@bpui/checkbox
Advanced tools
Comparing version 0.0.10 to 0.0.11
/*! | ||
* bpui checkbox v0.0.10 | ||
* bpui checkbox v0.0.11 | ||
* Copyright (c) 2020 Copyright bp All Rights Reserved. | ||
* Released under the MIT License. | ||
*/'use strict';function _interopDefault(a){return a&&"object"==typeof a&&"default"in a?a["default"]:a}var bpLibs=_interopDefault(require("@bpui/libs")),script={components:{},props:{checked:{default:!1},disabled:{default:!1,type:Boolean}},model:{prop:"checked",event:"change"},data(){return{isChecked:!1,hovering:!1}},computed:{isDisabled(){return this.disabled||!1!==this.disabled}},created(){this.isChecked=this.checked},beforeDestroy(){},beforeMount(){},mounted(){},methods:{handelChange(a){this.$emit("change",a.target.checked),this.isChecked=a.target.checked}}};function normalizeComponent(a,b,c,d,e,f,g,h,i,j){"boolean"!=typeof g&&(i=h,h=g,g=!1);const k="function"==typeof c?c.options:c;a&&a.render&&(k.render=a.render,k.staticRenderFns=a.staticRenderFns,k._compiled=!0,e&&(k.functional=!0)),d&&(k._scopeId=d);let l;if(f?(l=function(a){a=a||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,a||"undefined"==typeof __VUE_SSR_CONTEXT__||(a=__VUE_SSR_CONTEXT__),b&&b.call(this,i(a)),a&&a._registeredComponents&&a._registeredComponents.add(f)},k._ssrRegister=l):b&&(l=g?function(a){b.call(this,j(a,this.$root.$options.shadowRoot))}:function(a){b.call(this,h(a))}),l)if(k.functional){const a=k.render;k.render=function(b,c){return l.call(c),a(b,c)}}else{const a=k.beforeCreate;k.beforeCreate=a?[].concat(a,l):[l]}return c}const __vue_script__=script;var __vue_render__=function(){var a=this,b=a.$createElement,c=a._self._c||b;return c("label",{staticClass:"bp-checkbox",class:{"bp-Checkbox__disabled":a.isDisabled},on:{mouseenter:function(){a.hovering=!0},mouseleave:function(){a.hovering=!1}}},[c("span",{staticClass:"bp-checkbox__input"},[c("span",{staticClass:"bp-checkbox__inner",class:[a.hovering?"bp-checkbox__inner_hover":"",a.isChecked?"bp-checkbox__inner_checked":""]},[a.isChecked?c("bp-icon",{attrs:{name:"bp-checkbox_checked"}}):a._e()],1),a._v(" "),c("input",a._b({staticClass:"bp-checkbox__original",attrs:{type:"checkbox",disabled:a.isDisabled},domProps:{checked:a.checked},on:{change:a.handelChange}},"input",a.$attrs,!1))]),a._v(" "),a.$slots.default?c("span",{staticClass:"bp-checkbox__label"},[a._t("default")],2):a._e()])},__vue_staticRenderFns__=[];__vue_render__._withStripped=!0;const __vue_inject_styles__=void 0,__vue_scope_id__=void 0,__vue_module_identifier__=void 0,__vue_is_functional_template__=!1,__vue_component__=normalizeComponent({render:__vue_render__,staticRenderFns:__vue_staticRenderFns__},void 0,__vue_script__,__vue_scope_id__,__vue_is_functional_template__,__vue_module_identifier__,!1,void 0,void 0,void 0);function init(){bpLibs.icons.registerAliasIcon("bp-checkbox_checked","ok")}init();var index={init,bpCheckbox:__vue_component__};module.exports=index; |
/*! | ||
* bpui checkbox v0.0.10 | ||
* bpui checkbox v0.0.11 | ||
* Copyright (c) 2020 Copyright bp All Rights Reserved. | ||
* Released under the MIT License. | ||
*/import bpLibs from"@bpui/libs";var script={components:{},props:{checked:{default:!1},disabled:{default:!1,type:Boolean}},model:{prop:"checked",event:"change"},data(){return{isChecked:!1,hovering:!1}},computed:{isDisabled(){return this.disabled||!1!==this.disabled}},created(){this.isChecked=this.checked},beforeDestroy(){},beforeMount(){},mounted(){},methods:{handelChange(a){this.$emit("change",a.target.checked),this.isChecked=a.target.checked}}};function normalizeComponent(a,b,c,d,e,f,g,h,i,j){"boolean"!=typeof g&&(i=h,h=g,g=!1);const k="function"==typeof c?c.options:c;a&&a.render&&(k.render=a.render,k.staticRenderFns=a.staticRenderFns,k._compiled=!0,e&&(k.functional=!0)),d&&(k._scopeId=d);let l;if(f?(l=function(a){a=a||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,a||"undefined"==typeof __VUE_SSR_CONTEXT__||(a=__VUE_SSR_CONTEXT__),b&&b.call(this,i(a)),a&&a._registeredComponents&&a._registeredComponents.add(f)},k._ssrRegister=l):b&&(l=g?function(a){b.call(this,j(a,this.$root.$options.shadowRoot))}:function(a){b.call(this,h(a))}),l)if(k.functional){const a=k.render;k.render=function(b,c){return l.call(c),a(b,c)}}else{const a=k.beforeCreate;k.beforeCreate=a?[].concat(a,l):[l]}return c}const __vue_script__=script;var __vue_render__=function(){var a=this,b=a.$createElement,c=a._self._c||b;return c("label",{staticClass:"bp-checkbox",class:{"bp-Checkbox__disabled":a.isDisabled},on:{mouseenter:function(){a.hovering=!0},mouseleave:function(){a.hovering=!1}}},[c("span",{staticClass:"bp-checkbox__input"},[c("span",{staticClass:"bp-checkbox__inner",class:[a.hovering?"bp-checkbox__inner_hover":"",a.isChecked?"bp-checkbox__inner_checked":""]},[a.isChecked?c("bp-icon",{attrs:{name:"bp-checkbox_checked"}}):a._e()],1),a._v(" "),c("input",a._b({staticClass:"bp-checkbox__original",attrs:{type:"checkbox",disabled:a.isDisabled},domProps:{checked:a.checked},on:{change:a.handelChange}},"input",a.$attrs,!1))]),a._v(" "),a.$slots.default?c("span",{staticClass:"bp-checkbox__label"},[a._t("default")],2):a._e()])},__vue_staticRenderFns__=[];__vue_render__._withStripped=!0;const __vue_inject_styles__=void 0,__vue_scope_id__=void 0,__vue_module_identifier__=void 0,__vue_is_functional_template__=!1,__vue_component__=normalizeComponent({render:__vue_render__,staticRenderFns:__vue_staticRenderFns__},void 0,__vue_script__,__vue_scope_id__,__vue_is_functional_template__,__vue_module_identifier__,!1,void 0,void 0,void 0);function init(){bpLibs.icons.registerAliasIcon("bp-checkbox_checked","ok")}init();var index={init,bpCheckbox:__vue_component__};export default index; |
/*! | ||
* bpui checkbox v0.0.10 | ||
* bpui checkbox v0.0.11 | ||
* Copyright (c) 2020 Copyright bp All Rights Reserved. | ||
* Released under the MIT License. | ||
*/(function(a,b){"object"==typeof exports&&"undefined"!=typeof module?module.exports=b(require("@bpui/libs")):"function"==typeof define&&define.amd?define(["@bpui/libs"],b):(a=a||self,a.bpCheckbox=b(a.bpLibs))})(this,function(a){'use strict';function b(){a.icons.registerAliasIcon("bp-checkbox_checked","ok")}a=a&&a.hasOwnProperty("default")?a["default"]:a;var c={components:{},props:{checked:{default:!1},disabled:{default:!1,type:Boolean}},model:{prop:"checked",event:"change"},data(){return{isChecked:!1,hovering:!1}},computed:{isDisabled(){return this.disabled||!1!==this.disabled}},created(){this.isChecked=this.checked},beforeDestroy(){},beforeMount(){},mounted(){},methods:{handelChange(a){this.$emit("change",a.target.checked),this.isChecked=a.target.checked}}};var d=function(){var a=this,b=a.$createElement,c=a._self._c||b;return c("label",{staticClass:"bp-checkbox",class:{"bp-Checkbox__disabled":a.isDisabled},on:{mouseenter:function(){a.hovering=!0},mouseleave:function(){a.hovering=!1}}},[c("span",{staticClass:"bp-checkbox__input"},[c("span",{staticClass:"bp-checkbox__inner",class:[a.hovering?"bp-checkbox__inner_hover":"",a.isChecked?"bp-checkbox__inner_checked":""]},[a.isChecked?c("bp-icon",{attrs:{name:"bp-checkbox_checked"}}):a._e()],1),a._v(" "),c("input",a._b({staticClass:"bp-checkbox__original",attrs:{type:"checkbox",disabled:a.isDisabled},domProps:{checked:a.checked},on:{change:a.handelChange}},"input",a.$attrs,!1))]),a._v(" "),a.$slots.default?c("span",{staticClass:"bp-checkbox__label"},[a._t("default")],2):a._e()])};d._withStripped=!0;const e=function(a,b,c,d,e,f,g,h,i,j){"boolean"!=typeof g&&(i=h,h=g,g=!1);const k="function"==typeof c?c.options:c;a&&a.render&&(k.render=a.render,k.staticRenderFns=a.staticRenderFns,k._compiled=!0,e&&(k.functional=!0)),d&&(k._scopeId=d);let l;if(f?(l=function(a){a=a||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,a||"undefined"==typeof __VUE_SSR_CONTEXT__||(a=__VUE_SSR_CONTEXT__),b&&b.call(this,i(a)),a&&a._registeredComponents&&a._registeredComponents.add(f)},k._ssrRegister=l):b&&(l=g?function(a){b.call(this,j(a,this.$root.$options.shadowRoot))}:function(a){b.call(this,h(a))}),l)if(k.functional){const a=k.render;k.render=function(b,c){return l.call(c),a(b,c)}}else{const a=k.beforeCreate;k.beforeCreate=a?[].concat(a,l):[l]}return c}({render:d,staticRenderFns:[]},void 0,c,void 0,!1,void 0,!1,void 0,void 0,void 0);b();return{init:b,bpCheckbox:e}}); |
@@ -41,3 +41,3 @@ { | ||
"name": "@bpui/checkbox", | ||
"version": "0.0.10" | ||
"version": "0.0.11" | ||
} |
Sorry, the diff of this file is not supported yet
21332