@ihabdevteam/core 0.37.0 → 0.39.0

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.
Files changed (53) hide show
  1. package/dist/components.cjs.js +19 -19
  2. package/dist/components.esm.css +1 -1
  3. package/dist/hooks.cjs.js +1 -788
  4. package/dist/i18n.cjs.js +9 -9
  5. package/dist/ihabdevteam-core.cjs.js +178 -178
  6. package/dist/ihabdevteam-core.d.ts +74 -8
  7. package/dist/packages/core/src/components/BottomNav.js +1 -1
  8. package/dist/packages/core/src/components/DatePicker.js +1 -1
  9. package/dist/packages/core/src/components/Dropdown.js +1 -1
  10. package/dist/packages/core/src/components/FilterPanel.js +2 -1
  11. package/dist/packages/core/src/components/Header.js +1 -1
  12. package/dist/packages/core/src/components/PageTitle.css +7 -0
  13. package/dist/packages/core/src/components/PageTitle.d.ts +13 -1
  14. package/dist/packages/core/src/components/PageTitle.js +11 -2
  15. package/dist/packages/core/src/components/Panel.d.ts +3 -133
  16. package/dist/packages/core/src/components/Panel.js +2 -140
  17. package/dist/packages/core/src/components/PanelRow.d.ts +145 -0
  18. package/dist/packages/core/src/components/PanelRow.js +144 -0
  19. package/dist/packages/core/src/components/Popup/ConfirmPopup.d.ts +16 -2
  20. package/dist/packages/core/src/components/Popup/ConfirmPopup.js +19 -2
  21. package/dist/packages/core/src/components/Training/AudioPlayerWaveForm.js +1 -54
  22. package/dist/packages/core/src/components/Training/NoisePlayerContext.d.ts +2 -15
  23. package/dist/packages/core/src/components/Word/wordTablePrint.js +7 -1
  24. package/dist/packages/core/src/components/useAnchoredMenu.d.ts +8 -26
  25. package/dist/packages/core/src/components/useAnchoredMenu.js +7 -70
  26. package/dist/packages/core/src/components/useSoundCompassExam.d.ts +8 -51
  27. package/dist/packages/core/src/components/useSoundCompassExam.js +10 -128
  28. package/dist/packages/core/src/components.d.ts +4 -4
  29. package/dist/packages/core/src/components.js +2 -2
  30. package/dist/packages/core/src/hooks/useAnchoredMenu.d.ts +28 -0
  31. package/dist/packages/core/src/hooks/useAnchoredMenu.js +72 -0
  32. package/dist/packages/core/src/hooks/useSoundCompassExam.d.ts +54 -0
  33. package/dist/packages/core/src/hooks/useSoundCompassExam.js +128 -0
  34. package/dist/packages/core/src/hooks/useWordAttributeFilter.d.ts +2 -0
  35. package/dist/packages/core/src/hooks/useWordAttributeFilter.js +2 -1
  36. package/dist/packages/core/src/hooks/useWordTrainingDataGeneration.d.ts +2 -8
  37. package/dist/packages/core/src/hooks/useWordTrainingFilter.js +7 -6
  38. package/dist/packages/core/src/hooks.d.ts +4 -0
  39. package/dist/packages/core/src/hooks.js +6 -0
  40. package/dist/packages/core/src/i18n/locales/en.json +8 -0
  41. package/dist/packages/core/src/i18n/locales/ko.json +8 -0
  42. package/dist/packages/core/src/types/filterPanel.d.ts +15 -0
  43. package/dist/packages/core/src/types/training.d.ts +20 -0
  44. package/dist/packages/core/src/types/training.js +1 -0
  45. package/dist/packages/core/src/utils/audioPeaks.d.ts +2 -0
  46. package/dist/packages/core/src/utils/audioPeaks.js +67 -0
  47. package/dist/packages/core/src/utils/noiseSettingsStore.d.ts +1 -1
  48. package/dist/packages/core/src/utils/wordTrainingGroups.d.ts +1 -1
  49. package/dist/packages/core/src/utils/wordTrainingRuntimeTypes.d.ts +14 -0
  50. package/dist/packages/core/src/version.d.ts +1 -1
  51. package/dist/packages/core/src/version.js +1 -1
  52. package/dist/utils.cjs.js +1 -1
  53. package/package.json +1 -1
package/dist/hooks.cjs.js CHANGED
@@ -1,788 +1 @@
1
- "use strict";var l=require("react"),gt=require("react-i18next"),V=require("react/jsx-runtime"),Bo=require("react-dom"),Pn=typeof document<"u"?document.currentScript:null;function gr({storageKey:e="fontScale",baseFont:t=20,minScale:n=.8,maxScale:o=1.4,step:u=.1,lineHeightRatio:r=1.4}={}){const i=_=>Math.max(n,Math.min(o,Number(_))),[s,d]=l.useState(()=>{try{const _=localStorage.getItem(e),g=_?Number(_):1;return Number.isFinite(g)?g:1}catch{return 1}});l.useEffect(()=>{try{localStorage.setItem(e,String(s))}catch{}},[e,s]);const p=_=>{d(typeof _=="function"?g=>i(_(g)):i(_))},f=()=>p(_=>+(_+u).toFixed(6)),y=()=>p(_=>+(_-u).toFixed(6)),c=s<o-Number.EPSILON,m=s>n+Number.EPSILON,S=Math.round(t*s),w=Math.round(S*r);return{scale:s,setScale:p,increase:f,decrease:y,canIncrease:c,canDecrease:m,fontSize:S,lineHeight:w}}const Do=l.createContext(null);function _r(e){return/max-width:\s*7[0-9][0-9]px/.test(e)}function Er(e){const t=l.useContext(Do),n=r=>typeof window>"u"||!window.matchMedia?!1:window.matchMedia(r).matches,[o,u]=l.useState(n(e));return l.useEffect(()=>{if(typeof window>"u"||!window.matchMedia)return;const r=window.matchMedia(e),i=d=>u(d.matches),s=r;return s.addEventListener?s.addEventListener("change",i):s.addListener&&s.addListener(i),u(r.matches),()=>{s.removeEventListener?s.removeEventListener("change",i):s.removeListener&&s.removeListener(i)}},[e]),t&&typeof t.mobile=="boolean"&&_r(e)?t.mobile:o}function vo(e){const t=l.useRef(e);return l.useEffect(()=>{t.current=e}),t}function Oo(e,t){const n=vo(t);l.useEffect(()=>{const o=()=>n.current();try{window.addEventListener(e,o)}catch{}return()=>{try{window.removeEventListener(e,o)}catch{}}},[e,n])}const $n=" \xB7 ",Lo=(()=>{if(typeof document>"u")return"";const e=document.title;return e.includes($n)?e.split($n).pop()??e:e})(),Ro=l.createContext(!1);function br(e){const t=l.useContext(Ro);l.useEffect(()=>{if(t||typeof e!="string"||!e)return;const n=document.title;return document.title=Lo?`${e}${$n}${Lo}`:e,()=>{document.title=n}},[e,t])}function Sr(){const{t:e}=gt.useTranslation();return l.useCallback(t=>{if(!t)return"";const n=new Date(t).getTime();if(Number.isNaN(n))return"";const o=Math.floor((Date.now()-n)/864e5);return o<=0?e("myHomework.relativeDay.today","\uC624\uB298"):o===1?e("myHomework.relativeDay.yesterday","\uC5B4\uC81C"):e("myHomework.relativeDay.daysAgo",{n:o})},[e])}function kr(e){const[t,n]=l.useState({current:"",next:"",confirm:""}),[o,u]=l.useState(null),[r,i]=l.useState(!1),s=l.useRef(null);l.useEffect(()=>()=>{s.current!==null&&clearTimeout(s.current)},[]);const d=l.useCallback(()=>{n({current:"",next:"",confirm:""}),u(null)},[]),p=l.useCallback(async()=>{if(!t.current){u({type:"error",text:"\uD604\uC7AC \uBE44\uBC00\uBC88\uD638\uB97C \uC785\uB825\uD558\uC138\uC694."});return}if(!t.next){u({type:"error",text:"\uC0C8 \uBE44\uBC00\uBC88\uD638\uB97C \uC785\uB825\uD558\uC138\uC694."});return}if(t.next!==t.confirm){u({type:"error",text:"\uC0C8 \uBE44\uBC00\uBC88\uD638\uAC00 \uC77C\uCE58\uD558\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4."});return}i(!0);const f=e?await e(t.current,t.next):null;if(i(!1),f){u({type:"error",text:f});return}u({type:"success",text:"\uBE44\uBC00\uBC88\uD638\uAC00 \uBCC0\uACBD\uB418\uC5C8\uC2B5\uB2C8\uB2E4."}),n({current:"",next:"",confirm:""}),s.current!==null&&clearTimeout(s.current),s.current=setTimeout(()=>u(null),1500)},[t,e]);return{pw:t,setPw:n,pwMsg:o,setPwMsg:u,pwLoading:r,handleChangePw:p,reset:d}}const ke=["\u3131","\u3132","\u3134","\u3137","\u3138","\u3139","\u3141","\u3142","\u3143","\u3145","\u3146","\u3147","\u3148","\u3149","\u314A","\u314B","\u314C","\u314D","\u314E"],rt=["\u314F","\u3150","\u3151","\u3152","\u3153","\u3154","\u3155","\u3156","\u3157","\u3158","\u3159","\u315A","\u315B","\u315C","\u315D","\u315E","\u315F","\u3160","\u3161","\u3162","\u3163"],Fe=["","\u3131","\u3132","\u3133","\u3134","\u3135","\u3136","\u3137","\u3139","\u313A","\u313B","\u313C","\u313D","\u313E","\u313F","\u3140","\u3141","\u3142","\u3144","\u3145","\u3146","\u3147","\u3148","\u314A","\u314B","\u314C","\u314D","\u314E"];function le(e){if(!e)return null;const t=e.charCodeAt(0)-44032;return t<0||t>=11172?null:{cho:Math.floor(t/588),jung:Math.floor(t%588/28),jong:t%28}}function Ar(){const e=new Map;return t=>{let n=e.get(t);return n||(n=[...t].map(o=>le(o)),e.set(t,n)),n}}function _t(e,t,n=0){return String.fromCharCode(44032+(e*21+t)*28+n)}function wr(e,t){if(!e||!t||e===t||e.length!==t.length)return"random";let n=0,o=null;for(let u=0;u<e.length;u++){const r=le(e[u]),i=le(t[u]);if(!r||!i)return"random";if(r.cho===i.cho&&r.jung===i.jung&&r.jong===i.jong)continue;n++;const s=r.cho!==i.cho,d=r.jung!==i.jung,p=r.jong!==i.jong;(s?1:0)+(d?1:0)+(p?1:0)>1?o="multi":s?o="cho":d?o="jung":o="jong"}return n!==1?"random":o==="cho"?"cho":o==="jung"?"jung":o==="jong"?"jong":"random"}const $t={3:["\u3131","\u3145"],5:["\u3134","\u3148"],6:["\u3134","\u314E"],9:["\u3139","\u3131"],10:["\u3139","\u3141"],11:["\u3139","\u3142"],12:["\u3139","\u3145"],13:["\u3139","\u314C"],14:["\u3139","\u314D"],15:["\u3139","\u314E"],18:["\u3142","\u3145"]};Object.fromEntries(Object.entries($t).map(([e,t])=>[t.join(""),Fe[Number(e)]]));function Mr(e,t){if(!e||!t)return!1;for(const n of e){const o=le(n);if(o){if(ke[o.cho]===t)return!0;if(o.jong>0){if(Fe[o.jong]===t)return!0;const u=$t[o.jong];if(u&&u.includes(t))return!0}}}return!1}function pn(e){if(!e)return 0;let t=0;for(const n of e)le(n)&&t++;return t}function Nr(e){if(!e)return!1;let t=!1;for(const n of e){const o=le(n);if(o&&(t=!0,o.jong>0))return!1}return t}function Tr(e,t){if(e.jong<=0)return!1;if(t.includes(Fe[e.jong]))return!0;const n=$t[e.jong];return!!n&&n.some(o=>t.includes(o))}function xr(e,t,n){if(!e)return!1;const o=[...e],u=r=>{const i=le(o[r]);if(!i||t.cho&&!t.cho.includes(ke[i.cho])||t.jung&&!t.jung.includes(rt[i.jung]))return!1;if(t.jongNone){if(i.jong>0)return!1}else if(t.jong&&!Tr(i,t.jong))return!1;return!0};if(n==="head")return u(0);if(n==="tail")return u(o.length-1);if(n==="mid"){for(let r=1;r<o.length-1;r++)if(u(r))return!0;return!1}for(let r=0;r<o.length;r++)if(u(r))return!0;return!1}const Br={cho:ke.length,jung:rt.length,jong:Fe.length};function Dr(e,t,n,o,u=1/0){if(!e||n<1)return[];const r=[...e].map(y=>le(y));if(r.some(y=>!y))return[];const i=r,s=i.length;if(n>s)return[];const d=Br[t],p=new Set,f=[];(function y(c,m){if(m.length===n){f.push([...m]);return}for(let S=c;S<s;S++)m.push(S),y(S+1,m),m.pop()})(0,[]);for(const y of f)if((function c(m,S){if(p.size>=u)return;if(m===y.length){const g=S.map(k=>_t(k.cho,k.jung,k.jong)).join("");g!==e&&o.has(g)&&p.add(g);return}const w=y[m],_=i[w][t];for(let g=0;g<d;g++){if(g===_)continue;const k=S.slice();if(k[w]={...S[w],[t]:g},c(m+1,k),p.size>=u)return}})(0,i),p.size>=u)break;return[...p]}function vr(e,t){if(!e||!t||e.length!==t.length)return-1;let n=0;for(let o=0;o<e.length;o++){const u=le(e[o]),r=le(t[o]);if(!u||!r)return-1;u.cho!==r.cho&&n++,u.jung!==r.jung&&n++,u.jong!==r.jong&&n++}return n}const Io="word_pair_index_v2",jo="word_pair_index_sig_v2";let Ft=null;function Or(){try{if(typeof localStorage>"u")return null;const e=localStorage.getItem(Io),t=localStorage.getItem(jo);return!e||!t?null:{index:JSON.parse(e),sig:t}}catch{return null}}function Ht(){if(Ft)return Ft;const e=Or();return e?(Ft=e.index,e.sig,Ft):null}function Lr(){Ft=null;try{typeof localStorage<"u"&&(localStorage.removeItem(Io),localStorage.removeItem(jo))}catch{}}const Po="word_image_existence_map_v1";let Bt=null;function $o(){if(Bt)return Bt;try{const e=typeof localStorage<"u"?localStorage.getItem(Po):null;Bt=e?JSON.parse(e):{}}catch{Bt={}}return Bt}function Rr(e,t){return`${e}_${t??1}`}function Ir(e,t){const n=$o(),o=Rr(e,t);return o in n?n[o]:void 0}function Fo(){const e=$o(),t=Object.values(e);return t.length===0?null:{total:t.length,exists:t.filter(Boolean).length}}function jr(){Bt={};try{typeof localStorage<"u"&&localStorage.removeItem(Po)}catch{}}const Ho=[{id:"wordData",labelKey:"settings.cache.group.wordData.label",subKey:"settings.cache.group.wordData.sub",keys:["word_data_cache","word_data_version"]},{id:"pairIndex",labelKey:"settings.cache.group.pairIndex.label",subKey:"settings.cache.group.pairIndex.sub",keys:["word_pair_index_v2","word_pair_index_sig_v2"]},{id:"imageCache",labelKey:"settings.cache.group.imageCache.label",subKey:"settings.cache.group.imageCache.sub",keys:["word_image_existence_map_v1"]}];function zo(e){return e.reduce((t,n)=>{try{const o=localStorage.getItem(n);return t+(o?new Blob([o]).size:0)}catch{return t}},0)}function Pr(e){return e===0?"0 B":e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(1)} KB`:e<1024*1024*1024?`${(e/(1024*1024)).toFixed(2)} MB`:`${(e/(1024*1024*1024)).toFixed(2)} GB`}function $r(e){const{t}=gt.useTranslation(),[n,o]=l.useState({}),[u,r]=l.useState(null),[i,s]=l.useState(null),[d,p]=l.useState(null),f=l.useCallback(()=>{const c={};Ho.forEach(m=>{c[m.id]=zo([...m.keys])}),o(c),typeof navigator<"u"&&navigator.storage?.estimate&&navigator.storage.estimate().then(m=>{p({usage:m.usage??0,quota:m.quota??0})}).catch(()=>{})},[]);l.useEffect(()=>{f()},[f]);const y=l.useCallback(async c=>{r(c);try{c==="wordData"?(localStorage.removeItem("word_data_cache"),localStorage.removeItem("word_data_version")):c==="pairIndex"?Lr():c==="imageCache"&&jr(),f(),e?.(t("settings.cache.cleared","\uCE90\uC2DC\uAC00 \uC0AD\uC81C\uB418\uC5C8\uC2B5\uB2C8\uB2E4."))}finally{r(null)}},[f,e,t]);return{cacheSizes:n,clearingId:u,confirmCacheId:i,setConfirmCacheId:s,storageEstimate:d,refreshCacheSizes:f,handleClearCache:y}}function Fr(e){const[t,n]=l.useState(null),[o,u]=l.useState(null),r=l.useCallback(()=>{const i=Ht();if(i){const d=Object.values(i),p=d.filter(f=>f.cho.length+f.jung.length+f.jong.length>0).length;n({matched:p,total:d.length})}else n(null);const s=Fo();u(s?{exists:s.exists,total:s.total}:null)},[]);return l.useEffect(()=>{r();const i=setTimeout(r,1e3);return()=>clearTimeout(i)},[e?.length,r]),{pairStats:t,imgStats:o,setPairStats:n,setImgStats:u,refreshStats:r}}function Vo(e,t=[]){const[n,o]=l.useState(t),[u,r]=l.useState(null),[i,s]=l.useState(!1),[d,p]=l.useState(e),f=l.useRef(i);l.useEffect(()=>{f.current=i});const y=l.useRef(null);l.useEffect(()=>{if(f.current)return;const g=y.current;g!==null&&g.length===t.length&&g.every((k,A)=>k===t[A])||(y.current=t,o(t))},[t]);const c=l.useCallback(g=>{r(g),s(!1),p({...g})},[]),m=l.useCallback(()=>s(!0),[]),S=l.useCallback(()=>s(!1),[]),w=l.useCallback((g,k)=>{o(g),r(k),s(!1)},[]),_=l.useCallback(g=>{o(k=>k.filter(A=>A!==g)),r(null)},[]);return{list:n,setList:o,selected:u,setSelected:r,isEditing:i,setIsEditing:s,editForm:d,setEditForm:p,openDetail:c,startEditing:m,cancelEditing:S,commitEdit:w,remove:_}}const zt=()=>{const e=new Date;return{year:String(e.getFullYear()),month:String(e.getMonth()+1).padStart(2,"0"),day:String(e.getDate()).padStart(2,"0")}},Hr={year:"",month:"",day:"",hour:"09",minute:"00",memo:""};function zr(e=[]){const{list:t,setList:n,selected:o,setSelected:u,isEditing:r,setIsEditing:i,editForm:s,setEditForm:d,openDetail:p,commitEdit:f}=Vo(Hr,e),{year:y,month:c,day:m}=zt(),[S,w]=l.useState({year:y,month:c,day:m,hour:"09",minute:"00",memo:""});return{visitHistory:t,visitForm:S,setVisitForm:w,setVisit:_=>g=>w(k=>({...k,[_]:g})),selectedVisit:o,setSelectedVisit:u,isEditingVisit:r,setIsEditingVisit:i,editVisitForm:s,setEditVisitForm:d,openVisitDetail:p,handleVisitSave:_=>{n(T=>[S,...T]);const{year:g,month:k,day:A}=zt();w({year:g,month:k,day:A,hour:"09",minute:"00",memo:""}),_?.()},handleVisitEditSave:()=>{f(_=>_.map(g=>g===o?s:g),s)},addVisit:_=>{n(g=>[_,...g])},removeVisit:_=>{n(g=>g.filter(k=>k!==_))},revertVisitEdit:(_,g)=>{n(k=>k.map(A=>A===g?_:A)),u(k=>k===g?_:k)}}}const Uo=e=>`${e.year.padStart(4,"0")}-${e.month.padStart(2,"0")}-${e.day.padStart(2,"0")} ${e.hour.padStart(2,"0")}:${e.minute.padStart(2,"0")}`,Cn=e=>[...e].sort((t,n)=>{const o=Uo(t),u=Uo(n);return o<u?-1:o>u?1:0}),Vr={year:"",month:"",day:"",hour:"09",minute:"00",memo:""};function Ur(e,t=[]){const n=l.useMemo(()=>Cn(t),[t]),{list:o,setList:u,selected:r,setSelected:i,isEditing:s,setIsEditing:d,editForm:p,setEditForm:f,openDetail:y,commitEdit:c,remove:m}=Vo(Vr,n),[S,w]=l.useState([]),{year:_,month:g,day:k}=zt(),[A,T]=l.useState({year:_,month:g,day:k,hour:"09",minute:"00",memo:""}),v=F=>B=>T(O=>({...O,[F]:B})),D=F=>{u(Z=>Cn([...Z,A]));const{year:B,month:O,day:ye}=zt();T({year:B,month:O,day:ye,hour:"09",minute:"00",memo:""}),F?.()},I=()=>{c(F=>Cn(F.map(B=>B===r?p:B)),p)},$=l.useCallback(F=>{m(F)},[m]),G=l.useCallback(F=>{e({year:F.year,month:F.month,day:F.day,hour:F.hour,minute:F.minute,memo:F.memo}),m(F)},[e,m]),P=l.useCallback(F=>{u(B=>B.filter(O=>O!==F)),w(B=>[F,...B]),i(null)},[u,i]),Q=l.useCallback(F=>{u(B=>Cn([...B,F]))},[u]),Y=l.useCallback(F=>{u(B=>B.filter(O=>O!==F))},[u]),W=l.useCallback((F,B)=>{u(O=>O.map(ye=>ye===B?F:ye)),i(O=>O===B?F:O)},[u,i]);return{scheduleList:o,noShowList:S,addSchedule:Q,removeSchedule:Y,revertScheduleEdit:W,scheduleForm:A,setScheduleForm:T,setSchedule:v,selectedSchedule:r,setSelectedSchedule:i,isEditingSchedule:s,setIsEditingSchedule:d,editScheduleForm:p,setEditScheduleForm:f,openScheduleDetail:y,handleScheduleSave:D,handleScheduleEditSave:I,handleScheduleDelete:$,handleScheduleToVisit:G,handleScheduleNoVisit:P}}const Go=[{value:"10",label:"10\uAC1C\uC529 \uBCF4\uAE30"},{value:"25",label:"25\uAC1C\uC529 \uBCF4\uAE30"},{value:"50",label:"50\uAC1C\uC529 \uBCF4\uAE30"},{value:"100",label:"100\uAC1C\uC529 \uBCF4\uAE30"}];function Gr(e){const[t,n]=l.useState(""),[o,u]=l.useState("25"),[r,i]=l.useState("all"),[s,d]=l.useState(1),p=l.useMemo(()=>e.filter(({item:m,status:S})=>!(t&&!m.memo.includes(t)||r!=="all"&&S!==r)),[e,t,r]),f=Math.max(1,Math.ceil(p.length/Number(o))),y=Math.min(s,f),c=l.useMemo(()=>p.slice((y-1)*Number(o),y*Number(o)),[p,y,o]);return{vapSearch:t,setVapSearch:n,vapPageSize:o,setVapPageSize:u,vapStatus:r,setVapStatus:i,vapPage:y,setVapPage:d,vapFiltered:p,vapTotal:f,vapPageItems:c}}function Yr(e,t){const{t:n}=gt.useTranslation(),[o,u]=l.useState("25"),[r,i]=l.useState(1),[s,d]=l.useState(t);s!==t&&(d(t),r!==1&&i(1));const p=l.useMemo(()=>Go.map(m=>({...m,label:n("visits.showN",{n:m.value})})),[n]),f=l.useCallback(m=>{u(m),i(1)},[]),y=Math.max(1,Math.ceil(e.length/Number(o))),c=Math.min(r,y);return{pageRows:l.useMemo(()=>e.slice((c-1)*Number(o),c*Number(o)),[e,c,o]),pageSizeProps:{options:p,value:o,onChange:f},paginationProps:{page:c,total:y,onChange:i},setPage:i}}function qr(){const[e,t]=l.useState(null),n=l.useCallback(u=>{t(r=>r?.key===u?{key:u,asc:!r.asc}:{key:u,asc:!0})},[]),o=l.useCallback((u,r)=>({label:u,sortDir:e?.key===r?e.asc?"asc":"desc":null,onClick:()=>n(r)}),[e,n]);return{\uC815\uB82C:e,\uCE78:o}}function Wr(){const[e,t]=l.useState(!1),[n,o]=l.useState("\uC88C"),[u,r]=l.useState({\uC88C:null,\uC6B0:null}),[i,s]=l.useState({\uC88C:[],\uC6B0:[]}),[d,p]=l.useState(!1),[f,y]=l.useState("\uC88C"),c=l.useCallback(S=>{const w=S.direction;r(_=>({..._,[w]:S})),s(_=>({..._,[w]:[S,..._[w]]})),t(!1)},[]),m=l.useCallback(S=>{const w=S.direction;r(_=>({..._,[w]:S})),p(!1)},[]);return{showDevice:e,setShowDevice:t,deviceDirection:n,setDeviceDirection:o,devices:u,setDevices:r,deviceHistory:i,setDeviceHistory:s,showDeviceList:d,setShowDeviceList:p,listForSide:f,setListForSide:y,handleDeviceSubmit:c,handleSelectFromList:m}}const Kr="__ihab_core_word_pool__";function yn(){return globalThis[Kr]??null}function re(e,t=Math.random){const n=e.slice();for(let o=n.length-1;o>0;o--){const u=Math.floor(t()*(o+1));[n[o],n[u]]=[n[u],n[o]]}return n}function at(e,t,n=Math.random){return!Array.isArray(e)||e.length===0||t<=0?[]:t>=e.length?re(e,n):re(e,n).slice(0,t)}const Fn={SAME_SOUND_PICK:{difficulty:!0,choseong:!0,group:"discrimination"},SAME_OR_DIFF:{difficulty:!0,choseong:!0,group:"discrimination"},HEAR_AND_PICK_SAME:{difficulty:!0,choseong:!0,group:"discrimination"},HEAR_AND_PICK_INCLUDED:{difficulty:!0,choseong:!0,group:"discrimination"},STARTS_WITH_SAME_SOUND:{difficulty:!1,choseong:!0,group:"discrimination"},LISTEN_AND_REMEMBER_ORDER:{difficulty:!1,choseong:!0,group:"attention"},MERGE_2_SYLLABLES:{difficulty:!1,choseong:!0,group:"synthesis"},MERGE_3_SYLLABLES:{difficulty:!1,choseong:!0,group:"synthesis"},MERGE_2_PHONEMES:{difficulty:!1,choseong:!0,group:"synthesis"},MERGE_3_PHONEMES:{difficulty:!1,choseong:!0,group:"synthesis"},DROP_1_FROM_2SYLL:{difficulty:!1,choseong:!0,group:"deletion"},DROP_1_FROM_3SYLL:{difficulty:!1,choseong:!0,group:"deletion"},DROP_PART_FROM_COMPOUND:{difficulty:!1,choseong:!0,group:"deletion"},DROP_FINAL_CONSONANT_FROM_1SYLL:{difficulty:!1,choseong:!0,group:"deletion"},REMOVE_CONSONANT_AND_IDENTIFY_PHONEME:{difficulty:!1,choseong:!0,group:"deletion"},CHANGE_1_SYLL_IN_2SYLL:{difficulty:!0,choseong:!0,group:"substitution"},CHANGE_1_SYLL_IN_3SYLL:{difficulty:!0,choseong:!0,group:"substitution"},CHANGE_1_PHONEME_IN_1SYLL:{difficulty:!1,choseong:!0,group:"substitution"},CHANGE_1_PHONEME_IN_2SYLL:{difficulty:!0,choseong:!0,group:"substitution"}},Xr=ke.indexOf("\u3147"),Yo={DROP_FINAL_CONSONANT_FROM_1SYLL:{syllables:1,syllable:e=>e.jong>0},REMOVE_CONSONANT_AND_IDENTIFY_PHONEME:{syllables:1,syllable:e=>e.jong===0&&e.cho!==Xr},MERGE_2_SYLLABLES:{syllables:2,syllable:()=>!0},MERGE_3_SYLLABLES:{syllables:3,syllable:()=>!0},MERGE_2_PHONEMES:{syllables:1,syllable:e=>e.jong===0},MERGE_3_PHONEMES:{syllables:1,syllable:e=>e.jong>0}},Zr={\u3131:"\u3131",\u3132:"\u3131",\u314B:"\u3131",\u3133:"\u3131",\u313A:"\u3131",\u3134:"\u3134",\u3135:"\u3134",\u3136:"\u3134",\u3137:"\u3137",\u3145:"\u3137",\u3146:"\u3137",\u3148:"\u3137",\u314A:"\u3137",\u314C:"\u3137",\u314E:"\u3137",\u3139:"\u3139",\u313C:"\u3139",\u313D:"\u3139",\u313E:"\u3139",\u3140:"\u3139",\u3141:"\u3141",\u313B:"\u3141",\u3142:"\u3142",\u314D:"\u3142",\u313F:"\u3142",\u3144:"\u3142",\u3147:"\u3147"},Jr={\u314F:{nucleus:"\u314F"},\u3151:{glide:"j",nucleus:"\u314F"},\u3153:{nucleus:"\u3153"},\u3155:{glide:"j",nucleus:"\u3153"},\u3157:{nucleus:"\u3157"},\u315B:{glide:"j",nucleus:"\u3157"},\u315C:{nucleus:"\u315C"},\u3160:{glide:"j",nucleus:"\u315C"},\u3161:{nucleus:"\u3161"},\u3163:{nucleus:"\u3163"},\u3150:{nucleus:"\u3154/\u3150"},\u3152:{glide:"j",nucleus:"\u3154/\u3150"},\u3154:{nucleus:"\u3154/\u3150"},\u3156:{glide:"j",nucleus:"\u3154/\u3150"},\u3158:{glide:"w",nucleus:"\u314F"},\u3159:{glide:"w",nucleus:"\u3154/\u3150"},\u315A:{glide:"w",nucleus:"\u3154/\u3150"},\u315D:{glide:"w",nucleus:"\u3153"},\u315E:{glide:"w",nucleus:"\u3154/\u3150"},\u315F:{glide:"w",nucleus:"\u3163"},\u3162:{glide:"\u0270",nucleus:"\u3163"}};function qo(e){return Zr[e]??e}const Hn={cho:ke,jung:rt,jong:Fe},_e=e=>Array.isArray(e)?e.length>0:!!e;function zn(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++){const o=e[n],u=t[n];if(!(!o||!u)&&(o.cho!==u.cho&&ke[o.cho]==="\u3147"!=(ke[u.cho]==="\u3147")||o.jong!==u.jong&&o.jong===0!=(u.jong===0)))return!0}return!1}function Qr(e,t,n){const o=n.pronOf(e),u=n.decompOf,r=n.sameStructureOnly&&u?u(o):null,i=[];for(const s of t)s!==e&&(n.okSet&&!n.okSet.has(s)||n.pronOf(s)!==o&&(r&&u&&zn(r,u(n.pronOf(s)))||i.push(s)));return i}function Wo(e,t,n){const o=t?.[e];if(!o)return[];const u=n.kind?o[n.kind]??[]:[...o.cho??[],...o.jung??[],...o.jong??[]];return Qr(e,u,n)}function ea(e,t,n,o,u,r,i){const s=["cho","jung","jong"].filter(c=>_e(e[c])),d={};for(const c of s){const m=e[c];d[c]=new Set(Array.isArray(m)?m:[m])}const p=u==="pron",f=new Map;for(const c of t){const m=n(r(c));if(m.some(g=>!g))continue;let S=m;if(!p&&(S=n(c),S.length!==m.length||S.some(g=>!g)))continue;const w=m.length,_=f.get(w);_?_.push({w:c,dPron:m,dPos:S}):f.set(w,[{w:c,dPron:m,dPos:S}])}const y=new Map;for(const[c,m]of f){const S=new Map,w=(_,g)=>{const k=_.dPos[g];return k!=null&&s.every(A=>d[A].has(Hn[A][k[A]]))};for(const _ of m){let g;if(i==="head")g=w(_,0)?0:-1;else if(i==="tail")g=w(_,c-1)?c-1:-1;else if(i==="mid"){g=-1;for(let A=1;A<c-1;A++)if(w(_,A)){g=A;break}}else g=_.dPos.findIndex(A=>A!=null&&s.every(T=>d[T].has(Hn[T][A[T]])));if(g<0)continue;const k=S.get(g);k?k.push(_):S.set(g,[_])}for(const[_,g]of S){const k=new Set(s.map(v=>_+":"+v)),A=v=>{let D="";for(let I=0;I<c;I++){const $=v[I];for(const G of["cho","jung","jong"])D+=(k.has(I+":"+G)?"*":$[G])+"."}return D},T=new Map;for(const v of m){const D=A(v.dPron),I=T.get(D);I?I.push(v):T.set(D,[v])}for(const v of g){const D=T.get(A(v.dPron))??[],I=[];for(const $ of D){if($.w===v.w)continue;let G=!0;for(const P of s){const Q=v.dPron[_][P],Y=$.dPron[_][P];if(Y===Q){G=!1;break}if(p&&d[P].has(Hn[P][Y])){G=!1;break}}G&&(o&&zn(v.dPron,$.dPron)||I.push($.w))}y.set(v.w,I)}}}return y}const ta=e=>e==null?[]:Array.isArray(e)?e:[e];function na(e){if([...e].length!==1)return"";const t=le(e);if(!t)return"";const n=qo(Fe[t.jong]),o=n===""?0:Fe.indexOf(n);return _t(t.cho,t.jung,o<0?0:o)}function Ko(e,t){return t.get(e)||na(e)||e}function Vn(e){return e?_e(e.cho)?"cho":_e(e.jung)?"jung":_e(e.jong)?"jong":null:null}function Dt(e,t){const n=(o,u)=>!_e(o)||ta(o).includes(u);return n(t.cho,ke[e.cho])&&n(t.jung,rt[e.jung])&&n(t.jong,Fe[e.jong])}function Vt(e,t,n){const o=[...e];if(n!=="pron")return o.map(r=>le(r));const u=[...t.get(e)||e];return u.length!==o.length?o.map(r=>le(r)):u.map(r=>le(r))}function Ut(e,t,n,o,u){const r=t==="cho"?ke:t==="jung"?rt:Fe,i=e[t],s=[],d=new Set([Ko(n,u)]),p=re(r.map((f,y)=>y).filter(f=>f!==i&&(t!=="cho"||r[f]!=="\u3147")&&(t!=="jong"||f!==0)));for(const f of p){if(s.length>=o)break;const y=t==="cho"?_t(f,e.jung,e.jong):t==="jung"?_t(e.cho,f,e.jong):_t(e.cho,e.jung,f),c=Ko(y,u);d.has(c)||(d.add(c),s.push(y))}return s}function oa(e,t,n,o,u,r=null){const i=[...e];if(i.length!==2)return null;const s=i.map(y=>le(y));if(s.some(y=>!y))return null;const d=Vt(e,n,o);if(d.some(y=>!y))return null;const p=Vn(t);let f=p&&t?d.map((y,c)=>Dt(y,t)?c:-1).filter(y=>y>=0):[0,1];if(r!=null&&(f=f.filter(y=>y!==r)),!f.length)return null;for(const y of re(f)){const c=i[y];if(!u.has(c))continue;const m=Ut(s[y],p??"cho",c,40,n),S=[];for(const w of m)if(w!==c&&u.has(w)&&!S.includes(w)&&S.push(w),S.length>=2)break;if(!(S.length<2))return{question:e,distractors:[c,...S]}}return null}function ua(e,t,n,o,u,r=null){const i=[...e];if(i.length!==3)return null;const s=i.map(y=>le(y));if(s.some(y=>!y))return null;const d=Vt(e,n,o);if(d.some(y=>!y))return null;const p=Vn(t),f=p&&t?d.map((y,c)=>Dt(y,t)?c:-1).filter(y=>y>=0):[0,1,2];if(!f.length)return null;for(const y of re(f))for(const c of re([0,1,2].filter(m=>m!==y&&(r==null||m===r)))){const m=[0,1,2].filter(k=>k!==c),S=m.map(k=>i[k]).join("");if(!u.has(S))continue;const w=m.indexOf(y),_=Ut(s[y],p??"cho",i[y],40,n),g=[];for(const k of _){const A=m.map(v=>i[v]);A[w]=k;const T=A.join("");if(T!==S&&u.has(T)&&!g.includes(T)&&g.push(T),g.length>=2)break}if(!(g.length<2))return{question:e,distractors:[S,...g]}}return null}function ra(e,t,n,o,u,r=null){const i=[...e],s=i.length;if(s<2)return null;const d=[];for(let f=1;f<=s-1;f++)d.push({remain:i.slice(0,f).join(""),dropped:i.slice(f).join(""),droppedEnd:1}),d.push({remain:i.slice(s-f).join(""),dropped:i.slice(0,s-f).join(""),droppedEnd:0});const p=Vn(t);for(const{remain:f,dropped:y,droppedEnd:c}of re(d)){if(r!=null&&c!==r||f===e||!u.has(f)||!u.has(y))continue;const m=[...f],S=m.map(g=>le(g));if(S.some(g=>!g))continue;const w=Vt(f,n,o);if(w.some(g=>!g))continue;const _=p&&t?w.map((g,k)=>Dt(g,t)?k:-1).filter(g=>g>=0):m.map((g,k)=>k);if(_.length)for(const g of re(_)){const k=Ut(S[g],p??"cho",m[g],40,n),A=[];for(const T of k){const v=[...m];v[g]=T;const D=v.join("");if(D!==f&&u.has(D)&&!A.includes(D)&&A.push(D),A.length>=2)break}if(A.length>=2)return{question:e,distractors:[f,...A]}}}return null}function aa(e,t,n,o,u,r=null){if([...e].length!==1)return null;const i=le(n.get(e)||e);if(!i||i.jong===0)return null;const s=_t(i.cho,i.jung,0),d=Ut({cho:i.cho,jung:i.jung,jong:0},"cho",s,2,n);return d.length<2?null:{question:e,distractors:[s,...d]}}const Un=ke.indexOf("\u3147");function ia(e,t,n,o,u,r=null){if([...e].length!==1)return null;const i=le(n.get(e)||e);if(!i||i.jong!==0||i.cho===Un)return null;const s=_t(Un,i.jung,0),d=Ut({cho:Un,jung:i.jung,jong:0},"jung",s,2,n);return d.length<2?null:{question:e,distractors:[s,...d]}}function sa(e){const t=new Map;for(const n of e){const o=[...n],u=o.length;if(!(u<2||u>3))for(let r=0;r<u;r++){let i=u+"|"+r+"|";for(let d=0;d<u;d++)i+=d===r?"*":o[d];const s=t.get(i);s?s.push(n):t.set(i,[n])}}return t}function la(e,t,n,o,u,r=null,i=null,s=2){const d=[...e],p=d.length;if(p<2||p>3)return null;const f=d.map(k=>le(k));if(f.some(k=>!k))return null;const y=Vt(e,n,o);if(y.some(k=>!k))return null;const c=k=>n.get(k)??k,m=c(e),S=!!t&&(_e(t.cho)||_e(t.jung)||_e(t.jong)),w=!!i&&(_e(i.cho)||_e(i.jung)||_e(i.jong)),_=k=>{let A=p+"|"+k+"|";for(let T=0;T<p;T++)A+=T===k?"*":d[T];return A};let g;if(r!=null){if(r>=p||S&&!Dt(y[r],t))return null;g=[r]}else S?g=y.map((k,A)=>Dt(k,t)?A:-1).filter(k=>k>=0):g=Array.from({length:p},(k,A)=>A);for(const k of re(g)){const A=u.get(_(k))??[],T=[],v=[];for(const P of A){if(P===e)continue;const Q=[...P].map(B=>le(B)),Y=f[k],W=Q[k];if(!Y||!W)continue;let F=0;if(Y.cho!==W.cho&&F++,Y.jung!==W.jung&&F++,Y.jong!==W.jong&&F++,!(F<s||c(P)===m))if(w){const B=Vt(P,n,o)[k];B&&Dt(B,i)?T.push(P):v.push(P)}else T.push(P)}if(!T.length)continue;const D=re(T)[0],I=[],$=new Set([m,c(D)]),G=w?v:T.filter(P=>P!==D);for(const P of re(G)){const Q=c(P);if(!$.has(Q)&&($.add(Q),I.push(P),I.length>=2))break}if(!w&&I.length<2)for(const P of re(A)){if(P===e||P===D)continue;const Q=c(P);if(!$.has(Q)&&($.add(Q),I.push(P),I.length>=2))break}if(!(I.length<2))return{question:e,distractors:[D,...I]}}return null}let mn=null,Xo=null,Zo=null;function ca(){const e=yn();if(e&&e.entries.length>0){const t=Ht();if(mn&&Xo===e&&Zo===t)return mn;const n=new Set,o=[];for(const u of e.entries)!u.word||n.has(u.word)||(n.add(u.word),o.push({w:u.word,s:u.syllables,p:t?.[u.word]?[...t[u.word].cho??[],...t[u.word].jung??[],...t[u.word].jong??[]]:[],pron:u.pronunciation||u.word,grade:u.grade}));return mn=o,Xo=e,Zo=t,mn}return[]}const Ge=new Proxy([],{get(e,t){const n=ca(),o=n[t];return typeof o=="function"?o.bind(n):o}});function gn(e){return e.length?e[Math.floor(Math.random()*e.length)]:void 0}function Ye(e,t){if(t>=e.length)return re(e);if(t===0)return[];const n=e.slice();for(let o=0;o<t;o++){const u=o+Math.floor(Math.random()*(n.length-o)),r=n[o];n[o]=n[u],n[u]=r}return n.slice(0,t)}let Gn=null,Jo=null;function Et(){const e=yn();if(Gn&&Jo===e)return Gn;const t=new Map;for(const n of Ge)n.w&&t.set(n.w,n.pron);return Gn=t,Jo=e,t}function Oe(e){return Et().get(e)||e}function Yn(e,t,n=new Set){const o=[];for(const u of re(e)){if(o.length>=t)break;const r=Oe(u);n.has(r)||(n.add(r),o.push(u))}return o}let da=0;function Ae(e){return`${e}-rt-${++da}`}function Gt(e){const t=Fo();if(!t||t.total===0){const o=new Set;for(const u of e)o.add(u);return o}const n=new Set;for(const o of e)Ir(o)===!0&&n.add(o);return n}const _n=new Map;let Qo=null,eu=null;function Yt(e){return e==null?"":Array.isArray(e)?e.slice().sort().join(","):e}function tu(e){const t=Yt(e.choseong),n=e.composition,o=n?.syllable==null?"":Array.isArray(n.syllable)?n.syllable.slice().sort().join(","):String(n.syllable),u=n?`${Yt(n.cho)}/${Yt(n.jung)}/${Yt(n.jong)}/${n.jongNone?"N":""}/${o}`:"",r=Yt(e.grade);return`${e.difficulty??""}|${t}|${u}|${e.excludeNoImage?"1":"0"}|${e.count??""}|x${e.contrastCount??1}|${e.fullCount?"F":""}|s${e.sameStructureOnly===!1?"0":"1"}|v${e.phonemeView==="pron"?"p":"c"}|g${r}|t${e.targetSyllable??""}|c${e.choicesPerItem??""}`}async function Le(e){const t=yn(),n=Ht();(t!==Qo||n!==eu)&&(_n.clear(),Qo=t,eu=n);const o=tu(e);return _n.has(o)||_n.set(o,fa(e)),_n.get(o)}function ha(e){if(!e)return null;const t=i=>i==null?null:Array.isArray(i)?i.length?i:null:[i],n=t(e.cho),o=t(e.jung),u=!!e.jongNone,r=u?null:t(e.jong);return n||o||r||u?u&&!n&&!o&&!r?i=>Nr(i):i=>xr(i,{cho:n,jung:o,jong:r,jongNone:u}):null}async function fa(e){const{difficulty:t=null,choseong:n=null,composition:o=null,targetSyllable:u=null,excludeNoImage:r=!1}=e,i=e.grade&&e.grade.length>0?new Set(e.grade):null,s=e.sameStructureOnly??!0,d=e.phonemeView==="pron"?"pron":"char",p=Math.max(1,e.contrastCount??1),f=t==="cho"||t==="jung"||t==="jong",y=f&&p>=2,c=t==="count",m=n?new Set(Array.isArray(n)?n:[n]):null,S=o?.syllable!=null?new Set(Array.isArray(o.syllable)?o.syllable:[o.syllable]):null,w=o?[ha(o),S?M=>S.has(pn(M)):null].filter(M=>M!=null):[],_=t==="random"||t===null,g=_||c,k=_||y||c;let A=Ge.filter(M=>!M.w||i&&(!M.grade||!i.has(M.grade))?!1:k?!0:Array.isArray(M.p)&&M.p.length>0);m&&(A=A.filter(M=>{for(const j of m)if(Mr(M.w,j))return!0;return!1})),w.length>0&&(A=A.filter(M=>{const j=d==="pron"?Oe(M.w):M.w;return w.every(ae=>ae(j))})),u&&(A=A.filter(M=>M.w[0]===u));let T;if(r){const M=new Set;for(const j of A)if(M.add(j.w),Array.isArray(j.p))for(const ae of j.p)M.add(ae);if(g)for(const j of Ge)j.w&&M.add(j.w);T=Gt(M)}else{const M=new Set;for(const j of A)if(M.add(j.w),Array.isArray(j.p))for(const ae of j.p)M.add(ae);if(g)for(const j of Ge)j.w&&M.add(j.w);T=M}let v=null;if(y){const M=new Set;for(const j of Ge)j.w&&M.add(j.w);v=r?Gt(M):M}const D=A.filter(M=>T.has(M.w)),I=600,$=Array.from(T),G=$.length>I?Ye($,I):$,P=c&&o!=null&&(_e(o.cho)||_e(o.jung)||_e(o.jong)),Q=2500,Y=new Map;if(c&&!P&&p>=2){for(const M of $){const j=pn(M),ae=Y.get(j);ae?ae.push(M):Y.set(j,[M])}for(const[M,j]of Y)j.length>Q&&Y.set(M,Ye(j,Q))}const W=Ar(),F=P?ea(o,$,W,s,d,Oe):null,B=500,O=1500,ye=e.fullCount?D:t==="random"?D.length>B?Ye(D,B):D:D.length>O?Ye(D,O):D,Z=Ht(),ee=[];for(const M of ye){let j;const ae=Oe(M.w);if(y)j=Dr(M.w,t,p,v,24).filter(ne=>Oe(ne)!==ae);else if(c)P?j=(F.get(M.w)??[]).filter(ne=>Oe(ne)!==ae):p<=1?j=Wo(M.w,Z,{okSet:T,pronOf:Oe,decompOf:W,sameStructureOnly:!1}):j=(Y.get(pn(M.w))??[]).filter(ne=>{if(ne===M.w||Oe(ne)===ae)return!1;const q=vr(M.w,ne);return p>=5?q>=5:q===p});else if(_)j=G.filter(ne=>ne!==M.w&&ne.length===M.w.length&&Oe(ne)!==ae);else{const ne=t;j=Wo(M.w,Z,{kind:ne,okSet:T,pronOf:Oe,decompOf:W,sameStructureOnly:!1}),j.length===0&&(j=(G.length>30?Ye(G,30):G).filter(q=>q!==M.w&&wr(M.w,q)===t&&Oe(q)!==ae))}if(s&&j.length>0&&(f||c&&!P)){const ne=W(Oe(M.w));j=j.filter(q=>!zn(ne,W(Oe(q))))}j.length!==0&&ee.push({word:M,usable:j})}return ee}async function nu(e,t){const{choicesPerItem:n=3,count:o=10}=t,u=n-1,r=(await Le(t)).filter(s=>s.usable.length>=u),i=[];for(const s of re(r)){if(i.length>=o)break;const d=Yn(s.usable,u);if(d.length<u)continue;const p=re([s.word.w,...d]);i.push({id:Ae(e+"-item"),index:i.length+1,word:s.word.w,syllables:s.word.s,choices:p,answerIndex:p.indexOf(s.word.w)})}return i}async function pa(e){const{choicesPerItem:t=3,count:n=10}=e,o=t-1,u=await Le({...e,difficulty:null});if(u.length<t)return[];const r=[],i=re([...u]);for(const s of i){if(r.length>=n)break;const d=s.word.w,p=[...s.word.pron||d],f=gn(p);if(!f)continue;const y=u.filter(S=>S.word.w!==d&&S.word.s===s.word.s&&!(S.word.pron||S.word.w).includes(f)&&S.word.pron!==s.word.pron);if(y.length<o)continue;const c=Yn(y.map(S=>S.word.w),o);if(c.length<o)continue;const m=re([d,...c]);r.push({id:Ae("HPI-item"),index:r.length+1,targetSyllable:f,word:d,choices:m,answerIndex:m.indexOf(d)})}return r}async function Ca(e){const{count:t=10}=e,n=(await Le(e)).filter(o=>o.usable.length>=1);return Array.from({length:t},(o,u)=>{const r=gn(n);if(!r)return null;const i=u%2===0;let s;if(i)s=[r.word.w,r.word.w];else{const d=gn(r.usable);s=Math.random()<.5?[r.word.w,d]:[d,r.word.w]}return{id:Ae("SOD-item"),index:u+1,word:r.word.w,pair:s,same:i}}).filter(o=>!!o)}async function ya(e){const{choicesPerItem:t=3,count:n=10}=e,o=t-1,u=await Le({...e,difficulty:null});if(u.length<t+1)return[];const r=u.map(c=>c.word.w),i=new Map(u.map(c=>[c.word.w,c.word.pron])),s=c=>(i.get(c)||c)[0]??"",d={};for(const c of u){const m=s(c.word.w);m&&(d[m]||(d[m]=[]),d[m].push(c.word.w))}const p=Object.entries(d).filter(([,c])=>c.length>=2).map(([c])=>c);if(p.length===0)return[];const f=[],y=re([...p]);for(let c=0;f.length<n&&c<n*4;c++){const m=y[c%y.length],S=d[m];if(S.length<2)continue;const w=re([...S]),_=w[0],g=w[1];if(!_||!g||_===g||(i.get(_)||_)===(i.get(g)||g))continue;const k=i.get(g)||g,A=r.filter(D=>s(D)!==m&&D!==_&&D!==g&&D.length===g.length&&(i.get(D)||D)!==k);if(A.length<o)continue;const T=Yn(A,o);if(T.length<o)continue;const v=re([g,...T]);f.push({id:Ae("SWS-item"),index:f.length+1,sourceWord:_,targetSyllable:m,word:g,choices:v,answerIndex:v.indexOf(g)})}return f}function ou(e,t,n){return Ye(e,t).map((o,u)=>{const r=gn(o.usable)??"",i=[...o.word.w],s=[...r],d=i.findIndex((f,y)=>f!==s[y]),p=re(o.usable.filter(f=>f&&f!==r)).slice(0,2);return{id:Ae(n),index:u+1,word:o.word.w,original:o.word.w,changed:r,changedFrom:d>=0?i[d]:"",changedTo:d>=0?s[d]:"",distractors:p}})}async function uu(e,t,n){const{count:o=10}=t,u=Et(),r=Ge.filter(m=>m.w&&m.s===e),i=t.excludeNoImage?Gt(r.map(m=>m.w)):null,s=i?r.filter(m=>i.has(m.w)):r,d=new Set(s.map(m=>m.w)),p=sa(d),f=t.phonemeView??"char",y=t.composition??null,c=[];for(const m of re(s)){if(c.length>=o)break;const S=la(m.w,y,u,f,p,null,null);if(!S)continue;const w=S.distractors[0],_=[...m.w],g=[...w],k=_.findIndex((A,T)=>A!==g[T]);c.push({id:Ae(n),index:c.length+1,word:m.w,original:m.w,changed:w,changedFrom:k>=0?_[k]:"",changedTo:k>=0?g[k]:"",distractors:S.distractors.slice(1)})}return c}async function ma(e){return uu(2,e,"CS2-item")}async function ga(e){return uu(3,e,"CS3-item")}async function _a(e){const t=(await Le({...e,difficulty:"count",contrastCount:1})).filter(n=>n.word.s===1&&n.usable.length>=1);return ou(t,e.count??10,"CP1-item")}async function Ea(e){const t=e.difficulty&&e.difficulty!=="random"?e.difficulty:"count",n=(await Le({...e,difficulty:t,contrastCount:1})).filter(o=>o.word.s===2&&o.usable.length>=1);return ou(n,e.count??10,"CP2-item")}async function ba(e){const{count:t=10}=e,n=(await Le({...e})).filter(o=>o.word.s===2);return Ye(n,t).map((o,u)=>({id:Ae("M2S-item"),index:u+1,word:o.word.w,answer:o.word.w,parts:[...o.word.w]}))}async function Sa(e){const{count:t=10}=e,n=(await Le({...e})).filter(o=>o.word.s===3);return Ye(n,t).map((o,u)=>({id:Ae("M3S-item"),index:u+1,word:o.word.w,answer:o.word.w,parts:[...o.word.w]}))}async function ka(e){const{count:t=10}=e,n=(await Le({...e})).filter(s=>s.word.s===2),o=Et(),u=new Set(Ge.map(s=>s.w)),r=e.phonemeView??"char",i=[];for(const s of re(n)){if(i.length>=t)break;const d=oa(s.word.w,e.composition??null,o,r,u);if(!d)continue;const[p,...f]=d.distractors,y=[...s.word.w],c=y[0]===p?y[1]:y[0];i.push({id:Ae("D2-item"),index:i.length+1,original:s.word.w,word:s.word.w,dropped:c,missingResult:p,distractors:f})}return i}async function Aa(e){const{count:t=10}=e,n=(await Le({...e})).filter(s=>s.word.s===3),o=Et(),u=new Set(Ge.map(s=>s.w)),r=e.phonemeView??"char",i=[];for(const s of re(n)){if(i.length>=t)break;const d=ua(s.word.w,e.composition??null,o,r,u);if(!d)continue;const[p,...f]=d.distractors,y=[...s.word.w];let c="";for(let m=0;m<y.length;m++)if(y.filter((S,w)=>w!==m).join("")===p){c=y[m];break}i.push({id:Ae("D3-item"),index:i.length+1,original:s.word.w,word:s.word.w,dropped:c,missingResult:p,distractors:f})}return i}async function wa(e){const{count:t=10}=e,n=(await Le({...e})).filter(s=>s.word.s>=2),o=Et(),u=new Set(Ge.map(s=>s.w)),r=e.phonemeView??"char",i=[];for(const s of re(n)){if(i.length>=t)break;const d=ra(s.word.w,e.composition??null,o,r,u);if(!d)continue;const[p,...f]=d.distractors,y=s.word.w,c=y.startsWith(p)?y.slice(p.length):y.endsWith(p)?y.slice(0,y.length-p.length):"";i.push({id:Ae("DPC-item"),index:i.length+1,original:y,word:y,dropped:c,missingResult:p,distractors:f})}return i}async function Ma(e){const{count:t=10}=e,n=(await Le({...e})).map(o=>o.word.w);return n.length<3?[]:Array.from({length:t},(o,u)=>{const r=Ye(n,3);return{id:Ae("LRO-item"),index:u+1,sequence:r,choices:re(r)}})}function En(e,t,n){const o=Ge.filter(i=>i.w&&i.s===e),u=t?Gt(o.map(i=>i.w)):null,r=[];for(const i of o)if(!(u&&!u.has(i.w))){if(n){const s=le(i.w);if(!s||!n(s))continue}r.push(i)}return r}function Na(e){const t=En(1,e.excludeNoImage??!1,n=>n.jong===0);return Ye(t,e.count??10).map((n,o)=>{const u=le(n.w);return{id:Ae("M2P-item"),index:o+1,parts:[ke[u.cho],rt[u.jung]],answer:n.w,word:n.w}})}function Ta(e){const t=En(1,e.excludeNoImage??!1,n=>n.jong>0&&!$t[n.jong]);return Ye(t,e.count??10).map((n,o)=>{const u=le(n.w);return{id:Ae("M3P-item"),index:o+1,parts:[ke[u.cho],rt[u.jung],Fe[u.jong]],answer:n.w,word:n.w}})}function xa(e){const t=Yo.DROP_FINAL_CONSONANT_FROM_1SYLL,n=En(t.syllables,e.excludeNoImage??!1,t.syllable),o=Et(),u=[];for(const r of re(n)){if(u.length>=(e.count??10))break;const i=aa(r.w,null,o);if(!i)continue;const[s,...d]=i.distractors;u.push({id:Ae("DFC-item"),index:u.length+1,original:r.w,word:r.w,result:s,distractors:d})}return u}function Ba(e){const t=Yo.REMOVE_CONSONANT_AND_IDENTIFY_PHONEME,n=En(t.syllables,e.excludeNoImage??!1,t.syllable),o=Et(),u=[];for(const r of re(n)){if(u.length>=(e.count??10))break;const i=ia(r.w,null,o);if(!i)continue;const s=le(o.get(r.w)||r.w);if(!s)continue;const[d,...p]=i.distractors;u.push({id:Ae("RCP-item"),index:u.length+1,base:r.w,word:r.w,missingConsonant:ke[s.cho],remaining:d,distractors:p})}return u}const bn=new Map;let ru=null,au=null;async function iu(e,t={}){const n=yn(),o=Ht();(n!==ru||o!==au)&&(bn.clear(),ru=n,au=o);const u=`${e}:${tu(t)}`;if(bn.has(u))return bn.get(u);const r=await va(e,t);return bn.set(u,r),r}const Da={SAME_SOUND_PICK:e=>nu("SSP",e),HEAR_AND_PICK_SAME:e=>nu("HPS",e),HEAR_AND_PICK_INCLUDED:e=>pa(e),SAME_OR_DIFF:e=>Ca(e),STARTS_WITH_SAME_SOUND:e=>ya(e),LISTEN_AND_REMEMBER_ORDER:e=>Ma(e),MERGE_2_SYLLABLES:e=>ba(e),MERGE_3_SYLLABLES:e=>Sa(e),MERGE_2_PHONEMES:e=>Na(e),MERGE_3_PHONEMES:e=>Ta(e),DROP_1_FROM_2SYLL:e=>ka(e),DROP_1_FROM_3SYLL:e=>Aa(e),DROP_PART_FROM_COMPOUND:e=>wa(e),DROP_FINAL_CONSONANT_FROM_1SYLL:e=>xa(e),REMOVE_CONSONANT_AND_IDENTIFY_PHONEME:e=>Ba(e),CHANGE_1_SYLL_IN_2SYLL:e=>ma(e),CHANGE_1_SYLL_IN_3SYLL:e=>ga(e),CHANGE_1_PHONEME_IN_1SYLL:e=>_a(e),CHANGE_1_PHONEME_IN_2SYLL:e=>Ea(e)};async function va(e,t={}){const n=Da[e];return n?await n(t):[]}async function Oa(e){const t=[null,"count"],n=Object.keys(Fn);let o=0;for(const u of t)for(const r of n){const i=Fn[r];iu(r,{difficulty:i.difficulty?u:null,choseong:null,count:10,excludeNoImage:e}).catch(()=>{}),++o%6===0&&await new Promise(s=>setTimeout(s,0))}}async function La(e){return(await Le({...e,fullCount:!0})).length}async function Ra(e={}){const t=[];for(const s of Ge)s.w&&t.push(s.w);const n=e.excludeNoImage?Gt(t):t,o=new Set,u=new Set,r=new Set,i=new Set;for(const s of n){i.add(pn(s));for(const d of s){const p=le(d);if(p&&(ke[p.cho]!=="\u3147"&&o.add(ke[p.cho]),u.add(rt[p.jung]),p.jong>0)){r.add(Fe[p.jong]);const f=$t[p.jong];f&&f.forEach(y=>r.add(y))}}}return{cho:o,jung:u,jong:r,syllable:i}}const bt="\uC804\uCCB4";function Ia(...e){return e.filter(Boolean).join(" ")}const ja=(()=>{try{const e=globalThis;return e.process!=null&&e.process.env?.NODE_ENV!=="production"}catch{return!1}})();/**
2
- * @license lucide-react v1.38.0 - ISC
3
- *
4
- * This source code is licensed under the ISC license.
5
- * See the LICENSE file in the root directory of this source tree.
6
- */const su=(...e)=>e.filter((t,n,o)=>!!t&&t.trim()!==""&&o.indexOf(t)===n).join(" ").trim();/**
7
- * @license lucide-react v1.38.0 - ISC
8
- *
9
- * This source code is licensed under the ISC license.
10
- * See the LICENSE file in the root directory of this source tree.
11
- */const Pa=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/**
12
- * @license lucide-react v1.38.0 - ISC
13
- *
14
- * This source code is licensed under the ISC license.
15
- * See the LICENSE file in the root directory of this source tree.
16
- */const $a=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,o)=>o?o.toUpperCase():n.toLowerCase());/**
17
- * @license lucide-react v1.38.0 - ISC
18
- *
19
- * This source code is licensed under the ISC license.
20
- * See the LICENSE file in the root directory of this source tree.
21
- */const lu=e=>{const t=$a(e);return t.charAt(0).toUpperCase()+t.slice(1)};/**
22
- * @license lucide-react v1.38.0 - ISC
23
- *
24
- * This source code is licensed under the ISC license.
25
- * See the LICENSE file in the root directory of this source tree.
26
- */var qn={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
27
- * @license lucide-react v1.38.0 - ISC
28
- *
29
- * This source code is licensed under the ISC license.
30
- * See the LICENSE file in the root directory of this source tree.
31
- */const Fa=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0;return!1},Ha=l.createContext({}),za=()=>l.useContext(Ha),Va=l.forwardRef(({color:e,size:t,strokeWidth:n,absoluteStrokeWidth:o,className:u="",children:r,iconNode:i,...s},d)=>{const{size:p=24,strokeWidth:f=2,absoluteStrokeWidth:y=!1,color:c="currentColor",className:m=""}=za()??{},S=o??y?Number(n??f)*24/Number(t??p):n??f;return l.createElement("svg",{ref:d,...qn,width:t??p??qn.width,height:t??p??qn.height,stroke:e??c,strokeWidth:S,className:su("lucide",m,u),...!r&&!Fa(s)&&{"aria-hidden":"true"},...s},[...i.map(([w,_])=>l.createElement(w,_)),...Array.isArray(r)?r:[r]])});/**
32
- * @license lucide-react v1.38.0 - ISC
33
- *
34
- * This source code is licensed under the ISC license.
35
- * See the LICENSE file in the root directory of this source tree.
36
- */const C=(e,t)=>{const n=l.forwardRef(({className:o,...u},r)=>l.createElement(Va,{ref:r,iconNode:t,className:su(`lucide-${Pa(lu(e))}`,`lucide-${e}`,o),...u}));return n.displayName=lu(e),n};/**
37
- * @license lucide-react v1.38.0 - ISC
38
- *
39
- * This source code is licensed under the ISC license.
40
- * See the LICENSE file in the root directory of this source tree.
41
- */const Ua=[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]],cu=C("triangle-alert",Ua);/**
42
- * @license lucide-react v1.38.0 - ISC
43
- *
44
- * This source code is licensed under the ISC license.
45
- * See the LICENSE file in the root directory of this source tree.
46
- */const Ga=[["rect",{width:"9",height:"6",x:"6",y:"14",rx:"2",key:"lpm2y7"}],["rect",{width:"16",height:"6",x:"6",y:"4",rx:"2",key:"rdj6ps"}],["path",{d:"M2 2v20",key:"1ivd8o"}]],Ya=C("align-start-vertical",Ga);/**
47
- * @license lucide-react v1.38.0 - ISC
48
- *
49
- * This source code is licensed under the ISC license.
50
- * See the LICENSE file in the root directory of this source tree.
51
- */const qa=[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]],Wa=C("arrow-down",qa);/**
52
- * @license lucide-react v1.38.0 - ISC
53
- *
54
- * This source code is licensed under the ISC license.
55
- * See the LICENSE file in the root directory of this source tree.
56
- */const Ka=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],Xa=C("arrow-left",Ka);/**
57
- * @license lucide-react v1.38.0 - ISC
58
- *
59
- * This source code is licensed under the ISC license.
60
- * See the LICENSE file in the root directory of this source tree.
61
- */const Za=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],Ja=C("arrow-right",Za);/**
62
- * @license lucide-react v1.38.0 - ISC
63
- *
64
- * This source code is licensed under the ISC license.
65
- * See the LICENSE file in the root directory of this source tree.
66
- */const Qa=[["path",{d:"m16 3 4 4-4 4",key:"1x1c3m"}],["path",{d:"M20 7H4",key:"zbl0bi"}],["path",{d:"m8 21-4-4 4-4",key:"h9nckh"}],["path",{d:"M4 17h16",key:"g4d7ey"}]],ei=C("arrow-right-left",Qa);/**
67
- * @license lucide-react v1.38.0 - ISC
68
- *
69
- * This source code is licensed under the ISC license.
70
- * See the LICENSE file in the root directory of this source tree.
71
- */const ti=[["path",{d:"M2 10v3",key:"1fnikh"}],["path",{d:"M6 6v11",key:"11sgs0"}],["path",{d:"M10 3v18",key:"yhl04a"}],["path",{d:"M14 8v7",key:"3a1oy3"}],["path",{d:"M18 5v13",key:"123xd1"}],["path",{d:"M22 10v3",key:"154ddg"}]],ni=C("audio-lines",ti);/**
72
- * @license lucide-react v1.38.0 - ISC
73
- *
74
- * This source code is licensed under the ISC license.
75
- * See the LICENSE file in the root directory of this source tree.
76
- */const oi=[["path",{d:"M10 16c.5.3 1.2.5 2 .5s1.5-.2 2-.5",key:"1u7htd"}],["path",{d:"M15 12h.01",key:"1k8ypt"}],["path",{d:"M19.38 6.813A9 9 0 0 1 20.8 10.2a2 2 0 0 1 0 3.6 9 9 0 0 1-17.6 0 2 2 0 0 1 0-3.6A9 9 0 0 1 12 3c2 0 3.5 1.1 3.5 2.5s-.9 2.5-2 2.5c-.8 0-1.5-.4-1.5-1",key:"11xh7x"}],["path",{d:"M9 12h.01",key:"157uk2"}]],ui=C("baby",oi);/**
77
- * @license lucide-react v1.38.0 - ISC
78
- *
79
- * This source code is licensed under the ISC license.
80
- * See the LICENSE file in the root directory of this source tree.
81
- */const ri=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M4.929 4.929 19.07 19.071",key:"196cmz"}]],ai=C("ban",ri);/**
82
- * @license lucide-react v1.38.0 - ISC
83
- *
84
- * This source code is licensed under the ISC license.
85
- * See the LICENSE file in the root directory of this source tree.
86
- */const ii=[["path",{d:"M10.268 21a2 2 0 0 0 3.464 0",key:"vwvbt9"}],["path",{d:"M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326",key:"11g9vi"}]],si=C("bell",ii);/**
87
- * @license lucide-react v1.38.0 - ISC
88
- *
89
- * This source code is licensed under the ISC license.
90
- * See the LICENSE file in the root directory of this source tree.
91
- */const li=[["path",{d:"M10 2v8l3-3 3 3V2",key:"sqw3rj"}],["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20",key:"k3hazp"}]],ci=C("book-marked",li);/**
92
- * @license lucide-react v1.38.0 - ISC
93
- *
94
- * This source code is licensed under the ISC license.
95
- * See the LICENSE file in the root directory of this source tree.
96
- */const di=[["path",{d:"M12 5v16",key:"1f6ucr"}],["path",{d:"M20.001 19A2 2 0 0022 17V5a2 2 0 00-1.999-2L16 3.002A5 5 0 0012 5a5 5 0 00-4-2H4a2 2 0 00-2 2v12a2 2 0 001.999 2H8a5 5 0 014 2 5 5 0 014-2z",key:"1fyvmf"}]],hi=C("book-open",di);/**
97
- * @license lucide-react v1.38.0 - ISC
98
- *
99
- * This source code is licensed under the ISC license.
100
- * See the LICENSE file in the root directory of this source tree.
101
- */const fi=[["path",{d:"M17 3h4v4",key:"19p9u1"}],["path",{d:"M18.575 11.082a13 13 0 0 1 1.048 9.027 1.17 1.17 0 0 1-1.914.597L14 17",key:"12t3w9"}],["path",{d:"M7 10 3.29 6.29a1.17 1.17 0 0 1 .6-1.91 13 13 0 0 1 9.03 1.05",key:"ogng5l"}],["path",{d:"M7 14a1.7 1.7 0 0 0-1.207.5l-2.646 2.646A.5.5 0 0 0 3.5 18H5a1 1 0 0 1 1 1v1.5a.5.5 0 0 0 .854.354L9.5 18.207A1.7 1.7 0 0 0 10 17v-2a1 1 0 0 0-1-1z",key:"8v3fy2"}],["path",{d:"M9.707 14.293 21 3",key:"ydm3bn"}]],pi=C("bow-arrow",fi);/**
102
- * @license lucide-react v1.38.0 - ISC
103
- *
104
- * This source code is licensed under the ISC license.
105
- * See the LICENSE file in the root directory of this source tree.
106
- */const Ci=[["path",{d:"M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1",key:"ezmyqa"}],["path",{d:"M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1",key:"e1hn23"}]],yi=C("braces",Ci);/**
107
- * @license lucide-react v1.38.0 - ISC
108
- *
109
- * This source code is licensed under the ISC license.
110
- * See the LICENSE file in the root directory of this source tree.
111
- */const mi=[["path",{d:"M12 20v-9",key:"1qisl0"}],["path",{d:"M14 7a4 4 0 0 1 4 4v3a6 6 0 0 1-12 0v-3a4 4 0 0 1 4-4z",key:"uouzyp"}],["path",{d:"M14.12 3.88 16 2",key:"qol33r"}],["path",{d:"M21 21a4 4 0 0 0-3.81-4",key:"1b0z45"}],["path",{d:"M21 5a4 4 0 0 1-3.55 3.97",key:"5cxbf6"}],["path",{d:"M22 13h-4",key:"1jl80f"}],["path",{d:"M3 21a4 4 0 0 1 3.81-4",key:"1fjd4g"}],["path",{d:"M3 5a4 4 0 0 0 3.55 3.97",key:"1d7oge"}],["path",{d:"M6 13H2",key:"82j7cp"}],["path",{d:"m8 2 1.88 1.88",key:"fmnt4t"}],["path",{d:"M9 7.13V6a3 3 0 1 1 6 0v1.13",key:"1vgav8"}]],gi=C("bug",mi);/**
112
- * @license lucide-react v1.38.0 - ISC
113
- *
114
- * This source code is licensed under the ISC license.
115
- * See the LICENSE file in the root directory of this source tree.
116
- */const _i=[["path",{d:"M8 2v3",key:"1ioesn"}],["path",{d:"M16 2v3",key:"otl347"}],["rect",{x:"3",y:"3",width:"18",height:"18",rx:"2",key:"h1oib"}],["path",{d:"M3 9h18",key:"1pudct"}],["path",{d:"m9 15 2 2 4-4",key:"1grp1n"}]],Ei=C("calendar-check",_i);/**
117
- * @license lucide-react v1.38.0 - ISC
118
- *
119
- * This source code is licensed under the ISC license.
120
- * See the LICENSE file in the root directory of this source tree.
121
- */const bi=[["path",{d:"M8 2v3",key:"1ioesn"}],["path",{d:"M16 2v3",key:"otl347"}],["rect",{x:"3",y:"3",width:"18",height:"18",rx:"2",key:"h1oib"}],["path",{d:"M3 9h18",key:"1pudct"}],["path",{d:"M8 13h.01",key:"1sbv64"}],["path",{d:"M12 13h.01",key:"y0uutt"}],["path",{d:"M16 13h.01",key:"wip0gl"}],["path",{d:"M8 17h.01",key:"p3bg7i"}],["path",{d:"M12 17h.01",key:"p32p05"}],["path",{d:"M16 17h.01",key:"ql8jdd"}]],Si=C("calendar-days",bi);/**
122
- * @license lucide-react v1.38.0 - ISC
123
- *
124
- * This source code is licensed under the ISC license.
125
- * See the LICENSE file in the root directory of this source tree.
126
- */const ki=[["path",{d:"M13.997 4a2 2 0 0 1 1.76 1.05l.486.9A2 2 0 0 0 18.003 7H20a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h1.997a2 2 0 0 0 1.759-1.048l.489-.904A2 2 0 0 1 10.004 4z",key:"18u6gg"}],["circle",{cx:"12",cy:"13",r:"3",key:"1vg3eu"}]],Ai=C("camera",ki);/**
127
- * @license lucide-react v1.38.0 - ISC
128
- *
129
- * This source code is licensed under the ISC license.
130
- * See the LICENSE file in the root directory of this source tree.
131
- */const wi=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]],Mi=C("chart-column",wi);/**
132
- * @license lucide-react v1.38.0 - ISC
133
- *
134
- * This source code is licensed under the ISC license.
135
- * See the LICENSE file in the root directory of this source tree.
136
- */const Ni=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"m19 9-5 5-4-4-3 3",key:"2osh9i"}]],Ti=C("chart-line",Ni);/**
137
- * @license lucide-react v1.38.0 - ISC
138
- *
139
- * This source code is licensed under the ISC license.
140
- * See the LICENSE file in the root directory of this source tree.
141
- */const xi=[["path",{d:"M21 12c.552 0 1.005-.449.95-.998a10 10 0 0 0-8.953-8.951c-.55-.055-.998.398-.998.95v8a1 1 0 0 0 1 1z",key:"pzmjnu"}],["path",{d:"M21.21 15.89A10 10 0 1 1 8 2.83",key:"k2fpak"}]],Bi=C("chart-pie",xi);/**
142
- * @license lucide-react v1.38.0 - ISC
143
- *
144
- * This source code is licensed under the ISC license.
145
- * See the LICENSE file in the root directory of this source tree.
146
- */const Di=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],vi=C("check",Di);/**
147
- * @license lucide-react v1.38.0 - ISC
148
- *
149
- * This source code is licensed under the ISC license.
150
- * See the LICENSE file in the root directory of this source tree.
151
- */const Oi=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],Li=C("chevron-left",Oi);/**
152
- * @license lucide-react v1.38.0 - ISC
153
- *
154
- * This source code is licensed under the ISC license.
155
- * See the LICENSE file in the root directory of this source tree.
156
- */const Ri=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],Ii=C("chevron-right",Ri);/**
157
- * @license lucide-react v1.38.0 - ISC
158
- *
159
- * This source code is licensed under the ISC license.
160
- * See the LICENSE file in the root directory of this source tree.
161
- */const ji=[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}],["path",{d:"M12 11h4",key:"1jrz19"}],["path",{d:"M12 16h4",key:"n85exb"}],["path",{d:"M8 11h.01",key:"1dfujw"}],["path",{d:"M8 16h.01",key:"18s6g9"}]],Pi=C("clipboard-list",ji);/**
162
- * @license lucide-react v1.38.0 - ISC
163
- *
164
- * This source code is licensed under the ISC license.
165
- * See the LICENSE file in the root directory of this source tree.
166
- */const $i=[["path",{d:"M14 3a1 1 0 0 1 1 1v5a1 1 0 0 1-1 1",key:"1l7d7l"}],["path",{d:"M19 3a1 1 0 0 1 1 1v5a1 1 0 0 1-1 1",key:"9955pe"}],["path",{d:"m7 15 3 3",key:"4hkfgk"}],["path",{d:"m7 21 3-3H5a2 2 0 0 1-2-2v-2",key:"1xljwe"}],["rect",{x:"14",y:"14",width:"7",height:"7",rx:"1",key:"1cdgtw"}],["rect",{x:"3",y:"3",width:"7",height:"7",rx:"1",key:"zi3rio"}]],Fi=C("combine",$i);/**
167
- * @license lucide-react v1.38.0 - ISC
168
- *
169
- * This source code is licensed under the ISC license.
170
- * See the LICENSE file in the root directory of this source tree.
171
- */const Hi=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],zi=C("copy",Hi);/**
172
- * @license lucide-react v1.38.0 - ISC
173
- *
174
- * This source code is licensed under the ISC license.
175
- * See the LICENSE file in the root directory of this source tree.
176
- */const Vi=[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]],Ui=C("credit-card",Vi);/**
177
- * @license lucide-react v1.38.0 - ISC
178
- *
179
- * This source code is licensed under the ISC license.
180
- * See the LICENSE file in the root directory of this source tree.
181
- */const Gi=[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]],Yi=C("database",Gi);/**
182
- * @license lucide-react v1.38.0 - ISC
183
- *
184
- * This source code is licensed under the ISC license.
185
- * See the LICENSE file in the root directory of this source tree.
186
- */const qi=[["path",{d:"M12 3v14",key:"7cf3v8"}],["path",{d:"M5 10h14",key:"elsbfy"}],["path",{d:"M5 21h14",key:"11awu3"}]],Wi=C("diff",qi);/**
187
- * @license lucide-react v1.38.0 - ISC
188
- *
189
- * This source code is licensed under the ISC license.
190
- * See the LICENSE file in the root directory of this source tree.
191
- */const Ki=[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]],Xi=C("download",Ki);/**
192
- * @license lucide-react v1.38.0 - ISC
193
- *
194
- * This source code is licensed under the ISC license.
195
- * See the LICENSE file in the root directory of this source tree.
196
- */const Zi=[["path",{d:"M6 8.5a6.5 6.5 0 1 1 13 0c0 6-6 6-6 10a3.5 3.5 0 1 1-7 0",key:"1dfaln"}],["path",{d:"M15 8.5a2.5 2.5 0 0 0-5 0v1a2 2 0 1 1 0 4",key:"1qnva7"}]],Ji=C("ear",Zi);/**
197
- * @license lucide-react v1.38.0 - ISC
198
- *
199
- * This source code is licensed under the ISC license.
200
- * See the LICENSE file in the root directory of this source tree.
201
- */const Qi=[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]],es=C("square-pen",Qi);/**
202
- * @license lucide-react v1.38.0 - ISC
203
- *
204
- * This source code is licensed under the ISC license.
205
- * See the LICENSE file in the root directory of this source tree.
206
- */const ts=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]],ns=C("pen",ts);/**
207
- * @license lucide-react v1.38.0 - ISC
208
- *
209
- * This source code is licensed under the ISC license.
210
- * See the LICENSE file in the root directory of this source tree.
211
- */const os=[["path",{d:"M13 21h8",key:"1jsn5i"}],["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]],us=C("pen-line",os);/**
212
- * @license lucide-react v1.38.0 - ISC
213
- *
214
- * This source code is licensed under the ISC license.
215
- * See the LICENSE file in the root directory of this source tree.
216
- */const rs=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],du=C("ellipsis",rs);/**
217
- * @license lucide-react v1.38.0 - ISC
218
- *
219
- * This source code is licensed under the ISC license.
220
- * See the LICENSE file in the root directory of this source tree.
221
- */const as=[["path",{d:"M21 21H8a2 2 0 0 1-1.42-.587l-3.994-3.999a2 2 0 0 1 0-2.828l10-10a2 2 0 0 1 2.829 0l5.999 6a2 2 0 0 1 0 2.828L12.834 21",key:"g5wo59"}],["path",{d:"m5.082 11.09 8.828 8.828",key:"1wx5vj"}]],is=C("eraser",as);/**
222
- * @license lucide-react v1.38.0 - ISC
223
- *
224
- * This source code is licensed under the ISC license.
225
- * See the LICENSE file in the root directory of this source tree.
226
- */const ss=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],ls=C("external-link",ss);/**
227
- * @license lucide-react v1.38.0 - ISC
228
- *
229
- * This source code is licensed under the ISC license.
230
- * See the LICENSE file in the root directory of this source tree.
231
- */const cs=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],ds=C("eye",cs);/**
232
- * @license lucide-react v1.38.0 - ISC
233
- *
234
- * This source code is licensed under the ISC license.
235
- * See the LICENSE file in the root directory of this source tree.
236
- */const hs=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],fs=C("file-text",hs);/**
237
- * @license lucide-react v1.38.0 - ISC
238
- *
239
- * This source code is licensed under the ISC license.
240
- * See the LICENSE file in the root directory of this source tree.
241
- */const ps=[["path",{d:"M8 3H5a2 2 0 0 0-2 2v14c0 1.1.9 2 2 2h3",key:"1i73f7"}],["path",{d:"M16 3h3a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-3",key:"saxlbk"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 14v2",key:"8jcxud"}],["path",{d:"M12 8v2",key:"1woqiv"}],["path",{d:"M12 2v2",key:"tus03m"}]],Cs=C("square-centerline-dashed-horizontal",ps);/**
242
- * @license lucide-react v1.38.0 - ISC
243
- *
244
- * This source code is licensed under the ISC license.
245
- * See the LICENSE file in the root directory of this source tree.
246
- */const ys=[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]],ms=C("folder-open",ys);/**
247
- * @license lucide-react v1.38.0 - ISC
248
- *
249
- * This source code is licensed under the ISC license.
250
- * See the LICENSE file in the root directory of this source tree.
251
- */const gs=[["path",{d:"M12 10v6",key:"1bos4e"}],["path",{d:"M9 13h6",key:"1uhe8q"}],["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]],_s=C("folder-plus",gs);/**
252
- * @license lucide-react v1.38.0 - ISC
253
- *
254
- * This source code is licensed under the ISC license.
255
- * See the LICENSE file in the root directory of this source tree.
256
- */const Es=[["line",{x1:"6",x2:"10",y1:"12",y2:"12",key:"161bw2"}],["line",{x1:"8",x2:"8",y1:"10",y2:"14",key:"1i6ji0"}],["line",{x1:"15",x2:"15.01",y1:"13",y2:"13",key:"dqpgro"}],["line",{x1:"18",x2:"18.01",y1:"11",y2:"11",key:"meh2c"}],["rect",{width:"20",height:"12",x:"2",y:"6",rx:"2",key:"9lu3g6"}]],bs=C("gamepad",Es);/**
257
- * @license lucide-react v1.38.0 - ISC
258
- *
259
- * This source code is licensed under the ISC license.
260
- * See the LICENSE file in the root directory of this source tree.
261
- */const Ss=[["path",{d:"m14 13-8.381 8.38a1 1 0 0 1-3.001-3l8.384-8.381",key:"pgg06f"}],["path",{d:"m16 16 6-6",key:"vzrcl6"}],["path",{d:"m21.5 10.5-8-8",key:"a17d9x"}],["path",{d:"m8 8 6-6",key:"18bi4p"}],["path",{d:"m8.5 7.5 8 8",key:"1oyaui"}]],ks=C("gavel",Ss);/**
262
- * @license lucide-react v1.38.0 - ISC
263
- *
264
- * This source code is licensed under the ISC license.
265
- * See the LICENSE file in the root directory of this source tree.
266
- */const As=[["circle",{cx:"18",cy:"18",r:"3",key:"1xkwt0"}],["circle",{cx:"6",cy:"6",r:"3",key:"1lh9wr"}],["path",{d:"M6 21V9a9 9 0 0 0 9 9",key:"7kw0sc"}]],ws=C("git-merge",As);/**
267
- * @license lucide-react v1.38.0 - ISC
268
- *
269
- * This source code is licensed under the ISC license.
270
- * See the LICENSE file in the root directory of this source tree.
271
- */const Ms=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]],Ns=C("globe",Ms);/**
272
- * @license lucide-react v1.38.0 - ISC
273
- *
274
- * This source code is licensed under the ISC license.
275
- * See the LICENSE file in the root directory of this source tree.
276
- */const Ts=[["path",{d:"M3 14h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-7a9 9 0 0 1 18 0v7a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3",key:"1xhozi"}]],xs=C("headphones",Ts);/**
277
- * @license lucide-react v1.38.0 - ISC
278
- *
279
- * This source code is licensed under the ISC license.
280
- * See the LICENSE file in the root directory of this source tree.
281
- */const Bs=[["path",{d:"M2 9.5a5.5 5.5 0 0 1 9.591-3.676.56.56 0 0 0 .818 0A5.49 5.49 0 0 1 22 9.5c0 2.29-1.5 4-3 5.5l-5.492 5.313a2 2 0 0 1-3 .019L5 15c-1.5-1.5-3-3.2-3-5.5",key:"mvr1a0"}]],Ds=C("heart",Bs);/**
282
- * @license lucide-react v1.38.0 - ISC
283
- *
284
- * This source code is licensed under the ISC license.
285
- * See the LICENSE file in the root directory of this source tree.
286
- */const vs=[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"r6nss1"}]],Os=C("house",vs);/**
287
- * @license lucide-react v1.38.0 - ISC
288
- *
289
- * This source code is licensed under the ISC license.
290
- * See the LICENSE file in the root directory of this source tree.
291
- */const Ls=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],Rs=C("info",Ls);/**
292
- * @license lucide-react v1.38.0 - ISC
293
- *
294
- * This source code is licensed under the ISC license.
295
- * See the LICENSE file in the root directory of this source tree.
296
- */const Is=[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]],js=C("key-round",Is);/**
297
- * @license lucide-react v1.38.0 - ISC
298
- *
299
- * This source code is licensed under the ISC license.
300
- * See the LICENSE file in the root directory of this source tree.
301
- */const Ps=[["path",{d:"M10 18v-7",key:"wt116b"}],["path",{d:"M11.119 2.205a2 2 0 0 1 1.762 0l7.84 3.846A.5.5 0 0 1 20.5 7h-17a.5.5 0 0 1-.22-.949z",key:"yxxwt6"}],["path",{d:"M14 18v-7",key:"vav6t3"}],["path",{d:"M18 18v-7",key:"aexdmj"}],["path",{d:"M3 22h18",key:"8prr45"}],["path",{d:"M6 18v-7",key:"1ivflk"}]],$s=C("landmark",Ps);/**
302
- * @license lucide-react v1.38.0 - ISC
303
- *
304
- * This source code is licensed under the ISC license.
305
- * See the LICENSE file in the root directory of this source tree.
306
- */const Fs=[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]],Hs=C("layers",Fs);/**
307
- * @license lucide-react v1.38.0 - ISC
308
- *
309
- * This source code is licensed under the ISC license.
310
- * See the LICENSE file in the root directory of this source tree.
311
- */const zs=[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]],Vs=C("layout-dashboard",zs);/**
312
- * @license lucide-react v1.38.0 - ISC
313
- *
314
- * This source code is licensed under the ISC license.
315
- * See the LICENSE file in the root directory of this source tree.
316
- */const Us=[["path",{d:"M11 20A7 7 0 0 1 9.8 6.1C15.5 5 17 4.48 19 2c1 2 2 4.18 2 8 0 5.5-4.78 10-10 10Z",key:"nnexq3"}],["path",{d:"M2 21c0-3 1.85-5.36 5.08-6C9.5 14.52 12 13 13 12",key:"mt58a7"}]],Gs=C("leaf",Us);/**
317
- * @license lucide-react v1.38.0 - ISC
318
- *
319
- * This source code is licensed under the ISC license.
320
- * See the LICENSE file in the root directory of this source tree.
321
- */const Ys=[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5",key:"1gvzjb"}],["path",{d:"M9 18h6",key:"x1upvd"}],["path",{d:"M10 22h4",key:"ceow96"}]],qs=C("lightbulb",Ys);/**
322
- * @license lucide-react v1.38.0 - ISC
323
- *
324
- * This source code is licensed under the ISC license.
325
- * See the LICENSE file in the root directory of this source tree.
326
- */const Ws=[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]],Ks=C("link",Ws);/**
327
- * @license lucide-react v1.38.0 - ISC
328
- *
329
- * This source code is licensed under the ISC license.
330
- * See the LICENSE file in the root directory of this source tree.
331
- */const Xs=[["path",{d:"M9 17H7A5 5 0 0 1 7 7h2",key:"8i5ue5"}],["path",{d:"M15 7h2a5 5 0 1 1 0 10h-2",key:"1b9ql8"}],["line",{x1:"8",x2:"16",y1:"12",y2:"12",key:"1jonct"}]],Zs=C("link-2",Xs);/**
332
- * @license lucide-react v1.38.0 - ISC
333
- *
334
- * This source code is licensed under the ISC license.
335
- * See the LICENSE file in the root directory of this source tree.
336
- */const Js=[["path",{d:"M9 17H7A5 5 0 0 1 7 7",key:"10o201"}],["path",{d:"M15 7h2a5 5 0 0 1 4 8",key:"1d3206"}],["line",{x1:"8",x2:"12",y1:"12",y2:"12",key:"rvw6j4"}],["line",{x1:"2",x2:"22",y1:"2",y2:"22",key:"a6p6uj"}]],Qs=C("link-2-off",Js);/**
337
- * @license lucide-react v1.38.0 - ISC
338
- *
339
- * This source code is licensed under the ISC license.
340
- * See the LICENSE file in the root directory of this source tree.
341
- */const el=[["path",{d:"M3 5h.01",key:"18ugdj"}],["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 19h.01",key:"noohij"}],["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 19h13",key:"m83p4d"}]],tl=C("list",el);/**
342
- * @license lucide-react v1.38.0 - ISC
343
- *
344
- * This source code is licensed under the ISC license.
345
- * See the LICENSE file in the root directory of this source tree.
346
- */const nl=[["path",{d:"M13 5h8",key:"a7qcls"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}],["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["path",{d:"m3 7 2 2 4-4",key:"1obspn"}]],ol=C("list-checks",nl);/**
347
- * @license lucide-react v1.38.0 - ISC
348
- *
349
- * This source code is licensed under the ISC license.
350
- * See the LICENSE file in the root directory of this source tree.
351
- */const ul=[["path",{d:"M11 5h10",key:"1cz7ny"}],["path",{d:"M11 12h10",key:"1438ji"}],["path",{d:"M11 19h10",key:"11t30w"}],["path",{d:"M4 4h1v5",key:"10yrso"}],["path",{d:"M4 9h2",key:"r1h2o0"}],["path",{d:"M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02",key:"xtkcd5"}]],rl=C("list-ordered",ul);/**
352
- * @license lucide-react v1.38.0 - ISC
353
- *
354
- * This source code is licensed under the ISC license.
355
- * See the LICENSE file in the root directory of this source tree.
356
- */const al=[["path",{d:"M12 2v4",key:"3427ic"}],["path",{d:"m16.2 7.8 2.9-2.9",key:"r700ao"}],["path",{d:"M18 12h4",key:"wj9ykh"}],["path",{d:"m16.2 16.2 2.9 2.9",key:"1bxg5t"}],["path",{d:"M12 18v4",key:"jadmvz"}],["path",{d:"m4.9 19.1 2.9-2.9",key:"bwix9q"}],["path",{d:"M2 12h4",key:"j09sii"}],["path",{d:"m4.9 4.9 2.9 2.9",key:"giyufr"}]],il=C("loader",al);/**
357
- * @license lucide-react v1.38.0 - ISC
358
- *
359
- * This source code is licensed under the ISC license.
360
- * See the LICENSE file in the root directory of this source tree.
361
- */const sl=[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]],ll=C("log-out",sl);/**
362
- * @license lucide-react v1.38.0 - ISC
363
- *
364
- * This source code is licensed under the ISC license.
365
- * See the LICENSE file in the root directory of this source tree.
366
- */const cl=[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]],dl=C("mail",cl);/**
367
- * @license lucide-react v1.38.0 - ISC
368
- *
369
- * This source code is licensed under the ISC license.
370
- * See the LICENSE file in the root directory of this source tree.
371
- */const hl=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],fl=C("map-pin",hl);/**
372
- * @license lucide-react v1.38.0 - ISC
373
- *
374
- * This source code is licensed under the ISC license.
375
- * See the LICENSE file in the root directory of this source tree.
376
- */const pl=[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}]],Cl=C("message-circle",pl);/**
377
- * @license lucide-react v1.38.0 - ISC
378
- *
379
- * This source code is licensed under the ISC license.
380
- * See the LICENSE file in the root directory of this source tree.
381
- */const yl=[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]],ml=C("message-circle-question-mark",yl);/**
382
- * @license lucide-react v1.38.0 - ISC
383
- *
384
- * This source code is licensed under the ISC license.
385
- * See the LICENSE file in the root directory of this source tree.
386
- */const gl=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]],_l=C("message-square",gl);/**
387
- * @license lucide-react v1.38.0 - ISC
388
- *
389
- * This source code is licensed under the ISC license.
390
- * See the LICENSE file in the root directory of this source tree.
391
- */const El=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}],["path",{d:"M7 11h10",key:"1twpyw"}],["path",{d:"M7 15h6",key:"d9of3u"}],["path",{d:"M7 7h8",key:"af5zfr"}]],bl=C("message-square-text",El);/**
392
- * @license lucide-react v1.38.0 - ISC
393
- *
394
- * This source code is licensed under the ISC license.
395
- * See the LICENSE file in the root directory of this source tree.
396
- */const Sl=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}]],kl=C("circle-minus",Sl);/**
397
- * @license lucide-react v1.38.0 - ISC
398
- *
399
- * This source code is licensed under the ISC license.
400
- * See the LICENSE file in the root directory of this source tree.
401
- */const Al=[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]],wl=C("package",Al);/**
402
- * @license lucide-react v1.38.0 - ISC
403
- *
404
- * This source code is licensed under the ISC license.
405
- * See the LICENSE file in the root directory of this source tree.
406
- */const Ml=[["path",{d:"M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z",key:"e79jfc"}],["circle",{cx:"13.5",cy:"6.5",r:".5",fill:"currentColor",key:"1okk4w"}],["circle",{cx:"17.5",cy:"10.5",r:".5",fill:"currentColor",key:"f64h9f"}],["circle",{cx:"6.5",cy:"12.5",r:".5",fill:"currentColor",key:"qy21gx"}],["circle",{cx:"8.5",cy:"7.5",r:".5",fill:"currentColor",key:"fotxhn"}]],Nl=C("palette",Ml);/**
407
- * @license lucide-react v1.38.0 - ISC
408
- *
409
- * This source code is licensed under the ISC license.
410
- * See the LICENSE file in the root directory of this source tree.
411
- */const Tl=[["path",{d:"M5.8 11.3 2 22l10.7-3.79",key:"gwxi1d"}],["path",{d:"M4 3h.01",key:"1vcuye"}],["path",{d:"M22 8h.01",key:"1mrtc2"}],["path",{d:"M15 2h.01",key:"1cjtqr"}],["path",{d:"M22 20h.01",key:"1mrys2"}],["path",{d:"m22 2-2.24.75a2.9 2.9 0 0 0-1.96 3.12c.1.86-.57 1.63-1.45 1.63h-.38c-.86 0-1.6.6-1.76 1.44L14 10",key:"hbicv8"}],["path",{d:"m22 13-.82-.33c-.86-.34-1.82.2-1.98 1.11c-.11.7-.72 1.22-1.43 1.22H17",key:"1i94pl"}],["path",{d:"m11 2 .33.82c.34.86-.2 1.82-1.11 1.98C9.52 4.9 9 5.52 9 6.23V7",key:"1cofks"}],["path",{d:"M11 13c1.93 1.93 2.83 4.17 2 5-.83.83-3.07-.07-5-2-1.93-1.93-2.83-4.17-2-5 .83-.83 3.07.07 5 2Z",key:"4kbmks"}]],xl=C("party-popper",Tl);/**
412
- * @license lucide-react v1.38.0 - ISC
413
- *
414
- * This source code is licensed under the ISC license.
415
- * See the LICENSE file in the root directory of this source tree.
416
- */const Bl=[["rect",{x:"14",y:"3",width:"5",height:"18",rx:"1",key:"kaeet6"}],["rect",{x:"5",y:"3",width:"5",height:"18",rx:"1",key:"1wsw3u"}]],Dl=C("pause",Bl);/**
417
- * @license lucide-react v1.38.0 - ISC
418
- *
419
- * This source code is licensed under the ISC license.
420
- * See the LICENSE file in the root directory of this source tree.
421
- */const vl=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]],Ol=C("pencil",vl);/**
422
- * @license lucide-react v1.38.0 - ISC
423
- *
424
- * This source code is licensed under the ISC license.
425
- * See the LICENSE file in the root directory of this source tree.
426
- */const Ll=[["path",{d:"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384",key:"9njp5v"}]],Rl=C("phone",Ll);/**
427
- * @license lucide-react v1.38.0 - ISC
428
- *
429
- * This source code is licensed under the ISC license.
430
- * See the LICENSE file in the root directory of this source tree.
431
- */const Il=[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]],jl=C("play",Il);/**
432
- * @license lucide-react v1.38.0 - ISC
433
- *
434
- * This source code is licensed under the ISC license.
435
- * See the LICENSE file in the root directory of this source tree.
436
- */const Pl=[["path",{d:"M9 9.003a1 1 0 0 1 1.517-.859l4.997 2.997a1 1 0 0 1 0 1.718l-4.997 2.997A1 1 0 0 1 9 14.996z",key:"kmsa83"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],$l=C("circle-play",Pl);/**
437
- * @license lucide-react v1.38.0 - ISC
438
- *
439
- * This source code is licensed under the ISC license.
440
- * See the LICENSE file in the root directory of this source tree.
441
- */const Fl=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],Hl=C("plus",Fl);/**
442
- * @license lucide-react v1.38.0 - ISC
443
- *
444
- * This source code is licensed under the ISC license.
445
- * See the LICENSE file in the root directory of this source tree.
446
- */const zl=[["path",{d:"M6 18H4a2 2 0 0 1-2-2v-5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v5a2 2 0 0 1-2 2h-2",key:"143wyd"}],["path",{d:"M6 9V3a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v6",key:"1itne7"}],["rect",{x:"6",y:"14",width:"12",height:"8",rx:"1",key:"1ue0tg"}]],Vl=C("printer",zl);/**
447
- * @license lucide-react v1.38.0 - ISC
448
- *
449
- * This source code is licensed under the ISC license.
450
- * See the LICENSE file in the root directory of this source tree.
451
- */const Ul=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],Gl=C("refresh-cw",Ul);/**
452
- * @license lucide-react v1.38.0 - ISC
453
- *
454
- * This source code is licensed under the ISC license.
455
- * See the LICENSE file in the root directory of this source tree.
456
- */const Yl=[["path",{d:"m17 2 4 4-4 4",key:"nntrym"}],["path",{d:"M3 11v-1a4 4 0 0 1 4-4h14",key:"84bu3i"}],["path",{d:"m7 22-4-4 4-4",key:"1wqhfi"}],["path",{d:"M21 13v1a4 4 0 0 1-4 4H3",key:"1rx37r"}]],ql=C("repeat",Yl);/**
457
- * @license lucide-react v1.38.0 - ISC
458
- *
459
- * This source code is licensed under the ISC license.
460
- * See the LICENSE file in the root directory of this source tree.
461
- */const Wl=[["path",{d:"M14 4a1 1 0 0 1 1-1",key:"dhj8ez"}],["path",{d:"M15 10a1 1 0 0 1-1-1",key:"1mnyi5"}],["path",{d:"M21 4a1 1 0 0 0-1-1",key:"sfs9ap"}],["path",{d:"M21 9a1 1 0 0 1-1 1",key:"mp6qeo"}],["path",{d:"m3 7 3 3 3-3",key:"x25e72"}],["path",{d:"M6 10V5a2 2 0 0 1 2-2h2",key:"15xut4"}],["rect",{x:"3",y:"14",width:"7",height:"7",rx:"1",key:"1bkyp8"}]],Kl=C("replace",Wl);/**
462
- * @license lucide-react v1.38.0 - ISC
463
- *
464
- * This source code is licensed under the ISC license.
465
- * See the LICENSE file in the root directory of this source tree.
466
- */const Xl=[["path",{d:"M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5",key:"qeys4"}],["path",{d:"M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09",key:"u4xsad"}],["path",{d:"M9 12a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.4 22.4 0 0 1-4 2z",key:"676m9"}],["path",{d:"M9 12H4s.55-3.03 2-4c1.62-1.08 5 .05 5 .05",key:"92ym6u"}]],Zl=C("rocket",Xl);/**
467
- * @license lucide-react v1.38.0 - ISC
468
- *
469
- * This source code is licensed under the ISC license.
470
- * See the LICENSE file in the root directory of this source tree.
471
- */const Jl=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]],Ql=C("rotate-ccw",Jl);/**
472
- * @license lucide-react v1.38.0 - ISC
473
- *
474
- * This source code is licensed under the ISC license.
475
- * See the LICENSE file in the root directory of this source tree.
476
- */const ec=[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]],tc=C("rotate-cw",ec);/**
477
- * @license lucide-react v1.38.0 - ISC
478
- *
479
- * This source code is licensed under the ISC license.
480
- * See the LICENSE file in the root directory of this source tree.
481
- */const nc=[["path",{d:"M7 21h10",key:"1b0cd5"}],["path",{d:"M12 21a9 9 0 0 0 9-9H3a9 9 0 0 0 9 9Z",key:"4rw317"}],["path",{d:"M11.38 12a2.4 2.4 0 0 1-.4-4.77 2.4 2.4 0 0 1 3.2-2.77 2.4 2.4 0 0 1 3.47-.63 2.4 2.4 0 0 1 3.37 3.37 2.4 2.4 0 0 1-1.1 3.7 2.51 2.51 0 0 1 .03 1.1",key:"10xrj0"}],["path",{d:"m13 12 4-4",key:"1hckqy"}],["path",{d:"M10.9 7.25A3.99 3.99 0 0 0 4 10c0 .73.2 1.41.54 2",key:"1p4srx"}]],oc=C("salad",nc);/**
482
- * @license lucide-react v1.38.0 - ISC
483
- *
484
- * This source code is licensed under the ISC license.
485
- * See the LICENSE file in the root directory of this source tree.
486
- */const uc=[["path",{d:"M3 7V5a2 2 0 0 1 2-2h2",key:"aa7l1z"}],["path",{d:"M17 3h2a2 2 0 0 1 2 2v2",key:"4qcy5o"}],["path",{d:"M21 17v2a2 2 0 0 1-2 2h-2",key:"6vwrx8"}],["path",{d:"M7 21H5a2 2 0 0 1-2-2v-2",key:"ioqczr"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}],["path",{d:"m16 16-1.9-1.9",key:"1dq9hf"}]],rc=C("scan-search",uc);/**
487
- * @license lucide-react v1.38.0 - ISC
488
- *
489
- * This source code is licensed under the ISC license.
490
- * See the LICENSE file in the root directory of this source tree.
491
- */const ac=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],hu=C("circle-alert",ac);/**
492
- * @license lucide-react v1.38.0 - ISC
493
- *
494
- * This source code is licensed under the ISC license.
495
- * See the LICENSE file in the root directory of this source tree.
496
- */const ic=[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]],sc=C("circle-check-big",ic);/**
497
- * @license lucide-react v1.38.0 - ISC
498
- *
499
- * This source code is licensed under the ISC license.
500
- * See the LICENSE file in the root directory of this source tree.
501
- */const lc=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],cc=C("search",lc);/**
502
- * @license lucide-react v1.38.0 - ISC
503
- *
504
- * This source code is licensed under the ISC license.
505
- * See the LICENSE file in the root directory of this source tree.
506
- */const dc=[["circle",{cx:"6",cy:"6",r:"3",key:"1lh9wr"}],["path",{d:"M8.12 8.12 12 12",key:"1alkpv"}],["path",{d:"M20 4 8.12 15.88",key:"xgtan2"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["path",{d:"M14.8 14.8 20 20",key:"ptml3r"}]],hc=C("scissors",dc);/**
507
- * @license lucide-react v1.38.0 - ISC
508
- *
509
- * This source code is licensed under the ISC license.
510
- * See the LICENSE file in the root directory of this source tree.
511
- */const fc=[["path",{d:"m13.5 8.5-5 5",key:"1cs55j"}],["path",{d:"m8.5 8.5 5 5",key:"a8mexj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]],pc=C("search-x",fc);/**
512
- * @license lucide-react v1.38.0 - ISC
513
- *
514
- * This source code is licensed under the ISC license.
515
- * See the LICENSE file in the root directory of this source tree.
516
- */const Cc=[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]],yc=C("send",Cc);/**
517
- * @license lucide-react v1.38.0 - ISC
518
- *
519
- * This source code is licensed under the ISC license.
520
- * See the LICENSE file in the root directory of this source tree.
521
- */const mc=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],gc=C("settings",mc);/**
522
- * @license lucide-react v1.38.0 - ISC
523
- *
524
- * This source code is licensed under the ISC license.
525
- * See the LICENSE file in the root directory of this source tree.
526
- */const _c=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],Ec=C("shield-check",_c);/**
527
- * @license lucide-react v1.38.0 - ISC
528
- *
529
- * This source code is licensed under the ISC license.
530
- * See the LICENSE file in the root directory of this source tree.
531
- */const bc=[["path",{d:"m2.05 2.05 1.099-.028a1 1 0 0 1 1.008.815l2.69 14.347A1 1 0 0 0 7.83 18H18",key:"uebgi3"}],["path",{d:"M4.563 5h16.435a1 1 0 0 1 .981 1.204l-1.026 6.226A2 2 0 0 1 18.962 14H6.25",key:"1j7c9p"}],["circle",{cx:"18",cy:"20",r:"2",key:"t9985n"}],["circle",{cx:"8",cy:"20",r:"2",key:"ckkr5m"}]],Sc=C("shopping-cart",bc);/**
532
- * @license lucide-react v1.38.0 - ISC
533
- *
534
- * This source code is licensed under the ISC license.
535
- * See the LICENSE file in the root directory of this source tree.
536
- */const kc=[["path",{d:"m18 14 4 4-4 4",key:"10pe0f"}],["path",{d:"m18 2 4 4-4 4",key:"pucp1d"}],["path",{d:"M2 18h1.973a4 4 0 0 0 3.3-1.7l5.454-8.6a4 4 0 0 1 3.3-1.7H22",key:"1ailkh"}],["path",{d:"M2 6h1.972a4 4 0 0 1 3.6 2.2",key:"km57vx"}],["path",{d:"M22 18h-6.041a4 4 0 0 1-3.3-1.8l-.359-.45",key:"os18l9"}]],Ac=C("shuffle",kc);/**
537
- * @license lucide-react v1.38.0 - ISC
538
- *
539
- * This source code is licensed under the ISC license.
540
- * See the LICENSE file in the root directory of this source tree.
541
- */const wc=[["path",{d:"M17.971 4.285A2 2 0 0 1 21 6v12a2 2 0 0 1-3.029 1.715l-9.997-5.998a2 2 0 0 1-.003-3.432z",key:"15892j"}],["path",{d:"M3 20V4",key:"1ptbpl"}]],Mc=C("skip-back",wc);/**
542
- * @license lucide-react v1.38.0 - ISC
543
- *
544
- * This source code is licensed under the ISC license.
545
- * See the LICENSE file in the root directory of this source tree.
546
- */const Nc=[["path",{d:"M21 4v16",key:"7j8fe9"}],["path",{d:"M6.029 4.285A2 2 0 0 0 3 6v12a2 2 0 0 0 3.029 1.715l9.997-5.998a2 2 0 0 0 .003-3.432z",key:"zs4d6"}]],Tc=C("skip-forward",Nc);/**
547
- * @license lucide-react v1.38.0 - ISC
548
- *
549
- * This source code is licensed under the ISC license.
550
- * See the LICENSE file in the root directory of this source tree.
551
- */const xc=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]],Bc=C("square",xc);/**
552
- * @license lucide-react v1.38.0 - ISC
553
- *
554
- * This source code is licensed under the ISC license.
555
- * See the LICENSE file in the root directory of this source tree.
556
- */const Dc=[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]],vc=C("star",Dc);/**
557
- * @license lucide-react v1.38.0 - ISC
558
- *
559
- * This source code is licensed under the ISC license.
560
- * See the LICENSE file in the root directory of this source tree.
561
- */const Oc=[["path",{d:"M15 21v-5a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v5",key:"slp6dd"}],["path",{d:"M17.774 10.31a1.12 1.12 0 0 0-1.549 0 2.5 2.5 0 0 1-3.451 0 1.12 1.12 0 0 0-1.548 0 2.5 2.5 0 0 1-3.452 0 1.12 1.12 0 0 0-1.549 0 2.5 2.5 0 0 1-3.77-3.248l2.889-4.184A2 2 0 0 1 7 2h10a2 2 0 0 1 1.653.873l2.895 4.192a2.5 2.5 0 0 1-3.774 3.244",key:"o0xfot"}],["path",{d:"M4 10.95V19a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8.05",key:"wn3emo"}]],Lc=C("store",Oc);/**
562
- * @license lucide-react v1.38.0 - ISC
563
- *
564
- * This source code is licensed under the ISC license.
565
- * See the LICENSE file in the root directory of this source tree.
566
- */const Rc=[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 3v1",key:"1asbbs"}],["path",{d:"M12 20v1",key:"1wcdkc"}],["path",{d:"M3 12h1",key:"lp3yf2"}],["path",{d:"M20 12h1",key:"1vloll"}],["path",{d:"m18.364 5.636-.707.707",key:"1hakh0"}],["path",{d:"m6.343 17.657-.707.707",key:"18m9nf"}],["path",{d:"m5.636 5.636.707.707",key:"1xv1c5"}],["path",{d:"m17.657 17.657.707.707",key:"vl76zb"}]],Ic=C("sun-medium",Rc);/**
567
- * @license lucide-react v1.38.0 - ISC
568
- *
569
- * This source code is licensed under the ISC license.
570
- * See the LICENSE file in the root directory of this source tree.
571
- */const jc=[["path",{d:"M12 3v18",key:"108xh3"}],["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}],["path",{d:"M3 15h18",key:"5xshup"}]],Pc=C("table",jc);/**
572
- * @license lucide-react v1.38.0 - ISC
573
- *
574
- * This source code is licensed under the ISC license.
575
- * See the LICENSE file in the root directory of this source tree.
576
- */const $c=[["path",{d:"M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18",key:"gugj83"}]],Fc=C("table-2",$c);/**
577
- * @license lucide-react v1.38.0 - ISC
578
- *
579
- * This source code is licensed under the ISC license.
580
- * See the LICENSE file in the root directory of this source tree.
581
- */const Hc=[["path",{d:"M12 19h8",key:"baeox8"}],["path",{d:"m4 17 6-6-6-6",key:"1yngyt"}]],zc=C("terminal",Hc);/**
582
- * @license lucide-react v1.38.0 - ISC
583
- *
584
- * This source code is licensed under the ISC license.
585
- * See the LICENSE file in the root directory of this source tree.
586
- */const Vc=[["path",{d:"M12 20h-1a2 2 0 0 1-2-2 2 2 0 0 1-2 2H6",key:"1528k5"}],["path",{d:"M13 8h7a2 2 0 0 1 2 2v4a2 2 0 0 1-2 2h-7",key:"13ksps"}],["path",{d:"M5 16H4a2 2 0 0 1-2-2v-4a2 2 0 0 1 2-2h1",key:"1n9rhb"}],["path",{d:"M6 4h1a2 2 0 0 1 2 2 2 2 0 0 1 2-2h1",key:"1mj8rg"}],["path",{d:"M9 6v12",key:"velyjx"}]],Uc=C("text-cursor-input",Vc);/**
587
- * @license lucide-react v1.38.0 - ISC
588
- *
589
- * This source code is licensed under the ISC license.
590
- * See the LICENSE file in the root directory of this source tree.
591
- */const Gc=[["path",{d:"M15 5h6",key:"1pr8yx"}],["path",{d:"M15 12h6",key:"upa0zy"}],["path",{d:"M3 19h18",key:"awlh7x"}],["path",{d:"m3 12 3.553-7.724a.5.5 0 0 1 .894 0L11 12",key:"6lvno8"}],["path",{d:"M3.92 10h6.16",key:"1tl8ex"}]],Yc=C("text-initial",Gc);/**
592
- * @license lucide-react v1.38.0 - ISC
593
- *
594
- * This source code is licensed under the ISC license.
595
- * See the LICENSE file in the root directory of this source tree.
596
- */const qc=[["path",{d:"M2 9a3 3 0 0 1 0 6v2a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-2a3 3 0 0 1 0-6V7a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2Z",key:"qn84l0"}],["path",{d:"M13 5v2",key:"dyzc3o"}],["path",{d:"M13 17v2",key:"1ont0d"}],["path",{d:"M13 11v2",key:"1wjjxi"}]],Wc=C("ticket",qc);/**
597
- * @license lucide-react v1.38.0 - ISC
598
- *
599
- * This source code is licensed under the ISC license.
600
- * See the LICENSE file in the root directory of this source tree.
601
- */const Kc=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],Xc=C("trash-2",Kc);/**
602
- * @license lucide-react v1.38.0 - ISC
603
- *
604
- * This source code is licensed under the ISC license.
605
- * See the LICENSE file in the root directory of this source tree.
606
- */const Zc=[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]],Jc=C("trending-up",Zc);/**
607
- * @license lucide-react v1.38.0 - ISC
608
- *
609
- * This source code is licensed under the ISC license.
610
- * See the LICENSE file in the root directory of this source tree.
611
- */const Qc=[["path",{d:"M10 14.66V17a1 1 0 0 1-1 1 2 2 0 0 0-2 2v2",key:"pwuv1l"}],["path",{d:"M14 14.66V17a1 1 0 0 0 1 1 2 2 0 0 1 2 2v2",key:"1y54w1"}],["path",{d:"M17.916 10H19.5A2.5 2.5 0 0 0 22 7.5V5a1 1 0 0 0-1-1h-3",key:"e30mpu"}],["path",{d:"M4 22h16",key:"57wxv0"}],["path",{d:"M6 9a6 6 0 0 0 12 0V3a1 1 0 0 0-1-1H7a1 1 0 0 0-1 1z",key:"1mhfuq"}],["path",{d:"M6.084 10H4.5A2.5 2.5 0 0 1 2 7.5V5a1 1 0 0 1 1-1h3",key:"i0yafy"}]],e1=C("trophy",Qc);/**
612
- * @license lucide-react v1.38.0 - ISC
613
- *
614
- * This source code is licensed under the ISC license.
615
- * See the LICENSE file in the root directory of this source tree.
616
- */const t1=[["path",{d:"m18.84 12.25 1.72-1.71h-.02a5.004 5.004 0 0 0-.12-7.07 5.006 5.006 0 0 0-6.95 0l-1.72 1.71",key:"yqzxt4"}],["path",{d:"m5.17 11.75-1.71 1.71a5.004 5.004 0 0 0 .12 7.07 5.006 5.006 0 0 0 6.95 0l1.71-1.71",key:"4qinb0"}],["line",{x1:"8",x2:"8",y1:"2",y2:"5",key:"1041cp"}],["line",{x1:"2",x2:"5",y1:"8",y2:"8",key:"14m1p5"}],["line",{x1:"16",x2:"16",y1:"19",y2:"22",key:"rzdirn"}],["line",{x1:"19",x2:"22",y1:"16",y2:"16",key:"ox905f"}]],n1=C("unlink",t1);/**
617
- * @license lucide-react v1.38.0 - ISC
618
- *
619
- * This source code is licensed under the ISC license.
620
- * See the LICENSE file in the root directory of this source tree.
621
- */const o1=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],u1=C("upload",o1);/**
622
- * @license lucide-react v1.38.0 - ISC
623
- *
624
- * This source code is licensed under the ISC license.
625
- * See the LICENSE file in the root directory of this source tree.
626
- */const r1=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],a1=C("user",r1);/**
627
- * @license lucide-react v1.38.0 - ISC
628
- *
629
- * This source code is licensed under the ISC license.
630
- * See the LICENSE file in the root directory of this source tree.
631
- */const i1=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]],s1=C("user-plus",i1);/**
632
- * @license lucide-react v1.38.0 - ISC
633
- *
634
- * This source code is licensed under the ISC license.
635
- * See the LICENSE file in the root directory of this source tree.
636
- */const l1=[["circle",{cx:"12",cy:"8",r:"5",key:"1hypcn"}],["path",{d:"M20 21a8 8 0 0 0-16 0",key:"rfgkzh"}]],c1=C("user-round",l1);/**
637
- * @license lucide-react v1.38.0 - ISC
638
- *
639
- * This source code is licensed under the ISC license.
640
- * See the LICENSE file in the root directory of this source tree.
641
- */const d1=[["path",{d:"M2 21a8 8 0 0 1 13.292-6",key:"bjp14o"}],["circle",{cx:"10",cy:"8",r:"5",key:"o932ke"}],["path",{d:"m16 19 2 2 4-4",key:"1b14m6"}]],h1=C("user-round-check",d1);/**
642
- * @license lucide-react v1.38.0 - ISC
643
- *
644
- * This source code is licensed under the ISC license.
645
- * See the LICENSE file in the root directory of this source tree.
646
- */const f1=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],p1=C("users",f1);/**
647
- * @license lucide-react v1.38.0 - ISC
648
- *
649
- * This source code is licensed under the ISC license.
650
- * See the LICENSE file in the root directory of this source tree.
651
- */const C1=[["path",{d:"M18 21a8 8 0 0 0-16 0",key:"3ypg7q"}],["circle",{cx:"10",cy:"8",r:"5",key:"o932ke"}],["path",{d:"M22 20c0-3.37-2-6.5-4-8a5 5 0 0 0-.45-8.3",key:"10s06x"}]],y1=C("users-round",C1);/**
652
- * @license lucide-react v1.38.0 - ISC
653
- *
654
- * This source code is licensed under the ISC license.
655
- * See the LICENSE file in the root directory of this source tree.
656
- */const m1=[["path",{d:"M11 4.702a.705.705 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298z",key:"uqj9uw"}],["path",{d:"M16 9a5 5 0 0 1 0 6",key:"1q6k2b"}],["path",{d:"M19.364 18.364a9 9 0 0 0 0-12.728",key:"ijwkga"}]],g1=C("volume-2",m1);/**
657
- * @license lucide-react v1.38.0 - ISC
658
- *
659
- * This source code is licensed under the ISC license.
660
- * See the LICENSE file in the root directory of this source tree.
661
- */const _1=[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]],E1=C("wrench",_1);/**
662
- * @license lucide-react v1.38.0 - ISC
663
- *
664
- * This source code is licensed under the ISC license.
665
- * See the LICENSE file in the root directory of this source tree.
666
- */const b1=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],S1=C("x",b1);/**
667
- * @license lucide-react v1.38.0 - ISC
668
- *
669
- * This source code is licensed under the ISC license.
670
- * See the LICENSE file in the root directory of this source tree.
671
- */const k1=[["path",{d:"M15.914 4a1.5 1.5 0 00-2.474-1.561l-9 9A1.5 1.5 0 005.5 14h4.002a.5.5 0 01.471.666L8.086 20a1.5 1.5 0 002.475 1.56l9-9A1.5 1.5 0 0018.5 10h-3.997a.5.5 0 01-.472-.667z",key:"1v7up4"}]],A1=C("zap",k1);/**
672
- * @license lucide-react v1.38.0 - ISC
673
- *
674
- * This source code is licensed under the ISC license.
675
- * See the LICENSE file in the root directory of this source tree.
676
- */const w1=[["path",{d:"M12 6v16",key:"nqf5sj"}],["path",{d:"m19 13 2-1a9 9 0 0 1-18 0l2 1",key:"y7qv08"}],["path",{d:"M9 11h6",key:"1fldmi"}],["circle",{cx:"12",cy:"4",r:"2",key:"muu5ef"}]],M1=C("anchor",w1);/**
677
- * @license lucide-react v1.38.0 - ISC
678
- *
679
- * This source code is licensed under the ISC license.
680
- * See the LICENSE file in the root directory of this source tree.
681
- */const N1=[["path",{d:"M19 9V6a2 2 0 0 0-2-2H7a2 2 0 0 0-2 2v3",key:"irtipd"}],["path",{d:"M3 16a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-5a2 2 0 0 0-4 0v1.5a.5.5 0 0 1-.5.5h-9a.5.5 0 0 1-.5-.5V11a2 2 0 0 0-4 0z",key:"1qyhux"}],["path",{d:"M5 18v2",key:"ppbyun"}],["path",{d:"M19 18v2",key:"gy7782"}]],T1=C("armchair",N1);/**
682
- * @license lucide-react v1.38.0 - ISC
683
- *
684
- * This source code is licensed under the ISC license.
685
- * See the LICENSE file in the root directory of this source tree.
686
- */const x1=[["path",{d:"m3 8 4-4 4 4",key:"11wl7u"}],["path",{d:"M7 4v16",key:"1glfcx"}],["path",{d:"M20 8h-5",key:"1vsyxs"}],["path",{d:"M15 10V6.5a2.5 2.5 0 0 1 5 0V10",key:"ag13bf"}],["path",{d:"M15 14h5l-5 6h5",key:"ur5jdg"}]],B1=C("arrow-up-a-z",x1);/**
687
- * @license lucide-react v1.38.0 - ISC
688
- *
689
- * This source code is licensed under the ISC license.
690
- * See the LICENSE file in the root directory of this source tree.
691
- */const D1=[["path",{d:"M5 21v-6",key:"1hz6c0"}],["path",{d:"M12 21V3",key:"1lcnhd"}],["path",{d:"M19 21V9",key:"unv183"}]],v1=C("chart-no-axes-column",D1);/**
692
- * @license lucide-react v1.38.0 - ISC
693
- *
694
- * This source code is licensed under the ISC license.
695
- * See the LICENSE file in the root directory of this source tree.
696
- */const O1=[["path",{d:"M8 2v3",key:"1ioesn"}],["path",{d:"M16 2v3",key:"otl347"}],["rect",{x:"3",y:"3",width:"18",height:"18",rx:"2",key:"h1oib"}],["path",{d:"M3 9h18",key:"1pudct"}]],L1=C("calendar",O1);/**
697
- * @license lucide-react v1.38.0 - ISC
698
- *
699
- * This source code is licensed under the ISC license.
700
- * See the LICENSE file in the root directory of this source tree.
701
- */const R1=[["path",{d:"M19 17h2c.6 0 1-.4 1-1v-3c0-.9-.7-1.7-1.5-1.9C18.7 10.6 16 10 16 10s-1.3-1.4-2.2-2.3c-.5-.4-1.1-.7-1.8-.7H5c-.6 0-1.1.4-1.4.9l-1.4 2.9A3.7 3.7 0 0 0 2 12v4c0 .6.4 1 1 1h2",key:"5owen"}],["circle",{cx:"7",cy:"17",r:"2",key:"u2ysq9"}],["path",{d:"M9 17h6",key:"r8uit2"}],["circle",{cx:"17",cy:"17",r:"2",key:"axvx0g"}]],I1=C("car",R1);/**
702
- * @license lucide-react v1.38.0 - ISC
703
- *
704
- * This source code is licensed under the ISC license.
705
- * See the LICENSE file in the root directory of this source tree.
706
- */const j1=[["path",{d:"M10 2v2",key:"7u0qdc"}],["path",{d:"M14 2v2",key:"6buw04"}],["path",{d:"M16 8a1 1 0 0 1 1 1v8a4 4 0 0 1-4 4H7a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1h14a4 4 0 1 1 0 8h-1",key:"pwadti"}],["path",{d:"M6 2v2",key:"colzsn"}]],P1=C("coffee",j1);/**
707
- * @license lucide-react v1.38.0 - ISC
708
- *
709
- * This source code is licensed under the ISC license.
710
- * See the LICENSE file in the root directory of this source tree.
711
- */const $1=[["line",{x1:"6",x2:"10",y1:"11",y2:"11",key:"1gktln"}],["line",{x1:"8",x2:"8",y1:"9",y2:"13",key:"qnk9ow"}],["line",{x1:"15",x2:"15.01",y1:"12",y2:"12",key:"krot7o"}],["line",{x1:"18",x2:"18.01",y1:"10",y2:"10",key:"1lcuu1"}],["path",{d:"M17.32 5H6.68a4 4 0 0 0-3.978 3.59c-.006.052-.01.101-.017.152C2.604 9.416 2 14.456 2 16a3 3 0 0 0 3 3c1 0 1.5-.5 2-1l1.414-1.414A2 2 0 0 1 9.828 16h4.344a2 2 0 0 1 1.414.586L17 18c.5.5 1 1 2 1a3 3 0 0 0 3-3c0-1.545-.604-6.584-.685-7.258-.007-.05-.011-.1-.017-.151A4 4 0 0 0 17.32 5z",key:"mfqc10"}]],F1=C("gamepad-2",$1);/**
712
- * @license lucide-react v1.38.0 - ISC
713
- *
714
- * This source code is licensed under the ISC license.
715
- * See the LICENSE file in the root directory of this source tree.
716
- */const H1=[["polyline",{points:"22 12 16 12 14 15 10 15 8 12 2 12",key:"o97t9d"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}]],z1=C("inbox",H1);/**
717
- * @license lucide-react v1.38.0 - ISC
718
- *
719
- * This source code is licensed under the ISC license.
720
- * See the LICENSE file in the root directory of this source tree.
721
- */const V1=[["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}],["path",{d:"M3 10a2 2 0 0 0 2 2h3",key:"1npucw"}],["path",{d:"M3 5v12a2 2 0 0 0 2 2h3",key:"x1gjn2"}]],U1=C("list-tree",V1);/**
722
- * @license lucide-react v1.38.0 - ISC
723
- *
724
- * This source code is licensed under the ISC license.
725
- * See the LICENSE file in the root directory of this source tree.
726
- */const G1=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}],["path",{d:"M12 11h.01",key:"z322tv"}],["path",{d:"M16 11h.01",key:"xkw8gn"}],["path",{d:"M8 11h.01",key:"1dfujw"}]],Y1=C("message-square-more",G1);/**
727
- * @license lucide-react v1.38.0 - ISC
728
- *
729
- * This source code is licensed under the ISC license.
730
- * See the LICENSE file in the root directory of this source tree.
731
- */const q1=[["path",{d:"M5 12h14",key:"1ays0h"}]],W1=C("minus",q1);/**
732
- * @license lucide-react v1.38.0 - ISC
733
- *
734
- * This source code is licensed under the ISC license.
735
- * See the LICENSE file in the root directory of this source tree.
736
- */const K1=[["circle",{cx:"18",cy:"5",r:"3",key:"gq8acd"}],["circle",{cx:"6",cy:"12",r:"3",key:"w7nqdw"}],["circle",{cx:"18",cy:"19",r:"3",key:"1xt0gg"}],["line",{x1:"8.59",x2:"15.42",y1:"13.51",y2:"17.49",key:"47mynk"}],["line",{x1:"15.41",x2:"8.59",y1:"6.51",y2:"10.49",key:"1n3mei"}]],X1=C("share-2",K1);/**
737
- * @license lucide-react v1.38.0 - ISC
738
- *
739
- * This source code is licensed under the ISC license.
740
- * See the LICENSE file in the root directory of this source tree.
741
- */const Z1=[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],J1=C("sparkles",Z1);/**
742
- * @license lucide-react v1.38.0 - ISC
743
- *
744
- * This source code is licensed under the ISC license.
745
- * See the LICENSE file in the root directory of this source tree.
746
- */const Q1=[["path",{d:"M12 4v16",key:"1654pz"}],["path",{d:"M4 7V5a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v2",key:"e0r10z"}],["path",{d:"M9 20h6",key:"s66wpe"}]],e0=C("type",Q1);/**
747
- * @license lucide-react v1.38.0 - ISC
748
- *
749
- * This source code is licensed under the ISC license.
750
- * See the LICENSE file in the root directory of this source tree.
751
- */const t0=[["path",{d:"M11 4.702a.705.705 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298z",key:"uqj9uw"}]],n0=C("volume",t0);/**
752
- * @license lucide-react v1.38.0 - ISC
753
- *
754
- * This source code is licensed under the ISC license.
755
- * See the LICENSE file in the root directory of this source tree.
756
- */const o0=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],u0=C("chevron-down",o0);/**
757
- * @license lucide-react v1.38.0 - ISC
758
- *
759
- * This source code is licensed under the ISC license.
760
- * See the LICENSE file in the root directory of this source tree.
761
- */const r0=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],a0=C("chevron-up",r0);/**
762
- * @license lucide-react v1.38.0 - ISC
763
- *
764
- * This source code is licensed under the ISC license.
765
- * See the LICENSE file in the root directory of this source tree.
766
- */const i0=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],s0=C("circle",i0);/**
767
- * @license lucide-react v1.38.0 - ISC
768
- *
769
- * This source code is licensed under the ISC license.
770
- * See the LICENSE file in the root directory of this source tree.
771
- */const l0=[["path",{d:"M13.73 4a2 2 0 0 0-3.46 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z",key:"14u9p9"}]],c0=C("triangle",l0);/**
772
- * @license lucide-react v1.38.0 - ISC
773
- *
774
- * This source code is licensed under the ISC license.
775
- * See the LICENSE file in the root directory of this source tree.
776
- */const d0=[["path",{d:"M4 5h16",key:"1tepv9"}],["path",{d:"M4 12h16",key:"1lakjw"}],["path",{d:"M4 19h16",key:"1djgab"}]],h0=C("menu",d0);/**
777
- * @license lucide-react v1.38.0 - ISC
778
- *
779
- * This source code is licensed under the ISC license.
780
- * See the LICENSE file in the root directory of this source tree.
781
- */const f0=[["path",{d:"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",key:"kfwtm"}]],p0=C("moon",f0);/**
782
- * @license lucide-react v1.38.0 - ISC
783
- *
784
- * This source code is licensed under the ISC license.
785
- * See the LICENSE file in the root directory of this source tree.
786
- */const C0=[["path",{d:"M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z",key:"emmmcr"}],["path",{d:"M7 10v12",key:"1qc93n"}]],y0=C("thumbs-up",C0),fu={"alert-triangle":cu,"align-start-vertical":Ya,anchor:M1,armchair:T1,"arrow-down":Wa,"arrow-left":Xa,"arrow-right":Ja,"arrow-right-left":ei,"arrow-up-a-z":B1,"audio-lines":ni,baby:ui,ban:ai,"bar-chart-2":v1,bell:si,"book-marked":ci,"book-open":hi,"bow-arrow":pi,braces:yi,bug:gi,calendar:L1,"calendar-check":Ei,"calendar-days":Si,camera:Ai,car:I1,"chart-column":Mi,"chart-line":Ti,"chart-pie":Bi,check:vi,"chevron-down":u0,"chevron-left":Li,"chevron-right":Ii,"chevron-up":a0,circle:s0,"clipboard-list":Pi,coffee:P1,combine:Fi,copy:zi,"credit-card":Ui,database:Yi,diff:Wi,download:Xi,ear:Ji,edit:es,"edit-2":ns,"edit-3":us,ellipsis:du,eraser:is,"external-link":ls,eye:ds,"file-text":fs,"flip-horizontal":Cs,"folder-open":ms,"folder-plus":_s,gamepad:bs,"gamepad-2":F1,gavel:ks,"git-merge":ws,globe:Ns,headphones:xs,heart:Ds,home:Os,inbox:z1,info:Rs,"key-round":js,landmark:$s,layers:Hs,"layout-dashboard":Vs,leaf:Gs,lightbulb:qs,link:Ks,"link-2":Zs,"link-2-off":Qs,list:tl,"list-checks":ol,"list-ordered":rl,"list-tree":U1,loader:il,"log-out":ll,mail:dl,"map-pin":fl,menu:h0,"message-circle":Cl,"message-circle-question-mark":ml,"message-square":_l,"message-square-more":Y1,"message-square-text":bl,minus:W1,"minus-circle":kl,moon:p0,"more-horizontal":du,package:wl,palette:Nl,"party-popper":xl,pause:Dl,pencil:Ol,phone:Rl,play:jl,"play-circle":$l,plus:Hl,printer:Vl,"refresh-cw":Gl,repeat:ql,replace:Kl,rocket:Zl,"rotate-ccw":Ql,"rotate-cw":tc,salad:oc,"scan-search":rc,search:cc,"circle-alert":hu,"alert-circle":hu,"check-circle":sc,scissors:hc,"search-x":pc,send:yc,settings:gc,"share-2":X1,"shield-check":Ec,"shopping-cart":Sc,shuffle:Ac,"skip-back":Mc,"skip-forward":Tc,sparkles:J1,square:Bc,star:vc,store:Lc,"sun-medium":Ic,table:Pc,"table-2":Fc,terminal:zc,"text-cursor-input":Uc,"text-initial":Yc,"thumbs-up":y0,ticket:Wc,triangle:c0,"trash-2":Xc,"trending-up":Jc,"triangle-alert":cu,trophy:e1,type:e0,unlink:n1,upload:u1,user:a1,"user-plus":s1,"user-round":c1,"user-round-check":h1,users:p1,"users-round":y1,volume:n0,"volume-2":g1,wrench:E1,x:S1,zap:A1};function m0(e){return fu[e]??null}const pu=new Set;function g0(e){return ja&&!(e in fu)&&!pu.has(e)&&(pu.add(e),console.warn(`[ihabdevteam-core] lucide \uC544\uC774\uCF58 '${e}' \uC774 \uC815\uC801 \uBAA9\uB85D\uC5D0 \uC5C6\uC5B4 \uB80C\uB354\uB418\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4. utils/lucideIconSet.ts \uC758 STATIC_LUCIDE_ICONS \uC5D0 \uCD94\uAC00\uD558\uC138\uC694.`)),Promise.resolve(null)}const _0=e=>e.replace(/([A-Z]+)([A-Z][a-z])/g,"$1-$2").replace(/([a-z0-9])([A-Z])/g,"$1-$2").replace(/([A-Za-z])([0-9])/g,"$1-$2").replace(/[_ ]+/g,"-").toLowerCase();function E0(e){const t=e.toLowerCase();if(t.startsWith("http://")||t.startsWith("https://")||t.startsWith("data:")||e.includes("/assets/"))return null;const n=(e.split("/").pop()||"").replace(/\.svg$/,"");return n?_0(n):null}const Cu=new Map;function b0(e){const t=typeof e=="string"?E0(e):null,n=t?m0(t)??Cu.get(t)??null:null,[o,u]=l.useState(null);return l.useEffect(()=>{if(!t||n)return;let r=!1;return g0(t).then(i=>{Cu.set(t,i),r||u(i)}),()=>{r=!0}},[t,n]),n??o}/*! @license DOMPurify 3.4.14 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.4.14/LICENSE */function yu(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,o=Array(t);n<t;n++)o[n]=e[n];return o}function S0(e){if(Array.isArray(e))return e}function k0(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var o,u,r,i,s=[],d=!0,p=!1;try{if(r=(n=n.call(e)).next,t!==0)for(;!(d=(o=r.call(n)).done)&&(s.push(o.value),s.length!==t);d=!0);}catch(f){p=!0,u=f}finally{try{if(!d&&n.return!=null&&(i=n.return(),Object(i)!==i))return}finally{if(p)throw u}}return s}}function A0(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
787
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function w0(e,t){return S0(e)||k0(e,t)||M0(e,t)||A0()}function M0(e,t){if(e){if(typeof e=="string")return yu(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?yu(e,t):void 0}}const mu=Object.entries,gu=Object.setPrototypeOf,N0=Object.isFrozen,T0=Object.getPrototypeOf,x0=Object.getOwnPropertyDescriptor;let Ce=Object.freeze,ge=Object.seal,vt=Object.create,_u=typeof Reflect<"u"&&Reflect,Wn=_u.apply,Kn=_u.construct;Ce||(Ce=function(t){return t}),ge||(ge=function(t){return t}),Wn||(Wn=function(t,n){for(var o=arguments.length,u=new Array(o>2?o-2:0),r=2;r<o;r++)u[r-2]=arguments[r];return t.apply(n,u)}),Kn||(Kn=function(t){for(var n=arguments.length,o=new Array(n>1?n-1:0),u=1;u<n;u++)o[u-1]=arguments[u];return new t(...o)});const St=fe(Array.prototype.forEach),B0=fe(Array.prototype.lastIndexOf),Eu=fe(Array.prototype.pop),qt=fe(Array.prototype.push),D0=fe(Array.prototype.splice),Ot=Array.isArray,Wt=fe(String.prototype.toLowerCase),Xn=fe(String.prototype.toString),bu=fe(String.prototype.match),Kt=fe(String.prototype.replace),Su=fe(String.prototype.indexOf),v0=fe(String.prototype.trim),O0=fe(Number.prototype.toString),L0=fe(Boolean.prototype.toString),ku=typeof BigInt>"u"?null:fe(BigInt.prototype.toString),Au=typeof Symbol>"u"?null:fe(Symbol.prototype.toString),De=fe(Object.prototype.hasOwnProperty),Xt=fe(Object.prototype.toString),we=fe(RegExp.prototype.test),kt=R0(TypeError);function fe(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,o=new Array(n>1?n-1:0),u=1;u<n;u++)o[u-1]=arguments[u];return Wn(e,t,o)}}function R0(e){return function(){for(var t=arguments.length,n=new Array(t),o=0;o<t;o++)n[o]=arguments[o];return Kn(e,n)}}function J(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Wt;if(gu&&gu(e,null),!Ot(t))return e;let o=t.length;for(;o--;){let u=t[o];if(typeof u=="string"){const r=n(u);r!==u&&(N0(t)||(t[o]=r),u=r)}e[u]=!0}return e}function I0(e){for(let t=0;t<e.length;t++)De(e,t)||(e[t]=null);return e}function Re(e){const t=vt(null);for(const o of mu(e)){var n=w0(o,2);const u=n[0],r=n[1];De(e,u)&&(Ot(r)?t[u]=I0(r):r&&typeof r=="object"&&r.constructor===Object?t[u]=Re(r):t[u]=r)}return t}function j0(e){switch(typeof e){case"string":return e;case"number":return O0(e);case"boolean":return L0(e);case"bigint":return ku?ku(e):"0";case"symbol":return Au?Au(e):"Symbol()";case"undefined":return Xt(e);case"function":case"object":{if(e===null)return Xt(e);const t=e,n=qe(t,"toString");if(typeof n=="function"){const o=n(t);return typeof o=="string"?o:Xt(o)}return Xt(e)}default:return Xt(e)}}function qe(e,t){for(;e!==null;){const o=x0(e,t);if(o){if(o.get)return fe(o.get);if(typeof o.value=="function")return fe(o.value)}e=T0(e)}function n(){return null}return n}function P0(e){try{return we(e,""),!0}catch{return!1}}const wu=Ce(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Zn=Ce(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Jn=Ce(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),$0=Ce(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),Qn=Ce(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),F0=Ce(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Mu=Ce(["#text"]),Nu=Ce(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","command","commandfor","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns"]),eo=Ce(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dominant-baseline","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","pointer-events","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-orientation","text-rendering","textlength","type","u1","u2","unicode","values","vector-effect","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Tu=Ce(["accent","accentunder","align","bevelled","close","columnalign","columnlines","columnspacing","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lquote","lspace","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Sn=Ce(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),H0=ge(/{{[\w\W]*|^[\w\W]*}}/g),z0=ge(/<%[\w\W]*|^[\w\W]*%>/g),V0=ge(/\${[\w\W]*/g),U0=ge(/^data-[\-\w.\u00B7-\uFFFF]+$/),G0=ge(/^aria-[\-\w]+$/),xu=ge(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Y0=ge(/^(?:\w+script|data):/i),q0=ge(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),W0=ge(/^html$/i),K0=ge(/^[a-z][.\w]*(-[.\w]+)+$/i),Bu=ge(/<[/\w!]/g),Du=ge(/<[/\w]/g),X0=ge(/<\/no(script|embed|frames)/i),Z0=ge(/\/>/i),Ie={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},vu=["style","script","xmp","iframe","noembed","noframes","plaintext","noscript"],J0=Ce(J({},vu)),Q0=(function(){const e={};return St(vu,t=>{e[t]=ge(new RegExp("</"+t+"(?=[\\t\\n\\f\\r />])","i"))}),Ce(e)})(),ed=function(){return typeof window>"u"?null:window},td=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let o=null;const u="data-tt-policy-suffix";n&&n.hasAttribute(u)&&(o=n.getAttribute(u));const r="dompurify"+(o?"#"+o:"");try{return t.createPolicy(r,{createHTML(i){return i},createScriptURL(i){return i}})}catch{return console.warn("TrustedTypes policy "+r+" could not be created."),null}},Ou=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},ht=function(t,n,o,u){return De(t,n)&&Ot(t[n])?J(u.base?Re(u.base):{},t[n],u.transform):o},to=function(t,n,o){const u=De(t,n)?t[n]:void 0;return u&&typeof u=="object"?Re(u):o()};function Lu(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ed();const t=N=>Lu(N);if(t.version="3.4.14",t.removed=[],!e||!e.document||e.document.nodeType!==Ie.document||!e.Element)return t.isSupported=!1,t;let n=e.document;const o=n,u=o.currentScript;e.DocumentFragment;const r=e.HTMLTemplateElement,i=e.Node,s=e.Element,d=e.NodeFilter,p=e.NamedNodeMap;p===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;const f=e.DOMParser,y=e.trustedTypes,c=s.prototype,m=qe(c,"cloneNode"),S=qe(c,"remove"),w=qe(c,"nextSibling"),_=qe(c,"childNodes"),g=qe(c,"parentNode"),k=qe(c,"shadowRoot"),A=qe(c,"attributes"),T=i&&i.prototype?qe(i.prototype,"nodeType"):null,v=i&&i.prototype?qe(i.prototype,"nodeName"):null,D=i&&i.prototype?qe(i.prototype,"ownerDocument"):null,I=function(a){return T?T(a):a.nodeType},$=function(a){return v?v(a):a.nodeName};if(typeof r=="function"){const N=n.createElement("template");N.content&&N.content.ownerDocument&&(n=N.content.ownerDocument)}let G,P="",Q,Y=!1,W=0;const F=function(){if(W>0)throw kt('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},B=function(a){F(),W++;try{return G.createHTML(a)}finally{W--}},O=function(a){F(),W++;try{return G.createScriptURL(a)}finally{W--}},ye=function(){return Y||(Q=td(y,u),Y=!0),Q},Z=n,ee=Z.implementation,M=Z.createNodeIterator,j=Z.createDocumentFragment,ae=Z.getElementsByTagName,ne=o.importNode;let q=Ou();t.isSupported=typeof mu=="function"&&typeof g=="function"&&ee&&ee.createHTMLDocument!==void 0;const Me=H0,X=z0,he=V0,H=U0,He=G0,ze=Y0,je=q0,tt=K0;let Ve=xu,te=null;const nt=J({},[...wu,...Zn,...Jn,...Qn,...Mu]);let oe=null;const pt=J({},[...Nu,...eo,...Tu,...Sn]);let pe=Object.seal(vt(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),E=null,z=null;const L=Object.seal(vt(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let K=!0,ie=!0,Pe=!1,ve=!0,be=!1,Ne=!0,Se=!1,Ct=!1,We=null,ot=null,Ue=!1,$e=!1,lt=!1,yt=!1,Rt=!0,me=!1;const At="user-content-";let wt=!0,ut=!1,ct={},Ke=null;const ue=J({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]);let Xe=null;const It=J({},["audio","video","img","source","image","track"]);let Mt=null;const po=J({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),rn="http://www.w3.org/1998/Math/MathML",an="http://www.w3.org/2000/svg",Ze="http://www.w3.org/1999/xhtml";let Nt=Ze,Bn=!1,Dn=null;const nr=J({},[rn,an,Ze],Xn),Co=Ce(["mi","mo","mn","ms","mtext"]);let vn=J({},Co);const yo=Ce(["annotation-xml"]);let On=J({},yo);const or=J({},["title","style","font","a","script"]);let jt=null;const ur=["application/xhtml+xml","text/html"],rr="text/html";let de=null,Tt=null;const ar=n.createElement("form"),mo=function(a){return a instanceof RegExp||a instanceof Function},Ln=function(){let a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(Tt&&Tt===a)return;(!a||typeof a!="object")&&(a={}),a=Re(a),jt=ur.indexOf(a.PARSER_MEDIA_TYPE)===-1?rr:a.PARSER_MEDIA_TYPE,de=jt==="application/xhtml+xml"?Xn:Wt,te=ht(a,"ALLOWED_TAGS",nt,{transform:de}),oe=ht(a,"ALLOWED_ATTR",pt,{transform:de}),Dn=ht(a,"ALLOWED_NAMESPACES",nr,{transform:Xn}),Mt=ht(a,"ADD_URI_SAFE_ATTR",po,{transform:de,base:po}),Xe=ht(a,"ADD_DATA_URI_TAGS",It,{transform:de,base:It}),Ke=ht(a,"FORBID_CONTENTS",ue,{transform:de}),E=ht(a,"FORBID_TAGS",Re({}),{transform:de}),z=ht(a,"FORBID_ATTR",Re({}),{transform:de}),ct=De(a,"USE_PROFILES")?a.USE_PROFILES&&typeof a.USE_PROFILES=="object"?Re(a.USE_PROFILES):a.USE_PROFILES:!1,K=a.ALLOW_ARIA_ATTR!==!1,ie=a.ALLOW_DATA_ATTR!==!1,Pe=a.ALLOW_UNKNOWN_PROTOCOLS||!1,ve=a.ALLOW_SELF_CLOSE_IN_ATTR!==!1,be=a.SAFE_FOR_TEMPLATES||!1,Ne=a.SAFE_FOR_XML!==!1,Se=a.WHOLE_DOCUMENT||!1,$e=a.RETURN_DOM||!1,lt=a.RETURN_DOM_FRAGMENT||!1,yt=a.RETURN_TRUSTED_TYPE||!1,Ue=a.FORCE_BODY||!1,Rt=a.SANITIZE_DOM!==!1,me=a.SANITIZE_NAMED_PROPS||!1,wt=a.KEEP_CONTENT!==!1,ut=a.IN_PLACE||!1,Ve=P0(a.ALLOWED_URI_REGEXP)?a.ALLOWED_URI_REGEXP:xu,Nt=typeof a.NAMESPACE=="string"?a.NAMESPACE:Ze,vn=to(a,"MATHML_TEXT_INTEGRATION_POINTS",()=>J({},Co)),On=to(a,"HTML_INTEGRATION_POINTS",()=>J({},yo));const h=to(a,"CUSTOM_ELEMENT_HANDLING",()=>vt(null));if(pe=vt(null),De(h,"tagNameCheck")&&mo(h.tagNameCheck)&&(pe.tagNameCheck=h.tagNameCheck),De(h,"attributeNameCheck")&&mo(h.attributeNameCheck)&&(pe.attributeNameCheck=h.attributeNameCheck),De(h,"allowCustomizedBuiltInElements")&&typeof h.allowCustomizedBuiltInElements=="boolean"&&(pe.allowCustomizedBuiltInElements=h.allowCustomizedBuiltInElements),ge(pe),be&&(ie=!1),lt&&($e=!0),ct&&(te=J({},Mu),oe=vt(null),ct.html===!0&&(J(te,wu),J(oe,Nu)),ct.svg===!0&&(J(te,Zn),J(oe,eo),J(oe,Sn)),ct.svgFilters===!0&&(J(te,Jn),J(oe,eo),J(oe,Sn)),ct.mathMl===!0&&(J(te,Qn),J(oe,Tu),J(oe,Sn))),L.tagCheck=null,L.attributeCheck=null,De(a,"ADD_TAGS")&&(typeof a.ADD_TAGS=="function"?L.tagCheck=a.ADD_TAGS:Ot(a.ADD_TAGS)&&(te===nt&&(te=Re(te)),J(te,a.ADD_TAGS,de))),De(a,"ADD_ATTR")&&(typeof a.ADD_ATTR=="function"?L.attributeCheck=a.ADD_ATTR:Ot(a.ADD_ATTR)&&(oe===pt&&(oe=Re(oe)),J(oe,a.ADD_ATTR,de))),De(a,"ADD_FORBID_CONTENTS")&&Ot(a.ADD_FORBID_CONTENTS)&&(Ke===ue&&(Ke=Re(Ke)),J(Ke,a.ADD_FORBID_CONTENTS,de)),wt&&(te["#text"]=!0),Se&&J(te,["html","head","body"]),te.table&&(J(te,["tbody"]),delete E.tbody),a.TRUSTED_TYPES_POLICY){if(typeof a.TRUSTED_TYPES_POLICY.createHTML!="function")throw kt('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof a.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw kt('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');const b=G;G=a.TRUSTED_TYPES_POLICY;try{P=B("")}catch(x){throw G=b,x}}else a.TRUSTED_TYPES_POLICY===null?(G=void 0,P=""):(G===void 0&&(G=ye()),G&&typeof P=="string"&&(P=B("")));Ce&&Ce(a),Tt=a},go=J({},[...Zn,...Jn,...$0]),_o=J({},[...Qn,...F0]),ir=function(a,h,b){return h.namespaceURI===Ze?a==="svg":h.namespaceURI===rn?a==="svg"&&(b==="annotation-xml"||vn[b]):!!go[a]},sr=function(a,h,b){return h.namespaceURI===Ze?a==="math":h.namespaceURI===an?a==="math"&&On[b]:!!_o[a]},lr=function(a,h,b){return h.namespaceURI===an&&!On[b]||h.namespaceURI===rn&&!vn[b]?!1:!_o[a]&&(or[a]||!go[a])},cr=function(a){let h=g(a);(!h||!h.tagName)&&(h={namespaceURI:Nt,tagName:"template"});const b=Wt(a.tagName),x=Wt(h.tagName);return Dn[a.namespaceURI]?a.namespaceURI===an?ir(b,h,x):a.namespaceURI===rn?sr(b,h,x):a.namespaceURI===Ze?lr(b,h,x):!!(jt==="application/xhtml+xml"&&Dn[a.namespaceURI]):!1},dt=function(a){qt(t.removed,{element:a});try{g(a).removeChild(a)}catch{if(S(a),!g(a))throw kt("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},Eo=function(a,h,b){try{a.removeAttributeNode(h)}catch{try{a.removeAttribute(b)}catch{}}},sn=function(a){ln(a);const h=_(a);if(h){const x=[];St(h,R=>{qt(x,R)}),St(x,R=>{try{S(R)}catch{}})}const b=A(a);if(b)for(let x=b.length-1;x>=0;--x){const R=b[x],U=R&&R.name;typeof U=="string"&&Eo(a,R,U)}},mt=function(a,h,b){if(!b)try{b=h.getAttributeNode(a)}catch{b=null}qt(t.removed,{attribute:b||null,from:h});try{b?h.removeAttributeNode(b):h.removeAttribute(a)}catch{try{h.removeAttribute(a)}catch{}}if(a==="is")if($e||lt)try{dt(h)}catch{}else try{h.setAttribute(a,"")}catch{}},dr=function(a){const h=A(a);if(h)for(let b=h.length-1;b>=0;--b){const x=h[b],R=x&&x.name;typeof R!="string"||oe[de(R)]||Eo(a,x,R)}},ln=function(a){const h=[a];for(;h.length>0;){const b=h.pop();I(b)===Ie.element&&dr(b);const R=_(b);if(R)for(let U=R.length-1;U>=0;--U)h.push(R[U])}},bo=function(a,h){return Ne?a==="patchsrc"?!0:a==="for"&&h!=="label"&&h!=="output":!1},hr=function(a){if(!Ne)return;const h=[a];for(;h.length>0;){const b=h.pop(),x=I(b);if(x===Ie.processingInstruction||x===Ie.comment&&we(Du,b.data)){try{S(b)}catch{}continue}if(x===Ie.element){const U=b,se=de($(b));try{U.hasAttribute&&U.hasAttribute("patchsrc")&&U.removeAttribute("patchsrc"),U.hasAttribute&&U.hasAttribute("for")&&bo("for",se)&&U.removeAttribute("for")}catch{}}const R=_(b);if(R)for(let U=R.length-1;U>=0;--U)h.push(R[U])}},So=function(a){let h=null,b=null;if(Ue)a="<remove></remove>"+a;else{const U=bu(a,/^[\r\n\t ]+/);b=U&&U[0]}jt==="application/xhtml+xml"&&Nt===Ze&&(a='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+a+"</body></html>");const x=G?B(a):a;if(Nt===Ze)try{h=new f().parseFromString(x,jt)}catch{}if(!h||!h.documentElement){h=ee.createDocument(Nt,"template",null);try{h.documentElement.innerHTML=Bn?P:x}catch{}}const R=h.body||h.documentElement;return a&&b&&R.insertBefore(n.createTextNode(b),R.childNodes[0]||null),Nt===Ze?ae.call(h,Se?"html":"body")[0]:Se?h.documentElement:R},ko=function(a){const h=D?D(a):a.ownerDocument;return M.call(h||a,a,d.SHOW_ELEMENT|d.SHOW_COMMENT|d.SHOW_TEXT|d.SHOW_PROCESSING_INSTRUCTION|d.SHOW_CDATA_SECTION,null)},cn=function(a){return a=Kt(a,Me," "),a=Kt(a,X," "),a=Kt(a,he," "),a},Rn=function(a){var h;a.normalize();const b=D?D(a):a.ownerDocument,x=M.call(b||a,a,d.SHOW_TEXT|d.SHOW_COMMENT|d.SHOW_CDATA_SECTION|d.SHOW_PROCESSING_INSTRUCTION,null);let R=x.nextNode();for(;R;)R.data=cn(R.data),R=x.nextNode();const U=(h=a.querySelectorAll)===null||h===void 0?void 0:h.call(a,"template");U&&St(U,se=>{xt(se.content)&&Rn(se.content)})},dn=function(a){const h=v?v(a):null;return typeof h!="string"||de(h)!=="form"?!1:typeof a.nodeName!="string"||typeof a.textContent!="string"||typeof a.removeChild!="function"||a.attributes!==A(a)||typeof a.removeAttribute!="function"||typeof a.setAttribute!="function"||typeof a.namespaceURI!="string"||typeof a.insertBefore!="function"||typeof a.hasChildNodes!="function"||a.nodeType!==T(a)||a.childNodes!==_(a)},xt=function(a){if(!T||typeof a!="object"||a===null)return!1;try{return T(a)===Ie.documentFragment}catch{return!1}},Pt=function(a){if(!T||typeof a!="object"||a===null)return!1;try{return typeof T(a)=="number"}catch{return!1}};function Je(N,a,h){N.length!==0&&St(N,b=>{b.call(t,a,h,Tt)})}const fr=function(a,h){return!!(Ne&&a.hasChildNodes()&&!Pt(a.firstElementChild)&&we(Bu,a.textContent)&&we(Bu,a.innerHTML)||Ne&&a.namespaceURI===Ze&&J0[h]&&(Pt(a.firstElementChild)||typeof a.textContent=="string"&&we(Q0[h],a.textContent))||a.nodeType===Ie.processingInstruction||Ne&&a.nodeType===Ie.comment&&we(Du,a.data))},hn=function(a,h){if(a instanceof RegExp)return we(a,h);if(a instanceof Function){for(var b=arguments.length,x=new Array(b>2?b-2:0),R=2;R<b;R++)x[R-2]=arguments[R];return!!a(h,...x)}return!1},pr=function(a,h,b){if(!E[h]&&To(h)&&hn(pe.tagNameCheck,h))return!1;if(wt&&!Ke[h]){const x=g(a),R=_(a);if(R&&x){const U=R.length;for(let se=U-1;se>=0;--se){const ce=a===b?m(R[se],!0):R[se];x.insertBefore(ce,w(a))}}}return dt(a),!0},Ao=function(a,h,b,x){return a.length===0?h:h===b||h===x?Re(h):h},wo=function(a,h){return a===h||g(a)!==null?!1:(ut&&ln(a),!0)},Mo=function(a,h){if(Je(q.beforeSanitizeElements,a,null),wo(a,h))return!0;if(dn(a))return dt(a),!0;const b=de($(a));if(te=Ao(q.uponSanitizeElement,te,nt,We),Je(q.uponSanitizeElement,a,{tagName:b,allowedTags:te}),wo(a,h))return!0;if(fr(a,b))return dt(a),!0;if(E[b]||!(L.tagCheck instanceof Function&&L.tagCheck(b))&&!te[b]){const R=pr(a,b,h);return R===!1&&Je(q.afterSanitizeElements,a,null),R}if(I(a)===Ie.element&&!cr(a)||(b==="noscript"||b==="noembed"||b==="noframes")&&we(X0,a.innerHTML))return dt(a),!0;if(be&&a.nodeType===Ie.text){const R=cn(a.textContent);a.textContent!==R&&(qt(t.removed,{element:a.cloneNode()}),a.textContent=R)}return Je(q.afterSanitizeElements,a,null),!1},No=function(a,h,b){if(z[h]||bo(h,a)||Rt&&(h==="id"||h==="name")&&(b in n||b in ar))return!1;const x=oe[h]||L.attributeCheck instanceof Function&&L.attributeCheck(h,a);return ie&&we(H,h)||K&&we(He,h)?!0:x?Mt[h]||we(Ve,Kt(b,je,""))||(h==="src"||h==="xlink:href"||h==="href")&&a!=="script"&&Su(b,"data:")===0&&Xe[a]||Pe&&!we(ze,Kt(b,je,""))?!0:!b:To(a)&&hn(pe.tagNameCheck,a)&&hn(pe.attributeNameCheck,h,a)||h==="is"&&pe.allowCustomizedBuiltInElements&&hn(pe.tagNameCheck,b)},Cr=J({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),To=function(a){return!Cr[Wt(a)]&&we(tt,a)},yr=function(a,h,b,x){if(G&&typeof y=="object"&&typeof y.getAttributeType=="function"&&!b)switch(y.getAttributeType(a,h)){case"TrustedHTML":return B(x);case"TrustedScriptURL":return O(x)}return x},mr=function(a,h,b,x){try{b?a.setAttributeNS(b,h,x):a.setAttribute(h,x),dn(a)?dt(a):Eu(t.removed)}catch{mt(h,a)}},xo=function(a){Je(q.beforeSanitizeAttributes,a,null);const h=a.attributes;if(!h||dn(a))return;oe=Ao(q.uponSanitizeAttribute,oe,pt,ot);const b={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:oe,forceKeepAttr:void 0};let x=h.length;const R=de(a.nodeName);for(;x--;){const U=h[x],se=U.name,ce=U.namespaceURI,xe=U.value,Be=de(se),jn=xe;let Te=se==="value"?jn:v0(jn);if(b.attrName=Be,b.attrValue=Te,b.keepAttr=!0,b.forceKeepAttr=void 0,Je(q.uponSanitizeAttribute,a,b),Te=b.attrValue,me&&(Be==="id"||Be==="name")&&Su(Te,At)!==0&&(mt(se,a,U),Te=At+Te),Ne&&we(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,Te)){mt(se,a,U);continue}if(Be==="attributename"&&bu(Te,"href")){mt(se,a,U);continue}if(!b.forceKeepAttr){if(!b.keepAttr){mt(se,a,U);continue}if(!ve&&we(Z0,Te)){mt(se,a,U);continue}if(be&&(Te=cn(Te)),!No(R,Be,Te)){mt(se,a,U);continue}Te=yr(R,Be,ce,Te),Te!==jn&&mr(a,se,ce,Te)}}Je(q.afterSanitizeAttributes,a,null)},fn=function(a){let h=null;const b=ko(a);for(Je(q.beforeSanitizeShadowDOM,a,null);h=b.nextNode();)if(Je(q.uponSanitizeShadowNode,h,null),Mo(h,a),xo(h),xt(h.content)&&fn(h.content),I(h)===Ie.element){const x=k(h);xt(x)&&(In(x),fn(x))}Je(q.afterSanitizeShadowDOM,a,null)},In=function(a){const h=[{node:a,shadow:null}];for(;h.length>0;){const b=h.pop();if(b.shadow){fn(b.shadow);continue}const x=b.node,U=I(x)===Ie.element,se=_(x);if(se)for(let ce=se.length-1;ce>=0;--ce)h.push({node:se[ce],shadow:null});if(U){const ce=v?v(x):null;if(typeof ce=="string"&&de(ce)==="template"){const xe=x.content;xt(xe)&&h.push({node:xe,shadow:null})}}if(U){const ce=k(x);xt(ce)&&h.push({node:null,shadow:ce},{node:ce,shadow:null})}}};return t.sanitize=function(N){let a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},h=null,b=null,x=null,R=null;if(Bn=!N,Bn&&(N="<!-->"),typeof N!="string"&&!Pt(N)&&(N=j0(N),typeof N!="string"))throw kt("dirty is not a string, aborting");if(!t.isSupported)return N;Ct?(te=We,oe=ot):Ln(a),(q.uponSanitizeElement.length>0||q.uponSanitizeAttribute.length>0)&&(te=Re(te)),q.uponSanitizeAttribute.length>0&&(oe=Re(oe)),t.removed=[];const U=ut&&typeof N!="string"&&Pt(N);if(U){hr(N);const xe=$(N);if(typeof xe=="string"){const Be=de(xe);if(!te[Be]||E[Be])throw sn(N),kt("root node is forbidden and cannot be sanitized in-place")}if(dn(N))throw sn(N),kt("root node is clobbered and cannot be sanitized in-place");try{In(N)}catch(Be){throw sn(N),Be}}else if(Pt(N))h=So("<!---->"),b=h.ownerDocument.importNode(N,!0),b.nodeType===Ie.element&&b.nodeName==="BODY"||b.nodeName==="HTML"?h=b:h.appendChild(b),In(b);else{if(!$e&&!be&&!Se&&N.indexOf("<")===-1)return G&&yt?B(N):N;if(h=So(N),!h)return $e?null:yt?P:""}h&&Ue&&dt(h.firstChild);const se=U?N:h;try{const xe=ko(se);for(;x=xe.nextNode();)Mo(x,se),xo(x),xt(x.content)&&fn(x.content)}catch(xe){throw U&&(sn(N),St(t.removed,Be=>{Be.element&&ln(Be.element)})),xe}if(U)return St(t.removed,xe=>{xe.element&&ln(xe.element)}),be&&Rn(N),N;if($e){if(be&&Rn(h),lt)for(R=j.call(h.ownerDocument);h.firstChild;)R.appendChild(h.firstChild);else R=h;return(oe.shadowroot||oe.shadowrootmode)&&(R=ne.call(o,R,!0)),R}let ce=Se?h.outerHTML:h.innerHTML;return Se&&te["!doctype"]&&h.ownerDocument&&h.ownerDocument.doctype&&h.ownerDocument.doctype.name&&we(W0,h.ownerDocument.doctype.name)&&(ce="<!DOCTYPE "+h.ownerDocument.doctype.name+`>
788
- `+ce),be&&(ce=cn(ce)),G&&yt?B(ce):ce},t.setConfig=function(){let N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Ln(N),Ct=!0,We=te,ot=oe},t.clearConfig=function(){Tt=null,Ct=!1,We=null,ot=null,G=Q,P=""},t.isValidAttribute=function(N,a,h){Tt||Ln({});const b=de(N),x=de(a);return No(b,x,h)},t.addHook=function(N,a){typeof a=="function"&&De(q,N)&&qt(q[N],a)},t.removeHook=function(N,a){if(De(q,N)){if(a!==void 0){const h=B0(q[N],a);return h===-1?void 0:D0(q[N],h,1)[0]}return Eu(q[N])}},t.removeHooks=function(N){De(q,N)&&(q[N]=[])},t.removeAllHooks=function(){q=Ou()},t}var nd=Lu();const od=/^(?:[a-z]+:)?\/\//i;let ud="";function rd(){return ud}function no(e){const t=String(e||"").trim();if(!t)return"";if(od.test(t)||t.startsWith("data:")||t.startsWith("blob:"))return t;const n=t.startsWith("/")?t:`/${t}`,o=rd();return o?`${o}${n}`:n}function ad(){return kn(new Date)}function kn(e){if(e==null||e==="")return"";const t=e instanceof Date?e:new Date(e);return isNaN(t.getTime())?"":new Intl.DateTimeFormat("fr-CA",{timeZone:"Asia/Seoul"}).format(t)}const Zt=[],Jt=[],Qt=[],en=[],An={LISTEN_IN_NOISE:[],SHORT_STORY:[],LONG_STORY:[],ORDERING_SENTENCE:[]},wn={LISTEN_IN_NOISE:[],SHORT_STORY:[],LONG_STORY:[],ORDERING_SENTENCE:[]},id={LISTEN_IN_NOISE:3,SHORT_STORY:2,LONG_STORY:1,ORDERING_SENTENCE:2};let oo=null,Ru=null,ft=null;function sd({counts:e,forceRefresh:t}={}){const n=Object.assign({},id,e||{}),o=ad(),u=kn(new Date(`${o}T00:00:00+09:00`).getTime()-864e5),r=JSON.stringify(n);if(!t&&Ru===o&&oo===r&&ft)return Object.assign(An,ft.today),Object.assign(wn,ft.yesterday?.selection||{LISTEN_IN_NOISE:[],SHORT_STORY:[],LONG_STORY:[],ORDERING_SENTENCE:[]}),{today:An,yesterday:wn};const i={LISTEN_IN_NOISE:at(Zt,Math.max(0,Number(n.LISTEN_IN_NOISE)||0)),SHORT_STORY:at(Jt,Math.max(0,Number(n.SHORT_STORY)||0)),LONG_STORY:at(Qt,Math.max(0,Number(n.LONG_STORY)||0)),ORDERING_SENTENCE:at(en,Math.max(0,Number(n.ORDERING_SENTENCE)||0))};let s=null;return ft&&oo===r&&ft.yesterday&&ft.yesterday.date===u&&(s=ft.yesterday.selection),s||(s={LISTEN_IN_NOISE:at(Zt,Math.max(0,Number(n.LISTEN_IN_NOISE)||0)),SHORT_STORY:at(Jt,Math.max(0,Number(n.SHORT_STORY)||0)),LONG_STORY:at(Qt,Math.max(0,Number(n.LONG_STORY)||0)),ORDERING_SENTENCE:at(en,Math.max(0,Number(n.ORDERING_SENTENCE)||0))}),Object.assign(An,i),Object.assign(wn,s),Ru=o,oo=r,ft={today:i,yesterday:{date:u,countsKey:r,selection:s}},{today:An,yesterday:wn}}let Iu=!1,tn=null;async function ld(){try{const e={url:typeof document>"u"?require("url").pathToFileURL(__filename).href:Pn&&Pn.tagName.toUpperCase()==="SCRIPT"&&Pn.src||new URL("hooks.cjs.js",document.baseURI).href}&&void 0||"/",t=await fetch(`${e}data/allTrainingData.json`);return t.ok?await t.json():null}catch{return null}}async function cd(){if(!Iu)return tn||(tn=(async()=>{const e=await ld();if(!e){tn=null;try{window.dispatchEvent(new Event("speechear.data.error"))}catch{}return}try{for(const t of Object.keys(e||{})){const n=e[t]||[];for(const o of n){const u=o,r=String(u.training_type||t),i=String(u.category_main_code||u.category_main||u.category_0||""),s=String(u.category_sub_code||u.category_sub||u.category_1||""),d=Object.assign({},u,{training_type:r,category_0:i,category_1:s});r==="LISTEN_IN_NOISE"?Zt.push(d):r==="SHORT_STORY"?Jt.push(d):r==="LONG_STORY"?Qt.push(d):r==="ORDERING_SENTENCE"&&en.push(d)}}}catch{tn=null;try{window.dispatchEvent(new Event("speechear.data.error"))}catch{}return}try{window.dispatchEvent(new Event("speechear.data.updated"))}catch{}try{sd()}catch{}Iu=!0})(),tn)}async function dd(e=3e3){const t=cd();return Promise.race([t,new Promise(n=>setTimeout(n,e))])}const hd=[{key:"LISTEN_IN_NOISE",label:"\uC18C\uC74C \uD558 \uBB38\uC7A5 \uB4E3\uAE30",icon:"party-popper",desc:"\uB2E4\uC591\uD55C \uC18C\uC74C \uD658\uACBD\uC5D0\uC11C \uBB38\uC7A5 \uCCAD\uB825\uC744 \uD6C8\uB828\uD569\uB2C8\uB2E4."},{key:"SHORT_STORY",label:"\uC9E7\uC740 \uC774\uC57C\uAE30 \uB4E3\uAE30",icon:"message-square",desc:"\uC9E7\uC740 \uC774\uC57C\uAE30\uB97C \uB4E3\uACE0 \uAE30\uC5B5\uD558\uC5EC \uBB38\uC81C\uB97C \uD480\uC5B4\uBD05\uB2C8\uB2E4."},{key:"LONG_STORY",label:"\uAE34 \uC774\uC57C\uAE30 \uB4E3\uAE30",icon:"message-square-text",desc:"\uAE34 \uC774\uC57C\uAE30\uB97C \uB4E3\uACE0 \uAE30\uC5B5\uD558\uC5EC \uB2E4\uC218\uC758 \uBB38\uC81C\uB97C \uD480\uC5B4\uBD05\uB2C8\uB2E4."},{key:"ORDERING_SENTENCE",label:"\uBB38\uC7A5 \uC21C\uC11C\uD654 \uD558\uAE30",icon:"align-start-vertical",desc:"\uC5EC\uB7EC\uAC1C\uC758 \uC9E7\uC740 \uBB38\uC7A5\uC744 \uB4E3\uACE0 \uAE30\uC5B5\uD558\uC5EC \uADF8 \uC21C\uC11C\uC5D0 \uB9DE\uAC8C \uBC30\uC5F4\uD569\uB2C8\uB2E4."}],fd={LISTEN_IN_NOISE:"listenInNoise",SHORT_STORY:"shortStory",LONG_STORY:"longStory",ORDERING_SENTENCE:"orderingSentence"};function pd(e){return hd.map(t=>{const n=fd[t.key];return n?{...t,label:e(`trainingType.${n}.title`),desc:e(`trainingType.${n}.desc`)}:t})}const Cd="0.37.0";function yd(e){return typeof window>"u"?"":nd.sanitize(e,{USE_PROFILES:{svg:!0,svgFilters:!0},FORBID_TAGS:["script","use"],FORBID_ATTR:["xlink:href","href"]})}function md(e){const[t,n]=l.useState(null),[o,u]=l.useState(null),[r,i]=l.useState(null),[s,d]=l.useState(null);return l.useEffect(()=>{if(!e||typeof e!="string"||!e.endsWith(".svg")){n(null),u(null),i(null);return}const p=e.split("/").pop();let f=e;p&&(e.startsWith("/")?f=no(e):/^(Logo|Symbol)/i.test(p)?f=no(`logo/${p}`):(/^https?:\/\//i.test(e)||e.startsWith("data:"),f=e)),n(f)},[e]),l.useEffect(()=>{if(!t)return;let p=!1;async function f(){try{let y=await fetch(t);y.ok||(y=await fetch(t));const c=y.headers.get("content-type")||"";if(p)return;if(c.includes("svg")){u("mask");return}if(c.startsWith("image/")){u("img");return}const m=await fetch(t);if(!m.ok)throw new Error("not ok");const S=await m.text();if(p)return;if(/^\s*<svg[\s>]/i.test(S)){const w=yd(S);if(!w){u("none");return}i(w),u("inline");return}u("none")}catch{p||u("none")}}return f(),()=>{p=!0}},[t]),l.useEffect(()=>{let p=!1,f=null;return o==="mask"&&t&&fetch(t).then(y=>{if(!y.ok)throw new Error("fetch failed");return y.blob()}).then(y=>{p||(f=URL.createObjectURL(y),d(f))}).catch(()=>{p||u("img")}),()=>{p=!0,f&&URL.revokeObjectURL(f),d(null)}},[o,t]),{iconToUse:t,mode:o,svgText:r,blobUrl:s}}function gd(e){const{icon:t,label:n,className:o,imgClassName:u,maskClassName:r,svgClassName:i,wrapperStyle:s,size:d}=e||{},p=o??"iconRenderer-icon",f=u??"iconRenderer-icon-image",y=r??"iconRenderer-icon-mask",c=i??"iconRenderer-icon-svg",m=typeof t=="string"?t:null,S=b0(m),{iconToUse:w,mode:_,svgText:g,blobUrl:k}=md(m),A=(I,$={})=>V.jsx("span",{className:p,style:s,...$,children:I}),T=(I,$={})=>V.jsx("img",{src:I,alt:typeof n=="string"?n:n?String(n):"",className:f,...$});if(!t)return null;if(typeof t!="string")return A(t);if(t==="none")return A(V.jsx("span",{className:c,dangerouslySetInnerHTML:{__html:'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" aria-hidden="true"></svg>'}}),{"aria-hidden":"true"});if(S)try{return A(l.createElement(S,{className:c,size:typeof d=="number"?d:20}),{"aria-hidden":"true"})}catch{}if(w&&w.endsWith(".svg")){if(_==="mask"){const I={"--icon-url":k?`url(${k})`:`url(${w})`};return A(V.jsx("span",{className:y,style:I}),{"aria-hidden":"true"})}return _==="img"?A(T(w,{onError:I=>{I.currentTarget.onerror=null,I.currentTarget.style.display="none"}}),{"aria-hidden":"true"}):_==="inline"?A(V.jsx("span",{className:c,dangerouslySetInnerHTML:g?{__html:g}:void 0}),{"aria-hidden":"true"}):A(null,{"aria-hidden":"true"})}if(t.startsWith("/")||t.includes("/assets/")||t.match(/\.(png|jpg|jpeg|webp|gif)$/i))return T(no(t),{style:s,onError:I=>{I.currentTarget.onerror=null,I.currentTarget.style.display="none"}});const v=typeof d=="number"?d:20,D=`<svg width="${v}" height="${v}" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><rect x="3" y="3" width="18" height="18" rx="2" ry="2" style="fill:none;stroke:currentColor;stroke-width:2"/></svg>`;return A(V.jsx("span",{className:c,dangerouslySetInnerHTML:{__html:D}}),{"aria-hidden":"true"})}function ju(e){const{anchorRect:t,anchorEl:n,offset:o=20,edgeMargin:u=20,onClose:r,closeOnOutsideClick:i=!0,className:s="",role:d="dialog",ariaLabel:p="",children:f,backdrop:y=!1,isMobilePopup:c=!1,useBorder:m=!0,header:S}=e||{},w=l.useRef(null),[_,g]=l.useState({position:"fixed",left:0,top:-9999}),[k,A]=l.useState(!1),[T,v]=l.useState("bottom"),[D,I]=l.useState(!1),[$,G]=l.useState(!1),P=!t&&!n,Q=l.useCallback((B=!1)=>{if($&&c)return;const O=n?n.getBoundingClientRect():t;if(!O||!w.current)return;const ye=w.current,{offsetWidth:Z,offsetHeight:ee}=ye,M=window.innerWidth,j=window.innerHeight,ae=M-O.right,ne=O.left,q=O.top,Me=j-O.bottom;let X=0,he=0,H="top";if(q>=ee+o)H="top",he=O.top-o-ee,X=O.left+O.width/2-Z/2;else if(Me>=ee+o)H="bottom",he=O.bottom+o,X=O.left+O.width/2-Z/2;else if(ae>=Z+o)H="right",X=O.right+o,he=O.top+O.height/2-ee/2;else if(ne>=Z+o)H="left",X=O.left-o-Z,he=O.top+O.height/2-ee/2;else{const tt=Math.max(q,Me,ae,ne);tt===q?(H="top",he=O.top-o-ee,X=O.left+O.width/2-Z/2):tt===Me?(H="bottom",he=O.bottom+o,X=O.left+O.width/2-Z/2):tt===ae?(H="right",X=O.right+o,he=O.top+O.height/2-ee/2):(H="left",X=O.left-o-Z,he=O.top+O.height/2-ee/2)}const He=Number(u)||8;X=Math.min(Math.max(X,He),M-Z-He),he=Math.min(Math.max(he,He),j-ee-He);const ze=Math.round(X),je=Math.round(he);B&&w.current?(w.current.style.left=`${ze}px`,w.current.style.top=`${je}px`,w.current.dataset.placement=H):(v(H||T),g({position:"fixed",left:ze,top:je}),I(!0))},[$,c,n,t,o,u,T]);l.useLayoutEffect(()=>{if(P)return;if($&&c){g({position:"fixed",left:"50%",top:"50%",transform:"translate(-50%, -50%)",width:"calc(100% - 40px)",maxWidth:"calc(100% - 40px)"}),I(!0);return}Q();const B=requestAnimationFrame(()=>Q());return()=>cancelAnimationFrame(B)},[t,n,o,f,u,P,$,c,Q]),l.useEffect(()=>{if(P||$&&c||!w.current||typeof ResizeObserver>"u")return;const B=new ResizeObserver(()=>{t&&Q()});return B.observe(w.current),()=>B.disconnect()},[t,f,u,P,$,c,Q]),l.useEffect(()=>{if(P||$&&c)return;const B=()=>Q(!0);return window.addEventListener("resize",B),document.addEventListener("scroll",B,{passive:!0,capture:!0}),()=>{window.removeEventListener("resize",B),document.removeEventListener("scroll",B,{capture:!0})}},[t,o,f,u,P,$,c,Q]),l.useEffect(()=>{if(typeof window>"u"||!window.matchMedia)return;const B=window.matchMedia("(max-width: 768px)"),O=()=>G(!!B.matches);O();try{B.addEventListener?B.addEventListener("change",O):B.addListener(O)}catch{try{B.addListener(O)}catch{}}return()=>{try{B.removeEventListener?B.removeEventListener("change",O):B.removeListener(O)}catch{}}},[]);const Y=l.useRef(!1),W=l.useCallback((B=!1)=>{if(!(k||Y.current)){if(Y.current=!0,B){A(!0);try{r&&r()}catch{}return}A(!0),setTimeout(()=>{r&&r()},200)}},[k,r,A]);l.useEffect(()=>{const B=Z=>{const ee=w.current;if(!ee)return;const M=Z.target;if(M&&!ee.contains(M)){try{if(M.closest&&M.closest("[data-tooltip-ignore]"))return}catch{}i&&W(!0)}},O=Z=>{const ee=w.current;if(!ee)return;const M=Z.target;if(M&&!ee.contains(M)){try{if(M.closest&&M.closest("[data-tooltip-ignore]"))return}catch{}i&&W(!0)}},ye=Z=>{if(Z.key==="Escape"){Z.stopPropagation(),W();return}if(Z.key==="Tab"){const ee=w.current;if(!ee)return;const M=ee.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])');if(!M||M.length===0)return;const j=M[0],ae=M[M.length-1],ne=document.activeElement;Z.shiftKey?ne===j&&(Z.preventDefault(),ae.focus()):ne===ae&&(Z.preventDefault(),j.focus())}};return document.addEventListener("pointerdown",B,!0),document.addEventListener("click",O,!0),document.addEventListener("keydown",ye),()=>{document.removeEventListener("pointerdown",B,!0),document.removeEventListener("click",O,!0),document.removeEventListener("keydown",ye)}},[r,i,W]),l.useEffect(()=>{const B=()=>{W(!0)};return typeof document<"u"&&document.addEventListener("speechear-close-tooltips",B),()=>{typeof document<"u"&&document.removeEventListener("speechear-close-tooltips",B)}},[W]);const F=V.jsxs("div",{ref:w,className:`tooltip-content ${m?"tooltip-content--bordered":""} ${k?"is-closing":""} ${s} ${$&&c?"is-mobile":""}`,role:d,"aria-label":p||void 0,style:P?{}:{..._,visibility:D?"visible":"hidden"},tabIndex:-1,"data-placement":T,"data-left":P?"":_.left,"data-top":P?"":_.top,"data-anchor-left":t?Math.round(t.left):"","data-anchor-top":t?Math.round(t.top):"","data-anchor-width":t?Math.round(t.width):"","data-anchor-height":t?Math.round(t.height):"",children:[S!=null&&V.jsx("div",{className:"tooltip-content__header h5",children:S}),f]});if(P||typeof document>"u")return F;if(y||$&&c){const B=V.jsxs("div",{className:"tooltip-portal",children:[V.jsx("div",{className:"tooltip-backdrop",onClick:()=>{i&&W(!0)}}),F]});return Bo.createPortal(B,document.body)}return Bo.createPortal(F,document.body)}function _d(e){const{anchorRect:t,text:n,offset:o=8,onClose:u,className:r="",ariaLabel:i}=e||{};return n?V.jsx(ju,{anchorRect:t,offset:o,onClose:u,closeOnOutsideClick:!1,className:`tooltip-info ${r}`,ariaLabel:i||n,children:V.jsx("div",{className:"tooltip-info__content body-3",children:n})}):null}function Pu(e){const{anchorRect:t,title:n,items:o,activeIndex:u=-1,showIndex:r=!0,onClose:i,offset:s=12}=e||{},d=Array.isArray(o)?o:o?[o]:[];return!d.length&&!n?null:V.jsx(ju,{anchorRect:t,offset:s,onClose:i,closeOnOutsideClick:!0,useBorder:!1,className:"tooltip-description",children:V.jsxs("div",{className:"tooltip-description__box",children:[n&&V.jsx("span",{className:"tooltip-description__title body-2",children:n}),V.jsx("ol",{className:"tooltip-description__items",children:d.map((p,f)=>V.jsxs("li",{className:`tooltip-description__item body-3${f===u?" tooltip-description__item--active":""}`,children:[r&&d.length>1&&V.jsxs("span",{className:"tooltip-description__index button-1",children:[f+1,"."]}),V.jsx("span",{children:p})]},f))})]})})}function Ed(e){const{size:t=48,type:n,htmlType:o,href:u,target:r,rel:i,icon:s,rightIcon:d,label:p,count:f,subLabel:y,children:c,ariaLabel:m,variant:S="default",align:w="center",selected:_,toggleable:g=!1,disabled:k=!1,useLabel:A=!0,useBorder:T=!0,useBG:v=!0,useDisabledCovered:D=!1,useDisabledInvisible:I=!1,width:$,minWidth:G,onClick:P,onDisabledClick:Q,showTooltipInfo:Y=!1,tooltipInfoText:W=null,tooltipDescription:F=null,iconSize:B="medium",iconColor:O,shape:ye="rounded",color:Z,className:ee,...M}=e,j=typeof t=="string"&&isNaN(Number(t))?t.toLowerCase():String(Number(t)||48),ae=j.match(/^\d+$/)?`button${j}`:`button-${j}`,ne=Number(t),q=!isNaN(ne)&&ne<40?"button-2":"button-1",Me=p??c,X=k||!!M.disabled,he=X?D?"disabled-covered":I?"disabled-invisibled":"disabled":S,H=he?`button--variant-${he}`:"",He=w?`button--align-${w}`:"",ze=ye?`button--shape-${ye}`:"",je=typeof O=="string"&&O.startsWith("--")?`var(${O})`:O,tt={...$?{width:typeof $=="number"?`${$}px`:$}:{},...G?{minWidth:typeof G=="number"?`${G}px`:G}:{},...T?{}:{"--button-border":X?"0":"1px solid transparent"},...je?{"--button-icon-color":je}:{},...Z?{"--color-main":Z}:{}},Ve=A===!1?"":Me,te=Array.isArray(Ve)?Ve.length>0:!!Ve,nt=!!d,oe=n??(te||s||nt?"bar":"dot"),pt=`${ae}--${oe}`,pe=l.useRef(null),E=l.useRef(X),[z,L]=l.useState(!!_),[K,ie]=l.useState(!1),[Pe,ve]=l.useState(null),be=l.useCallback(()=>ie(!1),[]);l.useEffect(()=>{(Y||F)&&X&&K&&(ie(!1),ve(null))},[X,Y,F,K]),l.useEffect(()=>{typeof _=="boolean"&&L(_)},[_]),l.useEffect(()=>{if(E.current&&!X&&pe.current){const ue=pe.current;ue.blur(),ue.style.pointerEvents="none";const Xe=requestAnimationFrame(()=>{requestAnimationFrame(()=>{pe.current&&(pe.current.style.pointerEvents="")})});return()=>cancelAnimationFrame(Xe)}E.current=X},[X]);const Ne=typeof _=="boolean"?!!_:z,Se=g||typeof _=="boolean"?Ne?"true":"false":void 0,Ct=Ia("button",ae,pt,H,He,ze,Ne?"is-selected":null,v?null:"button--no-bg",ee),We=`button__icon button__icon--${B}`,ot=Array.isArray(y)?y:y!==void 0?[y]:[],Ue=()=>{if(Array.isArray(Ve))return Ve.map((Xe,It)=>{const Mt=ot[It];return V.jsxs("span",{className:`button__label-text${Mt!==void 0?" button__label-text--has-sub":""}`,children:[Xe,Mt!==void 0&&V.jsx("span",{className:"button__sub-label-text caption-1",children:Mt})]},It)});const ue=y!==void 0;return V.jsxs("span",{className:`button__label-text${ue?" button__label-text--has-sub":""}`,children:[Ve,f!=null&&V.jsx("span",{className:"button__count",children:f}),ue&&V.jsx("span",{className:"button__sub-label-text caption-1",children:y})]})},$e=ue=>{X||(typeof M.onMouseLeave=="function"&&M.onMouseLeave(ue),typeof _!="boolean"&&L(!1),ue.currentTarget.blur())},lt=ue=>{if(X){Q?.(ue);return}typeof _!="boolean"&&g&&L(Xe=>!Xe),P?.(ue)},yt=l.useCallback(()=>{!X&&(Y||F)&&(ie(!0),ve(pe.current?.getBoundingClientRect()??null))},[X,Y,F]),Rt=l.useCallback(()=>{(Y||F)&&(ie(!1),ve(null))},[Y,F]),me={...M};delete me.disabled,delete me.className,delete me.faded,delete me.useFaded,delete me.loading,delete me.onMouseLeave,delete me.onPointerEnter,delete me.onPointerLeave,delete me.onFocus,delete me.onBlur,X&&(Object.keys(me).forEach(ue=>{/^on[A-Z]/.test(ue)&&typeof me[ue]=="function"&&delete me[ue]}),me["aria-disabled"]="true");const At=(typeof Y=="string"?Y:null)??(typeof W=="string"?W:null)??(typeof m=="string"?m:null)??(typeof Me=="string"?Me:null)??void 0,wt=typeof m=="string"?m:typeof Me=="string"?Me:At,ut=(ue,Xe)=>V.jsx(gd,{icon:ue,label:Xe??wt,className:We,imgClassName:"button__icon-img",maskClassName:"button__icon-mask",svgClassName:"button__icon-svg"}),ct=()=>oe==="dot"?V.jsxs(V.Fragment,{children:[ut(s),te&&V.jsx("span",{className:`button__label ${q}`,children:Ue()})]}):w==="center"&&s?V.jsxs(V.Fragment,{children:[V.jsxs("span",{className:"button__center-group",children:[V.jsx("span",{className:"button__left",children:ut(s)}),te&&V.jsx("span",{className:`button__label ${q}`,children:Ue()})]}),nt&&V.jsx("span",{className:"button__right",children:ut(d)})]}):V.jsxs(V.Fragment,{children:[s&&V.jsx("span",{className:"button__left",children:ut(s,m??Me)}),te&&V.jsx("span",{className:`button__label ${q}`,children:Ue()}),nt&&V.jsx("span",{className:"button__right",children:ut(d)})]}),Ke=!!u&&!X;return V.jsxs(V.Fragment,{children:[V.jsx(Ke?"a":"button",{...me,ref:pe,...Ke?{href:u,target:r,rel:i??(r==="_blank"?"noreferrer":void 0)}:{type:o,disabled:X&&!Q},className:Ct,"aria-pressed":Se,"aria-label":wt,"aria-disabled":Ke&&X?!0:void 0,style:tt,onClick:lt,onMouseLeave:$e,onPointerEnter:ue=>{yt(),!X&&typeof M.onPointerEnter=="function"&&M.onPointerEnter(ue)},onPointerLeave:ue=>{Rt(),!X&&typeof M.onPointerLeave=="function"&&M.onPointerLeave(ue)},onFocus:ue=>{yt(),!X&&typeof M.onFocus=="function"&&M.onFocus(ue)},onBlur:ue=>{$e(ue),Rt(),!X&&typeof M.onBlur=="function"&&M.onBlur(ue)},children:ct()}),K&&F?V.jsx(Pu,{anchorRect:Pe,title:F.title,items:F.items,onClose:be}):K&&At?V.jsx(_d,{anchorRect:Pe,text:At,onClose:be}):null]})}function $u(){const[e,t]=l.useState(null),n=l.useCallback(r=>t(r.getBoundingClientRect()),[]),o=l.useCallback(()=>t(null),[]),u=l.useCallback(r=>{const i=r.getBoundingClientRect();t(s=>s?null:i)},[]);return{anchorRect:e,isOpen:e!=null,openAt:n,close:o,toggleAt:u}}function bd(e){const[t,n]=l.useState(null),[o,u]=l.useState(null),r=l.useRef(null);l.useEffect(()=>()=>{r.current&&clearTimeout(r.current)},[]);const i=l.useCallback((d,p)=>{r.current&&clearTimeout(r.current),r.current=setTimeout(()=>{n(d),u(p)},e)},[e]),s=l.useCallback(()=>{r.current&&clearTimeout(r.current),n(null),u(null)},[]);return{payload:t,anchorRect:o,openAfterDelay:i,close:s}}function Sd({title:e,items:t}){const{t:n}=gt.useTranslation(),{anchorRect:o,openAt:u,close:r}=$u();return V.jsxs(V.Fragment,{children:[V.jsx(Ed,{size:24,type:"dot",icon:"info",variant:"transparent-gray",useBorder:!1,selected:!!o,ariaLabel:n("common.info","\uC124\uBA85"),onPointerEnter:i=>u(i.currentTarget),onPointerLeave:r,onFocus:i=>u(i.currentTarget),onBlur:r}),o&&V.jsx(Pu,{title:e,items:t,showIndex:t.length>1,anchorRect:o,onClose:r})]})}function Fu(){const{t:e}=gt.useTranslation();return l.useMemo(()=>({difficulty:e("wordSearch.filter.difficulty","\uB4F1\uAE09"),syllables:e("wordSearch.filter.syllables","\uC74C\uC808 \uC218"),syllable5plus:e("wordSearch.filter.syllable5plus","5\uC74C\uC808 \uC774\uC0C1"),partOfSpeech:e("wordSearch.filter.partOfSpeech","\uD488\uC0AC"),wordType:e("wordSearch.filter.wordType","\uC720\uD615"),posMap:{[e("wordSearch.filter.pos.noun","\uCCB4\uC5B8(\uBA85\uC0AC, \uC218\uC0AC)")]:["\uBA85","\uC218"],[e("wordSearch.filter.pos.verb","\uC6A9\uC5B8(\uB3D9\uC0AC, \uD615\uC6A9\uC0AC)")]:["\uB3D9","\uD615"],[e("wordSearch.filter.pos.modifier","\uC218\uC2DD\uC5B8(\uBD80\uC0AC, \uAD00\uD615\uC0AC)")]:["\uBD80","\uAD00"]},typeMap:{[e("wordSearch.filter.type.native","\uACE0\uC720\uC5B4")]:"\uACE0\uC720",[e("wordSearch.filter.type.sino","\uD55C\uC790\uC5B4")]:"\uD55C\uC790",[e("wordSearch.filter.type.foreign","\uC678\uB798\uC5B4")]:"\uC678\uB798",[e("wordSearch.filter.type.mixed","\uD63C\uC885\uC5B4")]:"\uD63C\uC885"}}),[e])}function Hu(e,t,n){return{label:t.difficulty,items:[1,2,3,4].map(o=>e("wordSearch.filter.grade",{n:o})),multiple:!0,allOption:!0,allLabel:n?.allLabel,labelAction:n?.labelAction}}function zu(e){return{label:e.partOfSpeech,items:Object.keys(e.posMap),multiple:!0,allOption:!0}}function Vu(e){return{label:e.wordType,items:Object.keys(e.typeMap),multiple:!0,allOption:!0}}function kd(e,t){return{label:t.syllables,items:[e("wordSearch.filter.syllable",{n:1}),e("wordSearch.filter.syllable",{n:2}),e("wordSearch.filter.syllable",{n:3}),e("wordSearch.filter.syllable",{n:4}),t.syllable5plus],multiple:!0,allOption:!0}}function Ad(e,t){const n=[e("wordPairs.filter.onlyHasImage","\uC774\uBBF8\uC9C0 \uC788\uB294 \uB2E8\uC5B4\uB9CC")];return t?.includeStructure&&n.push(e("wordPairs.filter.onlySameStructure","\uC74C\uC18C \uAD6C\uC870 \uAC19\uC740 \uB2E8\uC5B4\uB9CC")),{label:e("wordPairs.filter.selectLabel","\uC120\uD0DD"),items:n,multiple:!0,labelAction:t?.labelAction}}function wd(e,t){const{label:n,headValue:o,midValue:u,tailValue:r,includeMid:i=!0,headDisabled:s,midDisabled:d,tailDisabled:p,allOptionDisabled:f,groupLabel:y,labelAction:c}=t;return{label:n,...y?{groupLabel:y}:{},...c?{labelAction:c}:{},allOption:!0,allLabel:e("wordSearch.filter.positionAny",{defaultValue:"\uBB34\uAD00"}),...f?{allOptionDisabled:f}:{},items:[{value:o,displayLabel:e("wordSearch.filter.positionHead",{defaultValue:"\uC5B4\uB450"}),disabled:s},...i?[{value:u,displayLabel:e("wordSearch.filter.positionMid",{defaultValue:"\uC5B4\uC911"}),disabled:d}]:[],{value:r,displayLabel:e("wordSearch.filter.positionTail",{defaultValue:"\uC5B4\uB9D0"}),disabled:p}]}}function Md(e,t,n){if(t===bt){const{[n]:r,...i}=e;return i}const o=e[n]??[],u=o.includes(t)?o.filter(r=>r!==t):[...o,t];if(u.length===0){const{[n]:r,...i}=e;return i}return{...e,[n]:u}}Object.fromEntries(Object.entries(Jr).map(([e,{nucleus:t}])=>[e,t]));const Nd={\uACE0\uC720\uC5B4:"\uACE0\uC720",\uD55C\uC790\uC5B4:"\uD55C\uC790",\uC678\uB798\uC5B4:"\uC678\uB798",\uD63C\uC885\uC5B4:"\uD63C\uC885"},Td={"\uCCB4\uC5B8(\uBA85\uC0AC,\uC218\uC0AC)":["\uBA85","\uC218"],"\uC6A9\uC5B8(\uB3D9\uC0AC,\uD615\uC6A9\uC0AC)":["\uB3D9","\uD615"],"\uC218\uC2DD\uC5B8(\uBD80\uC0AC,\uAD00\uD615\uC0AC)":["\uBD80","\uAD00"]},xd={difficulty:"\uB09C\uC774\uB3C4 \uB4F1\uAE09",syllables:"\uC74C\uC808 \uC218",syllable5plus:"5\uC74C\uC808 \uC774\uC0C1",partOfSpeech:"\uD488\uC0AC",wordType:"\uC720\uD615",posMap:Td,typeMap:Nd};function Bd(e,t,n=xd){const o=t[n.difficulty];if(o?.length&&!o.some(s=>e.grade===s.replace(/\D/g,"")))return!1;const u=t[n.syllables];if(u?.length){const s=e.syllables??0;if(!u.some(d=>d===n.syllable5plus?s>=5:s===parseInt(d)))return!1}const r=t[n.partOfSpeech];if(r?.length&&!r.flatMap(s=>n.posMap[s]??[s]).some(s=>(e.pos??"").includes(s)))return!1;const i=t[n.wordType];return!(i?.length&&!i.some(s=>e.wordType===n.typeMap[s]))}const it=(e,t)=>t.map(n=>({jamos:[n],tooltip:e})),Ee=(e,t)=>({jamos:[...e],tooltip:t}),uo={cho:[it("\uC591\uC21C\uC74C",["\u3142","\u3143","\u314D","\u3141"]),it("\uCE58\uC870\uC74C",["\u3137","\u3138","\u314C","\u3134","\u3139"]),it("\uCE58\uC870\uC74C",["\u3145","\u3146"]),it("\uACBD\uAD6C\uAC1C\uC74C",["\u3148","\u3149","\u314A"]),it("\uC5F0\uAD6C\uAC1C\uC74C",["\u3131","\u3132","\u314B"]),it("\uC131\uBB38\uC74C",["\u314E"])],jung:[[Ee("\u3163","\uC804\uC124 \uACE0\uBAA8\uC74C"),Ee("\u315F","\uC804\uC124 \uACE0\uBAA8\uC74C \xB7 w\uD65C\uC74C"),Ee("\u3162","\uC804\uC124 \uACE0\uBAA8\uC74C \xB7 \u0270\uD65C\uC74C")],[Ee("\u3161","\uD6C4\uC124 \uACE0\uBAA8\uC74C \uD3C9\uC21C")],[Ee("\u315C","\uD6C4\uC124 \uACE0\uBAA8\uC74C \uC6D0\uC21C"),Ee("\u3160","\uD6C4\uC124 \uACE0\uBAA8\uC74C \uC6D0\uC21C \xB7 j\uD65C\uC74C")],[Ee("\u3154\u3150","\uC804\uC124 \uC911\uBAA8\uC74C"),Ee("\u3156\u3152","\uC804\uC124 \uC911\uBAA8\uC74C \xB7 j\uD65C\uC74C"),Ee("\u3159\u315A\u315E","\uC804\uC124 \uC911\uBAA8\uC74C \xB7 w\uD65C\uC74C")],[Ee("\u3153","\uD6C4\uC124 \uC911\uBAA8\uC74C \uD3C9\uC21C"),Ee("\u3155","\uD6C4\uC124 \uC911\uBAA8\uC74C \uD3C9\uC21C \xB7 j\uD65C\uC74C"),Ee("\u315D","\uD6C4\uC124 \uC911\uBAA8\uC74C \uD3C9\uC21C \xB7 w\uD65C\uC74C")],[Ee("\u3157","\uD6C4\uC124 \uC911\uBAA8\uC74C \uC6D0\uC21C"),Ee("\u315B","\uD6C4\uC124 \uC911\uBAA8\uC74C \uC6D0\uC21C \xB7 j\uD65C\uC74C")],[Ee("\u314F","\uC800\uBAA8\uC74C"),Ee("\u3151","\uC800\uBAA8\uC74C \xB7 j\uD65C\uC74C"),Ee("\u3158","\uC800\uBAA8\uC74C \xB7 w\uD65C\uC74C")]],jong:[it("\uC591\uC21C\uC74C",["\u3142","\u3141"]),it("\uCE58\uC870\uC74C",["\u3137","\u3134","\u3139"]),it("\uC5F0\uAD6C\uAC1C\uC74C",["\u3131","\u3147"])]},Dd=[...ke],vd=[...rt],Od=Fe.filter(e=>e!==""),st=e=>e===Qe?[]:Array.from(e),Qe="__NO_CODA__",Uu=[1,2,3,4],et=5,Ld=12,Gu="SYL_",ro=e=>`${Gu}${e}`,Rd=e=>Number(e.slice(Gu.length));function ao(e){return e>=et?Array.from({length:Ld-et+1},(t,n)=>et+n):[e]}const Yu={cho:Dd,jung:vd,jong:Od},io=e=>e.map(t=>t.map(({jamos:n,tooltip:o})=>({v:n.join(""),tooltip:o}))),so={cho:io(uo.cho),jung:io(uo.jung),jong:io(uo.jong)},qu={};so.jung.flat().forEach(({v:e})=>{for(const t of st(e))qu[t]=e});const Id=new Set(so.cho.flat().map(e=>e.v));function Wu(e,t){return e==="cho"?Id.has(t)?t:null:e==="jung"?qu[t]??t:qo(t)}function Ku(e,t,n){if(e==="jung"){const o=st(t);return n&&o.includes(n)?n:o[0]??t}return t}function Xu(e,t,n){const o=(u,r)=>r?u==="jong"&&r===Qe?Qe:t==="pron"?Wu(u,r):Ku(u,r,u==="jung"?n:null):null;return{...e,cho:o("cho",e.cho),jung:o("jung",e.jung),jong:o("jong",e.jong)}}const lo={cho:null,jung:null,jong:null,syllable:null},jd="wt_filter",Zu=e=>`wt_filter_${e}`;function Ju(e){try{const t=localStorage.getItem(Zu(e))??localStorage.getItem(jd);if(t)return JSON.parse(t)}catch{}return null}function Pd(e){const t=e;return t?.composition?{cho:t.composition.cho??null,jung:t.composition.jung??null,jong:t.composition.jong??null,syllable:t.composition.syllable??null}:t?.choseong?{...lo,cho:t.choseong}:lo}function $d(e,t,n){const{t:o,i18n:u}=gt.useTranslation(),[r]=l.useState(()=>n?.resetOnMount?null:Ju(e)),i=r?.contrastCount,s=typeof i=="number"&&Number.isFinite(i)?i:1,[d,p]=l.useState(Math.min(5,Math.max(1,s))),[f,y]=l.useState(r?.phonemeView==="pron"?"pron":r?.phonemeView==="direct"?"direct":"char"),[c,m]=l.useState(()=>Pd(r)),S=l.useCallback(()=>t.requireSyllable?{cho:"\u3131",jung:"\u314F",jong:Qe,syllable:t.fixedSyllable??null}:{cho:null,jung:null,jong:t.fixedNoCoda?Qe:null,syllable:t.fixedSyllable??null},[t.requireSyllable,t.fixedSyllable,t.fixedNoCoda]);l.useEffect(()=>{!t.requireSyllable&&t.fixedSyllable==null&&!t.fixedNoCoda||m(E=>E.cho||E.jung||E.syllable!=null||E.jong?E:S())},[]);const w=l.useMemo(()=>_e(c.cho)||_e(c.jung)||_e(c.jong)?"count":"random",[c.cho,c.jung,c.jong]),_=l.useRef(f==="char"?c.jung:null);l.useEffect(()=>{f==="char"&&(_.current=c.jung)},[f,c.jung]);const[g,k]=l.useState(n?.resetOnMount?!!n?.defaultImageOnly:r?.excludeNoImage??!0),[A,T]=l.useState(n?.resetOnMount?!1:r?.sameStructureOnly??!0),[v,D]=l.useState(Array.isArray(r?.gradeFilter)?r.gradeFilter:[]),[I,$]=l.useState(Array.isArray(r?.posFilter)?r.posFilter:[]),[G,P]=l.useState(Array.isArray(r?.wordTypeFilter)?r.wordTypeFilter:[]),Q=l.useRef(n?.resetKey);l.useEffect(()=>{Q.current!==n?.resetKey&&(Q.current=n?.resetKey,m(S()),k(!1),T(!1),D([]),$([]),P([]),p(1))},[n?.resetKey]);const Y=Fu(),[W,F]=l.useState({cho:new Set,jung:new Set,jong:new Set,syllable:new Set}),[B,O]=l.useState(!1),[ye,Z]=l.useState(null),ee=1,M=Math.max(1,[c.cho,c.jung,c.jong].filter(Boolean).length);l.useEffect(()=>{d<M&&p(M)},[M,d]);const[j,ae]=l.useState(e);l.useEffect(()=>{if(j!==e){if(!n?.resetOnMount){const E=Ju(e),z=typeof E?.contrastCount=="number"&&Number.isFinite(E.contrastCount)?E.contrastCount:1;p(Math.min(5,Math.max(1,z))),m(E?.composition??S()),k(E?.excludeNoImage??!0),T(E?.sameStructureOnly??!0),y(E?.phonemeView==="pron"?"pron":"char"),D(Array.isArray(E?.gradeFilter)?E.gradeFilter:[]),$(Array.isArray(E?.posFilter)?E.posFilter:[]),P(Array.isArray(E?.wordTypeFilter)?E.wordTypeFilter:[])}ae(e)}},[e,j,n?.resetOnMount]),l.useEffect(()=>{if(!n?.resetOnMount&&j===e)try{localStorage.setItem(Zu(e),JSON.stringify({contrastCount:d,composition:c,excludeNoImage:g,sameStructureOnly:A,phonemeView:f,gradeFilter:v,posFilter:I,wordTypeFilter:G}))}catch{}},[n?.resetOnMount,e,j,d,c,g,A,f,v,I,G]);const[ne,q]=l.useState(0);Oo("wordpool:update",()=>q(E=>E+1));const Me=l.useRef(u.language);l.useEffect(()=>{Me.current!==u.language&&(Me.current=u.language,q(E=>E+1))},[u.language]),l.useEffect(()=>{if(!t.choseong)return;let E=!1;return Ra({difficulty:w,excludeNoImage:g}).then(z=>{E||(F(z),z.cho.size+z.jung.size+z.jong.size>0&&O(!0))}).catch(()=>{E||F({cho:new Set,jung:new Set,jong:new Set,syllable:new Set})}),()=>{E=!0}},[t.choseong,w,g,ne]),l.useEffect(()=>{let E=!1;const z=c,L=z.cho?st(z.cho):null,K=z.jung?st(z.jung):null,ie=z.jong===Qe,Pe=ie?null:z.jong?st(z.jong):null,ve=z.syllable!=null?ao(z.syllable):null,be=!!(L||K||Pe||ie||ve);return La({difficulty:t.difficulty?w:null,contrastCount:t.difficulty?d:1,composition:t.choseong&&be?{cho:L,jung:K,jong:Pe,jongNone:ie,syllable:ve}:null,excludeNoImage:g,sameStructureOnly:A,phonemeView:f==="pron"?"pron":"char",grade:v.length>0?v:null}).then(Ne=>{E||Z(Ne)}).catch(()=>{E||Z(null)}),()=>{E=!0}},[t.choseong,t.difficulty,w,d,c,f,g,A,ne,v]),l.useEffect(()=>{B&&m(E=>{const z={...E};let L=!1;return["cho","jung","jong"].forEach(K=>{const ie=E[K];!ie||ie===Qe||st(ie).some(Pe=>W[K].has(Pe))||(z[K]=null,L=!0)}),E.syllable!=null&&t.fixedSyllable==null&&(E.syllable>=et?[...W.syllable].some(K=>K>=et)||(z.syllable=null,L=!0):(!W.syllable.has(E.syllable)||E.syllable<ee)&&(z.syllable=null,L=!0)),L?z:E})},[W,B,ee,t.fixedSyllable]);const X=l.useMemo(()=>{const E=z=>{const L=new Set;for(const K of Yu[z])W[z].has(K)&&L.add(K);return L};return{cho:E("cho"),jung:E("jung"),jong:E("jong")}},[W]),he=l.useMemo(()=>({exact:new Set(Uu.filter(E=>W.syllable.has(E))),min:[...W.syllable].some(E=>E>=et)}),[W]),H=l.useMemo(()=>({diffPhonemeCount:o("training.contrast.diffPhonemeCount",{defaultValue:"\uB2E4\uB978 \uC74C\uC18C\uC758 \uCD1D \uAC2F\uC218"}),composition:o("wordPairs.composition","\uC815\uB2F5 \uB2E8\uC5B4 \uAD6C\uC131"),syllableCount:o("wordPairs.syllableCount","\uC74C\uC808 \uC218"),onset:o("wordPairs.onset","\uCD08\uC131"),vowel:o("wordPairs.vowel","\uBAA8\uC74C"),coda:o("wordPairs.coda","\uC885\uC131"),phonemeGroup:o("training.filter.phonemeGroup",{defaultValue:"\uD6C8\uB828 \uC74C\uC808"}),trainOnset:o("training.filter.trainOnset",{defaultValue:"\uCD08\uC131"}),trainVowel:o("training.filter.trainVowel",{defaultValue:"\uBAA8\uC74C"}),trainCoda:o("training.filter.trainCoda",{defaultValue:"\uC885\uC131"}),random:o("training.filter.random","\uBB34\uC791\uC704"),exclude:o("wordSearch.filter.exclude","\uC81C\uC678"),selectLabel:o("training.filter.selectSection",{defaultValue:"\uC120\uD0DD"}),none:o("common.none","\uC5C6\uC74C"),noImage:o("wordSearch.filter.excludeNoImage","\uC774\uBBF8\uC9C0 \uC5C6\uC74C"),excludeImage:o("training.filter.excludeImage",{defaultValue:"\uC774\uBBF8\uC9C0 \uC788\uB294 \uB2E8\uC5B4\uB9CC"}),sameStructure:o("training.filter.sameStructure",{defaultValue:"\uC74C\uC18C \uAD6C\uC870 \uAC19\uC740 \uB2E8\uC5B4\uB9CC"}),noLimit:o("training.filter.noLimit",{defaultValue:"\uBB34\uAD00"}),codaExclude:o("training.filter.codaExclude",{defaultValue:"\uC81C\uC678"}),gradeLabel:o("training.filter.gradeLabel",{defaultValue:"\uB09C\uC774\uB3C4 \uB4F1\uAE09"})}),[o]),He=l.useMemo(()=>({[H.trainOnset]:"cho",[H.trainVowel]:"jung",[H.trainCoda]:"jong"}),[H]),ze=l.useCallback((E,z)=>l.createElement(Sd,{title:z,items:E}),[]),je=l.useMemo(()=>[o("training.filter.excludeImageInfo",{defaultValue:"\uC774\uBBF8\uC9C0 \uC788\uB294 \uB2E8\uC5B4\uB9CC: \uB2E8\uC5B4 \uC911\uC5D0 \uC774\uBBF8\uC9C0\uAC00 \uC788\uB294 \uB2E8\uC5B4\uB9CC \uACB0\uACFC\uC5D0 \uBCF4\uC5EC\uC90D\uB2C8\uB2E4."}),o("training.filter.sameStructureInfo",{defaultValue:"\uC74C\uC18C \uAD6C\uC870 \uAC19\uC740 \uB2E8\uC5B4\uB9CC: \uC815\uB2F5\uACFC \uC624\uB2F5\uC758 \uC74C\uC808 \uAD6C\uC870(\uAE00\uC790 \uC218\xB7\uBC1B\uCE68 \uC720\uBB34 \uB4F1)\uAC00 \uAC19\uC740 \uACB0\uACFC\uB9CC \uB0A8\uACA8\uC694."})],[o]),tt=l.useMemo(()=>{const E=[];if(t.choseong){const z={value:Qe,displayLabel:H.codaExclude},L=t.fixedNoCoda===!0,K=(ie,Pe)=>{const ve=L&&ie==="jong",be={label:Pe,groupLabel:H.phonemeGroup,allOption:!t.requireSyllable,allLabel:H.noLimit,allOptionDisabled:ve};if(f==="pron"){const Se=so[ie].map(Ct=>Ct.map(({v:We,tooltip:ot})=>{const Ue=st(We),$e=ve||!Ue.some(lt=>W[ie].has(lt));return Ue.length>1?{value:We,labels:Ue,tooltip:ot,disabled:$e}:{value:We,tooltip:ot,disabled:$e}}));return ie==="jong"&&!t.requireCoda&&Se.unshift([z]),{...be,groups:Se}}const Ne=Yu[ie].map(Se=>!ve&&X[ie].has(Se)?Se:{value:Se,disabled:!0});return{...be,items:ie==="jong"&&!t.requireCoda?[z,...Ne]:Ne}};E.push(K("cho",H.trainOnset)),E.push(K("jung",H.trainVowel)),E.push(K("jong",H.trainCoda))}if(E.push({...Hu(o,Y,{labelAction:ze([o("wordPairs.filter.difficultyInfo",{defaultValue:"\uAD6D\uB9BD\uAD6D\uC5B4\uC6D0\uC758 \uAE30\uCD08 \uC5B4\uD718 \uB4F1\uAE09\uC774 \uACB0\uACFC\uC5D0 \uBC18\uC601\uB429\uB2C8\uB2E4."})])}),label:H.gradeLabel}),t.partOfSpeech&&E.push(zu(Y)),t.wordType&&E.push(Vu(Y)),t.choseong||t.fixedSyllable!=null){const z=t.fixedSyllable;E.push({label:H.syllableCount,items:[...Uu.map(L=>({value:ro(L),displayLabel:o("wordPairs.syllableN",{n:L,defaultValue:"{{n}}\uC74C\uC808"}),disabled:z!=null?L!==z:!he.exact.has(L)||L<ee})),{value:ro(et),displayLabel:o("wordPairs.syllableNPlus",{n:et,defaultValue:"{{n}}\uC74C\uC808 \uC774\uC0C1"}),disabled:z!=null?et!==z:!he.min}],allOption:!0,allOptionDisabled:z!=null})}return t.choseong?E.push({label:H.exclude,displayLabel:H.selectLabel,multiple:!0,items:[H.excludeImage,H.sameStructure],labelAction:ze(je)}):E.push({label:H.exclude,displayLabel:H.selectLabel,multiple:!0,items:[H.excludeImage],labelAction:ze([je[0]])}),E},[t.choseong,t.partOfSpeech,t.wordType,t.requireSyllable,t.fixedSyllable,t.fixedNoCoda,t.requireCoda,ee,X,W,f,he,H,o,ze,je,Y]),Ve={...t.difficulty?{[H.diffPhonemeCount]:String(d)}:{},...(t.choseong||t.fixedSyllable!=null)&&c.syllable!=null?{[H.syllableCount]:ro(c.syllable)}:{},...t.choseong&&c.cho?{[H.trainOnset]:c.cho}:{},...t.choseong&&c.jung?{[H.trainVowel]:c.jung}:{},...t.choseong&&c.jong?{[H.trainCoda]:c.jong}:{},[H.exclude]:[...g?[H.excludeImage]:[],...A?[H.sameStructure]:[]],[H.gradeLabel]:v.map(E=>o("wordSearch.filter.grade",{n:Number(E),defaultValue:"{{n}}\uB4F1\uAE09"})),...t.partOfSpeech?{[Y.partOfSpeech]:I}:{},...t.wordType?{[Y.wordType]:G}:{}},te=l.useCallback((E,z)=>{if(z===H.diffPhonemeCount){const L=Number(E);L>=1&&p(L)}else if(z===H.exclude)E===H.excludeImage?k(L=>!L):E===H.sameStructure&&T(L=>!L);else if(z===H.syllableCount)m(L=>{if(!E||E===bt)return{...L,syllable:null};const K=Rd(E);return{...L,syllable:L.syllable===K?null:K}});else if(z===H.gradeLabel){if(!E||E===bt){D([]);return}const L=E.replace(/\D/g,"");D(K=>K.includes(L)?K.filter(ie=>ie!==L):[...K,L])}else if(z===Y.partOfSpeech){if(!E||E===bt){$([]);return}$(L=>L.includes(E)?L.filter(K=>K!==E):[...L,E])}else if(z===Y.wordType){if(!E||E===bt){P([]);return}P(L=>L.includes(E)?L.filter(K=>K!==E):[...L,E])}else{const L=He[z];if(!L)return;m(K=>t.requireSyllable?E&&E!==bt?{...K,[L]:E}:K:!E||E===bt||K[L]===E?{...K,[L]:null}:{...K,[L]:E})}},[H,He,Y,t.requireSyllable]),nt=l.useCallback(E=>!t.partOfSpeech&&!t.wordType?!0:Bd(E,{...t.partOfSpeech?{[Y.partOfSpeech]:I}:{},...t.wordType?{[Y.wordType]:G}:{}},Y),[t.partOfSpeech,t.wordType,I,G,Y]),oe=l.useCallback(E=>{E!==f&&(E!=="direct"&&f!=="direct"&&m(z=>Xu(z,E,_.current)),y(E))},[f]),pt=l.useCallback(()=>({composition:c,contrastCount:d,excludeNoImage:g,sameStructureOnly:A,phonemeView:f,gradeFilter:v}),[c,d,g,A,f,v]),pe=l.useCallback(E=>{m(E.composition),p(E.contrastCount),k(E.excludeNoImage),T(E.sameStructureOnly??!0),y(E.phonemeView),D(Array.isArray(E.gradeFilter)?E.gradeFilter:[])},[]);return{difficulty:w,contrastCount:d,composition:c,choseong:c.cho,excludeNoImage:g,sameStructureOnly:A,gradeFilter:v,posFilter:I,wordTypeFilter:G,matchesWordAttributes:nt,poolVersion:ne,filterSections:tt,filterSelected:Ve,handleFilterSelect:te,phonemeView:f,setPhonemeView:oe,phonemeGroupLabel:H.phonemeGroup,wordCount:ye,getFilterSnapshot:pt,restoreFilterSnapshot:pe}}function Fd(e){const t=s=>s?st(s):null,n=t(e.cho),o=t(e.jung),u=e.jong===Qe,r=u?null:t(e.jong),i=e.syllable!=null?ao(e.syllable):null;return!n&&!o&&!r&&!u&&!i?null:{cho:n,jung:o,jong:r,jongNone:u,syllable:i}}function Hd(e,t,n,o,u,r,i=!0,s="char",d=[]){const[p,f]=l.useState({}),[y,c]=l.useState(!1),{cho:m=null,jung:S=null,jong:w=null,syllable:_=null}=o??{},g=d.length>0?d.slice().sort().join(","):"";return l.useEffect(()=>{r>0&&Oa(u).catch(()=>{})},[r,u]),l.useEffect(()=>{let k=!1;return c(!0),(async()=>{const A=Fd({cho:m,jung:S,jong:w,syllable:_}),T=`${m??""}_${S??""}_${w??""}_${_??""}_${g}`,v={};await Promise.all(e.map(async D=>{const I=Fn[D.key];try{const $=await iu(D.key,{difficulty:I.difficulty?t:null,contrastCount:I.difficulty?n:1,composition:I.choseong?A:null,count:5,excludeNoImage:u,sameStructureOnly:i,phonemeView:s,grade:d.length>0?d:null});$&&$.length>0?v[D.key]={id:`wt-${D.key}-${t}-${T}-${Date.now()}`,name:D.label,training_type:D.key,category_main_code:"WORD",iconColor:D.color,subTitle:D.subTitle,items:$,itemCount:$.length}:v[D.key]={id:`wt-${D.key}-empty`,name:D.label,training_type:D.key,category_main_code:"WORD",iconColor:D.color,subTitle:D.subTitle,items:[],itemCount:0,__empty:!0}}catch{v[D.key]=null}})),k||(f(v),c(!1))})(),()=>{k=!0}},[t,n,m,S,w,_,u,i,s,r,g]),{perTypeData:p,generating:y}}function zd(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619);return t>>>0}function Vd(e){let t=e>>>0;return()=>{t|=0,t=t+1831565813|0;let n=Math.imul(t^t>>>15,1|t);return n=n+Math.imul(n^n>>>7,61|n)^n,((n^n>>>14)>>>0)/4294967296}}const Mn=at;function co(e,t){const n=t?Vd(zd(t)):Math.random;return{LISTEN_IN_NOISE:Mn(Zt,Math.max(0,e.LISTEN_IN_NOISE||0),n),SHORT_STORY:Mn(Jt,Math.max(0,e.SHORT_STORY||0),n),LONG_STORY:Mn(Qt,Math.max(0,e.LONG_STORY||0),n),ORDERING_SENTENCE:Mn(en,Math.max(0,e.ORDERING_SENTENCE||0),n)}}function Qu(e){return e?!!(e.LISTEN_IN_NOISE?.length||e.SHORT_STORY?.length||e.LONG_STORY?.length||e.ORDERING_SENTENCE?.length):!1}const Ud={LISTEN_IN_NOISE:3,SHORT_STORY:2,LONG_STORY:1,ORDERING_SENTENCE:2};function er(e=!1,t=Ud,n){const o=kn(Date.now()),u=kn(Date.now()-864e5),r=`${n??""}|${o}`,i=`${n??""}|${u}`;return Zt.length>0||Jt.length>0||Qt.length>0||en.length>0?{today:co(t,r),yesterday:co(t,i)}:{today:co(t,r),yesterday:null}}function Gd(e){const t=l.useRef({LISTEN_IN_NOISE:[],SHORT_STORY:[],LONG_STORY:[],ORDERING_SENTENCE:[]}),n=l.useRef(null),[o,u]=l.useState(!1),[r,i]=l.useState(!1),[s,d]=l.useState(0),[p,f]=l.useState(!1);l.useEffect(()=>{let c=!1,m,S=0;const w=40,_=()=>{m!==void 0&&(clearInterval(m),m=void 0)};let g=!1;try{const T=new URLSearchParams(window.location.search),v=T.get("forceRefresh")||T.get("force");g=v==="1"||v==="true"}catch{}const k=T=>{t.current=T.today,n.current=T.yesterday,u(!0),f(!0),d(v=>v+1),c=!0,_()},A=async()=>{if(c)return;if(!g){const v=er(!1,void 0,e);if(Qu(v.today)){k(v);return}}try{await dd(3e3)}catch{}if(c)return;const T=er(g,void 0,e);if(Qu(T.today)){k(T);return}++S>=w&&(u(!0),f(!1),c=!0,_())};return A(),m=setInterval(A,250),()=>{c=!0,_()}},[e]);const y=l.useCallback(c=>{const m=r?n.current:t.current,S=r?t.current:n.current;return m?.[c]?.length?m[c]:S?.[c]?.length?S[c]:void 0},[r,s]);return{loaded:o,hasData:p,showYesterday:r,setShowYesterday:i,getTrainingPerType:y}}const Lt=[];let Nn=!1;function tr(e){if(e.key!=="Escape"||e.defaultPrevented)return;const t=Lt[Lt.length-1];t&&(e.stopPropagation(),t())}function Yd(e){return Lt.push(e),!Nn&&typeof document<"u"&&(document.addEventListener("keydown",tr),Nn=!0),()=>{const t=Lt.lastIndexOf(e);t>=0&&Lt.splice(t,1),Lt.length===0&&Nn&&typeof document<"u"&&(document.removeEventListener("keydown",tr),Nn=!1)}}function qd(e,t=!0){const n=vo(e);l.useEffect(()=>{if(t)return Yd(()=>{n.current?.()})},[t,n])}const ho=(e,t)=>`${e}:${t??1}`,fo=new Map;function Wd(e,t){const[n,o]=l.useState(0),u=e.map(r=>ho(r.word,r.homonum)).join("|");return l.useEffect(()=>{const r=(u?u.split("|"):[]).filter(d=>!fo.has(d));if(r.length===0)return;let i=!1;const s=Array.from(new Set(r.map(d=>d.slice(0,d.lastIndexOf(":")))));return t(s).then(d=>{if(!(i||d.length===0)){for(const p of d)p.Meaning&&fo.set(ho(p.Word,p.Homonum??void 0),p.Meaning);o(p=>p+1)}}),()=>{i=!0}},[u,t]),l.useMemo(()=>{const r=u?u.split("|"):[],i=new Map;for(const s of r){const d=fo.get(s);d!=null&&i.set(s,d)}return i},[u,n])}function Kd(e,t,n){const o=Number.isFinite(t)&&t>=1?Math.floor(t):1,u=Math.max(1,Math.ceil(e.length/o)),r=Number.isFinite(n)?Math.min(Math.max(1,Math.floor(n)),u):1;return{pageItems:l.useMemo(()=>e.slice((r-1)*o,r*o),[e,r,o]),totalPages:u,curPage:r}}function Xd(e="warning"){const[t,n]=l.useState(""),[o,u]=l.useState(e),[r,i]=l.useState(0),s=l.useCallback((y,c)=>{u(c),n(y),i(m=>m+1)},[]),d=l.useCallback(y=>s(y,"warning"),[s]),p=l.useCallback(y=>s(y,"normal"),[s]),f=l.useCallback(()=>n(""),[]);return{toastMessage:t,toastType:o,toastKey:r,showToast:s,showWarning:d,showNormal:p,clearToast:f}}const nn={blue:"#60A5FA",green:"#4ADE80",amber:"#FBBF24",purple:"#A78BFA",pink:"#F472B6"},on=nn.blue,Tn=nn.green,un=nn.amber,xn=nn.purple,Zd=nn.pink,Jd=[{key:"discrimination",label:"\uBCC0\uBCC4\uD6C8\uB828",disc:"\uB450 \uC18C\uB9AC\uAC00 \uAC19\uC740\uC9C0 \uB2E4\uB978\uC9C0, \uB610\uB294 \uD2B9\uC815 \uC18C\uB9AC\uB97C \uAD6C\uBCC4\uD558\uB294 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"ear",types:[{key:"SAME_SOUND_PICK",label:"\uAC19\uC740 \uC18C\uB9AC \uACE0\uB974\uAE30",icon:"volume-2",color:on,subTitle:"\uB4E4\uC740 \uC18C\uB9AC\uC640 \uAC19\uC740 \uB2E8\uC5B4 \uCE74\uB4DC\uB97C \uACE0\uB974\uC138\uC694."},{key:"SAME_OR_DIFF",label:"\uAC19\uC740\uC9C0 \uB2E4\uB978\uC9C0 \uB9DE\uD788\uAE30",icon:"diff",color:on,subTitle:"\uB450 \uC18C\uB9AC\uAC00 \uAC19\uC740\uC9C0, \uB2E4\uB978\uC9C0 \uAD6C\uBD84\uD558\uC138\uC694."},{key:"HEAR_AND_PICK_SAME",label:"\uC77C\uCE58\uD558\uB294 \uB2E8\uC5B4 \uB9DE\uD788\uAE30",icon:"headphones",color:on,subTitle:"\uB4E4\uC740 \uC18C\uB9AC\uC758 \uB2E8\uC5B4 \uCE74\uB4DC\uB97C \uACE0\uB974\uC138\uC694."},{key:"HEAR_AND_PICK_INCLUDED",label:"\uD55C \uC74C\uC808 \uD3EC\uD568 \uB2E8\uC5B4 \uB9DE\uD788\uAE30",icon:"scan-search",color:on,subTitle:"\uB4E4\uC740 \uC74C\uC808\uC774 \uD3EC\uD568\uB41C \uB2E8\uC5B4 \uCE74\uB4DC\uB97C \uACE0\uB974\uC138\uC694."},{key:"STARTS_WITH_SAME_SOUND",label:"\uCCAB \uC74C\uC808\uC774 \uAC19\uC740 \uB2E8\uC5B4 \uB9DE\uD788\uAE30",icon:"play-circle",color:on,subTitle:"\uB4E4\uC740 \uB2E8\uC5B4\uC640 \uAC19\uC740 \uC18C\uB9AC\uB85C \uC2DC\uC791\uD558\uB294 \uB2E8\uC5B4\uB97C \uACE0\uB974\uC138\uC694."}]},{key:"synthesis",label:"\uD569\uC131\uD6C8\uB828",disc:"\uB450 \uAC1C \uC774\uC0C1\uC758 \uC74C\uC808\uC774\uB098 \uC74C\uC18C\uB97C \uD569\uCCD0 \uB2E8\uC5B4\uB97C \uB9CC\uB4DC\uB294 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"git-merge",types:[{key:"MERGE_2_SYLLABLES",label:"\uC74C\uC808 2\uAC1C \uD569\uCE58\uAE30",icon:"link-2",color:Tn,subTitle:"\uB450 \uC74C\uC808\uC744 \uD569\uCE58\uBA74 \uC5B4\uB5A4 \uB2E8\uC5B4\uAC00 \uB420\uAE4C\uC694?"},{key:"MERGE_3_SYLLABLES",label:"\uC74C\uC808 3\uAC1C \uD569\uCE58\uAE30",icon:"git-merge",color:Tn,subTitle:"\uC138 \uC74C\uC808\uC744 \uD569\uCE58\uBA74 \uC5B4\uB5A4 \uB2E8\uC5B4\uAC00 \uB420\uAE4C\uC694?"},{key:"MERGE_2_PHONEMES",label:"\uC74C\uC18C 2\uAC1C \uD569\uCE58\uAE30",icon:"combine",color:Tn,subTitle:"\uB450 \uC74C\uC18C\uB97C \uD569\uCE58\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"},{key:"MERGE_3_PHONEMES",label:"\uC74C\uC18C 3\uAC1C \uD569\uCE58\uAE30",icon:"braces",color:Tn,subTitle:"\uC138 \uC74C\uC18C\uB97C \uD569\uCE58\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"}]},{key:"deletion",label:"\uD0C8\uB77D\uD6C8\uB828",disc:"\uB2E8\uC5B4\uC5D0\uC11C \uC74C\uC808\uC774\uB098 \uC74C\uC18C\uB97C \uC81C\uAC70\uD588\uC744 \uB54C \uB0A8\uB294 \uC18C\uB9AC\uB97C \uC778\uC2DD\uD558\uB294 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"scissors",types:[{key:"DROP_1_FROM_2SYLL",label:"2\uC74C\uC808\uC5D0\uC11C 1\uC74C\uC808 \uD0C8\uB77D",icon:"scissors",color:un,subTitle:"2\uC74C\uC808 \uB2E8\uC5B4\uC5D0\uC11C \uD55C \uC74C\uC808\uC744 \uBE7C\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"},{key:"DROP_1_FROM_3SYLL",label:"3\uC74C\uC808\uC5D0\uC11C 1\uC74C\uC808 \uD0C8\uB77D",icon:"minus-circle",color:un,subTitle:"3\uC74C\uC808 \uB2E8\uC5B4\uC5D0\uC11C \uD55C \uC74C\uC808\uC744 \uBE7C\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"},{key:"DROP_PART_FROM_COMPOUND",label:"\uD569\uC131\uC5B4\uC5D0\uC11C \uBD80\uBD84\uD0C8\uB77D",icon:"unlink",color:un,subTitle:"\uD569\uC131\uC5B4\uC758 \uC77C\uBD80\uB97C \uBE7C\uBA74 \uC5B4\uB5A4 \uB2E8\uC5B4\uAC00 \uB420\uAE4C\uC694?"},{key:"DROP_FINAL_CONSONANT_FROM_1SYLL",label:"1\uC74C\uC808\uC5D0\uC11C \uBC1B\uCE68 \uD0C8\uB77D",icon:"eraser",color:un,subTitle:"\uBC1B\uCE68\uC744 \uBE7C\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"},{key:"REMOVE_CONSONANT_AND_IDENTIFY_PHONEME",label:"1\uC74C\uC808\uC5D0\uC11C \uC790\uC74C \uD0C8\uB77D",icon:"audio-lines",color:un,subTitle:"\uC790\uC74C\uC744 \uBE7C\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB0A8\uC744\uAE4C\uC694?"}]},{key:"substitution",label:"\uB300\uCE58\uD6C8\uB828",disc:"\uB2E8\uC5B4\uC758 \uC77C\uBD80 \uC74C\uC808\uC774\uB098 \uC74C\uC18C\uB97C \uBC14\uAFB8\uC5B4 \uC0C8\uB85C\uC6B4 \uC18C\uB9AC\uB97C \uB9CC\uB4DC\uB294 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"replace",types:[{key:"CHANGE_1_SYLL_IN_2SYLL",label:"2\uC74C\uC808\uC5D0\uC11C \uD55C \uC74C\uC808 \uBC14\uAFB8\uAE30",icon:"replace",color:xn,subTitle:"2\uC74C\uC808 \uB2E8\uC5B4\uC758 \uD55C \uC74C\uC808\uC744 \uBC14\uAFD4 \uC0C8 \uB2E8\uC5B4\uB97C \uB9CC\uB4DC\uC138\uC694."},{key:"CHANGE_1_SYLL_IN_3SYLL",label:"3\uC74C\uC808\uC5D0\uC11C \uD55C \uC74C\uC808 \uBC14\uAFB8\uAE30",icon:"shuffle",color:xn,subTitle:"3\uC74C\uC808 \uB2E8\uC5B4\uC758 \uD55C \uC74C\uC808\uC744 \uBC14\uAFD4 \uC0C8 \uB2E8\uC5B4\uB97C \uB9CC\uB4DC\uC138\uC694."},{key:"CHANGE_1_PHONEME_IN_1SYLL",label:"1\uC74C\uC808\uC5D0\uC11C \uD55C \uC74C\uC18C \uBC14\uAFB8\uAE30",icon:"arrow-right-left",color:xn,subTitle:"1\uC74C\uC808 \uB2E8\uC5B4\uC758 \uD55C \uC74C\uC18C\uB97C \uBC14\uAFD4 \uC0C8 \uC18C\uB9AC\uB97C \uB9CC\uB4DC\uC138\uC694."},{key:"CHANGE_1_PHONEME_IN_2SYLL",label:"2\uC74C\uC808\uC5D0\uC11C \uD55C \uC74C\uC18C \uBC14\uAFB8\uAE30",icon:"flip-horizontal",color:xn,subTitle:"2\uC74C\uC808 \uB2E8\uC5B4\uC758 \uD55C \uC74C\uC18C\uB97C \uBC14\uAFD4 \uC0C8 \uB2E8\uC5B4\uB97C \uB9CC\uB4DC\uC138\uC694."}]},{key:"attention",label:"\uCCAD\uAC01\uC801\uC8FC\uC758\uB825\uD6C8\uB828",disc:"\uC5EC\uB7EC \uC18C\uB9AC\uB97C \uB4E3\uACE0 \uC21C\uC11C\uB97C \uAE30\uC5B5\uD558\uB294 \uC8FC\uC758\uB825\uACFC \uB2E8\uAE30 \uAE30\uC5B5 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"list-ordered",types:[{key:"LISTEN_AND_REMEMBER_ORDER",label:"\uB4E3\uACE0 \uC21C\uC11C\uB300\uB85C \uAE30\uC5B5\uD558\uAE30",icon:"list-ordered",color:Zd,subTitle:"\uC138 \uB2E8\uC5B4\uB97C \uB4E4\uC740 \uC21C\uC11C\uB300\uB85C \uCE74\uB4DC\uB97C \uC120\uD0DD\uD558\uC138\uC694."}]}];function Qd(){const{t:e}=gt.useTranslation();return l.useMemo(()=>{const t=Object.fromEntries(pd(e).map(o=>[o.key,o.label])),n={...t};return Jd.flatMap(o=>o.types).forEach(o=>{n[o.key]=e(`trainingType.${o.key}.label`,{defaultValue:o.label})}),{sentence:t,all:n}},[e])}exports.CACHE_GROUPS=Ho,exports.CORE_VERSION=Cd,exports.DocumentTitleSuppressContext=Ro,exports.EMPTY_COMPOSITION=lo,exports.MediaQueryOverrideContext=Do,exports.NO_CODA=Qe,exports.SYLLABLE_MIN=et,exports.VAP_PAGE_SIZE_OPTIONS=Go,exports.buildGradeSection=Hu,exports.buildPartOfSpeechSection=zu,exports.buildPositionSection=wd,exports.buildSelectSection=Ad,exports.buildSyllableSection=kd,exports.buildWordTypeSection=Vu,exports.charToPronValue=Wu,exports.convertComposition=Xu,exports.fmtBytes=Pr,exports.lsBytes=zo,exports.meaningKey=ho,exports.pronToCharValue=Ku,exports.syllableToFilter=ao,exports.today=zt,exports.toggleAttributeFilter=Md,exports.useCacheManagement=$r,exports.useDailyTrainingSelection=Gd,exports.useDelayedHoverAnchor=bd,exports.useDeviceManagement=Wr,exports.useDocumentTitle=br,exports.useEscToClose=qd,exports.useFontScale=gr,exports.useHoverAnchor=$u,exports.useMediaQuery=Er,exports.usePagedList=Kd,exports.usePasswordChange=kr,exports.useRelativeDay=Sr,exports.useTablePaging=Yr,exports.useTableSort=qr,exports.useToastState=Xd,exports.useTrainingTypeLabels=Qd,exports.useVisitAllPanel=Gr,exports.useVisitHistory=zr,exports.useVisitSchedule=Ur,exports.useWindowEvent=Oo,exports.useWordAttributeFilterKeys=Fu,exports.useWordDataStats=Fr,exports.useWordMeanings=Wd,exports.useWordTrainingDataGeneration=Hd,exports.useWordTrainingFilter=$d,exports.valueToJamos=st;
1
+ "use strict";var a=require("react"),Ee=require("react-i18next"),ru=typeof document<"u"?document.currentScript:null;function Mt({storageKey:e="fontScale",baseFont:u=20,minScale:t=.8,maxScale:n=1.4,step:o=.1,lineHeightRatio:l=1.4}={}){const r=p=>Math.max(t,Math.min(n,Number(p))),[s,c]=a.useState(()=>{try{const p=localStorage.getItem(e),h=p?Number(p):1;return Number.isFinite(h)?h:1}catch{return 1}});a.useEffect(()=>{try{localStorage.setItem(e,String(s))}catch{}},[e,s]);const C=p=>{c(typeof p=="function"?h=>r(p(h)):r(p))},d=()=>C(p=>+(p+o).toFixed(6)),f=()=>C(p=>+(p-o).toFixed(6)),i=s<n-Number.EPSILON,g=s>t+Number.EPSILON,E=Math.round(u*s),w=Math.round(E*l);return{scale:s,setScale:C,increase:d,decrease:f,canIncrease:i,canDecrease:g,fontSize:E,lineHeight:w}}const ju=a.createContext(null);function xt(e){return/max-width:\s*7[0-9][0-9]px/.test(e)}function Pt(e){const u=a.useContext(ju),t=l=>typeof window>"u"||!window.matchMedia?!1:window.matchMedia(l).matches,[n,o]=a.useState(t(e));return a.useEffect(()=>{if(typeof window>"u"||!window.matchMedia)return;const l=window.matchMedia(e),r=c=>o(c.matches),s=l;return s.addEventListener?s.addEventListener("change",r):s.addListener&&s.addListener(r),o(l.matches),()=>{s.removeEventListener?s.removeEventListener("change",r):s.removeListener&&s.removeListener(r)}},[e]),u&&typeof u.mobile=="boolean"&&xt(e)?u.mobile:n}function Iu(e){const u=a.useRef(e);return a.useEffect(()=>{u.current=e}),u}function Lu(e,u){const t=Iu(u);a.useEffect(()=>{const n=()=>t.current();try{window.addEventListener(e,n)}catch{}return()=>{try{window.removeEventListener(e,n)}catch{}}},[e,t])}const su=" \xB7 ",Ru=(()=>{if(typeof document>"u")return"";const e=document.title;return e.includes(su)?e.split(su).pop()??e:e})(),Mu=a.createContext(!1);function Ft(e){const u=a.useContext(Mu);a.useEffect(()=>{if(u||typeof e!="string"||!e)return;const t=document.title;return document.title=Ru?`${e}${su}${Ru}`:e,()=>{document.title=t}},[e,u])}function kt(){const{t:e}=Ee.useTranslation();return a.useCallback(u=>{if(!u)return"";const t=new Date(u).getTime();if(Number.isNaN(t))return"";const n=Math.floor((Date.now()-t)/864e5);return n<=0?e("myHomework.relativeDay.today","\uC624\uB298"):n===1?e("myHomework.relativeDay.yesterday","\uC5B4\uC81C"):e("myHomework.relativeDay.daysAgo",{n})},[e])}function vt(e){const[u,t]=a.useState({current:"",next:"",confirm:""}),[n,o]=a.useState(null),[l,r]=a.useState(!1),s=a.useRef(null);a.useEffect(()=>()=>{s.current!==null&&clearTimeout(s.current)},[]);const c=a.useCallback(()=>{t({current:"",next:"",confirm:""}),o(null)},[]),C=a.useCallback(async()=>{if(!u.current){o({type:"error",text:"\uD604\uC7AC \uBE44\uBC00\uBC88\uD638\uB97C \uC785\uB825\uD558\uC138\uC694."});return}if(!u.next){o({type:"error",text:"\uC0C8 \uBE44\uBC00\uBC88\uD638\uB97C \uC785\uB825\uD558\uC138\uC694."});return}if(u.next!==u.confirm){o({type:"error",text:"\uC0C8 \uBE44\uBC00\uBC88\uD638\uAC00 \uC77C\uCE58\uD558\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4."});return}r(!0);const d=e?await e(u.current,u.next):null;if(r(!1),d){o({type:"error",text:d});return}o({type:"success",text:"\uBE44\uBC00\uBC88\uD638\uAC00 \uBCC0\uACBD\uB418\uC5C8\uC2B5\uB2C8\uB2E4."}),t({current:"",next:"",confirm:""}),s.current!==null&&clearTimeout(s.current),s.current=setTimeout(()=>o(null),1500)},[u,e]);return{pw:u,setPw:t,pwMsg:n,setPwMsg:o,pwLoading:l,handleChangePw:C,reset:c}}const q=["\u3131","\u3132","\u3134","\u3137","\u3138","\u3139","\u3141","\u3142","\u3143","\u3145","\u3146","\u3147","\u3148","\u3149","\u314A","\u314B","\u314C","\u314D","\u314E"],se=["\u314F","\u3150","\u3151","\u3152","\u3153","\u3154","\u3155","\u3156","\u3157","\u3158","\u3159","\u315A","\u315B","\u315C","\u315D","\u315E","\u315F","\u3160","\u3161","\u3162","\u3163"],Q=["","\u3131","\u3132","\u3133","\u3134","\u3135","\u3136","\u3137","\u3139","\u313A","\u313B","\u313C","\u313D","\u313E","\u313F","\u3140","\u3141","\u3142","\u3144","\u3145","\u3146","\u3147","\u3148","\u314A","\u314B","\u314C","\u314D","\u314E"];function V(e){if(!e)return null;const u=e.charCodeAt(0)-44032;return u<0||u>=11172?null:{cho:Math.floor(u/588),jung:Math.floor(u%588/28),jong:u%28}}function Vt(){const e=new Map;return u=>{let t=e.get(u);return t||(t=[...u].map(n=>V(n)),e.set(u,t)),t}}function de(e,u,t=0){return String.fromCharCode(44032+(e*21+u)*28+t)}function Gt(e,u){if(!e||!u||e===u||e.length!==u.length)return"random";let t=0,n=null;for(let o=0;o<e.length;o++){const l=V(e[o]),r=V(u[o]);if(!l||!r)return"random";if(l.cho===r.cho&&l.jung===r.jung&&l.jong===r.jong)continue;t++;const s=l.cho!==r.cho,c=l.jung!==r.jung,C=l.jong!==r.jong;(s?1:0)+(c?1:0)+(C?1:0)>1?n="multi":s?n="cho":c?n="jung":n="jong"}return t!==1?"random":n==="cho"?"cho":n==="jung"?"jung":n==="jong"?"jong":"random"}const we={3:["\u3131","\u3145"],5:["\u3134","\u3148"],6:["\u3134","\u314E"],9:["\u3139","\u3131"],10:["\u3139","\u3141"],11:["\u3139","\u3142"],12:["\u3139","\u3145"],13:["\u3139","\u314C"],14:["\u3139","\u314D"],15:["\u3139","\u314E"],18:["\u3142","\u3145"]};Object.fromEntries(Object.entries(we).map(([e,u])=>[u.join(""),Q[Number(e)]]));function Yt(e,u){if(!e||!u)return!1;for(const t of e){const n=V(t);if(n){if(q[n.cho]===u)return!0;if(n.jong>0){if(Q[n.jong]===u)return!0;const o=we[n.jong];if(o&&o.includes(u))return!0}}}return!1}function Ge(e){if(!e)return 0;let u=0;for(const t of e)V(t)&&u++;return u}function $t(e){if(!e)return!1;let u=!1;for(const t of e){const n=V(t);if(n&&(u=!0,n.jong>0))return!1}return u}function Ht(e,u){if(e.jong<=0)return!1;if(u.includes(Q[e.jong]))return!0;const t=we[e.jong];return!!t&&t.some(n=>u.includes(n))}function Ut(e,u,t){if(!e)return!1;const n=[...e],o=l=>{const r=V(n[l]);if(!r||u.cho&&!u.cho.includes(q[r.cho])||u.jung&&!u.jung.includes(se[r.jung]))return!1;if(u.jongNone){if(r.jong>0)return!1}else if(u.jong&&!Ht(r,u.jong))return!1;return!0};if(t==="head")return o(0);if(t==="tail")return o(n.length-1);if(t==="mid"){for(let l=1;l<n.length-1;l++)if(o(l))return!0;return!1}for(let l=0;l<n.length;l++)if(o(l))return!0;return!1}const Kt={cho:q.length,jung:se.length,jong:Q.length};function Wt(e,u,t,n,o=1/0){if(!e||t<1)return[];const l=[...e].map(f=>V(f));if(l.some(f=>!f))return[];const r=l,s=r.length;if(t>s)return[];const c=Kt[u],C=new Set,d=[];(function f(i,g){if(g.length===t){d.push([...g]);return}for(let E=i;E<s;E++)g.push(E),f(E+1,g),g.pop()})(0,[]);for(const f of d)if((function i(g,E){if(C.size>=o)return;if(g===f.length){const h=E.map(S=>de(S.cho,S.jung,S.jong)).join("");h!==e&&n.has(h)&&C.add(h);return}const w=f[g],p=r[w][u];for(let h=0;h<c;h++){if(h===p)continue;const S=E.slice();if(S[w]={...E[w],[u]:h},i(g+1,S),C.size>=o)return}})(0,r),C.size>=o)break;return[...C]}function qt(e,u){if(!e||!u||e.length!==u.length)return-1;let t=0;for(let n=0;n<e.length;n++){const o=V(e[n]),l=V(u[n]);if(!o||!l)return-1;o.cho!==l.cho&&t++,o.jung!==l.jung&&t++,o.jong!==l.jong&&t++}return t}const xu="word_pair_index_v2",Pu="word_pair_index_sig_v2";let be=null;function zt(){try{if(typeof localStorage>"u")return null;const e=localStorage.getItem(xu),u=localStorage.getItem(Pu);return!e||!u?null:{index:JSON.parse(e),sig:u}}catch{return null}}function Ae(){if(be)return be;const e=zt();return e?(be=e.index,e.sig,be):null}function Jt(){be=null;try{typeof localStorage<"u"&&(localStorage.removeItem(xu),localStorage.removeItem(Pu))}catch{}}const Fu="word_image_existence_map_v1";let pe=null;function ku(){if(pe)return pe;try{const e=typeof localStorage<"u"?localStorage.getItem(Fu):null;pe=e?JSON.parse(e):{}}catch{pe={}}return pe}function Zt(e,u){return`${e}_${u??1}`}function Qt(e,u){const t=ku(),n=Zt(e,u);return n in t?t[n]:void 0}function vu(){const e=ku(),u=Object.values(e);return u.length===0?null:{total:u.length,exists:u.filter(Boolean).length}}function Xt(){pe={};try{typeof localStorage<"u"&&localStorage.removeItem(Fu)}catch{}}const Vu=[{id:"wordData",labelKey:"settings.cache.group.wordData.label",subKey:"settings.cache.group.wordData.sub",keys:["word_data_cache","word_data_version"]},{id:"pairIndex",labelKey:"settings.cache.group.pairIndex.label",subKey:"settings.cache.group.pairIndex.sub",keys:["word_pair_index_v2","word_pair_index_sig_v2"]},{id:"imageCache",labelKey:"settings.cache.group.imageCache.label",subKey:"settings.cache.group.imageCache.sub",keys:["word_image_existence_map_v1"]}];function Gu(e){return e.reduce((u,t)=>{try{const n=localStorage.getItem(t);return u+(n?new Blob([n]).size:0)}catch{return u}},0)}function en(e){return e===0?"0 B":e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(1)} KB`:e<1024*1024*1024?`${(e/(1024*1024)).toFixed(2)} MB`:`${(e/(1024*1024*1024)).toFixed(2)} GB`}function un(e){const{t:u}=Ee.useTranslation(),[t,n]=a.useState({}),[o,l]=a.useState(null),[r,s]=a.useState(null),[c,C]=a.useState(null),d=a.useCallback(()=>{const i={};Vu.forEach(g=>{i[g.id]=Gu([...g.keys])}),n(i),typeof navigator<"u"&&navigator.storage?.estimate&&navigator.storage.estimate().then(g=>{C({usage:g.usage??0,quota:g.quota??0})}).catch(()=>{})},[]);a.useEffect(()=>{d()},[d]);const f=a.useCallback(async i=>{l(i);try{i==="wordData"?(localStorage.removeItem("word_data_cache"),localStorage.removeItem("word_data_version")):i==="pairIndex"?Jt():i==="imageCache"&&Xt(),d(),e?.(u("settings.cache.cleared","\uCE90\uC2DC\uAC00 \uC0AD\uC81C\uB418\uC5C8\uC2B5\uB2C8\uB2E4."))}finally{l(null)}},[d,e,u]);return{cacheSizes:t,clearingId:o,confirmCacheId:r,setConfirmCacheId:s,storageEstimate:c,refreshCacheSizes:d,handleClearCache:f}}function tn(e){const[u,t]=a.useState(null),[n,o]=a.useState(null),l=a.useCallback(()=>{const r=Ae();if(r){const c=Object.values(r),C=c.filter(d=>d.cho.length+d.jung.length+d.jong.length>0).length;t({matched:C,total:c.length})}else t(null);const s=vu();o(s?{exists:s.exists,total:s.total}:null)},[]);return a.useEffect(()=>{l();const r=setTimeout(l,1e3);return()=>clearTimeout(r)},[e?.length,l]),{pairStats:u,imgStats:n,setPairStats:t,setImgStats:o,refreshStats:l}}function Yu(e,u=[]){const[t,n]=a.useState(u),[o,l]=a.useState(null),[r,s]=a.useState(!1),[c,C]=a.useState(e),d=a.useRef(r);a.useEffect(()=>{d.current=r});const f=a.useRef(null);a.useEffect(()=>{if(d.current)return;const h=f.current;h!==null&&h.length===u.length&&h.every((S,B)=>S===u[B])||(f.current=u,n(u))},[u]);const i=a.useCallback(h=>{l(h),s(!1),C({...h})},[]),g=a.useCallback(()=>s(!0),[]),E=a.useCallback(()=>s(!1),[]),w=a.useCallback((h,S)=>{n(h),l(S),s(!1)},[]),p=a.useCallback(h=>{n(S=>S.filter(B=>B!==h)),l(null)},[]);return{list:t,setList:n,selected:o,setSelected:l,isEditing:r,setIsEditing:s,editForm:c,setEditForm:C,openDetail:i,startEditing:g,cancelEditing:E,commitEdit:w,remove:p}}const De=()=>{const e=new Date;return{year:String(e.getFullYear()),month:String(e.getMonth()+1).padStart(2,"0"),day:String(e.getDate()).padStart(2,"0")}},nn={year:"",month:"",day:"",hour:"09",minute:"00",memo:""};function on(e=[]){const{list:u,setList:t,selected:n,setSelected:o,isEditing:l,setIsEditing:r,editForm:s,setEditForm:c,openDetail:C,commitEdit:d}=Yu(nn,e),{year:f,month:i,day:g}=De(),[E,w]=a.useState({year:f,month:i,day:g,hour:"09",minute:"00",memo:""});return{visitHistory:u,visitForm:E,setVisitForm:w,setVisit:p=>h=>w(S=>({...S,[p]:h})),selectedVisit:n,setSelectedVisit:o,isEditingVisit:l,setIsEditingVisit:r,editVisitForm:s,setEditVisitForm:c,openVisitDetail:C,handleVisitSave:p=>{t(A=>[E,...A]);const{year:h,month:S,day:B}=De();w({year:h,month:S,day:B,hour:"09",minute:"00",memo:""}),p?.()},handleVisitEditSave:()=>{d(p=>p.map(h=>h===n?s:h),s)},addVisit:p=>{t(h=>[p,...h])},removeVisit:p=>{t(h=>h.filter(S=>S!==p))},revertVisitEdit:(p,h)=>{t(S=>S.map(B=>B===h?p:B)),o(S=>S===h?p:S)}}}const $u=e=>`${e.year.padStart(4,"0")}-${e.month.padStart(2,"0")}-${e.day.padStart(2,"0")} ${e.hour.padStart(2,"0")}:${e.minute.padStart(2,"0")}`,Ye=e=>[...e].sort((u,t)=>{const n=$u(u),o=$u(t);return n<o?-1:n>o?1:0}),ln={year:"",month:"",day:"",hour:"09",minute:"00",memo:""};function rn(e,u=[]){const t=a.useMemo(()=>Ye(u),[u]),{list:n,setList:o,selected:l,setSelected:r,isEditing:s,setIsEditing:c,editForm:C,setEditForm:d,openDetail:f,commitEdit:i,remove:g}=Yu(ln,t),[E,w]=a.useState([]),{year:p,month:h,day:S}=De(),[B,A]=a.useState({year:p,month:h,day:S,hour:"09",minute:"00",memo:""}),_=T=>P=>A($=>({...$,[T]:P})),b=T=>{o(le=>Ye([...le,B]));const{year:P,month:$,day:X}=De();A({year:P,month:$,day:X,hour:"09",minute:"00",memo:""}),T?.()},I=()=>{i(T=>Ye(T.map(P=>P===l?C:P)),C)},R=a.useCallback(T=>{g(T)},[g]),v=a.useCallback(T=>{e({year:T.year,month:T.month,day:T.day,hour:T.hour,minute:T.minute,memo:T.memo}),g(T)},[e,g]),j=a.useCallback(T=>{o(P=>P.filter($=>$!==T)),w(P=>[T,...P]),r(null)},[o,r]),G=a.useCallback(T=>{o(P=>Ye([...P,T]))},[o]),x=a.useCallback(T=>{o(P=>P.filter($=>$!==T))},[o]),k=a.useCallback((T,P)=>{o($=>$.map(X=>X===P?T:X)),r($=>$===P?T:$)},[o,r]);return{scheduleList:n,noShowList:E,addSchedule:G,removeSchedule:x,revertScheduleEdit:k,scheduleForm:B,setScheduleForm:A,setSchedule:_,selectedSchedule:l,setSelectedSchedule:r,isEditingSchedule:s,setIsEditingSchedule:c,editScheduleForm:C,setEditScheduleForm:d,openScheduleDetail:f,handleScheduleSave:b,handleScheduleEditSave:I,handleScheduleDelete:R,handleScheduleToVisit:v,handleScheduleNoVisit:j}}const Hu=[{value:"10",label:"10\uAC1C\uC529 \uBCF4\uAE30"},{value:"25",label:"25\uAC1C\uC529 \uBCF4\uAE30"},{value:"50",label:"50\uAC1C\uC529 \uBCF4\uAE30"},{value:"100",label:"100\uAC1C\uC529 \uBCF4\uAE30"}];function sn(e){const[u,t]=a.useState(""),[n,o]=a.useState("25"),[l,r]=a.useState("all"),[s,c]=a.useState(1),C=a.useMemo(()=>e.filter(({item:g,status:E})=>!(u&&!g.memo.includes(u)||l!=="all"&&E!==l)),[e,u,l]),d=Math.max(1,Math.ceil(C.length/Number(n))),f=Math.min(s,d),i=a.useMemo(()=>C.slice((f-1)*Number(n),f*Number(n)),[C,f,n]);return{vapSearch:u,setVapSearch:t,vapPageSize:n,setVapPageSize:o,vapStatus:l,setVapStatus:r,vapPage:f,setVapPage:c,vapFiltered:C,vapTotal:d,vapPageItems:i}}function an(e,u){const{t}=Ee.useTranslation(),[n,o]=a.useState("25"),[l,r]=a.useState(1),[s,c]=a.useState(u);s!==u&&(c(u),l!==1&&r(1));const C=a.useMemo(()=>Hu.map(g=>({...g,label:t("visits.showN",{n:g.value})})),[t]),d=a.useCallback(g=>{o(g),r(1)},[]),f=Math.max(1,Math.ceil(e.length/Number(n))),i=Math.min(l,f);return{pageRows:a.useMemo(()=>e.slice((i-1)*Number(n),i*Number(n)),[e,i,n]),pageSizeProps:{options:C,value:n,onChange:d},paginationProps:{page:i,total:f,onChange:r},setPage:r}}function cn(){const[e,u]=a.useState(null),t=a.useCallback(o=>{u(l=>l?.key===o?{key:o,asc:!l.asc}:{key:o,asc:!0})},[]),n=a.useCallback((o,l)=>({label:o,sortDir:e?.key===l?e.asc?"asc":"desc":null,onClick:()=>t(l)}),[e,t]);return{\uC815\uB82C:e,\uCE78:n}}function Cn(){const[e,u]=a.useState(!1),[t,n]=a.useState("\uC88C"),[o,l]=a.useState({\uC88C:null,\uC6B0:null}),[r,s]=a.useState({\uC88C:[],\uC6B0:[]}),[c,C]=a.useState(!1),[d,f]=a.useState("\uC88C"),i=a.useCallback(E=>{const w=E.direction;l(p=>({...p,[w]:E})),s(p=>({...p,[w]:[E,...p[w]]})),u(!1)},[]),g=a.useCallback(E=>{const w=E.direction;l(p=>({...p,[w]:E})),C(!1)},[]);return{showDevice:e,setShowDevice:u,deviceDirection:t,setDeviceDirection:n,devices:o,setDevices:l,deviceHistory:r,setDeviceHistory:s,showDeviceList:c,setShowDeviceList:C,listForSide:d,setListForSide:f,handleDeviceSubmit:i,handleSelectFromList:g}}const dn="__ihab_core_word_pool__";function $e(){return globalThis[dn]??null}function F(e,u=Math.random){const t=e.slice();for(let n=t.length-1;n>0;n--){const o=Math.floor(u()*(n+1));[t[n],t[o]]=[t[o],t[n]]}return t}function ae(e,u,t=Math.random){return!Array.isArray(e)||e.length===0||u<=0?[]:u>=e.length?F(e,t):F(e,t).slice(0,u)}const au={SAME_SOUND_PICK:{difficulty:!0,choseong:!0,group:"discrimination"},SAME_OR_DIFF:{difficulty:!0,choseong:!0,group:"discrimination"},HEAR_AND_PICK_SAME:{difficulty:!0,choseong:!0,group:"discrimination"},HEAR_AND_PICK_INCLUDED:{difficulty:!0,choseong:!0,group:"discrimination"},STARTS_WITH_SAME_SOUND:{difficulty:!1,choseong:!0,group:"discrimination"},LISTEN_AND_REMEMBER_ORDER:{difficulty:!1,choseong:!0,group:"attention"},MERGE_2_SYLLABLES:{difficulty:!1,choseong:!0,group:"synthesis"},MERGE_3_SYLLABLES:{difficulty:!1,choseong:!0,group:"synthesis"},MERGE_2_PHONEMES:{difficulty:!1,choseong:!0,group:"synthesis"},MERGE_3_PHONEMES:{difficulty:!1,choseong:!0,group:"synthesis"},DROP_1_FROM_2SYLL:{difficulty:!1,choseong:!0,group:"deletion"},DROP_1_FROM_3SYLL:{difficulty:!1,choseong:!0,group:"deletion"},DROP_PART_FROM_COMPOUND:{difficulty:!1,choseong:!0,group:"deletion"},DROP_FINAL_CONSONANT_FROM_1SYLL:{difficulty:!1,choseong:!0,group:"deletion"},REMOVE_CONSONANT_AND_IDENTIFY_PHONEME:{difficulty:!1,choseong:!0,group:"deletion"},CHANGE_1_SYLL_IN_2SYLL:{difficulty:!0,choseong:!0,group:"substitution"},CHANGE_1_SYLL_IN_3SYLL:{difficulty:!0,choseong:!0,group:"substitution"},CHANGE_1_PHONEME_IN_1SYLL:{difficulty:!1,choseong:!0,group:"substitution"},CHANGE_1_PHONEME_IN_2SYLL:{difficulty:!0,choseong:!0,group:"substitution"}},fn=q.indexOf("\u3147"),Uu={DROP_FINAL_CONSONANT_FROM_1SYLL:{syllables:1,syllable:e=>e.jong>0},REMOVE_CONSONANT_AND_IDENTIFY_PHONEME:{syllables:1,syllable:e=>e.jong===0&&e.cho!==fn},MERGE_2_SYLLABLES:{syllables:2,syllable:()=>!0},MERGE_3_SYLLABLES:{syllables:3,syllable:()=>!0},MERGE_2_PHONEMES:{syllables:1,syllable:e=>e.jong===0},MERGE_3_PHONEMES:{syllables:1,syllable:e=>e.jong>0}},gn={\u3131:"\u3131",\u3132:"\u3131",\u314B:"\u3131",\u3133:"\u3131",\u313A:"\u3131",\u3134:"\u3134",\u3135:"\u3134",\u3136:"\u3134",\u3137:"\u3137",\u3145:"\u3137",\u3146:"\u3137",\u3148:"\u3137",\u314A:"\u3137",\u314C:"\u3137",\u314E:"\u3137",\u3139:"\u3139",\u313C:"\u3139",\u313D:"\u3139",\u313E:"\u3139",\u3140:"\u3139",\u3141:"\u3141",\u313B:"\u3141",\u3142:"\u3142",\u314D:"\u3142",\u313F:"\u3142",\u3144:"\u3142",\u3147:"\u3147"},hn={\u314F:{nucleus:"\u314F"},\u3151:{glide:"j",nucleus:"\u314F"},\u3153:{nucleus:"\u3153"},\u3155:{glide:"j",nucleus:"\u3153"},\u3157:{nucleus:"\u3157"},\u315B:{glide:"j",nucleus:"\u3157"},\u315C:{nucleus:"\u315C"},\u3160:{glide:"j",nucleus:"\u315C"},\u3161:{nucleus:"\u3161"},\u3163:{nucleus:"\u3163"},\u3150:{nucleus:"\u3154/\u3150"},\u3152:{glide:"j",nucleus:"\u3154/\u3150"},\u3154:{nucleus:"\u3154/\u3150"},\u3156:{glide:"j",nucleus:"\u3154/\u3150"},\u3158:{glide:"w",nucleus:"\u314F"},\u3159:{glide:"w",nucleus:"\u3154/\u3150"},\u315A:{glide:"w",nucleus:"\u3154/\u3150"},\u315D:{glide:"w",nucleus:"\u3153"},\u315E:{glide:"w",nucleus:"\u3154/\u3150"},\u315F:{glide:"w",nucleus:"\u3163"},\u3162:{glide:"\u0270",nucleus:"\u3163"}};function Ku(e){return gn[e]??e}const iu={cho:q,jung:se,jong:Q},K=e=>Array.isArray(e)?e.length>0:!!e;function cu(e,u){if(e.length!==u.length)return!1;for(let t=0;t<e.length;t++){const n=e[t],o=u[t];if(!(!n||!o)&&(n.cho!==o.cho&&q[n.cho]==="\u3147"!=(q[o.cho]==="\u3147")||n.jong!==o.jong&&n.jong===0!=(o.jong===0)))return!0}return!1}function mn(e,u,t){const n=t.pronOf(e),o=t.decompOf,l=t.sameStructureOnly&&o?o(n):null,r=[];for(const s of u)s!==e&&(t.okSet&&!t.okSet.has(s)||t.pronOf(s)!==n&&(l&&o&&cu(l,o(t.pronOf(s)))||r.push(s)));return r}function Wu(e,u,t){const n=u?.[e];if(!n)return[];const o=t.kind?n[t.kind]??[]:[...n.cho??[],...n.jung??[],...n.jong??[]];return mn(e,o,t)}function Sn(e,u,t,n,o,l,r){const s=["cho","jung","jong"].filter(i=>K(e[i])),c={};for(const i of s){const g=e[i];c[i]=new Set(Array.isArray(g)?g:[g])}const C=o==="pron",d=new Map;for(const i of u){const g=t(l(i));if(g.some(h=>!h))continue;let E=g;if(!C&&(E=t(i),E.length!==g.length||E.some(h=>!h)))continue;const w=g.length,p=d.get(w);p?p.push({w:i,dPron:g,dPos:E}):d.set(w,[{w:i,dPron:g,dPos:E}])}const f=new Map;for(const[i,g]of d){const E=new Map,w=(p,h)=>{const S=p.dPos[h];return S!=null&&s.every(B=>c[B].has(iu[B][S[B]]))};for(const p of g){let h;if(r==="head")h=w(p,0)?0:-1;else if(r==="tail")h=w(p,i-1)?i-1:-1;else if(r==="mid"){h=-1;for(let B=1;B<i-1;B++)if(w(p,B)){h=B;break}}else h=p.dPos.findIndex(B=>B!=null&&s.every(A=>c[A].has(iu[A][B[A]])));if(h<0)continue;const S=E.get(h);S?S.push(p):E.set(h,[p])}for(const[p,h]of E){const S=new Set(s.map(_=>p+":"+_)),B=_=>{let b="";for(let I=0;I<i;I++){const R=_[I];for(const v of["cho","jung","jong"])b+=(S.has(I+":"+v)?"*":R[v])+"."}return b},A=new Map;for(const _ of g){const b=B(_.dPron),I=A.get(b);I?I.push(_):A.set(b,[_])}for(const _ of h){const b=A.get(B(_.dPron))??[],I=[];for(const R of b){if(R.w===_.w)continue;let v=!0;for(const j of s){const G=_.dPron[p][j],x=R.dPron[p][j];if(x===G){v=!1;break}if(C&&c[j].has(iu[j][x])){v=!1;break}}v&&(n&&cu(_.dPron,R.dPron)||I.push(R.w))}f.set(_.w,I)}}}return f}const En=e=>e==null?[]:Array.isArray(e)?e:[e];function pn(e){if([...e].length!==1)return"";const u=V(e);if(!u)return"";const t=Ku(Q[u.jong]),n=t===""?0:Q.indexOf(t);return de(u.cho,u.jung,n<0?0:n)}function qu(e,u){return u.get(e)||pn(e)||e}function Cu(e){return e?K(e.cho)?"cho":K(e.jung)?"jung":K(e.jong)?"jong":null:null}function ye(e,u){const t=(n,o)=>!K(n)||En(n).includes(o);return t(u.cho,q[e.cho])&&t(u.jung,se[e.jung])&&t(u.jong,Q[e.jong])}function _e(e,u,t){const n=[...e];if(t!=="pron")return n.map(l=>V(l));const o=[...u.get(e)||e];return o.length!==n.length?n.map(l=>V(l)):o.map(l=>V(l))}function Oe(e,u,t,n,o){const l=u==="cho"?q:u==="jung"?se:Q,r=e[u],s=[],c=new Set([qu(t,o)]),C=F(l.map((d,f)=>f).filter(d=>d!==r&&(u!=="cho"||l[d]!=="\u3147")&&(u!=="jong"||d!==0)));for(const d of C){if(s.length>=n)break;const f=u==="cho"?de(d,e.jung,e.jong):u==="jung"?de(e.cho,d,e.jong):de(e.cho,e.jung,d),i=qu(f,o);c.has(i)||(c.add(i),s.push(f))}return s}function yn(e,u,t,n,o,l=null){const r=[...e];if(r.length!==2)return null;const s=r.map(f=>V(f));if(s.some(f=>!f))return null;const c=_e(e,t,n);if(c.some(f=>!f))return null;const C=Cu(u);let d=C&&u?c.map((f,i)=>ye(f,u)?i:-1).filter(f=>f>=0):[0,1];if(l!=null&&(d=d.filter(f=>f!==l)),!d.length)return null;for(const f of F(d)){const i=r[f];if(!o.has(i))continue;const g=Oe(s[f],C??"cho",i,40,t),E=[];for(const w of g)if(w!==i&&o.has(w)&&!E.includes(w)&&E.push(w),E.length>=2)break;if(!(E.length<2))return{question:e,distractors:[i,...E]}}return null}function Bn(e,u,t,n,o,l=null){const r=[...e];if(r.length!==3)return null;const s=r.map(f=>V(f));if(s.some(f=>!f))return null;const c=_e(e,t,n);if(c.some(f=>!f))return null;const C=Cu(u),d=C&&u?c.map((f,i)=>ye(f,u)?i:-1).filter(f=>f>=0):[0,1,2];if(!d.length)return null;for(const f of F(d))for(const i of F([0,1,2].filter(g=>g!==f&&(l==null||g===l)))){const g=[0,1,2].filter(S=>S!==i),E=g.map(S=>r[S]).join("");if(!o.has(E))continue;const w=g.indexOf(f),p=Oe(s[f],C??"cho",r[f],40,t),h=[];for(const S of p){const B=g.map(_=>r[_]);B[w]=S;const A=B.join("");if(A!==E&&o.has(A)&&!h.includes(A)&&h.push(A),h.length>=2)break}if(!(h.length<2))return{question:e,distractors:[E,...h]}}return null}function wn(e,u,t,n,o,l=null){const r=[...e],s=r.length;if(s<2)return null;const c=[];for(let d=1;d<=s-1;d++)c.push({remain:r.slice(0,d).join(""),dropped:r.slice(d).join(""),droppedEnd:1}),c.push({remain:r.slice(s-d).join(""),dropped:r.slice(0,s-d).join(""),droppedEnd:0});const C=Cu(u);for(const{remain:d,dropped:f,droppedEnd:i}of F(c)){if(l!=null&&i!==l||d===e||!o.has(d)||!o.has(f))continue;const g=[...d],E=g.map(h=>V(h));if(E.some(h=>!h))continue;const w=_e(d,t,n);if(w.some(h=>!h))continue;const p=C&&u?w.map((h,S)=>ye(h,u)?S:-1).filter(h=>h>=0):g.map((h,S)=>S);if(p.length)for(const h of F(p)){const S=Oe(E[h],C??"cho",g[h],40,t),B=[];for(const A of S){const _=[...g];_[h]=A;const b=_.join("");if(b!==d&&o.has(b)&&!B.includes(b)&&B.push(b),B.length>=2)break}if(B.length>=2)return{question:e,distractors:[d,...B]}}}return null}function bn(e,u,t,n,o,l=null){if([...e].length!==1)return null;const r=V(t.get(e)||e);if(!r||r.jong===0)return null;const s=de(r.cho,r.jung,0),c=Oe({cho:r.cho,jung:r.jung,jong:0},"cho",s,2,t);return c.length<2?null:{question:e,distractors:[s,...c]}}const du=q.indexOf("\u3147");function An(e,u,t,n,o,l=null){if([...e].length!==1)return null;const r=V(t.get(e)||e);if(!r||r.jong!==0||r.cho===du)return null;const s=de(du,r.jung,0),c=Oe({cho:du,jung:r.jung,jong:0},"jung",s,2,t);return c.length<2?null:{question:e,distractors:[s,...c]}}function Dn(e){const u=new Map;for(const t of e){const n=[...t],o=n.length;if(!(o<2||o>3))for(let l=0;l<o;l++){let r=o+"|"+l+"|";for(let c=0;c<o;c++)r+=c===l?"*":n[c];const s=u.get(r);s?s.push(t):u.set(r,[t])}}return u}function _n(e,u,t,n,o,l=null,r=null,s=2){const c=[...e],C=c.length;if(C<2||C>3)return null;const d=c.map(S=>V(S));if(d.some(S=>!S))return null;const f=_e(e,t,n);if(f.some(S=>!S))return null;const i=S=>t.get(S)??S,g=i(e),E=!!u&&(K(u.cho)||K(u.jung)||K(u.jong)),w=!!r&&(K(r.cho)||K(r.jung)||K(r.jong)),p=S=>{let B=C+"|"+S+"|";for(let A=0;A<C;A++)B+=A===S?"*":c[A];return B};let h;if(l!=null){if(l>=C||E&&!ye(f[l],u))return null;h=[l]}else E?h=f.map((S,B)=>ye(S,u)?B:-1).filter(S=>S>=0):h=Array.from({length:C},(S,B)=>B);for(const S of F(h)){const B=o.get(p(S))??[],A=[],_=[];for(const j of B){if(j===e)continue;const G=[...j].map(P=>V(P)),x=d[S],k=G[S];if(!x||!k)continue;let T=0;if(x.cho!==k.cho&&T++,x.jung!==k.jung&&T++,x.jong!==k.jong&&T++,!(T<s||i(j)===g))if(w){const P=_e(j,t,n)[S];P&&ye(P,r)?A.push(j):_.push(j)}else A.push(j)}if(!A.length)continue;const b=F(A)[0],I=[],R=new Set([g,i(b)]),v=w?_:A.filter(j=>j!==b);for(const j of F(v)){const G=i(j);if(!R.has(G)&&(R.add(G),I.push(j),I.length>=2))break}if(!w&&I.length<2)for(const j of F(B)){if(j===e||j===b)continue;const G=i(j);if(!R.has(G)&&(R.add(G),I.push(j),I.length>=2))break}if(!(I.length<2))return{question:e,distractors:[b,...I]}}return null}let He=null,zu=null,Ju=null;function On(){const e=$e();if(e&&e.entries.length>0){const u=Ae();if(He&&zu===e&&Ju===u)return He;const t=new Set,n=[];for(const o of e.entries)!o.word||t.has(o.word)||(t.add(o.word),n.push({w:o.word,s:o.syllables,p:u?.[o.word]?[...u[o.word].cho??[],...u[o.word].jung??[],...u[o.word].jong??[]]:[],pron:o.pronunciation||o.word,grade:o.grade}));return He=n,zu=e,Ju=u,He}return[]}const ue=new Proxy([],{get(e,u){const t=On(),n=t[u];return typeof n=="function"?n.bind(t):n}});function Ue(e){return e.length?e[Math.floor(Math.random()*e.length)]:void 0}function te(e,u){if(u>=e.length)return F(e);if(u===0)return[];const t=e.slice();for(let n=0;n<u;n++){const o=n+Math.floor(Math.random()*(t.length-n)),l=t[n];t[n]=t[o],t[o]=l}return t.slice(0,u)}let fu=null,Zu=null;function fe(){const e=$e();if(fu&&Zu===e)return fu;const u=new Map;for(const t of ue)t.w&&u.set(t.w,t.pron);return fu=u,Zu=e,u}function J(e){return fe().get(e)||e}function gu(e,u,t=new Set){const n=[];for(const o of F(e)){if(n.length>=u)break;const l=J(o);t.has(l)||(t.add(l),n.push(o))}return n}let Nn=0;function z(e){return`${e}-rt-${++Nn}`}function Ne(e){const u=vu();if(!u||u.total===0){const n=new Set;for(const o of e)n.add(o);return n}const t=new Set;for(const n of e)Qt(n)===!0&&t.add(n);return t}const Ke=new Map;let Qu=null,Xu=null;function Te(e){return e==null?"":Array.isArray(e)?e.slice().sort().join(","):e}function et(e){const u=Te(e.choseong),t=e.composition,n=t?.syllable==null?"":Array.isArray(t.syllable)?t.syllable.slice().sort().join(","):String(t.syllable),o=t?`${Te(t.cho)}/${Te(t.jung)}/${Te(t.jong)}/${t.jongNone?"N":""}/${n}`:"",l=Te(e.grade);return`${e.difficulty??""}|${u}|${o}|${e.excludeNoImage?"1":"0"}|${e.count??""}|x${e.contrastCount??1}|${e.fullCount?"F":""}|s${e.sameStructureOnly===!1?"0":"1"}|v${e.phonemeView==="pron"?"p":"c"}|g${l}|t${e.targetSyllable??""}|c${e.choicesPerItem??""}`}async function Z(e){const u=$e(),t=Ae();(u!==Qu||t!==Xu)&&(Ke.clear(),Qu=u,Xu=t);const n=et(e);return Ke.has(n)||Ke.set(n,jn(e)),Ke.get(n)}function Tn(e){if(!e)return null;const u=r=>r==null?null:Array.isArray(r)?r.length?r:null:[r],t=u(e.cho),n=u(e.jung),o=!!e.jongNone,l=o?null:u(e.jong);return t||n||l||o?o&&!t&&!n&&!l?r=>$t(r):r=>Ut(r,{cho:t,jung:n,jong:l,jongNone:o}):null}async function jn(e){const{difficulty:u=null,choseong:t=null,composition:n=null,targetSyllable:o=null,excludeNoImage:l=!1}=e,r=e.grade&&e.grade.length>0?new Set(e.grade):null,s=e.sameStructureOnly??!0,c=e.phonemeView==="pron"?"pron":"char",C=Math.max(1,e.contrastCount??1),d=u==="cho"||u==="jung"||u==="jong",f=d&&C>=2,i=u==="count",g=t?new Set(Array.isArray(t)?t:[t]):null,E=n?.syllable!=null?new Set(Array.isArray(n.syllable)?n.syllable:[n.syllable]):null,w=n?[Tn(n),E?y=>E.has(Ge(y)):null].filter(y=>y!=null):[],p=u==="random"||u===null,h=p||i,S=p||f||i;let B=ue.filter(y=>!y.w||r&&(!y.grade||!r.has(y.grade))?!1:S?!0:Array.isArray(y.p)&&y.p.length>0);g&&(B=B.filter(y=>{for(const D of g)if(Yt(y.w,D))return!0;return!1})),w.length>0&&(B=B.filter(y=>{const D=c==="pron"?J(y.w):y.w;return w.every(H=>H(D))})),o&&(B=B.filter(y=>y.w[0]===o));let A;if(l){const y=new Set;for(const D of B)if(y.add(D.w),Array.isArray(D.p))for(const H of D.p)y.add(H);if(h)for(const D of ue)D.w&&y.add(D.w);A=Ne(y)}else{const y=new Set;for(const D of B)if(y.add(D.w),Array.isArray(D.p))for(const H of D.p)y.add(H);if(h)for(const D of ue)D.w&&y.add(D.w);A=y}let _=null;if(f){const y=new Set;for(const D of ue)D.w&&y.add(D.w);_=l?Ne(y):y}const b=B.filter(y=>A.has(y.w)),I=600,R=Array.from(A),v=R.length>I?te(R,I):R,j=i&&n!=null&&(K(n.cho)||K(n.jung)||K(n.jong)),G=2500,x=new Map;if(i&&!j&&C>=2){for(const y of R){const D=Ge(y),H=x.get(D);H?H.push(y):x.set(D,[y])}for(const[y,D]of x)D.length>G&&x.set(y,te(D,G))}const k=Vt(),T=j?Sn(n,R,k,s,c,J):null,P=500,$=1500,X=e.fullCount?b:u==="random"?b.length>P?te(b,P):b:b.length>$?te(b,$):b,le=Ae(),re=[];for(const y of X){let D;const H=J(y.w);if(f)D=Wt(y.w,u,C,_,24).filter(Y=>J(Y)!==H);else if(i)j?D=(T.get(y.w)??[]).filter(Y=>J(Y)!==H):C<=1?D=Wu(y.w,le,{okSet:A,pronOf:J,decompOf:k,sameStructureOnly:!1}):D=(x.get(Ge(y.w))??[]).filter(Y=>{if(Y===y.w||J(Y)===H)return!1;const ee=qt(y.w,Y);return C>=5?ee>=5:ee===C});else if(p)D=v.filter(Y=>Y!==y.w&&Y.length===y.w.length&&J(Y)!==H);else{const Y=u;D=Wu(y.w,le,{kind:Y,okSet:A,pronOf:J,decompOf:k,sameStructureOnly:!1}),D.length===0&&(D=(v.length>30?te(v,30):v).filter(ee=>ee!==y.w&&Gt(y.w,ee)===u&&J(ee)!==H))}if(s&&D.length>0&&(d||i&&!j)){const Y=k(J(y.w));D=D.filter(ee=>!cu(Y,k(J(ee))))}D.length!==0&&re.push({word:y,usable:D})}return re}async function ut(e,u){const{choicesPerItem:t=3,count:n=10}=u,o=t-1,l=(await Z(u)).filter(s=>s.usable.length>=o),r=[];for(const s of F(l)){if(r.length>=n)break;const c=gu(s.usable,o);if(c.length<o)continue;const C=F([s.word.w,...c]);r.push({id:z(e+"-item"),index:r.length+1,word:s.word.w,syllables:s.word.s,choices:C,answerIndex:C.indexOf(s.word.w)})}return r}async function In(e){const{choicesPerItem:u=3,count:t=10}=e,n=u-1,o=await Z({...e,difficulty:null});if(o.length<u)return[];const l=[],r=F([...o]);for(const s of r){if(l.length>=t)break;const c=s.word.w,C=[...s.word.pron||c],d=Ue(C);if(!d)continue;const f=o.filter(E=>E.word.w!==c&&E.word.s===s.word.s&&!(E.word.pron||E.word.w).includes(d)&&E.word.pron!==s.word.pron);if(f.length<n)continue;const i=gu(f.map(E=>E.word.w),n);if(i.length<n)continue;const g=F([c,...i]);l.push({id:z("HPI-item"),index:l.length+1,targetSyllable:d,word:c,choices:g,answerIndex:g.indexOf(c)})}return l}async function Ln(e){const{count:u=10}=e,t=(await Z(e)).filter(n=>n.usable.length>=1);return Array.from({length:u},(n,o)=>{const l=Ue(t);if(!l)return null;const r=o%2===0;let s;if(r)s=[l.word.w,l.word.w];else{const c=Ue(l.usable);s=Math.random()<.5?[l.word.w,c]:[c,l.word.w]}return{id:z("SOD-item"),index:o+1,word:l.word.w,pair:s,same:r}}).filter(n=>!!n)}async function Rn(e){const{choicesPerItem:u=3,count:t=10}=e,n=u-1,o=await Z({...e,difficulty:null});if(o.length<u+1)return[];const l=o.map(i=>i.word.w),r=new Map(o.map(i=>[i.word.w,i.word.pron])),s=i=>(r.get(i)||i)[0]??"",c={};for(const i of o){const g=s(i.word.w);g&&(c[g]||(c[g]=[]),c[g].push(i.word.w))}const C=Object.entries(c).filter(([,i])=>i.length>=2).map(([i])=>i);if(C.length===0)return[];const d=[],f=F([...C]);for(let i=0;d.length<t&&i<t*4;i++){const g=f[i%f.length],E=c[g];if(E.length<2)continue;const w=F([...E]),p=w[0],h=w[1];if(!p||!h||p===h||(r.get(p)||p)===(r.get(h)||h))continue;const S=r.get(h)||h,B=l.filter(b=>s(b)!==g&&b!==p&&b!==h&&b.length===h.length&&(r.get(b)||b)!==S);if(B.length<n)continue;const A=gu(B,n);if(A.length<n)continue;const _=F([h,...A]);d.push({id:z("SWS-item"),index:d.length+1,sourceWord:p,targetSyllable:g,word:h,choices:_,answerIndex:_.indexOf(h)})}return d}function tt(e,u,t){return te(e,u).map((n,o)=>{const l=Ue(n.usable)??"",r=[...n.word.w],s=[...l],c=r.findIndex((d,f)=>d!==s[f]),C=F(n.usable.filter(d=>d&&d!==l)).slice(0,2);return{id:z(t),index:o+1,word:n.word.w,original:n.word.w,changed:l,changedFrom:c>=0?r[c]:"",changedTo:c>=0?s[c]:"",distractors:C}})}async function nt(e,u,t){const{count:n=10}=u,o=fe(),l=ue.filter(g=>g.w&&g.s===e),r=u.excludeNoImage?Ne(l.map(g=>g.w)):null,s=r?l.filter(g=>r.has(g.w)):l,c=new Set(s.map(g=>g.w)),C=Dn(c),d=u.phonemeView??"char",f=u.composition??null,i=[];for(const g of F(s)){if(i.length>=n)break;const E=_n(g.w,f,o,d,C,null,null);if(!E)continue;const w=E.distractors[0],p=[...g.w],h=[...w],S=p.findIndex((B,A)=>B!==h[A]);i.push({id:z(t),index:i.length+1,word:g.w,original:g.w,changed:w,changedFrom:S>=0?p[S]:"",changedTo:S>=0?h[S]:"",distractors:E.distractors.slice(1)})}return i}async function Mn(e){return nt(2,e,"CS2-item")}async function xn(e){return nt(3,e,"CS3-item")}async function Pn(e){const u=(await Z({...e,difficulty:"count",contrastCount:1})).filter(t=>t.word.s===1&&t.usable.length>=1);return tt(u,e.count??10,"CP1-item")}async function Fn(e){const u=e.difficulty&&e.difficulty!=="random"?e.difficulty:"count",t=(await Z({...e,difficulty:u,contrastCount:1})).filter(n=>n.word.s===2&&n.usable.length>=1);return tt(t,e.count??10,"CP2-item")}async function kn(e){const{count:u=10}=e,t=(await Z({...e})).filter(n=>n.word.s===2);return te(t,u).map((n,o)=>({id:z("M2S-item"),index:o+1,word:n.word.w,answer:n.word.w,parts:[...n.word.w]}))}async function vn(e){const{count:u=10}=e,t=(await Z({...e})).filter(n=>n.word.s===3);return te(t,u).map((n,o)=>({id:z("M3S-item"),index:o+1,word:n.word.w,answer:n.word.w,parts:[...n.word.w]}))}async function Vn(e){const{count:u=10}=e,t=(await Z({...e})).filter(s=>s.word.s===2),n=fe(),o=new Set(ue.map(s=>s.w)),l=e.phonemeView??"char",r=[];for(const s of F(t)){if(r.length>=u)break;const c=yn(s.word.w,e.composition??null,n,l,o);if(!c)continue;const[C,...d]=c.distractors,f=[...s.word.w],i=f[0]===C?f[1]:f[0];r.push({id:z("D2-item"),index:r.length+1,original:s.word.w,word:s.word.w,dropped:i,missingResult:C,distractors:d})}return r}async function Gn(e){const{count:u=10}=e,t=(await Z({...e})).filter(s=>s.word.s===3),n=fe(),o=new Set(ue.map(s=>s.w)),l=e.phonemeView??"char",r=[];for(const s of F(t)){if(r.length>=u)break;const c=Bn(s.word.w,e.composition??null,n,l,o);if(!c)continue;const[C,...d]=c.distractors,f=[...s.word.w];let i="";for(let g=0;g<f.length;g++)if(f.filter((E,w)=>w!==g).join("")===C){i=f[g];break}r.push({id:z("D3-item"),index:r.length+1,original:s.word.w,word:s.word.w,dropped:i,missingResult:C,distractors:d})}return r}async function Yn(e){const{count:u=10}=e,t=(await Z({...e})).filter(s=>s.word.s>=2),n=fe(),o=new Set(ue.map(s=>s.w)),l=e.phonemeView??"char",r=[];for(const s of F(t)){if(r.length>=u)break;const c=wn(s.word.w,e.composition??null,n,l,o);if(!c)continue;const[C,...d]=c.distractors,f=s.word.w,i=f.startsWith(C)?f.slice(C.length):f.endsWith(C)?f.slice(0,f.length-C.length):"";r.push({id:z("DPC-item"),index:r.length+1,original:f,word:f,dropped:i,missingResult:C,distractors:d})}return r}async function $n(e){const{count:u=10}=e,t=(await Z({...e})).map(n=>n.word.w);return t.length<3?[]:Array.from({length:u},(n,o)=>{const l=te(t,3);return{id:z("LRO-item"),index:o+1,sequence:l,choices:F(l)}})}function We(e,u,t){const n=ue.filter(r=>r.w&&r.s===e),o=u?Ne(n.map(r=>r.w)):null,l=[];for(const r of n)if(!(o&&!o.has(r.w))){if(t){const s=V(r.w);if(!s||!t(s))continue}l.push(r)}return l}function Hn(e){const u=We(1,e.excludeNoImage??!1,t=>t.jong===0);return te(u,e.count??10).map((t,n)=>{const o=V(t.w);return{id:z("M2P-item"),index:n+1,parts:[q[o.cho],se[o.jung]],answer:t.w,word:t.w}})}function Un(e){const u=We(1,e.excludeNoImage??!1,t=>t.jong>0&&!we[t.jong]);return te(u,e.count??10).map((t,n)=>{const o=V(t.w);return{id:z("M3P-item"),index:n+1,parts:[q[o.cho],se[o.jung],Q[o.jong]],answer:t.w,word:t.w}})}function Kn(e){const u=Uu.DROP_FINAL_CONSONANT_FROM_1SYLL,t=We(u.syllables,e.excludeNoImage??!1,u.syllable),n=fe(),o=[];for(const l of F(t)){if(o.length>=(e.count??10))break;const r=bn(l.w,null,n);if(!r)continue;const[s,...c]=r.distractors;o.push({id:z("DFC-item"),index:o.length+1,original:l.w,word:l.w,result:s,distractors:c})}return o}function Wn(e){const u=Uu.REMOVE_CONSONANT_AND_IDENTIFY_PHONEME,t=We(u.syllables,e.excludeNoImage??!1,u.syllable),n=fe(),o=[];for(const l of F(t)){if(o.length>=(e.count??10))break;const r=An(l.w,null,n);if(!r)continue;const s=V(n.get(l.w)||l.w);if(!s)continue;const[c,...C]=r.distractors;o.push({id:z("RCP-item"),index:o.length+1,base:l.w,word:l.w,missingConsonant:q[s.cho],remaining:c,distractors:C})}return o}const qe=new Map;let ot=null,lt=null;async function rt(e,u={}){const t=$e(),n=Ae();(t!==ot||n!==lt)&&(qe.clear(),ot=t,lt=n);const o=`${e}:${et(u)}`;if(qe.has(o))return qe.get(o);const l=await zn(e,u);return qe.set(o,l),l}const qn={SAME_SOUND_PICK:e=>ut("SSP",e),HEAR_AND_PICK_SAME:e=>ut("HPS",e),HEAR_AND_PICK_INCLUDED:e=>In(e),SAME_OR_DIFF:e=>Ln(e),STARTS_WITH_SAME_SOUND:e=>Rn(e),LISTEN_AND_REMEMBER_ORDER:e=>$n(e),MERGE_2_SYLLABLES:e=>kn(e),MERGE_3_SYLLABLES:e=>vn(e),MERGE_2_PHONEMES:e=>Hn(e),MERGE_3_PHONEMES:e=>Un(e),DROP_1_FROM_2SYLL:e=>Vn(e),DROP_1_FROM_3SYLL:e=>Gn(e),DROP_PART_FROM_COMPOUND:e=>Yn(e),DROP_FINAL_CONSONANT_FROM_1SYLL:e=>Kn(e),REMOVE_CONSONANT_AND_IDENTIFY_PHONEME:e=>Wn(e),CHANGE_1_SYLL_IN_2SYLL:e=>Mn(e),CHANGE_1_SYLL_IN_3SYLL:e=>xn(e),CHANGE_1_PHONEME_IN_1SYLL:e=>Pn(e),CHANGE_1_PHONEME_IN_2SYLL:e=>Fn(e)};async function zn(e,u={}){const t=qn[e];return t?await t(u):[]}async function Jn(e){const u=[null,"count"],t=Object.keys(au);let n=0;for(const o of u)for(const l of t){const r=au[l];rt(l,{difficulty:r.difficulty?o:null,choseong:null,count:10,excludeNoImage:e}).catch(()=>{}),++n%6===0&&await new Promise(s=>setTimeout(s,0))}}async function Zn(e){return(await Z({...e,fullCount:!0})).length}async function Qn(e={}){const u=[];for(const s of ue)s.w&&u.push(s.w);const t=e.excludeNoImage?Ne(u):u,n=new Set,o=new Set,l=new Set,r=new Set;for(const s of t){r.add(Ge(s));for(const c of s){const C=V(c);if(C&&(q[C.cho]!=="\u3147"&&n.add(q[C.cho]),o.add(se[C.jung]),C.jong>0)){l.add(Q[C.jong]);const d=we[C.jong];d&&d.forEach(f=>l.add(f))}}}return{cho:n,jung:o,jong:l,syllable:r}}const ge="\uC804\uCCB4";function st(){const{t:e}=Ee.useTranslation();return a.useMemo(()=>({difficulty:e("wordSearch.filter.difficulty","\uB4F1\uAE09"),syllables:e("wordSearch.filter.syllables","\uC74C\uC808 \uC218"),syllable5plus:e("wordSearch.filter.syllable5plus","5\uC74C\uC808 \uC774\uC0C1"),partOfSpeech:e("wordSearch.filter.partOfSpeech","\uD488\uC0AC"),wordType:e("wordSearch.filter.wordType","\uC720\uD615"),posMap:{[e("wordSearch.filter.pos.noun","\uCCB4\uC5B8(\uBA85\uC0AC, \uC218\uC0AC)")]:["\uBA85","\uC218"],[e("wordSearch.filter.pos.verb","\uC6A9\uC5B8(\uB3D9\uC0AC, \uD615\uC6A9\uC0AC)")]:["\uB3D9","\uD615"],[e("wordSearch.filter.pos.modifier","\uC218\uC2DD\uC5B8(\uBD80\uC0AC, \uAD00\uD615\uC0AC)")]:["\uBD80","\uAD00"]},typeMap:{[e("wordSearch.filter.type.native","\uACE0\uC720\uC5B4")]:"\uACE0\uC720",[e("wordSearch.filter.type.sino","\uD55C\uC790\uC5B4")]:"\uD55C\uC790",[e("wordSearch.filter.type.foreign","\uC678\uB798\uC5B4")]:"\uC678\uB798",[e("wordSearch.filter.type.mixed","\uD63C\uC885\uC5B4")]:"\uD63C\uC885"}}),[e])}function at(e,u,t){return{label:u.difficulty,items:[1,2,3,4].map(n=>e("wordSearch.filter.grade",{n})),multiple:!0,allOption:!0,allLabel:t?.allLabel,labelAction:t?.labelAction,labelInfo:t?.labelInfo}}function it(e){return{label:e.partOfSpeech,items:Object.keys(e.posMap),multiple:!0,allOption:!0}}function ct(e){return{label:e.wordType,items:Object.keys(e.typeMap),multiple:!0,allOption:!0}}function Xn(e,u){return{label:u.syllables,items:[e("wordSearch.filter.syllable",{n:1}),e("wordSearch.filter.syllable",{n:2}),e("wordSearch.filter.syllable",{n:3}),e("wordSearch.filter.syllable",{n:4}),u.syllable5plus],multiple:!0,allOption:!0}}function eo(e,u){const t=[e("wordPairs.filter.onlyHasImage","\uC774\uBBF8\uC9C0 \uC788\uB294 \uB2E8\uC5B4\uB9CC")];return u?.includeStructure&&t.push(e("wordPairs.filter.onlySameStructure","\uC74C\uC18C \uAD6C\uC870 \uAC19\uC740 \uB2E8\uC5B4\uB9CC")),{label:e("wordPairs.filter.selectLabel","\uC120\uD0DD"),items:t,multiple:!0,labelAction:u?.labelAction,labelInfo:u?.labelInfo}}function uo(e,u){const{label:t,headValue:n,midValue:o,tailValue:l,includeMid:r=!0,headDisabled:s,midDisabled:c,tailDisabled:C,allOptionDisabled:d,groupLabel:f,labelAction:i}=u;return{label:t,...f?{groupLabel:f}:{},...i?{labelAction:i}:{},allOption:!0,allLabel:e("wordSearch.filter.positionAny",{defaultValue:"\uBB34\uAD00"}),...d?{allOptionDisabled:d}:{},items:[{value:n,displayLabel:e("wordSearch.filter.positionHead",{defaultValue:"\uC5B4\uB450"}),disabled:s},...r?[{value:o,displayLabel:e("wordSearch.filter.positionMid",{defaultValue:"\uC5B4\uC911"}),disabled:c}]:[],{value:l,displayLabel:e("wordSearch.filter.positionTail",{defaultValue:"\uC5B4\uB9D0"}),disabled:C}]}}function to(e,u,t){if(u===ge){const{[t]:l,...r}=e;return r}const n=e[t]??[],o=n.includes(u)?n.filter(l=>l!==u):[...n,u];if(o.length===0){const{[t]:l,...r}=e;return r}return{...e,[t]:o}}Object.fromEntries(Object.entries(hn).map(([e,{nucleus:u}])=>[e,u]));const no={\uACE0\uC720\uC5B4:"\uACE0\uC720",\uD55C\uC790\uC5B4:"\uD55C\uC790",\uC678\uB798\uC5B4:"\uC678\uB798",\uD63C\uC885\uC5B4:"\uD63C\uC885"},oo={"\uCCB4\uC5B8(\uBA85\uC0AC,\uC218\uC0AC)":["\uBA85","\uC218"],"\uC6A9\uC5B8(\uB3D9\uC0AC,\uD615\uC6A9\uC0AC)":["\uB3D9","\uD615"],"\uC218\uC2DD\uC5B8(\uBD80\uC0AC,\uAD00\uD615\uC0AC)":["\uBD80","\uAD00"]},lo={difficulty:"\uB09C\uC774\uB3C4 \uB4F1\uAE09",syllables:"\uC74C\uC808 \uC218",syllable5plus:"5\uC74C\uC808 \uC774\uC0C1",partOfSpeech:"\uD488\uC0AC",wordType:"\uC720\uD615",posMap:oo,typeMap:no};function ro(e,u,t=lo){const n=u[t.difficulty];if(n?.length&&!n.some(s=>e.grade===s.replace(/\D/g,"")))return!1;const o=u[t.syllables];if(o?.length){const s=e.syllables??0;if(!o.some(c=>c===t.syllable5plus?s>=5:s===parseInt(c)))return!1}const l=u[t.partOfSpeech];if(l?.length&&!l.flatMap(s=>t.posMap[s]??[s]).some(s=>(e.pos??"").includes(s)))return!1;const r=u[t.wordType];return!(r?.length&&!r.some(s=>e.wordType===t.typeMap[s]))}const ie=(e,u)=>u.map(t=>({jamos:[t],tooltip:e})),W=(e,u)=>({jamos:[...e],tooltip:u}),hu={cho:[ie("\uC591\uC21C\uC74C",["\u3142","\u3143","\u314D","\u3141"]),ie("\uCE58\uC870\uC74C",["\u3137","\u3138","\u314C","\u3134","\u3139"]),ie("\uCE58\uC870\uC74C",["\u3145","\u3146"]),ie("\uACBD\uAD6C\uAC1C\uC74C",["\u3148","\u3149","\u314A"]),ie("\uC5F0\uAD6C\uAC1C\uC74C",["\u3131","\u3132","\u314B"]),ie("\uC131\uBB38\uC74C",["\u314E"])],jung:[[W("\u3163","\uC804\uC124 \uACE0\uBAA8\uC74C"),W("\u315F","\uC804\uC124 \uACE0\uBAA8\uC74C \xB7 w\uD65C\uC74C"),W("\u3162","\uC804\uC124 \uACE0\uBAA8\uC74C \xB7 \u0270\uD65C\uC74C")],[W("\u3161","\uD6C4\uC124 \uACE0\uBAA8\uC74C \uD3C9\uC21C")],[W("\u315C","\uD6C4\uC124 \uACE0\uBAA8\uC74C \uC6D0\uC21C"),W("\u3160","\uD6C4\uC124 \uACE0\uBAA8\uC74C \uC6D0\uC21C \xB7 j\uD65C\uC74C")],[W("\u3154\u3150","\uC804\uC124 \uC911\uBAA8\uC74C"),W("\u3156\u3152","\uC804\uC124 \uC911\uBAA8\uC74C \xB7 j\uD65C\uC74C"),W("\u3159\u315A\u315E","\uC804\uC124 \uC911\uBAA8\uC74C \xB7 w\uD65C\uC74C")],[W("\u3153","\uD6C4\uC124 \uC911\uBAA8\uC74C \uD3C9\uC21C"),W("\u3155","\uD6C4\uC124 \uC911\uBAA8\uC74C \uD3C9\uC21C \xB7 j\uD65C\uC74C"),W("\u315D","\uD6C4\uC124 \uC911\uBAA8\uC74C \uD3C9\uC21C \xB7 w\uD65C\uC74C")],[W("\u3157","\uD6C4\uC124 \uC911\uBAA8\uC74C \uC6D0\uC21C"),W("\u315B","\uD6C4\uC124 \uC911\uBAA8\uC74C \uC6D0\uC21C \xB7 j\uD65C\uC74C")],[W("\u314F","\uC800\uBAA8\uC74C"),W("\u3151","\uC800\uBAA8\uC74C \xB7 j\uD65C\uC74C"),W("\u3158","\uC800\uBAA8\uC74C \xB7 w\uD65C\uC74C")]],jong:[ie("\uC591\uC21C\uC74C",["\u3142","\u3141"]),ie("\uCE58\uC870\uC74C",["\u3137","\u3134","\u3139"]),ie("\uC5F0\uAD6C\uAC1C\uC74C",["\u3131","\u3147"])]},so=[...q],ao=[...se],io=Q.filter(e=>e!==""),ce=e=>e===ne?[]:Array.from(e),ne="__NO_CODA__",Ct=[1,2,3,4],oe=5,co=12,dt="SYL_",mu=e=>`${dt}${e}`,Co=e=>Number(e.slice(dt.length));function Su(e){return e>=oe?Array.from({length:co-oe+1},(u,t)=>oe+t):[e]}const ft={cho:so,jung:ao,jong:io},Eu=e=>e.map(u=>u.map(({jamos:t,tooltip:n})=>({v:t.join(""),tooltip:n}))),pu={cho:Eu(hu.cho),jung:Eu(hu.jung),jong:Eu(hu.jong)},gt={};pu.jung.flat().forEach(({v:e})=>{for(const u of ce(e))gt[u]=e});const fo=new Set(pu.cho.flat().map(e=>e.v));function ht(e,u){return e==="cho"?fo.has(u)?u:null:e==="jung"?gt[u]??u:Ku(u)}function mt(e,u,t){if(e==="jung"){const n=ce(u);return t&&n.includes(t)?t:n[0]??u}return u}function St(e,u,t){const n=(o,l)=>l?o==="jong"&&l===ne?ne:u==="pron"?ht(o,l):mt(o,l,o==="jung"?t:null):null;return{...e,cho:n("cho",e.cho),jung:n("jung",e.jung),jong:n("jong",e.jong)}}const yu={cho:null,jung:null,jong:null,syllable:null},go="wt_filter",Et=e=>`wt_filter_${e}`;function pt(e){try{const u=localStorage.getItem(Et(e))??localStorage.getItem(go);if(u)return JSON.parse(u)}catch{}return null}function ho(e){const u=e;return u?.composition?{cho:u.composition.cho??null,jung:u.composition.jung??null,jong:u.composition.jong??null,syllable:u.composition.syllable??null}:u?.choseong?{...yu,cho:u.choseong}:yu}function mo(e,u,t){const{t:n,i18n:o}=Ee.useTranslation(),[l]=a.useState(()=>t?.resetOnMount?null:pt(e)),r=l?.contrastCount,s=typeof r=="number"&&Number.isFinite(r)?r:1,[c,C]=a.useState(Math.min(5,Math.max(1,s))),[d,f]=a.useState(l?.phonemeView==="pron"?"pron":l?.phonemeView==="direct"?"direct":"char"),[i,g]=a.useState(()=>ho(l)),E=a.useCallback(()=>u.requireSyllable?{cho:"\u3131",jung:"\u314F",jong:ne,syllable:u.fixedSyllable??null}:{cho:null,jung:null,jong:u.fixedNoCoda?ne:null,syllable:u.fixedSyllable??null},[u.requireSyllable,u.fixedSyllable,u.fixedNoCoda]);a.useEffect(()=>{!u.requireSyllable&&u.fixedSyllable==null&&!u.fixedNoCoda||g(m=>m.cho||m.jung||m.syllable!=null||m.jong?m:E())},[]);const w=a.useMemo(()=>K(i.cho)||K(i.jung)||K(i.jong)?"count":"random",[i.cho,i.jung,i.jong]),p=a.useRef(d==="char"?i.jung:null);a.useEffect(()=>{d==="char"&&(p.current=i.jung)},[d,i.jung]);const[h,S]=a.useState(t?.resetOnMount?!!t?.defaultImageOnly:l?.excludeNoImage??!0),[B,A]=a.useState(t?.resetOnMount?!1:l?.sameStructureOnly??!0),[_,b]=a.useState(Array.isArray(l?.gradeFilter)?l.gradeFilter:[]),[I,R]=a.useState(Array.isArray(l?.posFilter)?l.posFilter:[]),[v,j]=a.useState(Array.isArray(l?.wordTypeFilter)?l.wordTypeFilter:[]),G=a.useRef(t?.resetKey);a.useEffect(()=>{G.current!==t?.resetKey&&(G.current=t?.resetKey,g(E()),S(!1),A(!1),b([]),R([]),j([]),C(1))},[t?.resetKey]);const x=st(),[k,T]=a.useState({cho:new Set,jung:new Set,jong:new Set,syllable:new Set}),[P,$]=a.useState(!1),[X,le]=a.useState(null),re=1,y=Math.max(1,[i.cho,i.jung,i.jong].filter(Boolean).length);a.useEffect(()=>{c<y&&C(y)},[y,c]);const[D,H]=a.useState(e);a.useEffect(()=>{if(D!==e){if(!t?.resetOnMount){const m=pt(e),N=typeof m?.contrastCount=="number"&&Number.isFinite(m.contrastCount)?m.contrastCount:1;C(Math.min(5,Math.max(1,N))),g(m?.composition??E()),S(m?.excludeNoImage??!0),A(m?.sameStructureOnly??!0),f(m?.phonemeView==="pron"?"pron":"char"),b(Array.isArray(m?.gradeFilter)?m.gradeFilter:[]),R(Array.isArray(m?.posFilter)?m.posFilter:[]),j(Array.isArray(m?.wordTypeFilter)?m.wordTypeFilter:[])}H(e)}},[e,D,t?.resetOnMount]),a.useEffect(()=>{if(!t?.resetOnMount&&D===e)try{localStorage.setItem(Et(e),JSON.stringify({contrastCount:c,composition:i,excludeNoImage:h,sameStructureOnly:B,phonemeView:d,gradeFilter:_,posFilter:I,wordTypeFilter:v}))}catch{}},[t?.resetOnMount,e,D,c,i,h,B,d,_,I,v]);const[Y,ee]=a.useState(0);Lu("wordpool:update",()=>ee(m=>m+1));const Du=a.useRef(o.language);a.useEffect(()=>{Du.current!==o.language&&(Du.current=o.language,ee(m=>m+1))},[o.language]),a.useEffect(()=>{if(!u.choseong)return;let m=!1;return Qn({difficulty:w,excludeNoImage:h}).then(N=>{m||(T(N),N.cho.size+N.jung.size+N.jong.size>0&&$(!0))}).catch(()=>{m||T({cho:new Set,jung:new Set,jong:new Set,syllable:new Set})}),()=>{m=!0}},[u.choseong,w,h,Y]),a.useEffect(()=>{let m=!1;const N=i,O=N.cho?ce(N.cho):null,M=N.jung?ce(N.jung):null,U=N.jong===ne,he=U?null:N.jong?ce(N.jong):null,me=N.syllable!=null?Su(N.syllable):null,ve=!!(O||M||he||U||me);return Zn({difficulty:u.difficulty?w:null,contrastCount:u.difficulty?c:1,composition:u.choseong&&ve?{cho:O,jung:M,jong:he,jongNone:U,syllable:me}:null,excludeNoImage:h,sameStructureOnly:B,phonemeView:d==="pron"?"pron":"char",grade:_.length>0?_:null}).then(Ve=>{m||le(Ve)}).catch(()=>{m||le(null)}),()=>{m=!0}},[u.choseong,u.difficulty,w,c,i,d,h,B,Y,_]),a.useEffect(()=>{P&&g(m=>{const N={...m};let O=!1;return["cho","jung","jong"].forEach(M=>{const U=m[M];!U||U===ne||ce(U).some(he=>k[M].has(he))||(N[M]=null,O=!0)}),m.syllable!=null&&u.fixedSyllable==null&&(m.syllable>=oe?[...k.syllable].some(M=>M>=oe)||(N.syllable=null,O=!0):(!k.syllable.has(m.syllable)||m.syllable<re)&&(N.syllable=null,O=!0)),O?N:m})},[k,P,re,u.fixedSyllable]);const _u=a.useMemo(()=>{const m=N=>{const O=new Set;for(const M of ft[N])k[N].has(M)&&O.add(M);return O};return{cho:m("cho"),jung:m("jung"),jong:m("jong")}},[k]),tu=a.useMemo(()=>({exact:new Set(Ct.filter(m=>k.syllable.has(m))),min:[...k.syllable].some(m=>m>=oe)}),[k]),L=a.useMemo(()=>({diffPhonemeCount:n("training.contrast.diffPhonemeCount",{defaultValue:"\uB2E4\uB978 \uC74C\uC18C\uC758 \uCD1D \uAC2F\uC218"}),composition:n("wordPairs.composition","\uC815\uB2F5 \uB2E8\uC5B4 \uAD6C\uC131"),syllableCount:n("wordPairs.syllableCount","\uC74C\uC808 \uC218"),onset:n("wordPairs.onset","\uCD08\uC131"),vowel:n("wordPairs.vowel","\uBAA8\uC74C"),coda:n("wordPairs.coda","\uC885\uC131"),phonemeGroup:n("training.filter.phonemeGroup",{defaultValue:"\uD6C8\uB828 \uC74C\uC808"}),trainOnset:n("training.filter.trainOnset",{defaultValue:"\uCD08\uC131"}),trainVowel:n("training.filter.trainVowel",{defaultValue:"\uBAA8\uC74C"}),trainCoda:n("training.filter.trainCoda",{defaultValue:"\uC885\uC131"}),random:n("training.filter.random","\uBB34\uC791\uC704"),exclude:n("wordSearch.filter.exclude","\uC81C\uC678"),selectLabel:n("training.filter.selectSection",{defaultValue:"\uC120\uD0DD"}),none:n("common.none","\uC5C6\uC74C"),noImage:n("wordSearch.filter.excludeNoImage","\uC774\uBBF8\uC9C0 \uC5C6\uC74C"),excludeImage:n("training.filter.excludeImage",{defaultValue:"\uC774\uBBF8\uC9C0 \uC788\uB294 \uB2E8\uC5B4\uB9CC"}),sameStructure:n("training.filter.sameStructure",{defaultValue:"\uC74C\uC18C \uAD6C\uC870 \uAC19\uC740 \uB2E8\uC5B4\uB9CC"}),noLimit:n("training.filter.noLimit",{defaultValue:"\uBB34\uAD00"}),codaExclude:n("training.filter.codaExclude",{defaultValue:"\uC81C\uC678"}),gradeLabel:n("training.filter.gradeLabel",{defaultValue:"\uB09C\uC774\uB3C4 \uB4F1\uAE09"})}),[n]),Ou=a.useMemo(()=>({[L.trainOnset]:"cho",[L.trainVowel]:"jung",[L.trainCoda]:"jong"}),[L]),ke=a.useCallback((m,N)=>({title:N,items:m}),[]),nu=a.useMemo(()=>[n("training.filter.excludeImageInfo",{defaultValue:"\uC774\uBBF8\uC9C0 \uC788\uB294 \uB2E8\uC5B4\uB9CC: \uB2E8\uC5B4 \uC911\uC5D0 \uC774\uBBF8\uC9C0\uAC00 \uC788\uB294 \uB2E8\uC5B4\uB9CC \uACB0\uACFC\uC5D0 \uBCF4\uC5EC\uC90D\uB2C8\uB2E4."}),n("training.filter.sameStructureInfo",{defaultValue:"\uC74C\uC18C \uAD6C\uC870 \uAC19\uC740 \uB2E8\uC5B4\uB9CC: \uC815\uB2F5\uACFC \uC624\uB2F5\uC758 \uC74C\uC808 \uAD6C\uC870(\uAE00\uC790 \uC218\xB7\uBC1B\uCE68 \uC720\uBB34 \uB4F1)\uAC00 \uAC19\uC740 \uACB0\uACFC\uB9CC \uB0A8\uACA8\uC694."})],[n]),Dt=a.useMemo(()=>{const m=[];if(u.choseong){const N={value:ne,displayLabel:L.codaExclude},O=u.fixedNoCoda===!0,M=(U,he)=>{const me=O&&U==="jong",ve={label:he,groupLabel:L.phonemeGroup,allOption:!u.requireSyllable,allLabel:L.noLimit,allOptionDisabled:me};if(d==="pron"){const Se=pu[U].map(Lt=>Lt.map(({v:ou,tooltip:Nu})=>{const lu=ce(ou),Tu=me||!lu.some(Rt=>k[U].has(Rt));return lu.length>1?{value:ou,labels:lu,tooltip:Nu,disabled:Tu}:{value:ou,tooltip:Nu,disabled:Tu}}));return U==="jong"&&!u.requireCoda&&Se.unshift([N]),{...ve,groups:Se}}const Ve=ft[U].map(Se=>!me&&_u[U].has(Se)?Se:{value:Se,disabled:!0});return{...ve,items:U==="jong"&&!u.requireCoda?[N,...Ve]:Ve}};m.push(M("cho",L.trainOnset)),m.push(M("jung",L.trainVowel)),m.push(M("jong",L.trainCoda))}if(m.push({...at(n,x,{labelInfo:ke([n("wordPairs.filter.difficultyInfo",{defaultValue:"\uAD6D\uB9BD\uAD6D\uC5B4\uC6D0\uC758 \uAE30\uCD08 \uC5B4\uD718 \uB4F1\uAE09\uC774 \uACB0\uACFC\uC5D0 \uBC18\uC601\uB429\uB2C8\uB2E4."})])}),label:L.gradeLabel}),u.partOfSpeech&&m.push(it(x)),u.wordType&&m.push(ct(x)),u.choseong||u.fixedSyllable!=null){const N=u.fixedSyllable;m.push({label:L.syllableCount,items:[...Ct.map(O=>({value:mu(O),displayLabel:n("wordPairs.syllableN",{n:O,defaultValue:"{{n}}\uC74C\uC808"}),disabled:N!=null?O!==N:!tu.exact.has(O)||O<re})),{value:mu(oe),displayLabel:n("wordPairs.syllableNPlus",{n:oe,defaultValue:"{{n}}\uC74C\uC808 \uC774\uC0C1"}),disabled:N!=null?oe!==N:!tu.min}],allOption:!0,allOptionDisabled:N!=null})}return u.choseong?m.push({label:L.exclude,displayLabel:L.selectLabel,multiple:!0,items:[L.excludeImage,L.sameStructure],labelInfo:ke(nu)}):m.push({label:L.exclude,displayLabel:L.selectLabel,multiple:!0,items:[L.excludeImage],labelInfo:ke([nu[0]])}),m},[u.choseong,u.partOfSpeech,u.wordType,u.requireSyllable,u.fixedSyllable,u.fixedNoCoda,u.requireCoda,re,_u,k,d,tu,L,n,ke,nu,x]),_t={...u.difficulty?{[L.diffPhonemeCount]:String(c)}:{},...(u.choseong||u.fixedSyllable!=null)&&i.syllable!=null?{[L.syllableCount]:mu(i.syllable)}:{},...u.choseong&&i.cho?{[L.trainOnset]:i.cho}:{},...u.choseong&&i.jung?{[L.trainVowel]:i.jung}:{},...u.choseong&&i.jong?{[L.trainCoda]:i.jong}:{},[L.exclude]:[...h?[L.excludeImage]:[],...B?[L.sameStructure]:[]],[L.gradeLabel]:_.map(m=>n("wordSearch.filter.grade",{n:Number(m),defaultValue:"{{n}}\uB4F1\uAE09"})),...u.partOfSpeech?{[x.partOfSpeech]:I}:{},...u.wordType?{[x.wordType]:v}:{}},Ot=a.useCallback((m,N)=>{if(N===L.diffPhonemeCount){const O=Number(m);O>=1&&C(O)}else if(N===L.exclude)m===L.excludeImage?S(O=>!O):m===L.sameStructure&&A(O=>!O);else if(N===L.syllableCount)g(O=>{if(!m||m===ge)return{...O,syllable:null};const M=Co(m);return{...O,syllable:O.syllable===M?null:M}});else if(N===L.gradeLabel){if(!m||m===ge){b([]);return}const O=m.replace(/\D/g,"");b(M=>M.includes(O)?M.filter(U=>U!==O):[...M,O])}else if(N===x.partOfSpeech){if(!m||m===ge){R([]);return}R(O=>O.includes(m)?O.filter(M=>M!==m):[...O,m])}else if(N===x.wordType){if(!m||m===ge){j([]);return}j(O=>O.includes(m)?O.filter(M=>M!==m):[...O,m])}else{const O=Ou[N];if(!O)return;g(M=>u.requireSyllable?m&&m!==ge?{...M,[O]:m}:M:!m||m===ge||M[O]===m?{...M,[O]:null}:{...M,[O]:m})}},[L,Ou,x,u.requireSyllable]),Nt=a.useCallback(m=>!u.partOfSpeech&&!u.wordType?!0:ro(m,{...u.partOfSpeech?{[x.partOfSpeech]:I}:{},...u.wordType?{[x.wordType]:v}:{}},x),[u.partOfSpeech,u.wordType,I,v,x]),Tt=a.useCallback(m=>{m!==d&&(m!=="direct"&&d!=="direct"&&g(N=>St(N,m,p.current)),f(m))},[d]),jt=a.useCallback(()=>({composition:i,contrastCount:c,excludeNoImage:h,sameStructureOnly:B,phonemeView:d,gradeFilter:_}),[i,c,h,B,d,_]),It=a.useCallback(m=>{g(m.composition),C(m.contrastCount),S(m.excludeNoImage),A(m.sameStructureOnly??!0),f(m.phonemeView),b(Array.isArray(m.gradeFilter)?m.gradeFilter:[])},[]);return{difficulty:w,contrastCount:c,composition:i,choseong:i.cho,excludeNoImage:h,sameStructureOnly:B,gradeFilter:_,posFilter:I,wordTypeFilter:v,matchesWordAttributes:Nt,poolVersion:Y,filterSections:Dt,filterSelected:_t,handleFilterSelect:Ot,phonemeView:d,setPhonemeView:Tt,phonemeGroupLabel:L.phonemeGroup,wordCount:X,getFilterSnapshot:jt,restoreFilterSnapshot:It}}function So(e){const u=s=>s?ce(s):null,t=u(e.cho),n=u(e.jung),o=e.jong===ne,l=o?null:u(e.jong),r=e.syllable!=null?Su(e.syllable):null;return!t&&!n&&!l&&!o&&!r?null:{cho:t,jung:n,jong:l,jongNone:o,syllable:r}}function Eo(e,u,t,n,o,l,r=!0,s="char",c=[]){const[C,d]=a.useState({}),[f,i]=a.useState(!1),{cho:g=null,jung:E=null,jong:w=null,syllable:p=null}=n??{},h=c.length>0?c.slice().sort().join(","):"";return a.useEffect(()=>{l>0&&Jn(o).catch(()=>{})},[l,o]),a.useEffect(()=>{let S=!1;return i(!0),(async()=>{const B=So({cho:g,jung:E,jong:w,syllable:p}),A=`${g??""}_${E??""}_${w??""}_${p??""}_${h}`,_={};await Promise.all(e.map(async b=>{const I=au[b.key];try{const R=await rt(b.key,{difficulty:I.difficulty?u:null,contrastCount:I.difficulty?t:1,composition:I.choseong?B:null,count:5,excludeNoImage:o,sameStructureOnly:r,phonemeView:s,grade:c.length>0?c:null});R&&R.length>0?_[b.key]={id:`wt-${b.key}-${u}-${A}-${Date.now()}`,name:b.label,training_type:b.key,category_main_code:"WORD",iconColor:b.color,subTitle:b.subTitle,items:R,itemCount:R.length}:_[b.key]={id:`wt-${b.key}-empty`,name:b.label,training_type:b.key,category_main_code:"WORD",iconColor:b.color,subTitle:b.subTitle,items:[],itemCount:0,__empty:!0}}catch{_[b.key]=null}})),S||(d(_),i(!1))})(),()=>{S=!0}},[u,t,g,E,w,p,o,r,s,l,h]),{perTypeData:C,generating:f}}function po(){return ze(new Date)}function ze(e){if(e==null||e==="")return"";const u=e instanceof Date?e:new Date(e);return isNaN(u.getTime())?"":new Intl.DateTimeFormat("fr-CA",{timeZone:"Asia/Seoul"}).format(u)}const je=[],Ie=[],Le=[],Re=[],Je={LISTEN_IN_NOISE:[],SHORT_STORY:[],LONG_STORY:[],ORDERING_SENTENCE:[]},Ze={LISTEN_IN_NOISE:[],SHORT_STORY:[],LONG_STORY:[],ORDERING_SENTENCE:[]},yo={LISTEN_IN_NOISE:3,SHORT_STORY:2,LONG_STORY:1,ORDERING_SENTENCE:2};let Bu=null,yt=null,Ce=null;function Bo({counts:e,forceRefresh:u}={}){const t=Object.assign({},yo,e||{}),n=po(),o=ze(new Date(`${n}T00:00:00+09:00`).getTime()-864e5),l=JSON.stringify(t);if(!u&&yt===n&&Bu===l&&Ce)return Object.assign(Je,Ce.today),Object.assign(Ze,Ce.yesterday?.selection||{LISTEN_IN_NOISE:[],SHORT_STORY:[],LONG_STORY:[],ORDERING_SENTENCE:[]}),{today:Je,yesterday:Ze};const r={LISTEN_IN_NOISE:ae(je,Math.max(0,Number(t.LISTEN_IN_NOISE)||0)),SHORT_STORY:ae(Ie,Math.max(0,Number(t.SHORT_STORY)||0)),LONG_STORY:ae(Le,Math.max(0,Number(t.LONG_STORY)||0)),ORDERING_SENTENCE:ae(Re,Math.max(0,Number(t.ORDERING_SENTENCE)||0))};let s=null;return Ce&&Bu===l&&Ce.yesterday&&Ce.yesterday.date===o&&(s=Ce.yesterday.selection),s||(s={LISTEN_IN_NOISE:ae(je,Math.max(0,Number(t.LISTEN_IN_NOISE)||0)),SHORT_STORY:ae(Ie,Math.max(0,Number(t.SHORT_STORY)||0)),LONG_STORY:ae(Le,Math.max(0,Number(t.LONG_STORY)||0)),ORDERING_SENTENCE:ae(Re,Math.max(0,Number(t.ORDERING_SENTENCE)||0))}),Object.assign(Je,r),Object.assign(Ze,s),yt=n,Bu=l,Ce={today:r,yesterday:{date:o,countsKey:l,selection:s}},{today:Je,yesterday:Ze}}let Bt=!1,Me=null;async function wo(){try{const e={url:typeof document>"u"?require("url").pathToFileURL(__filename).href:ru&&ru.tagName.toUpperCase()==="SCRIPT"&&ru.src||new URL("hooks.cjs.js",document.baseURI).href}&&void 0||"/",u=await fetch(`${e}data/allTrainingData.json`);return u.ok?await u.json():null}catch{return null}}async function bo(){if(!Bt)return Me||(Me=(async()=>{const e=await wo();if(!e){Me=null;try{window.dispatchEvent(new Event("speechear.data.error"))}catch{}return}try{for(const u of Object.keys(e||{})){const t=e[u]||[];for(const n of t){const o=n,l=String(o.training_type||u),r=String(o.category_main_code||o.category_main||o.category_0||""),s=String(o.category_sub_code||o.category_sub||o.category_1||""),c=Object.assign({},o,{training_type:l,category_0:r,category_1:s});l==="LISTEN_IN_NOISE"?je.push(c):l==="SHORT_STORY"?Ie.push(c):l==="LONG_STORY"?Le.push(c):l==="ORDERING_SENTENCE"&&Re.push(c)}}}catch{Me=null;try{window.dispatchEvent(new Event("speechear.data.error"))}catch{}return}try{window.dispatchEvent(new Event("speechear.data.updated"))}catch{}try{Bo()}catch{}Bt=!0})(),Me)}async function Ao(e=3e3){const u=bo();return Promise.race([u,new Promise(t=>setTimeout(t,e))])}function Do(e){let u=2166136261;for(let t=0;t<e.length;t++)u^=e.charCodeAt(t),u=Math.imul(u,16777619);return u>>>0}function _o(e){let u=e>>>0;return()=>{u|=0,u=u+1831565813|0;let t=Math.imul(u^u>>>15,1|u);return t=t+Math.imul(t^t>>>7,61|t)^t,((t^t>>>14)>>>0)/4294967296}}const Qe=ae;function wu(e,u){const t=u?_o(Do(u)):Math.random;return{LISTEN_IN_NOISE:Qe(je,Math.max(0,e.LISTEN_IN_NOISE||0),t),SHORT_STORY:Qe(Ie,Math.max(0,e.SHORT_STORY||0),t),LONG_STORY:Qe(Le,Math.max(0,e.LONG_STORY||0),t),ORDERING_SENTENCE:Qe(Re,Math.max(0,e.ORDERING_SENTENCE||0),t)}}function wt(e){return e?!!(e.LISTEN_IN_NOISE?.length||e.SHORT_STORY?.length||e.LONG_STORY?.length||e.ORDERING_SENTENCE?.length):!1}const Oo={LISTEN_IN_NOISE:3,SHORT_STORY:2,LONG_STORY:1,ORDERING_SENTENCE:2};function bt(e=!1,u=Oo,t){const n=ze(Date.now()),o=ze(Date.now()-864e5),l=`${t??""}|${n}`,r=`${t??""}|${o}`;return je.length>0||Ie.length>0||Le.length>0||Re.length>0?{today:wu(u,l),yesterday:wu(u,r)}:{today:wu(u,l),yesterday:null}}function No(e){const u=a.useRef({LISTEN_IN_NOISE:[],SHORT_STORY:[],LONG_STORY:[],ORDERING_SENTENCE:[]}),t=a.useRef(null),[n,o]=a.useState(!1),[l,r]=a.useState(!1),[s,c]=a.useState(0),[C,d]=a.useState(!1);a.useEffect(()=>{let i=!1,g,E=0;const w=40,p=()=>{g!==void 0&&(clearInterval(g),g=void 0)};let h=!1;try{const A=new URLSearchParams(window.location.search),_=A.get("forceRefresh")||A.get("force");h=_==="1"||_==="true"}catch{}const S=A=>{u.current=A.today,t.current=A.yesterday,o(!0),d(!0),c(_=>_+1),i=!0,p()},B=async()=>{if(i)return;if(!h){const _=bt(!1,void 0,e);if(wt(_.today)){S(_);return}}try{await Ao(3e3)}catch{}if(i)return;const A=bt(h,void 0,e);if(wt(A.today)){S(A);return}++E>=w&&(o(!0),d(!1),i=!0,p())};return B(),g=setInterval(B,250),()=>{i=!0,p()}},[e]);const f=a.useCallback(i=>{const g=l?t.current:u.current,E=l?u.current:t.current;return g?.[i]?.length?g[i]:E?.[i]?.length?E[i]:void 0},[l,s]);return{loaded:n,hasData:C,showYesterday:l,setShowYesterday:r,getTrainingPerType:f}}const Be=[];let Xe=!1;function At(e){if(e.key!=="Escape"||e.defaultPrevented)return;const u=Be[Be.length-1];u&&(e.stopPropagation(),u())}function To(e){return Be.push(e),!Xe&&typeof document<"u"&&(document.addEventListener("keydown",At),Xe=!0),()=>{const u=Be.lastIndexOf(e);u>=0&&Be.splice(u,1),Be.length===0&&Xe&&typeof document<"u"&&(document.removeEventListener("keydown",At),Xe=!1)}}function jo(e,u=!0){const t=Iu(e);a.useEffect(()=>{if(u)return To(()=>{t.current?.()})},[u,t])}const bu=(e,u)=>`${e}:${u??1}`,Au=new Map;function Io(e,u){const[t,n]=a.useState(0),o=e.map(l=>bu(l.word,l.homonum)).join("|");return a.useEffect(()=>{const l=(o?o.split("|"):[]).filter(c=>!Au.has(c));if(l.length===0)return;let r=!1;const s=Array.from(new Set(l.map(c=>c.slice(0,c.lastIndexOf(":")))));return u(s).then(c=>{if(!(r||c.length===0)){for(const C of c)C.Meaning&&Au.set(bu(C.Word,C.Homonum??void 0),C.Meaning);n(C=>C+1)}}),()=>{r=!0}},[o,u]),a.useMemo(()=>{const l=o?o.split("|"):[],r=new Map;for(const s of l){const c=Au.get(s);c!=null&&r.set(s,c)}return r},[o,t])}function Lo(){const[e,u]=a.useState(null),t=a.useCallback(l=>u(l.getBoundingClientRect()),[]),n=a.useCallback(()=>u(null),[]),o=a.useCallback(l=>{const r=l.getBoundingClientRect();u(s=>s?null:r)},[]);return{anchorRect:e,isOpen:e!=null,openAt:t,close:n,toggleAt:o}}function Ro(e){const[u,t]=a.useState(null),[n,o]=a.useState(null),l=a.useRef(null);a.useEffect(()=>()=>{l.current&&clearTimeout(l.current)},[]);const r=a.useCallback((c,C)=>{l.current&&clearTimeout(l.current),l.current=setTimeout(()=>{t(c),o(C)},e)},[e]),s=a.useCallback(()=>{l.current&&clearTimeout(l.current),t(null),o(null)},[]);return{payload:u,anchorRect:n,openAfterDelay:r,close:s}}function Mo(e,u,t){const n=Number.isFinite(u)&&u>=1?Math.floor(u):1,o=Math.max(1,Math.ceil(e.length/n)),l=Number.isFinite(t)?Math.min(Math.max(1,Math.floor(t)),o):1;return{pageItems:a.useMemo(()=>e.slice((l-1)*n,l*n),[e,l,n]),totalPages:o,curPage:l}}function xo(e="warning"){const[u,t]=a.useState(""),[n,o]=a.useState(e),[l,r]=a.useState(0),s=a.useCallback((f,i)=>{o(i),t(f),r(g=>g+1)},[]),c=a.useCallback(f=>s(f,"warning"),[s]),C=a.useCallback(f=>s(f,"normal"),[s]),d=a.useCallback(()=>t(""),[]);return{toastMessage:u,toastType:n,toastKey:l,showToast:s,showWarning:c,showNormal:C,clearToast:d}}const Po=[{key:"LISTEN_IN_NOISE",label:"\uC18C\uC74C \uD558 \uBB38\uC7A5 \uB4E3\uAE30",icon:"party-popper",desc:"\uB2E4\uC591\uD55C \uC18C\uC74C \uD658\uACBD\uC5D0\uC11C \uBB38\uC7A5 \uCCAD\uB825\uC744 \uD6C8\uB828\uD569\uB2C8\uB2E4."},{key:"SHORT_STORY",label:"\uC9E7\uC740 \uC774\uC57C\uAE30 \uB4E3\uAE30",icon:"message-square",desc:"\uC9E7\uC740 \uC774\uC57C\uAE30\uB97C \uB4E3\uACE0 \uAE30\uC5B5\uD558\uC5EC \uBB38\uC81C\uB97C \uD480\uC5B4\uBD05\uB2C8\uB2E4."},{key:"LONG_STORY",label:"\uAE34 \uC774\uC57C\uAE30 \uB4E3\uAE30",icon:"message-square-text",desc:"\uAE34 \uC774\uC57C\uAE30\uB97C \uB4E3\uACE0 \uAE30\uC5B5\uD558\uC5EC \uB2E4\uC218\uC758 \uBB38\uC81C\uB97C \uD480\uC5B4\uBD05\uB2C8\uB2E4."},{key:"ORDERING_SENTENCE",label:"\uBB38\uC7A5 \uC21C\uC11C\uD654 \uD558\uAE30",icon:"align-start-vertical",desc:"\uC5EC\uB7EC\uAC1C\uC758 \uC9E7\uC740 \uBB38\uC7A5\uC744 \uB4E3\uACE0 \uAE30\uC5B5\uD558\uC5EC \uADF8 \uC21C\uC11C\uC5D0 \uB9DE\uAC8C \uBC30\uC5F4\uD569\uB2C8\uB2E4."}],Fo={LISTEN_IN_NOISE:"listenInNoise",SHORT_STORY:"shortStory",LONG_STORY:"longStory",ORDERING_SENTENCE:"orderingSentence"};function ko(e){return Po.map(u=>{const t=Fo[u.key];return t?{...u,label:e(`trainingType.${t}.title`),desc:e(`trainingType.${t}.desc`)}:u})}const xe={blue:"#60A5FA",green:"#4ADE80",amber:"#FBBF24",purple:"#A78BFA",pink:"#F472B6"},Pe=xe.blue,eu=xe.green,Fe=xe.amber,uu=xe.purple,vo=xe.pink,Vo=[{key:"discrimination",label:"\uBCC0\uBCC4\uD6C8\uB828",disc:"\uB450 \uC18C\uB9AC\uAC00 \uAC19\uC740\uC9C0 \uB2E4\uB978\uC9C0, \uB610\uB294 \uD2B9\uC815 \uC18C\uB9AC\uB97C \uAD6C\uBCC4\uD558\uB294 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"ear",types:[{key:"SAME_SOUND_PICK",label:"\uAC19\uC740 \uC18C\uB9AC \uACE0\uB974\uAE30",icon:"volume-2",color:Pe,subTitle:"\uB4E4\uC740 \uC18C\uB9AC\uC640 \uAC19\uC740 \uB2E8\uC5B4 \uCE74\uB4DC\uB97C \uACE0\uB974\uC138\uC694."},{key:"SAME_OR_DIFF",label:"\uAC19\uC740\uC9C0 \uB2E4\uB978\uC9C0 \uB9DE\uD788\uAE30",icon:"diff",color:Pe,subTitle:"\uB450 \uC18C\uB9AC\uAC00 \uAC19\uC740\uC9C0, \uB2E4\uB978\uC9C0 \uAD6C\uBD84\uD558\uC138\uC694."},{key:"HEAR_AND_PICK_SAME",label:"\uC77C\uCE58\uD558\uB294 \uB2E8\uC5B4 \uB9DE\uD788\uAE30",icon:"headphones",color:Pe,subTitle:"\uB4E4\uC740 \uC18C\uB9AC\uC758 \uB2E8\uC5B4 \uCE74\uB4DC\uB97C \uACE0\uB974\uC138\uC694."},{key:"HEAR_AND_PICK_INCLUDED",label:"\uD55C \uC74C\uC808 \uD3EC\uD568 \uB2E8\uC5B4 \uB9DE\uD788\uAE30",icon:"scan-search",color:Pe,subTitle:"\uB4E4\uC740 \uC74C\uC808\uC774 \uD3EC\uD568\uB41C \uB2E8\uC5B4 \uCE74\uB4DC\uB97C \uACE0\uB974\uC138\uC694."},{key:"STARTS_WITH_SAME_SOUND",label:"\uCCAB \uC74C\uC808\uC774 \uAC19\uC740 \uB2E8\uC5B4 \uB9DE\uD788\uAE30",icon:"play-circle",color:Pe,subTitle:"\uB4E4\uC740 \uB2E8\uC5B4\uC640 \uAC19\uC740 \uC18C\uB9AC\uB85C \uC2DC\uC791\uD558\uB294 \uB2E8\uC5B4\uB97C \uACE0\uB974\uC138\uC694."}]},{key:"synthesis",label:"\uD569\uC131\uD6C8\uB828",disc:"\uB450 \uAC1C \uC774\uC0C1\uC758 \uC74C\uC808\uC774\uB098 \uC74C\uC18C\uB97C \uD569\uCCD0 \uB2E8\uC5B4\uB97C \uB9CC\uB4DC\uB294 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"git-merge",types:[{key:"MERGE_2_SYLLABLES",label:"\uC74C\uC808 2\uAC1C \uD569\uCE58\uAE30",icon:"link-2",color:eu,subTitle:"\uB450 \uC74C\uC808\uC744 \uD569\uCE58\uBA74 \uC5B4\uB5A4 \uB2E8\uC5B4\uAC00 \uB420\uAE4C\uC694?"},{key:"MERGE_3_SYLLABLES",label:"\uC74C\uC808 3\uAC1C \uD569\uCE58\uAE30",icon:"git-merge",color:eu,subTitle:"\uC138 \uC74C\uC808\uC744 \uD569\uCE58\uBA74 \uC5B4\uB5A4 \uB2E8\uC5B4\uAC00 \uB420\uAE4C\uC694?"},{key:"MERGE_2_PHONEMES",label:"\uC74C\uC18C 2\uAC1C \uD569\uCE58\uAE30",icon:"combine",color:eu,subTitle:"\uB450 \uC74C\uC18C\uB97C \uD569\uCE58\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"},{key:"MERGE_3_PHONEMES",label:"\uC74C\uC18C 3\uAC1C \uD569\uCE58\uAE30",icon:"braces",color:eu,subTitle:"\uC138 \uC74C\uC18C\uB97C \uD569\uCE58\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"}]},{key:"deletion",label:"\uD0C8\uB77D\uD6C8\uB828",disc:"\uB2E8\uC5B4\uC5D0\uC11C \uC74C\uC808\uC774\uB098 \uC74C\uC18C\uB97C \uC81C\uAC70\uD588\uC744 \uB54C \uB0A8\uB294 \uC18C\uB9AC\uB97C \uC778\uC2DD\uD558\uB294 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"scissors",types:[{key:"DROP_1_FROM_2SYLL",label:"2\uC74C\uC808\uC5D0\uC11C 1\uC74C\uC808 \uD0C8\uB77D",icon:"scissors",color:Fe,subTitle:"2\uC74C\uC808 \uB2E8\uC5B4\uC5D0\uC11C \uD55C \uC74C\uC808\uC744 \uBE7C\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"},{key:"DROP_1_FROM_3SYLL",label:"3\uC74C\uC808\uC5D0\uC11C 1\uC74C\uC808 \uD0C8\uB77D",icon:"minus-circle",color:Fe,subTitle:"3\uC74C\uC808 \uB2E8\uC5B4\uC5D0\uC11C \uD55C \uC74C\uC808\uC744 \uBE7C\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"},{key:"DROP_PART_FROM_COMPOUND",label:"\uD569\uC131\uC5B4\uC5D0\uC11C \uBD80\uBD84\uD0C8\uB77D",icon:"unlink",color:Fe,subTitle:"\uD569\uC131\uC5B4\uC758 \uC77C\uBD80\uB97C \uBE7C\uBA74 \uC5B4\uB5A4 \uB2E8\uC5B4\uAC00 \uB420\uAE4C\uC694?"},{key:"DROP_FINAL_CONSONANT_FROM_1SYLL",label:"1\uC74C\uC808\uC5D0\uC11C \uBC1B\uCE68 \uD0C8\uB77D",icon:"eraser",color:Fe,subTitle:"\uBC1B\uCE68\uC744 \uBE7C\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB420\uAE4C\uC694?"},{key:"REMOVE_CONSONANT_AND_IDENTIFY_PHONEME",label:"1\uC74C\uC808\uC5D0\uC11C \uC790\uC74C \uD0C8\uB77D",icon:"audio-lines",color:Fe,subTitle:"\uC790\uC74C\uC744 \uBE7C\uBA74 \uC5B4\uB5A4 \uC18C\uB9AC\uAC00 \uB0A8\uC744\uAE4C\uC694?"}]},{key:"substitution",label:"\uB300\uCE58\uD6C8\uB828",disc:"\uB2E8\uC5B4\uC758 \uC77C\uBD80 \uC74C\uC808\uC774\uB098 \uC74C\uC18C\uB97C \uBC14\uAFB8\uC5B4 \uC0C8\uB85C\uC6B4 \uC18C\uB9AC\uB97C \uB9CC\uB4DC\uB294 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"replace",types:[{key:"CHANGE_1_SYLL_IN_2SYLL",label:"2\uC74C\uC808\uC5D0\uC11C \uD55C \uC74C\uC808 \uBC14\uAFB8\uAE30",icon:"replace",color:uu,subTitle:"2\uC74C\uC808 \uB2E8\uC5B4\uC758 \uD55C \uC74C\uC808\uC744 \uBC14\uAFD4 \uC0C8 \uB2E8\uC5B4\uB97C \uB9CC\uB4DC\uC138\uC694."},{key:"CHANGE_1_SYLL_IN_3SYLL",label:"3\uC74C\uC808\uC5D0\uC11C \uD55C \uC74C\uC808 \uBC14\uAFB8\uAE30",icon:"shuffle",color:uu,subTitle:"3\uC74C\uC808 \uB2E8\uC5B4\uC758 \uD55C \uC74C\uC808\uC744 \uBC14\uAFD4 \uC0C8 \uB2E8\uC5B4\uB97C \uB9CC\uB4DC\uC138\uC694."},{key:"CHANGE_1_PHONEME_IN_1SYLL",label:"1\uC74C\uC808\uC5D0\uC11C \uD55C \uC74C\uC18C \uBC14\uAFB8\uAE30",icon:"arrow-right-left",color:uu,subTitle:"1\uC74C\uC808 \uB2E8\uC5B4\uC758 \uD55C \uC74C\uC18C\uB97C \uBC14\uAFD4 \uC0C8 \uC18C\uB9AC\uB97C \uB9CC\uB4DC\uC138\uC694."},{key:"CHANGE_1_PHONEME_IN_2SYLL",label:"2\uC74C\uC808\uC5D0\uC11C \uD55C \uC74C\uC18C \uBC14\uAFB8\uAE30",icon:"flip-horizontal",color:uu,subTitle:"2\uC74C\uC808 \uB2E8\uC5B4\uC758 \uD55C \uC74C\uC18C\uB97C \uBC14\uAFD4 \uC0C8 \uB2E8\uC5B4\uB97C \uB9CC\uB4DC\uC138\uC694."}]},{key:"attention",label:"\uCCAD\uAC01\uC801\uC8FC\uC758\uB825\uD6C8\uB828",disc:"\uC5EC\uB7EC \uC18C\uB9AC\uB97C \uB4E3\uACE0 \uC21C\uC11C\uB97C \uAE30\uC5B5\uD558\uB294 \uC8FC\uC758\uB825\uACFC \uB2E8\uAE30 \uAE30\uC5B5 \uD6C8\uB828\uC785\uB2C8\uB2E4.",icon:"list-ordered",types:[{key:"LISTEN_AND_REMEMBER_ORDER",label:"\uB4E3\uACE0 \uC21C\uC11C\uB300\uB85C \uAE30\uC5B5\uD558\uAE30",icon:"list-ordered",color:vo,subTitle:"\uC138 \uB2E8\uC5B4\uB97C \uB4E4\uC740 \uC21C\uC11C\uB300\uB85C \uCE74\uB4DC\uB97C \uC120\uD0DD\uD558\uC138\uC694."}]}];function Go(){const{t:e}=Ee.useTranslation();return a.useMemo(()=>{const u=Object.fromEntries(ko(e).map(n=>[n.key,n.label])),t={...u};return Vo.flatMap(n=>n.types).forEach(n=>{t[n.key]=e(`trainingType.${n.key}.label`,{defaultValue:n.label})}),{sentence:u,all:t}},[e])}const Yo="0.39.0";function $o({computeStyle:e,onScroll:u="close",onResize:t="close",ignoreOutsideClickSelector:n}){const[o,l]=a.useState(!1),[r,s]=a.useState({}),c=a.useRef(null),C=a.useRef(null),d=a.useCallback(()=>{c.current&&s(e(c.current.getBoundingClientRect()))},[e]);a.useEffect(()=>{if(!o)return;d();const g=h=>{const S=h.target;n&&S.closest?.(n)||c.current?.contains(S)||C.current?.contains(S)||l(!1)};document.addEventListener("mousedown",g);const E=h=>{C.current?.contains(h.target)||(u==="reposition"?d():u==="close"&&l(!1))};u!=="ignore"&&window.addEventListener("scroll",E,!0);const w=()=>{t==="reposition"?d():t==="close"&&l(!1)};t!=="ignore"&&window.addEventListener("resize",w);const p=h=>{h.key==="Escape"&&l(!1)};return document.addEventListener("keydown",p),()=>{document.removeEventListener("mousedown",g),u!=="ignore"&&window.removeEventListener("scroll",E,!0),t!=="ignore"&&window.removeEventListener("resize",w),document.removeEventListener("keydown",p)}},[o,d,u,t,n]);const f=a.useCallback(()=>l(g=>!g),[]),i=a.useCallback(()=>l(!1),[]);return{open:o,setOpen:l,toggle:f,close:i,style:r,triggerRef:c,menuRef:C}}function Ho(e,{mode:u="playback",autoStart:t=!1,onPlaySpeaker:n,onComplete:o,playMs:l=1100,feedbackMs:r=1500}={}){const[s,c]=a.useState([]),[C,d]=a.useState(0),[f,i]=a.useState("idle"),[g,E]=a.useState(null),[w,p]=a.useState([]),[h,S]=a.useState(null),[B,A]=a.useState(0),_=a.useRef(0),b=a.useCallback(y=>{_.current=typeof y=="function"?y(_.current):y,A(_.current)},[]),I=a.useRef(n),R=a.useRef(o);a.useEffect(()=>{I.current=n,R.current=o},[n,o]);const v=a.useRef([]),j=()=>{v.current.forEach(clearTimeout),v.current=[]},G=(y,D)=>{v.current.push(setTimeout(D,y))};a.useEffect(()=>()=>j(),[]);const x=s[C]?.id??null,k=a.useCallback(()=>{j(),i("playing"),p([]),S(null),b(0);let y=0;e.forEach((D,H)=>{G(y,()=>{d(H),E(D.id),I.current?.(D)}),G(y+1e3,()=>{E(null),p(Y=>[...Y,D.id])}),y+=1300}),G(y,()=>{i("done"),R.current?.({score:0,total:e.length})})},[e,b]),T=a.useCallback((y,D)=>{if(D>=y.length){i("done"),R.current?.({score:_.current,total:y.length});return}d(D),S(null),i("playing"),E(y[D].id),I.current?.(y[D]),G(l,()=>{E(null),i("waiting")})},[l]),P=a.useCallback(()=>{j();const y=F(e);c(y),b(0),p([]),T(y,0)},[e,T,b]),$=a.useCallback(()=>{u==="playback"?(c(e),k()):P()},[u,e,k,P]),X=a.useCallback(()=>{j(),i("idle"),E(null),p([]),S(null),d(0),b(0),c([])},[b]);a.useEffect(()=>{t?$():X()},[u,e.length,t]);const le=a.useCallback(y=>{f!=="waiting"||u==="playback"||(S(y),y===s[C]?.id&&b(D=>D+1),u==="exam"?(i("playing"),G(400,()=>T(s,C+1))):(i("feedback"),G(r,()=>T(s,C+1))))},[f,u,s,C,T,r,b]),re=u==="playback"?e.length:s.length;return{bind:{activeSpeakerId:g,playedIds:w,selectedId:h,answerId:x,showFeedback:f==="feedback",clickable:f==="waiting",onSelectSpeaker:le},index:C,total:re,score:B,phase:f,done:f==="done",start:$,reset:X}}exports.CACHE_GROUPS=Vu,exports.CORE_VERSION=Yo,exports.DocumentTitleSuppressContext=Mu,exports.EMPTY_COMPOSITION=yu,exports.MediaQueryOverrideContext=ju,exports.NO_CODA=ne,exports.SYLLABLE_MIN=oe,exports.VAP_PAGE_SIZE_OPTIONS=Hu,exports.buildGradeSection=at,exports.buildPartOfSpeechSection=it,exports.buildPositionSection=uo,exports.buildSelectSection=eo,exports.buildSyllableSection=Xn,exports.buildWordTypeSection=ct,exports.charToPronValue=ht,exports.convertComposition=St,exports.fmtBytes=en,exports.lsBytes=Gu,exports.meaningKey=bu,exports.pronToCharValue=mt,exports.syllableToFilter=Su,exports.today=De,exports.toggleAttributeFilter=to,exports.useAnchoredMenu=$o,exports.useCacheManagement=un,exports.useDailyTrainingSelection=No,exports.useDelayedHoverAnchor=Ro,exports.useDeviceManagement=Cn,exports.useDocumentTitle=Ft,exports.useEscToClose=jo,exports.useFontScale=Mt,exports.useHoverAnchor=Lo,exports.useMediaQuery=Pt,exports.usePagedList=Mo,exports.usePasswordChange=vt,exports.useRelativeDay=kt,exports.useSoundCompassExam=Ho,exports.useTablePaging=an,exports.useTableSort=cn,exports.useToastState=xo,exports.useTrainingTypeLabels=Go,exports.useVisitAllPanel=sn,exports.useVisitHistory=on,exports.useVisitSchedule=rn,exports.useWindowEvent=Lu,exports.useWordAttributeFilterKeys=st,exports.useWordDataStats=tn,exports.useWordMeanings=Io,exports.useWordTrainingDataGeneration=Eo,exports.useWordTrainingFilter=mo,exports.valueToJamos=ce;