Initial Commit
This commit is contained in:
1
assets/js/fields.min.js
vendored
Normal file
1
assets/js/fields.min.js
vendored
Normal file
@ -0,0 +1 @@
|
||||
void 0!==window.Vue&&Vue.component("colorPicker",{props:["value"],template:'<input type="text">',mounted(){const e=this;$(this.$el).val(this.value).wpColorPicker({width:200,defaultColor:this.value,change(o,t){e.$emit("input",t.color.toString())}})},watch:{value(e){$(this.$el).wpColorPicker("color",e)}},destroyed(){$(this.$el).off().wpColorPicker("destroy")}});
|
Reference in New Issue
Block a user