1import{G as I,j as e,P as S,e as c,lO as p,L as d,T as i,R as k,g3 as L,aH as M,n as u,y as P,b as w,c as _,lP as z,t as G,x as A,fz as T,dz as y,d as O,j5 as R,aP as B,X as h,a9 as H,cL as D,dL as V,o as q,p as E,w as F,fn as Y,r as $,gX as K,B as b,lz as j,aq as g,bk as Q,M as W}from"./index-aREvobyF.js";import{T as Z}from"./teacher-female-with-pencil-hMjmoM9x.js";import{E as X}from"./EmptyResource-BpXdf03_.js";import{P as N}from"./PageMetaHeader-6lUw-EYb.js";import{A as U}from"./AiRecordAssistantIcon-zoFZssO_.js";import{a as J,L as ee}from"./link-box-DcUyRFYn.js";import{A as re,f as te,a as se,b as oe,c as ae,d as ie,e as le}from"./accordion-CzJ6Bxtx.js";try{let r=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new r.Error().stack;t&&(r._sentryDebugIds=r._sentryDebugIds||{},r._sentryDebugIds[t]="16ecb58f-e35c-43f9-a987-0aabf32ff04c",r._sentryDebugIdIdentifier="sentry-dbid-16ecb58f-e35c-43f9-a987-0aabf32ff04c")}catch{}const ne=I({displayName:"EditSquareIcon",viewBox:"0 0 21 20",defaultProps:{width:21,height:20},path:e.jsx("path",{d:"M4.17052 17.4481C3.74955 17.4481 3.39323 17.3023 3.101
156 17.0106C2.8099 16.7189 2.66406 16.3626 2.66406 15.9416V4.78789C2.66406 4.36692 2.8099 4.0106 3.10156 3.71893C3.39323 3.42727 3.74955 3.28143 4.17052 3.28143H11.3836L10.1336 4.53143H4.17052C4.10635 4.53143 4.0476 4.55817 3.99427 4.61164C3.9408 4.66497 3.91406 4.72372 3.91406 4.78789V15.9416C3.91406 16.0058 3.9408 16.0646 3.99427 16.1179C4.0476 16.1714 4.10635 16.1981 4.17052 16.1981H15.3243C15.3884 16.1981 15.4472 16.1714 15.5005 16.1179C15.554 16.0646 15.5807 16.0058 15.5807 15.9416V9.9256L16.8307 8.6756V15.9416C16.8307 16.3626 16.6849 16.7189 16.3932 17.0106C16.1016 17.3023 15.7452 17.4481 15.3243 17.4481H4.17052ZM7.66406 12.4481V9.58747L15.2139 2.03789C15.343 1.90858 15.4851 1.81428 15.6401 1.75497C15.795 1.69567 15.9525 1.66602 16.1128 1.66602C16.2763 1.66602 16.4333 1.69567 16.5839 1.75497C16.7345 1.81428 16.8718 1.90588 16.9957 2.02976L18.0422 3.0731C18.1629 3.2024 18.2556 3.34504 18.3203 3.50101C18.3849 3.65699 18.4172 3.81511 18.4172 3.97539C18.4172 4.13567 18.3897 4.29108 18.3347 4.44164C18.2797 4.59233 18.1875 4.73227 18.0582 4.86143L10.4845 12.4481H7.66406ZM8.91406 11.1981H9.9526L15.1464 6.00414L14.6272 5.48497L14.0711 4.94977L8.91406 10.1068V11.1981Z",fill:"currentColor"})}),ce=({group:r})=>r.members_with_story_count>0?e.jsxs(M,{flexDirection:"row",variant:"outline",width:"100%",gap:"0.75rem",children:[e.jsx(u,{asChild:!0,colorPalette:"gray",flexGrow:1,height:"3rem",borderRadius:"0.5rem",borderColor:"border.emphasized",_hover:{backgroundColor:"gray.50",outline:"0.5px solid",outlineColor:"gray.500",outlineOffset:0},children:e.jsxs(d,{to:`${r.key}/story`,children:[e.jsx(c,{as:p,boxSize:5,mr:"0.5rem"}),e.jsx(i,{textStyle:"b3-medium-compact",children:"í¤ìë ë° ì¼í ì ë ¥"})]})}),e.jsx(u,{asChild:!0,colorPalette:"gray",flexGrow:1,height:"3rem",borderRadius:"0.5rem",borderColor:"border.emphasized",_hover:{backgroundColor:"gray.50",outline:"0.5px solid",outlineColor:"gray.500",outlineOffset:0},children:e.jsxs(d,{to:`${r.key}/generate`,children:[e.jsx(c,{as:U,boxSize:5,mr:"0.5rem"}),e.jsx(i,{textStyle:"b3-medium-compact",children:"AI ê¸°ë¡ ìì±"})]})}),e.jsx(u,{asChild:!0,colorPalette:"blue",flexGrow:1,height:"3rem",borderRadius:"0.5rem",_hover:{outline:"0.5px solid",outlineColor:"blue.500",outlineOffset:0},children:e.jsxs(d,{to:`${r.key}/record`,children:[e.jsx(c,{as:ne,boxSize:5,mr:"0.5rem"}),e.jsx(i,{textStyle:"b3-medium-compact",children:"ê¸°ë¡ í¸ì§"})]})})]}):e.jsxs(J,{as:S,backgroundColor:"blue.50",width:"100%",height:"3rem",px:"1.25rem",py:"0.75rem",borderRadius:"0.5rem",children:[e.jsx(c,{as:p,boxSize:5,color:"blue.500"}),e.jsx(ee,{asChild:!0,children:e.jsx(d,{to:`${r.key}/story`,children:e.jsx(i,{textStyle:"b3-medium-compact",color:"blue.500",children:"í¤ìë ë° ì¼í ì ë ¥ í íëí¹ì± ë° ì¢ í©ì견 ê¸°ë¡ ì´ìì ìì±í ì ììµëë¤."})})}),e.jsx(k,{}),e.jsx(c,{as:L,boxSize:6,color:"blue.500"})]}),de=({group:r})=>{const t=P(),a=w(),{mutate:n}=_({mutationFn:({groupKey:o})=>z.appsActivityCharactersApiActivityCharacterGroupDelete({groupKey:o}),onSuccess:()=>{G.create({title:"ê·¸ë£¹ì´ ìì ëììµëë¤.",type:"success"}),t.invalidateQueries({queryKey:A.activityCharacters.group._ctx.list._def})}});return e.jsxs(e.Fragment,{children:[e.jsxs(T,{triggerProps:{asChild:!0},trigger:e.jsx(O,{variant:"ghost",colorPalette:"gray",color:"gray.500",size:"sm",fontSize:"1.25rem",_hover:{backgroundColor:"gray.100"},onClick:o=>{o.stopPropagation()},children:e.jsx(R,{})}),contentProps:{minWidth:0,width:"7.5rem",zIndex:10,css:{"& > a:focus,button:focus":{backgroundColor:"unset",color:"blue.500"}}},children:[e.jsx(y,{asChild:!0,value:"group-update",children:e.jsx(d,{to:`${r.key}/update`,children:e.jsx(i,{width:"100%",textAlign:"center",children:"그룹 ìì "})})}),e.jsx(y,{value:"delete-group",onClick:o=>{o.stopPropagation(),a.onOpen()},children:e.jsx(i,{width:"100%",textAlign:"center",children:"그룹 ìì "})})]}),e.jsx(B,{modalType:"negative",trigger:a,title:`${r.name}ì ìì íìê² ìµëê¹?`,description:`ê´ë ¨ ë°ì´í°ê° 모ë ìì ëë©° 2ë³µêµ¬ê° ë¶ê°ë¥í©ëë¤.`,confirmButton:{label:"ìì ",onConfirm:()=>{n({groupKey:r.key}),a.onClose()}}})]})},C=({group:r,year:t,isPast:a})=>{const{open:n,onToggle:o}=w();return e.jsxs(h,{width:"100%",gap:0,borderRadius:"0.75rem",border:"1px solid",borderColor:"gray.200",px:"1.25rem",py:"1.25rem",align:"start",backgroundColor:"white",_hover:{cursor:"pointer",borderColor:"blue.500"},...n&&{borderColor:"blue.500"},onClick:o,children:[e.jsxs(S,{width:"100%",gap:"0.75rem",children:[e.jsxs(H,{
2colorPalette:a?"gray":"blue",children:[t,"ë ë"]}),e.jsx(i,{textStyle:"b1-medium-compact",color:"black.400",children:r.name}),e.jsx(k,{}),e.jsxs(i,{textStyle:"b3-medium-compact",color:"black.200",children:[D(r.created_at,V)," ìì±"]}),e.jsx(de,{group:r})]}),n&&e.jsxs(e.Fragment,{children:[e.jsx(q,{w:"full",my:"1.25rem",borderColor:"gray.200"}),e.jsx(ce,{group:r})]})]})},je=()=>{const{year:r}=E(),{data:t}=F({...A.activityCharacters.group._ctx.list()}),{data:a}=Y(),{currentYearGroups:n,pastYearsGroups:o}=$.useMemo(()=>({currentYearGroups:(t??[]).filter(s=>s.year===r),pastYearsGroups:(t??[]).filter(s=>s.year<r).reduce((s,l)=>({...s,[l.year]:[...s[l.year]??[],l]}),{})}),[r,t]),{requestTeacherAuthModalController:{onOpen:v}}=K();return a!=null&&a.is_unauthorized_teacher?e.jsx(f,{children:e.jsx(b,{alignSelf:"start",children:e.jsxs(u,{circle:!0,onClick:v,children:[e.jsx(c,{as:j,boxSize:5}),"그룹 ë§ë¤ê¸°"]})})}):e.jsxs(f,{children:[e.jsx(b,{alignSelf:"start",children:e.jsx(u,{asChild:!0,circle:!0,shadow:"core-action",children:e.jsxs(d,{to:"create",children:[e.jsx(c,{as:j,boxSize:5}),"그룹 ë§ë¤ê¸°"]})})}),t&&t.length===0&&e.jsx(X,{image:Z,title:"기ë¡ì ìì±í 그룹ì ìì±í´ì£¼ì¸ì.",description:"그룹 ë§ë¤ê¸° ë²í¼ì í´ë¦íì¸ì."}),n.length>0&&e.jsxs(h,{width:"100%",mt:"1.5rem",children:[e.jsxs(g,{as:"h3",textStyle:"b1-medium-compact",alignSelf:"start",children:[r,"ë ë"]}),n.map(s=>e.jsx(C,{group:s,year:r},s.key))]}),Object.keys(o).length>0&&e.jsx(re,{collapsible:!0,mt:"1.5rem",children:e.jsx(te,{children:s=>e.jsxs(se,{value:"0",border:0,children:[e.jsxs(oe,{width:"fit-content",px:0,children:[e.jsxs(i,{textStyle:"b1-medium-compact",color:"black.400",mr:1,children:["ì´ì íë ë ",s.value.length>0?"ì 기":"보기"]}),e.jsx(ae,{})]}),e.jsx(ie,{px:0,pb:"1rem",children:e.jsx(le,{children:Object.entries(o).sort(([l],[x])=>l>x?-1:1).map(([l,x])=>e.jsxs(h,{width:"100%",mt:"1rem",children:[e.jsxs(g,{as:"h4",textStyle:"t4-semibold-compact",alignSelf:"start",children:[l,"ë ë"]}),x.map(m=>e.jsx(C,{isPast:!0,group:m,year:m.year},m.key))]},l))})})]})})})]})},f=({children:r})=>(Q(),e.jsx(h,{width:"100%",height:"100%",gap:0,flex:1,pb:"2rem",px:0,children:e.jsxs(h,{width:"100%",maxWidth:W,px:"1.5rem",gap:0,children:[e.jsx(N,{title:"íëí¹ì± ë° ì¢ í©ì견 ì§ì",description:"AI Assistantê° íëí¹ì± ë° ì¢ í©ì견 ê¸°ë¡ ìì±ì ëìëë ¤ì! ë¨, AI ìì± ê²°ê³¼ë íì ì ìëì ìµì¢ íì¸ì´ íìí©ëë¤."}),r]})}));export{je as default}; 3//# sourceMappingURL=GroupListPage-DF7IodCQ.js.map
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.