diff --git a/build/webpack.config.js b/build/webpack.config.js index 883e983..0f465a6 100644 --- a/build/webpack.config.js +++ b/build/webpack.config.js @@ -29,6 +29,7 @@ const config = { plugins: [ new webpack.optimize.CommonsChunkPlugin({ name: 'vendor' }), page('index'), + page('render'), new FriendlyErrorsWebpackPlugin(), new ProgressBarPlugin() ], diff --git a/dist/builder.js b/dist/builder.js index 06ed889..d1c92a4 100644 --- a/dist/builder.js +++ b/dist/builder.js @@ -1,5 +1,5 @@ /** -* Builder v0.0.5 +* Builder v0.0.6 * (c) 2017 Abdelrahman Ismail * @license MIT */ @@ -3772,7 +3772,7 @@ var Section = function Section (options) { options = Object.assign({}, SECTION_OPTIONS, options); this.name = options.name; this.schema = options.schema; - this.data = Seeder.seed(options.schema); + this.data = options.data || Seeder.seed(options.schema); }; Section.prototype.set = function set (name, value) { @@ -3797,17 +3797,24 @@ Section.prototype.get = function get$$1 (name) { return obj[prop]; }; -var BuilderComponent = {render: function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[_c('div',{ref:"artboard",staticClass:"artboard",attrs:{"id":"artboard"}},_vm._l((_vm.$builder.sections),function(section){return _c(section.name,{key:section.id,tag:"component",attrs:{"id":section.id}})})),_c('div',{staticClass:"controller"},[(_vm.showIntro)?_c('div',{staticClass:"controller-intro"},[_c('h1',[_vm._v("Hello, start your project")]),_c('div',{staticClass:"grid is-center"},[_c('div',{staticClass:"column is-screen-6"},[_c('div',{staticClass:"input is-rounded"},[_c('input',{directives:[{name:"model",rawName:"v-model",value:(_vm.title),expression:"title"}],attrs:{"placeholder":"project name"},domProps:{"value":(_vm.title)},on:{"input":function($event){if($event.target.composing){ return; }_vm.title=$event.target.value;}}})])])])]):_vm._e(),_c('ul',{staticClass:"controller-list",class:{ 'is-hidden': !_vm.listShown }},_vm._l((_vm.sections),function(section){return _c('li',[_c('a',{staticClass:"controller-element",on:{"click":function($event){_vm.addElement(section);}}},[_vm._v(_vm._s(section))])])})),_c('div',{staticClass:"container"},[_c('div',{staticClass:"controller-buttons grid is-center"},[_c('div',{staticClass:"column is-screen-3"},[_c('button',{ref:"addButton",staticClass:"controller-add button is-blue is-block",attrs:{"disabled":_vm.showIntro && !_vm.title.length},on:{"click":function($event){_vm.addSection();}}},[_c('svg',{staticClass:"icon is-large",attrs:{"viewBox":"0 0 24 24"}},[_c('path',{attrs:{"d":"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"}})])])]),_c('div',{staticClass:"column is-screen-3"},[_c('button',{staticClass:"controller-submit button is-green is-block",on:{"click":_vm.submit}},[_c('svg',{staticClass:"icon is-large",attrs:{"viewBox":"0 0 24 24"}},[_c('path',{attrs:{"d":"M9 16.2L4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4L9 16.2z"}})])])])])])])])},staticRenderFns: [], +var BuilderComponent = {render: function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[_c('div',{ref:"artboard",staticClass:"artboard",attrs:{"id":"artboard"}},_vm._l((_vm.$builder.sections),function(section){return _c(section.name,{key:section.id,tag:"component",attrs:{"id":section.id}})})),_c('div',{staticClass:"controller"},[(_vm.showIntro && !this.$builder.sections.length)?_c('div',{staticClass:"controller-intro"},[_c('h1',[_vm._v("Hello, start your project")]),_c('div',{staticClass:"grid is-center"},[_c('div',{staticClass:"column is-screen-6"},[_c('div',{staticClass:"input is-rounded"},[_c('input',{directives:[{name:"model",rawName:"v-model",value:(_vm.title),expression:"title"}],attrs:{"placeholder":"project name"},domProps:{"value":(_vm.title)},on:{"input":function($event){if($event.target.composing){ return; }_vm.title=$event.target.value;}}})])])])]):_vm._e(),_c('ul',{staticClass:"controller-list",class:{ 'is-hidden': !_vm.listShown }},_vm._l((_vm.sections),function(section){return _c('li',[_c('a',{staticClass:"controller-element",on:{"click":function($event){_vm.addElement(section);}}},[_vm._v(_vm._s(section))])])})),_c('div',{staticClass:"container"},[_c('div',{staticClass:"controller-buttons grid is-center"},[_c('div',{staticClass:"column is-screen-3"},[_c('button',{ref:"addButton",staticClass:"controller-add button is-blue is-block",attrs:{"disabled":_vm.showIntro && !_vm.title.length},on:{"click":function($event){_vm.addSection();}}},[_c('svg',{staticClass:"icon is-large",attrs:{"viewBox":"0 0 24 24"}},[_c('path',{attrs:{"d":"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"}})])])]),_c('div',{staticClass:"column is-screen-3"},[_c('button',{staticClass:"controller-submit button is-green is-block",on:{"click":_vm.submit}},[_c('svg',{staticClass:"icon is-large",attrs:{"viewBox":"0 0 24 24"}},[_c('path',{attrs:{"d":"M9 16.2L4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4L9 16.2z"}})])])])])])])])},staticRenderFns: [], name: 'b-builder', props: { showIntro: { type: Boolean, default: true + }, + data: { + type: Object, + default: function () { return ({ + title: '', + sections: [] + }); } } }, data: function data () { return { - title: '', + title: null, listShown: false, sections: Object.keys(this.$builder.components) } @@ -3840,11 +3847,33 @@ var BuilderComponent = {render: function(){var _vm=this;var _h=_vm.$createElemen this.$emit('saved', this.$builder); } }, + created: function created () { + // sets the initial data. + this.$builder.set(this.data); + this.title = this.$builder.title; + }, mounted: function mounted () { this.$builder.rootEl = this.$refs.artboard; } }; +var Renderer = {render: function(){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"artboard",attrs:{"id":"artboard"}},_vm._l((_vm.$builder.sections),function(section){return _c(section.name,{key:section.id,tag:"component",attrs:{"id":section.id}})}))},staticRenderFns: [], + name: 'b-renderer', + props: { + data: { + type: Object, + default: function () { return ({ + title: '', + sections: [] + }); } + } + }, + created: function created () { + this.$builder.set(this.data); + this.$builder.isEditing = false; + } +}; + /**! * @fileOverview Kickass library to create and place poppers near their reference elements. * @version 1.11.1 @@ -6583,19 +6612,15 @@ Builder.install = function install (Vue, options) { var builder = new Builder(Object.assign({}, BUILDER_OPTIONS, options)); Vue.util.defineReactive(builder, 'sections', builder.sections); Vue.util.defineReactive(builder, 'isEditing', builder.isEditing); - - var BuilderInstance = Vue.extend(BuilderComponent); - Vue.component('builder', BuilderInstance.extend({ + var extension = { components: builder.components, - provide: function provide () { - return { - $builder: this.$builder - } - }, beforeCreate: function beforeCreate () { this.$builder = builder; } - })); + }; + // register the main components. + Vue.component('b-builder', Vue.extend(BuilderComponent).extend(extension)); + Vue.component('b-renderer', Vue.extend(Renderer).extend(extension)); }; /** @@ -6616,6 +6641,20 @@ Builder.use = function use (plugin, options) { PLUGINS.push({ plugin: plugin, options: options }); }; +Builder.prototype.set = function set (data) { + var this$1 = this; + + this.title = data.title !== undefined ? data.title : this.title; + if (data.sections && Array.isArray(data.sections)) { + data.sections.forEach(function (section) { + if (!section.schema) { + section.schema = this$1.components[section.name].options.$schema; + } + this$1.create(section); + }); + } +}; + /** * Outputs a JSON representation of the builder that can be used for rendering with the renderer component. */ @@ -6674,7 +6713,7 @@ if (typeof Vue !== 'undefined') { Vue.use(Builder); } -Builder.version = '0.0.5'; +Builder.version = '0.0.6'; Builder.types = types; return Builder; diff --git a/dist/builder.min.js b/dist/builder.min.js index 520a972..ac540cd 100644 --- a/dist/builder.min.js +++ b/dist/builder.min.js @@ -1 +1 @@ -!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):t.Builder=e()}(this,function(){"use strict";function t(t,e){return t===e||t!==t&&e!==e}function e(e,n){for(var r=e.length;r--;)if(t(e[r][0],n))return r;return-1}function n(t){var e=this,n=-1,r=null==t?0:t.length;for(this.clear();++n-1&&t%1==0&&t<=rn}function S(t){return null!=t&&A(t.length)&&!a(t)}function $(t){return E(t)&&S(t)}function L(t){if(!E(t)||i(t)!=un)return!1;var e=Ke(t);if(null===e)return!0;var n=dn.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&pn.call(n)==hn}function T(e,n,r){var o=e[n];xn.call(e,n)&&t(o,r)&&(void 0!==r||n in e)||g(e,n,r)}function N(t,e,n,r){var o=!n;n||(n={});for(var i=-1,s=e.length;++i-1&&t%1==0&&t1&&void 0!==arguments[1]?arguments[1]:"top")?"scrollTop":"scrollLeft",n=t.nodeName;if("BODY"===n||"HTML"===n){var r=window.document.documentElement;return(window.document.scrollingElement||r)[e]}return t[e]}function Ct(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=Ot(e,"top"),o=Ot(e,"left"),i=n?-1:1;return t.top+=r*i,t.bottom+=r*i,t.left+=o*i,t.right+=o*i,t}function jt(t,e){var n="x"===e?"Left":"Top",r="Left"===n?"Right":"Bottom";return+t["border"+n+"Width"].split("px")[0]+ +t["border"+r+"Width"].split("px")[0]}function Et(t,e,n,r){return Math.max(e["offset"+t],n["client"+t],n["offset"+t],Ho()?n["offset"+t]+r["margin"+("Height"===t?"Top":"Left")]+r["margin"+("Height"===t?"Bottom":"Right")]:0)}function kt(){var t=window.document.body,e=window.document.documentElement,n=Ho()&&window.getComputedStyle(e);return{height:Et("Height",t,e,n),width:Et("Width",t,e,n)}}function At(t){return Uo({},t,{right:t.left+t.width,bottom:t.top+t.height})}function St(t){var e={};if(Ho())try{e=t.getBoundingClientRect();var n=Ot(t,"top"),r=Ot(t,"left");e.top+=n,e.left+=r,e.bottom+=n,e.right+=r}catch(t){}else e=t.getBoundingClientRect();var o={left:e.left,top:e.top,width:e.right-e.left,height:e.bottom-e.top},i="HTML"===t.nodeName?kt():{},s=i.width||t.clientWidth||o.right-o.left,a=i.height||t.clientHeight||o.bottom-o.top,c=t.offsetWidth-s,u=t.offsetHeight-a;if(c||u){var l=mt(t);c-=jt(l,"x"),u-=jt(l,"y"),o.width-=c,o.height-=u}return At(o)}function $t(t,e){var n=Ho(),r="HTML"===e.nodeName,o=St(t),i=St(e),s=gt(t),a=mt(e),c=+a.borderTopWidth.split("px")[0],u=+a.borderLeftWidth.split("px")[0],l=At({top:o.top-i.top-c,left:o.left-i.left-u,width:o.width,height:o.height});if(l.marginTop=0,l.marginLeft=0,!n&&r){var f=+a.marginTop.split("px")[0],p=+a.marginLeft.split("px")[0];l.top-=c-f,l.bottom-=c-f,l.left-=u-p,l.right-=u-p,l.marginTop=f,l.marginLeft=p}return(n?e.contains(s):e===s&&"BODY"!==s.nodeName)&&(l=Ct(l,e)),l}function Lt(t){var e=window.document.documentElement,n=$t(t,e),r=Math.max(e.clientWidth,window.innerWidth||0),o=Math.max(e.clientHeight,window.innerHeight||0),i=Ot(e),s=Ot(e,"left");return At({top:i-n.top+n.marginTop,left:s-n.left+n.marginLeft,width:r,height:o})}function Tt(t){var e=t.nodeName;return"BODY"!==e&&"HTML"!==e&&("fixed"===mt(t,"position")||Tt(bt(t)))}function Nt(t,e,n,r){var o={top:0,left:0},i=xt(t,e);if("viewport"===r)o=Lt(i);else{var s=void 0;"scrollParent"===r?"BODY"===(s=gt(bt(t))).nodeName&&(s=window.document.documentElement):s="window"===r?window.document.documentElement:r;var a=$t(s,i);if("HTML"!==s.nodeName||Tt(i))o=a;else{var c=kt(),u=c.height,l=c.width;o.top+=a.top-a.marginTop,o.bottom=u+a.top,o.left+=a.left-a.marginLeft,o.right=l+a.left}}return o.left+=n,o.top+=n,o.right-=n,o.bottom-=n,o}function Pt(t){return t.width*t.height}function Bt(t,e,n,r,o){var i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0;if(-1===t.indexOf("auto"))return t;var s=Nt(n,r,i,o),a={top:{width:s.width,height:e.top-s.top},right:{width:s.right-e.right,height:s.height},bottom:{width:s.width,height:s.bottom-e.bottom},left:{width:e.left-s.left,height:s.height}},c=Object.keys(a).map(function(t){return Uo({key:t},a[t],{area:Pt(a[t])})}).sort(function(t,e){return e.area-t.area}),u=c.filter(function(t){var e=t.width,r=t.height;return e>=n.clientWidth&&r>=n.clientHeight}),l=u.length>0?u[0].key:c[0].key,f=t.split("-")[1];return l+(f?"-"+f:"")}function Mt(t,e,n){return $t(n,xt(e,n))}function zt(t){var e=window.getComputedStyle(t),n=parseFloat(e.marginTop)+parseFloat(e.marginBottom),r=parseFloat(e.marginLeft)+parseFloat(e.marginRight);return{width:t.offsetWidth+r,height:t.offsetHeight+n}}function Ft(t){var e={left:"right",right:"left",bottom:"top",top:"bottom"};return t.replace(/left|right|bottom|top/g,function(t){return e[t]})}function Ht(t,e,n){n=n.split("-")[0];var r=zt(t),o={width:r.width,height:r.height},i=-1!==["right","left"].indexOf(n),s=i?"top":"left",a=i?"left":"top",c=i?"height":"width",u=i?"width":"height";return o[s]=e[s]+e[c]/2-r[c]/2,o[a]=n===a?e[a]-r[u]:e[Ft(a)],o}function Dt(t,e){return Array.prototype.find?t.find(e):t.filter(e)[0]}function Wt(t,e,n){if(Array.prototype.findIndex)return t.findIndex(function(t){return t[e]===n});var r=Dt(t,function(t){return t[e]===n});return t.indexOf(r)}function It(t,e,n){return(void 0===n?t:t.slice(0,Wt(t,"name",n))).forEach(function(t){t.function&&console.warn("`modifier.function` is deprecated, use `modifier.fn`!");var n=t.function||t.fn;t.enabled&&vt(n)&&(e.offsets.popper=At(e.offsets.popper),e.offsets.reference=At(e.offsets.reference),e=n(e,t))}),e}function Ut(){if(!this.state.isDestroyed){var t={instance:this,styles:{},attributes:{},flipped:!1,offsets:{}};t.offsets.reference=Mt(this.state,this.popper,this.reference),t.placement=Bt(this.options.placement,t.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),t.originalPlacement=t.placement,t.offsets.popper=Ht(this.popper,t.offsets.reference,t.placement),t.offsets.popper.position="absolute",t=It(this.modifiers,t),this.state.isCreated?this.options.onUpdate(t):(this.state.isCreated=!0,this.options.onCreate(t))}}function Rt(t,e){return t.some(function(t){var n=t.name;return t.enabled&&n===e})}function Yt(t){for(var e=[!1,"ms","Webkit","Moz","O"],n=t.charAt(0).toUpperCase()+t.slice(1),r=0;r1&&void 0!==arguments[1]&&arguments[1],n=Yo.indexOf(t),r=Yo.slice(n+1).concat(Yo.slice(0,n));return e?r.reverse():r}function oe(t,e,n,r){var o=t.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),i=+o[1],s=o[2];if(!i)return t;if(0===s.indexOf("%")){var a=void 0;switch(s){case"%p":a=n;break;case"%":case"%r":default:a=r}return At(a)[e]/100*i}if("vh"===s||"vw"===s){return("vh"===s?Math.max(document.documentElement.clientHeight,window.innerHeight||0):Math.max(document.documentElement.clientWidth,window.innerWidth||0))/100*i}return i}function ie(t,e,n,r){var o=[0,0],i=-1!==["right","left"].indexOf(r),s=t.split(/(\+|\-)/).map(function(t){return t.trim()}),a=s.indexOf(Dt(s,function(t){return-1!==t.search(/,|\s/)}));s[a]&&-1===s[a].indexOf(",")&&console.warn("Offsets separated by white space(s) are deprecated, use a comma (,) instead.");var c=/\s*,\s*|\s+/,u=-1!==a?[s.slice(0,a).concat([s[a].split(c)[0]]),[s[a].split(c)[1]].concat(s.slice(a+1))]:[s];return(u=u.map(function(t,r){var o=(1===r?!i:i)?"height":"width",s=!1;return t.reduce(function(t,e){return""===t[t.length-1]&&-1!==["+","-"].indexOf(e)?(t[t.length-1]=e,s=!0,t):s?(t[t.length-1]+=e,s=!1,t):t.concat(e)},[]).map(function(t){return oe(t,o,e,n)})})).forEach(function(t,e){t.forEach(function(n,r){Xt(n)&&(o[e]+=n*("-"===t[r-1]?-1:1))})}),o}var se=Array.prototype.splice;n.prototype.clear=function(){this.__data__=[],this.size=0},n.prototype.delete=function(t){var n=this.__data__,r=e(n,t);return!(r<0||(r==n.length-1?n.pop():se.call(n,r,1),--this.size,0))},n.prototype.get=function(t){var n=this.__data__,r=e(n,t);return r<0?void 0:n[r][1]},n.prototype.has=function(t){return e(this.__data__,t)>-1},n.prototype.set=function(t,n){var r=this.__data__,o=e(r,t);return o<0?(++this.size,r.push([t,n])):r[o][1]=n,this};var ae="object"==typeof global&&global&&global.Object===Object&&global,ce="object"==typeof self&&self&&self.Object===Object&&self,ue=ae||ce||Function("return this")(),le=ue.Symbol,fe=Object.prototype,pe=fe.hasOwnProperty,de=fe.toString,he=le?le.toStringTag:void 0,ve=Object.prototype.toString,me="[object Null]",be="[object Undefined]",ge=le?le.toStringTag:void 0,ye="[object AsyncFunction]",we="[object Function]",_e="[object GeneratorFunction]",xe="[object Proxy]",Oe=ue["__core-js_shared__"],Ce=function(){var t=/[^.]+$/.exec(Oe&&Oe.keys&&Oe.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),je=Function.prototype.toString,Ee=/[\\^$.*+?()[\]{}|]/g,ke=/^\[object .+?Constructor\]$/,Ae=Function.prototype,Se=Object.prototype,$e=Ae.toString,Le=Se.hasOwnProperty,Te=RegExp("^"+$e.call(Le).replace(Ee,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ne=p(ue,"Map"),Pe=p(Object,"create"),Be="__lodash_hash_undefined__",Me=Object.prototype.hasOwnProperty,ze=Object.prototype.hasOwnProperty,Fe="__lodash_hash_undefined__";d.prototype.clear=function(){this.__data__=Pe?Pe(null):{},this.size=0},d.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},d.prototype.get=function(t){var e=this.__data__;if(Pe){var n=e[t];return n===Be?void 0:n}return Me.call(e,t)?e[t]:void 0},d.prototype.has=function(t){var e=this.__data__;return Pe?void 0!==e[t]:ze.call(e,t)},d.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=Pe&&void 0===e?Fe:e,this},m.prototype.clear=function(){this.size=0,this.__data__={hash:new d,map:new(Ne||n),string:new d}},m.prototype.delete=function(t){var e=v(this,t).delete(t);return this.size-=e?1:0,e},m.prototype.get=function(t){return v(this,t).get(t)},m.prototype.has=function(t){return v(this,t).has(t)},m.prototype.set=function(t,e){var n=v(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};var He=200;b.prototype.clear=function(){this.__data__=new n,this.size=0},b.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},b.prototype.get=function(t){return this.__data__.get(t)},b.prototype.has=function(t){return this.__data__.has(t)},b.prototype.set=function(t,e){var r=this.__data__;if(r instanceof n){var o=r.__data__;if(!Ne||o.length0){if(++e>=Sn)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(An),Nn=function(t){return V(function(e,n){var r=-1,o=n.length,i=o>1?n[o-1]:void 0,s=o>2?n[2]:void 0;for(i=t.length>3&&"function"==typeof i?(o--,i):void 0,s&&G(n[0],n[1],s)&&(i=o<3?void 0:i,o=1),e=Object(e);++r-1},at.prototype.set=function(t,e){var n=this.__data__,r=to(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this};var no=at,ro=qr(ar,"Map"),oo=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t},io=function(t,e){var n=t.__data__;return oo(e)?n["string"==typeof e?"string":"hash"]:n.map};ct.prototype.clear=function(){this.size=0,this.__data__={hash:new Xr,map:new(ro||no),string:new Xr}},ct.prototype.delete=function(t){var e=io(this,t).delete(t);return this.size-=e?1:0,e},ct.prototype.get=function(t){return io(this,t).get(t)},ct.prototype.has=function(t){return io(this,t).has(t)},ct.prototype.set=function(t,e){var n=io(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};var so=ct,ao="Expected a function";ut.Cache=so;var co=ut,uo=500,lo=/^\./,fo=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,po=/\\(\\)?/g,ho=function(t){var e=co(t,function(t){return n.size===uo&&n.clear(),t}),n=e.cache;return e}(function(t){var e=[];return lo.test(t)&&e.push(""),t.replace(fo,function(t,n,r,o){e.push(r?o.replace(po,"$1"):n||t)}),e}),vo=function(t,e){for(var n=-1,r=null==t?0:t.length,o=Array(r);++n=0){Bo=1;break}var zo=No&&function(t){return To.some(function(e){return(t||"").toString().indexOf(e)>-1})}(window.MutationObserver)?function(t){var e=!1,n=0,r=document.createElement("span");return new MutationObserver(function(){t(),e=!1}).observe(r,{attributes:!0}),function(){e||(e=!0,r.setAttribute("x-index",n),n+=1)}}:function(t){var e=!1;return function(){e||(e=!0,setTimeout(function(){e=!1,t()},Bo))}},Fo=void 0,Ho=function(){return void 0===Fo&&(Fo=-1!==navigator.appVersion.indexOf("MSIE 10")),Fo},Do=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},Wo=function(){function t(t,e){for(var n=0;nr[t]&&!e.escapeWithReference&&(o=Math.min(i[n],r[t]-("right"===t?i.width:i.height))),Io({},n,o)}};return o.forEach(function(t){var e=-1!==["left","top"].indexOf(t)?"primary":"secondary";i=Uo({},i,s[e](t))}),t.offsets.popper=i,t},priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:function(t){var e=t.offsets,n=e.popper,r=e.reference,o=t.placement.split("-")[0],i=Math.floor,s=-1!==["top","bottom"].indexOf(o),a=s?"right":"bottom",c=s?"left":"top",u=s?"width":"height";return n[a]i(r[a])&&(t.offsets.popper[c]=i(r[a])),t}},arrow:{order:500,enabled:!0,fn:function(t,e){if(!ee(t.instance.modifiers,"arrow","keepTogether"))return t;var n=e.element;if("string"==typeof n){if(!(n=t.instance.popper.querySelector(n)))return t}else if(!t.instance.popper.contains(n))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),t;var r=t.placement.split("-")[0],o=t.offsets,i=o.popper,s=o.reference,a=-1!==["left","right"].indexOf(r),c=a?"height":"width",u=a?"top":"left",l=a?"left":"top",f=a?"bottom":"right",p=zt(n)[c];s[f]-pi[f]&&(t.offsets.popper[u]+=s[u]+p-i[f]);var d=s[u]+s[c]/2-p/2-At(t.offsets.popper)[u];return d=Math.max(Math.min(i[c]-p,d),0),t.arrowElement=n,t.offsets.arrow={},t.offsets.arrow[u]=Math.round(d),t.offsets.arrow[l]="",t},element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:function(t,e){if(Rt(t.instance.modifiers,"inner"))return t;if(t.flipped&&t.placement===t.originalPlacement)return t;var n=Nt(t.instance.popper,t.instance.reference,e.padding,e.boundariesElement),r=t.placement.split("-")[0],o=Ft(r),i=t.placement.split("-")[1]||"",s=[];switch(e.behavior){case qo.FLIP:s=[r,o];break;case qo.CLOCKWISE:s=re(r);break;case qo.COUNTERCLOCKWISE:s=re(r,!0);break;default:s=e.behavior}return s.forEach(function(a,c){if(r!==a||s.length===c+1)return t;r=t.placement.split("-")[0],o=Ft(r);var u=t.offsets.popper,l=t.offsets.reference,f=Math.floor,p="left"===r&&f(u.right)>f(l.left)||"right"===r&&f(u.left)f(l.top)||"bottom"===r&&f(u.top)f(n.right),v=f(u.top)f(n.bottom),b="left"===r&&d||"right"===r&&h||"top"===r&&v||"bottom"===r&&m,g=-1!==["top","bottom"].indexOf(r),y=!!e.flipVariations&&(g&&"start"===i&&d||g&&"end"===i&&h||!g&&"start"===i&&v||!g&&"end"===i&&m);(p||b||y)&&(t.flipped=!0,(p||b)&&(r=s[c+1]),y&&(i=ne(i)),t.placement=r+(i?"-"+i:""),t.offsets.popper=Uo({},t.offsets.popper,Ht(t.instance.popper,t.offsets.reference,t.placement)),t=It(t.instance.modifiers,t,"flip"))}),t},behavior:"flip",padding:5,boundariesElement:"viewport"},inner:{order:700,enabled:!1,fn:function(t){var e=t.placement,n=e.split("-")[0],r=t.offsets,o=r.popper,i=r.reference,s=-1!==["left","right"].indexOf(n),a=-1===["top","left"].indexOf(n);return o[s?"left":"top"]=i[e]-(a?o[s?"width":"height"]:0),t.placement=Ft(e),t.offsets.popper=At(o),t}},hide:{order:800,enabled:!0,fn:function(t){if(!ee(t.instance.modifiers,"hide","preventOverflow"))return t;var e=t.offsets.reference,n=Dt(t.instance.modifiers,function(t){return"preventOverflow"===t.name}).boundaries;if(e.bottomn.right||e.top>n.bottom||e.right2&&void 0!==arguments[2]?arguments[2]:{};Do(this,t),this.scheduleUpdate=function(){return requestAnimationFrame(r.update)},this.update=zo(this.update.bind(this)),this.options=Uo({},t.Defaults,o),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=e.jquery?e[0]:e,this.popper=n.jquery?n[0]:n,this.options.modifiers={},Object.keys(Uo({},t.Defaults.modifiers,o.modifiers)).forEach(function(e){r.options.modifiers[e]=Uo({},t.Defaults.modifiers[e]||{},o.modifiers?o.modifiers[e]:{})}),this.modifiers=Object.keys(this.options.modifiers).map(function(t){return Uo({name:t},r.options.modifiers[t])}).sort(function(t,e){return t.order-e.order}),this.modifiers.forEach(function(t){t.enabled&&vt(t.onLoad)&&t.onLoad(r.reference,r.popper,r.options,t,r.state)}),this.update();var i=this.options.eventsEnabled;i&&this.enableEventListeners(),this.state.eventsEnabled=i}return Wo(t,[{key:"update",value:function(){return Ut.call(this)}},{key:"destroy",value:function(){return qt.call(this)}},{key:"enableEventListeners",value:function(){return Kt.call(this)}},{key:"disableEventListeners",value:function(){return Qt.call(this)}}]),t}();Go.Utils=("undefined"!=typeof window?window:global).PopperUtils,Go.placements=Ro,Go.Defaults=Vo;var Ko={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.$builder.isEditing?n("div",{ref:"styler",staticClass:"styler"},[n("ul",{staticClass:"styler-list"},["button"===t.type||"section"===t.type?n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("colorer")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-palettes"}})])])]):t._e(),"button"===t.type?n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("link")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-link"}})])])]):t._e(),"header"===t.type||"section"===t.type?n("li",[n("button",{staticClass:"styler-button",on:{click:t.removeSection}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-trash"}})])])]):t._e(),"text"===t.type?[n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("textColor")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-palettes"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("align")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-align"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("textStyle")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-textStyle"}})])])])]:t._e()],2),n("ul",{staticClass:"styler-list"},["colorer"===t.currentOption?n("li",[n("ul",{staticClass:"colorer"},t._l(t.colors,function(e){return n("li",[n("input",{directives:[{name:"model",rawName:"v-model",value:t.colorerColor,expression:"colorerColor"}],attrs:{type:"radio",id:"color"+(e.charAt(0).toUpperCase()+e.slice(1)),name:"colorer"},domProps:{value:e,checked:t._q(t.colorerColor,e)},on:{__c:function(n){t.colorerColor=e}}})])}))]):t._e(),"textColor"===t.currentOption?n("li",[n("ul",{staticClass:"colorer"},t._l(t.colors,function(e,r){return n("li",[n("input",{directives:[{name:"model",rawName:"v-model",value:t.textColor,expression:"textColor"}],attrs:{type:"radio",id:"color"+(e.charAt(0).toUpperCase()+e.slice(1)),name:"colorer"},domProps:{value:t.textColors[r],checked:t._q(t.textColor,t.textColors[r])},on:{click:function(e){t.execute("forecolor",t.textColor)},__c:function(e){t.textColor=t.textColors[r]}}})])}))]):t._e(),"link"===t.currentOption?n("li",[n("div",{staticClass:"input is-rounded is-button"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.url,expression:"url"}],attrs:{type:"text",placeholder:"type your link"},domProps:{value:t.url},on:{input:function(e){e.target.composing||(t.url=e.target.value)}}}),n("button",{staticClass:"button is-green",on:{click:t.addLink}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-link"}})])])])]):t._e(),"align"===t.currentOption?n("li",[n("ul",{staticClass:"align"},[n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("justifyleft")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-left"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("justifycenter")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-center"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("justifyright")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-right"}})])])])])]):t._e(),"textStyle"===t.currentOption?n("li",[n("ul",{staticClass:"align"},[n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("bold")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-bold"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("italic")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-italic"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("underline")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-underline"}})])])])])]):t._e()])]):t._e()},staticRenderFns:[],name:"styler",props:["el","type","name","section"],data:function(){return{colors:["blue","green","red","black","white"],textColors:["#4da1ff","#38E4B7","#EA4F52","#000000","#FFFFFF"],textColor:"",oldColorerColor:"",colorerColor:"",mouseTarget:"",currentOption:"",url:""}},watch:{colorerColor:function(){this.changeColor()}},methods:{updateOption:function(t){this.currentOption=t,this.popper.update()},addLink:function(){this.section.set(this.name+".href",this.url)},changeColor:function(){this.removeClass("is-"+this.oldColorerColor),this.oldColorerColor=this.colorerColor,this.addClass("is-"+this.colorerColor)},addClass:function(t){this.section.set(this.name,function(e){e&&e.classes&&Array.isArray(e.classes)&&(e=e.classes),e.push(t)})},removeClass:function(t){var e=this;if(Array.isArray(t))return t.forEach(function(t){e.removeClass(t)});this.section.set(this.name,function(e){e&&e.classes&&Array.isArray(e.classes)&&(e=e.classes);var n=e.indexOf(t);e.splice(n,1)})},removeSection:function(){document.removeEventListener("click",this.hideStyler),this.popper.destroy(),this.styler.remove(),this.$builder.remove(this.id)},execute:function(t,e){void 0===e&&(e=null),document.execCommand(t,!1,e)},showStyler:function(){this.styler.classList.add("is-visible"),this.currentOption="",this.popper.update()},hideStyler:function(t){var e=t.target;if(!pt(e,this.styler)&&!pt(e,this.el)){if(this.styler.classList.remove("is-visible"),document.removeEventListener("click",this.hideStyler),"section"===this.type)return;if("button"===this.type)return void this.section.set(this.name+".text",this.el.innerHTML);this.section.set(this.name,this.el.innerHTML)}}},created:function(){"button"===this.type&&(this.url=this.section.get(this.name+".href"))},mounted:function(){var t=this;if(this.$builder.isEditing){this.styler=this.$refs.styler,this.id=Number(this.section.id);var e="section"===this.$props.type?"left-start":"top";this.popper=new Go(this.el,this.styler,{placement:e}),this.el.addEventListener("click",function(){t.showStyler(),document.addEventListener("click",t.hideStyler,!1)},!1)}}},Jo=[],Qo={},Xo={title:"",intro:!0,sections:[],plugins:[]},Zo=null,ti=function(t){this.title=t.title,this.isEditing=!0,this.intro=t.intro,this.sections=t.sections,this.components={},this.installPlugins()};return ti.prototype.create=function(t){this.sections.push(new $o(t))},ti.prototype.outputFragment=function(){var t=document.createDocumentFragment();return t.appendChild(document.head.cloneNode(!0)),t.appendChild(this.rootEl.cloneNode(!0)),t},ti.prototype.find=function(t){return this.sections.find(function(e){return e.id===t})},ti.prototype.remove=function(t){var e=this.sections.findIndex(function(e){return e.id===t});this.sections.splice(e,1)},ti.component=function(t,e){ti.use(function(n){n.builder.component(t,e)})},ti.mix=function(t){Qo=Nn(Qo,t)},ti.prototype.component=function(t,e){"object"==typeof t&&(t=(e=t).name),e.extend||(e=Zo.extend(e)),this.components[t]=e.extend({directives:{styler:this.styler},mixins:[this.mixin],components:Qo.components})},ti.prototype.installPlugins=function(){var t=this;Jo.forEach(function(e){e.plugin({builder:t,Vue:Zo},e.options)}),Jo=[]},ti.install=function(t,e){if(void 0===e&&(e={}),!Zo){Zo=t;var n=new ti(Object.assign({},Xo,e));t.util.defineReactive(n,"sections",n.sections),t.util.defineReactive(n,"isEditing",n.isEditing);var r=t.extend(Lo);t.component("builder",r.extend({components:n.components,provide:function(){return{$builder:this.$builder}},beforeCreate:function(){this.$builder=n}}))}},ti.use=function(t,e){if(void 0===e&&(e={}),"function"!=typeof t)return console.warn("Plugins must be a function");Jo.push({plugin:t,options:e})},ti.prototype.toJSON=function(){return{title:this.title,sections:this.sections.map(function(t){return{name:t.name,data:t.data}})}},ti.prototype.preview=function(){var t=window.open("about:blank","print_preview").document;t.open(),t.write("\n \n "+document.documentElement.innerHTML+"\n ")},ti.prototype.export=function(t){return void 0===t&&(t="json"),"zip"===t?"function"==typeof this.download?this.download():console.warn("You do not have the zip plugin installed."):"preview"===t?this.preview():this.toJSON()},ti.use(function(t){var e=t.builder,n=t.Vue.extend(Ko).extend({beforeCreate:function(){this.$builder=e}});e.styler={inserted:function(t,e,r){var o=document.createElement("div");o.id="newNode",t.parentNode.appendChild(o),new n({propsData:{el:t,section:r.context.$section,type:e.arg||dt(e.expression,r.context.$section.schema)||ht(t.tagName),name:e.expression,editable:t.classList.contains("is-editable")}}).$mount("#newNode")}}}),ti.use(function(t){var e=t.builder;e.mixin={provide:function(){var t={};return this.$builder&&(t.$builder=this.$builder),this.$section&&(t.$section=this.$section),t},beforeCreate:function(){this.$builder=e,this.$options.propsData&&void 0!==this.$options.propsData.id&&(this.$section=this.$builder.find(this.$options.propsData.id),this.$options.computed||(this.$options.computed={}),this.$options.computed.$sectionData=function(){return this.$section.data})},mounted:function(){Array.from(this.$el.querySelectorAll(".is-editable")).forEach(function(t){t.contentEditable="true"})}}}),"undefined"!=typeof Vue&&Vue.use(ti),ti.version="0.0.5",ti.types=nr,ti}); \ No newline at end of file +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):t.Builder=e()}(this,function(){"use strict";function t(t,e){return t===e||t!==t&&e!==e}function e(e,n){for(var r=e.length;r--;)if(t(e[r][0],n))return r;return-1}function n(t){var e=this,n=-1,r=null==t?0:t.length;for(this.clear();++n-1&&t%1==0&&t<=rn}function $(t){return null!=t&&A(t.length)&&!a(t)}function S(t){return E(t)&&$(t)}function L(t){if(!E(t)||i(t)!=un)return!1;var e=Ke(t);if(null===e)return!0;var n=dn.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&pn.call(n)==hn}function T(e,n,r){var o=e[n];xn.call(e,n)&&t(o,r)&&(void 0!==r||n in e)||g(e,n,r)}function N(t,e,n,r){var o=!n;n||(n={});for(var i=-1,s=e.length;++i-1&&t%1==0&&t1&&void 0!==arguments[1]?arguments[1]:"top")?"scrollTop":"scrollLeft",n=t.nodeName;if("BODY"===n||"HTML"===n){var r=window.document.documentElement;return(window.document.scrollingElement||r)[e]}return t[e]}function Ct(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=Ot(e,"top"),o=Ot(e,"left"),i=n?-1:1;return t.top+=r*i,t.bottom+=r*i,t.left+=o*i,t.right+=o*i,t}function jt(t,e){var n="x"===e?"Left":"Top",r="Left"===n?"Right":"Bottom";return+t["border"+n+"Width"].split("px")[0]+ +t["border"+r+"Width"].split("px")[0]}function Et(t,e,n,r){return Math.max(e["offset"+t],n["client"+t],n["offset"+t],Do()?n["offset"+t]+r["margin"+("Height"===t?"Top":"Left")]+r["margin"+("Height"===t?"Bottom":"Right")]:0)}function kt(){var t=window.document.body,e=window.document.documentElement,n=Do()&&window.getComputedStyle(e);return{height:Et("Height",t,e,n),width:Et("Width",t,e,n)}}function At(t){return Uo({},t,{right:t.left+t.width,bottom:t.top+t.height})}function $t(t){var e={};if(Do())try{e=t.getBoundingClientRect();var n=Ot(t,"top"),r=Ot(t,"left");e.top+=n,e.left+=r,e.bottom+=n,e.right+=r}catch(t){}else e=t.getBoundingClientRect();var o={left:e.left,top:e.top,width:e.right-e.left,height:e.bottom-e.top},i="HTML"===t.nodeName?kt():{},s=i.width||t.clientWidth||o.right-o.left,a=i.height||t.clientHeight||o.bottom-o.top,c=t.offsetWidth-s,u=t.offsetHeight-a;if(c||u){var l=mt(t);c-=jt(l,"x"),u-=jt(l,"y"),o.width-=c,o.height-=u}return At(o)}function St(t,e){var n=Do(),r="HTML"===e.nodeName,o=$t(t),i=$t(e),s=gt(t),a=mt(e),c=+a.borderTopWidth.split("px")[0],u=+a.borderLeftWidth.split("px")[0],l=At({top:o.top-i.top-c,left:o.left-i.left-u,width:o.width,height:o.height});if(l.marginTop=0,l.marginLeft=0,!n&&r){var f=+a.marginTop.split("px")[0],p=+a.marginLeft.split("px")[0];l.top-=c-f,l.bottom-=c-f,l.left-=u-p,l.right-=u-p,l.marginTop=f,l.marginLeft=p}return(n?e.contains(s):e===s&&"BODY"!==s.nodeName)&&(l=Ct(l,e)),l}function Lt(t){var e=window.document.documentElement,n=St(t,e),r=Math.max(e.clientWidth,window.innerWidth||0),o=Math.max(e.clientHeight,window.innerHeight||0),i=Ot(e),s=Ot(e,"left");return At({top:i-n.top+n.marginTop,left:s-n.left+n.marginLeft,width:r,height:o})}function Tt(t){var e=t.nodeName;return"BODY"!==e&&"HTML"!==e&&("fixed"===mt(t,"position")||Tt(bt(t)))}function Nt(t,e,n,r){var o={top:0,left:0},i=xt(t,e);if("viewport"===r)o=Lt(i);else{var s=void 0;"scrollParent"===r?"BODY"===(s=gt(bt(t))).nodeName&&(s=window.document.documentElement):s="window"===r?window.document.documentElement:r;var a=St(s,i);if("HTML"!==s.nodeName||Tt(i))o=a;else{var c=kt(),u=c.height,l=c.width;o.top+=a.top-a.marginTop,o.bottom=u+a.top,o.left+=a.left-a.marginLeft,o.right=l+a.left}}return o.left+=n,o.top+=n,o.right-=n,o.bottom-=n,o}function Pt(t){return t.width*t.height}function Bt(t,e,n,r,o){var i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0;if(-1===t.indexOf("auto"))return t;var s=Nt(n,r,i,o),a={top:{width:s.width,height:e.top-s.top},right:{width:s.right-e.right,height:s.height},bottom:{width:s.width,height:s.bottom-e.bottom},left:{width:e.left-s.left,height:s.height}},c=Object.keys(a).map(function(t){return Uo({key:t},a[t],{area:Pt(a[t])})}).sort(function(t,e){return e.area-t.area}),u=c.filter(function(t){var e=t.width,r=t.height;return e>=n.clientWidth&&r>=n.clientHeight}),l=u.length>0?u[0].key:c[0].key,f=t.split("-")[1];return l+(f?"-"+f:"")}function Mt(t,e,n){return St(n,xt(e,n))}function zt(t){var e=window.getComputedStyle(t),n=parseFloat(e.marginTop)+parseFloat(e.marginBottom),r=parseFloat(e.marginLeft)+parseFloat(e.marginRight);return{width:t.offsetWidth+r,height:t.offsetHeight+n}}function Ft(t){var e={left:"right",right:"left",bottom:"top",top:"bottom"};return t.replace(/left|right|bottom|top/g,function(t){return e[t]})}function Ht(t,e,n){n=n.split("-")[0];var r=zt(t),o={width:r.width,height:r.height},i=-1!==["right","left"].indexOf(n),s=i?"top":"left",a=i?"left":"top",c=i?"height":"width",u=i?"width":"height";return o[s]=e[s]+e[c]/2-r[c]/2,o[a]=n===a?e[a]-r[u]:e[Ft(a)],o}function Dt(t,e){return Array.prototype.find?t.find(e):t.filter(e)[0]}function Wt(t,e,n){if(Array.prototype.findIndex)return t.findIndex(function(t){return t[e]===n});var r=Dt(t,function(t){return t[e]===n});return t.indexOf(r)}function It(t,e,n){return(void 0===n?t:t.slice(0,Wt(t,"name",n))).forEach(function(t){t.function&&console.warn("`modifier.function` is deprecated, use `modifier.fn`!");var n=t.function||t.fn;t.enabled&&vt(n)&&(e.offsets.popper=At(e.offsets.popper),e.offsets.reference=At(e.offsets.reference),e=n(e,t))}),e}function Rt(){if(!this.state.isDestroyed){var t={instance:this,styles:{},attributes:{},flipped:!1,offsets:{}};t.offsets.reference=Mt(this.state,this.popper,this.reference),t.placement=Bt(this.options.placement,t.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),t.originalPlacement=t.placement,t.offsets.popper=Ht(this.popper,t.offsets.reference,t.placement),t.offsets.popper.position="absolute",t=It(this.modifiers,t),this.state.isCreated?this.options.onUpdate(t):(this.state.isCreated=!0,this.options.onCreate(t))}}function Ut(t,e){return t.some(function(t){var n=t.name;return t.enabled&&n===e})}function Yt(t){for(var e=[!1,"ms","Webkit","Moz","O"],n=t.charAt(0).toUpperCase()+t.slice(1),r=0;r1&&void 0!==arguments[1]&&arguments[1],n=qo.indexOf(t),r=qo.slice(n+1).concat(qo.slice(0,n));return e?r.reverse():r}function oe(t,e,n,r){var o=t.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),i=+o[1],s=o[2];if(!i)return t;if(0===s.indexOf("%")){var a=void 0;switch(s){case"%p":a=n;break;case"%":case"%r":default:a=r}return At(a)[e]/100*i}if("vh"===s||"vw"===s){return("vh"===s?Math.max(document.documentElement.clientHeight,window.innerHeight||0):Math.max(document.documentElement.clientWidth,window.innerWidth||0))/100*i}return i}function ie(t,e,n,r){var o=[0,0],i=-1!==["right","left"].indexOf(r),s=t.split(/(\+|\-)/).map(function(t){return t.trim()}),a=s.indexOf(Dt(s,function(t){return-1!==t.search(/,|\s/)}));s[a]&&-1===s[a].indexOf(",")&&console.warn("Offsets separated by white space(s) are deprecated, use a comma (,) instead.");var c=/\s*,\s*|\s+/,u=-1!==a?[s.slice(0,a).concat([s[a].split(c)[0]]),[s[a].split(c)[1]].concat(s.slice(a+1))]:[s];return(u=u.map(function(t,r){var o=(1===r?!i:i)?"height":"width",s=!1;return t.reduce(function(t,e){return""===t[t.length-1]&&-1!==["+","-"].indexOf(e)?(t[t.length-1]=e,s=!0,t):s?(t[t.length-1]+=e,s=!1,t):t.concat(e)},[]).map(function(t){return oe(t,o,e,n)})})).forEach(function(t,e){t.forEach(function(n,r){Xt(n)&&(o[e]+=n*("-"===t[r-1]?-1:1))})}),o}var se=Array.prototype.splice;n.prototype.clear=function(){this.__data__=[],this.size=0},n.prototype.delete=function(t){var n=this.__data__,r=e(n,t);return!(r<0||(r==n.length-1?n.pop():se.call(n,r,1),--this.size,0))},n.prototype.get=function(t){var n=this.__data__,r=e(n,t);return r<0?void 0:n[r][1]},n.prototype.has=function(t){return e(this.__data__,t)>-1},n.prototype.set=function(t,n){var r=this.__data__,o=e(r,t);return o<0?(++this.size,r.push([t,n])):r[o][1]=n,this};var ae="object"==typeof global&&global&&global.Object===Object&&global,ce="object"==typeof self&&self&&self.Object===Object&&self,ue=ae||ce||Function("return this")(),le=ue.Symbol,fe=Object.prototype,pe=fe.hasOwnProperty,de=fe.toString,he=le?le.toStringTag:void 0,ve=Object.prototype.toString,me="[object Null]",be="[object Undefined]",ge=le?le.toStringTag:void 0,ye="[object AsyncFunction]",we="[object Function]",_e="[object GeneratorFunction]",xe="[object Proxy]",Oe=ue["__core-js_shared__"],Ce=function(){var t=/[^.]+$/.exec(Oe&&Oe.keys&&Oe.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),je=Function.prototype.toString,Ee=/[\\^$.*+?()[\]{}|]/g,ke=/^\[object .+?Constructor\]$/,Ae=Function.prototype,$e=Object.prototype,Se=Ae.toString,Le=$e.hasOwnProperty,Te=RegExp("^"+Se.call(Le).replace(Ee,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ne=p(ue,"Map"),Pe=p(Object,"create"),Be="__lodash_hash_undefined__",Me=Object.prototype.hasOwnProperty,ze=Object.prototype.hasOwnProperty,Fe="__lodash_hash_undefined__";d.prototype.clear=function(){this.__data__=Pe?Pe(null):{},this.size=0},d.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},d.prototype.get=function(t){var e=this.__data__;if(Pe){var n=e[t];return n===Be?void 0:n}return Me.call(e,t)?e[t]:void 0},d.prototype.has=function(t){var e=this.__data__;return Pe?void 0!==e[t]:ze.call(e,t)},d.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=Pe&&void 0===e?Fe:e,this},m.prototype.clear=function(){this.size=0,this.__data__={hash:new d,map:new(Ne||n),string:new d}},m.prototype.delete=function(t){var e=v(this,t).delete(t);return this.size-=e?1:0,e},m.prototype.get=function(t){return v(this,t).get(t)},m.prototype.has=function(t){return v(this,t).has(t)},m.prototype.set=function(t,e){var n=v(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};var He=200;b.prototype.clear=function(){this.__data__=new n,this.size=0},b.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},b.prototype.get=function(t){return this.__data__.get(t)},b.prototype.has=function(t){return this.__data__.has(t)},b.prototype.set=function(t,e){var r=this.__data__;if(r instanceof n){var o=r.__data__;if(!Ne||o.length0){if(++e>=$n)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(An),Nn=function(t){return V(function(e,n){var r=-1,o=n.length,i=o>1?n[o-1]:void 0,s=o>2?n[2]:void 0;for(i=t.length>3&&"function"==typeof i?(o--,i):void 0,s&&G(n[0],n[1],s)&&(i=o<3?void 0:i,o=1),e=Object(e);++r-1},at.prototype.set=function(t,e){var n=this.__data__,r=to(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this};var no=at,ro=qr(ar,"Map"),oo=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t},io=function(t,e){var n=t.__data__;return oo(e)?n["string"==typeof e?"string":"hash"]:n.map};ct.prototype.clear=function(){this.size=0,this.__data__={hash:new Xr,map:new(ro||no),string:new Xr}},ct.prototype.delete=function(t){var e=io(this,t).delete(t);return this.size-=e?1:0,e},ct.prototype.get=function(t){return io(this,t).get(t)},ct.prototype.has=function(t){return io(this,t).has(t)},ct.prototype.set=function(t,e){var n=io(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};var so=ct,ao="Expected a function";ut.Cache=so;var co=ut,uo=500,lo=/^\./,fo=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,po=/\\(\\)?/g,ho=function(t){var e=co(t,function(t){return n.size===uo&&n.clear(),t}),n=e.cache;return e}(function(t){var e=[];return lo.test(t)&&e.push(""),t.replace(fo,function(t,n,r,o){e.push(r?o.replace(po,"$1"):n||t)}),e}),vo=function(t,e){for(var n=-1,r=null==t?0:t.length,o=Array(r);++n=0){Mo=1;break}var Fo=Po&&function(t){return No.some(function(e){return(t||"").toString().indexOf(e)>-1})}(window.MutationObserver)?function(t){var e=!1,n=0,r=document.createElement("span");return new MutationObserver(function(){t(),e=!1}).observe(r,{attributes:!0}),function(){e||(e=!0,r.setAttribute("x-index",n),n+=1)}}:function(t){var e=!1;return function(){e||(e=!0,setTimeout(function(){e=!1,t()},Mo))}},Ho=void 0,Do=function(){return void 0===Ho&&(Ho=-1!==navigator.appVersion.indexOf("MSIE 10")),Ho},Wo=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},Io=function(){function t(t,e){for(var n=0;nr[t]&&!e.escapeWithReference&&(o=Math.min(i[n],r[t]-("right"===t?i.width:i.height))),Ro({},n,o)}};return o.forEach(function(t){var e=-1!==["left","top"].indexOf(t)?"primary":"secondary";i=Uo({},i,s[e](t))}),t.offsets.popper=i,t},priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:function(t){var e=t.offsets,n=e.popper,r=e.reference,o=t.placement.split("-")[0],i=Math.floor,s=-1!==["top","bottom"].indexOf(o),a=s?"right":"bottom",c=s?"left":"top",u=s?"width":"height";return n[a]i(r[a])&&(t.offsets.popper[c]=i(r[a])),t}},arrow:{order:500,enabled:!0,fn:function(t,e){if(!ee(t.instance.modifiers,"arrow","keepTogether"))return t;var n=e.element;if("string"==typeof n){if(!(n=t.instance.popper.querySelector(n)))return t}else if(!t.instance.popper.contains(n))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),t;var r=t.placement.split("-")[0],o=t.offsets,i=o.popper,s=o.reference,a=-1!==["left","right"].indexOf(r),c=a?"height":"width",u=a?"top":"left",l=a?"left":"top",f=a?"bottom":"right",p=zt(n)[c];s[f]-pi[f]&&(t.offsets.popper[u]+=s[u]+p-i[f]);var d=s[u]+s[c]/2-p/2-At(t.offsets.popper)[u];return d=Math.max(Math.min(i[c]-p,d),0),t.arrowElement=n,t.offsets.arrow={},t.offsets.arrow[u]=Math.round(d),t.offsets.arrow[l]="",t},element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:function(t,e){if(Ut(t.instance.modifiers,"inner"))return t;if(t.flipped&&t.placement===t.originalPlacement)return t;var n=Nt(t.instance.popper,t.instance.reference,e.padding,e.boundariesElement),r=t.placement.split("-")[0],o=Ft(r),i=t.placement.split("-")[1]||"",s=[];switch(e.behavior){case Vo.FLIP:s=[r,o];break;case Vo.CLOCKWISE:s=re(r);break;case Vo.COUNTERCLOCKWISE:s=re(r,!0);break;default:s=e.behavior}return s.forEach(function(a,c){if(r!==a||s.length===c+1)return t;r=t.placement.split("-")[0],o=Ft(r);var u=t.offsets.popper,l=t.offsets.reference,f=Math.floor,p="left"===r&&f(u.right)>f(l.left)||"right"===r&&f(u.left)f(l.top)||"bottom"===r&&f(u.top)f(n.right),v=f(u.top)f(n.bottom),b="left"===r&&d||"right"===r&&h||"top"===r&&v||"bottom"===r&&m,g=-1!==["top","bottom"].indexOf(r),y=!!e.flipVariations&&(g&&"start"===i&&d||g&&"end"===i&&h||!g&&"start"===i&&v||!g&&"end"===i&&m);(p||b||y)&&(t.flipped=!0,(p||b)&&(r=s[c+1]),y&&(i=ne(i)),t.placement=r+(i?"-"+i:""),t.offsets.popper=Uo({},t.offsets.popper,Ht(t.instance.popper,t.offsets.reference,t.placement)),t=It(t.instance.modifiers,t,"flip"))}),t},behavior:"flip",padding:5,boundariesElement:"viewport"},inner:{order:700,enabled:!1,fn:function(t){var e=t.placement,n=e.split("-")[0],r=t.offsets,o=r.popper,i=r.reference,s=-1!==["left","right"].indexOf(n),a=-1===["top","left"].indexOf(n);return o[s?"left":"top"]=i[e]-(a?o[s?"width":"height"]:0),t.placement=Ft(e),t.offsets.popper=At(o),t}},hide:{order:800,enabled:!0,fn:function(t){if(!ee(t.instance.modifiers,"hide","preventOverflow"))return t;var e=t.offsets.reference,n=Dt(t.instance.modifiers,function(t){return"preventOverflow"===t.name}).boundaries;if(e.bottomn.right||e.top>n.bottom||e.right2&&void 0!==arguments[2]?arguments[2]:{};Wo(this,t),this.scheduleUpdate=function(){return requestAnimationFrame(r.update)},this.update=Fo(this.update.bind(this)),this.options=Uo({},t.Defaults,o),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=e.jquery?e[0]:e,this.popper=n.jquery?n[0]:n,this.options.modifiers={},Object.keys(Uo({},t.Defaults.modifiers,o.modifiers)).forEach(function(e){r.options.modifiers[e]=Uo({},t.Defaults.modifiers[e]||{},o.modifiers?o.modifiers[e]:{})}),this.modifiers=Object.keys(this.options.modifiers).map(function(t){return Uo({name:t},r.options.modifiers[t])}).sort(function(t,e){return t.order-e.order}),this.modifiers.forEach(function(t){t.enabled&&vt(t.onLoad)&&t.onLoad(r.reference,r.popper,r.options,t,r.state)}),this.update();var i=this.options.eventsEnabled;i&&this.enableEventListeners(),this.state.eventsEnabled=i}return Io(t,[{key:"update",value:function(){return Rt.call(this)}},{key:"destroy",value:function(){return qt.call(this)}},{key:"enableEventListeners",value:function(){return Kt.call(this)}},{key:"disableEventListeners",value:function(){return Qt.call(this)}}]),t}();Ko.Utils=("undefined"!=typeof window?window:global).PopperUtils,Ko.placements=Yo,Ko.Defaults=Go;var Jo={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.$builder.isEditing?n("div",{ref:"styler",staticClass:"styler"},[n("ul",{staticClass:"styler-list"},["button"===t.type||"section"===t.type?n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("colorer")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-palettes"}})])])]):t._e(),"button"===t.type?n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("link")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-link"}})])])]):t._e(),"header"===t.type||"section"===t.type?n("li",[n("button",{staticClass:"styler-button",on:{click:t.removeSection}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-trash"}})])])]):t._e(),"text"===t.type?[n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("textColor")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-palettes"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("align")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-align"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.updateOption("textStyle")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-textStyle"}})])])])]:t._e()],2),n("ul",{staticClass:"styler-list"},["colorer"===t.currentOption?n("li",[n("ul",{staticClass:"colorer"},t._l(t.colors,function(e){return n("li",[n("input",{directives:[{name:"model",rawName:"v-model",value:t.colorerColor,expression:"colorerColor"}],attrs:{type:"radio",id:"color"+(e.charAt(0).toUpperCase()+e.slice(1)),name:"colorer"},domProps:{value:e,checked:t._q(t.colorerColor,e)},on:{__c:function(n){t.colorerColor=e}}})])}))]):t._e(),"textColor"===t.currentOption?n("li",[n("ul",{staticClass:"colorer"},t._l(t.colors,function(e,r){return n("li",[n("input",{directives:[{name:"model",rawName:"v-model",value:t.textColor,expression:"textColor"}],attrs:{type:"radio",id:"color"+(e.charAt(0).toUpperCase()+e.slice(1)),name:"colorer"},domProps:{value:t.textColors[r],checked:t._q(t.textColor,t.textColors[r])},on:{click:function(e){t.execute("forecolor",t.textColor)},__c:function(e){t.textColor=t.textColors[r]}}})])}))]):t._e(),"link"===t.currentOption?n("li",[n("div",{staticClass:"input is-rounded is-button"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.url,expression:"url"}],attrs:{type:"text",placeholder:"type your link"},domProps:{value:t.url},on:{input:function(e){e.target.composing||(t.url=e.target.value)}}}),n("button",{staticClass:"button is-green",on:{click:t.addLink}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-link"}})])])])]):t._e(),"align"===t.currentOption?n("li",[n("ul",{staticClass:"align"},[n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("justifyleft")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-left"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("justifycenter")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-center"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("justifyright")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-right"}})])])])])]):t._e(),"textStyle"===t.currentOption?n("li",[n("ul",{staticClass:"align"},[n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("bold")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-bold"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("italic")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-italic"}})])])]),n("li",[n("button",{staticClass:"styler-button",on:{click:function(e){t.execute("underline")}}},[n("svg",{staticClass:"icon is-large",attrs:{viewBox:"0 0 24 24"}},[n("use",{attrs:{"xlink:href":"dist/img/icons.svg#icon-underline"}})])])])])]):t._e()])]):t._e()},staticRenderFns:[],name:"styler",props:["el","type","name","section"],data:function(){return{colors:["blue","green","red","black","white"],textColors:["#4da1ff","#38E4B7","#EA4F52","#000000","#FFFFFF"],textColor:"",oldColorerColor:"",colorerColor:"",mouseTarget:"",currentOption:"",url:""}},watch:{colorerColor:function(){this.changeColor()}},methods:{updateOption:function(t){this.currentOption=t,this.popper.update()},addLink:function(){this.section.set(this.name+".href",this.url)},changeColor:function(){this.removeClass("is-"+this.oldColorerColor),this.oldColorerColor=this.colorerColor,this.addClass("is-"+this.colorerColor)},addClass:function(t){this.section.set(this.name,function(e){e&&e.classes&&Array.isArray(e.classes)&&(e=e.classes),e.push(t)})},removeClass:function(t){var e=this;if(Array.isArray(t))return t.forEach(function(t){e.removeClass(t)});this.section.set(this.name,function(e){e&&e.classes&&Array.isArray(e.classes)&&(e=e.classes);var n=e.indexOf(t);e.splice(n,1)})},removeSection:function(){document.removeEventListener("click",this.hideStyler),this.popper.destroy(),this.styler.remove(),this.$builder.remove(this.id)},execute:function(t,e){void 0===e&&(e=null),document.execCommand(t,!1,e)},showStyler:function(){this.styler.classList.add("is-visible"),this.currentOption="",this.popper.update()},hideStyler:function(t){var e=t.target;if(!pt(e,this.styler)&&!pt(e,this.el)){if(this.styler.classList.remove("is-visible"),document.removeEventListener("click",this.hideStyler),"section"===this.type)return;if("button"===this.type)return void this.section.set(this.name+".text",this.el.innerHTML);this.section.set(this.name,this.el.innerHTML)}}},created:function(){"button"===this.type&&(this.url=this.section.get(this.name+".href"))},mounted:function(){var t=this;if(this.$builder.isEditing){this.styler=this.$refs.styler,this.id=Number(this.section.id);var e="section"===this.$props.type?"left-start":"top";this.popper=new Ko(this.el,this.styler,{placement:e}),this.el.addEventListener("click",function(){t.showStyler(),document.addEventListener("click",t.hideStyler,!1)},!1)}}},Qo=[],Xo={},Zo={title:"",intro:!0,sections:[],plugins:[]},ti=null,ei=function(t){this.title=t.title,this.isEditing=!0,this.intro=t.intro,this.sections=t.sections,this.components={},this.installPlugins()};return ei.prototype.create=function(t){this.sections.push(new So(t))},ei.prototype.outputFragment=function(){var t=document.createDocumentFragment();return t.appendChild(document.head.cloneNode(!0)),t.appendChild(this.rootEl.cloneNode(!0)),t},ei.prototype.find=function(t){return this.sections.find(function(e){return e.id===t})},ei.prototype.remove=function(t){var e=this.sections.findIndex(function(e){return e.id===t});this.sections.splice(e,1)},ei.component=function(t,e){ei.use(function(n){n.builder.component(t,e)})},ei.mix=function(t){Xo=Nn(Xo,t)},ei.prototype.component=function(t,e){"object"==typeof t&&(t=(e=t).name),e.extend||(e=ti.extend(e)),this.components[t]=e.extend({directives:{styler:this.styler},mixins:[this.mixin],components:Xo.components})},ei.prototype.installPlugins=function(){var t=this;Qo.forEach(function(e){e.plugin({builder:t,Vue:ti},e.options)}),Qo=[]},ei.install=function(t,e){if(void 0===e&&(e={}),!ti){ti=t;var n=new ei(Object.assign({},Zo,e));t.util.defineReactive(n,"sections",n.sections),t.util.defineReactive(n,"isEditing",n.isEditing);var r={components:n.components,beforeCreate:function(){this.$builder=n}};t.component("b-builder",t.extend(Lo).extend(r)),t.component("b-renderer",t.extend(To).extend(r))}},ei.use=function(t,e){if(void 0===e&&(e={}),"function"!=typeof t)return console.warn("Plugins must be a function");Qo.push({plugin:t,options:e})},ei.prototype.set=function(t){var e=this;this.title=void 0!==t.title?t.title:this.title,t.sections&&Array.isArray(t.sections)&&t.sections.forEach(function(t){t.schema||(t.schema=e.components[t.name].options.$schema),e.create(t)})},ei.prototype.toJSON=function(){return{title:this.title,sections:this.sections.map(function(t){return{name:t.name,data:t.data}})}},ei.prototype.preview=function(){var t=window.open("about:blank","print_preview").document;t.open(),t.write("\n \n "+document.documentElement.innerHTML+"\n ")},ei.prototype.export=function(t){return void 0===t&&(t="json"),"zip"===t?"function"==typeof this.download?this.download():console.warn("You do not have the zip plugin installed."):"preview"===t?this.preview():this.toJSON()},ei.use(function(t){var e=t.builder,n=t.Vue.extend(Jo).extend({beforeCreate:function(){this.$builder=e}});e.styler={inserted:function(t,e,r){var o=document.createElement("div");o.id="newNode",t.parentNode.appendChild(o),new n({propsData:{el:t,section:r.context.$section,type:e.arg||dt(e.expression,r.context.$section.schema)||ht(t.tagName),name:e.expression,editable:t.classList.contains("is-editable")}}).$mount("#newNode")}}}),ei.use(function(t){var e=t.builder;e.mixin={provide:function(){var t={};return this.$builder&&(t.$builder=this.$builder),this.$section&&(t.$section=this.$section),t},beforeCreate:function(){this.$builder=e,this.$options.propsData&&void 0!==this.$options.propsData.id&&(this.$section=this.$builder.find(this.$options.propsData.id),this.$options.computed||(this.$options.computed={}),this.$options.computed.$sectionData=function(){return this.$section.data})},mounted:function(){Array.from(this.$el.querySelectorAll(".is-editable")).forEach(function(t){t.contentEditable="true"})}}}),"undefined"!=typeof Vue&&Vue.use(ei),ei.version="0.0.6",ei.types=nr,ei}); \ No newline at end of file diff --git a/docs/dist/js/app.js b/docs/dist/js/app.js index 39543d0..4f2b0de 100644 --- a/docs/dist/js/app.js +++ b/docs/dist/js/app.js @@ -1,14 +1,14 @@ -webpackJsonp([0],[function(t,e,n){"use strict";function r(t){var e=null;return e=c.uint8array?new Uint8Array(t.length):new Array(t.length),o(t,e)}function i(t){return t}function o(t,e){for(var n=0;n1;)try{return h.stringifyByChunk(t,r,n)}catch(t){n=Math.floor(n/2)}return h.stringifyByChar(t)}function a(t,e){for(var n=0;n "+t:t}},t.exports=r},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e){t.exports=function(t,e,n,r,i){var o,s=t=t||{},a=typeof t.default;"object"!==a&&"function"!==a||(o=t,s=t.default);var c="function"==typeof s?s.options:s;e&&(c.render=e.render,c.staticRenderFns=e.staticRenderFns),r&&(c._scopeId=r);var l;if(i?(l=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),n&&n.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(i)},c._ssrRegister=l):n&&(l=n),l){var u=c.functional,f=u?c.render:c.beforeCreate;u?c.render=function(t,e){return l.call(e),f(t,e)}:c.beforeCreate=f?[].concat(f,l):[l]}return{esModule:o,exports:s,options:c}}},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});e.Avatar=function t(){r(this,t)},e.Title=function t(){r(this,t)},e.Text=function t(){r(this,t)},e.Logo=function t(){r(this,t)},e.Image=function t(){r(this,t)},e.Quote=function t(){r(this,t)},e.Link=function t(){r(this,t)},e.ClassList=function t(){r(this,t)},e.Button=function t(){r(this,t)}},function(t,e,n){"use strict";(function(t){if(e.base64=!0,e.array=!0,e.string=!0,e.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,e.nodebuffer=void 0!==t,e.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)e.blob=!1;else{var r=new ArrayBuffer(0);try{e.blob=0===new Blob([r],{type:"application/zip"}).size}catch(t){try{var i=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder,o=new i;o.append(r),e.blob=0===o.getBlob("application/zip").size}catch(t){e.blob=!1}}}try{e.nodestream=!!n(76).Readable}catch(t){e.nodestream=!1}}).call(e,n(13).Buffer)},function(t,e,n){"use strict";var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;e.assign=function(t){for(var e=Array.prototype.slice.call(arguments,1);e.length;){var n=e.shift();if(n){if("object"!=typeof n)throw new TypeError(n+"must be non-object");for(var r in n)n.hasOwnProperty(r)&&(t[r]=n[r])}}return t},e.shrinkBuf=function(t,e){return t.length===e?t:t.subarray?t.subarray(0,e):(t.length=e,t)};var i={arraySet:function(t,e,n,r,i){if(e.subarray&&t.subarray)return void t.set(e.subarray(n,n+r),i);for(var o=0;o=252?6:u>=248?5:u>=240?4:u>=224?3:u>=192?2:1;l[254]=l[254]=1;var f=function(t){var e,n,r,i,o,a=t.length,c=0;for(i=0;i>>6,e[o++]=128|63&n):n<65536?(e[o++]=224|n>>>12,e[o++]=128|n>>>6&63,e[o++]=128|63&n):(e[o++]=240|n>>>18,e[o++]=128|n>>>12&63,e[o++]=128|n>>>6&63,e[o++]=128|63&n);return e},d=function(t,e){var n;for(e=e||t.length,e>t.length&&(e=t.length),n=e-1;n>=0&&128==(192&t[n]);)n--;return n<0?e:0===n?e:n+l[t[n]]>e?n:e},h=function(t){var e,n,r,i,s=t.length,a=new Array(2*s);for(n=0,e=0;e4)a[n++]=65533,e+=i-1;else{for(r&=2===i?31:3===i?15:7;i>1&&e1?a[n++]=65533:r<65536?a[n++]=r:(r-=65536,a[n++]=55296|r>>10&1023,a[n++]=56320|1023&r)}return a.length!==n&&(a.subarray?a=a.subarray(0,n):a.length=n),o.applyFromCharCode(a)};e.utf8encode=function(t){return s.nodebuffer?a.newBuffer(t,"utf-8"):f(t)},e.utf8decode=function(t){return s.nodebuffer?o.transformTo("nodebuffer",t).toString("utf-8"):(t=o.transformTo(s.uint8array?"uint8array":"array",t),h(t))},o.inherits(r,c),r.prototype.processChunk=function(t){var n=o.transformTo(s.uint8array?"uint8array":"array",t.data);if(this.leftOver&&this.leftOver.length){if(s.uint8array){var r=n;n=new Uint8Array(r.length+this.leftOver.length),n.set(this.leftOver,0),n.set(r,this.leftOver.length)}else n=this.leftOver.concat(n);this.leftOver=null}var i=d(n),a=n;i!==n.length&&(s.uint8array?(a=n.subarray(0,i),this.leftOver=n.subarray(i,n.length)):(a=n.slice(0,i),this.leftOver=n.slice(i,n.length))),this.push({data:e.utf8decode(a),meta:t.meta})},r.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:e.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},e.Utf8DecodeWorker=r,o.inherits(i,c),i.prototype.processChunk=function(t){this.push({data:e.utf8encode(t.data),meta:t.meta})},e.Utf8EncodeWorker=i},function(t,e,n){"use strict";(function(t){function r(){return o.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function i(t,e){if(r()=r())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+r().toString(16)+" bytes");return 0|t}function m(t){return+t!=t&&(t=0),o.alloc(+t)}function v(t,e){if(o.isBuffer(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var n=t.length;if(0===n)return 0;for(var r=!1;;)switch(e){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return W(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return q(t).length;default:if(r)return W(t).length;e=(""+e).toLowerCase(),r=!0}}function b(t,e,n){var r=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if(n>>>=0,e>>>=0,n<=e)return"";for(t||(t="utf8");;)switch(t){case"hex":return R(this,e,n);case"utf8":case"utf-8":return A(this,e,n);case"ascii":return T(this,e,n);case"latin1":case"binary":return $(this,e,n);case"base64":return S(this,e,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return D(this,e,n);default:if(r)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),r=!0}}function g(t,e,n){var r=t[e];t[e]=t[n],t[n]=r}function y(t,e,n,r,i){if(0===t.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=i?0:t.length-1),n<0&&(n=t.length+n),n>=t.length){if(i)return-1;n=t.length-1}else if(n<0){if(!i)return-1;n=0}if("string"==typeof e&&(e=o.from(e,r)),o.isBuffer(e))return 0===e.length?-1:w(t,e,n,r,i);if("number"==typeof e)return e&=255,o.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(t,e,n):Uint8Array.prototype.lastIndexOf.call(t,e,n):w(t,[e],n,r,i);throw new TypeError("val must be string, number or Buffer")}function w(t,e,n,r,i){function o(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}var s=1,a=t.length,c=e.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(t.length<2||e.length<2)return-1;s=2,a/=2,c/=2,n/=2}var l;if(i){var u=-1;for(l=n;la&&(n=a-c),l=n;l>=0;l--){for(var f=!0,d=0;di&&(r=i):r=i;var o=e.length;if(o%2!=0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var s=0;s239?4:o>223?3:o>191?2:1;if(i+a<=n){var c,l,u,f;switch(a){case 1:o<128&&(s=o);break;case 2:c=t[i+1],128==(192&c)&&(f=(31&o)<<6|63&c)>127&&(s=f);break;case 3:c=t[i+1],l=t[i+2],128==(192&c)&&128==(192&l)&&(f=(15&o)<<12|(63&c)<<6|63&l)>2047&&(f<55296||f>57343)&&(s=f);break;case 4:c=t[i+1],l=t[i+2],u=t[i+3],128==(192&c)&&128==(192&l)&&128==(192&u)&&(f=(15&o)<<18|(63&c)<<12|(63&l)<<6|63&u)>65535&&f<1114112&&(s=f)}}null===s?(s=65533,a=1):s>65535&&(s-=65536,r.push(s>>>10&1023|55296),s=56320|1023&s),r.push(s),i+=a}return j(r)}function j(t){var e=t.length;if(e<=Q)return String.fromCharCode.apply(String,t);for(var n="",r=0;rr)&&(n=r);for(var i="",o=e;on)throw new RangeError("Trying to access beyond buffer length")}function P(t,e,n,r,i,s){if(!o.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>i||et.length)throw new RangeError("Index out of range")}function I(t,e,n,r){e<0&&(e=65535+e+1);for(var i=0,o=Math.min(t.length-n,2);i>>8*(r?i:1-i)}function z(t,e,n,r){e<0&&(e=4294967295+e+1);for(var i=0,o=Math.min(t.length-n,4);i>>8*(r?i:3-i)&255}function B(t,e,n,r,i,o){if(n+r>t.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function M(t,e,n,r,i){return i||B(t,e,n,4,3.4028234663852886e38,-3.4028234663852886e38),G.write(t,e,n,r,23,4),n+4}function N(t,e,n,r,i){return i||B(t,e,n,8,1.7976931348623157e308,-1.7976931348623157e308),G.write(t,e,n,r,52,8),n+8}function U(t){if(t=F(t).replace(tt,""),t.length<2)return"";for(;t.length%4!=0;)t+="=";return t}function F(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function H(t){return t<16?"0"+t.toString(16):t.toString(16)}function W(t,e){e=e||1/0;for(var n,r=t.length,i=null,o=[],s=0;s55295&&n<57344){if(!i){if(n>56319){(e-=3)>-1&&o.push(239,191,189);continue}if(s+1===r){(e-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(e-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(e-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((e-=1)<0)break;o.push(n)}else if(n<2048){if((e-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((e-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function Z(t){for(var e=[],n=0;n>8,i=n%256,o.push(i),o.push(r);return o}function q(t){return J.toByteArray(U(t))}function V(t,e,n,r){for(var i=0;i=e.length||i>=t.length);++i)e[i+n]=t[i];return i}function K(t){return t!==t}/*! +webpackJsonp([0],[function(t,e,n){"use strict";function r(t){var e=null;return e=c.uint8array?new Uint8Array(t.length):new Array(t.length),o(t,e)}function i(t){return t}function o(t,e){for(var n=0;n1;)try{return h.stringifyByChunk(t,r,n)}catch(t){n=Math.floor(n/2)}return h.stringifyByChar(t)}function a(t,e){for(var n=0;n "+t:t}},t.exports=r},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});e.Avatar=function t(){r(this,t)},e.Title=function t(){r(this,t)},e.Text=function t(){r(this,t)},e.Logo=function t(){r(this,t)},e.Image=function t(){r(this,t)},e.Quote=function t(){r(this,t)},e.Link=function t(){r(this,t)},e.ClassList=function t(){r(this,t)},e.Button=function t(){r(this,t)}},function(t,e,n){"use strict";(function(t){if(e.base64=!0,e.array=!0,e.string=!0,e.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,e.nodebuffer=void 0!==t,e.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)e.blob=!1;else{var r=new ArrayBuffer(0);try{e.blob=0===new Blob([r],{type:"application/zip"}).size}catch(t){try{var i=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder,o=new i;o.append(r),e.blob=0===o.getBlob("application/zip").size}catch(t){e.blob=!1}}}try{e.nodestream=!!n(76).Readable}catch(t){e.nodestream=!1}}).call(e,n(13).Buffer)},function(t,e,n){"use strict";var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;e.assign=function(t){for(var e=Array.prototype.slice.call(arguments,1);e.length;){var n=e.shift();if(n){if("object"!=typeof n)throw new TypeError(n+"must be non-object");for(var r in n)n.hasOwnProperty(r)&&(t[r]=n[r])}}return t},e.shrinkBuf=function(t,e){return t.length===e?t:t.subarray?t.subarray(0,e):(t.length=e,t)};var i={arraySet:function(t,e,n,r,i){if(e.subarray&&t.subarray)return void t.set(e.subarray(n,n+r),i);for(var o=0;o=252?6:u>=248?5:u>=240?4:u>=224?3:u>=192?2:1;l[254]=l[254]=1;var f=function(t){var e,n,r,i,o,a=t.length,c=0;for(i=0;i>>6,e[o++]=128|63&n):n<65536?(e[o++]=224|n>>>12,e[o++]=128|n>>>6&63,e[o++]=128|63&n):(e[o++]=240|n>>>18,e[o++]=128|n>>>12&63,e[o++]=128|n>>>6&63,e[o++]=128|63&n);return e},d=function(t,e){var n;for(e=e||t.length,e>t.length&&(e=t.length),n=e-1;n>=0&&128==(192&t[n]);)n--;return n<0?e:0===n?e:n+l[t[n]]>e?n:e},h=function(t){var e,n,r,i,s=t.length,a=new Array(2*s);for(n=0,e=0;e4)a[n++]=65533,e+=i-1;else{for(r&=2===i?31:3===i?15:7;i>1&&e1?a[n++]=65533:r<65536?a[n++]=r:(r-=65536,a[n++]=55296|r>>10&1023,a[n++]=56320|1023&r)}return a.length!==n&&(a.subarray?a=a.subarray(0,n):a.length=n),o.applyFromCharCode(a)};e.utf8encode=function(t){return s.nodebuffer?a.newBuffer(t,"utf-8"):f(t)},e.utf8decode=function(t){return s.nodebuffer?o.transformTo("nodebuffer",t).toString("utf-8"):(t=o.transformTo(s.uint8array?"uint8array":"array",t),h(t))},o.inherits(r,c),r.prototype.processChunk=function(t){var n=o.transformTo(s.uint8array?"uint8array":"array",t.data);if(this.leftOver&&this.leftOver.length){if(s.uint8array){var r=n;n=new Uint8Array(r.length+this.leftOver.length),n.set(this.leftOver,0),n.set(r,this.leftOver.length)}else n=this.leftOver.concat(n);this.leftOver=null}var i=d(n),a=n;i!==n.length&&(s.uint8array?(a=n.subarray(0,i),this.leftOver=n.subarray(i,n.length)):(a=n.slice(0,i),this.leftOver=n.slice(i,n.length))),this.push({data:e.utf8decode(a),meta:t.meta})},r.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:e.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},e.Utf8DecodeWorker=r,o.inherits(i,c),i.prototype.processChunk=function(t){this.push({data:e.utf8encode(t.data),meta:t.meta})},e.Utf8EncodeWorker=i},function(t,e,n){"use strict";(function(t){function r(){return o.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function i(t,e){if(r()=r())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+r().toString(16)+" bytes");return 0|t}function m(t){return+t!=t&&(t=0),o.alloc(+t)}function v(t,e){if(o.isBuffer(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var n=t.length;if(0===n)return 0;for(var r=!1;;)switch(e){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return W(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return q(t).length;default:if(r)return W(t).length;e=(""+e).toLowerCase(),r=!0}}function b(t,e,n){var r=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if(n>>>=0,e>>>=0,n<=e)return"";for(t||(t="utf8");;)switch(t){case"hex":return R(this,e,n);case"utf8":case"utf-8":return A(this,e,n);case"ascii":return T(this,e,n);case"latin1":case"binary":return $(this,e,n);case"base64":return S(this,e,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return D(this,e,n);default:if(r)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),r=!0}}function g(t,e,n){var r=t[e];t[e]=t[n],t[n]=r}function y(t,e,n,r,i){if(0===t.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=i?0:t.length-1),n<0&&(n=t.length+n),n>=t.length){if(i)return-1;n=t.length-1}else if(n<0){if(!i)return-1;n=0}if("string"==typeof e&&(e=o.from(e,r)),o.isBuffer(e))return 0===e.length?-1:w(t,e,n,r,i);if("number"==typeof e)return e&=255,o.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(t,e,n):Uint8Array.prototype.lastIndexOf.call(t,e,n):w(t,[e],n,r,i);throw new TypeError("val must be string, number or Buffer")}function w(t,e,n,r,i){function o(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}var s=1,a=t.length,c=e.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(t.length<2||e.length<2)return-1;s=2,a/=2,c/=2,n/=2}var l;if(i){var u=-1;for(l=n;la&&(n=a-c),l=n;l>=0;l--){for(var f=!0,d=0;di&&(r=i):r=i;var o=e.length;if(o%2!=0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var s=0;s239?4:o>223?3:o>191?2:1;if(i+a<=n){var c,l,u,f;switch(a){case 1:o<128&&(s=o);break;case 2:c=t[i+1],128==(192&c)&&(f=(31&o)<<6|63&c)>127&&(s=f);break;case 3:c=t[i+1],l=t[i+2],128==(192&c)&&128==(192&l)&&(f=(15&o)<<12|(63&c)<<6|63&l)>2047&&(f<55296||f>57343)&&(s=f);break;case 4:c=t[i+1],l=t[i+2],u=t[i+3],128==(192&c)&&128==(192&l)&&128==(192&u)&&(f=(15&o)<<18|(63&c)<<12|(63&l)<<6|63&u)>65535&&f<1114112&&(s=f)}}null===s?(s=65533,a=1):s>65535&&(s-=65536,r.push(s>>>10&1023|55296),s=56320|1023&s),r.push(s),i+=a}return j(r)}function j(t){var e=t.length;if(e<=Q)return String.fromCharCode.apply(String,t);for(var n="",r=0;rr)&&(n=r);for(var i="",o=e;on)throw new RangeError("Trying to access beyond buffer length")}function P(t,e,n,r,i,s){if(!o.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>i||et.length)throw new RangeError("Index out of range")}function I(t,e,n,r){e<0&&(e=65535+e+1);for(var i=0,o=Math.min(t.length-n,2);i>>8*(r?i:1-i)}function z(t,e,n,r){e<0&&(e=4294967295+e+1);for(var i=0,o=Math.min(t.length-n,4);i>>8*(r?i:3-i)&255}function M(t,e,n,r,i,o){if(n+r>t.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function B(t,e,n,r,i){return i||M(t,e,n,4,3.4028234663852886e38,-3.4028234663852886e38),G.write(t,e,n,r,23,4),n+4}function N(t,e,n,r,i){return i||M(t,e,n,8,1.7976931348623157e308,-1.7976931348623157e308),G.write(t,e,n,r,52,8),n+8}function U(t){if(t=F(t).replace(tt,""),t.length<2)return"";for(;t.length%4!=0;)t+="=";return t}function F(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function H(t){return t<16?"0"+t.toString(16):t.toString(16)}function W(t,e){e=e||1/0;for(var n,r=t.length,i=null,o=[],s=0;s55295&&n<57344){if(!i){if(n>56319){(e-=3)>-1&&o.push(239,191,189);continue}if(s+1===r){(e-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(e-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(e-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((e-=1)<0)break;o.push(n)}else if(n<2048){if((e-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((e-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function Z(t){for(var e=[],n=0;n>8,i=n%256,o.push(i),o.push(r);return o}function q(t){return J.toByteArray(U(t))}function V(t,e,n,r){for(var i=0;i=e.length||i>=t.length);++i)e[i+n]=t[i];return i}function K(t){return t!==t}/*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT */ -var J=n(278),G=n(279),X=n(75);e.Buffer=o,e.SlowBuffer=m,e.INSPECT_MAX_BYTES=50,o.TYPED_ARRAY_SUPPORT=void 0!==t.TYPED_ARRAY_SUPPORT?t.TYPED_ARRAY_SUPPORT:function(){try{var t=new Uint8Array(1);return t.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===t.foo()&&"function"==typeof t.subarray&&0===t.subarray(1,1).byteLength}catch(t){return!1}}(),e.kMaxLength=r(),o.poolSize=8192,o._augment=function(t){return t.__proto__=o.prototype,t},o.from=function(t,e,n){return s(null,t,e,n)},o.TYPED_ARRAY_SUPPORT&&(o.prototype.__proto__=Uint8Array.prototype,o.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&o[Symbol.species]===o&&Object.defineProperty(o,Symbol.species,{value:null,configurable:!0})),o.alloc=function(t,e,n){return c(null,t,e,n)},o.allocUnsafe=function(t){return l(null,t)},o.allocUnsafeSlow=function(t){return l(null,t)},o.isBuffer=function(t){return!(null==t||!t._isBuffer)},o.compare=function(t,e){if(!o.isBuffer(t)||!o.isBuffer(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var n=t.length,r=e.length,i=0,s=Math.min(n,r);i0&&(t=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(t+=" ... ")),""},o.prototype.compare=function(t,e,n,r,i){if(!o.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===e&&(e=0),void 0===n&&(n=t?t.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),e<0||n>t.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&e>=n)return 0;if(r>=i)return-1;if(e>=n)return 1;if(e>>>=0,n>>>=0,r>>>=0,i>>>=0,this===t)return 0;for(var s=i-r,a=n-e,c=Math.min(s,a),l=this.slice(r,i),u=t.slice(e,n),f=0;fi)&&(n=i),t.length>0&&(n<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return _(this,t,e,n);case"utf8":case"utf-8":return x(this,t,e,n);case"ascii":return k(this,t,e,n);case"latin1":case"binary":return C(this,t,e,n);case"base64":return O(this,t,e,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,t,e,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var Q=4096;o.prototype.slice=function(t,e){var n=this.length;t=~~t,e=void 0===e?n:~~e,t<0?(t+=n)<0&&(t=0):t>n&&(t=n),e<0?(e+=n)<0&&(e=0):e>n&&(e=n),e0&&(i*=256);)r+=this[t+--e]*i;return r},o.prototype.readUInt8=function(t,e){return e||L(t,1,this.length),this[t]},o.prototype.readUInt16LE=function(t,e){return e||L(t,2,this.length),this[t]|this[t+1]<<8},o.prototype.readUInt16BE=function(t,e){return e||L(t,2,this.length),this[t]<<8|this[t+1]},o.prototype.readUInt32LE=function(t,e){return e||L(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},o.prototype.readUInt32BE=function(t,e){return e||L(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},o.prototype.readIntLE=function(t,e,n){t|=0,e|=0,n||L(t,e,this.length);for(var r=this[t],i=1,o=0;++o=i&&(r-=Math.pow(2,8*e)),r},o.prototype.readIntBE=function(t,e,n){t|=0,e|=0,n||L(t,e,this.length);for(var r=e,i=1,o=this[t+--r];r>0&&(i*=256);)o+=this[t+--r]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*e)),o},o.prototype.readInt8=function(t,e){return e||L(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},o.prototype.readInt16LE=function(t,e){e||L(t,2,this.length);var n=this[t]|this[t+1]<<8;return 32768&n?4294901760|n:n},o.prototype.readInt16BE=function(t,e){e||L(t,2,this.length);var n=this[t+1]|this[t]<<8;return 32768&n?4294901760|n:n},o.prototype.readInt32LE=function(t,e){return e||L(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},o.prototype.readInt32BE=function(t,e){return e||L(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},o.prototype.readFloatLE=function(t,e){return e||L(t,4,this.length),G.read(this,t,!0,23,4)},o.prototype.readFloatBE=function(t,e){return e||L(t,4,this.length),G.read(this,t,!1,23,4)},o.prototype.readDoubleLE=function(t,e){return e||L(t,8,this.length),G.read(this,t,!0,52,8)},o.prototype.readDoubleBE=function(t,e){return e||L(t,8,this.length),G.read(this,t,!1,52,8)},o.prototype.writeUIntLE=function(t,e,n,r){if(t=+t,e|=0,n|=0,!r){P(this,t,e,n,Math.pow(2,8*n)-1,0)}var i=1,o=0;for(this[e]=255&t;++o=0&&(o*=256);)this[e+i]=t/o&255;return e+n},o.prototype.writeUInt8=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,1,255,0),o.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&t,e+1},o.prototype.writeUInt16LE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,2,65535,0),o.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):I(this,t,e,!0),e+2},o.prototype.writeUInt16BE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,2,65535,0),o.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):I(this,t,e,!1),e+2},o.prototype.writeUInt32LE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,4,4294967295,0),o.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):z(this,t,e,!0),e+4},o.prototype.writeUInt32BE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,4,4294967295,0),o.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):z(this,t,e,!1),e+4},o.prototype.writeIntLE=function(t,e,n,r){if(t=+t,e|=0,!r){var i=Math.pow(2,8*n-1);P(this,t,e,n,i-1,-i)}var o=0,s=1,a=0;for(this[e]=255&t;++o>0)-a&255;return e+n},o.prototype.writeIntBE=function(t,e,n,r){if(t=+t,e|=0,!r){var i=Math.pow(2,8*n-1);P(this,t,e,n,i-1,-i)}var o=n-1,s=1,a=0;for(this[e+o]=255&t;--o>=0&&(s*=256);)t<0&&0===a&&0!==this[e+o+1]&&(a=1),this[e+o]=(t/s>>0)-a&255;return e+n},o.prototype.writeInt8=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,1,127,-128),o.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=255&t,e+1},o.prototype.writeInt16LE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,2,32767,-32768),o.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):I(this,t,e,!0),e+2},o.prototype.writeInt16BE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,2,32767,-32768),o.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):I(this,t,e,!1),e+2},o.prototype.writeInt32LE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,4,2147483647,-2147483648),o.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):z(this,t,e,!0),e+4},o.prototype.writeInt32BE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),o.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):z(this,t,e,!1),e+4},o.prototype.writeFloatLE=function(t,e,n){return M(this,t,e,!0,n)},o.prototype.writeFloatBE=function(t,e,n){return M(this,t,e,!1,n)},o.prototype.writeDoubleLE=function(t,e,n){return N(this,t,e,!0,n)},o.prototype.writeDoubleBE=function(t,e,n){return N(this,t,e,!1,n)},o.prototype.copy=function(t,e,n,r){if(n||(n=0),r||0===r||(r=this.length),e>=t.length&&(e=t.length),e||(e=0),r>0&&r=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),t.length-e=0;--i)t[i+e]=this[i+n];else if(s<1e3||!o.TYPED_ARRAY_SUPPORT)for(i=0;i>>=0,n=void 0===n?this.length:n>>>0,t||(t=0);var s;if("number"==typeof t)for(s=e;s1)for(var n=1;nn.parts.length&&(r.parts.length=n.parts.length)}else{for(var s=[],i=0;i0&&this._events[t].length>i&&(this._events[t].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[t].length),"function"==typeof console.trace&&console.trace()),this},n.prototype.on=n.prototype.addListener,n.prototype.once=function(t,e){function n(){this.removeListener(t,n),i||(i=!0,e.apply(this,arguments))}if(!r(e))throw TypeError("listener must be a function");var i=!1;return n.listener=e,this.on(t,n),this},n.prototype.removeListener=function(t,e){var n,i,s,a;if(!r(e))throw TypeError("listener must be a function");if(!this._events||!this._events[t])return this;if(n=this._events[t],s=n.length,i=-1,n===e||r(n.listener)&&n.listener===e)delete this._events[t],this._events.removeListener&&this.emit("removeListener",t,e);else if(o(n)){for(a=s;a-- >0;)if(n[a]===e||n[a].listener&&n[a].listener===e){i=a;break}if(i<0)return this;1===n.length?(n.length=0,delete this._events[t]):n.splice(i,1),this._events.removeListener&&this.emit("removeListener",t,e)}return this},n.prototype.removeAllListeners=function(t){var e,n;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[t]&&delete this._events[t],this;if(0===arguments.length){for(e in this._events)"removeListener"!==e&&this.removeAllListeners(e);return this.removeAllListeners("removeListener"),this._events={},this}if(n=this._events[t],r(n))this.removeListener(t,n);else if(n)for(;n.length;)this.removeListener(t,n[n.length-1]);return delete this._events[t],this},n.prototype.listeners=function(t){return this._events&&this._events[t]?r(this._events[t])?[this._events[t]]:this._events[t].slice():[]},n.prototype.listenerCount=function(t){if(this._events){var e=this._events[t];if(r(e))return 1;if(e)return e.length}return 0},n.listenerCount=function(t,e){return t.listenerCount(e)}},function(t,e,n){e=t.exports=n(77),e.Stream=e,e.Readable=e,e.Writable=n(47),e.Duplex=n(8),e.Transform=n(81),e.PassThrough=n(286)},function(t,e,n){function r(t,e){for(var n in t)e[n]=t[n]}function i(t,e,n){return s(t,e,n)}var o=n(13),s=o.Buffer;s.from&&s.alloc&&s.allocUnsafe&&s.allocUnsafeSlow?t.exports=o:(r(o,e),e.Buffer=i),r(s,i),i.from=function(t,e,n){if("number"==typeof t)throw new TypeError("Argument must not be a number");return s(t,e,n)},i.alloc=function(t,e,n){if("number"!=typeof t)throw new TypeError("Argument must be a number");var r=s(t);return void 0!==e?"string"==typeof n?r.fill(e,n):r.fill(e):r.fill(0),r},i.allocUnsafe=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return s(t)},i.allocUnsafeSlow=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return o.SlowBuffer(t)}},function(t,e,n){"use strict";(function(e,r,i){function o(t){var e=this;this.next=null,this.entry=null,this.finish=function(){S(e,t)}}function s(t){return L.from(t)}function a(t){return L.isBuffer(t)||t instanceof P}function c(){}function l(t,e){j=j||n(8),t=t||{},this.objectMode=!!t.objectMode,e instanceof j&&(this.objectMode=this.objectMode||!!t.writableObjectMode);var r=t.highWaterMark,i=this.objectMode?16:16384;this.highWaterMark=r||0===r?r:i,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var s=!1===t.decodeStrings;this.decodeStrings=!s,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(t){g(e,t)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function u(t){if(j=j||n(8),!(z.call(u,this)||this instanceof j))return new u(t);this._writableState=new l(t,this),this.writable=!0,t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final)),D.call(this)}function f(t,e){var n=new Error("write after end");t.emit("error",n),A(e,n)}function d(t,e,n,r){var i=!0,o=!1;return null===n?o=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||e.objectMode||(o=new TypeError("Invalid non-string/buffer chunk")),o&&(t.emit("error",o),A(r,o),i=!1),i}function h(t,e,n){return t.objectMode||!1===t.decodeStrings||"string"!=typeof e||(e=L.from(e,n)),e}function p(t,e,n,r,i,o){if(!n){var s=h(e,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=e.objectMode?1:r.length;e.length+=a;var c=e.length-1?r:A;u.WritableState=l;var $=n(17);$.inherits=n(14);var R={deprecate:n(285)},D=n(78),L=n(46).Buffer,P=i.Uint8Array||function(){},I=n(79);$.inherits(u,D),l.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(l.prototype,"buffer",{get:R.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}();var z;"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(z=Function.prototype[Symbol.hasInstance],Object.defineProperty(u,Symbol.hasInstance,{value:function(t){return!!z.call(this,t)||t&&t._writableState instanceof l}})):z=function(t){return t instanceof this},u.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},u.prototype.write=function(t,e,n){var r=this._writableState,i=!1,o=a(t)&&!r.objectMode;return o&&!L.isBuffer(t)&&(t=s(t)),"function"==typeof e&&(n=e,e=null),o?e="buffer":e||(e=r.defaultEncoding),"function"!=typeof n&&(n=c),r.ended?f(this,n):(o||d(this,r,t,n))&&(r.pendingcb++,i=p(this,r,o,t,e,n)),i},u.prototype.cork=function(){this._writableState.corked++},u.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,t.writing||t.corked||t.finished||t.bufferProcessing||!t.bufferedRequest||_(this,t))},u.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},u.prototype._write=function(t,e,n){n(new Error("_write() is not implemented"))},u.prototype._writev=null,u.prototype.end=function(t,e,n){var r=this._writableState;"function"==typeof t?(n=t,t=null,e=null):"function"==typeof e&&(n=e,e=null),null!==t&&void 0!==t&&this.write(t,e),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||E(this,r,n)},Object.defineProperty(u.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),u.prototype.destroy=I.destroy,u.prototype._undestroy=I.undestroy,u.prototype._destroy=function(t,e){this.end(),e(t)}}).call(e,n(16),n(283).setImmediate,n(2))},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e,n){t.exports=!n(85)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(t,e,n){"use strict";function r(t,e,n,r,i){this.compressedSize=t,this.uncompressedSize=e,this.crc32=n,this.compression=r,this.compressedContent=i}var i=n(18),o=n(89),s=n(90),a=n(91),s=n(90);r.prototype={getContentWorker:function(){var t=new o(i.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new s("data_length")),e=this;return t.on("end",function(){if(this.streamInfo.data_length!==e.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),t},getCompressedWorker:function(){return new o(i.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},r.createWorkerFrom=function(t,e,n){return t.pipe(new a).pipe(new s("uncompressedSize")).pipe(e.compressWorker(n)).pipe(new s("compressedSize")).withStreamInfo("compression",e)},t.exports=r},function(t,e,n){"use strict";function r(t,e,n,r){var i=s,o=r+n;t^=-1;for(var a=r;a>>8^i[255&(t^e[a])];return-1^t}function i(t,e,n,r){var i=s,o=r+n;t^=-1;for(var a=r;a>>8^i[255&(t^e.charCodeAt(a))];return-1^t}var o=n(0),s=function(){for(var t,e=[],n=0;n<256;n++){t=n;for(var r=0;r<8;r++)t=1&t?3988292384^t>>>1:t>>>1;e[n]=t}return e}();t.exports=function(t,e){return void 0!==t&&t.length?"string"!==o.getTypeOf(t)?r(0|e,t,t.length,0):i(0|e,t,t.length,0):0}},function(t,e,n){"use strict";t.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},function(t,e,n){"use strict";var r=n(34),i=n(9),o=Object(r.a)(i.a,"Map");e.a=o},function(t,e,n){"use strict";(function(t){var n="object"==typeof t&&t&&t.Object===Object&&t;e.a=n}).call(e,n(2))},function(t,e,n){"use strict";function r(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1&&t%1==0&&t<=i}var i=9007199254740991;e.a=r},function(t,e,n){"use strict";(function(t){var r=n(9),i=n(165),o="object"==typeof exports&&exports&&!exports.nodeType&&exports,s=o&&"object"==typeof t&&t&&!t.nodeType&&t,a=s&&s.exports===o,c=a?r.a.Buffer:void 0,l=c?c.isBuffer:void 0,u=l||i.a;e.a=u}).call(e,n(38)(t))},function(t,e,n){"use strict";var r=n(167),i=n(168),o=n(169),s=o.a&&o.a.isTypedArray,a=s?Object(i.a)(s):r.a;e.a=a},function(t,e,n){"use strict";function r(t){return Object(s.a)(t)?Object(i.a)(t,!0):Object(o.a)(t)}var i=n(173),o=n(175),s=n(39);e.a=r},function(t,e,n){"use strict";function r(t,e){return!!(e=null==e?i:e)&&("number"==typeof t||o.test(t))&&t>-1&&t%1==0&&t0?("string"==typeof e||s.objectMode||Object.getPrototypeOf(e)===z.prototype||(e=i(e)),r?s.endEmitted?t.emit("error",new Error("stream.unshift() after end event")):u(t,s,e,!0):s.ended?t.emit("error",new Error("stream.push() after EOF")):(s.reading=!1,s.decoder&&!n?(e=s.decoder.write(e),s.objectMode||0!==e.length?u(t,s,e,!1):g(t,s)):u(t,s,e,!1))):r||(s.reading=!1)}return d(s)}function u(t,e,n,r){e.flowing&&0===e.length&&!e.sync?(t.emit("data",n),t.read(0)):(e.length+=e.objectMode?1:n.length,r?e.buffer.unshift(n):e.buffer.push(n),e.needReadable&&v(t)),g(t,e)}function f(t,e){var n;return o(e)||"string"==typeof e||void 0===e||t.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function d(t){return!t.ended&&(t.needReadable||t.length=Y?t=Y:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function p(t,e){return t<=0||0===e.length&&e.ended?0:e.objectMode?1:t!==t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=h(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function m(t,e){if(!e.ended){if(e.decoder){var n=e.decoder.end();n&&n.length&&(e.buffer.push(n),e.length+=e.objectMode?1:n.length)}e.ended=!0,v(t)}}function v(t){var e=t._readableState;e.needReadable=!1,e.emittedReadable||(U("emitReadable",e.flowing),e.emittedReadable=!0,e.sync?R(b,t):b(t))}function b(t){U("emit readable"),t.emit("readable"),C(t)}function g(t,e){e.readingMore||(e.readingMore=!0,R(y,t,e))}function y(t,e){for(var n=e.length;!e.reading&&!e.flowing&&!e.ended&&e.length=e.length?(n=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.head.data:e.buffer.concat(e.length),e.buffer.clear()):n=E(t,e.buffer,e.decoder),n}function E(t,e,n){var r;return to.length?o.length:t;if(s===o.length?i+=o:i+=o.slice(0,t),0===(t-=s)){s===o.length?(++r,n.next?e.head=n.next:e.head=e.tail=null):(e.head=n,n.data=o.slice(s));break}++r}return e.length-=r,i}function A(t,e){var n=z.allocUnsafe(t),r=e.head,i=1;for(r.data.copy(n),t-=r.data.length;r=r.next;){var o=r.data,s=t>o.length?o.length:t;if(o.copy(n,n.length-t,0,s),0===(t-=s)){s===o.length?(++i,r.next?e.head=r.next:e.head=e.tail=null):(e.head=r,r.data=o.slice(s));break}++i}return e.length-=i,n}function j(t){var e=t._readableState;if(e.length>0)throw new Error('"endReadable()" called on non-empty stream');e.endEmitted||(e.ended=!0,R(T,e,t))}function T(t,e){t.endEmitted||0!==t.length||(t.endEmitted=!0,e.readable=!1,e.emit("end"))}function $(t,e){for(var n=0,r=t.length;n=e.highWaterMark||e.ended))return U("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?j(this):v(this),null;if(0===(t=p(t,e))&&e.ended)return 0===e.length&&j(this),null;var r=e.needReadable;U("need readable",r),(0===e.length||e.length-t0?O(t,e):null,null===i?(e.needReadable=!0,t=0):e.length-=t,0===e.length&&(e.ended||(e.needReadable=!0),n!==t&&e.ended&&j(this)),null!==i&&this.emit("data",i),i},c.prototype._read=function(t){this.emit("error",new Error("_read() is not implemented"))},c.prototype.pipe=function(t,e){function n(t,e){U("onunpipe"),t===d&&e&&!1===e.hasUnpiped&&(e.hasUnpiped=!0,o())}function i(){U("onend"),t.end()}function o(){U("cleanup"),t.removeListener("close",l),t.removeListener("finish",u),t.removeListener("drain",v),t.removeListener("error",c),t.removeListener("unpipe",n),d.removeListener("end",i),d.removeListener("end",f),d.removeListener("data",a),b=!0,!h.awaitDrain||t._writableState&&!t._writableState.needDrain||v()}function a(e){U("ondata"),g=!1,!1!==t.write(e)||g||((1===h.pipesCount&&h.pipes===t||h.pipesCount>1&&-1!==$(h.pipes,t))&&!b&&(U("false write response, pause",d._readableState.awaitDrain),d._readableState.awaitDrain++,g=!0),d.pause())}function c(e){U("onerror",e),f(),t.removeListener("error",c),0===P(t,"error")&&t.emit("error",e)}function l(){t.removeListener("finish",u),f()}function u(){U("onfinish"),t.removeListener("close",l),f()}function f(){U("unpipe"),d.unpipe(t)}var d=this,h=this._readableState;switch(h.pipesCount){case 0:h.pipes=t;break;case 1:h.pipes=[h.pipes,t];break;default:h.pipes.push(t)}h.pipesCount+=1,U("pipe count=%d opts=%j",h.pipesCount,e);var p=(!e||!1!==e.end)&&t!==r.stdout&&t!==r.stderr,m=p?i:f;h.endEmitted?R(m):d.once("end",m),t.on("unpipe",n);var v=w(d);t.on("drain",v);var b=!1,g=!1;return d.on("data",a),s(t,"error",c),t.once("close",l),t.once("finish",u),t.emit("pipe",d),h.flowing||(U("pipe resume"),d.resume()),t},c.prototype.unpipe=function(t){var e=this._readableState,n={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,n),this);if(!t){var r=e.pipes,i=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o=this.charLength-this.charReceived?this.charLength-this.charReceived:t.length;if(t.copy(this.charBuffer,this.charReceived,0,n),this.charReceived+=n,this.charReceived=55296&&r<=56319)){if(this.charReceived=this.charLength=0,0===t.length)return e;break}this.charLength+=this.surrogateSize,e=""}this.detectIncompleteChar(t);var i=t.length;this.charLength&&(t.copy(this.charBuffer,0,t.length-this.charReceived,i),i-=this.charReceived),e+=t.toString(this.encoding,0,i);var i=e.length-1,r=e.charCodeAt(i);if(r>=55296&&r<=56319){var o=this.surrogateSize;return this.charLength+=o,this.charReceived+=o,this.charBuffer.copy(this.charBuffer,o,0,o),t.copy(this.charBuffer,0,0,o),e.substring(0,i)}return e},l.prototype.detectIncompleteChar=function(t){for(var e=t.length>=3?3:t.length;e>0;e--){var n=t[t.length-e];if(1==e&&n>>5==6){this.charLength=2;break}if(e<=2&&n>>4==14){this.charLength=3;break}if(e<=3&&n>>3==30){this.charLength=4;break}}this.charReceived=e},l.prototype.end=function(t){var e="";if(t&&t.length&&(e=this.write(t)),this.charReceived){var n=this.charReceived,r=this.charBuffer,i=this.encoding;e+=r.slice(0,n).toString(i)}return e}},function(t,e,n){"use strict";function r(t){this.afterTransform=function(e,n){return i(t,e,n)},this.needTransform=!1,this.transforming=!1,this.writecb=null,this.writechunk=null,this.writeencoding=null}function i(t,e,n){var r=t._transformState;r.transforming=!1;var i=r.writecb;if(!i)return t.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,null!==n&&void 0!==n&&t.push(n),i(e);var o=t._readableState;o.reading=!1,(o.needReadable||o.length>2,a=(3&e)<<4|n>>4,c=h>1?(15&n)<<2|i>>6:64,l=h>2?63&i:64,u.push(o.charAt(s)+o.charAt(a)+o.charAt(c)+o.charAt(l));return u.join("")},e.decode=function(t){var e,n,r,s,a,c,l,u=0,f=0;if("data:"===t.substr(0,"data:".length))throw new Error("Invalid base64 input, it looks like a data url.");t=t.replace(/[^A-Za-z0-9\+\/\=]/g,"");var d=3*t.length/4;if(t.charAt(t.length-1)===o.charAt(64)&&d--,t.charAt(t.length-2)===o.charAt(64)&&d--,d%1!=0)throw new Error("Invalid base64 input, bad content length.");var h;for(h=i.uint8array?new Uint8Array(0|d):new Array(0|d);u>4,n=(15&a)<<4|c>>2,r=(3&c)<<6|l,h[f++]=e,64!==c&&(h[f++]=n),64!==l&&(h[f++]=r);return h}},function(t,e){var n=t.exports={version:"2.3.0"};"number"==typeof __e&&(__e=n)},function(t,e,n){var r=n(294);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}}},function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,e,n){var r=n(48),i=n(32).document,o=r(i)&&r(i.createElement);t.exports=function(t){return o?i.createElement(t):{}}},function(t,e,n){"use strict";(function(e){function r(t,e,n,r){var o=null;switch(t){case"blob":return a.newBlob(n,r);case"base64":return o=i(e,n),u.encode(o);default:return o=i(e,n),a.transformTo(t,o)}}function i(t,n){var r,i=0,o=null,s=0;for(r=0;r=this.max)return this.end();switch(this.type){case"string":t=this.data.substring(this.index,e);break;case"uint8array":t=this.data.subarray(this.index,e);break;case"array":case"nodebuffer":t=this.data.slice(this.index,e)}return this.index=e,this.push({data:t,meta:{percent:this.max?this.index/this.max*100:0}})},t.exports=r},function(t,e,n){"use strict";function r(t){o.call(this,"DataLengthProbe for "+t),this.propName=t,this.withStreamInfo(t,0)}var i=n(0),o=n(1);i.inherits(r,o),r.prototype.processChunk=function(t){if(t){var e=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=e+t.data.length}o.prototype.processChunk.call(this,t)},t.exports=r},function(t,e,n){"use strict";function r(){i.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}var i=n(1),o=n(51);n(0).inherits(r,i),r.prototype.processChunk=function(t){this.streamInfo.crc32=o(t.data,this.streamInfo.crc32||0),this.push(t)},t.exports=r},function(t,e,n){"use strict";var r=n(1);e.STORE={magic:"\0\0",compressWorker:function(t){return new r("STORE compression")},uncompressWorker:function(){return new r("STORE decompression")}},e.DEFLATE=n(314)},function(t,e,n){"use strict";function r(t,e,n,r){for(var i=65535&t|0,o=t>>>16&65535|0,s=0;0!==n;){s=n>2e3?2e3:n,n-=s;do{i=i+e[r++]|0,o=o+i|0}while(--s);i%=65521,o%=65521}return i|o<<16|0}t.exports=r},function(t,e,n){"use strict";function r(t,e,n,r){var o=i,s=r+n;t^=-1;for(var a=r;a>>8^o[255&(t^e[a])];return-1^t}var i=function(){for(var t,e=[],n=0;n<256;n++){t=n;for(var r=0;r<8;r++)t=1&t?3988292384^t>>>1:t>>>1;e[n]=t}return e}();t.exports=r},function(t,e,n){"use strict";function r(t,e){if(e<65537&&(t.subarray&&s||!t.subarray&&o))return String.fromCharCode.apply(null,i.shrinkBuf(t,e));for(var n="",r=0;r=252?6:c>=248?5:c>=240?4:c>=224?3:c>=192?2:1;a[254]=a[254]=1,e.string2buf=function(t){var e,n,r,o,s,a=t.length,c=0;for(o=0;o>>6,e[s++]=128|63&n):n<65536?(e[s++]=224|n>>>12,e[s++]=128|n>>>6&63,e[s++]=128|63&n):(e[s++]=240|n>>>18,e[s++]=128|n>>>12&63,e[s++]=128|n>>>6&63,e[s++]=128|63&n);return e},e.buf2binstring=function(t){return r(t,t.length)},e.binstring2buf=function(t){for(var e=new i.Buf8(t.length),n=0,r=e.length;n4)l[i++]=65533,n+=s-1;else{for(o&=2===s?31:3===s?15:7;s>1&&n1?l[i++]=65533:o<65536?l[i++]=o:(o-=65536,l[i++]=55296|o>>10&1023,l[i++]=56320|1023&o)}return r(l,i)},e.utf8border=function(t,e){var n;for(e=e||t.length,e>t.length&&(e=t.length),n=e-1;n>=0&&128==(192&t[n]);)n--;return n<0?e:0===n?e:n+a[t[n]]>e?n:e}},function(t,e,n){"use strict";function r(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}t.exports=r},function(t,e,n){"use strict";t.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},function(t,e,n){"use strict";e.LOCAL_FILE_HEADER="PK",e.CENTRAL_FILE_HEADER="PK",e.CENTRAL_DIRECTORY_END="PK",e.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK",e.ZIP64_CENTRAL_DIRECTORY_END="PK",e.DATA_DESCRIPTOR="PK\b"},function(t,e,n){"use strict";var r=n(0),i=n(5),o=n(100),s=n(328),a=n(329),c=n(102);t.exports=function(t){var e=r.getTypeOf(t);return r.checkSupport(e),"string"!==e||i.uint8array?"nodebuffer"===e?new a(t):i.uint8array?new c(r.transformTo("uint8array",t)):new o(r.transformTo("array",t)):new s(t)}},function(t,e,n){"use strict";function r(t){i.call(this,t);for(var e=0;e=0;--o)if(this.data[o]===e&&this.data[o+1]===n&&this.data[o+2]===r&&this.data[o+3]===i)return o-this.zero;return-1},r.prototype.readAndCheckSignature=function(t){var e=t.charCodeAt(0),n=t.charCodeAt(1),r=t.charCodeAt(2),i=t.charCodeAt(3),o=this.readData(4);return e===o[0]&&n===o[1]&&r===o[2]&&i===o[3]},r.prototype.readData=function(t){if(this.checkOffset(t),0===t)return[];var e=this.data.slice(this.zero+this.index,this.zero+this.index+t);return this.index+=t,e},t.exports=r},function(t,e,n){"use strict";function r(t){this.data=t,this.length=t.length,this.index=0,this.zero=0}var i=n(0);r.prototype={checkOffset:function(t){this.checkIndex(this.index+t)},checkIndex:function(t){if(this.length=this.index;e--)n=(n<<8)+this.byteAt(e);return this.index+=t,n},readString:function(t){return i.transformTo("string",this.readData(t))},readData:function(t){},lastIndexOfSignature:function(t){},readAndCheckSignature:function(t){},readDate:function(){var t=this.readInt(4);return new Date(Date.UTC(1980+(t>>25&127),(t>>21&15)-1,t>>16&31,t>>11&31,t>>5&63,(31&t)<<1))}},t.exports=r},function(t,e,n){"use strict";function r(t){i.call(this,t)}var i=n(100);n(0).inherits(r,i),r.prototype.readData=function(t){if(this.checkOffset(t),0===t)return new Uint8Array(0);var e=this.data.subarray(this.zero+this.index,this.zero+this.index+t);return this.index+=t,e},t.exports=r},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}var i=n(104),o=r(i),s=n(105),a=r(s);n(111);var c=n(120),l=r(c),u=n(251),f=r(u),d=n(254),h=r(d),p=n(257),m=r(p),v=n(260),b=r(v),g=n(263),y=r(g),w=n(266),_=r(w),x=n(269),k=r(x),C=n(272),O=r(C),E=n(275),S=r(E);l.default.mix({components:{Uploader:a.default}}),l.default.component(f.default),l.default.component(h.default),l.default.component(m.default),l.default.component(b.default),l.default.component(y.default),l.default.component(_.default),l.default.component(k.default),l.default.component(O.default),l.default.use(S.default),o.default.use(l.default),new o.default({el:"#app"})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t){/*! +var J=n(281),G=n(282),X=n(75);e.Buffer=o,e.SlowBuffer=m,e.INSPECT_MAX_BYTES=50,o.TYPED_ARRAY_SUPPORT=void 0!==t.TYPED_ARRAY_SUPPORT?t.TYPED_ARRAY_SUPPORT:function(){try{var t=new Uint8Array(1);return t.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===t.foo()&&"function"==typeof t.subarray&&0===t.subarray(1,1).byteLength}catch(t){return!1}}(),e.kMaxLength=r(),o.poolSize=8192,o._augment=function(t){return t.__proto__=o.prototype,t},o.from=function(t,e,n){return s(null,t,e,n)},o.TYPED_ARRAY_SUPPORT&&(o.prototype.__proto__=Uint8Array.prototype,o.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&o[Symbol.species]===o&&Object.defineProperty(o,Symbol.species,{value:null,configurable:!0})),o.alloc=function(t,e,n){return c(null,t,e,n)},o.allocUnsafe=function(t){return l(null,t)},o.allocUnsafeSlow=function(t){return l(null,t)},o.isBuffer=function(t){return!(null==t||!t._isBuffer)},o.compare=function(t,e){if(!o.isBuffer(t)||!o.isBuffer(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var n=t.length,r=e.length,i=0,s=Math.min(n,r);i0&&(t=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(t+=" ... ")),""},o.prototype.compare=function(t,e,n,r,i){if(!o.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===e&&(e=0),void 0===n&&(n=t?t.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),e<0||n>t.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&e>=n)return 0;if(r>=i)return-1;if(e>=n)return 1;if(e>>>=0,n>>>=0,r>>>=0,i>>>=0,this===t)return 0;for(var s=i-r,a=n-e,c=Math.min(s,a),l=this.slice(r,i),u=t.slice(e,n),f=0;fi)&&(n=i),t.length>0&&(n<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return _(this,t,e,n);case"utf8":case"utf-8":return x(this,t,e,n);case"ascii":return k(this,t,e,n);case"latin1":case"binary":return C(this,t,e,n);case"base64":return O(this,t,e,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,t,e,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var Q=4096;o.prototype.slice=function(t,e){var n=this.length;t=~~t,e=void 0===e?n:~~e,t<0?(t+=n)<0&&(t=0):t>n&&(t=n),e<0?(e+=n)<0&&(e=0):e>n&&(e=n),e0&&(i*=256);)r+=this[t+--e]*i;return r},o.prototype.readUInt8=function(t,e){return e||L(t,1,this.length),this[t]},o.prototype.readUInt16LE=function(t,e){return e||L(t,2,this.length),this[t]|this[t+1]<<8},o.prototype.readUInt16BE=function(t,e){return e||L(t,2,this.length),this[t]<<8|this[t+1]},o.prototype.readUInt32LE=function(t,e){return e||L(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},o.prototype.readUInt32BE=function(t,e){return e||L(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},o.prototype.readIntLE=function(t,e,n){t|=0,e|=0,n||L(t,e,this.length);for(var r=this[t],i=1,o=0;++o=i&&(r-=Math.pow(2,8*e)),r},o.prototype.readIntBE=function(t,e,n){t|=0,e|=0,n||L(t,e,this.length);for(var r=e,i=1,o=this[t+--r];r>0&&(i*=256);)o+=this[t+--r]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*e)),o},o.prototype.readInt8=function(t,e){return e||L(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},o.prototype.readInt16LE=function(t,e){e||L(t,2,this.length);var n=this[t]|this[t+1]<<8;return 32768&n?4294901760|n:n},o.prototype.readInt16BE=function(t,e){e||L(t,2,this.length);var n=this[t+1]|this[t]<<8;return 32768&n?4294901760|n:n},o.prototype.readInt32LE=function(t,e){return e||L(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},o.prototype.readInt32BE=function(t,e){return e||L(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},o.prototype.readFloatLE=function(t,e){return e||L(t,4,this.length),G.read(this,t,!0,23,4)},o.prototype.readFloatBE=function(t,e){return e||L(t,4,this.length),G.read(this,t,!1,23,4)},o.prototype.readDoubleLE=function(t,e){return e||L(t,8,this.length),G.read(this,t,!0,52,8)},o.prototype.readDoubleBE=function(t,e){return e||L(t,8,this.length),G.read(this,t,!1,52,8)},o.prototype.writeUIntLE=function(t,e,n,r){if(t=+t,e|=0,n|=0,!r){P(this,t,e,n,Math.pow(2,8*n)-1,0)}var i=1,o=0;for(this[e]=255&t;++o=0&&(o*=256);)this[e+i]=t/o&255;return e+n},o.prototype.writeUInt8=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,1,255,0),o.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&t,e+1},o.prototype.writeUInt16LE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,2,65535,0),o.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):I(this,t,e,!0),e+2},o.prototype.writeUInt16BE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,2,65535,0),o.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):I(this,t,e,!1),e+2},o.prototype.writeUInt32LE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,4,4294967295,0),o.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):z(this,t,e,!0),e+4},o.prototype.writeUInt32BE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,4,4294967295,0),o.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):z(this,t,e,!1),e+4},o.prototype.writeIntLE=function(t,e,n,r){if(t=+t,e|=0,!r){var i=Math.pow(2,8*n-1);P(this,t,e,n,i-1,-i)}var o=0,s=1,a=0;for(this[e]=255&t;++o>0)-a&255;return e+n},o.prototype.writeIntBE=function(t,e,n,r){if(t=+t,e|=0,!r){var i=Math.pow(2,8*n-1);P(this,t,e,n,i-1,-i)}var o=n-1,s=1,a=0;for(this[e+o]=255&t;--o>=0&&(s*=256);)t<0&&0===a&&0!==this[e+o+1]&&(a=1),this[e+o]=(t/s>>0)-a&255;return e+n},o.prototype.writeInt8=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,1,127,-128),o.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=255&t,e+1},o.prototype.writeInt16LE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,2,32767,-32768),o.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):I(this,t,e,!0),e+2},o.prototype.writeInt16BE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,2,32767,-32768),o.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):I(this,t,e,!1),e+2},o.prototype.writeInt32LE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,4,2147483647,-2147483648),o.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):z(this,t,e,!0),e+4},o.prototype.writeInt32BE=function(t,e,n){return t=+t,e|=0,n||P(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),o.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):z(this,t,e,!1),e+4},o.prototype.writeFloatLE=function(t,e,n){return B(this,t,e,!0,n)},o.prototype.writeFloatBE=function(t,e,n){return B(this,t,e,!1,n)},o.prototype.writeDoubleLE=function(t,e,n){return N(this,t,e,!0,n)},o.prototype.writeDoubleBE=function(t,e,n){return N(this,t,e,!1,n)},o.prototype.copy=function(t,e,n,r){if(n||(n=0),r||0===r||(r=this.length),e>=t.length&&(e=t.length),e||(e=0),r>0&&r=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),t.length-e=0;--i)t[i+e]=this[i+n];else if(s<1e3||!o.TYPED_ARRAY_SUPPORT)for(i=0;i>>=0,n=void 0===n?this.length:n>>>0,t||(t=0);var s;if("number"==typeof t)for(s=e;s1)for(var n=1;nn.parts.length&&(r.parts.length=n.parts.length)}else{for(var s=[],i=0;i0&&this._events[t].length>i&&(this._events[t].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[t].length),"function"==typeof console.trace&&console.trace()),this},n.prototype.on=n.prototype.addListener,n.prototype.once=function(t,e){function n(){this.removeListener(t,n),i||(i=!0,e.apply(this,arguments))}if(!r(e))throw TypeError("listener must be a function");var i=!1;return n.listener=e,this.on(t,n),this},n.prototype.removeListener=function(t,e){var n,i,s,a;if(!r(e))throw TypeError("listener must be a function");if(!this._events||!this._events[t])return this;if(n=this._events[t],s=n.length,i=-1,n===e||r(n.listener)&&n.listener===e)delete this._events[t],this._events.removeListener&&this.emit("removeListener",t,e);else if(o(n)){for(a=s;a-- >0;)if(n[a]===e||n[a].listener&&n[a].listener===e){i=a;break}if(i<0)return this;1===n.length?(n.length=0,delete this._events[t]):n.splice(i,1),this._events.removeListener&&this.emit("removeListener",t,e)}return this},n.prototype.removeAllListeners=function(t){var e,n;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[t]&&delete this._events[t],this;if(0===arguments.length){for(e in this._events)"removeListener"!==e&&this.removeAllListeners(e);return this.removeAllListeners("removeListener"),this._events={},this}if(n=this._events[t],r(n))this.removeListener(t,n);else if(n)for(;n.length;)this.removeListener(t,n[n.length-1]);return delete this._events[t],this},n.prototype.listeners=function(t){return this._events&&this._events[t]?r(this._events[t])?[this._events[t]]:this._events[t].slice():[]},n.prototype.listenerCount=function(t){if(this._events){var e=this._events[t];if(r(e))return 1;if(e)return e.length}return 0},n.listenerCount=function(t,e){return t.listenerCount(e)}},function(t,e,n){e=t.exports=n(77),e.Stream=e,e.Readable=e,e.Writable=n(47),e.Duplex=n(8),e.Transform=n(81),e.PassThrough=n(289)},function(t,e,n){function r(t,e){for(var n in t)e[n]=t[n]}function i(t,e,n){return s(t,e,n)}var o=n(13),s=o.Buffer;s.from&&s.alloc&&s.allocUnsafe&&s.allocUnsafeSlow?t.exports=o:(r(o,e),e.Buffer=i),r(s,i),i.from=function(t,e,n){if("number"==typeof t)throw new TypeError("Argument must not be a number");return s(t,e,n)},i.alloc=function(t,e,n){if("number"!=typeof t)throw new TypeError("Argument must be a number");var r=s(t);return void 0!==e?"string"==typeof n?r.fill(e,n):r.fill(e):r.fill(0),r},i.allocUnsafe=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return s(t)},i.allocUnsafeSlow=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return o.SlowBuffer(t)}},function(t,e,n){"use strict";(function(e,r,i){function o(t){var e=this;this.next=null,this.entry=null,this.finish=function(){S(e,t)}}function s(t){return L.from(t)}function a(t){return L.isBuffer(t)||t instanceof P}function c(){}function l(t,e){j=j||n(8),t=t||{},this.objectMode=!!t.objectMode,e instanceof j&&(this.objectMode=this.objectMode||!!t.writableObjectMode);var r=t.highWaterMark,i=this.objectMode?16:16384;this.highWaterMark=r||0===r?r:i,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var s=!1===t.decodeStrings;this.decodeStrings=!s,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(t){g(e,t)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function u(t){if(j=j||n(8),!(z.call(u,this)||this instanceof j))return new u(t);this._writableState=new l(t,this),this.writable=!0,t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final)),D.call(this)}function f(t,e){var n=new Error("write after end");t.emit("error",n),A(e,n)}function d(t,e,n,r){var i=!0,o=!1;return null===n?o=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||e.objectMode||(o=new TypeError("Invalid non-string/buffer chunk")),o&&(t.emit("error",o),A(r,o),i=!1),i}function h(t,e,n){return t.objectMode||!1===t.decodeStrings||"string"!=typeof e||(e=L.from(e,n)),e}function p(t,e,n,r,i,o){if(!n){var s=h(e,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=e.objectMode?1:r.length;e.length+=a;var c=e.length-1?r:A;u.WritableState=l;var $=n(17);$.inherits=n(14);var R={deprecate:n(288)},D=n(78),L=n(46).Buffer,P=i.Uint8Array||function(){},I=n(79);$.inherits(u,D),l.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(l.prototype,"buffer",{get:R.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}();var z;"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(z=Function.prototype[Symbol.hasInstance],Object.defineProperty(u,Symbol.hasInstance,{value:function(t){return!!z.call(this,t)||t&&t._writableState instanceof l}})):z=function(t){return t instanceof this},u.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},u.prototype.write=function(t,e,n){var r=this._writableState,i=!1,o=a(t)&&!r.objectMode;return o&&!L.isBuffer(t)&&(t=s(t)),"function"==typeof e&&(n=e,e=null),o?e="buffer":e||(e=r.defaultEncoding),"function"!=typeof n&&(n=c),r.ended?f(this,n):(o||d(this,r,t,n))&&(r.pendingcb++,i=p(this,r,o,t,e,n)),i},u.prototype.cork=function(){this._writableState.corked++},u.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,t.writing||t.corked||t.finished||t.bufferProcessing||!t.bufferedRequest||_(this,t))},u.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},u.prototype._write=function(t,e,n){n(new Error("_write() is not implemented"))},u.prototype._writev=null,u.prototype.end=function(t,e,n){var r=this._writableState;"function"==typeof t?(n=t,t=null,e=null):"function"==typeof e&&(n=e,e=null),null!==t&&void 0!==t&&this.write(t,e),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||E(this,r,n)},Object.defineProperty(u.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),u.prototype.destroy=I.destroy,u.prototype._undestroy=I.undestroy,u.prototype._destroy=function(t,e){this.end(),e(t)}}).call(e,n(16),n(286).setImmediate,n(3))},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e,n){t.exports=!n(85)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(t,e,n){"use strict";function r(t,e,n,r,i){this.compressedSize=t,this.uncompressedSize=e,this.crc32=n,this.compression=r,this.compressedContent=i}var i=n(18),o=n(89),s=n(90),a=n(91),s=n(90);r.prototype={getContentWorker:function(){var t=new o(i.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new s("data_length")),e=this;return t.on("end",function(){if(this.streamInfo.data_length!==e.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),t},getCompressedWorker:function(){return new o(i.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},r.createWorkerFrom=function(t,e,n){return t.pipe(new a).pipe(new s("uncompressedSize")).pipe(e.compressWorker(n)).pipe(new s("compressedSize")).withStreamInfo("compression",e)},t.exports=r},function(t,e,n){"use strict";function r(t,e,n,r){var i=s,o=r+n;t^=-1;for(var a=r;a>>8^i[255&(t^e[a])];return-1^t}function i(t,e,n,r){var i=s,o=r+n;t^=-1;for(var a=r;a>>8^i[255&(t^e.charCodeAt(a))];return-1^t}var o=n(0),s=function(){for(var t,e=[],n=0;n<256;n++){t=n;for(var r=0;r<8;r++)t=1&t?3988292384^t>>>1:t>>>1;e[n]=t}return e}();t.exports=function(t,e){return void 0!==t&&t.length?"string"!==o.getTypeOf(t)?r(0|e,t,t.length,0):i(0|e,t,t.length,0):0}},function(t,e,n){"use strict";t.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},function(t,e,n){"use strict";var r=n(34),i=n(9),o=Object(r.a)(i.a,"Map");e.a=o},function(t,e,n){"use strict";(function(t){var n="object"==typeof t&&t&&t.Object===Object&&t;e.a=n}).call(e,n(3))},function(t,e,n){"use strict";function r(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1&&t%1==0&&t<=i}var i=9007199254740991;e.a=r},function(t,e,n){"use strict";(function(t){var r=n(9),i=n(165),o="object"==typeof exports&&exports&&!exports.nodeType&&exports,s=o&&"object"==typeof t&&t&&!t.nodeType&&t,a=s&&s.exports===o,c=a?r.a.Buffer:void 0,l=c?c.isBuffer:void 0,u=l||i.a;e.a=u}).call(e,n(38)(t))},function(t,e,n){"use strict";var r=n(167),i=n(168),o=n(169),s=o.a&&o.a.isTypedArray,a=s?Object(i.a)(s):r.a;e.a=a},function(t,e,n){"use strict";function r(t){return Object(s.a)(t)?Object(i.a)(t,!0):Object(o.a)(t)}var i=n(173),o=n(175),s=n(39);e.a=r},function(t,e,n){"use strict";function r(t,e){return!!(e=null==e?i:e)&&("number"==typeof t||o.test(t))&&t>-1&&t%1==0&&t0?("string"==typeof e||s.objectMode||Object.getPrototypeOf(e)===z.prototype||(e=i(e)),r?s.endEmitted?t.emit("error",new Error("stream.unshift() after end event")):u(t,s,e,!0):s.ended?t.emit("error",new Error("stream.push() after EOF")):(s.reading=!1,s.decoder&&!n?(e=s.decoder.write(e),s.objectMode||0!==e.length?u(t,s,e,!1):g(t,s)):u(t,s,e,!1))):r||(s.reading=!1)}return d(s)}function u(t,e,n,r){e.flowing&&0===e.length&&!e.sync?(t.emit("data",n),t.read(0)):(e.length+=e.objectMode?1:n.length,r?e.buffer.unshift(n):e.buffer.push(n),e.needReadable&&v(t)),g(t,e)}function f(t,e){var n;return o(e)||"string"==typeof e||void 0===e||t.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function d(t){return!t.ended&&(t.needReadable||t.length=Y?t=Y:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function p(t,e){return t<=0||0===e.length&&e.ended?0:e.objectMode?1:t!==t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=h(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function m(t,e){if(!e.ended){if(e.decoder){var n=e.decoder.end();n&&n.length&&(e.buffer.push(n),e.length+=e.objectMode?1:n.length)}e.ended=!0,v(t)}}function v(t){var e=t._readableState;e.needReadable=!1,e.emittedReadable||(U("emitReadable",e.flowing),e.emittedReadable=!0,e.sync?R(b,t):b(t))}function b(t){U("emit readable"),t.emit("readable"),C(t)}function g(t,e){e.readingMore||(e.readingMore=!0,R(y,t,e))}function y(t,e){for(var n=e.length;!e.reading&&!e.flowing&&!e.ended&&e.length=e.length?(n=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.head.data:e.buffer.concat(e.length),e.buffer.clear()):n=E(t,e.buffer,e.decoder),n}function E(t,e,n){var r;return to.length?o.length:t;if(s===o.length?i+=o:i+=o.slice(0,t),0===(t-=s)){s===o.length?(++r,n.next?e.head=n.next:e.head=e.tail=null):(e.head=n,n.data=o.slice(s));break}++r}return e.length-=r,i}function A(t,e){var n=z.allocUnsafe(t),r=e.head,i=1;for(r.data.copy(n),t-=r.data.length;r=r.next;){var o=r.data,s=t>o.length?o.length:t;if(o.copy(n,n.length-t,0,s),0===(t-=s)){s===o.length?(++i,r.next?e.head=r.next:e.head=e.tail=null):(e.head=r,r.data=o.slice(s));break}++i}return e.length-=i,n}function j(t){var e=t._readableState;if(e.length>0)throw new Error('"endReadable()" called on non-empty stream');e.endEmitted||(e.ended=!0,R(T,e,t))}function T(t,e){t.endEmitted||0!==t.length||(t.endEmitted=!0,e.readable=!1,e.emit("end"))}function $(t,e){for(var n=0,r=t.length;n=e.highWaterMark||e.ended))return U("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?j(this):v(this),null;if(0===(t=p(t,e))&&e.ended)return 0===e.length&&j(this),null;var r=e.needReadable;U("need readable",r),(0===e.length||e.length-t0?O(t,e):null,null===i?(e.needReadable=!0,t=0):e.length-=t,0===e.length&&(e.ended||(e.needReadable=!0),n!==t&&e.ended&&j(this)),null!==i&&this.emit("data",i),i},c.prototype._read=function(t){this.emit("error",new Error("_read() is not implemented"))},c.prototype.pipe=function(t,e){function n(t,e){U("onunpipe"),t===d&&e&&!1===e.hasUnpiped&&(e.hasUnpiped=!0,o())}function i(){U("onend"),t.end()}function o(){U("cleanup"),t.removeListener("close",l),t.removeListener("finish",u),t.removeListener("drain",v),t.removeListener("error",c),t.removeListener("unpipe",n),d.removeListener("end",i),d.removeListener("end",f),d.removeListener("data",a),b=!0,!h.awaitDrain||t._writableState&&!t._writableState.needDrain||v()}function a(e){U("ondata"),g=!1,!1!==t.write(e)||g||((1===h.pipesCount&&h.pipes===t||h.pipesCount>1&&-1!==$(h.pipes,t))&&!b&&(U("false write response, pause",d._readableState.awaitDrain),d._readableState.awaitDrain++,g=!0),d.pause())}function c(e){U("onerror",e),f(),t.removeListener("error",c),0===P(t,"error")&&t.emit("error",e)}function l(){t.removeListener("finish",u),f()}function u(){U("onfinish"),t.removeListener("close",l),f()}function f(){U("unpipe"),d.unpipe(t)}var d=this,h=this._readableState;switch(h.pipesCount){case 0:h.pipes=t;break;case 1:h.pipes=[h.pipes,t];break;default:h.pipes.push(t)}h.pipesCount+=1,U("pipe count=%d opts=%j",h.pipesCount,e);var p=(!e||!1!==e.end)&&t!==r.stdout&&t!==r.stderr,m=p?i:f;h.endEmitted?R(m):d.once("end",m),t.on("unpipe",n);var v=w(d);t.on("drain",v);var b=!1,g=!1;return d.on("data",a),s(t,"error",c),t.once("close",l),t.once("finish",u),t.emit("pipe",d),h.flowing||(U("pipe resume"),d.resume()),t},c.prototype.unpipe=function(t){var e=this._readableState,n={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,n),this);if(!t){var r=e.pipes,i=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o=this.charLength-this.charReceived?this.charLength-this.charReceived:t.length;if(t.copy(this.charBuffer,this.charReceived,0,n),this.charReceived+=n,this.charReceived=55296&&r<=56319)){if(this.charReceived=this.charLength=0,0===t.length)return e;break}this.charLength+=this.surrogateSize,e=""}this.detectIncompleteChar(t);var i=t.length;this.charLength&&(t.copy(this.charBuffer,0,t.length-this.charReceived,i),i-=this.charReceived),e+=t.toString(this.encoding,0,i);var i=e.length-1,r=e.charCodeAt(i);if(r>=55296&&r<=56319){var o=this.surrogateSize;return this.charLength+=o,this.charReceived+=o,this.charBuffer.copy(this.charBuffer,o,0,o),t.copy(this.charBuffer,0,0,o),e.substring(0,i)}return e},l.prototype.detectIncompleteChar=function(t){for(var e=t.length>=3?3:t.length;e>0;e--){var n=t[t.length-e];if(1==e&&n>>5==6){this.charLength=2;break}if(e<=2&&n>>4==14){this.charLength=3;break}if(e<=3&&n>>3==30){this.charLength=4;break}}this.charReceived=e},l.prototype.end=function(t){var e="";if(t&&t.length&&(e=this.write(t)),this.charReceived){var n=this.charReceived,r=this.charBuffer,i=this.encoding;e+=r.slice(0,n).toString(i)}return e}},function(t,e,n){"use strict";function r(t){this.afterTransform=function(e,n){return i(t,e,n)},this.needTransform=!1,this.transforming=!1,this.writecb=null,this.writechunk=null,this.writeencoding=null}function i(t,e,n){var r=t._transformState;r.transforming=!1;var i=r.writecb;if(!i)return t.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,null!==n&&void 0!==n&&t.push(n),i(e);var o=t._readableState;o.reading=!1,(o.needReadable||o.length>2,a=(3&e)<<4|n>>4,c=h>1?(15&n)<<2|i>>6:64,l=h>2?63&i:64,u.push(o.charAt(s)+o.charAt(a)+o.charAt(c)+o.charAt(l));return u.join("")},e.decode=function(t){var e,n,r,s,a,c,l,u=0,f=0;if("data:"===t.substr(0,"data:".length))throw new Error("Invalid base64 input, it looks like a data url.");t=t.replace(/[^A-Za-z0-9\+\/\=]/g,"");var d=3*t.length/4;if(t.charAt(t.length-1)===o.charAt(64)&&d--,t.charAt(t.length-2)===o.charAt(64)&&d--,d%1!=0)throw new Error("Invalid base64 input, bad content length.");var h;for(h=i.uint8array?new Uint8Array(0|d):new Array(0|d);u>4,n=(15&a)<<4|c>>2,r=(3&c)<<6|l,h[f++]=e,64!==c&&(h[f++]=n),64!==l&&(h[f++]=r);return h}},function(t,e){var n=t.exports={version:"2.3.0"};"number"==typeof __e&&(__e=n)},function(t,e,n){var r=n(297);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}}},function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,e,n){var r=n(48),i=n(32).document,o=r(i)&&r(i.createElement);t.exports=function(t){return o?i.createElement(t):{}}},function(t,e,n){"use strict";(function(e){function r(t,e,n,r){var o=null;switch(t){case"blob":return a.newBlob(n,r);case"base64":return o=i(e,n),u.encode(o);default:return o=i(e,n),a.transformTo(t,o)}}function i(t,n){var r,i=0,o=null,s=0;for(r=0;r=this.max)return this.end();switch(this.type){case"string":t=this.data.substring(this.index,e);break;case"uint8array":t=this.data.subarray(this.index,e);break;case"array":case"nodebuffer":t=this.data.slice(this.index,e)}return this.index=e,this.push({data:t,meta:{percent:this.max?this.index/this.max*100:0}})},t.exports=r},function(t,e,n){"use strict";function r(t){o.call(this,"DataLengthProbe for "+t),this.propName=t,this.withStreamInfo(t,0)}var i=n(0),o=n(2);i.inherits(r,o),r.prototype.processChunk=function(t){if(t){var e=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=e+t.data.length}o.prototype.processChunk.call(this,t)},t.exports=r},function(t,e,n){"use strict";function r(){i.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}var i=n(2),o=n(51);n(0).inherits(r,i),r.prototype.processChunk=function(t){this.streamInfo.crc32=o(t.data,this.streamInfo.crc32||0),this.push(t)},t.exports=r},function(t,e,n){"use strict";var r=n(2);e.STORE={magic:"\0\0",compressWorker:function(t){return new r("STORE compression")},uncompressWorker:function(){return new r("STORE decompression")}},e.DEFLATE=n(317)},function(t,e,n){"use strict";function r(t,e,n,r){for(var i=65535&t|0,o=t>>>16&65535|0,s=0;0!==n;){s=n>2e3?2e3:n,n-=s;do{i=i+e[r++]|0,o=o+i|0}while(--s);i%=65521,o%=65521}return i|o<<16|0}t.exports=r},function(t,e,n){"use strict";function r(t,e,n,r){var o=i,s=r+n;t^=-1;for(var a=r;a>>8^o[255&(t^e[a])];return-1^t}var i=function(){for(var t,e=[],n=0;n<256;n++){t=n;for(var r=0;r<8;r++)t=1&t?3988292384^t>>>1:t>>>1;e[n]=t}return e}();t.exports=r},function(t,e,n){"use strict";function r(t,e){if(e<65537&&(t.subarray&&s||!t.subarray&&o))return String.fromCharCode.apply(null,i.shrinkBuf(t,e));for(var n="",r=0;r=252?6:c>=248?5:c>=240?4:c>=224?3:c>=192?2:1;a[254]=a[254]=1,e.string2buf=function(t){var e,n,r,o,s,a=t.length,c=0;for(o=0;o>>6,e[s++]=128|63&n):n<65536?(e[s++]=224|n>>>12,e[s++]=128|n>>>6&63,e[s++]=128|63&n):(e[s++]=240|n>>>18,e[s++]=128|n>>>12&63,e[s++]=128|n>>>6&63,e[s++]=128|63&n);return e},e.buf2binstring=function(t){return r(t,t.length)},e.binstring2buf=function(t){for(var e=new i.Buf8(t.length),n=0,r=e.length;n4)l[i++]=65533,n+=s-1;else{for(o&=2===s?31:3===s?15:7;s>1&&n1?l[i++]=65533:o<65536?l[i++]=o:(o-=65536,l[i++]=55296|o>>10&1023,l[i++]=56320|1023&o)}return r(l,i)},e.utf8border=function(t,e){var n;for(e=e||t.length,e>t.length&&(e=t.length),n=e-1;n>=0&&128==(192&t[n]);)n--;return n<0?e:0===n?e:n+a[t[n]]>e?n:e}},function(t,e,n){"use strict";function r(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}t.exports=r},function(t,e,n){"use strict";t.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},function(t,e,n){"use strict";e.LOCAL_FILE_HEADER="PK",e.CENTRAL_FILE_HEADER="PK",e.CENTRAL_DIRECTORY_END="PK",e.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK",e.ZIP64_CENTRAL_DIRECTORY_END="PK",e.DATA_DESCRIPTOR="PK\b"},function(t,e,n){"use strict";var r=n(0),i=n(5),o=n(100),s=n(331),a=n(332),c=n(102);t.exports=function(t){var e=r.getTypeOf(t);return r.checkSupport(e),"string"!==e||i.uint8array?"nodebuffer"===e?new a(t):i.uint8array?new c(r.transformTo("uint8array",t)):new o(r.transformTo("array",t)):new s(t)}},function(t,e,n){"use strict";function r(t){i.call(this,t);for(var e=0;e=0;--o)if(this.data[o]===e&&this.data[o+1]===n&&this.data[o+2]===r&&this.data[o+3]===i)return o-this.zero;return-1},r.prototype.readAndCheckSignature=function(t){var e=t.charCodeAt(0),n=t.charCodeAt(1),r=t.charCodeAt(2),i=t.charCodeAt(3),o=this.readData(4);return e===o[0]&&n===o[1]&&r===o[2]&&i===o[3]},r.prototype.readData=function(t){if(this.checkOffset(t),0===t)return[];var e=this.data.slice(this.zero+this.index,this.zero+this.index+t);return this.index+=t,e},t.exports=r},function(t,e,n){"use strict";function r(t){this.data=t,this.length=t.length,this.index=0,this.zero=0}var i=n(0);r.prototype={checkOffset:function(t){this.checkIndex(this.index+t)},checkIndex:function(t){if(this.length=this.index;e--)n=(n<<8)+this.byteAt(e);return this.index+=t,n},readString:function(t){return i.transformTo("string",this.readData(t))},readData:function(t){},lastIndexOfSignature:function(t){},readAndCheckSignature:function(t){},readDate:function(){var t=this.readInt(4);return new Date(Date.UTC(1980+(t>>25&127),(t>>21&15)-1,t>>16&31,t>>11&31,t>>5&63,(31&t)<<1))}},t.exports=r},function(t,e,n){"use strict";function r(t){i.call(this,t)}var i=n(100);n(0).inherits(r,i),r.prototype.readData=function(t){if(this.checkOffset(t),0===t)return new Uint8Array(0);var e=this.data.subarray(this.zero+this.index,this.zero+this.index+t);return this.index+=t,e},t.exports=r},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}var i=n(104),o=r(i),s=n(105),a=r(s);n(111);var c=n(120),l=r(c),u=n(254),f=r(u),d=n(257),h=r(d),p=n(260),m=r(p),v=n(263),b=r(v),g=n(266),y=r(g),w=n(269),_=r(w),x=n(272),k=r(x),C=n(275),O=r(C),E=n(278),S=r(E);l.default.mix({components:{Uploader:a.default}}),l.default.component(f.default),l.default.component(h.default),l.default.component(m.default),l.default.component(b.default),l.default.component(y.default),l.default.component(_.default),l.default.component(k.default),l.default.component(O.default),l.default.use(S.default),o.default.use(l.default),new o.default({el:"#app"})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t){/*! * Vue.js v2.4.2 * (c) 2014-2017 Evan You * Released under the MIT License. */ -function n(t){return void 0===t||null===t}function r(t){return void 0!==t&&null!==t}function i(t){return!0===t}function o(t){return!1===t}function s(t){return"string"==typeof t||"number"==typeof t||"boolean"==typeof t}function a(t){return null!==t&&"object"==typeof t}function c(t){return"[object Object]"===zi.call(t)}function l(t){return"[object RegExp]"===zi.call(t)}function u(t){var e=parseFloat(t);return e>=0&&Math.floor(e)===e&&isFinite(t)}function f(t){return null==t?"":"object"==typeof t?JSON.stringify(t,null,2):String(t)}function d(t){var e=parseFloat(t);return isNaN(e)?t:e}function h(t,e){for(var n=Object.create(null),r=t.split(","),i=0;i-1)return t.splice(n,1)}}function m(t,e){return Ni.call(t,e)}function v(t){var e=Object.create(null);return function(n){return e[n]||(e[n]=t(n))}}function b(t,e){function n(n){var r=arguments.length;return r?r>1?t.apply(e,arguments):t.call(e,n):t.call(e)}return n._length=t.length,n}function g(t,e){e=e||0;for(var n=t.length-e,r=new Array(n);n--;)r[n]=t[n+e];return r}function y(t,e){for(var n in e)t[n]=e[n];return t}function w(t){for(var e={},n=0;nUo&&Io[n].id>t.id;)n--;Io.splice(n+1,0,t)}else Io.push(t);Mo||(Mo=!0,yo(jt))}}function Lt(t){Wo.clear(),Pt(t,Wo)}function Pt(t,e){var n,r,i=Array.isArray(t);if((i||a(t))&&Object.isExtensible(t)){if(t.__ob__){var o=t.__ob__.dep.id;if(e.has(o))return;e.add(o)}if(i)for(n=t.length;n--;)Pt(t[n],e);else for(r=Object.keys(t),n=r.length;n--;)Pt(t[r[n]],e)}}function It(t,e,n){Zo.get=function(){return this[e][n]},Zo.set=function(t){this[e][n]=t},Object.defineProperty(t,n,Zo)}function zt(t){t._watchers=[];var e=t.$options;e.props&&Bt(t,e.props),e.methods&&Wt(t,e.methods),e.data?Mt(t):L(t._data={},!0),e.computed&&Ut(t,e.computed),e.watch&&e.watch!==uo&&Zt(t,e.watch)}function Bt(t,e){var n=t.$options.propsData||{},r=t._props={},i=t.$options._propKeys=[],o=!t.$parent;Eo.shouldConvert=o;for(var s in e)!function(o){i.push(o);var s=V(o,e,n,t);P(r,o,s),o in t||It(t,"_props",o)}(s);Eo.shouldConvert=!0}function Mt(t){var e=t.$options.data;e=t._data="function"==typeof e?Nt(e,t):e||{},c(e)||(e={});for(var n=Object.keys(e),r=t.$options.props,i=(t.$options.methods,n.length);i--;){var o=n[i];r&&m(r,o)||O(o)||It(t,"_data",o)}L(e,!0)}function Nt(t,e){try{return t.call(e)}catch(t){return A(t,e,"data()"),{}}}function Ut(t,e){var n=t._computedWatchers=Object.create(null);for(var r in e){var i=e[r],o="function"==typeof i?i:i.get;n[r]=new Ho(t,o||_,_,Yo),r in t||Ft(t,r,i)}}function Ft(t,e,n){"function"==typeof n?(Zo.get=Ht(e),Zo.set=_):(Zo.get=n.get?!1!==n.cache?Ht(e):n.get:_,Zo.set=n.set?n.set:_),Object.defineProperty(t,e,Zo)}function Ht(t){return function(){var e=this._computedWatchers&&this._computedWatchers[t];if(e)return e.dirty&&e.evaluate(),_o.target&&e.depend(),e.value}}function Wt(t,e){t.$options.props;for(var n in e)t[n]=null==e[n]?_:b(e[n],t)}function Zt(t,e){for(var n in e){var r=e[n];if(Array.isArray(r))for(var i=0;i=0||n.indexOf(t[i])<0)&&r.push(t[i]);return r}return t}function _e(t){this._init(t)}function xe(t){t.use=function(t){var e=this._installedPlugins||(this._installedPlugins=[]);if(e.indexOf(t)>-1)return this;var n=g(arguments,1);return n.unshift(this),"function"==typeof t.install?t.install.apply(t,n):"function"==typeof t&&t.apply(null,n),e.push(t),this}}function ke(t){t.mixin=function(t){return this.options=Y(this.options,t),this}}function Ce(t){t.cid=0;var e=1;t.extend=function(t){t=t||{};var n=this,r=n.cid,i=t._Ctor||(t._Ctor={});if(i[r])return i[r];var o=t.name||n.options.name,s=function(t){this._init(t)};return s.prototype=Object.create(n.prototype),s.prototype.constructor=s,s.cid=e++,s.options=Y(n.options,t),s.super=n,s.options.props&&Oe(s),s.options.computed&&Ee(s),s.extend=n.extend,s.mixin=n.mixin,s.use=n.use,Ki.forEach(function(t){s[t]=n[t]}),o&&(s.options.components[o]=s),s.superOptions=n.options,s.extendOptions=t,s.sealedOptions=y({},s.options),i[r]=s,s}}function Oe(t){var e=t.options.props;for(var n in e)It(t.prototype,"_props",n)}function Ee(t){var e=t.options.computed;for(var n in e)Ft(t.prototype,n,e[n])}function Se(t){Ki.forEach(function(e){t[e]=function(t,n){return n?("component"===e&&c(n)&&(n.name=n.name||t,n=this.options._base.extend(n)),"directive"===e&&"function"==typeof n&&(n={bind:n,update:n}),this.options[e+"s"][t]=n,n):this.options[e+"s"][t]}})}function Ae(t){return t&&(t.Ctor.options.name||t.tag)}function je(t,e){return Array.isArray(t)?t.indexOf(e)>-1:"string"==typeof t?t.split(",").indexOf(e)>-1:!!l(t)&&t.test(e)}function Te(t,e,n){for(var r in t){var i=t[r];if(i){var o=Ae(i.componentOptions);o&&!n(o)&&(i!==e&&$e(i),t[r]=null)}}}function $e(t){t&&t.componentInstance.$destroy()}function Re(t){for(var e=t.data,n=t,i=t;r(i.componentInstance);)i=i.componentInstance._vnode,i.data&&(e=De(i.data,e));for(;r(n=n.parent);)n.data&&(e=De(e,n.data));return Le(e.staticClass,e.class)}function De(t,e){return{staticClass:Pe(t.staticClass,e.staticClass),class:r(t.class)?[t.class,e.class]:e.class}}function Le(t,e){return r(t)||r(e)?Pe(t,Ie(e)):""}function Pe(t,e){return t?e?t+" "+e:t:e||""}function Ie(t){return Array.isArray(t)?ze(t):a(t)?Be(t):"string"==typeof t?t:""}function ze(t){for(var e,n="",i=0,o=t.length;i-1?Cs[t]=e.constructor===window.HTMLUnknownElement||e.constructor===window.HTMLElement:Cs[t]=/HTMLUnknownElement/.test(e.toString())}function Ue(t){if("string"==typeof t){var e=document.querySelector(t);return e||document.createElement("div")}return t}function Fe(t,e){var n=document.createElement(t);return"select"!==t?n:(e.data&&e.data.attrs&&void 0!==e.data.attrs.multiple&&n.setAttribute("multiple","multiple"),n)}function He(t,e){return document.createElementNS(ys[t],e)}function We(t){return document.createTextNode(t)}function Ze(t){return document.createComment(t)}function Ye(t,e,n){t.insertBefore(e,n)}function qe(t,e){t.removeChild(e)}function Ve(t,e){t.appendChild(e)}function Ke(t){return t.parentNode}function Je(t){return t.nextSibling}function Ge(t){return t.tagName}function Xe(t,e){t.textContent=e}function Qe(t,e,n){t.setAttribute(e,n)}function tn(t,e){var n=t.data.ref;if(n){var r=t.context,i=t.componentInstance||t.elm,o=r.$refs;e?Array.isArray(o[n])?p(o[n],i):o[n]===i&&(o[n]=void 0):t.data.refInFor?Array.isArray(o[n])?o[n].indexOf(i)<0&&o[n].push(i):o[n]=[i]:o[n]=i}}function en(t,e){return t.key===e.key&&(t.tag===e.tag&&t.isComment===e.isComment&&r(t.data)===r(e.data)&&nn(t,e)||i(t.isAsyncPlaceholder)&&t.asyncFactory===e.asyncFactory&&n(e.asyncFactory.error))}function nn(t,e){if("input"!==t.tag)return!0;var n;return(r(n=t.data)&&r(n=n.attrs)&&n.type)===(r(n=e.data)&&r(n=n.attrs)&&n.type)}function rn(t,e,n){var i,o,s={};for(i=e;i<=n;++i)o=t[i].key,r(o)&&(s[o]=i);return s}function on(t,e){(t.data.directives||e.data.directives)&&sn(t,e)}function sn(t,e){var n,r,i,o=t===Ss,s=e===Ss,a=an(t.data.directives,t.context),c=an(e.data.directives,e.context),l=[],u=[];for(n in c)r=a[n],i=c[n],r?(i.oldValue=r.value,ln(i,"update",e,t),i.def&&i.def.componentUpdated&&u.push(i)):(ln(i,"bind",e,t),i.def&&i.def.inserted&&l.push(i));if(l.length){var f=function(){for(var n=0;n=0&&" "===(v=t.charAt(m));m--);v&&Ls.test(v)||(u=!0)}}else void 0===o?(p=i+1,o=t.slice(0,i).trim()):e();if(void 0===o?o=t.slice(0,i).trim():0!==p&&e(),s)for(i=0;i=es}function An(t){return 34===t||39===t}function jn(t){var e=1;for(os=is;!Sn();)if(t=En(),An(t))Tn(t);else if(91===t&&e++,93===t&&e--,0===e){ss=is;break}}function Tn(t){for(var e=t;!Sn()&&(t=En())!==e;);}function $n(t,e,n){as=n;var r=e.value,i=e.modifiers,o=t.tag,s=t.attrsMap.type;if(t.component)return kn(t,r,i),!1;if("select"===o)Ln(t,r,i);else if("input"===o&&"checkbox"===s)Rn(t,r,i);else if("input"===o&&"radio"===s)Dn(t,r,i);else if("input"===o||"textarea"===o)Pn(t,r,i);else if(!Gi.isReservedTag(o))return kn(t,r,i),!1;return!0}function Rn(t,e,n){var r=n&&n.number,i=_n(t,"value")||"null",o=_n(t,"true-value")||"true",s=_n(t,"false-value")||"false";bn(t,"checked","Array.isArray("+e+")?_i("+e+","+i+")>-1"+("true"===o?":("+e+")":":_q("+e+","+o+")")),wn(t,Is,"var $$a="+e+",$$el=$event.target,$$c=$$el.checked?("+o+"):("+s+");if(Array.isArray($$a)){var $$v="+(r?"_n("+i+")":i)+",$$i=_i($$a,$$v);if($$el.checked){$$i<0&&("+e+"=$$a.concat($$v))}else{$$i>-1&&("+e+"=$$a.slice(0,$$i).concat($$a.slice($$i+1)))}}else{"+Cn(e,"$$c")+"}",null,!0)}function Dn(t,e,n){var r=n&&n.number,i=_n(t,"value")||"null";i=r?"_n("+i+")":i,bn(t,"checked","_q("+e+","+i+")"),wn(t,Is,Cn(e,i),null,!0)}function Ln(t,e,n){var r=n&&n.number,i='Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = "_value" in o ? o._value : o.value;return '+(r?"_n(val)":"val")+"})",o="var $$selectedVal = "+i+";";o=o+" "+Cn(e,"$event.target.multiple ? $$selectedVal : $$selectedVal[0]"),wn(t,"change",o,null,!0)}function Pn(t,e,n){var r=t.attrsMap.type,i=n||{},o=i.lazy,s=i.number,a=i.trim,c=!o&&"range"!==r,l=o?"change":"range"===r?Ps:"input",u="$event.target.value";a&&(u="$event.target.value.trim()"),s&&(u="_n("+u+")");var f=Cn(e,u);c&&(f="if($event.target.composing)return;"+f),bn(t,"value","("+e+")"),wn(t,l,f,null,!0),(a||s)&&wn(t,"blur","$forceUpdate()")}function In(t){var e;r(t[Ps])&&(e=io?"change":"input",t[e]=[].concat(t[Ps],t[e]||[]),delete t[Ps]),r(t[Is])&&(e=lo?"click":"change",t[e]=[].concat(t[Is],t[e]||[]),delete t[Is])}function zn(t,e,n,r,i){if(n){var o=e,s=cs;e=function(n){null!==(1===arguments.length?o(n):o.apply(null,arguments))&&Bn(t,e,r,s)}}cs.addEventListener(t,e,fo?{capture:r,passive:i}:r)}function Bn(t,e,n,r){(r||cs).removeEventListener(t,e,n)}function Mn(t,e){if(!n(t.data.on)||!n(e.data.on)){var r=e.data.on||{},i=t.data.on||{};cs=e.elm,In(r),nt(r,i,zn,Bn,e.context)}}function Nn(t,e){if(!n(t.data.domProps)||!n(e.data.domProps)){var i,o,s=e.elm,a=t.data.domProps||{},c=e.data.domProps||{};r(c.__ob__)&&(c=e.data.domProps=y({},c));for(i in a)n(c[i])&&(s[i]="");for(i in c)if(o=c[i],"textContent"!==i&&"innerHTML"!==i||(e.children&&(e.children.length=0),o!==a[i]))if("value"===i){s._value=o;var l=n(o)?"":String(o);Un(s,e,l)&&(s.value=l)}else s[i]=o}}function Un(t,e,n){return!t.composing&&("option"===e.tag||Fn(t,n)||Hn(t,n))}function Fn(t,e){var n=!0;try{n=document.activeElement!==t}catch(t){}return n&&t.value!==e}function Hn(t,e){var n=t.value,i=t._vModifiers;return r(i)&&i.number?d(n)!==d(e):r(i)&&i.trim?n.trim()!==e.trim():n!==e}function Wn(t){var e=Zn(t.style);return t.staticStyle?y(t.staticStyle,e):e}function Zn(t){return Array.isArray(t)?w(t):"string"==typeof t?Ms(t):t}function Yn(t,e){var n,r={};if(e)for(var i=t;i.componentInstance;)i=i.componentInstance._vnode,i.data&&(n=Wn(i.data))&&y(r,n);(n=Wn(t.data))&&y(r,n);for(var o=t;o=o.parent;)o.data&&(n=Wn(o.data))&&y(r,n);return r}function qn(t,e){var i=e.data,o=t.data;if(!(n(i.staticStyle)&&n(i.style)&&n(o.staticStyle)&&n(o.style))){var s,a,c=e.elm,l=o.staticStyle,u=o.normalizedStyle||o.style||{},f=l||u,d=Zn(e.data.style)||{};e.data.normalizedStyle=r(d.__ob__)?y({},d):d;var h=Yn(e,!0);for(a in f)n(h[a])&&Fs(c,a,"");for(a in h)(s=h[a])!==f[a]&&Fs(c,a,null==s?"":s)}}function Vn(t,e){if(e&&(e=e.trim()))if(t.classList)e.indexOf(" ")>-1?e.split(/\s+/).forEach(function(e){return t.classList.add(e)}):t.classList.add(e);else{var n=" "+(t.getAttribute("class")||"")+" ";n.indexOf(" "+e+" ")<0&&t.setAttribute("class",(n+e).trim())}}function Kn(t,e){if(e&&(e=e.trim()))if(t.classList)e.indexOf(" ")>-1?e.split(/\s+/).forEach(function(e){return t.classList.remove(e)}):t.classList.remove(e),t.classList.length||t.removeAttribute("class");else{for(var n=" "+(t.getAttribute("class")||"")+" ",r=" "+e+" ";n.indexOf(r)>=0;)n=n.replace(r," ");n=n.trim(),n?t.setAttribute("class",n):t.removeAttribute("class")}}function Jn(t){if(t){if("object"==typeof t){var e={};return!1!==t.css&&y(e,Ys(t.name||"v")),y(e,t),e}return"string"==typeof t?Ys(t):void 0}}function Gn(t){ta(function(){ta(t)})}function Xn(t,e){var n=t._transitionClasses||(t._transitionClasses=[]);n.indexOf(e)<0&&(n.push(e),Vn(t,e))}function Qn(t,e){t._transitionClasses&&p(t._transitionClasses,e),Kn(t,e)}function tr(t,e,n){var r=er(t,e),i=r.type,o=r.timeout,s=r.propCount;if(!i)return n();var a=i===Vs?Gs:Qs,c=0,l=function(){t.removeEventListener(a,u),n()},u=function(e){e.target===t&&++c>=s&&l()};setTimeout(function(){c0&&(n=Vs,u=s,f=o.length):e===Ks?l>0&&(n=Ks,u=l,f=c.length):(u=Math.max(s,l),n=u>0?s>l?Vs:Ks:null,f=n?n===Vs?o.length:c.length:0),{type:n,timeout:u,propCount:f,hasTransform:n===Vs&&ea.test(r[Js+"Property"])}}function nr(t,e){for(;t.length1}function cr(t,e){!0!==e.data.show&&ir(e)}function lr(t,e,n){var r=e.value,i=t.multiple;if(!i||Array.isArray(r)){for(var o,s,a=0,c=t.options.length;a-1,s.selected!==o&&(s.selected=o);else if(x(ur(s),r))return void(t.selectedIndex!==a&&(t.selectedIndex=a));i||(t.selectedIndex=-1)}}function ur(t){return"_value"in t?t._value:t.value}function fr(t){t.target.composing=!0}function dr(t){t.target.composing&&(t.target.composing=!1,hr(t.target,"input"))}function hr(t,e){var n=document.createEvent("HTMLEvents");n.initEvent(e,!0,!0),t.dispatchEvent(n)}function pr(t){return!t.componentInstance||t.data&&t.data.transition?t:pr(t.componentInstance._vnode)}function mr(t){var e=t&&t.componentOptions;return e&&e.Ctor.options.abstract?mr(ht(e.children)):t}function vr(t){var e={},n=t.$options;for(var r in n.propsData)e[r]=t[r];var i=n._parentListeners;for(var o in i)e[Fi(o)]=i[o];return e}function br(t,e){if(/\d-keep-alive$/.test(e.tag))return t("keep-alive",{props:e.componentOptions.propsData})}function gr(t){for(;t=t.parent;)if(t.data.transition)return!0}function yr(t,e){return e.key===t.key&&e.tag===t.tag}function wr(t){return t.isComment&&t.asyncFactory}function _r(t){t.elm._moveCb&&t.elm._moveCb(),t.elm._enterCb&&t.elm._enterCb()}function xr(t){t.data.newPos=t.elm.getBoundingClientRect()}function kr(t){var e=t.data.pos,n=t.data.newPos,r=e.left-n.left,i=e.top-n.top;if(r||i){t.data.moved=!0;var o=t.elm.style;o.transform=o.WebkitTransform="translate("+r+"px,"+i+"px)",o.transitionDuration="0s"}}function Cr(t,e){var n=e?ya(e):ba;if(n.test(t)){for(var r,i,o=[],s=n.lastIndex=0;r=n.exec(t);){i=r.index,i>s&&o.push(JSON.stringify(t.slice(s,i)));var a=hn(r[1].trim());o.push("_s("+a+")"),s=i+r[0].length}return s=0&&s[i].lowerCasedTag!==a;i--);else i=0;if(i>=0){for(var c=s.length-1;c>=i;c--)e.end&&e.end(s[c].tag,n,r);s.length=i,o=i&&s[i-1].tag}else"br"===a?e.start&&e.start(t,[],!0,n,r):"p"===a&&(e.start&&e.start(t,[],!1,n,r),e.end&&e.end(t,n,r))}for(var i,o,s=[],a=e.expectHTML,c=e.isUnaryTag||Yi,l=e.canBeLeftOpenTag||Yi,u=0;t;){if(i=t,o&&Xa(o)){var f=0,d=o.toLowerCase(),h=Qa[d]||(Qa[d]=new RegExp("([\\s\\S]*?)(]*>)","i")),p=t.replace(h,function(t,n,r){return f=r.length,Xa(d)||"noscript"===d||(n=n.replace(//g,"$1").replace(//g,"$1")),ic(d,n)&&(n=n.slice(1)),e.chars&&e.chars(n),""});u+=t.length-p.length,t=p,r(d,u-f,u)}else{var m=t.indexOf("<");if(0===m){if(Ma.test(t)){var v=t.indexOf("--\x3e");if(v>=0){e.shouldKeepComment&&e.comment(t.substring(4,v)),n(v+3);continue}}if(Na.test(t)){var b=t.indexOf("]>");if(b>=0){n(b+2);continue}}var g=t.match(Ba);if(g){n(g[0].length);continue}var y=t.match(za);if(y){var w=u;n(y[0].length),r(y[1],w,u);continue}var _=function(){var e=t.match(Pa);if(e){var r={tagName:e[1],attrs:[],start:u};n(e[0].length);for(var i,o;!(i=t.match(Ia))&&(o=t.match(Ra));)n(o[0].length),r.attrs.push(o);if(i)return r.unarySlash=i[1],n(i[0].length),r.end=u,r}}();if(_){!function(t){var n=t.tagName,i=t.unarySlash;a&&("p"===o&&Ea(n)&&r(o),l(n)&&o===n&&r(n));for(var u=c(n)||!!i,f=t.attrs.length,d=new Array(f),h=0;h=0){for(k=t.slice(m);!(za.test(k)||Pa.test(k)||Ma.test(k)||Na.test(k)||(C=k.indexOf("<",1))<0);)m+=C,k=t.slice(m);x=t.substring(0,m),n(m)}m<0&&(x=t,t=""),e.chars&&x&&e.chars(x)}if(t===i){e.chars&&e.chars(t);break}}r()}function Dr(t,e){function n(t){t.pre&&(a=!1),qa(t.tag)&&(c=!1)}Fa=e.warn||mn,qa=e.isPreTag||Yi,Va=e.mustUseProp||Yi,Ka=e.getTagNamespace||Yi,Wa=vn(e.modules,"transformNode"),Za=vn(e.modules,"preTransformNode"),Ya=vn(e.modules,"postTransformNode"),Ha=e.delimiters;var r,i,o=[],s=!1!==e.preserveWhitespace,a=!1,c=!1;return Rr(t,{warn:Fa,expectHTML:e.expectHTML,isUnaryTag:e.isUnaryTag,canBeLeftOpenTag:e.canBeLeftOpenTag,shouldDecodeNewlines:e.shouldDecodeNewlines,shouldKeepComment:e.comments,start:function(t,s,l){var u=i&&i.ns||Ka(t);io&&"svg"===u&&(s=Xr(s));var f={type:1,tag:t,attrsList:s,attrsMap:Kr(s),parent:i,children:[]};u&&(f.ns=u),Gr(f)&&!vo()&&(f.forbidden=!0);for(var d=0;d0,so=ro&&ro.indexOf("edge/")>0,ao=ro&&ro.indexOf("android")>0,co=ro&&/iphone|ipad|ipod|ios/.test(ro),lo=ro&&/chrome\/\d+/.test(ro)&&!so,uo={}.watch,fo=!1;if(no)try{var ho={};Object.defineProperty(ho,"passive",{get:function(){fo=!0}}),window.addEventListener("test-passive",null,ho)}catch(t){}var po,mo,vo=function(){return void 0===po&&(po=!no&&void 0!==t&&"server"===t.process.env.VUE_ENV),po},bo=no&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__,go="undefined"!=typeof Symbol&&j(Symbol)&&"undefined"!=typeof Reflect&&j(Reflect.ownKeys),yo=function(){function t(){r=!1;var t=n.slice(0);n.length=0;for(var e=0;e1?g(n):n;for(var r=g(arguments,1),i=0,o=n.length;i1&&(e[n[0].trim()]=n[1].trim())}}),e}),Ns=/^--/,Us=/\s*!important$/,Fs=function(t,e,n){if(Ns.test(e))t.style.setProperty(e,n);else if(Us.test(n))t.style.setProperty(e,n.replace(Us,""),"important");else{var r=Ws(e);if(Array.isArray(n))for(var i=0,o=n.length;ip?(f=n(i[b+1])?null:i[b+1].elm,g(t,f,i,h,b,o)):h>b&&w(t,e,d,p)}function k(t,e,o,s){if(t!==e){var a=e.elm=t.elm;if(i(t.isAsyncPlaceholder))return void(r(e.asyncFactory.resolved)?O(t.elm,e,o):e.isAsyncPlaceholder=!0);if(i(e.isStatic)&&i(t.isStatic)&&e.key===t.key&&(i(e.isCloned)||i(e.isOnce)))return void(e.componentInstance=t.componentInstance);var c,l=e.data;r(l)&&r(c=l.hook)&&r(c=c.prepatch)&&c(t,e);var u=t.children,f=e.children;if(r(l)&&m(e)){for(c=0;c',n.innerHTML.indexOf(e)>0}("\n"," "),ba=/\{\{((?:.|\n)+?)\}\}/g,ga=/[-.*+?^${}()|[\]\/\\]/g,ya=v(function(t){var e=t[0].replace(ga,"\\$&"),n=t[1].replace(ga,"\\$&");return new RegExp(e+"((?:.|\\n)+?)"+n,"g")}),wa={staticKeys:["staticClass"],transformNode:Or,genData:Er},_a={staticKeys:["staticStyle"],transformNode:Sr,genData:Ar},xa=[wa,_a],ka={model:$n,text:jr,html:Tr},Ca=h("area,base,br,col,embed,frame,hr,img,input,isindex,keygen,link,meta,param,source,track,wbr"),Oa=h("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source"),Ea=h("address,article,aside,base,blockquote,body,caption,col,colgroup,dd,details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,title,tr,track"),Sa={expectHTML:!0,modules:xa,directives:ka,isPreTag:xs,isUnaryTag:Ca,mustUseProp:ds,canBeLeftOpenTag:Oa,isReservedTag:ks,getTagNamespace:Me,staticKeys:function(t){return t.reduce(function(t,e){return t.concat(e.staticKeys||[])},[]).join(",")}(xa)},Aa={decode:function(t){return ma=ma||document.createElement("div"),ma.innerHTML=t,ma.textContent}},ja=/([^\s"'<>\/=]+)/,Ta=/(?:=)/,$a=[/"([^"]*)"+/.source,/'([^']*)'+/.source,/([^\s"'=<>`]+)/.source],Ra=new RegExp("^\\s*"+ja.source+"(?:\\s*("+Ta.source+")\\s*(?:"+$a.join("|")+"))?"),Da="[a-zA-Z_][\\w\\-\\.]*",La="((?:"+Da+"\\:)?"+Da+")",Pa=new RegExp("^<"+La),Ia=/^\s*(\/?)>/,za=new RegExp("^<\\/"+La+"[^>]*>"),Ba=/^]+>/i,Ma=/^/g,"$1").replace(//g,"$1")),ic(d,n)&&(n=n.slice(1)),e.chars&&e.chars(n),""});u+=t.length-p.length,t=p,r(d,u-f,u)}else{var m=t.indexOf("<");if(0===m){if(Ba.test(t)){var v=t.indexOf("--\x3e");if(v>=0){e.shouldKeepComment&&e.comment(t.substring(4,v)),n(v+3);continue}}if(Na.test(t)){var b=t.indexOf("]>");if(b>=0){n(b+2);continue}}var g=t.match(Ma);if(g){n(g[0].length);continue}var y=t.match(za);if(y){var w=u;n(y[0].length),r(y[1],w,u);continue}var _=function(){var e=t.match(Pa);if(e){var r={tagName:e[1],attrs:[],start:u};n(e[0].length);for(var i,o;!(i=t.match(Ia))&&(o=t.match(Ra));)n(o[0].length),r.attrs.push(o);if(i)return r.unarySlash=i[1],n(i[0].length),r.end=u,r}}();if(_){!function(t){var n=t.tagName,i=t.unarySlash;a&&("p"===o&&Ea(n)&&r(o),l(n)&&o===n&&r(n));for(var u=c(n)||!!i,f=t.attrs.length,d=new Array(f),h=0;h=0){for(k=t.slice(m);!(za.test(k)||Pa.test(k)||Ba.test(k)||Na.test(k)||(C=k.indexOf("<",1))<0);)m+=C,k=t.slice(m);x=t.substring(0,m),n(m)}m<0&&(x=t,t=""),e.chars&&x&&e.chars(x)}if(t===i){e.chars&&e.chars(t);break}}r()}function Dr(t,e){function n(t){t.pre&&(a=!1),qa(t.tag)&&(c=!1)}Fa=e.warn||mn,qa=e.isPreTag||Yi,Va=e.mustUseProp||Yi,Ka=e.getTagNamespace||Yi,Wa=vn(e.modules,"transformNode"),Za=vn(e.modules,"preTransformNode"),Ya=vn(e.modules,"postTransformNode"),Ha=e.delimiters;var r,i,o=[],s=!1!==e.preserveWhitespace,a=!1,c=!1;return Rr(t,{warn:Fa,expectHTML:e.expectHTML,isUnaryTag:e.isUnaryTag,canBeLeftOpenTag:e.canBeLeftOpenTag,shouldDecodeNewlines:e.shouldDecodeNewlines,shouldKeepComment:e.comments,start:function(t,s,l){var u=i&&i.ns||Ka(t);io&&"svg"===u&&(s=Xr(s));var f={type:1,tag:t,attrsList:s,attrsMap:Kr(s),parent:i,children:[]};u&&(f.ns=u),Gr(f)&&!vo()&&(f.forbidden=!0);for(var d=0;d0,so=ro&&ro.indexOf("edge/")>0,ao=ro&&ro.indexOf("android")>0,co=ro&&/iphone|ipad|ipod|ios/.test(ro),lo=ro&&/chrome\/\d+/.test(ro)&&!so,uo={}.watch,fo=!1;if(no)try{var ho={};Object.defineProperty(ho,"passive",{get:function(){fo=!0}}),window.addEventListener("test-passive",null,ho)}catch(t){}var po,mo,vo=function(){return void 0===po&&(po=!no&&void 0!==t&&"server"===t.process.env.VUE_ENV),po},bo=no&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__,go="undefined"!=typeof Symbol&&j(Symbol)&&"undefined"!=typeof Reflect&&j(Reflect.ownKeys),yo=function(){function t(){r=!1;var t=n.slice(0);n.length=0;for(var e=0;e1?g(n):n;for(var r=g(arguments,1),i=0,o=n.length;i1&&(e[n[0].trim()]=n[1].trim())}}),e}),Ns=/^--/,Us=/\s*!important$/,Fs=function(t,e,n){if(Ns.test(e))t.style.setProperty(e,n);else if(Us.test(n))t.style.setProperty(e,n.replace(Us,""),"important");else{var r=Ws(e);if(Array.isArray(n))for(var i=0,o=n.length;ip?(f=n(i[b+1])?null:i[b+1].elm,g(t,f,i,h,b,o)):h>b&&w(t,e,d,p)}function k(t,e,o,s){if(t!==e){var a=e.elm=t.elm;if(i(t.isAsyncPlaceholder))return void(r(e.asyncFactory.resolved)?O(t.elm,e,o):e.isAsyncPlaceholder=!0);if(i(e.isStatic)&&i(t.isStatic)&&e.key===t.key&&(i(e.isCloned)||i(e.isOnce)))return void(e.componentInstance=t.componentInstance);var c,l=e.data;r(l)&&r(c=l.hook)&&r(c=c.prepatch)&&c(t,e);var u=t.children,f=e.children;if(r(l)&&m(e)){for(c=0;c',n.innerHTML.indexOf(e)>0}("\n"," "),ba=/\{\{((?:.|\n)+?)\}\}/g,ga=/[-.*+?^${}()|[\]\/\\]/g,ya=v(function(t){var e=t[0].replace(ga,"\\$&"),n=t[1].replace(ga,"\\$&");return new RegExp(e+"((?:.|\\n)+?)"+n,"g")}),wa={staticKeys:["staticClass"],transformNode:Or,genData:Er},_a={staticKeys:["staticStyle"],transformNode:Sr,genData:Ar},xa=[wa,_a],ka={model:$n,text:jr,html:Tr},Ca=h("area,base,br,col,embed,frame,hr,img,input,isindex,keygen,link,meta,param,source,track,wbr"),Oa=h("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source"),Ea=h("address,article,aside,base,blockquote,body,caption,col,colgroup,dd,details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,title,tr,track"),Sa={expectHTML:!0,modules:xa,directives:ka,isPreTag:xs,isUnaryTag:Ca,mustUseProp:ds,canBeLeftOpenTag:Oa,isReservedTag:ks,getTagNamespace:Be,staticKeys:function(t){return t.reduce(function(t,e){return t.concat(e.staticKeys||[])},[]).join(",")}(xa)},Aa={decode:function(t){return ma=ma||document.createElement("div"),ma.innerHTML=t,ma.textContent}},ja=/([^\s"'<>\/=]+)/,Ta=/(?:=)/,$a=[/"([^"]*)"+/.source,/'([^']*)'+/.source,/([^\s"'=<>`]+)/.source],Ra=new RegExp("^\\s*"+ja.source+"(?:\\s*("+Ta.source+")\\s*(?:"+$a.join("|")+"))?"),Da="[a-zA-Z_][\\w\\-\\.]*",La="((?:"+Da+"\\:)?"+Da+")",Pa=new RegExp("^<"+La),Ia=/^\s*(\/?)>/,za=new RegExp("^<\\/"+La+"[^>]*>"),Ma=/^]+>/i,Ba=/^ ' : repeat(' ', 5 + i * 2)) + (Array.isArray(vm)\n ? ((formatComponentName(vm[0])) + \"... (\" + (vm[1]) + \" recursive calls)\")\n : formatComponentName(vm))); })\n .join('\\n')\n } else {\n return (\"\\n\\n(found in \" + (formatComponentName(vm)) + \")\")\n }\n };\n}\n\n/* */\n\nfunction handleError (err, vm, info) {\n if (config.errorHandler) {\n config.errorHandler.call(null, err, vm, info);\n } else {\n if (false) {\n warn((\"Error in \" + info + \": \\\"\" + (err.toString()) + \"\\\"\"), vm);\n }\n /* istanbul ignore else */\n if (inBrowser && typeof console !== 'undefined') {\n console.error(err);\n } else {\n throw err\n }\n }\n}\n\n/* */\n/* globals MutationObserver */\n\n// can we use __proto__?\nvar hasProto = '__proto__' in {};\n\n// Browser environment sniffing\nvar inBrowser = typeof window !== 'undefined';\nvar UA = inBrowser && window.navigator.userAgent.toLowerCase();\nvar isIE = UA && /msie|trident/.test(UA);\nvar isIE9 = UA && UA.indexOf('msie 9.0') > 0;\nvar isEdge = UA && UA.indexOf('edge/') > 0;\nvar isAndroid = UA && UA.indexOf('android') > 0;\nvar isIOS = UA && /iphone|ipad|ipod|ios/.test(UA);\nvar isChrome = UA && /chrome\\/\\d+/.test(UA) && !isEdge;\n\n// Firefix has a \"watch\" function on Object.prototype...\nvar nativeWatch = ({}).watch;\n\nvar supportsPassive = false;\nif (inBrowser) {\n try {\n var opts = {};\n Object.defineProperty(opts, 'passive', ({\n get: function get () {\n /* istanbul ignore next */\n supportsPassive = true;\n }\n })); // https://github.com/facebook/flow/issues/285\n window.addEventListener('test-passive', null, opts);\n } catch (e) {}\n}\n\n// this needs to be lazy-evaled because vue may be required before\n// vue-server-renderer can set VUE_ENV\nvar _isServer;\nvar isServerRendering = function () {\n if (_isServer === undefined) {\n /* istanbul ignore if */\n if (!inBrowser && typeof global !== 'undefined') {\n // detect presence of vue-server-renderer and avoid\n // Webpack shimming the process\n _isServer = global['process'].env.VUE_ENV === 'server';\n } else {\n _isServer = false;\n }\n }\n return _isServer\n};\n\n// detect devtools\nvar devtools = inBrowser && window.__VUE_DEVTOOLS_GLOBAL_HOOK__;\n\n/* istanbul ignore next */\nfunction isNative (Ctor) {\n return typeof Ctor === 'function' && /native code/.test(Ctor.toString())\n}\n\nvar hasSymbol =\n typeof Symbol !== 'undefined' && isNative(Symbol) &&\n typeof Reflect !== 'undefined' && isNative(Reflect.ownKeys);\n\n/**\n * Defer a task to execute it asynchronously.\n */\nvar nextTick = (function () {\n var callbacks = [];\n var pending = false;\n var timerFunc;\n\n function nextTickHandler () {\n pending = false;\n var copies = callbacks.slice(0);\n callbacks.length = 0;\n for (var i = 0; i < copies.length; i++) {\n copies[i]();\n }\n }\n\n // the nextTick behavior leverages the microtask queue, which can be accessed\n // via either native Promise.then or MutationObserver.\n // MutationObserver has wider support, however it is seriously bugged in\n // UIWebView in iOS >= 9.3.3 when triggered in touch event handlers. It\n // completely stops working after triggering a few times... so, if native\n // Promise is available, we will use it:\n /* istanbul ignore if */\n if (typeof Promise !== 'undefined' && isNative(Promise)) {\n var p = Promise.resolve();\n var logError = function (err) { console.error(err); };\n timerFunc = function () {\n p.then(nextTickHandler).catch(logError);\n // in problematic UIWebViews, Promise.then doesn't completely break, but\n // it can get stuck in a weird state where callbacks are pushed into the\n // microtask queue but the queue isn't being flushed, until the browser\n // needs to do some other work, e.g. handle a timer. Therefore we can\n // \"force\" the microtask queue to be flushed by adding an empty timer.\n if (isIOS) { setTimeout(noop); }\n };\n } else if (typeof MutationObserver !== 'undefined' && (\n isNative(MutationObserver) ||\n // PhantomJS and iOS 7.x\n MutationObserver.toString() === '[object MutationObserverConstructor]'\n )) {\n // use MutationObserver where native Promise is not available,\n // e.g. PhantomJS IE11, iOS7, Android 4.4\n var counter = 1;\n var observer = new MutationObserver(nextTickHandler);\n var textNode = document.createTextNode(String(counter));\n observer.observe(textNode, {\n characterData: true\n });\n timerFunc = function () {\n counter = (counter + 1) % 2;\n textNode.data = String(counter);\n };\n } else {\n // fallback to setTimeout\n /* istanbul ignore next */\n timerFunc = function () {\n setTimeout(nextTickHandler, 0);\n };\n }\n\n return function queueNextTick (cb, ctx) {\n var _resolve;\n callbacks.push(function () {\n if (cb) {\n try {\n cb.call(ctx);\n } catch (e) {\n handleError(e, ctx, 'nextTick');\n }\n } else if (_resolve) {\n _resolve(ctx);\n }\n });\n if (!pending) {\n pending = true;\n timerFunc();\n }\n if (!cb && typeof Promise !== 'undefined') {\n return new Promise(function (resolve, reject) {\n _resolve = resolve;\n })\n }\n }\n})();\n\nvar _Set;\n/* istanbul ignore if */\nif (typeof Set !== 'undefined' && isNative(Set)) {\n // use native Set when available.\n _Set = Set;\n} else {\n // a non-standard Set polyfill that only works with primitive keys.\n _Set = (function () {\n function Set () {\n this.set = Object.create(null);\n }\n Set.prototype.has = function has (key) {\n return this.set[key] === true\n };\n Set.prototype.add = function add (key) {\n this.set[key] = true;\n };\n Set.prototype.clear = function clear () {\n this.set = Object.create(null);\n };\n\n return Set;\n }());\n}\n\n/* */\n\n\nvar uid = 0;\n\n/**\n * A dep is an observable that can have multiple\n * directives subscribing to it.\n */\nvar Dep = function Dep () {\n this.id = uid++;\n this.subs = [];\n};\n\nDep.prototype.addSub = function addSub (sub) {\n this.subs.push(sub);\n};\n\nDep.prototype.removeSub = function removeSub (sub) {\n remove(this.subs, sub);\n};\n\nDep.prototype.depend = function depend () {\n if (Dep.target) {\n Dep.target.addDep(this);\n }\n};\n\nDep.prototype.notify = function notify () {\n // stabilize the subscriber list first\n var subs = this.subs.slice();\n for (var i = 0, l = subs.length; i < l; i++) {\n subs[i].update();\n }\n};\n\n// the current target watcher being evaluated.\n// this is globally unique because there could be only one\n// watcher being evaluated at any time.\nDep.target = null;\nvar targetStack = [];\n\nfunction pushTarget (_target) {\n if (Dep.target) { targetStack.push(Dep.target); }\n Dep.target = _target;\n}\n\nfunction popTarget () {\n Dep.target = targetStack.pop();\n}\n\n/*\n * not type checking this file because flow doesn't play well with\n * dynamically accessing methods on Array prototype\n */\n\nvar arrayProto = Array.prototype;\nvar arrayMethods = Object.create(arrayProto);[\n 'push',\n 'pop',\n 'shift',\n 'unshift',\n 'splice',\n 'sort',\n 'reverse'\n]\n.forEach(function (method) {\n // cache original method\n var original = arrayProto[method];\n def(arrayMethods, method, function mutator () {\n var args = [], len = arguments.length;\n while ( len-- ) args[ len ] = arguments[ len ];\n\n var result = original.apply(this, args);\n var ob = this.__ob__;\n var inserted;\n switch (method) {\n case 'push':\n case 'unshift':\n inserted = args;\n break\n case 'splice':\n inserted = args.slice(2);\n break\n }\n if (inserted) { ob.observeArray(inserted); }\n // notify change\n ob.dep.notify();\n return result\n });\n});\n\n/* */\n\nvar arrayKeys = Object.getOwnPropertyNames(arrayMethods);\n\n/**\n * By default, when a reactive property is set, the new value is\n * also converted to become reactive. However when passing down props,\n * we don't want to force conversion because the value may be a nested value\n * under a frozen data structure. Converting it would defeat the optimization.\n */\nvar observerState = {\n shouldConvert: true\n};\n\n/**\n * Observer class that are attached to each observed\n * object. Once attached, the observer converts target\n * object's property keys into getter/setters that\n * collect dependencies and dispatches updates.\n */\nvar Observer = function Observer (value) {\n this.value = value;\n this.dep = new Dep();\n this.vmCount = 0;\n def(value, '__ob__', this);\n if (Array.isArray(value)) {\n var augment = hasProto\n ? protoAugment\n : copyAugment;\n augment(value, arrayMethods, arrayKeys);\n this.observeArray(value);\n } else {\n this.walk(value);\n }\n};\n\n/**\n * Walk through each property and convert them into\n * getter/setters. This method should only be called when\n * value type is Object.\n */\nObserver.prototype.walk = function walk (obj) {\n var keys = Object.keys(obj);\n for (var i = 0; i < keys.length; i++) {\n defineReactive$$1(obj, keys[i], obj[keys[i]]);\n }\n};\n\n/**\n * Observe a list of Array items.\n */\nObserver.prototype.observeArray = function observeArray (items) {\n for (var i = 0, l = items.length; i < l; i++) {\n observe(items[i]);\n }\n};\n\n// helpers\n\n/**\n * Augment an target Object or Array by intercepting\n * the prototype chain using __proto__\n */\nfunction protoAugment (target, src, keys) {\n /* eslint-disable no-proto */\n target.__proto__ = src;\n /* eslint-enable no-proto */\n}\n\n/**\n * Augment an target Object or Array by defining\n * hidden properties.\n */\n/* istanbul ignore next */\nfunction copyAugment (target, src, keys) {\n for (var i = 0, l = keys.length; i < l; i++) {\n var key = keys[i];\n def(target, key, src[key]);\n }\n}\n\n/**\n * Attempt to create an observer instance for a value,\n * returns the new observer if successfully observed,\n * or the existing observer if the value already has one.\n */\nfunction observe (value, asRootData) {\n if (!isObject(value)) {\n return\n }\n var ob;\n if (hasOwn(value, '__ob__') && value.__ob__ instanceof Observer) {\n ob = value.__ob__;\n } else if (\n observerState.shouldConvert &&\n !isServerRendering() &&\n (Array.isArray(value) || isPlainObject(value)) &&\n Object.isExtensible(value) &&\n !value._isVue\n ) {\n ob = new Observer(value);\n }\n if (asRootData && ob) {\n ob.vmCount++;\n }\n return ob\n}\n\n/**\n * Define a reactive property on an Object.\n */\nfunction defineReactive$$1 (\n obj,\n key,\n val,\n customSetter,\n shallow\n) {\n var dep = new Dep();\n\n var property = Object.getOwnPropertyDescriptor(obj, key);\n if (property && property.configurable === false) {\n return\n }\n\n // cater for pre-defined getter/setters\n var getter = property && property.get;\n var setter = property && property.set;\n\n var childOb = !shallow && observe(val);\n Object.defineProperty(obj, key, {\n enumerable: true,\n configurable: true,\n get: function reactiveGetter () {\n var value = getter ? getter.call(obj) : val;\n if (Dep.target) {\n dep.depend();\n if (childOb) {\n childOb.dep.depend();\n }\n if (Array.isArray(value)) {\n dependArray(value);\n }\n }\n return value\n },\n set: function reactiveSetter (newVal) {\n var value = getter ? getter.call(obj) : val;\n /* eslint-disable no-self-compare */\n if (newVal === value || (newVal !== newVal && value !== value)) {\n return\n }\n /* eslint-enable no-self-compare */\n if (false) {\n customSetter();\n }\n if (setter) {\n setter.call(obj, newVal);\n } else {\n val = newVal;\n }\n childOb = !shallow && observe(newVal);\n dep.notify();\n }\n });\n}\n\n/**\n * Set a property on an object. Adds the new property and\n * triggers change notification if the property doesn't\n * already exist.\n */\nfunction set (target, key, val) {\n if (Array.isArray(target) && isValidArrayIndex(key)) {\n target.length = Math.max(target.length, key);\n target.splice(key, 1, val);\n return val\n }\n if (hasOwn(target, key)) {\n target[key] = val;\n return val\n }\n var ob = (target).__ob__;\n if (target._isVue || (ob && ob.vmCount)) {\n \"production\" !== 'production' && warn(\n 'Avoid adding reactive properties to a Vue instance or its root $data ' +\n 'at runtime - declare it upfront in the data option.'\n );\n return val\n }\n if (!ob) {\n target[key] = val;\n return val\n }\n defineReactive$$1(ob.value, key, val);\n ob.dep.notify();\n return val\n}\n\n/**\n * Delete a property and trigger change if necessary.\n */\nfunction del (target, key) {\n if (Array.isArray(target) && isValidArrayIndex(key)) {\n target.splice(key, 1);\n return\n }\n var ob = (target).__ob__;\n if (target._isVue || (ob && ob.vmCount)) {\n \"production\" !== 'production' && warn(\n 'Avoid deleting properties on a Vue instance or its root $data ' +\n '- just set it to null.'\n );\n return\n }\n if (!hasOwn(target, key)) {\n return\n }\n delete target[key];\n if (!ob) {\n return\n }\n ob.dep.notify();\n}\n\n/**\n * Collect dependencies on array elements when the array is touched, since\n * we cannot intercept array element access like property getters.\n */\nfunction dependArray (value) {\n for (var e = (void 0), i = 0, l = value.length; i < l; i++) {\n e = value[i];\n e && e.__ob__ && e.__ob__.dep.depend();\n if (Array.isArray(e)) {\n dependArray(e);\n }\n }\n}\n\n/* */\n\n/**\n * Option overwriting strategies are functions that handle\n * how to merge a parent option value and a child option\n * value into the final value.\n */\nvar strats = config.optionMergeStrategies;\n\n/**\n * Options with restrictions\n */\nif (false) {\n strats.el = strats.propsData = function (parent, child, vm, key) {\n if (!vm) {\n warn(\n \"option \\\"\" + key + \"\\\" can only be used during instance \" +\n 'creation with the `new` keyword.'\n );\n }\n return defaultStrat(parent, child)\n };\n}\n\n/**\n * Helper that recursively merges two data objects together.\n */\nfunction mergeData (to, from) {\n if (!from) { return to }\n var key, toVal, fromVal;\n var keys = Object.keys(from);\n for (var i = 0; i < keys.length; i++) {\n key = keys[i];\n toVal = to[key];\n fromVal = from[key];\n if (!hasOwn(to, key)) {\n set(to, key, fromVal);\n } else if (isPlainObject(toVal) && isPlainObject(fromVal)) {\n mergeData(toVal, fromVal);\n }\n }\n return to\n}\n\n/**\n * Data\n */\nfunction mergeDataOrFn (\n parentVal,\n childVal,\n vm\n) {\n if (!vm) {\n // in a Vue.extend merge, both should be functions\n if (!childVal) {\n return parentVal\n }\n if (!parentVal) {\n return childVal\n }\n // when parentVal & childVal are both present,\n // we need to return a function that returns the\n // merged result of both functions... no need to\n // check if parentVal is a function here because\n // it has to be a function to pass previous merges.\n return function mergedDataFn () {\n return mergeData(\n typeof childVal === 'function' ? childVal.call(this) : childVal,\n typeof parentVal === 'function' ? parentVal.call(this) : parentVal\n )\n }\n } else if (parentVal || childVal) {\n return function mergedInstanceDataFn () {\n // instance merge\n var instanceData = typeof childVal === 'function'\n ? childVal.call(vm)\n : childVal;\n var defaultData = typeof parentVal === 'function'\n ? parentVal.call(vm)\n : undefined;\n if (instanceData) {\n return mergeData(instanceData, defaultData)\n } else {\n return defaultData\n }\n }\n }\n}\n\nstrats.data = function (\n parentVal,\n childVal,\n vm\n) {\n if (!vm) {\n if (childVal && typeof childVal !== 'function') {\n \"production\" !== 'production' && warn(\n 'The \"data\" option should be a function ' +\n 'that returns a per-instance value in component ' +\n 'definitions.',\n vm\n );\n\n return parentVal\n }\n return mergeDataOrFn.call(this, parentVal, childVal)\n }\n\n return mergeDataOrFn(parentVal, childVal, vm)\n};\n\n/**\n * Hooks and props are merged as arrays.\n */\nfunction mergeHook (\n parentVal,\n childVal\n) {\n return childVal\n ? parentVal\n ? parentVal.concat(childVal)\n : Array.isArray(childVal)\n ? childVal\n : [childVal]\n : parentVal\n}\n\nLIFECYCLE_HOOKS.forEach(function (hook) {\n strats[hook] = mergeHook;\n});\n\n/**\n * Assets\n *\n * When a vm is present (instance creation), we need to do\n * a three-way merge between constructor options, instance\n * options and parent options.\n */\nfunction mergeAssets (parentVal, childVal) {\n var res = Object.create(parentVal || null);\n return childVal\n ? extend(res, childVal)\n : res\n}\n\nASSET_TYPES.forEach(function (type) {\n strats[type + 's'] = mergeAssets;\n});\n\n/**\n * Watchers.\n *\n * Watchers hashes should not overwrite one\n * another, so we merge them as arrays.\n */\nstrats.watch = function (parentVal, childVal) {\n // work around Firefox's Object.prototype.watch...\n if (parentVal === nativeWatch) { parentVal = undefined; }\n if (childVal === nativeWatch) { childVal = undefined; }\n /* istanbul ignore if */\n if (!childVal) { return Object.create(parentVal || null) }\n if (!parentVal) { return childVal }\n var ret = {};\n extend(ret, parentVal);\n for (var key in childVal) {\n var parent = ret[key];\n var child = childVal[key];\n if (parent && !Array.isArray(parent)) {\n parent = [parent];\n }\n ret[key] = parent\n ? parent.concat(child)\n : Array.isArray(child) ? child : [child];\n }\n return ret\n};\n\n/**\n * Other object hashes.\n */\nstrats.props =\nstrats.methods =\nstrats.inject =\nstrats.computed = function (parentVal, childVal) {\n if (!parentVal) { return childVal }\n var ret = Object.create(null);\n extend(ret, parentVal);\n if (childVal) { extend(ret, childVal); }\n return ret\n};\nstrats.provide = mergeDataOrFn;\n\n/**\n * Default strategy.\n */\nvar defaultStrat = function (parentVal, childVal) {\n return childVal === undefined\n ? parentVal\n : childVal\n};\n\n/**\n * Validate component names\n */\nfunction checkComponents (options) {\n for (var key in options.components) {\n var lower = key.toLowerCase();\n if (isBuiltInTag(lower) || config.isReservedTag(lower)) {\n warn(\n 'Do not use built-in or reserved HTML elements as component ' +\n 'id: ' + key\n );\n }\n }\n}\n\n/**\n * Ensure all props option syntax are normalized into the\n * Object-based format.\n */\nfunction normalizeProps (options) {\n var props = options.props;\n if (!props) { return }\n var res = {};\n var i, val, name;\n if (Array.isArray(props)) {\n i = props.length;\n while (i--) {\n val = props[i];\n if (typeof val === 'string') {\n name = camelize(val);\n res[name] = { type: null };\n } else if (false) {\n warn('props must be strings when using array syntax.');\n }\n }\n } else if (isPlainObject(props)) {\n for (var key in props) {\n val = props[key];\n name = camelize(key);\n res[name] = isPlainObject(val)\n ? val\n : { type: val };\n }\n }\n options.props = res;\n}\n\n/**\n * Normalize all injections into Object-based format\n */\nfunction normalizeInject (options) {\n var inject = options.inject;\n if (Array.isArray(inject)) {\n var normalized = options.inject = {};\n for (var i = 0; i < inject.length; i++) {\n normalized[inject[i]] = inject[i];\n }\n }\n}\n\n/**\n * Normalize raw function directives into object format.\n */\nfunction normalizeDirectives (options) {\n var dirs = options.directives;\n if (dirs) {\n for (var key in dirs) {\n var def = dirs[key];\n if (typeof def === 'function') {\n dirs[key] = { bind: def, update: def };\n }\n }\n }\n}\n\n/**\n * Merge two option objects into a new one.\n * Core utility used in both instantiation and inheritance.\n */\nfunction mergeOptions (\n parent,\n child,\n vm\n) {\n if (false) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child);\n normalizeInject(child);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}\n\n/**\n * Resolve an asset.\n * This function is used because child instances need access\n * to assets defined in its ancestor chain.\n */\nfunction resolveAsset (\n options,\n type,\n id,\n warnMissing\n) {\n /* istanbul ignore if */\n if (typeof id !== 'string') {\n return\n }\n var assets = options[type];\n // check local registration variations first\n if (hasOwn(assets, id)) { return assets[id] }\n var camelizedId = camelize(id);\n if (hasOwn(assets, camelizedId)) { return assets[camelizedId] }\n var PascalCaseId = capitalize(camelizedId);\n if (hasOwn(assets, PascalCaseId)) { return assets[PascalCaseId] }\n // fallback to prototype chain\n var res = assets[id] || assets[camelizedId] || assets[PascalCaseId];\n if (false) {\n warn(\n 'Failed to resolve ' + type.slice(0, -1) + ': ' + id,\n options\n );\n }\n return res\n}\n\n/* */\n\nfunction validateProp (\n key,\n propOptions,\n propsData,\n vm\n) {\n var prop = propOptions[key];\n var absent = !hasOwn(propsData, key);\n var value = propsData[key];\n // handle boolean props\n if (isType(Boolean, prop.type)) {\n if (absent && !hasOwn(prop, 'default')) {\n value = false;\n } else if (!isType(String, prop.type) && (value === '' || value === hyphenate(key))) {\n value = true;\n }\n }\n // check default value\n if (value === undefined) {\n value = getPropDefaultValue(vm, prop, key);\n // since the default value is a fresh copy,\n // make sure to observe it.\n var prevShouldConvert = observerState.shouldConvert;\n observerState.shouldConvert = true;\n observe(value);\n observerState.shouldConvert = prevShouldConvert;\n }\n if (false) {\n assertProp(prop, key, value, vm, absent);\n }\n return value\n}\n\n/**\n * Get the default value of a prop.\n */\nfunction getPropDefaultValue (vm, prop, key) {\n // no default, return undefined\n if (!hasOwn(prop, 'default')) {\n return undefined\n }\n var def = prop.default;\n // warn against non-factory defaults for Object & Array\n if (false) {\n warn(\n 'Invalid default value for prop \"' + key + '\": ' +\n 'Props with type Object/Array must use a factory function ' +\n 'to return the default value.',\n vm\n );\n }\n // the raw prop value was also undefined from previous render,\n // return previous default value to avoid unnecessary watcher trigger\n if (vm && vm.$options.propsData &&\n vm.$options.propsData[key] === undefined &&\n vm._props[key] !== undefined\n ) {\n return vm._props[key]\n }\n // call factory function for non-Function types\n // a value is Function if its prototype is function even across different execution context\n return typeof def === 'function' && getType(prop.type) !== 'Function'\n ? def.call(vm)\n : def\n}\n\n/**\n * Assert whether a prop is valid.\n */\nfunction assertProp (\n prop,\n name,\n value,\n vm,\n absent\n) {\n if (prop.required && absent) {\n warn(\n 'Missing required prop: \"' + name + '\"',\n vm\n );\n return\n }\n if (value == null && !prop.required) {\n return\n }\n var type = prop.type;\n var valid = !type || type === true;\n var expectedTypes = [];\n if (type) {\n if (!Array.isArray(type)) {\n type = [type];\n }\n for (var i = 0; i < type.length && !valid; i++) {\n var assertedType = assertType(value, type[i]);\n expectedTypes.push(assertedType.expectedType || '');\n valid = assertedType.valid;\n }\n }\n if (!valid) {\n warn(\n 'Invalid prop: type check failed for prop \"' + name + '\".' +\n ' Expected ' + expectedTypes.map(capitalize).join(', ') +\n ', got ' + Object.prototype.toString.call(value).slice(8, -1) + '.',\n vm\n );\n return\n }\n var validator = prop.validator;\n if (validator) {\n if (!validator(value)) {\n warn(\n 'Invalid prop: custom validator check failed for prop \"' + name + '\".',\n vm\n );\n }\n }\n}\n\nvar simpleCheckRE = /^(String|Number|Boolean|Function|Symbol)$/;\n\nfunction assertType (value, type) {\n var valid;\n var expectedType = getType(type);\n if (simpleCheckRE.test(expectedType)) {\n valid = typeof value === expectedType.toLowerCase();\n } else if (expectedType === 'Object') {\n valid = isPlainObject(value);\n } else if (expectedType === 'Array') {\n valid = Array.isArray(value);\n } else {\n valid = value instanceof type;\n }\n return {\n valid: valid,\n expectedType: expectedType\n }\n}\n\n/**\n * Use function string name to check built-in types,\n * because a simple equality check will fail when running\n * across different vms / iframes.\n */\nfunction getType (fn) {\n var match = fn && fn.toString().match(/^\\s*function (\\w+)/);\n return match ? match[1] : ''\n}\n\nfunction isType (type, fn) {\n if (!Array.isArray(fn)) {\n return getType(fn) === getType(type)\n }\n for (var i = 0, len = fn.length; i < len; i++) {\n if (getType(fn[i]) === getType(type)) {\n return true\n }\n }\n /* istanbul ignore next */\n return false\n}\n\n/* */\n\nvar mark;\nvar measure;\n\nif (false) {\n var perf = inBrowser && window.performance;\n /* istanbul ignore if */\n if (\n perf &&\n perf.mark &&\n perf.measure &&\n perf.clearMarks &&\n perf.clearMeasures\n ) {\n mark = function (tag) { return perf.mark(tag); };\n measure = function (name, startTag, endTag) {\n perf.measure(name, startTag, endTag);\n perf.clearMarks(startTag);\n perf.clearMarks(endTag);\n perf.clearMeasures(name);\n };\n }\n}\n\n/* not type checking this file because flow doesn't play well with Proxy */\n\nvar initProxy;\n\nif (false) {\n var allowedGlobals = makeMap(\n 'Infinity,undefined,NaN,isFinite,isNaN,' +\n 'parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,' +\n 'Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,' +\n 'require' // for Webpack/Browserify\n );\n\n var warnNonPresent = function (target, key) {\n warn(\n \"Property or method \\\"\" + key + \"\\\" is not defined on the instance but \" +\n \"referenced during render. Make sure to declare reactive data \" +\n \"properties in the data option.\",\n target\n );\n };\n\n var hasProxy =\n typeof Proxy !== 'undefined' &&\n Proxy.toString().match(/native code/);\n\n if (hasProxy) {\n var isBuiltInModifier = makeMap('stop,prevent,self,ctrl,shift,alt,meta');\n config.keyCodes = new Proxy(config.keyCodes, {\n set: function set (target, key, value) {\n if (isBuiltInModifier(key)) {\n warn((\"Avoid overwriting built-in modifier in config.keyCodes: .\" + key));\n return false\n } else {\n target[key] = value;\n return true\n }\n }\n });\n }\n\n var hasHandler = {\n has: function has (target, key) {\n var has = key in target;\n var isAllowed = allowedGlobals(key) || key.charAt(0) === '_';\n if (!has && !isAllowed) {\n warnNonPresent(target, key);\n }\n return has || !isAllowed\n }\n };\n\n var getHandler = {\n get: function get (target, key) {\n if (typeof key === 'string' && !(key in target)) {\n warnNonPresent(target, key);\n }\n return target[key]\n }\n };\n\n initProxy = function initProxy (vm) {\n if (hasProxy) {\n // determine which proxy handler to use\n var options = vm.$options;\n var handlers = options.render && options.render._withStripped\n ? getHandler\n : hasHandler;\n vm._renderProxy = new Proxy(vm, handlers);\n } else {\n vm._renderProxy = vm;\n }\n };\n}\n\n/* */\n\nvar VNode = function VNode (\n tag,\n data,\n children,\n text,\n elm,\n context,\n componentOptions,\n asyncFactory\n) {\n this.tag = tag;\n this.data = data;\n this.children = children;\n this.text = text;\n this.elm = elm;\n this.ns = undefined;\n this.context = context;\n this.functionalContext = undefined;\n this.key = data && data.key;\n this.componentOptions = componentOptions;\n this.componentInstance = undefined;\n this.parent = undefined;\n this.raw = false;\n this.isStatic = false;\n this.isRootInsert = true;\n this.isComment = false;\n this.isCloned = false;\n this.isOnce = false;\n this.asyncFactory = asyncFactory;\n this.asyncMeta = undefined;\n this.isAsyncPlaceholder = false;\n};\n\nvar prototypeAccessors = { child: {} };\n\n// DEPRECATED: alias for componentInstance for backwards compat.\n/* istanbul ignore next */\nprototypeAccessors.child.get = function () {\n return this.componentInstance\n};\n\nObject.defineProperties( VNode.prototype, prototypeAccessors );\n\nvar createEmptyVNode = function (text) {\n if ( text === void 0 ) text = '';\n\n var node = new VNode();\n node.text = text;\n node.isComment = true;\n return node\n};\n\nfunction createTextVNode (val) {\n return new VNode(undefined, undefined, undefined, String(val))\n}\n\n// optimized shallow clone\n// used for static nodes and slot nodes because they may be reused across\n// multiple renders, cloning them avoids errors when DOM manipulations rely\n// on their elm reference.\nfunction cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned\n}\n\nfunction cloneVNodes (vnodes) {\n var len = vnodes.length;\n var res = new Array(len);\n for (var i = 0; i < len; i++) {\n res[i] = cloneVNode(vnodes[i]);\n }\n return res\n}\n\n/* */\n\nvar normalizeEvent = cached(function (name) {\n var passive = name.charAt(0) === '&';\n name = passive ? name.slice(1) : name;\n var once$$1 = name.charAt(0) === '~'; // Prefixed last, checked first\n name = once$$1 ? name.slice(1) : name;\n var capture = name.charAt(0) === '!';\n name = capture ? name.slice(1) : name;\n return {\n name: name,\n once: once$$1,\n capture: capture,\n passive: passive\n }\n});\n\nfunction createFnInvoker (fns) {\n function invoker () {\n var arguments$1 = arguments;\n\n var fns = invoker.fns;\n if (Array.isArray(fns)) {\n var cloned = fns.slice();\n for (var i = 0; i < cloned.length; i++) {\n cloned[i].apply(null, arguments$1);\n }\n } else {\n // return handler return value for single handlers\n return fns.apply(null, arguments)\n }\n }\n invoker.fns = fns;\n return invoker\n}\n\nfunction updateListeners (\n on,\n oldOn,\n add,\n remove$$1,\n vm\n) {\n var name, cur, old, event;\n for (name in on) {\n cur = on[name];\n old = oldOn[name];\n event = normalizeEvent(name);\n if (isUndef(cur)) {\n \"production\" !== 'production' && warn(\n \"Invalid handler for event \\\"\" + (event.name) + \"\\\": got \" + String(cur),\n vm\n );\n } else if (isUndef(old)) {\n if (isUndef(cur.fns)) {\n cur = on[name] = createFnInvoker(cur);\n }\n add(event.name, cur, event.once, event.capture, event.passive);\n } else if (cur !== old) {\n old.fns = cur;\n on[name] = old;\n }\n }\n for (name in oldOn) {\n if (isUndef(on[name])) {\n event = normalizeEvent(name);\n remove$$1(event.name, oldOn[name], event.capture);\n }\n }\n}\n\n/* */\n\nfunction mergeVNodeHook (def, hookKey, hook) {\n var invoker;\n var oldHook = def[hookKey];\n\n function wrappedHook () {\n hook.apply(this, arguments);\n // important: remove merged hook to ensure it's called only once\n // and prevent memory leak\n remove(invoker.fns, wrappedHook);\n }\n\n if (isUndef(oldHook)) {\n // no existing hook\n invoker = createFnInvoker([wrappedHook]);\n } else {\n /* istanbul ignore if */\n if (isDef(oldHook.fns) && isTrue(oldHook.merged)) {\n // already a merged invoker\n invoker = oldHook;\n invoker.fns.push(wrappedHook);\n } else {\n // existing plain hook\n invoker = createFnInvoker([oldHook, wrappedHook]);\n }\n }\n\n invoker.merged = true;\n def[hookKey] = invoker;\n}\n\n/* */\n\nfunction extractPropsFromVNodeData (\n data,\n Ctor,\n tag\n) {\n // we are only extracting raw values here.\n // validation and default values are handled in the child\n // component itself.\n var propOptions = Ctor.options.props;\n if (isUndef(propOptions)) {\n return\n }\n var res = {};\n var attrs = data.attrs;\n var props = data.props;\n if (isDef(attrs) || isDef(props)) {\n for (var key in propOptions) {\n var altKey = hyphenate(key);\n if (false) {\n var keyInLowerCase = key.toLowerCase();\n if (\n key !== keyInLowerCase &&\n attrs && hasOwn(attrs, keyInLowerCase)\n ) {\n tip(\n \"Prop \\\"\" + keyInLowerCase + \"\\\" is passed to component \" +\n (formatComponentName(tag || Ctor)) + \", but the declared prop name is\" +\n \" \\\"\" + key + \"\\\". \" +\n \"Note that HTML attributes are case-insensitive and camelCased \" +\n \"props need to use their kebab-case equivalents when using in-DOM \" +\n \"templates. You should probably use \\\"\" + altKey + \"\\\" instead of \\\"\" + key + \"\\\".\"\n );\n }\n }\n checkProp(res, props, key, altKey, true) ||\n checkProp(res, attrs, key, altKey, false);\n }\n }\n return res\n}\n\nfunction checkProp (\n res,\n hash,\n key,\n altKey,\n preserve\n) {\n if (isDef(hash)) {\n if (hasOwn(hash, key)) {\n res[key] = hash[key];\n if (!preserve) {\n delete hash[key];\n }\n return true\n } else if (hasOwn(hash, altKey)) {\n res[key] = hash[altKey];\n if (!preserve) {\n delete hash[altKey];\n }\n return true\n }\n }\n return false\n}\n\n/* */\n\n// The template compiler attempts to minimize the need for normalization by\n// statically analyzing the template at compile time.\n//\n// For plain HTML markup, normalization can be completely skipped because the\n// generated render function is guaranteed to return Array. There are\n// two cases where extra normalization is needed:\n\n// 1. When the children contains components - because a functional component\n// may return an Array instead of a single root. In this case, just a simple\n// normalization is needed - if any child is an Array, we flatten the whole\n// thing with Array.prototype.concat. It is guaranteed to be only 1-level deep\n// because functional components already normalize their own children.\nfunction simpleNormalizeChildren (children) {\n for (var i = 0; i < children.length; i++) {\n if (Array.isArray(children[i])) {\n return Array.prototype.concat.apply([], children)\n }\n }\n return children\n}\n\n// 2. When the children contains constructs that always generated nested Arrays,\n// e.g.