@krds.ui/vue 0.0.8 → 0.0.9

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.
@@ -1,2 +1,2 @@
1
- (function(b,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(b=typeof globalThis<"u"?globalThis:b||self,e(b.KrdsVue={},b.Vue))})(this,(function(b,e){"use strict";const O=e.defineComponent({name:"KrdsButton",props:{type:{type:String,default:"button"},size:{type:String,default:void 0},variant:{type:String,default:"primary"},icon:{type:Boolean,default:!1},border:{type:Boolean,default:!1},pure:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:r,slots:s}){const a=e.computed(()=>{const o=["krds-btn"];return t.icon&&o.push("icon"),t.border&&o.push("border"),t.pure&&o.push("pure"),t.variant&&!t.icon&&o.push(t.variant),t.size&&o.push(t.size),t.class&&o.push(t.class),o}),n=o=>{t.disabled||r("click",o)};return()=>e.h("button",{type:t.type,class:a.value,disabled:t.disabled,onClick:n},s.default?.())}}),Y=e.defineComponent({name:"KrdsButtonGroup",props:{},setup(t,{slots:r}){return()=>e.h("div",{class:"btn-group"},r.default?.())}}),G=e.defineComponent({name:"KrdsIcon",props:{name:{type:String,required:!0},class:{type:String,default:void 0}},setup(t){return()=>e.h("i",{class:["svg-icon",t.name,t.class].filter(Boolean).join(" ")})}}),U=e.defineComponent({name:"KrdsLink",props:{href:{type:String,default:"#!"},target:{type:String,default:void 0},title:{type:String,default:void 0},size:{type:String,default:void 0},link:{type:Boolean,default:!0},basic:{type:Boolean,default:!1},pure:{type:Boolean,default:!1},class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:r,slots:s}){const a=e.computed(()=>{const i=["krds-btn"];return t.size&&i.push(t.size),t.link&&i.push("link"),t.basic&&i.push("basic"),t.pure&&i.push("pure"),t.class&&i.push(t.class),i}),n=e.computed(()=>{const i={href:t.href,class:a.value};return t.target&&(i.target=t.target),t.title&&(i.title=t.title),t.target==="_blank"&&(i.rel="noopener noreferrer"),i}),o=i=>{r("click",i)};return()=>e.h("a",{...n.value,onClick:o},s.default?.())}}),q=e.defineComponent({name:"KrdsSpinner",props:{label:{type:String,default:void 0}},render(){const t=[e.h("span",{class:"sr-only"},"로딩 중")];return this.label&&t.push(e.h("span",this.label)),e.h("div",{class:"krds-spinner",role:"status"},t)}}),X=e.defineComponent({name:"KrdsInput",props:{modelValue:{type:[String,Number],default:void 0},type:{type:String,default:"text"},size:{type:String,default:void 0},placeholder:{type:String,default:void 0},maxlength:{type:Number,default:void 0},minlength:{type:Number,default:void 0},max:{type:Number,default:void 0},min:{type:Number,default:void 0},step:{type:Number,default:void 0},autocomplete:{type:String,default:void 0},autofocus:{type:Boolean,default:!1},name:{type:String,default:void 0},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},error:{type:String,default:void 0},state:{type:String,default:"default"},icon:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","input","change","focus","blur","keydown","keyup"],setup(t,{emit:r,slots:s}){const a=e.computed(()=>{const g=["krds-input"];return t.size&&g.push(t.size),t.class&&g.push(t.class),g}),n=g=>{const w=g.target,m=t.type==="number"?Number(w.value):w.value;r("update:modelValue",m),r("input",g)},o=g=>{r("change",g)},i=g=>{r("focus",g)},u=g=>{r("blur",g)},d=g=>{r("keydown",g)},h=g=>{r("keyup",g)},y=e.computed(()=>{const g={type:t.type,class:a.value,value:t.modelValue,placeholder:t.placeholder,name:t.name,id:t.id,required:t.required,readonly:t.readonly,disabled:t.disabled,autocomplete:t.autocomplete,autofocus:t.autofocus,onInput:n,onChange:o,onFocus:i,onBlur:u,onKeydown:d,onKeyup:h};return t.maxlength!==void 0&&(g.maxlength=t.maxlength),t.minlength!==void 0&&(g.minlength=t.minlength),t.type==="number"&&(t.max!==void 0&&(g.max=t.max),t.min!==void 0&&(g.min=t.min),t.step!==void 0&&(g.step=t.step)),g}),C=e.computed(()=>{const g=["form-conts"];return t.state!=="default"&&g.push(`is-${t.state}`),t.icon&&g.push("btn-ico-wrap"),g});return()=>{const g=[e.h("input",y.value)];return t.loading?e.h("div",{class:C.value},[e.h("div",{class:"form-spinner"},[...g,e.h(q)])]):(s.default&&g.push(...s.default()),e.h("div",{class:C.value},g))}}}),J=e.defineComponent({name:"KrdsFormLabel",props:{for:{type:String,default:void 0},class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},emits:["click"],setup(t,{emit:r,slots:s}){const a=n=>{r("click",n)};return()=>e.h("div",{class:"form-tit"},[e.h("label",{for:t.for,id:t.id,class:t.class,style:t.style,onClick:a},s.default?.())])}}),Q=e.defineComponent({name:"KrdsFormHint",props:{type:{type:String,default:"hint"},class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},emits:["click"],setup(t,{emit:r,slots:s}){const a=o=>{r("click",o)},n=()=>{let o;switch(t.type){case"error":o="form-hint-invalid";break;case"success":o="form-hint-success";break;case"information":o="form-hint-information";break;default:o="form-hint";break}return t.class?`${o} ${t.class}`:o};return()=>e.h("p",{id:t.id,class:n(),style:t.style,onClick:a},s.default?.())}}),Z=e.defineComponent({name:"KrdsFormGroup",props:{class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},setup(t,{slots:r}){const s=e.computed(()=>{const a=["form-group"];return t.class&&a.push(t.class),a});return()=>e.h("div",{id:t.id,class:s.value,style:t.style},r.default?.())}});function $e(t,r){const s=new Date,a=e.ref(t||s.getFullYear()),n=e.ref(r||s.getMonth()+1),o=e.ref(null),i=e.ref(null),u=e.ref(null),d=e.computed(()=>{const p=s.getFullYear(),c=[];for(let f=p-10;f<=p+10;f++)c.push(f);return c}),h=e.computed(()=>Array.from({length:12},(p,c)=>c+1)),y=()=>{o.value=null,i.value=null},C=()=>{n.value===1?(n.value=12,a.value-=1):n.value-=1},g=()=>{n.value===12?(n.value=1,a.value+=1):n.value+=1},w=(p,c=!1)=>{if(c)o.value=p,i.value=p;else if(!o.value||o.value&&i.value)o.value=p,i.value=null;else{const f=new Date(o.value.replace(/\./g,"-"));new Date(p.replace(/\./g,"-"))<f?(o.value=p,i.value=null):i.value=p}};return{currentYear:a,currentMonth:n,selectedStartDate:o,selectedEndDate:i,activeDateSelector:u,yearOptions:d,monthOptions:h,clearDateSelection:y,prevMonth:C,nextMonth:g,handleDateSelection:w,selectToday:()=>{const p=`${s.getFullYear()}.${String(s.getMonth()+1).padStart(2,"0")}.${String(s.getDate()).padStart(2,"0")}`;w(p,!0)},isDateInSelectedRange:p=>{if(!o.value||!i.value)return{isInRange:!1,isStart:!1,isEnd:!1};const c=new Date(p.replace(/\./g,"-")),f=new Date(o.value.replace(/\./g,"-")),E=new Date(i.value.replace(/\./g,"-")),K=p===o.value,v=p===i.value;return{isInRange:c>=f&&c<=E,isStart:K,isEnd:v}}}}function Le(t,r,s={}){let a=null;const n=typeof s=="string"?{ignore:s}:s,{ignore:o,event:i="click"}=n,u=()=>{a=h=>{const y=h.target;t.value?.contains(y)||o&&y.closest(o)||r()},document.addEventListener(i,a)},d=()=>{if(a){const h=typeof s=="string"?"click":s.event||"click";document.removeEventListener(h,a),a=null}};return e.onMounted(()=>{u()}),e.onBeforeUnmount(()=>{d()}),{setupGlobalListeners:u,removeGlobalListeners:d}}const xe={class:"form-conts"},Ie={class:"calendar-input"},Te=["id","name","placeholder","value","readonly","disabled","required","autofocus"],Me=["disabled","aria-expanded"],Re={class:"calendar-head"},Fe={class:"calendar-switch-wrap"},Pe={class:"calendar-drop-down"},Ae=["aria-expanded"],Oe={class:"calendar-select calendar-year-wrap"},qe={class:"sel year"},He=["onClick"],je={class:"calendar-drop-down"},We=["aria-expanded"],Ye={class:"calendar-select calendar-mon-wrap"},Ge={class:"sel month"},Ue=["onClick"],Xe={class:"calendar-body"},Je={class:"calendar-table-wrap"},Qe={class:"calendar-tbl"},Ze=["data-date"],et=["aria-pressed","onClick"],tt={class:"calendar-footer"},nt={class:"calendar-btn-wrap"},ee=e.defineComponent({__name:"KrdsDateInput",props:{modelValue:{default:void 0},size:{default:"medium"},placeholder:{default:"YYYY.MM.DD"},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},autofocus:{type:Boolean,default:!1},eventDates:{default:()=>[]},holidays:{default:()=>[]},initialYear:{default:void 0},initialMonth:{default:void 0},name:{default:void 0},required:{type:Boolean,default:!1},class:{default:void 0},style:{},id:{default:void 0}},emits:["update:modelValue","input","change","focus","blur"],setup(t,{emit:r}){const s=t,a=r,n=e.ref(),o=e.ref(),i=e.ref(!1),u=e.ref(null),{currentYear:d,currentMonth:h,selectedStartDate:y,selectedEndDate:C,yearOptions:g,monthOptions:w,prevMonth:m,nextMonth:l,handleDateSelection:p,selectToday:c,isDateInSelectedRange:f}=$e(s.initialYear,s.initialMonth),E=()=>{i.value&&o.value?.focus(),i.value=!1,u.value=null};Le(n,E,".calendar-conts");const K=e.computed(()=>{const k=["krds-input","datepicker","cal"];return s.size&&k.push(s.size),s.class&&k.push(s.class),k}),v=e.computed(()=>["form-conts","calendar-conts"]),_=e.computed(()=>({"krds-calendar-area":!0,active:i.value})),N=e.computed(()=>{const k=d.value,S=h.value,V=new Date(k,S-1,1),T=new Date(V);T.setDate(T.getDate()-V.getDay());const I=[],D=new Date(T);for(let W=0;W<6;W++){const Ke=[];for(let De=0;De<7;De++){const Gt=`${D.getFullYear()}.${String(D.getMonth()+1).padStart(2,"0")}.${String(D.getDate()).padStart(2,"0")}`,ze=D.getDay();Ke.push({day:D.getDate(),dateString:Gt,isCurrentMonth:D.getMonth()===S-1,isToday:D.toDateString()===new Date().toDateString(),isPrevMonth:D.getMonth()<S-1||D.getMonth()===11&&S===1,isNextMonth:D.getMonth()>S-1||D.getMonth()===0&&S===12,isSunday:ze===0,isSaturday:ze===6}),D.setDate(D.getDate()+1)}I.push(Ke)}return I}),L=k=>{const S=[];if(k.isPrevMonth&&S.push("old"),k.isNextMonth&&S.push("new"),k.isToday&&S.push("today"),k.isSunday&&S.push("day-off"),s.holidays?.includes(k.dateString)&&S.push("day-off"),s.eventDates?.includes(k.dateString)&&S.push("day-event"),k.isCurrentMonth){const V=f(k.dateString);V.isInRange&&(S.push("period"),V.isStart&&S.push("start"),V.isEnd&&S.push("end"))}return S},B=e.computed(()=>[{id:"get-today",label:"오늘",class:"text",variant:void 0,size:"small",handler:c},{id:"cancel-btn",label:"취소",class:void 0,variant:"tertiary",size:"small",handler:E},{id:"confirm-btn",label:"확인",class:void 0,variant:"primary",size:"small",handler:M}]),x=k=>{u.value===k?u.value=null:u.value=k},P=k=>{d.value=k,u.value=null},j=k=>{h.value=k,u.value=null},M=()=>{if(y.value){if(C.value&&y.value!==C.value){const k=`${y.value} ~ ${C.value}`;a("update:modelValue",k)}else a("update:modelValue",y.value);E()}},z=()=>{i.value=!0,u.value=null,setTimeout(()=>{n.value?.querySelector(".calendar-wrap")?.focus()},50)},$=()=>{i.value?E():z()},_e=k=>{k.code==="Escape"&&(u.value?u.value=null:i.value&&E())},A=k=>{const S=k.target;a("update:modelValue",S.value),a("input",k)},jt=k=>{a("change",k)},Wt=k=>{a("focus",k)},Yt=k=>{a("blur",k)};return(k,S)=>(e.openBlock(),e.createElementBlock("div",xe,[e.createElementVNode("div",{class:e.normalizeClass(v.value)},[e.createElementVNode("div",Ie,[e.createElementVNode("input",{id:k.id,name:k.name,class:e.normalizeClass(K.value),placeholder:k.placeholder,value:k.modelValue,readonly:k.readonly,disabled:k.disabled,required:k.required,autofocus:k.autofocus,type:"text",onInput:A,onChange:jt,onFocus:Wt,onBlur:Yt},null,42,Te),e.createElementVNode("button",{ref_key:"datePickerButtonRef",ref:o,class:e.normalizeClass(`krds-btn ${k.size||"medium"} icon form-btn-datepicker`),disabled:k.disabled,"aria-expanded":i.value,type:"button",onClick:$},[...S[4]||(S[4]=[e.createElementVNode("span",{class:"sr-only"},"달력 열기",-1),e.createElementVNode("i",{class:"svg-icon ico-calendar"},null,-1)])],10,Me)]),e.createElementVNode("div",{ref_key:"datePickerAreaRef",ref:n,class:e.normalizeClass(_.value)},[e.withDirectives(e.createElementVNode("div",{class:"calendar-wrap bottom","aria-label":"달력",tabindex:"0",onKeydown:_e},[e.createElementVNode("div",Re,[e.createElementVNode("button",{type:"button",class:"btn-cal-move prev",onClick:S[0]||(S[0]=(...V)=>e.unref(m)&&e.unref(m)(...V))},[...S[5]||(S[5]=[e.createElementVNode("span",{class:"sr-only"},"이전 달",-1)])]),e.createElementVNode("div",Fe,[e.createElementVNode("div",Pe,[e.createElementVNode("button",{type:"button",class:"btn-cal-switch year","aria-label":"연도 선택","aria-expanded":u.value==="year",onClick:S[1]||(S[1]=V=>x("year"))},e.toDisplayString(e.unref(d))+"년 ",9,Ae),e.withDirectives(e.createElementVNode("div",Oe,[e.createElementVNode("ul",qe,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(g),V=>(e.openBlock(),e.createElementBlock("li",{key:V},[e.createElementVNode("button",{type:"button",class:e.normalizeClass({active:V===e.unref(d)}),onClick:T=>P(V)},e.toDisplayString(V)+"년",11,He)]))),128))])],512),[[e.vShow,u.value==="year"]])]),e.createElementVNode("div",je,[e.createElementVNode("button",{type:"button",class:"btn-cal-switch month","aria-label":"월 선택","aria-expanded":u.value==="month",onClick:S[2]||(S[2]=V=>x("month"))},e.toDisplayString(e.unref(h).toString().padStart(2,"0"))+"월 ",9,We),e.withDirectives(e.createElementVNode("div",Ye,[e.createElementVNode("ul",Ge,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(w),V=>(e.openBlock(),e.createElementBlock("li",{key:V},[e.createElementVNode("button",{type:"button",class:e.normalizeClass({active:V===e.unref(h)}),onClick:T=>j(V)},e.toDisplayString(V.toString().padStart(2,"0"))+"월 ",11,Ue)]))),128))])],512),[[e.vShow,u.value==="month"]])])]),e.createElementVNode("button",{type:"button",class:"btn-cal-move next",onClick:S[3]||(S[3]=(...V)=>e.unref(l)&&e.unref(l)(...V))},[...S[6]||(S[6]=[e.createElementVNode("span",{class:"sr-only"},"다음 달",-1)])])]),e.createElementVNode("div",Xe,[e.createElementVNode("div",Je,[e.createElementVNode("table",Qe,[e.createElementVNode("caption",null,e.toDisplayString(e.unref(d))+"년 "+e.toDisplayString(e.unref(h).toString().padStart(2,"0"))+"월",1),S[7]||(S[7]=e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",null,"일"),e.createElementVNode("th",null,"월"),e.createElementVNode("th",null,"화"),e.createElementVNode("th",null,"수"),e.createElementVNode("th",null,"목"),e.createElementVNode("th",null,"금"),e.createElementVNode("th",null,"토")])],-1)),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(N.value,(V,T)=>(e.openBlock(),e.createElementBlock("tr",{key:T},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(V,(I,D)=>(e.openBlock(),e.createElementBlock("td",{key:D,class:e.normalizeClass(L(I)),"data-date":I.dateString},[e.createElementVNode("button",{type:"button",class:"btn-set-date","aria-pressed":e.unref(f)(I.dateString).isInRange?"true":"false",onClick:W=>e.unref(p)(I.dateString)},[e.createElementVNode("span",null,e.toDisplayString(I.day),1)],8,et)],10,Ze))),128))]))),128))])])])]),e.createElementVNode("div",tt,[e.createElementVNode("div",nt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,V=>(e.openBlock(),e.createBlock(e.unref(O),{id:V.id,key:V.id,class:e.normalizeClass(V.class),variant:V.variant,size:V.size,onClick:V.handler},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(V.label),1)]),_:2},1032,["id","class","variant","size","onClick"]))),128))])])],544),[[e.vShow,i.value]])],2)],2)]))}}),te=e.defineComponent({name:"KrdsTextarea",props:{modelValue:{type:String,default:""},size:{type:String,default:void 0},placeholder:{type:String,default:void 0},maxlength:{type:Number,default:void 0},minlength:{type:Number,default:void 0},rows:{type:Number,default:4},cols:{type:Number,default:void 0},autofocus:{type:Boolean,default:!1},name:{type:String,default:void 0},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},showCount:{type:Boolean,default:!0},resize:{type:String,default:"vertical"},class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","input","change","focus","blur","keydown","keyup"],setup(t,{emit:r}){const s=e.ref(0);e.watch(()=>t.modelValue,l=>{s.value=(l||"").length},{immediate:!0});const a=e.computed(()=>{const l=["krds-input"];return t.size&&l.push(t.size),t.class&&l.push(t.class),l}),n=e.computed(()=>{const l={};return t.resize&&(l.resize=t.resize),l}),o=l=>{const c=l.target.value;s.value=c.length,r("update:modelValue",c),r("input",l)},i=l=>{r("change",l)},u=l=>{r("focus",l)},d=l=>{r("blur",l)},h=l=>{r("keydown",l)},y=l=>{r("keyup",l)},C=e.computed(()=>{const l={class:a.value,style:n.value,value:t.modelValue,placeholder:t.placeholder,name:t.name,id:t.id,required:t.required,readonly:t.readonly,disabled:t.disabled,autofocus:t.autofocus,rows:t.rows,cols:t.cols,onInput:o,onChange:i,onFocus:u,onBlur:d,onKeydown:h,onKeyup:y};return t.maxlength!==void 0&&(l.maxlength=t.maxlength),t.minlength!==void 0&&(l.minlength=t.minlength),l}),g=e.computed(()=>["form-conts"]),w=e.computed(()=>["textarea-wrap"]),m=e.computed(()=>{if(!t.showCount)return null;const l=s.value,p=t.maxlength;return{current:l,max:p||""}});return()=>{const l=[e.h("textarea",C.value)];return m.value&&l.push(e.h("p",{class:"textarea-count"},[e.h("span",{class:"count-now"},m.value.current),e.h("span",{class:"count-total"},m.value.max?`/${m.value.max}`:"")])),e.h("div",{class:g.value},[e.h("div",{class:w.value},l)])}}}),ne=e.defineComponent({name:"KrdsSelect",props:{modelValue:{type:[String,Number,null],default:null},size:{type:String,default:"medium"},title:{type:String,default:void 0},options:{type:Array,default:()=>[]},placeholder:{type:String,default:"선택"},name:{type:String,default:void 0},disabled:{type:Boolean,default:!1},state:{type:String,default:"default"},sort:{type:Boolean,default:!1},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","focus","blur"],setup(t,{emit:r,slots:s}){const a=e.computed(()=>{const y=[];return t.sort?y.push("krds-form-select-sort"):y.push("krds-form-select"),t.size&&y.push(t.size),t.class&&y.push(t.class),y}),n=y=>{const C=y.target,g=C.value===""?null:C.value;r("update:modelValue",g)},o=y=>{r("focus",y)},i=y=>{r("blur",y)},u=e.computed(()=>({class:a.value,value:t.modelValue??"",title:t.title||t.placeholder,name:t.name,id:t.id,disabled:t.disabled||t.readonly,onChange:n,onFocus:o,onBlur:i})),d=e.computed(()=>{const y=["form-conts"];return t.state!=="default"&&y.push(`is-${t.state}`),y}),h=()=>{const y=[];return t.placeholder&&!t.modelValue&&y.push(e.h("option",{value:"",disabled:!0,selected:!0},t.placeholder)),t.options&&t.options.length>0&&t.options.forEach(C=>{y.push(e.h("option",{value:C.value,disabled:C.disabled,selected:C.value===t.modelValue},C.label))}),s.default&&y.push(...s.default()),y};return()=>{const y=e.h("select",u.value,h());return t.sort?y:e.h("div",{class:d.value},[y])}}}),le=e.defineComponent({name:"KrdsFileUpload",props:{modelValue:{type:Array,default:()=>[]},size:{type:String,default:"medium"},accept:{type:String,default:void 0},maxFiles:{type:Number,default:10},maxFileSize:{type:Number,default:20*1024*1024},multiple:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1},dragAndDrop:{type:Boolean,default:!0},title:{type:String,default:"타이틀영역"},description:{type:String,default:"컨텐츠 영역"},placeholder:{type:String,default:"첨부할 파일을 여기에 끌어다 놓거나, 파일 선택 버튼을 눌러 파일을 직접 선택해주세요."},showPreview:{type:Boolean,default:!0},showDownload:{type:Boolean,default:!0},showPreviewButton:{type:Boolean,default:!0},showClearAll:{type:Boolean,default:!0},name:{type:String,default:void 0},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","file-added","file-removed","file-error","upload-start","upload-progress","upload-complete","upload-error","clear-all","download","preview"],setup(t,{emit:r}){e.ref(!1),e.computed(()=>{const a=["krds-file-upload","line"];return t.class&&a.push(t.class),a});const s=e.computed(()=>t.modelValue?.length||0);return e.computed(()=>!t.disabled&&s.value<t.maxFiles),()=>null}}),ae=e.defineComponent({name:"KrdsBadge",props:{type:{type:String,default:"outline"},color:{type:String,default:"primary"},size:{type:String,default:"large"},number:{type:Boolean,default:!1},class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:r,slots:s}){const a=e.computed(()=>{const o=["krds-badge"];return o.push(`${t.type}-${t.color}`),t.size&&o.push(t.size),t.number&&o.push("number"),t.class&&o.push(t.class),o}),n=o=>{r("click",o)};return()=>e.h("span",{type:t.type,color:t.color,size:t.size,number:t.number,class:a.value,onClick:n},s.default?.())}}),oe=e.defineComponent({name:"KrdsTag",props:{link:{type:Boolean,default:!1},href:{type:String,default:"#"},target:{type:String,default:void 0},rel:{type:String,default:void 0},class:{type:String,default:void 0}},emits:["remove"],setup(t,{emit:r,slots:s}){const a=e.computed(()=>{const i=["krds-btn-tag"];return t.link&&i.push("link"),t.class&&i.push(t.class),i}),n=i=>{r("remove",i)},o=()=>e.h("button",{type:"button",class:"btn-delete",onClick:n},[e.h("span",{class:"sr-only"},"삭제")]);return()=>{const i=[],u=s.default?.();if(u&&i.push(u),t.link||i.push(o()),t.link){const d={href:t.href,class:a.value};return t.target&&(d.target=t.target),t.rel&&(d.rel=t.rel),e.h("a",d,i)}return e.h("span",{class:a.value},i)}}}),se=e.defineComponent({name:"KrdsTagGroup",props:{size:{type:String,default:"medium"},class:{type:String,default:void 0}},setup(t,{slots:r}){const s=e.computed(()=>{const a=["krds-tag-wrap"];return t.size&&a.push(t.size),t.class&&a.push(t.class),a});return()=>e.h("div",{class:s.value},r.default?.())}}),ie=e.defineComponent({name:"KrdsMasthead",props:{class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:r,slots:s}){const a=e.computed(()=>{const o=[""];return t.class&&o.push(t.class),o}),n=o=>{r("click",o)};return()=>e.h("div",{id:"krds-masthead",class:a.value,onClick:n},[e.h("div",{class:"toggle-wrap"},[e.h("div",{class:"toggle-head"},[e.h("div",{class:"inner"},[e.h("span",{class:"nuri-txt"},s.default?.())])])])])}});let lt=0;function R(t="krds"){return`${t}-${++lt}`}function at(){const t=Date.now().toString(36).slice(-4),r=Math.random().toString(36).substring(2,5);return`${t}${r}`}function F(...t){return t.filter(Boolean).join(" ")}const re=e.defineComponent({name:"KrdsToggleSwitch",props:{modelValue:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},label:{type:String,default:void 0},size:{type:String,default:"medium",validator:t=>["medium","large"].includes(t)},name:{type:String,default:void 0},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","change"],setup(t,{emit:r,attrs:s}){const a=e.computed(()=>t.modelValue),n=e.computed(()=>F("krds-form-toggle-switch",t.size,t.class)),o=u=>{if(t.disabled)return;const h=u.target.checked;r("update:modelValue",h),r("change",h)},i=e.computed(()=>t.id||R("toggle-switch"));return()=>e.h("div",{class:n.value},[e.h("input",{type:"checkbox",id:i.value,name:t.name,checked:a.value,disabled:t.disabled,onChange:o,...s}),e.h("label",{for:i.value},[e.h("span",{class:"switch-toggle"},[e.h("i")]),t.label||""])])}}),ce=e.defineComponent({name:"KrdsCheckArea",props:{class:{type:String,default:void 0},column:{type:Boolean,default:!1}},setup(t,{slots:r}){return()=>{const s=["krds-check-area"];return t.column&&s.push("chk-column"),t.class&&s.push(t.class),e.h("div",{class:s},r.default?.())}}}),de=e.defineComponent({name:"KrdsCheckbox",props:{modelValue:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},size:{type:String,default:"medium",validator:t=>["medium","large"].includes(t)},chip:{type:Boolean,default:!1},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue"],slots:Object,setup(t,{emit:r,attrs:s,slots:a}){const n=e.computed(()=>t.modelValue),o=e.computed(()=>{const d=t.chip?"krds-form-chip":"krds-form-check";return F(d,t.size,t.class)}),i=d=>{if(t.disabled)return;const y=d.target.checked;r("update:modelValue",y)},u=e.computed(()=>t.id||R("checkbox"));return()=>{const d=[e.h("input",{type:"checkbox",id:u.value,checked:n.value,disabled:t.disabled,onChange:i,...s}),e.h("label",{for:u.value},a.default?.())];return a.description&&!t.chip&&d.push(e.h("div",{class:"krds-form-check-cnt"},e.h("p",{class:"krds-form-check-p"},a.description()))),e.h("div",{class:o.value},d)}}}),ue=e.defineComponent({name:"KrdsRadio",props:{modelValue:{type:[String,Number,Boolean],default:void 0},value:{type:[String,Number,Boolean],required:!0},disabled:{type:Boolean,default:!1},size:{type:String,default:"medium",validator:t=>["medium","large"].includes(t)},chip:{type:Boolean,default:!1},name:{type:String,default:void 0},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue"],slots:Object,setup(t,{emit:r,attrs:s,slots:a}){const n=e.computed(()=>t.modelValue===t.value),o=e.computed(()=>{const h=t.chip?"krds-form-chip":"krds-form-check";return F(h,t.size,t.class)}),i=h=>{if(t.disabled)return;h.target.checked&&r("update:modelValue",t.value)},u=e.computed(()=>t.id||R("radio")),d=e.computed(()=>t.name);return()=>{const h=[e.h("input",{type:"radio",id:u.value,name:d.value,value:String(t.value),checked:n.value,disabled:t.disabled,onChange:i,...s}),e.h("label",{for:u.value},a.default?.())];return a.description&&!t.chip&&h.push(e.h("div",{class:"krds-form-check-cnt"},e.h("p",{class:"krds-form-check-p"},a.description()))),e.h("div",{class:o.value},h)}}}),fe=e.defineComponent({name:"KrdsStepIndicator",props:{modelValue:{type:Number,default:0},class:{type:String,default:void 0}},emits:["update:modelValue"],setup(t,{slots:r}){const s=e.computed(()=>{const u=["krds-step-wrap"];return t.class&&u.push(t.class),u}),a=u=>{const d=t.modelValue||0;return u<d?"done":u===d?"active":"pending"},n=e.ref(0),o=()=>{n.value=0},i=()=>n.value++;return e.provide("stepIndicator",{activeStep:e.computed(()=>t.modelValue||0),getStepStatus:a,getNextStepIndex:i,resetStepIndex:o}),()=>(o(),e.h("ol",{class:s.value},r.default?.()))}}),me=e.defineComponent({name:"KrdsStep",props:{step:{type:[String,Number],required:!0},title:{type:String,required:!0},status:{type:String,default:void 0},class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:r,slots:s}){const a=e.inject("stepIndicator"),n=a?a.getNextStepIndex():-1,o=e.computed(()=>t.status?t.status:a&&n>=0?a.getStepStatus(n):"pending"),i=e.computed(()=>{const d=[o.value];return t.class&&d.push(t.class),d}),u=d=>{r("click",d,t.step)};return()=>{const d=o.value==="active";return e.h("li",{class:i.value,onClick:u},[e.h("span",[d&&e.h("em",{class:"sr-only"},"현재단계"),e.h("i",{class:"step"},t.step),e.h("span",{class:"step-tit"},t.title),s.default?.()])])}}}),pe=e.defineComponent({name:"KrdsSkipLink",props:{href:{type:String,required:!0,validator:t=>t.startsWith("#")},class:{type:[String,Array,Object],default:void 0},id:{type:String,default:"krds-skip-link"}},setup(t,{slots:r}){return()=>e.h("div",{id:t.id,class:t.class},[e.h("a",{href:t.href},r.default?.())])}}),ot=["id","aria-label"],st={class:"breadcrumb"},it=["href","aria-current","onClick"],rt={key:0},he=e.defineComponent({__name:"KrdsBreadcrumb",props:{items:{},id:{default:void 0},ariaLabel:{default:"현재 경로"},showHomeIcon:{type:Boolean,default:!0}},emits:["item-click"],setup(t,{emit:r}){const s=t,a=r,n=i=>i===s.items.length-1,o=(i,u)=>{i.onClick&&i.onClick(u),a("item-click",i,u)};return(i,u)=>(e.openBlock(),e.createElementBlock("nav",{id:i.id,class:"krds-breadcrumb-wrap","aria-label":i.ariaLabel},[e.createElementVNode("ol",st,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.items,(d,h)=>(e.openBlock(),e.createElementBlock("li",{key:`breadcrumb-${h}`,class:e.normalizeClass({home:h===0&&i.showHomeIcon})},[e.createElementVNode("a",{href:d.href||"#",class:"txt","aria-current":n(h)?"page":void 0,onClick:y=>o(d,y)},[h===0&&i.showHomeIcon?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",rt,e.toDisplayString(d.text),1))],8,it)],2))),128))])],8,ot))}}),ye=e.defineComponent({name:"KrdsInPageNavigation",props:{title:{type:String,default:void 0},caption:{type:String,default:"이 페이지의 구성"},items:{type:Array,default:()=>[]},autoActive:{type:Boolean,default:!0},headerTopSelector:{type:String,default:"#krds-masthead"},headerInnerSelector:{type:String,default:"#krds-header .header-in"},class:{type:String,default:void 0}},emits:["itemClick"],slots:Object,setup(t,{emit:r,slots:s}){const a=e.ref(""),n=e.ref(new Map),o=e.computed(()=>{const m=["krds-in-page-navigation-type"];return t.class&&m.push(t.class),m}),i=()=>{const m=t.headerTopSelector,l=t.headerInnerSelector,p=document.querySelector(m)?.clientHeight||0,c=document.querySelector(l)?.clientHeight||0;return p+c},u=(m,l)=>{if(r("itemClick",m,l),m.href.startsWith("#")){l.preventDefault();const p=document.querySelector(m.href);if(p){const c=i();if(window.scrollTo({left:0,top:p.getBoundingClientRect().top+window.scrollY-c,behavior:"smooth"}),a.value=m.href,l instanceof KeyboardEvent){const f=p.querySelector(".sec-tit, h1, h2, h3, h4, h5, h6");f&&f instanceof HTMLElement&&(f.setAttribute("tabindex","-1"),f.focus({preventScroll:!0}))}}}},d=()=>{n.value.clear(),t.items&&t.items.filter(m=>m.href.startsWith("#")).forEach(m=>{const l=document.querySelector(m.href);l&&n.value.set(m.href,l)})},h=()=>{if(!t.autoActive||!t.items||n.value.size===0)return;const m=window.innerHeight,l=Math.ceil(m/5),p=window.scrollY+m,c=document.body.scrollHeight,f=t.items.filter(N=>N.href.startsWith("#")&&n.value.has(N.href)).map(N=>({href:N.href,element:n.value.get(N.href),item:N}));if(f.length===0)return;const E=f[0],K=f[f.length-1],v=E.element.offsetTop;let _="";if(p>=c)_=K.href;else if(window.scrollY<=v)_=E.href;else for(const N of f){const L=N.element.offsetHeight,B=N.element.offsetTop-l;if(window.scrollY>B&&window.scrollY<=B+L){_=N.href;break}}_&&_!==a.value&&(a.value=_)},y=()=>{if(!t.items)return;const m=t.items.find(l=>l.active);m?a.value=m.href:t.items.length>0&&(a.value=t.items[0].href)};e.onMounted(()=>{if(y(),t.autoActive){d(),h(),window.addEventListener("scroll",h,{passive:!0});const m=new MutationObserver(()=>{d()});m.observe(document.body,{childList:!0,subtree:!0}),e.onUnmounted(()=>{m.disconnect()})}}),e.onUnmounted(()=>{t.autoActive&&(window.removeEventListener("scroll",h),n.value.clear())});const C=()=>!t.caption&&!t.title?null:e.h("div",{class:"in-page-navigation-header"},[t.caption&&e.h("p",{class:"quick-caption"},t.caption),t.title&&e.h("p",{class:"quick-title"},t.title)]),g=()=>{if(!t.items)return null;const m=t.items.map(l=>{const p=a.value===l.href||!t.autoActive&&l.active;return e.h("li",{key:l.href},[e.h("a",{href:l.href,class:p?"active":"",onClick:c=>u(l,c),onKeydown:c=>{(c.key==="Enter"||c.key===" ")&&(c.preventDefault(),u(l,c))}},l.text)])});return e.h("nav",{class:"in-page-navigation-list"},[e.h("ul",{},m)])},w=()=>s.action?e.h("div",{class:"in-page-navigation-action"},[s.action()]):null;return()=>e.h("div",{class:o.value},[e.h("div",{class:"krds-in-page-navigation-area"},[C(),g(),w()].filter(Boolean))])}}),ct=["id"],dt={class:"page-links"},ut=["href","aria-current","onClick"],ft={key:0},mt=["aria-label"],ge=e.defineComponent({__name:"KrdsPagination",props:{modelValue:{default:1},min:{default:1},max:{},id:{default:void 0},ariaLabel:{default:"페이지 내비게이션"},pageRange:{default:8}},emits:["update:modelValue"],setup(t,{emit:r}){const s=t,a=r,n=e.computed(()=>Math.max(1,s.min)),o=e.computed(()=>s.modelValue??n.value),i=e.computed(()=>o.value<=n.value),u=e.computed(()=>o.value>=s.max),d=e.computed(()=>{if(!i.value)return"#"}),h=e.computed(()=>{if(!u.value)return"#"}),y=e.computed(()=>{const{pageRange:m,max:l}=s,p=1,c=[];if(l<=m+2*p)for(let f=n.value;f<=l;f++)c.push({type:"page",key:`page-${f}`,page:f,href:"#"});else{const f=Math.min(p,l),E=Math.max(l-p+1,1),K=Math.max(n.value,o.value-Math.floor(m/2)),v=Math.min(l,K+m-1),_=Math.max(n.value,v-m+1);for(let B=n.value;B<=f;B++)c.push({type:"page",key:`page-${B}`,page:B,href:"#"});_>f+1&&c.push({type:"ellipsis",key:"ellipsis-left",ariaLabel:"페이지 생략"});const N=Math.max(_,f+1),L=Math.min(v,E-1);for(let B=N;B<=L;B++)c.push({type:"page",key:`page-${B}`,page:B,href:"#"});v<E-1&&c.push({type:"ellipsis",key:"ellipsis-right",ariaLabel:"페이지 생략"});for(let B=E;B<=l;B++)c.push({type:"page",key:`page-${B}`,page:B,href:"#"})}return c}),C=(m,l)=>{if(m===o.value){l.preventDefault();return}a("update:modelValue",m)},g=m=>{if(i.value){m.preventDefault();return}const l=o.value-1;a("update:modelValue",l)},w=m=>{if(u.value){m.preventDefault();return}const l=o.value+1;a("update:modelValue",l)};return(m,l)=>{const p=e.resolveDirective("sr-only");return e.openBlock(),e.createElementBlock("div",{id:m.id,class:"krds-pagination"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i.value?"span":"a"),{href:i.value?void 0:d.value,class:e.normalizeClass(["page-navi","prev",{disabled:i.value}]),onClick:g},{default:e.withCtx(()=>[...l[0]||(l[0]=[e.createTextVNode(" 이전 ",-1)])]),_:1},8,["href","class"])),e.createElementVNode("div",dt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,c=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:c.key},[c.type==="page"?(e.openBlock(),e.createElementBlock("a",{key:0,href:c.href||"#",class:e.normalizeClass(["page-link",{active:c.page===o.value}]),"aria-current":c.page===o.value?"page":void 0,onClick:f=>C(c.page,f)},[c.page===o.value?e.withDirectives((e.openBlock(),e.createElementBlock("span",ft,[...l[1]||(l[1]=[e.createTextVNode("현재페이지",-1)])])),[[p]]):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(c.page),1)],10,ut)):c.type==="ellipsis"?(e.openBlock(),e.createElementBlock("span",{key:1,class:"page-link link-dot","aria-label":c.ariaLabel},null,8,mt)):e.createCommentVNode("",!0)],64))),128))]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(u.value?"span":"a"),{href:u.value?void 0:h.value,class:e.normalizeClass(["page-navi","next",{disabled:u.value}]),onClick:w},{default:e.withCtx(()=>[...l[2]||(l[2]=[e.createTextVNode(" 다음 ",-1)])]),_:1},8,["href","class"]))],8,ct)}}}),pt={class:"inner help-panel-flexible"},ht={class:"help-panel-wrap"},yt={class:"help-conts-area"},ke=e.defineComponent({__name:"KrdsPanel",props:{modelValue:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(t,{emit:r}){const s=t,a=r,n=e.computed({get:()=>s.modelValue,set:u=>a("update:modelValue",u)}),o=()=>{n.value=!0},i=()=>{n.value=!1};return(u,d)=>(e.openBlock(),e.createElementBlock("div",pt,[e.createElementVNode("button",{type:"button",class:"krds-btn small tertiary btn-help-panel expand btn-help-exec",onClick:o},[...d[0]||(d[0]=[e.createElementVNode("i",{class:"svg-icon ico-fold"},null,-1),e.createTextVNode(" 도움말 ",-1)])]),e.createElementVNode("div",{class:e.normalizeClass(["krds-help-panel",{expand:n.value}])},[e.createElementVNode("div",ht,[e.createElementVNode("div",yt,[e.renderSlot(u.$slots,"default"),e.createElementVNode("button",{type:"button",class:"krds-btn small tertiary btn-help-panel fold",onClick:i},[...d[1]||(d[1]=[e.createElementVNode("span",{class:"sr-only"},"도움말",-1),e.createTextVNode(" 접어두기 ",-1),e.createElementVNode("i",{class:"svg-icon ico-angle right"},null,-1)])])])])],2)]))}}),gt={class:"tooltip-action"},kt={key:0,class:"svg-icon ico-help"},bt={key:1,class:"svg-icon ico-tooltip"},St={class:"tooltip-title"},Ct={class:"tooltip-contents"},be=e.defineComponent({__name:"KrdsContextualHelp",props:{tooltipTitle:{default:"도움말 제목"},helpIcon:{type:Boolean},position:{default:"top left"}},setup(t){const r=t,s=e.ref(),a=e.ref(),n=e.ref(),o=e.ref(),i=e.ref(!1),u=()=>{const l=i.value;y(),l||d()},d=()=>{if(!n.value||!a.value)return;i.value=!0,n.value.style.display="block",a.value.setAttribute("aria-expanded","true"),n.value.querySelector('a, button, [tabindex="0"], input, textarea, select')?.focus(),C()},h=()=>{!n.value||!a.value||(i.value=!1,n.value.style.display="none",a.value.setAttribute("aria-expanded","false"))},y=()=>{const l=document.querySelectorAll(".krds-contextual-help .tooltip-popover"),p=document.querySelectorAll(".krds-contextual-help .tooltip-btn");l.forEach(c=>{c.style.display="none"}),p.forEach(c=>{c.setAttribute("aria-expanded","false")}),i.value=!1},C=()=>{if(!s.value||!n.value)return;const l=window.innerWidth<=768,p=s.value.querySelector(".tooltip-action");if(l){const f=getComputedStyle(document.querySelector(":root")).getPropertyValue("--krds-contents-padding-x").trim().split("px")[0],K=p.getBoundingClientRect().left-parseInt(f),v=document.body.clientWidth-parseInt(f)*2;n.value.style.left=`-${K}px`,n.value.style.width=`${v}px`}else n.value.style.left="",n.value.style.right="",n.value.style.width="360px"},g=l=>{(l.key==="Escape"||l.key==="Esc")&&y()},w=l=>{l.target.closest(".tooltip-action")||y()},m=()=>{i.value&&C()};return e.onMounted(()=>{s.value&&(a.value&&a.value.setAttribute("aria-expanded","false"),n.value&&n.value.setAttribute("role","tooltip"),document.addEventListener("keydown",g),document.addEventListener("click",w),window.addEventListener("resize",m))}),e.onUnmounted(()=>{document.removeEventListener("keydown",g),document.removeEventListener("click",w),window.removeEventListener("resize",m)}),(l,p)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:s,class:e.normalizeClass(["krds-contextual-help",r.position])},[e.createElementVNode("div",gt,[e.createElementVNode("button",{ref_key:"tooltipBtnRef",ref:a,type:"button",class:"krds-btn medium icon tooltip-btn",onClick:u},[p[0]||(p[0]=e.createElementVNode("span",{class:"sr-only"},"도움말",-1)),r.helpIcon?(e.openBlock(),e.createElementBlock("i",kt)):(e.openBlock(),e.createElementBlock("i",bt))],512),e.createElementVNode("div",{ref_key:"tooltipPopoverRef",ref:n,class:"tooltip-popover",role:"tooltip"},[e.createElementVNode("h4",St,e.toDisplayString(r.tooltipTitle),1),e.createElementVNode("div",Ct,[e.renderSlot(l.$slots,"default")]),e.createElementVNode("button",{ref_key:"closeBtnRef",ref:o,type:"button",class:"krds-btn xsmall icon tooltip-close",onClick:h},[...p[1]||(p[1]=[e.createElementVNode("span",{class:"sr-only"},"닫기",-1),e.createElementVNode("i",{class:"svg-icon ico-modal-close"},null,-1)])],512)],512)])],2))}}),Et={key:0,class:"coach-balloon"},Vt={class:"coach-tit"},wt={class:"desc"},Bt={class:"coach-controls"},Nt={class:"num"},vt={class:"btn-wrap"},Se=e.defineComponent({__name:"KrdsCoachMark",props:{coachMarkClass:{default:""},stepsData:{},activeStep:{},modelValue:{default:null},class:{},style:{},id:{}},emits:["update:modelValue","close"],setup(t,{emit:r}){const s=t,a=e.computed(()=>{const d=s.activeStep-1;return s.stepsData&&d>=0&&d<s.stepsData.length?s.stepsData[d]:null}),n=r,o=()=>{s.activeStep>1&&n("update:modelValue",s.activeStep-1)},i=()=>{s.activeStep<s.stepsData.length&&n("update:modelValue",s.activeStep+1)},u=()=>{n("close")};return(d,h)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["krds-coach-mark",d.coachMarkClass]),style:e.normalizeStyle(d.style)},[d.modelValue===d.activeStep&&a.value?(e.openBlock(),e.createElementBlock("div",Et,[h[2]||(h[2]=e.createElementVNode("h5",{class:"sr-only"},"따라하기 가이드",-1)),e.createElementVNode("h6",Vt,e.toDisplayString(d.activeStep)+"단계 : "+e.toDisplayString(a.value.title),1),e.createElementVNode("p",wt,e.toDisplayString(a.value.description),1),e.createElementVNode("div",Bt,[e.createElementVNode("div",Nt,[h[0]||(h[0]=e.createElementVNode("span",{class:"sr-only"},"현재 단계",-1)),e.createElementVNode("strong",null,e.toDisplayString(d.activeStep),1),h[1]||(h[1]=e.createElementVNode("span",{class:"sr-only"},"총 단계",-1)),e.createElementVNode("span",null,e.toDisplayString(d.stepsData.length),1)]),e.createElementVNode("div",vt,[e.createElementVNode("button",{type:"button",class:"krds-btn small text",onClick:u},"그만보기"),d.activeStep!==1?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"krds-btn small text",onClick:o},"이전으로")):e.createCommentVNode("",!0),d.activeStep!==d.stepsData.length?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"krds-btn small tertiary",onClick:i},"다음으로")):e.createCommentVNode("",!0)])])])):e.createCommentVNode("",!0),e.renderSlot(d.$slots,"coach-mark-content")],6))}}),_t=["disabled","aria-labelledby"],Kt=["id","aria-hidden"],Dt={class:"sr-only"},Ce=e.defineComponent({__name:"KrdsTooltip",props:{type:{default:"default"},tooltipContent:{},vertical:{type:Boolean},box:{type:Boolean},disabled:{type:Boolean,default:!1},class:{},style:{},id:{}},setup(t){const r=t,s=e.ref(null),a=e.ref(null),n=e.ref(!1),o=e.ref({}),i=e.ref(`tooltip-popover-${Math.random().toString(36).substring(2,9)}`),u=e.ref(!1),d=e.computed(()=>{const f=["krds-btn","krds-tooltip"];return r.type==="default"?f.push("small","text"):r.type==="icon"?f.push("icon"):r.type==="button"&&f.push(""),!r.box&&r.vertical&&f.push("tooltip-vertical"),r.box&&!r.vertical&&f.push("tooltip-box"),f.join(" ")}),h=e.computed(()=>{const f=[];return r.box&&f.push("tooltip-box"),r.vertical&&f.push("tooltip-vertical"),n.value&&f.push("active"),f}),y=e.computed(()=>s.value?.querySelector("button")?.textContent?.trim()||""),C=()=>window.innerWidth<=768,g=()=>{if(!s.value||!a.value)return;const f=s.value.querySelector("button");if(!f)return;const E=12,{clientHeight:K,clientWidth:v}=a.value,{top:_,left:N,right:L,height:B,width:x}=f.getBoundingClientRect(),P=window.innerWidth/2,j=window.innerHeight/2;let M,z;const $=[];u.value||r.box||r.vertical?(_+B>j?(M=_-K-E,$.push("top")):(M=_+B+E,$.push("bottom")),N+x>P?(z=L-v,$.push("right"),window.innerWidth-(N+x)>v/2&&(z=N+(x-v)/2,$.splice($.indexOf("right"),1))):(z=N+(x-v)/2,z<0&&(z=N,$.push("left")))):(M=_+(B-K)/2,N+x>P?(z=N-v-E,$.push("right")):z=L+E);const A=window.innerWidth<=420;o.value={top:`${M}px`,left:A?"50%":`${z}px`,transform:A?"translateX(-50%)":"none"},a.value&&(a.value.className=`krds-tooltip-popover ${$.join(" ")} ${h.value.join(" ")}`)},w=async()=>{r.disabled||!r.tooltipContent||(n.value=!0,await e.nextTick(),g())},m=()=>{n.value=!1,o.value={}},l=f=>{(f.key==="Escape"||f.key==="Esc")&&n.value&&m()},p=()=>{u.value=C(),n.value&&m()},c=()=>{n.value&&m()};return e.onMounted(()=>{u.value=C(),document.addEventListener("keydown",l),window.addEventListener("scroll",c),window.addEventListener("resize",p)}),e.onUnmounted(()=>{document.removeEventListener("keydown",l),window.removeEventListener("scroll",c),window.removeEventListener("resize",p)}),(f,E)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:s},[e.createElementVNode("button",{type:"button",class:e.normalizeClass(d.value),disabled:f.disabled,"aria-labelledby":i.value,onMouseover:w,onMouseout:m,onFocusin:w,onFocusout:m},[e.renderSlot(f.$slots,"default")],42,_t),e.withDirectives(e.createElementVNode("div",{id:i.value,ref_key:"popoverRef",ref:a,class:e.normalizeClass(["krds-tooltip-popover",h.value]),style:e.normalizeStyle(o.value),"aria-hidden":!n.value,role:"tooltip"},[e.createElementVNode("span",Dt,e.toDisplayString(y.value),1),e.createTextVNode(" "+e.toDisplayString(f.tooltipContent),1)],14,Kt),[[e.vShow,n.value]])],512))}}),zt=["aria-expanded"],$t={class:"drop-in"},Lt={key:0,class:"drop-top"},xt={key:1,class:"drop-list"},It=["lang","aria-selected","onClick"],Tt={class:"sr-only"},Mt={key:2,class:"drop-list"},Rt=["href","lang"],Ee=e.defineComponent({__name:"KrdsLanguageSwitcher",props:{languageList:{},modelValue:{default:""},type:{default:"default"},dropPosition:{default:"center"},class:{},style:{},id:{}},emits:["update:modelValue","close"],setup(t,{emit:r}){const s=t,a=r,n=e.ref(!1),o=e.ref(),i=e.ref(),u=()=>{n.value=!n.value,n.value&&o.value&&y()},d=()=>{n.value=!1},h=l=>{a("update:modelValue",l),d(),a("close"),i.value?.focus()},y=()=>{if(!o.value)return;const l=o.value.querySelector(".drop-menu");if(!l)return;const p=l.getBoundingClientRect(),c=window.innerWidth;o.value.classList.remove("drop-left","drop-right"),p.left<0?o.value.classList.add("drop-left"):c<p.left+p.width&&o.value.classList.add("drop-right")},C=l=>{l.key==="Escape"&&(d(),i.value?.focus())},g=l=>{o.value?.contains(l.target)||d()},w=l=>{o.value?.contains(l.relatedTarget)||d()},m=l=>{if(!o.value)return;o.value.querySelectorAll(".drop-list .item-link").forEach(f=>{f.style.position="relative",f.style.zIndex="0"});const c=l.target;c.style.zIndex="1"};return e.watch(n,l=>{l?(document.addEventListener("keydown",C),document.addEventListener("click",g)):(document.removeEventListener("keydown",C),document.removeEventListener("click",g))}),e.onUnmounted(()=>{document.removeEventListener("keydown",C),document.removeEventListener("click",g)}),(l,p)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"dropdownRef",ref:o,class:e.normalizeClass(["krds-drop-wrap krds-language",{active:n.value,"drop-left":s.dropPosition==="left","drop-right":s.dropPosition==="right"}]),onFocusout:w},[e.createElementVNode("button",{ref_key:"buttonRef",ref:i,type:"button",class:e.normalizeClass(["krds-btn small text drop-btn",{active:n.value}]),"aria-expanded":n.value,onClick:u},[p[0]||(p[0]=e.createElementVNode("i",{class:"svg-icon ico-global"},null,-1)),e.renderSlot(l.$slots,"default"),p[1]||(p[1]=e.createElementVNode("i",{class:"svg-icon ico-toggle"},null,-1))],10,zt),e.createElementVNode("div",{class:"drop-menu",style:e.normalizeStyle({display:n.value?"block":"none"})},[e.createElementVNode("div",$t,[l.$slots["prev-item"]?(e.openBlock(),e.createElementBlock("div",Lt,[e.renderSlot(l.$slots,"prev-item")])):e.createCommentVNode("",!0),s.type==="default"?(e.openBlock(),e.createElementBlock("ul",xt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.languageList,c=>(e.openBlock(),e.createElementBlock("li",{key:c.code},[e.createElementVNode("a",{href:"#",class:e.normalizeClass(["item-link",{active:s.modelValue===c.code}]),lang:c.code,"aria-selected":s.modelValue===c.code,onClick:e.withModifiers(f=>h(c.code),["prevent"]),onFocus:m},[e.createTextVNode(e.toDisplayString(c.name)+" ",1),e.createElementVNode("span",Tt,e.toDisplayString(s.modelValue===c.code?"선택됨":""),1)],42,It)]))),128))])):s.type==="external"?(e.openBlock(),e.createElementBlock("ul",Mt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.languageList,c=>(e.openBlock(),e.createElementBlock("li",{key:c.code},[e.createElementVNode("a",{href:c.url||"#",class:"item-link",lang:c.code,target:"_blank",title:"새 창 열림",onFocus:m},[e.createTextVNode(e.toDisplayString(c.name)+" ",1),p[2]||(p[2]=e.createElementVNode("i",{class:"svg-icon ico-go"},null,-1))],40,Rt)]))),128))])):e.createCommentVNode("",!0)])],4)],34))}}),Ft={class:"drop-in"},Pt={class:"drop-list"},At=["data-adjust-scale","onClick"],Ot={class:"drop-bottom"},Ve=e.defineComponent({__name:"KrdsResize",emits:["update:modelValue","close"],setup(t,{emit:r}){const s=r,a=e.ref(!1),n=e.ref(),o=e.ref(),i=e.ref("md"),u=[{key:"sm",label:"작게",zoom:"0.9"},{key:"md",label:"보통",zoom:"1"},{key:"lg",label:"조금 크게",zoom:"1.1"},{key:"xlg",label:"크게",zoom:"1.3"},{key:"xxlg",label:"가장 크게",zoom:"1.5"}],d=()=>{a.value=!a.value,a.value&&n.value&&g()},h=()=>{a.value=!1},y=c=>{h(),s("close"),o.value?.focus(),i.value=c.key,document.body.style.zoom=c?.zoom},C=()=>{const c=u.find(f=>f.key==="md");c&&y(c)},g=()=>{if(!n.value)return;const c=n.value.querySelector(".drop-menu");if(!c)return;const f=c.getBoundingClientRect(),E=window.innerWidth;n.value.classList.remove("drop-left","drop-right"),f.left<0?n.value.classList.add("drop-left"):E<f.left+f.width&&n.value.classList.add("drop-right")},w=c=>{c.key==="Escape"&&(h(),o.value?.focus())},m=c=>{n.value?.contains(c.target)||h()},l=c=>{n.value?.contains(c.relatedTarget)||h()},p=c=>{if(!n.value)return;n.value.querySelectorAll(".drop-list .item-link").forEach(K=>{K.style.position="relative",K.style.zIndex="0"});const E=c.target;E.style.zIndex="1"};return e.watch(a,c=>{c?(document.addEventListener("keydown",w),document.addEventListener("click",m)):(document.removeEventListener("keydown",w),document.removeEventListener("click",m))}),e.onUnmounted(()=>{document.removeEventListener("keydown",w),document.removeEventListener("click",m)}),(c,f)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"dropdownRef",ref:n,class:"krds-drop-wrap krds-resize","data-adjust":"scale",onFocusout:l},[e.createElementVNode("button",{ref_key:"buttonRef",ref:o,type:"button",class:"krds-btn small text drop-btn",onClick:d},[...f[0]||(f[0]=[e.createTextVNode(" 화면크기 ",-1),e.createElementVNode("i",{class:"svg-icon ico-toggle"},null,-1)])],512),e.createElementVNode("div",{class:"drop-menu",style:e.normalizeStyle({display:a.value?"block":"none"})},[e.createElementVNode("div",Ft,[e.createElementVNode("ul",Pt,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(u,E=>e.createElementVNode("li",{key:E.key},[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["item-link",[E.key,E.key===i.value?"active":""]]),"data-adjust-scale":E.key,onClick:e.withModifiers(K=>y(E),["prevent"]),onFocus:p},e.toDisplayString(E.label),43,At)])),64))]),e.createElementVNode("div",Ot,[e.createElementVNode("button",{type:"button",class:"krds-btn medium text","data-adjust-scale":"md",onClick:e.withModifiers(C,["prevent"]),onFocus:p},[...f[1]||(f[1]=[e.createElementVNode("i",{class:"svg-icon ico-reset"},null,-1),e.createTextVNode(" 초기화 ",-1)])],32)])])],4)],544))}}),we=Object.freeze(Object.defineProperty({__proto__:null,KrdsBadge:ae,KrdsBreadcrumb:he,KrdsButton:O,KrdsButtonGroup:Y,KrdsCheckArea:ce,KrdsCheckbox:de,KrdsCoachMark:Se,KrdsContextualHelp:be,KrdsDateInput:ee,KrdsFileUpload:le,KrdsFormGroup:Z,KrdsFormHint:Q,KrdsFormLabel:J,KrdsIcon:G,KrdsInPageNavigation:ye,KrdsInput:X,KrdsLanguageSwitcher:Ee,KrdsLink:U,KrdsMasthead:ie,KrdsPagination:ge,KrdsPanel:ke,KrdsRadio:ue,KrdsResize:Ve,KrdsSelect:ne,KrdsSkipLink:pe,KrdsSpinner:q,KrdsStep:me,KrdsStepIndicator:fe,KrdsTag:oe,KrdsTagGroup:se,KrdsTextarea:te,KrdsToggleSwitch:re,KrdsTooltip:Ce},Symbol.toStringTag,{value:"Module"})),H={mounted(t,r){r.value!==!1&&t.classList.add("sr-only")},updated(t,r){r.value===!1?t.classList.remove("sr-only"):t.classList.add("sr-only")},unmounted(t){t.classList.remove("sr-only")}},Be={"sr-only":H},Ne=t=>{t.directive("sr-only",H)},ve=Object.freeze(Object.defineProperty({__proto__:null,default:Be,directives:Be,installDirectives:Ne,vSrOnly:H},Symbol.toStringTag,{value:"Module"})),qt={install(t,r={}){t.provide("krds:config",r);const s=r.components||Object.keys(we);s.forEach(a=>{const n=we[a];n&&t.component(a,n)}),typeof ve=="object"&&ve!==null&&Ne(t),t.config.globalProperties.$krds={version:"__VERSION__"},process.env.NODE_ENV!=="production"&&console.log(`[KRDS Vue] v__VERSION__ 설치 완료 - 컴포넌트: ${s.length}개`)}},Ht="__VERSION__";b.KrdsBadge=ae,b.KrdsBreadcrumb=he,b.KrdsButton=O,b.KrdsButtonGroup=Y,b.KrdsCheckArea=ce,b.KrdsCheckbox=de,b.KrdsCoachMark=Se,b.KrdsContextualHelp=be,b.KrdsDateInput=ee,b.KrdsFileUpload=le,b.KrdsFormGroup=Z,b.KrdsFormHint=Q,b.KrdsFormLabel=J,b.KrdsIcon=G,b.KrdsInPageNavigation=ye,b.KrdsInput=X,b.KrdsLanguageSwitcher=Ee,b.KrdsLink=U,b.KrdsMasthead=ie,b.KrdsPagination=ge,b.KrdsPanel=ke,b.KrdsRadio=ue,b.KrdsResize=Ve,b.KrdsSelect=ne,b.KrdsSkipLink=pe,b.KrdsSpinner=q,b.KrdsStep=me,b.KrdsStepIndicator=fe,b.KrdsTag=oe,b.KrdsTagGroup=se,b.KrdsTextarea=te,b.KrdsToggleSwitch=re,b.KrdsTooltip=Ce,b.classNames=F,b.default=qt,b.generateId=R,b.generateUid=at,b.version=Ht,Object.defineProperties(b,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
1
+ (function(k,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(k=typeof globalThis<"u"?globalThis:k||self,e(k.KrdsVue={},k.Vue))})(this,(function(k,e){"use strict";const O=e.defineComponent({name:"KrdsButton",props:{type:{type:String,default:"button"},size:{type:String,default:void 0},variant:{type:String,default:"primary"},icon:{type:Boolean,default:!1},border:{type:Boolean,default:!1},pure:{type:Boolean,default:!1},text:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:i,slots:s}){const o=e.computed(()=>{const a=["krds-btn"];return t.icon&&a.push("icon"),t.border&&a.push("border"),t.pure&&a.push("pure"),t.text&&a.push("text"),t.variant&&!t.icon&&a.push(t.variant),t.size&&a.push(t.size),t.class&&a.push(t.class),a}),n=a=>{t.disabled||i("click",a)};return()=>e.h("button",{type:t.type,class:o.value,disabled:t.disabled,onClick:n},s.default?.())}}),Y=e.defineComponent({name:"KrdsButtonGroup",props:{},setup(t,{slots:i}){return()=>e.h("div",{class:"btn-group"},i.default?.())}}),G=e.defineComponent({name:"KrdsIcon",props:{name:{type:String,required:!0},class:{type:String,default:void 0}},setup(t){return()=>e.h("i",{class:["svg-icon",t.name,t.class].filter(Boolean).join(" ")})}}),U=e.defineComponent({name:"KrdsLink",props:{href:{type:String,default:"#!"},target:{type:String,default:void 0},title:{type:String,default:void 0},size:{type:String,default:void 0},link:{type:Boolean,default:!0},basic:{type:Boolean,default:!1},pure:{type:Boolean,default:!1},class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:i,slots:s}){const o=e.computed(()=>{const r=["krds-btn"];return t.size&&r.push(t.size),t.link&&r.push("link"),t.basic&&r.push("basic"),t.pure&&r.push("pure"),t.class&&r.push(t.class),r}),n=e.computed(()=>{const r={href:t.href,class:o.value};return t.target&&(r.target=t.target),t.title&&(r.title=t.title),t.target==="_blank"&&(r.rel="noopener noreferrer"),r}),a=r=>{i("click",r)};return()=>e.h("a",{...n.value,onClick:a},s.default?.())}}),q=e.defineComponent({name:"KrdsSpinner",props:{label:{type:String,default:void 0}},render(){const t=[e.h("span",{class:"sr-only"},"로딩 중")];return this.label&&t.push(e.h("span",this.label)),e.h("div",{class:"krds-spinner",role:"status"},t)}}),X=e.defineComponent({name:"KrdsInput",props:{modelValue:{type:[String,Number],default:void 0},type:{type:String,default:"text"},size:{type:String,default:void 0},placeholder:{type:String,default:void 0},maxlength:{type:Number,default:void 0},minlength:{type:Number,default:void 0},max:{type:Number,default:void 0},min:{type:Number,default:void 0},step:{type:Number,default:void 0},autocomplete:{type:String,default:void 0},autofocus:{type:Boolean,default:!1},name:{type:String,default:void 0},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},error:{type:String,default:void 0},state:{type:String,default:"default"},icon:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","input","change","focus","blur","keydown","keyup"],setup(t,{emit:i,slots:s}){const o=e.computed(()=>{const g=["krds-input"];return t.size&&g.push(t.size),t.class&&g.push(t.class),g}),n=g=>{const w=g.target,m=t.type==="number"?Number(w.value):w.value;i("update:modelValue",m),i("input",g)},a=g=>{i("change",g)},r=g=>{i("focus",g)},d=g=>{i("blur",g)},u=g=>{i("keydown",g)},h=g=>{i("keyup",g)},y=e.computed(()=>{const g={type:t.type,class:o.value,value:t.modelValue,placeholder:t.placeholder,name:t.name,id:t.id,required:t.required,readonly:t.readonly,disabled:t.disabled,autocomplete:t.autocomplete,autofocus:t.autofocus,onInput:n,onChange:a,onFocus:r,onBlur:d,onKeydown:u,onKeyup:h};return t.maxlength!==void 0&&(g.maxlength=t.maxlength),t.minlength!==void 0&&(g.minlength=t.minlength),t.type==="number"&&(t.max!==void 0&&(g.max=t.max),t.min!==void 0&&(g.min=t.min),t.step!==void 0&&(g.step=t.step)),g}),C=e.computed(()=>{const g=["form-conts"];return t.state!=="default"&&g.push(`is-${t.state}`),t.icon&&g.push("btn-ico-wrap"),g});return()=>{const g=[e.h("input",y.value)];return t.loading?e.h("div",{class:C.value},[e.h("div",{class:"form-spinner"},[...g,e.h(q)])]):(s.default&&g.push(...s.default()),e.h("div",{class:C.value},g))}}}),J=e.defineComponent({name:"KrdsFormLabel",props:{for:{type:String,default:void 0},class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},emits:["click"],setup(t,{emit:i,slots:s}){const o=n=>{i("click",n)};return()=>e.h("div",{class:"form-tit"},[e.h("label",{for:t.for,id:t.id,class:t.class,style:t.style,onClick:o},s.default?.())])}}),Q=e.defineComponent({name:"KrdsFormHint",props:{type:{type:String,default:"hint"},class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},emits:["click"],setup(t,{emit:i,slots:s}){const o=a=>{i("click",a)},n=()=>{let a;switch(t.type){case"error":a="form-hint-invalid";break;case"success":a="form-hint-success";break;case"information":a="form-hint-information";break;default:a="form-hint";break}return t.class?`${a} ${t.class}`:a};return()=>e.h("p",{id:t.id,class:n(),style:t.style,onClick:o},s.default?.())}}),Z=e.defineComponent({name:"KrdsFormGroup",props:{class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},setup(t,{slots:i}){const s=e.computed(()=>{const o=["form-group"];return t.class&&o.push(t.class),o});return()=>e.h("div",{id:t.id,class:s.value,style:t.style},i.default?.())}});function ze(t,i){const s=new Date,o=e.ref(t||s.getFullYear()),n=e.ref(i||s.getMonth()+1),a=e.ref(null),r=e.ref(null),d=e.ref(null),u=e.computed(()=>{const p=s.getFullYear(),c=[];for(let f=p-10;f<=p+10;f++)c.push(f);return c}),h=e.computed(()=>Array.from({length:12},(p,c)=>c+1)),y=()=>{a.value=null,r.value=null},C=()=>{n.value===1?(n.value=12,o.value-=1):n.value-=1},g=()=>{n.value===12?(n.value=1,o.value+=1):n.value+=1},w=(p,c=!1)=>{if(c)a.value=p,r.value=p;else if(!a.value||a.value&&r.value)a.value=p,r.value=null;else{const f=new Date(a.value.replace(/\./g,"-"));new Date(p.replace(/\./g,"-"))<f?(a.value=p,r.value=null):r.value=p}};return{currentYear:o,currentMonth:n,selectedStartDate:a,selectedEndDate:r,activeDateSelector:d,yearOptions:u,monthOptions:h,clearDateSelection:y,prevMonth:C,nextMonth:g,handleDateSelection:w,selectToday:()=>{const p=`${s.getFullYear()}.${String(s.getMonth()+1).padStart(2,"0")}.${String(s.getDate()).padStart(2,"0")}`;w(p,!0)},isDateInSelectedRange:p=>{if(!a.value||!r.value)return{isInRange:!1,isStart:!1,isEnd:!1};const c=new Date(p.replace(/\./g,"-")),f=new Date(a.value.replace(/\./g,"-")),E=new Date(r.value.replace(/\./g,"-")),D=p===a.value,v=p===r.value;return{isInRange:c>=f&&c<=E,isStart:D,isEnd:v}}}}function $e(t,i,s={}){let o=null;const n=typeof s=="string"?{ignore:s}:s,{ignore:a,event:r="click"}=n,d=()=>{o=h=>{const y=h.target;t.value?.contains(y)||a&&y.closest(a)||i()},document.addEventListener(r,o)},u=()=>{if(o){const h=typeof s=="string"?"click":s.event||"click";document.removeEventListener(h,o),o=null}};return e.onMounted(()=>{d()}),e.onBeforeUnmount(()=>{u()}),{setupGlobalListeners:d,removeGlobalListeners:u}}const Le={class:"form-conts"},Ie={class:"calendar-input"},Te=["id","name","placeholder","value","readonly","disabled","required","autofocus"],Me=["disabled","aria-expanded"],Re={class:"calendar-head"},Fe={class:"calendar-switch-wrap"},Pe={class:"calendar-drop-down"},Ae=["aria-expanded"],Oe={class:"calendar-select calendar-year-wrap"},qe={class:"sel year"},He=["onClick"],je={class:"calendar-drop-down"},We=["aria-expanded"],Ye={class:"calendar-select calendar-mon-wrap"},Ge={class:"sel month"},Ue=["onClick"],Xe={class:"calendar-body"},Je={class:"calendar-table-wrap"},Qe={class:"calendar-tbl"},Ze=["data-date"],et=["aria-pressed","onClick"],tt={class:"calendar-footer"},nt={class:"calendar-btn-wrap"},ee=e.defineComponent({__name:"KrdsDateInput",props:{modelValue:{default:void 0},size:{default:"medium"},placeholder:{default:"YYYY.MM.DD"},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},autofocus:{type:Boolean,default:!1},eventDates:{default:()=>[]},holidays:{default:()=>[]},initialYear:{default:void 0},initialMonth:{default:void 0},name:{default:void 0},required:{type:Boolean,default:!1},class:{default:void 0},style:{},id:{default:void 0}},emits:["update:modelValue","input","change","focus","blur"],setup(t,{emit:i}){const s=t,o=i,n=e.ref(),a=e.ref(),r=e.ref(!1),d=e.ref(null),{currentYear:u,currentMonth:h,selectedStartDate:y,selectedEndDate:C,yearOptions:g,monthOptions:w,prevMonth:m,nextMonth:l,handleDateSelection:p,selectToday:c,isDateInSelectedRange:f}=ze(s.initialYear,s.initialMonth),E=()=>{r.value&&a.value?.focus(),r.value=!1,d.value=null};$e(n,E,".calendar-conts");const D=e.computed(()=>{const b=["krds-input","datepicker","cal"];return s.size&&b.push(s.size),s.class&&b.push(s.class),b}),v=e.computed(()=>["form-conts","calendar-conts"]),K=e.computed(()=>({"krds-calendar-area":!0,active:r.value})),N=e.computed(()=>{const b=u.value,S=h.value,V=new Date(b,S-1,1),T=new Date(V);T.setDate(T.getDate()-V.getDay());const I=[],x=new Date(T);for(let W=0;W<6;W++){const De=[];for(let xe=0;xe<7;xe++){const Gt=`${x.getFullYear()}.${String(x.getMonth()+1).padStart(2,"0")}.${String(x.getDate()).padStart(2,"0")}`,_e=x.getDay();De.push({day:x.getDate(),dateString:Gt,isCurrentMonth:x.getMonth()===S-1,isToday:x.toDateString()===new Date().toDateString(),isPrevMonth:x.getMonth()<S-1||x.getMonth()===11&&S===1,isNextMonth:x.getMonth()>S-1||x.getMonth()===0&&S===12,isSunday:_e===0,isSaturday:_e===6}),x.setDate(x.getDate()+1)}I.push(De)}return I}),$=b=>{const S=[];if(b.isPrevMonth&&S.push("old"),b.isNextMonth&&S.push("new"),b.isToday&&S.push("today"),b.isSunday&&S.push("day-off"),s.holidays?.includes(b.dateString)&&S.push("day-off"),s.eventDates?.includes(b.dateString)&&S.push("day-event"),b.isCurrentMonth){const V=f(b.dateString);V.isInRange&&(S.push("period"),V.isStart&&S.push("start"),V.isEnd&&S.push("end"))}return S},B=e.computed(()=>[{id:"get-today",label:"오늘",class:"text",variant:void 0,size:"small",handler:c},{id:"cancel-btn",label:"취소",class:void 0,variant:"tertiary",size:"small",handler:E},{id:"confirm-btn",label:"확인",class:void 0,variant:"primary",size:"small",handler:M}]),L=b=>{d.value===b?d.value=null:d.value=b},P=b=>{u.value=b,d.value=null},j=b=>{h.value=b,d.value=null},M=()=>{if(y.value){if(C.value&&y.value!==C.value){const b=`${y.value} ~ ${C.value}`;o("update:modelValue",b)}else o("update:modelValue",y.value);E()}},_=()=>{r.value=!0,d.value=null,setTimeout(()=>{n.value?.querySelector(".calendar-wrap")?.focus()},50)},z=()=>{r.value?E():_()},Ke=b=>{b.code==="Escape"&&(d.value?d.value=null:r.value&&E())},A=b=>{const S=b.target;o("update:modelValue",S.value),o("input",b)},jt=b=>{o("change",b)},Wt=b=>{o("focus",b)},Yt=b=>{o("blur",b)};return(b,S)=>(e.openBlock(),e.createElementBlock("div",Le,[e.createElementVNode("div",{class:e.normalizeClass(v.value)},[e.createElementVNode("div",Ie,[e.createElementVNode("input",{id:t.id,name:t.name,class:e.normalizeClass(D.value),placeholder:t.placeholder,value:t.modelValue,readonly:t.readonly,disabled:t.disabled,required:t.required,autofocus:t.autofocus,type:"text",onInput:A,onChange:jt,onFocus:Wt,onBlur:Yt},null,42,Te),e.createElementVNode("button",{ref_key:"datePickerButtonRef",ref:a,class:e.normalizeClass(`krds-btn ${t.size||"medium"} icon form-btn-datepicker`),disabled:t.disabled,"aria-expanded":r.value,type:"button",onClick:z},[...S[4]||(S[4]=[e.createElementVNode("span",{class:"sr-only"},"달력 열기",-1),e.createElementVNode("i",{class:"svg-icon ico-calendar"},null,-1)])],10,Me)]),e.createElementVNode("div",{ref_key:"datePickerAreaRef",ref:n,class:e.normalizeClass(K.value)},[e.withDirectives(e.createElementVNode("div",{class:"calendar-wrap bottom","aria-label":"달력",tabindex:"0",onKeydown:Ke},[e.createElementVNode("div",Re,[e.createElementVNode("button",{type:"button",class:"btn-cal-move prev",onClick:S[0]||(S[0]=(...V)=>e.unref(m)&&e.unref(m)(...V))},[...S[5]||(S[5]=[e.createElementVNode("span",{class:"sr-only"},"이전 달",-1)])]),e.createElementVNode("div",Fe,[e.createElementVNode("div",Pe,[e.createElementVNode("button",{type:"button",class:"btn-cal-switch year","aria-label":"연도 선택","aria-expanded":d.value==="year",onClick:S[1]||(S[1]=V=>L("year"))},e.toDisplayString(e.unref(u))+"년 ",9,Ae),e.withDirectives(e.createElementVNode("div",Oe,[e.createElementVNode("ul",qe,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(g),V=>(e.openBlock(),e.createElementBlock("li",{key:V},[e.createElementVNode("button",{type:"button",class:e.normalizeClass({active:V===e.unref(u)}),onClick:T=>P(V)},e.toDisplayString(V)+"년",11,He)]))),128))])],512),[[e.vShow,d.value==="year"]])]),e.createElementVNode("div",je,[e.createElementVNode("button",{type:"button",class:"btn-cal-switch month","aria-label":"월 선택","aria-expanded":d.value==="month",onClick:S[2]||(S[2]=V=>L("month"))},e.toDisplayString(e.unref(h).toString().padStart(2,"0"))+"월 ",9,We),e.withDirectives(e.createElementVNode("div",Ye,[e.createElementVNode("ul",Ge,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(w),V=>(e.openBlock(),e.createElementBlock("li",{key:V},[e.createElementVNode("button",{type:"button",class:e.normalizeClass({active:V===e.unref(h)}),onClick:T=>j(V)},e.toDisplayString(V.toString().padStart(2,"0"))+"월 ",11,Ue)]))),128))])],512),[[e.vShow,d.value==="month"]])])]),e.createElementVNode("button",{type:"button",class:"btn-cal-move next",onClick:S[3]||(S[3]=(...V)=>e.unref(l)&&e.unref(l)(...V))},[...S[6]||(S[6]=[e.createElementVNode("span",{class:"sr-only"},"다음 달",-1)])])]),e.createElementVNode("div",Xe,[e.createElementVNode("div",Je,[e.createElementVNode("table",Qe,[e.createElementVNode("caption",null,e.toDisplayString(e.unref(u))+"년 "+e.toDisplayString(e.unref(h).toString().padStart(2,"0"))+"월",1),S[7]||(S[7]=e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",null,"일"),e.createElementVNode("th",null,"월"),e.createElementVNode("th",null,"화"),e.createElementVNode("th",null,"수"),e.createElementVNode("th",null,"목"),e.createElementVNode("th",null,"금"),e.createElementVNode("th",null,"토")])],-1)),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(N.value,(V,T)=>(e.openBlock(),e.createElementBlock("tr",{key:T},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(V,(I,x)=>(e.openBlock(),e.createElementBlock("td",{key:x,class:e.normalizeClass($(I)),"data-date":I.dateString},[e.createElementVNode("button",{type:"button",class:"btn-set-date","aria-pressed":e.unref(f)(I.dateString).isInRange?"true":"false",onClick:W=>e.unref(p)(I.dateString)},[e.createElementVNode("span",null,e.toDisplayString(I.day),1)],8,et)],10,Ze))),128))]))),128))])])])]),e.createElementVNode("div",tt,[e.createElementVNode("div",nt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,V=>(e.openBlock(),e.createBlock(e.unref(O),{id:V.id,key:V.id,class:e.normalizeClass(V.class),variant:V.variant,size:V.size,onClick:V.handler},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(V.label),1)]),_:2},1032,["id","class","variant","size","onClick"]))),128))])])],544),[[e.vShow,r.value]])],2)],2)]))}}),te=e.defineComponent({name:"KrdsTextarea",props:{modelValue:{type:String,default:""},size:{type:String,default:void 0},placeholder:{type:String,default:void 0},maxlength:{type:Number,default:void 0},minlength:{type:Number,default:void 0},rows:{type:Number,default:4},cols:{type:Number,default:void 0},autofocus:{type:Boolean,default:!1},name:{type:String,default:void 0},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},showCount:{type:Boolean,default:!0},resize:{type:String,default:"vertical"},class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","input","change","focus","blur","keydown","keyup"],setup(t,{emit:i}){const s=e.ref(0);e.watch(()=>t.modelValue,l=>{s.value=(l||"").length},{immediate:!0});const o=e.computed(()=>{const l=["krds-input"];return t.size&&l.push(t.size),t.class&&l.push(t.class),l}),n=e.computed(()=>{const l={};return t.resize&&(l.resize=t.resize),l}),a=l=>{const c=l.target.value;s.value=c.length,i("update:modelValue",c),i("input",l)},r=l=>{i("change",l)},d=l=>{i("focus",l)},u=l=>{i("blur",l)},h=l=>{i("keydown",l)},y=l=>{i("keyup",l)},C=e.computed(()=>{const l={class:o.value,style:n.value,value:t.modelValue,placeholder:t.placeholder,name:t.name,id:t.id,required:t.required,readonly:t.readonly,disabled:t.disabled,autofocus:t.autofocus,rows:t.rows,cols:t.cols,onInput:a,onChange:r,onFocus:d,onBlur:u,onKeydown:h,onKeyup:y};return t.maxlength!==void 0&&(l.maxlength=t.maxlength),t.minlength!==void 0&&(l.minlength=t.minlength),l}),g=e.computed(()=>["form-conts"]),w=e.computed(()=>["textarea-wrap"]),m=e.computed(()=>{if(!t.showCount)return null;const l=s.value,p=t.maxlength;return{current:l,max:p||""}});return()=>{const l=[e.h("textarea",C.value)];return m.value&&l.push(e.h("p",{class:"textarea-count"},[e.h("span",{class:"count-now"},m.value.current),e.h("span",{class:"count-total"},m.value.max?`/${m.value.max}`:"")])),e.h("div",{class:g.value},[e.h("div",{class:w.value},l)])}}}),ne=e.defineComponent({name:"KrdsSelect",props:{modelValue:{type:[String,Number,null],default:null},size:{type:String,default:"medium"},title:{type:String,default:void 0},options:{type:Array,default:()=>[]},placeholder:{type:String,default:"선택"},name:{type:String,default:void 0},disabled:{type:Boolean,default:!1},state:{type:String,default:"default"},sort:{type:Boolean,default:!1},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","focus","blur"],setup(t,{emit:i,slots:s}){const o=e.computed(()=>{const y=[];return t.sort?y.push("krds-form-select-sort"):y.push("krds-form-select"),t.size&&y.push(t.size),t.class&&y.push(t.class),y}),n=y=>{const C=y.target,g=C.value===""?null:C.value;i("update:modelValue",g)},a=y=>{i("focus",y)},r=y=>{i("blur",y)},d=e.computed(()=>({class:o.value,value:t.modelValue??"",title:t.title||t.placeholder,name:t.name,id:t.id,disabled:t.disabled||t.readonly,onChange:n,onFocus:a,onBlur:r})),u=e.computed(()=>{const y=["form-conts"];return t.state!=="default"&&y.push(`is-${t.state}`),y}),h=()=>{const y=[];return t.placeholder&&!t.modelValue&&y.push(e.h("option",{value:"",disabled:!0,selected:!0},t.placeholder)),t.options&&t.options.length>0&&t.options.forEach(C=>{y.push(e.h("option",{value:C.value,disabled:C.disabled,selected:C.value===t.modelValue},C.label))}),s.default&&y.push(...s.default()),y};return()=>{const y=e.h("select",d.value,h());return t.sort?y:e.h("div",{class:u.value},[y])}}}),le=e.defineComponent({name:"KrdsFileUpload",props:{modelValue:{type:Array,default:()=>[]},size:{type:String,default:"medium"},accept:{type:String,default:void 0},maxFiles:{type:Number,default:10},maxFileSize:{type:Number,default:20*1024*1024},multiple:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1},dragAndDrop:{type:Boolean,default:!0},title:{type:String,default:"타이틀영역"},description:{type:String,default:"컨텐츠 영역"},placeholder:{type:String,default:"첨부할 파일을 여기에 끌어다 놓거나, 파일 선택 버튼을 눌러 파일을 직접 선택해주세요."},showPreview:{type:Boolean,default:!0},showDownload:{type:Boolean,default:!0},showPreviewButton:{type:Boolean,default:!0},showClearAll:{type:Boolean,default:!0},name:{type:String,default:void 0},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},class:{type:String,default:void 0},style:{type:[String,Object],default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","file-added","file-removed","file-error","upload-start","upload-progress","upload-complete","upload-error","clear-all","download","preview"],setup(t,{emit:i}){e.ref(!1),e.computed(()=>{const o=["krds-file-upload","line"];return t.class&&o.push(t.class),o});const s=e.computed(()=>t.modelValue?.length||0);return e.computed(()=>!t.disabled&&s.value<t.maxFiles),()=>null}}),ae=e.defineComponent({name:"KrdsBadge",props:{type:{type:String,default:"outline"},color:{type:String,default:"primary"},size:{type:String,default:"large"},number:{type:Boolean,default:!1},class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:i,slots:s}){const o=e.computed(()=>{const a=["krds-badge"];return a.push(`${t.type}-${t.color}`),t.size&&a.push(t.size),t.number&&a.push("number"),t.class&&a.push(t.class),a}),n=a=>{i("click",a)};return()=>e.h("span",{type:t.type,color:t.color,size:t.size,number:t.number,class:o.value,onClick:n},s.default?.())}}),oe=e.defineComponent({name:"KrdsTag",props:{link:{type:Boolean,default:!1},href:{type:String,default:"#"},target:{type:String,default:void 0},rel:{type:String,default:void 0},class:{type:String,default:void 0}},emits:["remove"],setup(t,{emit:i,slots:s}){const o=e.computed(()=>{const r=["krds-btn-tag"];return t.link&&r.push("link"),t.class&&r.push(t.class),r}),n=r=>{i("remove",r)},a=()=>e.h("button",{type:"button",class:"btn-delete",onClick:n},[e.h("span",{class:"sr-only"},"삭제")]);return()=>{const r=[],d=s.default?.();if(d&&r.push(d),t.link||r.push(a()),t.link){const u={href:t.href,class:o.value};return t.target&&(u.target=t.target),t.rel&&(u.rel=t.rel),e.h("a",u,r)}return e.h("span",{class:o.value},r)}}}),se=e.defineComponent({name:"KrdsTagGroup",props:{size:{type:String,default:"medium"},class:{type:String,default:void 0}},setup(t,{slots:i}){const s=e.computed(()=>{const o=["krds-tag-wrap"];return t.size&&o.push(t.size),t.class&&o.push(t.class),o});return()=>e.h("div",{class:s.value},i.default?.())}}),ie=e.defineComponent({name:"KrdsMasthead",props:{class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:i,slots:s}){const o=e.computed(()=>{const a=[""];return t.class&&a.push(t.class),a}),n=a=>{i("click",a)};return()=>e.h("div",{id:"krds-masthead",class:o.value,onClick:n},[e.h("div",{class:"toggle-wrap"},[e.h("div",{class:"toggle-head"},[e.h("div",{class:"inner"},[e.h("span",{class:"nuri-txt"},s.default?.())])])])])}});let lt=0;function R(t="krds"){return`${t}-${++lt}`}function at(){const t=Date.now().toString(36).slice(-4),i=Math.random().toString(36).substring(2,5);return`${t}${i}`}function F(...t){return t.filter(Boolean).join(" ")}const re=e.defineComponent({name:"KrdsToggleSwitch",props:{modelValue:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},label:{type:String,default:void 0},size:{type:String,default:"medium",validator:t=>["medium","large"].includes(t)},name:{type:String,default:void 0},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue","change"],setup(t,{emit:i,attrs:s}){const o=e.computed(()=>t.modelValue),n=e.computed(()=>F("krds-form-toggle-switch",t.size,t.class)),a=d=>{if(t.disabled)return;const h=d.target.checked;i("update:modelValue",h),i("change",h)},r=e.computed(()=>t.id||R("toggle-switch"));return()=>e.h("div",{class:n.value},[e.h("input",{type:"checkbox",id:r.value,name:t.name,checked:o.value,disabled:t.disabled,onChange:a,...s}),e.h("label",{for:r.value},[e.h("span",{class:"switch-toggle"},[e.h("i")]),t.label||""])])}}),ce=e.defineComponent({name:"KrdsCheckArea",props:{class:{type:String,default:void 0},column:{type:Boolean,default:!1}},setup(t,{slots:i}){return()=>{const s=["krds-check-area"];return t.column&&s.push("chk-column"),t.class&&s.push(t.class),e.h("div",{class:s},i.default?.())}}}),de=e.defineComponent({name:"KrdsCheckbox",props:{modelValue:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},size:{type:String,default:"medium",validator:t=>["medium","large"].includes(t)},chip:{type:Boolean,default:!1},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue"],slots:Object,setup(t,{emit:i,attrs:s,slots:o}){const n=e.computed(()=>t.modelValue),a=e.computed(()=>{const u=t.chip?"krds-form-chip":"krds-form-check";return F(u,t.size,t.class)}),r=u=>{if(t.disabled)return;const y=u.target.checked;i("update:modelValue",y)},d=e.computed(()=>t.id||R("checkbox"));return()=>{const u=[e.h("input",{type:"checkbox",id:d.value,checked:n.value,disabled:t.disabled,onChange:r,...s}),e.h("label",{for:d.value},o.default?.())];return o.description&&!t.chip&&u.push(e.h("div",{class:"krds-form-check-cnt"},e.h("p",{class:"krds-form-check-p"},o.description()))),e.h("div",{class:a.value},u)}}}),ue=e.defineComponent({name:"KrdsRadio",props:{modelValue:{type:[String,Number,Boolean],default:void 0},value:{type:[String,Number,Boolean],required:!0},disabled:{type:Boolean,default:!1},size:{type:String,default:"medium",validator:t=>["medium","large"].includes(t)},chip:{type:Boolean,default:!1},name:{type:String,default:void 0},class:{type:String,default:void 0},id:{type:String,default:void 0}},emits:["update:modelValue"],slots:Object,setup(t,{emit:i,attrs:s,slots:o}){const n=e.computed(()=>t.modelValue===t.value),a=e.computed(()=>{const h=t.chip?"krds-form-chip":"krds-form-check";return F(h,t.size,t.class)}),r=h=>{if(t.disabled)return;h.target.checked&&i("update:modelValue",t.value)},d=e.computed(()=>t.id||R("radio")),u=e.computed(()=>t.name);return()=>{const h=[e.h("input",{type:"radio",id:d.value,name:u.value,value:String(t.value),checked:n.value,disabled:t.disabled,onChange:r,...s}),e.h("label",{for:d.value},o.default?.())];return o.description&&!t.chip&&h.push(e.h("div",{class:"krds-form-check-cnt"},e.h("p",{class:"krds-form-check-p"},o.description()))),e.h("div",{class:a.value},h)}}}),fe=e.defineComponent({name:"KrdsStepIndicator",props:{modelValue:{type:Number,default:0},class:{type:String,default:void 0}},emits:["update:modelValue"],setup(t,{slots:i}){const s=e.computed(()=>{const d=["krds-step-wrap"];return t.class&&d.push(t.class),d}),o=d=>{const u=t.modelValue||0;return d<u?"done":d===u?"active":"pending"},n=e.ref(0),a=()=>{n.value=0},r=()=>n.value++;return e.provide("stepIndicator",{activeStep:e.computed(()=>t.modelValue||0),getStepStatus:o,getNextStepIndex:r,resetStepIndex:a}),()=>(a(),e.h("ol",{class:s.value},i.default?.()))}}),me=e.defineComponent({name:"KrdsStep",props:{step:{type:[String,Number],required:!0},title:{type:String,required:!0},status:{type:String,default:void 0},class:{type:String,default:void 0}},emits:["click"],setup(t,{emit:i,slots:s}){const o=e.inject("stepIndicator"),n=o?o.getNextStepIndex():-1,a=e.computed(()=>t.status?t.status:o&&n>=0?o.getStepStatus(n):"pending"),r=e.computed(()=>{const u=[a.value];return t.class&&u.push(t.class),u}),d=u=>{i("click",u,t.step)};return()=>{const u=a.value==="active";return e.h("li",{class:r.value,onClick:d},[e.h("span",[u&&e.h("em",{class:"sr-only"},"현재단계"),e.h("i",{class:"step"},t.step),e.h("span",{class:"step-tit"},t.title),s.default?.()])])}}}),pe=e.defineComponent({name:"KrdsSkipLink",props:{href:{type:String,required:!0,validator:t=>t.startsWith("#")},class:{type:[String,Array,Object],default:void 0},id:{type:String,default:"krds-skip-link"}},setup(t,{slots:i}){return()=>e.h("div",{id:t.id,class:t.class},[e.h("a",{href:t.href},i.default?.())])}}),ot=["id","aria-label"],st={class:"breadcrumb"},it=["href","aria-current","onClick"],rt={key:0},he=e.defineComponent({__name:"KrdsBreadcrumb",props:{items:{},id:{default:void 0},ariaLabel:{default:"현재 경로"},showHomeIcon:{type:Boolean,default:!0}},emits:["item-click"],setup(t,{emit:i}){const s=t,o=i,n=r=>r===s.items.length-1,a=(r,d)=>{r.onClick&&r.onClick(d),o("item-click",r,d)};return(r,d)=>(e.openBlock(),e.createElementBlock("nav",{id:t.id,class:"krds-breadcrumb-wrap","aria-label":t.ariaLabel},[e.createElementVNode("ol",st,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(u,h)=>(e.openBlock(),e.createElementBlock("li",{key:`breadcrumb-${h}`,class:e.normalizeClass({home:h===0&&t.showHomeIcon})},[e.createElementVNode("a",{href:u.href||"#",class:"txt","aria-current":n(h)?"page":void 0,onClick:y=>a(u,y)},[h===0&&t.showHomeIcon?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",rt,e.toDisplayString(u.text),1))],8,it)],2))),128))])],8,ot))}}),ye=e.defineComponent({name:"KrdsInPageNavigation",props:{title:{type:String,default:void 0},caption:{type:String,default:"이 페이지의 구성"},items:{type:Array,default:()=>[]},autoActive:{type:Boolean,default:!0},headerTopSelector:{type:String,default:"#krds-masthead"},headerInnerSelector:{type:String,default:"#krds-header .header-in"},class:{type:String,default:void 0}},emits:["itemClick"],slots:Object,setup(t,{emit:i,slots:s}){const o=e.ref(""),n=e.ref(new Map),a=e.computed(()=>{const m=["krds-in-page-navigation-type"];return t.class&&m.push(t.class),m}),r=()=>{const m=t.headerTopSelector,l=t.headerInnerSelector,p=document.querySelector(m)?.clientHeight||0,c=document.querySelector(l)?.clientHeight||0;return p+c},d=(m,l)=>{if(i("itemClick",m,l),m.href.startsWith("#")){l.preventDefault();const p=document.querySelector(m.href);if(p){const c=r();if(window.scrollTo({left:0,top:p.getBoundingClientRect().top+window.scrollY-c,behavior:"smooth"}),o.value=m.href,l instanceof KeyboardEvent){const f=p.querySelector(".sec-tit, h1, h2, h3, h4, h5, h6");f&&f instanceof HTMLElement&&(f.setAttribute("tabindex","-1"),f.focus({preventScroll:!0}))}}}},u=()=>{n.value.clear(),t.items&&t.items.filter(m=>m.href.startsWith("#")).forEach(m=>{const l=document.querySelector(m.href);l&&n.value.set(m.href,l)})},h=()=>{if(!t.autoActive||!t.items||n.value.size===0)return;const m=window.innerHeight,l=Math.ceil(m/5),p=window.scrollY+m,c=document.body.scrollHeight,f=t.items.filter(N=>N.href.startsWith("#")&&n.value.has(N.href)).map(N=>({href:N.href,element:n.value.get(N.href),item:N}));if(f.length===0)return;const E=f[0],D=f[f.length-1],v=E.element.offsetTop;let K="";if(p>=c)K=D.href;else if(window.scrollY<=v)K=E.href;else for(const N of f){const $=N.element.offsetHeight,B=N.element.offsetTop-l;if(window.scrollY>B&&window.scrollY<=B+$){K=N.href;break}}K&&K!==o.value&&(o.value=K)},y=()=>{if(!t.items)return;const m=t.items.find(l=>l.active);m?o.value=m.href:t.items.length>0&&(o.value=t.items[0].href)};e.onMounted(()=>{if(y(),t.autoActive){u(),h(),window.addEventListener("scroll",h,{passive:!0});const m=new MutationObserver(()=>{u()});m.observe(document.body,{childList:!0,subtree:!0}),e.onUnmounted(()=>{m.disconnect()})}}),e.onUnmounted(()=>{t.autoActive&&(window.removeEventListener("scroll",h),n.value.clear())});const C=()=>!t.caption&&!t.title?null:e.h("div",{class:"in-page-navigation-header"},[t.caption&&e.h("p",{class:"quick-caption"},t.caption),t.title&&e.h("p",{class:"quick-title"},t.title)]),g=()=>{if(!t.items)return null;const m=t.items.map(l=>{const p=o.value===l.href||!t.autoActive&&l.active;return e.h("li",{key:l.href},[e.h("a",{href:l.href,class:p?"active":"",onClick:c=>d(l,c),onKeydown:c=>{(c.key==="Enter"||c.key===" ")&&(c.preventDefault(),d(l,c))}},l.text)])});return e.h("nav",{class:"in-page-navigation-list"},[e.h("ul",{},m)])},w=()=>s.action?e.h("div",{class:"in-page-navigation-action"},[s.action()]):null;return()=>e.h("div",{class:a.value},[e.h("div",{class:"krds-in-page-navigation-area"},[C(),g(),w()].filter(Boolean))])}}),ct=["id"],dt={class:"page-links"},ut=["href","aria-current","onClick"],ft={key:0},mt=["aria-label"],ge=e.defineComponent({__name:"KrdsPagination",props:{modelValue:{default:1},min:{default:1},max:{},id:{default:void 0},ariaLabel:{default:"페이지 내비게이션"},pageRange:{default:8}},emits:["update:modelValue"],setup(t,{emit:i}){const s=t,o=i,n=e.computed(()=>Math.max(1,s.min)),a=e.computed(()=>s.modelValue??n.value),r=e.computed(()=>a.value<=n.value),d=e.computed(()=>a.value>=s.max),u=e.computed(()=>{if(!r.value)return"#"}),h=e.computed(()=>{if(!d.value)return"#"}),y=e.computed(()=>{const{pageRange:m,max:l}=s,p=1,c=[];if(l<=m+2*p)for(let f=n.value;f<=l;f++)c.push({type:"page",key:`page-${f}`,page:f,href:"#"});else{const f=Math.min(p,l),E=Math.max(l-p+1,1),D=Math.max(n.value,a.value-Math.floor(m/2)),v=Math.min(l,D+m-1),K=Math.max(n.value,v-m+1);for(let B=n.value;B<=f;B++)c.push({type:"page",key:`page-${B}`,page:B,href:"#"});K>f+1&&c.push({type:"ellipsis",key:"ellipsis-left",ariaLabel:"페이지 생략"});const N=Math.max(K,f+1),$=Math.min(v,E-1);for(let B=N;B<=$;B++)c.push({type:"page",key:`page-${B}`,page:B,href:"#"});v<E-1&&c.push({type:"ellipsis",key:"ellipsis-right",ariaLabel:"페이지 생략"});for(let B=E;B<=l;B++)c.push({type:"page",key:`page-${B}`,page:B,href:"#"})}return c}),C=(m,l)=>{if(m===a.value){l.preventDefault();return}o("update:modelValue",m)},g=m=>{if(r.value){m.preventDefault();return}const l=a.value-1;o("update:modelValue",l)},w=m=>{if(d.value){m.preventDefault();return}const l=a.value+1;o("update:modelValue",l)};return(m,l)=>{const p=e.resolveDirective("sr-only");return e.openBlock(),e.createElementBlock("div",{id:t.id,class:"krds-pagination"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.value?"span":"a"),{href:r.value?void 0:u.value,class:e.normalizeClass(["page-navi","prev",{disabled:r.value}]),onClick:g},{default:e.withCtx(()=>[...l[0]||(l[0]=[e.createTextVNode(" 이전 ",-1)])]),_:1},8,["href","class"])),e.createElementVNode("div",dt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,c=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:c.key},[c.type==="page"?(e.openBlock(),e.createElementBlock("a",{key:0,href:c.href||"#",class:e.normalizeClass(["page-link",{active:c.page===a.value}]),"aria-current":c.page===a.value?"page":void 0,onClick:f=>C(c.page,f)},[c.page===a.value?e.withDirectives((e.openBlock(),e.createElementBlock("span",ft,[...l[1]||(l[1]=[e.createTextVNode("현재페이지",-1)])])),[[p]]):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(c.page),1)],10,ut)):c.type==="ellipsis"?(e.openBlock(),e.createElementBlock("span",{key:1,class:"page-link link-dot","aria-label":c.ariaLabel},null,8,mt)):e.createCommentVNode("",!0)],64))),128))]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(d.value?"span":"a"),{href:d.value?void 0:h.value,class:e.normalizeClass(["page-navi","next",{disabled:d.value}]),onClick:w},{default:e.withCtx(()=>[...l[2]||(l[2]=[e.createTextVNode(" 다음 ",-1)])]),_:1},8,["href","class"]))],8,ct)}}}),pt={class:"inner help-panel-flexible"},ht={class:"help-panel-wrap"},yt={class:"help-conts-area"},ke=e.defineComponent({__name:"KrdsPanel",props:{modelValue:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(t,{emit:i}){const s=t,o=i,n=e.computed({get:()=>s.modelValue,set:d=>o("update:modelValue",d)}),a=()=>{n.value=!0},r=()=>{n.value=!1};return(d,u)=>(e.openBlock(),e.createElementBlock("div",pt,[e.createElementVNode("button",{type:"button",class:"krds-btn small tertiary btn-help-panel expand btn-help-exec",onClick:a},[...u[0]||(u[0]=[e.createElementVNode("i",{class:"svg-icon ico-fold"},null,-1),e.createTextVNode(" 도움말 ",-1)])]),e.createElementVNode("div",{class:e.normalizeClass(["krds-help-panel",{expand:n.value}])},[e.createElementVNode("div",ht,[e.createElementVNode("div",yt,[e.renderSlot(d.$slots,"default"),e.createElementVNode("button",{type:"button",class:"krds-btn small tertiary btn-help-panel fold",onClick:r},[...u[1]||(u[1]=[e.createElementVNode("span",{class:"sr-only"},"도움말",-1),e.createTextVNode(" 접어두기 ",-1),e.createElementVNode("i",{class:"svg-icon ico-angle right"},null,-1)])])])])],2)]))}}),gt={class:"tooltip-action"},kt={key:0,class:"svg-icon ico-help"},bt={key:1,class:"svg-icon ico-tooltip"},St={class:"tooltip-title"},Ct={class:"tooltip-contents"},be=e.defineComponent({__name:"KrdsContextualHelp",props:{tooltipTitle:{default:"도움말 제목"},helpIcon:{type:Boolean},position:{default:"top left"}},setup(t){const i=t,s=e.ref(),o=e.ref(),n=e.ref(),a=e.ref(),r=e.ref(!1),d=()=>{const l=r.value;y(),l||u()},u=()=>{if(!n.value||!o.value)return;r.value=!0,n.value.style.display="block",o.value.setAttribute("aria-expanded","true"),n.value.querySelector('a, button, [tabindex="0"], input, textarea, select')?.focus(),C()},h=()=>{!n.value||!o.value||(r.value=!1,n.value.style.display="none",o.value.setAttribute("aria-expanded","false"))},y=()=>{const l=document.querySelectorAll(".krds-contextual-help .tooltip-popover"),p=document.querySelectorAll(".krds-contextual-help .tooltip-btn");l.forEach(c=>{c.style.display="none"}),p.forEach(c=>{c.setAttribute("aria-expanded","false")}),r.value=!1},C=()=>{if(!s.value||!n.value)return;const l=window.innerWidth<=768,p=s.value.querySelector(".tooltip-action");if(l){const f=getComputedStyle(document.querySelector(":root")).getPropertyValue("--krds-contents-padding-x").trim().split("px")[0],D=p.getBoundingClientRect().left-parseInt(f),v=document.body.clientWidth-parseInt(f)*2;n.value.style.left=`-${D}px`,n.value.style.width=`${v}px`}else n.value.style.left="",n.value.style.right="",n.value.style.width="360px"},g=l=>{(l.key==="Escape"||l.key==="Esc")&&y()},w=l=>{l.target.closest(".tooltip-action")||y()},m=()=>{r.value&&C()};return e.onMounted(()=>{s.value&&(o.value&&o.value.setAttribute("aria-expanded","false"),n.value&&n.value.setAttribute("role","tooltip"),document.addEventListener("keydown",g),document.addEventListener("click",w),window.addEventListener("resize",m))}),e.onUnmounted(()=>{document.removeEventListener("keydown",g),document.removeEventListener("click",w),window.removeEventListener("resize",m)}),(l,p)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:s,class:e.normalizeClass(["krds-contextual-help",i.position])},[e.createElementVNode("div",gt,[e.createElementVNode("button",{ref_key:"tooltipBtnRef",ref:o,type:"button",class:"krds-btn medium icon tooltip-btn",onClick:d},[p[0]||(p[0]=e.createElementVNode("span",{class:"sr-only"},"도움말",-1)),i.helpIcon?(e.openBlock(),e.createElementBlock("i",kt)):(e.openBlock(),e.createElementBlock("i",bt))],512),e.createElementVNode("div",{ref_key:"tooltipPopoverRef",ref:n,class:"tooltip-popover",role:"tooltip"},[e.createElementVNode("h4",St,e.toDisplayString(i.tooltipTitle),1),e.createElementVNode("div",Ct,[e.renderSlot(l.$slots,"default")]),e.createElementVNode("button",{ref_key:"closeBtnRef",ref:a,type:"button",class:"krds-btn xsmall icon tooltip-close",onClick:h},[...p[1]||(p[1]=[e.createElementVNode("span",{class:"sr-only"},"닫기",-1),e.createElementVNode("i",{class:"svg-icon ico-modal-close"},null,-1)])],512)],512)])],2))}}),Et={key:0,class:"coach-balloon"},Vt={class:"coach-tit"},wt={class:"desc"},Bt={class:"coach-controls"},Nt={class:"num"},vt={class:"btn-wrap"},Se=e.defineComponent({__name:"KrdsCoachMark",props:{coachMarkClass:{default:""},stepsData:{},activeStep:{},modelValue:{default:null},class:{},style:{},id:{}},emits:["update:modelValue","close"],setup(t,{emit:i}){const s=t,o=e.computed(()=>{const u=s.activeStep-1;return s.stepsData&&u>=0&&u<s.stepsData.length?s.stepsData[u]:null}),n=i,a=()=>{s.activeStep>1&&n("update:modelValue",s.activeStep-1)},r=()=>{s.activeStep<s.stepsData.length&&n("update:modelValue",s.activeStep+1)},d=()=>{n("close")};return(u,h)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["krds-coach-mark",t.coachMarkClass]),style:e.normalizeStyle(t.style)},[t.modelValue===t.activeStep&&o.value?(e.openBlock(),e.createElementBlock("div",Et,[h[2]||(h[2]=e.createElementVNode("h5",{class:"sr-only"},"따라하기 가이드",-1)),e.createElementVNode("h6",Vt,e.toDisplayString(t.activeStep)+"단계 : "+e.toDisplayString(o.value.title),1),e.createElementVNode("p",wt,e.toDisplayString(o.value.description),1),e.createElementVNode("div",Bt,[e.createElementVNode("div",Nt,[h[0]||(h[0]=e.createElementVNode("span",{class:"sr-only"},"현재 단계",-1)),e.createElementVNode("strong",null,e.toDisplayString(t.activeStep),1),h[1]||(h[1]=e.createElementVNode("span",{class:"sr-only"},"총 단계",-1)),e.createElementVNode("span",null,e.toDisplayString(t.stepsData.length),1)]),e.createElementVNode("div",vt,[e.createElementVNode("button",{type:"button",class:"krds-btn small text",onClick:d},"그만보기"),t.activeStep!==1?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"krds-btn small text",onClick:a},"이전으로")):e.createCommentVNode("",!0),t.activeStep!==t.stepsData.length?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"krds-btn small tertiary",onClick:r},"다음으로")):e.createCommentVNode("",!0)])])])):e.createCommentVNode("",!0),e.renderSlot(u.$slots,"coach-mark-content")],6))}}),Kt=["disabled","aria-labelledby"],Dt=["id","aria-hidden"],xt={class:"sr-only"},Ce=e.defineComponent({__name:"KrdsTooltip",props:{type:{default:"default"},tooltipContent:{},vertical:{type:Boolean},box:{type:Boolean},disabled:{type:Boolean,default:!1},class:{},style:{},id:{}},setup(t){const i=t,s=e.ref(null),o=e.ref(null),n=e.ref(!1),a=e.ref({}),r=e.ref(`tooltip-popover-${Math.random().toString(36).substring(2,9)}`),d=e.ref(!1),u=e.computed(()=>{const f=["krds-btn","krds-tooltip"];return i.type==="default"?f.push("small","text"):i.type==="icon"?f.push("icon"):i.type==="button"&&f.push(""),!i.box&&i.vertical&&f.push("tooltip-vertical"),i.box&&!i.vertical&&f.push("tooltip-box"),f.join(" ")}),h=e.computed(()=>{const f=[];return i.box&&f.push("tooltip-box"),i.vertical&&f.push("tooltip-vertical"),n.value&&f.push("active"),f}),y=e.computed(()=>s.value?.querySelector("button")?.textContent?.trim()||""),C=()=>window.innerWidth<=768,g=()=>{if(!s.value||!o.value)return;const f=s.value.querySelector("button");if(!f)return;const E=12,{clientHeight:D,clientWidth:v}=o.value,{top:K,left:N,right:$,height:B,width:L}=f.getBoundingClientRect(),P=window.innerWidth/2,j=window.innerHeight/2;let M,_;const z=[];d.value||i.box||i.vertical?(K+B>j?(M=K-D-E,z.push("top")):(M=K+B+E,z.push("bottom")),N+L>P?(_=$-v,z.push("right"),window.innerWidth-(N+L)>v/2&&(_=N+(L-v)/2,z.splice(z.indexOf("right"),1))):(_=N+(L-v)/2,_<0&&(_=N,z.push("left")))):(M=K+(B-D)/2,N+L>P?(_=N-v-E,z.push("right")):_=$+E);const A=window.innerWidth<=420;a.value={top:`${M}px`,left:A?"50%":`${_}px`,transform:A?"translateX(-50%)":"none"},o.value&&(o.value.className=`krds-tooltip-popover ${z.join(" ")} ${h.value.join(" ")}`)},w=async()=>{i.disabled||!i.tooltipContent||(n.value=!0,await e.nextTick(),g())},m=()=>{n.value=!1,a.value={}},l=f=>{(f.key==="Escape"||f.key==="Esc")&&n.value&&m()},p=()=>{d.value=C(),n.value&&m()},c=()=>{n.value&&m()};return e.onMounted(()=>{d.value=C(),document.addEventListener("keydown",l),window.addEventListener("scroll",c),window.addEventListener("resize",p)}),e.onUnmounted(()=>{document.removeEventListener("keydown",l),window.removeEventListener("scroll",c),window.removeEventListener("resize",p)}),(f,E)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:s},[e.createElementVNode("button",{type:"button",class:e.normalizeClass(u.value),disabled:t.disabled,"aria-labelledby":r.value,onMouseover:w,onMouseout:m,onFocusin:w,onFocusout:m},[e.renderSlot(f.$slots,"default")],42,Kt),e.withDirectives(e.createElementVNode("div",{id:r.value,ref_key:"popoverRef",ref:o,class:e.normalizeClass(["krds-tooltip-popover",h.value]),style:e.normalizeStyle(a.value),"aria-hidden":!n.value,role:"tooltip"},[e.createElementVNode("span",xt,e.toDisplayString(y.value),1),e.createTextVNode(" "+e.toDisplayString(t.tooltipContent),1)],14,Dt),[[e.vShow,n.value]])],512))}}),_t=["aria-expanded"],zt={class:"drop-in"},$t={key:0,class:"drop-top"},Lt={key:1,class:"drop-list"},It=["lang","aria-selected","onClick"],Tt={class:"sr-only"},Mt={key:2,class:"drop-list"},Rt=["href","lang"],Ee=e.defineComponent({__name:"KrdsLanguageSwitcher",props:{languageList:{},modelValue:{default:""},type:{default:"default"},dropPosition:{default:"center"},class:{},style:{},id:{}},emits:["update:modelValue","close"],setup(t,{emit:i}){const s=t,o=i,n=e.ref(!1),a=e.ref(),r=e.ref(),d=()=>{n.value=!n.value,n.value&&a.value&&y()},u=()=>{n.value=!1},h=l=>{o("update:modelValue",l),u(),o("close"),r.value?.focus()},y=()=>{if(!a.value)return;const l=a.value.querySelector(".drop-menu");if(!l)return;const p=l.getBoundingClientRect(),c=window.innerWidth;a.value.classList.remove("drop-left","drop-right"),p.left<0?a.value.classList.add("drop-left"):c<p.left+p.width&&a.value.classList.add("drop-right")},C=l=>{l.key==="Escape"&&(u(),r.value?.focus())},g=l=>{a.value?.contains(l.target)||u()},w=l=>{a.value?.contains(l.relatedTarget)||u()},m=l=>{if(!a.value)return;a.value.querySelectorAll(".drop-list .item-link").forEach(f=>{f.style.position="relative",f.style.zIndex="0"});const c=l.target;c.style.zIndex="1"};return e.watch(n,l=>{l?(document.addEventListener("keydown",C),document.addEventListener("click",g)):(document.removeEventListener("keydown",C),document.removeEventListener("click",g))}),e.onUnmounted(()=>{document.removeEventListener("keydown",C),document.removeEventListener("click",g)}),(l,p)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"dropdownRef",ref:a,class:e.normalizeClass(["krds-drop-wrap krds-language",{active:n.value,"drop-left":s.dropPosition==="left","drop-right":s.dropPosition==="right"}]),onFocusout:w},[e.createElementVNode("button",{ref_key:"buttonRef",ref:r,type:"button",class:e.normalizeClass(["krds-btn small text drop-btn",{active:n.value}]),"aria-expanded":n.value,onClick:d},[p[0]||(p[0]=e.createElementVNode("i",{class:"svg-icon ico-global"},null,-1)),e.renderSlot(l.$slots,"default"),p[1]||(p[1]=e.createElementVNode("i",{class:"svg-icon ico-toggle"},null,-1))],10,_t),e.createElementVNode("div",{class:"drop-menu",style:e.normalizeStyle({display:n.value?"block":"none"})},[e.createElementVNode("div",zt,[l.$slots["prev-item"]?(e.openBlock(),e.createElementBlock("div",$t,[e.renderSlot(l.$slots,"prev-item")])):e.createCommentVNode("",!0),s.type==="default"?(e.openBlock(),e.createElementBlock("ul",Lt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.languageList,c=>(e.openBlock(),e.createElementBlock("li",{key:c.code},[e.createElementVNode("a",{href:"#",class:e.normalizeClass(["item-link",{active:s.modelValue===c.code}]),lang:c.code,"aria-selected":s.modelValue===c.code,onClick:e.withModifiers(f=>h(c.code),["prevent"]),onFocus:m},[e.createTextVNode(e.toDisplayString(c.name)+" ",1),e.createElementVNode("span",Tt,e.toDisplayString(s.modelValue===c.code?"선택됨":""),1)],42,It)]))),128))])):s.type==="external"?(e.openBlock(),e.createElementBlock("ul",Mt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.languageList,c=>(e.openBlock(),e.createElementBlock("li",{key:c.code},[e.createElementVNode("a",{href:c.url||"#",class:"item-link",lang:c.code,target:"_blank",title:"새 창 열림",onFocus:m},[e.createTextVNode(e.toDisplayString(c.name)+" ",1),p[2]||(p[2]=e.createElementVNode("i",{class:"svg-icon ico-go"},null,-1))],40,Rt)]))),128))])):e.createCommentVNode("",!0)])],4)],34))}}),Ft={class:"drop-in"},Pt={class:"drop-list"},At=["data-adjust-scale","onClick"],Ot={class:"drop-bottom"},Ve=e.defineComponent({__name:"KrdsResize",emits:["update:modelValue","close"],setup(t,{emit:i}){const s=i,o=e.ref(!1),n=e.ref(),a=e.ref(),r=e.ref("md"),d=[{key:"sm",label:"작게",zoom:"0.9"},{key:"md",label:"보통",zoom:"1"},{key:"lg",label:"조금 크게",zoom:"1.1"},{key:"xlg",label:"크게",zoom:"1.3"},{key:"xxlg",label:"가장 크게",zoom:"1.5"}],u=()=>{o.value=!o.value,o.value&&n.value&&g()},h=()=>{o.value=!1},y=c=>{h(),s("close"),a.value?.focus(),r.value=c.key,document.body.style.zoom=c?.zoom},C=()=>{const c=d.find(f=>f.key==="md");c&&y(c)},g=()=>{if(!n.value)return;const c=n.value.querySelector(".drop-menu");if(!c)return;const f=c.getBoundingClientRect(),E=window.innerWidth;n.value.classList.remove("drop-left","drop-right"),f.left<0?n.value.classList.add("drop-left"):E<f.left+f.width&&n.value.classList.add("drop-right")},w=c=>{c.key==="Escape"&&(h(),a.value?.focus())},m=c=>{n.value?.contains(c.target)||h()},l=c=>{n.value?.contains(c.relatedTarget)||h()},p=c=>{if(!n.value)return;n.value.querySelectorAll(".drop-list .item-link").forEach(D=>{D.style.position="relative",D.style.zIndex="0"});const E=c.target;E.style.zIndex="1"};return e.watch(o,c=>{c?(document.addEventListener("keydown",w),document.addEventListener("click",m)):(document.removeEventListener("keydown",w),document.removeEventListener("click",m))}),e.onUnmounted(()=>{document.removeEventListener("keydown",w),document.removeEventListener("click",m)}),(c,f)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"dropdownRef",ref:n,class:"krds-drop-wrap krds-resize","data-adjust":"scale",onFocusout:l},[e.createElementVNode("button",{ref_key:"buttonRef",ref:a,type:"button",class:"krds-btn small text drop-btn",onClick:u},[...f[0]||(f[0]=[e.createTextVNode(" 화면크기 ",-1),e.createElementVNode("i",{class:"svg-icon ico-toggle"},null,-1)])],512),e.createElementVNode("div",{class:"drop-menu",style:e.normalizeStyle({display:o.value?"block":"none"})},[e.createElementVNode("div",Ft,[e.createElementVNode("ul",Pt,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(d,E=>e.createElementVNode("li",{key:E.key},[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["item-link",[E.key,E.key===r.value?"active":""]]),"data-adjust-scale":E.key,onClick:e.withModifiers(D=>y(E),["prevent"]),onFocus:p},e.toDisplayString(E.label),43,At)])),64))]),e.createElementVNode("div",Ot,[e.createElementVNode("button",{type:"button",class:"krds-btn medium text","data-adjust-scale":"md",onClick:e.withModifiers(C,["prevent"]),onFocus:p},[...f[1]||(f[1]=[e.createElementVNode("i",{class:"svg-icon ico-reset"},null,-1),e.createTextVNode(" 초기화 ",-1)])],32)])])],4)],544))}}),we=Object.freeze(Object.defineProperty({__proto__:null,KrdsBadge:ae,KrdsBreadcrumb:he,KrdsButton:O,KrdsButtonGroup:Y,KrdsCheckArea:ce,KrdsCheckbox:de,KrdsCoachMark:Se,KrdsContextualHelp:be,KrdsDateInput:ee,KrdsFileUpload:le,KrdsFormGroup:Z,KrdsFormHint:Q,KrdsFormLabel:J,KrdsIcon:G,KrdsInPageNavigation:ye,KrdsInput:X,KrdsLanguageSwitcher:Ee,KrdsLink:U,KrdsMasthead:ie,KrdsPagination:ge,KrdsPanel:ke,KrdsRadio:ue,KrdsResize:Ve,KrdsSelect:ne,KrdsSkipLink:pe,KrdsSpinner:q,KrdsStep:me,KrdsStepIndicator:fe,KrdsTag:oe,KrdsTagGroup:se,KrdsTextarea:te,KrdsToggleSwitch:re,KrdsTooltip:Ce},Symbol.toStringTag,{value:"Module"})),H={mounted(t,i){i.value!==!1&&t.classList.add("sr-only")},updated(t,i){i.value===!1?t.classList.remove("sr-only"):t.classList.add("sr-only")},unmounted(t){t.classList.remove("sr-only")}},Be={"sr-only":H},Ne=t=>{t.directive("sr-only",H)},ve=Object.freeze(Object.defineProperty({__proto__:null,default:Be,directives:Be,installDirectives:Ne,vSrOnly:H},Symbol.toStringTag,{value:"Module"})),qt={install(t,i={}){t.provide("krds:config",i);const s=i.components||Object.keys(we);s.forEach(o=>{const n=we[o];n&&t.component(o,n)}),typeof ve=="object"&&ve!==null&&Ne(t),t.config.globalProperties.$krds={version:"__VERSION__"},process.env.NODE_ENV!=="production"&&console.log(`[KRDS Vue] v__VERSION__ 설치 완료 - 컴포넌트: ${s.length}개`)}},Ht="__VERSION__";k.KrdsBadge=ae,k.KrdsBreadcrumb=he,k.KrdsButton=O,k.KrdsButtonGroup=Y,k.KrdsCheckArea=ce,k.KrdsCheckbox=de,k.KrdsCoachMark=Se,k.KrdsContextualHelp=be,k.KrdsDateInput=ee,k.KrdsFileUpload=le,k.KrdsFormGroup=Z,k.KrdsFormHint=Q,k.KrdsFormLabel=J,k.KrdsIcon=G,k.KrdsInPageNavigation=ye,k.KrdsInput=X,k.KrdsLanguageSwitcher=Ee,k.KrdsLink=U,k.KrdsMasthead=ie,k.KrdsPagination=ge,k.KrdsPanel=ke,k.KrdsRadio=ue,k.KrdsResize=Ve,k.KrdsSelect=ne,k.KrdsSkipLink=pe,k.KrdsSpinner=q,k.KrdsStep=me,k.KrdsStepIndicator=fe,k.KrdsTag=oe,k.KrdsTagGroup=se,k.KrdsTextarea=te,k.KrdsToggleSwitch=re,k.KrdsTooltip=Ce,k.classNames=F,k.default=qt,k.generateId=R,k.generateUid=at,k.version=Ht,Object.defineProperties(k,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
2
2
  //# sourceMappingURL=krds-vue.umd.js.map