From 0ff12070e8b2ec9d801f85cc49db8e5314147eb5 Mon Sep 17 00:00:00 2001 From: Gregor Terrill Date: Sun, 3 Jul 2016 22:10:55 -0400 Subject: [PATCH] Game state updates --- client/public/build.css | 6 +- client/public/build.js | 8 +- client/public/build.js.map | 2 +- client/src/components/app.vue | 21 ++++- client/src/components/game/board.vue | 11 ++- client/src/components/ui/deckloader.vue | 26 ++---- client/src/components/ui/infobar.vue | 4 + client/src/entry.js | 2 +- client/src/sass/main.scss | 1 + server/app.js | 119 +++++++++++++++++++----- 10 files changed, 145 insertions(+), 55 deletions(-) diff --git a/client/public/build.css b/client/public/build.css index 4e90dc1..e40d730 100644 --- a/client/public/build.css +++ b/client/public/build.css @@ -1,9 +1,9 @@ -*{box-sizing:border-box}html,body{margin:0;padding:0;font-family:'Marcellus', serif;font-size:16px}a{text-decoration:none;color:#963535}a:hover,a:focus{text-decoration:underline}.btn{cursor:pointer;border:none;background-color:#963535;color:white;font-size:1rem;font-family:'Marcellus', serif;padding:0.5rem 1rem;margin:0 0.75rem 0.25rem 0;border-bottom:4px solid #832e2e}.btn:hover,.btn:active{position:relative;top:1px;background-color:#832e2e;border-bottom:3px solid #702828}.btn[disabled]{background-color:#777;border-bottom:4px solid #666;color:#666}.btn[disabled]:hover,.btn[disabled]:active{top:0;background-color:#777;border-bottom:4px solid #666}.btn--block{display:block}label{display:block}input[type="text"],textarea{display:block;width:100%;background-color:#dadada;font-size:1rem;font-family:'Marcellus', serif;padding:0.5rem;border:none}input[type="text"]:hover,input[type="text"]:focus,textarea:hover,textarea:focus{outline:none}.alert{margin:0}.alert--error{color:red}.alert--success{color:green}.area{position:relative;display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start;border-radius:8px;background-color:rgba(0,128,0,0.1)}.area__slot{margin-left:0.25rem;height:150px;width:100px;background-color:rgba(0,0,0,0.1);border-radius:8px}.area__slot:first-of-type{margin-left:0}.stack__counter,.area__title{position:absolute;top:0;left:0;background-color:rgba(0,0,0,0.8);color:white;padding:0.5rem;border-radius:4px}.container{display:-ms-flexbox;display:flex}.boards{-ms-flex-positive:1;flex-grow:1}.sidebar{width:200px;background-color:black;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.actions{margin:auto 0;text-align:center;-ms-flex-positive:1;flex-grow:1;padding:1rem;color:white;border-top:1px solid white;border-bottom:1px solid white}.actions h2{margin-top:0;margin-bottom:0.5rem}.actions hr{margin:1rem 0;border:none;background-color:white;height:1px}.actions .btn{width:100%;display:block;border:none;background-color:white;color:black;margin-bottom:0.5rem;padding:0.25rem;font-size:0.825rem}.chat{width:100%;height:50%;margin:auto;-ms-flex-positive:0;flex-grow:0;position:relative}.chat__messages{list-style-type:none;margin:0;padding:0.5rem;height:calc(50vh - 1.5rem);overflow-y:scroll}.chat__messages li{color:white;padding:0.25rem}.chat__messages li:last-of-type{margin-bottom:1rem}.chat__messages li.server-msg{color:#CCC;font-style:italic}.chat__form{display:block;position:absolute;bottom:0;width:100%}.chat__input,.chat__btn{display:inline-block;border:none;border-top:1px solid white;border-bottom:1px solid white;background-color:black;color:white;padding:0.25rem}.chat__input:focus,.chat__btn:focus{outline:none}.chat__input{width:80%}.chat__btn{width:20%;border-left:1px solid white}.chat__btn:hover,.chat__btn:active{background-color:#555;cursor:pointer} -.board{width:100%;height:calc(50vh - 1rem);padding:1rem;display:-ms-flexbox;display:flex}.board *{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.board__player{margin:auto}.board__areas{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:distribute;justify-content:space-around}.board--you{border-top:1px dashed #CCC}.board--you .board__areas{-ms-flex-direction:column-reverse;flex-direction:column-reverse} +*{box-sizing:border-box}html,body{margin:0;padding:0;font-family:'Marcellus', serif;font-size:16px}a{text-decoration:none;color:#963535}a:hover,a:focus{text-decoration:underline}.btn{cursor:pointer;border:none;background-color:#963535;color:white;font-size:1rem;font-family:'Marcellus', serif;padding:0.5rem 1rem;margin:0 0.75rem 0.25rem 0;border-bottom:4px solid #832e2e}.btn:hover,.btn:active{position:relative;top:1px;background-color:#832e2e;border-bottom:3px solid #702828}.btn[disabled]{background-color:#777;border-bottom:4px solid #666;color:#666}.btn[disabled]:hover,.btn[disabled]:active{top:0;background-color:#777;border-bottom:4px solid #666}.btn--block{display:block}label{display:block}input[type="text"],textarea{display:block;width:100%;background-color:#dadada;font-size:1rem;font-family:'Marcellus', serif;padding:0.5rem;border:none}input[type="text"]:hover,input[type="text"]:focus,textarea:hover,textarea:focus{outline:none}.alert{margin:0}.alert--error{color:red}.alert--success{color:green}.area{position:relative;display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start;border-radius:8px;background-color:rgba(0,128,0,0.1)}.area__slot{margin-left:0.25rem;height:150px;width:100px;background-color:rgba(0,0,0,0.1);border-radius:8px}.area__slot:first-of-type{margin-left:0}.stack__counter,.area__title{position:absolute;top:0;left:0;background-color:rgba(0,0,0,0.8);color:white;padding:0.5rem;border-radius:4px}.container{display:-ms-flexbox;display:flex;height:calc(100vh - 2rem)}.boards{-ms-flex-positive:1;flex-grow:1}.sidebar{width:200px;background-color:black;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.actions{margin:auto 0;text-align:center;-ms-flex-positive:1;flex-grow:1;padding:1rem;color:white;border-top:1px solid white;border-bottom:1px solid white}.actions h2{margin-top:0;margin-bottom:0.5rem}.actions hr{margin:1rem 0;border:none;background-color:white;height:1px}.actions .btn{width:100%;display:block;border:none;background-color:white;color:black;margin-bottom:0.5rem;padding:0.25rem;font-size:0.825rem}.chat{width:100%;height:50%;margin:auto;-ms-flex-positive:0;flex-grow:0;position:relative}.chat__messages{list-style-type:none;margin:0;padding:0.5rem;height:calc(50vh - 1.5rem);overflow-y:scroll}.chat__messages li{color:white;padding:0.25rem}.chat__messages li:last-of-type{margin-bottom:1rem}.chat__messages li.server-msg{color:#CCC;font-style:italic}.chat__form{display:block;position:absolute;bottom:0;width:100%}.chat__input,.chat__btn{display:inline-block;border:none;border-top:1px solid white;border-bottom:1px solid white;background-color:black;color:white;padding:0.25rem}.chat__input:focus,.chat__btn:focus{outline:none}.chat__input{width:80%}.chat__btn{width:20%;border-left:1px solid white}.chat__btn:hover,.chat__btn:active{background-color:#555;cursor:pointer}.boards{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:end;justify-content:flex-end} +.board{width:100%;height:calc(50vh - 1rem);padding:1rem;display:-ms-flexbox;display:flex}.board *{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.board__player{margin:auto}.board__areas{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:distribute;justify-content:space-around}.board--opponent{border-bottom:1px dashed #CCC}.board--you .board__areas{-ms-flex-direction:column-reverse;flex-direction:column-reverse} .card{display:inline-block;vertical-align:top;width:100px;height:136px;position:relative;background-image:url("../img/back-standard.jpg");background-size:100px 136px} .die{position:relative;width:29px;height:29px;display:inline-block;margin-right:2px}.die.die--exhausted::after{content:"";display:block;position:absolute;top:0;right:0;bottom:0;left:0;border-radius:2px;background-color:rgba(0,0,0,0.6)}.die.die--rolling{animation:diceRoll 0.25s infinite linear}.die--illbasic{background-image:url("../img/dice/illbasic.jpg")}.die--illclass{background-image:url("../img/dice/illclass.jpg")}.die--illpower{background-image:url("../img/dice/illpower.jpg")}.die--natbasic{background-image:url("../img/dice/natbasic.jpg")}.die--natclass{background-image:url("../img/dice/natclass.jpg")}.die--natpower{background-image:url("../img/dice/natpower.jpg")}.die--chabasic{background-image:url("../img/dice/chabasic.jpg")}.die--chaclass{background-image:url("../img/dice/chaclass.jpg")}.die--chapower{background-image:url("../img/dice/chapower.jpg")}.die--cerbasic{background-image:url("../img/dice/cerbasic.jpg")}.die--cerclass{background-image:url("../img/dice/cerclass.jpg")}.die--cerpower{background-image:url("../img/dice/cerpower.jpg")}@keyframes diceRoll{0%{top:0}25%{top:-0.75rem;transform:rotate(90deg)}50%{top:-0.25rem;transform:rotate(180deg)}75%{top:0;transform:rotate(270deg)}100%{top:0;transform:rotate(359deg)}} .stack{display:inline-block;vertical-align:top;width:100px;height:136px;position:relative;background-image:url("../img/back-standard.jpg");background-size:100px 136px}.stack--conjurations{background-image:url("../img/back-conjuration.jpg")}.stack--empty{background-image:none} .context-menu{position:absolute;z-index:99;background:rgba(0,0,0,0.85);border:1px solid white;color:white}.context-menu__list,.context-menu__sublist{margin:0;padding:0;list-style-type:none;min-width:7.5rem}.context-menu__item{padding:0.25rem 0.5rem;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative}.context-menu__item:hover{background-color:black}.context-menu__item:hover .context-menu__sublist{display:block}.context-menu__sublist{display:none;position:absolute;left:100%;top:0;background:rgba(0,0,0,0.85);border:1px solid white} .deck-loader{-ms-flex-positive:1;flex-grow:1}label{display:block}#decklist,#prebuilt{margin-bottom:1rem} -.infobar{height:2rem;background-color:black;color:white;padding:0.375rem 1.5rem;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.infobar__title{font-size:1rem;font-weight:normal;margin:0 auto;text-align:center}.infobar__round{text-align:right} +.infobar{height:2rem;background-color:black;color:white;padding:0.375rem 1.5rem;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.infobar__playerlist,.infobar__title,.infobar__round{-ms-flex:1;flex:1}.infobar__title{font-size:1rem;font-weight:normal;margin:0 auto;text-align:center}.infobar__round{text-align:right} .lobby h1{text-align:center;margin-bottom:0}.lobby .subheading{display:block;text-align:center;font-size:1.25rem;letter-spacing:1.25rem;padding-left:1.25rem}.lobby .container{display:block;max-width:40rem;margin:auto}.lobby .lobby__games{background-color:black;margin:1rem 0;min-height:10rem}.lobby .lobby__game-list{margin:0;padding:0;list-style-type:none}.lobby .lobby__games-none{color:white;padding:0.5rem;margin:0}.lobby .lobby__game{color:white;padding:0.5rem}.lobby .lobby__game.selected{background-color:#555} diff --git a/client/public/build.js b/client/public/build.js index e4578e8..7dcd86a 100644 --- a/client/public/build.js +++ b/client/public/build.js @@ -1,5 +1,5 @@ -!function t(e,n,i){function o(s,a){if(!n[s]){if(!e[s]){var c="function"==typeof require&&require;if(!a&&c)return c(s,!0);if(r)return r(s,!0);var l=new Error("Cannot find module '"+s+"'");throw l.code="MODULE_NOT_FOUND",l}var u=n[s]={exports:{}};e[s][0].call(u.exports,function(t){var n=e[s][1][t];return o(n?n:t)},u,u.exports,t,e,n,i)}return n[s].exports}for(var r="function"==typeof require&&require,s=0;s\n',e.hot&&!function(){e.hot.accept();var n=t("vue-hot-reload-api");n.install(t("vue"),!0),n.compatible&&(e.hot.dispose(function(){i.cache['.card{display:inline-block;vertical-align:top;width:100px;height:136px;position:relative;background-image:url("../img/back-standard.jpg");background-size:100px 136px}\n']=!1,document.head.removeChild(o)}),e.hot.data?n.update("_v-1b648219",e.exports,("function"==typeof e.exports?e.exports.options:e.exports).template):n.createRecord("_v-1b648219",e.exports))}()},{vue:54,"vue-hot-reload-api":53,"vueify/lib/insert-css":55}],4:[function(t,e,n){var i=t("vueify/lib/insert-css"),o=0;Object.defineProperty(n,"__esModule",{value:!0}),n["default"]={props:["type","face","exhausted"],data:function(){return{faces:["basic","basic","class","class","class","power"],rolling:!1,contextActions:[{text:"Roll",action:this.roll},{text:"Refresh",action:this.refresh},{text:"Exhaust",action:this.exhaust}]}},methods:{roll:function(){this.rolling=!0,this.$dispatch("playSound","dice"),setTimeout(function(){this.face=this.faces[Math.floor(Math.random()*this.faces.length)],this.rolling=!1}.bind(this),250)},refresh:function(){this.exhausted=!1},exhaust:function(){this.exhausted=!0},openContext:function(t){this.$dispatch("openContext",this.contextActions,t)}}},e.exports.__esModule&&(e.exports=e.exports["default"]),("function"==typeof e.exports?e.exports.options:e.exports).template="\n
\n",e.hot&&!function(){e.hot.accept();var n=t("vue-hot-reload-api");n.install(t("vue"),!0),n.compatible&&(e.hot.dispose(function(){i.cache['.die{position:relative;width:29px;height:29px;display:inline-block;margin-right:2px}.die.die--exhausted::after{content:"";display:block;position:absolute;top:0;right:0;bottom:0;left:0;border-radius:2px;background-color:rgba(0,0,0,0.6)}.die.die--rolling{animation:diceRoll 0.25s infinite linear}.die--illbasic{background-image:url("../img/dice/illbasic.jpg")}.die--illclass{background-image:url("../img/dice/illclass.jpg")}.die--illpower{background-image:url("../img/dice/illpower.jpg")}.die--natbasic{background-image:url("../img/dice/natbasic.jpg")}.die--natclass{background-image:url("../img/dice/natclass.jpg")}.die--natpower{background-image:url("../img/dice/natpower.jpg")}.die--chabasic{background-image:url("../img/dice/chabasic.jpg")}.die--chaclass{background-image:url("../img/dice/chaclass.jpg")}.die--chapower{background-image:url("../img/dice/chapower.jpg")}.die--cerbasic{background-image:url("../img/dice/cerbasic.jpg")}.die--cerclass{background-image:url("../img/dice/cerclass.jpg")}.die--cerpower{background-image:url("../img/dice/cerpower.jpg")}@keyframes diceRoll{0%{top:0}25%{top:-0.75rem;transform:rotate(90deg)}50%{top:-0.25rem;transform:rotate(180deg)}75%{top:0;transform:rotate(270deg)}100%{top:0;transform:rotate(359deg)}}\n']=!1,document.head.removeChild(o)}),e.hot.data?n.update("_v-63a8c887",e.exports,("function"==typeof e.exports?e.exports.options:e.exports).template):n.createRecord("_v-63a8c887",e.exports))}()},{vue:54,"vue-hot-reload-api":53,"vueify/lib/insert-css":55}],5:[function(t,e,n){function i(t){return t&&t.__esModule?t:{"default":t}}var o=t("vueify/lib/insert-css"),r=0;Object.defineProperty(n,"__esModule",{value:!0});var s=t("../../store.js"),a=i(s);n["default"]={props:["type","cards"],data:function(){return{contextActions:[{text:"Shuffle",action:this.shuffle},{text:"Peek",action:this.peekAtCards}]}},methods:{openContext:function(t){this.$dispatch("openContext",this.contextActions,t)},shuffle:function(){this.$dispatch("playSound","shuffle");for(var t,e,n=this.cards.length;n;)e=Math.floor(Math.random()*n--),t=this.cards[n],this.cards[n]=this.cards[e],this.cards[e]=t},peekAtCards:function(){a["default"].socket.emit("chat","DEBUG",this.cards)}}},e.exports.__esModule&&(e.exports=e.exports["default"]),("function"==typeof e.exports?e.exports.options:e.exports).template="\n
\n\t
{{ this.cards.length ? this.cards.length : '0' }}
\n
\n",e.hot&&!function(){e.hot.accept();var n=t("vue-hot-reload-api");n.install(t("vue"),!0),n.compatible&&(e.hot.dispose(function(){o.cache['.stack{display:inline-block;vertical-align:top;width:100px;height:136px;position:relative;background-image:url("../img/back-standard.jpg");background-size:100px 136px}.stack--conjurations{background-image:url("../img/back-conjuration.jpg")}.stack--empty{background-image:none}\n']=!1,document.head.removeChild(r)}),e.hot.data?n.update("_v-6d35ba62",e.exports,("function"==typeof e.exports?e.exports.options:e.exports).template):n.createRecord("_v-6d35ba62",e.exports))}()},{"../../store.js":13,vue:54,"vue-hot-reload-api":53,"vueify/lib/insert-css":55}],6:[function(t,e,n){var i=t("vueify/lib/insert-css"),o=0;Object.defineProperty(n,"__esModule",{value:!0});var r=t("vue-clickaway");n["default"]={mixins:[r.mixin],data:function(){return{viewMenu:!1,top:"0px",left:"0px",contextActions:[]}},methods:{positionMenu:function(t,e){largestHeight=window.innerHeight-this.$els.menu.offsetHeight,largestWidth=window.innerWidth-this.$els.menu.offsetWidth,e>largestHeight&&(e=largestHeight),t>largestWidth&&(t=largestWidth),this.top=e+"px",this.left=t+"px"},openMenu:function(t,e){this.viewMenu=!0,this.contextActions=t,this.positionMenu(e.x,e.y)},closeMenu:function(t){this.viewMenu=!1},triggerAndClose:function(t){t(),this.closeMenu()}}},e.exports.__esModule&&(e.exports=e.exports["default"]),("function"==typeof e.exports?e.exports.options:e.exports).template='\n
\n\t
    \n\t\t
  • {{ item.text }}\n\t\t\t
      \n\t\t\t\t
    • {{ subItem.text }}\n\t\t\t
    \n\t\t
  • \n\t
\n
\n',e.hot&&!function(){e.hot.accept();var n=t("vue-hot-reload-api");n.install(t("vue"),!0),n.compatible&&(e.hot.dispose(function(){i.cache[".context-menu{position:absolute;z-index:99;background:rgba(0,0,0,0.85);border:1px solid white;color:white}.context-menu__list,.context-menu__sublist{margin:0;padding:0;list-style-type:none;min-width:7.5rem}.context-menu__item{padding:0.25rem 0.5rem;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative}.context-menu__item:hover{background-color:black}.context-menu__item:hover .context-menu__sublist{display:block}.context-menu__sublist{display:none;position:absolute;left:100%;top:0;background:rgba(0,0,0,0.85);border:1px solid white}\n"]=!1,document.head.removeChild(o)}),e.hot.data?n.update("_v-629b0992",e.exports,("function"==typeof e.exports?e.exports.options:e.exports).template):n.createRecord("_v-629b0992",e.exports))}()},{vue:54,"vue-clickaway":52,"vue-hot-reload-api":53,"vueify/lib/insert-css":55}],7:[function(t,e,n){function i(t){return t&&t.__esModule?t:{"default":t}}var o=t("vueify/lib/insert-css"),r=0;Object.defineProperty(n,"__esModule",{value:!0});var s=t("babel-runtime/core-js/json/stringify"),a=i(s),c=t("../../store.js"),l=i(c);n["default"]={props:["player"],data:function(){return{prebuiltLists:{},prebuiltSelection:"",decklist:"",decklistValid:!1,validationError:""}},ready:function(){l["default"].socket.emit("requestPrebuiltLists",l["default"].state.gameId)},methods:{populateDecklist:function(){this.decklist=(0,a["default"])(this.prebuiltLists[this.prebuiltSelection])},submitDecklistForValidation:function(){l["default"].socket.emit("submitDecklistForValidation",l["default"].state.gameId,this.decklist)}},events:{prebuiltDecklists:function(t){this.prebuiltLists=t},decklistValidated:function(t,e,n,i){t===l["default"].socketId&&(this.decklistValid=n,this.decklist=e,i?this.validationError=i:n||(this.validationError="Unspecified validation error.")),l["default"].state.gameRound=0,l["default"].socket.emit("requestGameState",l["default"].state.gameId)}}},e.exports.__esModule&&(e.exports=e.exports["default"]),("function"==typeof e.exports?e.exports.options:e.exports).template='\n
\n\t

Deck Loader

\n\n\t
\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\n\t\t\n\n\t\t

{{ validationError }} Please re-submit.

\n\t
\n\n\t
\n\t\t

Your decklist is valid and locked in!

\n\t
\n\n
\n',e.hot&&!function(){e.hot.accept();var n=t("vue-hot-reload-api");n.install(t("vue"),!0),n.compatible&&(e.hot.dispose(function(){o.cache[".deck-loader{-ms-flex-positive:1;flex-grow:1}label{display:block}#decklist,#prebuilt{margin-bottom:1rem}\n"]=!1,document.head.removeChild(r)}),e.hot.data?n.update("_v-6881f463",e.exports,("function"==typeof e.exports?e.exports.options:e.exports).template):n.createRecord("_v-6881f463",e.exports))}()},{"../../store.js":13,"babel-runtime/core-js/json/stringify":14,vue:54,"vue-hot-reload-api":53,"vueify/lib/insert-css":55}],8:[function(t,e,n){function i(t){return t&&t.__esModule?t:{"default":t}}var o=t("vueify/lib/insert-css"),r=0;Object.defineProperty(n,"__esModule",{value:!0});var s=t("../../store.js"),a=i(s);n["default"]={data:function(){return{}},computed:{gameRound:function(){return a["default"].state.gameRound},playerList:function(){var t=[];for(player in a["default"].state.players)a["default"].state.players.hasOwnProperty(player)&&t.push({playerSocketId:player,playerName:a["default"].state.players[player].username,playerPos:a["default"].state.players[player].position});return t.sort(function(t,e){return t.playerPos-e.playerPos}),t}}},e.exports.__esModule&&(e.exports=e.exports["default"]),("function"==typeof e.exports?e.exports.options:e.exports).template='\n
\n\t
\n\t\t{{ playerList[0].playerName }}\n\t\t vs. {{ playerList[1].playerName }}\n\t\t waiting for opponent\n\t
\n\t

A · S · H · E · S

\n\t
{{ (gameRound > 0) ? \'Round \' + gameRound : \'Setup\' }}
\n
\n',e.hot&&!function(){e.hot.accept();var n=t("vue-hot-reload-api");n.install(t("vue"),!0),n.compatible&&(e.hot.dispose(function(){o.cache[".infobar{height:2rem;background-color:black;color:white;padding:0.375rem 1.5rem;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.infobar__title{font-size:1rem;font-weight:normal;margin:0 auto;text-align:center}.infobar__round{text-align:right}\n"]=!1,document.head.removeChild(r)}),e.hot.data?n.update("_v-6184c564",e.exports,("function"==typeof e.exports?e.exports.options:e.exports).template):n.createRecord("_v-6184c564",e.exports))}()},{"../../store.js":13,vue:54,"vue-hot-reload-api":53,"vueify/lib/insert-css":55}],9:[function(t,e,n){function i(t){return t&&t.__esModule?t:{"default":t}}var o=t("vueify/lib/insert-css"),r=0;Object.defineProperty(n,"__esModule",{value:!0});var s=t("babel-runtime/core-js/object/keys"),a=i(s),c=t("../../store.js"),l=i(c);n["default"]={data:function(){return{username:"",gameSelected:!1}},computed:{gameList:function(){return l["default"].gameList},readyToJoin:function(){return!(!this.username||!this.gameSelected)},totalGames:function(){return l["default"].gameList?(0,a["default"])(l["default"].gameList).length:0}},methods:{createGame:function(){l["default"].socket.emit("createGame",this.username),l["default"].username=this.username},joinGame:function(){l["default"].socket.emit("joinGame",this.gameSelected,this.username),l["default"].username=this.username,l["default"].state.gameId=this.gameSelected},selectGame:function(t){this.gameSelected=t}},ready:function(){l["default"].socket.emit("requestGameList")}},e.exports.__esModule&&(e.exports=e.exports["default"]),("function"==typeof e.exports?e.exports.options:e.exports).template='\n
\n\t
\n\n\t\t

A · S · H · E · S

\n\t\tONLINE\n\n\t\t

This is a fan project by @GregorTerrill. I am not associated with Plaid Hat Games in any way. If you like Ashes, please show your support by purchasing their products.

\n\t\t\n\t\t

Lobby

\n\n\t\t

User

\n\n\t\t\n\t\t\n\n\t\t

Available Games

\n\n\t\t
\n\n\t\t
    \n\t\t\t
  • {{ game.roomName }}
  • \n\t\t
\n\n\t\t

None

\n\n\t\t
\n\n\t\t\n\t\t\n\n\t
\n
\n',e.hot&&!function(){e.hot.accept();var n=t("vue-hot-reload-api");n.install(t("vue"),!0),n.compatible&&(e.hot.dispose(function(){o.cache[".lobby h1{text-align:center;margin-bottom:0}.lobby .subheading{display:block;text-align:center;font-size:1.25rem;letter-spacing:1.25rem;padding-left:1.25rem}.lobby .container{display:block;max-width:40rem;margin:auto}.lobby .lobby__games{background-color:black;margin:1rem 0;min-height:10rem}.lobby .lobby__game-list{margin:0;padding:0;list-style-type:none}.lobby .lobby__games-none{color:white;padding:0.5rem;margin:0}.lobby .lobby__game{color:white;padding:0.5rem}.lobby .lobby__game.selected{background-color:#555}\n"]=!1,document.head.removeChild(r)}),e.hot.data?n.update("_v-437c8f82",e.exports,("function"==typeof e.exports?e.exports.options:e.exports).template):n.createRecord("_v-437c8f82",e.exports))}()},{"../../store.js":13,"babel-runtime/core-js/object/keys":15,vue:54,"vue-hot-reload-api":53,"vueify/lib/insert-css":55}],10:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}Object.defineProperty(n,"__esModule",{value:!0});var o=t("../../store.js"),r=i(o);n["default"]={data:function(){return{message:"",chatLog:r["default"].state.chatLog}},methods:{sendChat:function(){this.message.length&&(r["default"].socket.emit("chat",r["default"].username,this.message),this.message="")}},events:{chatRecieved:function(t){r["default"].state.chatLog.push(t)}}},e.exports.__esModule&&(e.exports=e.exports["default"]),("function"==typeof e.exports?e.exports.options:e.exports).template='\n\n',e.hot&&!function(){e.hot.accept();var n=t("vue-hot-reload-api");n.install(t("vue"),!0),n.compatible&&(e.hot.data?n.update("_v-b92e76f6",e.exports,("function"==typeof e.exports?e.exports.options:e.exports).template):n.createRecord("_v-b92e76f6",e.exports))}()},{"../../store.js":13,vue:54,"vue-hot-reload-api":53}],11:[function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{"default":t}}var o=t("./store.js"),r=i(o),s=t("vue"),a=t("./components/app.vue");s.directive("click-outside",{bind:function(){document.addEventListener("click",function(){this.vm[this.expression]()}.bind(this)),this.el.addEventListener("click",function(t){t.stopPropagation()})}});var c=new s({el:"body",components:{App:a}});r["default"].socket.on("socketId",function(t){r["default"].socketId=t}),r["default"].socket.on("chat",function(t,e,n){c.$broadcast("chatRecieved",{sender:t,message:e,className:n});var i=document.getElementsByClassName("chat__messages")[0];i&&(i.scrollTop=i.scrollHeight)}),r["default"].socket.on("gameStateUpdated",function(t,e){r["default"].state.gameId=t,console.log(e),r["default"].state.players=e.players}),r["default"].socket.on("gameList",function(t){r["default"].gameList=t}),r["default"].socket.on("prebuiltDecklists",function(t){c.$broadcast("prebuiltDecklists",t)}),r["default"].socket.on("decklistValidated",function(t,e,n,i){c.$broadcast("decklistValidated",t,e,n,i)})},{"./components/app.vue":1,"./store.js":13,vue:54}],12:[function(t,e,n){"use strict";function i(){console.log("hello")}Object.defineProperty(n,"__esModule",{value:!0}),n.testFunction=i},{}],13:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n["default"]={socket:io(),socketId:"",username:"Anonymous",gameList:[],state:{gameId:"",gameRound:-1,chatLog:[],players:[]}}},{}],14:[function(t,e,n){e.exports={"default":t("core-js/library/fn/json/stringify"),__esModule:!0}},{"core-js/library/fn/json/stringify":16}],15:[function(t,e,n){e.exports={"default":t("core-js/library/fn/object/keys"),__esModule:!0}},{"core-js/library/fn/object/keys":17}],16:[function(t,e,n){var i=t("../../modules/_core"),o=i.JSON||(i.JSON={stringify:JSON.stringify});e.exports=function(t){return o.stringify.apply(o,arguments)}},{"../../modules/_core":22}],17:[function(t,e,n){t("../../modules/es6.object.keys"),e.exports=t("../../modules/_core").Object.keys},{"../../modules/_core":22,"../../modules/es6.object.keys":50}],18:[function(t,e,n){e.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},{}],19:[function(t,e,n){var i=t("./_is-object");e.exports=function(t){if(!i(t))throw TypeError(t+" is not an object!");return t}},{"./_is-object":35}],20:[function(t,e,n){var i=t("./_to-iobject"),o=t("./_to-length"),r=t("./_to-index");e.exports=function(t){return function(e,n,s){var a,c=i(e),l=o(c.length),u=r(s,l);if(t&&n!=n){for(;l>u;)if(a=c[u++],a!=a)return!0}else for(;l>u;u++)if((t||u in c)&&c[u]===n)return t||u||0;return!t&&-1}}},{"./_to-index":43,"./_to-iobject":45,"./_to-length":46}],21:[function(t,e,n){var i={}.toString;e.exports=function(t){return i.call(t).slice(8,-1)}},{}],22:[function(t,e,n){var i=e.exports={version:"2.4.0"};"number"==typeof __e&&(__e=i)},{}],23:[function(t,e,n){var i=t("./_a-function");e.exports=function(t,e,n){if(i(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,i){return t.call(e,n,i)};case 3:return function(n,i,o){return t.call(e,n,i,o)}}return function(){return t.apply(e,arguments)}}},{"./_a-function":18}],24:[function(t,e,n){e.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},{}],25:[function(t,e,n){e.exports=!t("./_fails")(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},{"./_fails":29}],26:[function(t,e,n){var i=t("./_is-object"),o=t("./_global").document,r=i(o)&&i(o.createElement);e.exports=function(t){return r?o.createElement(t):{}}},{"./_global":30,"./_is-object":35}],27:[function(t,e,n){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},{}],28:[function(t,e,n){var i=t("./_global"),o=t("./_core"),r=t("./_ctx"),s=t("./_hide"),a="prototype",c=function(t,e,n){var l,u,h,d=t&c.F,p=t&c.G,f=t&c.S,v=t&c.P,m=t&c.B,g=t&c.W,b=p?o:o[e]||(o[e]={}),_=b[a],y=p?i:f?i[e]:(i[e]||{})[a];p&&(n=e);for(l in n)u=!d&&y&&void 0!==y[l],u&&l in b||(h=u?y[l]:n[l],b[l]=p&&"function"!=typeof y[l]?n[l]:m&&u?r(h,i):g&&y[l]==h?function(t){var e=function(e,n,i){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,i)}return t.apply(this,arguments)};return e[a]=t[a],e}(h):v&&"function"==typeof h?r(Function.call,h):h,v&&((b.virtual||(b.virtual={}))[l]=h,t&c.R&&_&&!_[l]&&s(_,l,h)))};c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,e.exports=c},{"./_core":22,"./_ctx":23,"./_global":30,"./_hide":32}],29:[function(t,e,n){e.exports=function(t){try{return!!t()}catch(e){return!0}}},{}],30:[function(t,e,n){var i=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=i)},{}],31:[function(t,e,n){var i={}.hasOwnProperty;e.exports=function(t,e){return i.call(t,e)}},{}],32:[function(t,e,n){var i=t("./_object-dp"),o=t("./_property-desc");e.exports=t("./_descriptors")?function(t,e,n){return i.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},{"./_descriptors":25,"./_object-dp":36,"./_property-desc":40}],33:[function(t,e,n){e.exports=!t("./_descriptors")&&!t("./_fails")(function(){return 7!=Object.defineProperty(t("./_dom-create")("div"),"a",{get:function(){return 7}}).a})},{"./_descriptors":25,"./_dom-create":26,"./_fails":29}],34:[function(t,e,n){ -var i=t("./_cof");e.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==i(t)?t.split(""):Object(t)}},{"./_cof":21}],35:[function(t,e,n){e.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},{}],36:[function(t,e,n){var i=t("./_an-object"),o=t("./_ie8-dom-define"),r=t("./_to-primitive"),s=Object.defineProperty;n.f=t("./_descriptors")?Object.defineProperty:function(t,e,n){if(i(t),e=r(e,!0),i(n),o)try{return s(t,e,n)}catch(a){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}},{"./_an-object":19,"./_descriptors":25,"./_ie8-dom-define":33,"./_to-primitive":48}],37:[function(t,e,n){var i=t("./_has"),o=t("./_to-iobject"),r=t("./_array-includes")(!1),s=t("./_shared-key")("IE_PROTO");e.exports=function(t,e){var n,a=o(t),c=0,l=[];for(n in a)n!=s&&i(a,n)&&l.push(n);for(;e.length>c;)i(a,n=e[c++])&&(~r(l,n)||l.push(n));return l}},{"./_array-includes":20,"./_has":31,"./_shared-key":41,"./_to-iobject":45}],38:[function(t,e,n){var i=t("./_object-keys-internal"),o=t("./_enum-bug-keys");e.exports=Object.keys||function(t){return i(t,o)}},{"./_enum-bug-keys":27,"./_object-keys-internal":37}],39:[function(t,e,n){var i=t("./_export"),o=t("./_core"),r=t("./_fails");e.exports=function(t,e){var n=(o.Object||{})[t]||Object[t],s={};s[t]=e(n),i(i.S+i.F*r(function(){n(1)}),"Object",s)}},{"./_core":22,"./_export":28,"./_fails":29}],40:[function(t,e,n){e.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},{}],41:[function(t,e,n){var i=t("./_shared")("keys"),o=t("./_uid");e.exports=function(t){return i[t]||(i[t]=o(t))}},{"./_shared":42,"./_uid":49}],42:[function(t,e,n){var i=t("./_global"),o="__core-js_shared__",r=i[o]||(i[o]={});e.exports=function(t){return r[t]||(r[t]={})}},{"./_global":30}],43:[function(t,e,n){var i=t("./_to-integer"),o=Math.max,r=Math.min;e.exports=function(t,e){return t=i(t),t<0?o(t+e,0):r(t,e)}},{"./_to-integer":44}],44:[function(t,e,n){var i=Math.ceil,o=Math.floor;e.exports=function(t){return isNaN(t=+t)?0:(t>0?o:i)(t)}},{}],45:[function(t,e,n){var i=t("./_iobject"),o=t("./_defined");e.exports=function(t){return i(o(t))}},{"./_defined":24,"./_iobject":34}],46:[function(t,e,n){var i=t("./_to-integer"),o=Math.min;e.exports=function(t){return t>0?o(i(t),9007199254740991):0}},{"./_to-integer":44}],47:[function(t,e,n){var i=t("./_defined");e.exports=function(t){return Object(i(t))}},{"./_defined":24}],48:[function(t,e,n){var i=t("./_is-object");e.exports=function(t,e){if(!i(t))return t;var n,o;if(e&&"function"==typeof(n=t.toString)&&!i(o=n.call(t)))return o;if("function"==typeof(n=t.valueOf)&&!i(o=n.call(t)))return o;if(!e&&"function"==typeof(n=t.toString)&&!i(o=n.call(t)))return o;throw TypeError("Can't convert object to primitive value")}},{"./_is-object":35}],49:[function(t,e,n){var i=0,o=Math.random();e.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++i+o).toString(36))}},{}],50:[function(t,e,n){var i=t("./_to-object"),o=t("./_object-keys");t("./_object-sap")("keys",function(){return function(t){return o(i(t))}})},{"./_object-keys":38,"./_object-sap":39,"./_to-object":47}],51:[function(t,e,n){function i(){d&&u&&(d=!1,u.length?h=u.concat(h):p=-1,h.length&&o())}function o(){if(!d){var t=a(i);d=!0;for(var e=h.length;e;){for(u=h,h=[];++p1)for(var n=1;n hot reload shim applied."))}},n.createRecord=function(t,e){"function"==typeof e&&(e=e.options),"string"!=typeof e.el&&"object"!=typeof e.data&&(s(t,e),p[t]={Component:null,views:[],instances:[]})},n.update=function(t,e,n){var i=p[t];if(!i||i.instances.length&&!i.views.length){if(console.log("[HMR] Root or manually-mounted instance modified. Full reload may be required."),v)return;window.location.reload()}v||console.log("[HMR] Updating component: "+h(t));var o=i.Component;e&&(o=i.Component="function"==typeof e?e:d.extend(e),s(t,o.options)),n&&(o.options.template=n),o.options.name&&(o.options.components[o.options.name]=o),o.linker=null,i.views.forEach(function(t){c(t,o)}),window.__VUE_DEVTOOLS_GLOBAL_HOOK__&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__.emit("flush")}},{}],54:[function(t,e,n){(function(t,n){"use strict";function i(t,e,n){if(r(t,e))return void(t[e]=n);if(t._isVue)return void i(t._data,e,n);var o=t.__ob__;if(!o)return void(t[e]=n);if(o.convert(e,n),o.dep.notify(),o.vms)for(var s=o.vms.length;s--;){var a=o.vms[s];a._proxy(e),a._digest()}return n}function o(t,e){if(r(t,e)){delete t[e];var n=t.__ob__;if(!n)return void(t._isVue&&(delete t._data[e],t._digest()));if(n.dep.notify(),n.vms)for(var i=n.vms.length;i--;){var o=n.vms[i];o._unproxy(e),o._digest()}}}function r(t,e){return Sn.call(t,e)}function s(t){return Vn.test(t)}function a(t){var e=(t+"").charCodeAt(0);return 36===e||95===e}function c(t){return null==t?"":t.toString()}function l(t){if("string"!=typeof t)return t;var e=Number(t);return isNaN(e)?t:e}function u(t){return"true"===t||"false"!==t&&t}function h(t){var e=t.charCodeAt(0),n=t.charCodeAt(t.length-1);return e!==n||34!==e&&39!==e?t:t.slice(1,-1)}function d(t){return t.replace(Mn,p)}function p(t,e){return e?e.toUpperCase():""}function f(t){return t.replace(Pn,"$1-$2").toLowerCase()}function v(t){return t.replace(Ln,p)}function m(t,e){return function(n){var i=arguments.length;return i?i>1?t.apply(e,arguments):t.call(e,n):t.call(e)}}function g(t,e){e=e||0;for(var n=t.length-e,i=new Array(n);n--;)i[n]=t[n+e];return i}function b(t,e){for(var n=Object.keys(e),i=n.length;i--;)t[n[i]]=e[n[i]];return t}function _(t){return null!==t&&"object"==typeof t}function y(t){return Rn.call(t)===Fn}function x(t,e,n,i){Object.defineProperty(t,e,{value:n,enumerable:!!i,writable:!0,configurable:!0})}function w(t,e){var n,i,o,r,s,a=function c(){var a=Date.now()-r;a=0?n=setTimeout(c,e-a):(n=null,s=t.apply(o,i),n||(o=i=null))};return function(){return o=this,i=arguments,r=Date.now(),n||(n=setTimeout(a,e)),s}}function k(t,e){for(var n=t.length;n--;)if(t[n]===e)return n;return-1}function C(t){var e=function n(){if(!n.cancelled)return t.apply(this,arguments)};return e.cancel=function(){e.cancelled=!0},e}function E(t,e){return t==e||!(!_(t)||!_(e))&&JSON.stringify(t)===JSON.stringify(e)}function N(t){this.size=0,this.limit=t,this.head=this.tail=void 0,this._keymap=Object.create(null)}function $(){var t,e=ai.slice(pi,hi).trim();if(e){t={};var n=e.match(yi);t.name=n[0],n.length>1&&(t.args=n.slice(1).map(O))}t&&(ci.filters=ci.filters||[]).push(t),pi=hi+1}function O(t){if(xi.test(t))return{value:l(t),dynamic:!1};var e=h(t),n=e===t;return{value:n?t:e,dynamic:n}}function j(t){var e=_i.get(t);if(e)return e;for(ai=t,fi=vi=!1,mi=gi=bi=0,pi=0,ci={},hi=0,di=ai.length;hil&&c.push({value:t.slice(l,i)}),o=Ni.test(n[0]),r=o?n[1]:n[2],s=r.charCodeAt(0),a=42===s,r=a?r.slice(1):r,c.push({tag:!0,value:r.trim(),html:o,oneTime:a}),l=i+n[0].length;return l1?t.map(function(t){return V(t,e)}).join("+"):V(t[0],e,!0)}function V(t,e,n){return t.tag?t.oneTime&&e?'"'+e.$eval(t.value)+'"':M(t.value,n):'"'+t.value+'"'}function M(t,e){if($i.test(t)){var n=j(t);return n.filters?"this._applyFilters("+n.expression+",null,"+JSON.stringify(n.filters)+",false)":"("+t+")"}return e?t:"("+t+")"}function P(t,e,n,i){F(t,1,function(){e.appendChild(t)},n,i)}function L(t,e,n,i){F(t,1,function(){z(t,e)},n,i)}function R(t,e,n){F(t,-1,function(){q(t)},e,n)}function F(t,e,n,i,o){var r=t.__v_trans;if(!r||!r.hooks&&!Xn||!i._isCompiled||i.$parent&&!i.$parent._isCompiled)return n(),void(o&&o());var s=e>0?"enter":"leave";r[s](n,o)}function I(e){if("string"==typeof e){var n=e;e=document.querySelector(e),e||"production"!==t.env.NODE_ENV&&Ti("Cannot find element: "+n)}return e}function H(t){if(!t)return!1;var e=t.ownerDocument.documentElement,n=t.parentNode;return e===t||e===n||!(!n||1!==n.nodeType||!e.contains(n))}function U(t,e){var n=t.getAttribute(e);return null!==n&&t.removeAttribute(e),n}function W(t,e){var n=U(t,":"+e);return null===n&&(n=U(t,"v-bind:"+e)),n}function B(t,e){return t.hasAttribute(e)||t.hasAttribute(":"+e)||t.hasAttribute("v-bind:"+e)}function z(t,e){e.parentNode.insertBefore(t,e)}function G(t,e){e.nextSibling?z(t,e.nextSibling):e.parentNode.appendChild(t)}function q(t){t.parentNode.removeChild(t)}function J(t,e){e.firstChild?z(t,e.firstChild):e.appendChild(t)}function Y(t,e){var n=t.parentNode;n&&n.replaceChild(e,t)}function Q(t,e,n,i){t.addEventListener(e,n,i)}function Z(t,e,n){t.removeEventListener(e,n)}function K(t){var e=t.className;return"object"==typeof e&&(e=e.baseVal||""),e}function X(t,e){Gn&&!/svg$/.test(t.namespaceURI)?t.className=e:t.setAttribute("class",e)}function tt(t,e){if(t.classList)t.classList.add(e);else{var n=" "+K(t)+" ";n.indexOf(" "+e+" ")<0&&X(t,(n+e).trim())}}function et(t,e){if(t.classList)t.classList.remove(e);else{for(var n=" "+K(t)+" ",i=" "+e+" ";n.indexOf(i)>=0;)n=n.replace(i," ");X(t,n.trim())}t.className||t.removeAttribute("class")}function nt(t,e){var n,i;if(rt(t)&&ut(t.content)&&(t=t.content),t.hasChildNodes())for(it(t),i=e?document.createDocumentFragment():document.createElement("div");n=t.firstChild;)i.appendChild(n);return i}function it(t){for(var e;e=t.firstChild,ot(e);)t.removeChild(e);for(;e=t.lastChild,ot(e);)t.removeChild(e)}function ot(t){return t&&(3===t.nodeType&&!t.data.trim()||8===t.nodeType)}function rt(t){return t.tagName&&"template"===t.tagName.toLowerCase()}function st(t,e){var n=Di.debug?document.createComment(t):document.createTextNode(e?" ":"");return n.__v_anchor=!0,n}function at(t){if(t.hasAttributes())for(var e=t.attributes,n=0,i=e.length;n=c.length){for(var t=0;t - did you mean <"+s+">? HTML is case-insensitive, remember to use kebab-case in templates."):Ri(e,i)&&Ti("Unknown custom element: <"+i+'> - did you register the component correctly? For recursive components, make sure to provide the "name" option.')}}}function pt(t,e){var n=t.getAttribute("is");if(null!=n){if(yt(e,"components",n))return t.removeAttribute("is"),{id:n}}else if(n=W(t,"is"),null!=n)return{id:n,dynamic:!0}}function ft(t,e){var n,o,s;for(n in e)o=t[n],s=e[n],r(t,n)?_(o)&&_(s)&&ft(o,s):i(t,n,s);return t}function vt(t,e){var n=Object.create(t||null);return e?b(n,bt(e)):n}function mt(e){if(e.components){var n,i=e.components=bt(e.components),o=Object.keys(i);if("production"!==t.env.NODE_ENV)var r=e._componentNameMap={};for(var s=0,a=o.length;s=97&&e<=122||e>=65&&e<=90?"ident":e>=49&&e<=57?"number":"else"}function At(t){var e=t.trim();return("0"!==t.charAt(0)||!isNaN(t))&&(s(e)?h(e):"*"+e)}function Dt(t){function e(){var e=t[u+1];if(h===oo&&"'"===e||h===ro&&'"'===e)return u++,i="\\"+e,p[Yi](),!0}var n,i,o,r,s,a,c,l=[],u=-1,h=Xi,d=0,p=[];for(p[Qi]=function(){void 0!==o&&(l.push(o),o=void 0)},p[Yi]=function(){void 0===o?o=i:o+=i},p[Zi]=function(){p[Yi](),d++},p[Ki]=function(){if(d>0)d--,h=io,p[Yi]();else{if(d=0,o=At(o),o===!1)return!1;p[Qi]()}};null!=h;)if(u++,n=t[u],"\\"!==n||!e()){if(r=jt(n),c=co[h],s=c[r]||c["else"]||ao,s===ao)return;if(h=s[0],a=p[s[1]],a&&(i=s[2],i=void 0===i?n:i,a()===!1))return;if(h===so)return l.raw=t,l}}function Tt(t){var e=Ji.get(t);return e||(e=Dt(t),e&&Ji.put(t,e)),e}function St(t,e){return Ut(e).get(t)}function Vt(e,n,o){var r=e;if("string"==typeof n&&(n=Dt(n)),!n||!_(e))return!1;for(var s,a,c=0,l=n.length;c-1?n.replace(yo,Rt):n,e+"scope."+n)}function Rt(t,e){return Co[e]}function Ft(e){mo.test(e)&&"production"!==t.env.NODE_ENV&&Ti("Avoid using reserved keywords in expression: "+e),Co.length=0;var n=e.replace(_o,Pt).replace(go,"");return n=(" "+n).replace(wo,Lt).replace(yo,Rt),It(n)}function It(e){try{return new Function("scope","return "+e+";")}catch(n){return"production"!==t.env.NODE_ENV&&Ti(n.toString().match(/unsafe-eval|CSP/)?"It seems you are using the default build of Vue.js in an environment with Content Security Policy that prohibits unsafe-eval. Use the CSP-compliant build instead: http://vuejs.org/guide/installation.html#CSP-compliant-build":"Invalid expression. Generated function body: "+e),Mt}}function Ht(e){var n=Tt(e);return n?function(t,e){Vt(t,n,e)}:void("production"!==t.env.NODE_ENV&&Ti("Invalid setter expression: "+e))}function Ut(t,e){t=t.trim();var n=ho.get(t);if(n)return e&&!n.set&&(n.set=Ht(n.exp)),n;var i={exp:t};return i.get=Wt(t)&&t.indexOf("[")<0?It("scope."+t):Ft(t),e&&(i.set=Ht(t)),ho.put(t,i),i}function Wt(t){return xo.test(t)&&!ko.test(t)&&"Math."!==t.slice(0,5)}function Bt(){No.length=0,$o.length=0,Oo={},jo={},Ao=!1}function zt(){for(var t=!0;t;)t=!1,Gt(No),Gt($o),No.length?t=!0:(Wn&&Di.devtools&&Wn.emit("flush"),Bt())}function Gt(e){for(var n=0;nDi._maxUpdateCount)){Ti('You may have an infinite update loop for watcher with expression "'+i.expression+'"',i.vm);break}}e.length=0}function qt(t){var e=t.id;if(null==Oo[e]){var n=t.user?$o:No;Oo[e]=n.length,n.push(t),Ao||(Ao=!0,oi(zt))}}function Jt(t,e,n,i){i&&b(this,i);var o="function"==typeof e;if(this.vm=t,t._watchers.push(this),this.expression=e,this.cb=n,this.id=++Do,this.active=!0,this.dirty=this.lazy,this.deps=[],this.newDeps=[],this.depIds=new ri,this.newDepIds=new ri,this.prevError=null,o)this.getter=e,this.setter=void 0;else{var r=Ut(e,this.twoWay);this.getter=r.get,this.setter=r.set}this.value=this.lazy?void 0:this.get(),this.queued=this.shallow=!1}function Yt(t,e){var n=void 0,i=void 0;e||(e=To,e.clear());var o=In(t),r=_(t);if(o||r){if(t.__ob__){var s=t.__ob__.dep.id;if(e.has(s))return;e.add(s)}if(o)for(n=t.length;n--;)Yt(t[n],e);else if(r)for(i=Object.keys(t),n=i.length;n--;)Yt(t[i[n]],e)}}function Qt(t){return rt(t)&&ut(t.content)}function Zt(t,e){var n=e?t:t.trim(),i=Vo.get(n);if(i)return i;var o=document.createDocumentFragment(),r=t.match(Lo),s=Ro.test(t),a=Fo.test(t);if(r||s||a){var c=r&&r[1],l=Po[c]||Po.efault,u=l[0],h=l[1],d=l[2],p=document.createElement("div");for(p.innerHTML=h+t+d;u--;)p=p.lastChild;for(var f;f=p.firstChild;)o.appendChild(f)}else o.appendChild(document.createTextNode(t));return e||it(o),Vo.put(n,o),o}function Kt(t){if(Qt(t))return Zt(t.innerHTML);if("SCRIPT"===t.tagName)return Zt(t.textContent);for(var e,n=Xt(t),i=document.createDocumentFragment();e=n.firstChild;)i.appendChild(e);return it(i),i}function Xt(t){if(!t.querySelectorAll)return t.cloneNode();var e,n,i,o=t.cloneNode(!0);if(Io){var r=o;if(Qt(t)&&(t=t.content,r=o.content),n=t.querySelectorAll("template"),n.length)for(i=r.querySelectorAll("template"),e=i.length;e--;)i[e].parentNode.replaceChild(Xt(n[e]),i[e])}if(Ho)if("TEXTAREA"===t.tagName)o.value=t.value;else if(n=t.querySelectorAll("textarea"),n.length)for(i=o.querySelectorAll("textarea"),e=i.length;e--;)i[e].value=n[e].value;return o}function te(t,e,n){var i,o;return ut(t)?(it(t),e?Xt(t):t):("string"==typeof t?n||"#"!==t.charAt(0)?o=Zt(t,n):(o=Mo.get(t),o||(i=document.getElementById(t.slice(1)),i&&(o=Kt(i),Mo.put(t,o)))):t.nodeType&&(o=Kt(t)),o&&e?Xt(o):o)}function ee(t,e,n,i,o,r){this.children=[],this.childFrags=[],this.vm=e,this.scope=o,this.inserted=!1,this.parentFrag=r,r&&r.childFrags.push(this),this.unlink=t(e,n,i,o,this);var s=this.single=1===n.childNodes.length&&!n.childNodes[0].__v_anchor;s?(this.node=n.childNodes[0],this.before=ne,this.remove=ie):(this.node=st("fragment-start"),this.end=st("fragment-end"),this.frag=n,J(this.node,n),n.appendChild(this.end),this.before=oe,this.remove=re),this.node.__v_frag=this}function ne(t,e){this.inserted=!0;var n=e!==!1?L:z;n(this.node,t,this.vm),H(this.node)&&this.callHook(se)}function ie(){this.inserted=!1;var t=H(this.node),e=this;this.beforeRemove(),R(this.node,this.vm,function(){t&&e.callHook(ae),e.destroy()})}function oe(t,e){this.inserted=!0;var n=this.vm,i=e!==!1?L:z;ct(this.node,this.end,function(e){i(e,t,n)}),H(this.node)&&this.callHook(se)}function re(){this.inserted=!1;var t=this,e=H(this.node);this.beforeRemove(),lt(this.node,this.end,this.vm,this.frag,function(){e&&t.callHook(ae),t.destroy()})}function se(t){!t._isAttached&&H(t.$el)&&t._callHook("attached")}function ae(t){t._isAttached&&!H(t.$el)&&t._callHook("detached")}function ce(t,e){this.vm=t;var n,i="string"==typeof e;i||rt(e)&&!e.hasAttribute("v-if")?n=te(e,!0):(n=document.createDocumentFragment(),n.appendChild(e)),this.template=n;var o,r=t.constructor.cid;if(r>0){var s=r+(i?e:ht(e));o=Bo.get(s),o||(o=Fe(n,t.$options,!0),Bo.put(s,o))}else o=Fe(n,t.$options,!0);this.linker=o}function le(t,e,n){var i=t.node.previousSibling;if(i){for(t=i.__v_frag;!(t&&t.forId===n&&t.inserted||i===e);){if(i=i.previousSibling,!i)return;t=i.__v_frag}return t}}function ue(t){var e=t.node;if(t.end)for(;!e.__vue__&&e!==t.end&&e.nextSibling;)e=e.nextSibling;return e.__vue__}function he(t){for(var e=-1,n=new Array(Math.floor(t));++e47&&e<58?parseInt(t,10):1===t.length&&(e=t.toUpperCase().charCodeAt(0),e>64&&e<91)?e:hr[t]});return n=[].concat.apply([],n),function(e){if(n.indexOf(e.keyCode)>-1)return t.call(this,e)}}function me(t){return function(e){return e.stopPropagation(),t.call(this,e)}}function ge(t){return function(e){return e.preventDefault(),t.call(this,e)}}function be(t){return function(e){if(e.target===e.currentTarget)return t.call(this,e)}}function _e(t){if(mr[t])return mr[t];var e=ye(t);return mr[t]=mr[e]=e,e}function ye(t){t=f(t);var e=d(t),n=e.charAt(0).toUpperCase()+e.slice(1);gr||(gr=document.createElement("div"));var i,o=pr.length;if("filter"!==e&&e in gr.style)return{kebab:t,camel:e};for(;o--;)if(i=fr[o]+n,i in gr.style)return{kebab:pr[o]+t,camel:i}}function xe(t){var e=[];if(In(t))for(var n=0,i=t.length;n=o?n():t[r].call(e,i)}var o=t.length,r=0;t[0].call(e,i)}function Ce(e,n,i){for(var o,r,a,c,l,u,h,p=[],v=Object.keys(n),m=v.length;m--;)if(r=v[m],o=n[r]||Sr,"production"===t.env.NODE_ENV||"$data"!==r)if(l=d(r),Vr.test(l)){if(h={name:r,path:l,options:o,mode:Tr.ONE_WAY,raw:null},a=f(r),null===(c=W(e,a))&&(null!==(c=W(e,a+".sync"))?h.mode=Tr.TWO_WAY:null!==(c=W(e,a+".once"))&&(h.mode=Tr.ONE_TIME)),null!==c)h.raw=c,u=j(c),c=u.expression,h.filters=u.filters,s(c)&&!u.filters?h.optimizedLiteral=!0:(h.dynamic=!0,"production"===t.env.NODE_ENV||h.mode!==Tr.TWO_WAY||Mr.test(c)||(h.mode=Tr.ONE_WAY,Ti("Cannot bind two-way prop with non-settable parent path: "+c,i))),h.parentPath=c,"production"!==t.env.NODE_ENV&&o.twoWay&&h.mode!==Tr.TWO_WAY&&Ti('Prop "'+r+'" expects a two-way binding type.',i);else if(null!==(c=U(e,a)))h.raw=c;else if("production"!==t.env.NODE_ENV){var g=l.toLowerCase();c=/[A-Z\-]/.test(r)&&(e.getAttribute(g)||e.getAttribute(":"+g)||e.getAttribute("v-bind:"+g)||e.getAttribute(":"+g+".once")||e.getAttribute("v-bind:"+g+".once")||e.getAttribute(":"+g+".sync")||e.getAttribute("v-bind:"+g+".sync")),c?Ti("Possible usage error for prop `"+g+"` - did you mean `"+a+"`? HTML is case-insensitive, remember to use kebab-case for props in templates.",i):o.required&&Ti("Missing required prop: "+r,i)}p.push(h)}else"production"!==t.env.NODE_ENV&&Ti('Invalid prop key: "'+r+'". Prop keys must be valid identifiers.',i);else Ti("Do not use $data as prop.",i);return Ee(p)}function Ee(t){return function(e,n){e._props={};for(var i,o,s,a,c,d=e.$options.propsData,p=t.length;p--;)if(i=t[p],c=i.raw,o=i.path,s=i.options,e._props[o]=i,d&&r(d,o)&&$e(e,i,d[o]),null===c)$e(e,i,void 0);else if(i.dynamic)i.mode===Tr.ONE_TIME?(a=(n||e._context||e).$get(i.parentPath),$e(e,i,a)):e._context?e._bindDir({name:"prop",def:Lr,prop:i},null,null,n):$e(e,i,e.$get(i.parentPath));else if(i.optimizedLiteral){var v=h(c);a=v===c?u(l(c)):v,$e(e,i,a)}else a=s.type===Boolean&&(""===c||c===f(i.name))||c,$e(e,i,a)}}function Ne(t,e,n,i){var o=e.dynamic&&Wt(e.parentPath),r=n;void 0===r&&(r=je(t,e)),r=De(e,r,t);var s=r!==n;Ae(e,r,t)||(r=void 0),o&&!s?wt(function(){i(r)}):i(r)}function $e(t,e,n){Ne(t,e,n,function(n){$t(t,e.path,n)})}function Oe(t,e,n){Ne(t,e,n,function(n){t[e.path]=n})}function je(e,n){var i=n.options;if(!r(i,"default"))return i.type!==Boolean&&void 0;var o=i["default"];return _(o)&&"production"!==t.env.NODE_ENV&&Ti('Invalid default value for prop "'+n.name+'": Props with type Object/Array must use a factory function to return the default value.',e),"function"==typeof o&&i.type!==Function?o.call(e):o}function Ae(e,n,i){if(!e.options.required&&(null===e.raw||null==n))return!0;var o=e.options,r=o.type,s=!r,a=[];if(r){In(r)||(r=[r]);for(var c=0;ce?-1:t===e?0:1}function Ue(t,e,n,i){function o(o){We(t,e,o),n&&i&&We(n,i)}return o.dirs=e,o}function We(e,n,i){for(var o=n.length;o--;)n[o]._teardown(),"production"===t.env.NODE_ENV||i||e._directives.$remove(n[o])}function Be(t,e,n,i){var o=Ce(e,n,t),r=Ie(function(){o(t,i)},t);return Ue(t,r)}function ze(e,n,i){var o,r,s=n._containerAttrs,a=n._replacerAttrs;if(11!==e.nodeType)n._asComponent?(s&&i&&(o=sn(s,i)),a&&(r=sn(a,n))):r=sn(e.attributes,n);else if("production"!==t.env.NODE_ENV&&s){var c=s.filter(function(t){return t.name.indexOf("_v-")<0&&!Qr.test(t.name)&&"slot"!==t.name}).map(function(t){return'"'+t.name+'"'});if(c.length){var l=c.length>1;Ti("Attribute"+(l?"s ":" ")+c.join(", ")+(l?" are":" is")+" ignored on component <"+n.el.tagName.toLowerCase()+"> because the component is a fragment instance: http://vuejs.org/guide/components.html#Fragment-Instance")}}return n._containerAttrs=n._replacerAttrs=null,function(t,e,n){var i,s=t._context;s&&o&&(i=Ie(function(){o(s,e,null,n)},s));var a=Ie(function(){r&&r(t,e)},t);return Ue(t,a,s,i)}}function Ge(t,e){var n=t.nodeType;return 1!==n||un(t)?3===n&&t.data.trim()?Je(t,e):null:qe(t,e)}function qe(t,e){if("TEXTAREA"===t.tagName){var n=T(t.value);n&&(t.setAttribute(":value",S(n)),t.value="")}var i,o=t.hasAttributes(),r=o&&g(t.attributes);return o&&(i=nn(t,r,e)),i||(i=tn(t,e)),i||(i=en(t,e)),!i&&o&&(i=sn(r,e)),i}function Je(t,e){if(t._skip)return Ye;var n=T(t.wholeText);if(!n)return null;for(var i=t.nextSibling;i&&3===i.nodeType;)i._skip=!0,i=i.nextSibling;for(var o,r,s=document.createDocumentFragment(),a=0,c=n.length;ap.priority)&&(p=d,u=o.name,a=an(o.name),s=o.value,l=c[1],h=c[2]));return p?rn(t,l,s,n,p,u,h,a):void 0}function on(){}function rn(t,e,n,i,o,r,s,a){var c=j(n),l={name:e,arg:s,expression:c.expression,filters:c.filters,raw:n,attr:r,modifiers:a,def:o};"for"!==e&&"router-view"!==e||(l.ref=at(t));var u=function(t,e,n,i,o){l.ref&&$t((i||t).$refs,l.ref,null),t._bindDir(l,e,n,i,o)};return u.terminal=!0,u}function sn(e,n){function i(t,e,n){var i=n&&ln(n),o=!i&&j(s);m.push({name:t,attr:a,raw:c,def:e,arg:u,modifiers:h,expression:o&&o.expression,filters:o&&o.filters,interp:n,hasOneTime:i})}for(var o,r,s,a,c,l,u,h,d,p,f,v=e.length,m=[];v--;)if(o=e[v],r=a=o.name,s=c=o.value,p=T(s),u=null,h=an(r),r=r.replace(Kr,""),p)s=S(p),u=r,i("bind",jr.bind,p),"production"!==t.env.NODE_ENV&&"class"===r&&Array.prototype.some.call(e,function(t){return":class"===t.name||"v-bind:class"===t.name})&&Ti('class="'+c+'": Do not mix mustache interpolation and v-bind for "class" on the same element. Use one or the other.',n);else if(Xr.test(r))h.literal=!Yr.test(r),i("transition",Jr.transition);else if(Qr.test(r))u=r.replace(Qr,""),i("on",jr.on);else if(Yr.test(r))l=r.replace(Yr,""),"style"===l||"class"===l?i(l,Jr[l]):(u=l,i("bind",jr.bind));else if(f=r.match(Zr)){if(l=f[1],u=f[2],"else"===l)continue;d=yt(n,"directives",l,!0),d&&i(l,d)}if(m.length)return cn(m)}function an(t){var e=Object.create(null),n=t.match(Kr);if(n)for(var i=n.length;i--;)e[n[i].slice(1)]=!0;return e}function cn(t){return function(e,n,i,o,r){for(var s=t.length;s--;)e._bindDir(t[s],n,i,o,r)}}function ln(t){for(var e=t.length;e--;)if(t[e].oneTime)return!0}function un(t){return"SCRIPT"===t.tagName&&(!t.hasAttribute("type")||"text/javascript"===t.getAttribute("type"))}function hn(t,e){return e&&(e._containerAttrs=pn(t)),rt(t)&&(t=te(t)),e&&(e._asComponent&&!e.template&&(e.template=""),e.template&&(e._content=nt(t),t=dn(t,e))),ut(t)&&(J(st("v-start",!0),t),t.appendChild(st("v-end",!0))),t}function dn(e,n){var i=n.template,o=te(i,!0);if(o){var r=o.firstChild,s=r.tagName&&r.tagName.toLowerCase();return n.replace?(e===document.body&&"production"!==t.env.NODE_ENV&&Ti("You are mounting an instance with a template to . This will replace entirely. You should probably use `replace: false` here."),o.childNodes.length>1||1!==r.nodeType||"component"===s||yt(n,"components",s)||B(r,"is")||yt(n,"elementDirectives",s)||r.hasAttribute("v-for")||r.hasAttribute("v-if")?o:(n._replacerAttrs=pn(r),fn(e,r),r)):(e.appendChild(o),e)}"production"!==t.env.NODE_ENV&&Ti("Invalid template option: "+i)}function pn(t){if(1===t.nodeType&&t.hasAttributes())return g(t.attributes)}function fn(t,e){for(var n,i,o=t.attributes,r=o.length;r--;)n=o[r].name,i=o[r].value,e.hasAttribute(n)||ns.test(n)?"class"===n&&!T(i)&&(i=i.trim())&&i.split(/\s+/).forEach(function(t){tt(e,t)}):e.setAttribute(n,i)}function vn(e,n){if(n){for(var i,o,r=e._slotContents=Object.create(null),s=0,a=n.children.length;s1?g(n):n;var o=e&&n.some(function(t){return t._fromParent});o&&(i=!1);for(var r=g(arguments,1),s=0,a=n.length;se?r:-r}var n=null,i=void 0;t=ls(t);var o=g(arguments,1),r=o[o.length-1];"number"==typeof r?(r=r<0?-1:1,o=o.length>1?o.slice(0,-1):o):r=1;var s=o[0];return s?("function"==typeof s?n=function(t,e){return s(t,e)*r}:(i=Array.prototype.concat.apply([],o),n=function(t,o,r){return r=r||0,r>=i.length-1?e(t,o,r):e(t,o,r)||n(t,o,r+1)}),t.slice().sort(n)):t}function Dn(t,e){var n;if(y(t)){var i=Object.keys(t);for(n=i.length;n--;)if(Dn(t[i[n]],e))return!0}else if(In(t)){for(n=t.length;n--;)if(Dn(t[n],e))return!0}else if(null!=t)return t.toString().toLowerCase().indexOf(e)>-1}function Tn(e){function n(t){return new Function("return function "+v(t)+" (options) { this._init(options) }")()}e.options={directives:jr,elementDirectives:cs,filters:hs,transitions:{},components:{},partials:{},replace:!0},e.util=Gi,e.config=Di,e.set=i,e["delete"]=o,e.nextTick=oi,e.compiler=is,e.FragmentFactory=ce,e.internalDirectives=Jr,e.parsers={path:uo,text:Oi,template:Uo,directive:wi,expression:Eo},e.cid=0;var r=1;e.extend=function(e){e=e||{};var i=this,o=0===i.cid;if(o&&e._Ctor)return e._Ctor;var s=e.name||i.options.name;"production"!==t.env.NODE_ENV&&(/^[a-zA-Z][\w-]*$/.test(s)||(Ti('Invalid component name: "'+s+'". Component names can only contain alphanumeric characaters and the hyphen.'),s=null));var a=n(s||"VueComponent");return a.prototype=Object.create(i.prototype),a.prototype.constructor=a,a.cid=r++,a.options=_t(i.options,e),a["super"]=i,a.extend=i.extend,Di._assetTypes.forEach(function(t){a[t]=i[t]}),s&&(a.options.components[s]=a),o&&(e._Ctor=a),a},e.use=function(t){if(!t.installed){var e=g(arguments,1);return e.unshift(this),"function"==typeof t.install?t.install.apply(t,e):t.apply(null,e),t.installed=!0,this}},e.mixin=function(t){e.options=_t(e.options,t)},Di._assetTypes.forEach(function(n){e[n]=function(i,o){return o?("production"!==t.env.NODE_ENV&&"component"===n&&(Pi.test(i)||Li.test(i))&&Ti("Do not use built-in or reserved HTML elements as component id: "+i),"component"===n&&y(o)&&(o.name||(o.name=i),o=e.extend(o)),this.options[n+"s"][i]=o,o):this.options[n+"s"][i]}}),b(e.transition,Vi)}var Sn=Object.prototype.hasOwnProperty,Vn=/^\s?(true|false|-?[\d\.]+|'[^']*'|"[^"]*")\s?$/,Mn=/-(\w)/g,Pn=/([a-z\d])([A-Z])/g,Ln=/(?:^|[-_\/])(\w)/g,Rn=Object.prototype.toString,Fn="[object Object]",In=Array.isArray,Hn="__proto__"in{},Un="undefined"!=typeof window&&"[object Object]"!==Object.prototype.toString.call(window),Wn=Un&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__,Bn=Un&&window.navigator.userAgent.toLowerCase(),zn=Bn&&Bn.indexOf("trident")>0,Gn=Bn&&Bn.indexOf("msie 9.0")>0,qn=Bn&&Bn.indexOf("android")>0,Jn=Bn&&/(iphone|ipad|ipod|ios)/i.test(Bn),Yn=Jn&&Bn.match(/os ([\d_]+)/),Qn=Yn&&Yn[1].split("_"),Zn=Qn&&Number(Qn[0])>=9&&Number(Qn[1])>=3&&!window.indexedDB,Kn=void 0,Xn=void 0,ti=void 0,ei=void 0;if(Un&&!Gn){var ni=void 0===window.ontransitionend&&void 0!==window.onwebkittransitionend,ii=void 0===window.onanimationend&&void 0!==window.onwebkitanimationend;Kn=ni?"WebkitTransition":"transition",Xn=ni?"webkitTransitionEnd":"transitionend",ti=ii?"WebkitAnimation":"animation",ei=ii?"webkitAnimationEnd":"animationend"}var oi=function(){function t(){o=!1;var t=i.slice(0);i=[];for(var e=0;e)":""}}();var Vi=Object.freeze({appendWithTransition:P,beforeWithTransition:L,removeWithTransition:R,applyTransition:F}),Mi=/^v-ref:/,Pi=/^(div|p|span|img|a|b|i|br|ul|ol|li|h1|h2|h3|h4|h5|h6|code|pre|table|th|td|tr|form|label|input|select|option|nav|article|section|header|footer)$/i,Li=/^(slot|partial|component)$/i,Ri=void 0;"production"!==t.env.NODE_ENV&&(Ri=function(t,e){return e.indexOf("-")>-1?t.constructor===window.HTMLUnknownElement||t.constructor===window.HTMLElement:/HTMLUnknownElement/.test(t.toString())&&!/^(data|time|rtc|rb|details|dialog|summary)$/.test(e)});var Fi=Di.optionMergeStrategies=Object.create(null);Fi.data=function(e,n,i){return i?e||n?function(){var t="function"==typeof n?n.call(i):n,o="function"==typeof e?e.call(i):void 0;return t?ft(t,o):o}:void 0:n?"function"!=typeof n?("production"!==t.env.NODE_ENV&&Ti('The "data" option should be a function that returns a per-instance value in component definitions.',i),e):e?function(){return ft(n.call(this),e.call(this))}:n:e},Fi.el=function(e,n,i){if(!i&&n&&"function"!=typeof n)return void("production"!==t.env.NODE_ENV&&Ti('The "el" option should be a function that returns a per-instance value in component definitions.',i));var o=n||e;return i&&"function"==typeof o?o.call(i):o},Fi.init=Fi.created=Fi.ready=Fi.attached=Fi.detached=Fi.beforeCompile=Fi.compiled=Fi.beforeDestroy=Fi.destroyed=Fi.activate=function(t,e){return e?t?t.concat(e):In(e)?e:[e]:t},Di._assetTypes.forEach(function(t){Fi[t+"s"]=vt}),Fi.watch=Fi.events=function(t,e){if(!e)return t;if(!t)return e;var n={};b(n,t);for(var i in e){var o=n[i],r=e[i];o&&!In(o)&&(o=[o]),n[i]=o?o.concat(r):[r]}return n},Fi.props=Fi.methods=Fi.computed=function(t,e){if(!e)return t;if(!t)return e;var n=Object.create(null);return b(n,t),b(n,e),n};var Ii=function(t,e){return void 0===e?t:e},Hi=0;xt.target=null,xt.prototype.addSub=function(t){this.subs.push(t)},xt.prototype.removeSub=function(t){this.subs.$remove(t)},xt.prototype.depend=function(){xt.target.addDep(this)},xt.prototype.notify=function(){for(var t=g(this.subs),e=0,n=t.length;e=this.length&&(this.length=Number(t)+1),this.splice(t,1,e)[0]}),x(Ui,"$remove",function(t){if(this.length){var e=k(this,t);return e>-1?this.splice(e,1):void 0}});var Bi=Object.getOwnPropertyNames(Wi),zi=!0;kt.prototype.walk=function(t){for(var e=Object.keys(t),n=0,i=e.length;n",""],tr:[2,"","
"],col:[2,"","
"]};Po.td=Po.th=[3,"","
"],Po.option=Po.optgroup=[1,'"],Po.thead=Po.tbody=Po.colgroup=Po.caption=Po.tfoot=[1,"","
"],Po.g=Po.defs=Po.symbol=Po.use=Po.image=Po.text=Po.circle=Po.ellipse=Po.line=Po.path=Po.polygon=Po.polyline=Po.rect=[1,'',""];var Lo=/<([\w:-]+)/,Ro=/&#?\w+?;/,Fo=/ E\n }\n entry.newer = undefined; // D --x\n entry.older = this.tail; // D. --> E\n if (this.tail) {\n this.tail.newer = entry; // E. <-- D\n }\n this.tail = entry;\n return returnEntry ? entry : entry.value;\n};\n\nvar cache$1 = new Cache(1000);\nvar filterTokenRE = /[^\\s'\"]+|'[^']*'|\"[^\"]*\"/g;\nvar reservedArgRE = /^in$|^-?\\d+/;\n\n/**\n * Parser state\n */\n\nvar str;\nvar dir;\nvar c;\nvar prev;\nvar i;\nvar l;\nvar lastFilterIndex;\nvar inSingle;\nvar inDouble;\nvar curly;\nvar square;\nvar paren;\n/**\n * Push a filter to the current directive object\n */\n\nfunction pushFilter() {\n var exp = str.slice(lastFilterIndex, i).trim();\n var filter;\n if (exp) {\n filter = {};\n var tokens = exp.match(filterTokenRE);\n filter.name = tokens[0];\n if (tokens.length > 1) {\n filter.args = tokens.slice(1).map(processFilterArg);\n }\n }\n if (filter) {\n (dir.filters = dir.filters || []).push(filter);\n }\n lastFilterIndex = i + 1;\n}\n\n/**\n * Check if an argument is dynamic and strip quotes.\n *\n * @param {String} arg\n * @return {Object}\n */\n\nfunction processFilterArg(arg) {\n if (reservedArgRE.test(arg)) {\n return {\n value: toNumber(arg),\n dynamic: false\n };\n } else {\n var stripped = stripQuotes(arg);\n var dynamic = stripped === arg;\n return {\n value: dynamic ? arg : stripped,\n dynamic: dynamic\n };\n }\n}\n\n/**\n * Parse a directive value and extract the expression\n * and its filters into a descriptor.\n *\n * Example:\n *\n * \"a + 1 | uppercase\" will yield:\n * {\n * expression: 'a + 1',\n * filters: [\n * { name: 'uppercase', args: null }\n * ]\n * }\n *\n * @param {String} s\n * @return {Object}\n */\n\nfunction parseDirective(s) {\n var hit = cache$1.get(s);\n if (hit) {\n return hit;\n }\n\n // reset parser state\n str = s;\n inSingle = inDouble = false;\n curly = square = paren = 0;\n lastFilterIndex = 0;\n dir = {};\n\n for (i = 0, l = str.length; i < l; i++) {\n prev = c;\n c = str.charCodeAt(i);\n if (inSingle) {\n // check single quote\n if (c === 0x27 && prev !== 0x5C) inSingle = !inSingle;\n } else if (inDouble) {\n // check double quote\n if (c === 0x22 && prev !== 0x5C) inDouble = !inDouble;\n } else if (c === 0x7C && // pipe\n str.charCodeAt(i + 1) !== 0x7C && str.charCodeAt(i - 1) !== 0x7C) {\n if (dir.expression == null) {\n // first filter, end of expression\n lastFilterIndex = i + 1;\n dir.expression = str.slice(0, i).trim();\n } else {\n // already has filter\n pushFilter();\n }\n } else {\n switch (c) {\n case 0x22:\n inDouble = true;break; // \"\n case 0x27:\n inSingle = true;break; // '\n case 0x28:\n paren++;break; // (\n case 0x29:\n paren--;break; // )\n case 0x5B:\n square++;break; // [\n case 0x5D:\n square--;break; // ]\n case 0x7B:\n curly++;break; // {\n case 0x7D:\n curly--;break; // }\n }\n }\n }\n\n if (dir.expression == null) {\n dir.expression = str.slice(0, i).trim();\n } else if (lastFilterIndex !== 0) {\n pushFilter();\n }\n\n cache$1.put(s, dir);\n return dir;\n}\n\nvar directive = Object.freeze({\n parseDirective: parseDirective\n});\n\nvar regexEscapeRE = /[-.*+?^${}()|[\\]\\/\\\\]/g;\nvar cache = undefined;\nvar tagRE = undefined;\nvar htmlRE = undefined;\n/**\n * Escape a string so it can be used in a RegExp\n * constructor.\n *\n * @param {String} str\n */\n\nfunction escapeRegex(str) {\n return str.replace(regexEscapeRE, '\\\\$&');\n}\n\nfunction compileRegex() {\n var open = escapeRegex(config.delimiters[0]);\n var close = escapeRegex(config.delimiters[1]);\n var unsafeOpen = escapeRegex(config.unsafeDelimiters[0]);\n var unsafeClose = escapeRegex(config.unsafeDelimiters[1]);\n tagRE = new RegExp(unsafeOpen + '((?:.|\\\\n)+?)' + unsafeClose + '|' + open + '((?:.|\\\\n)+?)' + close, 'g');\n htmlRE = new RegExp('^' + unsafeOpen + '((?:.|\\\\n)+?)' + unsafeClose + '$');\n // reset cache\n cache = new Cache(1000);\n}\n\n/**\n * Parse a template text string into an array of tokens.\n *\n * @param {String} text\n * @return {Array | null}\n * - {String} type\n * - {String} value\n * - {Boolean} [html]\n * - {Boolean} [oneTime]\n */\n\nfunction parseText(text) {\n if (!cache) {\n compileRegex();\n }\n var hit = cache.get(text);\n if (hit) {\n return hit;\n }\n if (!tagRE.test(text)) {\n return null;\n }\n var tokens = [];\n var lastIndex = tagRE.lastIndex = 0;\n var match, index, html, value, first, oneTime;\n /* eslint-disable no-cond-assign */\n while (match = tagRE.exec(text)) {\n /* eslint-enable no-cond-assign */\n index = match.index;\n // push text token\n if (index > lastIndex) {\n tokens.push({\n value: text.slice(lastIndex, index)\n });\n }\n // tag token\n html = htmlRE.test(match[0]);\n value = html ? match[1] : match[2];\n first = value.charCodeAt(0);\n oneTime = first === 42; // *\n value = oneTime ? value.slice(1) : value;\n tokens.push({\n tag: true,\n value: value.trim(),\n html: html,\n oneTime: oneTime\n });\n lastIndex = index + match[0].length;\n }\n if (lastIndex < text.length) {\n tokens.push({\n value: text.slice(lastIndex)\n });\n }\n cache.put(text, tokens);\n return tokens;\n}\n\n/**\n * Format a list of tokens into an expression.\n * e.g. tokens parsed from 'a {{b}} c' can be serialized\n * into one single expression as '\"a \" + b + \" c\"'.\n *\n * @param {Array} tokens\n * @param {Vue} [vm]\n * @return {String}\n */\n\nfunction tokensToExp(tokens, vm) {\n if (tokens.length > 1) {\n return tokens.map(function (token) {\n return formatToken(token, vm);\n }).join('+');\n } else {\n return formatToken(tokens[0], vm, true);\n }\n}\n\n/**\n * Format a single token.\n *\n * @param {Object} token\n * @param {Vue} [vm]\n * @param {Boolean} [single]\n * @return {String}\n */\n\nfunction formatToken(token, vm, single) {\n return token.tag ? token.oneTime && vm ? '\"' + vm.$eval(token.value) + '\"' : inlineFilters(token.value, single) : '\"' + token.value + '\"';\n}\n\n/**\n * For an attribute with multiple interpolation tags,\n * e.g. attr=\"some-{{thing | filter}}\", in order to combine\n * the whole thing into a single watchable expression, we\n * have to inline those filters. This function does exactly\n * that. This is a bit hacky but it avoids heavy changes\n * to directive parser and watcher mechanism.\n *\n * @param {String} exp\n * @param {Boolean} single\n * @return {String}\n */\n\nvar filterRE = /[^|]\\|[^|]/;\nfunction inlineFilters(exp, single) {\n if (!filterRE.test(exp)) {\n return single ? exp : '(' + exp + ')';\n } else {\n var dir = parseDirective(exp);\n if (!dir.filters) {\n return '(' + exp + ')';\n } else {\n return 'this._applyFilters(' + dir.expression + // value\n ',null,' + // oldValue (null for read)\n JSON.stringify(dir.filters) + // filter descriptors\n ',false)'; // write?\n }\n }\n}\n\nvar text = Object.freeze({\n compileRegex: compileRegex,\n parseText: parseText,\n tokensToExp: tokensToExp\n});\n\nvar delimiters = ['{{', '}}'];\nvar unsafeDelimiters = ['{{{', '}}}'];\n\nvar config = Object.defineProperties({\n\n /**\n * Whether to print debug messages.\n * Also enables stack trace for warnings.\n *\n * @type {Boolean}\n */\n\n debug: false,\n\n /**\n * Whether to suppress warnings.\n *\n * @type {Boolean}\n */\n\n silent: false,\n\n /**\n * Whether to use async rendering.\n */\n\n async: true,\n\n /**\n * Whether to warn against errors caught when evaluating\n * expressions.\n */\n\n warnExpressionErrors: true,\n\n /**\n * Whether to allow devtools inspection.\n * Disabled by default in production builds.\n */\n\n devtools: process.env.NODE_ENV !== 'production',\n\n /**\n * Internal flag to indicate the delimiters have been\n * changed.\n *\n * @type {Boolean}\n */\n\n _delimitersChanged: true,\n\n /**\n * List of asset types that a component can own.\n *\n * @type {Array}\n */\n\n _assetTypes: ['component', 'directive', 'elementDirective', 'filter', 'transition', 'partial'],\n\n /**\n * prop binding modes\n */\n\n _propBindingModes: {\n ONE_WAY: 0,\n TWO_WAY: 1,\n ONE_TIME: 2\n },\n\n /**\n * Max circular updates allowed in a batcher flush cycle.\n */\n\n _maxUpdateCount: 100\n\n}, {\n delimiters: { /**\n * Interpolation delimiters. Changing these would trigger\n * the text parser to re-compile the regular expressions.\n *\n * @type {Array}\n */\n\n get: function get() {\n return delimiters;\n },\n set: function set(val) {\n delimiters = val;\n compileRegex();\n },\n configurable: true,\n enumerable: true\n },\n unsafeDelimiters: {\n get: function get() {\n return unsafeDelimiters;\n },\n set: function set(val) {\n unsafeDelimiters = val;\n compileRegex();\n },\n configurable: true,\n enumerable: true\n }\n});\n\nvar warn = undefined;\nvar formatComponentName = undefined;\n\nif (process.env.NODE_ENV !== 'production') {\n (function () {\n var hasConsole = typeof console !== 'undefined';\n\n warn = function (msg, vm) {\n if (hasConsole && !config.silent) {\n console.error('[Vue warn]: ' + msg + (vm ? formatComponentName(vm) : ''));\n }\n };\n\n formatComponentName = function (vm) {\n var name = vm._isVue ? vm.$options.name : vm.name;\n return name ? ' (found in component: <' + hyphenate(name) + '>)' : '';\n };\n })();\n}\n\n/**\n * Append with transition.\n *\n * @param {Element} el\n * @param {Element} target\n * @param {Vue} vm\n * @param {Function} [cb]\n */\n\nfunction appendWithTransition(el, target, vm, cb) {\n applyTransition(el, 1, function () {\n target.appendChild(el);\n }, vm, cb);\n}\n\n/**\n * InsertBefore with transition.\n *\n * @param {Element} el\n * @param {Element} target\n * @param {Vue} vm\n * @param {Function} [cb]\n */\n\nfunction beforeWithTransition(el, target, vm, cb) {\n applyTransition(el, 1, function () {\n before(el, target);\n }, vm, cb);\n}\n\n/**\n * Remove with transition.\n *\n * @param {Element} el\n * @param {Vue} vm\n * @param {Function} [cb]\n */\n\nfunction removeWithTransition(el, vm, cb) {\n applyTransition(el, -1, function () {\n remove(el);\n }, vm, cb);\n}\n\n/**\n * Apply transitions with an operation callback.\n *\n * @param {Element} el\n * @param {Number} direction\n * 1: enter\n * -1: leave\n * @param {Function} op - the actual DOM operation\n * @param {Vue} vm\n * @param {Function} [cb]\n */\n\nfunction applyTransition(el, direction, op, vm, cb) {\n var transition = el.__v_trans;\n if (!transition ||\n // skip if there are no js hooks and CSS transition is\n // not supported\n !transition.hooks && !transitionEndEvent ||\n // skip transitions for initial compile\n !vm._isCompiled ||\n // if the vm is being manipulated by a parent directive\n // during the parent's compilation phase, skip the\n // animation.\n vm.$parent && !vm.$parent._isCompiled) {\n op();\n if (cb) cb();\n return;\n }\n var action = direction > 0 ? 'enter' : 'leave';\n transition[action](op, cb);\n}\n\nvar transition = Object.freeze({\n appendWithTransition: appendWithTransition,\n beforeWithTransition: beforeWithTransition,\n removeWithTransition: removeWithTransition,\n applyTransition: applyTransition\n});\n\n/**\n * Query an element selector if it's not an element already.\n *\n * @param {String|Element} el\n * @return {Element}\n */\n\nfunction query(el) {\n if (typeof el === 'string') {\n var selector = el;\n el = document.querySelector(el);\n if (!el) {\n process.env.NODE_ENV !== 'production' && warn('Cannot find element: ' + selector);\n }\n }\n return el;\n}\n\n/**\n * Check if a node is in the document.\n * Note: document.documentElement.contains should work here\n * but always returns false for comment nodes in phantomjs,\n * making unit tests difficult. This is fixed by doing the\n * contains() check on the node's parentNode instead of\n * the node itself.\n *\n * @param {Node} node\n * @return {Boolean}\n */\n\nfunction inDoc(node) {\n if (!node) return false;\n var doc = node.ownerDocument.documentElement;\n var parent = node.parentNode;\n return doc === node || doc === parent || !!(parent && parent.nodeType === 1 && doc.contains(parent));\n}\n\n/**\n * Get and remove an attribute from a node.\n *\n * @param {Node} node\n * @param {String} _attr\n */\n\nfunction getAttr(node, _attr) {\n var val = node.getAttribute(_attr);\n if (val !== null) {\n node.removeAttribute(_attr);\n }\n return val;\n}\n\n/**\n * Get an attribute with colon or v-bind: prefix.\n *\n * @param {Node} node\n * @param {String} name\n * @return {String|null}\n */\n\nfunction getBindAttr(node, name) {\n var val = getAttr(node, ':' + name);\n if (val === null) {\n val = getAttr(node, 'v-bind:' + name);\n }\n return val;\n}\n\n/**\n * Check the presence of a bind attribute.\n *\n * @param {Node} node\n * @param {String} name\n * @return {Boolean}\n */\n\nfunction hasBindAttr(node, name) {\n return node.hasAttribute(name) || node.hasAttribute(':' + name) || node.hasAttribute('v-bind:' + name);\n}\n\n/**\n * Insert el before target\n *\n * @param {Element} el\n * @param {Element} target\n */\n\nfunction before(el, target) {\n target.parentNode.insertBefore(el, target);\n}\n\n/**\n * Insert el after target\n *\n * @param {Element} el\n * @param {Element} target\n */\n\nfunction after(el, target) {\n if (target.nextSibling) {\n before(el, target.nextSibling);\n } else {\n target.parentNode.appendChild(el);\n }\n}\n\n/**\n * Remove el from DOM\n *\n * @param {Element} el\n */\n\nfunction remove(el) {\n el.parentNode.removeChild(el);\n}\n\n/**\n * Prepend el to target\n *\n * @param {Element} el\n * @param {Element} target\n */\n\nfunction prepend(el, target) {\n if (target.firstChild) {\n before(el, target.firstChild);\n } else {\n target.appendChild(el);\n }\n}\n\n/**\n * Replace target with el\n *\n * @param {Element} target\n * @param {Element} el\n */\n\nfunction replace(target, el) {\n var parent = target.parentNode;\n if (parent) {\n parent.replaceChild(el, target);\n }\n}\n\n/**\n * Add event listener shorthand.\n *\n * @param {Element} el\n * @param {String} event\n * @param {Function} cb\n * @param {Boolean} [useCapture]\n */\n\nfunction on(el, event, cb, useCapture) {\n el.addEventListener(event, cb, useCapture);\n}\n\n/**\n * Remove event listener shorthand.\n *\n * @param {Element} el\n * @param {String} event\n * @param {Function} cb\n */\n\nfunction off(el, event, cb) {\n el.removeEventListener(event, cb);\n}\n\n/**\n * For IE9 compat: when both class and :class are present\n * getAttribute('class') returns wrong value...\n *\n * @param {Element} el\n * @return {String}\n */\n\nfunction getClass(el) {\n var classname = el.className;\n if (typeof classname === 'object') {\n classname = classname.baseVal || '';\n }\n return classname;\n}\n\n/**\n * In IE9, setAttribute('class') will result in empty class\n * if the element also has the :class attribute; However in\n * PhantomJS, setting `className` does not work on SVG elements...\n * So we have to do a conditional check here.\n *\n * @param {Element} el\n * @param {String} cls\n */\n\nfunction setClass(el, cls) {\n /* istanbul ignore if */\n if (isIE9 && !/svg$/.test(el.namespaceURI)) {\n el.className = cls;\n } else {\n el.setAttribute('class', cls);\n }\n}\n\n/**\n * Add class with compatibility for IE & SVG\n *\n * @param {Element} el\n * @param {String} cls\n */\n\nfunction addClass(el, cls) {\n if (el.classList) {\n el.classList.add(cls);\n } else {\n var cur = ' ' + getClass(el) + ' ';\n if (cur.indexOf(' ' + cls + ' ') < 0) {\n setClass(el, (cur + cls).trim());\n }\n }\n}\n\n/**\n * Remove class with compatibility for IE & SVG\n *\n * @param {Element} el\n * @param {String} cls\n */\n\nfunction removeClass(el, cls) {\n if (el.classList) {\n el.classList.remove(cls);\n } else {\n var cur = ' ' + getClass(el) + ' ';\n var tar = ' ' + cls + ' ';\n while (cur.indexOf(tar) >= 0) {\n cur = cur.replace(tar, ' ');\n }\n setClass(el, cur.trim());\n }\n if (!el.className) {\n el.removeAttribute('class');\n }\n}\n\n/**\n * Extract raw content inside an element into a temporary\n * container div\n *\n * @param {Element} el\n * @param {Boolean} asFragment\n * @return {Element|DocumentFragment}\n */\n\nfunction extractContent(el, asFragment) {\n var child;\n var rawContent;\n /* istanbul ignore if */\n if (isTemplate(el) && isFragment(el.content)) {\n el = el.content;\n }\n if (el.hasChildNodes()) {\n trimNode(el);\n rawContent = asFragment ? document.createDocumentFragment() : document.createElement('div');\n /* eslint-disable no-cond-assign */\n while (child = el.firstChild) {\n /* eslint-enable no-cond-assign */\n rawContent.appendChild(child);\n }\n }\n return rawContent;\n}\n\n/**\n * Trim possible empty head/tail text and comment\n * nodes inside a parent.\n *\n * @param {Node} node\n */\n\nfunction trimNode(node) {\n var child;\n /* eslint-disable no-sequences */\n while ((child = node.firstChild, isTrimmable(child))) {\n node.removeChild(child);\n }\n while ((child = node.lastChild, isTrimmable(child))) {\n node.removeChild(child);\n }\n /* eslint-enable no-sequences */\n}\n\nfunction isTrimmable(node) {\n return node && (node.nodeType === 3 && !node.data.trim() || node.nodeType === 8);\n}\n\n/**\n * Check if an element is a template tag.\n * Note if the template appears inside an SVG its tagName\n * will be in lowercase.\n *\n * @param {Element} el\n */\n\nfunction isTemplate(el) {\n return el.tagName && el.tagName.toLowerCase() === 'template';\n}\n\n/**\n * Create an \"anchor\" for performing dom insertion/removals.\n * This is used in a number of scenarios:\n * - fragment instance\n * - v-html\n * - v-if\n * - v-for\n * - component\n *\n * @param {String} content\n * @param {Boolean} persist - IE trashes empty textNodes on\n * cloneNode(true), so in certain\n * cases the anchor needs to be\n * non-empty to be persisted in\n * templates.\n * @return {Comment|Text}\n */\n\nfunction createAnchor(content, persist) {\n var anchor = config.debug ? document.createComment(content) : document.createTextNode(persist ? ' ' : '');\n anchor.__v_anchor = true;\n return anchor;\n}\n\n/**\n * Find a component ref attribute that starts with $.\n *\n * @param {Element} node\n * @return {String|undefined}\n */\n\nvar refRE = /^v-ref:/;\n\nfunction findRef(node) {\n if (node.hasAttributes()) {\n var attrs = node.attributes;\n for (var i = 0, l = attrs.length; i < l; i++) {\n var name = attrs[i].name;\n if (refRE.test(name)) {\n return camelize(name.replace(refRE, ''));\n }\n }\n }\n}\n\n/**\n * Map a function to a range of nodes .\n *\n * @param {Node} node\n * @param {Node} end\n * @param {Function} op\n */\n\nfunction mapNodeRange(node, end, op) {\n var next;\n while (node !== end) {\n next = node.nextSibling;\n op(node);\n node = next;\n }\n op(end);\n}\n\n/**\n * Remove a range of nodes with transition, store\n * the nodes in a fragment with correct ordering,\n * and call callback when done.\n *\n * @param {Node} start\n * @param {Node} end\n * @param {Vue} vm\n * @param {DocumentFragment} frag\n * @param {Function} cb\n */\n\nfunction removeNodeRange(start, end, vm, frag, cb) {\n var done = false;\n var removed = 0;\n var nodes = [];\n mapNodeRange(start, end, function (node) {\n if (node === end) done = true;\n nodes.push(node);\n removeWithTransition(node, vm, onRemoved);\n });\n function onRemoved() {\n removed++;\n if (done && removed >= nodes.length) {\n for (var i = 0; i < nodes.length; i++) {\n frag.appendChild(nodes[i]);\n }\n cb && cb();\n }\n }\n}\n\n/**\n * Check if a node is a DocumentFragment.\n *\n * @param {Node} node\n * @return {Boolean}\n */\n\nfunction isFragment(node) {\n return node && node.nodeType === 11;\n}\n\n/**\n * Get outerHTML of elements, taking care\n * of SVG elements in IE as well.\n *\n * @param {Element} el\n * @return {String}\n */\n\nfunction getOuterHTML(el) {\n if (el.outerHTML) {\n return el.outerHTML;\n } else {\n var container = document.createElement('div');\n container.appendChild(el.cloneNode(true));\n return container.innerHTML;\n }\n}\n\nvar commonTagRE = /^(div|p|span|img|a|b|i|br|ul|ol|li|h1|h2|h3|h4|h5|h6|code|pre|table|th|td|tr|form|label|input|select|option|nav|article|section|header|footer)$/i;\nvar reservedTagRE = /^(slot|partial|component)$/i;\n\nvar isUnknownElement = undefined;\nif (process.env.NODE_ENV !== 'production') {\n isUnknownElement = function (el, tag) {\n if (tag.indexOf('-') > -1) {\n // http://stackoverflow.com/a/28210364/1070244\n return el.constructor === window.HTMLUnknownElement || el.constructor === window.HTMLElement;\n } else {\n return (/HTMLUnknownElement/.test(el.toString()) &&\n // Chrome returns unknown for several HTML5 elements.\n // https://code.google.com/p/chromium/issues/detail?id=540526\n // Firefox returns unknown for some \"Interactive elements.\"\n !/^(data|time|rtc|rb|details|dialog|summary)$/.test(tag)\n );\n }\n };\n}\n\n/**\n * Check if an element is a component, if yes return its\n * component id.\n *\n * @param {Element} el\n * @param {Object} options\n * @return {Object|undefined}\n */\n\nfunction checkComponentAttr(el, options) {\n var tag = el.tagName.toLowerCase();\n var hasAttrs = el.hasAttributes();\n if (!commonTagRE.test(tag) && !reservedTagRE.test(tag)) {\n if (resolveAsset(options, 'components', tag)) {\n return { id: tag };\n } else {\n var is = hasAttrs && getIsBinding(el, options);\n if (is) {\n return is;\n } else if (process.env.NODE_ENV !== 'production') {\n var expectedTag = options._componentNameMap && options._componentNameMap[tag];\n if (expectedTag) {\n warn('Unknown custom element: <' + tag + '> - ' + 'did you mean <' + expectedTag + '>? ' + 'HTML is case-insensitive, remember to use kebab-case in templates.');\n } else if (isUnknownElement(el, tag)) {\n warn('Unknown custom element: <' + tag + '> - did you ' + 'register the component correctly? For recursive components, ' + 'make sure to provide the \"name\" option.');\n }\n }\n }\n } else if (hasAttrs) {\n return getIsBinding(el, options);\n }\n}\n\n/**\n * Get \"is\" binding from an element.\n *\n * @param {Element} el\n * @param {Object} options\n * @return {Object|undefined}\n */\n\nfunction getIsBinding(el, options) {\n // dynamic syntax\n var exp = el.getAttribute('is');\n if (exp != null) {\n if (resolveAsset(options, 'components', exp)) {\n el.removeAttribute('is');\n return { id: exp };\n }\n } else {\n exp = getBindAttr(el, 'is');\n if (exp != null) {\n return { id: exp, dynamic: true };\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 *\n * All strategy functions follow the same signature:\n *\n * @param {*} parentVal\n * @param {*} childVal\n * @param {Vue} [vm]\n */\n\nvar strats = config.optionMergeStrategies = Object.create(null);\n\n/**\n * Helper that recursively merges two data objects together.\n */\n\nfunction mergeData(to, from) {\n var key, toVal, fromVal;\n for (key in from) {\n toVal = to[key];\n fromVal = from[key];\n if (!hasOwn(to, key)) {\n set(to, key, fromVal);\n } else if (isObject(toVal) && isObject(fromVal)) {\n mergeData(toVal, fromVal);\n }\n }\n return to;\n}\n\n/**\n * Data\n */\n\nstrats.data = function (parentVal, childVal, vm) {\n if (!vm) {\n // in a Vue.extend merge, both should be functions\n if (!childVal) {\n return parentVal;\n }\n if (typeof childVal !== 'function') {\n process.env.NODE_ENV !== 'production' && warn('The \"data\" option should be a function ' + 'that returns a per-instance value in component ' + 'definitions.', vm);\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(childVal.call(this), parentVal.call(this));\n };\n } else if (parentVal || childVal) {\n return function mergedInstanceDataFn() {\n // instance merge\n var instanceData = typeof childVal === 'function' ? childVal.call(vm) : childVal;\n var defaultData = typeof parentVal === 'function' ? parentVal.call(vm) : undefined;\n if (instanceData) {\n return mergeData(instanceData, defaultData);\n } else {\n return defaultData;\n }\n };\n }\n};\n\n/**\n * El\n */\n\nstrats.el = function (parentVal, childVal, vm) {\n if (!vm && childVal && typeof childVal !== 'function') {\n process.env.NODE_ENV !== 'production' && warn('The \"el\" option should be a function ' + 'that returns a per-instance value in component ' + 'definitions.', vm);\n return;\n }\n var ret = childVal || parentVal;\n // invoke the element factory if this is instance merge\n return vm && typeof ret === 'function' ? ret.call(vm) : ret;\n};\n\n/**\n * Hooks and param attributes are merged as arrays.\n */\n\nstrats.init = strats.created = strats.ready = strats.attached = strats.detached = strats.beforeCompile = strats.compiled = strats.beforeDestroy = strats.destroyed = strats.activate = function (parentVal, childVal) {\n return childVal ? parentVal ? parentVal.concat(childVal) : isArray(childVal) ? childVal : [childVal] : parentVal;\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 */\n\nfunction mergeAssets(parentVal, childVal) {\n var res = Object.create(parentVal || null);\n return childVal ? extend(res, guardArrayAssets(childVal)) : res;\n}\n\nconfig._assetTypes.forEach(function (type) {\n strats[type + 's'] = mergeAssets;\n});\n\n/**\n * Events & Watchers.\n *\n * Events & watchers hashes should not overwrite one\n * another, so we merge them as arrays.\n */\n\nstrats.watch = strats.events = function (parentVal, childVal) {\n if (!childVal) return parentVal;\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 && !isArray(parent)) {\n parent = [parent];\n }\n ret[key] = parent ? parent.concat(child) : [child];\n }\n return ret;\n};\n\n/**\n * Other object hashes.\n */\n\nstrats.props = strats.methods = strats.computed = function (parentVal, childVal) {\n if (!childVal) return parentVal;\n if (!parentVal) return childVal;\n var ret = Object.create(null);\n extend(ret, parentVal);\n extend(ret, childVal);\n return ret;\n};\n\n/**\n * Default strategy.\n */\n\nvar defaultStrat = function defaultStrat(parentVal, childVal) {\n return childVal === undefined ? parentVal : childVal;\n};\n\n/**\n * Make sure component options get converted to actual\n * constructors.\n *\n * @param {Object} options\n */\n\nfunction guardComponents(options) {\n if (options.components) {\n var components = options.components = guardArrayAssets(options.components);\n var ids = Object.keys(components);\n var def;\n if (process.env.NODE_ENV !== 'production') {\n var map = options._componentNameMap = {};\n }\n for (var i = 0, l = ids.length; i < l; i++) {\n var key = ids[i];\n if (commonTagRE.test(key) || reservedTagRE.test(key)) {\n process.env.NODE_ENV !== 'production' && warn('Do not use built-in or reserved HTML elements as component ' + 'id: ' + key);\n continue;\n }\n // record a all lowercase <-> kebab-case mapping for\n // possible custom element case error warning\n if (process.env.NODE_ENV !== 'production') {\n map[key.replace(/-/g, '').toLowerCase()] = hyphenate(key);\n }\n def = components[key];\n if (isPlainObject(def)) {\n components[key] = Vue.extend(def);\n }\n }\n }\n}\n\n/**\n * Ensure all props option syntax are normalized into the\n * Object-based format.\n *\n * @param {Object} options\n */\n\nfunction guardProps(options) {\n var props = options.props;\n var i, val;\n if (isArray(props)) {\n options.props = {};\n i = props.length;\n while (i--) {\n val = props[i];\n if (typeof val === 'string') {\n options.props[val] = null;\n } else if (val.name) {\n options.props[val.name] = val;\n }\n }\n } else if (isPlainObject(props)) {\n var keys = Object.keys(props);\n i = keys.length;\n while (i--) {\n val = props[keys[i]];\n if (typeof val === 'function') {\n props[keys[i]] = { type: val };\n }\n }\n }\n}\n\n/**\n * Guard an Array-format assets option and converted it\n * into the key-value Object format.\n *\n * @param {Object|Array} assets\n * @return {Object}\n */\n\nfunction guardArrayAssets(assets) {\n if (isArray(assets)) {\n var res = {};\n var i = assets.length;\n var asset;\n while (i--) {\n asset = assets[i];\n var id = typeof asset === 'function' ? asset.options && asset.options.name || asset.id : asset.name || asset.id;\n if (!id) {\n process.env.NODE_ENV !== 'production' && warn('Array-syntax assets must provide a \"name\" or \"id\" field.');\n } else {\n res[id] = asset;\n }\n }\n return res;\n }\n return assets;\n}\n\n/**\n * Merge two option objects into a new one.\n * Core utility used in both instantiation and inheritance.\n *\n * @param {Object} parent\n * @param {Object} child\n * @param {Vue} [vm] - if vm is present, indicates this is\n * an instantiation merge.\n */\n\nfunction mergeOptions(parent, child, vm) {\n guardComponents(child);\n guardProps(child);\n if (process.env.NODE_ENV !== 'production') {\n if (child.propsData && !vm) {\n warn('propsData can only be used as an instantiation option.');\n }\n }\n var options = {};\n var key;\n if (child['extends']) {\n parent = typeof child['extends'] === 'function' ? mergeOptions(parent, child['extends'].options, vm) : mergeOptions(parent, child['extends'], vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n var mixin = child.mixins[i];\n var mixinOptions = mixin.prototype instanceof Vue ? mixin.options : mixin;\n parent = mergeOptions(parent, mixinOptions, vm);\n }\n }\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 *\n * @param {Object} options\n * @param {String} type\n * @param {String} id\n * @param {Boolean} warnMissing\n * @return {Object|Function}\n */\n\nfunction resolveAsset(options, type, id, warnMissing) {\n /* istanbul ignore if */\n if (typeof id !== 'string') {\n return;\n }\n var assets = options[type];\n var camelizedId;\n var res = assets[id] ||\n // camelCase ID\n assets[camelizedId = camelize(id)] ||\n // Pascal Case ID\n assets[camelizedId.charAt(0).toUpperCase() + camelizedId.slice(1)];\n if (process.env.NODE_ENV !== 'production' && warnMissing && !res) {\n warn('Failed to resolve ' + type.slice(0, -1) + ': ' + id, options);\n }\n return res;\n}\n\nvar uid$1 = 0;\n\n/**\n * A dep is an observable that can have multiple\n * directives subscribing to it.\n *\n * @constructor\n */\nfunction Dep() {\n this.id = uid$1++;\n this.subs = [];\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;\n\n/**\n * Add a directive subscriber.\n *\n * @param {Directive} sub\n */\n\nDep.prototype.addSub = function (sub) {\n this.subs.push(sub);\n};\n\n/**\n * Remove a directive subscriber.\n *\n * @param {Directive} sub\n */\n\nDep.prototype.removeSub = function (sub) {\n this.subs.$remove(sub);\n};\n\n/**\n * Add self as a dependency to the target watcher.\n */\n\nDep.prototype.depend = function () {\n Dep.target.addDep(this);\n};\n\n/**\n * Notify all subscribers of a new value.\n */\n\nDep.prototype.notify = function () {\n // stablize the subscriber list first\n var subs = toArray(this.subs);\n for (var i = 0, l = subs.length; i < l; i++) {\n subs[i].update();\n }\n};\n\nvar arrayProto = Array.prototype;\nvar arrayMethods = Object.create(arrayProto)\n\n/**\n * Intercept mutating methods and emit events\n */\n\n;['push', 'pop', 'shift', 'unshift', 'splice', 'sort', 'reverse'].forEach(function (method) {\n // cache original method\n var original = arrayProto[method];\n def(arrayMethods, method, function mutator() {\n // avoid leaking arguments:\n // http://jsperf.com/closure-with-arguments\n var i = arguments.length;\n var args = new Array(i);\n while (i--) {\n args[i] = arguments[i];\n }\n var result = original.apply(this, args);\n var ob = this.__ob__;\n var inserted;\n switch (method) {\n case 'push':\n inserted = args;\n break;\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 * Swap the element at the given index with a new value\n * and emits corresponding event.\n *\n * @param {Number} index\n * @param {*} val\n * @return {*} - replaced element\n */\n\ndef(arrayProto, '$set', function $set(index, val) {\n if (index >= this.length) {\n this.length = Number(index) + 1;\n }\n return this.splice(index, 1, val)[0];\n});\n\n/**\n * Convenience method to remove the element at given index or target element reference.\n *\n * @param {*} item\n */\n\ndef(arrayProto, '$remove', function $remove(item) {\n /* istanbul ignore if */\n if (!this.length) return;\n var index = indexOf(this, item);\n if (index > -1) {\n return this.splice(index, 1);\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 in certain cases, e.g.\n * v-for scope alias and props, we don't want to force conversion\n * because the value may be a nested value under a frozen data structure.\n *\n * So whenever we want to set a reactive property without forcing\n * conversion on the new value, we wrap that call inside this function.\n */\n\nvar shouldConvert = true;\n\nfunction withoutConversion(fn) {\n shouldConvert = false;\n fn();\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 *\n * @param {Array|Object} value\n * @constructor\n */\n\nfunction Observer(value) {\n this.value = value;\n this.dep = new Dep();\n def(value, '__ob__', this);\n if (isArray(value)) {\n var augment = hasProto ? protoAugment : copyAugment;\n augment(value, arrayMethods, arrayKeys);\n this.observeArray(value);\n } else {\n this.walk(value);\n }\n}\n\n// Instance methods\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 *\n * @param {Object} obj\n */\n\nObserver.prototype.walk = function (obj) {\n var keys = Object.keys(obj);\n for (var i = 0, l = keys.length; i < l; i++) {\n this.convert(keys[i], obj[keys[i]]);\n }\n};\n\n/**\n * Observe a list of Array items.\n *\n * @param {Array} items\n */\n\nObserver.prototype.observeArray = function (items) {\n for (var i = 0, l = items.length; i < l; i++) {\n observe(items[i]);\n }\n};\n\n/**\n * Convert a property into getter/setter so we can emit\n * the events when the property is accessed/changed.\n *\n * @param {String} key\n * @param {*} val\n */\n\nObserver.prototype.convert = function (key, val) {\n defineReactive(this.value, key, val);\n};\n\n/**\n * Add an owner vm, so that when $set/$delete mutations\n * happen we can notify owner vms to proxy the keys and\n * digest the watchers. This is only called when the object\n * is observed as an instance's root $data.\n *\n * @param {Vue} vm\n */\n\nObserver.prototype.addVm = function (vm) {\n (this.vms || (this.vms = [])).push(vm);\n};\n\n/**\n * Remove an owner vm. This is called when the object is\n * swapped out as an instance's $data object.\n *\n * @param {Vue} vm\n */\n\nObserver.prototype.removeVm = function (vm) {\n this.vms.$remove(vm);\n};\n\n// helpers\n\n/**\n * Augment an target Object or Array by intercepting\n * the prototype chain using __proto__\n *\n * @param {Object|Array} target\n * @param {Object} src\n */\n\nfunction protoAugment(target, src) {\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 * @param {Object|Array} target\n * @param {Object} proto\n */\n\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 *\n * @param {*} value\n * @param {Vue} [vm]\n * @return {Observer|undefined}\n * @static\n */\n\nfunction observe(value, vm) {\n if (!value || typeof value !== 'object') {\n return;\n }\n var ob;\n if (hasOwn(value, '__ob__') && value.__ob__ instanceof Observer) {\n ob = value.__ob__;\n } else if (shouldConvert && (isArray(value) || isPlainObject(value)) && Object.isExtensible(value) && !value._isVue) {\n ob = new Observer(value);\n }\n if (ob && vm) {\n ob.addVm(vm);\n }\n return ob;\n}\n\n/**\n * Define a reactive property on an Object.\n *\n * @param {Object} obj\n * @param {String} key\n * @param {*} val\n */\n\nfunction defineReactive(obj, key, val) {\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 = 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 (isArray(value)) {\n for (var e, i = 0, l = value.length; i < l; i++) {\n e = value[i];\n e && e.__ob__ && e.__ob__.dep.depend();\n }\n }\n }\n return value;\n },\n set: function reactiveSetter(newVal) {\n var value = getter ? getter.call(obj) : val;\n if (newVal === value) {\n return;\n }\n if (setter) {\n setter.call(obj, newVal);\n } else {\n val = newVal;\n }\n childOb = observe(newVal);\n dep.notify();\n }\n });\n}\n\n\n\nvar util = Object.freeze({\n\tdefineReactive: defineReactive,\n\tset: set,\n\tdel: del,\n\thasOwn: hasOwn,\n\tisLiteral: isLiteral,\n\tisReserved: isReserved,\n\t_toString: _toString,\n\ttoNumber: toNumber,\n\ttoBoolean: toBoolean,\n\tstripQuotes: stripQuotes,\n\tcamelize: camelize,\n\thyphenate: hyphenate,\n\tclassify: classify,\n\tbind: bind,\n\ttoArray: toArray,\n\textend: extend,\n\tisObject: isObject,\n\tisPlainObject: isPlainObject,\n\tdef: def,\n\tdebounce: _debounce,\n\tindexOf: indexOf,\n\tcancellable: cancellable,\n\tlooseEqual: looseEqual,\n\tisArray: isArray,\n\thasProto: hasProto,\n\tinBrowser: inBrowser,\n\tdevtools: devtools,\n\tisIE: isIE,\n\tisIE9: isIE9,\n\tisAndroid: isAndroid,\n\tisIos: isIos,\n\tiosVersionMatch: iosVersionMatch,\n\tiosVersion: iosVersion,\n\thasMutationObserverBug: hasMutationObserverBug,\n\tget transitionProp () { return transitionProp; },\n\tget transitionEndEvent () { return transitionEndEvent; },\n\tget animationProp () { return animationProp; },\n\tget animationEndEvent () { return animationEndEvent; },\n\tnextTick: nextTick,\n\tget _Set () { return _Set; },\n\tquery: query,\n\tinDoc: inDoc,\n\tgetAttr: getAttr,\n\tgetBindAttr: getBindAttr,\n\thasBindAttr: hasBindAttr,\n\tbefore: before,\n\tafter: after,\n\tremove: remove,\n\tprepend: prepend,\n\treplace: replace,\n\ton: on,\n\toff: off,\n\tsetClass: setClass,\n\taddClass: addClass,\n\tremoveClass: removeClass,\n\textractContent: extractContent,\n\ttrimNode: trimNode,\n\tisTemplate: isTemplate,\n\tcreateAnchor: createAnchor,\n\tfindRef: findRef,\n\tmapNodeRange: mapNodeRange,\n\tremoveNodeRange: removeNodeRange,\n\tisFragment: isFragment,\n\tgetOuterHTML: getOuterHTML,\n\tmergeOptions: mergeOptions,\n\tresolveAsset: resolveAsset,\n\tcheckComponentAttr: checkComponentAttr,\n\tcommonTagRE: commonTagRE,\n\treservedTagRE: reservedTagRE,\n\tget warn () { return warn; }\n});\n\nvar uid = 0;\n\nfunction initMixin (Vue) {\n /**\n * The main init sequence. This is called for every\n * instance, including ones that are created from extended\n * constructors.\n *\n * @param {Object} options - this options object should be\n * the result of merging class\n * options and the options passed\n * in to the constructor.\n */\n\n Vue.prototype._init = function (options) {\n options = options || {};\n\n this.$el = null;\n this.$parent = options.parent;\n this.$root = this.$parent ? this.$parent.$root : this;\n this.$children = [];\n this.$refs = {}; // child vm references\n this.$els = {}; // element references\n this._watchers = []; // all watchers as an array\n this._directives = []; // all directives\n\n // a uid\n this._uid = uid++;\n\n // a flag to avoid this being observed\n this._isVue = true;\n\n // events bookkeeping\n this._events = {}; // registered callbacks\n this._eventsCount = {}; // for $broadcast optimization\n\n // fragment instance properties\n this._isFragment = false;\n this._fragment = // @type {DocumentFragment}\n this._fragmentStart = // @type {Text|Comment}\n this._fragmentEnd = null; // @type {Text|Comment}\n\n // lifecycle state\n this._isCompiled = this._isDestroyed = this._isReady = this._isAttached = this._isBeingDestroyed = this._vForRemoving = false;\n this._unlinkFn = null;\n\n // context:\n // if this is a transcluded component, context\n // will be the common parent vm of this instance\n // and its host.\n this._context = options._context || this.$parent;\n\n // scope:\n // if this is inside an inline v-for, the scope\n // will be the intermediate scope created for this\n // repeat fragment. this is used for linking props\n // and container directives.\n this._scope = options._scope;\n\n // fragment:\n // if this instance is compiled inside a Fragment, it\n // needs to reigster itself as a child of that fragment\n // for attach/detach to work properly.\n this._frag = options._frag;\n if (this._frag) {\n this._frag.children.push(this);\n }\n\n // push self into parent / transclusion host\n if (this.$parent) {\n this.$parent.$children.push(this);\n }\n\n // merge options.\n options = this.$options = mergeOptions(this.constructor.options, options, this);\n\n // set ref\n this._updateRef();\n\n // initialize data as empty object.\n // it will be filled up in _initData().\n this._data = {};\n\n // call init hook\n this._callHook('init');\n\n // initialize data observation and scope inheritance.\n this._initState();\n\n // setup event system and option events.\n this._initEvents();\n\n // call created hook\n this._callHook('created');\n\n // if `el` option is passed, start compilation.\n if (options.el) {\n this.$mount(options.el);\n }\n };\n}\n\nvar pathCache = new Cache(1000);\n\n// actions\nvar APPEND = 0;\nvar PUSH = 1;\nvar INC_SUB_PATH_DEPTH = 2;\nvar PUSH_SUB_PATH = 3;\n\n// states\nvar BEFORE_PATH = 0;\nvar IN_PATH = 1;\nvar BEFORE_IDENT = 2;\nvar IN_IDENT = 3;\nvar IN_SUB_PATH = 4;\nvar IN_SINGLE_QUOTE = 5;\nvar IN_DOUBLE_QUOTE = 6;\nvar AFTER_PATH = 7;\nvar ERROR = 8;\n\nvar pathStateMachine = [];\n\npathStateMachine[BEFORE_PATH] = {\n 'ws': [BEFORE_PATH],\n 'ident': [IN_IDENT, APPEND],\n '[': [IN_SUB_PATH],\n 'eof': [AFTER_PATH]\n};\n\npathStateMachine[IN_PATH] = {\n 'ws': [IN_PATH],\n '.': [BEFORE_IDENT],\n '[': [IN_SUB_PATH],\n 'eof': [AFTER_PATH]\n};\n\npathStateMachine[BEFORE_IDENT] = {\n 'ws': [BEFORE_IDENT],\n 'ident': [IN_IDENT, APPEND]\n};\n\npathStateMachine[IN_IDENT] = {\n 'ident': [IN_IDENT, APPEND],\n '0': [IN_IDENT, APPEND],\n 'number': [IN_IDENT, APPEND],\n 'ws': [IN_PATH, PUSH],\n '.': [BEFORE_IDENT, PUSH],\n '[': [IN_SUB_PATH, PUSH],\n 'eof': [AFTER_PATH, PUSH]\n};\n\npathStateMachine[IN_SUB_PATH] = {\n \"'\": [IN_SINGLE_QUOTE, APPEND],\n '\"': [IN_DOUBLE_QUOTE, APPEND],\n '[': [IN_SUB_PATH, INC_SUB_PATH_DEPTH],\n ']': [IN_PATH, PUSH_SUB_PATH],\n 'eof': ERROR,\n 'else': [IN_SUB_PATH, APPEND]\n};\n\npathStateMachine[IN_SINGLE_QUOTE] = {\n \"'\": [IN_SUB_PATH, APPEND],\n 'eof': ERROR,\n 'else': [IN_SINGLE_QUOTE, APPEND]\n};\n\npathStateMachine[IN_DOUBLE_QUOTE] = {\n '\"': [IN_SUB_PATH, APPEND],\n 'eof': ERROR,\n 'else': [IN_DOUBLE_QUOTE, APPEND]\n};\n\n/**\n * Determine the type of a character in a keypath.\n *\n * @param {Char} ch\n * @return {String} type\n */\n\nfunction getPathCharType(ch) {\n if (ch === undefined) {\n return 'eof';\n }\n\n var code = ch.charCodeAt(0);\n\n switch (code) {\n case 0x5B: // [\n case 0x5D: // ]\n case 0x2E: // .\n case 0x22: // \"\n case 0x27: // '\n case 0x30:\n // 0\n return ch;\n\n case 0x5F: // _\n case 0x24:\n // $\n return 'ident';\n\n case 0x20: // Space\n case 0x09: // Tab\n case 0x0A: // Newline\n case 0x0D: // Return\n case 0xA0: // No-break space\n case 0xFEFF: // Byte Order Mark\n case 0x2028: // Line Separator\n case 0x2029:\n // Paragraph Separator\n return 'ws';\n }\n\n // a-z, A-Z\n if (code >= 0x61 && code <= 0x7A || code >= 0x41 && code <= 0x5A) {\n return 'ident';\n }\n\n // 1-9\n if (code >= 0x31 && code <= 0x39) {\n return 'number';\n }\n\n return 'else';\n}\n\n/**\n * Format a subPath, return its plain form if it is\n * a literal string or number. Otherwise prepend the\n * dynamic indicator (*).\n *\n * @param {String} path\n * @return {String}\n */\n\nfunction formatSubPath(path) {\n var trimmed = path.trim();\n // invalid leading 0\n if (path.charAt(0) === '0' && isNaN(path)) {\n return false;\n }\n return isLiteral(trimmed) ? stripQuotes(trimmed) : '*' + trimmed;\n}\n\n/**\n * Parse a string path into an array of segments\n *\n * @param {String} path\n * @return {Array|undefined}\n */\n\nfunction parse(path) {\n var keys = [];\n var index = -1;\n var mode = BEFORE_PATH;\n var subPathDepth = 0;\n var c, newChar, key, type, transition, action, typeMap;\n\n var actions = [];\n\n actions[PUSH] = function () {\n if (key !== undefined) {\n keys.push(key);\n key = undefined;\n }\n };\n\n actions[APPEND] = function () {\n if (key === undefined) {\n key = newChar;\n } else {\n key += newChar;\n }\n };\n\n actions[INC_SUB_PATH_DEPTH] = function () {\n actions[APPEND]();\n subPathDepth++;\n };\n\n actions[PUSH_SUB_PATH] = function () {\n if (subPathDepth > 0) {\n subPathDepth--;\n mode = IN_SUB_PATH;\n actions[APPEND]();\n } else {\n subPathDepth = 0;\n key = formatSubPath(key);\n if (key === false) {\n return false;\n } else {\n actions[PUSH]();\n }\n }\n };\n\n function maybeUnescapeQuote() {\n var nextChar = path[index + 1];\n if (mode === IN_SINGLE_QUOTE && nextChar === \"'\" || mode === IN_DOUBLE_QUOTE && nextChar === '\"') {\n index++;\n newChar = '\\\\' + nextChar;\n actions[APPEND]();\n return true;\n }\n }\n\n while (mode != null) {\n index++;\n c = path[index];\n\n if (c === '\\\\' && maybeUnescapeQuote()) {\n continue;\n }\n\n type = getPathCharType(c);\n typeMap = pathStateMachine[mode];\n transition = typeMap[type] || typeMap['else'] || ERROR;\n\n if (transition === ERROR) {\n return; // parse error\n }\n\n mode = transition[0];\n action = actions[transition[1]];\n if (action) {\n newChar = transition[2];\n newChar = newChar === undefined ? c : newChar;\n if (action() === false) {\n return;\n }\n }\n\n if (mode === AFTER_PATH) {\n keys.raw = path;\n return keys;\n }\n }\n}\n\n/**\n * External parse that check for a cache hit first\n *\n * @param {String} path\n * @return {Array|undefined}\n */\n\nfunction parsePath(path) {\n var hit = pathCache.get(path);\n if (!hit) {\n hit = parse(path);\n if (hit) {\n pathCache.put(path, hit);\n }\n }\n return hit;\n}\n\n/**\n * Get from an object from a path string\n *\n * @param {Object} obj\n * @param {String} path\n */\n\nfunction getPath(obj, path) {\n return parseExpression(path).get(obj);\n}\n\n/**\n * Warn against setting non-existent root path on a vm.\n */\n\nvar warnNonExistent;\nif (process.env.NODE_ENV !== 'production') {\n warnNonExistent = function (path, vm) {\n warn('You are setting a non-existent path \"' + path.raw + '\" ' + 'on a vm instance. Consider pre-initializing the property ' + 'with the \"data\" option for more reliable reactivity ' + 'and better performance.', vm);\n };\n}\n\n/**\n * Set on an object from a path\n *\n * @param {Object} obj\n * @param {String | Array} path\n * @param {*} val\n */\n\nfunction setPath(obj, path, val) {\n var original = obj;\n if (typeof path === 'string') {\n path = parse(path);\n }\n if (!path || !isObject(obj)) {\n return false;\n }\n var last, key;\n for (var i = 0, l = path.length; i < l; i++) {\n last = obj;\n key = path[i];\n if (key.charAt(0) === '*') {\n key = parseExpression(key.slice(1)).get.call(original, original);\n }\n if (i < l - 1) {\n obj = obj[key];\n if (!isObject(obj)) {\n obj = {};\n if (process.env.NODE_ENV !== 'production' && last._isVue) {\n warnNonExistent(path, last);\n }\n set(last, key, obj);\n }\n } else {\n if (isArray(obj)) {\n obj.$set(key, val);\n } else if (key in obj) {\n obj[key] = val;\n } else {\n if (process.env.NODE_ENV !== 'production' && obj._isVue) {\n warnNonExistent(path, obj);\n }\n set(obj, key, val);\n }\n }\n }\n return true;\n}\n\nvar path = Object.freeze({\n parsePath: parsePath,\n getPath: getPath,\n setPath: setPath\n});\n\nvar expressionCache = new Cache(1000);\n\nvar allowedKeywords = 'Math,Date,this,true,false,null,undefined,Infinity,NaN,' + 'isNaN,isFinite,decodeURI,decodeURIComponent,encodeURI,' + 'encodeURIComponent,parseInt,parseFloat';\nvar allowedKeywordsRE = new RegExp('^(' + allowedKeywords.replace(/,/g, '\\\\b|') + '\\\\b)');\n\n// keywords that don't make sense inside expressions\nvar improperKeywords = 'break,case,class,catch,const,continue,debugger,default,' + 'delete,do,else,export,extends,finally,for,function,if,' + 'import,in,instanceof,let,return,super,switch,throw,try,' + 'var,while,with,yield,enum,await,implements,package,' + 'protected,static,interface,private,public';\nvar improperKeywordsRE = new RegExp('^(' + improperKeywords.replace(/,/g, '\\\\b|') + '\\\\b)');\n\nvar wsRE = /\\s/g;\nvar newlineRE = /\\n/g;\nvar saveRE = /[\\{,]\\s*[\\w\\$_]+\\s*:|('(?:[^'\\\\]|\\\\.)*'|\"(?:[^\"\\\\]|\\\\.)*\"|`(?:[^`\\\\]|\\\\.)*\\$\\{|\\}(?:[^`\\\\]|\\\\.)*`|`(?:[^`\\\\]|\\\\.)*`)|new |typeof |void /g;\nvar restoreRE = /\"(\\d+)\"/g;\nvar pathTestRE = /^[A-Za-z_$][\\w$]*(?:\\.[A-Za-z_$][\\w$]*|\\['.*?'\\]|\\[\".*?\"\\]|\\[\\d+\\]|\\[[A-Za-z_$][\\w$]*\\])*$/;\nvar identRE = /[^\\w$\\.](?:[A-Za-z_$][\\w$]*)/g;\nvar literalValueRE$1 = /^(?:true|false|null|undefined|Infinity|NaN)$/;\n\nfunction noop() {}\n\n/**\n * Save / Rewrite / Restore\n *\n * When rewriting paths found in an expression, it is\n * possible for the same letter sequences to be found in\n * strings and Object literal property keys. Therefore we\n * remove and store these parts in a temporary array, and\n * restore them after the path rewrite.\n */\n\nvar saved = [];\n\n/**\n * Save replacer\n *\n * The save regex can match two possible cases:\n * 1. An opening object literal\n * 2. A string\n * If matched as a plain string, we need to escape its\n * newlines, since the string needs to be preserved when\n * generating the function body.\n *\n * @param {String} str\n * @param {String} isString - str if matched as a string\n * @return {String} - placeholder with index\n */\n\nfunction save(str, isString) {\n var i = saved.length;\n saved[i] = isString ? str.replace(newlineRE, '\\\\n') : str;\n return '\"' + i + '\"';\n}\n\n/**\n * Path rewrite replacer\n *\n * @param {String} raw\n * @return {String}\n */\n\nfunction rewrite(raw) {\n var c = raw.charAt(0);\n var path = raw.slice(1);\n if (allowedKeywordsRE.test(path)) {\n return raw;\n } else {\n path = path.indexOf('\"') > -1 ? path.replace(restoreRE, restore) : path;\n return c + 'scope.' + path;\n }\n}\n\n/**\n * Restore replacer\n *\n * @param {String} str\n * @param {String} i - matched save index\n * @return {String}\n */\n\nfunction restore(str, i) {\n return saved[i];\n}\n\n/**\n * Rewrite an expression, prefixing all path accessors with\n * `scope.` and generate getter/setter functions.\n *\n * @param {String} exp\n * @return {Function}\n */\n\nfunction compileGetter(exp) {\n if (improperKeywordsRE.test(exp)) {\n process.env.NODE_ENV !== 'production' && warn('Avoid using reserved keywords in expression: ' + exp);\n }\n // reset state\n saved.length = 0;\n // save strings and object literal keys\n var body = exp.replace(saveRE, save).replace(wsRE, '');\n // rewrite all paths\n // pad 1 space here because the regex matches 1 extra char\n body = (' ' + body).replace(identRE, rewrite).replace(restoreRE, restore);\n return makeGetterFn(body);\n}\n\n/**\n * Build a getter function. Requires eval.\n *\n * We isolate the try/catch so it doesn't affect the\n * optimization of the parse function when it is not called.\n *\n * @param {String} body\n * @return {Function|undefined}\n */\n\nfunction makeGetterFn(body) {\n try {\n /* eslint-disable no-new-func */\n return new Function('scope', 'return ' + body + ';');\n /* eslint-enable no-new-func */\n } catch (e) {\n if (process.env.NODE_ENV !== 'production') {\n /* istanbul ignore if */\n if (e.toString().match(/unsafe-eval|CSP/)) {\n warn('It seems you are using the default build of Vue.js in an environment ' + 'with Content Security Policy that prohibits unsafe-eval. ' + 'Use the CSP-compliant build instead: ' + 'http://vuejs.org/guide/installation.html#CSP-compliant-build');\n } else {\n warn('Invalid expression. ' + 'Generated function body: ' + body);\n }\n }\n return noop;\n }\n}\n\n/**\n * Compile a setter function for the expression.\n *\n * @param {String} exp\n * @return {Function|undefined}\n */\n\nfunction compileSetter(exp) {\n var path = parsePath(exp);\n if (path) {\n return function (scope, val) {\n setPath(scope, path, val);\n };\n } else {\n process.env.NODE_ENV !== 'production' && warn('Invalid setter expression: ' + exp);\n }\n}\n\n/**\n * Parse an expression into re-written getter/setters.\n *\n * @param {String} exp\n * @param {Boolean} needSet\n * @return {Function}\n */\n\nfunction parseExpression(exp, needSet) {\n exp = exp.trim();\n // try cache\n var hit = expressionCache.get(exp);\n if (hit) {\n if (needSet && !hit.set) {\n hit.set = compileSetter(hit.exp);\n }\n return hit;\n }\n var res = { exp: exp };\n res.get = isSimplePath(exp) && exp.indexOf('[') < 0\n // optimized super simple getter\n ? makeGetterFn('scope.' + exp)\n // dynamic getter\n : compileGetter(exp);\n if (needSet) {\n res.set = compileSetter(exp);\n }\n expressionCache.put(exp, res);\n return res;\n}\n\n/**\n * Check if an expression is a simple path.\n *\n * @param {String} exp\n * @return {Boolean}\n */\n\nfunction isSimplePath(exp) {\n return pathTestRE.test(exp) &&\n // don't treat literal values as paths\n !literalValueRE$1.test(exp) &&\n // Math constants e.g. Math.PI, Math.E etc.\n exp.slice(0, 5) !== 'Math.';\n}\n\nvar expression = Object.freeze({\n parseExpression: parseExpression,\n isSimplePath: isSimplePath\n});\n\n// we have two separate queues: one for directive updates\n// and one for user watcher registered via $watch().\n// we want to guarantee directive updates to be called\n// before user watchers so that when user watchers are\n// triggered, the DOM would have already been in updated\n// state.\n\nvar queue = [];\nvar userQueue = [];\nvar has = {};\nvar circular = {};\nvar waiting = false;\n\n/**\n * Reset the batcher's state.\n */\n\nfunction resetBatcherState() {\n queue.length = 0;\n userQueue.length = 0;\n has = {};\n circular = {};\n waiting = false;\n}\n\n/**\n * Flush both queues and run the watchers.\n */\n\nfunction flushBatcherQueue() {\n var _again = true;\n\n _function: while (_again) {\n _again = false;\n\n runBatcherQueue(queue);\n runBatcherQueue(userQueue);\n // user watchers triggered more watchers,\n // keep flushing until it depletes\n if (queue.length) {\n _again = true;\n continue _function;\n }\n // dev tool hook\n /* istanbul ignore if */\n if (devtools && config.devtools) {\n devtools.emit('flush');\n }\n resetBatcherState();\n }\n}\n\n/**\n * Run the watchers in a single queue.\n *\n * @param {Array} queue\n */\n\nfunction runBatcherQueue(queue) {\n // do not cache length because more watchers might be pushed\n // as we run existing watchers\n for (var i = 0; i < queue.length; i++) {\n var watcher = queue[i];\n var id = watcher.id;\n has[id] = null;\n watcher.run();\n // in dev build, check and stop circular updates.\n if (process.env.NODE_ENV !== 'production' && has[id] != null) {\n circular[id] = (circular[id] || 0) + 1;\n if (circular[id] > config._maxUpdateCount) {\n warn('You may have an infinite update loop for watcher ' + 'with expression \"' + watcher.expression + '\"', watcher.vm);\n break;\n }\n }\n }\n queue.length = 0;\n}\n\n/**\n * Push a watcher into the watcher queue.\n * Jobs with duplicate IDs will be skipped unless it's\n * pushed when the queue is being flushed.\n *\n * @param {Watcher} watcher\n * properties:\n * - {Number} id\n * - {Function} run\n */\n\nfunction pushWatcher(watcher) {\n var id = watcher.id;\n if (has[id] == null) {\n // push watcher into appropriate queue\n var q = watcher.user ? userQueue : queue;\n has[id] = q.length;\n q.push(watcher);\n // queue the flush\n if (!waiting) {\n waiting = true;\n nextTick(flushBatcherQueue);\n }\n }\n}\n\nvar uid$2 = 0;\n\n/**\n * A watcher parses an expression, collects dependencies,\n * and fires callback when the expression value changes.\n * This is used for both the $watch() api and directives.\n *\n * @param {Vue} vm\n * @param {String|Function} expOrFn\n * @param {Function} cb\n * @param {Object} options\n * - {Array} filters\n * - {Boolean} twoWay\n * - {Boolean} deep\n * - {Boolean} user\n * - {Boolean} sync\n * - {Boolean} lazy\n * - {Function} [preProcess]\n * - {Function} [postProcess]\n * @constructor\n */\nfunction Watcher(vm, expOrFn, cb, options) {\n // mix in options\n if (options) {\n extend(this, options);\n }\n var isFn = typeof expOrFn === 'function';\n this.vm = vm;\n vm._watchers.push(this);\n this.expression = expOrFn;\n this.cb = cb;\n this.id = ++uid$2; // uid for batching\n this.active = true;\n this.dirty = this.lazy; // for lazy watchers\n this.deps = [];\n this.newDeps = [];\n this.depIds = new _Set();\n this.newDepIds = new _Set();\n this.prevError = null; // for async error stacks\n // parse expression for getter/setter\n if (isFn) {\n this.getter = expOrFn;\n this.setter = undefined;\n } else {\n var res = parseExpression(expOrFn, this.twoWay);\n this.getter = res.get;\n this.setter = res.set;\n }\n this.value = this.lazy ? undefined : this.get();\n // state for avoiding false triggers for deep and Array\n // watchers during vm._digest()\n this.queued = this.shallow = false;\n}\n\n/**\n * Evaluate the getter, and re-collect dependencies.\n */\n\nWatcher.prototype.get = function () {\n this.beforeGet();\n var scope = this.scope || this.vm;\n var value;\n try {\n value = this.getter.call(scope, scope);\n } catch (e) {\n if (process.env.NODE_ENV !== 'production' && config.warnExpressionErrors) {\n warn('Error when evaluating expression ' + '\"' + this.expression + '\": ' + e.toString(), this.vm);\n }\n }\n // \"touch\" every property so they are all tracked as\n // dependencies for deep watching\n if (this.deep) {\n traverse(value);\n }\n if (this.preProcess) {\n value = this.preProcess(value);\n }\n if (this.filters) {\n value = scope._applyFilters(value, null, this.filters, false);\n }\n if (this.postProcess) {\n value = this.postProcess(value);\n }\n this.afterGet();\n return value;\n};\n\n/**\n * Set the corresponding value with the setter.\n *\n * @param {*} value\n */\n\nWatcher.prototype.set = function (value) {\n var scope = this.scope || this.vm;\n if (this.filters) {\n value = scope._applyFilters(value, this.value, this.filters, true);\n }\n try {\n this.setter.call(scope, scope, value);\n } catch (e) {\n if (process.env.NODE_ENV !== 'production' && config.warnExpressionErrors) {\n warn('Error when evaluating setter ' + '\"' + this.expression + '\": ' + e.toString(), this.vm);\n }\n }\n // two-way sync for v-for alias\n var forContext = scope.$forContext;\n if (forContext && forContext.alias === this.expression) {\n if (forContext.filters) {\n process.env.NODE_ENV !== 'production' && warn('It seems you are using two-way binding on ' + 'a v-for alias (' + this.expression + '), and the ' + 'v-for has filters. This will not work properly. ' + 'Either remove the filters or use an array of ' + 'objects and bind to object properties instead.', this.vm);\n return;\n }\n forContext._withLock(function () {\n if (scope.$key) {\n // original is an object\n forContext.rawValue[scope.$key] = value;\n } else {\n forContext.rawValue.$set(scope.$index, value);\n }\n });\n }\n};\n\n/**\n * Prepare for dependency collection.\n */\n\nWatcher.prototype.beforeGet = function () {\n Dep.target = this;\n};\n\n/**\n * Add a dependency to this directive.\n *\n * @param {Dep} dep\n */\n\nWatcher.prototype.addDep = function (dep) {\n var id = dep.id;\n if (!this.newDepIds.has(id)) {\n this.newDepIds.add(id);\n this.newDeps.push(dep);\n if (!this.depIds.has(id)) {\n dep.addSub(this);\n }\n }\n};\n\n/**\n * Clean up for dependency collection.\n */\n\nWatcher.prototype.afterGet = function () {\n Dep.target = null;\n var i = this.deps.length;\n while (i--) {\n var dep = this.deps[i];\n if (!this.newDepIds.has(dep.id)) {\n dep.removeSub(this);\n }\n }\n var tmp = this.depIds;\n this.depIds = this.newDepIds;\n this.newDepIds = tmp;\n this.newDepIds.clear();\n tmp = this.deps;\n this.deps = this.newDeps;\n this.newDeps = tmp;\n this.newDeps.length = 0;\n};\n\n/**\n * Subscriber interface.\n * Will be called when a dependency changes.\n *\n * @param {Boolean} shallow\n */\n\nWatcher.prototype.update = function (shallow) {\n if (this.lazy) {\n this.dirty = true;\n } else if (this.sync || !config.async) {\n this.run();\n } else {\n // if queued, only overwrite shallow with non-shallow,\n // but not the other way around.\n this.shallow = this.queued ? shallow ? this.shallow : false : !!shallow;\n this.queued = true;\n // record before-push error stack in debug mode\n /* istanbul ignore if */\n if (process.env.NODE_ENV !== 'production' && config.debug) {\n this.prevError = new Error('[vue] async stack trace');\n }\n pushWatcher(this);\n }\n};\n\n/**\n * Batcher job interface.\n * Will be called by the batcher.\n */\n\nWatcher.prototype.run = function () {\n if (this.active) {\n var value = this.get();\n if (value !== this.value ||\n // Deep watchers and watchers on Object/Arrays should fire even\n // when the value is the same, because the value may\n // have mutated; but only do so if this is a\n // non-shallow update (caused by a vm digest).\n (isObject(value) || this.deep) && !this.shallow) {\n // set new value\n var oldValue = this.value;\n this.value = value;\n // in debug + async mode, when a watcher callbacks\n // throws, we also throw the saved before-push error\n // so the full cross-tick stack trace is available.\n var prevError = this.prevError;\n /* istanbul ignore if */\n if (process.env.NODE_ENV !== 'production' && config.debug && prevError) {\n this.prevError = null;\n try {\n this.cb.call(this.vm, value, oldValue);\n } catch (e) {\n nextTick(function () {\n throw prevError;\n }, 0);\n throw e;\n }\n } else {\n this.cb.call(this.vm, value, oldValue);\n }\n }\n this.queued = this.shallow = false;\n }\n};\n\n/**\n * Evaluate the value of the watcher.\n * This only gets called for lazy watchers.\n */\n\nWatcher.prototype.evaluate = function () {\n // avoid overwriting another watcher that is being\n // collected.\n var current = Dep.target;\n this.value = this.get();\n this.dirty = false;\n Dep.target = current;\n};\n\n/**\n * Depend on all deps collected by this watcher.\n */\n\nWatcher.prototype.depend = function () {\n var i = this.deps.length;\n while (i--) {\n this.deps[i].depend();\n }\n};\n\n/**\n * Remove self from all dependencies' subcriber list.\n */\n\nWatcher.prototype.teardown = function () {\n if (this.active) {\n // remove self from vm's watcher list\n // this is a somewhat expensive operation so we skip it\n // if the vm is being destroyed or is performing a v-for\n // re-render (the watcher list is then filtered by v-for).\n if (!this.vm._isBeingDestroyed && !this.vm._vForRemoving) {\n this.vm._watchers.$remove(this);\n }\n var i = this.deps.length;\n while (i--) {\n this.deps[i].removeSub(this);\n }\n this.active = false;\n this.vm = this.cb = this.value = null;\n }\n};\n\n/**\n * Recrusively traverse an object to evoke all converted\n * getters, so that every nested property inside the object\n * is collected as a \"deep\" dependency.\n *\n * @param {*} val\n */\n\nvar seenObjects = new _Set();\nfunction traverse(val, seen) {\n var i = undefined,\n keys = undefined;\n if (!seen) {\n seen = seenObjects;\n seen.clear();\n }\n var isA = isArray(val);\n var isO = isObject(val);\n if (isA || isO) {\n if (val.__ob__) {\n var depId = val.__ob__.dep.id;\n if (seen.has(depId)) {\n return;\n } else {\n seen.add(depId);\n }\n }\n if (isA) {\n i = val.length;\n while (i--) traverse(val[i], seen);\n } else if (isO) {\n keys = Object.keys(val);\n i = keys.length;\n while (i--) traverse(val[keys[i]], seen);\n }\n }\n}\n\nvar text$1 = {\n\n bind: function bind() {\n this.attr = this.el.nodeType === 3 ? 'data' : 'textContent';\n },\n\n update: function update(value) {\n this.el[this.attr] = _toString(value);\n }\n};\n\nvar templateCache = new Cache(1000);\nvar idSelectorCache = new Cache(1000);\n\nvar map = {\n efault: [0, '', ''],\n legend: [1, '
', '
'],\n tr: [2, '', '
'],\n col: [2, '', '
']\n};\n\nmap.td = map.th = [3, '', '
'];\n\nmap.option = map.optgroup = [1, ''];\n\nmap.thead = map.tbody = map.colgroup = map.caption = map.tfoot = [1, '', '
'];\n\nmap.g = map.defs = map.symbol = map.use = map.image = map.text = map.circle = map.ellipse = map.line = map.path = map.polygon = map.polyline = map.rect = [1, '', ''];\n\n/**\n * Check if a node is a supported template node with a\n * DocumentFragment content.\n *\n * @param {Node} node\n * @return {Boolean}\n */\n\nfunction isRealTemplate(node) {\n return isTemplate(node) && isFragment(node.content);\n}\n\nvar tagRE$1 = /<([\\w:-]+)/;\nvar entityRE = /&#?\\w+?;/;\nvar commentRE = / E\n }\n entry.newer = undefined; // D --x\n entry.older = this.tail; // D. --> E\n if (this.tail) {\n this.tail.newer = entry; // E. <-- D\n }\n this.tail = entry;\n return returnEntry ? entry : entry.value;\n};\n\nvar cache$1 = new Cache(1000);\nvar filterTokenRE = /[^\\s'\"]+|'[^']*'|\"[^\"]*\"/g;\nvar reservedArgRE = /^in$|^-?\\d+/;\n\n/**\n * Parser state\n */\n\nvar str;\nvar dir;\nvar c;\nvar prev;\nvar i;\nvar l;\nvar lastFilterIndex;\nvar inSingle;\nvar inDouble;\nvar curly;\nvar square;\nvar paren;\n/**\n * Push a filter to the current directive object\n */\n\nfunction pushFilter() {\n var exp = str.slice(lastFilterIndex, i).trim();\n var filter;\n if (exp) {\n filter = {};\n var tokens = exp.match(filterTokenRE);\n filter.name = tokens[0];\n if (tokens.length > 1) {\n filter.args = tokens.slice(1).map(processFilterArg);\n }\n }\n if (filter) {\n (dir.filters = dir.filters || []).push(filter);\n }\n lastFilterIndex = i + 1;\n}\n\n/**\n * Check if an argument is dynamic and strip quotes.\n *\n * @param {String} arg\n * @return {Object}\n */\n\nfunction processFilterArg(arg) {\n if (reservedArgRE.test(arg)) {\n return {\n value: toNumber(arg),\n dynamic: false\n };\n } else {\n var stripped = stripQuotes(arg);\n var dynamic = stripped === arg;\n return {\n value: dynamic ? arg : stripped,\n dynamic: dynamic\n };\n }\n}\n\n/**\n * Parse a directive value and extract the expression\n * and its filters into a descriptor.\n *\n * Example:\n *\n * \"a + 1 | uppercase\" will yield:\n * {\n * expression: 'a + 1',\n * filters: [\n * { name: 'uppercase', args: null }\n * ]\n * }\n *\n * @param {String} s\n * @return {Object}\n */\n\nfunction parseDirective(s) {\n var hit = cache$1.get(s);\n if (hit) {\n return hit;\n }\n\n // reset parser state\n str = s;\n inSingle = inDouble = false;\n curly = square = paren = 0;\n lastFilterIndex = 0;\n dir = {};\n\n for (i = 0, l = str.length; i < l; i++) {\n prev = c;\n c = str.charCodeAt(i);\n if (inSingle) {\n // check single quote\n if (c === 0x27 && prev !== 0x5C) inSingle = !inSingle;\n } else if (inDouble) {\n // check double quote\n if (c === 0x22 && prev !== 0x5C) inDouble = !inDouble;\n } else if (c === 0x7C && // pipe\n str.charCodeAt(i + 1) !== 0x7C && str.charCodeAt(i - 1) !== 0x7C) {\n if (dir.expression == null) {\n // first filter, end of expression\n lastFilterIndex = i + 1;\n dir.expression = str.slice(0, i).trim();\n } else {\n // already has filter\n pushFilter();\n }\n } else {\n switch (c) {\n case 0x22:\n inDouble = true;break; // \"\n case 0x27:\n inSingle = true;break; // '\n case 0x28:\n paren++;break; // (\n case 0x29:\n paren--;break; // )\n case 0x5B:\n square++;break; // [\n case 0x5D:\n square--;break; // ]\n case 0x7B:\n curly++;break; // {\n case 0x7D:\n curly--;break; // }\n }\n }\n }\n\n if (dir.expression == null) {\n dir.expression = str.slice(0, i).trim();\n } else if (lastFilterIndex !== 0) {\n pushFilter();\n }\n\n cache$1.put(s, dir);\n return dir;\n}\n\nvar directive = Object.freeze({\n parseDirective: parseDirective\n});\n\nvar regexEscapeRE = /[-.*+?^${}()|[\\]\\/\\\\]/g;\nvar cache = undefined;\nvar tagRE = undefined;\nvar htmlRE = undefined;\n/**\n * Escape a string so it can be used in a RegExp\n * constructor.\n *\n * @param {String} str\n */\n\nfunction escapeRegex(str) {\n return str.replace(regexEscapeRE, '\\\\$&');\n}\n\nfunction compileRegex() {\n var open = escapeRegex(config.delimiters[0]);\n var close = escapeRegex(config.delimiters[1]);\n var unsafeOpen = escapeRegex(config.unsafeDelimiters[0]);\n var unsafeClose = escapeRegex(config.unsafeDelimiters[1]);\n tagRE = new RegExp(unsafeOpen + '((?:.|\\\\n)+?)' + unsafeClose + '|' + open + '((?:.|\\\\n)+?)' + close, 'g');\n htmlRE = new RegExp('^' + unsafeOpen + '((?:.|\\\\n)+?)' + unsafeClose + '$');\n // reset cache\n cache = new Cache(1000);\n}\n\n/**\n * Parse a template text string into an array of tokens.\n *\n * @param {String} text\n * @return {Array | null}\n * - {String} type\n * - {String} value\n * - {Boolean} [html]\n * - {Boolean} [oneTime]\n */\n\nfunction parseText(text) {\n if (!cache) {\n compileRegex();\n }\n var hit = cache.get(text);\n if (hit) {\n return hit;\n }\n if (!tagRE.test(text)) {\n return null;\n }\n var tokens = [];\n var lastIndex = tagRE.lastIndex = 0;\n var match, index, html, value, first, oneTime;\n /* eslint-disable no-cond-assign */\n while (match = tagRE.exec(text)) {\n /* eslint-enable no-cond-assign */\n index = match.index;\n // push text token\n if (index > lastIndex) {\n tokens.push({\n value: text.slice(lastIndex, index)\n });\n }\n // tag token\n html = htmlRE.test(match[0]);\n value = html ? match[1] : match[2];\n first = value.charCodeAt(0);\n oneTime = first === 42; // *\n value = oneTime ? value.slice(1) : value;\n tokens.push({\n tag: true,\n value: value.trim(),\n html: html,\n oneTime: oneTime\n });\n lastIndex = index + match[0].length;\n }\n if (lastIndex < text.length) {\n tokens.push({\n value: text.slice(lastIndex)\n });\n }\n cache.put(text, tokens);\n return tokens;\n}\n\n/**\n * Format a list of tokens into an expression.\n * e.g. tokens parsed from 'a {{b}} c' can be serialized\n * into one single expression as '\"a \" + b + \" c\"'.\n *\n * @param {Array} tokens\n * @param {Vue} [vm]\n * @return {String}\n */\n\nfunction tokensToExp(tokens, vm) {\n if (tokens.length > 1) {\n return tokens.map(function (token) {\n return formatToken(token, vm);\n }).join('+');\n } else {\n return formatToken(tokens[0], vm, true);\n }\n}\n\n/**\n * Format a single token.\n *\n * @param {Object} token\n * @param {Vue} [vm]\n * @param {Boolean} [single]\n * @return {String}\n */\n\nfunction formatToken(token, vm, single) {\n return token.tag ? token.oneTime && vm ? '\"' + vm.$eval(token.value) + '\"' : inlineFilters(token.value, single) : '\"' + token.value + '\"';\n}\n\n/**\n * For an attribute with multiple interpolation tags,\n * e.g. attr=\"some-{{thing | filter}}\", in order to combine\n * the whole thing into a single watchable expression, we\n * have to inline those filters. This function does exactly\n * that. This is a bit hacky but it avoids heavy changes\n * to directive parser and watcher mechanism.\n *\n * @param {String} exp\n * @param {Boolean} single\n * @return {String}\n */\n\nvar filterRE = /[^|]\\|[^|]/;\nfunction inlineFilters(exp, single) {\n if (!filterRE.test(exp)) {\n return single ? exp : '(' + exp + ')';\n } else {\n var dir = parseDirective(exp);\n if (!dir.filters) {\n return '(' + exp + ')';\n } else {\n return 'this._applyFilters(' + dir.expression + // value\n ',null,' + // oldValue (null for read)\n JSON.stringify(dir.filters) + // filter descriptors\n ',false)'; // write?\n }\n }\n}\n\nvar text = Object.freeze({\n compileRegex: compileRegex,\n parseText: parseText,\n tokensToExp: tokensToExp\n});\n\nvar delimiters = ['{{', '}}'];\nvar unsafeDelimiters = ['{{{', '}}}'];\n\nvar config = Object.defineProperties({\n\n /**\n * Whether to print debug messages.\n * Also enables stack trace for warnings.\n *\n * @type {Boolean}\n */\n\n debug: false,\n\n /**\n * Whether to suppress warnings.\n *\n * @type {Boolean}\n */\n\n silent: false,\n\n /**\n * Whether to use async rendering.\n */\n\n async: true,\n\n /**\n * Whether to warn against errors caught when evaluating\n * expressions.\n */\n\n warnExpressionErrors: true,\n\n /**\n * Whether to allow devtools inspection.\n * Disabled by default in production builds.\n */\n\n devtools: process.env.NODE_ENV !== 'production',\n\n /**\n * Internal flag to indicate the delimiters have been\n * changed.\n *\n * @type {Boolean}\n */\n\n _delimitersChanged: true,\n\n /**\n * List of asset types that a component can own.\n *\n * @type {Array}\n */\n\n _assetTypes: ['component', 'directive', 'elementDirective', 'filter', 'transition', 'partial'],\n\n /**\n * prop binding modes\n */\n\n _propBindingModes: {\n ONE_WAY: 0,\n TWO_WAY: 1,\n ONE_TIME: 2\n },\n\n /**\n * Max circular updates allowed in a batcher flush cycle.\n */\n\n _maxUpdateCount: 100\n\n}, {\n delimiters: { /**\n * Interpolation delimiters. Changing these would trigger\n * the text parser to re-compile the regular expressions.\n *\n * @type {Array}\n */\n\n get: function get() {\n return delimiters;\n },\n set: function set(val) {\n delimiters = val;\n compileRegex();\n },\n configurable: true,\n enumerable: true\n },\n unsafeDelimiters: {\n get: function get() {\n return unsafeDelimiters;\n },\n set: function set(val) {\n unsafeDelimiters = val;\n compileRegex();\n },\n configurable: true,\n enumerable: true\n }\n});\n\nvar warn = undefined;\nvar formatComponentName = undefined;\n\nif (process.env.NODE_ENV !== 'production') {\n (function () {\n var hasConsole = typeof console !== 'undefined';\n\n warn = function (msg, vm) {\n if (hasConsole && !config.silent) {\n console.error('[Vue warn]: ' + msg + (vm ? formatComponentName(vm) : ''));\n }\n };\n\n formatComponentName = function (vm) {\n var name = vm._isVue ? vm.$options.name : vm.name;\n return name ? ' (found in component: <' + hyphenate(name) + '>)' : '';\n };\n })();\n}\n\n/**\n * Append with transition.\n *\n * @param {Element} el\n * @param {Element} target\n * @param {Vue} vm\n * @param {Function} [cb]\n */\n\nfunction appendWithTransition(el, target, vm, cb) {\n applyTransition(el, 1, function () {\n target.appendChild(el);\n }, vm, cb);\n}\n\n/**\n * InsertBefore with transition.\n *\n * @param {Element} el\n * @param {Element} target\n * @param {Vue} vm\n * @param {Function} [cb]\n */\n\nfunction beforeWithTransition(el, target, vm, cb) {\n applyTransition(el, 1, function () {\n before(el, target);\n }, vm, cb);\n}\n\n/**\n * Remove with transition.\n *\n * @param {Element} el\n * @param {Vue} vm\n * @param {Function} [cb]\n */\n\nfunction removeWithTransition(el, vm, cb) {\n applyTransition(el, -1, function () {\n remove(el);\n }, vm, cb);\n}\n\n/**\n * Apply transitions with an operation callback.\n *\n * @param {Element} el\n * @param {Number} direction\n * 1: enter\n * -1: leave\n * @param {Function} op - the actual DOM operation\n * @param {Vue} vm\n * @param {Function} [cb]\n */\n\nfunction applyTransition(el, direction, op, vm, cb) {\n var transition = el.__v_trans;\n if (!transition ||\n // skip if there are no js hooks and CSS transition is\n // not supported\n !transition.hooks && !transitionEndEvent ||\n // skip transitions for initial compile\n !vm._isCompiled ||\n // if the vm is being manipulated by a parent directive\n // during the parent's compilation phase, skip the\n // animation.\n vm.$parent && !vm.$parent._isCompiled) {\n op();\n if (cb) cb();\n return;\n }\n var action = direction > 0 ? 'enter' : 'leave';\n transition[action](op, cb);\n}\n\nvar transition = Object.freeze({\n appendWithTransition: appendWithTransition,\n beforeWithTransition: beforeWithTransition,\n removeWithTransition: removeWithTransition,\n applyTransition: applyTransition\n});\n\n/**\n * Query an element selector if it's not an element already.\n *\n * @param {String|Element} el\n * @return {Element}\n */\n\nfunction query(el) {\n if (typeof el === 'string') {\n var selector = el;\n el = document.querySelector(el);\n if (!el) {\n process.env.NODE_ENV !== 'production' && warn('Cannot find element: ' + selector);\n }\n }\n return el;\n}\n\n/**\n * Check if a node is in the document.\n * Note: document.documentElement.contains should work here\n * but always returns false for comment nodes in phantomjs,\n * making unit tests difficult. This is fixed by doing the\n * contains() check on the node's parentNode instead of\n * the node itself.\n *\n * @param {Node} node\n * @return {Boolean}\n */\n\nfunction inDoc(node) {\n if (!node) return false;\n var doc = node.ownerDocument.documentElement;\n var parent = node.parentNode;\n return doc === node || doc === parent || !!(parent && parent.nodeType === 1 && doc.contains(parent));\n}\n\n/**\n * Get and remove an attribute from a node.\n *\n * @param {Node} node\n * @param {String} _attr\n */\n\nfunction getAttr(node, _attr) {\n var val = node.getAttribute(_attr);\n if (val !== null) {\n node.removeAttribute(_attr);\n }\n return val;\n}\n\n/**\n * Get an attribute with colon or v-bind: prefix.\n *\n * @param {Node} node\n * @param {String} name\n * @return {String|null}\n */\n\nfunction getBindAttr(node, name) {\n var val = getAttr(node, ':' + name);\n if (val === null) {\n val = getAttr(node, 'v-bind:' + name);\n }\n return val;\n}\n\n/**\n * Check the presence of a bind attribute.\n *\n * @param {Node} node\n * @param {String} name\n * @return {Boolean}\n */\n\nfunction hasBindAttr(node, name) {\n return node.hasAttribute(name) || node.hasAttribute(':' + name) || node.hasAttribute('v-bind:' + name);\n}\n\n/**\n * Insert el before target\n *\n * @param {Element} el\n * @param {Element} target\n */\n\nfunction before(el, target) {\n target.parentNode.insertBefore(el, target);\n}\n\n/**\n * Insert el after target\n *\n * @param {Element} el\n * @param {Element} target\n */\n\nfunction after(el, target) {\n if (target.nextSibling) {\n before(el, target.nextSibling);\n } else {\n target.parentNode.appendChild(el);\n }\n}\n\n/**\n * Remove el from DOM\n *\n * @param {Element} el\n */\n\nfunction remove(el) {\n el.parentNode.removeChild(el);\n}\n\n/**\n * Prepend el to target\n *\n * @param {Element} el\n * @param {Element} target\n */\n\nfunction prepend(el, target) {\n if (target.firstChild) {\n before(el, target.firstChild);\n } else {\n target.appendChild(el);\n }\n}\n\n/**\n * Replace target with el\n *\n * @param {Element} target\n * @param {Element} el\n */\n\nfunction replace(target, el) {\n var parent = target.parentNode;\n if (parent) {\n parent.replaceChild(el, target);\n }\n}\n\n/**\n * Add event listener shorthand.\n *\n * @param {Element} el\n * @param {String} event\n * @param {Function} cb\n * @param {Boolean} [useCapture]\n */\n\nfunction on(el, event, cb, useCapture) {\n el.addEventListener(event, cb, useCapture);\n}\n\n/**\n * Remove event listener shorthand.\n *\n * @param {Element} el\n * @param {String} event\n * @param {Function} cb\n */\n\nfunction off(el, event, cb) {\n el.removeEventListener(event, cb);\n}\n\n/**\n * For IE9 compat: when both class and :class are present\n * getAttribute('class') returns wrong value...\n *\n * @param {Element} el\n * @return {String}\n */\n\nfunction getClass(el) {\n var classname = el.className;\n if (typeof classname === 'object') {\n classname = classname.baseVal || '';\n }\n return classname;\n}\n\n/**\n * In IE9, setAttribute('class') will result in empty class\n * if the element also has the :class attribute; However in\n * PhantomJS, setting `className` does not work on SVG elements...\n * So we have to do a conditional check here.\n *\n * @param {Element} el\n * @param {String} cls\n */\n\nfunction setClass(el, cls) {\n /* istanbul ignore if */\n if (isIE9 && !/svg$/.test(el.namespaceURI)) {\n el.className = cls;\n } else {\n el.setAttribute('class', cls);\n }\n}\n\n/**\n * Add class with compatibility for IE & SVG\n *\n * @param {Element} el\n * @param {String} cls\n */\n\nfunction addClass(el, cls) {\n if (el.classList) {\n el.classList.add(cls);\n } else {\n var cur = ' ' + getClass(el) + ' ';\n if (cur.indexOf(' ' + cls + ' ') < 0) {\n setClass(el, (cur + cls).trim());\n }\n }\n}\n\n/**\n * Remove class with compatibility for IE & SVG\n *\n * @param {Element} el\n * @param {String} cls\n */\n\nfunction removeClass(el, cls) {\n if (el.classList) {\n el.classList.remove(cls);\n } else {\n var cur = ' ' + getClass(el) + ' ';\n var tar = ' ' + cls + ' ';\n while (cur.indexOf(tar) >= 0) {\n cur = cur.replace(tar, ' ');\n }\n setClass(el, cur.trim());\n }\n if (!el.className) {\n el.removeAttribute('class');\n }\n}\n\n/**\n * Extract raw content inside an element into a temporary\n * container div\n *\n * @param {Element} el\n * @param {Boolean} asFragment\n * @return {Element|DocumentFragment}\n */\n\nfunction extractContent(el, asFragment) {\n var child;\n var rawContent;\n /* istanbul ignore if */\n if (isTemplate(el) && isFragment(el.content)) {\n el = el.content;\n }\n if (el.hasChildNodes()) {\n trimNode(el);\n rawContent = asFragment ? document.createDocumentFragment() : document.createElement('div');\n /* eslint-disable no-cond-assign */\n while (child = el.firstChild) {\n /* eslint-enable no-cond-assign */\n rawContent.appendChild(child);\n }\n }\n return rawContent;\n}\n\n/**\n * Trim possible empty head/tail text and comment\n * nodes inside a parent.\n *\n * @param {Node} node\n */\n\nfunction trimNode(node) {\n var child;\n /* eslint-disable no-sequences */\n while ((child = node.firstChild, isTrimmable(child))) {\n node.removeChild(child);\n }\n while ((child = node.lastChild, isTrimmable(child))) {\n node.removeChild(child);\n }\n /* eslint-enable no-sequences */\n}\n\nfunction isTrimmable(node) {\n return node && (node.nodeType === 3 && !node.data.trim() || node.nodeType === 8);\n}\n\n/**\n * Check if an element is a template tag.\n * Note if the template appears inside an SVG its tagName\n * will be in lowercase.\n *\n * @param {Element} el\n */\n\nfunction isTemplate(el) {\n return el.tagName && el.tagName.toLowerCase() === 'template';\n}\n\n/**\n * Create an \"anchor\" for performing dom insertion/removals.\n * This is used in a number of scenarios:\n * - fragment instance\n * - v-html\n * - v-if\n * - v-for\n * - component\n *\n * @param {String} content\n * @param {Boolean} persist - IE trashes empty textNodes on\n * cloneNode(true), so in certain\n * cases the anchor needs to be\n * non-empty to be persisted in\n * templates.\n * @return {Comment|Text}\n */\n\nfunction createAnchor(content, persist) {\n var anchor = config.debug ? document.createComment(content) : document.createTextNode(persist ? ' ' : '');\n anchor.__v_anchor = true;\n return anchor;\n}\n\n/**\n * Find a component ref attribute that starts with $.\n *\n * @param {Element} node\n * @return {String|undefined}\n */\n\nvar refRE = /^v-ref:/;\n\nfunction findRef(node) {\n if (node.hasAttributes()) {\n var attrs = node.attributes;\n for (var i = 0, l = attrs.length; i < l; i++) {\n var name = attrs[i].name;\n if (refRE.test(name)) {\n return camelize(name.replace(refRE, ''));\n }\n }\n }\n}\n\n/**\n * Map a function to a range of nodes .\n *\n * @param {Node} node\n * @param {Node} end\n * @param {Function} op\n */\n\nfunction mapNodeRange(node, end, op) {\n var next;\n while (node !== end) {\n next = node.nextSibling;\n op(node);\n node = next;\n }\n op(end);\n}\n\n/**\n * Remove a range of nodes with transition, store\n * the nodes in a fragment with correct ordering,\n * and call callback when done.\n *\n * @param {Node} start\n * @param {Node} end\n * @param {Vue} vm\n * @param {DocumentFragment} frag\n * @param {Function} cb\n */\n\nfunction removeNodeRange(start, end, vm, frag, cb) {\n var done = false;\n var removed = 0;\n var nodes = [];\n mapNodeRange(start, end, function (node) {\n if (node === end) done = true;\n nodes.push(node);\n removeWithTransition(node, vm, onRemoved);\n });\n function onRemoved() {\n removed++;\n if (done && removed >= nodes.length) {\n for (var i = 0; i < nodes.length; i++) {\n frag.appendChild(nodes[i]);\n }\n cb && cb();\n }\n }\n}\n\n/**\n * Check if a node is a DocumentFragment.\n *\n * @param {Node} node\n * @return {Boolean}\n */\n\nfunction isFragment(node) {\n return node && node.nodeType === 11;\n}\n\n/**\n * Get outerHTML of elements, taking care\n * of SVG elements in IE as well.\n *\n * @param {Element} el\n * @return {String}\n */\n\nfunction getOuterHTML(el) {\n if (el.outerHTML) {\n return el.outerHTML;\n } else {\n var container = document.createElement('div');\n container.appendChild(el.cloneNode(true));\n return container.innerHTML;\n }\n}\n\nvar commonTagRE = /^(div|p|span|img|a|b|i|br|ul|ol|li|h1|h2|h3|h4|h5|h6|code|pre|table|th|td|tr|form|label|input|select|option|nav|article|section|header|footer)$/i;\nvar reservedTagRE = /^(slot|partial|component)$/i;\n\nvar isUnknownElement = undefined;\nif (process.env.NODE_ENV !== 'production') {\n isUnknownElement = function (el, tag) {\n if (tag.indexOf('-') > -1) {\n // http://stackoverflow.com/a/28210364/1070244\n return el.constructor === window.HTMLUnknownElement || el.constructor === window.HTMLElement;\n } else {\n return (/HTMLUnknownElement/.test(el.toString()) &&\n // Chrome returns unknown for several HTML5 elements.\n // https://code.google.com/p/chromium/issues/detail?id=540526\n // Firefox returns unknown for some \"Interactive elements.\"\n !/^(data|time|rtc|rb|details|dialog|summary)$/.test(tag)\n );\n }\n };\n}\n\n/**\n * Check if an element is a component, if yes return its\n * component id.\n *\n * @param {Element} el\n * @param {Object} options\n * @return {Object|undefined}\n */\n\nfunction checkComponentAttr(el, options) {\n var tag = el.tagName.toLowerCase();\n var hasAttrs = el.hasAttributes();\n if (!commonTagRE.test(tag) && !reservedTagRE.test(tag)) {\n if (resolveAsset(options, 'components', tag)) {\n return { id: tag };\n } else {\n var is = hasAttrs && getIsBinding(el, options);\n if (is) {\n return is;\n } else if (process.env.NODE_ENV !== 'production') {\n var expectedTag = options._componentNameMap && options._componentNameMap[tag];\n if (expectedTag) {\n warn('Unknown custom element: <' + tag + '> - ' + 'did you mean <' + expectedTag + '>? ' + 'HTML is case-insensitive, remember to use kebab-case in templates.');\n } else if (isUnknownElement(el, tag)) {\n warn('Unknown custom element: <' + tag + '> - did you ' + 'register the component correctly? For recursive components, ' + 'make sure to provide the \"name\" option.');\n }\n }\n }\n } else if (hasAttrs) {\n return getIsBinding(el, options);\n }\n}\n\n/**\n * Get \"is\" binding from an element.\n *\n * @param {Element} el\n * @param {Object} options\n * @return {Object|undefined}\n */\n\nfunction getIsBinding(el, options) {\n // dynamic syntax\n var exp = el.getAttribute('is');\n if (exp != null) {\n if (resolveAsset(options, 'components', exp)) {\n el.removeAttribute('is');\n return { id: exp };\n }\n } else {\n exp = getBindAttr(el, 'is');\n if (exp != null) {\n return { id: exp, dynamic: true };\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 *\n * All strategy functions follow the same signature:\n *\n * @param {*} parentVal\n * @param {*} childVal\n * @param {Vue} [vm]\n */\n\nvar strats = config.optionMergeStrategies = Object.create(null);\n\n/**\n * Helper that recursively merges two data objects together.\n */\n\nfunction mergeData(to, from) {\n var key, toVal, fromVal;\n for (key in from) {\n toVal = to[key];\n fromVal = from[key];\n if (!hasOwn(to, key)) {\n set(to, key, fromVal);\n } else if (isObject(toVal) && isObject(fromVal)) {\n mergeData(toVal, fromVal);\n }\n }\n return to;\n}\n\n/**\n * Data\n */\n\nstrats.data = function (parentVal, childVal, vm) {\n if (!vm) {\n // in a Vue.extend merge, both should be functions\n if (!childVal) {\n return parentVal;\n }\n if (typeof childVal !== 'function') {\n process.env.NODE_ENV !== 'production' && warn('The \"data\" option should be a function ' + 'that returns a per-instance value in component ' + 'definitions.', vm);\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(childVal.call(this), parentVal.call(this));\n };\n } else if (parentVal || childVal) {\n return function mergedInstanceDataFn() {\n // instance merge\n var instanceData = typeof childVal === 'function' ? childVal.call(vm) : childVal;\n var defaultData = typeof parentVal === 'function' ? parentVal.call(vm) : undefined;\n if (instanceData) {\n return mergeData(instanceData, defaultData);\n } else {\n return defaultData;\n }\n };\n }\n};\n\n/**\n * El\n */\n\nstrats.el = function (parentVal, childVal, vm) {\n if (!vm && childVal && typeof childVal !== 'function') {\n process.env.NODE_ENV !== 'production' && warn('The \"el\" option should be a function ' + 'that returns a per-instance value in component ' + 'definitions.', vm);\n return;\n }\n var ret = childVal || parentVal;\n // invoke the element factory if this is instance merge\n return vm && typeof ret === 'function' ? ret.call(vm) : ret;\n};\n\n/**\n * Hooks and param attributes are merged as arrays.\n */\n\nstrats.init = strats.created = strats.ready = strats.attached = strats.detached = strats.beforeCompile = strats.compiled = strats.beforeDestroy = strats.destroyed = strats.activate = function (parentVal, childVal) {\n return childVal ? parentVal ? parentVal.concat(childVal) : isArray(childVal) ? childVal : [childVal] : parentVal;\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 */\n\nfunction mergeAssets(parentVal, childVal) {\n var res = Object.create(parentVal || null);\n return childVal ? extend(res, guardArrayAssets(childVal)) : res;\n}\n\nconfig._assetTypes.forEach(function (type) {\n strats[type + 's'] = mergeAssets;\n});\n\n/**\n * Events & Watchers.\n *\n * Events & watchers hashes should not overwrite one\n * another, so we merge them as arrays.\n */\n\nstrats.watch = strats.events = function (parentVal, childVal) {\n if (!childVal) return parentVal;\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 && !isArray(parent)) {\n parent = [parent];\n }\n ret[key] = parent ? parent.concat(child) : [child];\n }\n return ret;\n};\n\n/**\n * Other object hashes.\n */\n\nstrats.props = strats.methods = strats.computed = function (parentVal, childVal) {\n if (!childVal) return parentVal;\n if (!parentVal) return childVal;\n var ret = Object.create(null);\n extend(ret, parentVal);\n extend(ret, childVal);\n return ret;\n};\n\n/**\n * Default strategy.\n */\n\nvar defaultStrat = function defaultStrat(parentVal, childVal) {\n return childVal === undefined ? parentVal : childVal;\n};\n\n/**\n * Make sure component options get converted to actual\n * constructors.\n *\n * @param {Object} options\n */\n\nfunction guardComponents(options) {\n if (options.components) {\n var components = options.components = guardArrayAssets(options.components);\n var ids = Object.keys(components);\n var def;\n if (process.env.NODE_ENV !== 'production') {\n var map = options._componentNameMap = {};\n }\n for (var i = 0, l = ids.length; i < l; i++) {\n var key = ids[i];\n if (commonTagRE.test(key) || reservedTagRE.test(key)) {\n process.env.NODE_ENV !== 'production' && warn('Do not use built-in or reserved HTML elements as component ' + 'id: ' + key);\n continue;\n }\n // record a all lowercase <-> kebab-case mapping for\n // possible custom element case error warning\n if (process.env.NODE_ENV !== 'production') {\n map[key.replace(/-/g, '').toLowerCase()] = hyphenate(key);\n }\n def = components[key];\n if (isPlainObject(def)) {\n components[key] = Vue.extend(def);\n }\n }\n }\n}\n\n/**\n * Ensure all props option syntax are normalized into the\n * Object-based format.\n *\n * @param {Object} options\n */\n\nfunction guardProps(options) {\n var props = options.props;\n var i, val;\n if (isArray(props)) {\n options.props = {};\n i = props.length;\n while (i--) {\n val = props[i];\n if (typeof val === 'string') {\n options.props[val] = null;\n } else if (val.name) {\n options.props[val.name] = val;\n }\n }\n } else if (isPlainObject(props)) {\n var keys = Object.keys(props);\n i = keys.length;\n while (i--) {\n val = props[keys[i]];\n if (typeof val === 'function') {\n props[keys[i]] = { type: val };\n }\n }\n }\n}\n\n/**\n * Guard an Array-format assets option and converted it\n * into the key-value Object format.\n *\n * @param {Object|Array} assets\n * @return {Object}\n */\n\nfunction guardArrayAssets(assets) {\n if (isArray(assets)) {\n var res = {};\n var i = assets.length;\n var asset;\n while (i--) {\n asset = assets[i];\n var id = typeof asset === 'function' ? asset.options && asset.options.name || asset.id : asset.name || asset.id;\n if (!id) {\n process.env.NODE_ENV !== 'production' && warn('Array-syntax assets must provide a \"name\" or \"id\" field.');\n } else {\n res[id] = asset;\n }\n }\n return res;\n }\n return assets;\n}\n\n/**\n * Merge two option objects into a new one.\n * Core utility used in both instantiation and inheritance.\n *\n * @param {Object} parent\n * @param {Object} child\n * @param {Vue} [vm] - if vm is present, indicates this is\n * an instantiation merge.\n */\n\nfunction mergeOptions(parent, child, vm) {\n guardComponents(child);\n guardProps(child);\n if (process.env.NODE_ENV !== 'production') {\n if (child.propsData && !vm) {\n warn('propsData can only be used as an instantiation option.');\n }\n }\n var options = {};\n var key;\n if (child['extends']) {\n parent = typeof child['extends'] === 'function' ? mergeOptions(parent, child['extends'].options, vm) : mergeOptions(parent, child['extends'], vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n var mixin = child.mixins[i];\n var mixinOptions = mixin.prototype instanceof Vue ? mixin.options : mixin;\n parent = mergeOptions(parent, mixinOptions, vm);\n }\n }\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 *\n * @param {Object} options\n * @param {String} type\n * @param {String} id\n * @param {Boolean} warnMissing\n * @return {Object|Function}\n */\n\nfunction resolveAsset(options, type, id, warnMissing) {\n /* istanbul ignore if */\n if (typeof id !== 'string') {\n return;\n }\n var assets = options[type];\n var camelizedId;\n var res = assets[id] ||\n // camelCase ID\n assets[camelizedId = camelize(id)] ||\n // Pascal Case ID\n assets[camelizedId.charAt(0).toUpperCase() + camelizedId.slice(1)];\n if (process.env.NODE_ENV !== 'production' && warnMissing && !res) {\n warn('Failed to resolve ' + type.slice(0, -1) + ': ' + id, options);\n }\n return res;\n}\n\nvar uid$1 = 0;\n\n/**\n * A dep is an observable that can have multiple\n * directives subscribing to it.\n *\n * @constructor\n */\nfunction Dep() {\n this.id = uid$1++;\n this.subs = [];\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;\n\n/**\n * Add a directive subscriber.\n *\n * @param {Directive} sub\n */\n\nDep.prototype.addSub = function (sub) {\n this.subs.push(sub);\n};\n\n/**\n * Remove a directive subscriber.\n *\n * @param {Directive} sub\n */\n\nDep.prototype.removeSub = function (sub) {\n this.subs.$remove(sub);\n};\n\n/**\n * Add self as a dependency to the target watcher.\n */\n\nDep.prototype.depend = function () {\n Dep.target.addDep(this);\n};\n\n/**\n * Notify all subscribers of a new value.\n */\n\nDep.prototype.notify = function () {\n // stablize the subscriber list first\n var subs = toArray(this.subs);\n for (var i = 0, l = subs.length; i < l; i++) {\n subs[i].update();\n }\n};\n\nvar arrayProto = Array.prototype;\nvar arrayMethods = Object.create(arrayProto)\n\n/**\n * Intercept mutating methods and emit events\n */\n\n;['push', 'pop', 'shift', 'unshift', 'splice', 'sort', 'reverse'].forEach(function (method) {\n // cache original method\n var original = arrayProto[method];\n def(arrayMethods, method, function mutator() {\n // avoid leaking arguments:\n // http://jsperf.com/closure-with-arguments\n var i = arguments.length;\n var args = new Array(i);\n while (i--) {\n args[i] = arguments[i];\n }\n var result = original.apply(this, args);\n var ob = this.__ob__;\n var inserted;\n switch (method) {\n case 'push':\n inserted = args;\n break;\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 * Swap the element at the given index with a new value\n * and emits corresponding event.\n *\n * @param {Number} index\n * @param {*} val\n * @return {*} - replaced element\n */\n\ndef(arrayProto, '$set', function $set(index, val) {\n if (index >= this.length) {\n this.length = Number(index) + 1;\n }\n return this.splice(index, 1, val)[0];\n});\n\n/**\n * Convenience method to remove the element at given index or target element reference.\n *\n * @param {*} item\n */\n\ndef(arrayProto, '$remove', function $remove(item) {\n /* istanbul ignore if */\n if (!this.length) return;\n var index = indexOf(this, item);\n if (index > -1) {\n return this.splice(index, 1);\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 in certain cases, e.g.\n * v-for scope alias and props, we don't want to force conversion\n * because the value may be a nested value under a frozen data structure.\n *\n * So whenever we want to set a reactive property without forcing\n * conversion on the new value, we wrap that call inside this function.\n */\n\nvar shouldConvert = true;\n\nfunction withoutConversion(fn) {\n shouldConvert = false;\n fn();\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 *\n * @param {Array|Object} value\n * @constructor\n */\n\nfunction Observer(value) {\n this.value = value;\n this.dep = new Dep();\n def(value, '__ob__', this);\n if (isArray(value)) {\n var augment = hasProto ? protoAugment : copyAugment;\n augment(value, arrayMethods, arrayKeys);\n this.observeArray(value);\n } else {\n this.walk(value);\n }\n}\n\n// Instance methods\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 *\n * @param {Object} obj\n */\n\nObserver.prototype.walk = function (obj) {\n var keys = Object.keys(obj);\n for (var i = 0, l = keys.length; i < l; i++) {\n this.convert(keys[i], obj[keys[i]]);\n }\n};\n\n/**\n * Observe a list of Array items.\n *\n * @param {Array} items\n */\n\nObserver.prototype.observeArray = function (items) {\n for (var i = 0, l = items.length; i < l; i++) {\n observe(items[i]);\n }\n};\n\n/**\n * Convert a property into getter/setter so we can emit\n * the events when the property is accessed/changed.\n *\n * @param {String} key\n * @param {*} val\n */\n\nObserver.prototype.convert = function (key, val) {\n defineReactive(this.value, key, val);\n};\n\n/**\n * Add an owner vm, so that when $set/$delete mutations\n * happen we can notify owner vms to proxy the keys and\n * digest the watchers. This is only called when the object\n * is observed as an instance's root $data.\n *\n * @param {Vue} vm\n */\n\nObserver.prototype.addVm = function (vm) {\n (this.vms || (this.vms = [])).push(vm);\n};\n\n/**\n * Remove an owner vm. This is called when the object is\n * swapped out as an instance's $data object.\n *\n * @param {Vue} vm\n */\n\nObserver.prototype.removeVm = function (vm) {\n this.vms.$remove(vm);\n};\n\n// helpers\n\n/**\n * Augment an target Object or Array by intercepting\n * the prototype chain using __proto__\n *\n * @param {Object|Array} target\n * @param {Object} src\n */\n\nfunction protoAugment(target, src) {\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 * @param {Object|Array} target\n * @param {Object} proto\n */\n\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 *\n * @param {*} value\n * @param {Vue} [vm]\n * @return {Observer|undefined}\n * @static\n */\n\nfunction observe(value, vm) {\n if (!value || typeof value !== 'object') {\n return;\n }\n var ob;\n if (hasOwn(value, '__ob__') && value.__ob__ instanceof Observer) {\n ob = value.__ob__;\n } else if (shouldConvert && (isArray(value) || isPlainObject(value)) && Object.isExtensible(value) && !value._isVue) {\n ob = new Observer(value);\n }\n if (ob && vm) {\n ob.addVm(vm);\n }\n return ob;\n}\n\n/**\n * Define a reactive property on an Object.\n *\n * @param {Object} obj\n * @param {String} key\n * @param {*} val\n */\n\nfunction defineReactive(obj, key, val) {\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 = 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 (isArray(value)) {\n for (var e, i = 0, l = value.length; i < l; i++) {\n e = value[i];\n e && e.__ob__ && e.__ob__.dep.depend();\n }\n }\n }\n return value;\n },\n set: function reactiveSetter(newVal) {\n var value = getter ? getter.call(obj) : val;\n if (newVal === value) {\n return;\n }\n if (setter) {\n setter.call(obj, newVal);\n } else {\n val = newVal;\n }\n childOb = observe(newVal);\n dep.notify();\n }\n });\n}\n\n\n\nvar util = Object.freeze({\n\tdefineReactive: defineReactive,\n\tset: set,\n\tdel: del,\n\thasOwn: hasOwn,\n\tisLiteral: isLiteral,\n\tisReserved: isReserved,\n\t_toString: _toString,\n\ttoNumber: toNumber,\n\ttoBoolean: toBoolean,\n\tstripQuotes: stripQuotes,\n\tcamelize: camelize,\n\thyphenate: hyphenate,\n\tclassify: classify,\n\tbind: bind,\n\ttoArray: toArray,\n\textend: extend,\n\tisObject: isObject,\n\tisPlainObject: isPlainObject,\n\tdef: def,\n\tdebounce: _debounce,\n\tindexOf: indexOf,\n\tcancellable: cancellable,\n\tlooseEqual: looseEqual,\n\tisArray: isArray,\n\thasProto: hasProto,\n\tinBrowser: inBrowser,\n\tdevtools: devtools,\n\tisIE: isIE,\n\tisIE9: isIE9,\n\tisAndroid: isAndroid,\n\tisIos: isIos,\n\tiosVersionMatch: iosVersionMatch,\n\tiosVersion: iosVersion,\n\thasMutationObserverBug: hasMutationObserverBug,\n\tget transitionProp () { return transitionProp; },\n\tget transitionEndEvent () { return transitionEndEvent; },\n\tget animationProp () { return animationProp; },\n\tget animationEndEvent () { return animationEndEvent; },\n\tnextTick: nextTick,\n\tget _Set () { return _Set; },\n\tquery: query,\n\tinDoc: inDoc,\n\tgetAttr: getAttr,\n\tgetBindAttr: getBindAttr,\n\thasBindAttr: hasBindAttr,\n\tbefore: before,\n\tafter: after,\n\tremove: remove,\n\tprepend: prepend,\n\treplace: replace,\n\ton: on,\n\toff: off,\n\tsetClass: setClass,\n\taddClass: addClass,\n\tremoveClass: removeClass,\n\textractContent: extractContent,\n\ttrimNode: trimNode,\n\tisTemplate: isTemplate,\n\tcreateAnchor: createAnchor,\n\tfindRef: findRef,\n\tmapNodeRange: mapNodeRange,\n\tremoveNodeRange: removeNodeRange,\n\tisFragment: isFragment,\n\tgetOuterHTML: getOuterHTML,\n\tmergeOptions: mergeOptions,\n\tresolveAsset: resolveAsset,\n\tcheckComponentAttr: checkComponentAttr,\n\tcommonTagRE: commonTagRE,\n\treservedTagRE: reservedTagRE,\n\tget warn () { return warn; }\n});\n\nvar uid = 0;\n\nfunction initMixin (Vue) {\n /**\n * The main init sequence. This is called for every\n * instance, including ones that are created from extended\n * constructors.\n *\n * @param {Object} options - this options object should be\n * the result of merging class\n * options and the options passed\n * in to the constructor.\n */\n\n Vue.prototype._init = function (options) {\n options = options || {};\n\n this.$el = null;\n this.$parent = options.parent;\n this.$root = this.$parent ? this.$parent.$root : this;\n this.$children = [];\n this.$refs = {}; // child vm references\n this.$els = {}; // element references\n this._watchers = []; // all watchers as an array\n this._directives = []; // all directives\n\n // a uid\n this._uid = uid++;\n\n // a flag to avoid this being observed\n this._isVue = true;\n\n // events bookkeeping\n this._events = {}; // registered callbacks\n this._eventsCount = {}; // for $broadcast optimization\n\n // fragment instance properties\n this._isFragment = false;\n this._fragment = // @type {DocumentFragment}\n this._fragmentStart = // @type {Text|Comment}\n this._fragmentEnd = null; // @type {Text|Comment}\n\n // lifecycle state\n this._isCompiled = this._isDestroyed = this._isReady = this._isAttached = this._isBeingDestroyed = this._vForRemoving = false;\n this._unlinkFn = null;\n\n // context:\n // if this is a transcluded component, context\n // will be the common parent vm of this instance\n // and its host.\n this._context = options._context || this.$parent;\n\n // scope:\n // if this is inside an inline v-for, the scope\n // will be the intermediate scope created for this\n // repeat fragment. this is used for linking props\n // and container directives.\n this._scope = options._scope;\n\n // fragment:\n // if this instance is compiled inside a Fragment, it\n // needs to reigster itself as a child of that fragment\n // for attach/detach to work properly.\n this._frag = options._frag;\n if (this._frag) {\n this._frag.children.push(this);\n }\n\n // push self into parent / transclusion host\n if (this.$parent) {\n this.$parent.$children.push(this);\n }\n\n // merge options.\n options = this.$options = mergeOptions(this.constructor.options, options, this);\n\n // set ref\n this._updateRef();\n\n // initialize data as empty object.\n // it will be filled up in _initData().\n this._data = {};\n\n // call init hook\n this._callHook('init');\n\n // initialize data observation and scope inheritance.\n this._initState();\n\n // setup event system and option events.\n this._initEvents();\n\n // call created hook\n this._callHook('created');\n\n // if `el` option is passed, start compilation.\n if (options.el) {\n this.$mount(options.el);\n }\n };\n}\n\nvar pathCache = new Cache(1000);\n\n// actions\nvar APPEND = 0;\nvar PUSH = 1;\nvar INC_SUB_PATH_DEPTH = 2;\nvar PUSH_SUB_PATH = 3;\n\n// states\nvar BEFORE_PATH = 0;\nvar IN_PATH = 1;\nvar BEFORE_IDENT = 2;\nvar IN_IDENT = 3;\nvar IN_SUB_PATH = 4;\nvar IN_SINGLE_QUOTE = 5;\nvar IN_DOUBLE_QUOTE = 6;\nvar AFTER_PATH = 7;\nvar ERROR = 8;\n\nvar pathStateMachine = [];\n\npathStateMachine[BEFORE_PATH] = {\n 'ws': [BEFORE_PATH],\n 'ident': [IN_IDENT, APPEND],\n '[': [IN_SUB_PATH],\n 'eof': [AFTER_PATH]\n};\n\npathStateMachine[IN_PATH] = {\n 'ws': [IN_PATH],\n '.': [BEFORE_IDENT],\n '[': [IN_SUB_PATH],\n 'eof': [AFTER_PATH]\n};\n\npathStateMachine[BEFORE_IDENT] = {\n 'ws': [BEFORE_IDENT],\n 'ident': [IN_IDENT, APPEND]\n};\n\npathStateMachine[IN_IDENT] = {\n 'ident': [IN_IDENT, APPEND],\n '0': [IN_IDENT, APPEND],\n 'number': [IN_IDENT, APPEND],\n 'ws': [IN_PATH, PUSH],\n '.': [BEFORE_IDENT, PUSH],\n '[': [IN_SUB_PATH, PUSH],\n 'eof': [AFTER_PATH, PUSH]\n};\n\npathStateMachine[IN_SUB_PATH] = {\n \"'\": [IN_SINGLE_QUOTE, APPEND],\n '\"': [IN_DOUBLE_QUOTE, APPEND],\n '[': [IN_SUB_PATH, INC_SUB_PATH_DEPTH],\n ']': [IN_PATH, PUSH_SUB_PATH],\n 'eof': ERROR,\n 'else': [IN_SUB_PATH, APPEND]\n};\n\npathStateMachine[IN_SINGLE_QUOTE] = {\n \"'\": [IN_SUB_PATH, APPEND],\n 'eof': ERROR,\n 'else': [IN_SINGLE_QUOTE, APPEND]\n};\n\npathStateMachine[IN_DOUBLE_QUOTE] = {\n '\"': [IN_SUB_PATH, APPEND],\n 'eof': ERROR,\n 'else': [IN_DOUBLE_QUOTE, APPEND]\n};\n\n/**\n * Determine the type of a character in a keypath.\n *\n * @param {Char} ch\n * @return {String} type\n */\n\nfunction getPathCharType(ch) {\n if (ch === undefined) {\n return 'eof';\n }\n\n var code = ch.charCodeAt(0);\n\n switch (code) {\n case 0x5B: // [\n case 0x5D: // ]\n case 0x2E: // .\n case 0x22: // \"\n case 0x27: // '\n case 0x30:\n // 0\n return ch;\n\n case 0x5F: // _\n case 0x24:\n // $\n return 'ident';\n\n case 0x20: // Space\n case 0x09: // Tab\n case 0x0A: // Newline\n case 0x0D: // Return\n case 0xA0: // No-break space\n case 0xFEFF: // Byte Order Mark\n case 0x2028: // Line Separator\n case 0x2029:\n // Paragraph Separator\n return 'ws';\n }\n\n // a-z, A-Z\n if (code >= 0x61 && code <= 0x7A || code >= 0x41 && code <= 0x5A) {\n return 'ident';\n }\n\n // 1-9\n if (code >= 0x31 && code <= 0x39) {\n return 'number';\n }\n\n return 'else';\n}\n\n/**\n * Format a subPath, return its plain form if it is\n * a literal string or number. Otherwise prepend the\n * dynamic indicator (*).\n *\n * @param {String} path\n * @return {String}\n */\n\nfunction formatSubPath(path) {\n var trimmed = path.trim();\n // invalid leading 0\n if (path.charAt(0) === '0' && isNaN(path)) {\n return false;\n }\n return isLiteral(trimmed) ? stripQuotes(trimmed) : '*' + trimmed;\n}\n\n/**\n * Parse a string path into an array of segments\n *\n * @param {String} path\n * @return {Array|undefined}\n */\n\nfunction parse(path) {\n var keys = [];\n var index = -1;\n var mode = BEFORE_PATH;\n var subPathDepth = 0;\n var c, newChar, key, type, transition, action, typeMap;\n\n var actions = [];\n\n actions[PUSH] = function () {\n if (key !== undefined) {\n keys.push(key);\n key = undefined;\n }\n };\n\n actions[APPEND] = function () {\n if (key === undefined) {\n key = newChar;\n } else {\n key += newChar;\n }\n };\n\n actions[INC_SUB_PATH_DEPTH] = function () {\n actions[APPEND]();\n subPathDepth++;\n };\n\n actions[PUSH_SUB_PATH] = function () {\n if (subPathDepth > 0) {\n subPathDepth--;\n mode = IN_SUB_PATH;\n actions[APPEND]();\n } else {\n subPathDepth = 0;\n key = formatSubPath(key);\n if (key === false) {\n return false;\n } else {\n actions[PUSH]();\n }\n }\n };\n\n function maybeUnescapeQuote() {\n var nextChar = path[index + 1];\n if (mode === IN_SINGLE_QUOTE && nextChar === \"'\" || mode === IN_DOUBLE_QUOTE && nextChar === '\"') {\n index++;\n newChar = '\\\\' + nextChar;\n actions[APPEND]();\n return true;\n }\n }\n\n while (mode != null) {\n index++;\n c = path[index];\n\n if (c === '\\\\' && maybeUnescapeQuote()) {\n continue;\n }\n\n type = getPathCharType(c);\n typeMap = pathStateMachine[mode];\n transition = typeMap[type] || typeMap['else'] || ERROR;\n\n if (transition === ERROR) {\n return; // parse error\n }\n\n mode = transition[0];\n action = actions[transition[1]];\n if (action) {\n newChar = transition[2];\n newChar = newChar === undefined ? c : newChar;\n if (action() === false) {\n return;\n }\n }\n\n if (mode === AFTER_PATH) {\n keys.raw = path;\n return keys;\n }\n }\n}\n\n/**\n * External parse that check for a cache hit first\n *\n * @param {String} path\n * @return {Array|undefined}\n */\n\nfunction parsePath(path) {\n var hit = pathCache.get(path);\n if (!hit) {\n hit = parse(path);\n if (hit) {\n pathCache.put(path, hit);\n }\n }\n return hit;\n}\n\n/**\n * Get from an object from a path string\n *\n * @param {Object} obj\n * @param {String} path\n */\n\nfunction getPath(obj, path) {\n return parseExpression(path).get(obj);\n}\n\n/**\n * Warn against setting non-existent root path on a vm.\n */\n\nvar warnNonExistent;\nif (process.env.NODE_ENV !== 'production') {\n warnNonExistent = function (path, vm) {\n warn('You are setting a non-existent path \"' + path.raw + '\" ' + 'on a vm instance. Consider pre-initializing the property ' + 'with the \"data\" option for more reliable reactivity ' + 'and better performance.', vm);\n };\n}\n\n/**\n * Set on an object from a path\n *\n * @param {Object} obj\n * @param {String | Array} path\n * @param {*} val\n */\n\nfunction setPath(obj, path, val) {\n var original = obj;\n if (typeof path === 'string') {\n path = parse(path);\n }\n if (!path || !isObject(obj)) {\n return false;\n }\n var last, key;\n for (var i = 0, l = path.length; i < l; i++) {\n last = obj;\n key = path[i];\n if (key.charAt(0) === '*') {\n key = parseExpression(key.slice(1)).get.call(original, original);\n }\n if (i < l - 1) {\n obj = obj[key];\n if (!isObject(obj)) {\n obj = {};\n if (process.env.NODE_ENV !== 'production' && last._isVue) {\n warnNonExistent(path, last);\n }\n set(last, key, obj);\n }\n } else {\n if (isArray(obj)) {\n obj.$set(key, val);\n } else if (key in obj) {\n obj[key] = val;\n } else {\n if (process.env.NODE_ENV !== 'production' && obj._isVue) {\n warnNonExistent(path, obj);\n }\n set(obj, key, val);\n }\n }\n }\n return true;\n}\n\nvar path = Object.freeze({\n parsePath: parsePath,\n getPath: getPath,\n setPath: setPath\n});\n\nvar expressionCache = new Cache(1000);\n\nvar allowedKeywords = 'Math,Date,this,true,false,null,undefined,Infinity,NaN,' + 'isNaN,isFinite,decodeURI,decodeURIComponent,encodeURI,' + 'encodeURIComponent,parseInt,parseFloat';\nvar allowedKeywordsRE = new RegExp('^(' + allowedKeywords.replace(/,/g, '\\\\b|') + '\\\\b)');\n\n// keywords that don't make sense inside expressions\nvar improperKeywords = 'break,case,class,catch,const,continue,debugger,default,' + 'delete,do,else,export,extends,finally,for,function,if,' + 'import,in,instanceof,let,return,super,switch,throw,try,' + 'var,while,with,yield,enum,await,implements,package,' + 'protected,static,interface,private,public';\nvar improperKeywordsRE = new RegExp('^(' + improperKeywords.replace(/,/g, '\\\\b|') + '\\\\b)');\n\nvar wsRE = /\\s/g;\nvar newlineRE = /\\n/g;\nvar saveRE = /[\\{,]\\s*[\\w\\$_]+\\s*:|('(?:[^'\\\\]|\\\\.)*'|\"(?:[^\"\\\\]|\\\\.)*\"|`(?:[^`\\\\]|\\\\.)*\\$\\{|\\}(?:[^`\\\\]|\\\\.)*`|`(?:[^`\\\\]|\\\\.)*`)|new |typeof |void /g;\nvar restoreRE = /\"(\\d+)\"/g;\nvar pathTestRE = /^[A-Za-z_$][\\w$]*(?:\\.[A-Za-z_$][\\w$]*|\\['.*?'\\]|\\[\".*?\"\\]|\\[\\d+\\]|\\[[A-Za-z_$][\\w$]*\\])*$/;\nvar identRE = /[^\\w$\\.](?:[A-Za-z_$][\\w$]*)/g;\nvar literalValueRE$1 = /^(?:true|false|null|undefined|Infinity|NaN)$/;\n\nfunction noop() {}\n\n/**\n * Save / Rewrite / Restore\n *\n * When rewriting paths found in an expression, it is\n * possible for the same letter sequences to be found in\n * strings and Object literal property keys. Therefore we\n * remove and store these parts in a temporary array, and\n * restore them after the path rewrite.\n */\n\nvar saved = [];\n\n/**\n * Save replacer\n *\n * The save regex can match two possible cases:\n * 1. An opening object literal\n * 2. A string\n * If matched as a plain string, we need to escape its\n * newlines, since the string needs to be preserved when\n * generating the function body.\n *\n * @param {String} str\n * @param {String} isString - str if matched as a string\n * @return {String} - placeholder with index\n */\n\nfunction save(str, isString) {\n var i = saved.length;\n saved[i] = isString ? str.replace(newlineRE, '\\\\n') : str;\n return '\"' + i + '\"';\n}\n\n/**\n * Path rewrite replacer\n *\n * @param {String} raw\n * @return {String}\n */\n\nfunction rewrite(raw) {\n var c = raw.charAt(0);\n var path = raw.slice(1);\n if (allowedKeywordsRE.test(path)) {\n return raw;\n } else {\n path = path.indexOf('\"') > -1 ? path.replace(restoreRE, restore) : path;\n return c + 'scope.' + path;\n }\n}\n\n/**\n * Restore replacer\n *\n * @param {String} str\n * @param {String} i - matched save index\n * @return {String}\n */\n\nfunction restore(str, i) {\n return saved[i];\n}\n\n/**\n * Rewrite an expression, prefixing all path accessors with\n * `scope.` and generate getter/setter functions.\n *\n * @param {String} exp\n * @return {Function}\n */\n\nfunction compileGetter(exp) {\n if (improperKeywordsRE.test(exp)) {\n process.env.NODE_ENV !== 'production' && warn('Avoid using reserved keywords in expression: ' + exp);\n }\n // reset state\n saved.length = 0;\n // save strings and object literal keys\n var body = exp.replace(saveRE, save).replace(wsRE, '');\n // rewrite all paths\n // pad 1 space here because the regex matches 1 extra char\n body = (' ' + body).replace(identRE, rewrite).replace(restoreRE, restore);\n return makeGetterFn(body);\n}\n\n/**\n * Build a getter function. Requires eval.\n *\n * We isolate the try/catch so it doesn't affect the\n * optimization of the parse function when it is not called.\n *\n * @param {String} body\n * @return {Function|undefined}\n */\n\nfunction makeGetterFn(body) {\n try {\n /* eslint-disable no-new-func */\n return new Function('scope', 'return ' + body + ';');\n /* eslint-enable no-new-func */\n } catch (e) {\n if (process.env.NODE_ENV !== 'production') {\n /* istanbul ignore if */\n if (e.toString().match(/unsafe-eval|CSP/)) {\n warn('It seems you are using the default build of Vue.js in an environment ' + 'with Content Security Policy that prohibits unsafe-eval. ' + 'Use the CSP-compliant build instead: ' + 'http://vuejs.org/guide/installation.html#CSP-compliant-build');\n } else {\n warn('Invalid expression. ' + 'Generated function body: ' + body);\n }\n }\n return noop;\n }\n}\n\n/**\n * Compile a setter function for the expression.\n *\n * @param {String} exp\n * @return {Function|undefined}\n */\n\nfunction compileSetter(exp) {\n var path = parsePath(exp);\n if (path) {\n return function (scope, val) {\n setPath(scope, path, val);\n };\n } else {\n process.env.NODE_ENV !== 'production' && warn('Invalid setter expression: ' + exp);\n }\n}\n\n/**\n * Parse an expression into re-written getter/setters.\n *\n * @param {String} exp\n * @param {Boolean} needSet\n * @return {Function}\n */\n\nfunction parseExpression(exp, needSet) {\n exp = exp.trim();\n // try cache\n var hit = expressionCache.get(exp);\n if (hit) {\n if (needSet && !hit.set) {\n hit.set = compileSetter(hit.exp);\n }\n return hit;\n }\n var res = { exp: exp };\n res.get = isSimplePath(exp) && exp.indexOf('[') < 0\n // optimized super simple getter\n ? makeGetterFn('scope.' + exp)\n // dynamic getter\n : compileGetter(exp);\n if (needSet) {\n res.set = compileSetter(exp);\n }\n expressionCache.put(exp, res);\n return res;\n}\n\n/**\n * Check if an expression is a simple path.\n *\n * @param {String} exp\n * @return {Boolean}\n */\n\nfunction isSimplePath(exp) {\n return pathTestRE.test(exp) &&\n // don't treat literal values as paths\n !literalValueRE$1.test(exp) &&\n // Math constants e.g. Math.PI, Math.E etc.\n exp.slice(0, 5) !== 'Math.';\n}\n\nvar expression = Object.freeze({\n parseExpression: parseExpression,\n isSimplePath: isSimplePath\n});\n\n// we have two separate queues: one for directive updates\n// and one for user watcher registered via $watch().\n// we want to guarantee directive updates to be called\n// before user watchers so that when user watchers are\n// triggered, the DOM would have already been in updated\n// state.\n\nvar queue = [];\nvar userQueue = [];\nvar has = {};\nvar circular = {};\nvar waiting = false;\n\n/**\n * Reset the batcher's state.\n */\n\nfunction resetBatcherState() {\n queue.length = 0;\n userQueue.length = 0;\n has = {};\n circular = {};\n waiting = false;\n}\n\n/**\n * Flush both queues and run the watchers.\n */\n\nfunction flushBatcherQueue() {\n var _again = true;\n\n _function: while (_again) {\n _again = false;\n\n runBatcherQueue(queue);\n runBatcherQueue(userQueue);\n // user watchers triggered more watchers,\n // keep flushing until it depletes\n if (queue.length) {\n _again = true;\n continue _function;\n }\n // dev tool hook\n /* istanbul ignore if */\n if (devtools && config.devtools) {\n devtools.emit('flush');\n }\n resetBatcherState();\n }\n}\n\n/**\n * Run the watchers in a single queue.\n *\n * @param {Array} queue\n */\n\nfunction runBatcherQueue(queue) {\n // do not cache length because more watchers might be pushed\n // as we run existing watchers\n for (var i = 0; i < queue.length; i++) {\n var watcher = queue[i];\n var id = watcher.id;\n has[id] = null;\n watcher.run();\n // in dev build, check and stop circular updates.\n if (process.env.NODE_ENV !== 'production' && has[id] != null) {\n circular[id] = (circular[id] || 0) + 1;\n if (circular[id] > config._maxUpdateCount) {\n warn('You may have an infinite update loop for watcher ' + 'with expression \"' + watcher.expression + '\"', watcher.vm);\n break;\n }\n }\n }\n queue.length = 0;\n}\n\n/**\n * Push a watcher into the watcher queue.\n * Jobs with duplicate IDs will be skipped unless it's\n * pushed when the queue is being flushed.\n *\n * @param {Watcher} watcher\n * properties:\n * - {Number} id\n * - {Function} run\n */\n\nfunction pushWatcher(watcher) {\n var id = watcher.id;\n if (has[id] == null) {\n // push watcher into appropriate queue\n var q = watcher.user ? userQueue : queue;\n has[id] = q.length;\n q.push(watcher);\n // queue the flush\n if (!waiting) {\n waiting = true;\n nextTick(flushBatcherQueue);\n }\n }\n}\n\nvar uid$2 = 0;\n\n/**\n * A watcher parses an expression, collects dependencies,\n * and fires callback when the expression value changes.\n * This is used for both the $watch() api and directives.\n *\n * @param {Vue} vm\n * @param {String|Function} expOrFn\n * @param {Function} cb\n * @param {Object} options\n * - {Array} filters\n * - {Boolean} twoWay\n * - {Boolean} deep\n * - {Boolean} user\n * - {Boolean} sync\n * - {Boolean} lazy\n * - {Function} [preProcess]\n * - {Function} [postProcess]\n * @constructor\n */\nfunction Watcher(vm, expOrFn, cb, options) {\n // mix in options\n if (options) {\n extend(this, options);\n }\n var isFn = typeof expOrFn === 'function';\n this.vm = vm;\n vm._watchers.push(this);\n this.expression = expOrFn;\n this.cb = cb;\n this.id = ++uid$2; // uid for batching\n this.active = true;\n this.dirty = this.lazy; // for lazy watchers\n this.deps = [];\n this.newDeps = [];\n this.depIds = new _Set();\n this.newDepIds = new _Set();\n this.prevError = null; // for async error stacks\n // parse expression for getter/setter\n if (isFn) {\n this.getter = expOrFn;\n this.setter = undefined;\n } else {\n var res = parseExpression(expOrFn, this.twoWay);\n this.getter = res.get;\n this.setter = res.set;\n }\n this.value = this.lazy ? undefined : this.get();\n // state for avoiding false triggers for deep and Array\n // watchers during vm._digest()\n this.queued = this.shallow = false;\n}\n\n/**\n * Evaluate the getter, and re-collect dependencies.\n */\n\nWatcher.prototype.get = function () {\n this.beforeGet();\n var scope = this.scope || this.vm;\n var value;\n try {\n value = this.getter.call(scope, scope);\n } catch (e) {\n if (process.env.NODE_ENV !== 'production' && config.warnExpressionErrors) {\n warn('Error when evaluating expression ' + '\"' + this.expression + '\": ' + e.toString(), this.vm);\n }\n }\n // \"touch\" every property so they are all tracked as\n // dependencies for deep watching\n if (this.deep) {\n traverse(value);\n }\n if (this.preProcess) {\n value = this.preProcess(value);\n }\n if (this.filters) {\n value = scope._applyFilters(value, null, this.filters, false);\n }\n if (this.postProcess) {\n value = this.postProcess(value);\n }\n this.afterGet();\n return value;\n};\n\n/**\n * Set the corresponding value with the setter.\n *\n * @param {*} value\n */\n\nWatcher.prototype.set = function (value) {\n var scope = this.scope || this.vm;\n if (this.filters) {\n value = scope._applyFilters(value, this.value, this.filters, true);\n }\n try {\n this.setter.call(scope, scope, value);\n } catch (e) {\n if (process.env.NODE_ENV !== 'production' && config.warnExpressionErrors) {\n warn('Error when evaluating setter ' + '\"' + this.expression + '\": ' + e.toString(), this.vm);\n }\n }\n // two-way sync for v-for alias\n var forContext = scope.$forContext;\n if (forContext && forContext.alias === this.expression) {\n if (forContext.filters) {\n process.env.NODE_ENV !== 'production' && warn('It seems you are using two-way binding on ' + 'a v-for alias (' + this.expression + '), and the ' + 'v-for has filters. This will not work properly. ' + 'Either remove the filters or use an array of ' + 'objects and bind to object properties instead.', this.vm);\n return;\n }\n forContext._withLock(function () {\n if (scope.$key) {\n // original is an object\n forContext.rawValue[scope.$key] = value;\n } else {\n forContext.rawValue.$set(scope.$index, value);\n }\n });\n }\n};\n\n/**\n * Prepare for dependency collection.\n */\n\nWatcher.prototype.beforeGet = function () {\n Dep.target = this;\n};\n\n/**\n * Add a dependency to this directive.\n *\n * @param {Dep} dep\n */\n\nWatcher.prototype.addDep = function (dep) {\n var id = dep.id;\n if (!this.newDepIds.has(id)) {\n this.newDepIds.add(id);\n this.newDeps.push(dep);\n if (!this.depIds.has(id)) {\n dep.addSub(this);\n }\n }\n};\n\n/**\n * Clean up for dependency collection.\n */\n\nWatcher.prototype.afterGet = function () {\n Dep.target = null;\n var i = this.deps.length;\n while (i--) {\n var dep = this.deps[i];\n if (!this.newDepIds.has(dep.id)) {\n dep.removeSub(this);\n }\n }\n var tmp = this.depIds;\n this.depIds = this.newDepIds;\n this.newDepIds = tmp;\n this.newDepIds.clear();\n tmp = this.deps;\n this.deps = this.newDeps;\n this.newDeps = tmp;\n this.newDeps.length = 0;\n};\n\n/**\n * Subscriber interface.\n * Will be called when a dependency changes.\n *\n * @param {Boolean} shallow\n */\n\nWatcher.prototype.update = function (shallow) {\n if (this.lazy) {\n this.dirty = true;\n } else if (this.sync || !config.async) {\n this.run();\n } else {\n // if queued, only overwrite shallow with non-shallow,\n // but not the other way around.\n this.shallow = this.queued ? shallow ? this.shallow : false : !!shallow;\n this.queued = true;\n // record before-push error stack in debug mode\n /* istanbul ignore if */\n if (process.env.NODE_ENV !== 'production' && config.debug) {\n this.prevError = new Error('[vue] async stack trace');\n }\n pushWatcher(this);\n }\n};\n\n/**\n * Batcher job interface.\n * Will be called by the batcher.\n */\n\nWatcher.prototype.run = function () {\n if (this.active) {\n var value = this.get();\n if (value !== this.value ||\n // Deep watchers and watchers on Object/Arrays should fire even\n // when the value is the same, because the value may\n // have mutated; but only do so if this is a\n // non-shallow update (caused by a vm digest).\n (isObject(value) || this.deep) && !this.shallow) {\n // set new value\n var oldValue = this.value;\n this.value = value;\n // in debug + async mode, when a watcher callbacks\n // throws, we also throw the saved before-push error\n // so the full cross-tick stack trace is available.\n var prevError = this.prevError;\n /* istanbul ignore if */\n if (process.env.NODE_ENV !== 'production' && config.debug && prevError) {\n this.prevError = null;\n try {\n this.cb.call(this.vm, value, oldValue);\n } catch (e) {\n nextTick(function () {\n throw prevError;\n }, 0);\n throw e;\n }\n } else {\n this.cb.call(this.vm, value, oldValue);\n }\n }\n this.queued = this.shallow = false;\n }\n};\n\n/**\n * Evaluate the value of the watcher.\n * This only gets called for lazy watchers.\n */\n\nWatcher.prototype.evaluate = function () {\n // avoid overwriting another watcher that is being\n // collected.\n var current = Dep.target;\n this.value = this.get();\n this.dirty = false;\n Dep.target = current;\n};\n\n/**\n * Depend on all deps collected by this watcher.\n */\n\nWatcher.prototype.depend = function () {\n var i = this.deps.length;\n while (i--) {\n this.deps[i].depend();\n }\n};\n\n/**\n * Remove self from all dependencies' subcriber list.\n */\n\nWatcher.prototype.teardown = function () {\n if (this.active) {\n // remove self from vm's watcher list\n // this is a somewhat expensive operation so we skip it\n // if the vm is being destroyed or is performing a v-for\n // re-render (the watcher list is then filtered by v-for).\n if (!this.vm._isBeingDestroyed && !this.vm._vForRemoving) {\n this.vm._watchers.$remove(this);\n }\n var i = this.deps.length;\n while (i--) {\n this.deps[i].removeSub(this);\n }\n this.active = false;\n this.vm = this.cb = this.value = null;\n }\n};\n\n/**\n * Recrusively traverse an object to evoke all converted\n * getters, so that every nested property inside the object\n * is collected as a \"deep\" dependency.\n *\n * @param {*} val\n */\n\nvar seenObjects = new _Set();\nfunction traverse(val, seen) {\n var i = undefined,\n keys = undefined;\n if (!seen) {\n seen = seenObjects;\n seen.clear();\n }\n var isA = isArray(val);\n var isO = isObject(val);\n if (isA || isO) {\n if (val.__ob__) {\n var depId = val.__ob__.dep.id;\n if (seen.has(depId)) {\n return;\n } else {\n seen.add(depId);\n }\n }\n if (isA) {\n i = val.length;\n while (i--) traverse(val[i], seen);\n } else if (isO) {\n keys = Object.keys(val);\n i = keys.length;\n while (i--) traverse(val[keys[i]], seen);\n }\n }\n}\n\nvar text$1 = {\n\n bind: function bind() {\n this.attr = this.el.nodeType === 3 ? 'data' : 'textContent';\n },\n\n update: function update(value) {\n this.el[this.attr] = _toString(value);\n }\n};\n\nvar templateCache = new Cache(1000);\nvar idSelectorCache = new Cache(1000);\n\nvar map = {\n efault: [0, '', ''],\n legend: [1, '
', '
'],\n tr: [2, '', '
'],\n col: [2, '', '
']\n};\n\nmap.td = map.th = [3, '', '
'];\n\nmap.option = map.optgroup = [1, ''];\n\nmap.thead = map.tbody = map.colgroup = map.caption = map.tfoot = [1, '', '
'];\n\nmap.g = map.defs = map.symbol = map.use = map.image = map.text = map.circle = map.ellipse = map.line = map.path = map.polygon = map.polyline = map.rect = [1, '', ''];\n\n/**\n * Check if a node is a supported template node with a\n * DocumentFragment content.\n *\n * @param {Node} node\n * @return {Boolean}\n */\n\nfunction isRealTemplate(node) {\n return isTemplate(node) && isFragment(node.content);\n}\n\nvar tagRE$1 = /<([\\w:-]+)/;\nvar entityRE = /&#?\\w+?;/;\nvar commentRE = /