Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 4dab16c

Browse filesBrowse files
veebuveuvl
authored andcommitted
ability to tag values, add sync blocker (#107)
1 parent 4a60d4d commit 4dab16c
Copy full SHA for 4dab16c

File tree

Expand file treeCollapse file tree

1 file changed

+14
-7
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+14
-7
lines changed

‎src/Button.vue

Copy file name to clipboardExpand all lines: src/Button.vue
+14-7Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,9 @@ export default {
7070
type: Boolean,
7171
default: false
7272
},
73+
tag: {
74+
type: String,
75+
},
7376
sync: {
7477
type: Boolean,
7578
default: false
@@ -269,14 +272,18 @@ export default {
269272
}
270273
},
271274
methods: {
272-
toggle (event) {
273-
this.toggled = !this.toggled
274-
this.$emit('input', this.toggled)
275+
toggle(event) {
276+
const toggled = !this.toggled;
277+
if (!this.sync) {
278+
this.toggled = toggled;
279+
}
280+
this.$emit('input', toggled);
275281
this.$emit('change', {
276-
value: this.toggled,
277-
srcEvent: event
278-
})
279-
}
282+
value: toggled,
283+
tag: this.tag,
284+
srcEvent: event,
285+
});
286+
},
280287
}
281288
}
282289
</script>

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.