Skip to content

Commit c462224

Browse files
committed
Release 2.1.0
1 parent 7fdf625 commit c462224

File tree

7 files changed

+25
-7
lines changed

7 files changed

+25
-7
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
## [2.1.0] - 2016-10-20
2+
3+
## Added
4+
- `.lazy` modifier to mimic v1 behavior
5+
16
## [2.0.0] - 2016-10-20
27

38
No changes from 2.0.0-rc2
@@ -48,3 +53,4 @@ Initial release
4853
[2.0.0-rc1]: https://github.com/simplesmiler/vue-focus/compare/1.0.0...2.0.0-rc1
4954
[2.0.0-rc2]: https://github.com/simplesmiler/vue-focus/compare/2.0.0-rc1...2.0.0-rc2
5055
[2.0.0]: https://github.com/simplesmiler/vue-focus/compare/2.0.0-rc2...2.0.0
56+
[2.1.0]: https://github.com/simplesmiler/vue-focus/compare/2.0.0...2.1.0

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ $ npm install vue-focus --save
3636
From CDN:
3737

3838
``` html
39-
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue-focus/2.0.0/vue-focus.js"></script>
39+
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue-focus/2.1.0/vue-focus.js"></script>
4040
<!-- OR -->
41-
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue-focus/2.0.0/vue-focus.min.js"></script>
41+
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue-focus/2.1.0/vue-focus.min.js"></script>
4242
```
4343

4444
## API

dist/vue-focus.common.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
var Vue = require('vue');
44
Vue = 'default' in Vue ? Vue['default'] : Vue;
55

6-
var version = '2.0.0';
6+
var version = '2.1.0';
77

88
var compatible = (/^2\./).test(Vue.version);
99
if (!compatible) {
@@ -17,6 +17,12 @@ var focus = {
1717
},
1818

1919
componentUpdated: function(el, binding) {
20+
if (binding.modifiers.lazy) {
21+
if (Boolean(binding.value) === Boolean(binding.oldValue)) {
22+
return;
23+
}
24+
}
25+
2026
if (binding.value) el.focus();
2127
else el.blur();
2228
},

dist/vue-focus.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Vue = 'default' in Vue ? Vue['default'] : Vue;
44

5-
var version = '2.0.0';
5+
var version = '2.1.0';
66

77
var compatible = (/^2\./).test(Vue.version);
88
if (!compatible) {
@@ -16,6 +16,12 @@
1616
},
1717

1818
componentUpdated: function(el, binding) {
19+
if (binding.modifiers.lazy) {
20+
if (Boolean(binding.value) === Boolean(binding.oldValue)) {
21+
return;
22+
}
23+
}
24+
1925
if (binding.value) el.focus();
2026
else el.blur();
2127
},

dist/vue-focus.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import Vue from 'vue';
22

3-
export var version = '2.0.0';
3+
export var version = '2.1.0';
44

55
var compatible = (/^2\./).test(Vue.version);
66
if (!compatible) {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "vue-focus",
33
"description": "A set of reusable focus directives for reusable Vue.js components",
4-
"version": "2.0.0",
4+
"version": "2.1.0",
55
"author": "Denis Karabaza <[email protected]>",
66
"browserify": {
77
"transform": [

0 commit comments

Comments
 (0)