@sysvale/cuida 3.0.0-beta.88 → 3.0.0-beta.90
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/@sysvale/cuida.es.js +15 -8
- package/dist/@sysvale/cuida.umd.js +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -30268,6 +30268,10 @@ const Uue = {
|
|
|
30268
30268
|
type: Boolean,
|
|
30269
30269
|
default: !1
|
|
30270
30270
|
},
|
|
30271
|
+
variant: {
|
|
30272
|
+
type: String,
|
|
30273
|
+
default: "green"
|
|
30274
|
+
},
|
|
30271
30275
|
large: {
|
|
30272
30276
|
type: Boolean,
|
|
30273
30277
|
default: !1
|
|
@@ -30318,20 +30322,23 @@ function Gue(t, e, n, i, s, r) {
|
|
|
30318
30322
|
]),
|
|
30319
30323
|
$("span", {
|
|
30320
30324
|
tabindex: "0",
|
|
30321
|
-
class: Y(["switch__slider",
|
|
30322
|
-
|
|
30323
|
-
|
|
30324
|
-
|
|
30325
|
-
|
|
30326
|
-
|
|
30327
|
-
|
|
30325
|
+
class: Y(["switch__slider", [
|
|
30326
|
+
`switch__slider--${n.variant}`,
|
|
30327
|
+
{
|
|
30328
|
+
[`switch__slider--active-focused--${n.variant}`]: s.internalFocus && s.isActive && !n.disabled,
|
|
30329
|
+
"switch__slider--inactive-focused": s.internalFocus && !s.isActive && !n.disabled,
|
|
30330
|
+
"switch__slider--small": n.small && n.small !== n.large,
|
|
30331
|
+
"switch__slider--large": n.large && n.small !== n.large,
|
|
30332
|
+
"switch__slider--medium": n.small === n.large
|
|
30333
|
+
}
|
|
30334
|
+
]]),
|
|
30328
30335
|
onFocusout: e[2] || (e[2] = (a) => s.internalFocus = !1),
|
|
30329
30336
|
onFocusin: e[3] || (e[3] = (a) => s.internalFocus = !0)
|
|
30330
30337
|
}, null, 34)
|
|
30331
30338
|
], 2)
|
|
30332
30339
|
]);
|
|
30333
30340
|
}
|
|
30334
|
-
const Kue = /* @__PURE__ */ _e(Uue, [["render", Gue], ["__scopeId", "data-v-
|
|
30341
|
+
const Kue = /* @__PURE__ */ _e(Uue, [["render", Gue], ["__scopeId", "data-v-d1c48c91"]]);
|
|
30335
30342
|
var $a = { exports: {} };
|
|
30336
30343
|
/**
|
|
30337
30344
|
* @license
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
a 15.9155 15.9155 0 0 1 0 31.831
|
|
50
50
|
a 15.9155 15.9155 0 0 1 0 -31.831`},null,12,GJ),n.noLabel?c.createCommentVNode("",!0):(c.openBlock(),c.createElementBlock("text",{key:0,x:"18",y:"21.7",class:c.normalizeClass(a.labelClass)},c.toDisplayString(a.label),3))],2)}const ZJ=rt(jJ,[["render",KJ]]),j1t="",XJ={props:{modelValue:{default:null,required:!0},value:{default:null,required:!0},label:{type:String,default:"radio content"},disabled:{type:Boolean,default:!1}},computed:{isChecked(){return this.modelValue===this.value}}},JJ={class:"cds-radio"},QJ=["id","value","disabled","name","checked"],qJ=["for"],$J=["disabled"];function tQ(e,t,n,i,s,a){return c.openBlock(),c.createElementBlock("span",JJ,[c.createElementVNode("input",{id:n.value,type:"radio",value:n.value,disabled:n.disabled,name:e.$attrs.name,checked:a.isChecked,onChange:t[0]||(t[0]=o=>e.$emit("update:modelValue",o.target.value))},null,40,QJ),c.createElementVNode("label",{class:"cds-radio__label",for:n.value},[c.renderSlot(e.$slots,"default",{},()=>[c.createElementVNode("span",{class:"cds-radio__label-text",disabled:n.disabled},c.toDisplayString(n.label),9,$J)])],8,qJ)])}const eQ=rt(XJ,[["render",tQ]]),U1t="",nQ={props:{modelValue:{default:null,required:!0},options:{type:Array,default:()=>[],required:!0},disabled:{type:Boolean,default:!1,required:!1},inline:{type:Boolean,default:!1,description:"When true, the radio buttons will be displayed in a row.",required:!1}},data(){return{selected:this.modelValue}},watch:{selected(e){this.$emit("update:modelValue",e)},modelValue:{handler(e){this.selected=e},immediate:!0}}},iQ={id:"radioButton"},sQ=["disabled","for"],aQ=["id","value","disabled"],oQ=["for"];function rQ(e,t,n,i,s,a){return c.openBlock(),c.createElementBlock("span",iQ,[c.createElementVNode("div",{class:c.normalizeClass({"button-group":n.inline})},[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.options,(o,l)=>(c.openBlock(),c.createElementBlock("div",{key:o.value,class:c.normalizeClass({"radio-button__container--vertical":n.inline&&l>0})},[c.createElementVNode("label",{class:"radio-button",disabled:o.disabled||n.disabled,for:o.value},[c.withDirectives(c.createElementVNode("input",{id:o.value,"onUpdate:modelValue":t[0]||(t[0]=d=>s.selected=d),type:"radio",value:o.value,disabled:o.disabled||n.disabled},null,8,aQ),[[c.vModelRadio,s.selected]]),c.createElementVNode("label",{class:"radio-button__content",for:o.value},c.toDisplayString(o.text),9,oQ)],8,sQ)],2))),128))],2)])}const lQ=rt(nQ,[["render",rQ]]),G1t="",cQ={components:{CdsIcon:Me,CdsLinkButton:E_},props:{modelValue:{type:[String,Number],default:""},disabled:{type:Boolean,default:!1},placeholder:{type:String,default:"Busque..."},fluid:{type:Boolean,default:!1,required:!1}},data(){return{internalValue:"",isBeingFocused:!1}},computed:{hasSlots(){return!!Object.keys(this.$slots).length},stepperInputDynamicClass(){return(this.fluid?"search-input--fluid":"search-input").concat(" ",this.disabled?"search-input--disabled":"")},inputClass(){return this.fluid?"search-input__field--fluid":"search-input__field"}},methods:{handleInput(e){this.$emit("update:modelValue",e.target.value)}}},dQ=["value","placeholder","disabled"];function uQ(e,t,n,i,s,a){const o=c.resolveComponent("cds-icon");return c.openBlock(),c.createElementBlock("div",null,[c.createElementVNode("div",{class:c.normalizeClass(a.stepperInputDynamicClass)},[c.createVNode(o,{name:"search-outline",class:"search-input__search-icon"}),c.createElementVNode("input",{id:"cds-search-input",value:n.modelValue,placeholder:n.placeholder,disabled:n.disabled,class:c.normalizeClass(a.inputClass),onFocus:t[0]||(t[0]=l=>s.isBeingFocused=!0),onBlur:t[1]||(t[1]=l=>s.isBeingFocused=!1),onInput:t[2]||(t[2]=(...l)=>a.handleInput&&a.handleInput(...l))},null,42,dQ),n.modelValue?(c.openBlock(),c.createBlock(o,{key:0,name:"x-outline",width:"18",height:"18",class:"search-input__close-icon",onClick:t[3]||(t[3]=l=>s.internalValue="")})):c.createCommentVNode("",!0)],2)])}const hQ=rt(cQ,[["render",uQ],["__scopeId","data-v-06cf65a5"]]),K1t="",fQ={components:{CdsIcon:Me,CdsTooltip:m0},props:{segments:{type:Array,default:()=>[]},withIcon:{type:Boolean,default:!1},segmentsTooltipText:{type:Array,default:()=>[]}},data(){return{activeSegment:""}},mounted(){this.activeSegment=this.segments[0]},methods:{handleClick(e,t){this.activeSegment=e,this.$emit("click",this.activeSegment,t)}}},pQ={class:"segment-control"},mQ=["onClick"],gQ={key:1};function vQ(e,t,n,i,s,a){const o=c.resolveComponent("cds-icon"),l=c.resolveComponent("cds-tooltip");return c.openBlock(),c.createElementBlock("div",pQ,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.segments,(d,h)=>(c.openBlock(),c.createElementBlock("button",{key:h,class:c.normalizeClass(["segment-control__button",{"segment-control__button--active":d===s.activeSegment,"segment-control__button--inactive":d!==s.activeSegment}]),onClick:f=>a.handleClick(d,h)},[n.withIcon?(c.openBlock(),c.createBlock(l,{key:0,text:n.segmentsTooltipText[h]},{default:c.withCtx(()=>[c.createVNode(o,{height:"20",width:"20",name:d},null,8,["name"])]),_:2},1032,["text"])):(c.openBlock(),c.createElementBlock("span",gQ,c.toDisplayString(d),1))],10,mQ))),128))])}const _Q=rt(fQ,[["render",vQ]]);function J_(e=""){const t="\xC0\xC1\xC2\xC3\xC4\xC5\xE0\xE1\xE2\xE3\xE4\xE5\xD2\xD3\xD4\xD5\xD5\xD6\xD8\xF2\xF3\xF4\xF5\xF6\xF8\xC8\xC9\xCA\xCB\xE8\xE9\xEA\xEB\xF0\xC7\xE7\xD0\xCC\xCD\xCE\xCF\xEC\xED\xEE\xEF\xD9\xDA\xDB\xDC\xF9\xFA\xFB\xFC\xD1\xF1\u0160\u0161\u0178\xFF\xFD\u017D\u017E",n="AAAAAAaaaaaaOOOOOOOooooooEEEEeeeeeCcDIIIIiiiiUUUUuuuuNnSsYyyZz",i=e.length;let s=e.split(""),a;for(let o=0;o<i;o+=1)a=t.indexOf(e[o]),a!==-1&&(s[o]=n[a]);return s=s.join(""),s=s.split(".").join(""),s=s.split("-").join(""),s=s.split("/").join(""),s}const Z1t="",yQ={components:{CdsIcon:Me},props:{label:{type:String,default:"Label",required:!0},placeholder:{type:String,default:"Selecione...",required:!1},options:{type:Array,default:()=>[],required:!0},modelValue:{type:[Array,Object],required:!0},state:{type:String,default:"default"},required:{type:Boolean,default:!1,required:!1},errorMessage:{type:String,default:"Valor inv\xE1lido"},searchable:{type:Boolean,default:!1,required:!1},width:{type:String,default:"default",required:!1},fluid:{type:Boolean,default:!1,required:!1},disabled:{type:Boolean,default:!1,required:!1},tooltip:{type:String,default:null},tooltipIcon:{type:String,default:"info-outline"},optionsField:{type:String,default:"value",required:!1}},data(){return{currentPos:0,active:!1,id:null,allowSearch:!1,localOptions:[],pristineOptions:[],localValue:"",selectElement:"",direction:"down",uniqueKey:Y1()}},computed:{errorState(){return this.state==="invalid"},inputClass(){let e="";return this.active&&this.direction==="down"?e="select__input--opened-down":this.active&&this.direction==="up"?e="select__input--opened-up":e="select__input--closed",this.disabled?e+=" select__input--disabled":this.state==="valid"?e+=" select__input--valid":this.state==="invalid"&&(e+=" select__input--invalid"),e+=` select__input--${O8.find(t=>t===this.width)}`,e+=this.fluid?" select__input--fluid":" select__input--fit",e+=this.searchable?" select__input--searchable":"",e}},watch:{modelValue:{handler(e,t){e!==t&&(this.localValue=e)},immediate:!0},options:{handler(e,t){e!==t&&(this.localOptions=e,this.pristineOptions=e)},immediate:!0},searchable:{handler(e,t){e!==t&&(this.allowSearch=e)},immediate:!0},localValue:{handler(e){this.$emit("update:modelValue",e)},deep:!0}},mounted(){this.id=`cds-select-${this.uniqueKey}`,this.selectElement=this.$refs["cds-select"]},methods:{filterOptions(){const e=J_(this.localValue[this.optionsField]),t=new RegExp(e,"i");this.localOptions=this.options.filter(n=>J_(n[this.optionsField]).search(t)>=0)},activeSelection(){this.disabled||this.$nextTick().then(()=>{const e=this.localOptions[this.currentPos];this.$refs[`${e[this.optionsField]}-${this.currentPos}`][0].classList.add("highlight")})},activateSelectionOnEnter(){this.disabled||(this.active=!this.active,typeof this.localOptions[this.currentPos]>"u"?this.localOptions=this.pristineOptions:this.localValue=R1(this.localOptions[this.currentPos]),this.$refs["select-input"].blur())},activateSelectionOnClick(){let e=this.selectElement.getBoundingClientRect();e.top+e.height+286<window.innerHeight?this.direction="down":this.direction="up",!this.disabled&&(this.active=!this.active)},hide(){this.localOptions=this.pristineOptions,this.active=!1},selectItem(){this.localValue=R1(this.localOptions[this.currentPos])},getLiInDOM(e){const t=this.localOptions[e];return this.$refs[`${t[this.optionsField]}-${e}`][0]},handleOptionVisibility(e,t,n){const i=e.getBoundingClientRect(),s=this.$refs["select-options"],a=s.getBoundingClientRect();n==="up"&&i.top<=a.top&&(s.scrollTop+=t),n==="down"&&i.top>=a.bottom&&(s.scrollTop+=t)},highlightOnArrowDown(){if(this.currentPos===this.localOptions.length-1)return;this.currentPos+=1;const e=this.getLiInDOM(this.currentPos),t=this.getLiInDOM(this.currentPos-1);e.classList.add("highlight"),t.classList.remove("highlight"),this.handleOptionVisibility(e,37,"down")},highlightOnArrowUp(){if(this.currentPos===0)return;const e=this.getLiInDOM(this.currentPos),t=this.getLiInDOM(this.currentPos-1);e.classList.remove("highlight"),t.classList.add("highlight"),this.handleOptionVisibility(e,-37,"up"),this.currentPos-=1},highlightOnMouseOver(e){this.currentPos=e,this.getLiInDOM(this.currentPos).classList.add("highlight")},unhighlightOnMouseOut(){this.getLiInDOM(this.currentPos).classList.remove("highlight")}}},bQ=e=>(c.pushScopeId("data-v-fbfd91b7"),e=e(),c.popScopeId(),e),wQ={ref:"cds-select",class:"select"},xQ={class:"select__label",for:"cds-select"},SQ={key:0,class:"select--required"},kQ=["id","onkeypress","placeholder","disabled","readonly"],CQ={key:0,class:"option__container"},OQ=["onMouseover"],MQ={key:1,class:"option__container"},DQ=[bQ(()=>c.createElementVNode("li",{class:"option__text--muted"}," Nenhuma op\xE7\xE3o encontrada ",-1))],EQ={key:0,class:"select__error-message"};function TQ(e,t,n,i,s,a){const o=c.resolveComponent("cds-icon"),l=c.resolveDirective("cdstip");return c.openBlock(),c.createElementBlock("div",wQ,[c.createElementVNode("label",xQ,[c.createElementVNode("span",null,c.toDisplayString(n.label),1),n.required?(c.openBlock(),c.createElementBlock("span",SQ," * ")):c.createCommentVNode("",!0),n.tooltip?c.withDirectives((c.openBlock(),c.createBlock(o,{key:1,name:n.tooltipIcon,height:"20",width:"20",class:"select__icon"},null,8,["name"])),[[l,n.tooltip]]):c.createCommentVNode("",!0)]),c.createElementVNode("div",{class:c.normalizeClass(["select__container",n.fluid?"select__container--fluid":"select__container--fit"])},[c.withDirectives(c.createElementVNode("input",{id:e.$attrs.id||s.id,ref:"select-input","onUpdate:modelValue":t[0]||(t[0]=d=>s.localValue[n.optionsField]=d),type:"text",autocomplete:"off",onkeypress:`return ${s.allowSearch};`,class:c.normalizeClass(a.inputClass),placeholder:n.placeholder,disabled:n.disabled,readonly:!n.searchable,onKeydown:[t[1]||(t[1]=c.withKeys(c.withModifiers((...d)=>a.activateSelectionOnEnter&&a.activateSelectionOnEnter(...d),["prevent"]),["enter"])),t[2]||(t[2]=c.withKeys(c.withModifiers((...d)=>a.highlightOnArrowDown&&a.highlightOnArrowDown(...d),["prevent"]),["arrow-down"])),t[3]||(t[3]=c.withKeys(c.withModifiers((...d)=>a.highlightOnArrowUp&&a.highlightOnArrowUp(...d),["prevent"]),["arrow-up"]))],onClick:t[4]||(t[4]=(...d)=>a.activateSelectionOnClick&&a.activateSelectionOnClick(...d)),onInput:t[5]||(t[5]=(...d)=>a.filterOptions&&a.filterOptions(...d)),onFocus:t[6]||(t[6]=(...d)=>a.activeSelection&&a.activeSelection(...d)),onBlur:t[7]||(t[7]=(...d)=>a.hide&&a.hide(...d))},null,42,kQ),[[c.vModelText,s.localValue[n.optionsField]]]),c.withDirectives(c.createElementVNode("div",{ref:"select-options",class:c.normalizeClass(["select__options",{"select__options--thin":n.width==="thin","select__options--default":n.width==="default","select__options--wide":n.width==="wide","select__options--fluid":n.fluid,"select__options--down":s.direction==="down","select__options--up":s.direction==="up"}])},[s.localOptions.length>0?(c.openBlock(),c.createElementBlock("ul",CQ,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(s.localOptions,(d,h)=>(c.openBlock(),c.createElementBlock("li",{key:h,ref_for:!0,ref:`${d[n.optionsField]}-${h}`,class:"option__text",onMousedown:t[8]||(t[8]=(...f)=>a.selectItem&&a.selectItem(...f)),onMouseover:f=>a.highlightOnMouseOver(h),onMouseout:t[9]||(t[9]=f=>a.unhighlightOnMouseOut())},c.toDisplayString(d[n.optionsField]),41,OQ))),128))])):(c.openBlock(),c.createElementBlock("ul",MQ,DQ))],2),[[c.vShow,s.active]]),c.createElementVNode("span",{class:c.normalizeClass(s.active?"select__chevron--opened":"select__chevron--closed")},null,2)],2),a.errorState&&!n.disabled?(c.openBlock(),c.createElementBlock("div",EQ,c.toDisplayString(n.errorMessage),1)):c.createCommentVNode("",!0)],512)}const IQ=rt(yQ,[["render",TQ],["__scopeId","data-v-fbfd91b7"]]),J1t="",AQ={components:{CdsIcon:Me,CdsAvatar:G1},props:{items:{type:Array,default:()=>[],required:!0,validator:e=>!e.filter(n=>{const i=We(n.path)&&We(n.route),s=We(n.items)||n.items.filter(a=>We(a.path)&&We(a.route)).length;return We(n.label)||s&&i}).length},activeItem:{type:Object,default:()=>({}),required:!0},showLogout:{type:Boolean,default:!0},userName:{type:String,default:""},userRole:{type:String,default:""},userPicture:{type:String,default:null}},data(){return{internalActiveItem:{},colorOptions:so}},watch:{items:{handler(e){const t=e.filter(n=>n.name===this.activeItem.name);[this.internalActiveItem]=t.length?t:e},immediate:!0},activeItem:{handler(e){this.internalActiveItem=e},immediate:!0}},mounted(){this.internalActiveItem=this.activeItem},methods:{colorHexCode:pr,handleClick(e,t){this.internalActiveItem=t,this.$emit("sidebar-click",this.internalActiveItem)},isActive(e){let t=!1,n=!1;return!!e.items&&e.items.length>0&&(t=e.items.some(i=>lc(i,this.internalActiveItem))),n=lc(this.internalActiveItem,e),t||n},resolveRoute({route:e,path:t}){const n=We(e)?t:e;return n instanceof String?{path:n}:n},routerPushTo(e){return this.resolveRoute(e)?this.resolveRoute(e).path:null}}},VQ={class:"side-bar"},BQ={class:"side-bar__logo"},PQ={key:0,class:"side-bar__subitem-container"},NQ={class:"side-bar__subitems"},zQ=["onClick"],LQ={class:"side-bar__footer"},FQ={class:"side-bar__avatar"},RQ=c.createElementVNode("span",null,"Sair",-1);function HQ(e,t,n,i,s,a){const o=c.resolveComponent("cds-icon"),l=c.resolveComponent("router-link"),d=c.resolveComponent("cds-avatar");return c.openBlock(),c.createElementBlock("div",VQ,[c.createElementVNode("div",null,[c.createElementVNode("div",BQ,[c.renderSlot(e.$slots,"logo")]),c.createElementVNode("ul",{class:c.normalizeClass({"side-bar__container":n.items.length>=1})},[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.items,(h,f)=>(c.openBlock(),c.createElementBlock("li",{key:`${f}-${h.name}-item`,role:"presentation"},[c.createElementVNode("div",{class:c.normalizeClass(["side-bar__item-container",a.isActive(h)?"side-bar__item-container--active":"side-bar__item-container--inactive"])},[c.createVNode(l,{to:a.routerPushTo(h),class:c.normalizeClass(["side-bar__item",a.isActive(h)?"side-bar__item--active":"side-bar__item--inactive"]),onClick:m=>a.handleClick(m,h)},{default:c.withCtx(()=>[c.createElementVNode("div",null,[c.createVNode(o,{name:h.icon,width:"20",height:"20"},null,8,["name"]),c.createElementVNode("span",null,c.toDisplayString(h.label),1)]),!!h.items&&h.items.length>0?(c.openBlock(),c.createBlock(o,{key:0,name:"caret-down-outline",class:c.normalizeClass({item__caret:a.isActive(h)}),width:"16",height:"16"},null,8,["class"])):c.createCommentVNode("",!0)]),_:2},1032,["to","class","onClick"])],2),c.createVNode(c.Transition,null,{default:c.withCtx(()=>[!!h.items&&h.items.length>0&&a.isActive(h)?(c.openBlock(),c.createElementBlock("div",PQ,[c.createElementVNode("div",NQ,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(h.items,(m,v)=>(c.openBlock(),c.createElementBlock("div",{key:`${v}-${m.name}-item`,class:c.normalizeClass(["side-bar__subitem",a.isActive(m)?"side-bar__subitem--active":"side-bar__subitem--inactive"]),onClick:y=>a.handleClick(y,m)},[c.createVNode(l,{to:a.routerPushTo(m)},{default:c.withCtx(()=>[c.createTextVNode(c.toDisplayString(m.label),1)]),_:2},1032,["to"])],10,zQ))),128))])])):c.createCommentVNode("",!0)]),_:2},1024)]))),128))],2)]),c.createElementVNode("div",LQ,[c.createElementVNode("div",FQ,[c.createVNode(d,{src:n.userPicture,name:n.userName,variant:"white",size:"lg"},null,8,["src","name"]),c.createElementVNode("div",null,[c.createElementVNode("p",null,c.toDisplayString(n.userName),1),c.createElementVNode("p",null,c.toDisplayString(n.userRole),1)])]),c.createElementVNode("ul",null,[n.showLogout?(c.openBlock(),c.createElementBlock("li",{key:0,class:"side-bar__logout-button",onClick:t[0]||(t[0]=h=>e.$emit("logout",!0))},[c.createVNode(o,{name:"logout-outline",width:"20",height:"20"}),RQ])):c.createCommentVNode("",!0)])])])}const WQ=rt(AQ,[["render",HQ]]),Q1t="",b0={components:{CdsIcon:Me,CdsBox:Il,CdsClickable:Qs},props:{title:{type:String,default:null},modelValue:{type:Boolean,default:!1,required:!0},withOverlay:{type:Boolean,default:!1},size:{type:String,default:"md"},noCloseOnBackdrop:{type:Boolean,default:!1},noCloseOnEsc:{type:Boolean,default:!1}},data(){return{sassColorVariables:Pd}},computed:{overlayColor(){const e=this.withOverlay?this.sassColorVariables.n900:"transparent";return`rgba(${this.hexToRgb(e)}, 0.4)`},sideSheetWidth(){let e="328px";switch(this.size){case"xl":e="840px";break;case"lg":e="700px";break;case"md":e="500px";break;default:e="340px";break}return e}},watch:{modelValue(e){if(!e){this.dettachKeyupEvent();return}this.attachKeyupEvent()}},created(){this.attachKeyupEvent()},beforeUnmount(){this.dettachKeyupEvent()},methods:{hexToRgb:Xh,shouldCloseOnBackdrop(){this.noCloseOnBackdrop||this.$emit("update:modelValue",!this.modelValue)},shouldCloseOnEsc(){this.noCloseOnEsc||this.$emit("update:modelValue",!this.modelValue)},keyupListener(e){e.keyCode===C8.ESC&&this.shouldCloseOnEsc()},attachKeyupEvent(){window.addEventListener("keyup",this.keyupListener)},dettachKeyupEvent(){window.removeEventListener("keyup",this.keyupListener)}}},Q_=()=>{c.useCssVars(e=>({cc3f5f34:e.overlayColor,ccc8a1de:e.sideSheetWidth}))},q_=b0.setup;b0.setup=q_?(e,t)=>(Q_(),q_(e,t)):Q_;const YQ=b0,jQ={class:"side-sheet__header"};function UQ(e,t,n,i,s,a){const o=c.resolveComponent("cds-icon"),l=c.resolveComponent("cds-clickable"),d=c.resolveComponent("cds-box");return n.modelValue?(c.openBlock(),c.createElementBlock("div",{key:0,class:"side-sheet__overlay",tabindex:"0",onClick:t[3]||(t[3]=(...h)=>a.shouldCloseOnBackdrop&&a.shouldCloseOnBackdrop(...h))},[c.createVNode(d,{padding:"5",class:"side-sheet__container",elevated:"",onClick:t[2]||(t[2]=c.withModifiers(()=>{},["stop"]))},{default:c.withCtx(()=>[c.createElementVNode("header",null,[c.renderSlot(e.$slots,"header",{},()=>[c.createElementVNode("div",jQ,[c.createElementVNode("h3",null,c.toDisplayString(n.title),1),c.createElementVNode("div",{class:"side-sheet__close-icon",onClick:t[1]||(t[1]=(...h)=>e.closeHandle&&e.closeHandle(...h))},[c.createVNode(l,{clickable:""},{default:c.withCtx(()=>[c.createVNode(o,{height:"20",width:"20",name:"x-outline",onClick:t[0]||(t[0]=c.withModifiers(h=>e.$emit("update:modelValue",!n.modelValue),["stop"]))})]),_:1})])])],!0)]),c.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3})])):c.createCommentVNode("",!0)}const GQ=rt(YQ,[["render",UQ],["__scopeId","data-v-5aaa253a"]]),q1t="",KQ={props:{width:{type:String,required:!1},height:{type:String,required:!1,default:"16"}},computed:{computedStyle(){return{"--width":`${this.width}px`,"--height":`${this.height}px`}}}};function ZQ(e,t,n,i,s,a){return c.openBlock(),c.createElementBlock("div",{class:"skeleton__container",style:c.normalizeStyle(a.computedStyle)},null,4)}const XQ=rt(KQ,[["render",ZQ],["__scopeId","data-v-d39e7029"]]),$1t="",JQ={components:{CdsIcon:Me},props:{steps:{type:Array,default:()=>[],required:!0,description:`Um array com objetos com as propriedades 'label', 'inProcessing',
|
|
51
51
|
'error' e 'completed'. A 'label' \xE9 o texto que descreve o passo,
|
|
52
|
-
e as demais props s\xE3o booleanas e representam o status do passo.`},vertical:{type:Boolean,default:!1,required:!1},value:{type:Number,default:1,required:!0},disableOnClick:{type:Boolean,default:!1}},data(){return{internalValue:this.value-1}},watch:{internalValue(e){this.$emit("input",e+1)},value:{handler(e){this.internalValue=e-1},immediate:!0}},methods:{circleStyle(e,t){const n=this.disableOnClick?"":"stepper__step--clickable";return e.inProcessing?`stepper__step--in-processing ${n}`:e.error?`stepper__step--error ${n}`:e.completed?`stepper__step--completed ${n}`:t===this.internalValue?`stepper__step--active ${n}`:` stepper__step--muted ${n}`},changeStep(e){this.disableOnClick||(this.internalValue=e)},dividerStyle(e){const t=this.vertical?"vertical-":"";if(e<0)return`stepper__${t}divider--default`;const n=e===this.steps.length-1,i=e===0,s=e-1,a=e+1;return!n&&this.steps[e].completed&&this.steps[a].completed?`stepper__${t}divider--completed`:!n&&e>0&&this.steps[e].completed&&this.steps[s].completed||!n&&i&&this.steps[e].completed?`stepper__${t}divider--in-progress`:`stepper__${t}divider--default`},stepSectionStyle(e){let t="";return t+=e!==this.steps.length-1?"stepper__step-section ":"",t+=this.vertical?"stepper__step-section--vertical":"",t},labelStyle(e){let t="";return t+=e===this.internalValue?"stepper__step-label--active":"stepper__step-label--muted",t+=this.vertical?"":" stepper__step-label--horizontal",t+=this.disableOnClick?"":" stepper__step--clickable",t}}},QQ=e=>(c.pushScopeId("data-v-6046312d"),e=e(),c.popScopeId(),e),qQ={class:"stepper__edge"},$Q=["onClick"],tq=["id","onClick"],eq={key:2,class:"stepper__processing-icon"},nq=[QQ(()=>c.createElementVNode("svg",{width:"19",height:"22",viewBox:"0 0 19 22",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[c.createElementVNode("path",{d:"M18.78 16.6325C17.738 18.0472 16.3457 19.1664 14.7402 19.8799C13.1346 20.5935 11.3709 20.8769 9.62259 20.7023C7.87428 20.5276 6.20151 19.901 4.76877 18.884C3.33604 17.867 2.19266 16.4945 1.45107 14.9017C0.709475 13.3089 0.395207 11.5504 0.539162 9.79934C0.683116 8.04824 1.28034 6.36474 2.2721 4.9144C3.26387 3.46406 4.61603 2.2968 6.19562 1.52741C7.77522 0.758019 9.52787 0.412981 11.2812 0.526225L10.6287 10.6288L18.78 16.6325Z",fill:"#3A7EDF"})],-1))],iq={key:3,class:"stepper__icon-text"},sq={key:0,class:"stepper__edge-container"},aq={class:"stepper__edge"};function oq(e,t,n,i,s,a){const o=c.resolveComponent("cds-icon");return c.openBlock(),c.createElementBlock("div",{class:c.normalizeClass(n.vertical?"stepper--vertical":"stepper")},[c.createElementVNode("div",{class:c.normalizeClass(n.vertical?"stepper__edge-container--vertical":"stepper__edge-container")},[c.createElementVNode("div",qQ,[c.createElementVNode("div",{class:c.normalizeClass(a.dividerStyle(-1))},null,2)])],2),(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.steps,(l,d)=>(c.openBlock(),c.createElementBlock("div",{key:d,class:c.normalizeClass(a.stepSectionStyle(d))},[n.vertical?(c.openBlock(),c.createElementBlock("div",{key:0,class:c.normalizeClass(["stepper__step-label--vertical",a.labelStyle(d)]),onClick:h=>a.changeStep(d)},[c.createElementVNode("small",null,c.toDisplayString(l.label),1)],10,$Q)):c.createCommentVNode("",!0),c.createElementVNode("div",{id:`step-${d+1}`,class:c.normalizeClass(n.vertical?"stepper__icon-container--vertical":"stepper__icon-container"),onClick:h=>a.changeStep(d)},[c.createElementVNode("div",{class:c.normalizeClass(["stepper__icon-circle",a.circleStyle(l,d)])},[l.completed?(c.openBlock(),c.createBlock(o,{key:0,height:"32",width:"32",name:"check-outline"})):l.error?(c.openBlock(),c.createBlock(o,{key:1,height:"32",width:"32",name:"x-outline"})):l.inProcessing?(c.openBlock(),c.createElementBlock("div",eq,nq)):(c.openBlock(),c.createElementBlock("span",iq,c.toDisplayString(d+1),1))],2),c.createElementVNode("div",{class:c.normalizeClass(a.dividerStyle(d))},null,2)],10,tq),n.vertical?c.createCommentVNode("",!0):(c.openBlock(),c.createElementBlock("div",{key:1,class:c.normalizeClass(["stepper__step-label",a.labelStyle(d)])},[c.createElementVNode("small",null,c.toDisplayString(l.label),1)],2))],2))),128)),n.vertical?c.createCommentVNode("",!0):(c.openBlock(),c.createElementBlock("div",sq,[c.createElementVNode("div",aq,[c.createElementVNode("div",{class:c.normalizeClass(a.dividerStyle(-1))},null,2)])]))],2)}const rq=rt(JQ,[["render",oq],["__scopeId","data-v-6046312d"]]);var $_={exports:{}};(function(e){e.exports=function(t){var n={};function i(s){if(n[s])return n[s].exports;var a=n[s]={i:s,l:!1,exports:{}};return t[s].call(a.exports,a,a.exports,i),a.l=!0,a.exports}return i.m=t,i.c=n,i.d=function(s,a,o){i.o(s,a)||Object.defineProperty(s,a,{enumerable:!0,get:o})},i.r=function(s){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(s,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(s,"__esModule",{value:!0})},i.t=function(s,a){if(a&1&&(s=i(s)),a&8||a&4&&typeof s=="object"&&s&&s.__esModule)return s;var o=Object.create(null);if(i.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:s}),a&2&&typeof s!="string")for(var l in s)i.d(o,l,function(d){return s[d]}.bind(null,l));return o},i.n=function(s){var a=s&&s.__esModule?function(){return s.default}:function(){return s};return i.d(a,"a",a),a},i.o=function(s,a){return Object.prototype.hasOwnProperty.call(s,a)},i.p="",i(i.s="fae3")}({"01f9":function(t,n,i){var s=i("2d00"),a=i("5ca1"),o=i("2aba"),l=i("32e9"),d=i("84f2"),h=i("41a0"),f=i("7f20"),m=i("38fd"),v=i("2b4c")("iterator"),y=!([].keys&&"next"in[].keys()),w="@@iterator",x="keys",k="values",D=function(){return this};t.exports=function(E,B,S,A,I,F,L){h(S,B,A);var W=function(R){if(!y&&R in et)return et[R];switch(R){case x:return function(){return new S(this,R)};case k:return function(){return new S(this,R)}}return function(){return new S(this,R)}},X=B+" Iterator",Z=I==k,Q=!1,et=E.prototype,gt=et[v]||et[w]||I&&et[I],at=gt||W(I),ft=I?Z?W("entries"):at:void 0,lt=B=="Array"&&et.entries||gt,vt,xt,ct;if(lt&&(ct=m(lt.call(new E)),ct!==Object.prototype&&ct.next&&(f(ct,X,!0),!s&&typeof ct[v]!="function"&&l(ct,v,D))),Z&>&>.name!==k&&(Q=!0,at=function(){return gt.call(this)}),(!s||L)&&(y||Q||!et[v])&&l(et,v,at),d[B]=at,d[X]=D,I)if(vt={values:Z?at:W(k),keys:F?at:W(x),entries:ft},L)for(xt in vt)xt in et||o(et,xt,vt[xt]);else a(a.P+a.F*(y||Q),B,vt);return vt}},"0d58":function(t,n,i){var s=i("ce10"),a=i("e11e");t.exports=Object.keys||function(l){return s(l,a)}},1495:function(t,n,i){var s=i("86cc"),a=i("cb7c"),o=i("0d58");t.exports=i("9e1e")?Object.defineProperties:function(d,h){a(d);for(var f=o(h),m=f.length,v=0,y;m>v;)s.f(d,y=f[v++],h[y]);return d}},"230e":function(t,n,i){var s=i("d3f4"),a=i("7726").document,o=s(a)&&s(a.createElement);t.exports=function(l){return o?a.createElement(l):{}}},"2aba":function(t,n,i){var s=i("7726"),a=i("32e9"),o=i("69a8"),l=i("ca5a")("src"),d=i("fa5b"),h="toString",f=(""+d).split(h);i("8378").inspectSource=function(m){return d.call(m)},(t.exports=function(m,v,y,w){var x=typeof y=="function";x&&(o(y,"name")||a(y,"name",v)),m[v]!==y&&(x&&(o(y,l)||a(y,l,m[v]?""+m[v]:f.join(String(v)))),m===s?m[v]=y:w?m[v]?m[v]=y:a(m,v,y):(delete m[v],a(m,v,y)))})(Function.prototype,h,function(){return typeof this=="function"&&this[l]||d.call(this)})},"2aeb":function(t,n,i){var s=i("cb7c"),a=i("1495"),o=i("e11e"),l=i("613b")("IE_PROTO"),d=function(){},h="prototype",f=function(){var m=i("230e")("iframe"),v=o.length,y="<",w=">",x;for(m.style.display="none",i("fab2").appendChild(m),m.src="javascript:",x=m.contentWindow.document,x.open(),x.write(y+"script"+w+"document.F=Object"+y+"/script"+w),x.close(),f=x.F;v--;)delete f[h][o[v]];return f()};t.exports=Object.create||function(v,y){var w;return v!==null?(d[h]=s(v),w=new d,d[h]=null,w[l]=v):w=f(),y===void 0?w:a(w,y)}},"2b4c":function(t,n,i){var s=i("5537")("wks"),a=i("ca5a"),o=i("7726").Symbol,l=typeof o=="function",d=t.exports=function(h){return s[h]||(s[h]=l&&o[h]||(l?o:a)("Symbol."+h))};d.store=s},"2d00":function(t,n){t.exports=!1},"2d95":function(t,n){var i={}.toString;t.exports=function(s){return i.call(s).slice(8,-1)}},"32e9":function(t,n,i){var s=i("86cc"),a=i("4630");t.exports=i("9e1e")?function(o,l,d){return s.f(o,l,a(1,d))}:function(o,l,d){return o[l]=d,o}},"38fd":function(t,n,i){var s=i("69a8"),a=i("4bf8"),o=i("613b")("IE_PROTO"),l=Object.prototype;t.exports=Object.getPrototypeOf||function(d){return d=a(d),s(d,o)?d[o]:typeof d.constructor=="function"&&d instanceof d.constructor?d.constructor.prototype:d instanceof Object?l:null}},"41a0":function(t,n,i){var s=i("2aeb"),a=i("4630"),o=i("7f20"),l={};i("32e9")(l,i("2b4c")("iterator"),function(){return this}),t.exports=function(d,h,f){d.prototype=s(l,{next:a(1,f)}),o(d,h+" Iterator")}},4588:function(t,n){var i=Math.ceil,s=Math.floor;t.exports=function(a){return isNaN(a=+a)?0:(a>0?s:i)(a)}},4630:function(t,n){t.exports=function(i,s){return{enumerable:!(i&1),configurable:!(i&2),writable:!(i&4),value:s}}},"4bf8":function(t,n,i){var s=i("be13");t.exports=function(a){return Object(s(a))}},5537:function(t,n,i){var s=i("8378"),a=i("7726"),o="__core-js_shared__",l=a[o]||(a[o]={});(t.exports=function(d,h){return l[d]||(l[d]=h!==void 0?h:{})})("versions",[]).push({version:s.version,mode:i("2d00")?"pure":"global",copyright:"\xA9 2020 Denis Pushkarev (zloirock.ru)"})},"5ca1":function(t,n,i){var s=i("7726"),a=i("8378"),o=i("32e9"),l=i("2aba"),d=i("9b43"),h="prototype",f=function(m,v,y){var w=m&f.F,x=m&f.G,k=m&f.S,D=m&f.P,E=m&f.B,B=x?s:k?s[v]||(s[v]={}):(s[v]||{})[h],S=x?a:a[v]||(a[v]={}),A=S[h]||(S[h]={}),I,F,L,W;x&&(y=v);for(I in y)F=!w&&B&&B[I]!==void 0,L=(F?B:y)[I],W=E&&F?d(L,s):D&&typeof L=="function"?d(Function.call,L):L,B&&l(B,I,L,m&f.U),S[I]!=L&&o(S,I,W),D&&A[I]!=L&&(A[I]=L)};s.core=a,f.F=1,f.G=2,f.S=4,f.P=8,f.B=16,f.W=32,f.U=64,f.R=128,t.exports=f},"613b":function(t,n,i){var s=i("5537")("keys"),a=i("ca5a");t.exports=function(o){return s[o]||(s[o]=a(o))}},"626a":function(t,n,i){var s=i("2d95");t.exports=Object("z").propertyIsEnumerable(0)?Object:function(a){return s(a)=="String"?a.split(""):Object(a)}},6821:function(t,n,i){var s=i("626a"),a=i("be13");t.exports=function(o){return s(a(o))}},"69a8":function(t,n){var i={}.hasOwnProperty;t.exports=function(s,a){return i.call(s,a)}},"6a99":function(t,n,i){var s=i("d3f4");t.exports=function(a,o){if(!s(a))return a;var l,d;if(o&&typeof(l=a.toString)=="function"&&!s(d=l.call(a))||typeof(l=a.valueOf)=="function"&&!s(d=l.call(a))||!o&&typeof(l=a.toString)=="function"&&!s(d=l.call(a)))return d;throw TypeError("Can't convert object to primitive value")}},7726:function(t,n){var i=t.exports=typeof window<"u"&&window.Math==Math?window:typeof self<"u"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=i)},"77f1":function(t,n,i){var s=i("4588"),a=Math.max,o=Math.min;t.exports=function(l,d){return l=s(l),l<0?a(l+d,0):o(l,d)}},"79e5":function(t,n){t.exports=function(i){try{return!!i()}catch{return!0}}},"7f20":function(t,n,i){var s=i("86cc").f,a=i("69a8"),o=i("2b4c")("toStringTag");t.exports=function(l,d,h){l&&!a(l=h?l:l.prototype,o)&&s(l,o,{configurable:!0,value:d})}},"7f7f":function(t,n,i){var s=i("86cc").f,a=Function.prototype,o=/^\s*function ([^ (]*)/,l="name";l in a||i("9e1e")&&s(a,l,{configurable:!0,get:function(){try{return(""+this).match(o)[1]}catch{return""}}})},8378:function(t,n){var i=t.exports={version:"2.6.12"};typeof __e=="number"&&(__e=i)},"84f2":function(t,n){t.exports={}},"86cc":function(t,n,i){var s=i("cb7c"),a=i("c69a"),o=i("6a99"),l=Object.defineProperty;n.f=i("9e1e")?Object.defineProperty:function(h,f,m){if(s(h),f=o(f,!0),s(m),a)try{return l(h,f,m)}catch{}if("get"in m||"set"in m)throw TypeError("Accessors not supported!");return"value"in m&&(h[f]=m.value),h}},"9b43":function(t,n,i){var s=i("d8e8");t.exports=function(a,o,l){if(s(a),o===void 0)return a;switch(l){case 1:return function(d){return a.call(o,d)};case 2:return function(d,h){return a.call(o,d,h)};case 3:return function(d,h,f){return a.call(o,d,h,f)}}return function(){return a.apply(o,arguments)}}},"9c6c":function(t,n,i){var s=i("2b4c")("unscopables"),a=Array.prototype;a[s]==null&&i("32e9")(a,s,{}),t.exports=function(o){a[s][o]=!0}},"9def":function(t,n,i){var s=i("4588"),a=Math.min;t.exports=function(o){return o>0?a(s(o),9007199254740991):0}},"9e1e":function(t,n,i){t.exports=!i("79e5")(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7})},ac6a:function(t,n,i){for(var s=i("cadf"),a=i("0d58"),o=i("2aba"),l=i("7726"),d=i("32e9"),h=i("84f2"),f=i("2b4c"),m=f("iterator"),v=f("toStringTag"),y=h.Array,w={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},x=a(w),k=0;k<x.length;k++){var D=x[k],E=w[D],B=l[D],S=B&&B.prototype,A;if(S&&(S[m]||d(S,m,y),S[v]||d(S,v,D),h[D]=y,E))for(A in s)S[A]||o(S,A,s[A],!0)}},be13:function(t,n){t.exports=function(i){if(i==null)throw TypeError("Can't call method on "+i);return i}},c366:function(t,n,i){var s=i("6821"),a=i("9def"),o=i("77f1");t.exports=function(l){return function(d,h,f){var m=s(d),v=a(m.length),y=o(f,v),w;if(l&&h!=h){for(;v>y;)if(w=m[y++],w!=w)return!0}else for(;v>y;y++)if((l||y in m)&&m[y]===h)return l||y||0;return!l&&-1}}},c69a:function(t,n,i){t.exports=!i("9e1e")&&!i("79e5")(function(){return Object.defineProperty(i("230e")("div"),"a",{get:function(){return 7}}).a!=7})},ca5a:function(t,n){var i=0,s=Math.random();t.exports=function(a){return"Symbol(".concat(a===void 0?"":a,")_",(++i+s).toString(36))}},cadf:function(t,n,i){var s=i("9c6c"),a=i("d53b"),o=i("84f2"),l=i("6821");t.exports=i("01f9")(Array,"Array",function(d,h){this._t=l(d),this._i=0,this._k=h},function(){var d=this._t,h=this._k,f=this._i++;return!d||f>=d.length?(this._t=void 0,a(1)):h=="keys"?a(0,f):h=="values"?a(0,d[f]):a(0,[f,d[f]])},"values"),o.Arguments=o.Array,s("keys"),s("values"),s("entries")},cb7c:function(t,n,i){var s=i("d3f4");t.exports=function(a){if(!s(a))throw TypeError(a+" is not an object!");return a}},ce10:function(t,n,i){var s=i("69a8"),a=i("6821"),o=i("c366")(!1),l=i("613b")("IE_PROTO");t.exports=function(d,h){var f=a(d),m=0,v=[],y;for(y in f)y!=l&&s(f,y)&&v.push(y);for(;h.length>m;)s(f,y=h[m++])&&(~o(v,y)||v.push(y));return v}},d3f4:function(t,n){t.exports=function(i){return typeof i=="object"?i!==null:typeof i=="function"}},d53b:function(t,n){t.exports=function(i,s){return{value:s,done:!!i}}},d8e8:function(t,n){t.exports=function(i){if(typeof i!="function")throw TypeError(i+" is not a function!");return i}},e11e:function(t,n){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},f6fd:function(t,n){(function(i){var s="currentScript",a=i.getElementsByTagName("script");s in i||Object.defineProperty(i,s,{get:function(){try{throw new Error}catch(d){var o,l=(/.*at [^\(]*\((.*):.+:.+\)$/ig.exec(d.stack)||[!1])[1];for(o in a)if(a[o].src==l||a[o].readyState=="interactive")return a[o];return null}}})})(document)},fa5b:function(t,n,i){t.exports=i("5537")("native-function-to-string",Function.toString)},fab2:function(t,n,i){var s=i("7726").document;t.exports=s&&s.documentElement},fae3:function(t,n,i){if(i.r(n),i.d(n,"longClickDirective",function(){return o}),typeof window<"u"){i("f6fd");var s;(s=window.document.currentScript)&&(s=s.src.match(/(.+\/)[^/]+\.js(\?.*)?$/))&&(i.p=s[1])}i("ac6a"),i("7f7f");var a=function(l){var d=l.delay,h=d===void 0?400:d,f=l.interval,m=f===void 0?50:f;return{beforeMount:function(y,w,x,k){if(typeof w.value!="function"){var D=x.context.name,E="[longclick:] provided expression '".concat(w.expression,"' is not a function, but has to be");D&&(E+="Found in component '".concat(D,"' ")),console.warn(E)}var B=null,S=null,A=function(W){w.value(W)},I=function(W){W.type==="click"&&W.button!==0||B===null&&(B=setTimeout(function(){m&&m>0&&(S=setInterval(function(){A(W)},m)),A(W)},h))},F=function(){B!==null&&(clearTimeout(B),B=null),S&&(clearInterval(S),S=null)};["mousedown","touchstart"].forEach(function(L){y.addEventListener(L,I,{passive:!0})}),["click","mouseout","touchend","touchcancel"].forEach(function(L){y.addEventListener(L,F,{passive:!0})})},created:function(){},mounted:function(){},beforeUpdate:function(){},updated:function(){},beforeUnmount:function(){},unmounted:function(){}}},o=a}})})($_);const eht="",lq=$_.exports.longClickDirective({delay:400,interval:50}),cq={components:{CdsIcon:Me},directives:{longclick:lq},props:{modelValue:{type:[Number,String],default:0},max:{type:[Number,String],default:Number.MAX_SAFE_INTEGER},min:{type:[Number,String],default:Number.MIN_SAFE_INTEGER},label:{type:String,default:"Label"},required:{type:Boolean,default:!1},width:{type:String,default:"default",required:!1},disabled:{type:Boolean,default:!1},state:{type:String,default:"default"},errorMessage:{type:String,default:"Valor inv\xE1lido"}},data(){return{internalValue:this.modelValue,isBeingFocused:!1}},computed:{hasSlots(){return!!Object.keys(this.$slots).length},errorState(){return this.state==="invalid"},stepperInputDynamicClass(){let e="";return this.isBeingFocused?this.disabled||(this.state==="default"?e+=" stepper-input--focused":this.state==="valid"?e+=" stepper-input--focused-valid":this.state==="invalid"&&(e+=" stepper-input--focused-invalid")):(e="stepper-input",this.disabled?e+=" stepper-input--disabled":this.state==="valid"?e+=" stepper-input--valid":this.state==="invalid"&&(e+=" stepper-input--invalid")),e}},watch:{modelValue(e){this.internalValue=e},internalValue(e){e||(this.internalValue=0),typeof e=="string"&&(this.internalValue=+this.internalValue),e<this.min?(this.internalValue=this.min,this.$emit("invalid-number",`'O campo n\xE3o pode ser menor que ${parseInt(this.min,10)}.'`)):e>this.max?(this.internalValue=this.max,this.$emit("invalid-number",`'O campo n\xE3o pode ser maior que ${parseInt(this.max,10)}.'`)):this.$emit("update:modelValue",parseInt(e,10))}},methods:{changeValue(e){this.internalValue=parseInt(this.internalValue)+e}}},dq={key:0},uq={key:1,class:"stepper-input__label",for:"stepper-input"},hq={key:0,class:"stepper-input__label--required-indicator"},fq=["disabled"],pq={class:"stepper-input__icon-container"},mq=["disabled"],gq=["disabled"],vq={key:0,class:"stepper-input__error-message"};function _q(e,t,n,i,s,a){const o=c.resolveComponent("cds-icon"),l=c.resolveDirective("longclick");return c.openBlock(),c.createElementBlock("div",null,[c.createElementVNode("span",null,[a.hasSlots?(c.openBlock(),c.createElementBlock("span",dq,[c.renderSlot(e.$slots,"label",{},void 0,!0)])):(c.openBlock(),c.createElementBlock("label",uq,[c.createElementVNode("span",null,c.toDisplayString(n.label),1),n.required?(c.openBlock(),c.createElementBlock("span",hq," * ")):c.createCommentVNode("",!0)]))]),c.createElementVNode("div",{class:c.normalizeClass(a.stepperInputDynamicClass)},[c.withDirectives(c.createElementVNode("input",{id:"stepper-input","onUpdate:modelValue":t[0]||(t[0]=d=>s.internalValue=d),disabled:n.disabled,class:c.normalizeClass(["stepper-input__field",{"stepper-input__field--thin":n.width==="thin","stepper-input__field--default":n.width==="default","stepper-input__field--wide":n.width=="wide"}]),type:"number",onFocus:t[1]||(t[1]=d=>s.isBeingFocused=!0),onBlur:t[2]||(t[2]=d=>s.isBeingFocused=!1)},null,42,fq),[[c.vModelText,s.internalValue]]),c.createElementVNode("div",pq,[c.withDirectives((c.openBlock(),c.createElementBlock("button",{disabled:n.disabled,class:"stepper-input__icon--plus",tabindex:"-1",onFocus:t[3]||(t[3]=d=>s.isBeingFocused=!0),onBlur:t[4]||(t[4]=d=>s.isBeingFocused=!1),onClick:t[5]||(t[5]=d=>a.changeValue(1))},[c.createVNode(o,{height:"16",width:"16",name:"plus-outline"})],40,mq)),[[l,()=>a.changeValue(1)]]),c.withDirectives((c.openBlock(),c.createElementBlock("button",{disabled:n.disabled,class:"stepper-input__icon--minus",tabindex:"-1",onFocus:t[6]||(t[6]=d=>s.isBeingFocused=!0),onBlur:t[7]||(t[7]=d=>s.isBeingFocused=!1),onClick:t[8]||(t[8]=d=>a.changeValue(-1))},[c.createVNode(o,{height:"16",width:"16",name:"minus-outline"})],40,gq)),[[l,()=>a.changeValue(-1)]])])],2),a.errorState&&!n.disabled?(c.openBlock(),c.createElementBlock("div",vq,c.toDisplayString(n.errorMessage),1)):c.createCommentVNode("",!0)])}const yq=rt(cq,[["render",_q],["__scopeId","data-v-0bcdcaeb"]]),nht="",bq={props:{modelValue:{type:Boolean,default:!1,required:!0},small:{type:Boolean,default:!1},large:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},focused:{type:Boolean,default:!1}},data(){return{isActive:this.modelValue,internalFocus:this.focused}},computed:{toggleSwitchSize(){return this.small===this.large?"switch--medium":this.small?"switch--small":"switch--large"}},watch:{modelValue(e,t){e!==t&&(this.isActive=e)}},methods:{handleClick(){this.$emit("update:modelValue",!this.isActive)}}},wq=["disabled"];function xq(e,t,n,i,s,a){return c.openBlock(),c.createElementBlock("div",null,[c.createElementVNode("label",{class:c.normalizeClass(["switch",a.toggleSwitchSize])},[c.withDirectives(c.createElementVNode("input",{"onUpdate:modelValue":t[0]||(t[0]=o=>s.isActive=o),type:"checkbox",disabled:n.disabled,onClick:t[1]||(t[1]=(...o)=>a.handleClick&&a.handleClick(...o))},null,8,wq),[[c.vModelCheckbox,s.isActive]]),c.createElementVNode("span",{tabindex:"0",class:c.normalizeClass(["switch__slider",{"switch__slider--active-focused":s.internalFocus&&s.isActive&&!n.disabled,"switch__slider--inactive-focused":s.internalFocus&&!s.isActive&&!n.disabled,"switch__slider--small":n.small&&n.small!==n.large,"switch__slider--large":n.large&&n.small!==n.large,"switch__slider--medium":n.small===n.large}]),onFocusout:t[2]||(t[2]=o=>s.internalFocus=!1),onFocusin:t[3]||(t[3]=o=>s.internalFocus=!0)},null,34)],2)])}const Sq=rt(bq,[["render",xq],["__scopeId","data-v-4d622dcc"]]);var oo={exports:{}};/**
|
|
52
|
+
e as demais props s\xE3o booleanas e representam o status do passo.`},vertical:{type:Boolean,default:!1,required:!1},value:{type:Number,default:1,required:!0},disableOnClick:{type:Boolean,default:!1}},data(){return{internalValue:this.value-1}},watch:{internalValue(e){this.$emit("input",e+1)},value:{handler(e){this.internalValue=e-1},immediate:!0}},methods:{circleStyle(e,t){const n=this.disableOnClick?"":"stepper__step--clickable";return e.inProcessing?`stepper__step--in-processing ${n}`:e.error?`stepper__step--error ${n}`:e.completed?`stepper__step--completed ${n}`:t===this.internalValue?`stepper__step--active ${n}`:` stepper__step--muted ${n}`},changeStep(e){this.disableOnClick||(this.internalValue=e)},dividerStyle(e){const t=this.vertical?"vertical-":"";if(e<0)return`stepper__${t}divider--default`;const n=e===this.steps.length-1,i=e===0,s=e-1,a=e+1;return!n&&this.steps[e].completed&&this.steps[a].completed?`stepper__${t}divider--completed`:!n&&e>0&&this.steps[e].completed&&this.steps[s].completed||!n&&i&&this.steps[e].completed?`stepper__${t}divider--in-progress`:`stepper__${t}divider--default`},stepSectionStyle(e){let t="";return t+=e!==this.steps.length-1?"stepper__step-section ":"",t+=this.vertical?"stepper__step-section--vertical":"",t},labelStyle(e){let t="";return t+=e===this.internalValue?"stepper__step-label--active":"stepper__step-label--muted",t+=this.vertical?"":" stepper__step-label--horizontal",t+=this.disableOnClick?"":" stepper__step--clickable",t}}},QQ=e=>(c.pushScopeId("data-v-6046312d"),e=e(),c.popScopeId(),e),qQ={class:"stepper__edge"},$Q=["onClick"],tq=["id","onClick"],eq={key:2,class:"stepper__processing-icon"},nq=[QQ(()=>c.createElementVNode("svg",{width:"19",height:"22",viewBox:"0 0 19 22",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[c.createElementVNode("path",{d:"M18.78 16.6325C17.738 18.0472 16.3457 19.1664 14.7402 19.8799C13.1346 20.5935 11.3709 20.8769 9.62259 20.7023C7.87428 20.5276 6.20151 19.901 4.76877 18.884C3.33604 17.867 2.19266 16.4945 1.45107 14.9017C0.709475 13.3089 0.395207 11.5504 0.539162 9.79934C0.683116 8.04824 1.28034 6.36474 2.2721 4.9144C3.26387 3.46406 4.61603 2.2968 6.19562 1.52741C7.77522 0.758019 9.52787 0.412981 11.2812 0.526225L10.6287 10.6288L18.78 16.6325Z",fill:"#3A7EDF"})],-1))],iq={key:3,class:"stepper__icon-text"},sq={key:0,class:"stepper__edge-container"},aq={class:"stepper__edge"};function oq(e,t,n,i,s,a){const o=c.resolveComponent("cds-icon");return c.openBlock(),c.createElementBlock("div",{class:c.normalizeClass(n.vertical?"stepper--vertical":"stepper")},[c.createElementVNode("div",{class:c.normalizeClass(n.vertical?"stepper__edge-container--vertical":"stepper__edge-container")},[c.createElementVNode("div",qQ,[c.createElementVNode("div",{class:c.normalizeClass(a.dividerStyle(-1))},null,2)])],2),(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.steps,(l,d)=>(c.openBlock(),c.createElementBlock("div",{key:d,class:c.normalizeClass(a.stepSectionStyle(d))},[n.vertical?(c.openBlock(),c.createElementBlock("div",{key:0,class:c.normalizeClass(["stepper__step-label--vertical",a.labelStyle(d)]),onClick:h=>a.changeStep(d)},[c.createElementVNode("small",null,c.toDisplayString(l.label),1)],10,$Q)):c.createCommentVNode("",!0),c.createElementVNode("div",{id:`step-${d+1}`,class:c.normalizeClass(n.vertical?"stepper__icon-container--vertical":"stepper__icon-container"),onClick:h=>a.changeStep(d)},[c.createElementVNode("div",{class:c.normalizeClass(["stepper__icon-circle",a.circleStyle(l,d)])},[l.completed?(c.openBlock(),c.createBlock(o,{key:0,height:"32",width:"32",name:"check-outline"})):l.error?(c.openBlock(),c.createBlock(o,{key:1,height:"32",width:"32",name:"x-outline"})):l.inProcessing?(c.openBlock(),c.createElementBlock("div",eq,nq)):(c.openBlock(),c.createElementBlock("span",iq,c.toDisplayString(d+1),1))],2),c.createElementVNode("div",{class:c.normalizeClass(a.dividerStyle(d))},null,2)],10,tq),n.vertical?c.createCommentVNode("",!0):(c.openBlock(),c.createElementBlock("div",{key:1,class:c.normalizeClass(["stepper__step-label",a.labelStyle(d)])},[c.createElementVNode("small",null,c.toDisplayString(l.label),1)],2))],2))),128)),n.vertical?c.createCommentVNode("",!0):(c.openBlock(),c.createElementBlock("div",sq,[c.createElementVNode("div",aq,[c.createElementVNode("div",{class:c.normalizeClass(a.dividerStyle(-1))},null,2)])]))],2)}const rq=rt(JQ,[["render",oq],["__scopeId","data-v-6046312d"]]);var $_={exports:{}};(function(e){e.exports=function(t){var n={};function i(s){if(n[s])return n[s].exports;var a=n[s]={i:s,l:!1,exports:{}};return t[s].call(a.exports,a,a.exports,i),a.l=!0,a.exports}return i.m=t,i.c=n,i.d=function(s,a,o){i.o(s,a)||Object.defineProperty(s,a,{enumerable:!0,get:o})},i.r=function(s){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(s,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(s,"__esModule",{value:!0})},i.t=function(s,a){if(a&1&&(s=i(s)),a&8||a&4&&typeof s=="object"&&s&&s.__esModule)return s;var o=Object.create(null);if(i.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:s}),a&2&&typeof s!="string")for(var l in s)i.d(o,l,function(d){return s[d]}.bind(null,l));return o},i.n=function(s){var a=s&&s.__esModule?function(){return s.default}:function(){return s};return i.d(a,"a",a),a},i.o=function(s,a){return Object.prototype.hasOwnProperty.call(s,a)},i.p="",i(i.s="fae3")}({"01f9":function(t,n,i){var s=i("2d00"),a=i("5ca1"),o=i("2aba"),l=i("32e9"),d=i("84f2"),h=i("41a0"),f=i("7f20"),m=i("38fd"),v=i("2b4c")("iterator"),y=!([].keys&&"next"in[].keys()),w="@@iterator",x="keys",k="values",D=function(){return this};t.exports=function(E,B,S,A,I,F,L){h(S,B,A);var W=function(R){if(!y&&R in et)return et[R];switch(R){case x:return function(){return new S(this,R)};case k:return function(){return new S(this,R)}}return function(){return new S(this,R)}},X=B+" Iterator",Z=I==k,Q=!1,et=E.prototype,gt=et[v]||et[w]||I&&et[I],at=gt||W(I),ft=I?Z?W("entries"):at:void 0,lt=B=="Array"&&et.entries||gt,vt,xt,ct;if(lt&&(ct=m(lt.call(new E)),ct!==Object.prototype&&ct.next&&(f(ct,X,!0),!s&&typeof ct[v]!="function"&&l(ct,v,D))),Z&>&>.name!==k&&(Q=!0,at=function(){return gt.call(this)}),(!s||L)&&(y||Q||!et[v])&&l(et,v,at),d[B]=at,d[X]=D,I)if(vt={values:Z?at:W(k),keys:F?at:W(x),entries:ft},L)for(xt in vt)xt in et||o(et,xt,vt[xt]);else a(a.P+a.F*(y||Q),B,vt);return vt}},"0d58":function(t,n,i){var s=i("ce10"),a=i("e11e");t.exports=Object.keys||function(l){return s(l,a)}},1495:function(t,n,i){var s=i("86cc"),a=i("cb7c"),o=i("0d58");t.exports=i("9e1e")?Object.defineProperties:function(d,h){a(d);for(var f=o(h),m=f.length,v=0,y;m>v;)s.f(d,y=f[v++],h[y]);return d}},"230e":function(t,n,i){var s=i("d3f4"),a=i("7726").document,o=s(a)&&s(a.createElement);t.exports=function(l){return o?a.createElement(l):{}}},"2aba":function(t,n,i){var s=i("7726"),a=i("32e9"),o=i("69a8"),l=i("ca5a")("src"),d=i("fa5b"),h="toString",f=(""+d).split(h);i("8378").inspectSource=function(m){return d.call(m)},(t.exports=function(m,v,y,w){var x=typeof y=="function";x&&(o(y,"name")||a(y,"name",v)),m[v]!==y&&(x&&(o(y,l)||a(y,l,m[v]?""+m[v]:f.join(String(v)))),m===s?m[v]=y:w?m[v]?m[v]=y:a(m,v,y):(delete m[v],a(m,v,y)))})(Function.prototype,h,function(){return typeof this=="function"&&this[l]||d.call(this)})},"2aeb":function(t,n,i){var s=i("cb7c"),a=i("1495"),o=i("e11e"),l=i("613b")("IE_PROTO"),d=function(){},h="prototype",f=function(){var m=i("230e")("iframe"),v=o.length,y="<",w=">",x;for(m.style.display="none",i("fab2").appendChild(m),m.src="javascript:",x=m.contentWindow.document,x.open(),x.write(y+"script"+w+"document.F=Object"+y+"/script"+w),x.close(),f=x.F;v--;)delete f[h][o[v]];return f()};t.exports=Object.create||function(v,y){var w;return v!==null?(d[h]=s(v),w=new d,d[h]=null,w[l]=v):w=f(),y===void 0?w:a(w,y)}},"2b4c":function(t,n,i){var s=i("5537")("wks"),a=i("ca5a"),o=i("7726").Symbol,l=typeof o=="function",d=t.exports=function(h){return s[h]||(s[h]=l&&o[h]||(l?o:a)("Symbol."+h))};d.store=s},"2d00":function(t,n){t.exports=!1},"2d95":function(t,n){var i={}.toString;t.exports=function(s){return i.call(s).slice(8,-1)}},"32e9":function(t,n,i){var s=i("86cc"),a=i("4630");t.exports=i("9e1e")?function(o,l,d){return s.f(o,l,a(1,d))}:function(o,l,d){return o[l]=d,o}},"38fd":function(t,n,i){var s=i("69a8"),a=i("4bf8"),o=i("613b")("IE_PROTO"),l=Object.prototype;t.exports=Object.getPrototypeOf||function(d){return d=a(d),s(d,o)?d[o]:typeof d.constructor=="function"&&d instanceof d.constructor?d.constructor.prototype:d instanceof Object?l:null}},"41a0":function(t,n,i){var s=i("2aeb"),a=i("4630"),o=i("7f20"),l={};i("32e9")(l,i("2b4c")("iterator"),function(){return this}),t.exports=function(d,h,f){d.prototype=s(l,{next:a(1,f)}),o(d,h+" Iterator")}},4588:function(t,n){var i=Math.ceil,s=Math.floor;t.exports=function(a){return isNaN(a=+a)?0:(a>0?s:i)(a)}},4630:function(t,n){t.exports=function(i,s){return{enumerable:!(i&1),configurable:!(i&2),writable:!(i&4),value:s}}},"4bf8":function(t,n,i){var s=i("be13");t.exports=function(a){return Object(s(a))}},5537:function(t,n,i){var s=i("8378"),a=i("7726"),o="__core-js_shared__",l=a[o]||(a[o]={});(t.exports=function(d,h){return l[d]||(l[d]=h!==void 0?h:{})})("versions",[]).push({version:s.version,mode:i("2d00")?"pure":"global",copyright:"\xA9 2020 Denis Pushkarev (zloirock.ru)"})},"5ca1":function(t,n,i){var s=i("7726"),a=i("8378"),o=i("32e9"),l=i("2aba"),d=i("9b43"),h="prototype",f=function(m,v,y){var w=m&f.F,x=m&f.G,k=m&f.S,D=m&f.P,E=m&f.B,B=x?s:k?s[v]||(s[v]={}):(s[v]||{})[h],S=x?a:a[v]||(a[v]={}),A=S[h]||(S[h]={}),I,F,L,W;x&&(y=v);for(I in y)F=!w&&B&&B[I]!==void 0,L=(F?B:y)[I],W=E&&F?d(L,s):D&&typeof L=="function"?d(Function.call,L):L,B&&l(B,I,L,m&f.U),S[I]!=L&&o(S,I,W),D&&A[I]!=L&&(A[I]=L)};s.core=a,f.F=1,f.G=2,f.S=4,f.P=8,f.B=16,f.W=32,f.U=64,f.R=128,t.exports=f},"613b":function(t,n,i){var s=i("5537")("keys"),a=i("ca5a");t.exports=function(o){return s[o]||(s[o]=a(o))}},"626a":function(t,n,i){var s=i("2d95");t.exports=Object("z").propertyIsEnumerable(0)?Object:function(a){return s(a)=="String"?a.split(""):Object(a)}},6821:function(t,n,i){var s=i("626a"),a=i("be13");t.exports=function(o){return s(a(o))}},"69a8":function(t,n){var i={}.hasOwnProperty;t.exports=function(s,a){return i.call(s,a)}},"6a99":function(t,n,i){var s=i("d3f4");t.exports=function(a,o){if(!s(a))return a;var l,d;if(o&&typeof(l=a.toString)=="function"&&!s(d=l.call(a))||typeof(l=a.valueOf)=="function"&&!s(d=l.call(a))||!o&&typeof(l=a.toString)=="function"&&!s(d=l.call(a)))return d;throw TypeError("Can't convert object to primitive value")}},7726:function(t,n){var i=t.exports=typeof window<"u"&&window.Math==Math?window:typeof self<"u"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=i)},"77f1":function(t,n,i){var s=i("4588"),a=Math.max,o=Math.min;t.exports=function(l,d){return l=s(l),l<0?a(l+d,0):o(l,d)}},"79e5":function(t,n){t.exports=function(i){try{return!!i()}catch{return!0}}},"7f20":function(t,n,i){var s=i("86cc").f,a=i("69a8"),o=i("2b4c")("toStringTag");t.exports=function(l,d,h){l&&!a(l=h?l:l.prototype,o)&&s(l,o,{configurable:!0,value:d})}},"7f7f":function(t,n,i){var s=i("86cc").f,a=Function.prototype,o=/^\s*function ([^ (]*)/,l="name";l in a||i("9e1e")&&s(a,l,{configurable:!0,get:function(){try{return(""+this).match(o)[1]}catch{return""}}})},8378:function(t,n){var i=t.exports={version:"2.6.12"};typeof __e=="number"&&(__e=i)},"84f2":function(t,n){t.exports={}},"86cc":function(t,n,i){var s=i("cb7c"),a=i("c69a"),o=i("6a99"),l=Object.defineProperty;n.f=i("9e1e")?Object.defineProperty:function(h,f,m){if(s(h),f=o(f,!0),s(m),a)try{return l(h,f,m)}catch{}if("get"in m||"set"in m)throw TypeError("Accessors not supported!");return"value"in m&&(h[f]=m.value),h}},"9b43":function(t,n,i){var s=i("d8e8");t.exports=function(a,o,l){if(s(a),o===void 0)return a;switch(l){case 1:return function(d){return a.call(o,d)};case 2:return function(d,h){return a.call(o,d,h)};case 3:return function(d,h,f){return a.call(o,d,h,f)}}return function(){return a.apply(o,arguments)}}},"9c6c":function(t,n,i){var s=i("2b4c")("unscopables"),a=Array.prototype;a[s]==null&&i("32e9")(a,s,{}),t.exports=function(o){a[s][o]=!0}},"9def":function(t,n,i){var s=i("4588"),a=Math.min;t.exports=function(o){return o>0?a(s(o),9007199254740991):0}},"9e1e":function(t,n,i){t.exports=!i("79e5")(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7})},ac6a:function(t,n,i){for(var s=i("cadf"),a=i("0d58"),o=i("2aba"),l=i("7726"),d=i("32e9"),h=i("84f2"),f=i("2b4c"),m=f("iterator"),v=f("toStringTag"),y=h.Array,w={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},x=a(w),k=0;k<x.length;k++){var D=x[k],E=w[D],B=l[D],S=B&&B.prototype,A;if(S&&(S[m]||d(S,m,y),S[v]||d(S,v,D),h[D]=y,E))for(A in s)S[A]||o(S,A,s[A],!0)}},be13:function(t,n){t.exports=function(i){if(i==null)throw TypeError("Can't call method on "+i);return i}},c366:function(t,n,i){var s=i("6821"),a=i("9def"),o=i("77f1");t.exports=function(l){return function(d,h,f){var m=s(d),v=a(m.length),y=o(f,v),w;if(l&&h!=h){for(;v>y;)if(w=m[y++],w!=w)return!0}else for(;v>y;y++)if((l||y in m)&&m[y]===h)return l||y||0;return!l&&-1}}},c69a:function(t,n,i){t.exports=!i("9e1e")&&!i("79e5")(function(){return Object.defineProperty(i("230e")("div"),"a",{get:function(){return 7}}).a!=7})},ca5a:function(t,n){var i=0,s=Math.random();t.exports=function(a){return"Symbol(".concat(a===void 0?"":a,")_",(++i+s).toString(36))}},cadf:function(t,n,i){var s=i("9c6c"),a=i("d53b"),o=i("84f2"),l=i("6821");t.exports=i("01f9")(Array,"Array",function(d,h){this._t=l(d),this._i=0,this._k=h},function(){var d=this._t,h=this._k,f=this._i++;return!d||f>=d.length?(this._t=void 0,a(1)):h=="keys"?a(0,f):h=="values"?a(0,d[f]):a(0,[f,d[f]])},"values"),o.Arguments=o.Array,s("keys"),s("values"),s("entries")},cb7c:function(t,n,i){var s=i("d3f4");t.exports=function(a){if(!s(a))throw TypeError(a+" is not an object!");return a}},ce10:function(t,n,i){var s=i("69a8"),a=i("6821"),o=i("c366")(!1),l=i("613b")("IE_PROTO");t.exports=function(d,h){var f=a(d),m=0,v=[],y;for(y in f)y!=l&&s(f,y)&&v.push(y);for(;h.length>m;)s(f,y=h[m++])&&(~o(v,y)||v.push(y));return v}},d3f4:function(t,n){t.exports=function(i){return typeof i=="object"?i!==null:typeof i=="function"}},d53b:function(t,n){t.exports=function(i,s){return{value:s,done:!!i}}},d8e8:function(t,n){t.exports=function(i){if(typeof i!="function")throw TypeError(i+" is not a function!");return i}},e11e:function(t,n){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},f6fd:function(t,n){(function(i){var s="currentScript",a=i.getElementsByTagName("script");s in i||Object.defineProperty(i,s,{get:function(){try{throw new Error}catch(d){var o,l=(/.*at [^\(]*\((.*):.+:.+\)$/ig.exec(d.stack)||[!1])[1];for(o in a)if(a[o].src==l||a[o].readyState=="interactive")return a[o];return null}}})})(document)},fa5b:function(t,n,i){t.exports=i("5537")("native-function-to-string",Function.toString)},fab2:function(t,n,i){var s=i("7726").document;t.exports=s&&s.documentElement},fae3:function(t,n,i){if(i.r(n),i.d(n,"longClickDirective",function(){return o}),typeof window<"u"){i("f6fd");var s;(s=window.document.currentScript)&&(s=s.src.match(/(.+\/)[^/]+\.js(\?.*)?$/))&&(i.p=s[1])}i("ac6a"),i("7f7f");var a=function(l){var d=l.delay,h=d===void 0?400:d,f=l.interval,m=f===void 0?50:f;return{beforeMount:function(y,w,x,k){if(typeof w.value!="function"){var D=x.context.name,E="[longclick:] provided expression '".concat(w.expression,"' is not a function, but has to be");D&&(E+="Found in component '".concat(D,"' ")),console.warn(E)}var B=null,S=null,A=function(W){w.value(W)},I=function(W){W.type==="click"&&W.button!==0||B===null&&(B=setTimeout(function(){m&&m>0&&(S=setInterval(function(){A(W)},m)),A(W)},h))},F=function(){B!==null&&(clearTimeout(B),B=null),S&&(clearInterval(S),S=null)};["mousedown","touchstart"].forEach(function(L){y.addEventListener(L,I,{passive:!0})}),["click","mouseout","touchend","touchcancel"].forEach(function(L){y.addEventListener(L,F,{passive:!0})})},created:function(){},mounted:function(){},beforeUpdate:function(){},updated:function(){},beforeUnmount:function(){},unmounted:function(){}}},o=a}})})($_);const eht="",lq=$_.exports.longClickDirective({delay:400,interval:50}),cq={components:{CdsIcon:Me},directives:{longclick:lq},props:{modelValue:{type:[Number,String],default:0},max:{type:[Number,String],default:Number.MAX_SAFE_INTEGER},min:{type:[Number,String],default:Number.MIN_SAFE_INTEGER},label:{type:String,default:"Label"},required:{type:Boolean,default:!1},width:{type:String,default:"default",required:!1},disabled:{type:Boolean,default:!1},state:{type:String,default:"default"},errorMessage:{type:String,default:"Valor inv\xE1lido"}},data(){return{internalValue:this.modelValue,isBeingFocused:!1}},computed:{hasSlots(){return!!Object.keys(this.$slots).length},errorState(){return this.state==="invalid"},stepperInputDynamicClass(){let e="";return this.isBeingFocused?this.disabled||(this.state==="default"?e+=" stepper-input--focused":this.state==="valid"?e+=" stepper-input--focused-valid":this.state==="invalid"&&(e+=" stepper-input--focused-invalid")):(e="stepper-input",this.disabled?e+=" stepper-input--disabled":this.state==="valid"?e+=" stepper-input--valid":this.state==="invalid"&&(e+=" stepper-input--invalid")),e}},watch:{modelValue(e){this.internalValue=e},internalValue(e){e||(this.internalValue=0),typeof e=="string"&&(this.internalValue=+this.internalValue),e<this.min?(this.internalValue=this.min,this.$emit("invalid-number",`'O campo n\xE3o pode ser menor que ${parseInt(this.min,10)}.'`)):e>this.max?(this.internalValue=this.max,this.$emit("invalid-number",`'O campo n\xE3o pode ser maior que ${parseInt(this.max,10)}.'`)):this.$emit("update:modelValue",parseInt(e,10))}},methods:{changeValue(e){this.internalValue=parseInt(this.internalValue)+e}}},dq={key:0},uq={key:1,class:"stepper-input__label",for:"stepper-input"},hq={key:0,class:"stepper-input__label--required-indicator"},fq=["disabled"],pq={class:"stepper-input__icon-container"},mq=["disabled"],gq=["disabled"],vq={key:0,class:"stepper-input__error-message"};function _q(e,t,n,i,s,a){const o=c.resolveComponent("cds-icon"),l=c.resolveDirective("longclick");return c.openBlock(),c.createElementBlock("div",null,[c.createElementVNode("span",null,[a.hasSlots?(c.openBlock(),c.createElementBlock("span",dq,[c.renderSlot(e.$slots,"label",{},void 0,!0)])):(c.openBlock(),c.createElementBlock("label",uq,[c.createElementVNode("span",null,c.toDisplayString(n.label),1),n.required?(c.openBlock(),c.createElementBlock("span",hq," * ")):c.createCommentVNode("",!0)]))]),c.createElementVNode("div",{class:c.normalizeClass(a.stepperInputDynamicClass)},[c.withDirectives(c.createElementVNode("input",{id:"stepper-input","onUpdate:modelValue":t[0]||(t[0]=d=>s.internalValue=d),disabled:n.disabled,class:c.normalizeClass(["stepper-input__field",{"stepper-input__field--thin":n.width==="thin","stepper-input__field--default":n.width==="default","stepper-input__field--wide":n.width=="wide"}]),type:"number",onFocus:t[1]||(t[1]=d=>s.isBeingFocused=!0),onBlur:t[2]||(t[2]=d=>s.isBeingFocused=!1)},null,42,fq),[[c.vModelText,s.internalValue]]),c.createElementVNode("div",pq,[c.withDirectives((c.openBlock(),c.createElementBlock("button",{disabled:n.disabled,class:"stepper-input__icon--plus",tabindex:"-1",onFocus:t[3]||(t[3]=d=>s.isBeingFocused=!0),onBlur:t[4]||(t[4]=d=>s.isBeingFocused=!1),onClick:t[5]||(t[5]=d=>a.changeValue(1))},[c.createVNode(o,{height:"16",width:"16",name:"plus-outline"})],40,mq)),[[l,()=>a.changeValue(1)]]),c.withDirectives((c.openBlock(),c.createElementBlock("button",{disabled:n.disabled,class:"stepper-input__icon--minus",tabindex:"-1",onFocus:t[6]||(t[6]=d=>s.isBeingFocused=!0),onBlur:t[7]||(t[7]=d=>s.isBeingFocused=!1),onClick:t[8]||(t[8]=d=>a.changeValue(-1))},[c.createVNode(o,{height:"16",width:"16",name:"minus-outline"})],40,gq)),[[l,()=>a.changeValue(-1)]])])],2),a.errorState&&!n.disabled?(c.openBlock(),c.createElementBlock("div",vq,c.toDisplayString(n.errorMessage),1)):c.createCommentVNode("",!0)])}const yq=rt(cq,[["render",_q],["__scopeId","data-v-0bcdcaeb"]]),nht="",bq={props:{modelValue:{type:Boolean,default:!1,required:!0},small:{type:Boolean,default:!1},variant:{type:String,default:"green"},large:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},focused:{type:Boolean,default:!1}},data(){return{isActive:this.modelValue,internalFocus:this.focused}},computed:{toggleSwitchSize(){return this.small===this.large?"switch--medium":this.small?"switch--small":"switch--large"}},watch:{modelValue(e,t){e!==t&&(this.isActive=e)}},methods:{handleClick(){this.$emit("update:modelValue",!this.isActive)}}},wq=["disabled"];function xq(e,t,n,i,s,a){return c.openBlock(),c.createElementBlock("div",null,[c.createElementVNode("label",{class:c.normalizeClass(["switch",a.toggleSwitchSize])},[c.withDirectives(c.createElementVNode("input",{"onUpdate:modelValue":t[0]||(t[0]=o=>s.isActive=o),type:"checkbox",disabled:n.disabled,onClick:t[1]||(t[1]=(...o)=>a.handleClick&&a.handleClick(...o))},null,8,wq),[[c.vModelCheckbox,s.isActive]]),c.createElementVNode("span",{tabindex:"0",class:c.normalizeClass(["switch__slider",[`switch__slider--${n.variant}`,{[`switch__slider--active-focused--${n.variant}`]:s.internalFocus&&s.isActive&&!n.disabled,"switch__slider--inactive-focused":s.internalFocus&&!s.isActive&&!n.disabled,"switch__slider--small":n.small&&n.small!==n.large,"switch__slider--large":n.large&&n.small!==n.large,"switch__slider--medium":n.small===n.large}]]),onFocusout:t[2]||(t[2]=o=>s.internalFocus=!1),onFocusin:t[3]||(t[3]=o=>s.internalFocus=!0)},null,34)],2)])}const Sq=rt(bq,[["render",xq],["__scopeId","data-v-d1c48c91"]]);var oo={exports:{}};/**
|
|
53
53
|
* @license
|
|
54
54
|
* Lodash <https://lodash.com/>
|
|
55
55
|
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|