Socket
Socket
Sign inDemoInstall

@thinknimble/togglecheckbox

Package Overview
Dependencies
11
Maintainers
9
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.1.2 to 0.1.3

8

dist/togglecheckbox.common.js

@@ -613,8 +613,8 @@ module.exports =

// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"b61fb5ee-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ToggleCheckBox.vue?vue&type=template&id=e5d1b6ec&
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{staticClass:"toggle"},[_c('input',{staticClass:"toggle",attrs:{"type":"checkbox","false-value":_vm.invert ? 1 : 0,"true-value":_vm.invert ? 0 : 1},domProps:{"value":_vm.value,"checked":_vm.active},on:{"click":_vm.emitToggle}}),_c('div',{style:(_vm.checkboxStyles)},[_c('div')])])}
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"b61fb5ee-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ToggleCheckBox.vue?vue&type=template&id=712e5e09&
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{staticClass:"toggle"},[_c('input',{staticClass:"toggle",attrs:{"type":"checkbox"},domProps:{"value":_vm.value,"checked":_vm.invert ? !_vm.active : _vm.active},on:{"click":_vm.emitToggle}}),_c('div',{style:(_vm.checkboxStyles)},[_c('div')])])}
var staticRenderFns = []
// CONCATENATED MODULE: ./src/components/ToggleCheckBox.vue?vue&type=template&id=e5d1b6ec&
// CONCATENATED MODULE: ./src/components/ToggleCheckBox.vue?vue&type=template&id=712e5e09&

@@ -637,4 +637,2 @@ // CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ToggleCheckBox.vue?vue&type=script&lang=js&

//
//
//

@@ -641,0 +639,0 @@ /**

@@ -622,8 +622,8 @@ (function webpackUniversalModuleDefinition(root, factory) {

// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"b61fb5ee-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ToggleCheckBox.vue?vue&type=template&id=e5d1b6ec&
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{staticClass:"toggle"},[_c('input',{staticClass:"toggle",attrs:{"type":"checkbox","false-value":_vm.invert ? 1 : 0,"true-value":_vm.invert ? 0 : 1},domProps:{"value":_vm.value,"checked":_vm.active},on:{"click":_vm.emitToggle}}),_c('div',{style:(_vm.checkboxStyles)},[_c('div')])])}
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"b61fb5ee-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ToggleCheckBox.vue?vue&type=template&id=712e5e09&
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{staticClass:"toggle"},[_c('input',{staticClass:"toggle",attrs:{"type":"checkbox"},domProps:{"value":_vm.value,"checked":_vm.invert ? !_vm.active : _vm.active},on:{"click":_vm.emitToggle}}),_c('div',{style:(_vm.checkboxStyles)},[_c('div')])])}
var staticRenderFns = []
// CONCATENATED MODULE: ./src/components/ToggleCheckBox.vue?vue&type=template&id=e5d1b6ec&
// CONCATENATED MODULE: ./src/components/ToggleCheckBox.vue?vue&type=template&id=712e5e09&

@@ -646,4 +646,2 @@ // CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ToggleCheckBox.vue?vue&type=script&lang=js&

//
//
//

@@ -650,0 +648,0 @@ /**

@@ -1,2 +0,2 @@

(function(e,t){"object"===typeof exports&&"object"===typeof module?module.exports=t():"function"===typeof define&&define.amd?define([],t):"object"===typeof exports?exports["togglecheckbox"]=t():e["togglecheckbox"]=t()})("undefined"!==typeof self?self:this,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s="fb15")}({"24fb":function(e,t,n){"use strict";function r(e,t){var n=e[1]||"",r=e[3];if(!r)return n;if(t&&"function"===typeof btoa){var i=o(r),c=r.sources.map((function(e){return"/*# sourceURL=".concat(r.sourceRoot||"").concat(e," */")}));return[n].concat(c).concat([i]).join("\n")}return[n].join("\n")}function o(e){var t=btoa(unescape(encodeURIComponent(JSON.stringify(e)))),n="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(t);return"/*# ".concat(n," */")}e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n=r(t,e);return t[2]?"@media ".concat(t[2]," {").concat(n,"}"):n})).join("")},t.i=function(e,n,r){"string"===typeof e&&(e=[[null,e,""]]);var o={};if(r)for(var i=0;i<this.length;i++){var c=this[i][0];null!=c&&(o[c]=!0)}for(var a=0;a<e.length;a++){var u=[].concat(e[a]);r&&o[u[0]]||(n&&(u[2]?u[2]="".concat(n," and ").concat(u[2]):u[2]=n),t.push(u))}},t}},"499e":function(e,t,n){"use strict";function r(e,t){for(var n=[],r={},o=0;o<t.length;o++){var i=t[o],c=i[0],a=i[1],u=i[2],s=i[3],d={id:e+":"+o,css:a,media:u,sourceMap:s};r[c]?r[c].parts.push(d):n.push(r[c]={id:c,parts:[d]})}return n}n.r(t),n.d(t,"default",(function(){return h}));var o="undefined"!==typeof document;if("undefined"!==typeof DEBUG&&DEBUG&&!o)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var i={},c=o&&(document.head||document.getElementsByTagName("head")[0]),a=null,u=0,s=!1,d=function(){},l=null,f="data-vue-ssr-id",p="undefined"!==typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());function h(e,t,n,o){s=n,l=o||{};var c=r(e,t);return v(c),function(t){for(var n=[],o=0;o<c.length;o++){var a=c[o],u=i[a.id];u.refs--,n.push(u)}t?(c=r(e,t),v(c)):c=[];for(o=0;o<n.length;o++){u=n[o];if(0===u.refs){for(var s=0;s<u.parts.length;s++)u.parts[s]();delete i[u.id]}}}}function v(e){for(var t=0;t<e.length;t++){var n=e[t],r=i[n.id];if(r){r.refs++;for(var o=0;o<r.parts.length;o++)r.parts[o](n.parts[o]);for(;o<n.parts.length;o++)r.parts.push(m(n.parts[o]));r.parts.length>n.parts.length&&(r.parts.length=n.parts.length)}else{var c=[];for(o=0;o<n.parts.length;o++)c.push(m(n.parts[o]));i[n.id]={id:n.id,refs:1,parts:c}}}}function g(){var e=document.createElement("style");return e.type="text/css",c.appendChild(e),e}function m(e){var t,n,r=document.querySelector("style["+f+'~="'+e.id+'"]');if(r){if(s)return d;r.parentNode.removeChild(r)}if(p){var o=u++;r=a||(a=g()),t=y.bind(null,r,o,!1),n=y.bind(null,r,o,!0)}else r=g(),t=x.bind(null,r),n=function(){r.parentNode.removeChild(r)};return t(e),function(r){if(r){if(r.css===e.css&&r.media===e.media&&r.sourceMap===e.sourceMap)return;t(e=r)}else n()}}var b=function(){var e=[];return function(t,n){return e[t]=n,e.filter(Boolean).join("\n")}}();function y(e,t,n,r){var o=n?"":r.css;if(e.styleSheet)e.styleSheet.cssText=b(t,o);else{var i=document.createTextNode(o),c=e.childNodes;c[t]&&e.removeChild(c[t]),c.length?e.insertBefore(i,c[t]):e.appendChild(i)}}function x(e,t){var n=t.css,r=t.media,o=t.sourceMap;if(r&&e.setAttribute("media",r),l.ssrId&&e.setAttribute(f,t.id),o&&(n+="\n/*# sourceURL="+o.sources[0]+" */",n+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(o))))+" */"),e.styleSheet)e.styleSheet.cssText=n;else{while(e.firstChild)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(n))}}},8875:function(e,t,n){var r,o,i;(function(n,c){o=[],r=c,i="function"===typeof r?r.apply(t,o):r,void 0===i||(e.exports=i)})("undefined"!==typeof self&&self,(function(){function e(){var t=Object.getOwnPropertyDescriptor(document,"currentScript");if(!t&&"currentScript"in document&&document.currentScript)return document.currentScript;if(t&&t.get!==e&&document.currentScript)return document.currentScript;try{throw new Error}catch(p){var n,r,o,i=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,c=/@([^@]*):(\d+):(\d+)\s*$/gi,a=i.exec(p.stack)||c.exec(p.stack),u=a&&a[1]||!1,s=a&&a[2]||!1,d=document.location.href.replace(document.location.hash,""),l=document.getElementsByTagName("script");u===d&&(n=document.documentElement.outerHTML,r=new RegExp("(?:[^\\n]+?\\n){0,"+(s-2)+"}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*","i"),o=n.replace(r,"$1").trim());for(var f=0;f<l.length;f++){if("interactive"===l[f].readyState)return l[f];if(l[f].src===u)return l[f];if(u===d&&l[f].innerHTML&&l[f].innerHTML.trim()===o)return l[f]}return null}}return e}))},a1c7:function(e,t,n){var r=n("bc7d");"string"===typeof r&&(r=[[e.i,r,""]]),r.locals&&(e.exports=r.locals);var o=n("499e").default;o("b645f2d4",r,!0,{sourceMap:!1,shadowMode:!1})},b052:function(e,t,n){"use strict";var r=n("a1c7"),o=n.n(r);o.a},bc7d:function(e,t,n){var r=n("24fb");t=r(!1),t.push([e.i,"label.toggle{cursor:pointer;height:auto;width:auto}input[type=checkbox].toggle{display:none}input[type=checkbox].toggle+div{vertical-align:middle;width:40px;height:20px;border-radius:999px;background-color:#d7d7dd;transition-duration:.4s;transition-property:background-color,box-shadow;box-shadow:inset 0 0 0 0 rgba(151,109,109,.4)}input[type=checkbox].toggle:checked+div{width:40px;background-position:0 0;background-color:#199e54}input[type=checkbox].toggle+div>div{float:left;width:18px;height:18px;border-radius:inherit;background:#fff;transition-property:transform,background-color,box-shadow;transition-timing-function:cubic-bezier(.54,1.85,.5,1);transition-duration:.4s;transition-property:transform,background-color;pointer-events:none;margin-top:1px;margin-left:1px}input[type=checkbox].toggle:checked+div>div{transform:translate3d(20px,0,0);background-color:#fff}",""]),e.exports=t},fb15:function(e,t,n){"use strict";if(n.r(t),"undefined"!==typeof window){var r=window.document.currentScript,o=n("8875");r=o(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:o});var i=r&&r.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);i&&(n.p=i[1])}var c=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("label",{staticClass:"toggle"},[n("input",{staticClass:"toggle",attrs:{type:"checkbox","false-value":e.invert?1:0,"true-value":e.invert?0:1},domProps:{value:e.value,checked:e.active},on:{click:e.emitToggle}}),n("div",{style:e.checkboxStyles},[n("div")])])},a=[],u={name:"ToggleCheckBox",props:{value:{type:Boolean,required:!0},offColor:{type:String,default:"lightgray"},onColor:{type:String,default:"blue"},invert:{type:Boolean,default:!1}},data:function(){return{active:this.value}},watch:{value:function(){this.active=this.value}},computed:{checkboxStyles:function(){return{backgroundColor:this.active?this.onColor:this.offColor}}},methods:{emitToggle:function(){this.$emit("input",!this.active),this.active=!this.active}}},s=u;n("b052");function d(e,t,n,r,o,i,c,a){var u,s="function"===typeof e?e.options:e;if(t&&(s.render=t,s.staticRenderFns=n,s._compiled=!0),r&&(s.functional=!0),i&&(s._scopeId="data-v-"+i),c?(u=function(e){e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,e||"undefined"===typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),o&&o.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(c)},s._ssrRegister=u):o&&(u=a?function(){o.call(this,(s.functional?this.parent:this).$root.$options.shadowRoot)}:o),u)if(s.functional){s._injectStyles=u;var d=s.render;s.render=function(e,t){return u.call(t),d(e,t)}}else{var l=s.beforeCreate;s.beforeCreate=l?[].concat(l,u):[u]}return{exports:e,options:s}}var l=d(s,c,a,!1,null,null,null),f=l.exports;t["default"]=f}})["default"]}));
(function(e,t){"object"===typeof exports&&"object"===typeof module?module.exports=t():"function"===typeof define&&define.amd?define([],t):"object"===typeof exports?exports["togglecheckbox"]=t():e["togglecheckbox"]=t()})("undefined"!==typeof self?self:this,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s="fb15")}({"24fb":function(e,t,n){"use strict";function r(e,t){var n=e[1]||"",r=e[3];if(!r)return n;if(t&&"function"===typeof btoa){var i=o(r),c=r.sources.map((function(e){return"/*# sourceURL=".concat(r.sourceRoot||"").concat(e," */")}));return[n].concat(c).concat([i]).join("\n")}return[n].join("\n")}function o(e){var t=btoa(unescape(encodeURIComponent(JSON.stringify(e)))),n="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(t);return"/*# ".concat(n," */")}e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n=r(t,e);return t[2]?"@media ".concat(t[2]," {").concat(n,"}"):n})).join("")},t.i=function(e,n,r){"string"===typeof e&&(e=[[null,e,""]]);var o={};if(r)for(var i=0;i<this.length;i++){var c=this[i][0];null!=c&&(o[c]=!0)}for(var a=0;a<e.length;a++){var u=[].concat(e[a]);r&&o[u[0]]||(n&&(u[2]?u[2]="".concat(n," and ").concat(u[2]):u[2]=n),t.push(u))}},t}},"499e":function(e,t,n){"use strict";function r(e,t){for(var n=[],r={},o=0;o<t.length;o++){var i=t[o],c=i[0],a=i[1],u=i[2],s=i[3],d={id:e+":"+o,css:a,media:u,sourceMap:s};r[c]?r[c].parts.push(d):n.push(r[c]={id:c,parts:[d]})}return n}n.r(t),n.d(t,"default",(function(){return h}));var o="undefined"!==typeof document;if("undefined"!==typeof DEBUG&&DEBUG&&!o)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var i={},c=o&&(document.head||document.getElementsByTagName("head")[0]),a=null,u=0,s=!1,d=function(){},l=null,f="data-vue-ssr-id",p="undefined"!==typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());function h(e,t,n,o){s=n,l=o||{};var c=r(e,t);return v(c),function(t){for(var n=[],o=0;o<c.length;o++){var a=c[o],u=i[a.id];u.refs--,n.push(u)}t?(c=r(e,t),v(c)):c=[];for(o=0;o<n.length;o++){u=n[o];if(0===u.refs){for(var s=0;s<u.parts.length;s++)u.parts[s]();delete i[u.id]}}}}function v(e){for(var t=0;t<e.length;t++){var n=e[t],r=i[n.id];if(r){r.refs++;for(var o=0;o<r.parts.length;o++)r.parts[o](n.parts[o]);for(;o<n.parts.length;o++)r.parts.push(m(n.parts[o]));r.parts.length>n.parts.length&&(r.parts.length=n.parts.length)}else{var c=[];for(o=0;o<n.parts.length;o++)c.push(m(n.parts[o]));i[n.id]={id:n.id,refs:1,parts:c}}}}function g(){var e=document.createElement("style");return e.type="text/css",c.appendChild(e),e}function m(e){var t,n,r=document.querySelector("style["+f+'~="'+e.id+'"]');if(r){if(s)return d;r.parentNode.removeChild(r)}if(p){var o=u++;r=a||(a=g()),t=y.bind(null,r,o,!1),n=y.bind(null,r,o,!0)}else r=g(),t=x.bind(null,r),n=function(){r.parentNode.removeChild(r)};return t(e),function(r){if(r){if(r.css===e.css&&r.media===e.media&&r.sourceMap===e.sourceMap)return;t(e=r)}else n()}}var b=function(){var e=[];return function(t,n){return e[t]=n,e.filter(Boolean).join("\n")}}();function y(e,t,n,r){var o=n?"":r.css;if(e.styleSheet)e.styleSheet.cssText=b(t,o);else{var i=document.createTextNode(o),c=e.childNodes;c[t]&&e.removeChild(c[t]),c.length?e.insertBefore(i,c[t]):e.appendChild(i)}}function x(e,t){var n=t.css,r=t.media,o=t.sourceMap;if(r&&e.setAttribute("media",r),l.ssrId&&e.setAttribute(f,t.id),o&&(n+="\n/*# sourceURL="+o.sources[0]+" */",n+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(o))))+" */"),e.styleSheet)e.styleSheet.cssText=n;else{while(e.firstChild)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(n))}}},8875:function(e,t,n){var r,o,i;(function(n,c){o=[],r=c,i="function"===typeof r?r.apply(t,o):r,void 0===i||(e.exports=i)})("undefined"!==typeof self&&self,(function(){function e(){var t=Object.getOwnPropertyDescriptor(document,"currentScript");if(!t&&"currentScript"in document&&document.currentScript)return document.currentScript;if(t&&t.get!==e&&document.currentScript)return document.currentScript;try{throw new Error}catch(p){var n,r,o,i=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,c=/@([^@]*):(\d+):(\d+)\s*$/gi,a=i.exec(p.stack)||c.exec(p.stack),u=a&&a[1]||!1,s=a&&a[2]||!1,d=document.location.href.replace(document.location.hash,""),l=document.getElementsByTagName("script");u===d&&(n=document.documentElement.outerHTML,r=new RegExp("(?:[^\\n]+?\\n){0,"+(s-2)+"}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*","i"),o=n.replace(r,"$1").trim());for(var f=0;f<l.length;f++){if("interactive"===l[f].readyState)return l[f];if(l[f].src===u)return l[f];if(u===d&&l[f].innerHTML&&l[f].innerHTML.trim()===o)return l[f]}return null}}return e}))},a1c7:function(e,t,n){var r=n("bc7d");"string"===typeof r&&(r=[[e.i,r,""]]),r.locals&&(e.exports=r.locals);var o=n("499e").default;o("b645f2d4",r,!0,{sourceMap:!1,shadowMode:!1})},b052:function(e,t,n){"use strict";var r=n("a1c7"),o=n.n(r);o.a},bc7d:function(e,t,n){var r=n("24fb");t=r(!1),t.push([e.i,"label.toggle{cursor:pointer;height:auto;width:auto}input[type=checkbox].toggle{display:none}input[type=checkbox].toggle+div{vertical-align:middle;width:40px;height:20px;border-radius:999px;background-color:#d7d7dd;transition-duration:.4s;transition-property:background-color,box-shadow;box-shadow:inset 0 0 0 0 rgba(151,109,109,.4)}input[type=checkbox].toggle:checked+div{width:40px;background-position:0 0;background-color:#199e54}input[type=checkbox].toggle+div>div{float:left;width:18px;height:18px;border-radius:inherit;background:#fff;transition-property:transform,background-color,box-shadow;transition-timing-function:cubic-bezier(.54,1.85,.5,1);transition-duration:.4s;transition-property:transform,background-color;pointer-events:none;margin-top:1px;margin-left:1px}input[type=checkbox].toggle:checked+div>div{transform:translate3d(20px,0,0);background-color:#fff}",""]),e.exports=t},fb15:function(e,t,n){"use strict";if(n.r(t),"undefined"!==typeof window){var r=window.document.currentScript,o=n("8875");r=o(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:o});var i=r&&r.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);i&&(n.p=i[1])}var c=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("label",{staticClass:"toggle"},[n("input",{staticClass:"toggle",attrs:{type:"checkbox"},domProps:{value:e.value,checked:e.invert?!e.active:e.active},on:{click:e.emitToggle}}),n("div",{style:e.checkboxStyles},[n("div")])])},a=[],u={name:"ToggleCheckBox",props:{value:{type:Boolean,required:!0},offColor:{type:String,default:"lightgray"},onColor:{type:String,default:"blue"},invert:{type:Boolean,default:!1}},data:function(){return{active:this.value}},watch:{value:function(){this.active=this.value}},computed:{checkboxStyles:function(){return{backgroundColor:this.active?this.onColor:this.offColor}}},methods:{emitToggle:function(){this.$emit("input",!this.active),this.active=!this.active}}},s=u;n("b052");function d(e,t,n,r,o,i,c,a){var u,s="function"===typeof e?e.options:e;if(t&&(s.render=t,s.staticRenderFns=n,s._compiled=!0),r&&(s.functional=!0),i&&(s._scopeId="data-v-"+i),c?(u=function(e){e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,e||"undefined"===typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),o&&o.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(c)},s._ssrRegister=u):o&&(u=a?function(){o.call(this,(s.functional?this.parent:this).$root.$options.shadowRoot)}:o),u)if(s.functional){s._injectStyles=u;var d=s.render;s.render=function(e,t){return u.call(t),d(e,t)}}else{var l=s.beforeCreate;s.beforeCreate=l?[].concat(l,u):[u]}return{exports:e,options:s}}var l=d(s,c,a,!1,null,null,null),f=l.exports;t["default"]=f}})["default"]}));
//# sourceMappingURL=togglecheckbox.umd.min.js.map
{
"name": "@thinknimble/togglecheckbox",
"version": "0.1.2",
"version": "0.1.3",
"main": "dist/togglecheckbox.common.js",

@@ -77,2 +77,2 @@ "scripts": {

]
}
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc