+
+
{{{ highlightedLines }}}
diff --git a/bower.json b/bower.json
index e143c1d..c1dd6ec 100644
--- a/bower.json
+++ b/bower.json
@@ -2,7 +2,7 @@
"name": "fluentd-ui",
"dependencies": {
"es6-promise": "~1.0.0",
- "vue": "~0.10.0",
+ "vue": "~0.11.0",
"lodash": "~2.4.0"
},
"devDependencies": {
diff --git a/vendor/assets/javascripts/bower/vue/.bower.json b/vendor/assets/javascripts/bower/vue/.bower.json
index 30a2288..ff27e96 100644
--- a/vendor/assets/javascripts/bower/vue/.bower.json
+++ b/vendor/assets/javascripts/bower/vue/.bower.json
@@ -1,6 +1,6 @@
{
"name": "vue",
- "version": "0.10.6",
+ "version": "0.11.0",
"main": "dist/vue.js",
"description": "Simple, Fast & Composable MVVM for building interative interfaces",
"authors": [
@@ -11,19 +11,19 @@
".*",
"examples",
"test",
- "tasks",
- "Gruntfile.js",
+ "grunt",
+ "gruntfile.js",
"*.json",
"*.md"
],
"homepage": "https://github.com/yyx990803/vue",
- "_release": "0.10.6",
+ "_release": "0.11.0",
"_resolution": {
"type": "version",
- "tag": "v0.10.6",
- "commit": "cf37f7efd6d63c0aa46b50c624816e645ddd7edd"
+ "tag": "0.11.0",
+ "commit": "5bc3e30b694dc3b6aeeb87c24f88b9cd7a7259d6"
},
"_source": "git://github.com/yyx990803/vue.git",
- "_target": "~0.10.0",
+ "_target": "~0.11.0",
"_originalSource": "vue"
}
\ No newline at end of file
diff --git a/vendor/assets/javascripts/bower/vue/LICENSE b/vendor/assets/javascripts/bower/vue/LICENSE
index 17a9b2f..405481c 100644
--- a/vendor/assets/javascripts/bower/vue/LICENSE
+++ b/vendor/assets/javascripts/bower/vue/LICENSE
@@ -1,6 +1,6 @@
The MIT License (MIT)
-Copyright (c) 2013 Yuxi Evan You
+Copyright (c) 2013-2014 Yuxi Evan You
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
diff --git a/vendor/assets/javascripts/bower/vue/dist/vue.js b/vendor/assets/javascripts/bower/vue/dist/vue.js
index a747ba9..ab0eefc 100644
--- a/vendor/assets/javascripts/bower/vue/dist/vue.js
+++ b/vendor/assets/javascripts/bower/vue/dist/vue.js
@@ -1,4772 +1,7615 @@
-/*
- Vue.js v0.10.6
- (c) 2014 Evan You
- License: MIT
-*/
-;(function(){
-'use strict';
-
/**
- * Require the given path.
- *
- * @param {String} path
- * @return {Object} exports
- * @api public
+ * Vue.js v0.11.0
+ * (c) 2014 Evan You
+ * Released under the MIT License.
*/
-function require(path, parent, orig) {
- var resolved = require.resolve(path);
+(function webpackUniversalModuleDefinition(root, factory) {
+ if(typeof exports === 'object' && typeof module === 'object')
+ module.exports = factory();
+ else if(typeof define === 'function' && define.amd)
+ define(factory);
+ else if(typeof exports === 'object')
+ exports["Vue"] = factory();
+ else
+ root["Vue"] = factory();
+})(this, function() {
+return /******/ (function(modules) { // webpackBootstrap
+/******/ // The module cache
+/******/ var installedModules = {};
+/******/
+/******/ // The require function
+/******/ function __webpack_require__(moduleId) {
+/******/
+/******/ // Check if module is in cache
+/******/ if(installedModules[moduleId])
+/******/ return installedModules[moduleId].exports;
+/******/
+/******/ // Create a new module (and put it into the cache)
+/******/ var module = installedModules[moduleId] = {
+/******/ exports: {},
+/******/ id: moduleId,
+/******/ loaded: false
+/******/ };
+/******/
+/******/ // Execute the module function
+/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+/******/
+/******/ // Flag the module as loaded
+/******/ module.loaded = true;
+/******/
+/******/ // Return the exports of the module
+/******/ return module.exports;
+/******/ }
+/******/
+/******/
+/******/ // expose the modules object (__webpack_modules__)
+/******/ __webpack_require__.m = modules;
+/******/
+/******/ // expose the module cache
+/******/ __webpack_require__.c = installedModules;
+/******/
+/******/ // __webpack_public_path__
+/******/ __webpack_require__.p = "";
+/******/
+/******/ // Load entry module and return exports
+/******/ return __webpack_require__(0);
+/******/ })
+/************************************************************************/
+/******/ ([
+/* 0 */
+/***/ function(module, exports, __webpack_require__) {
- // lookup failed
- if (null == resolved) {
- throwError()
- return
- }
+ var _ = __webpack_require__(1)
+ var extend = _.extend
- var module = require.modules[resolved];
+ /**
+ * The exposed Vue constructor.
+ *
+ * API conventions:
+ * - public API methods/properties are prefiexed with `$`
+ * - internal methods/properties are prefixed with `_`
+ * - non-prefixed properties are assumed to be proxied user
+ * data.
+ *
+ * @constructor
+ * @param {Object} [options]
+ * @public
+ */
- // perform real require()
- // by invoking the module's
- // registered function
- if (!module._resolving && !module.exports) {
- var mod = {};
- mod.exports = {};
- mod.client = mod.component = true;
- module._resolving = true;
- module.call(this, mod.exports, require.relative(resolved), mod);
- delete module._resolving;
- module.exports = mod.exports;
- }
+ function Vue (options) {
+ this._init(options)
+ }
- function throwError () {
- orig = orig || path;
- parent = parent || 'root';
- var err = new Error('Failed to require "' + orig + '" from "' + parent + '"');
- err.path = orig;
- err.parent = parent;
- err.require = true;
- throw err;
- }
+ /**
+ * Mixin global API
+ */
- return module.exports;
-}
+ extend(Vue, __webpack_require__(2))
-/**
- * Registered modules.
- */
+ /**
+ * Vue and every constructor that extends Vue has an
+ * associated options object, which can be accessed during
+ * compilation steps as `this.constructor.options`.
+ *
+ * These can be seen as the default options of every
+ * Vue instance.
+ */
-require.modules = {};
+ Vue.options = {
+ directives : __webpack_require__(8),
+ filters : __webpack_require__(9),
+ partials : {},
+ transitions : {},
+ components : {}
+ }
-/**
- * Registered aliases.
- */
+ /**
+ * Build up the prototype
+ */
-require.aliases = {};
+ var p = Vue.prototype
-/**
- * Resolve `path`.
- *
- * Lookup:
- *
- * - PATH/index.js
- * - PATH.js
- * - PATH
- *
- * @param {String} path
- * @return {String} path or null
- * @api private
- */
+ /**
+ * $data has a setter which does a bunch of
+ * teardown/setup work
+ */
-require.exts = [
- '',
- '.js',
- '.json',
- '/index.js',
- '/index.json'
- ];
+ Object.defineProperty(p, '$data', {
+ get: function () {
+ return this._data
+ },
+ set: function (newData) {
+ this._setData(newData)
+ }
+ })
-require.resolve = function(path) {
- if (path.charAt(0) === '/') path = path.slice(1);
+ /**
+ * Mixin internal instance methods
+ */
- for (var i = 0; i < 5; i++) {
- var fullPath = path + require.exts[i];
- if (require.modules.hasOwnProperty(fullPath)) return fullPath;
- if (require.aliases.hasOwnProperty(fullPath)) return require.aliases[fullPath];
- }
-};
+ extend(p, __webpack_require__(10))
+ extend(p, __webpack_require__(11))
+ extend(p, __webpack_require__(12))
+ extend(p, __webpack_require__(13))
-/**
- * Normalize `path` relative to the current path.
- *
- * @param {String} curr
- * @param {String} path
- * @return {String}
- * @api private
- */
+ /**
+ * Mixin public API methods
+ */
-require.normalize = function(curr, path) {
+ extend(p, __webpack_require__(3))
+ extend(p, __webpack_require__(4))
+ extend(p, __webpack_require__(5))
+ extend(p, __webpack_require__(6))
+ extend(p, __webpack_require__(7))
- var segs = [];
+ module.exports = _.Vue = Vue
- if ('.' != path.charAt(0)) return path;
+/***/ },
+/* 1 */
+/***/ function(module, exports, __webpack_require__) {
- curr = curr.split('/');
- path = path.split('/');
+ var lang = __webpack_require__(14)
+ var extend = lang.extend
- for (var i = 0; i < path.length; ++i) {
- if ('..' === path[i]) {
- curr.pop();
- } else if ('.' != path[i] && '' != path[i]) {
- segs.push(path[i]);
- }
- }
- return curr.concat(segs).join('/');
-};
+ extend(exports, lang)
+ extend(exports, __webpack_require__(15))
+ extend(exports, __webpack_require__(16))
+ extend(exports, __webpack_require__(17))
+ extend(exports, __webpack_require__(18))
-/**
- * Register module at `path` with callback `definition`.
- *
- * @param {String} path
- * @param {Function} definition
- * @api private
- */
+/***/ },
+/* 2 */
+/***/ function(module, exports, __webpack_require__) {
-require.register = function(path, definition) {
- require.modules[path] = definition;
-};
+ var _ = __webpack_require__(1)
+ var mergeOptions = __webpack_require__(19)
-/**
- * Alias a module definition.
- *
- * @param {String} from
- * @param {String} to
- * @api private
- */
+ /**
+ * Expose useful internals
+ */
-require.alias = function(from, to) {
- if (!require.modules.hasOwnProperty(from)) {
- throwError()
- return
- }
- require.aliases[to] = from;
+ exports.util = _
+ exports.nextTick = _.nextTick
+ exports.config = __webpack_require__(20)
- function throwError () {
- throw new Error('Failed to alias "' + from + '", it does not exist');
- }
-};
+ /**
+ * Each instance constructor, including Vue, has a unique
+ * cid. This enables us to create wrapped "child
+ * constructors" for prototypal inheritance and cache them.
+ */
-/**
- * Return a require function relative to the `parent` path.
- *
- * @param {String} parent
- * @return {Function}
- * @api private
- */
+ exports.cid = 0
+ var cid = 1
-require.relative = function(parent) {
- var p = require.normalize(parent, '..');
+ /**
+ * Class inehritance
+ *
+ * @param {Object} extendOptions
+ */
- /**
- * The relative require() itself.
- */
+ exports.extend = function (extendOptions) {
+ extendOptions = extendOptions || {}
+ var Super = this
+ var Sub = createClass(extendOptions.name || 'VueComponent')
+ Sub.prototype = Object.create(Super.prototype)
+ Sub.prototype.constructor = Sub
+ Sub.cid = cid++
+ Sub.options = mergeOptions(
+ Super.options,
+ extendOptions
+ )
+ Sub['super'] = Super
+ // allow further extension
+ Sub.extend = Super.extend
+ // create asset registers, so extended classes
+ // can have their private assets too.
+ createAssetRegisters(Sub)
+ return Sub
+ }
- function localRequire(path) {
- var resolved = localRequire.resolve(path);
- return require(resolved, parent, path);
- }
+ /**
+ * A function that returns a sub-class constructor with the
+ * given name. This gives us much nicer output when
+ * logging instances in the console.
+ *
+ * @param {String} name
+ * @return {Function}
+ */
- /**
- * Resolve relative to the parent.
- */
+ function createClass (name) {
+ return new Function(
+ 'return function ' + _.camelize(name, true) +
+ ' (options) { this._init(options) }'
+ )()
+ }
- localRequire.resolve = function(path) {
- var c = path.charAt(0);
- if ('/' === c) return path.slice(1);
- if ('.' === c) return require.normalize(p, path);
+ /**
+ * Plugin system
+ *
+ * @param {Object} plugin
+ */
- // resolve deps by returning
- // the dep in the nearest "deps"
- // directory
- var segs = parent.split('/');
- var i = segs.length;
- while (i--) {
- if (segs[i] === 'deps') {
- break;
- }
- }
- path = segs.slice(0, i + 2).join('/') + '/deps/' + path;
- return path;
- };
+ exports.use = function (plugin) {
+ // additional parameters
+ var args = _.toArray(arguments, 1)
+ args.unshift(this)
+ if (typeof plugin.install === 'function') {
+ plugin.install.apply(plugin, args)
+ } else {
+ plugin.apply(null, args)
+ }
+ return this
+ }
- /**
- * Check if module is defined at `path`.
- */
+ /**
+ * Define asset registration methods on a constructor.
+ *
+ * @param {Function} Constructor
+ */
- localRequire.exists = function(path) {
- return require.modules.hasOwnProperty(localRequire.resolve(path));
- };
+ var assetTypes = [
+ 'directive',
+ 'filter',
+ 'partial',
+ 'transition'
+ ]
- return localRequire;
-};
-require.register("vue/src/main.js", function(exports, require, module){
-var config = require('./config'),
- ViewModel = require('./viewmodel'),
- utils = require('./utils'),
- makeHash = utils.hash,
- assetTypes = ['directive', 'filter', 'partial', 'effect', 'component'],
- // Internal modules that are exposed for plugins
- pluginAPI = {
- utils: utils,
- config: config,
- transition: require('./transition'),
- observer: require('./observer')
- }
+ function createAssetRegisters (Constructor) {
-ViewModel.options = config.globalAssets = {
- directives : require('./directives'),
- filters : require('./filters'),
- partials : makeHash(),
- effects : makeHash(),
- components : makeHash()
-}
+ /* Asset registration methods share the same signature:
+ *
+ * @param {String} id
+ * @param {*} definition
+ */
-/**
- * Expose asset registration methods
- */
-assetTypes.forEach(function (type) {
- ViewModel[type] = function (id, value) {
- var hash = this.options[type + 's']
- if (!hash) {
- hash = this.options[type + 's'] = makeHash()
- }
- if (!value) return hash[id]
- if (type === 'partial') {
- value = utils.parseTemplateOption(value)
- } else if (type === 'component') {
- value = utils.toConstructor(value)
- } else if (type === 'filter') {
- utils.checkFilter(value)
- }
- hash[id] = value
- return this
- }
-})
+ assetTypes.forEach(function (type) {
+ Constructor[type] = function (id, definition) {
+ if (!definition) {
+ return this.options[type + 's'][id]
+ } else {
+ this.options[type + 's'][id] = definition
+ }
+ }
+ })
-/**
- * Set config options
- */
-ViewModel.config = function (opts, val) {
- if (typeof opts === 'string') {
- if (val === undefined) {
- return config[opts]
- } else {
- config[opts] = val
- }
- } else {
- utils.extend(config, opts)
- }
- return this
-}
+ /**
+ * Component registration needs to automatically invoke
+ * Vue.extend on object values.
+ *
+ * @param {String} id
+ * @param {Object|Function} definition
+ */
-/**
- * Expose an interface for plugins
- */
-ViewModel.use = function (plugin) {
- if (typeof plugin === 'string') {
- try {
- plugin = require(plugin)
- } catch (e) {
- utils.warn('Cannot find plugin: ' + plugin)
- return
- }
- }
+ Constructor.component = function (id, definition) {
+ if (!definition) {
+ return this.options.components[id]
+ } else {
+ if (_.isPlainObject(definition)) {
+ definition.name = id
+ definition = _.Vue.extend(definition)
+ }
+ this.options.components[id] = definition
+ }
+ }
+ }
- // additional parameters
- var args = [].slice.call(arguments, 1)
- args.unshift(this)
+ createAssetRegisters(exports)
- if (typeof plugin.install === 'function') {
- plugin.install.apply(plugin, args)
- } else {
- plugin.apply(null, args)
- }
- return this
-}
+/***/ },
+/* 3 */
+/***/ function(module, exports, __webpack_require__) {
-/**
- * Expose internal modules for plugins
- */
-ViewModel.require = function (module) {
- return pluginAPI[module]
-}
+ var _ = __webpack_require__(1)
+ var Watcher = __webpack_require__(21)
+ var Path = __webpack_require__(41)
+ var textParser = __webpack_require__(42)
+ var dirParser = __webpack_require__(43)
+ var expParser = __webpack_require__(44)
+ var filterRE = /[^|]\|[^|]/
-ViewModel.extend = extend
-ViewModel.nextTick = utils.nextTick
+ /**
+ * Get the value from an expression on this vm.
+ *
+ * @param {String} exp
+ * @return {*}
+ */
-/**
- * Expose the main ViewModel class
- * and add extend method
- */
-function extend (options) {
+ exports.$get = function (exp) {
+ var res = expParser.parse(exp)
+ if (res) {
+ return res.get.call(this, this)
+ }
+ }
- var ParentVM = this
+ /**
+ * Set the value from an expression on this vm.
+ * The expression must be a valid left-hand
+ * expression in an assignment.
+ *
+ * @param {String} exp
+ * @param {*} val
+ */
- // extend data options need to be copied
- // on instantiation
- if (options.data) {
- options.defaultData = options.data
- delete options.data
- }
+ exports.$set = function (exp, val) {
+ var res = expParser.parse(exp, true)
+ if (res && res.set) {
+ res.set.call(this, this, val)
+ }
+ }
- // inherit options
- // but only when the super class is not the native Vue.
- if (ParentVM !== ViewModel) {
- options = inheritOptions(options, ParentVM.options, true)
- }
- utils.processOptions(options)
+ /**
+ * Add a property on the VM
+ *
+ * @param {String} key
+ * @param {*} val
+ */
- var ExtendedVM = function (opts, asParent) {
- if (!asParent) {
- opts = inheritOptions(opts, options, true)
- }
- ParentVM.call(this, opts, true)
- }
+ exports.$add = function (key, val) {
+ this._data.$add(key, val)
+ }
- // inherit prototype props
- var proto = ExtendedVM.prototype = Object.create(ParentVM.prototype)
- utils.defProtected(proto, 'constructor', ExtendedVM)
+ /**
+ * Delete a property on the VM
+ *
+ * @param {String} key
+ */
- // allow extended VM to be further extended
- ExtendedVM.extend = extend
- ExtendedVM.super = ParentVM
- ExtendedVM.options = options
+ exports.$delete = function (key) {
+ this._data.$delete(key)
+ }
- // allow extended VM to add its own assets
- assetTypes.forEach(function (type) {
- ExtendedVM[type] = ViewModel[type]
- })
+ /**
+ * Watch an expression, trigger callback when its
+ * value changes.
+ *
+ * @param {String} exp
+ * @param {Function} cb
+ * @param {Boolean} [deep]
+ * @param {Boolean} [immediate]
+ * @return {Function} - unwatchFn
+ */
- // allow extended VM to use plugins
- ExtendedVM.use = ViewModel.use
- ExtendedVM.require = ViewModel.require
+ exports.$watch = function (exp, cb, deep, immediate) {
+ var vm = this
+ var key = deep ? exp + '**deep**' : exp
+ var watcher = vm._userWatchers[key]
+ var wrappedCb = function (val, oldVal) {
+ cb.call(vm, val, oldVal)
+ }
+ if (!watcher) {
+ watcher = vm._userWatchers[key] =
+ new Watcher(vm, exp, wrappedCb, null, false, deep)
+ } else {
+ watcher.addCb(wrappedCb)
+ }
+ if (immediate) {
+ wrappedCb(watcher.value)
+ }
+ return function unwatchFn () {
+ watcher.removeCb(wrappedCb)
+ if (!watcher.active) {
+ vm._userWatchers[key] = null
+ }
+ }
+ }
- return ExtendedVM
-}
+ /**
+ * Evaluate a text directive, including filters.
+ *
+ * @param {String} text
+ * @return {String}
+ */
-/**
- * Inherit options
- *
- * For options such as `data`, `vms`, `directives`, 'partials',
- * they should be further extended. However extending should only
- * be done at top level.
- *
- * `proto` is an exception because it's handled directly on the
- * prototype.
- *
- * `el` is an exception because it's not allowed as an
- * extension option, but only as an instance option.
- */
-function inheritOptions (child, parent, topLevel) {
- child = child || {}
- if (!parent) return child
- for (var key in parent) {
- if (key === 'el') continue
- var val = child[key],
- parentVal = parent[key]
- if (topLevel && typeof val === 'function' && parentVal) {
- // merge hook functions into an array
- child[key] = [val]
- if (Array.isArray(parentVal)) {
- child[key] = child[key].concat(parentVal)
- } else {
- child[key].push(parentVal)
- }
- } else if (
- topLevel &&
- (utils.isTrueObject(val) || utils.isTrueObject(parentVal))
- && !(parentVal instanceof ViewModel)
- ) {
- // merge toplevel object options
- child[key] = inheritOptions(val, parentVal)
- } else if (val === undefined) {
- // inherit if child doesn't override
- child[key] = parentVal
- }
- }
- return child
-}
+ exports.$eval = function (text) {
+ // check for filters.
+ if (filterRE.test(text)) {
+ var dir = dirParser.parse(text)[0]
+ // the filter regex check might give false positive
+ // for pipes inside strings, so it's possible that
+ // we don't get any filters here
+ return dir.filters
+ ? _.applyFilters(
+ this.$get(dir.expression),
+ _.resolveFilters(this, dir.filters).read,
+ this
+ )
+ : this.$get(dir.expression)
+ } else {
+ // no filter
+ return this.$get(text)
+ }
+ }
-module.exports = ViewModel
+ /**
+ * Interpolate a piece of template text.
+ *
+ * @param {String} text
+ * @return {String}
+ */
+
+ exports.$interpolate = function (text) {
+ var tokens = textParser.parse(text)
+ var vm = this
+ if (tokens) {
+ return tokens.length === 1
+ ? vm.$eval(tokens[0].value)
+ : tokens.map(function (token) {
+ return token.tag
+ ? vm.$eval(token.value)
+ : token.value
+ }).join('')
+ } else {
+ return text
+ }
+ }
+
+ /**
+ * Log instance data as a plain JS object
+ * so that it is easier to inspect in console.
+ * This method assumes console is available.
+ *
+ * @param {String} [path]
+ */
+
+ exports.$log = function (path) {
+ var data = path
+ ? Path.get(this, path)
+ : this._data
+ console.log(JSON.parse(JSON.stringify(data)))
+ }
+
+/***/ },
+/* 4 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var _ = __webpack_require__(1)
+ var transition = __webpack_require__(45)
+
+ /**
+ * Append instance to target
+ *
+ * @param {Node} target
+ * @param {Function} [cb]
+ * @param {Boolean} [withTransition] - defaults to true
+ */
+
+ exports.$appendTo = function (target, cb, withTransition) {
+ target = query(target)
+ var targetIsDetached = !_.inDoc(target)
+ var op = withTransition === false || targetIsDetached
+ ? append
+ : transition.append
+ insert(this, target, op, targetIsDetached, cb)
+ return this
+ }
+
+ /**
+ * Prepend instance to target
+ *
+ * @param {Node} target
+ * @param {Function} [cb]
+ * @param {Boolean} [withTransition] - defaults to true
+ */
+
+ exports.$prependTo = function (target, cb, withTransition) {
+ target = query(target)
+ if (target.hasChildNodes()) {
+ this.$before(target.firstChild, cb, withTransition)
+ } else {
+ this.$appendTo(target, cb, withTransition)
+ }
+ return this
+ }
+
+ /**
+ * Insert instance before target
+ *
+ * @param {Node} target
+ * @param {Function} [cb]
+ * @param {Boolean} [withTransition] - defaults to true
+ */
+
+ exports.$before = function (target, cb, withTransition) {
+ target = query(target)
+ var targetIsDetached = !_.inDoc(target)
+ var op = withTransition === false || targetIsDetached
+ ? before
+ : transition.before
+ insert(this, target, op, targetIsDetached, cb)
+ return this
+ }
+
+ /**
+ * Insert instance after target
+ *
+ * @param {Node} target
+ * @param {Function} [cb]
+ * @param {Boolean} [withTransition] - defaults to true
+ */
+
+ exports.$after = function (target, cb, withTransition) {
+ target = query(target)
+ if (target.nextSibling) {
+ this.$before(target.nextSibling, cb, withTransition)
+ } else {
+ this.$appendTo(target.parentNode, cb, withTransition)
+ }
+ return this
+ }
+
+ /**
+ * Remove instance from DOM
+ *
+ * @param {Function} [cb]
+ * @param {Boolean} [withTransition] - defaults to true
+ */
+
+ exports.$remove = function (cb, withTransition) {
+ var inDoc = this._isAttached && _.inDoc(this.$el)
+ // if we are not in document, no need to check
+ // for transitions
+ if (!inDoc) withTransition = false
+ var op
+ var self = this
+ var realCb = function () {
+ if (inDoc) self._callHook('detached')
+ if (cb) cb()
+ }
+ if (
+ this._isBlock &&
+ !this._blockFragment.hasChildNodes()
+ ) {
+ op = withTransition === false
+ ? append
+ : transition.removeThenAppend
+ blockOp(this, this._blockFragment, op, realCb)
+ } else {
+ op = withTransition === false
+ ? remove
+ : transition.remove
+ op(this.$el, this, realCb)
+ }
+ return this
+ }
+
+ /**
+ * Shared DOM insertion function.
+ *
+ * @param {Vue} vm
+ * @param {Element} target
+ * @param {Function} op
+ * @param {Boolean} targetIsDetached
+ * @param {Function} [cb]
+ */
+
+ function insert (vm, target, op, targetIsDetached, cb) {
+ var shouldCallHook =
+ !targetIsDetached &&
+ !vm._isAttached &&
+ !_.inDoc(vm.$el)
+ if (vm._isBlock) {
+ blockOp(vm, target, op, cb)
+ } else {
+ op(vm.$el, target, vm, cb)
+ }
+ if (shouldCallHook) {
+ vm._callHook('attached')
+ }
+ }
+
+ /**
+ * Execute a transition operation on a block instance,
+ * iterating through all its block nodes.
+ *
+ * @param {Vue} vm
+ * @param {Node} target
+ * @param {Function} op
+ * @param {Function} cb
+ */
+
+ function blockOp (vm, target, op, cb) {
+ var current = vm._blockStart
+ var end = vm._blockEnd
+ var next
+ while (next !== end) {
+ next = current.nextSibling
+ op(current, target, vm)
+ current = next
+ }
+ op(end, target, vm, cb)
+ }
+
+ /**
+ * Check for selectors
+ *
+ * @param {String|Element} el
+ */
+
+ function query (el) {
+ return typeof el === 'string'
+ ? document.querySelector(el)
+ : el
+ }
+
+ /**
+ * Append operation that takes a callback.
+ *
+ * @param {Node} el
+ * @param {Node} target
+ * @param {Vue} vm - unused
+ * @param {Function} [cb]
+ */
+
+ function append (el, target, vm, cb) {
+ target.appendChild(el)
+ if (cb) cb()
+ }
+
+ /**
+ * InsertBefore operation that takes a callback.
+ *
+ * @param {Node} el
+ * @param {Node} target
+ * @param {Vue} vm - unused
+ * @param {Function} [cb]
+ */
+
+ function before (el, target, vm, cb) {
+ _.before(el, target)
+ if (cb) cb()
+ }
+
+ /**
+ * Remove operation that takes a callback.
+ *
+ * @param {Node} el
+ * @param {Vue} vm - unused
+ * @param {Function} [cb]
+ */
+
+ function remove (el, vm, cb) {
+ _.remove(el)
+ if (cb) cb()
+ }
+
+/***/ },
+/* 5 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var _ = __webpack_require__(1)
+
+ /**
+ * Listen on the given `event` with `fn`.
+ *
+ * @param {String} event
+ * @param {Function} fn
+ */
+
+ exports.$on = function (event, fn) {
+ (this._events[event] || (this._events[event] = []))
+ .push(fn)
+ modifyListenerCount(this, event, 1)
+ return this
+ }
+
+ /**
+ * Adds an `event` listener that will be invoked a single
+ * time then automatically removed.
+ *
+ * @param {String} event
+ * @param {Function} fn
+ */
+
+ exports.$once = function (event, fn) {
+ var self = this
+ function on () {
+ self.$off(event, on)
+ fn.apply(this, arguments)
+ }
+ on.fn = fn
+ this.$on(event, on)
+ return this
+ }
+
+ /**
+ * Remove the given callback for `event` or all
+ * registered callbacks.
+ *
+ * @param {String} event
+ * @param {Function} fn
+ */
+
+ exports.$off = function (event, fn) {
+ var cbs
+ // all
+ if (!arguments.length) {
+ if (this.$parent) {
+ for (event in this._events) {
+ cbs = this._events[event]
+ if (cbs) {
+ modifyListenerCount(this, event, -cbs.length)
+ }
+ }
+ }
+ this._events = {}
+ return this
+ }
+ // specific event
+ cbs = this._events[event]
+ if (!cbs) {
+ return this
+ }
+ if (arguments.length === 1) {
+ modifyListenerCount(this, event, -cbs.length)
+ this._events[event] = null
+ return this
+ }
+ // specific handler
+ var cb
+ var i = cbs.length
+ while (i--) {
+ cb = cbs[i]
+ if (cb === fn || cb.fn === fn) {
+ modifyListenerCount(this, event, -1)
+ cbs.splice(i, 1)
+ break
+ }
+ }
+ return this
+ }
+
+ /**
+ * Trigger an event on self.
+ *
+ * @param {String} event
+ */
+
+ exports.$emit = function (event) {
+ this._eventCancelled = false
+ var cbs = this._events[event]
+ if (cbs) {
+ // avoid leaking arguments:
+ // http://jsperf.com/closure-with-arguments
+ var i = arguments.length - 1
+ var args = new Array(i)
+ while (i--) {
+ args[i] = arguments[i + 1]
+ }
+ i = 0
+ cbs = cbs.length > 1
+ ? _.toArray(cbs)
+ : cbs
+ for (var l = cbs.length; i < l; i++) {
+ if (cbs[i].apply(this, args) === false) {
+ this._eventCancelled = true
+ }
+ }
+ }
+ return this
+ }
+
+ /**
+ * Recursively broadcast an event to all children instances.
+ *
+ * @param {String} event
+ * @param {...*} additional arguments
+ */
+
+ exports.$broadcast = function (event) {
+ // if no child has registered for this event,
+ // then there's no need to broadcast.
+ if (!this._eventsCount[event]) return
+ var children = this._children
+ if (children) {
+ for (var i = 0, l = children.length; i < l; i++) {
+ var child = children[i]
+ child.$emit.apply(child, arguments)
+ if (!child._eventCancelled) {
+ child.$broadcast.apply(child, arguments)
+ }
+ }
+ }
+ return this
+ }
+
+ /**
+ * Recursively propagate an event up the parent chain.
+ *
+ * @param {String} event
+ * @param {...*} additional arguments
+ */
+
+ exports.$dispatch = function () {
+ var parent = this.$parent
+ while (parent) {
+ parent.$emit.apply(parent, arguments)
+ parent = parent._eventCancelled
+ ? null
+ : parent.$parent
+ }
+ return this
+ }
+
+ /**
+ * Modify the listener counts on all parents.
+ * This bookkeeping allows $broadcast to return early when
+ * no child has listened to a certain event.
+ *
+ * @param {Vue} vm
+ * @param {String} event
+ * @param {Number} count
+ */
+
+ var hookRE = /^hook:/
+ function modifyListenerCount (vm, event, count) {
+ var parent = vm.$parent
+ // hooks do not get broadcasted so no need
+ // to do bookkeeping for them
+ if (!parent || !count || hookRE.test(event)) return
+ while (parent) {
+ parent._eventsCount[event] =
+ (parent._eventsCount[event] || 0) + count
+ parent = parent.$parent
+ }
+ }
+
+/***/ },
+/* 6 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var _ = __webpack_require__(1)
+
+ /**
+ * Create a child instance that prototypally inehrits
+ * data on parent. To achieve that we create an intermediate
+ * constructor with its prototype pointing to parent.
+ *
+ * @param {Object} opts
+ * @param {Function} [BaseCtor]
+ * @return {Vue}
+ * @public
+ */
+
+ exports.$addChild = function (opts, BaseCtor) {
+ BaseCtor = BaseCtor || _.Vue
+ opts = opts || {}
+ var parent = this
+ var ChildVue
+ var inherit = opts.inherit !== undefined
+ ? opts.inherit
+ : BaseCtor.options.inherit
+ if (inherit) {
+ var ctors = parent._childCtors
+ if (!ctors) {
+ ctors = parent._childCtors = {}
+ }
+ ChildVue = ctors[BaseCtor.cid]
+ if (!ChildVue) {
+ var optionName = BaseCtor.options.name
+ var className = optionName
+ ? _.camelize(optionName, true)
+ : 'VueComponent'
+ ChildVue = new Function(
+ 'return function ' + className + ' (options) {' +
+ 'this.constructor = ' + className + ';' +
+ 'this._init(options) }'
+ )()
+ ChildVue.options = BaseCtor.options
+ ChildVue.prototype = this
+ ctors[BaseCtor.cid] = ChildVue
+ }
+ } else {
+ ChildVue = BaseCtor
+ }
+ opts._parent = parent
+ opts._root = parent.$root
+ var child = new ChildVue(opts)
+ if (!this._children) {
+ this._children = []
+ }
+ this._children.push(child)
+ return child
+ }
+
+/***/ },
+/* 7 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var _ = __webpack_require__(1)
+ var compile = __webpack_require__(46)
+
+ /**
+ * Set instance target element and kick off the compilation
+ * process. The passed in `el` can be a selector string, an
+ * existing Element, or a DocumentFragment (for block
+ * instances).
+ *
+ * @param {Element|DocumentFragment|string} el
+ * @public
+ */
+
+ exports.$mount = function (el) {
+ if (this._isCompiled) {
+ _.warn('$mount() should be called only once.')
+ return
+ }
+ if (!el) {
+ el = document.createElement('div')
+ } else if (typeof el === 'string') {
+ var selector = el
+ el = document.querySelector(el)
+ if (!el) {
+ _.warn('Cannot find element: ' + selector)
+ return
+ }
+ }
+ this._compile(el)
+ this._isCompiled = true
+ this._callHook('compiled')
+ if (_.inDoc(this.$el)) {
+ this._callHook('attached')
+ this._initDOMHooks()
+ ready.call(this)
+ } else {
+ this._initDOMHooks()
+ this.$once('hook:attached', ready)
+ }
+ return this
+ }
+
+ /**
+ * Mark an instance as ready.
+ */
+
+ function ready () {
+ this._isAttached = true
+ this._isReady = true
+ this._callHook('ready')
+ }
+
+ /**
+ * 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.
+ * @public
+ */
+
+ exports.$destroy = function (remove) {
+ if (this._isBeingDestroyed) {
+ 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) {
+ i = parent._children.indexOf(this)
+ parent._children.splice(i, 1)
+ }
+ // destroy all children.
+ if (this._children) {
+ i = this._children.length
+ while (i--) {
+ this._children[i].$destroy()
+ }
+ }
+ // teardown all directives. this also tearsdown all
+ // directive-owned watchers.
+ i = this._directives.length
+ while (i--) {
+ this._directives[i]._teardown()
+ }
+ // teardown all user watchers.
+ for (i in this._userWatchers) {
+ this._userWatchers[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 () {
+ cleanup(self)
+ })
+ } else {
+ cleanup(self)
+ }
+ }
+
+ /**
+ * Clean up to ensure garbage collection.
+ * This is called after the leave transition if there
+ * is any.
+ *
+ * @param {Vue} vm
+ */
+
+ function cleanup (vm) {
+ // remove reference from data ob
+ vm._data.__ob__.removeVm(vm)
+ vm._data =
+ vm._watchers =
+ vm._userWatchers =
+ vm._watcherList =
+ vm.$el =
+ vm.$parent =
+ vm.$root =
+ vm._children =
+ vm._bindings =
+ vm._directives = null
+ // call the last hook...
+ vm._isDestroyed = true
+ vm._callHook('destroyed')
+ // turn off all instance listeners.
+ vm.$off()
+ }
+
+ /**
+ * Partially compile a piece of DOM and return a
+ * decompile function.
+ *
+ * @param {Element|DocumentFragment} el
+ * @return {Function}
+ */
+
+ exports.$compile = function (el) {
+ return compile(el, this.$options, true)(this, el)
+ }
+
+/***/ },
+/* 8 */
+/***/ function(module, exports, __webpack_require__) {
+
+ // manipulation directives
+ exports.text = __webpack_require__(22)
+ exports.html = __webpack_require__(23)
+ exports.attr = __webpack_require__(24)
+ exports.show = __webpack_require__(25)
+ exports['class'] = __webpack_require__(26)
+ exports.el = __webpack_require__(27)
+ exports.ref = __webpack_require__(28)
+ exports.cloak = __webpack_require__(29)
+ exports.style = __webpack_require__(30)
+ exports.partial = __webpack_require__(31)
+ exports.transition = __webpack_require__(32)
+
+ // event listener directives
+ exports.on = __webpack_require__(33)
+ exports.model = __webpack_require__(48)
+
+ // child vm directives
+ exports.component = __webpack_require__(34)
+ exports.repeat = __webpack_require__(35)
+ exports['if'] = __webpack_require__(36)
+ exports['with'] = __webpack_require__(37)
+
+/***/ },
+/* 9 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var _ = __webpack_require__(1)
+
+ /**
+ * Stringify value.
+ *
+ * @param {Number} indent
+ */
+
+ exports.json = function (value, indent) {
+ return JSON.stringify(value, null, Number(indent) || 2)
+ }
+
+ /**
+ * '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, sign) {
+ value = parseFloat(value)
+ if (!value && value !== 0) return ''
+ sign = sign || '$'
+ var s = Math.floor(Math.abs(value)).toString(),
+ i = s.length % 3,
+ h = i > 0
+ ? (s.slice(0, i) + (s.length > 3 ? ',' : ''))
+ : '',
+ f = '.' + value.toFixed(2).slice(-2)
+ return (value < 0 ? '-' : '') +
+ sign + h + s.slice(i).replace(digitsRE, '$1,') + f
+ }
+
+ /**
+ * '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'))
+ }
+
+ /**
+ * A special filter that takes a handler function,
+ * wraps it so it only gets triggered on specific
+ * keypresses. v-on only.
+ *
+ * @param {String} key
+ */
+
+ var keyCodes = {
+ enter : 13,
+ tab : 9,
+ 'delete' : 46,
+ up : 38,
+ left : 37,
+ right : 39,
+ down : 40,
+ esc : 27
+ }
+
+ exports.key = function (handler, key) {
+ if (!handler) return
+ var code = keyCodes[key]
+ if (!code) {
+ code = parseInt(key, 10)
+ }
+ return function (e) {
+ if (e.keyCode === code) {
+ return handler.call(this, e)
+ }
+ }
+ }
+
+ /**
+ * Install special array filters
+ */
+
+ _.extend(exports, __webpack_require__(38))
+
+/***/ },
+/* 10 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var mergeOptions = __webpack_require__(19)
+
+ /**
+ * 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 = options._root || this
+ this.$ = {} // child vm references
+ this.$$ = {} // element references
+ this._watcherList = [] // all watchers as an array
+ this._watchers = {} // internal watchers as a hash
+ this._userWatchers = {} // user watchers as a hash
+ this._directives = [] // all directives
+
+ // a flag to avoid this being observed
+ this._isVue = true
+
+ // events bookkeeping
+ this._events = {} // registered callbacks
+ this._eventsCount = {} // for $broadcast optimization
+ this._eventCancelled = false // for event cancellation
+
+ // block instance properties
+ this._isBlock = false
+ this._blockStart = // @type {CommentNode}
+ this._blockEnd = null // @type {CommentNode}
+
+ // lifecycle state
+ this._isCompiled =
+ this._isDestroyed =
+ this._isReady =
+ this._isAttached =
+ this._isBeingDestroyed = false
+
+ // children
+ this._children = // @type {Array}
+ this._childCtors = null // @type {Object} - hash to cache
+ // child constructors
+
+ // merge options.
+ options = this.$options = mergeOptions(
+ this.constructor.options,
+ options,
+ this
+ )
+
+ // set data after merge.
+ this._data = options.data || {}
+
+ // initialize data observation and scope inheritance.
+ this._initScope()
+
+ // 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)
+ }
+ }
+
+/***/ },
+/* 11 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var _ = __webpack_require__(1)
+ var inDoc = _.inDoc
+
+ /**
+ * 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
+ registerCallbacks(this, '$on', options.events)
+ registerCallbacks(this, '$watch', options.watch)
+ }
+
+ /**
+ * 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 {*} handler
+ */
+
+ function register (vm, action, key, handler) {
+ var type = typeof handler
+ if (type === 'function') {
+ vm[action](key, handler)
+ } else if (type === 'string') {
+ var methods = vm.$options.methods
+ var method = methods && methods[handler]
+ if (method) {
+ vm[action](key, method)
+ } else {
+ _.warn(
+ 'Unknown method: "' + handler + '" when ' +
+ 'registering callback for ' + action +
+ ': "' + key + '".'
+ )
+ }
+ }
+ }
+
+ /**
+ * 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 () {
+ this._isAttached = true
+ var children = this._children
+ if (!children) return
+ for (var i = 0, l = children.length; i < l; i++) {
+ var child = children[i]
+ if (!child._isAttached && inDoc(child.$el)) {
+ child._callHook('attached')
+ }
+ }
+ }
+
+ /**
+ * Callback to recursively call detached hook on children
+ */
+
+ function onDetached () {
+ this._isAttached = false
+ var children = this._children
+ if (!children) return
+ for (var i = 0, l = children.length; i < l; i++) {
+ var child = children[i]
+ 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)
+ }
+
+/***/ },
+/* 12 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var _ = __webpack_require__(1)
+ var Observer = __webpack_require__(49)
+ var Binding = __webpack_require__(39)
+
+ /**
+ * Setup the scope of an instance, which contains:
+ * - observed data
+ * - computed properties
+ * - user methods
+ * - meta properties
+ */
+
+ exports._initScope = function () {
+ this._initData()
+ this._initComputed()
+ this._initMethods()
+ this._initMeta()
+ }
+
+ /**
+ * Initialize the data.
+ */
+
+ exports._initData = function () {
+ // proxy data on instance
+ var data = this._data
+ var keys = Object.keys(data)
+ var i = keys.length
+ var key
+ while (i--) {
+ key = keys[i]
+ if (!_.isReserved(key)) {
+ this._proxy(key)
+ }
+ }
+ // observe data
+ Observer.create(data).addVm(this)
+ }
+
+ /**
+ * Swap the isntance'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 (!_.isReserved(key) && !(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) && !_.isReserved(key)) {
+ // new property
+ this._proxy(key)
+ }
+ }
+ oldData.__ob__.removeVm(this)
+ Observer.create(newData).addVm(this)
+ this._digest()
+ }
+
+ /**
+ * Proxy a property, so that
+ * vm.prop === vm._data.prop
+ *
+ * @param {String} key
+ */
+
+ exports._proxy = function (key) {
+ // need to store ref to self here
+ // because these getter/setters might
+ // be called by child instances!
+ 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) {
+ delete this[key]
+ }
+
+ /**
+ * Force update on every watcher in scope.
+ */
+
+ exports._digest = function () {
+ var i = this._watcherList.length
+ while (i--) {
+ this._watcherList[i].update()
+ }
+ var children = this._children
+ var child
+ if (children) {
+ i = children.length
+ while (i--) {
+ child = children[i]
+ if (child.$options.inherit) {
+ child._digest()
+ }
+ }
+ }
+ }
+
+ /**
+ * 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 = _.bind(userDef, this)
+ def.set = noop
+ } else {
+ def.get = userDef.get
+ ? _.bind(userDef.get, this)
+ : noop
+ def.set = userDef.set
+ ? _.bind(userDef.set, this)
+ : noop
+ }
+ Object.defineProperty(this, key, def)
+ }
+ }
+ }
+
+ /**
+ * Setup instance methods. Methods must be bound to the
+ * instance since they might be called by children
+ * inheriting them.
+ */
+
+ 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) {
+ this._defineMeta(key, metas[key])
+ }
+ }
+ }
+
+ /**
+ * Define a meta property, e.g $index, $key, $value
+ * which only exists on the vm instance but not in $data.
+ *
+ * @param {String} key
+ * @param {*} value
+ */
+
+ exports._defineMeta = function (key, value) {
+ var binding = new Binding()
+ Object.defineProperty(this, key, {
+ enumerable: true,
+ configurable: true,
+ get: function metaGetter () {
+ if (Observer.target) {
+ Observer.target.addDep(binding)
+ }
+ return value
+ },
+ set: function metaSetter (val) {
+ if (val !== value) {
+ value = val
+ binding.notify()
+ }
+ }
+ })
+ }
+
+/***/ },
+/* 13 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var _ = __webpack_require__(1)
+ var Directive = __webpack_require__(40)
+ var compile = __webpack_require__(46)
+ var transclude = __webpack_require__(47)
+
+ /**
+ * 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
+ if (options._linker) {
+ this._initElement(el)
+ options._linker(this, el)
+ } else {
+ var raw = el
+ el = transclude(el, options)
+ this._initElement(el)
+ var linker = compile(el, options)
+ linker(this, el)
+ if (options.replace) {
+ _.replace(raw, el)
+ }
+ }
+ return el
+ }
+
+ /**
+ * Initialize instance element. Called in the public
+ * $mount() method.
+ *
+ * @param {Element} el
+ */
+
+ exports._initElement = function (el) {
+ if (el instanceof DocumentFragment) {
+ this._isBlock = true
+ this.$el = this._blockStart = el.firstChild
+ this._blockEnd = el.lastChild
+ this._blockFragment = 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 {Function} [linker] - pre-compiled linker fn
+ */
+
+ exports._bindDir = function (name, node, desc, def, linker) {
+ this._directives.push(
+ new Directive(name, node, this, desc, def, linker)
+ )
+ }
+
+/***/ },
+/* 14 */
+/***/ function(module, exports, __webpack_require__) {
+
+ /**
+ * Check is a string starts with $ or _
+ *
+ * @param {String} str
+ * @return {Boolean}
+ */
+
+ exports.isReserved = function (str) {
+ var c = str.charCodeAt(0)
+ return c === 0x24 || c === 0x5F
+ }
+
+ /**
+ * Guard text output, make sure undefined outputs
+ * empty string
+ *
+ * @param {*} value
+ * @return {String}
+ */
+
+ exports.toString = function (value) {
+ return value == null
+ ? ''
+ : value.toString()
+ }
+
+ /**
+ * Check and convert possible numeric numbers before
+ * setting back to data
+ *
+ * @param {*} value
+ * @return {*|Number}
+ */
+
+ exports.toNumber = function (value) {
+ return (
+ isNaN(value) ||
+ value === null ||
+ typeof value === 'boolean'
+ ) ? value
+ : Number(value)
+ }
+
+ /**
+ * Strip quotes from a string
+ *
+ * @param {String} str
+ * @return {String | false}
+ */
+
+ exports.stripQuotes = function (str) {
+ var a = str.charCodeAt(0)
+ var b = str.charCodeAt(str.length - 1)
+ return a === b && (a === 0x22 || a === 0x27)
+ ? str.slice(1, -1)
+ : false
+ }
+
+ /**
+ * Camelize a hyphen-delmited string.
+ *
+ * @param {String} str
+ * @return {String}
+ */
+
+ var camelRE = /[-_](\w)/g
+ var capitalCamelRE = /(?:^|[-_])(\w)/g
+
+ exports.camelize = function (str, cap) {
+ var RE = cap ? capitalCamelRE : camelRE
+ return str.replace(RE, function (_, c) {
+ return c ? c.toUpperCase () : '';
+ })
+ }
+
+ /**
+ * Simple bind, faster than native
+ *
+ * @param {Function} fn
+ * @param {Object} ctx
+ * @return {Function}
+ */
+
+ exports.bind = function (fn, ctx) {
+ return function () {
+ return fn.apply(ctx, arguments)
+ }
+ }
+
+ /**
+ * Convert an Array-like object to a real Array.
+ *
+ * @param {Array-like} list
+ * @param {Number} [start] - start index
+ * @return {Array}
+ */
+
+ exports.toArray = function (list, start) {
+ start = start || 0
+ var i = list.length - start
+ var ret = new Array(i)
+ while (i--) {
+ ret[i] = list[i + start]
+ }
+ return ret
+ }
+
+ /**
+ * Mix properties into target object.
+ *
+ * @param {Object} to
+ * @param {Object} from
+ */
+
+ exports.extend = function (to, from) {
+ for (var key in from) {
+ to[key] = from[key]
+ }
+ }
+
+ /**
+ * Quick object check - this is primarily used to tell
+ * Objects from primitive values when we know the value
+ * is a JSON-compliant type.
+ *
+ * @param {*} obj
+ * @return {Boolean}
+ */
+
+ exports.isObject = function (obj) {
+ return obj && typeof obj === 'object'
+ }
+
+ /**
+ * Strict object type check. Only returns true
+ * for plain JavaScript objects.
+ *
+ * @param {*} obj
+ * @return {Boolean}
+ */
+
+ var toString = Object.prototype.toString
+ exports.isPlainObject = function (obj) {
+ return toString.call(obj) === '[object Object]'
+ }
+
+ /**
+ * Array type check.
+ *
+ * @param {*} obj
+ * @return {Boolean}
+ */
+
+ exports.isArray = function (obj) {
+ return Array.isArray(obj)
+ }
+
+ /**
+ * Define a non-enumerable property
+ *
+ * @param {Object} obj
+ * @param {String} key
+ * @param {*} val
+ * @param {Boolean} [enumerable]
+ */
+
+ exports.define = function (obj, key, val, enumerable) {
+ Object.defineProperty(obj, key, {
+ value : val,
+ enumerable : !!enumerable,
+ writable : true,
+ configurable : true
+ })
+ }
+
+/***/ },
+/* 15 */
+/***/ function(module, exports, __webpack_require__) {
+
+ /**
+ * Can we use __proto__?
+ *
+ * @type {Boolean}
+ */
+
+ exports.hasProto = '__proto__' in {}
+
+ /**
+ * Indicates we have a window
+ *
+ * @type {Boolean}
+ */
+
+ var toString = Object.prototype.toString
+ var inBrowser = exports.inBrowser =
+ typeof window !== 'undefined' &&
+ toString.call(window) !== '[object Object]'
+
+ /**
+ * Defer a task to the start of the next event loop
+ *
+ * @param {Function} cb
+ * @param {Object} ctx
+ */
+
+ var defer = inBrowser
+ ? (window.requestAnimationFrame ||
+ window.webkitRequestAnimationFrame ||
+ setTimeout)
+ : setTimeout
+
+ exports.nextTick = function (cb, ctx) {
+ if (ctx) {
+ defer(function () { cb.call(ctx) }, 0)
+ } else {
+ defer(cb, 0)
+ }
+ }
+
+ /**
+ * Detect if we are in IE9...
+ *
+ * @type {Boolean}
+ */
+
+ exports.isIE9 =
+ inBrowser &&
+ navigator.userAgent.indexOf('MSIE 9.0') > 0
+
+ /**
+ * Sniff transition/animation events
+ */
+
+ if (inBrowser && !exports.isIE9) {
+ var isWebkitTrans =
+ window.ontransitionend === undefined &&
+ window.onwebkittransitionend !== undefined
+ var isWebkitAnim =
+ window.onanimationend === undefined &&
+ window.onwebkitanimationend !== undefined
+ exports.transitionProp = isWebkitTrans
+ ? 'WebkitTransition'
+ : 'transition'
+ exports.transitionEndEvent = isWebkitTrans
+ ? 'webkitTransitionEnd'
+ : 'transitionend'
+ exports.animationProp = isWebkitAnim
+ ? 'WebkitAnimation'
+ : 'animation'
+ exports.animationEndEvent = isWebkitAnim
+ ? 'webkitAnimationEnd'
+ : 'animationend'
+ }
+
+/***/ },
+/* 16 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var config = __webpack_require__(20)
+
+ /**
+ * Check if a node is in the document.
+ *
+ * @param {Node} node
+ * @return {Boolean}
+ */
+
+ var doc =
+ typeof document !== 'undefined' &&
+ document.documentElement
+
+ exports.inDoc = function (node) {
+ return doc && doc.contains(node)
+ }
+
+ /**
+ * Extract an attribute from a node.
+ *
+ * @param {Node} node
+ * @param {String} attr
+ */
+
+ exports.attr = function (node, attr) {
+ attr = config.prefix + attr
+ var val = node.getAttribute(attr)
+ if (val !== null) {
+ node.removeAttribute(attr)
+ }
+ return val
+ }
+
+ /**
+ * Insert el before target
+ *
+ * @param {Element} el
+ * @param {Element} target
+ */
+
+ exports.before = function (el, target) {
+ target.parentNode.insertBefore(el, target)
+ }
+
+ /**
+ * Insert el after target
+ *
+ * @param {Element} el
+ * @param {Element} target
+ */
+
+ exports.after = function (el, target) {
+ if (target.nextSibling) {
+ exports.before(el, target.nextSibling)
+ } else {
+ target.parentNode.appendChild(el)
+ }
+ }
+
+ /**
+ * Remove el from DOM
+ *
+ * @param {Element} el
+ */
+
+ exports.remove = function (el) {
+ el.parentNode.removeChild(el)
+ }
+
+ /**
+ * Prepend el to target
+ *
+ * @param {Element} el
+ * @param {Element} target
+ */
+
+ exports.prepend = function (el, target) {
+ if (target.firstChild) {
+ exports.before(el, target.firstChild)
+ } else {
+ target.appendChild(el)
+ }
+ }
+
+ /**
+ * Replace target with el
+ *
+ * @param {Element} target
+ * @param {Element} el
+ */
+
+ exports.replace = function (target, el) {
+ var parent = target.parentNode
+ if (parent) {
+ parent.replaceChild(el, target)
+ }
+ }
+
+ /**
+ * Copy attributes from one element to another.
+ *
+ * @param {Element} from
+ * @param {Element} to
+ */
+
+ exports.copyAttributes = function (from, to) {
+ if (from.hasAttributes()) {
+ var attrs = from.attributes
+ for (var i = 0, l = attrs.length; i < l; i++) {
+ var attr = attrs[i]
+ to.setAttribute(attr.name, attr.value)
+ }
+ }
+ }
+
+ /**
+ * Add event listener shorthand.
+ *
+ * @param {Element} el
+ * @param {String} event
+ * @param {Function} cb
+ */
+
+ exports.on = function (el, event, cb) {
+ el.addEventListener(event, cb)
+ }
+
+ /**
+ * Remove event listener shorthand.
+ *
+ * @param {Element} el
+ * @param {String} event
+ * @param {Function} cb
+ */
+
+ exports.off = function (el, event, cb) {
+ el.removeEventListener(event, cb)
+ }
+
+ /**
+ * Add class with compatibility for IE & SVG
+ *
+ * @param {Element} el
+ * @param {Strong} cls
+ */
+
+ exports.addClass = function (el, cls) {
+ if (el.classList) {
+ el.classList.add(cls)
+ } else {
+ var cur = ' ' + (el.getAttribute('class') || '') + ' '
+ if (cur.indexOf(' ' + cls + ' ') < 0) {
+ el.setAttribute('class', (cur + cls).trim())
+ }
+ }
+ }
+
+ /**
+ * Remove class with compatibility for IE & SVG
+ *
+ * @param {Element} el
+ * @param {Strong} cls
+ */
+
+ exports.removeClass = function (el, cls) {
+ if (el.classList) {
+ el.classList.remove(cls)
+ } else {
+ var cur = ' ' + (el.getAttribute('class') || '') + ' '
+ var tar = ' ' + cls + ' '
+ while (cur.indexOf(tar) >= 0) {
+ cur = cur.replace(tar, ' ')
+ }
+ el.setAttribute('class', cur.trim())
+ }
+ }
+
+/***/ },
+/* 17 */
+/***/ function(module, exports, __webpack_require__) {
+
+ var _ = __webpack_require__(18)
+
+ /**
+ * Resolve read & write filters for a vm instance. The
+ * filters descriptor Array comes from the directive parser.
+ *
+ * This is extracted into its own utility so it can
+ * be used in multiple scenarios.
+ *
+ * @param {Vue} vm
+ * @param {Array