@vlalg-nimbus/nb-inputs 6.0.4 → 6.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/nb-inputs.js CHANGED
@@ -338,17 +338,17 @@ const ze = ["id"], Ae = ["id", "disabled", "value", "name"], Oe = ["for"], $e =
338
338
  emits: ["current-value", "changed"],
339
339
  setup(e, { emit: o }) {
340
340
  oe((t) => ({
341
- "0c22faaf": K.value,
342
- "7cf2a69b": R.value,
343
- "45a557e4": Z.value,
344
- "0911140e": H(x),
345
- e69e33ee: ee.value,
346
- "92a8a2dc": X.value,
347
- f98ceb84: y.value,
348
- "4fde7de5": Q.value,
349
- "5d8fd640": n.value,
350
- b681146c: Y.value,
351
- "4d59470d": a.value
341
+ "0e22b153": K.value,
342
+ "752e6b3f": R.value,
343
+ "45bd3dc0": Z.value,
344
+ "5856bcc6": H(x),
345
+ 33327636: ee.value,
346
+ e1ee4b94: X.value,
347
+ "8e0b463c": y.value,
348
+ "18b53789": Q.value,
349
+ d95eae38: n.value,
350
+ "12801eb4": Y.value,
351
+ "3c01949e": a.value
352
352
  })), ue(() => {
353
353
  q();
354
354
  });
@@ -407,7 +407,7 @@ const ze = ["id"], Ae = ["id", "disabled", "value", "name"], Oe = ["for"], $e =
407
407
  return t.activeHoverEffect ? t.colorHover : t.color;
408
408
  }), ee = l(() => {
409
409
  const t = u.value;
410
- return t.activeHoverEffect ? `${t.colorHover}80` : "";
410
+ return t.activeHoverEffect && t.background ? `${t.colorHover}80` : "";
411
411
  }), j = l(() => u.value.background ? "component-checkbox__item--with-background" : "component-checkbox__item--without-background"), a = l(() => {
412
412
  const t = u.value;
413
413
  return t.background ? "#ffffff" : t.textColor;
@@ -470,7 +470,7 @@ const ze = ["id"], Ae = ["id", "disabled", "value", "name"], Oe = ["for"], $e =
470
470
  ], 10, ze)
471
471
  ], 6)) : fe("", !0);
472
472
  }
473
- }), Be = /* @__PURE__ */ ve($e, [["__scopeId", "data-v-98f82380"]]), le = {
473
+ }), Be = /* @__PURE__ */ ve($e, [["__scopeId", "data-v-7f659856"]]), le = {
474
474
  NbInputRadio: Ie,
475
475
  NbInputCheckbox: Be
476
476
  }, we = {
@@ -1 +1 @@
1
- (function(e,O){typeof exports=="object"&&typeof module<"u"?module.exports=O(require("vue")):typeof define=="function"&&define.amd?define(["vue"],O):(e=typeof globalThis<"u"?globalThis:e||self,e.NbInputs=O(e.Vue))})(this,function(e){"use strict";const O="",Y=(t,o)=>{const s=t.__vccOpts||t;for(const[i,d]of o)s[i]=d;return s},Z=["id"],ee=["id","disabled","value","name"],te=["for"],ae=Y(Object.assign({name:"NbInputRadio",inheritAttrs:!1},{__name:"NbInputRadio",props:{nbId:{type:String,required:!0},display:{type:String,default:"b",validator:(t="b")=>{const o=t?t.toLowerCase():"";return["b","ib"].includes(o)}},groupName:{type:String,default:"",required:!0,validator:t=>t.toString().toLowerCase()},options:{type:Array,required:!0,default:()=>[],validator:t=>{if(!t.length)return!1;let o=!1;for(const s of t){const i=Object.keys(s);i.length!==2&&(o=!0),i.every(f=>["value","text"].includes(f))||(o=!0)}if(!o)return t}},currentOption:{type:[String,Number,Boolean],default:null},valueType:{type:String,default:"boolean",validator:t=>["boolean","string","number"].indexOf(t)!==-1},textColor:{type:String,default:"black"},color:{type:String,default:"#767676"},hoverEffect:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},activeHoverEffect:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},colorHover:{type:String,default:"#a6a6a6"},itemGap:{type:Number,default:15},internalGap:{type:Number,default:6},scale:{type:Number,default:1},disabled:{type:Boolean,default:!1,validator:t=>typeof t=="boolean"&&[!0,!1].includes(t)},fontFamily:{type:String,default:"'Lato', sans-serif"},fontSize:{type:String,default:"1.6em",validator:t=>t||"1.6em"},fontWeight:{type:Number,default:400,validator:t=>t||200}},emits:["current-value","changed"],setup(t,{emit:o}){e.useCssVars(l=>({"75d259e1":q.value,"96c9c666":J.value,"173e02f2":U.value,"2a49b0aa":e.unref(g),c463f2d2:F.value,"02cde372":P.value,"14c10358":M.value,b3e13f78:T.value})),e.onMounted(()=>{w()});const s=o,i=t,d=e.ref(null),{currentOption:f,valueType:C,display:k,options:b,textColor:V,color:S,hoverEffect:E,activeHoverEffect:N,colorHover:g,itemGap:p,internalGap:v,scale:h,disabled:H,fontFamily:z,fontSize:B,fontWeight:x}=e.toRefs(i),c=e.computed(()=>{const l=H.value?"component-disabled":"",r=k.value!=="b"?"inline-block":"block",m=z.value?z.value:"'Lato', sans-serif",G=B.value?B.value:"1.6em",I=!x.value||x.value<0?200:x.value,Q=V.value?V.value:"black",R=S.value?S.value:"#767676",a=[!1,!0].includes(E.value)?E.value:!1,u=[!1,!0].includes(N.value)?N.value:!1,y=g.value?g.value:"#a6a6a6",$=!p.value||p.value<0?15:p.value,A=!v.value||v.value<0?6:v.value,X=!h.value||h.value<0?1:h.value;return{disabled:l,display:r,textColor:Q,color:R,hoverEffect:a,activeHoverEffect:u,colorHover:y,itemGap:$,internalGap:A,scale:X,font:m,fontSize:G,fontWeight:I}}),_=e.computed(()=>c.value.disabled),n=e.computed(()=>({display:c.value.display})),W=e.computed(()=>c.value.display==="inline-block"?"component-radio__item--display-inline":"component-radio__item--display-block"),j=e.computed(()=>{const l=c.value;return{fontSize:l.fontSize,fontWeight:l.fontWeight}}),D=e.computed(()=>Array.isArray(b.value)&&b.value.constructor===Array&&b.value.length>0),q=e.computed(()=>c.value.font),F=e.computed(()=>c.value.textColor),T=e.computed(()=>c.value.color),M=e.computed(()=>{const l=c.value;return l.hoverEffect?l.colorHover:l.color}),U=e.computed(()=>{const l=c.value;return l.activeHoverEffect?l.colorHover:l.color}),P=e.computed(()=>{const r=c.value.internalGap;return!r||r<0?0:`${r}px`}),J=e.computed(()=>{const r=c.value.itemGap;return!r||r<0?0:`${r}px`}),K=e.computed(()=>({zoom:c.value.scale})),w=()=>{const l=f.value;l&&(["string"].includes(C.value)?d.value=l.toString().toLowerCase():d.value=l)};return e.watch(f,(l,r)=>{l!==r&&w()}),e.watch(d,(l,r)=>{l!==r&&(s("current-value",l),s("changed",l))}),(l,r)=>t.nbId&&D.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["nb-wrapper",_.value]),style:e.normalizeStyle([n.value,K.value])},[e.createElementVNode("div",{id:t.nbId,class:e.normalizeClass(["nb-reset","component",W.value])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(b),(m,G)=>(e.openBlock(),e.createElementBlock("div",{key:G,class:"component-radio__item"},[e.withDirectives(e.createElementVNode("input",{id:`${t.nbId}-${m.value}`,"onUpdate:modelValue":r[0]||(r[0]=I=>d.value=I),type:"radio",class:"component-radio__item--input",disabled:e.unref(H),value:m.value,name:t.groupName},null,8,ee),[[e.vModelRadio,d.value]]),e.createElementVNode("label",{for:`${t.nbId}-${m.value}`,class:"component-radio__item--label"},[r[1]||(r[1]=e.createElementVNode("div",null,null,-1)),e.createElementVNode("span",{style:e.normalizeStyle([j.value])},e.toDisplayString(m.text),5)],8,te)]))),128))],10,Z)],6)):e.createCommentVNode("",!0)}}),[["__scopeId","data-v-7eeedc4c"]]),be="",le=["id"],oe=["id","disabled","value","name"],ne=["for"],L={NbInputRadio:ae,NbInputCheckbox:Y(Object.assign({name:"NbInputCheckbox",inheritAttrs:!1},{__name:"NbInputCheckbox",props:{nbId:{type:String,required:!0},display:{type:String,default:"b",validator:(t="b")=>{const o=t?t.toLowerCase():"";return["b","ib"].includes(o)}},groupName:{type:String,default:"",required:!0,validator:t=>t.toString().toLowerCase()},options:{type:Array,required:!0,default:()=>[],validator:t=>{if(!t.length)return!1;let o=!1;for(const s of t){const i=Object.keys(s);i.length!==2&&(o=!0),i.every(f=>["value","text"].includes(f))||(o=!0)}if(!o)return t}},currentOption:{type:Array,default:()=>[]},textColor:{type:String,default:"black"},boxRadius:{type:Number,default:0},color:{type:String,default:"#767676"},hoverEffect:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},activeHoverEffect:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},colorHover:{type:String,default:"#a6a6a6"},itemGap:{type:Number,default:15},internalGap:{type:Number,default:6},scale:{type:Number,default:1},type:{type:String,default:"box",validator:t=>["box","circle"].indexOf(t)!==-1},background:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},disabled:{type:Boolean,default:!1,validator:t=>typeof t=="boolean"&&[!0,!1].includes(t)},fontFamily:{type:String,default:"'Lato', sans-serif"},fontSize:{type:String,default:"1.6em",validator:t=>t||"1.6em"},fontWeight:{type:Number,default:400,validator:t=>t||200}},emits:["current-value","changed"],setup(t,{emit:o}){e.useCssVars(a=>({"0c22faaf":T.value,"7cf2a69b":G.value,"45a557e4":J.value,"0911140e":e.unref(g),e69e33ee:K.value,"92a8a2dc":U.value,f98ceb84:m.value,"4fde7de5":M.value,"5d8fd640":r.value,b681146c:P.value,"4d59470d":l.value})),e.onMounted(()=>{R()});const s=o,i=t,d=e.ref(null),{currentOption:f,display:C,options:k,textColor:b,boxRadius:V,color:S,hoverEffect:E,activeHoverEffect:N,colorHover:g,itemGap:p,internalGap:v,scale:h,type:H,background:z,disabled:B,fontFamily:x,fontSize:c,fontWeight:_}=e.toRefs(i),n=e.computed(()=>{const a=B.value?"component-disabled":"",u=C.value!=="b"?"inline-block":"block",y=x.value?x.value:"'Lato', sans-serif",$=c.value?c.value:"1.6em",A=_.value!==0&&!_.value||_.value<0?200:_.value,X=b.value?b.value:"black",re=V.value!==0&&!V.value||V.value<0?0:V.value,ue=S.value?S.value:"#767676",se=[!1,!0].includes(E.value)?E.value:!1,ce=[!1,!0].includes(N.value)?N.value:!1,de=g.value?g.value:"#a6a6a6",ie=p.value!==0&&!p.value||p.value<0?15:p.value,fe=v.value!==0&&!v.value||v.value<0?6:v.value,pe=["box","circle"].includes(H.value)?H.value:"box",ve=!h.value||h.value<0?1:h.value,me=[!1,!0].includes(z.value)?z.value:!1;return{disabled:a,display:u,textColor:X,boxRadius:re,color:ue,hoverEffect:se,activeHoverEffect:ce,colorHover:de,itemGap:ie,internalGap:fe,scale:ve,type:pe,font:y,background:me,fontSize:$,fontWeight:A}}),W=e.computed(()=>n.value.disabled),j=e.computed(()=>({display:n.value.display})),D=e.computed(()=>n.value.display==="inline-block"?"component-checkbox__item--display-inline":"component-checkbox__item--display-block"),q=e.computed(()=>{const a=n.value;return{fontSize:a.fontSize,fontWeight:a.fontWeight}}),F=e.computed(()=>Array.isArray(k.value)&&k.value.constructor===Array&&k.value.length>0),T=e.computed(()=>n.value.font),M=e.computed(()=>n.value.textColor),U=e.computed(()=>n.value.color),P=e.computed(()=>{const a=n.value;return a.hoverEffect?a.colorHover:a.color}),J=e.computed(()=>{const a=n.value;return a.activeHoverEffect?a.colorHover:a.color}),K=e.computed(()=>{const a=n.value;return a.activeHoverEffect?`${a.colorHover}80`:""}),w=e.computed(()=>n.value.background?"component-checkbox__item--with-background":"component-checkbox__item--without-background"),l=e.computed(()=>{const a=n.value;return a.background?"#ffffff":a.textColor});e.computed(()=>n.value.background?"19px":"auto");const r=e.computed(()=>{const u=n.value.internalGap;return!u||u<0?0:`${u}px`}),m=e.computed(()=>{const a=n.value;return`${a.boxRadius>7?7:a.boxRadius}px`}),G=e.computed(()=>{const u=n.value.itemGap;return!u||u<0?0:`${u}px`}),I=e.computed(()=>n.value.type==="circle"?"custom-checkbox__input--type-circle":""),Q=e.computed(()=>({zoom:n.value.scale})),R=()=>{d.value=f.value};return e.watch(f,(a,u)=>{a!==u&&R()}),e.watch(d,(a,u)=>{a!==u&&(s("current-value",a),s("changed",a))}),(a,u)=>t.nbId&&F.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["nb-wrapper",W.value]),style:e.normalizeStyle([j.value,Q.value])},[e.createElementVNode("div",{id:t.nbId,class:e.normalizeClass(["nb-reset","component",D.value])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(k),(y,$)=>(e.openBlock(),e.createElementBlock("div",{key:$,class:"component-checkbox__item"},[e.withDirectives(e.createElementVNode("input",{id:`${t.nbId}-${y.value}`,"onUpdate:modelValue":u[0]||(u[0]=A=>d.value=A),type:"checkbox",class:"component-checkbox__item--input",disabled:e.unref(B),value:y.value,name:t.groupName},null,8,oe),[[e.vModelCheckbox,d.value]]),e.createElementVNode("label",{for:`${t.nbId}-${y.value}`,class:e.normalizeClass([[I.value],"component-checkbox__item--label"])},[e.createElementVNode("div",{class:e.normalizeClass([w.value])},null,2),e.createElementVNode("span",{style:e.normalizeStyle([q.value])},e.toDisplayString(y.text),5)],10,ne)]))),128))],10,le)],6)):e.createCommentVNode("",!0)}}),[["__scopeId","data-v-98f82380"]])};return{install(t){for(const o in L)if(Object.prototype.hasOwnProperty.call(L,o)){const s=L[o];t.component(s.name,s)}}}});
1
+ (function(e,O){typeof exports=="object"&&typeof module<"u"?module.exports=O(require("vue")):typeof define=="function"&&define.amd?define(["vue"],O):(e=typeof globalThis<"u"?globalThis:e||self,e.NbInputs=O(e.Vue))})(this,function(e){"use strict";const O="",Y=(t,o)=>{const s=t.__vccOpts||t;for(const[i,d]of o)s[i]=d;return s},Z=["id"],ee=["id","disabled","value","name"],te=["for"],ae=Y(Object.assign({name:"NbInputRadio",inheritAttrs:!1},{__name:"NbInputRadio",props:{nbId:{type:String,required:!0},display:{type:String,default:"b",validator:(t="b")=>{const o=t?t.toLowerCase():"";return["b","ib"].includes(o)}},groupName:{type:String,default:"",required:!0,validator:t=>t.toString().toLowerCase()},options:{type:Array,required:!0,default:()=>[],validator:t=>{if(!t.length)return!1;let o=!1;for(const s of t){const i=Object.keys(s);i.length!==2&&(o=!0),i.every(f=>["value","text"].includes(f))||(o=!0)}if(!o)return t}},currentOption:{type:[String,Number,Boolean],default:null},valueType:{type:String,default:"boolean",validator:t=>["boolean","string","number"].indexOf(t)!==-1},textColor:{type:String,default:"black"},color:{type:String,default:"#767676"},hoverEffect:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},activeHoverEffect:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},colorHover:{type:String,default:"#a6a6a6"},itemGap:{type:Number,default:15},internalGap:{type:Number,default:6},scale:{type:Number,default:1},disabled:{type:Boolean,default:!1,validator:t=>typeof t=="boolean"&&[!0,!1].includes(t)},fontFamily:{type:String,default:"'Lato', sans-serif"},fontSize:{type:String,default:"1.6em",validator:t=>t||"1.6em"},fontWeight:{type:Number,default:400,validator:t=>t||200}},emits:["current-value","changed"],setup(t,{emit:o}){e.useCssVars(l=>({"75d259e1":q.value,"96c9c666":J.value,"173e02f2":U.value,"2a49b0aa":e.unref(g),c463f2d2:F.value,"02cde372":P.value,"14c10358":M.value,b3e13f78:T.value})),e.onMounted(()=>{w()});const s=o,i=t,d=e.ref(null),{currentOption:f,valueType:C,display:k,options:y,textColor:V,color:S,hoverEffect:E,activeHoverEffect:N,colorHover:g,itemGap:p,internalGap:v,scale:h,disabled:H,fontFamily:z,fontSize:B,fontWeight:x}=e.toRefs(i),c=e.computed(()=>{const l=H.value?"component-disabled":"",r=k.value!=="b"?"inline-block":"block",m=z.value?z.value:"'Lato', sans-serif",G=B.value?B.value:"1.6em",I=!x.value||x.value<0?200:x.value,Q=V.value?V.value:"black",R=S.value?S.value:"#767676",a=[!1,!0].includes(E.value)?E.value:!1,u=[!1,!0].includes(N.value)?N.value:!1,b=g.value?g.value:"#a6a6a6",$=!p.value||p.value<0?15:p.value,A=!v.value||v.value<0?6:v.value,X=!h.value||h.value<0?1:h.value;return{disabled:l,display:r,textColor:Q,color:R,hoverEffect:a,activeHoverEffect:u,colorHover:b,itemGap:$,internalGap:A,scale:X,font:m,fontSize:G,fontWeight:I}}),_=e.computed(()=>c.value.disabled),n=e.computed(()=>({display:c.value.display})),W=e.computed(()=>c.value.display==="inline-block"?"component-radio__item--display-inline":"component-radio__item--display-block"),j=e.computed(()=>{const l=c.value;return{fontSize:l.fontSize,fontWeight:l.fontWeight}}),D=e.computed(()=>Array.isArray(y.value)&&y.value.constructor===Array&&y.value.length>0),q=e.computed(()=>c.value.font),F=e.computed(()=>c.value.textColor),T=e.computed(()=>c.value.color),M=e.computed(()=>{const l=c.value;return l.hoverEffect?l.colorHover:l.color}),U=e.computed(()=>{const l=c.value;return l.activeHoverEffect?l.colorHover:l.color}),P=e.computed(()=>{const r=c.value.internalGap;return!r||r<0?0:`${r}px`}),J=e.computed(()=>{const r=c.value.itemGap;return!r||r<0?0:`${r}px`}),K=e.computed(()=>({zoom:c.value.scale})),w=()=>{const l=f.value;l&&(["string"].includes(C.value)?d.value=l.toString().toLowerCase():d.value=l)};return e.watch(f,(l,r)=>{l!==r&&w()}),e.watch(d,(l,r)=>{l!==r&&(s("current-value",l),s("changed",l))}),(l,r)=>t.nbId&&D.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["nb-wrapper",_.value]),style:e.normalizeStyle([n.value,K.value])},[e.createElementVNode("div",{id:t.nbId,class:e.normalizeClass(["nb-reset","component",W.value])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(y),(m,G)=>(e.openBlock(),e.createElementBlock("div",{key:G,class:"component-radio__item"},[e.withDirectives(e.createElementVNode("input",{id:`${t.nbId}-${m.value}`,"onUpdate:modelValue":r[0]||(r[0]=I=>d.value=I),type:"radio",class:"component-radio__item--input",disabled:e.unref(H),value:m.value,name:t.groupName},null,8,ee),[[e.vModelRadio,d.value]]),e.createElementVNode("label",{for:`${t.nbId}-${m.value}`,class:"component-radio__item--label"},[r[1]||(r[1]=e.createElementVNode("div",null,null,-1)),e.createElementVNode("span",{style:e.normalizeStyle([j.value])},e.toDisplayString(m.text),5)],8,te)]))),128))],10,Z)],6)):e.createCommentVNode("",!0)}}),[["__scopeId","data-v-7eeedc4c"]]),ye="",le=["id"],oe=["id","disabled","value","name"],ne=["for"],L={NbInputRadio:ae,NbInputCheckbox:Y(Object.assign({name:"NbInputCheckbox",inheritAttrs:!1},{__name:"NbInputCheckbox",props:{nbId:{type:String,required:!0},display:{type:String,default:"b",validator:(t="b")=>{const o=t?t.toLowerCase():"";return["b","ib"].includes(o)}},groupName:{type:String,default:"",required:!0,validator:t=>t.toString().toLowerCase()},options:{type:Array,required:!0,default:()=>[],validator:t=>{if(!t.length)return!1;let o=!1;for(const s of t){const i=Object.keys(s);i.length!==2&&(o=!0),i.every(f=>["value","text"].includes(f))||(o=!0)}if(!o)return t}},currentOption:{type:Array,default:()=>[]},textColor:{type:String,default:"black"},boxRadius:{type:Number,default:0},color:{type:String,default:"#767676"},hoverEffect:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},activeHoverEffect:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},colorHover:{type:String,default:"#a6a6a6"},itemGap:{type:Number,default:15},internalGap:{type:Number,default:6},scale:{type:Number,default:1},type:{type:String,default:"box",validator:t=>["box","circle"].indexOf(t)!==-1},background:{type:Boolean,default:!1,validator:t=>[!0,!1].indexOf(t)!==-1},disabled:{type:Boolean,default:!1,validator:t=>typeof t=="boolean"&&[!0,!1].includes(t)},fontFamily:{type:String,default:"'Lato', sans-serif"},fontSize:{type:String,default:"1.6em",validator:t=>t||"1.6em"},fontWeight:{type:Number,default:400,validator:t=>t||200}},emits:["current-value","changed"],setup(t,{emit:o}){e.useCssVars(a=>({"0e22b153":T.value,"752e6b3f":G.value,"45bd3dc0":J.value,"5856bcc6":e.unref(g),33327636:K.value,e1ee4b94:U.value,"8e0b463c":m.value,"18b53789":M.value,d95eae38:r.value,"12801eb4":P.value,"3c01949e":l.value})),e.onMounted(()=>{R()});const s=o,i=t,d=e.ref(null),{currentOption:f,display:C,options:k,textColor:y,boxRadius:V,color:S,hoverEffect:E,activeHoverEffect:N,colorHover:g,itemGap:p,internalGap:v,scale:h,type:H,background:z,disabled:B,fontFamily:x,fontSize:c,fontWeight:_}=e.toRefs(i),n=e.computed(()=>{const a=B.value?"component-disabled":"",u=C.value!=="b"?"inline-block":"block",b=x.value?x.value:"'Lato', sans-serif",$=c.value?c.value:"1.6em",A=_.value!==0&&!_.value||_.value<0?200:_.value,X=y.value?y.value:"black",re=V.value!==0&&!V.value||V.value<0?0:V.value,ue=S.value?S.value:"#767676",se=[!1,!0].includes(E.value)?E.value:!1,ce=[!1,!0].includes(N.value)?N.value:!1,de=g.value?g.value:"#a6a6a6",ie=p.value!==0&&!p.value||p.value<0?15:p.value,fe=v.value!==0&&!v.value||v.value<0?6:v.value,pe=["box","circle"].includes(H.value)?H.value:"box",ve=!h.value||h.value<0?1:h.value,me=[!1,!0].includes(z.value)?z.value:!1;return{disabled:a,display:u,textColor:X,boxRadius:re,color:ue,hoverEffect:se,activeHoverEffect:ce,colorHover:de,itemGap:ie,internalGap:fe,scale:ve,type:pe,font:b,background:me,fontSize:$,fontWeight:A}}),W=e.computed(()=>n.value.disabled),j=e.computed(()=>({display:n.value.display})),D=e.computed(()=>n.value.display==="inline-block"?"component-checkbox__item--display-inline":"component-checkbox__item--display-block"),q=e.computed(()=>{const a=n.value;return{fontSize:a.fontSize,fontWeight:a.fontWeight}}),F=e.computed(()=>Array.isArray(k.value)&&k.value.constructor===Array&&k.value.length>0),T=e.computed(()=>n.value.font),M=e.computed(()=>n.value.textColor),U=e.computed(()=>n.value.color),P=e.computed(()=>{const a=n.value;return a.hoverEffect?a.colorHover:a.color}),J=e.computed(()=>{const a=n.value;return a.activeHoverEffect?a.colorHover:a.color}),K=e.computed(()=>{const a=n.value;return a.activeHoverEffect&&a.background?`${a.colorHover}80`:""}),w=e.computed(()=>n.value.background?"component-checkbox__item--with-background":"component-checkbox__item--without-background"),l=e.computed(()=>{const a=n.value;return a.background?"#ffffff":a.textColor});e.computed(()=>n.value.background?"19px":"auto");const r=e.computed(()=>{const u=n.value.internalGap;return!u||u<0?0:`${u}px`}),m=e.computed(()=>{const a=n.value;return`${a.boxRadius>7?7:a.boxRadius}px`}),G=e.computed(()=>{const u=n.value.itemGap;return!u||u<0?0:`${u}px`}),I=e.computed(()=>n.value.type==="circle"?"custom-checkbox__input--type-circle":""),Q=e.computed(()=>({zoom:n.value.scale})),R=()=>{d.value=f.value};return e.watch(f,(a,u)=>{a!==u&&R()}),e.watch(d,(a,u)=>{a!==u&&(s("current-value",a),s("changed",a))}),(a,u)=>t.nbId&&F.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["nb-wrapper",W.value]),style:e.normalizeStyle([j.value,Q.value])},[e.createElementVNode("div",{id:t.nbId,class:e.normalizeClass(["nb-reset","component",D.value])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(k),(b,$)=>(e.openBlock(),e.createElementBlock("div",{key:$,class:"component-checkbox__item"},[e.withDirectives(e.createElementVNode("input",{id:`${t.nbId}-${b.value}`,"onUpdate:modelValue":u[0]||(u[0]=A=>d.value=A),type:"checkbox",class:"component-checkbox__item--input",disabled:e.unref(B),value:b.value,name:t.groupName},null,8,oe),[[e.vModelCheckbox,d.value]]),e.createElementVNode("label",{for:`${t.nbId}-${b.value}`,class:e.normalizeClass([[I.value],"component-checkbox__item--label"])},[e.createElementVNode("div",{class:e.normalizeClass([w.value])},null,2),e.createElementVNode("span",{style:e.normalizeStyle([q.value])},e.toDisplayString(b.text),5)],10,ne)]))),128))],10,le)],6)):e.createCommentVNode("",!0)}}),[["__scopeId","data-v-7f659856"]])};return{install(t){for(const o in L)if(Object.prototype.hasOwnProperty.call(L,o)){const s=L[o];t.component(s.name,s)}}}});
package/dist/style.css CHANGED
@@ -1 +1 @@
1
- @charset "UTF-8";@import"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap";.nb-wrapper[data-v-7eeedc4c]{margin:0;padding:0;font-size:62.5%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;vertical-align:text-bottom}.nb-reset[data-v-7eeedc4c]{font-family:Lato,sans-serif;font-style:normal;font-weight:light;line-height:1.42857143}.nb-reset[data-v-7eeedc4c] *{margin:0;padding:0}.nb-reset[data-v-7eeedc4c] *,.nb-reset[data-v-7eeedc4c] *:before,.nb-reset[data-v-7eeedc4c] *:after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.component[data-v-7eeedc4c]{margin:0;box-sizing:border-box;line-height:16px;font-family:Lato,sans-serif;font-family:var(--75d259e1);-webkit-user-select:none;user-select:none;touch-action:manipulation;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-align:left;-webkit-text-decoration-line:none;text-decoration-line:none;white-space:nowrap;outline:0;position:relative}.component.component-radio__item--display-block[data-v-7eeedc4c],.component.component-radio__item--display-inline[data-v-7eeedc4c]{display:flex;flex-wrap:wrap;gap:var(--96c9c666);width:auto;word-break:break-word;overflow-wrap:break-word;white-space:normal}.component.component-radio__item--display-block[data-v-7eeedc4c]{flex-direction:column}.component.component-radio__item--display-inline[data-v-7eeedc4c]{flex-direction:row}.component .component-radio__item[data-v-7eeedc4c]{position:relative}.component .component-radio__item .component-radio__item--input[data-v-7eeedc4c]{display:none}.component .component-radio__item .component-radio__item--input:checked+.component-radio__item--label:hover div[data-v-7eeedc4c]{border:2px solid var(--173e02f2);color:var(--173e02f2)}.component .component-radio__item .component-radio__item--input:checked+.component-radio__item--label div[data-v-7eeedc4c]:before{content:"⏺";font-size:1.3em;text-shadow:0;display:flex;align-items:center;text-align:center;justify-content:center;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;color:var(--2a49b0aa);border-radius:50%}.component .component-radio__item .component-radio__item--label[data-v-7eeedc4c]{--disabled-color: var(--c463f2d2);color:var(--disabled-color)!important;display:flex;flex-direction:row;gap:var(--02cde372);align-items:center}.component .component-radio__item .component-radio__item--label[data-v-7eeedc4c]:hover{cursor:pointer}.component .component-radio__item .component-radio__item--label:hover div[data-v-7eeedc4c]{border:2px solid var(--14c10358)}.component .component-radio__item .component-radio__item--label div[data-v-7eeedc4c]{width:19px;height:19px;flex-shrink:0;border-radius:50%;text-shadow:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;border:2px solid var(--b3e13f78);font-family:Lato,sans-serif!important}.component-disabled[data-v-7eeedc4c]{cursor:not-allowed;pointer-events:none;-webkit-user-select:none;user-select:none}.component-disabled .component[data-v-7eeedc4c]{--disabled-color: var(--c463f2d2);color:var(--disabled-color)!important;opacity:.7;border-radius:inherit}.nb-wrapper[data-v-98f82380]{margin:0;padding:0;font-size:62.5%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;vertical-align:text-bottom}.nb-reset[data-v-98f82380]{font-family:Lato,sans-serif;font-style:normal;font-weight:light;line-height:1.42857143}.nb-reset[data-v-98f82380] *{margin:0;padding:0}.nb-reset[data-v-98f82380] *,.nb-reset[data-v-98f82380] *:before,.nb-reset[data-v-98f82380] *:after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.component[data-v-98f82380]{margin:0;box-sizing:border-box;line-height:16px;font-family:Lato,sans-serif;font-family:var(--0c22faaf);-webkit-user-select:none;user-select:none;touch-action:manipulation;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-align:left;-webkit-text-decoration-line:none;text-decoration-line:none;white-space:nowrap;outline:0;position:relative}.component.component-checkbox__item--display-block[data-v-98f82380],.component.component-checkbox__item--display-inline[data-v-98f82380]{display:flex;flex-wrap:wrap;gap:var(--7cf2a69b);width:auto;word-break:break-word;overflow-wrap:break-word;white-space:normal}.component.component-checkbox__item--display-block[data-v-98f82380]{flex-direction:column}.component.component-checkbox__item--display-inline[data-v-98f82380]{flex-direction:row}.component .component-checkbox__item[data-v-98f82380]{position:relative}.component .component-checkbox__item .component-checkbox__item--input[data-v-98f82380]{display:none}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label:hover div.component-checkbox__item--without-background[data-v-98f82380]{border:2px solid var(--45a557e4);color:var(--0911140e)}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label:hover div.component-checkbox__item--with-background[data-v-98f82380]{background:var(--e69e33ee)}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div[data-v-98f82380]{font-size:1.2em}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div.component-checkbox__item--without-background[data-v-98f82380]{border:2px solid var(--92a8a2dc);color:var(--0911140e)}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div.component-checkbox__item--with-background[data-v-98f82380]{border:2px solid var(--0911140e)}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div[data-v-98f82380]:before{content:"";text-shadow:0;display:flex;align-items:center;text-align:center;justify-content:center;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;border-radius:var(--f98ceb84);border:0}.component .component-checkbox__item .component-checkbox__item--label[data-v-98f82380]{--disabled-color: var(--4fde7de5);color:var(--disabled-color)!important;display:flex;flex-direction:row;gap:var(--5d8fd640);align-items:center}.component .component-checkbox__item .component-checkbox__item--label[data-v-98f82380]:hover{cursor:pointer}.component .component-checkbox__item .component-checkbox__item--label:hover div.component-checkbox__item--without-background[data-v-98f82380],.component .component-checkbox__item .component-checkbox__item--label:hover div.component-checkbox__item--with-background[data-v-98f82380]{border:2px solid var(--b681146c)}.component .component-checkbox__item .component-checkbox__item--label div[data-v-98f82380]{width:19px;height:19px;flex-shrink:0;text-shadow:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;border-radius:var(--f98ceb84);font-family:Lato,sans-serif!important;font-weight:700}.component .component-checkbox__item .component-checkbox__item--label div.component-checkbox__item--without-background[data-v-98f82380]{border:2px solid var(--92a8a2dc);color:var(--92a8a2dc)}.component .component-checkbox__item .component-checkbox__item--label div.component-checkbox__item--with-background[data-v-98f82380]{border:2px solid var(--92a8a2dc);color:var(--4d59470d)}.component .component-checkbox__item .component-checkbox__item--label.custom-checkbox__input--type-circle div[data-v-98f82380]{border-radius:50%!important}.component .component-checkbox__item .component-checkbox__item--label.custom-checkbox__input--type-circle div[data-v-98f82380]:before{border-radius:50%!important}.component-disabled[data-v-98f82380]{cursor:not-allowed;pointer-events:none;-webkit-user-select:none;user-select:none}.component-disabled .component[data-v-98f82380]{--disabled-color: var(--4fde7de5);color:var(--disabled-color)!important;opacity:.4;border-radius:inherit}.component-disabled .component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div.component-checkbox__item--without-background[data-v-98f82380]{border:2px solid var(--45a557e4);color:var(--0911140e)}.component-disabled .component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div.component-checkbox__item--with-background[data-v-98f82380]{background:var(--e69e33ee)}
1
+ @charset "UTF-8";@import"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap";.nb-wrapper[data-v-7eeedc4c]{margin:0;padding:0;font-size:62.5%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;vertical-align:text-bottom}.nb-reset[data-v-7eeedc4c]{font-family:Lato,sans-serif;font-style:normal;font-weight:light;line-height:1.42857143}.nb-reset[data-v-7eeedc4c] *{margin:0;padding:0}.nb-reset[data-v-7eeedc4c] *,.nb-reset[data-v-7eeedc4c] *:before,.nb-reset[data-v-7eeedc4c] *:after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.component[data-v-7eeedc4c]{margin:0;box-sizing:border-box;line-height:16px;font-family:Lato,sans-serif;font-family:var(--75d259e1);-webkit-user-select:none;user-select:none;touch-action:manipulation;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-align:left;-webkit-text-decoration-line:none;text-decoration-line:none;white-space:nowrap;outline:0;position:relative}.component.component-radio__item--display-block[data-v-7eeedc4c],.component.component-radio__item--display-inline[data-v-7eeedc4c]{display:flex;flex-wrap:wrap;gap:var(--96c9c666);width:auto;word-break:break-word;overflow-wrap:break-word;white-space:normal}.component.component-radio__item--display-block[data-v-7eeedc4c]{flex-direction:column}.component.component-radio__item--display-inline[data-v-7eeedc4c]{flex-direction:row}.component .component-radio__item[data-v-7eeedc4c]{position:relative}.component .component-radio__item .component-radio__item--input[data-v-7eeedc4c]{display:none}.component .component-radio__item .component-radio__item--input:checked+.component-radio__item--label:hover div[data-v-7eeedc4c]{border:2px solid var(--173e02f2);color:var(--173e02f2)}.component .component-radio__item .component-radio__item--input:checked+.component-radio__item--label div[data-v-7eeedc4c]:before{content:"⏺";font-size:1.3em;text-shadow:0;display:flex;align-items:center;text-align:center;justify-content:center;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;color:var(--2a49b0aa);border-radius:50%}.component .component-radio__item .component-radio__item--label[data-v-7eeedc4c]{--disabled-color: var(--c463f2d2);color:var(--disabled-color)!important;display:flex;flex-direction:row;gap:var(--02cde372);align-items:center}.component .component-radio__item .component-radio__item--label[data-v-7eeedc4c]:hover{cursor:pointer}.component .component-radio__item .component-radio__item--label:hover div[data-v-7eeedc4c]{border:2px solid var(--14c10358)}.component .component-radio__item .component-radio__item--label div[data-v-7eeedc4c]{width:19px;height:19px;flex-shrink:0;border-radius:50%;text-shadow:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;border:2px solid var(--b3e13f78);font-family:Lato,sans-serif!important}.component-disabled[data-v-7eeedc4c]{cursor:not-allowed;pointer-events:none;-webkit-user-select:none;user-select:none}.component-disabled .component[data-v-7eeedc4c]{--disabled-color: var(--c463f2d2);color:var(--disabled-color)!important;opacity:.7;border-radius:inherit}.nb-wrapper[data-v-7f659856]{margin:0;padding:0;font-size:62.5%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;vertical-align:text-bottom}.nb-reset[data-v-7f659856]{font-family:Lato,sans-serif;font-style:normal;font-weight:light;line-height:1.42857143}.nb-reset[data-v-7f659856] *{margin:0;padding:0}.nb-reset[data-v-7f659856] *,.nb-reset[data-v-7f659856] *:before,.nb-reset[data-v-7f659856] *:after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.component[data-v-7f659856]{margin:0;box-sizing:border-box;line-height:16px;font-family:Lato,sans-serif;font-family:var(--0e22b153);-webkit-user-select:none;user-select:none;touch-action:manipulation;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-align:left;-webkit-text-decoration-line:none;text-decoration-line:none;white-space:nowrap;outline:0;position:relative}.component.component-checkbox__item--display-block[data-v-7f659856],.component.component-checkbox__item--display-inline[data-v-7f659856]{display:flex;flex-wrap:wrap;gap:var(--752e6b3f);width:auto;word-break:break-word;overflow-wrap:break-word;white-space:normal}.component.component-checkbox__item--display-block[data-v-7f659856]{flex-direction:column}.component.component-checkbox__item--display-inline[data-v-7f659856]{flex-direction:row}.component .component-checkbox__item[data-v-7f659856]{position:relative}.component .component-checkbox__item .component-checkbox__item--input[data-v-7f659856]{display:none}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label:hover div.component-checkbox__item--without-background[data-v-7f659856]{border:2px solid var(--45bd3dc0);color:var(--5856bcc6)}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label:hover div.component-checkbox__item--with-background[data-v-7f659856]{background:var(--33327636)}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label.custom-checkbox__input--type-circle div[data-v-7f659856]:before{margin-top:0;margin-left:-1px}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label.custom-checkbox__input--type-circle div.component-checkbox__item--without-background[data-v-7f659856]{font-size:1em}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label.custom-checkbox__input--type-circle div.component-checkbox__item--with-background[data-v-7f659856]{font-size:1em}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div.component-checkbox__item--without-background[data-v-7f659856]{font-size:1.2em;border:2px solid var(--e1ee4b94);color:var(--5856bcc6)}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div.component-checkbox__item--with-background[data-v-7f659856]{font-size:1.2em;border:2px solid var(--5856bcc6);background:var(--33327636)}.component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div[data-v-7f659856]:before{content:"";text-shadow:0;display:flex;align-items:center;text-align:center;justify-content:center;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;border-radius:var(--8e0b463c);border:0}.component .component-checkbox__item .component-checkbox__item--label[data-v-7f659856]{--disabled-color: var(--18b53789);color:var(--disabled-color)!important;display:flex;flex-direction:row;gap:var(--d95eae38);align-items:center}.component .component-checkbox__item .component-checkbox__item--label[data-v-7f659856]:hover{cursor:pointer}.component .component-checkbox__item .component-checkbox__item--label:hover div.component-checkbox__item--without-background[data-v-7f659856],.component .component-checkbox__item .component-checkbox__item--label:hover div.component-checkbox__item--with-background[data-v-7f659856]{border:2px solid var(--12801eb4)}.component .component-checkbox__item .component-checkbox__item--label div[data-v-7f659856]{width:19px;height:19px;flex-shrink:0;text-shadow:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;border-radius:var(--8e0b463c);font-family:Lato,sans-serif!important;font-weight:700}.component .component-checkbox__item .component-checkbox__item--label div.component-checkbox__item--without-background[data-v-7f659856]{border:2px solid var(--e1ee4b94);color:var(--e1ee4b94)}.component .component-checkbox__item .component-checkbox__item--label div.component-checkbox__item--with-background[data-v-7f659856]{border:2px solid var(--e1ee4b94);color:var(--3c01949e)}.component .component-checkbox__item .component-checkbox__item--label.custom-checkbox__input--type-circle div[data-v-7f659856]{border-radius:50%!important}.component .component-checkbox__item .component-checkbox__item--label.custom-checkbox__input--type-circle div[data-v-7f659856]:before{border-radius:50%!important}.component-disabled[data-v-7f659856]{cursor:not-allowed;pointer-events:none;-webkit-user-select:none;user-select:none}.component-disabled .component[data-v-7f659856]{--disabled-color: var(--18b53789);color:var(--disabled-color)!important;opacity:.4;border-radius:inherit}.component-disabled .component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div.component-checkbox__item--without-background[data-v-7f659856]{border:2px solid var(--45bd3dc0);color:var(--5856bcc6)}.component-disabled .component .component-checkbox__item .component-checkbox__item--input:checked+.component-checkbox__item--label div.component-checkbox__item--with-background[data-v-7f659856]{background:var(--33327636)}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vlalg-nimbus/nb-inputs",
3
3
  "description": "Input components for Vuejs 3",
4
- "version": "6.0.4",
4
+ "version": "6.0.5",
5
5
  "type": "module",
6
6
  "main": "./dist/nb-inputs.umd.js",
7
7
  "module": "./dist/nb-inputs.js",