(("undefined"!==typeof self?self:this)["webpackJsonpwebform_plugin"]=("undefined"!==typeof self?self:this)["webpackJsonpwebform_plugin"]||[]).push([[8],{"0437":function(e,o,t){"use strict";t.r(o);var r=function(){var e=this,o=e.$createElement,t=e._self._c||o;return t("div",{ref:"colorpicker",staticClass:"input-group color-picker"},[t("span",{staticClass:"current-color",style:{"background-color":e.colorValue},on:{click:function(o){return e.togglePicker()}}}),e.displayPicker?t("chrome-picker",{attrs:{value:e.colors},on:{input:e.updateFromPicker}}):e._e()],1)},i=[],c=(t("fb6a"),t("ac1f"),t("1276"),t("5319"),t("d3b7"),t("25f0"),t("c345")),s={name:"colorpicker",props:["color"],components:{"chrome-picker":c["Chrome"]},data:function(){return{colors:{hex:"#000000"},colorValue:"",displayPicker:!1}},mounted:function(){this.setColor(this.color||"#000000")},methods:{setColor:function(e){this.updateColors(e),this.colorValue=e},updateColors:function(e){if("#"==e.slice(0,1))this.colors={hex:e};else if("rgba"==e.slice(0,4)){var o=e.replace(/^rgba?\(|\s+|\)$/g,"").split(","),t="#"+((1<<24)+(parseInt(o[0])<<16)+(parseInt(o[1])<<8)+parseInt(o[2])).toString(16).slice(1);this.colors={hex:t,a:o[3]}}},showPicker:function(){document.addEventListener("click",this.documentClick),this.displayPicker=!0},hidePicker:function(){document.removeEventListener("click",this.documentClick),this.displayPicker=!1},togglePicker:function(){this.displayPicker?this.hidePicker():this.showPicker()},updateFromInput:function(){this.updateColors(this.colorValue)},updateFromPicker:function(e){this.colors=e,1==e.rgba.a?this.colorValue=e.hex:this.colorValue="rgba("+e.rgba.r+", "+e.rgba.g+", "+e.rgba.b+", "+e.rgba.a+")"},documentClick:function(e){var o=this.$refs.colorpicker,t=e.target;o===t||o.contains(t)||this.hidePicker()}},watch:{colorValue:function(e){e&&(this.updateColors(e),this.$emit("input",e))}}},n=s,l=(t("6132"),t("2877")),a=Object(l["a"])(n,r,i,!1,null,null,null);o["default"]=a.exports},"0644":function(e,o,t){var r=t("091f");r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.i,r,""]]),r.locals&&(e.exports=r.locals);var i=t("499e").default;i("557e2e3d",r,!0,{sourceMap:!1,shadowMode:!1})},"091f":function(e,o,t){var r=t("24fb");o=r(!1),o.push([e.i,".current-color{display:inline-block;width:25px;height:25px;background-color:#000;cursor:pointer;border:1px solid #ccc}.vc-chrome{position:absolute;right:0;top:35px;z-index:9}.right-45>.vc-chrome{right:-100px!important}",""]),e.exports=o},6132:function(e,o,t){"use strict";t("0644")}}]);
//# sourceMappingURL=webform-plugin.umd.min.8.js.map