or
+ *
+ * - dynamic:
+ *
+ */
+
+ bind: function (){
+ if (!this.el.__vue__) {
+ // keep-alive cache
+ this.keepAlive = this.params.keepAlive
+ if (this.keepAlive) {
+ this.cache = {}
+ }
+ // check inline-template
+ if (this.params.inlineTemplate) {
+ // extract inline template as a DocumentFragment
+ this.inlineTemplate = _.extractContent(this.el, true)
+ }
+ // component resolution related state
+ this.pendingComponentCb =
+ this.Component = null
+ // transition related state
+ this.pendingRemovals = 0
+ this.pendingRemovalCb = null
+ // create a ref anchor
+ this.anchor = _.createAnchor('v-component')
+ _.replace(this.el, this.anchor)
+ // remove is attribute.
+ // this is removed during compilation, but because compilation is
+ // cached, when the component is used elsewhere this attribute
+ // will remain at link time.
+ this.el.removeAttribute('is')
+ // remove ref, same as above
+ if (this.descriptor.ref) {
+ this.el.removeAttribute('v-ref:' + _.hyphenate(this.descriptor.ref))
+ }
+ // if static, build right now.
+ if (this.literal) {
+ this.setComponent(this.expression)
+ }
+ } else {
+ ("development") !== 'production' && _.warn(
+ 'cannot mount component "' + this.expression + '" ' +
+ 'on already mounted element: ' + this.el
+ )
+ }
+ },
+
+ /**
+ * Public update, called by the watcher in the dynamic
+ * literal scenario, e.g.
+ */
+
+ update: function (value){
+ if (!this.literal) {
+ this.setComponent(value)
+ }
+ },
+
+ /**
+ * Switch dynamic components. May resolve the component
+ * asynchronously, and perform transition based on
+ * specified transition mode. Accepts a few additional
+ * arguments specifically for vue-router.
+ *
+ * The callback is called when the full transition is
+ * finished.
+ *
+ * @param {String} value
+ * @param {Function} [cb]
+ */
+
+ setComponent: function (value, cb){
+ this.invalidatePending()
+ if (!value) {
+ // just remove current
+ this.unbuild(true)
+ this.remove(this.childVM, cb)
+ this.childVM = null
+ } else {
+ var self = this
+ this.resolveComponent(value, function (){
+ self.mountComponent(cb)
+ })
+ }
+ },
+
+ /**
+ * Resolve the component constructor to use when creating
+ * the child vm.
+ */
+
+ resolveComponent: function (id, cb){
+ var self = this
+ this.pendingComponentCb = _.cancellable(function (Component){
+ self.ComponentName = Component.options.name || id
+ self.Component = Component
+ cb()
+ })
+ this.vm._resolveComponent(id, this.pendingComponentCb)
+ },
+
+ /**
+ * Create a new instance using the current constructor and
+ * replace the existing instance. This method doesn't care
+ * whether the new component and the old one are actually
+ * the same.
+ *
+ * @param {Function} [cb]
+ */
+
+ mountComponent: function (cb){
+ // actual mount
+ this.unbuild(true)
+ var self = this
+ var activateHook = this.Component.options.activate
+ var cached = this.getCached()
+ var newComponent = this.build()
+ if (activateHook && !cached) {
+ this.waitingFor = newComponent
+ activateHook.call(newComponent, function (){
+ self.waitingFor = null
+ self.transition(newComponent, cb)
+ })
+ } else {
+ // update ref for kept-alive component
+ if (cached) {
+ newComponent._updateRef()
+ }
+ this.transition(newComponent, cb)
+ }
+ },
+
+ /**
+ * When the component changes or unbinds before an async
+ * constructor is resolved, we need to invalidate its
+ * pending callback.
+ */
+
+ invalidatePending: function (){
+ if (this.pendingComponentCb) {
+ this.pendingComponentCb.cancel()
+ this.pendingComponentCb = null
+ }
+ },
+
+ /**
+ * Instantiate/insert a new child vm.
+ * If keep alive and has cached instance, insert that
+ * instance; otherwise build a new one and cache it.
+ *
+ * @param {Object} [extraOptions]
+ * @return {Vue} - the created instance
+ */
+
+ build: function (extraOptions){
+ var cached = this.getCached()
+ if (cached) {
+ return cached
+ }
+ if (this.Component) {
+ // default options
+ var options = {
+ name: this.ComponentName,
+ el: templateParser.clone(this.el),
+ template: this.inlineTemplate,
+ // make sure to add the child with correct parent
+ // if this is a transcluded component, its parent
+ // should be the transclusion host.
+ parent: this._host || this.vm,
+ // if no inline-template, then the compiled
+ // linker can be cached for better performance.
+ _linkerCachable: !this.inlineTemplate,
+ _ref: this.descriptor.ref,
+ _asComponent: true,
+ _isRouterView: this._isRouterView,
+ // if this is a transcluded component, context
+ // will be the common parent vm of this instance
+ // and its host.
+ _context: this.vm,
+ // if this is inside an inline v-for, the scope
+ // will be the intermediate scope created for this
+ // repeat fragment. this is used for linking props
+ // and container directives.
+ _scope: this._scope,
+ // pass in the owner fragment of this component.
+ // this is necessary so that the fragment can keep
+ // track of its contained components in order to
+ // call attach/detach hooks for them.
+ _frag: this._frag
+ }
+ // extra options
+ // in 1.0.0 this is used by vue-router only
+ /* istanbul ignore if */
+ if (extraOptions) {
+ _.extend(options, extraOptions)
+ }
+ var child = new this.Component(options)
+ if (this.keepAlive) {
+ this.cache[this.Component.cid] = child
+ }
+ /* istanbul ignore if */
+ if (("development") !== 'production' &&
+ this.el.hasAttribute('transition') &&
+ child._isFragment) {
+ _.warn(
+ 'Transitions will not work on a fragment instance. ' +
+ 'Template: ' + child.$options.template
+ )
+ }
+ return child
+ }
+ },
+
+ /**
+ * Try to get a cached instance of the current component.
+ *
+ * @return {Vue|undefined}
+ */
+
+ getCached: function (){
+ return this.keepAlive && this.cache[this.Component.cid]
+ },
+
+ /**
+ * Teardown the current child, but defers cleanup so
+ * that we can separate the destroy and removal steps.
+ *
+ * @param {Boolean} defer
+ */
+
+ unbuild: function (defer){
+ if (this.waitingFor) {
+ this.waitingFor.$destroy()
+ this.waitingFor = null
+ }
+ var child = this.childVM
+ if (!child || this.keepAlive) {
+ if (child) {
+ // remove ref
+ child._updateRef(true)
+ }
+ return
+ }
+ // the sole purpose of `deferCleanup` is so that we can
+ // "deactivate" the vm right now and perform DOM removal
+ // later.
+ child.$destroy(false, defer)
+ },
+
+ /**
+ * Remove current destroyed child and manually do
+ * the cleanup after removal.
+ *
+ * @param {Function} cb
+ */
+
+ remove: function (child, cb){
+ var keepAlive = this.keepAlive
+ if (child) {
+ // we may have a component switch when a previous
+ // component is still being transitioned out.
+ // we want to trigger only one lastest insertion cb
+ // when the existing transition finishes. (#1119)
+ this.pendingRemovals++
+ this.pendingRemovalCb = cb
+ var self = this
+ child.$remove(function (){
+ self.pendingRemovals--
+ if (!keepAlive) child._cleanup()
+ if (!self.pendingRemovals && self.pendingRemovalCb) {
+ self.pendingRemovalCb()
+ self.pendingRemovalCb = null
+ }
+ })
+ } else if (cb) {
+ cb()
+ }
+ },
+
+ /**
+ * Actually swap the components, depending on the
+ * transition mode. Defaults to simultaneous.
+ *
+ * @param {Vue} target
+ * @param {Function} [cb]
+ */
+
+ transition: function (target, cb){
+ var self = this
+ var current = this.childVM
+ // for devtool inspection
+ if (true) {
+ if (current) current._inactive = true
+ target._inactive = false
+ }
+ this.childVM = target
+ switch (self.params.transitionMode) {
+ case 'in-out':
+ target.$before(self.anchor, function (){
+ self.remove(current, cb)
+ })
+ break
+ case 'out-in':
+ self.remove(current, function (){
+ target.$before(self.anchor, cb)
+ })
+ break
+ default:
+ self.remove(current)
+ target.$before(self.anchor, cb)
+ }
+ },
+
+ /**
+ * Unbind.
+ */
+
+ unbind: function (){
+ this.invalidatePending()
+ // Do not defer cleanup when unbinding
+ this.unbuild()
+ // destroy all keep-alive cached instances
+ if (this.cache) {
+ for (var key in this.cache) {
+ this.cache[key].$destroy()
+ }
+ this.cache = null
+ }
+ }
+ }
+
+ /***/
+ },
+ /* 39 */
+ /***/ function (module, exports, __webpack_require__){
+
+ // NOTE: the prop internal directive is compiled and linked
+ // during _initScope(), before the created hook is called.
+ // The purpose is to make the initial prop values available
+ // inside `created` hooks and `data` functions.
+
+ var _ = __webpack_require__(1)
+ var Watcher = __webpack_require__(40)
+ var bindingModes = __webpack_require__(5)._propBindingModes
+
+ module.exports = {
+
+ bind: function (){
+
+ var child = this.vm
+ var parent = child._context
+ // passed in from compiler directly
+ var prop = this.descriptor.prop
+ var childKey = prop.path
+ var parentKey = prop.parentPath
+ var twoWay = prop.mode === bindingModes.TWO_WAY
+
+ var parentWatcher = this.parentWatcher = new Watcher(
+ parent,
+ parentKey,
+ function (val){
+ if (_.assertProp(prop, val)) {
+ child[childKey] = val
+ }
+ }, {
+ twoWay: twoWay,
+ filters: prop.filters,
+ // important: props need to be observed on the
+ // v-for scope if present
+ scope: this._scope
+ }
+ )
+
+ // set the child initial value.
+ _.initProp(child, prop, parentWatcher.value)
+
+ // setup two-way binding
+ if (twoWay) {
+ // important: defer the child watcher creation until
+ // the created hook (after data observation)
+ var self = this
+ child.$once('hook:created', function (){
+ self.childWatcher = new Watcher(
+ child,
+ childKey,
+ function (val){
+ parentWatcher.set(val)
+ }, {
+ // ensure sync upward before parent sync down.
+ // this is necessary in cases e.g. the child
+ // mutates a prop array, then replaces it. (#1683)
+ sync: true
+ }
+ )
+ })
+ }
+ },
+
+ unbind: function (){
+ this.parentWatcher.teardown()
+ if (this.childWatcher) {
+ this.childWatcher.teardown()
+ }
+ }
+ }
+
+ /***/
+ },
+ /* 40 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var config = __webpack_require__(5)
+ var Dep = __webpack_require__(41)
+ var expParser = __webpack_require__(42)
+ var batcher = __webpack_require__(44)
+ var uid = 0
+
+ /**
+ * A watcher parses an expression, collects dependencies,
+ * and fires callback when the expression value changes.
+ * This is used for both the $watch() api and directives.
+ *
+ * @param {Vue} vm
+ * @param {String} expression
+ * @param {Function} cb
+ * @param {Object} options
+ * - {Array} filters
+ * - {Boolean} twoWay
+ * - {Boolean} deep
+ * - {Boolean} user
+ * - {Boolean} sync
+ * - {Boolean} lazy
+ * - {Function} [preProcess]
+ * - {Function} [postProcess]
+ * @constructor
+ */
+
+ function Watcher(vm, expOrFn, cb, options){
+ // mix in options
+ if (options) {
+ _.extend(this, options)
+ }
+ var isFn = typeof expOrFn === 'function'
+ this.vm = vm
+ vm._watchers.push(this)
+ this.expression = isFn ? expOrFn.toString() : expOrFn
+ this.cb = cb
+ this.id = ++uid // uid for batching
+ this.active = true
+ this.dirty = this.lazy // for lazy watchers
+ this.deps = Object.create(null)
+ this.newDeps = null
+ this.prevError = null // for async error stacks
+ // parse expression for getter/setter
+ if (isFn) {
+ this.getter = expOrFn
+ this.setter = undefined
+ } else {
+ var res = expParser.parse(expOrFn, this.twoWay)
+ this.getter = res.get
+ this.setter = res.set
+ }
+ this.value = this.lazy
+ ? undefined
+ : this.get()
+ // state for avoiding false triggers for deep and Array
+ // watchers during vm._digest()
+ this.queued = this.shallow = false
+ }
+
+ /**
+ * Add a dependency to this directive.
+ *
+ * @param {Dep} dep
+ */
+
+ Watcher.prototype.addDep = function (dep){
+ var id = dep.id
+ if (!this.newDeps[id]) {
+ this.newDeps[id] = dep
+ if (!this.deps[id]) {
+ this.deps[id] = dep
+ dep.addSub(this)
+ }
+ }
+ }
+
+ /**
+ * Evaluate the getter, and re-collect dependencies.
+ */
+
+ Watcher.prototype.get = function (){
+ this.beforeGet()
+ var scope = this.scope || this.vm
+ var value
+ try {
+ value = this.getter.call(scope, scope)
+ } catch (e) {
+ if (
+ ("development") !== 'production' &&
+ config.warnExpressionErrors
+ ) {
+ _.warn(
+ 'Error when evaluating expression "' +
+ this.expression + '". ' +
+ (config.debug
+ ? ''
+ : 'Turn on debug mode to see stack trace.'
+ ), e
+ )
+ }
+ }
+ // "touch" every property so they are all tracked as
+ // dependencies for deep watching
+ if (this.deep) {
+ traverse(value)
+ }
+ if (this.preProcess) {
+ value = this.preProcess(value)
+ }
+ if (this.filters) {
+ value = scope._applyFilters(value, null, this.filters, false)
+ }
+ if (this.postProcess) {
+ value = this.postProcess(value)
+ }
+ this.afterGet()
+ return value
+ }
+
+ /**
+ * Set the corresponding value with the setter.
+ *
+ * @param {*} value
+ */
+
+ Watcher.prototype.set = function (value){
+ var scope = this.scope || this.vm
+ if (this.filters) {
+ value = scope._applyFilters(
+ value, this.value, this.filters, true)
+ }
+ try {
+ this.setter.call(scope, scope, value)
+ } catch (e) {
+ if (
+ ("development") !== 'production' &&
+ config.warnExpressionErrors
+ ) {
+ _.warn(
+ 'Error when evaluating setter "' +
+ this.expression + '"', e
+ )
+ }
+ }
+ // two-way sync for v-for alias
+ var forContext = scope.$forContext
+ if (forContext && forContext.alias === this.expression) {
+ if (forContext.filters) {
+ ("development") !== '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.'
+ )
+ return
+ }
+ forContext._withLock(function (){
+ if (scope.$key) { // original is an object
+ forContext.rawValue[scope.$key] = value
+ } else {
+ forContext.rawValue.$set(scope.$index, value)
+ }
+ })
+ }
+ }
+
+ /**
+ * Prepare for dependency collection.
+ */
+
+ Watcher.prototype.beforeGet = function (){
+ Dep.target = this
+ this.newDeps = Object.create(null)
+ }
+
+ /**
+ * Clean up for dependency collection.
+ */
+
+ Watcher.prototype.afterGet = function (){
+ Dep.target = null
+ var ids = Object.keys(this.deps)
+ var i = ids.length
+ while (i--) {
+ var id = ids[i]
+ if (!this.newDeps[id]) {
+ this.deps[id].removeSub(this)
+ }
+ }
+ this.deps = this.newDeps
+ }
+
+ /**
+ * Subscriber interface.
+ * Will be called when a dependency changes.
+ *
+ * @param {Boolean} shallow
+ */
+
+ Watcher.prototype.update = function (shallow){
+ if (this.lazy) {
+ this.dirty = true
+ } else if (this.sync || !config.async) {
+ this.run()
+ } else {
+ // if queued, only overwrite shallow with non-shallow,
+ // but not the other way around.
+ this.shallow = this.queued
+ ? shallow
+ ? this.shallow
+ : false
+ : !!shallow
+ this.queued = true
+ // record before-push error stack in debug mode
+ /* istanbul ignore if */
+ if (("development") !== 'production' && config.debug) {
+ this.prevError = new Error('[vue] async stack trace')
+ }
+ batcher.push(this)
+ }
+ }
+
+ /**
+ * Batcher job interface.
+ * Will be called by the batcher.
+ */
+
+ Watcher.prototype.run = function (){
+ if (this.active) {
+ var value = this.get()
+ if (
+ value !== this.value ||
+ // Deep watchers and Array watchers should fire even
+ // when the value is the same, because the value may
+ // have mutated; but only do so if this is a
+ // non-shallow update (caused by a vm digest).
+ ((_.isArray(value) || this.deep) && !this.shallow)
+ ) {
+ // set new value
+ var oldValue = this.value
+ this.value = value
+ // in debug + async mode, when a watcher callbacks
+ // throws, we also throw the saved before-push error
+ // so the full cross-tick stack trace is available.
+ var prevError = this.prevError
+ /* istanbul ignore if */
+ if (("development") !== 'production' &&
+ config.debug && prevError) {
+ this.prevError = null
+ try {
+ this.cb.call(this.vm, value, oldValue)
+ } catch (e) {
+ _.nextTick(function (){
+ throw prevError
+ }, 0)
+ throw e
+ }
+ } else {
+ this.cb.call(this.vm, value, oldValue)
+ }
+ }
+ this.queued = this.shallow = false
+ }
+ }
+
+ /**
+ * Evaluate the value of the watcher.
+ * This only gets called for lazy watchers.
+ */
+
+ Watcher.prototype.evaluate = function (){
+ // avoid overwriting another watcher that is being
+ // collected.
+ var current = Dep.target
+ this.value = this.get()
+ this.dirty = false
+ Dep.target = current
+ }
+
+ /**
+ * Depend on all deps collected by this watcher.
+ */
+
+ Watcher.prototype.depend = function (){
+ var depIds = Object.keys(this.deps)
+ var i = depIds.length
+ while (i--) {
+ this.deps[depIds[i]].depend()
+ }
+ }
+
+ /**
+ * Remove self from all dependencies' subcriber list.
+ */
+
+ Watcher.prototype.teardown = function (){
+ if (this.active) {
+ // remove self from vm's watcher list
+ // we can skip this if the vm if being destroyed
+ // which can improve teardown performance.
+ if (!this.vm._isBeingDestroyed) {
+ this.vm._watchers.$remove(this)
+ }
+ var depIds = Object.keys(this.deps)
+ var i = depIds.length
+ while (i--) {
+ this.deps[depIds[i]].removeSub(this)
+ }
+ this.active = false
+ this.vm = this.cb = this.value = null
+ }
+ }
+
+ /**
+ * Recrusively traverse an object to evoke all converted
+ * getters, so that every nested property inside the object
+ * is collected as a "deep" dependency.
+ *
+ * @param {*} val
+ */
+
+ function traverse(val){
+ var i, keys
+ if (_.isArray(val)) {
+ i = val.length
+ while (i--) traverse(val[i])
+ } else if (_.isObject(val)) {
+ keys = Object.keys(val)
+ i = keys.length
+ while (i--) traverse(val[keys[i]])
+ }
+ }
+
+ module.exports = Watcher
+
+ /***/
+ },
+ /* 41 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var uid = 0
+
+ /**
+ * A dep is an observable that can have multiple
+ * directives subscribing to it.
+ *
+ * @constructor
+ */
+
+ function Dep(){
+ this.id = uid++
+ this.subs = []
+ }
+
+ // the current target watcher being evaluated.
+ // this is globally unique because there could be only one
+ // watcher being evaluated at any time.
+ Dep.target = null
+
+ /**
+ * Add a directive subscriber.
+ *
+ * @param {Directive} sub
+ */
+
+ Dep.prototype.addSub = function (sub){
+ this.subs.push(sub)
+ }
+
+ /**
+ * Remove a directive subscriber.
+ *
+ * @param {Directive} sub
+ */
+
+ Dep.prototype.removeSub = function (sub){
+ this.subs.$remove(sub)
+ }
+
+ /**
+ * Add self as a dependency to the target watcher.
+ */
+
+ Dep.prototype.depend = function (){
+ Dep.target.addDep(this)
+ }
+
+ /**
+ * Notify all subscribers of a new value.
+ */
+
+ Dep.prototype.notify = function (){
+ // stablize the subscriber list first
+ var subs = _.toArray(this.subs)
+ for (var i = 0, l = subs.length; i < l; i++) {
+ subs[i].update()
+ }
+ }
+
+ module.exports = Dep
+
+ /***/
+ },
+ /* 42 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var Path = __webpack_require__(43)
+ var Cache = __webpack_require__(7)
+ var expressionCache = new Cache(1000)
+
+ var allowedKeywords =
+ 'Math,Date,this,true,false,null,undefined,Infinity,NaN,' +
+ 'isNaN,isFinite,decodeURI,decodeURIComponent,encodeURI,' +
+ 'encodeURIComponent,parseInt,parseFloat'
+ var allowedKeywordsRE =
+ new RegExp('^(' + allowedKeywords.replace(/,/g, '\\b|') + '\\b)')
+
+ // keywords that don't make sense inside expressions
+ var 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,' +
+ 'proctected,static,interface,private,public'
+ var improperKeywordsRE =
+ new RegExp('^(' + improperKeywords.replace(/,/g, '\\b|') + '\\b)')
+
+ var wsRE = /\s/g
+ var newlineRE = /\n/g
+ var saveRE = /[\{,]\s*[\w\$_]+\s*:|('[^']*'|"[^"]*")|new |typeof |void /g
+ var restoreRE = /"(\d+)"/g
+ var pathTestRE = /^[A-Za-z_$][\w$]*(\.[A-Za-z_$][\w$]*|\['.*?'\]|\[".*?"\]|\[\d+\]|\[[A-Za-z_$][\w$]*\])*$/
+ var pathReplaceRE = /[^\w$\.]([A-Za-z_$][\w$]*(\.[A-Za-z_$][\w$]*|\['.*?'\]|\[".*?"\])*)/g
+ var booleanLiteralRE = /^(true|false)$/
+
+ /**
+ * Save / Rewrite / Restore
+ *
+ * When rewriting paths found in an expression, it is
+ * possible for the same letter sequences to be found in
+ * strings and Object literal property keys. Therefore we
+ * remove and store these parts in a temporary array, and
+ * restore them after the path rewrite.
+ */
+
+ var saved = []
+
+ /**
+ * Save replacer
+ *
+ * The save regex can match two possible cases:
+ * 1. An opening object literal
+ * 2. A string
+ * If matched as a plain string, we need to escape its
+ * newlines, since the string needs to be preserved when
+ * generating the function body.
+ *
+ * @param {String} str
+ * @param {String} isString - str if matched as a string
+ * @return {String} - placeholder with index
+ */
+
+ function save(str, isString){
+ var i = saved.length
+ saved[i] = isString
+ ? str.replace(newlineRE, '\\n')
+ : str
+ return '"' + i + '"'
+ }
+
+ /**
+ * Path rewrite replacer
+ *
+ * @param {String} raw
+ * @return {String}
+ */
+
+ function rewrite(raw){
+ var c = raw.charAt(0)
+ var path = raw.slice(1)
+ if (allowedKeywordsRE.test(path)) {
+ return raw
+ } else {
+ path = path.indexOf('"') > -1
+ ? path.replace(restoreRE, restore)
+ : path
+ return c + 'scope.' + path
+ }
+ }
+
+ /**
+ * Restore replacer
+ *
+ * @param {String} str
+ * @param {String} i - matched save index
+ * @return {String}
+ */
+
+ function restore(str, i){
+ return saved[i]
+ }
+
+ /**
+ * Rewrite an expression, prefixing all path accessors with
+ * `scope.` and generate getter/setter functions.
+ *
+ * @param {String} exp
+ * @param {Boolean} needSet
+ * @return {Function}
+ */
+
+ function compileExpFns(exp, needSet){
+ if (improperKeywordsRE.test(exp)) {
+ ("development") !== 'production' && _.warn(
+ 'Avoid using reserved keywords in expression: ' + exp
+ )
+ }
+ // reset state
+ saved.length = 0
+ // save strings and object literal keys
+ var body = exp
+ .replace(saveRE, save)
+ .replace(wsRE, '')
+ // rewrite all paths
+ // pad 1 space here becaue the regex matches 1 extra char
+ body = (' ' + body)
+ .replace(pathReplaceRE, rewrite)
+ .replace(restoreRE, restore)
+ var getter = makeGetter(body)
+ if (getter) {
+ return {
+ get: getter,
+ body: body,
+ set: needSet
+ ? makeSetter(body)
+ : null
+ }
+ }
+ }
+
+ /**
+ * Compile getter setters for a simple path.
+ *
+ * @param {String} exp
+ * @return {Function}
+ */
+
+ function compilePathFns(exp){
+ var getter, path
+ if (exp.indexOf('[') < 0) {
+ // really simple path
+ path = exp.split('.')
+ path.raw = exp
+ getter = Path.compileGetter(path)
+ } else {
+ // do the real parsing
+ path = Path.parse(exp)
+ getter = path.get
+ }
+ return {
+ get: getter,
+ // always generate setter for simple paths
+ set: function (obj, val){
+ Path.set(obj, path, val)
+ }
+ }
+ }
+
+ /**
+ * Build a getter function. Requires eval.
+ *
+ * We isolate the try/catch so it doesn't affect the
+ * optimization of the parse function when it is not called.
+ *
+ * @param {String} body
+ * @return {Function|undefined}
+ */
+
+ function makeGetter(body){
+ try {
+ return new Function('scope', 'return ' + body + ';')
+ } catch (e) {
+ ("development") !== 'production' && _.warn(
+ 'Invalid expression. ' +
+ 'Generated function body: ' + body
+ )
+ }
+ }
+
+ /**
+ * Build a setter function.
+ *
+ * This is only needed in rare situations like "a[b]" where
+ * a settable path requires dynamic evaluation.
+ *
+ * This setter function may throw error when called if the
+ * expression body is not a valid left-hand expression in
+ * assignment.
+ *
+ * @param {String} body
+ * @return {Function|undefined}
+ */
+
+ function makeSetter(body){
+ try {
+ return new Function('scope', 'value', body + '=value;')
+ } catch (e) {
+ ("development") !== 'production' && _.warn(
+ 'Invalid setter function body: ' + body
+ )
+ }
+ }
+
+ /**
+ * Check for setter existence on a cache hit.
+ *
+ * @param {Function} hit
+ */
+
+ function checkSetter(hit){
+ if (!hit.set) {
+ hit.set = makeSetter(hit.body)
+ }
+ }
+
+ /**
+ * Parse an expression into re-written getter/setters.
+ *
+ * @param {String} exp
+ * @param {Boolean} needSet
+ * @return {Function}
+ */
+
+ exports.parse = function (exp, needSet){
+ exp = exp.trim()
+ // try cache
+ var hit = expressionCache.get(exp)
+ if (hit) {
+ if (needSet) {
+ checkSetter(hit)
+ }
+ return hit
+ }
+ // we do a simple path check to optimize for them.
+ // the check fails valid paths with unusal whitespaces,
+ // but that's too rare and we don't care.
+ // also skip boolean literals and paths that start with
+ // global "Math"
+ var res = exports.isSimplePath(exp)
+ ? compilePathFns(exp)
+ : compileExpFns(exp, needSet)
+ expressionCache.put(exp, res)
+ return res
+ }
+
+ /**
+ * Check if an expression is a simple path.
+ *
+ * @param {String} exp
+ * @return {Boolean}
+ */
+
+ exports.isSimplePath = function (exp){
+ return pathTestRE.test(exp) &&
+ // don't treat true/false as paths
+ !booleanLiteralRE.test(exp) &&
+ // Math constants e.g. Math.PI, Math.E etc.
+ exp.slice(0, 5) !== 'Math.'
+ }
+
+ /***/
+ },
+ /* 43 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var Cache = __webpack_require__(7)
+ var pathCache = new Cache(1000)
+ var identRE = exports.identRE = /^[$_a-zA-Z]+[\w$]*$/
+
+ // actions
+ var APPEND = 0
+ var PUSH = 1
+
+ // states
+ var BEFORE_PATH = 0
+ var IN_PATH = 1
+ var BEFORE_IDENT = 2
+ var IN_IDENT = 3
+ var BEFORE_ELEMENT = 4
+ var AFTER_ZERO = 5
+ var IN_INDEX = 6
+ var IN_SINGLE_QUOTE = 7
+ var IN_DOUBLE_QUOTE = 8
+ var IN_SUB_PATH = 9
+ var AFTER_ELEMENT = 10
+ var AFTER_PATH = 11
+ var ERROR = 12
+
+ var pathStateMachine = []
+
+ pathStateMachine[BEFORE_PATH] = {
+ 'ws': [BEFORE_PATH],
+ 'ident': [IN_IDENT, APPEND],
+ '[': [BEFORE_ELEMENT],
+ 'eof': [AFTER_PATH]
+ }
+
+ pathStateMachine[IN_PATH] = {
+ 'ws': [IN_PATH],
+ '.': [BEFORE_IDENT],
+ '[': [BEFORE_ELEMENT],
+ 'eof': [AFTER_PATH]
+ }
+
+ pathStateMachine[BEFORE_IDENT] = {
+ 'ws': [BEFORE_IDENT],
+ 'ident': [IN_IDENT, APPEND]
+ }
+
+ pathStateMachine[IN_IDENT] = {
+ 'ident': [IN_IDENT, APPEND],
+ '0': [IN_IDENT, APPEND],
+ 'number': [IN_IDENT, APPEND],
+ 'ws': [IN_PATH, PUSH],
+ '.': [BEFORE_IDENT, PUSH],
+ '[': [BEFORE_ELEMENT, PUSH],
+ 'eof': [AFTER_PATH, PUSH]
+ }
+
+ pathStateMachine[BEFORE_ELEMENT] = {
+ 'ws': [BEFORE_ELEMENT],
+ '0': [AFTER_ZERO, APPEND],
+ 'number': [IN_INDEX, APPEND],
+ "'": [IN_SINGLE_QUOTE, APPEND, ''],
+ '"': [IN_DOUBLE_QUOTE, APPEND, ''],
+ 'ident': [IN_SUB_PATH, APPEND, '*']
+ }
+
+ pathStateMachine[AFTER_ZERO] = {
+ 'ws': [AFTER_ELEMENT, PUSH],
+ ']': [IN_PATH, PUSH]
+ }
+
+ pathStateMachine[IN_INDEX] = {
+ '0': [IN_INDEX, APPEND],
+ 'number': [IN_INDEX, APPEND],
+ 'ws': [AFTER_ELEMENT],
+ ']': [IN_PATH, PUSH]
+ }
+
+ pathStateMachine[IN_SINGLE_QUOTE] = {
+ "'": [AFTER_ELEMENT],
+ 'eof': ERROR,
+ 'else': [IN_SINGLE_QUOTE, APPEND]
+ }
+
+ pathStateMachine[IN_DOUBLE_QUOTE] = {
+ '"': [AFTER_ELEMENT],
+ 'eof': ERROR,
+ 'else': [IN_DOUBLE_QUOTE, APPEND]
+ }
+
+ pathStateMachine[IN_SUB_PATH] = {
+ 'ident': [IN_SUB_PATH, APPEND],
+ '0': [IN_SUB_PATH, APPEND],
+ 'number': [IN_SUB_PATH, APPEND],
+ 'ws': [AFTER_ELEMENT],
+ ']': [IN_PATH, PUSH]
+ }
+
+ pathStateMachine[AFTER_ELEMENT] = {
+ 'ws': [AFTER_ELEMENT],
+ ']': [IN_PATH, PUSH]
+ }
+
+ /**
+ * Determine the type of a character in a keypath.
+ *
+ * @param {Char} ch
+ * @return {String} type
+ */
+
+ function getPathCharType(ch){
+ if (ch === undefined) {
+ return 'eof'
+ }
+
+ var code = ch.charCodeAt(0)
+
+ switch (code) {
+ case 0x5B: // [
+ case 0x5D: // ]
+ case 0x2E: // .
+ case 0x22: // "
+ case 0x27: // '
+ case 0x30: // 0
+ return ch
+
+ case 0x5F: // _
+ case 0x24: // $
+ return 'ident'
+
+ case 0x20: // Space
+ case 0x09: // Tab
+ case 0x0A: // Newline
+ case 0x0D: // Return
+ case 0xA0: // No-break space
+ case 0xFEFF: // Byte Order Mark
+ case 0x2028: // Line Separator
+ case 0x2029: // Paragraph Separator
+ return 'ws'
+ }
+
+ // a-z, A-Z
+ if (
+ (code >= 0x61 && code <= 0x7A) ||
+ (code >= 0x41 && code <= 0x5A)
+ ) {
+ return 'ident'
+ }
+
+ // 1-9
+ if (code >= 0x31 && code <= 0x39) {
+ return 'number'
+ }
+
+ return 'else'
+ }
+
+ /**
+ * Parse a string path into an array of segments
+ *
+ * @param {String} path
+ * @return {Array|undefined}
+ */
+
+ function parsePath(path){
+ var keys = []
+ var index = -1
+ var mode = BEFORE_PATH
+ var c, newChar, key, type, transition, action, typeMap
+
+ var actions = []
+ actions[PUSH] = function (){
+ if (key === undefined) {
+ return
+ }
+ keys.push(key)
+ key = undefined
+ }
+ actions[APPEND] = function (){
+ if (key === undefined) {
+ key = newChar
+ } else {
+ key += newChar
+ }
+ }
+
+ function maybeUnescapeQuote(){
+ var nextChar = path[index + 1]
+ if ((mode === IN_SINGLE_QUOTE && nextChar === "'") ||
+ (mode === IN_DOUBLE_QUOTE && nextChar === '"')) {
+ index++
+ newChar = nextChar
+ actions[APPEND]()
+ return true
+ }
+ }
+
+ while (mode != null) {
+ index++
+ c = path[index]
+
+ if (c === '\\' && maybeUnescapeQuote()) {
+ continue
+ }
+
+ type = getPathCharType(c)
+ typeMap = pathStateMachine[mode]
+ transition = typeMap[type] || typeMap['else'] || ERROR
+
+ if (transition === ERROR) {
+ return // parse error
+ }
+
+ mode = transition[0]
+ action = actions[transition[1]]
+ if (action) {
+ newChar = transition[2]
+ newChar = newChar === undefined
+ ? c
+ : newChar === '*'
+ ? newChar + c
+ : newChar
+ action()
+ }
+
+ if (mode === AFTER_PATH) {
+ keys.raw = path
+ return keys
+ }
+ }
+ }
+
+ /**
+ * Format a accessor segment based on its type.
+ *
+ * @param {String} key
+ * @return {Boolean}
+ */
+
+ function formatAccessor(key){
+ if (identRE.test(key)) { // identifier
+ return '.' + key
+ } else if (+key === key >>> 0) { // bracket index
+ return '[' + key + ']'
+ } else if (key.charAt(0) === '*') {
+ return '[o' + formatAccessor(key.slice(1)) + ']'
+ } else { // bracket string
+ return '["' + key.replace(/"/g, '\\"') + '"]'
+ }
+ }
+
+ /**
+ * Compiles a getter function with a fixed path.
+ * The fixed path getter supresses errors.
+ *
+ * @param {Array} path
+ * @return {Function}
+ */
+
+ exports.compileGetter = function (path){
+ var body = 'return o' + path.map(formatAccessor).join('')
+ return new Function('o', body)
+ }
+
+ /**
+ * External parse that check for a cache hit first
+ *
+ * @param {String} path
+ * @return {Array|undefined}
+ */
+
+ exports.parse = function (path){
+ var hit = pathCache.get(path)
+ if (!hit) {
+ hit = parsePath(path)
+ if (hit) {
+ hit.get = exports.compileGetter(hit)
+ pathCache.put(path, hit)
+ }
+ }
+ return hit
+ }
+
+ /**
+ * Get from an object from a path string
+ *
+ * @param {Object} obj
+ * @param {String} path
+ */
+
+ exports.get = function (obj, path){
+ path = exports.parse(path)
+ if (path) {
+ return path.get(obj)
+ }
+ }
+
+ /**
+ * Warn against setting non-existent root path on a vm.
+ */
+
+ var warnNonExistent
+ if (true) {
+ warnNonExistent = function (path){
+ _.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.'
+ )
+ }
+ }
+
+ /**
+ * Set on an object from a path
+ *
+ * @param {Object} obj
+ * @param {String | Array} path
+ * @param {*} val
+ */
+
+ exports.set = function (obj, path, val){
+ var original = obj
+ if (typeof path === 'string') {
+ path = exports.parse(path)
+ }
+ if (!path || !_.isObject(obj)) {
+ return false
+ }
+ var last, key
+ for (var i = 0, l = path.length; i < l; i++) {
+ last = obj
+ key = path[i]
+ if (key.charAt(0) === '*') {
+ key = original[key.slice(1)]
+ }
+ if (i < l - 1) {
+ obj = obj[key]
+ if (!_.isObject(obj)) {
+ obj = {}
+ if (("development") !== 'production' && last._isVue) {
+ warnNonExistent(path)
+ }
+ _.set(last, key, obj)
+ }
+ } else {
+ if (_.isArray(obj)) {
+ obj.$set(key, val)
+ } else if (key in obj) {
+ obj[key] = val
+ } else {
+ if (("development") !== 'production' && obj._isVue) {
+ warnNonExistent(path)
+ }
+ _.set(obj, key, val)
+ }
+ }
+ }
+ return true
+ }
+
+ /***/
+ },
+ /* 44 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var config = __webpack_require__(5)
+
+ // we have two separate queues: one for directive updates
+ // and one for user watcher registered via $watch().
+ // we want to guarantee directive updates to be called
+ // before user watchers so that when user watchers are
+ // triggered, the DOM would have already been in updated
+ // state.
+ var queue = []
+ var userQueue = []
+ var has = {}
+ var circular = {}
+ var waiting = false
+ var internalQueueDepleted = false
+
+ /**
+ * Reset the batcher's state.
+ */
+
+ function resetBatcherState(){
+ queue = []
+ userQueue = []
+ has = {}
+ circular = {}
+ waiting = internalQueueDepleted = false
+ }
+
+ /**
+ * Flush both queues and run the watchers.
+ */
+
+ function flushBatcherQueue(){
+ runBatcherQueue(queue)
+ internalQueueDepleted = true
+ runBatcherQueue(userQueue)
+ // dev tool hook
+ /* istanbul ignore if */
+ if (true) {
+ if (_.inBrowser && window.__VUE_DEVTOOLS_GLOBAL_HOOK__) {
+ window.__VUE_DEVTOOLS_GLOBAL_HOOK__.emit('flush')
+ }
+ }
+ resetBatcherState()
+ }
+
+ /**
+ * Run the watchers in a single queue.
+ *
+ * @param {Array} queue
+ */
+
+ function runBatcherQueue(queue){
+ // do not cache length because more watchers might be pushed
+ // as we run existing watchers
+ for (var i = 0; i < queue.length; i++) {
+ var watcher = queue[i]
+ var id = watcher.id
+ has[id] = null
+ watcher.run()
+ // in dev build, check and stop circular updates.
+ if (("development") !== 'production' && has[id] != null) {
+ circular[id] = (circular[id] || 0) + 1
+ if (circular[id] > config._maxUpdateCount) {
+ queue.splice(has[id], 1)
+ _.warn(
+ 'You may have an infinite update loop for watcher ' +
+ 'with expression: ' + watcher.expression
+ )
+ }
+ }
+ }
+ }
+
+ /**
+ * Push a watcher into the watcher queue.
+ * Jobs with duplicate IDs will be skipped unless it's
+ * pushed when the queue is being flushed.
+ *
+ * @param {Watcher} watcher
+ * properties:
+ * - {Number} id
+ * - {Function} run
+ */
+
+ exports.push = function (watcher){
+ var id = watcher.id
+ if (has[id] == null) {
+ // if an internal watcher is pushed, but the internal
+ // queue is already depleted, we run it immediately.
+ if (internalQueueDepleted && !watcher.user) {
+ watcher.run()
+ return
+ }
+ // push watcher into appropriate queue
+ var q = watcher.user ? userQueue : queue
+ has[id] = q.length
+ q.push(watcher)
+ // queue the flush
+ if (!waiting) {
+ waiting = true
+ _.nextTick(flushBatcherQueue)
+ }
+ }
+ }
+
+ /***/
+ },
+ /* 45 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var Transition = __webpack_require__(46)
+
+ module.exports = {
+
+ priority: 1100,
+
+ update: function (id, oldId){
+ var el = this.el
+ // resolve on owner vm
+ var hooks = _.resolveAsset(this.vm.$options, 'transitions', id)
+ id = id || 'v'
+ // apply on closest vm
+ el.__v_trans = new Transition(el, id, hooks, this.el.__vue__ || this.vm)
+ if (oldId) {
+ _.removeClass(el, oldId + '-transition')
+ }
+ _.addClass(el, id + '-transition')
+ }
+ }
+
+ /***/
+ },
+ /* 46 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var queue = __webpack_require__(47)
+ var addClass = _.addClass
+ var removeClass = _.removeClass
+ var transitionEndEvent = _.transitionEndEvent
+ var animationEndEvent = _.animationEndEvent
+ var transDurationProp = _.transitionProp + 'Duration'
+ var animDurationProp = _.animationProp + 'Duration'
+
+ var TYPE_TRANSITION = 1
+ var TYPE_ANIMATION = 2
+
+ /**
+ * A Transition object that encapsulates the state and logic
+ * of the transition.
+ *
+ * @param {Element} el
+ * @param {String} id
+ * @param {Object} hooks
+ * @param {Vue} vm
+ */
+
+ function Transition(el, id, hooks, vm){
+ this.id = id
+ this.el = el
+ this.enterClass = id + '-enter'
+ this.leaveClass = id + '-leave'
+ this.hooks = hooks
+ this.vm = vm
+ // async state
+ this.pendingCssEvent =
+ this.pendingCssCb =
+ this.cancel =
+ this.pendingJsCb =
+ this.op =
+ this.cb = null
+ this.justEntered = false
+ this.entered = this.left = false
+ this.typeCache = {}
+ // bind
+ var self = this
+ ;
+ ['enterNextTick', 'enterDone', 'leaveNextTick', 'leaveDone']
+ .forEach(function (m){
+ self[m] = _.bind(self[m], self)
+ })
+ }
+
+ var p = Transition.prototype
+
+ /**
+ * Start an entering transition.
+ *
+ * 1. enter transition triggered
+ * 2. call beforeEnter hook
+ * 3. add enter class
+ * 4. insert/show element
+ * 5. call enter hook (with possible explicit js callback)
+ * 6. reflow
+ * 7. based on transition type:
+ * - transition:
+ * remove class now, wait for transitionend,
+ * then done if there's no explicit js callback.
+ * - animation:
+ * wait for animationend, remove class,
+ * then done if there's no explicit js callback.
+ * - no css transition:
+ * done now if there's no explicit js callback.
+ * 8. wait for either done or js callback, then call
+ * afterEnter hook.
+ *
+ * @param {Function} op - insert/show the element
+ * @param {Function} [cb]
+ */
+
+ p.enter = function (op, cb){
+ this.cancelPending()
+ this.callHook('beforeEnter')
+ this.cb = cb
+ addClass(this.el, this.enterClass)
+ op()
+ this.entered = false
+ this.callHookWithCb('enter')
+ if (this.entered) {
+ return // user called done synchronously.
+ }
+ this.cancel = this.hooks && this.hooks.enterCancelled
+ queue.push(this.enterNextTick)
+ }
+
+ /**
+ * The "nextTick" phase of an entering transition, which is
+ * to be pushed into a queue and executed after a reflow so
+ * that removing the class can trigger a CSS transition.
+ */
+
+ p.enterNextTick = function (){
+
+ // Important hack:
+ // in Chrome, if a just-entered element is applied the
+ // leave class while its interpolated property still has
+ // a very small value (within one frame), Chrome will
+ // skip the leave transition entirely and not firing the
+ // transtionend event. Therefore we need to protected
+ // against such cases using a one-frame timeout.
+ this.justEntered = true
+ var self = this
+ setTimeout(function (){
+ self.justEntered = false
+ }, 17)
+
+ var enterDone = this.enterDone
+ var type = this.getCssTransitionType(this.enterClass)
+ if (!this.pendingJsCb) {
+ if (type === TYPE_TRANSITION) {
+ // trigger transition by removing enter class now
+ removeClass(this.el, this.enterClass)
+ this.setupCssCb(transitionEndEvent, enterDone)
+ } else if (type === TYPE_ANIMATION) {
+ this.setupCssCb(animationEndEvent, enterDone)
+ } else {
+ enterDone()
+ }
+ } else if (type === TYPE_TRANSITION) {
+ removeClass(this.el, this.enterClass)
+ }
+ }
+
+ /**
+ * The "cleanup" phase of an entering transition.
+ */
+
+ p.enterDone = function (){
+ this.entered = true
+ this.cancel = this.pendingJsCb = null
+ removeClass(this.el, this.enterClass)
+ this.callHook('afterEnter')
+ if (this.cb) this.cb()
+ }
+
+ /**
+ * Start a leaving transition.
+ *
+ * 1. leave transition triggered.
+ * 2. call beforeLeave hook
+ * 3. add leave class (trigger css transition)
+ * 4. call leave hook (with possible explicit js callback)
+ * 5. reflow if no explicit js callback is provided
+ * 6. based on transition type:
+ * - transition or animation:
+ * wait for end event, remove class, then done if
+ * there's no explicit js callback.
+ * - no css transition:
+ * done if there's no explicit js callback.
+ * 7. wait for either done or js callback, then call
+ * afterLeave hook.
+ *
+ * @param {Function} op - remove/hide the element
+ * @param {Function} [cb]
+ */
+
+ p.leave = function (op, cb){
+ this.cancelPending()
+ this.callHook('beforeLeave')
+ this.op = op
+ this.cb = cb
+ addClass(this.el, this.leaveClass)
+ this.left = false
+ this.callHookWithCb('leave')
+ if (this.left) {
+ return // user called done synchronously.
+ }
+ this.cancel = this.hooks && this.hooks.leaveCancelled
+ // only need to handle leaveDone if
+ // 1. the transition is already done (synchronously called
+ // by the user, which causes this.op set to null)
+ // 2. there's no explicit js callback
+ if (this.op && !this.pendingJsCb) {
+ // if a CSS transition leaves immediately after enter,
+ // the transitionend event never fires. therefore we
+ // detect such cases and end the leave immediately.
+ if (this.justEntered) {
+ this.leaveDone()
+ } else {
+ queue.push(this.leaveNextTick)
+ }
+ }
+ }
+
+ /**
+ * The "nextTick" phase of a leaving transition.
+ */
+
+ p.leaveNextTick = function (){
+ var type = this.getCssTransitionType(this.leaveClass)
+ if (type) {
+ var event = type === TYPE_TRANSITION
+ ? transitionEndEvent
+ : animationEndEvent
+ this.setupCssCb(event, this.leaveDone)
+ } else {
+ this.leaveDone()
+ }
+ }
+
+ /**
+ * The "cleanup" phase of a leaving transition.
+ */
+
+ p.leaveDone = function (){
+ this.left = true
+ this.cancel = this.pendingJsCb = null
+ this.op()
+ removeClass(this.el, this.leaveClass)
+ this.callHook('afterLeave')
+ if (this.cb) this.cb()
+ this.op = null
+ }
+
+ /**
+ * Cancel any pending callbacks from a previously running
+ * but not finished transition.
+ */
+
+ p.cancelPending = function (){
+ this.op = this.cb = null
+ var hasPending = false
+ if (this.pendingCssCb) {
+ hasPending = true
+ _.off(this.el, this.pendingCssEvent, this.pendingCssCb)
+ this.pendingCssEvent = this.pendingCssCb = null
+ }
+ if (this.pendingJsCb) {
+ hasPending = true
+ this.pendingJsCb.cancel()
+ this.pendingJsCb = null
+ }
+ if (hasPending) {
+ removeClass(this.el, this.enterClass)
+ removeClass(this.el, this.leaveClass)
+ }
+ if (this.cancel) {
+ this.cancel.call(this.vm, this.el)
+ this.cancel = null
+ }
+ }
+
+ /**
+ * Call a user-provided synchronous hook function.
+ *
+ * @param {String} type
+ */
+
+ p.callHook = function (type){
+ if (this.hooks && this.hooks[type]) {
+ this.hooks[type].call(this.vm, this.el)
+ }
+ }
+
+ /**
+ * Call a user-provided, potentially-async hook function.
+ * We check for the length of arguments to see if the hook
+ * expects a `done` callback. If true, the transition's end
+ * will be determined by when the user calls that callback;
+ * otherwise, the end is determined by the CSS transition or
+ * animation.
+ *
+ * @param {String} type
+ */
+
+ p.callHookWithCb = function (type){
+ var hook = this.hooks && this.hooks[type]
+ if (hook) {
+ if (hook.length > 1) {
+ this.pendingJsCb = _.cancellable(this[type + 'Done'])
+ }
+ hook.call(this.vm, this.el, this.pendingJsCb)
+ }
+ }
+
+ /**
+ * Get an element's transition type based on the
+ * calculated styles.
+ *
+ * @param {String} className
+ * @return {Number}
+ */
+
+ p.getCssTransitionType = function (className){
+ /* istanbul ignore if */
+ if (
+ !transitionEndEvent ||
+ // skip CSS transitions if page is not visible -
+ // this solves the issue of transitionend events not
+ // firing until the page is visible again.
+ // pageVisibility API is supported in IE10+, same as
+ // CSS transitions.
+ document.hidden ||
+ // explicit js-only transition
+ (this.hooks && this.hooks.css === false) ||
+ // element is hidden
+ isHidden(this.el)
+ ) {
+ return
+ }
+ var type = this.typeCache[className]
+ if (type) return type
+ var inlineStyles = this.el.style
+ var computedStyles = window.getComputedStyle(this.el)
+ var transDuration =
+ inlineStyles[transDurationProp] ||
+ computedStyles[transDurationProp]
+ if (transDuration && transDuration !== '0s') {
+ type = TYPE_TRANSITION
+ } else {
+ var animDuration =
+ inlineStyles[animDurationProp] ||
+ computedStyles[animDurationProp]
+ if (animDuration && animDuration !== '0s') {
+ type = TYPE_ANIMATION
+ }
+ }
+ if (type) {
+ this.typeCache[className] = type
+ }
+ return type
+ }
+
+ /**
+ * Setup a CSS transitionend/animationend callback.
+ *
+ * @param {String} event
+ * @param {Function} cb
+ */
+
+ p.setupCssCb = function (event, cb){
+ this.pendingCssEvent = event
+ var self = this
+ var el = this.el
+ var onEnd = this.pendingCssCb = function (e){
+ if (e.target === el) {
+ _.off(el, event, onEnd)
+ self.pendingCssEvent = self.pendingCssCb = null
+ if (!self.pendingJsCb && cb) {
+ cb()
+ }
+ }
+ }
+ _.on(el, event, onEnd)
+ }
+
+ /**
+ * Check if an element is hidden - in that case we can just
+ * skip the transition alltogether.
+ *
+ * @param {Element} el
+ * @return {Boolean}
+ */
+
+ function isHidden(el){
+ return !(
+ el.offsetWidth ||
+ el.offsetHeight ||
+ el.getClientRects().length
+ )
+ }
+
+ module.exports = Transition
+
+ /***/
+ },
+ /* 47 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var queue = []
+ var queued = false
+
+ /**
+ * Push a job into the queue.
+ *
+ * @param {Function} job
+ */
+
+ exports.push = function (job){
+ queue.push(job)
+ if (!queued) {
+ queued = true
+ _.nextTick(flush)
+ }
+ }
+
+ /**
+ * Flush the queue, and do one forced reflow before
+ * triggering transitions.
+ */
+
+ function flush(){
+ // Force layout
+ var f = document.documentElement.offsetHeight
+ for (var i = 0; i < queue.length; i++) {
+ queue[i]()
+ }
+ queue = []
+ queued = false
+ // dummy return, so js linters don't complain about
+ // unused variable f
+ return f
+ }
+
+ /***/
+ },
+ /* 48 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var dirParser = __webpack_require__(8)
+ var propDef = __webpack_require__(39)
+ var propBindingModes = __webpack_require__(5)._propBindingModes
+ var empty = {}
+
+ // regexes
+ var identRE = __webpack_require__(43).identRE
+ var settablePathRE = /^[A-Za-z_$][\w$]*(\.[A-Za-z_$][\w$]*|\[[^\[\]]+\])*$/
+
+ /**
+ * Compile props on a root element and return
+ * a props link function.
+ *
+ * @param {Element|DocumentFragment} el
+ * @param {Array} propOptions
+ * @return {Function} propsLinkFn
+ */
+
+ module.exports = function compileProps(el, propOptions){
+ var props = []
+ var names = Object.keys(propOptions)
+ var i = names.length
+ var options, name, attr, value, path, parsed, prop
+ while (i--) {
+ name = names[i]
+ options = propOptions[name] || empty
+
+ if (("development") !== 'production' && name === '$data') {
+ _.warn('Do not use $data as prop.')
+ continue
+ }
+
+ // props could contain dashes, which will be
+ // interpreted as minus calculations by the parser
+ // so we need to camelize the path here
+ path = _.camelize(name)
+ if (!identRE.test(path)) {
+ ("development") !== 'production' && _.warn(
+ 'Invalid prop key: "' + name + '". Prop keys ' +
+ 'must be valid identifiers.'
+ )
+ continue
+ }
+
+ prop = {
+ name: name,
+ path: path,
+ options: options,
+ mode: propBindingModes.ONE_WAY,
+ raw: null
+ }
+
+ attr = _.hyphenate(name)
+ // first check dynamic version
+ if ((value = _.getBindAttr(el, attr)) === null) {
+ if ((value = _.getBindAttr(el, attr + '.sync')) !== null) {
+ prop.mode = propBindingModes.TWO_WAY
+ } else if ((value = _.getBindAttr(el, attr + '.once')) !== null) {
+ prop.mode = propBindingModes.ONE_TIME
+ }
+ }
+ if (value !== null) {
+ // has dynamic binding!
+ prop.raw = value
+ parsed = dirParser.parse(value)
+ value = parsed.expression
+ prop.filters = parsed.filters
+ // check binding type
+ if (_.isLiteral(value)) {
+ // for expressions containing literal numbers and
+ // booleans, there's no need to setup a prop binding,
+ // so we can optimize them as a one-time set.
+ prop.optimizedLiteral = true
+ } else {
+ prop.dynamic = true
+ // check non-settable path for two-way bindings
+ if (("development") !== 'production' &&
+ prop.mode === propBindingModes.TWO_WAY && !settablePathRE.test(value)) {
+ prop.mode = propBindingModes.ONE_WAY
+ _.warn(
+ 'Cannot bind two-way prop with non-settable ' +
+ 'parent path: ' + value
+ )
+ }
+ }
+ prop.parentPath = value
+
+ // warn required two-way
+ if (
+ ("development") !== 'production' &&
+ options.twoWay &&
+ prop.mode !== propBindingModes.TWO_WAY
+ ) {
+ _.warn(
+ 'Prop "' + name + '" expects a two-way binding type.'
+ )
+ }
+ } else if ((value = _.attr(el, attr)) !== null) {
+ // has literal binding!
+ prop.raw = value
+ } else if (options.required) {
+ // warn missing required
+ ("development") !== 'production' && _.warn(
+ 'Missing required prop: ' + name
+ )
+ }
+ // push prop
+ props.push(prop)
+ }
+ return makePropsLinkFn(props)
+ }
+
+ /**
+ * Build a function that applies props to a vm.
+ *
+ * @param {Array} props
+ * @return {Function} propsLinkFn
+ */
+
+ function makePropsLinkFn(props){
+ return function propsLinkFn(vm, scope){
+ // store resolved props info
+ vm._props = {}
+ var i = props.length
+ var prop, path, options, value, raw
+ while (i--) {
+ prop = props[i]
+ raw = prop.raw
+ path = prop.path
+ options = prop.options
+ vm._props[path] = prop
+ if (raw === null) {
+ // initialize absent prop
+ _.initProp(vm, prop, getDefault(vm, options))
+ } else if (prop.dynamic) {
+ // dynamic prop
+ if (vm._context) {
+ if (prop.mode === propBindingModes.ONE_TIME) {
+ // one time binding
+ value = (scope || vm._context).$get(prop.parentPath)
+ _.initProp(vm, prop, value)
+ } else {
+ // dynamic binding
+ vm._bindDir({
+ name: 'prop',
+ def: propDef,
+ prop: prop
+ }, null, null, scope) // el, host, scope
+ }
+ } else {
+ ("development") !== 'production' && _.warn(
+ 'Cannot bind dynamic prop on a root instance' +
+ ' with no parent: ' + prop.name + '="' +
+ raw + '"'
+ )
+ }
+ } else if (prop.optimizedLiteral) {
+ // optimized literal, cast it and just set once
+ var stripped = _.stripQuotes(raw)
+ value = stripped === raw
+ ? _.toBoolean(_.toNumber(raw))
+ : stripped
+ _.initProp(vm, prop, value)
+ } else {
+ // string literal, but we need to cater for
+ // Boolean props with no value
+ value = options.type === Boolean && raw === ''
+ ? true
+ : raw
+ _.initProp(vm, prop, value)
+ }
+ }
+ }
+ }
+
+ /**
+ * Get the default value of a prop.
+ *
+ * @param {Vue} vm
+ * @param {Object} options
+ * @return {*}
+ */
+
+ function getDefault(vm, options){
+ // no default, return undefined
+ if (!options.hasOwnProperty('default')) {
+ // absent boolean value defaults to false
+ return options.type === Boolean
+ ? false
+ : undefined
+ }
+ var def = options.default
+ // warn against non-factory defaults for Object & Array
+ if (_.isObject(def)) {
+ ("development") !== 'production' && _.warn(
+ 'Object/Array as default prop values will be shared ' +
+ 'across multiple instances. Use a factory function ' +
+ 'to return the default value instead.'
+ )
+ }
+ // call factory function for non-Function types
+ return typeof def === 'function' && options.type !== Function
+ ? def.call(vm)
+ : def
+ }
+
+ /***/
+ },
+ /* 49 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var templateParser = __webpack_require__(19)
+ var specialCharRE = /[^\w\-:\.]/
+
+ /**
+ * Process an element or a DocumentFragment based on a
+ * instance option object. This allows us to transclude
+ * a template node/fragment before the instance is created,
+ * so the processed fragment can then be cloned and reused
+ * in v-for.
+ *
+ * @param {Element} el
+ * @param {Object} options
+ * @return {Element|DocumentFragment}
+ */
+
+ exports.transclude = function (el, options){
+ // extract container attributes to pass them down
+ // to compiler, because they need to be compiled in
+ // parent scope. we are mutating the options object here
+ // assuming the same object will be used for compile
+ // right after this.
+ if (options) {
+ options._containerAttrs = extractAttrs(el)
+ }
+ // for template tags, what we want is its content as
+ // a documentFragment (for fragment instances)
+ if (_.isTemplate(el)) {
+ el = templateParser.parse(el)
+ }
+ if (options) {
+ if (options._asComponent && !options.template) {
+ options.template = ''
+ }
+ if (options.template) {
+ options._content = _.extractContent(el)
+ el = transcludeTemplate(el, options)
+ }
+ }
+ if (el instanceof DocumentFragment) {
+ // anchors for fragment instance
+ // passing in `persist: true` to avoid them being
+ // discarded by IE during template cloning
+ _.prepend(_.createAnchor('v-start', true), el)
+ el.appendChild(_.createAnchor('v-end', true))
+ }
+ return el
+ }
+
+ /**
+ * Process the template option.
+ * If the replace option is true this will swap the $el.
+ *
+ * @param {Element} el
+ * @param {Object} options
+ * @return {Element|DocumentFragment}
+ */
+
+ function transcludeTemplate(el, options){
+ var template = options.template
+ var frag = templateParser.parse(template, true)
+ if (frag) {
+ var replacer = frag.firstChild
+ var tag = replacer.tagName && replacer.tagName.toLowerCase()
+ if (options.replace) {
+ /* istanbul ignore if */
+ if (el === document.body) {
+ ("development") !== 'production' && _.warn(
+ 'You are mounting an instance with a template to ' +
+ '. This will replace entirely. You ' +
+ 'should probably use `replace: false` here.'
+ )
+ }
+ // there are many cases where the instance must
+ // become a fragment instance: basically anything that
+ // can create more than 1 root nodes.
+ if (
+ // multi-children template
+ frag.childNodes.length > 1 ||
+ // non-element template
+ replacer.nodeType !== 1 ||
+ // single nested component
+ tag === 'component' ||
+ _.resolveAsset(options, 'components', tag) ||
+ replacer.hasAttribute('is') ||
+ replacer.hasAttribute(':is') ||
+ replacer.hasAttribute('v-bind:is') ||
+ // element directive
+ _.resolveAsset(options, 'elementDirectives', tag) ||
+ // for block
+ replacer.hasAttribute('v-for') ||
+ // if block
+ replacer.hasAttribute('v-if')
+ ) {
+ return frag
+ } else {
+ options._replacerAttrs = extractAttrs(replacer)
+ mergeAttrs(el, replacer)
+ return replacer
+ }
+ } else {
+ el.appendChild(frag)
+ return el
+ }
+ } else {
+ ("development") !== 'production' && _.warn(
+ 'Invalid template option: ' + template
+ )
+ }
+ }
+
+ /**
+ * Helper to extract a component container's attributes
+ * into a plain object array.
+ *
+ * @param {Element} el
+ * @return {Array}
+ */
+
+ function extractAttrs(el){
+ if (el.nodeType === 1 && el.hasAttributes()) {
+ return _.toArray(el.attributes)
+ }
+ }
+
+ /**
+ * Merge the attributes of two elements, and make sure
+ * the class names are merged properly.
+ *
+ * @param {Element} from
+ * @param {Element} to
+ */
+
+ function mergeAttrs(from, to){
+ var attrs = from.attributes
+ var i = attrs.length
+ var name, value
+ while (i--) {
+ name = attrs[i].name
+ value = attrs[i].value
+ if (!to.hasAttribute(name) && !specialCharRE.test(name)) {
+ to.setAttribute(name, value)
+ } else if (name === 'class') {
+ value = to.getAttribute(name) + ' ' + value
+ to.setAttribute(name, value)
+ }
+ }
+ }
+
+ /***/
+ },
+ /* 50 */
+ /***/ function (module, exports, __webpack_require__){
+
+ exports.slot = __webpack_require__(51)
+ exports.partial = __webpack_require__(52)
+
+ /***/
+ },
+ /* 51 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var templateParser = __webpack_require__(19)
+
+ // This is the elementDirective that handles
+ // transclusions. It relies on the raw content of an
+ // instance being stored as `$options._content` during
+ // the transclude phase.
+
+ module.exports = {
+
+ priority: 1750,
+
+ params: ['name'],
+
+ bind: function (){
+ var host = this.vm
+ var raw = host.$options._content
+ var content
+ if (!raw) {
+ this.fallback()
+ return
+ }
+ var context = host._context
+ var slotName = this.params.name
+ if (!slotName) {
+ // Default content
+ var self = this
+ var compileDefaultContent = function (){
+ self.compile(
+ extractFragment(raw.childNodes, raw, true),
+ context,
+ host
+ )
+ }
+ if (!host._isCompiled) {
+ // defer until the end of instance compilation,
+ // because the default outlet must wait until all
+ // other possible outlets with selectors have picked
+ // out their contents.
+ host.$once('hook:compiled', compileDefaultContent)
+ } else {
+ compileDefaultContent()
+ }
+ } else {
+ var selector = '[slot="' + slotName + '"]'
+ var nodes = raw.querySelectorAll(selector)
+ if (nodes.length) {
+ content = extractFragment(nodes, raw)
+ if (content.hasChildNodes()) {
+ this.compile(content, context, host)
+ } else {
+ this.fallback()
+ }
+ } else {
+ this.fallback()
+ }
+ }
+ },
+
+ fallback: function (){
+ this.compile(_.extractContent(this.el, true), this.vm)
+ },
+
+ compile: function (content, context, host){
+ if (content && context) {
+ var scope = host
+ ? host._scope
+ : this._scope
+ this.unlink = context.$compile(
+ content, host, scope, this._frag
+ )
+ }
+ if (content) {
+ _.replace(this.el, content)
+ } else {
+ _.remove(this.el)
+ }
+ },
+
+ unbind: function (){
+ if (this.unlink) {
+ this.unlink()
+ }
+ }
+ }
+
+ /**
+ * Extract qualified content nodes from a node list.
+ *
+ * @param {NodeList} nodes
+ * @param {Element} parent
+ * @param {Boolean} main
+ * @return {DocumentFragment}
+ */
+
+ function extractFragment(nodes, parent, main){
+ var frag = document.createDocumentFragment()
+ for (var i = 0, l = nodes.length; i < l; i++) {
+ var node = nodes[i]
+ // if this is the main outlet, we want to skip all
+ // previously selected nodes;
+ // otherwise, we want to mark the node as selected.
+ // clone the node so the original raw content remains
+ // intact. this ensures proper re-compilation in cases
+ // where the outlet is inside a conditional block
+ if (main && !node.__v_selected) {
+ append(node)
+ } else if (!main && node.parentNode === parent) {
+ node.__v_selected = true
+ append(node)
+ }
+ }
+ return frag
+
+ function append(node){
+ if (_.isTemplate(node) && !node.hasAttribute('v-if') && !node.hasAttribute('v-for')) {
+ node = templateParser.parse(node)
+ }
+ node = templateParser.clone(node)
+ frag.appendChild(node)
+ }
+ }
+
+ /***/
+ },
+ /* 52 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var vIf = __webpack_require__(23)
+ var FragmentFactory = __webpack_require__(21)
+
+ module.exports = {
+
+ priority: 1750,
+
+ params: ['name'],
+
+ // watch changes to name for dynamic partials
+ paramWatchers: {
+ name: function (value){
+ vIf.remove.call(this)
+ if (value) {
+ this.insert(value)
+ }
+ }
+ },
+
+ bind: function (){
+ this.anchor = _.createAnchor('v-partial')
+ _.replace(this.el, this.anchor)
+ this.insert(this.params.name)
+ },
+
+ insert: function (id){
+ var partial = _.resolveAsset(this.vm.$options, 'partials', id)
+ if (true) {
+ _.assertAsset(partial, 'partial', id)
+ }
+ if (partial) {
+ this.factory = new FragmentFactory(this.vm, partial)
+ vIf.insert.call(this)
+ }
+ },
+
+ unbind: function (){
+ if (this.frag) {
+ this.frag.destroy()
+ }
+ }
+ }
+
+ /***/
+ },
+ /* 53 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+
+ /**
+ * Stringify value.
+ *
+ * @param {Number} indent
+ */
+
+ exports.json = {
+ read: function (value, indent){
+ return typeof value === 'string'
+ ? value
+ : JSON.stringify(value, null, Number(indent) || 2)
+ },
+ write: function (value){
+ try {
+ return JSON.parse(value)
+ } catch (e) {
+ return value
+ }
+ }
+ }
+
+ /**
+ * 'abc' => 'Abc'
+ */
+
+ exports.capitalize = function (value){
+ if (!value && value !== 0) return ''
+ value = value.toString()
+ return value.charAt(0).toUpperCase() + value.slice(1)
+ }
+
+ /**
+ * 'abc' => 'ABC'
+ */
+
+ exports.uppercase = function (value){
+ return (value || value === 0)
+ ? value.toString().toUpperCase()
+ : ''
+ }
+
+ /**
+ * 'AbC' => 'abc'
+ */
+
+ exports.lowercase = function (value){
+ return (value || value === 0)
+ ? value.toString().toLowerCase()
+ : ''
+ }
+
+ /**
+ * 12345 => $12,345.00
+ *
+ * @param {String} sign
+ */
+
+ var digitsRE = /(\d{3})(?=\d)/g
+ exports.currency = function (value, currency){
+ value = parseFloat(value)
+ if (!isFinite(value) || (!value && value !== 0)) return ''
+ currency = currency != null ? currency : '$'
+ var stringified = Math.abs(value).toFixed(2)
+ var _int = stringified.slice(0, -3)
+ var i = _int.length % 3
+ var head = i > 0
+ ? (_int.slice(0, i) + (_int.length > 3 ? ',' : ''))
+ : ''
+ var _float = stringified.slice(-3)
+ var sign = value < 0 ? '-' : ''
+ return currency + sign + head +
+ _int.slice(i).replace(digitsRE, '$1,') +
+ _float
+ }
+
+ /**
+ * 'item' => 'items'
+ *
+ * @params
+ * an array of strings corresponding to
+ * the single, double, triple ... forms of the word to
+ * be pluralized. When the number to be pluralized
+ * exceeds the length of the args, it will use the last
+ * entry in the array.
+ *
+ * e.g. ['single', 'double', 'triple', 'multiple']
+ */
+
+ exports.pluralize = function (value){
+ var args = _.toArray(arguments, 1)
+ return args.length > 1
+ ? (args[value % 10 - 1] || args[args.length - 1])
+ : (args[0] + (value === 1 ? '' : 's'))
+ }
+
+ /**
+ * Debounce a handler function.
+ *
+ * @param {Function} handler
+ * @param {Number} delay = 300
+ * @return {Function}
+ */
+
+ exports.debounce = function (handler, delay){
+ if (!handler) return
+ if (!delay) {
+ delay = 300
+ }
+ return _.debounce(handler, delay)
+ }
+
+ /**
+ * Install special array filters
+ */
+
+ _.extend(exports, __webpack_require__(54))
+
+ /***/
+ },
+ /* 54 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var Path = __webpack_require__(43)
+ var toArray = __webpack_require__(20)._postProcess
+
+ /**
+ * Limit filter for arrays
+ *
+ * @param {Number} n
+ * @param {Number} offset (Decimal expected)
+ */
+
+ exports.limitBy = function (arr, n, offset){
+ offset = offset ? parseInt(offset, 10) : 0
+ return typeof n === 'number'
+ ? arr.slice(offset, offset + n)
+ : arr
+ }
+
+ /**
+ * Filter filter for arrays
+ *
+ * @param {String} search
+ * @param {String} [delimiter]
+ * @param {String} ...dataKeys
+ */
+
+ exports.filterBy = function (arr, search, delimiter){
+ arr = toArray(arr)
+ if (search == null) {
+ return arr
+ }
+ if (typeof search === 'function') {
+ return arr.filter(search)
+ }
+ // cast to lowercase string
+ search = ('' + search).toLowerCase()
+ // allow optional `in` delimiter
+ // because why not
+ var n = delimiter === 'in' ? 3 : 2
+ // extract and flatten keys
+ var keys = _.toArray(arguments, n).reduce(function (prev, cur){
+ return prev.concat(cur)
+ }, [])
+ var res = []
+ var item, key, val, j
+ for (var i = 0, l = arr.length; i < l; i++) {
+ item = arr[i]
+ val = (item && item.$value) || item
+ j = keys.length
+ if (j) {
+ while (j--) {
+ key = keys[j]
+ if ((key === '$key' && contains(item.$key, search)) ||
+ contains(Path.get(val, key), search)) {
+ res.push(item)
+ break
+ }
+ }
+ } else if (contains(item, search)) {
+ res.push(item)
+ }
+ }
+ return res
+ }
+
+ /**
+ * Filter filter for arrays
+ *
+ * @param {String} sortKey
+ * @param {String} reverse
+ */
+
+ exports.orderBy = function (arr, sortKey, reverse){
+ arr = toArray(arr)
+ if (!sortKey) {
+ return arr
+ }
+ var order = (reverse && reverse < 0) ? -1 : 1
+ // sort on a copy to avoid mutating original array
+ return arr.slice().sort(function (a, b){
+ if (sortKey !== '$key') {
+ if (_.isObject(a) && '$value' in a) a = a.$value
+ if (_.isObject(b) && '$value' in b) b = b.$value
+ }
+ a = _.isObject(a) ? Path.get(a, sortKey) : a
+ b = _.isObject(b) ? Path.get(b, sortKey) : b
+ return a === b ? 0 : a > b ? order : -order
+ })
+ }
+
+ /**
+ * String contain helper
+ *
+ * @param {*} val
+ * @param {String} search
+ */
+
+ function contains(val, search){
+ var i
+ if (_.isPlainObject(val)) {
+ var keys = Object.keys(val)
+ i = keys.length
+ while (i--) {
+ if (contains(val[keys[i]], search)) {
+ return true
+ }
+ }
+ } else if (_.isArray(val)) {
+ i = val.length
+ while (i--) {
+ if (contains(val[i], search)) {
+ return true
+ }
+ }
+ } else if (val != null) {
+ return val.toString().toLowerCase().indexOf(search) > -1
+ }
+ }
+
+ /***/
+ },
+ /* 55 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var mergeOptions = __webpack_require__(1).mergeOptions
+ var uid = 0
+
+ /**
+ * The main init sequence. This is called for every
+ * instance, including ones that are created from extended
+ * constructors.
+ *
+ * @param {Object} options - this options object should be
+ * the result of merging class
+ * options and the options passed
+ * in to the constructor.
+ */
+
+ exports._init = function (options){
+
+ options = options || {}
+
+ this.$el = null
+ this.$parent = options.parent
+ this.$root = this.$parent
+ ? this.$parent.$root
+ : this
+ this.$children = []
+ this.$refs = {} // child vm references
+ this.$els = {} // element references
+ this._watchers = [] // all watchers as an array
+ this._directives = [] // all directives
+
+ // a uid
+ this._uid = uid++
+
+ // a flag to avoid this being observed
+ this._isVue = true
+
+ // events bookkeeping
+ this._events = {} // registered callbacks
+ this._eventsCount = {} // for $broadcast optimization
+ this._shouldPropagate = false // for event propagation
+
+ // fragment instance properties
+ this._isFragment = false
+ this._fragment = // @type {DocumentFragment}
+ this._fragmentStart = // @type {Text|Comment}
+ this._fragmentEnd = null // @type {Text|Comment}
+
+ // lifecycle state
+ this._isCompiled =
+ this._isDestroyed =
+ this._isReady =
+ this._isAttached =
+ this._isBeingDestroyed = false
+ this._unlinkFn = null
+
+ // context:
+ // if this is a transcluded component, context
+ // will be the common parent vm of this instance
+ // and its host.
+ this._context = options._context || this.$parent
+
+ // scope:
+ // if this is inside an inline v-for, the scope
+ // will be the intermediate scope created for this
+ // repeat fragment. this is used for linking props
+ // and container directives.
+ this._scope = options._scope
+
+ // fragment:
+ // if this instance is compiled inside a Fragment, it
+ // needs to reigster itself as a child of that fragment
+ // for attach/detach to work properly.
+ this._frag = options._frag
+ if (this._frag) {
+ this._frag.children.push(this)
+ }
+
+ // push self into parent / transclusion host
+ if (this.$parent) {
+ this.$parent.$children.push(this)
+ }
+
+ // merge options.
+ options = this.$options = mergeOptions(
+ this.constructor.options,
+ options,
+ this
+ )
+
+ // set ref
+ this._updateRef()
+
+ // initialize data as empty object.
+ // it will be filled up in _initScope().
+ this._data = {}
+
+ // call init hook
+ this._callHook('init')
+
+ // initialize data observation and scope inheritance.
+ this._initState()
+
+ // setup event system and option events.
+ this._initEvents()
+
+ // call created hook
+ this._callHook('created')
+
+ // if `el` option is passed, start compilation.
+ if (options.el) {
+ this.$mount(options.el)
+ }
+ }
+
+ /***/
+ },
+ /* 56 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var inDoc = _.inDoc
+ var eventRE = /^v-on:|^@/
+
+ /**
+ * Setup the instance's option events & watchers.
+ * If the value is a string, we pull it from the
+ * instance's methods by name.
+ */
+
+ exports._initEvents = function (){
+ var options = this.$options
+ if (options._asComponent) {
+ registerComponentEvents(this, options.el)
+ }
+ registerCallbacks(this, '$on', options.events)
+ registerCallbacks(this, '$watch', options.watch)
+ }
+
+ /**
+ * Register v-on events on a child component
+ *
+ * @param {Vue} vm
+ * @param {Element} el
+ */
+
+ function registerComponentEvents(vm, el){
+ var attrs = el.attributes
+ var name, handler
+ for (var i = 0, l = attrs.length; i < l; i++) {
+ name = attrs[i].name
+ if (eventRE.test(name)) {
+ name = name.replace(eventRE, '')
+ handler = (vm._scope || vm._context).$eval(attrs[i].value, true)
+ vm.$on(name.replace(eventRE), handler)
+ }
+ }
+ }
+
+ /**
+ * Register callbacks for option events and watchers.
+ *
+ * @param {Vue} vm
+ * @param {String} action
+ * @param {Object} hash
+ */
+
+ function registerCallbacks(vm, action, hash){
+ if (!hash) return
+ var handlers, key, i, j
+ for (key in hash) {
+ handlers = hash[key]
+ if (_.isArray(handlers)) {
+ for (i = 0, j = handlers.length; i < j; i++) {
+ register(vm, action, key, handlers[i])
+ }
+ } else {
+ register(vm, action, key, handlers)
+ }
+ }
+ }
+
+ /**
+ * Helper to register an event/watch callback.
+ *
+ * @param {Vue} vm
+ * @param {String} action
+ * @param {String} key
+ * @param {Function|String|Object} handler
+ * @param {Object} [options]
+ */
+
+ function register(vm, action, key, handler, options){
+ var type = typeof handler
+ if (type === 'function') {
+ vm[action](key, handler, options)
+ } else if (type === 'string') {
+ var methods = vm.$options.methods
+ var method = methods && methods[handler]
+ if (method) {
+ vm[action](key, method, options)
+ } else {
+ ("development") !== 'production' && _.warn(
+ 'Unknown method: "' + handler + '" when ' +
+ 'registering callback for ' + action +
+ ': "' + key + '".'
+ )
+ }
+ } else if (handler && type === 'object') {
+ register(vm, action, key, handler.handler, handler)
+ }
+ }
+
+ /**
+ * Setup recursive attached/detached calls
+ */
+
+ exports._initDOMHooks = function (){
+ this.$on('hook:attached', onAttached)
+ this.$on('hook:detached', onDetached)
+ }
+
+ /**
+ * Callback to recursively call attached hook on children
+ */
+
+ function onAttached(){
+ if (!this._isAttached) {
+ this._isAttached = true
+ this.$children.forEach(callAttach)
+ }
+ }
+
+ /**
+ * Iterator to call attached hook
+ *
+ * @param {Vue} child
+ */
+
+ function callAttach(child){
+ if (!child._isAttached && inDoc(child.$el)) {
+ child._callHook('attached')
+ }
+ }
+
+ /**
+ * Callback to recursively call detached hook on children
+ */
+
+ function onDetached(){
+ if (this._isAttached) {
+ this._isAttached = false
+ this.$children.forEach(callDetach)
+ }
+ }
+
+ /**
+ * Iterator to call detached hook
+ *
+ * @param {Vue} child
+ */
+
+ function callDetach(child){
+ if (child._isAttached && !inDoc(child.$el)) {
+ child._callHook('detached')
+ }
+ }
+
+ /**
+ * Trigger all handlers for a hook
+ *
+ * @param {String} hook
+ */
+
+ exports._callHook = function (hook){
+ var handlers = this.$options[hook]
+ if (handlers) {
+ for (var i = 0, j = handlers.length; i < j; i++) {
+ handlers[i].call(this)
+ }
+ }
+ this.$emit('hook:' + hook)
+ }
+
+ /***/
+ },
+ /* 57 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var compiler = __webpack_require__(14)
+ var Observer = __webpack_require__(58)
+ var Dep = __webpack_require__(41)
+ var Watcher = __webpack_require__(40)
+
+ /**
+ * Setup the scope of an instance, which contains:
+ * - observed data
+ * - computed properties
+ * - user methods
+ * - meta properties
+ */
+
+ exports._initState = function (){
+ this._initProps()
+ this._initMeta()
+ this._initMethods()
+ this._initData()
+ this._initComputed()
+ }
+
+ /**
+ * Initialize props.
+ */
+
+ exports._initProps = function (){
+ var options = this.$options
+ var el = options.el
+ var props = options.props
+ if (props && !el) {
+ ("development") !== 'production' && _.warn(
+ 'Props will not be compiled if no `el` option is ' +
+ 'provided at instantiation.'
+ )
+ }
+ // make sure to convert string selectors into element now
+ el = options.el = _.query(el)
+ this._propsUnlinkFn = el && el.nodeType === 1 && props
+ // props must be linked in proper scope if inside v-for
+ ? compiler.compileAndLinkProps(this, el, props, this._scope)
+ : null
+ }
+
+ /**
+ * Initialize the data.
+ */
+
+ exports._initData = function (){
+ var propsData = this._data
+ var optionsDataFn = this.$options.data
+ var optionsData = optionsDataFn && optionsDataFn()
+ if (optionsData) {
+ this._data = optionsData
+ for (var prop in propsData) {
+ if (("development") !== 'production' &&
+ optionsData.hasOwnProperty(prop)) {
+ _.warn(
+ 'Data field "' + prop + '" is already defined ' +
+ 'as a prop. Use prop default value instead.'
+ )
+ }
+ if (this._props[prop].raw !== null || !optionsData.hasOwnProperty(prop)) {
+ _.set(optionsData, prop, propsData[prop])
+ }
+ }
+ }
+ var data = this._data
+ // proxy data on instance
+ var keys = Object.keys(data)
+ var i, key
+ i = keys.length
+ while (i--) {
+ key = keys[i]
+ this._proxy(key)
+ }
+ // observe data
+ Observer.create(data, this)
+ }
+
+ /**
+ * Swap the instance's $data. Called in $data's setter.
+ *
+ * @param {Object} newData
+ */
+
+ exports._setData = function (newData){
+ newData = newData || {}
+ var oldData = this._data
+ this._data = newData
+ var keys, key, i
+ // unproxy keys not present in new data
+ keys = Object.keys(oldData)
+ i = keys.length
+ while (i--) {
+ key = keys[i]
+ if (!(key in newData)) {
+ this._unproxy(key)
+ }
+ }
+ // proxy keys not already proxied,
+ // and trigger change for changed values
+ keys = Object.keys(newData)
+ i = keys.length
+ while (i--) {
+ key = keys[i]
+ if (!this.hasOwnProperty(key)) {
+ // new property
+ this._proxy(key)
+ }
+ }
+ oldData.__ob__.removeVm(this)
+ Observer.create(newData, this)
+ this._digest()
+ }
+
+ /**
+ * Proxy a property, so that
+ * vm.prop === vm._data.prop
+ *
+ * @param {String} key
+ */
+
+ exports._proxy = function (key){
+ if (!_.isReserved(key)) {
+ // need to store ref to self here
+ // because these getter/setters might
+ // be called by child scopes via
+ // prototype inheritance.
+ var self = this
+ Object.defineProperty(self, key, {
+ configurable: true,
+ enumerable: true,
+ get: function proxyGetter(){
+ return self._data[key]
+ },
+ set: function proxySetter(val){
+ self._data[key] = val
+ }
+ })
+ }
+ }
+
+ /**
+ * Unproxy a property.
+ *
+ * @param {String} key
+ */
+
+ exports._unproxy = function (key){
+ if (!_.isReserved(key)) {
+ delete this[key]
+ }
+ }
+
+ /**
+ * Force update on every watcher in scope.
+ */
+
+ exports._digest = function (){
+ for (var i = 0, l = this._watchers.length; i < l; i++) {
+ this._watchers[i].update(true) // shallow updates
+ }
+ }
+
+ /**
+ * Setup computed properties. They are essentially
+ * special getter/setters
+ */
+
+ function noop(){}
+
+ exports._initComputed = function (){
+ var computed = this.$options.computed
+ if (computed) {
+ for (var key in computed) {
+ var userDef = computed[key]
+ var def = {
+ enumerable: true,
+ configurable: true
+ }
+ if (typeof userDef === 'function') {
+ def.get = makeComputedGetter(userDef, this)
+ def.set = noop
+ } else {
+ def.get = userDef.get
+ ? userDef.cache !== false
+ ? makeComputedGetter(userDef.get, this)
+ : _.bind(userDef.get, this)
+ : noop
+ def.set = userDef.set
+ ? _.bind(userDef.set, this)
+ : noop
+ }
+ Object.defineProperty(this, key, def)
+ }
+ }
+ }
+
+ function makeComputedGetter(getter, owner){
+ var watcher = new Watcher(owner, getter, null, {
+ lazy: true
+ })
+ return function computedGetter(){
+ if (watcher.dirty) {
+ watcher.evaluate()
+ }
+ if (Dep.target) {
+ watcher.depend()
+ }
+ return watcher.value
+ }
+ }
+
+ /**
+ * Setup instance methods. Methods must be bound to the
+ * instance since they might be passed down as a prop to
+ * child components.
+ */
+
+ exports._initMethods = function (){
+ var methods = this.$options.methods
+ if (methods) {
+ for (var key in methods) {
+ this[key] = _.bind(methods[key], this)
+ }
+ }
+ }
+
+ /**
+ * Initialize meta information like $index, $key & $value.
+ */
+
+ exports._initMeta = function (){
+ var metas = this.$options._meta
+ if (metas) {
+ for (var key in metas) {
+ _.defineReactive(this, key, metas[key])
+ }
+ }
+ }
+
+ /***/
+ },
+ /* 58 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var config = __webpack_require__(5)
+ var Dep = __webpack_require__(41)
+ var arrayMethods = __webpack_require__(59)
+ var arrayKeys = Object.getOwnPropertyNames(arrayMethods)
+
+ /**
+ * Observer class that are attached to each observed
+ * object. Once attached, the observer converts target
+ * object's property keys into getter/setters that
+ * collect dependencies and dispatches updates.
+ *
+ * @param {Array|Object} value
+ * @constructor
+ */
+
+ function Observer(value){
+ this.value = value
+ this.dep = new Dep()
+ _.define(value, '__ob__', this)
+ if (_.isArray(value)) {
+ var augment = _.hasProto
+ ? protoAugment
+ : copyAugment
+ augment(value, arrayMethods, arrayKeys)
+ this.observeArray(value)
+ } else {
+ this.walk(value)
+ }
+ }
+
+ // Static methods
+
+ /**
+ * Attempt to create an observer instance for a value,
+ * returns the new observer if successfully observed,
+ * or the existing observer if the value already has one.
+ *
+ * @param {*} value
+ * @param {Vue} [vm]
+ * @return {Observer|undefined}
+ * @static
+ */
+
+ Observer.create = function (value, vm){
+ if (!value || typeof value !== 'object') {
+ return
+ }
+ var ob
+ if (
+ Object.prototype.hasOwnProperty.call(value, '__ob__') &&
+ value.__ob__ instanceof Observer
+ ) {
+ ob = value.__ob__
+ } else if (
+ (_.isArray(value) || _.isPlainObject(value)) && !Object.isFrozen(value) && !value._isVue
+ ) {
+ ob = new Observer(value)
+ }
+ if (ob && vm) {
+ ob.addVm(vm)
+ }
+ return ob
+ }
+
+ // Instance methods
+
+ /**
+ * Walk through each property and convert them into
+ * getter/setters. This method should only be called when
+ * value type is Object.
+ *
+ * @param {Object} obj
+ */
+
+ Observer.prototype.walk = function (obj){
+ var keys = Object.keys(obj)
+ var i = keys.length
+ while (i--) {
+ this.convert(keys[i], obj[keys[i]])
+ }
+ }
+
+ /**
+ * Observe a list of Array items.
+ *
+ * @param {Array} items
+ */
+
+ Observer.prototype.observeArray = function (items){
+ var i = items.length
+ while (i--) {
+ Observer.create(items[i])
+ }
+ }
+
+ /**
+ * Convert a property into getter/setter so we can emit
+ * the events when the property is accessed/changed.
+ *
+ * @param {String} key
+ * @param {*} val
+ */
+
+ Observer.prototype.convert = function (key, val){
+ defineReactive(this.value, key, val)
+ }
+
+ /**
+ * Add an owner vm, so that when $set/$delete mutations
+ * happen we can notify owner vms to proxy the keys and
+ * digest the watchers. This is only called when the object
+ * is observed as an instance's root $data.
+ *
+ * @param {Vue} vm
+ */
+
+ Observer.prototype.addVm = function (vm){
+ (this.vms || (this.vms = [])).push(vm)
+ }
+
+ /**
+ * Remove an owner vm. This is called when the object is
+ * swapped out as an instance's $data object.
+ *
+ * @param {Vue} vm
+ */
+
+ Observer.prototype.removeVm = function (vm){
+ this.vms.$remove(vm)
+ }
+
+ // helpers
+
+ /**
+ * Augment an target Object or Array by intercepting
+ * the prototype chain using __proto__
+ *
+ * @param {Object|Array} target
+ * @param {Object} proto
+ */
+
+ function protoAugment(target, src){
+ target.__proto__ = src
+ }
+
+ /**
+ * Augment an target Object or Array by defining
+ * hidden properties.
+ *
+ * @param {Object|Array} target
+ * @param {Object} proto
+ */
+
+ function copyAugment(target, src, keys){
+ var i = keys.length
+ var key
+ while (i--) {
+ key = keys[i]
+ _.define(target, key, src[key])
+ }
+ }
+
+ /**
+ * Define a reactive property on an Object.
+ *
+ * @param {Object} obj
+ * @param {String} key
+ * @param {*} val
+ */
+
+ function defineReactive(obj, key, val){
+ var dep = new Dep()
+
+ // cater for pre-defined getter/setters
+ var getter, setter
+ if (config.convertAllProperties) {
+ var property = Object.getOwnPropertyDescriptor(obj, key)
+ if (property && property.configurable === false) {
+ return
+ }
+ getter = property && property.get
+ setter = property && property.set
+ }
+
+ var childOb = Observer.create(val)
+ Object.defineProperty(obj, key, {
+ enumerable: true,
+ configurable: true,
+ get: function reactiveGetter(){
+ var value = getter ? getter.call(obj) : val
+ if (Dep.target) {
+ dep.depend()
+ if (childOb) {
+ childOb.dep.depend()
+ }
+ if (_.isArray(value)) {
+ for (var e, i = 0, l = value.length; i < l; i++) {
+ e = value[i]
+ e && e.__ob__ && e.__ob__.dep.depend()
+ }
+ }
+ }
+ return value
+ },
+ set: function reactiveSetter(newVal){
+ var value = getter ? getter.call(obj) : val
+ if (newVal === value) {
+ return
+ }
+ if (setter) {
+ setter.call(obj, newVal)
+ } else {
+ val = newVal
+ }
+ childOb = Observer.create(newVal)
+ dep.notify()
+ }
+ })
+ }
+
+ // Attach to the util object so it can be used elsewhere.
+ _.defineReactive = defineReactive
+
+ module.exports = Observer
+
+ /***/
+ },
+ /* 59 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var arrayProto = Array.prototype
+ var arrayMethods = Object.create(arrayProto)
+
+ /**
+ * Intercept mutating methods and emit events
+ */
+
+ ;
+ [
+ 'push',
+ 'pop',
+ 'shift',
+ 'unshift',
+ 'splice',
+ 'sort',
+ 'reverse'
+ ]
+ .forEach(function (method){
+ // cache original method
+ var original = arrayProto[method]
+ _.define(arrayMethods, method, function mutator(){
+ // avoid leaking arguments:
+ // http://jsperf.com/closure-with-arguments
+ var i = arguments.length
+ var args = new Array(i)
+ while (i--) {
+ args[i] = arguments[i]
+ }
+ var result = original.apply(this, args)
+ var ob = this.__ob__
+ var inserted
+ switch (method) {
+ case 'push':
+ inserted = args
+ break
+ case 'unshift':
+ inserted = args
+ break
+ case 'splice':
+ inserted = args.slice(2)
+ break
+ }
+ if (inserted) ob.observeArray(inserted)
+ // notify change
+ ob.dep.notify()
+ return result
+ })
+ })
+
+ /**
+ * Swap the element at the given index with a new value
+ * and emits corresponding event.
+ *
+ * @param {Number} index
+ * @param {*} val
+ * @return {*} - replaced element
+ */
+
+ _.define(
+ arrayProto,
+ '$set',
+ function $set(index, val){
+ if (index >= this.length) {
+ this.length = index + 1
+ }
+ return this.splice(index, 1, val)[0]
+ }
+ )
+
+ /**
+ * Convenience method to remove the element at given index.
+ *
+ * @param {Number} index
+ * @param {*} val
+ */
+
+ _.define(
+ arrayProto,
+ '$remove',
+ function $remove(item){
+ /* istanbul ignore if */
+ if (!this.length) return
+ var index = _.indexOf(this, item)
+ if (index > -1) {
+ return this.splice(index, 1)
+ }
+ }
+ )
+
+ module.exports = arrayMethods
+
+ /***/
+ },
+ /* 60 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var Directive = __webpack_require__(61)
+ var compiler = __webpack_require__(14)
+
+ /**
+ * Update v-ref for component.
+ *
+ * @param {Boolean} remove
+ */
+
+ exports._updateRef = function (remove){
+ var ref = this.$options._ref
+ if (ref) {
+ var refs = (this._scope || this._context).$refs
+ if (remove) {
+ if (refs[ref] === this) {
+ refs[ref] = null
+ }
+ } else {
+ refs[ref] = this
+ }
+ }
+ }
+
+ /**
+ * Transclude, compile and link element.
+ *
+ * If a pre-compiled linker is available, that means the
+ * passed in element will be pre-transcluded and compiled
+ * as well - all we need to do is to call the linker.
+ *
+ * Otherwise we need to call transclude/compile/link here.
+ *
+ * @param {Element} el
+ * @return {Element}
+ */
+
+ exports._compile = function (el){
+ var options = this.$options
+
+ // transclude and init element
+ // transclude can potentially replace original
+ // so we need to keep reference; this step also injects
+ // the template and caches the original attributes
+ // on the container node and replacer node.
+ var original = el
+ el = compiler.transclude(el, options)
+ this._initElement(el)
+
+ // root is always compiled per-instance, because
+ // container attrs and props can be different every time.
+ var contextOptions = this._context && this._context.$options
+ var rootLinker = compiler.compileRoot(el, options, contextOptions)
+
+ // compile and link the rest
+ var contentLinkFn
+ var ctor = this.constructor
+ // component compilation can be cached
+ // as long as it's not using inline-template
+ if (options._linkerCachable) {
+ contentLinkFn = ctor.linker
+ if (!contentLinkFn) {
+ contentLinkFn = ctor.linker = compiler.compile(el, options)
+ }
+ }
+
+ // link phase
+ // make sure to link root with prop scope!
+ var rootUnlinkFn = rootLinker(this, el, this._scope)
+ var contentUnlinkFn = contentLinkFn
+ ? contentLinkFn(this, el)
+ : compiler.compile(el, options)(this, el)
+
+ // register composite unlink function
+ // to be called during instance destruction
+ this._unlinkFn = function (){
+ rootUnlinkFn()
+ // passing destroying: true to avoid searching and
+ // splicing the directives
+ contentUnlinkFn(true)
+ }
+
+ // finally replace original
+ if (options.replace) {
+ _.replace(original, el)
+ }
+
+ this._isCompiled = true
+ this._callHook('compiled')
+ return el
+ }
+
+ /**
+ * Initialize instance element. Called in the public
+ * $mount() method.
+ *
+ * @param {Element} el
+ */
+
+ exports._initElement = function (el){
+ if (el instanceof DocumentFragment) {
+ this._isFragment = true
+ this.$el = this._fragmentStart = el.firstChild
+ this._fragmentEnd = el.lastChild
+ // set persisted text anchors to empty
+ if (this._fragmentStart.nodeType === 3) {
+ this._fragmentStart.data = this._fragmentEnd.data = ''
+ }
+ this._fragment = el
+ } else {
+ this.$el = el
+ }
+ this.$el.__vue__ = this
+ this._callHook('beforeCompile')
+ }
+
+ /**
+ * Create and bind a directive to an element.
+ *
+ * @param {String} name - directive name
+ * @param {Node} node - target node
+ * @param {Object} desc - parsed directive descriptor
+ * @param {Object} def - directive definition object
+ * @param {Vue} [host] - transclusion host component
+ * @param {Object} [scope] - v-for scope
+ * @param {Fragment} [frag] - owner fragment
+ */
+
+ exports._bindDir = function (descriptor, node, host, scope, frag){
+ this._directives.push(
+ new Directive(descriptor, this, node, host, scope, frag)
+ )
+ }
+
+ /**
+ * Teardown an instance, unobserves the data, unbind all the
+ * directives, turn off all the event listeners, etc.
+ *
+ * @param {Boolean} remove - whether to remove the DOM node.
+ * @param {Boolean} deferCleanup - if true, defer cleanup to
+ * be called later
+ */
+
+ exports._destroy = function (remove, deferCleanup){
+ if (this._isBeingDestroyed) {
+ if (!deferCleanup) {
+ this._cleanup()
+ }
+ return
+ }
+ this._callHook('beforeDestroy')
+ this._isBeingDestroyed = true
+ var i
+ // remove self from parent. only necessary
+ // if parent is not being destroyed as well.
+ var parent = this.$parent
+ if (parent && !parent._isBeingDestroyed) {
+ parent.$children.$remove(this)
+ // unregister ref (remove: true)
+ this._updateRef(true)
+ }
+ // destroy all children.
+ i = this.$children.length
+ while (i--) {
+ this.$children[i].$destroy()
+ }
+ // teardown props
+ if (this._propsUnlinkFn) {
+ this._propsUnlinkFn()
+ }
+ // teardown all directives. this also tearsdown all
+ // directive-owned watchers.
+ if (this._unlinkFn) {
+ this._unlinkFn()
+ }
+ i = this._watchers.length
+ while (i--) {
+ this._watchers[i].teardown()
+ }
+ // remove reference to self on $el
+ if (this.$el) {
+ this.$el.__vue__ = null
+ }
+ // remove DOM element
+ var self = this
+ if (remove && this.$el) {
+ this.$remove(function (){
+ self._cleanup()
+ })
+ } else if (!deferCleanup) {
+ this._cleanup()
+ }
+ }
+
+ /**
+ * Clean up to ensure garbage collection.
+ * This is called after the leave transition if there
+ * is any.
+ */
+
+ exports._cleanup = function (){
+ if (this._isDestroyed) {
+ return
+ }
+ // remove self from owner fragment
+ // do it in cleanup so that we can call $destroy with
+ // defer right when a fragment is about to be removed.
+ if (this._frag) {
+ this._frag.children.$remove(this)
+ }
+ // remove reference from data ob
+ // frozen object may not have observer.
+ if (this._data.__ob__) {
+ this._data.__ob__.removeVm(this)
+ }
+ // Clean up references to private properties and other
+ // instances. preserve reference to _data so that proxy
+ // accessors still work. The only potential side effect
+ // here is that mutating the instance after it's destroyed
+ // may affect the state of other components that are still
+ // observing the same object, but that seems to be a
+ // reasonable responsibility for the user rather than
+ // always throwing an error on them.
+ this.$el =
+ this.$parent =
+ this.$root =
+ this.$children =
+ this._watchers =
+ this._context =
+ this._scope =
+ this._directives = null
+ // call the last hook...
+ this._isDestroyed = true
+ this._callHook('destroyed')
+ // turn off all instance listeners.
+ this.$off()
+ }
+
+ /***/
+ },
+ /* 61 */
+ /***/ function (module, exports, __webpack_require__){
+
+ var _ = __webpack_require__(1)
+ var Watcher = __webpack_require__(40)
+ var expParser = __webpack_require__(42)
+
+ function noop(){}
+
+ /**
+ * A directive links a DOM element with a piece of data,
+ * which is the result of evaluating an expression.
+ * It registers a watcher with the expression and calls
+ * the DOM update function when a change is triggered.
+ *
+ * @param {String} name
+ * @param {Node} el
+ * @param {Vue} vm
+ * @param {Object} descriptor
+ * - {String} name
+ * - {Object} def
+ * - {String} expression
+ * - {Array