Skip to content

Commit

Permalink
[release] 0.12.4
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Jun 25, 2015
1 parent 25eee91 commit e614d9c
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 56 deletions.
2 changes: 1 addition & 1 deletion component.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vue",
"version": "0.12.3",
"version": "0.12.4",
"main": "src/vue.js",
"author": "Evan You <[email protected]>",
"description": "Simple, Fast & Composable MVVM for building interative interfaces",
Expand Down
99 changes: 49 additions & 50 deletions dist/vue.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Vue.js v0.12.3
* Vue.js v0.12.4
* (c) 2015 Evan You
* Released under the MIT License.
*/
Expand Down Expand Up @@ -375,10 +375,12 @@ return /******/ (function(modules) { // webpackBootstrap
*/

_assetTypes: [
'component',
'directive',
'elementDirective',
'filter',
'transition'
'transition',
'partial'
],

/**
Expand Down Expand Up @@ -801,8 +803,27 @@ return /******/ (function(modules) { // webpackBootstrap
/* 6 */
/***/ function(module, exports, __webpack_require__) {

var _ = __webpack_require__(1)
var config = __webpack_require__(3)

/**
* Query an element selector if it's not an element already.
*
* @param {String|Element} el
* @return {Element}
*/

exports.query = function (el) {
if (typeof el === 'string') {
var selector = el
el = document.querySelector(el)
if (!el) {
_.warn('Cannot find element: ' + selector)
}
}
return el
}

/**
* Check if a node is in the document.
* Note: document.documentElement.contains should work here
Expand Down Expand Up @@ -1447,7 +1468,9 @@ return /******/ (function(modules) { // webpackBootstrap
Sub.extend = Super.extend
// create asset registers, so extended classes
// can have their private assets too.
createAssetRegisters(Sub)
config._assetTypes.forEach(function (type) {
Sub[type] = Super[type]
})
return Sub
}

Expand Down Expand Up @@ -1486,51 +1509,29 @@ return /******/ (function(modules) { // webpackBootstrap
}

/**
* Define asset registration methods on a constructor.
* Create asset registration methods with the following
* signature:
*
* @param {Function} Constructor
* @param {String} id
* @param {*} definition
*/

function createAssetRegisters (Constructor) {

/* Asset registration methods share the same signature:
*
* @param {String} id
* @param {*} definition
*/

config._assetTypes.forEach(function (type) {
Constructor[type] = function (id, definition) {
if (!definition) {
return this.options[type + 's'][id]
} else {
this.options[type + 's'][id] = definition
}
}
})

/**
* Component registration needs to automatically invoke
* Vue.extend on object values.
*
* @param {String} id
* @param {Object|Function} definition
*/

Constructor.component = function (id, definition) {
config._assetTypes.forEach(function (type) {
exports[type] = function (id, definition) {
if (!definition) {
return this.options.components[id]
return this.options[type + 's'][id]
} else {
if (_.isPlainObject(definition)) {
if (
type === 'component' &&
_.isPlainObject(definition)
) {
definition.name = id
definition = _.Vue.extend(definition)
}
this.options.components[id] = definition
this.options[type + 's'][id] = definition
}
}
}

createAssetRegisters(exports)
})


/***/ },
Expand Down Expand Up @@ -2109,6 +2110,7 @@ return /******/ (function(modules) { // webpackBootstrap

function checkElementDirectives (el, options) {
var tag = el.tagName.toLowerCase()
if (_.commonTagRE.test(tag)) return
var def = resolveAsset(options, 'elementDirectives', tag)
if (def) {
return makeTerminalNodeLinkFn(el, tag, '', options, def)
Expand Down Expand Up @@ -8105,17 +8107,19 @@ return /******/ (function(modules) { // webpackBootstrap
var options = this.$options
var el = options.el
var props = options.props
this._propsUnlinkFn = el && props
? compiler.compileAndLinkProps(
this, el, props
)
: null
if (props && !el) {
_.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 && props
? compiler.compileAndLinkProps(
this, el, props
)
: null
}

/**
Expand Down Expand Up @@ -9500,15 +9504,9 @@ return /******/ (function(modules) { // webpackBootstrap
_.warn('$mount() should be called only once.')
return
}
el = _.query(el)
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
Expand Down Expand Up @@ -9556,6 +9554,7 @@ return /******/ (function(modules) { // webpackBootstrap
return compiler.compile(el, this.$options, true, host)(this, el)
}


/***/ }
/******/ ])
});
Expand Down
8 changes: 4 additions & 4 deletions dist/vue.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vue",
"version": "0.12.3",
"version": "0.12.4",
"author": "Evan You <[email protected]>",
"license": "MIT",
"description": "Simple, Fast & Composable MVVM for building interative interfaces",
Expand Down

0 comments on commit e614d9c

Please sign in to comment.