1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6707],{60850:function(e,t,n){n.d(t,{CZ:function(){return r},R2:function(){return s},T9:function(){return l},fk:function(){return o},mK:function(){return a}}),n(83079);var i=n(12119),r=(0,i.$)("489a0c9551b931e08d89f7f5f5c892c7b23fefff"),s=(0,i.$)("2a95e2f3f90e7fed938e495986951730a05744b5"),o=(0,i.$)("b4d076709ab489b493a50d11e39e0979ff1959b6"),l=(0,i.$)("b9f327ac565182d2647700118e1b3771a61f0997"),a=(0,i.$)("0fc61a8119cacee671e8cde298a46648317d4bef")},35596:function(e,t,n){n.d(t,{Z:function(){return j}});var i=n(57437),r=n(2265),s=n(52345),o=n(59717),l=n(81906),a=n(33728),d=n(57586),c=n(13100),u=n(32489),h=n(46977),f=n(93448),m=n(21652),x=n(8345),v=n(82941);let g=0,b=[],p=0,w=!1;function k(){p++,window.history.back()}let y="";function j(e){let{isOpen:t,onClose:n,title:j,children:z,footer:N,className:M}=e,C=(0,r.useId)(),L=(0,s.J)(),E=(0,o.o)(),R=(0,l.c)(0);(0,r.useEffect)(()=>{t&&R.set(0)},[t,R]);let D=(0,a.H)(R,[0,240],[1,0]),W=(0,r.useRef)(n),S=(0,r.useRef)(!1);(0,r.useEffect)(()=>{W.current=n},[n]),(0,r.useEffect)(()=>{if(!t)return;g||(y=document.body.style.overflow),g++,w||(w=!0,window.addEventListener("popstate",e=>{var t;if((p>0||b.length>0)&&(0,x.l)(e),p>0){p--;return}null===(t=b.at(-1))||void 0===t||t.onPop()},{capture:!0}));let e={id:C,onPop:()=>{S.current&&(S.current=!1,W.current())}};b.push(e),document.body.style.overflow="hidden";let n=(0,m.UM)(),i=window.history.state||{};return n&&!S.current&&(window.history.pushState({...i,isBottomSheet:!0,sheetId:C},""),S.current=!0),()=>{var t;S.current&&(null===(t=window.history.state)||void 0===t?void 0:t.sheetId)===C&&(S.current=!1,k()),b.splice(b.indexOf(e),1),--g<=0&&(g=0,document.body.style.overflow=y)}},[t,C]);let B=(0,r.useCallback)(()=>{S.current&&(S.current=!1,k()),n()},[n]),T=(0,h.a)(t,B),A=(0,r.useCallback)((e,t)=>{"pointercancel"!==e.type&&"touchcancel"!==e.type&&(t.velocity.y>500||t.offset.y>100)&&B()},[B]),I=(0,r.useRef)(null),H=(0,r.useRef)(null);return(0,r.useEffect)(()=>{if(!t)return;let e=I.current;if(!e)return;let n=[],i=function(t){let n=!(arguments.length>1)||void 0===arguments[1]||arguments[1];if(!e.contains(t)||H.current!==t)return;let i=e.getBoundingClientRect(),r=t.getBoundingClientRect(),s=(0,v.Wk)({top:r.top-i.top,bottom:r.bottom-i.top},e.clientHeight,12,12);0!==s&&e.scrollTo({top:Math.max(0,e.scrollTop+s),behavior:n?"smooth":"auto"})},r=e=>{let t=e.target;t&&("INPUT"===t.tagName||"TEXTAREA"===t.tagName||"SELECT"===t.tagName||t.isContentEditable)&&(H.current=t,i(t,!1),n.push(setTimeout(()=>i(t,!0),120)),n.push(setTimeout(()=>i(t,!0),300)),n.push(setTimeout(()=>i(t,!0),500)))},s=()=>{H.current=null},o=()=>{H.current&&i(H.current,!0)};e.addEventListener("focusin",r),e.addEventListener("focusout",s);let l=window.visualViewport;return null==l||l.addEventListener("resize",o),()=>{n.forEach(clearTimeout),e.removeEventListener("focusin",r),e.removeEventListener("focusout",s),null==l||l.removeEventListener("resize",o)}},[t]),(0,i.jsx)(d.M,{children:t&&(0,i.jsxs)("div",{className:"md:hidden fixed inset-x-0 z-[100] flex items-end",style:{top:"var(--vv-offset-top, 0px)",height:"var(--app-height)"},children:[(0,i.jsx)(c.E.div,{initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0},transition:{duration:.22,ease:[.22,1,.36,1]},className:"absolute inset-0",children:(0,i.jsx)(c.E.div,{style:{opacity:D},onClick:B,className:"absolute inset-0 bg-black/50 backdrop-blur-sm"})}),(0,i.jsxs)(c.E.div,{style:{y:R,maxHeight:"90%"},initial:L?{opacity:0}:{y:"100%"},animate:{y:0,opacity:1},exit:L?{opacity:0}:{y:"100%"},transition:L?{duration:.12}:{type:"spring",damping:30,stiffness:320,mass:.8},drag:"y",dragListener:!1,dragControls:E,dragConstraints:{top:0},dragSnapToOrigin:!0,dragMomentum:!1,dragElastic:{top:.12,bottom:.75},onDragEnd:A,ref:T,tabIndex:-1,"aria-label":j||"ìì¸ ì¤ì ",role:"dialog","aria-modal":"true",className:(0,f.cn)("relative w-full bg-white dark:bg-[#18181b] border-t border-transparent dark:border-white/[0.08] rounded-t-2xl","flex flex-col overflow-hidden mobile-sheet-pad shadow-2xl",M),children:[(0,i.jsxs)("div",{onPointerDown:e=>{e.target.closest("button")||E.start(e)},className:"shrink-0 cursor-grab active:cursor-grabbing touch-none select-none",children:[(0,i.jsx)("div",{className:"flex justify-center pt-3 pb-2",children:(0,i.jsx)("div",{className:"w-9 h-1 rounded-full bg-zinc-400/70 dark:bg-zinc-700"})}),(0,i.jsxs)("div",{className:"flex items-center justify-between px-4 pb-2 border-b border-zinc-200/40 dark:border-zinc-800/60",children:[(0,i.jsx)("h3",{className:"text-[var(--mobile-font-h2)] font-semibold text-zinc-900 dark:text-zinc-100",children:j}),(0,i.jsx)("button",{type:"button",onClick:B,"aria-label":"ë«ê¸°",className:"flex h-11 w-11 items-center justify-center rounded-lg text-zinc-600 dark:text-zinc-300",children:(0,i.jsx)(u.Z,{size:20})})]})]}),(0,i.jsx)("div",{ref:I,className:"flex-1 overflow-y-auto overflow-x-hidden px-4 pt-3 pb-2 mobile-scroll mobile-sheet-scroll",children:z}),N&&(0,i.jsx)("div",{className:"shrink-0 px-4 pt-2.5 pb-1 border-t border-zinc-100 dark:border-zinc-800/80 bg-white/95 dark:bg-[#18181b]/95 backdrop-blur-md",children:N})]})]})})}},59112:function(e,t,n){n.r(t),n.d(t,{default:function(){return j}});var i=n(57437),r=n(2265),s=n(98319),o=n(10136),l=n(46078),a=n(22606),d=n(67920),c=n(83008),u=n(93448),h=n(95805),f=n(88501),m=n(38553),x=n(69076),v=n(30401),g=n(21047),b=n(99397),p=n(48013);let w={timetableView:"my",setTimetableView:()=>{},timetableData:{},todayInfo:{index:1,key:"mon"},memo:"ë©ëª¨ ìì ¯ ììì
ëë¤.",onMemoChange:()=>{},scheduleEvents:[{id:"1",title:"êµì§ì íì",date:"2026-03-15",tag:"red",createdAt:""},{id:"2",title:"íë¶ëª¨ ìë´",date:"2026-03-16",tag:"green",createdAt:""}],isGuest:!0,attendanceStats:{absent:1,late:0,early:1,passing:0},attendanceRecords:[],homeroomStudents:[],roleAssignments:[{id:"1",studentId:"s1",studentName:"ê¹ì² ì",role:"ì¹ í ì§ì°ê¸°"},{id:"2",studentId:"s2",studentName:"ì´ìí¬",role:"ì°ì ë¹ë²"}],onReload:()=>{}},k=[{id:"timetable",label:"ìê°í",icon:(0,i.jsx)(function(e){let{size:t=18,className:n="",...r}=e;return(0,i.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",className:n,...r,children:(0,i.jsx)("path",{fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd",d:"M19.25 3c.966 0 1.75.784 1.75 1.75v14.5A1.75 1.75 0 0 1 19.25 21H4.75A1.75 1.75 0 0 1 3 19.25V4.75C3 3.784 3.784 3 4.75 3zM4.5 10v9.25c0 .138.112.25.25.25H8.5V10zm5.5 0v9.5h4V10zm5.5 0v9.5h3.75a.25.25 0 0 0 .25-.25V10zM4.75 4.5a.25.25 0 0 0-.25.25V8.5h4v-4zm5.25 4h4v-4h-4zm5.5 0h4V4.75a.25.25 0 0 0-.25-.25H15.5z"})})},{size:18})},{id:"memo",label:"ë©ëª¨",icon:(0,i.jsx)(function(e){let{size:t=18,className:n="",...r}=e;return(0,i.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",className:n,...r,children:(0,i.jsx)("path",{fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd",d:"M19.25 3c.966 0 1.75.784 1.75 1.75v9.005l-.004.067-.001.013-.002.015-.012.068-.002.008a1 1 0 0 1-.03.095l-.005.012-.006.016-.005.01-.016.034-.005.01-.007.013-.01.018-.006.009a1 1 0 0 1-.082.109l-.003.004-.024.024-6.5 6.5-.024.023-.004.004-.024.02-.002.002a1 1 0 0 1-.083.06l-.01.005-.017.01-.013.008-.01.005-.033.016-.011.005-.016.007-.012.004-.069.023-.004.001-.022.006-.008.002-.068.012-.015.002-.013.001-.03.003h-.
1037L13.75 21h-9A1.75 1.75 0 0 1 3 19.25V4.75C3 3.784 3.784 3 4.75 3zM4.75 4.5a.25.25 0 0 0-.25.25v14.5c0 .138.112.25.25.25H13v-5.75a.75.75 0 0 1 .75-.75h5.75V4.75a.25.25 0 0 0-.25-.25zm9.75 13.94 3.94-3.94H14.5z"})})},{size:18})},{id:"attendance",label:"ì¶ê²° íí©",icon:(0,i.jsx)(h.Z,{size:18,strokeWidth:1.5})},{id:"roles",label:"íìë³ ìí ",icon:(0,i.jsx)(function(e){let{size:t=18,className:n="",...r}=e;return(0,i.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",className:n,...r,children:(0,i.jsxs)("g",{fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd",children:[(0,i.jsx)("path",{d:"M12 5.5a4.5 4.5 0 1 1 0 9 4.5 4.5 0 0 1 0-9M12 7a3 3 0 1 0 0 6 3 3 0 0 0 0-6"}),(0,i.jsx)("path",{d:"M12 2a8 8 0 0 1 7.705 10.146l3.037 3.036c.977.976.49 2.646-.858 2.946l-2.256.5-.501 2.257c-.3 1.347-1.969 1.834-2.945.858l-3.756-3.756A8 8 0 0 1 12 18q-.215 0-.428-.013l-3.754 3.756c-.976.976-2.646.49-2.946-.858l-.502-2.256-2.255-.501c-1.347-.3-1.833-1.97-.857-2.946l3.036-3.037A8 8 0 0 1 12 2M2.318 16.243a.25.25 0 0 0 .122.42l2.722.606.104.03a.75.75 0 0 1 .465.539l.606 2.722a.25.25 0 0 0 .42.122l3-3A8.02 8.02 0 0 1 4.89 13.67zm16.792-2.572a8.02 8.02 0 0 1-4.868 4.01l3 3c.14.14.378.07.421-.121l.605-2.722.03-.104a.75.75 0 0 1 .539-.465l2.722-.606a.25.25 0 0 0 .123-.42zM12 3.5a6.5 6.5 0 1 0 0 13 6.5 6.5 0 0 0 0-13"})]})})},{size:18})},{id:"schedule",label:"ë¤ê°ì¤ë ì¼ì ",icon:(0,i.jsx)(f.Z,{size:18,strokeWidth:1.5})},{id:"meal",label:"ì¤ëì ê¸ì",icon:(0,i.jsx)(m.Z,{size:18,strokeWidth:1.5})},{id:"checklist",label:"ì²´í¬ë¦¬ì¤í¸",icon:(0,i.jsx)(function(e){let{size:t=18,className:n="",...r}=e;return(0,i.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",className:n,...r,children:(0,i.jsxs)("g",{fill:"currentColor",children:[(0,i.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M7.25 16a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-.75.75h-3.5a.75.75 0 0 1-.75-.75v-3.5a.75.75 0 0 1 .75-.75zM4.5 19.5h2v-2h-2z"}),(0,i.jsx)("path",{d:"M20.25 17.25a.75.75 0 0 1 0 1.5h-9.5a.75.75 0 0 1 0-1.5z"}),(0,i.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M7.25 9.5a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-.75.75h-3.5a.75.75 0 0 1-.75-.75v-3.5a.75.75 0 0 1 .75-.75zM4.5 13h2v-2h-2z"}),(0,i.jsx)("path",{d:"M20.25 11.25a.75.75 0 0 1 0 1.5h-9.5a.75.75 0 0 1 0-1.5z"}),(0,i.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M7.25 3a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-.75.75h-3.5A.75.75 0 0 1 3 7.25v-3.5A.75.75 0 0 1 3.75 3zM4.5 6.5h2v-2h-2z"}),(0,i.jsx)("path",{d:"M20.25 5.5a.75.75 0 0 1 0 1.5h-9.5a.75.75 0 0 1 0-1.5z"})]})})},{size:18})},{id:"work-note-shortcut",label:"ì
무ë
¸í¸ ë°ë¡ê°ê¸°",icon:(0,i.jsx)(p.k7,{size:18,strokeWidth:1.5})},{id:"dday",label:"D-DAY",icon:(0,i.jsx)(function(e){let{size:t=18,className:n="",...r}=e;return(0,i.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",className:n,...r,children:(0,i.jsx)("path",{fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd",d:"M9.68 3a2.75 2.75 0 0 1 2.738 2.492l.048.508h7.784a.75.75 0 0 1 .75.75v10.5a.75.75 0 0 1-.75.75h-5.668a2.75 2.75 0 0 1-2.74-2.51l-.086-.99H4.5v5.75a.75.75 0 0 1-1.5 0V3.75A.75.75 0 0 1 3.75 3zm3.51 10.68v.005l.147 1.674a1.25 1.25 0 0 0 1.245 1.141H19.5v-9h-6.894zM4.5 13h7.12l-.696-7.367A1.25 1.25 0 0 0 9.68 4.5H4.5z"})})},{size:18})},{id:"weather",label:"ì¤ëì ë ì¨",icon:(0,i.jsx)(function(e){let{size:t=18,className:n="",...r}=e;return(0,i.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:t,viewBox:"0 0 24 24",fill:"none",className:n,...r,children:(0,i.jsx)("path",{fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd",d:"M12 3a7.25 7.25 0 0 1 7.183 6.263A5.502 5.502 0 0 1 17.5 20h-12a4.5 4.5 0 0 1-.706-8.945A7.25 7.25 0 0 1 12 3m0 1.5a5.75 5.75 0 0 0-5.595 7.081.75.75 0 0 1-.764.922L5.5 12.5a3 3 0 1 0 0 6h12a4 4 0 0 0 .833-7.913.75.75 0 0 1-.593-.689A5.75 5.75 0 0 0 12 4.5"})})},{size:18})}];function y(){let{visibleWidgets:e,layouts:t,setConfig:n}=(0,a.Ln)(),h=(0,d.XC)(),f=(0,o.N)(),{showToast:m}=(0,s.pm)(),p=r.useRef(null),[y,j]=r.useState(1),[z,N]=r.useState(!1),[M,C]=r.useState(t),[L,E]=r.useState(e),[R,D]=r.useState(!1),[W,S]=r.useState(!1);r.useEffect(()=>{R||(C(t),E(e))},[t,e,R]);let B=r.useMemo(()=>{let e=(null==M?void 0:M.lg)||[],t=new Set(L),n=e.filter(e=>t.has(e.i)).reduce((e,t)=>
1Math.max(e,(t.y||0)+(t.h||0)),0);return Math.max(520,180*n+16*Math.max(0,n-1)+48)},[M,L]),T=e=>{L.includes(e)?E(t=>t.filter(t=>t!==e)):(E(t=>[...t,e]),C(t=>{let n={...t},i=a.DV[e];return["lg","md","sm"].forEach(t=>{let r=n[t]?[...n[t]]:[];if(!r.some(t=>t.i===e)&&i){let t=r.reduce((e,t)=>Math.max(e,(t.y||0)+(t.h||0)),0);r.push({i:e,x:0,y:t,w:i.defaultW,h:i.defaultH,minW:i.minW,minH:i.minH,maxW:i.maxW,maxH:i.maxH})}n[t]=r}),n})),D(!0)},A=async()=>{N(!0);try{let e=await (0,c.X)("saveDashboardConfig",{layouts:M,visibleWidgets:L},h);if(!e.success){if("Unauthorized"===e.error||"Unauthorized"===e.message){n(M,L),D(!1),S(!0),m("ì²´í 모ëììë íì¬ ë¸ë¼ì°ì ì ìì ì ì¥ë©ëë¤.","info"),setTimeout(()=>S(!1),2e3);return}m(e.error||"ì ì¥ì ì¤í¨íìµëë¤. ë¤ì ìëí´ì£¼ì¸ì.","error");return}n(M,L),D(!1),S(!0),setTimeout(()=>S(!1),2e3)}catch(e){console.error("Failed to save dashboard config:",e),m("ì ì¥ ì¤ ì¤ë¥ê° ë°ìíìµëë¤. ë¤ì ìëí´ì£¼ì¸ì.","error")}finally{N(!1)}};return r.useEffect(()=>{let e=()=>{if(p.current){let{width:e}=p.current.getBoundingClientRect();j(Math.max(.1,Math.min(1,(e-48)/1200)))}};e();let t=new ResizeObserver(e);return p.current&&t.observe(p.current),()=>t.disconnect()},[]),(0,i.jsxs)("div",{className:"flex flex-col h-full",children:[(0,i.jsxs)("div",{className:"flex items-end justify-between pb-2 mb-4 border-b border-zinc-200 dark:border-[#27272a] shrink-0",children:[(0,i.jsxs)("div",{children:[(0,i.jsx)("h3",{className:"text-[17px] font-medium text-zinc-900 dark:text-white",children:"ëìë³´ë í¸ì§"}),(0,i.jsx)("p",{className:"text-[13px] text-zinc-500 mt-1",children:"ì¼ìª½ìì ìì ¯ì ì¼ê³ ëê³ , ì¤ë¥¸ìª½ìì ëì´ í¬ê¸°ì ì리를 ì íì¸ì."})]}),(0,i.jsxs)("div",{className:"flex items-center gap-2",children:[(0,i.jsxs)("button",{onClick:()=>{(async()=>{await f({title:"기본 ì¤ì ì¼ë¡ ëë릴ê¹ì?",description:"ì§ê¸ ë°°ì¹í ìì ¯ 구ì±ì´ ì²ì ìíë¡ ëìê°ëë¤.",confirmLabel:"ëë리기",tone:"default"})&&(C(a.Gj),E(a.h4),D(!0))})()},className:"flex items-center gap-2 px-3 py-1.5 rounded-lg text-sm text-zinc-500 hover:text-zinc-900 dark:text-zinc-400 dark:hover:text-zinc-200 hover:bg-zinc-100 dark:hover:bg-zinc-800 transition-colors",children:[(0,i.jsx)(x.Z,{size:16}),"ì´ê¸°í"]}),(0,i.jsxs)("button",{onClick:A,disabled:!R||z,className:(0,u.cn)("flex items-center gap-2 px-3 py-1.5 rounded-lg text-sm font-medium transition-colors",R&&!z?"bg-[#007AFF] dark:bg-[#2883DE] text-white hover:opacity-90":W?"text-[#007AFF] dark:text-[#2883DE]":"text-zinc-400 cursor-not-allowed"),children:[(0,i.jsx)(v.Z,{size:16}),z?"ì ì¥ ì¤...":W?"ì ì¥ë¨":"ì ì¥"]})]})]}),(0,i.jsxs)("div",{className:"flex flex-1 gap-6 min-h-0",children:[(0,i.jsx)("div",{className:"w-64 shrink-0 flex flex-col gap-4",children:(0,i.jsxs)("div",{className:"bg-zinc-50 dark:bg-[#18181b] rounded-xl p-3 border border-zinc-200 dark:border-[#27272a] h-full overflow-y-auto flex flex-col",children:[(0,i.jsx)("h4",{className:"text-[14px] font-medium text-zinc-700 dark:text-zinc-300 mb-4",children:"ìì ¯ 목ë¡"}),(0,i.jsx)("div",{className:"space-y-2 flex-1",children:k.map(e=>{let t=e.id,n=L.includes(t);return(0,i.jsxs)("button",{onClick:()=>T(t),"aria-pressed":n,className:(0,u.cn)("w-full flex items-center justify-between py-2 px-3 rounded-md border transition-colors text-sm","bg-white dark:bg-[#18181b] border-zinc-200 dark:border-[#27272a]","hover:border-zinc-300 dark:hover:border-[#3f3f46]",n?"text-zinc-900 dark:text-zinc-100":"text-zinc-400 dark:text-zinc-500"),children:[(0,i.jsxs)("div",{className:"flex items-center gap-3",children:[e.icon,(0,i.jsx)("span",{children:e.label})]}),n?(0,i.jsx)(g.Z,{size:16,className:"shrink-0 text-[#007AFF] dark:text-[#2883DE]"}):(0,i.jsx)(b.Z,{size:16,className:"shrink-0"})]},t)})})]})}),(0,i.jsxs)("div",{ref:p,className:"flex-1 bg-zinc-100 dark:bg-[#18181b] rounded-xl border border-zinc-200 dark:border-[#27272a] overflow-hidden relative",children:[(0,i.jsx)("div",{className:"absolute inset-0 overflow-y-auto custom-scrollbar p-6 flex flex-col items-center",children:(0,i.jsx)("div",{style:{width:1200*y,height:B*y,position:"relative",transition:"width 0.2s, height 0.2s"},children:(0,i.jsx)("div",{className:"transform origin-top-left transition-transform",style:{width:"1200px",transform:"scale(".concat(y,")")},children:(0,i.jsx)(l.Z,{data:w,isEditing:!0,customLayouts:M,customVisibleWidgets:L,onLayoutChangeOverride:e=>{C(e),D(!0)},onRemoveWidget:T,transformScale:y})})})}),0===L.length&&(0,i.jsx)("div",{className:"absolute inset-0 flex items-center justify-center pointer-events-none",children:(0,i.jsxs)("div",{className:"text-center text-[13px] text-zinc-500",children:["ëìë³´ëì ì¬ë¦° ìì ¯ì´ ììµëë¤.",(0,i.jsx)("br",{}),"ì¼ìª½ 목ë¡ìì ìì ¯ì ëë¬ ì¶ê°íì¸ì."]})})]})]})]})}function j(){return(0,i.jsx)("div",{className:"h-full flex flex-col",children:(0,i.jsx)("div",{className:"flex-1 min-h-0",children:(0,i.jsx)(y,{})})})}},25997:function(e,t,n){n.d(t,{Y:function(){return a},x:function(){return l}});var i=n(57437),r=n(2265),s=n(76245);let o=(0,r.createContext)(void 0);function l(e){let{children:t}=e,[n,l]=(0,r.useState)(!1),[a,d]=(0,r.useState)("general"),[c,u]=(0,r.useState)(void 0),[h,f]=(0,r.useState)({}),m=(0,r.useRef)(void 0),x=()=>{l(!1),f({}),m.current&&(m.current(),m.current=void 0)};return(0,i.jsxs)(o.Provider,{value:{openSettings:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"general",t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0;d(e),u(t),f(n||{}),m.current=null==n?void 0:n.onClose,l(!0)},closeSettings:x,isOpen:n},children:[t,(0,i.jsx)(s.T,{isOpen:n,onClose:x,defaultTab:a,studentId:c,autoAddClass:h.autoAddClass})]})}function a(){let e=(0,r.useContext)(o);if(void 0===e)throw Error("useSettingsModal must be used within a SettingsModalProvider");return e}},36013:function(e,t,n){n.d(t,{b:function(){return i},o:function(){return r}});let i="2026-03-12",r=()=>new Date("".concat(i,"T12:00:00"))},82941:function(e,t,n){n.d(t,{Wk:function(){return i}});function i(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:16,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:64,r=t-i;return r<=n||e.bottom-e.top>r-n?0:e.bottom>r?e.bottom-r:e.top<n?e.top-n:0}},8345:function(e,t,n){n.d(t,{Y:function(){return s},l:function(){return r}});let i=new WeakSet;function r(e){i.add(e)}function s(e){return i.has(e)}},21652:function(e,t,n){n.d(t,{RS:function(){return i},UM:function(){return r},nX:function(){return s}});let i="(max-width: ".concat(599,"px), (max-height: ").concat(599,"px) and (max-width: ").concat(1023,"px) and (hover: none)");function r(){var e,t,n;let i=!1;if("function"==typeof window.matchMedia)try{i=window.matchMedia("(hover: hover)").matches}catch(e){i=!1}return e=window.innerWidth,t=window.innerHeight,n=i,e<=599||!n&&t<=599&&e<=1023}function s(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"undefined"==typeof navigator?{}:navigator,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.matchMedia.bind(window);if(!0===e.standalone)return!0;
1if(!t)return!1;try{return["standalone","fullscreen","minimal-ui"].some(e=>t("(display-mode: ".concat(e,")")).matches)}catch(e){return!1}}},16338:function(e,t,n){n.d(t,{o:function(){return l}});var i=n(3011),r=n(89134),s=n(83008);let o=null,l=(0,i.U)()((0,r.tJ)((e,t)=>({title:"ì²´í¬ë¦¬ì¤í¸",items:[],isLoaded:!1,isLoading:!1,syncWithDB:async e=>{var n;if((null==e?void 0:null===(n=e.user)||void 0===n?void 0:n.id)&&"teacher-1"!==e.user.id){if(!t().isLoaded){console.warn("[checklist] ìë²ìì ìì§ ë¶ë¬ì¤ì§ ëª»í´ ì ì¥ì ë³´ë¥í©ëë¤.");return}o&&clearTimeout(o),o=setTimeout(async()=>{o=null;let{title:n,items:i}=t();try{await (0,s.X)("saveChecklist",{title:n,items:i},e)}catch(e){console.error("Failed to sync checklist with DB:",e)}},700)}},flushSync:async e=>{var n;if(!(null==e?void 0:null===(n=e.user)||void 0===n?void 0:n.id)||"teacher-1"===e.user.id||!t().isLoaded||!o)return;clearTimeout(o),o=null;let{title:i,items:r}=t();try{await (0,s.X)("saveChecklist",{title:i,items:r},e)}catch(e){console.error("Failed to flush checklist to DB:",e)}},loadFromDB:async n=>{if(n&&"teacher-1"!==n.user.id&&!t().isLoading&&!t().isLoaded){e({isLoading:!0});try{let t=await (0,s.X)("getChecklist",{},n);t.success?t.data?e({title:t.data.title||"ì²´í¬ë¦¬ì¤í¸",items:t.data.items||[],isLoaded:!0,isLoading:!1}):e({isLoaded:!0,isLoading:!1}):(console.warn("[checklist] load failed, keeping local data:",t.message||t.error),e({isLoading:!1}))}catch(t){console.error("Failed to load checklist from DB:",t),e({isLoading:!1})}}},setTitle:(n,i)=>{e({title:n}),t().syncWithDB(i)},addItem:function(n){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=crypto.randomUUID();return e(e=>({items:[...e.items,{id:r,text:i,checked:!1}]})),t().syncWithDB(n),r},updateItem:(n,i,r)=>{e(e=>({items:e.items.map(e=>e.id===n?{...e,text:i}:e)})),t().syncWithDB(r)},toggleItem:(n,i)=>{e(e=>({items:e.items.map(e=>e.id===n?{...e,checked:!e.checked}:e)})),t().syncWithDB(i)},deleteItem:(n,i)=>{e(e=>({items:e.items.filter(e=>e.id!==n)})),t().syncWithDB(i)},reorderItems:(n,i)=>{e({items:n}),t().syncWithDB(i)},clearItems:()=>{o&&(clearTimeout(o),o=null),e({items:[],isLoaded:!1,isLoading:!1})}}),{name:"checklist-storage-v1",partialize:e=>({title:e.title,items:e.items})}))},86267:function(e,t,n){n.d(t,{X:function(){return o}});var i=n(3011),r=n(89134),s=n(83008);let o=(0,i.U)()((0,r.tJ)((e,t)=>({linkedNotes:[],targetNoteId:null,isLoaded:!1,syncWithDB:async()=>{if(!t().isLoaded){console.warn("[workNoteShortcut] ìë²ìì ìì§ ë¶ë¬ì¤ì§ ëª»í´ ì ì¥ì ë³´ë¥í©ëë¤.");return}let{linkedNotes:e}=t();try{await (0,s.X)("saveWorkNoteShortcut",{linkedNotes:e},{user:{id:"",name:"",role:""}})}catch(e){console.error("Failed to sync work note shortcuts with DB:",e)}},loadFromDB:async()=>{try{let r=await (0,s.X)("getWorkNoteShortcut",{},{user:{id:"",name:"",role:""}});if(r.success){var n,i;e({linkedNotes:null!==(i=null===(n=r.data)||void 0===n?void 0:n.linkedNotes)&&void 0!==i?i:t().linkedNotes,isLoaded:!0})}else console.warn("[workNoteShortcut] ë¶ë¬ì¤ê¸° ì¤í¨, ì´ ê¸°ê¸° ë°ì´í°ë¥¼ ì ì§í©ëë¤.")}catch(e){console.error("Failed to load work note shortcuts from DB:",e)}},addLinkedNote:(n,i)=>{e(e=>e.linkedNotes.some(e=>e.id===n)?e:{linkedNotes:[...e.linkedNotes,{id:n,title:i}]}),t().syncWithDB()},removeLinkedNote:n=>{e(e=>({linkedNotes:e.linkedNotes.filter(e=>e.id!==n)})),t().syncWithDB()},setTargetNoteId:t=>e({targetNoteId:t}),clearTargetNoteId:()=>e({targetNoteId:null}),clear:()=>e({linkedNotes:[],targetNoteId:null,isLoaded:!1})}),{name:"work-note-shortcut-v2",partialize:e=>({linkedNotes:e.linkedNotes})}))}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.