vuejs-rails 0.11.3 → 0.11.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 66d8defef93f3e001e9b7d8ed4eb6cc6fdc219e3
4
- data.tar.gz: 2fda4cc6667f294fa77df8d205c3846d8edd18a5
3
+ metadata.gz: 56e18cf43780fa077cc2a652db271e0b6809a12b
4
+ data.tar.gz: 2605d945a3cd6dfd77f30085d19f290e34f0b4e1
5
5
  SHA512:
6
- metadata.gz: aec3a6c89feaa1f69eea1e938f52834736b01b051352402cd0b294842491e5ae91e1d6bb329674e6f0d566333f702bc94f8cea6e983e589abd4fc361131abc1d
7
- data.tar.gz: 9ef2f6d80e2b61d45a336a6660a506e20b28f090a6af542a4852f73d3e9dbf742297ccec5a585d84bd02bdba682bec26ac6352e3ad329fae9d217fa3a4cfb553
6
+ metadata.gz: 2cb6ab9f67900842a1597863e78aad8b39fb14ddc0815d659dcdb2b51b6628924186fc06271a3aaf2eaa7e0965ec572d3f7ecf062e67ec25d4f20c2fd3768d0c
7
+ data.tar.gz: ca8943251c78b61a40dd7c884504e2de5b271cb5685a3dccf916a174fde9bc62e5e784da7c03787c52dfd789401bb815f2fef4554f1b394f711f125b618103e2
@@ -1,5 +1,5 @@
1
1
  module Vue
2
2
  module Rails
3
- VERSION = "0.11.3"
3
+ VERSION = "0.11.4"
4
4
  end
5
5
  end
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Vue.js v0.11.3
2
+ * Vue.js v0.11.4
3
3
  * (c) 2014 Evan You
4
4
  * Released under the MIT License.
5
5
  */
@@ -174,16 +174,16 @@ return /******/ (function(modules) { // webpackBootstrap
174
174
  exports.config = __webpack_require__(20)
175
175
 
176
176
  exports.compiler = {
177
- compile: __webpack_require__(41),
178
- transclude: __webpack_require__(42)
177
+ compile: __webpack_require__(42),
178
+ transclude: __webpack_require__(43)
179
179
  }
180
180
 
181
181
  exports.parsers = {
182
- path: __webpack_require__(43),
183
- text: __webpack_require__(44),
184
- template: __webpack_require__(45),
185
- directive: __webpack_require__(46),
186
- expression: __webpack_require__(47)
182
+ path: __webpack_require__(44),
183
+ text: __webpack_require__(45),
184
+ template: __webpack_require__(46),
185
+ directive: __webpack_require__(47),
186
+ expression: __webpack_require__(48)
187
187
  }
188
188
 
189
189
  /**
@@ -315,10 +315,10 @@ return /******/ (function(modules) { // webpackBootstrap
315
315
 
316
316
  var _ = __webpack_require__(1)
317
317
  var Watcher = __webpack_require__(21)
318
- var Path = __webpack_require__(43)
319
- var textParser = __webpack_require__(44)
320
- var dirParser = __webpack_require__(46)
321
- var expParser = __webpack_require__(47)
318
+ var Path = __webpack_require__(44)
319
+ var textParser = __webpack_require__(45)
320
+ var dirParser = __webpack_require__(47)
321
+ var expParser = __webpack_require__(48)
322
322
  var filterRE = /[^|]\|[^|]/
323
323
 
324
324
  /**
@@ -392,7 +392,10 @@ return /******/ (function(modules) { // webpackBootstrap
392
392
  }
393
393
  if (!watcher) {
394
394
  watcher = vm._userWatchers[key] =
395
- new Watcher(vm, exp, wrappedCb, null, false, deep)
395
+ new Watcher(vm, exp, wrappedCb, {
396
+ deep: deep,
397
+ user: true
398
+ })
396
399
  } else {
397
400
  watcher.addCb(wrappedCb)
398
401
  }
@@ -480,7 +483,7 @@ return /******/ (function(modules) { // webpackBootstrap
480
483
  /***/ function(module, exports, __webpack_require__) {
481
484
 
482
485
  var _ = __webpack_require__(1)
483
- var transition = __webpack_require__(48)
486
+ var transition = __webpack_require__(49)
484
487
 
485
488
  /**
486
489
  * Append instance to target
@@ -935,7 +938,7 @@ return /******/ (function(modules) { // webpackBootstrap
935
938
  /***/ function(module, exports, __webpack_require__) {
936
939
 
937
940
  var _ = __webpack_require__(1)
938
- var compile = __webpack_require__(41)
941
+ var compile = __webpack_require__(42)
939
942
 
940
943
  /**
941
944
  * Set instance target element and kick off the compilation
@@ -1026,13 +1029,16 @@ return /******/ (function(modules) { // webpackBootstrap
1026
1029
 
1027
1030
  // event listener directives
1028
1031
  exports.on = __webpack_require__(33)
1029
- exports.model = __webpack_require__(49)
1032
+ exports.model = __webpack_require__(50)
1030
1033
 
1031
1034
  // child vm directives
1032
1035
  exports.component = __webpack_require__(34)
1033
1036
  exports.repeat = __webpack_require__(35)
1034
1037
  exports['if'] = __webpack_require__(36)
1038
+
1039
+ // child vm communication directives
1035
1040
  exports['with'] = __webpack_require__(37)
1041
+ exports.events = __webpack_require__(38)
1036
1042
 
1037
1043
  /***/ },
1038
1044
  /* 9 */
@@ -1172,7 +1178,7 @@ return /******/ (function(modules) { // webpackBootstrap
1172
1178
  * Install special array filters
1173
1179
  */
1174
1180
 
1175
- _.extend(exports, __webpack_require__(38))
1181
+ _.extend(exports, __webpack_require__(39))
1176
1182
 
1177
1183
  /***/ },
1178
1184
  /* 10 */
@@ -1387,8 +1393,8 @@ return /******/ (function(modules) { // webpackBootstrap
1387
1393
  /***/ function(module, exports, __webpack_require__) {
1388
1394
 
1389
1395
  var _ = __webpack_require__(1)
1390
- var Observer = __webpack_require__(50)
1391
- var Dep = __webpack_require__(39)
1396
+ var Observer = __webpack_require__(51)
1397
+ var Dep = __webpack_require__(40)
1392
1398
 
1393
1399
  /**
1394
1400
  * Setup the scope of an instance, which contains:
@@ -1609,9 +1615,9 @@ return /******/ (function(modules) { // webpackBootstrap
1609
1615
  /***/ function(module, exports, __webpack_require__) {
1610
1616
 
1611
1617
  var _ = __webpack_require__(1)
1612
- var Directive = __webpack_require__(40)
1613
- var compile = __webpack_require__(41)
1614
- var transclude = __webpack_require__(42)
1618
+ var Directive = __webpack_require__(41)
1619
+ var compile = __webpack_require__(42)
1620
+ var transclude = __webpack_require__(43)
1615
1621
 
1616
1622
  /**
1617
1623
  * Transclude, compile and link element.
@@ -1656,13 +1662,14 @@ return /******/ (function(modules) { // webpackBootstrap
1656
1662
  }
1657
1663
  // tranclude, this possibly replaces original
1658
1664
  el = transclude(el, options)
1665
+ this._initElement(el)
1659
1666
  // now call the container linker on the resolved el
1660
1667
  this._containerUnlinkFn = containerLinkFn(parent, el)
1661
1668
  } else {
1662
1669
  // simply transclude
1663
1670
  el = transclude(el, options)
1671
+ this._initElement(el)
1664
1672
  }
1665
- this._initElement(el)
1666
1673
  var linkFn = compile(el, options)
1667
1674
  linkFn(this, el)
1668
1675
  if (options.replace) {
@@ -2371,8 +2378,14 @@ return /******/ (function(modules) { // webpackBootstrap
2371
2378
  exports.warn = function (msg) {
2372
2379
  if (hasConsole && !config.silent) {
2373
2380
  console.warn('[Vue warn]: ' + msg)
2374
- if (config.debug && console.trace) {
2375
- console.trace()
2381
+ /* istanbul ignore if */
2382
+ if (config.debug) {
2383
+ /* jshint debug: true */
2384
+ debugger
2385
+ } else {
2386
+ console.log(
2387
+ 'Set `Vue.config.debug = true` to enable debug mode.'
2388
+ )
2376
2389
  }
2377
2390
  }
2378
2391
  }
@@ -2738,11 +2751,9 @@ return /******/ (function(modules) { // webpackBootstrap
2738
2751
 
2739
2752
  var _ = __webpack_require__(1)
2740
2753
  var config = __webpack_require__(20)
2741
- var Observer = __webpack_require__(50)
2742
- var expParser = __webpack_require__(47)
2743
- var Batcher = __webpack_require__(51)
2744
-
2745
- var batcher = new Batcher()
2754
+ var Observer = __webpack_require__(51)
2755
+ var expParser = __webpack_require__(48)
2756
+ var batcher = __webpack_require__(52)
2746
2757
  var uid = 0
2747
2758
 
2748
2759
  /**
@@ -2753,29 +2764,35 @@ return /******/ (function(modules) { // webpackBootstrap
2753
2764
  * @param {Vue} vm
2754
2765
  * @param {String} expression
2755
2766
  * @param {Function} cb
2756
- * @param {Array} [filters]
2757
- * @param {Boolean} [needSet]
2758
- * @param {Boolean} [deep]
2767
+ * @param {Object} options
2768
+ * - {Array} filters
2769
+ * - {Boolean} twoWay
2770
+ * - {Boolean} deep
2771
+ * - {Boolean} user
2759
2772
  * @constructor
2760
2773
  */
2761
2774
 
2762
- function Watcher (vm, expression, cb, filters, needSet, deep) {
2775
+ function Watcher (vm, expression, cb, options) {
2763
2776
  this.vm = vm
2764
2777
  vm._watcherList.push(this)
2765
2778
  this.expression = expression
2766
2779
  this.cbs = [cb]
2767
2780
  this.id = ++uid // uid for batching
2768
2781
  this.active = true
2769
- this.deep = deep
2782
+ options = options || {}
2783
+ this.deep = options.deep
2784
+ this.user = options.user
2770
2785
  this.deps = Object.create(null)
2771
2786
  // setup filters if any.
2772
2787
  // We delegate directive filters here to the watcher
2773
2788
  // because they need to be included in the dependency
2774
2789
  // collection process.
2775
- this.readFilters = filters && filters.read
2776
- this.writeFilters = filters && filters.write
2790
+ if (options.filters) {
2791
+ this.readFilters = options.filters.read
2792
+ this.writeFilters = options.filters.write
2793
+ }
2777
2794
  // parse expression for getter/setter
2778
- var res = expParser.parse(expression, needSet)
2795
+ var res = expParser.parse(expression, options.twoWay)
2779
2796
  this.getter = res.get
2780
2797
  this.setter = res.set
2781
2798
  this.value = this.get()
@@ -2811,7 +2828,10 @@ return /******/ (function(modules) { // webpackBootstrap
2811
2828
  try {
2812
2829
  value = this.getter.call(vm, vm)
2813
2830
  } catch (e) {
2814
- _.warn(e)
2831
+ _.warn(
2832
+ 'Error when evaluating expression "' +
2833
+ this.expression + '":\n ' + e
2834
+ )
2815
2835
  }
2816
2836
  // "touch" every property so they are all tracked as
2817
2837
  // dependencies for deep watching
@@ -2836,7 +2856,12 @@ return /******/ (function(modules) { // webpackBootstrap
2836
2856
  )
2837
2857
  try {
2838
2858
  this.setter.call(vm, vm, value)
2839
- } catch (e) {}
2859
+ } catch (e) {
2860
+ _.warn(
2861
+ 'Error when evaluating setter "' +
2862
+ this.expression + '":\n ' + e
2863
+ )
2864
+ }
2840
2865
  }
2841
2866
 
2842
2867
  /**
@@ -2868,10 +2893,10 @@ return /******/ (function(modules) { // webpackBootstrap
2868
2893
  */
2869
2894
 
2870
2895
  p.update = function () {
2871
- if (config.async) {
2872
- batcher.push(this)
2873
- } else {
2896
+ if (!config.async || config.debug) {
2874
2897
  this.run()
2898
+ } else {
2899
+ batcher.push(this)
2875
2900
  }
2876
2901
  }
2877
2902
 
@@ -3002,7 +3027,7 @@ return /******/ (function(modules) { // webpackBootstrap
3002
3027
  /***/ function(module, exports, __webpack_require__) {
3003
3028
 
3004
3029
  var _ = __webpack_require__(1)
3005
- var templateParser = __webpack_require__(45)
3030
+ var templateParser = __webpack_require__(46)
3006
3031
 
3007
3032
  module.exports = {
3008
3033
 
@@ -3081,7 +3106,7 @@ return /******/ (function(modules) { // webpackBootstrap
3081
3106
  /* 25 */
3082
3107
  /***/ function(module, exports, __webpack_require__) {
3083
3108
 
3084
- var transition = __webpack_require__(48)
3109
+ var transition = __webpack_require__(49)
3085
3110
 
3086
3111
  module.exports = function (value) {
3087
3112
  var el = this.el
@@ -3142,19 +3167,20 @@ return /******/ (function(modules) { // webpackBootstrap
3142
3167
  isLiteral: true,
3143
3168
 
3144
3169
  bind: function () {
3145
- if (this.el !== this.vm.$el) {
3170
+ var child = this.el.__vue__
3171
+ if (!child || this.vm !== child.$parent) {
3146
3172
  _.warn(
3147
- 'v-ref should only be used on instance root nodes.'
3173
+ 'v-ref should only be used on a child component ' +
3174
+ 'from the parent template.'
3148
3175
  )
3149
3176
  return
3150
3177
  }
3151
- this.owner = this.vm.$parent
3152
- this.owner.$[this.expression] = this.vm
3178
+ this.vm.$[this.expression] = child
3153
3179
  },
3154
3180
 
3155
3181
  unbind: function () {
3156
- if (this.owner.$[this.expression] === this.vm) {
3157
- delete this.owner.$[this.expression]
3182
+ if (this.vm.$[this.expression] === this.el.__vue__) {
3183
+ delete this.vm.$[this.expression]
3158
3184
  }
3159
3185
  }
3160
3186
 
@@ -3181,26 +3207,33 @@ return /******/ (function(modules) { // webpackBootstrap
3181
3207
  /* 30 */
3182
3208
  /***/ function(module, exports, __webpack_require__) {
3183
3209
 
3210
+ var _ = __webpack_require__(1)
3184
3211
  var prefixes = ['-webkit-', '-moz-', '-ms-']
3212
+ var camelPrefixes = ['Webkit', 'Moz', 'ms']
3185
3213
  var importantRE = /!important;?$/
3214
+ var camelRE = /([a-z])([A-Z])/g
3215
+ var testEl = null
3216
+ var propCache = {}
3186
3217
 
3187
3218
  module.exports = {
3188
3219
 
3189
3220
  deep: true,
3190
3221
 
3191
- bind: function () {
3192
- var prop = this.arg
3193
- if (!prop) return
3194
- this.prop = prop
3195
- },
3196
-
3197
3222
  update: function (value) {
3198
- if (this.prop) {
3199
- this.setCssProperty(this.prop, value)
3223
+ if (this.arg) {
3224
+ this.setProp(this.arg, value)
3200
3225
  } else {
3201
3226
  if (typeof value === 'object') {
3227
+ // cache object styles so that only changed props
3228
+ // are actually updated.
3229
+ if (!this.cache) this.cache = {}
3202
3230
  for (var prop in value) {
3203
- this.setCssProperty(prop, value[prop])
3231
+ this.setProp(prop, value[prop])
3232
+ /* jshint eqeqeq: false */
3233
+ if (value[prop] != this.cache[prop]) {
3234
+ this.cache[prop] = value[prop]
3235
+ this.setProp(prop, value[prop])
3236
+ }
3204
3237
  }
3205
3238
  } else {
3206
3239
  this.el.style.cssText = value
@@ -3208,44 +3241,79 @@ return /******/ (function(modules) { // webpackBootstrap
3208
3241
  }
3209
3242
  },
3210
3243
 
3211
- setCssProperty: function (prop, value) {
3212
- var prefixed = false
3213
- if (prop.charAt(0) === '$') {
3214
- // properties that start with $ will be auto-prefixed
3215
- prop = prop.slice(1)
3216
- prefixed = true
3217
- }
3244
+ setProp: function (prop, value) {
3245
+ prop = normalize(prop)
3246
+ if (!prop) return // unsupported prop
3218
3247
  // cast possible numbers/booleans into strings
3219
- if (value != null) {
3220
- value += ''
3221
- }
3222
- var isImportant = importantRE.test(value)
3223
- ? 'important'
3224
- : ''
3225
- if (isImportant) {
3226
- value = value.replace(importantRE, '').trim()
3227
- }
3228
- this.el.style.setProperty(prop, value, isImportant)
3229
- if (prefixed) {
3230
- var i = prefixes.length
3231
- while (i--) {
3232
- this.el.style.setProperty(
3233
- prefixes[i] + prop,
3234
- value,
3235
- isImportant
3236
- )
3248
+ if (value != null) value += ''
3249
+ if (value) {
3250
+ var isImportant = importantRE.test(value)
3251
+ ? 'important'
3252
+ : ''
3253
+ if (isImportant) {
3254
+ value = value.replace(importantRE, '').trim()
3237
3255
  }
3256
+ this.el.style.setProperty(prop, value, isImportant)
3257
+ } else {
3258
+ this.el.style.removeProperty(prop)
3238
3259
  }
3239
3260
  }
3240
3261
 
3241
3262
  }
3242
3263
 
3264
+ /**
3265
+ * Normalize a CSS property name.
3266
+ * - cache result
3267
+ * - auto prefix
3268
+ * - camelCase -> dash-case
3269
+ *
3270
+ * @param {String} prop
3271
+ * @return {String}
3272
+ */
3273
+
3274
+ function normalize (prop) {
3275
+ if (propCache[prop]) {
3276
+ return propCache[prop]
3277
+ }
3278
+ var res = prefix(prop)
3279
+ propCache[prop] = propCache[res] = res
3280
+ return res
3281
+ }
3282
+
3283
+ /**
3284
+ * Auto detect the appropriate prefix for a CSS property.
3285
+ * https://gist.github.com/paulirish/523692
3286
+ *
3287
+ * @param {String} prop
3288
+ * @return {String}
3289
+ */
3290
+
3291
+ function prefix (prop) {
3292
+ prop = prop.replace(camelRE, '$1-$2').toLowerCase()
3293
+ var camel = _.camelize(prop)
3294
+ var upper = camel.charAt(0).toUpperCase() + camel.slice(1)
3295
+ if (!testEl) {
3296
+ testEl = document.createElement('div')
3297
+ }
3298
+ if (camel in testEl.style) {
3299
+ return prop
3300
+ }
3301
+ var i = prefixes.length
3302
+ var prefixed
3303
+ while (i--) {
3304
+ prefixed = camelPrefixes[i] + upper
3305
+ if (prefixed in testEl.style) {
3306
+ return prefixes[i] + prop
3307
+ }
3308
+ }
3309
+ }
3310
+
3243
3311
  /***/ },
3244
3312
  /* 31 */
3245
3313
  /***/ function(module, exports, __webpack_require__) {
3246
3314
 
3247
3315
  var _ = __webpack_require__(1)
3248
- var templateParser = __webpack_require__(45)
3316
+ var templateParser = __webpack_require__(46)
3249
3317
  var vIf = __webpack_require__(36)
3250
3318
 
3251
3319
  module.exports = {
@@ -3375,7 +3443,7 @@ return /******/ (function(modules) { // webpackBootstrap
3375
3443
  /***/ function(module, exports, __webpack_require__) {
3376
3444
 
3377
3445
  var _ = __webpack_require__(1)
3378
- var templateParser = __webpack_require__(45)
3446
+ var templateParser = __webpack_require__(46)
3379
3447
 
3380
3448
  module.exports = {
3381
3449
 
@@ -3577,11 +3645,11 @@ return /******/ (function(modules) { // webpackBootstrap
3577
3645
 
3578
3646
  var _ = __webpack_require__(1)
3579
3647
  var isObject = _.isObject
3580
- var textParser = __webpack_require__(44)
3581
- var expParser = __webpack_require__(47)
3582
- var templateParser = __webpack_require__(45)
3583
- var compile = __webpack_require__(41)
3584
- var transclude = __webpack_require__(42)
3648
+ var textParser = __webpack_require__(45)
3649
+ var expParser = __webpack_require__(48)
3650
+ var templateParser = __webpack_require__(46)
3651
+ var compile = __webpack_require__(42)
3652
+ var transclude = __webpack_require__(43)
3585
3653
  var mergeOptions = __webpack_require__(19)
3586
3654
  var uid = 0
3587
3655
 
@@ -3689,7 +3757,7 @@ return /******/ (function(modules) { // webpackBootstrap
3689
3757
  $parent: this.vm
3690
3758
  })
3691
3759
  this.template = transclude(this.template, merged)
3692
- this._linkFn = compile(this.template, merged)
3760
+ this._linkFn = compile(this.template, merged, false, true)
3693
3761
  }
3694
3762
  } else {
3695
3763
  // to be resolved later
@@ -4084,9 +4152,9 @@ return /******/ (function(modules) { // webpackBootstrap
4084
4152
  /***/ function(module, exports, __webpack_require__) {
4085
4153
 
4086
4154
  var _ = __webpack_require__(1)
4087
- var compile = __webpack_require__(41)
4088
- var templateParser = __webpack_require__(45)
4089
- var transition = __webpack_require__(48)
4155
+ var compile = __webpack_require__(42)
4156
+ var templateParser = __webpack_require__(46)
4157
+ var transition = __webpack_require__(49)
4090
4158
 
4091
4159
  module.exports = {
4092
4160
 
@@ -4228,7 +4296,39 @@ return /******/ (function(modules) { // webpackBootstrap
4228
4296
  /***/ function(module, exports, __webpack_require__) {
4229
4297
 
4230
4298
  var _ = __webpack_require__(1)
4231
- var Path = __webpack_require__(43)
4299
+
4300
+ module.exports = {
4301
+
4302
+ bind: function () {
4303
+ var child = this.el.__vue__
4304
+ if (!child || this.vm !== child.$parent) {
4305
+ _.warn(
4306
+ '`v-events` should only be used on a child component ' +
4307
+ 'from the parent template.'
4308
+ )
4309
+ return
4310
+ }
4311
+ var method = this.vm[this.expression]
4312
+ if (!method) {
4313
+ _.warn(
4314
+ '`v-events` cannot find method "' + this.expression +
4315
+ '" on the parent instance.'
4316
+ )
4317
+ }
4318
+ child.$on(this.arg, method)
4319
+ }
4320
+
4321
+ // when child is destroyed, all events are turned off,
4322
+ // so no need for unbind here.
4323
+
4324
+ }
4325
+
4326
+ /***/ },
4327
+ /* 39 */
4328
+ /***/ function(module, exports, __webpack_require__) {
4329
+
4330
+ var _ = __webpack_require__(1)
4331
+ var Path = __webpack_require__(44)
4232
4332
 
4233
4333
  /**
4234
4334
  * Filter filter for v-repeat
@@ -4316,7 +4416,7 @@ return /******/ (function(modules) { // webpackBootstrap
4316
4416
  }
4317
4417
 
4318
4418
  /***/ },
4319
- /* 39 */
4419
+ /* 40 */
4320
4420
  /***/ function(module, exports, __webpack_require__) {
4321
4421
 
4322
4422
  var uid = 0
@@ -4371,14 +4471,14 @@ return /******/ (function(modules) { // webpackBootstrap
4371
4471
  module.exports = Dep
4372
4472
 
4373
4473
  /***/ },
4374
- /* 40 */
4474
+ /* 41 */
4375
4475
  /***/ function(module, exports, __webpack_require__) {
4376
4476
 
4377
4477
  var _ = __webpack_require__(1)
4378
4478
  var config = __webpack_require__(20)
4379
4479
  var Watcher = __webpack_require__(21)
4380
- var textParser = __webpack_require__(44)
4381
- var expParser = __webpack_require__(47)
4480
+ var textParser = __webpack_require__(45)
4481
+ var expParser = __webpack_require__(48)
4382
4482
 
4383
4483
  /**
4384
4484
  * A directive links a DOM element with a piece of data,
@@ -4461,9 +4561,11 @@ return /******/ (function(modules) { // webpackBootstrap
4461
4561
  this.vm,
4462
4562
  this._watcherExp,
4463
4563
  update, // callback
4464
- this.filters,
4465
- this.twoWay, // need setter,
4466
- this.deep
4564
+ {
4565
+ filters: this.filters,
4566
+ twoWay: this.twoWay,
4567
+ deep: this.deep
4568
+ }
4467
4569
  )
4468
4570
  } else {
4469
4571
  watcher.addCb(update)
@@ -4595,14 +4697,14 @@ return /******/ (function(modules) { // webpackBootstrap
4595
4697
  module.exports = Directive
4596
4698
 
4597
4699
  /***/ },
4598
- /* 41 */
4700
+ /* 42 */
4599
4701
  /***/ function(module, exports, __webpack_require__) {
4600
4702
 
4601
4703
  var _ = __webpack_require__(1)
4602
4704
  var config = __webpack_require__(20)
4603
- var textParser = __webpack_require__(44)
4604
- var dirParser = __webpack_require__(46)
4605
- var templateParser = __webpack_require__(45)
4705
+ var textParser = __webpack_require__(45)
4706
+ var dirParser = __webpack_require__(47)
4707
+ var templateParser = __webpack_require__(46)
4606
4708
 
4607
4709
  /**
4608
4710
  * Compile a template and return a reusable composite link
@@ -5072,7 +5174,6 @@ return /******/ (function(modules) { // webpackBootstrap
5072
5174
  dirName = attrName.slice(config.prefix.length)
5073
5175
  if (asParent &&
5074
5176
  (dirName === 'with' ||
5075
- dirName === 'ref' ||
5076
5177
  dirName === 'component')) {
5077
5178
  continue
5078
5179
  }
@@ -5154,11 +5255,11 @@ return /******/ (function(modules) { // webpackBootstrap
5154
5255
  }
5155
5256
 
5156
5257
  /***/ },
5157
- /* 42 */
5258
+ /* 43 */
5158
5259
  /***/ function(module, exports, __webpack_require__) {
5159
5260
 
5160
5261
  var _ = __webpack_require__(1)
5161
- var templateParser = __webpack_require__(45)
5262
+ var templateParser = __webpack_require__(46)
5162
5263
 
5163
5264
  /**
5164
5265
  * Process an element or a DocumentFragment based on a
@@ -5305,11 +5406,11 @@ return /******/ (function(modules) { // webpackBootstrap
5305
5406
  }
5306
5407
 
5307
5408
  /***/ },
5308
- /* 43 */
5409
+ /* 44 */
5309
5410
  /***/ function(module, exports, __webpack_require__) {
5310
5411
 
5311
5412
  var _ = __webpack_require__(1)
5312
- var Cache = __webpack_require__(52)
5413
+ var Cache = __webpack_require__(53)
5313
5414
  var pathCache = new Cache(1000)
5314
5415
  var identRE = /^[$_a-zA-Z]+[\w$]*$/
5315
5416
 
@@ -5610,12 +5711,12 @@ return /******/ (function(modules) { // webpackBootstrap
5610
5711
  }
5611
5712
 
5612
5713
  /***/ },
5613
- /* 44 */
5714
+ /* 45 */
5614
5715
  /***/ function(module, exports, __webpack_require__) {
5615
5716
 
5616
- var Cache = __webpack_require__(52)
5717
+ var Cache = __webpack_require__(53)
5617
5718
  var config = __webpack_require__(20)
5618
- var dirParser = __webpack_require__(46)
5719
+ var dirParser = __webpack_require__(47)
5619
5720
  var regexEscapeRE = /[-.*+?^${}()|[\]\/\\]/g
5620
5721
  var cache, tagRE, htmlRE, firstChar, lastChar
5621
5722
 
@@ -5793,11 +5894,11 @@ return /******/ (function(modules) { // webpackBootstrap
5793
5894
  }
5794
5895
 
5795
5896
  /***/ },
5796
- /* 45 */
5897
+ /* 46 */
5797
5898
  /***/ function(module, exports, __webpack_require__) {
5798
5899
 
5799
5900
  var _ = __webpack_require__(1)
5800
- var Cache = __webpack_require__(52)
5901
+ var Cache = __webpack_require__(53)
5801
5902
  var templateCache = new Cache(1000)
5802
5903
  var idSelectorCache = new Cache(1000)
5803
5904
 
@@ -5854,7 +5955,8 @@ return /******/ (function(modules) { // webpackBootstrap
5854
5955
  '</svg>'
5855
5956
  ]
5856
5957
 
5857
- var TAG_RE = /<([\w:]+)/
5958
+ var tagRE = /<([\w:]+)/
5959
+ var entityRE = /&\w+;/
5858
5960
 
5859
5961
  /**
5860
5962
  * Convert a string template to a DocumentFragment.
@@ -5873,16 +5975,17 @@ return /******/ (function(modules) { // webpackBootstrap
5873
5975
  }
5874
5976
 
5875
5977
  var frag = document.createDocumentFragment()
5876
- var tagMatch = TAG_RE.exec(templateString)
5978
+ var tagMatch = templateString.match(tagRE)
5979
+ var entityMatch = entityRE.test(templateString)
5877
5980
 
5878
- if (!tagMatch) {
5981
+ if (!tagMatch && !entityMatch) {
5879
5982
  // text only, return a single text node.
5880
5983
  frag.appendChild(
5881
5984
  document.createTextNode(templateString)
5882
5985
  )
5883
5986
  } else {
5884
5987
 
5885
- var tag = tagMatch[1]
5988
+ var tag = tagMatch && tagMatch[1]
5886
5989
  var wrap = map[tag] || map._default
5887
5990
  var depth = wrap[0]
5888
5991
  var prefix = wrap[1]
@@ -6046,11 +6149,11 @@ return /******/ (function(modules) { // webpackBootstrap
6046
6149
  }
6047
6150
 
6048
6151
  /***/ },
6049
- /* 46 */
6152
+ /* 47 */
6050
6153
  /***/ function(module, exports, __webpack_require__) {
6051
6154
 
6052
6155
  var _ = __webpack_require__(1)
6053
- var Cache = __webpack_require__(52)
6156
+ var Cache = __webpack_require__(53)
6054
6157
  var cache = new Cache(1000)
6055
6158
  var argRE = /^[^\{\?]+$|^'[^']*'$|^"[^"]*"$/
6056
6159
  var filterTokenRE = /[^\s'"]+|'[^']+'|"[^"]+"/g
@@ -6210,12 +6313,12 @@ return /******/ (function(modules) { // webpackBootstrap
6210
6313
  }
6211
6314
 
6212
6315
  /***/ },
6213
- /* 47 */
6316
+ /* 48 */
6214
6317
  /***/ function(module, exports, __webpack_require__) {
6215
6318
 
6216
6319
  var _ = __webpack_require__(1)
6217
- var Path = __webpack_require__(43)
6218
- var Cache = __webpack_require__(52)
6320
+ var Path = __webpack_require__(44)
6321
+ var Cache = __webpack_require__(53)
6219
6322
  var expressionCache = new Cache(1000)
6220
6323
 
6221
6324
  var keywords =
@@ -6441,12 +6544,12 @@ return /******/ (function(modules) { // webpackBootstrap
6441
6544
  exports.pathTestRE = pathTestRE
6442
6545
 
6443
6546
  /***/ },
6444
- /* 48 */
6547
+ /* 49 */
6445
6548
  /***/ function(module, exports, __webpack_require__) {
6446
6549
 
6447
6550
  var _ = __webpack_require__(1)
6448
- var applyCSSTransition = __webpack_require__(53)
6449
- var applyJSTransition = __webpack_require__(54)
6551
+ var applyCSSTransition = __webpack_require__(54)
6552
+ var applyJSTransition = __webpack_require__(55)
6450
6553
 
6451
6554
  /**
6452
6555
  * Append with transition.
@@ -6597,16 +6700,16 @@ return /******/ (function(modules) { // webpackBootstrap
6597
6700
  }
6598
6701
 
6599
6702
  /***/ },
6600
- /* 49 */
6703
+ /* 50 */
6601
6704
  /***/ function(module, exports, __webpack_require__) {
6602
6705
 
6603
6706
  var _ = __webpack_require__(1)
6604
6707
 
6605
6708
  var handlers = {
6606
- _default: __webpack_require__(55),
6607
- radio: __webpack_require__(56),
6608
- select: __webpack_require__(57),
6609
- checkbox: __webpack_require__(58)
6709
+ _default: __webpack_require__(56),
6710
+ radio: __webpack_require__(57),
6711
+ select: __webpack_require__(58),
6712
+ checkbox: __webpack_require__(59)
6610
6713
  }
6611
6714
 
6612
6715
  module.exports = {
@@ -6658,15 +6761,15 @@ return /******/ (function(modules) { // webpackBootstrap
6658
6761
  }
6659
6762
 
6660
6763
  /***/ },
6661
- /* 50 */
6764
+ /* 51 */
6662
6765
  /***/ function(module, exports, __webpack_require__) {
6663
6766
 
6664
6767
  var _ = __webpack_require__(1)
6665
6768
  var config = __webpack_require__(20)
6666
- var Dep = __webpack_require__(39)
6667
- var arrayMethods = __webpack_require__(59)
6769
+ var Dep = __webpack_require__(40)
6770
+ var arrayMethods = __webpack_require__(60)
6668
6771
  var arrayKeys = Object.getOwnPropertyNames(arrayMethods)
6669
- __webpack_require__(60)
6772
+ __webpack_require__(61)
6670
6773
 
6671
6774
  var uid = 0
6672
6775
 
@@ -6899,77 +7002,92 @@ return /******/ (function(modules) { // webpackBootstrap
6899
7002
 
6900
7003
 
6901
7004
  /***/ },
6902
- /* 51 */
7005
+ /* 52 */
6903
7006
  /***/ function(module, exports, __webpack_require__) {
6904
7007
 
6905
7008
  var _ = __webpack_require__(1)
6906
7009
 
7010
+ // we have two separate queues: one for directive updates
7011
+ // and one for user watcher registered via $watch().
7012
+ // we want to guarantee directive updates to be called
7013
+ // before user watchers so that when user watchers are
7014
+ // triggered, the DOM would have already been in updated
7015
+ // state.
7016
+ var queue = []
7017
+ var userQueue = []
7018
+ var has = {}
7019
+ var waiting = false
7020
+ var flushing = false
7021
+
6907
7022
  /**
6908
- * The Batcher maintains a job queue to be run
6909
- * async on the next event loop.
7023
+ * Reset the batcher's state.
6910
7024
  */
6911
7025
 
6912
- function Batcher () {
6913
- this.reset()
7026
+ function reset () {
7027
+ queue = []
7028
+ userQueue = []
7029
+ has = {}
7030
+ waiting = false
7031
+ flushing = false
6914
7032
  }
6915
7033
 
6916
- var p = Batcher.prototype
6917
-
6918
7034
  /**
6919
- * Push a job into the job queue.
6920
- * Jobs with duplicate IDs will be skipped unless it's
6921
- * pushed when the queue is being flushed.
6922
- *
6923
- * @param {Object} job
6924
- * properties:
6925
- * - {String|Number} id
6926
- * - {Function} run
7035
+ * Flush both queues and run the jobs.
6927
7036
  */
6928
7037
 
6929
- p.push = function (job) {
6930
- if (!job.id || !this.has[job.id] || this.flushing) {
6931
- this.queue.push(job)
6932
- this.has[job.id] = job
6933
- if (!this.waiting) {
6934
- this.waiting = true
6935
- _.nextTick(this.flush, this)
6936
- }
6937
- }
7038
+ function flush () {
7039
+ flushing = true
7040
+ run(queue)
7041
+ run(userQueue)
7042
+ reset()
6938
7043
  }
6939
7044
 
6940
7045
  /**
6941
- * Flush the queue and run the jobs.
6942
- * Will call a preFlush hook if has one.
7046
+ * Run the jobs in a single queue.
7047
+ *
7048
+ * @param {Array} queue
6943
7049
  */
6944
7050
 
6945
- p.flush = function () {
6946
- this.flushing = true
7051
+ function run (queue) {
6947
7052
  // do not cache length because more jobs might be pushed
6948
7053
  // as we run existing jobs
6949
- for (var i = 0; i < this.queue.length; i++) {
6950
- var job = this.queue[i]
6951
- if (!job.cancelled) {
6952
- job.run()
6953
- }
7054
+ for (var i = 0; i < queue.length; i++) {
7055
+ queue[i].run()
6954
7056
  }
6955
- this.reset()
6956
7057
  }
6957
7058
 
6958
7059
  /**
6959
- * Reset the batcher's state.
7060
+ * Push a job into the job queue.
7061
+ * Jobs with duplicate IDs will be skipped unless it's
7062
+ * pushed when the queue is being flushed.
7063
+ *
7064
+ * @param {Object} job
7065
+ * properties:
7066
+ * - {String|Number} id
7067
+ * - {Function} run
6960
7068
  */
6961
7069
 
6962
- p.reset = function () {
6963
- this.has = {}
6964
- this.queue = []
6965
- this.waiting = false
6966
- this.flushing = false
7070
+ exports.push = function (job) {
7071
+ if (!job.id || !has[job.id] || flushing) {
7072
+ // A user watcher callback could trigger another
7073
+ // directive update during the flushing; at that time
7074
+ // the directive queue would already have been run, so
7075
+ // we call that update immediately as it is pushed.
7076
+ if (flushing && !job.user) {
7077
+ job.run()
7078
+ return
7079
+ }
7080
+ ;(job.user ? userQueue : queue).push(job)
7081
+ has[job.id] = job
7082
+ if (!waiting) {
7083
+ waiting = true
7084
+ _.nextTick(flush)
7085
+ }
7086
+ }
6967
7087
  }
6968
7088
 
6969
- module.exports = Batcher
6970
-
6971
7089
  /***/ },
6972
- /* 52 */
7090
+ /* 53 */
6973
7091
  /***/ function(module, exports, __webpack_require__) {
6974
7092
 
6975
7093
  /**
@@ -7086,7 +7204,7 @@ return /******/ (function(modules) { // webpackBootstrap
7086
7204
  module.exports = Cache
7087
7205
 
7088
7206
  /***/ },
7089
- /* 53 */
7207
+ /* 54 */
7090
7208
  /***/ function(module, exports, __webpack_require__) {
7091
7209
 
7092
7210
  var _ = __webpack_require__(1)
@@ -7280,7 +7398,7 @@ return /******/ (function(modules) { // webpackBootstrap
7280
7398
  }
7281
7399
 
7282
7400
  /***/ },
7283
- /* 54 */
7401
+ /* 55 */
7284
7402
  /***/ function(module, exports, __webpack_require__) {
7285
7403
 
7286
7404
  /**
@@ -7328,7 +7446,7 @@ return /******/ (function(modules) { // webpackBootstrap
7328
7446
  }
7329
7447
 
7330
7448
  /***/ },
7331
- /* 55 */
7449
+ /* 56 */
7332
7450
  /***/ function(module, exports, __webpack_require__) {
7333
7451
 
7334
7452
  var _ = __webpack_require__(1)
@@ -7456,7 +7574,7 @@ return /******/ (function(modules) { // webpackBootstrap
7456
7574
  }
7457
7575
 
7458
7576
  /***/ },
7459
- /* 56 */
7577
+ /* 57 */
7460
7578
  /***/ function(module, exports, __webpack_require__) {
7461
7579
 
7462
7580
  var _ = __webpack_require__(1)
@@ -7487,7 +7605,7 @@ return /******/ (function(modules) { // webpackBootstrap
7487
7605
  }
7488
7606
 
7489
7607
  /***/ },
7490
- /* 57 */
7608
+ /* 58 */
7491
7609
  /***/ function(module, exports, __webpack_require__) {
7492
7610
 
7493
7611
  var _ = __webpack_require__(1)
@@ -7561,7 +7679,8 @@ return /******/ (function(modules) { // webpackBootstrap
7561
7679
  this.optionWatcher = new Watcher(
7562
7680
  this.vm,
7563
7681
  expression,
7564
- optionUpdateWatcher
7682
+ optionUpdateWatcher,
7683
+ { deep: true }
7565
7684
  )
7566
7685
  // update with initial value
7567
7686
  optionUpdateWatcher(this.optionWatcher.value)
@@ -7658,7 +7777,7 @@ return /******/ (function(modules) { // webpackBootstrap
7658
7777
  }
7659
7778
 
7660
7779
  /***/ },
7661
- /* 58 */
7780
+ /* 59 */
7662
7781
  /***/ function(module, exports, __webpack_require__) {
7663
7782
 
7664
7783
  var _ = __webpack_require__(1)
@@ -7688,7 +7807,7 @@ return /******/ (function(modules) { // webpackBootstrap
7688
7807
  }
7689
7808
 
7690
7809
  /***/ },
7691
- /* 59 */
7810
+ /* 60 */
7692
7811
  /***/ function(module, exports, __webpack_require__) {
7693
7812
 
7694
7813
  var _ = __webpack_require__(1)
@@ -7783,7 +7902,7 @@ return /******/ (function(modules) { // webpackBootstrap
7783
7902
  module.exports = arrayMethods
7784
7903
 
7785
7904
  /***/ },
7786
- /* 60 */
7905
+ /* 61 */
7787
7906
  /***/ function(module, exports, __webpack_require__) {
7788
7907
 
7789
7908
  var _ = __webpack_require__(1)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vuejs-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.3
4
+ version: 0.11.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Adam Butler
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-04 00:00:00.000000000 Z
11
+ date: 2014-12-09 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A simple asset-pipeline wrapper for vue.js by Evan You
14
14
  email: