@chorus-aidlc/chorus 0.9.0 → 0.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.next/standalone/.next/BUILD_ID +1 -1
- package/.next/standalone/.next/app-build-manifest.json +269 -269
- package/.next/standalone/.next/app-path-routes-manifest.json +32 -32
- package/.next/standalone/.next/build-manifest.json +5 -5
- package/.next/standalone/.next/prerender-manifest.json +38 -38
- package/.next/standalone/.next/server/app/(dashboard)/project-groups/[uuid]/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/project-groups/[uuid]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/project-groups/[uuid]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/activity/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/activity/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/activity/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/[ideaUuid]/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/[ideaUuid]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/[ideaUuid]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/page.js +2 -2
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/[documentUuid]/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/[documentUuid]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/[documentUuid]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/ideas/[ideaUuid]/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/ideas/[ideaUuid]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/ideas/[ideaUuid]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/ideas/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/ideas/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/ideas/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/[proposalUuid]/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/[proposalUuid]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/[proposalUuid]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/new/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/new/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/new/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/[taskUuid]/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/[taskUuid]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/[taskUuid]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/page.js +3 -3
- package/.next/standalone/.next/server/app/(dashboard)/projects/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/projects/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/settings/page.js +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/settings/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/(dashboard)/settings/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_not-found.html +1 -1
- package/.next/standalone/.next/server/app/_not-found.rsc +2 -2
- package/.next/standalone/.next/server/app/admin/companies/[uuid]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/admin/companies/new/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/admin/companies/new.html +1 -1
- package/.next/standalone/.next/server/app/admin/companies/new.rsc +2 -2
- package/.next/standalone/.next/server/app/admin/companies/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/admin/companies.html +1 -1
- package/.next/standalone/.next/server/app/admin/companies.rsc +2 -2
- package/.next/standalone/.next/server/app/admin/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/admin.html +1 -1
- package/.next/standalone/.next/server/app/admin.rsc +2 -2
- package/.next/standalone/.next/server/app/api/admin/companies/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/admin/companies/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/admin/login/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/admin/session/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/agents/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/agents/[uuid]/sessions/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/agents/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/api-keys/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/api-keys/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/callback/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/check-default/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/company-oidc/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/default-login/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/identify/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/logout/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/me/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/refresh/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/session/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/auth/sync-token/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/comments/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/documents/[uuid]/route.js +1 -1
- package/.next/standalone/.next/server/app/api/documents/[uuid]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/documents/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/events/notifications/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/events/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/health/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/ideas/[uuid]/claim/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/ideas/[uuid]/move/preview/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/ideas/[uuid]/move/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/ideas/[uuid]/release/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/ideas/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/mcp/route.js +1 -1
- package/.next/standalone/.next/server/app/api/mcp/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/me/assignments/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/mentionables/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/notifications/[uuid]/archive/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/notifications/[uuid]/read/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/notifications/preferences/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/notifications/read-all/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/notifications/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/notifications/unread-count/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/project-groups/[uuid]/dashboard/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/project-groups/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/project-groups/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/activity/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/available/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/documents/route.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/documents/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/group/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/ideas/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/ideas/tracker/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/proposals/[proposalUuid]/validate/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/proposals/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/proposals/summary/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/stats/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/tasks/dependencies/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/[uuid]/tasks/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/projects/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/proposals/[uuid]/approve/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/proposals/[uuid]/close/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/proposals/[uuid]/reject/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/proposals/[uuid]/revoke/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/proposals/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/search/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/sessions/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tasks/[uuid]/claim/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tasks/[uuid]/dependencies/[dependsOnUuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tasks/[uuid]/dependencies/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tasks/[uuid]/release/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tasks/[uuid]/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/api/tasks/[uuid]/sessions/route_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/index.html +1 -1
- package/.next/standalone/.next/server/app/index.rsc +2 -2
- package/.next/standalone/.next/server/app/login/admin/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/login/admin.html +1 -1
- package/.next/standalone/.next/server/app/login/admin.rsc +2 -2
- package/.next/standalone/.next/server/app/login/callback/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/login/callback.html +1 -1
- package/.next/standalone/.next/server/app/login/callback.rsc +2 -2
- package/.next/standalone/.next/server/app/login/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/login/pick-workspace/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/login/pick-workspace.html +1 -1
- package/.next/standalone/.next/server/app/login/pick-workspace.rsc +2 -2
- package/.next/standalone/.next/server/app/login/silent-refresh/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/login/silent-refresh.html +1 -1
- package/.next/standalone/.next/server/app/login/silent-refresh.rsc +2 -2
- package/.next/standalone/.next/server/app/login.html +1 -1
- package/.next/standalone/.next/server/app/login.rsc +2 -2
- package/.next/standalone/.next/server/app/onboarding/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/onboarding.html +1 -1
- package/.next/standalone/.next/server/app/onboarding.rsc +2 -2
- package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/projects.html +1 -1
- package/.next/standalone/.next/server/app/projects.rsc +4 -4
- package/.next/standalone/.next/server/app/settings.html +1 -1
- package/.next/standalone/.next/server/app/settings.rsc +3 -3
- package/.next/standalone/.next/server/app-paths-manifest.json +32 -32
- package/.next/standalone/.next/server/chunks/162.js +16 -0
- package/.next/standalone/.next/server/chunks/2961.js +1 -1
- package/.next/standalone/.next/server/chunks/4090.js +2 -2
- package/.next/standalone/.next/server/chunks/6113.js +1 -1
- package/.next/standalone/.next/server/chunks/6207.js +1 -1
- package/.next/standalone/.next/server/chunks/6592.js +1 -1
- package/.next/standalone/.next/server/chunks/6643.js +1 -1
- package/.next/standalone/.next/server/chunks/7368.js +1 -1
- package/.next/standalone/.next/server/chunks/8637.js +1 -1
- package/.next/standalone/.next/server/chunks/920.js +1 -1
- package/.next/standalone/.next/server/chunks/937.js +1 -1
- package/.next/standalone/.next/server/middleware-build-manifest.js +1 -1
- package/.next/standalone/.next/server/middleware-manifest.json +1 -1
- package/.next/standalone/.next/server/pages/404.html +1 -1
- package/.next/standalone/.next/server/pages/500.html +1 -1
- package/.next/standalone/.next/server/server-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/static/chunks/3853-f94afe2f83089c0d.js +1 -0
- package/.next/standalone/.next/static/chunks/44046-5c0f7f8c0914988a.js +1 -0
- package/.next/standalone/.next/static/chunks/{4860.29e14c631b3a4ed0.js → 4860.60152a625f2a714f.js} +1 -1
- package/.next/standalone/.next/static/chunks/6028-fe4175ea5e6241ed.js +1 -0
- package/.next/standalone/.next/static/chunks/93346-c4468893138daac7.js +1 -0
- package/.next/standalone/.next/static/chunks/{99373.20008a2c9ebbec89.js → 99373.4d93aaaf56fe7819.js} +1 -1
- package/.next/standalone/.next/static/chunks/app/(dashboard)/layout-8409ca03f132910b.js +1 -0
- package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/dashboard/{page-6d49b00568c97056.js → page-7f7a7f654cab4dc3.js} +1 -1
- package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/page-c36345b80cc5bf5c.js +1 -0
- package/.next/standalone/.next/static/chunks/{webpack-3cb38d4d37d2765b.js → webpack-8e0df5e10bc6b98f.js} +1 -1
- package/.next/standalone/.next/static/css/ea3f196c7951f8d6.css +1 -0
- package/.next/standalone/package.json +1 -1
- package/README.md +2 -4
- package/README.zh.md +2 -4
- package/package.json +1 -1
- package/.next/standalone/.next/server/chunks/5869.js +0 -16
- package/.next/standalone/.next/static/chunks/25846-d1c43e3a187a0c82.js +0 -1
- package/.next/standalone/.next/static/chunks/44046-732e5888413d45df.js +0 -1
- package/.next/standalone/.next/static/chunks/6028-0fcaf8b495e9bfc8.js +0 -1
- package/.next/standalone/.next/static/chunks/93346-9258abbb12887208.js +0 -1
- package/.next/standalone/.next/static/chunks/app/(dashboard)/layout-5e2b4f48ec70f0e8.js +0 -1
- package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/page-5326f2b34b200e50.js +0 -1
- package/.next/standalone/.next/static/css/26282a3639f03089.css +0 -1
- /package/.next/standalone/.next/static/{lMRAkQ7TedkdqmIWybcRT → yBxnuARbl0brBJS3_STaI}/_buildManifest.js +0 -0
- /package/.next/standalone/.next/static/{lMRAkQ7TedkdqmIWybcRT → yBxnuARbl0brBJS3_STaI}/_ssgManifest.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[85e3],{5725:(e,t,s)=>{"use strict";s.d(t,{b:()=>d});var a=s(1856),n=s(93367),l=s(90508),i="horizontal",r=["horizontal","vertical"],c=a.forwardRef((e,t)=>{var s;let{decorative:a,orientation:c=i,...d}=e,o=(s=c,r.includes(s))?c:i;return(0,l.jsx)(n.sG.div,{"data-orientation":o,...a?{role:"none"}:{"aria-orientation":"vertical"===o?o:void 0,role:"separator"},...d,ref:t})});c.displayName="Separator";var d=c},7045:(e,t,s)=>{"use strict";s.d(t,{ProjectSettingsModal:()=>v});var a=s(90508),n=s(1856),l=s(23675),i=s(39268),r=s(52309),c=s(85226),d=s(22922),o=s(14554),x=s(88064),u=s(15972),p=s(97438),m=s(84247),h=s(51817),f=s(52217);let g=(0,f.createServerReference)("60cfafb97dee121da111a8fbb6d24763894ee7029a",f.callServer,void 0,f.findSourceMapURL,"updateProjectAction"),j=(0,f.createServerReference)("40cb34bdc4fed2104114738bf7775d107b52ddb319",f.callServer,void 0,f.findSourceMapURL,"deleteProjectAction");function v(e){let{projectUuid:t,projectName:s,projectDescription:f}=e,v=(0,i.c)(),b=(0,l.useRouter)(),[N,A]=(0,n.useState)(!1),[y,C]=(0,n.useState)(s),[w,k]=(0,n.useState)(f||""),[E,F]=(0,n.useState)(!1),[B,S]=(0,n.useState)(!1),D=async()=>{F(!0);let e=await g(t,{name:y,description:w||null});F(!1),e.success&&(A(!1),b.refresh())},_=async()=>{S(!0);let e=await j(t);e&&!e.success&&S(!1)};return(0,a.jsxs)(p.lG,{open:N,onOpenChange:A,children:[(0,a.jsx)(p.zM,{asChild:!0,children:(0,a.jsxs)(d.$,{variant:"outline",size:"sm",className:"gap-1.5 rounded-lg border-[#E5E2DC] bg-white text-[12px] font-normal text-[#2C2C2C] hover:border-[#C67A52] hover:bg-white",children:[(0,a.jsx)(r.A,{className:"h-3.5 w-3.5 text-[#6B6B6B]"}),v("dashboard.settings")]})}),(0,a.jsxs)(p.Cf,{className:"gap-0 overflow-hidden rounded-2xl border-0 p-0 sm:max-w-[520px]",children:[(0,a.jsx)(p.c7,{className:"px-7 py-6",children:(0,a.jsx)(p.L3,{className:"text-[20px] font-semibold tracking-tight text-[#2C2C2C]",children:v("projectSettings.title")})}),(0,a.jsx)(m.Separator,{className:"bg-[#E5E2DC]"}),(0,a.jsxs)("div",{className:"flex flex-col gap-7 p-7",children:[(0,a.jsxs)("div",{className:"flex flex-col gap-5",children:[(0,a.jsx)("h3",{className:"text-[14px] font-semibold text-[#2C2C2C]",children:v("projectSettings.basicInfo")}),(0,a.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,a.jsx)(x.J,{className:"text-[12px] font-medium text-[#6B6B6B]",children:v("projectSettings.projectName")}),(0,a.jsx)(o.p,{value:y,onChange:e=>C(e.target.value),className:"h-11 rounded-[10px] border-[#E5E2DC] text-[14px] text-[#2C2C2C] focus-visible:ring-[#C67A52]"})]}),(0,a.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,a.jsx)(x.J,{className:"text-[12px] font-medium text-[#6B6B6B]",children:v("projectSettings.description")}),(0,a.jsx)(u.T,{value:w,onChange:e=>k(e.target.value),rows:3,className:"resize-none rounded-[10px] border-[#E5E2DC] text-[14px] text-[#2C2C2C] focus-visible:ring-[#C67A52]"})]}),(0,a.jsx)(d.$,{onClick:D,disabled:E||!y.trim(),className:"w-fit rounded-[10px] bg-[#C67A52] px-6 text-[13px] font-semibold text-white hover:bg-[#B56A42]",children:E?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.A,{className:"mr-2 h-4 w-4 animate-spin"}),v("projectSettings.saving")]}):v("projectSettings.saveChanges")})]}),(0,a.jsx)(m.Separator,{className:"bg-[#E5E2DC]"}),(0,a.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,a.jsx)("h3",{className:"text-[14px] font-semibold text-[#C4574C]",children:v("projectSettings.dangerZone")}),(0,a.jsx)("div",{className:"rounded-xl border border-[#C4574C40] bg-[#C4574C08] px-[18px] py-4",children:(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,a.jsx)("span",{className:"text-[13px] font-semibold text-[#2C2C2C]",children:v("projectSettings.deleteTitle")}),(0,a.jsx)("span",{className:"text-[12px] text-[#6B6B6B]",children:v("projectSettings.deleteDescription")})]}),(0,a.jsxs)(h.Lt,{children:[(0,a.jsx)(h.tv,{asChild:!0,children:(0,a.jsx)(d.$,{variant:"destructive",size:"sm",className:"ml-4 shrink-0 rounded-lg bg-[#C4574C] px-[18px] text-[12px] font-medium hover:bg-[#B3463B]",children:v("common.delete")})}),(0,a.jsxs)(h.EO,{children:[(0,a.jsxs)(h.wd,{children:[(0,a.jsx)(h.r7,{children:v("projectOverview.deleteProject")}),(0,a.jsx)(h.$v,{children:v("projectOverview.deleteProjectConfirm",{name:s})})]}),(0,a.jsxs)(h.ck,{children:[(0,a.jsx)(h.Zr,{children:v("common.cancel")}),(0,a.jsx)(h.Rx,{variant:"destructive",onClick:_,disabled:B,children:B?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.A,{className:"mr-2 h-4 w-4 animate-spin"}),v("common.delete")]}):v("common.delete")})]})]})]})]})})]})]})]})]})}},9715:(e,t,s)=>{"use strict";s.d(t,{IdeaTracker:()=>eG});var a=s(90508),n=s(39268),l=s(1856),i=s(5616),r=s(22922),c=s(81531),d=s(36755),o=s(29767),x=s(57223),u=s(63964),p=s(17730),m=s(78948),h=s(81750),f=s(96213),g=s(38106);let j={open:"open",researching:"researching",answer_questions:"answerQuestions",planning:"planning",review_proposal:"reviewProposal",building:"building",verify_work:"verifyWork",done:"done",closed:"closed"},v={open:"text-[#888780]",researching:"text-[#7F77DD]",answer_questions:"text-[#C47A20]",planning:"text-[#7F77DD]",review_proposal:"text-[#C47A20]",building:"text-[#7F77DD]",verify_work:"text-[#C47A20]",done:"text-[#1D9E75]",closed:"text-[#888780]"};function b(e){let{idea:t,onClick:s}=e,l=(0,n.c)("ideaTracker"),i=t.badgeHint?j[t.badgeHint]:null,r=t.badgeHint&&v[t.badgeHint]||"text-[#888780]";return(0,a.jsxs)("div",{className:"flex items-center justify-between px-3.5 py-3 transition-colors ".concat(s?"cursor-pointer hover:bg-[#FAF8F4]":""),onClick:s?()=>s(t.uuid):void 0,children:[(0,a.jsxs)("div",{className:"flex min-w-0 items-center gap-2.5",children:[(0,a.jsx)("span",{className:"shrink-0 text-[11px] text-[#B4B2A9]",children:"IDEA"}),(0,a.jsx)("span",{className:"truncate text-[13px] text-[#2C2C2A]",children:t.title}),i&&(0,a.jsx)("span",{className:"shrink-0 rounded bg-[#F0EEEA] px-1.5 py-0.5 text-[11px] ".concat(r),children:l("badge.".concat(i))})]}),(0,a.jsx)("span",{className:"shrink-0 pl-4 text-[12px] text-[#888780]",children:(0,g.s)(t.createdAt)})]})}let N={human_conduct_required:{fill:"#7F77DD"},in_progress:{fill:"#378ADD"},todo:{stroke:"#888780"},done:{fill:"#1D9E75"}},A={todo:"todo",in_progress:"inProgress",human_conduct_required:"humanConductRequired",done:"done"};function y(e){let{status:t,ideas:s,defaultOpen:i=!0,onIdeaClick:r}=e,c=(0,n.c)("ideaTracker"),d=s.length>0,[o,x]=(0,l.useState)(!!d&&i),u=A[t]||"todo",g=N[t]||N.todo;return(0,a.jsxs)(h.Nt,{open:o,onOpenChange:x,children:[(0,a.jsxs)(h.R6,{className:"group flex w-full cursor-pointer items-center gap-2 px-0 pb-1.5 pt-0",children:[o?(0,a.jsx)(p.A,{className:"h-3.5 w-3.5 shrink-0 text-[#888780] transition-colors group-hover:text-[#2C2C2A]"}):(0,a.jsx)(m.A,{className:"h-3.5 w-3.5 shrink-0 text-[#888780] transition-colors group-hover:text-[#2C2C2A]"}),(0,a.jsx)("span",{className:"h-2 w-2 shrink-0 rounded-full",style:{backgroundColor:g.fill,border:g.stroke?"1.5px solid ".concat(g.stroke):void 0}}),(0,a.jsx)("span",{className:"text-[13px] font-medium transition-colors group-hover:text-[#2C2C2A] ".concat(d?"text-[#5F5E5A]":"text-[#B4B2A9]"),children:c("status.".concat(u))}),(0,a.jsx)("span",{className:"text-[12px] text-[#888780] transition-colors group-hover:text-[#2C2C2A]",children:s.length})]}),d&&(0,a.jsx)(h.Ke,{children:(0,a.jsx)("div",{className:"overflow-hidden rounded-lg bg-white",children:s.map((e,t)=>(0,a.jsxs)("div",{children:[t>0&&(0,a.jsx)("div",{className:"mx-0 h-px bg-[#F0EEEA]"}),(0,a.jsx)(f.D,{entityType:"idea",entityUuid:e.uuid,badgeInside:!0,children:(0,a.jsx)(b,{idea:e,onClick:r})})]},e.uuid))})})]})}let C=["human_conduct_required","in_progress","todo","done"];function w(e){var t;let{projectUuid:s,initialData:c,onIdeaClick:p,onNewIdea:m,onEmptyChange:h}=e,f=(0,n.c)("ideaTracker"),[g,j]=(0,l.useState)(null!=(t=null==c?void 0:c.groups)?t:{}),[v,b]=(0,l.useState)(!c),[N,A]=(0,l.useState)(null),w=(0,l.useCallback)(async()=>{try{let e=await fetch("/api/projects/".concat(s,"/ideas/tracker")),t=await e.json();t.success&&t.data?(j(t.data.groups),A(null)):A(t.error||f("error.loadFailed"))}catch(e){A(f("error.loadFailed"))}finally{b(!1)}},[s,f]);(0,u.eV)("idea",w),(0,u.eV)("proposal",w),(0,u.eV)("task",w),(0,l.useEffect)(()=>{c||w()},[w,c]);let k=C.reduce((e,t)=>e+(g[t]||[]).length,0);return((0,l.useEffect)(()=>{v||null==h||h(0===k)},[k,v,h]),v)?(0,a.jsx)("div",{className:"space-y-4",children:[1,2,3].map(e=>(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(x.E,{className:"h-5 w-32"}),(0,a.jsx)(x.E,{className:"h-12 w-full rounded-lg"}),(0,a.jsx)(x.E,{className:"h-12 w-full rounded-lg"})]},e))}):N&&0===Object.keys(g).length?(0,a.jsxs)("div",{className:"flex flex-col items-center gap-4 py-16",children:[(0,a.jsx)(d.A,{className:"h-10 w-10 text-[#E65100]"}),(0,a.jsx)("p",{className:"text-[13px] text-[#6B6B6B]",children:N}),(0,a.jsx)(r.$,{variant:"outline",size:"sm",onClick:()=>{b(!0),A(null),w()},className:"border-[#E5E0D8] text-[#2C2C2C]",children:f("actions.retry")})]}):0===k?(0,a.jsxs)("div",{className:"flex min-h-[60vh] flex-col items-center justify-center gap-3",children:[(0,a.jsx)("div",{className:"flex h-12 w-12 items-center justify-center rounded-full bg-[#F5F2EC]",children:(0,a.jsx)(o.A,{className:"h-5 w-5 text-[#B4B2A9]"})}),(0,a.jsx)("p",{className:"text-[13px] font-medium text-[#6B6B6B]",children:f("empty.noIdeas")}),(0,a.jsx)("p",{className:"max-w-[260px] text-center text-[12px] leading-relaxed text-[#9A9A9A]",children:f("empty.getStarted")}),m&&(0,a.jsxs)(r.$,{onClick:m,size:"sm",className:"mt-2 gap-1.5 rounded-md bg-[#C67A52] px-4 py-2 text-white hover:bg-[#B56A42]",children:[(0,a.jsx)(i.A,{className:"h-4 w-4"}),f("actions.newIdea")]})]}):(0,a.jsxs)("div",{className:"space-y-4",children:[N&&Object.keys(g).length>0&&(0,a.jsx)("div",{className:"rounded-lg bg-destructive/10 px-3 py-2 text-[12px] text-destructive",children:N}),(0,a.jsx)("div",{className:"space-y-4",children:C.map(e=>{let t=g[e]||[];return 0===t.length?null:(0,a.jsx)(y,{status:e,ideas:t,defaultOpen:"done"!==e,onIdeaClick:p},e)})})]})}var k=s(12790),E=s.n(k),F=s(48416),B=s(90795),S=s(85226),D=s(18789),_=s(71921),T=s(56770);let U=[{key:"todo",bg:"#E65100"},{key:"inProgress",bg:"#5A9E6F"},{key:"toVerify",bg:"#7B1FA2"},{key:"done",bg:"#00796B"}],M={idea:"bg-[#C67A52]",task:"bg-[#5A9E6F]",proposal:"bg-[#1976D2]",document:"bg-[#9A9A9A]"};function R(e){let{projectUuid:t,initialData:s}=e,i=(0,n.c)(),r=(0,n.c)("ideaTracker"),[c,d]=(0,l.useState)(null!=s?s:null),[x,p]=(0,l.useState)(!s),m=(0,l.useCallback)(async()=>{try{let e=await fetch("/api/projects/".concat(t,"/stats"));if(!e.ok)return;let s=await e.json();s.success&&d(s.data)}finally{p(!1)}},[t]);if((0,l.useEffect)(()=>{s||m()},[m,s]),(0,u.eV)(["idea","task","proposal","document"],m),x)return(0,a.jsx)("div",{className:"flex items-center justify-center py-20",children:(0,a.jsx)(S.A,{className:"h-6 w-6 animate-spin text-[#9A9A9A]"})});if(!c)return null;let{stats:h,recentActivities:f}=c,g=[{label:r("stats.totalIdeas"),value:h.ideas.total,badge:h.ideas.open>0?r("stats.openCount",{count:h.ideas.open}):null,badgeStyle:"bg-[#C67A5220] text-[#C67A52]",href:"/projects/".concat(t,"/ideas"),iconBg:"bg-[#FFF3E0]",icon:(0,a.jsx)(o.A,{className:"h-5 w-5 text-[#E65100]"})},{label:r("stats.totalTasks"),value:h.tasks.total,badge:h.tasks.inProgress>0?r("stats.activeCount",{count:h.tasks.inProgress}):null,badgeStyle:"bg-[#5A9E6F20] text-[#5A9E6F]",href:"/projects/".concat(t,"/tasks"),iconBg:"bg-[#E3F2FD]",icon:(0,a.jsx)(D.A,{className:"h-5 w-5 text-[#1976D2]"})},{label:r("stats.totalProposals"),value:h.proposals.total,badge:h.proposals.pending>0?r("stats.pendingCount",{count:h.proposals.pending}):null,badgeStyle:"bg-[#C67A5220] text-[#C67A52]",href:"/projects/".concat(t,"/proposals"),iconBg:"bg-[#F3E5F5]",icon:(0,a.jsx)(_.A,{className:"h-5 w-5 text-[#7B1FA2]"})},{label:r("stats.totalDocuments"),value:h.documents.total,badge:null,badgeStyle:"",href:"/projects/".concat(t,"/documents"),iconBg:"bg-[#E8F5E9]",icon:(0,a.jsx)(T.A,{className:"h-5 w-5 text-[#5A9E6F]"})}],j=[h.tasks.todo,h.tasks.inProgress,h.tasks.toVerify,h.tasks.done],v=h.tasks.total,b=[{label:r("stats.todoCount",{count:h.tasks.todo}),color:"#E65100"},{label:r("stats.inProgressCount",{count:h.tasks.inProgress}),color:"#5A9E6F"},{label:r("stats.toVerifyCount",{count:h.tasks.toVerify}),color:"#7B1FA2"},{label:r("stats.doneCount",{count:h.tasks.done}),color:"#00796B"}];return(0,a.jsxs)("div",{className:"flex flex-col gap-6",children:[(0,a.jsx)("div",{className:"grid grid-cols-2 gap-3 md:gap-4 lg:grid-cols-4",children:g.map(e=>(0,a.jsx)(E(),{href:e.href,children:(0,a.jsxs)(F.Zp,{className:"cursor-pointer rounded-2xl border-0 bg-white p-3 shadow-none transition-all hover:shadow-md md:p-5",children:[(0,a.jsxs)("div",{className:"mb-2 flex items-center justify-between md:mb-3.5",children:[(0,a.jsx)("div",{className:"flex h-8 w-8 items-center justify-center rounded-lg md:h-10 md:w-10 md:rounded-xl ".concat(e.iconBg),children:e.icon}),e.badge&&(0,a.jsx)("span",{className:"hidden rounded-lg px-2.5 py-1 text-[11px] font-medium sm:inline ".concat(e.badgeStyle),children:e.badge})]}),(0,a.jsx)("div",{className:"text-2xl font-semibold leading-none tracking-tight text-[#2C2C2C] md:text-[32px]",children:e.value}),(0,a.jsx)("div",{className:"mt-0.5 text-[12px] text-[#6B6B6B] md:text-[13px]",children:e.label})]})},e.label))}),(0,a.jsxs)("div",{className:"grid min-h-0 gap-5 lg:grid-cols-2",children:[(0,a.jsxs)(F.Zp,{className:"flex flex-col rounded-2xl border-0 bg-white p-6 shadow-none",children:[(0,a.jsxs)("div",{className:"mb-5 flex items-center justify-between",children:[(0,a.jsx)("h2",{className:"text-[16px] font-semibold text-[#2C2C2C]",children:r("stats.taskPipeline")}),(0,a.jsx)("span",{className:"text-[12px] text-[#9A9A9A]",children:r("stats.totalCount",{count:v})})]}),v>0?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"mb-5 flex h-3 w-full overflow-hidden rounded-md",children:j.map((e,t)=>e>0?(0,a.jsx)("div",{className:"h-full",style:{width:"".concat(e/v*100,"%"),backgroundColor:U[t].bg}},U[t].key):null)}),(0,a.jsx)("div",{className:"flex flex-wrap gap-5",children:b.map(e=>(0,a.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,a.jsx)("div",{className:"h-2.5 w-2.5 rounded-sm",style:{backgroundColor:e.color}}),(0,a.jsx)("span",{className:"text-[12px] text-[#6B6B6B]",children:e.label})]},e.color))})]}):(0,a.jsx)("div",{className:"flex flex-1 items-center justify-center py-10 text-[13px] text-[#9A9A9A]",children:r("stats.noTasks")})]}),(0,a.jsxs)(F.Zp,{className:"flex flex-col rounded-2xl border-0 bg-white p-6 shadow-none",children:[(0,a.jsxs)("div",{className:"mb-4 flex items-center justify-between",children:[(0,a.jsx)("h2",{className:"text-[16px] font-semibold text-[#2C2C2C]",children:r("stats.recentActivity")}),(0,a.jsx)(E(),{href:"/projects/".concat(t,"/activity"),className:"text-[12px] font-medium text-[#C67A52] hover:underline",children:r("stats.viewAll")})]}),f.length>0?(0,a.jsx)("div",{className:"flex flex-col",children:f.map((e,t)=>{let s=M[e.targetType]||"bg-[#9A9A9A]";return(0,a.jsxs)("div",{className:"flex items-start gap-3 py-3 ".concat(t<f.length-1?"border-b border-[#F5F2EC]":""),children:[(0,a.jsx)("div",{className:"mt-1.5 h-2 w-2 shrink-0 rounded-full ".concat(s)}),(0,a.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,a.jsxs)("p",{className:"text-[13px] text-[#2C2C2C]",children:[e.actorName," ",e.action]}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:(0,B.fw)(e.createdAt,i)})]})]},e.uuid)})}):(0,a.jsx)("div",{className:"flex flex-1 items-center justify-center py-10 text-[13px] text-[#9A9A9A]",children:r("stats.noActivity")})]})]})]})}var P=s(23675),z=s(95900),I=s(57893),L=s(9160),q=s(94903),$=s(97413),V=s(64993),O=s(57731),H=s(14554),J=s(15972),G=s(88064),K=s(51817),Z=s(5425),Q=s(84247),W=s(26468),X=s(49192),Y=s(97261),ee=s(16544),et=s(65626),es=s(73693);function ea(e){let{assignee:t}=e,s=(0,n.c)("common");return(0,a.jsxs)("div",{children:[(0,a.jsx)(G.J,{className:"text-[11px] font-medium uppercase tracking-wide text-[#9A9A9A]",children:s("assignee")}),(0,a.jsx)("div",{className:"mt-2 flex items-center gap-2.5 rounded-lg bg-[#FAF8F4] p-3",children:t?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(es.eu,{className:"h-7 w-7",children:(0,a.jsx)(es.q5,{className:"agent"===t.type?"bg-[#C67A52] text-white":"bg-[#E5E0D8] text-[#6B6B6B]",children:"agent"===t.type?(0,a.jsx)(Z.A,{className:"h-3.5 w-3.5"}):t.name.charAt(0).toUpperCase()})}),(0,a.jsxs)("div",{children:[(0,a.jsx)("div",{className:"text-sm font-medium text-[#2C2C2C]",children:t.name}),(0,a.jsx)("div",{className:"text-xs text-[#6B6B6B]",children:s("agent"===t.type?"agent":"user")})]})]}):(0,a.jsx)("span",{className:"text-sm text-[#9A9A9A]",children:s("unassigned")})})]})}function en(e){let{idea:t,onRefresh:s}=e,i=(0,n.c)("ideaTracker"),r=(0,n.c)("common"),[c,d]=(0,l.useState)(null),[o,x]=(0,l.useState)(!0),p=(0,l.useCallback)(async()=>{let e=await (0,X.z)(t.uuid);e.success&&e.data&&d(e.data),x(!1)},[t.uuid]);(0,l.useEffect)(()=>{p()},[p]),(0,u.eV)("idea",p);let m=async()=>{await p(),await s()};return o?(0,a.jsx)("div",{className:"flex items-center justify-center py-12",children:(0,a.jsx)(S.A,{className:"h-5 w-5 animate-spin text-[#C67A52]"})}):(0,a.jsxs)(ee.P.div,{variants:et.qG,initial:"initial",animate:"animate",children:[(0,a.jsx)(ea,{assignee:t.assignee}),(0,a.jsx)(Q.Separator,{className:"my-5 bg-[#F5F2EC]"}),c&&c.rounds.length>0?(0,a.jsx)("div",{children:(0,a.jsx)(W.R,{ideaUuid:t.uuid,elaboration:c,onRefresh:m})}):"open"===t.status?(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center gap-3 py-8 text-center",children:[(0,a.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-[#FFF3E0]",children:(0,a.jsx)(Z.A,{className:"h-5 w-5 text-[#E65100]"})}),(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"text-sm font-medium text-[#2C2C2C]",children:i("panel.elaborationNotStarted")}),(0,a.jsx)("p",{className:"mt-1 text-xs text-[#9A9A9A]",children:i("panel.elaborationNotStartedDesc")})]})]}):(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center gap-3 py-8 text-center",children:[(0,a.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-[#E3F2FD]",children:(0,a.jsx)(Z.A,{className:"h-5 w-5 text-[#1976D2]"})}),(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"text-sm font-medium text-[#2C2C2C]",children:i("panel.elaborationWaiting")}),(0,a.jsx)("p",{className:"mt-1 text-xs text-[#9A9A9A]",children:i("panel.elaborationWaitingDesc")})]})]}),t.content&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(Q.Separator,{className:"my-5 bg-[#F5F2EC]"}),(0,a.jsxs)("div",{children:[(0,a.jsx)(G.J,{className:"text-[11px] font-medium uppercase tracking-wide text-[#9A9A9A]",children:r("content")}),(0,a.jsx)("div",{className:"mt-2",children:(0,a.jsx)("div",{className:"prose prose-sm max-w-none text-[13px] leading-relaxed text-[#2C2C2C]",children:(0,a.jsx)(Y.MarkdownContent,{children:t.content})})})]})]})]})}var el=s(37915),ei=s(32470),er=s(47754),ec=s(92745);function ed(e){return e.replace(/\\n/g,"\n")}let eo={prd:"typePrd",tech_design:"typeTechDesign",adr:"typeAdr",spec:"typeSpec",guide:"typeGuide",design:"typeDesign",note:"typeNote",report:"typeReport",other:"typeOther"};var ex=s(52217);let eu=(0,ex.createServerReference)("6069d5893c952546dbbe150e494d758fde93dbba08",ex.callServer,void 0,ex.findSourceMapURL,"getProposalsForIdeaAction"),ep=(0,ex.createServerReference)("6050dd308d7c75c1229578f89c56198c125fd45636",ex.callServer,void 0,ex.findSourceMapURL,"getTasksForProposalAction");var em=s(67712);function eh(e){let{idea:t,projectUuid:s,onTaskClick:i,onDocClick:r,initialProposals:c}=e,d=(0,n.c)("ideaTracker"),[o,x]=(0,l.useState)(null!=c?c:[]),[p,m]=(0,l.useState)(!c),h=(0,l.useCallback)(async()=>{try{let e=await eu(s,t.uuid);if(e.success)return x(e.data),e.data}catch(e){em.q.error("Failed to fetch proposals:",e)}finally{m(!1)}return[]},[s,t.uuid]);(0,l.useEffect)(()=>{c||h()},[h,c]);let f=(0,l.useRef)(o);f.current=o;let{getPresence:g}=(0,er.xQ)();return((0,u.eV)("proposal",async()=>{let e=f.current;for(let l of(await h())){var t,s,a,n;let i=e.find(e=>e.uuid===l.uuid);if(!i)continue;let r=new Set((null!=(t=i.documentDrafts)?t:[]).map(e=>e.uuid)),c=new Set((null!=(s=i.taskDrafts)?s:[]).map(e=>e.uuid)),d=(null!=(a=l.documentDrafts)?a:[]).filter(e=>e.uuid&&!r.has(e.uuid)),o=(null!=(n=l.taskDrafts)?n:[]).filter(e=>e.uuid&&!c.has(e.uuid)),x=[...d.map(e=>e.uuid),...o.map(e=>e.uuid)];if(x.length>0){let e=g("proposal",l.uuid)[0];if(e)for(let t of x)(0,er.fv)({entityType:"proposal",entityUuid:l.uuid,subEntityType:"draft",subEntityUuid:t,agentUuid:e.agentUuid,agentName:e.agentName,action:"mutate"})}}}),p)?(0,a.jsx)("div",{className:"flex items-center justify-center py-12",children:(0,a.jsx)(S.A,{className:"h-5 w-5 animate-spin text-[#C67A52]"})}):0===o.length?(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center gap-3 py-12 text-center",children:[(0,a.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-[#F3E5F5]",children:(0,a.jsx)(_.A,{className:"h-5 w-5 text-[#7B1FA2]"})}),(0,a.jsx)("p",{className:"text-sm text-[#9A9A9A]",children:d("panel.noProposals")})]}):(0,a.jsx)("div",{className:"space-y-5",children:o.map(e=>(0,a.jsx)(eg,{proposal:e,projectUuid:s,onTaskClick:i,onDocClick:r},e.uuid))})}let ef={draft:"bg-[#F5F5F5] text-[#6B6B6B]",pending:"bg-[#FFF3E0] text-[#E65100]",approved:"bg-[#E8F5E9] text-[#5A9E6F]",rejected:"bg-[#FFEBEE] text-[#C4574C]",revised:"bg-[#E3F2FD] text-[#1976D2]",closed:"bg-[#F5F5F5] text-[#9A9A9A]"};function eg(e){let{proposal:t,projectUuid:s,onTaskClick:i,onDocClick:c}=e,d=(0,n.c)("ideaTracker"),o=(0,n.c)(),x=(0,n.c)("proposals"),u=(0,n.c)("tasks"),p=(0,n.c)("documents"),h=t.documentDrafts||[],g=t.taskDrafts||[],[j,v]=(0,l.useState)(new Set),[b,N]=(0,l.useState)("cards"),[A,y]=(0,l.useState)([]),C="approved"===t.status;(0,l.useEffect)(()=>{C&&ep(s,t.uuid).then(e=>{e.success&&y(e.data||[])}).catch(e=>em.q.error("Failed to fetch materialized tasks:",e))},[C,s,t.uuid]);let w=(0,l.useMemo)(()=>{let e=new Map;for(let t of A)e.set(t.title,t);return e},[A]),{dagTasks:k,dagEdges:F,dagHeight:B}=(0,l.useMemo)(()=>{let e=g.map(e=>{let t=w.get(e.title);return{uuid:(null==t?void 0:t.uuid)||e.uuid,title:e.title,status:(null==t?void 0:t.status)||"open",priority:e.priority||"medium"}}),t=[],s=new Map(g.map(e=>[e.uuid,e]));for(let e of g)if(e.dependsOnDraftUuids)for(let a of e.dependsOnDraftUuids){let n=w.get(e.title),l=s.get(a),i=l?w.get(l.title):void 0;t.push({from:(null==n?void 0:n.uuid)||e.uuid,to:(null==i?void 0:i.uuid)||a})}return{dagTasks:e,dagEdges:t,dagHeight:Math.max(350,90*e.length)}},[g,w]),S=C?A.filter(e=>"done"===e.status||"closed"===e.status).length:0;return(0,a.jsxs)("div",{className:"space-y-5",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("h3",{className:"text-[14px] font-semibold text-[#2C2C2C] truncate flex-1",children:t.title}),(0,a.jsx)(O.E,{className:"text-[11px] font-semibold border-0 shrink-0 ".concat(ef[t.status]||""),children:o("status.".concat(t.status))})]}),t.description&&(0,a.jsx)("div",{className:"max-h-[120px] overflow-y-auto text-[13px] leading-relaxed text-[#4A4A4A] prose prose-sm max-w-none [&_h1]:text-sm [&_h2]:text-[13px] [&_h3]:text-xs [&_p]:text-[13px] [&_p]:text-[#4A4A4A] [&_p]:my-1.5 [&_li]:text-[13px] [&_li]:text-[#4A4A4A] [&_ul]:my-1 [&_ol]:my-1 [&_strong]:text-[#2C2C2C]",children:(0,a.jsx)(Y.MarkdownContent,{children:ed(t.description)})}),(0,a.jsxs)(E(),{href:"/projects/".concat(s,"/proposals/").concat(t.uuid),className:"flex items-center gap-1 text-[13px] font-medium text-[#C67A52] hover:underline",children:[d("panel.viewProposal"),(0,a.jsx)(m.A,{className:"h-3.5 w-3.5"})]}),h.length>0&&(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"text-[11px] font-semibold uppercase tracking-[1px] text-[#9A9A9A]",children:x(C?"documents":"documentDrafts")}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:h.length})]}),(0,a.jsx)("div",{className:"space-y-0",children:h.map((e,s)=>(0,a.jsx)(f.D,{entityType:"proposal",entityUuid:t.uuid,subEntityType:"draft",subEntityUuid:e.uuid||"draft-".concat(s),badgeInside:!0,children:(0,a.jsxs)(r.$,{variant:"ghost",className:"w-full justify-start h-auto text-left flex items-center gap-2.5 py-3.5 hover:bg-[#FAF8F4] transition-colors cursor-pointer -mx-1 px-1 rounded-lg",onClick:()=>e.content&&(null==c?void 0:c({title:e.title,type:e.type,content:e.content})),children:[(0,a.jsx)(el.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}),(0,a.jsx)(O.E,{variant:"outline",className:"shrink-0 text-[10px] font-medium border-[#E5E0D8] text-[#6B6B6B] bg-[#F5F2EC] px-2 py-0.5 font-mono",children:p(eo[e.type]||"typeOther")}),(0,a.jsx)("span",{className:"flex-1 min-w-0 text-left text-[13px] text-[#2C2C2A] truncate",children:e.title})]})},e.uuid||s))})]}),(g.length>0||A.length>0)&&(0,a.jsxs)("div",{children:[(0,a.jsxs)("div",{className:"flex items-center justify-between pb-2",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"text-[11px] font-semibold uppercase tracking-[1px] text-[#9A9A9A]",children:x(C?"tasks":"taskDrafts")}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:C&&A.length>0?A.length:g.length})]}),(0,a.jsxs)("span",{className:"text-[12px] text-[#9A9A9A]",children:[S,"/",C&&A.length>0?A.length:g.length]})]}),(0,a.jsx)("div",{className:"-mx-6 border-t border-[#E5E0D8]"}),F.length>0&&(0,a.jsxs)("div",{className:"flex gap-0.5 rounded-lg border border-[#E5E0D8] bg-[#F7F6F3] p-0.5 mt-3 w-fit",children:[(0,a.jsx)(r.$,{variant:"ghost",size:"sm",onClick:()=>N("cards"),className:"rounded-md px-2.5 py-1 h-auto text-[11px] font-medium transition-colors ".concat("cards"===b?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:x("cardsView")}),(0,a.jsx)(r.$,{variant:"ghost",size:"sm",onClick:()=>N("dag"),className:"rounded-md px-2.5 py-1 h-auto text-[11px] font-medium transition-colors ".concat("dag"===b?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:u("dagView")})]}),"cards"===b&&(0,a.jsx)("div",{className:"space-y-0",children:C&&A.length>0?A.map(e=>(0,a.jsx)(f.D,{entityType:"task",entityUuid:e.uuid,badgeInside:!0,children:(0,a.jsx)(eb,{task:{uuid:e.uuid,title:e.title},expanded:!1,onToggle:()=>{},onNavigate:i?()=>i(e.uuid):void 0,taskStatus:e.status})},e.uuid)):g.map((e,s)=>(0,a.jsx)(f.D,{entityType:"proposal",entityUuid:t.uuid,subEntityType:"draft",subEntityUuid:e.uuid,badgeInside:!0,children:(0,a.jsx)(eb,{task:e,expanded:j.has(s),onToggle:()=>{v(e=>{let t=new Set(e);return t.has(s)?t.delete(s):t.add(s),t})}})},e.uuid))}),"dag"===b&&(0,a.jsx)("div",{className:"mt-3",children:(0,a.jsx)(ec._u,{tasks:k,edges:F,readonly:!0,height:B,onNodeClick:i})})]}),0===h.length&&0===g.length&&0===A.length&&(0,a.jsx)("p",{className:"text-xs text-[#9A9A9A] italic",children:x("emptyContainer")})]})}let ej={open:"border-[#D9D9D9] bg-white",assigned:"border-[#1976D2] bg-[#1976D2]",in_progress:"border-[#5A9E6F] bg-[#5A9E6F]",to_verify:"border-[#7B1FA2] bg-[#7B1FA2]",done:"border-[#00796B] bg-[#00796B]",closed:"border-[#9A9A9A] bg-[#9A9A9A]"},ev={open:null,assigned:null,in_progress:{className:"bg-[#E8F5E9] text-[#5A9E6F]",key:"inProgress"},to_verify:{className:"bg-[#F3E5F5] text-[#7B1FA2]",key:"toVerify"},done:{className:"bg-[#E0F2F1] text-[#00796B]",key:"done"},closed:{className:"bg-[#F5F5F5] text-[#9A9A9A]",key:"done"}};function eb(e){let{task:t,expanded:s,onToggle:l,onNavigate:i,taskStatus:c}=e,d=(0,n.c)("proposals"),o=(0,n.c)("acceptanceCriteria"),x=(0,n.c)("status"),u=t.acceptanceCriteriaItems||[],h=!!(t.description||u.length>0),f=c?ej[c]||ej.open:"border-[#D9D9D9] bg-white",g=c?ev[c]:null,j=(0,a.jsx)("span",{className:"shrink-0 h-2 w-2 rounded-full border-[1.5px] ".concat(f," transition-colors")}),v=(0,a.jsx)("span",{className:"flex-1 min-w-0 text-[13px] leading-snug truncate text-[#6B6B6B]",children:t.title}),b=g?(0,a.jsx)("span",{className:"shrink-0 rounded px-1.5 py-0.5 text-[10px] font-medium ".concat(g.className),children:x(g.key)}):null;return i?(0,a.jsxs)(r.$,{variant:"ghost",onClick:i,className:"w-full justify-start h-auto text-left flex items-center gap-2.5 py-4 cursor-pointer hover:bg-[#FAF8F4] -mx-1 px-1 rounded-lg transition-colors",children:[(0,a.jsx)(el.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}),j,v,b]}):(0,a.jsxs)("div",{children:[(0,a.jsxs)(r.$,{variant:"ghost",onClick:h?l:void 0,className:"w-full justify-start h-auto text-left flex items-center gap-2.5 py-4 ".concat(h?"cursor-pointer hover:bg-[#FAF8F4] -mx-1 px-1 rounded-lg":""," transition-colors"),children:[s?(0,a.jsx)(p.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}):(0,a.jsx)(m.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}),j,v,b]}),s&&h&&(0,a.jsxs)("div",{className:"pb-3 pl-5 space-y-3",children:[t.description&&(0,a.jsx)("p",{className:"text-[11px] leading-relaxed text-[#6B6B6B]",children:t.description}),u.length>0&&(0,a.jsxs)("div",{className:"rounded-lg bg-[#FAF8F4] p-3 space-y-2",children:[(0,a.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,a.jsx)(ei.A,{className:"h-3.5 w-3.5 text-[#888780]"}),(0,a.jsx)("span",{className:"text-[11px] font-semibold text-[#2C2C2C]",children:d("taskAcceptanceCriteria")})]}),(0,a.jsx)("div",{className:"space-y-1.5",children:u.map((e,t)=>(0,a.jsxs)("div",{className:"flex items-start justify-between gap-2",children:[(0,a.jsx)("p",{className:"text-[11px] leading-snug text-[#4A4A4A] flex-1",children:e.description}),!1!==e.required&&(0,a.jsx)("span",{className:"shrink-0 text-[10px] font-medium text-[#E65100]",children:o("required")})]},t))})]})]})]})}let eN=(0,s(66206).A)("message-square-text",[["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"}]]);var eA=s(60532),ey=s(97964);let eC=(0,ex.createServerReference)("401f6f6cb27a3ada1b9f397af1c4c7b946e70e09fe",ex.callServer,void 0,ex.findSourceMapURL,"getElaborationAction");function ew(e){let{idea:t,proposals:s,tasks:i,onSelectTask:r}=e,c=(0,n.c)("ideaTracker"),d=(0,n.c)(),[x,u]=(0,l.useState)(null),[h,f]=(0,l.useState)(new Set);(0,l.useEffect)(()=>{"open"!==t.status&&eC(t.uuid).then(e=>{e.success&&e.data&&u(e.data)})},[t.uuid,t.status]);let g=(0,l.useMemo)(()=>"open"===t.status?"idea_created":"elaborating"===t.status||0===s.length?"elaboration":s.some(e=>"approved"===e.status)&&i.length>0?"tasks":"proposal",[t.status,s,i]),j=(0,l.useMemo)(()=>{let e=["idea_created","elaboration","proposal","tasks"],t=e.indexOf(g);return e.map((e,s)=>({id:e,labelKey:({idea_created:"panel.timeline.ideaCreated",elaboration:"panel.timeline.elaboration",proposal:"panel.timeline.proposal",tasks:"panel.timeline.tasksProgress"})[e],status:s<t?"completed":s===t?"active":"upcoming",icon:({idea_created:(0,a.jsx)(o.A,{className:"h-3.5 w-3.5"}),elaboration:(0,a.jsx)(eN,{className:"h-3.5 w-3.5"}),proposal:(0,a.jsx)(_.A,{className:"h-3.5 w-3.5"}),tasks:(0,a.jsx)(ei.A,{className:"h-3.5 w-3.5"})})[e]}))},[g]);(0,l.useEffect)(()=>{let e=j.find(e=>"active"===e.status);e&&f(new Set([e.id]))},[g]);let v=(0,l.useCallback)(e=>{f(t=>{let s=new Set(t);return s.has(e)?s.delete(e):s.add(e),s})},[]),b=(0,l.useMemo)(()=>"open"===t.status?c("panel.timeline.noElaboration"):"skipped"===t.elaborationStatus?c("panel.timeline.elaborationSkipped"):"resolved"===t.elaborationStatus&&x?c("panel.timeline.elaborationComplete",{count:x.summary.totalQuestions}):"elaborating"===t.status?c("panel.timeline.elaborationInProgress"):x&&x.summary.totalQuestions>0?c("panel.timeline.elaborationComplete",{count:x.summary.totalQuestions}):c("panel.timeline.noElaboration"),[t.status,t.elaborationStatus,x,c]),N=(0,l.useMemo)(()=>{if(0===s.length)return c("panel.timeline.noProposal");let e=s.filter(e=>"approved"===e.status).length,t=s.filter(e=>"pending"===e.status).length;if(e>0&&1===s.length)return c("panel.timeline.proposalApproved");if(e>0)return c("panel.timeline.proposalsApproved",{count:e,total:s.length});if(t>0)return c("panel.timeline.proposalPending");switch(s[0].status){case"draft":default:return c("panel.timeline.proposalDraft");case"rejected":return c("panel.timeline.proposalRejected")}},[s,c]),A=(0,l.useMemo)(()=>{let e=0,t=0;for(let r of s){var a,n,l,i;e+=null!=(l=null==(a=r.documentDrafts)?void 0:a.length)?l:0,t+=null!=(i=null==(n=r.taskDrafts)?void 0:n.length)?i:0}return{docCount:e,taskDraftCount:t}},[s]),y=(0,l.useMemo)(()=>{let e=i.filter(e=>"done"===e.status||"closed"===e.status).length,t=i.filter(e=>"in_progress"===e.status).length;return{done:e,inProgress:t,toVerify:i.filter(e=>"to_verify"===e.status).length,open:i.filter(e=>"open"===e.status||"assigned"===e.status).length,total:i.length}},[i]);return(0,a.jsx)("div",{className:"space-y-0",children:j.map((e,n)=>{let l=h.has(e.id),o=n===j.length-1;return(0,a.jsxs)("div",{className:"flex gap-3",children:[(0,a.jsxs)("div",{className:"flex flex-col items-center w-5 shrink-0",children:[(0,a.jsx)("div",{className:"mt-1",children:"completed"===e.status?(0,a.jsx)("div",{className:"h-5 w-5 rounded-full bg-[#E0F2F1] flex items-center justify-center",children:(0,a.jsx)(eA.A,{className:"h-3 w-3 text-[#00796B]"})}):"active"===e.status?(0,a.jsx)("div",{className:"h-5 w-5 rounded-full bg-[#C67A52] flex items-center justify-center",children:(0,a.jsx)(ey.A,{className:"h-2 w-2 fill-white text-white"})}):(0,a.jsx)("div",{className:"h-5 w-5 rounded-full border-2 border-dashed border-[#D9D9D9] flex items-center justify-center",children:(0,a.jsx)(ey.A,{className:"h-2 w-2 text-[#D9D9D9]"})})}),!o&&(0,a.jsx)("div",{className:"flex-1 w-px bg-[#E5E0D8] mt-1 min-h-[8px]"})]}),(0,a.jsxs)("div",{className:"flex-1 min-w-0 ".concat(o?"pb-0":"pb-4"),children:[(0,a.jsxs)("button",{onClick:()=>v(e.id),className:"flex items-center gap-1.5 w-full text-left group cursor-pointer",children:[l?(0,a.jsx)(p.A,{className:"h-3.5 w-3.5 text-[#9A9A9A] shrink-0"}):(0,a.jsx)(m.A,{className:"h-3.5 w-3.5 text-[#9A9A9A] shrink-0"}),(0,a.jsx)("span",{className:"text-[13px] font-medium ".concat("active"===e.status?"text-[#C67A52]":"completed"===e.status?"text-[#2C2C2C]":"text-[#9A9A9A]"),children:c(e.labelKey)}),!l&&(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A] truncate ml-1",children:(e=>{switch(e.id){case"idea_created":return t.createdBy?t.createdBy.name:"";case"elaboration":return b;case"proposal":return N;case"tasks":return i.length>0?c("panel.timeline.tasksComplete",{done:y.done,total:y.total}):c("panel.timeline.noTasks");default:return""}})(e)})]}),(e=>{let n=h.has(e.id);switch(e.id){case"idea_created":return n?(0,a.jsxs)("div",{className:"mt-2 space-y-1.5",children:[t.createdBy&&(0,a.jsx)("p",{className:"text-[12px] text-[#6B6B6B]",children:c("panel.timeline.createdBy",{name:t.createdBy.name})}),(0,a.jsx)("p",{className:"text-[12px] text-[#9A9A9A]",children:(0,B.fw)(t.createdAt,d)}),t.content&&(0,a.jsxs)("p",{className:"text-[12px] text-[#6B6B6B] line-clamp-2",children:[t.content.slice(0,120),t.content.length>120?"...":""]})]}):null;case"elaboration":return n?(0,a.jsxs)("div",{className:"mt-2 space-y-1.5",children:[(0,a.jsx)("p",{className:"text-[12px] text-[#6B6B6B]",children:b}),x&&x.rounds.length>0&&(0,a.jsx)("p",{className:"text-[12px] text-[#9A9A9A]",children:c("panel.timeline.rounds",{count:x.rounds.length})})]}):null;case"proposal":return n?(0,a.jsxs)("div",{className:"mt-2 space-y-1.5",children:[(0,a.jsx)("p",{className:"text-[12px] text-[#6B6B6B]",children:N}),s.length>0&&(0,a.jsxs)("div",{className:"space-y-1",children:[A.docCount>0&&(0,a.jsxs)("div",{className:"flex items-center gap-1.5 text-[12px] text-[#9A9A9A]",children:[(0,a.jsx)(T.A,{className:"h-3 w-3"}),(0,a.jsx)("span",{children:c("panel.timeline.documents",{count:A.docCount})})]}),A.taskDraftCount>0&&(0,a.jsxs)("div",{className:"flex items-center gap-1.5 text-[12px] text-[#9A9A9A]",children:[(0,a.jsx)(ei.A,{className:"h-3 w-3"}),(0,a.jsx)("span",{children:c("panel.timeline.tasks",{count:A.taskDraftCount})})]})]})]}):null;case"tasks":return n?(0,a.jsx)("div",{className:"mt-2 space-y-2",children:0===i.length?(0,a.jsx)("p",{className:"text-[12px] text-[#9A9A9A]",children:c("panel.timeline.noTasks")}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsxs)("div",{className:"flex-1 h-1.5 rounded-full bg-[#F0EDE8] overflow-hidden flex",children:[y.done>0&&(0,a.jsx)("div",{className:"h-full bg-[#00796B]",style:{width:"".concat(y.done/y.total*100,"%")}}),y.inProgress>0&&(0,a.jsx)("div",{className:"h-full bg-[#1976D2]",style:{width:"".concat(y.inProgress/y.total*100,"%")}}),y.toVerify>0&&(0,a.jsx)("div",{className:"h-full bg-[#7B1FA2]",style:{width:"".concat(y.toVerify/y.total*100,"%")}})]}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A] shrink-0",children:c("panel.timeline.tasksComplete",{done:y.done,total:y.total})})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[i.slice(0,5).map(e=>(0,a.jsxs)("button",{onClick:()=>r(e.uuid),className:"flex items-center gap-2 w-full text-left rounded-md px-2 py-1.5 hover:bg-[#F5F2EC] transition-colors group cursor-pointer",children:[(0,a.jsx)(el.A,{className:"h-3 w-3 text-[#D9D9D9] shrink-0 group-hover:text-[#C67A52]"}),(0,a.jsx)("span",{className:"h-2 w-2 rounded-full shrink-0 ".concat((0,B.eT)(e.status))}),(0,a.jsx)("span",{className:"flex-1 text-[12px] text-[#2C2C2C] truncate group-hover:text-[#C67A52]",children:e.title})]},e.uuid)),i.length>5&&(0,a.jsx)("p",{className:"text-[11px] text-[#9A9A9A] px-2",children:c("panel.timeline.moreItems",{count:i.length-5})})]})]})}):null;default:return null}})(e)]})]},e.id)})})}let ek=(0,ex.createServerReference)("6013cbc19aa3119a1c2af52cfdd66bdda2781c7891",ex.callServer,void 0,ex.findSourceMapURL,"getReportsForIdeaAction");function eE(e){let{projectUuid:t,ideaUuid:s,proposals:i,onDocClick:c}=e,d=(0,n.c)("idea"),o=(0,n.c)("documents"),[x,p]=(0,l.useState)([]),[m,h]=(0,l.useState)(!0),f=i.some(e=>"approved"===e.status),g=(0,l.useCallback)(async()=>{if(!f){p([]),h(!1);return}try{let e=await ek(t,s);if(e.success){let t=[...e.data].sort((e,t)=>new Date(t.createdAt).getTime()-new Date(e.createdAt).getTime());p(t.map(e=>{var t;return{uuid:e.uuid,title:e.title,type:e.type,content:null!=(t=e.content)?t:null,createdAt:e.createdAt}}))}}catch(e){em.q.error("Failed to fetch reports for idea:",e)}finally{h(!1)}},[t,s,f]);return((0,l.useEffect)(()=>{h(!0),g()},[g]),(0,u.eV)("document",g),m)?f?(0,a.jsx)("div",{className:"flex items-center justify-center py-3",children:(0,a.jsx)(S.A,{className:"h-4 w-4 animate-spin text-[#C67A52]"})}):null:0===x.length?null:(0,a.jsxs)("div",{className:"mt-6 space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-baseline gap-2",children:[(0,a.jsx)("span",{className:"text-[11px] font-semibold uppercase tracking-[1px] text-[#9A9A9A]",children:d("reportsList")}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:x.length}),(0,a.jsxs)("span",{className:"text-[11px] text-[#B4B2A9]",children:["\xb7 ",d("reportsAcrossProposals")]})]}),(0,a.jsx)("div",{className:"space-y-0",children:x.map(e=>(0,a.jsxs)(r.$,{variant:"ghost",className:"w-full justify-start h-auto text-left flex items-center gap-2.5 py-3.5 hover:bg-[#FAF8F4] transition-colors cursor-pointer -mx-1 px-1 rounded-lg",onClick:()=>{var t;return c({title:e.title,type:"report",content:null!=(t=e.content)?t:""})},children:[(0,a.jsx)(el.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}),(0,a.jsx)(O.E,{variant:"outline",className:"shrink-0 text-[10px] font-medium border-[#E5E0D8] text-[#6B6B6B] bg-[#F5F2EC] px-2 py-0.5 font-mono",children:o(eo[e.type]||"typeOther")}),(0,a.jsx)("span",{className:"flex-1 min-w-0 text-left text-[13px] text-[#2C2C2A] truncate",children:e.title})]},e.uuid))})]})}var eF=s(76677);let eB=["in_progress","to_verify","open","assigned","done","closed"];function eS(e){let{tasks:t,projectUuid:s,proposalUuids:i,onSelectTask:r}=e,c=(0,n.c)("ideaTracker"),[d,o]=(0,l.useState)({}),x=(0,l.useMemo)(()=>t.map(e=>e.uuid),[t]),h=(0,l.useCallback)(async()=>{if(0===x.length)return;let e=await (0,eF.h)(x);e.success&&e.data&&o(e.data)},[x]);(0,l.useEffect)(()=>{h()},[h]),(0,u.eV)("task",h);let g=(0,l.useMemo)(()=>{let e=[];for(let s of eB){let a=t.filter(e=>e.status===s);a.length>0&&e.push({status:s,tasks:a})}let s=new Set(eB),a=t.filter(e=>!s.has(e.status));return a.length>0&&e.push({status:"other",tasks:a}),e},[t]),[j,v]=(0,l.useState)(new Set),b=(0,l.useMemo)(()=>{let e=t.length,s=t.filter(e=>"done"===e.status||"closed"===e.status).length,a=0,n=0,l=0,i=0;for(let e of t)e.acceptanceSummary&&(a+=e.acceptanceSummary.total,n+=e.acceptanceSummary.passed,l+=e.acceptanceSummary.required,i+=e.acceptanceSummary.requiredPassed);return{total:e,done:s,acTotal:a,acPassed:n,acRequired:l,acRequiredPassed:i}},[t]);return 0===t.length?(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center gap-3 py-12 text-center",children:[(0,a.jsx)(ei.A,{className:"h-8 w-8 text-[#D9D9D9]"}),(0,a.jsx)("p",{className:"text-sm text-[#9A9A9A]",children:c("panel.taskList.noTasks")})]}):(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-center gap-3 rounded-lg bg-[#FAFAF7] px-3 py-2",children:[(0,a.jsx)("span",{className:"text-[12px] text-[#6B6B6B]",children:c("panel.taskList.summary",{done:b.done,total:b.total})}),b.acTotal>0&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"text-[12px] text-[#D9D9D9]",children:"\xb7"}),(0,a.jsx)("span",{className:"text-[12px] text-[#6B6B6B]",children:c("panel.taskList.acSummary",{passed:b.acRequiredPassed,total:b.acRequired})})]}),i.length>0&&(0,a.jsxs)(E(),{href:"/projects/".concat(s,"/tasks?proposalUuids=").concat(i.join(",")),className:"ml-auto flex items-center gap-1 text-[13px] font-medium text-[#C67A52] shrink-0",children:[c("panel.taskList.viewKanban"),(0,a.jsx)(m.A,{className:"h-3.5 w-3.5"})]})]}),g.map(e=>{let t=j.has(e.status);return(0,a.jsxs)("div",{children:[(0,a.jsxs)("button",{onClick:()=>{var t;return t=e.status,void v(e=>{let s=new Set(e);return s.has(t)?s.delete(t):s.add(t),s})},className:"flex items-center gap-2 w-full text-left py-1.5 group cursor-pointer",children:[t?(0,a.jsx)(m.A,{className:"h-3.5 w-3.5 text-[#9A9A9A]"}):(0,a.jsx)(p.A,{className:"h-3.5 w-3.5 text-[#9A9A9A]"}),(0,a.jsx)("span",{className:"h-2 w-2 rounded-full shrink-0 ".concat((0,B.eT)(e.status))}),(0,a.jsx)("span",{className:"text-[13px] font-medium text-[#2C2C2C]",children:function(e,t){switch(e){case"in_progress":return t("panel.taskList.inProgress");case"to_verify":return t("panel.taskList.toVerify");case"open":return t("panel.taskList.open");case"assigned":return t("panel.taskList.assigned");case"done":return t("panel.taskList.done");case"closed":return t("panel.taskList.closed");default:return e}}(e.status,c)}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A] ml-auto",children:e.tasks.length})]}),!t&&(0,a.jsx)("div",{className:"ml-3 space-y-0.5",children:e.tasks.map(e=>{let t=d[e.uuid]||0,s=e.acceptanceSummary;return(0,a.jsx)(f.D,{entityType:"task",entityUuid:e.uuid,badgeInside:!0,children:(0,a.jsxs)("button",{onClick:()=>r(e.uuid),className:"flex items-center gap-2 w-full text-left rounded-md px-2.5 py-2 hover:bg-[#F5F2EC] transition-colors group cursor-pointer",children:[(0,a.jsx)(el.A,{className:"h-3.5 w-3.5 text-[#D9D9D9] shrink-0 group-hover:text-[#C67A52]"}),(0,a.jsx)("span",{className:"h-1.5 w-1.5 rounded-full shrink-0 ".concat((0,B.eT)(e.status))}),(0,a.jsx)("span",{className:"flex-1 text-[13px] text-[#2C2C2C] truncate group-hover:text-[#C67A52]",children:e.title}),s&&s.total>0&&(0,a.jsxs)("span",{className:"inline-flex items-center gap-0.5 shrink-0 rounded-full bg-[#F0EDE8] px-1.5 py-0.5 text-[10px] text-[#6B6B6B]",children:[(0,a.jsx)(eA.A,{className:"h-2.5 w-2.5"}),s.requiredPassed,"/",s.required]}),e.assignee&&(0,a.jsxs)("span",{className:"shrink-0 inline-flex items-center gap-1 text-[10px] text-[#9A9A9A] max-w-[72px] truncate",title:e.assignee.name,children:[(0,a.jsx)(q.A,{className:"h-2.5 w-2.5 shrink-0"}),e.assignee.name.split(/[@\s]/)[0]]}),t>0&&(0,a.jsx)("span",{className:"inline-flex items-center justify-center h-4 min-w-[16px] rounded-full bg-[#E8F5E9] text-[#2E7D32] text-[9px] font-semibold shrink-0",title:c("panel.taskList.workersActive",{count:t}),children:t})]})},e.uuid)})})]},e.status)})]})}var eD=s(35680);function e_(e){let{ideaUuid:t}=e,s=(0,n.c)(),[i,r]=(0,l.useState)([]),[c,d]=(0,l.useState)(!0),o=(0,l.useCallback)(async()=>{d(!0),r((await (0,eD.x)(t)).activities),d(!1)},[t]);return(0,l.useEffect)(()=>{o()},[o]),(0,a.jsxs)("div",{className:"mt-5",children:[(0,a.jsx)(G.J,{className:"text-[11px] font-medium uppercase tracking-wider text-[#9A9A9A]",children:s("common.activity")}),(0,a.jsx)("div",{className:"mt-2",children:c?(0,a.jsx)("div",{className:"flex items-center justify-center py-4",children:(0,a.jsx)(S.A,{className:"h-4 w-4 animate-spin text-[#9A9A9A]"})}):0===i.length?(0,a.jsx)("p",{className:"text-sm text-[#9A9A9A] italic",children:s("common.noActivity")}):i.map((e,t)=>(0,a.jsxs)("div",{className:"flex items-stretch gap-2.5",children:[(0,a.jsxs)("div",{className:"flex flex-col items-center w-2 shrink-0",children:[(0,a.jsx)("div",{className:"mt-1.5 h-2 w-2 shrink-0 rounded-full border-[1.5px] border-[#D9D9D9] bg-white"}),t<i.length-1&&(0,a.jsx)("div",{className:"flex-1 w-px bg-[#E5E0D8] mt-1"})]}),(0,a.jsxs)("div",{className:"flex-1 pb-3",children:[(0,a.jsx)("p",{className:"text-[13px] text-[#2C2C2C]",children:function(e,t){let{action:s,actorName:a}=e;switch(s){case"created":case"idea_created":return t("activity.ideaCreated",{actor:a});case"assigned":case"idea_assigned":return t("activity.ideaAssigned",{actor:a});case"claimed":case"idea_claimed":return t("activity.ideaClaimed",{actor:a});case"released":case"idea_released":return t("activity.ideaReleased",{actor:a});case"status_changed":case"idea_status_changed":return t("activity.ideaStatusChanged",{actor:a});case"elaboration_started":return t("activity.elaborationStarted",{actor:a});case"elaboration_answered":return t("activity.elaborationAnswered",{actor:a});case"elaboration_skipped":return t("activity.elaborationSkipped",{actor:a});case"elaboration_resolved":return t("activity.elaborationResolved",{actor:a});case"elaboration_followup":return t("activity.elaborationFollowup",{actor:a});default:return t("activity.genericAction",{actor:a,action:s})}}(e,s)}),(0,a.jsx)("p",{className:"text-[11px] text-[#9A9A9A]",children:(0,B.fw)(e.createdAt,s)})]})]},e.uuid))})]})}var eT=s(72642);function eU(e){let{ideaUuid:t,currentUserUuid:s,commentCount:i,onCommentCountChange:r}=e,c=(0,n.c)("ideaTracker"),[d,o]=(0,l.useState)("comments");return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"flex gap-1 rounded-lg bg-[#F5F2EC] p-0.5",children:[(0,a.jsxs)("button",{onClick:()=>o("comments"),className:"flex-1 rounded-md px-3 py-1.5 text-[13px] font-medium transition-colors flex items-center justify-center gap-1.5 cursor-pointer ".concat("comments"===d?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:[c("panel.activityTab.comments"),i>0&&(0,a.jsx)("span",{className:"inline-flex items-center justify-center min-w-[18px] h-[18px] px-1 rounded-full bg-[#F5F2EC] text-[#6B6B6B] text-[10px] font-semibold leading-none",children:i})]}),(0,a.jsx)("button",{onClick:()=>o("activity"),className:"flex-1 rounded-md px-3 py-1.5 text-[13px] font-medium transition-colors cursor-pointer ".concat("activity"===d?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:c("panel.activityTab.activity")})]}),(0,a.jsx)("div",{children:"activity"===d?(0,a.jsx)(e_,{ideaUuid:t}):(0,a.jsx)(eT.$,{targetType:"idea",targetUuid:t,currentUserUuid:s,onCountChange:r,compact:!0})})]})}var eM=s(91418),eR=s(70633);function eP(e){let{title:t,type:s,content:i,mode:c="overlay",onClose:d,onBack:o}=e,x=(0,n.c)("documents"),[u,p]=(0,l.useState)(!1);(0,l.useEffect)(()=>{let e=setTimeout(()=>p(!0),300);return()=>clearTimeout(e)},[]),(0,l.useEffect)(()=>{let e=e=>{"Escape"!==e.key||e.defaultPrevented||(e.preventDefault(),d())};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[d]);let m="sidebyside"===c;return(0,a.jsxs)(a.Fragment,{children:[!m&&(0,a.jsx)("div",{className:"fixed inset-0 z-40 bg-black/20",onClick:d}),(0,a.jsxs)("div",{className:"fixed top-14 md:top-0 flex h-[calc(100%-3.5rem)] md:h-full w-full flex-col bg-white shadow-xl border-l border-[#E5E0D8] ".concat(m?"z-40 ".concat(u?"":"animate-in slide-in-from-right duration-300"):"z-50 right-0 ".concat(u?"":"animate-in slide-in-from-right duration-300")),style:{width:"min(100%, ".concat(B.L8,"px)"),...m?{right:"".concat(B.L8,"px")}:{}},children:[(0,a.jsxs)("div",{className:"flex items-center justify-between border-b border-[#F5F2EC] px-6 py-5",children:[o&&(0,a.jsx)(r.$,{variant:"ghost",size:"icon",className:"mr-2 h-8 w-8 shrink-0",onClick:o,children:(0,a.jsx)(eR.A,{className:"h-4 w-4 text-[#6B6B6B]"})}),(0,a.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-[#2C2C2C] truncate",children:t}),(0,a.jsx)("div",{className:"mt-1.5",children:(0,a.jsx)(O.E,{variant:"outline",className:"text-[10px] font-medium border-[#E5E0D8] text-[#6B6B6B] bg-[#F5F2EC] px-2 py-0.5 font-mono",children:x(eo[s]||"typeOther")})})]}),(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"ml-4 h-8 w-8 shrink-0 border-[#E5E0D8]",onClick:d,children:(0,a.jsx)(L.A,{className:"h-4 w-4 text-[#6B6B6B]"})})]}),(0,a.jsx)(V.F,{className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:(0,a.jsx)("div",{className:"px-6 py-5 text-[13px] leading-relaxed text-[#2C2C2A] prose prose-sm max-w-none [&_h1]:text-lg [&_h1]:font-semibold [&_h1]:mt-4 [&_h1]:mb-2 [&_h2]:text-base [&_h2]:font-semibold [&_h2]:mt-3 [&_h2]:mb-1.5 [&_h3]:text-sm [&_h3]:font-medium [&_h3]:mt-2 [&_h3]:mb-1 [&_p]:text-[13px] [&_p]:text-[#4A4A4A] [&_p]:my-1.5 [&_li]:text-[13px] [&_li]:text-[#4A4A4A] [&_ul]:my-1 [&_ol]:my-1 [&_strong]:text-[#2C2C2C] [&_code]:text-[12px] [&_code]:bg-[#F5F2EC] [&_code]:px-1 [&_code]:py-0.5 [&_code]:rounded [&_pre]:bg-[#FAF8F4] [&_pre]:p-3 [&_pre]:rounded-lg [&_pre]:my-2",children:(0,a.jsx)(Y.MarkdownContent,{children:ed(i)})})})]})]})}var ez=s(98480),eI=s(71645),eL=s(77381);let eq=(0,ex.createServerReference)("408d014f9a96037a922b7e6bf7e3cf1e0e28a96577",ex.callServer,void 0,ex.findSourceMapURL,"getIdeaAction"),e$=(0,ex.createServerReference)("40106e9c885a122b86951906d0e2409f8e4a62031b",ex.callServer,void 0,ex.findSourceMapURL,"getTaskAction");var eV=s(10836);function eO(e){let{ideaUuid:t,projectUuid:s,currentUserUuid:i,onClose:c}=e,d=(0,n.c)(),o=(0,n.c)("ideaTracker"),x=(0,n.c)("status"),p=(0,P.useRouter)(),[m,h]=(0,l.useState)(null),[f,j]=(0,l.useState)(!0),[v,b]=(0,l.useState)(null),[N,A]=(0,l.useState)([]),[y,C]=(0,l.useState)([]),[w,k]=(0,l.useState)("overview"),[E,F]=(0,l.useState)(new Set(["overview"])),[D,_]=(0,l.useState)(!1),[T,U]=(0,l.useState)(0),[M,R]=(0,l.useState)(!1),[Z,Q]=(0,l.useState)(!1),[W,X]=(0,l.useState)(!1),[Y,ee]=(0,l.useState)(""),[et,es]=(0,l.useState)(""),[ea,el]=(0,l.useState)(!1),[ei,er]=(0,l.useState)(null),[ec,ed]=(0,l.useState)(!1),[eo,ex]=(0,l.useState)(null),[ef,eg]=(0,l.useState)(null),[ej,ev]=(0,l.useState)(null),eb=(0,l.useCallback)(e=>{ev(null),ex(e)},[]),eN=(0,l.useCallback)(e=>{ex(null),eg(null),ev(e)},[]),[eA,ey]=(0,l.useState)(!1);(0,l.useEffect)(()=>{let e=window.matchMedia("(min-width: 960px)");ey(e.matches);let t=e=>ey(e.matches);return e.addEventListener("change",t),()=>e.removeEventListener("change",t)},[]);let[eC,ek]=(0,l.useState)(!1);(0,l.useEffect)(()=>{let e=setTimeout(()=>ek(!0),300);return()=>clearTimeout(e)},[]);let eF=(0,l.useCallback)(e=>{let t=new URLSearchParams(window.location.search);t.set("tab",e),window.history.replaceState(null,"","".concat(window.location.pathname,"?").concat(t.toString()))},[]),eB=(0,l.useCallback)(async()=>{try{let e=await eq(t);e.success?(h(e.data),b(null)):b(o("Not found"===e.error?"panel.notFound":"panel.loadFailed"))}catch(e){b(o("panel.loadFailed"))}finally{j(!1)}},[t,o]);(0,l.useEffect)(()=>{j(!0),eB()},[eB]),(0,u.eV)("idea",eB),(0,u.eV)("proposal",eB),(0,u.eV)("task",eB);let eD=null==m?void 0:m.uuid,e_=null==m?void 0:m.status,eT=(0,l.useCallback)(async()=>{if(!eD||"open"===e_)return void A([]);try{let e=await eu(s,eD);e.success&&A(e.data)}catch(e){em.q.error("Failed to fetch proposals:",e)}},[s,eD,e_]);(0,l.useEffect)(()=>{eT()},[eT]),(0,u.eV)("proposal",eT);let eR=(0,l.useCallback)(async()=>{let e=N.filter(e=>"approved"===e.status);if(0===e.length)return void C([]);try{let t=(await Promise.all(e.map(e=>ep(s,e.uuid)))).flatMap(e=>e.success&&e.data?e.data.map(e=>{var t,s,a;return{uuid:e.uuid,title:e.title,status:e.status,commentCount:null!=(t=e.commentCount)?t:0,assignee:null!=(s=e.assignee)?s:null,acceptanceSummary:null!=(a=e.acceptanceSummary)?a:null}}):[]);C(t)}catch(e){em.q.error("Failed to fetch tasks:",e)}},[s,N]);(0,l.useEffect)(()=>{eR()},[eR]),(0,u.eV)("task",eR);let eO=(0,l.useMemo)(()=>m?function(e,t,s){let a=["overview"];return a.push("elaboration"),t.length>0&&a.push("proposal"),s.length>0&&a.push("tasks"),a.push("activity"),a}(0,N,y):["overview","activity"],[m,N,y]),eH=(0,l.useRef)(new URLSearchParams(window.location.search).get("tab")),eJ=m?function(e){switch(e){case"open":case"researching":case"answer_questions":return"elaboration";case"planning":case"review_proposal":return"proposal";case"building":case"verify_work":return"tasks";default:return"overview"}}(m.badgeHint):"overview";(0,l.useEffect)(()=>{let e;if(!m||D)return;let t=eH.current;if(t)if(!eO.includes(t))return;else e=t,eH.current=null,_(!0);else if(eO.includes(eJ))e=eJ;else{if("overview"!==eJ)return;e="overview"}k(e),F(t=>new Set([...t,e])),eF(e)},[null==m?void 0:m.uuid,eJ,eO]),(0,l.useEffect)(()=>{_(!1)},[t]),(0,l.useEffect)(()=>{eO.includes(w)||k("overview")},[eO,w]);let eG=(0,l.useMemo)(()=>y.filter(e=>"in_progress"===e.status||"assigned"===e.status||"to_verify"===e.status).length,[y]),eK=(0,l.useCallback)(()=>{if(!eo)return void eg(null);e$(eo).then(e=>{e.success&&eg(e.data)}).catch(e=>em.q.error("Failed to load task details:",e))},[eo]);(0,l.useEffect)(()=>{eK()},[eK]),(0,u.eV)("task",eK),(0,l.useEffect)(()=>{X(!1),ee((null==m?void 0:m.title)||""),es((null==m?void 0:m.content)||""),er(null)},[null==m?void 0:m.uuid,null==m?void 0:m.title,null==m?void 0:m.content]);let eZ=()=>{X(!1),ee((null==m?void 0:m.title)||""),es((null==m?void 0:m.content)||""),er(null)},eQ=async()=>{if(!m||!Y.trim())return void er(d("ideas.titleRequired"));el(!0),er(null);let e=await (0,eI.J)({ideaUuid:m.uuid,projectUuid:s,title:Y.trim(),content:et.trim()||null});el(!1),e.success?(X(!1),await eB(),p.refresh()):er(e.error||d("ideas.updateFailed"))},eW=async()=>{if(!m)return;Q(!0);let e=await (0,eL.Z)(m.uuid,s);Q(!1),e.success&&(c(),p.refresh())},eX=(null==m?void 0:m.derivedStatus)||"todo",eY=!!m&&"elaborated"!==m.status,e0=(null==m?void 0:m.elaborationStatus)==="resolved",e2=(null==m?void 0:m.status)==="elaborating"&&!e0;return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"fixed inset-0 z-40 bg-black/20",onClick:c}),(0,a.jsxs)("div",{className:"fixed right-0 top-14 md:top-0 z-50 flex h-[calc(100%-3.5rem)] md:h-full w-full md:w-[480px] flex-col bg-white shadow-xl border-l border-[#E5E0D8] ".concat(eC?"":"animate-in slide-in-from-right duration-300"),children:[(0,a.jsxs)("div",{className:"flex items-center justify-between border-b border-[#F5F2EC] px-6 py-5",children:[(0,a.jsx)("div",{className:"flex-1 min-w-0",children:f?(0,a.jsx)("div",{className:"h-5 w-40 animate-pulse rounded bg-[#F5F2EC]"}):m?W?(0,a.jsx)("h2",{className:"text-base font-semibold text-[#2C2C2C]",children:d("ideas.editIdea")}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-[#2C2C2C] truncate",children:m.title}),(0,a.jsxs)("div",{className:"mt-1.5 flex items-center gap-2",children:[(0,a.jsx)(O.E,{className:B._5[eX]||B._5.todo,children:m.badgeHint?o("badge.".concat(B.Wl[m.badgeHint]||"open")):x(B.Bj[eX]||"todo")}),(0,a.jsx)("span",{className:"text-xs text-[#9A9A9A]",children:(0,g.r)(m.createdAt)})]})]}):(0,a.jsx)("h2",{className:"text-base font-semibold text-[#2C2C2C]",children:o("panel.notFound")})}),(0,a.jsxs)("div",{className:"flex items-center gap-2 ml-4",children:[m&&!W&&(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"h-8 w-8 border-[#E5E0D8]",onClick:()=>ed(!0),title:d("ideas.actions.move"),"aria-label":d("ideas.actions.move"),children:(0,a.jsx)(z.A,{className:"h-4 w-4 text-[#6B6B6B]"})}),m&&"elaborated"!==m.status&&!W&&(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"h-8 w-8 border-[#E5E0D8]",onClick:()=>{m&&(ee(m.title),es(m.content||""),er(null),X(!0))},title:d("ideas.editIdea"),children:(0,a.jsx)(I.A,{className:"h-4 w-4 text-[#6B6B6B]"})}),(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"h-8 w-8 border-[#E5E0D8]",onClick:W?eZ:c,children:(0,a.jsx)(L.A,{className:"h-4 w-4 text-[#6B6B6B]"})})]})]}),m&&!f&&!W&&(0,a.jsx)("div",{className:"border-b border-[#F5F2EC] px-6",children:(0,a.jsx)("div",{className:"flex gap-0 -mb-px",children:eO.map(e=>(0,a.jsxs)("button",{onClick:()=>{k(e),_(!0),F(t=>new Set([...t,e])),eF(e)},className:"relative flex items-center gap-1.5 px-3 py-2.5 text-[13px] font-medium transition-colors cursor-pointer ".concat(w===e?"text-[#C67A52] border-b-2 border-[#C67A52]":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:[o("panel.tabs.".concat(e)),"tasks"===e&&eG>0&&(0,a.jsx)("span",{className:"inline-flex items-center justify-center min-w-[18px] h-[18px] px-1 rounded-full bg-[#E3F2FD] text-[#1976D2] text-[10px] font-semibold leading-none",children:eG}),"activity"===e&&T>0&&(0,a.jsx)("span",{className:"inline-flex items-center justify-center min-w-[18px] h-[18px] px-1 rounded-full bg-[#F5F2EC] text-[#6B6B6B] text-[10px] font-semibold leading-none",children:T})]},e))})}),(0,a.jsx)(V.F,{className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:(0,a.jsx)("div",{className:"flex min-h-full flex-col px-6 py-5",children:f?(0,a.jsxs)("div",{className:"flex flex-1 items-center justify-center py-12",children:[(0,a.jsx)(S.A,{className:"h-6 w-6 animate-spin text-[#C67A52]"}),(0,a.jsx)("span",{className:"ml-2 text-sm text-[#9A9A9A]",children:o("loading")})]}):v?(0,a.jsx)("div",{className:"flex flex-1 items-center justify-center py-12",children:(0,a.jsx)("p",{className:"text-sm text-[#9A9A9A]",children:v})}):m?W?(0,a.jsxs)("div",{className:"space-y-5",children:[ei&&(0,a.jsx)("div",{className:"rounded-lg bg-destructive/10 p-3 text-sm text-destructive",children:ei}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(G.J,{htmlFor:"edit-title",className:"text-[13px] font-medium text-[#2C2C2C]",children:d("ideas.titleLabel")}),(0,a.jsx)(H.p,{id:"edit-title",value:Y,onChange:e=>ee(e.target.value),className:"border-[#E5E0D8] text-sm focus-visible:ring-[#C67A52]",autoFocus:!0})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(G.J,{htmlFor:"edit-content",className:"text-[13px] font-medium text-[#2C2C2C]",children:d("common.content")}),(0,a.jsx)(J.T,{id:"edit-content",value:et,onChange:e=>es(e.target.value),rows:8,className:"border-[#E5E0D8] text-sm resize-none focus-visible:ring-[#C67A52]"})]})]}):(0,a.jsxs)(a.Fragment,{children:[E.has("overview")&&(0,a.jsxs)("div",{style:{display:"overview"===w?"block":"none"},children:[(0,a.jsx)(ew,{idea:m,proposals:N,tasks:y,onSelectTask:eb}),(0,a.jsx)(eE,{projectUuid:s,ideaUuid:m.uuid,proposals:N,onDocClick:eN})]}),eO.includes("elaboration")&&E.has("elaboration")&&(0,a.jsx)("div",{style:{display:"elaboration"===w?"block":"none"},children:(0,a.jsx)(en,{idea:m,onRefresh:eB})}),eO.includes("proposal")&&E.has("proposal")&&(0,a.jsx)("div",{style:{display:"proposal"===w?"block":"none"},children:(0,a.jsx)(eh,{idea:m,projectUuid:s,onTaskClick:eb,onDocClick:eN,initialProposals:N})}),eO.includes("tasks")&&E.has("tasks")&&(0,a.jsx)("div",{style:{display:"tasks"===w?"block":"none"},children:(0,a.jsx)(eS,{tasks:y,projectUuid:s,proposalUuids:N.filter(e=>"approved"===e.status).map(e=>e.uuid),onSelectTask:eb})}),E.has("activity")&&(0,a.jsx)("div",{style:{display:"activity"===w?"block":"none"},children:(0,a.jsx)(eU,{ideaUuid:m.uuid,currentUserUuid:i,commentCount:T,onCommentCountChange:U})})]}):null})}),m&&!f&&(0,a.jsx)("div",{className:"border-t border-[#F5F2EC] px-6 py-4",children:W?(0,a.jsxs)("div",{className:"flex items-center justify-end gap-3",children:[(0,a.jsx)(r.$,{variant:"outline",className:"border-[#E5E0D8]",onClick:eZ,disabled:ea,children:d("common.cancel")}),(0,a.jsx)(r.$,{className:"bg-[#C67A52] hover:bg-[#B56A42] text-white",onClick:eQ,disabled:ea||!Y.trim(),children:ea?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(S.A,{className:"mr-2 h-4 w-4 animate-spin"}),d("common.save")]}):d("common.save")})]}):(0,a.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[eY&&(0,a.jsxs)(r.$,{variant:"outline",className:"shrink-0 border-[#E5E0D8] rounded-md px-4 py-2 text-[13px] font-medium",onClick:()=>R(!0),children:[(0,a.jsx)(q.A,{className:"mr-2 h-4 w-4"}),m.assignee?d("common.reassign"):d("common.assign")]}),(0,a.jsx)("div",{className:"flex-1 min-w-0",children:e2&&(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:d("elaboration.elaborationRequiredHint")})}),(0,a.jsxs)(K.Lt,{children:[(0,a.jsx)(K.tv,{asChild:!0,children:(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"shrink-0 h-8 w-8 border-[#E5E0D8] text-[#EF4444] hover:bg-[#FFEBEE] hover:text-[#EF4444] hover:border-[#EF4444]",children:(0,a.jsx)($.A,{className:"h-4 w-4"})})}),(0,a.jsxs)(K.EO,{children:[(0,a.jsxs)(K.wd,{children:[(0,a.jsx)(K.r7,{children:d("ideas.deleteIdea")}),(0,a.jsx)(K.$v,{children:d("ideas.deleteIdeaConfirm",{title:m.title})})]}),(0,a.jsxs)(K.ck,{children:[(0,a.jsx)(K.Zr,{children:d("common.cancel")}),(0,a.jsx)(K.Rx,{variant:"destructive",onClick:eW,disabled:Z,children:Z?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(S.A,{className:"mr-2 h-4 w-4 animate-spin"}),d("common.delete")]}):d("common.delete")})]})]})]})]})})]}),(0,a.jsx)(ez.h,{open:ec,onOpenChange:ed,ideaUuid:t,projectUuid:s,onMoved:()=>c()}),M&&m&&(0,a.jsx)(eV.i,{idea:{uuid:m.uuid,title:m.title,content:m.content,status:m.status,assignee:m.assignee?{type:m.assignee.type,uuid:m.assignee.uuid,name:m.assignee.name}:null},projectUuid:s,currentUserUuid:i,onClose:()=>{R(!1),eB()}}),eo&&ef&&(0,a.jsx)(eM.v,{task:ef,projectUuid:s,currentUserUuid:i,mode:eA?"sidebyside":"overlay",onClose:()=>{ex(null),eg(null)},onBack:()=>{ex(null),eg(null)}}),ej&&(0,a.jsx)(eP,{title:ej.title,type:ej.type,content:ej.content,mode:eA?"sidebyside":"overlay",onClose:()=>ev(null),onBack:()=>ev(null)})]})}var eH=s(97438);function eJ(e){let{open:t,onOpenChange:s,projectUuid:i,onCreated:c}=e,d=(0,n.c)("ideaTracker"),o=(0,n.c)("common"),[x,u]=(0,l.useState)(""),[p,m]=(0,l.useState)(""),[h,f]=(0,l.useState)(!1),[g,j]=(0,l.useState)(null),v=async()=>{let e=x.trim();if(e){f(!0),j(null);try{var t;let a=await fetch("/api/projects/".concat(i,"/ideas"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({title:e,content:p.trim()||void 0})}),n=await a.json();n.success&&(null==(t=n.data)?void 0:t.uuid)?(u(""),m(""),s(!1),null==c||c(n.data.uuid)):j(n.error||d("error.createFailed"))}catch(e){j(d("error.createFailed"))}finally{f(!1)}}};return(0,a.jsx)(eH.lG,{open:t,onOpenChange:s,children:(0,a.jsxs)(eH.Cf,{className:"sm:max-w-[480px]",children:[(0,a.jsx)(eH.c7,{children:(0,a.jsx)(eH.L3,{children:d("newIdea.title")})}),(0,a.jsxs)("div",{className:"space-y-4 py-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(G.J,{htmlFor:"idea-title",children:d("newIdea.ideaTitle")}),(0,a.jsx)(H.p,{id:"idea-title",value:x,onChange:e=>u(e.target.value),placeholder:d("newIdea.titlePlaceholder"),autoFocus:!0,onKeyDown:e=>{"Enter"===e.key&&!e.shiftKey&&x.trim()&&(e.preventDefault(),v())}})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsxs)(G.J,{htmlFor:"idea-content",children:[d("newIdea.description"),(0,a.jsxs)("span",{className:"ml-1 text-xs font-normal text-[#9A9A9A]",children:["(",o("optional"),")"]})]}),(0,a.jsx)(J.T,{id:"idea-content",value:p,onChange:e=>m(e.target.value),placeholder:d("newIdea.descriptionPlaceholder"),rows:4,className:"resize-none"})]}),g&&(0,a.jsx)("div",{className:"rounded-lg bg-destructive/10 px-3 py-2 text-[12px] text-destructive",children:g})]}),(0,a.jsxs)(eH.Es,{children:[(0,a.jsx)(r.$,{variant:"outline",onClick:()=>s(!1),disabled:h,children:o("cancel")}),(0,a.jsxs)(r.$,{onClick:v,disabled:h||!x.trim(),className:"bg-[#C67A52] hover:bg-[#B56A42] text-white",children:[h?(0,a.jsx)(S.A,{className:"mr-2 h-4 w-4 animate-spin"}):null,o("create")]})]})]})})}function eG(e){let{projectUuid:t,currentUserUuid:s,initialTrackerData:d,initialStatsData:o,initialSelectedIdeaUuid:x}=e,u=(0,n.c)("ideaTracker"),[p,m]=(0,l.useState)("ideas"),[h,f]=(0,l.useState)(!1),[g,j]=(0,l.useState)(!1),v="/projects/".concat(t,"/dashboard"),{selectedId:b,openPanel:N,closePanel:A}=(0,c.T)(v,x);return(0,a.jsxs)("div",{className:"flex h-full flex-col",children:[!h&&(0,a.jsxs)("div",{className:"mb-4 flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"flex gap-0.5 rounded-lg border border-[#E5E0D8] p-0.5",children:[(0,a.jsx)(r.$,{variant:"ghost",size:"sm",onClick:()=>m("ideas"),className:"rounded-md px-3 py-1 h-auto text-[12px] font-medium transition-colors ".concat("ideas"===p?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:u("tabs.ideas")}),(0,a.jsx)(r.$,{variant:"ghost",size:"sm",onClick:()=>m("stats"),className:"rounded-md px-3 py-1 h-auto text-[12px] font-medium transition-colors ".concat("stats"===p?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:u("tabs.stats")})]}),"ideas"===p&&(0,a.jsxs)(r.$,{onClick:()=>j(!0),size:"sm",className:"gap-1.5 rounded-md bg-[#C67A52] px-3.5 py-2 text-white hover:bg-[#B56A42]",children:[(0,a.jsx)(i.A,{className:"h-4 w-4"}),u("actions.newIdea")]})]}),"ideas"===p?(0,a.jsx)(w,{projectUuid:t,initialData:d,onIdeaClick:N,onNewIdea:()=>j(!0),onEmptyChange:f}):(0,a.jsx)(R,{projectUuid:t,initialData:o}),(0,a.jsx)(eJ,{open:g,onOpenChange:j,projectUuid:t,onCreated:e=>N(e)}),b&&(0,a.jsx)(eO,{ideaUuid:b,projectUuid:t,currentUserUuid:s,onClose:A})]})}},29767:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("lightbulb",[["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"}]])},32470:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("list-checks",[["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"}]])},37915:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("chevron-left",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]])},38476:(e,t,s)=>{"use strict";s.r(t),s.d(t,{Collapsible:()=>j,CollapsibleContent:()=>A,CollapsibleTrigger:()=>b,Content:()=>E,Root:()=>w,Trigger:()=>k,createCollapsibleScope:()=>h});var a=s(1856),n=s(33328),l=s(21032),i=s(66249),r=s(99457),c=s(34124),d=s(93367),o=s(19900),x=s(40577),u=s(90508),p="Collapsible",[m,h]=(0,l.A)(p),[f,g]=m(p),j=a.forwardRef((e,t)=>{let{__scopeCollapsible:s,open:n,defaultOpen:l,disabled:r,onOpenChange:c,...o}=e,[m,h]=(0,i.i)({prop:n,defaultProp:null!=l&&l,onChange:c,caller:p});return(0,u.jsx)(f,{scope:s,disabled:r,contentId:(0,x.B)(),open:m,onOpenToggle:a.useCallback(()=>h(e=>!e),[h]),children:(0,u.jsx)(d.sG.div,{"data-state":C(m),"data-disabled":r?"":void 0,...o,ref:t})})});j.displayName=p;var v="CollapsibleTrigger",b=a.forwardRef((e,t)=>{let{__scopeCollapsible:s,...a}=e,l=g(v,s);return(0,u.jsx)(d.sG.button,{type:"button","aria-controls":l.contentId,"aria-expanded":l.open||!1,"data-state":C(l.open),"data-disabled":l.disabled?"":void 0,disabled:l.disabled,...a,ref:t,onClick:(0,n.mK)(e.onClick,l.onOpenToggle)})});b.displayName=v;var N="CollapsibleContent",A=a.forwardRef((e,t)=>{let{forceMount:s,...a}=e,n=g(N,e.__scopeCollapsible);return(0,u.jsx)(o.C,{present:s||n.open,children:e=>{let{present:s}=e;return(0,u.jsx)(y,{...a,ref:t,present:s})}})});A.displayName=N;var y=a.forwardRef((e,t)=>{let{__scopeCollapsible:s,present:n,children:l,...i}=e,o=g(N,s),[x,p]=a.useState(n),m=a.useRef(null),h=(0,c.s)(t,m),f=a.useRef(0),j=f.current,v=a.useRef(0),b=v.current,A=o.open||x,y=a.useRef(A),w=a.useRef(void 0);return a.useEffect(()=>{let e=requestAnimationFrame(()=>y.current=!1);return()=>cancelAnimationFrame(e)},[]),(0,r.N)(()=>{let e=m.current;if(e){w.current=w.current||{transitionDuration:e.style.transitionDuration,animationName:e.style.animationName},e.style.transitionDuration="0s",e.style.animationName="none";let t=e.getBoundingClientRect();f.current=t.height,v.current=t.width,y.current||(e.style.transitionDuration=w.current.transitionDuration,e.style.animationName=w.current.animationName),p(n)}},[o.open,n]),(0,u.jsx)(d.sG.div,{"data-state":C(o.open),"data-disabled":o.disabled?"":void 0,id:o.contentId,hidden:!A,...i,ref:h,style:{"--radix-collapsible-content-height":j?"".concat(j,"px"):void 0,"--radix-collapsible-content-width":b?"".concat(b,"px"):void 0,...e.style},children:A&&l})});function C(e){return e?"open":"closed"}var w=j,k=b,E=A},52309:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("settings",[["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"}]])},56669:(e,t,s)=>{Promise.resolve().then(s.bind(s,9715)),Promise.resolve().then(s.bind(s,7045))},57223:(e,t,s)=>{"use strict";s.d(t,{E:()=>l});var a=s(90508),n=s(24377);function l(e){let{className:t,...s}=e;return(0,a.jsx)("div",{"data-slot":"skeleton",className:(0,n.cn)("bg-accent animate-pulse rounded-md",t),...s})}},71921:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("clipboard-list",[["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"}]])},78948:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]])},84247:(e,t,s)=>{"use strict";s.d(t,{Separator:()=>i});var a=s(90508);s(1856);var n=s(5725),l=s(24377);function i(e){let{className:t,orientation:s="horizontal",decorative:i=!0,...r}=e;return(0,a.jsx)(n.b,{"data-slot":"separator",decorative:i,orientation:s,className:(0,l.cn)("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",t),...r})}},95900:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("arrow-right-left",[["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"}]])}},e=>{e.O(0,[41282,93151,41752,30996,57084,59764,12079,18944,12790,26885,21932,16544,53298,30724,27201,16551,97784,14753,45532,70552,86944,11207,76803,29660,84541,23466,44046,6028,9562,74951,65496,77358],()=>e(e.s=56669)),_N_E=e.O()}]);
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[85e3],{5725:(e,t,s)=>{"use strict";s.d(t,{b:()=>d});var a=s(1856),n=s(93367),l=s(90508),i="horizontal",r=["horizontal","vertical"],c=a.forwardRef((e,t)=>{var s;let{decorative:a,orientation:c=i,...d}=e,o=(s=c,r.includes(s))?c:i;return(0,l.jsx)(n.sG.div,{"data-orientation":o,...a?{role:"none"}:{"aria-orientation":"vertical"===o?o:void 0,role:"separator"},...d,ref:t})});c.displayName="Separator";var d=c},7045:(e,t,s)=>{"use strict";s.d(t,{ProjectSettingsModal:()=>v});var a=s(90508),n=s(1856),l=s(23675),i=s(39268),r=s(52309),c=s(85226),d=s(22922),o=s(14554),x=s(88064),u=s(15972),p=s(97438),m=s(84247),h=s(51817),f=s(52217);let g=(0,f.createServerReference)("60cfafb97dee121da111a8fbb6d24763894ee7029a",f.callServer,void 0,f.findSourceMapURL,"updateProjectAction"),j=(0,f.createServerReference)("40cb34bdc4fed2104114738bf7775d107b52ddb319",f.callServer,void 0,f.findSourceMapURL,"deleteProjectAction");function v(e){let{projectUuid:t,projectName:s,projectDescription:f}=e,v=(0,i.c)(),b=(0,l.useRouter)(),[N,A]=(0,n.useState)(!1),[y,C]=(0,n.useState)(s),[w,k]=(0,n.useState)(f||""),[E,F]=(0,n.useState)(!1),[B,S]=(0,n.useState)(!1),D=async()=>{F(!0);let e=await g(t,{name:y,description:w||null});F(!1),e.success&&(A(!1),b.refresh())},_=async()=>{S(!0);let e=await j(t);e&&!e.success&&S(!1)};return(0,a.jsxs)(p.lG,{open:N,onOpenChange:A,children:[(0,a.jsx)(p.zM,{asChild:!0,children:(0,a.jsxs)(d.$,{variant:"outline",size:"sm",className:"gap-1.5 rounded-lg border-[#E5E2DC] bg-white text-[12px] font-normal text-[#2C2C2C] hover:border-[#C67A52] hover:bg-white",children:[(0,a.jsx)(r.A,{className:"h-3.5 w-3.5 text-[#6B6B6B]"}),v("dashboard.settings")]})}),(0,a.jsxs)(p.Cf,{className:"gap-0 overflow-hidden rounded-2xl border-0 p-0 sm:max-w-[520px]",children:[(0,a.jsx)(p.c7,{className:"px-7 py-6",children:(0,a.jsx)(p.L3,{className:"text-[20px] font-semibold tracking-tight text-[#2C2C2C]",children:v("projectSettings.title")})}),(0,a.jsx)(m.Separator,{className:"bg-[#E5E2DC]"}),(0,a.jsxs)("div",{className:"flex flex-col gap-7 p-7",children:[(0,a.jsxs)("div",{className:"flex flex-col gap-5",children:[(0,a.jsx)("h3",{className:"text-[14px] font-semibold text-[#2C2C2C]",children:v("projectSettings.basicInfo")}),(0,a.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,a.jsx)(x.J,{className:"text-[12px] font-medium text-[#6B6B6B]",children:v("projectSettings.projectName")}),(0,a.jsx)(o.p,{value:y,onChange:e=>C(e.target.value),className:"h-11 rounded-[10px] border-[#E5E2DC] text-[14px] text-[#2C2C2C] focus-visible:ring-[#C67A52]"})]}),(0,a.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,a.jsx)(x.J,{className:"text-[12px] font-medium text-[#6B6B6B]",children:v("projectSettings.description")}),(0,a.jsx)(u.T,{value:w,onChange:e=>k(e.target.value),rows:3,className:"resize-none rounded-[10px] border-[#E5E2DC] text-[14px] text-[#2C2C2C] focus-visible:ring-[#C67A52]"})]}),(0,a.jsx)(d.$,{onClick:D,disabled:E||!y.trim(),className:"w-fit rounded-[10px] bg-[#C67A52] px-6 text-[13px] font-semibold text-white hover:bg-[#B56A42]",children:E?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.A,{className:"mr-2 h-4 w-4 animate-spin"}),v("projectSettings.saving")]}):v("projectSettings.saveChanges")})]}),(0,a.jsx)(m.Separator,{className:"bg-[#E5E2DC]"}),(0,a.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,a.jsx)("h3",{className:"text-[14px] font-semibold text-[#C4574C]",children:v("projectSettings.dangerZone")}),(0,a.jsx)("div",{className:"rounded-xl border border-[#C4574C40] bg-[#C4574C08] px-[18px] py-4",children:(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,a.jsx)("span",{className:"text-[13px] font-semibold text-[#2C2C2C]",children:v("projectSettings.deleteTitle")}),(0,a.jsx)("span",{className:"text-[12px] text-[#6B6B6B]",children:v("projectSettings.deleteDescription")})]}),(0,a.jsxs)(h.Lt,{children:[(0,a.jsx)(h.tv,{asChild:!0,children:(0,a.jsx)(d.$,{variant:"destructive",size:"sm",className:"ml-4 shrink-0 rounded-lg bg-[#C4574C] px-[18px] text-[12px] font-medium hover:bg-[#B3463B]",children:v("common.delete")})}),(0,a.jsxs)(h.EO,{children:[(0,a.jsxs)(h.wd,{children:[(0,a.jsx)(h.r7,{children:v("projectOverview.deleteProject")}),(0,a.jsx)(h.$v,{children:v("projectOverview.deleteProjectConfirm",{name:s})})]}),(0,a.jsxs)(h.ck,{children:[(0,a.jsx)(h.Zr,{children:v("common.cancel")}),(0,a.jsx)(h.Rx,{variant:"destructive",onClick:_,disabled:B,children:B?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.A,{className:"mr-2 h-4 w-4 animate-spin"}),v("common.delete")]}):v("common.delete")})]})]})]})]})})]})]})]})]})}},9715:(e,t,s)=>{"use strict";s.d(t,{IdeaTracker:()=>eK});var a=s(90508),n=s(39268),l=s(1856),i=s(5616),r=s(22922),c=s(81531),d=s(36755),o=s(29767),x=s(57223),u=s(63964),p=s(17730),m=s(78948),h=s(81750),f=s(96213),g=s(38106);let j={open:"open",researching:"researching",answer_questions:"answerQuestions",planning:"planning",review_proposal:"reviewProposal",building:"building",verify_work:"verifyWork",done:"done",closed:"closed"},v={open:"text-[#888780]",researching:"text-[#7F77DD]",answer_questions:"text-[#C47A20]",planning:"text-[#7F77DD]",review_proposal:"text-[#C47A20]",building:"text-[#7F77DD]",verify_work:"text-[#C47A20]",done:"text-[#1D9E75]",closed:"text-[#888780]"};function b(e){let{idea:t,onClick:s}=e,l=(0,n.c)("ideaTracker"),i=t.badgeHint?j[t.badgeHint]:null,r=t.badgeHint&&v[t.badgeHint]||"text-[#888780]";return(0,a.jsxs)("div",{className:"flex items-center justify-between px-3.5 py-3 transition-colors ".concat(s?"cursor-pointer hover:bg-[#FAF8F4]":""),onClick:s?()=>s(t.uuid):void 0,children:[(0,a.jsxs)("div",{className:"flex min-w-0 items-center gap-2.5",children:[(0,a.jsx)("span",{className:"shrink-0 text-[11px] text-[#B4B2A9]",children:"IDEA"}),(0,a.jsx)("span",{className:"truncate text-[13px] text-[#2C2C2A]",children:t.title}),i&&(0,a.jsx)("span",{className:"shrink-0 rounded bg-[#F0EEEA] px-1.5 py-0.5 text-[11px] ".concat(r),children:l("badge.".concat(i))})]}),(0,a.jsx)("span",{className:"shrink-0 pl-4 text-[12px] text-[#888780]",children:(0,g.s)(t.createdAt)})]})}let N={human_conduct_required:{fill:"#7F77DD"},in_progress:{fill:"#378ADD"},todo:{stroke:"#888780"},done:{fill:"#1D9E75"}},A={todo:"todo",in_progress:"inProgress",human_conduct_required:"humanConductRequired",done:"done"};function y(e){let{status:t,ideas:s,defaultOpen:i=!0,onIdeaClick:r}=e,c=(0,n.c)("ideaTracker"),d=s.length>0,[o,x]=(0,l.useState)(!!d&&i),u=A[t]||"todo",g=N[t]||N.todo;return(0,a.jsxs)(h.Nt,{open:o,onOpenChange:x,children:[(0,a.jsxs)(h.R6,{className:"group flex w-full cursor-pointer items-center gap-2 px-0 pb-1.5 pt-0",children:[o?(0,a.jsx)(p.A,{className:"h-3.5 w-3.5 shrink-0 text-[#888780] transition-colors group-hover:text-[#2C2C2A]"}):(0,a.jsx)(m.A,{className:"h-3.5 w-3.5 shrink-0 text-[#888780] transition-colors group-hover:text-[#2C2C2A]"}),(0,a.jsx)("span",{className:"h-2 w-2 shrink-0 rounded-full",style:{backgroundColor:g.fill,border:g.stroke?"1.5px solid ".concat(g.stroke):void 0}}),(0,a.jsx)("span",{className:"text-[13px] font-medium transition-colors group-hover:text-[#2C2C2A] ".concat(d?"text-[#5F5E5A]":"text-[#B4B2A9]"),children:c("status.".concat(u))}),(0,a.jsx)("span",{className:"text-[12px] text-[#888780] transition-colors group-hover:text-[#2C2C2A]",children:s.length})]}),d&&(0,a.jsx)(h.Ke,{children:(0,a.jsx)("div",{className:"overflow-hidden rounded-lg bg-white",children:s.map((e,t)=>(0,a.jsxs)("div",{children:[t>0&&(0,a.jsx)("div",{className:"mx-0 h-px bg-[#F0EEEA]"}),(0,a.jsx)(f.D,{entityType:"idea",entityUuid:e.uuid,badgeInside:!0,children:(0,a.jsx)(b,{idea:e,onClick:r})})]},e.uuid))})})]})}let C=["human_conduct_required","in_progress","todo","done"];function w(e){var t;let{projectUuid:s,initialData:c,onIdeaClick:p,onNewIdea:m,onEmptyChange:h}=e,f=(0,n.c)("ideaTracker"),[g,j]=(0,l.useState)(null!=(t=null==c?void 0:c.groups)?t:{}),[v,b]=(0,l.useState)(!c),[N,A]=(0,l.useState)(null),w=(0,l.useCallback)(async()=>{try{let e=await fetch("/api/projects/".concat(s,"/ideas/tracker")),t=await e.json();t.success&&t.data?(j(t.data.groups),A(null)):A(t.error||f("error.loadFailed"))}catch(e){A(f("error.loadFailed"))}finally{b(!1)}},[s,f]);(0,u.eV)("idea",w),(0,u.eV)("proposal",w),(0,u.eV)("task",w),(0,l.useEffect)(()=>{c||w()},[w,c]);let k=C.reduce((e,t)=>e+(g[t]||[]).length,0);return((0,l.useEffect)(()=>{v||null==h||h(0===k)},[k,v,h]),v)?(0,a.jsx)("div",{className:"space-y-4",children:[1,2,3].map(e=>(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(x.E,{className:"h-5 w-32"}),(0,a.jsx)(x.E,{className:"h-12 w-full rounded-lg"}),(0,a.jsx)(x.E,{className:"h-12 w-full rounded-lg"})]},e))}):N&&0===Object.keys(g).length?(0,a.jsxs)("div",{className:"flex flex-col items-center gap-4 py-16",children:[(0,a.jsx)(d.A,{className:"h-10 w-10 text-[#E65100]"}),(0,a.jsx)("p",{className:"text-[13px] text-[#6B6B6B]",children:N}),(0,a.jsx)(r.$,{variant:"outline",size:"sm",onClick:()=>{b(!0),A(null),w()},className:"border-[#E5E0D8] text-[#2C2C2C]",children:f("actions.retry")})]}):0===k?(0,a.jsxs)("div",{className:"flex min-h-[60vh] flex-col items-center justify-center gap-3",children:[(0,a.jsx)("div",{className:"flex h-12 w-12 items-center justify-center rounded-full bg-[#F5F2EC]",children:(0,a.jsx)(o.A,{className:"h-5 w-5 text-[#B4B2A9]"})}),(0,a.jsx)("p",{className:"text-[13px] font-medium text-[#6B6B6B]",children:f("empty.noIdeas")}),(0,a.jsx)("p",{className:"max-w-[260px] text-center text-[12px] leading-relaxed text-[#9A9A9A]",children:f("empty.getStarted")}),m&&(0,a.jsxs)(r.$,{onClick:m,size:"sm",className:"mt-2 gap-1.5 rounded-md bg-[#C67A52] px-4 py-2 text-white hover:bg-[#B56A42]",children:[(0,a.jsx)(i.A,{className:"h-4 w-4"}),f("actions.newIdea")]})]}):(0,a.jsxs)("div",{className:"space-y-4",children:[N&&Object.keys(g).length>0&&(0,a.jsx)("div",{className:"rounded-lg bg-destructive/10 px-3 py-2 text-[12px] text-destructive",children:N}),(0,a.jsx)("div",{className:"space-y-4",children:C.map(e=>{let t=g[e]||[];return 0===t.length?null:(0,a.jsx)(y,{status:e,ideas:t,defaultOpen:"done"!==e,onIdeaClick:p},e)})})]})}var k=s(12790),E=s.n(k),F=s(48416),B=s(90795),S=s(85226),D=s(18789),_=s(71921),T=s(56770);let U=[{key:"todo",bg:"#E65100"},{key:"inProgress",bg:"#5A9E6F"},{key:"toVerify",bg:"#7B1FA2"},{key:"done",bg:"#00796B"}],M={idea:"bg-[#C67A52]",task:"bg-[#5A9E6F]",proposal:"bg-[#1976D2]",document:"bg-[#9A9A9A]"};function R(e){let{projectUuid:t,initialData:s}=e,i=(0,n.c)(),r=(0,n.c)("ideaTracker"),[c,d]=(0,l.useState)(null!=s?s:null),[x,p]=(0,l.useState)(!s),m=(0,l.useCallback)(async()=>{try{let e=await fetch("/api/projects/".concat(t,"/stats"));if(!e.ok)return;let s=await e.json();s.success&&d(s.data)}finally{p(!1)}},[t]);if((0,l.useEffect)(()=>{s||m()},[m,s]),(0,u.eV)(["idea","task","proposal","document"],m),x)return(0,a.jsx)("div",{className:"flex items-center justify-center py-20",children:(0,a.jsx)(S.A,{className:"h-6 w-6 animate-spin text-[#9A9A9A]"})});if(!c)return null;let{stats:h,recentActivities:f}=c,g=[{label:r("stats.totalIdeas"),value:h.ideas.total,badge:h.ideas.open>0?r("stats.openCount",{count:h.ideas.open}):null,badgeStyle:"bg-[#C67A5220] text-[#C67A52]",href:"/projects/".concat(t,"/ideas"),iconBg:"bg-[#FFF3E0]",icon:(0,a.jsx)(o.A,{className:"h-5 w-5 text-[#E65100]"})},{label:r("stats.totalTasks"),value:h.tasks.total,badge:h.tasks.inProgress>0?r("stats.activeCount",{count:h.tasks.inProgress}):null,badgeStyle:"bg-[#5A9E6F20] text-[#5A9E6F]",href:"/projects/".concat(t,"/tasks"),iconBg:"bg-[#E3F2FD]",icon:(0,a.jsx)(D.A,{className:"h-5 w-5 text-[#1976D2]"})},{label:r("stats.totalProposals"),value:h.proposals.total,badge:h.proposals.pending>0?r("stats.pendingCount",{count:h.proposals.pending}):null,badgeStyle:"bg-[#C67A5220] text-[#C67A52]",href:"/projects/".concat(t,"/proposals"),iconBg:"bg-[#F3E5F5]",icon:(0,a.jsx)(_.A,{className:"h-5 w-5 text-[#7B1FA2]"})},{label:r("stats.totalDocuments"),value:h.documents.total,badge:null,badgeStyle:"",href:"/projects/".concat(t,"/documents"),iconBg:"bg-[#E8F5E9]",icon:(0,a.jsx)(T.A,{className:"h-5 w-5 text-[#5A9E6F]"})}],j=[h.tasks.todo,h.tasks.inProgress,h.tasks.toVerify,h.tasks.done],v=h.tasks.total,b=[{label:r("stats.todoCount",{count:h.tasks.todo}),color:"#E65100"},{label:r("stats.inProgressCount",{count:h.tasks.inProgress}),color:"#5A9E6F"},{label:r("stats.toVerifyCount",{count:h.tasks.toVerify}),color:"#7B1FA2"},{label:r("stats.doneCount",{count:h.tasks.done}),color:"#00796B"}];return(0,a.jsxs)("div",{className:"flex flex-col gap-6",children:[(0,a.jsx)("div",{className:"grid grid-cols-2 gap-3 md:gap-4 lg:grid-cols-4",children:g.map(e=>(0,a.jsx)(E(),{href:e.href,children:(0,a.jsxs)(F.Zp,{className:"cursor-pointer rounded-2xl border-0 bg-white p-3 shadow-none transition-all hover:shadow-md md:p-5",children:[(0,a.jsxs)("div",{className:"mb-2 flex items-center justify-between md:mb-3.5",children:[(0,a.jsx)("div",{className:"flex h-8 w-8 items-center justify-center rounded-lg md:h-10 md:w-10 md:rounded-xl ".concat(e.iconBg),children:e.icon}),e.badge&&(0,a.jsx)("span",{className:"hidden rounded-lg px-2.5 py-1 text-[11px] font-medium sm:inline ".concat(e.badgeStyle),children:e.badge})]}),(0,a.jsx)("div",{className:"text-2xl font-semibold leading-none tracking-tight text-[#2C2C2C] md:text-[32px]",children:e.value}),(0,a.jsx)("div",{className:"mt-0.5 text-[12px] text-[#6B6B6B] md:text-[13px]",children:e.label})]})},e.label))}),(0,a.jsxs)("div",{className:"grid min-h-0 gap-5 lg:grid-cols-2",children:[(0,a.jsxs)(F.Zp,{className:"flex flex-col rounded-2xl border-0 bg-white p-6 shadow-none",children:[(0,a.jsxs)("div",{className:"mb-5 flex items-center justify-between",children:[(0,a.jsx)("h2",{className:"text-[16px] font-semibold text-[#2C2C2C]",children:r("stats.taskPipeline")}),(0,a.jsx)("span",{className:"text-[12px] text-[#9A9A9A]",children:r("stats.totalCount",{count:v})})]}),v>0?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"mb-5 flex h-3 w-full overflow-hidden rounded-md",children:j.map((e,t)=>e>0?(0,a.jsx)("div",{className:"h-full",style:{width:"".concat(e/v*100,"%"),backgroundColor:U[t].bg}},U[t].key):null)}),(0,a.jsx)("div",{className:"flex flex-wrap gap-5",children:b.map(e=>(0,a.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,a.jsx)("div",{className:"h-2.5 w-2.5 rounded-sm",style:{backgroundColor:e.color}}),(0,a.jsx)("span",{className:"text-[12px] text-[#6B6B6B]",children:e.label})]},e.color))})]}):(0,a.jsx)("div",{className:"flex flex-1 items-center justify-center py-10 text-[13px] text-[#9A9A9A]",children:r("stats.noTasks")})]}),(0,a.jsxs)(F.Zp,{className:"flex flex-col rounded-2xl border-0 bg-white p-6 shadow-none",children:[(0,a.jsxs)("div",{className:"mb-4 flex items-center justify-between",children:[(0,a.jsx)("h2",{className:"text-[16px] font-semibold text-[#2C2C2C]",children:r("stats.recentActivity")}),(0,a.jsx)(E(),{href:"/projects/".concat(t,"/activity"),className:"text-[12px] font-medium text-[#C67A52] hover:underline",children:r("stats.viewAll")})]}),f.length>0?(0,a.jsx)("div",{className:"flex flex-col",children:f.map((e,t)=>{let s=M[e.targetType]||"bg-[#9A9A9A]";return(0,a.jsxs)("div",{className:"flex items-start gap-3 py-3 ".concat(t<f.length-1?"border-b border-[#F5F2EC]":""),children:[(0,a.jsx)("div",{className:"mt-1.5 h-2 w-2 shrink-0 rounded-full ".concat(s)}),(0,a.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,a.jsxs)("p",{className:"text-[13px] text-[#2C2C2C]",children:[e.actorName," ",e.action]}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:(0,B.fw)(e.createdAt,i)})]})]},e.uuid)})}):(0,a.jsx)("div",{className:"flex flex-1 items-center justify-center py-10 text-[13px] text-[#9A9A9A]",children:r("stats.noActivity")})]})]})]})}var P=s(23675),z=s(95900),I=s(57893),L=s(9160),q=s(94903),$=s(97413),V=s(64993),O=s(57731),H=s(14554),J=s(15972),G=s(88064),K=s(51817),Z=s(5425),Q=s(84247),W=s(26468),X=s(49192),Y=s(97261),ee=s(16544),et=s(65626),es=s(73693);function ea(e){let{assignee:t}=e,s=(0,n.c)("common");return(0,a.jsxs)("div",{children:[(0,a.jsx)(G.J,{className:"text-[11px] font-medium uppercase tracking-wide text-[#9A9A9A]",children:s("assignee")}),(0,a.jsx)("div",{className:"mt-2 flex items-center gap-2.5 rounded-lg bg-[#FAF8F4] p-3",children:t?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(es.eu,{className:"h-7 w-7",children:(0,a.jsx)(es.q5,{className:"agent"===t.type?"bg-[#C67A52] text-white":"bg-[#E5E0D8] text-[#6B6B6B]",children:"agent"===t.type?(0,a.jsx)(Z.A,{className:"h-3.5 w-3.5"}):t.name.charAt(0).toUpperCase()})}),(0,a.jsxs)("div",{children:[(0,a.jsx)("div",{className:"text-sm font-medium text-[#2C2C2C]",children:t.name}),(0,a.jsx)("div",{className:"text-xs text-[#6B6B6B]",children:s("agent"===t.type?"agent":"user")})]})]}):(0,a.jsx)("span",{className:"text-sm text-[#9A9A9A]",children:s("unassigned")})})]})}function en(e){let{idea:t,onRefresh:s}=e,i=(0,n.c)("ideaTracker"),r=(0,n.c)("common"),[c,d]=(0,l.useState)(null),[o,x]=(0,l.useState)(!0),p=(0,l.useCallback)(async()=>{let e=await (0,X.z)(t.uuid);e.success&&e.data&&d(e.data),x(!1)},[t.uuid]);(0,l.useEffect)(()=>{p()},[p]),(0,u.eV)("idea",p);let m=async()=>{await p(),await s()};return o?(0,a.jsx)("div",{className:"flex items-center justify-center py-12",children:(0,a.jsx)(S.A,{className:"h-5 w-5 animate-spin text-[#C67A52]"})}):(0,a.jsxs)(ee.P.div,{variants:et.qG,initial:"initial",animate:"animate",children:[(0,a.jsx)(ea,{assignee:t.assignee}),(0,a.jsx)(Q.Separator,{className:"my-5 bg-[#F5F2EC]"}),c&&c.rounds.length>0?(0,a.jsx)("div",{children:(0,a.jsx)(W.R,{ideaUuid:t.uuid,elaboration:c,onRefresh:m})}):"open"===t.status?(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center gap-3 py-8 text-center",children:[(0,a.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-[#FFF3E0]",children:(0,a.jsx)(Z.A,{className:"h-5 w-5 text-[#E65100]"})}),(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"text-sm font-medium text-[#2C2C2C]",children:i("panel.elaborationNotStarted")}),(0,a.jsx)("p",{className:"mt-1 text-xs text-[#9A9A9A]",children:i("panel.elaborationNotStartedDesc")})]})]}):(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center gap-3 py-8 text-center",children:[(0,a.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-[#E3F2FD]",children:(0,a.jsx)(Z.A,{className:"h-5 w-5 text-[#1976D2]"})}),(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"text-sm font-medium text-[#2C2C2C]",children:i("panel.elaborationWaiting")}),(0,a.jsx)("p",{className:"mt-1 text-xs text-[#9A9A9A]",children:i("panel.elaborationWaitingDesc")})]})]}),t.content&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(Q.Separator,{className:"my-5 bg-[#F5F2EC]"}),(0,a.jsxs)("div",{children:[(0,a.jsx)(G.J,{className:"text-[11px] font-medium uppercase tracking-wide text-[#9A9A9A]",children:r("content")}),(0,a.jsx)("div",{className:"mt-2",children:(0,a.jsx)("div",{className:"prose prose-sm max-w-none text-[13px] leading-relaxed text-[#2C2C2C]",children:(0,a.jsx)(Y.MarkdownContent,{children:t.content})})})]})]})]})}var el=s(37915),ei=s(32470),er=s(47754),ec=s(92745);function ed(e){return e.replace(/\\n/g,"\n")}let eo={prd:"typePrd",tech_design:"typeTechDesign",adr:"typeAdr",spec:"typeSpec",guide:"typeGuide",design:"typeDesign",note:"typeNote",report:"typeReport",other:"typeOther"};var ex=s(52217);let eu=(0,ex.createServerReference)("6069d5893c952546dbbe150e494d758fde93dbba08",ex.callServer,void 0,ex.findSourceMapURL,"getProposalsForIdeaAction"),ep=(0,ex.createServerReference)("6050dd308d7c75c1229578f89c56198c125fd45636",ex.callServer,void 0,ex.findSourceMapURL,"getTasksForProposalAction");var em=s(67712);function eh(e){let{idea:t,projectUuid:s,onTaskClick:i,onDocClick:r,initialProposals:c}=e,d=(0,n.c)("ideaTracker"),[o,x]=(0,l.useState)(null!=c?c:[]),[p,m]=(0,l.useState)(!c),h=(0,l.useCallback)(async()=>{try{let e=await eu(s,t.uuid);if(e.success)return x(e.data),e.data}catch(e){em.q.error("Failed to fetch proposals:",e)}finally{m(!1)}return[]},[s,t.uuid]);(0,l.useEffect)(()=>{c||h()},[h,c]);let f=(0,l.useRef)(o);f.current=o;let{getPresence:g}=(0,er.xQ)();return((0,u.eV)("proposal",async()=>{let e=f.current;for(let l of(await h())){var t,s,a,n;let i=e.find(e=>e.uuid===l.uuid);if(!i)continue;let r=new Set((null!=(t=i.documentDrafts)?t:[]).map(e=>e.uuid)),c=new Set((null!=(s=i.taskDrafts)?s:[]).map(e=>e.uuid)),d=(null!=(a=l.documentDrafts)?a:[]).filter(e=>e.uuid&&!r.has(e.uuid)),o=(null!=(n=l.taskDrafts)?n:[]).filter(e=>e.uuid&&!c.has(e.uuid)),x=[...d.map(e=>e.uuid),...o.map(e=>e.uuid)];if(x.length>0){let e=g("proposal",l.uuid)[0];if(e)for(let t of x)(0,er.fv)({entityType:"proposal",entityUuid:l.uuid,subEntityType:"draft",subEntityUuid:t,agentUuid:e.agentUuid,agentName:e.agentName,action:"mutate"})}}}),p)?(0,a.jsx)("div",{className:"flex items-center justify-center py-12",children:(0,a.jsx)(S.A,{className:"h-5 w-5 animate-spin text-[#C67A52]"})}):0===o.length?(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center gap-3 py-12 text-center",children:[(0,a.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-[#F3E5F5]",children:(0,a.jsx)(_.A,{className:"h-5 w-5 text-[#7B1FA2]"})}),(0,a.jsx)("p",{className:"text-sm text-[#9A9A9A]",children:d("panel.noProposals")})]}):(0,a.jsx)("div",{className:"space-y-5",children:o.map(e=>(0,a.jsx)(eg,{proposal:e,projectUuid:s,onTaskClick:i,onDocClick:r},e.uuid))})}let ef={draft:"bg-[#F5F5F5] text-[#6B6B6B]",pending:"bg-[#FFF3E0] text-[#E65100]",approved:"bg-[#E8F5E9] text-[#5A9E6F]",rejected:"bg-[#FFEBEE] text-[#C4574C]",revised:"bg-[#E3F2FD] text-[#1976D2]",closed:"bg-[#F5F5F5] text-[#9A9A9A]"};function eg(e){let{proposal:t,projectUuid:s,onTaskClick:i,onDocClick:c}=e,d=(0,n.c)("ideaTracker"),o=(0,n.c)(),x=(0,n.c)("proposals"),u=(0,n.c)("tasks"),p=(0,n.c)("documents"),h=t.documentDrafts||[],g=t.taskDrafts||[],[j,v]=(0,l.useState)(new Set),[b,N]=(0,l.useState)("cards"),[A,y]=(0,l.useState)([]),C="approved"===t.status;(0,l.useEffect)(()=>{C&&ep(s,t.uuid).then(e=>{e.success&&y(e.data||[])}).catch(e=>em.q.error("Failed to fetch materialized tasks:",e))},[C,s,t.uuid]);let w=(0,l.useMemo)(()=>{let e=new Map;for(let t of A)e.set(t.title,t);return e},[A]),{dagTasks:k,dagEdges:F,dagHeight:B}=(0,l.useMemo)(()=>{let e=g.map(e=>{let t=w.get(e.title);return{uuid:(null==t?void 0:t.uuid)||e.uuid,title:e.title,status:(null==t?void 0:t.status)||"open",priority:e.priority||"medium"}}),t=[],s=new Map(g.map(e=>[e.uuid,e]));for(let e of g)if(e.dependsOnDraftUuids)for(let a of e.dependsOnDraftUuids){let n=w.get(e.title),l=s.get(a),i=l?w.get(l.title):void 0;t.push({from:(null==n?void 0:n.uuid)||e.uuid,to:(null==i?void 0:i.uuid)||a})}return{dagTasks:e,dagEdges:t,dagHeight:Math.max(350,90*e.length)}},[g,w]),S=C?A.filter(e=>"done"===e.status||"closed"===e.status).length:0;return(0,a.jsxs)("div",{className:"space-y-5",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("h3",{className:"text-[14px] font-semibold text-[#2C2C2C] truncate flex-1",children:t.title}),(0,a.jsx)(O.E,{className:"text-[11px] font-semibold border-0 shrink-0 ".concat(ef[t.status]||""),children:o("status.".concat(t.status))})]}),t.description&&(0,a.jsx)("div",{className:"max-h-[120px] overflow-y-auto text-[13px] leading-relaxed text-[#4A4A4A] prose prose-sm max-w-none [&_h1]:text-sm [&_h2]:text-[13px] [&_h3]:text-xs [&_p]:text-[13px] [&_p]:text-[#4A4A4A] [&_p]:my-1.5 [&_li]:text-[13px] [&_li]:text-[#4A4A4A] [&_ul]:my-1 [&_ol]:my-1 [&_strong]:text-[#2C2C2C]",children:(0,a.jsx)(Y.MarkdownContent,{children:ed(t.description)})}),(0,a.jsxs)(E(),{href:"/projects/".concat(s,"/proposals/").concat(t.uuid),className:"flex items-center gap-1 text-[13px] font-medium text-[#C67A52] hover:underline",children:[d("panel.viewProposal"),(0,a.jsx)(m.A,{className:"h-3.5 w-3.5"})]}),h.length>0&&(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"text-[11px] font-semibold uppercase tracking-[1px] text-[#9A9A9A]",children:x(C?"documents":"documentDrafts")}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:h.length})]}),(0,a.jsx)("div",{className:"space-y-0",children:h.map((e,s)=>(0,a.jsx)(f.D,{entityType:"proposal",entityUuid:t.uuid,subEntityType:"draft",subEntityUuid:e.uuid||"draft-".concat(s),badgeInside:!0,children:(0,a.jsxs)(r.$,{variant:"ghost",className:"w-full justify-start h-auto text-left flex items-center gap-2.5 py-3.5 hover:bg-[#FAF8F4] transition-colors cursor-pointer -mx-1 px-1 rounded-lg",onClick:()=>e.content&&(null==c?void 0:c({title:e.title,type:e.type,content:e.content})),children:[(0,a.jsx)(el.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}),(0,a.jsx)(O.E,{variant:"outline",className:"shrink-0 text-[10px] font-medium border-[#E5E0D8] text-[#6B6B6B] bg-[#F5F2EC] px-2 py-0.5 font-mono",children:p(eo[e.type]||"typeOther")}),(0,a.jsx)("span",{className:"flex-1 min-w-0 text-left text-[13px] text-[#2C2C2A] truncate",children:e.title})]})},e.uuid||s))})]}),(g.length>0||A.length>0)&&(0,a.jsxs)("div",{children:[(0,a.jsxs)("div",{className:"flex items-center justify-between pb-2",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"text-[11px] font-semibold uppercase tracking-[1px] text-[#9A9A9A]",children:x(C?"tasks":"taskDrafts")}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:C&&A.length>0?A.length:g.length})]}),(0,a.jsxs)("span",{className:"text-[12px] text-[#9A9A9A]",children:[S,"/",C&&A.length>0?A.length:g.length]})]}),(0,a.jsx)("div",{className:"-mx-6 border-t border-[#E5E0D8]"}),F.length>0&&(0,a.jsxs)("div",{className:"flex gap-0.5 rounded-lg border border-[#E5E0D8] bg-[#F7F6F3] p-0.5 mt-3 w-fit",children:[(0,a.jsx)(r.$,{variant:"ghost",size:"sm",onClick:()=>N("cards"),className:"rounded-md px-2.5 py-1 h-auto text-[11px] font-medium transition-colors ".concat("cards"===b?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:x("cardsView")}),(0,a.jsx)(r.$,{variant:"ghost",size:"sm",onClick:()=>N("dag"),className:"rounded-md px-2.5 py-1 h-auto text-[11px] font-medium transition-colors ".concat("dag"===b?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:u("dagView")})]}),"cards"===b&&(0,a.jsx)("div",{className:"space-y-0",children:C&&A.length>0?A.map(e=>(0,a.jsx)(f.D,{entityType:"task",entityUuid:e.uuid,badgeInside:!0,children:(0,a.jsx)(eb,{task:{uuid:e.uuid,title:e.title},expanded:!1,onToggle:()=>{},onNavigate:i?()=>i(e.uuid):void 0,taskStatus:e.status})},e.uuid)):g.map((e,s)=>(0,a.jsx)(f.D,{entityType:"proposal",entityUuid:t.uuid,subEntityType:"draft",subEntityUuid:e.uuid,badgeInside:!0,children:(0,a.jsx)(eb,{task:e,expanded:j.has(s),onToggle:()=>{v(e=>{let t=new Set(e);return t.has(s)?t.delete(s):t.add(s),t})}})},e.uuid))}),"dag"===b&&(0,a.jsx)("div",{className:"mt-3",children:(0,a.jsx)(ec._u,{tasks:k,edges:F,readonly:!0,height:B,onNodeClick:i})})]}),0===h.length&&0===g.length&&0===A.length&&(0,a.jsx)("p",{className:"text-xs text-[#9A9A9A] italic",children:x("emptyContainer")})]})}let ej={open:"border-[#D9D9D9] bg-white",assigned:"border-[#1976D2] bg-[#1976D2]",in_progress:"border-[#5A9E6F] bg-[#5A9E6F]",to_verify:"border-[#7B1FA2] bg-[#7B1FA2]",done:"border-[#00796B] bg-[#00796B]",closed:"border-[#9A9A9A] bg-[#9A9A9A]"},ev={open:null,assigned:null,in_progress:{className:"bg-[#E8F5E9] text-[#5A9E6F]",key:"inProgress"},to_verify:{className:"bg-[#F3E5F5] text-[#7B1FA2]",key:"toVerify"},done:{className:"bg-[#E0F2F1] text-[#00796B]",key:"done"},closed:{className:"bg-[#F5F5F5] text-[#9A9A9A]",key:"done"}};function eb(e){let{task:t,expanded:s,onToggle:l,onNavigate:i,taskStatus:c}=e,d=(0,n.c)("proposals"),o=(0,n.c)("acceptanceCriteria"),x=(0,n.c)("status"),u=t.acceptanceCriteriaItems||[],h=!!(t.description||u.length>0),f=c?ej[c]||ej.open:"border-[#D9D9D9] bg-white",g=c?ev[c]:null,j=(0,a.jsx)("span",{className:"shrink-0 h-2 w-2 rounded-full border-[1.5px] ".concat(f," transition-colors")}),v=(0,a.jsx)("span",{className:"flex-1 min-w-0 text-[13px] leading-snug truncate text-[#6B6B6B]",children:t.title}),b=g?(0,a.jsx)("span",{className:"shrink-0 rounded px-1.5 py-0.5 text-[10px] font-medium ".concat(g.className),children:x(g.key)}):null;return i?(0,a.jsxs)(r.$,{variant:"ghost",onClick:i,className:"w-full justify-start h-auto text-left flex items-center gap-2.5 py-4 cursor-pointer hover:bg-[#FAF8F4] -mx-1 px-1 rounded-lg transition-colors",children:[(0,a.jsx)(el.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}),j,v,b]}):(0,a.jsxs)("div",{children:[(0,a.jsxs)(r.$,{variant:"ghost",onClick:h?l:void 0,className:"w-full justify-start h-auto text-left flex items-center gap-2.5 py-4 ".concat(h?"cursor-pointer hover:bg-[#FAF8F4] -mx-1 px-1 rounded-lg":""," transition-colors"),children:[s?(0,a.jsx)(p.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}):(0,a.jsx)(m.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}),j,v,b]}),s&&h&&(0,a.jsxs)("div",{className:"pb-3 pl-5 space-y-3",children:[t.description&&(0,a.jsx)("p",{className:"text-[11px] leading-relaxed text-[#6B6B6B]",children:t.description}),u.length>0&&(0,a.jsxs)("div",{className:"rounded-lg bg-[#FAF8F4] p-3 space-y-2",children:[(0,a.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,a.jsx)(ei.A,{className:"h-3.5 w-3.5 text-[#888780]"}),(0,a.jsx)("span",{className:"text-[11px] font-semibold text-[#2C2C2C]",children:d("taskAcceptanceCriteria")})]}),(0,a.jsx)("div",{className:"space-y-1.5",children:u.map((e,t)=>(0,a.jsxs)("div",{className:"flex items-start justify-between gap-2",children:[(0,a.jsx)("p",{className:"text-[11px] leading-snug text-[#4A4A4A] flex-1",children:e.description}),!1!==e.required&&(0,a.jsx)("span",{className:"shrink-0 text-[10px] font-medium text-[#E65100]",children:o("required")})]},t))})]})]})]})}let eN=(0,s(66206).A)("message-square-text",[["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"}]]);var eA=s(60532),ey=s(97964);let eC=(0,ex.createServerReference)("401f6f6cb27a3ada1b9f397af1c4c7b946e70e09fe",ex.callServer,void 0,ex.findSourceMapURL,"getElaborationAction");function ew(e){let{idea:t,proposals:s,tasks:i,onSelectTask:r}=e,c=(0,n.c)("ideaTracker"),d=(0,n.c)(),[x,u]=(0,l.useState)(null),[h,f]=(0,l.useState)(new Set);(0,l.useEffect)(()=>{"open"!==t.status&&eC(t.uuid).then(e=>{e.success&&e.data&&u(e.data)})},[t.uuid,t.status]);let g=(0,l.useMemo)(()=>"open"===t.status?"idea_created":"elaborating"===t.status||0===s.length?"elaboration":s.some(e=>"approved"===e.status)&&i.length>0?"tasks":"proposal",[t.status,s,i]),j=(0,l.useMemo)(()=>{let e=["idea_created","elaboration","proposal","tasks"],t=e.indexOf(g);return e.map((e,s)=>({id:e,labelKey:({idea_created:"panel.timeline.ideaCreated",elaboration:"panel.timeline.elaboration",proposal:"panel.timeline.proposal",tasks:"panel.timeline.tasksProgress"})[e],status:s<t?"completed":s===t?"active":"upcoming",icon:({idea_created:(0,a.jsx)(o.A,{className:"h-3.5 w-3.5"}),elaboration:(0,a.jsx)(eN,{className:"h-3.5 w-3.5"}),proposal:(0,a.jsx)(_.A,{className:"h-3.5 w-3.5"}),tasks:(0,a.jsx)(ei.A,{className:"h-3.5 w-3.5"})})[e]}))},[g]);(0,l.useEffect)(()=>{let e=j.find(e=>"active"===e.status);e&&f(new Set([e.id]))},[g]);let v=(0,l.useCallback)(e=>{f(t=>{let s=new Set(t);return s.has(e)?s.delete(e):s.add(e),s})},[]),b=(0,l.useMemo)(()=>"open"===t.status?c("panel.timeline.noElaboration"):"skipped"===t.elaborationStatus?c("panel.timeline.elaborationSkipped"):"resolved"===t.elaborationStatus&&x?c("panel.timeline.elaborationComplete",{count:x.summary.totalQuestions}):"elaborating"===t.status?c("panel.timeline.elaborationInProgress"):x&&x.summary.totalQuestions>0?c("panel.timeline.elaborationComplete",{count:x.summary.totalQuestions}):c("panel.timeline.noElaboration"),[t.status,t.elaborationStatus,x,c]),N=(0,l.useMemo)(()=>{if(0===s.length)return c("panel.timeline.noProposal");let e=s.filter(e=>"approved"===e.status).length,t=s.filter(e=>"pending"===e.status).length;if(e>0&&1===s.length)return c("panel.timeline.proposalApproved");if(e>0)return c("panel.timeline.proposalsApproved",{count:e,total:s.length});if(t>0)return c("panel.timeline.proposalPending");switch(s[0].status){case"draft":default:return c("panel.timeline.proposalDraft");case"rejected":return c("panel.timeline.proposalRejected")}},[s,c]),A=(0,l.useMemo)(()=>{let e=0,t=0;for(let r of s){var a,n,l,i;e+=null!=(l=null==(a=r.documentDrafts)?void 0:a.length)?l:0,t+=null!=(i=null==(n=r.taskDrafts)?void 0:n.length)?i:0}return{docCount:e,taskDraftCount:t}},[s]),y=(0,l.useMemo)(()=>{let e=i.filter(e=>"done"===e.status||"closed"===e.status).length,t=i.filter(e=>"in_progress"===e.status).length;return{done:e,inProgress:t,toVerify:i.filter(e=>"to_verify"===e.status).length,open:i.filter(e=>"open"===e.status||"assigned"===e.status).length,total:i.length}},[i]);return(0,a.jsx)("div",{className:"space-y-0",children:j.map((e,n)=>{let l=h.has(e.id),o=n===j.length-1;return(0,a.jsxs)("div",{className:"flex gap-3",children:[(0,a.jsxs)("div",{className:"flex flex-col items-center w-5 shrink-0",children:[(0,a.jsx)("div",{className:"mt-1",children:"completed"===e.status?(0,a.jsx)("div",{className:"h-5 w-5 rounded-full bg-[#E0F2F1] flex items-center justify-center",children:(0,a.jsx)(eA.A,{className:"h-3 w-3 text-[#00796B]"})}):"active"===e.status?(0,a.jsx)("div",{className:"h-5 w-5 rounded-full bg-[#C67A52] flex items-center justify-center",children:(0,a.jsx)(ey.A,{className:"h-2 w-2 fill-white text-white"})}):(0,a.jsx)("div",{className:"h-5 w-5 rounded-full border-2 border-dashed border-[#D9D9D9] flex items-center justify-center",children:(0,a.jsx)(ey.A,{className:"h-2 w-2 text-[#D9D9D9]"})})}),!o&&(0,a.jsx)("div",{className:"flex-1 w-px bg-[#E5E0D8] mt-1 min-h-[8px]"})]}),(0,a.jsxs)("div",{className:"flex-1 min-w-0 ".concat(o?"pb-0":"pb-4"),children:[(0,a.jsxs)("button",{onClick:()=>v(e.id),className:"flex items-center gap-1.5 w-full text-left group cursor-pointer",children:[l?(0,a.jsx)(p.A,{className:"h-3.5 w-3.5 text-[#9A9A9A] shrink-0"}):(0,a.jsx)(m.A,{className:"h-3.5 w-3.5 text-[#9A9A9A] shrink-0"}),(0,a.jsx)("span",{className:"text-[13px] font-medium ".concat("active"===e.status?"text-[#C67A52]":"completed"===e.status?"text-[#2C2C2C]":"text-[#9A9A9A]"),children:c(e.labelKey)}),!l&&(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A] truncate ml-1",children:(e=>{switch(e.id){case"idea_created":return t.createdBy?t.createdBy.name:"";case"elaboration":return b;case"proposal":return N;case"tasks":return i.length>0?c("panel.timeline.tasksComplete",{done:y.done,total:y.total}):c("panel.timeline.noTasks");default:return""}})(e)})]}),(e=>{let n=h.has(e.id);switch(e.id){case"idea_created":return n?(0,a.jsxs)("div",{className:"mt-2 space-y-1.5",children:[t.createdBy&&(0,a.jsx)("p",{className:"text-[12px] text-[#6B6B6B]",children:c("panel.timeline.createdBy",{name:t.createdBy.name})}),(0,a.jsx)("p",{className:"text-[12px] text-[#9A9A9A]",children:(0,B.fw)(t.createdAt,d)}),t.content&&(0,a.jsxs)("p",{className:"text-[12px] text-[#6B6B6B] line-clamp-2",children:[t.content.slice(0,120),t.content.length>120?"...":""]})]}):null;case"elaboration":return n?(0,a.jsxs)("div",{className:"mt-2 space-y-1.5",children:[(0,a.jsx)("p",{className:"text-[12px] text-[#6B6B6B]",children:b}),x&&x.rounds.length>0&&(0,a.jsx)("p",{className:"text-[12px] text-[#9A9A9A]",children:c("panel.timeline.rounds",{count:x.rounds.length})})]}):null;case"proposal":return n?(0,a.jsxs)("div",{className:"mt-2 space-y-1.5",children:[(0,a.jsx)("p",{className:"text-[12px] text-[#6B6B6B]",children:N}),s.length>0&&(0,a.jsxs)("div",{className:"space-y-1",children:[A.docCount>0&&(0,a.jsxs)("div",{className:"flex items-center gap-1.5 text-[12px] text-[#9A9A9A]",children:[(0,a.jsx)(T.A,{className:"h-3 w-3"}),(0,a.jsx)("span",{children:c("panel.timeline.documents",{count:A.docCount})})]}),A.taskDraftCount>0&&(0,a.jsxs)("div",{className:"flex items-center gap-1.5 text-[12px] text-[#9A9A9A]",children:[(0,a.jsx)(ei.A,{className:"h-3 w-3"}),(0,a.jsx)("span",{children:c("panel.timeline.tasks",{count:A.taskDraftCount})})]})]})]}):null;case"tasks":return n?(0,a.jsx)("div",{className:"mt-2 space-y-2",children:0===i.length?(0,a.jsx)("p",{className:"text-[12px] text-[#9A9A9A]",children:c("panel.timeline.noTasks")}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsxs)("div",{className:"flex-1 h-1.5 rounded-full bg-[#F0EDE8] overflow-hidden flex",children:[y.done>0&&(0,a.jsx)("div",{className:"h-full bg-[#00796B]",style:{width:"".concat(y.done/y.total*100,"%")}}),y.inProgress>0&&(0,a.jsx)("div",{className:"h-full bg-[#1976D2]",style:{width:"".concat(y.inProgress/y.total*100,"%")}}),y.toVerify>0&&(0,a.jsx)("div",{className:"h-full bg-[#7B1FA2]",style:{width:"".concat(y.toVerify/y.total*100,"%")}})]}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A] shrink-0",children:c("panel.timeline.tasksComplete",{done:y.done,total:y.total})})]}),(0,a.jsxs)("div",{className:"space-y-1",children:[i.slice(0,5).map(e=>(0,a.jsxs)("button",{onClick:()=>r(e.uuid),className:"flex items-center gap-2 w-full text-left rounded-md px-2 py-1.5 hover:bg-[#F5F2EC] transition-colors group cursor-pointer",children:[(0,a.jsx)(el.A,{className:"h-3 w-3 text-[#D9D9D9] shrink-0 group-hover:text-[#C67A52]"}),(0,a.jsx)("span",{className:"h-2 w-2 rounded-full shrink-0 ".concat((0,B.eT)(e.status))}),(0,a.jsx)("span",{className:"flex-1 text-[12px] text-[#2C2C2C] truncate group-hover:text-[#C67A52]",children:e.title})]},e.uuid)),i.length>5&&(0,a.jsx)("p",{className:"text-[11px] text-[#9A9A9A] px-2",children:c("panel.timeline.moreItems",{count:i.length-5})})]})]})}):null;default:return null}})(e)]})]},e.id)})})}let ek=(0,ex.createServerReference)("6013cbc19aa3119a1c2af52cfdd66bdda2781c7891",ex.callServer,void 0,ex.findSourceMapURL,"getReportsForIdeaAction");function eE(e){let{projectUuid:t,ideaUuid:s,proposals:i,onDocClick:c}=e,d=(0,n.c)("idea"),o=(0,n.c)("documents"),[x,p]=(0,l.useState)([]),[m,h]=(0,l.useState)(!0),f=i.some(e=>"approved"===e.status),g=(0,l.useCallback)(async()=>{if(!f){p([]),h(!1);return}try{let e=await ek(t,s);if(e.success){let t=[...e.data].sort((e,t)=>new Date(t.createdAt).getTime()-new Date(e.createdAt).getTime());p(t.map(e=>{var t;return{uuid:e.uuid,title:e.title,type:e.type,content:null!=(t=e.content)?t:null,createdAt:e.createdAt}}))}}catch(e){em.q.error("Failed to fetch reports for idea:",e)}finally{h(!1)}},[t,s,f]);return((0,l.useEffect)(()=>{h(!0),g()},[g]),(0,u.eV)("document",g),m)?f?(0,a.jsx)("div",{className:"flex items-center justify-center py-3",children:(0,a.jsx)(S.A,{className:"h-4 w-4 animate-spin text-[#C67A52]"})}):null:0===x.length?null:(0,a.jsxs)("div",{className:"mt-6 space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-baseline gap-2",children:[(0,a.jsx)("span",{className:"text-[11px] font-semibold uppercase tracking-[1px] text-[#9A9A9A]",children:d("reportsList")}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:x.length}),(0,a.jsxs)("span",{className:"text-[11px] text-[#B4B2A9]",children:["\xb7 ",d("reportsAcrossProposals")]})]}),(0,a.jsx)("div",{className:"space-y-0",children:x.map(e=>(0,a.jsxs)(r.$,{variant:"ghost",className:"w-full justify-start h-auto text-left flex items-center gap-2.5 py-3.5 hover:bg-[#FAF8F4] transition-colors cursor-pointer -mx-1 px-1 rounded-lg",onClick:()=>{var t;return c({title:e.title,type:"report",content:null!=(t=e.content)?t:""})},children:[(0,a.jsx)(el.A,{className:"h-3.5 w-3.5 shrink-0 text-[#B4B2A9]"}),(0,a.jsx)(O.E,{variant:"outline",className:"shrink-0 text-[10px] font-medium border-[#E5E0D8] text-[#6B6B6B] bg-[#F5F2EC] px-2 py-0.5 font-mono",children:o(eo[e.type]||"typeOther")}),(0,a.jsx)("span",{className:"flex-1 min-w-0 text-left text-[13px] text-[#2C2C2A] truncate",children:e.title})]},e.uuid))})]})}var eF=s(76677);let eB=["in_progress","to_verify","open","assigned","done","closed"];function eS(e){let{tasks:t,projectUuid:s,proposalUuids:i,onSelectTask:r}=e,c=(0,n.c)("ideaTracker"),[d,o]=(0,l.useState)({}),x=(0,l.useMemo)(()=>t.map(e=>e.uuid),[t]),h=(0,l.useCallback)(async()=>{if(0===x.length)return;let e=await (0,eF.h)(x);e.success&&e.data&&o(e.data)},[x]);(0,l.useEffect)(()=>{h()},[h]),(0,u.eV)("task",h);let g=(0,l.useMemo)(()=>{let e=[];for(let s of eB){let a=t.filter(e=>e.status===s);a.length>0&&e.push({status:s,tasks:a})}let s=new Set(eB),a=t.filter(e=>!s.has(e.status));return a.length>0&&e.push({status:"other",tasks:a}),e},[t]),[j,v]=(0,l.useState)(new Set),b=(0,l.useMemo)(()=>{let e=t.length,s=t.filter(e=>"done"===e.status||"closed"===e.status).length,a=0,n=0,l=0,i=0;for(let e of t)e.acceptanceSummary&&(a+=e.acceptanceSummary.total,n+=e.acceptanceSummary.passed,l+=e.acceptanceSummary.required,i+=e.acceptanceSummary.requiredPassed);return{total:e,done:s,acTotal:a,acPassed:n,acRequired:l,acRequiredPassed:i}},[t]);return 0===t.length?(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center gap-3 py-12 text-center",children:[(0,a.jsx)(ei.A,{className:"h-8 w-8 text-[#D9D9D9]"}),(0,a.jsx)("p",{className:"text-sm text-[#9A9A9A]",children:c("panel.taskList.noTasks")})]}):(0,a.jsxs)("div",{className:"space-y-3",children:[(0,a.jsxs)("div",{className:"flex items-center gap-3 rounded-lg bg-[#FAFAF7] px-3 py-2",children:[(0,a.jsx)("span",{className:"text-[12px] text-[#6B6B6B]",children:c("panel.taskList.summary",{done:b.done,total:b.total})}),b.acTotal>0&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"text-[12px] text-[#D9D9D9]",children:"\xb7"}),(0,a.jsx)("span",{className:"text-[12px] text-[#6B6B6B]",children:c("panel.taskList.acSummary",{passed:b.acRequiredPassed,total:b.acRequired})})]}),i.length>0&&(0,a.jsxs)(E(),{href:"/projects/".concat(s,"/tasks?proposalUuids=").concat(i.join(",")),className:"ml-auto flex items-center gap-1 text-[13px] font-medium text-[#C67A52] shrink-0",children:[c("panel.taskList.viewKanban"),(0,a.jsx)(m.A,{className:"h-3.5 w-3.5"})]})]}),g.map(e=>{let t=j.has(e.status);return(0,a.jsxs)("div",{children:[(0,a.jsxs)("button",{onClick:()=>{var t;return t=e.status,void v(e=>{let s=new Set(e);return s.has(t)?s.delete(t):s.add(t),s})},className:"flex items-center gap-2 w-full text-left py-1.5 group cursor-pointer",children:[t?(0,a.jsx)(m.A,{className:"h-3.5 w-3.5 text-[#9A9A9A]"}):(0,a.jsx)(p.A,{className:"h-3.5 w-3.5 text-[#9A9A9A]"}),(0,a.jsx)("span",{className:"h-2 w-2 rounded-full shrink-0 ".concat((0,B.eT)(e.status))}),(0,a.jsx)("span",{className:"text-[13px] font-medium text-[#2C2C2C]",children:function(e,t){switch(e){case"in_progress":return t("panel.taskList.inProgress");case"to_verify":return t("panel.taskList.toVerify");case"open":return t("panel.taskList.open");case"assigned":return t("panel.taskList.assigned");case"done":return t("panel.taskList.done");case"closed":return t("panel.taskList.closed");default:return e}}(e.status,c)}),(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A] ml-auto",children:e.tasks.length})]}),!t&&(0,a.jsx)("div",{className:"ml-3 space-y-0.5",children:e.tasks.map(e=>{let t=d[e.uuid]||0,s=e.acceptanceSummary;return(0,a.jsx)(f.D,{entityType:"task",entityUuid:e.uuid,badgeInside:!0,children:(0,a.jsxs)("button",{onClick:()=>r(e.uuid),className:"flex items-center gap-2 w-full text-left rounded-md px-2.5 py-2 hover:bg-[#F5F2EC] transition-colors group cursor-pointer",children:[(0,a.jsx)(el.A,{className:"h-3.5 w-3.5 text-[#D9D9D9] shrink-0 group-hover:text-[#C67A52]"}),(0,a.jsx)("span",{className:"h-1.5 w-1.5 rounded-full shrink-0 ".concat((0,B.eT)(e.status))}),(0,a.jsx)("span",{className:"flex-1 text-[13px] text-[#2C2C2C] truncate group-hover:text-[#C67A52]",children:e.title}),s&&s.total>0&&(0,a.jsxs)("span",{className:"inline-flex items-center gap-0.5 shrink-0 rounded-full bg-[#F0EDE8] px-1.5 py-0.5 text-[10px] text-[#6B6B6B]",children:[(0,a.jsx)(eA.A,{className:"h-2.5 w-2.5"}),s.requiredPassed,"/",s.required]}),e.assignee&&(0,a.jsxs)("span",{className:"shrink-0 inline-flex items-center gap-1 text-[10px] text-[#9A9A9A] max-w-[72px] truncate",title:e.assignee.name,children:[(0,a.jsx)(q.A,{className:"h-2.5 w-2.5 shrink-0"}),e.assignee.name.split(/[@\s]/)[0]]}),t>0&&(0,a.jsx)("span",{className:"inline-flex items-center justify-center h-4 min-w-[16px] rounded-full bg-[#E8F5E9] text-[#2E7D32] text-[9px] font-semibold shrink-0",title:c("panel.taskList.workersActive",{count:t}),children:t})]})},e.uuid)})})]},e.status)})]})}var eD=s(35680);function e_(e){let{ideaUuid:t}=e,s=(0,n.c)(),[i,r]=(0,l.useState)([]),[c,d]=(0,l.useState)(!0),o=(0,l.useCallback)(async()=>{d(!0),r((await (0,eD.x)(t)).activities),d(!1)},[t]);return(0,l.useEffect)(()=>{o()},[o]),(0,a.jsxs)("div",{className:"mt-5",children:[(0,a.jsx)(G.J,{className:"text-[11px] font-medium uppercase tracking-wider text-[#9A9A9A]",children:s("common.activity")}),(0,a.jsx)("div",{className:"mt-2",children:c?(0,a.jsx)("div",{className:"flex items-center justify-center py-4",children:(0,a.jsx)(S.A,{className:"h-4 w-4 animate-spin text-[#9A9A9A]"})}):0===i.length?(0,a.jsx)("p",{className:"text-sm text-[#9A9A9A] italic",children:s("common.noActivity")}):i.map((e,t)=>(0,a.jsxs)("div",{className:"flex items-stretch gap-2.5",children:[(0,a.jsxs)("div",{className:"flex flex-col items-center w-2 shrink-0",children:[(0,a.jsx)("div",{className:"mt-1.5 h-2 w-2 shrink-0 rounded-full border-[1.5px] border-[#D9D9D9] bg-white"}),t<i.length-1&&(0,a.jsx)("div",{className:"flex-1 w-px bg-[#E5E0D8] mt-1"})]}),(0,a.jsxs)("div",{className:"flex-1 pb-3",children:[(0,a.jsx)("p",{className:"text-[13px] text-[#2C2C2C]",children:function(e,t){let{action:s,actorName:a}=e;switch(s){case"created":case"idea_created":return t("activity.ideaCreated",{actor:a});case"assigned":case"idea_assigned":return t("activity.ideaAssigned",{actor:a});case"claimed":case"idea_claimed":return t("activity.ideaClaimed",{actor:a});case"released":case"idea_released":return t("activity.ideaReleased",{actor:a});case"status_changed":case"idea_status_changed":return t("activity.ideaStatusChanged",{actor:a});case"elaboration_started":return t("activity.elaborationStarted",{actor:a});case"elaboration_answered":return t("activity.elaborationAnswered",{actor:a});case"elaboration_skipped":return t("activity.elaborationSkipped",{actor:a});case"elaboration_resolved":return t("activity.elaborationResolved",{actor:a});case"elaboration_followup":return t("activity.elaborationFollowup",{actor:a});default:return t("activity.genericAction",{actor:a,action:s})}}(e,s)}),(0,a.jsx)("p",{className:"text-[11px] text-[#9A9A9A]",children:(0,B.fw)(e.createdAt,s)})]})]},e.uuid))})]})}var eT=s(72642);function eU(e){let{ideaUuid:t,currentUserUuid:s,commentCount:i,onCommentCountChange:r}=e,c=(0,n.c)("ideaTracker"),[d,o]=(0,l.useState)("comments");return(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"flex gap-1 rounded-lg bg-[#F5F2EC] p-0.5",children:[(0,a.jsxs)("button",{onClick:()=>o("comments"),className:"flex-1 rounded-md px-3 py-1.5 text-[13px] font-medium transition-colors flex items-center justify-center gap-1.5 cursor-pointer ".concat("comments"===d?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:[c("panel.activityTab.comments"),i>0&&(0,a.jsx)("span",{className:"inline-flex items-center justify-center min-w-[18px] h-[18px] px-1 rounded-full bg-[#F5F2EC] text-[#6B6B6B] text-[10px] font-semibold leading-none",children:i})]}),(0,a.jsx)("button",{onClick:()=>o("activity"),className:"flex-1 rounded-md px-3 py-1.5 text-[13px] font-medium transition-colors cursor-pointer ".concat("activity"===d?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:c("panel.activityTab.activity")})]}),(0,a.jsx)("div",{children:"activity"===d?(0,a.jsx)(e_,{ideaUuid:t}):(0,a.jsx)(eT.$,{targetType:"idea",targetUuid:t,currentUserUuid:s,onCountChange:r,compact:!0})})]})}var eM=s(91418),eR=s(70633);function eP(e){let{title:t,type:s,content:i,mode:c="overlay",onClose:d,onBack:o}=e,x=(0,n.c)("documents"),[u,p]=(0,l.useState)(!1);(0,l.useEffect)(()=>{let e=setTimeout(()=>p(!0),300);return()=>clearTimeout(e)},[]),(0,l.useEffect)(()=>{let e=e=>{"Escape"!==e.key||e.defaultPrevented||(e.preventDefault(),d())};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[d]);let m="sidebyside"===c;return(0,a.jsxs)(a.Fragment,{children:[!m&&(0,a.jsx)("div",{className:"fixed inset-0 z-40 bg-black/20",onClick:d}),(0,a.jsxs)("div",{className:"fixed top-14 md:top-0 flex h-[calc(100%-3.5rem)] md:h-full w-full flex-col bg-white shadow-xl border-l border-[#E5E0D8] ".concat(m?"z-40 ".concat(u?"":"animate-in slide-in-from-right duration-300"):"z-50 right-0 ".concat(u?"":"animate-in slide-in-from-right duration-300")),style:{width:"min(100%, ".concat(B.L8,"px)"),...m?{right:"".concat(B.L8,"px")}:{}},children:[(0,a.jsxs)("div",{className:"flex items-center justify-between border-b border-[#F5F2EC] px-6 py-5",children:[o&&(0,a.jsx)(r.$,{variant:"ghost",size:"icon",className:"mr-2 h-8 w-8 shrink-0",onClick:o,children:(0,a.jsx)(eR.A,{className:"h-4 w-4 text-[#6B6B6B]"})}),(0,a.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-[#2C2C2C] truncate",children:t}),(0,a.jsx)("div",{className:"mt-1.5",children:(0,a.jsx)(O.E,{variant:"outline",className:"text-[10px] font-medium border-[#E5E0D8] text-[#6B6B6B] bg-[#F5F2EC] px-2 py-0.5 font-mono",children:x(eo[s]||"typeOther")})})]}),(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"ml-4 h-8 w-8 shrink-0 border-[#E5E0D8]",onClick:d,children:(0,a.jsx)(L.A,{className:"h-4 w-4 text-[#6B6B6B]"})})]}),(0,a.jsx)(V.F,{className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:(0,a.jsx)("div",{className:"px-6 py-5 text-[13px] leading-relaxed text-[#2C2C2A] prose prose-sm max-w-none [&_h1]:text-lg [&_h1]:font-semibold [&_h1]:mt-4 [&_h1]:mb-2 [&_h2]:text-base [&_h2]:font-semibold [&_h2]:mt-3 [&_h2]:mb-1.5 [&_h3]:text-sm [&_h3]:font-medium [&_h3]:mt-2 [&_h3]:mb-1 [&_p]:text-[13px] [&_p]:text-[#4A4A4A] [&_p]:my-1.5 [&_li]:text-[13px] [&_li]:text-[#4A4A4A] [&_ul]:my-1 [&_ol]:my-1 [&_strong]:text-[#2C2C2C] [&_code]:text-[12px] [&_code]:bg-[#F5F2EC] [&_code]:px-1 [&_code]:py-0.5 [&_code]:rounded [&_pre]:bg-[#FAF8F4] [&_pre]:p-3 [&_pre]:rounded-lg [&_pre]:my-2",children:(0,a.jsx)(Y.MarkdownContent,{children:ed(i)})})})]})]})}var ez=s(98480),eI=s(71645),eL=s(77381);let eq=(0,ex.createServerReference)("408d014f9a96037a922b7e6bf7e3cf1e0e28a96577",ex.callServer,void 0,ex.findSourceMapURL,"getIdeaAction"),e$=(0,ex.createServerReference)("40106e9c885a122b86951906d0e2409f8e4a62031b",ex.callServer,void 0,ex.findSourceMapURL,"getTaskAction");var eV=s(10836);function eO(e){let{ideaUuid:t,projectUuid:s,currentUserUuid:i,onClose:c}=e,d=(0,n.c)(),o=(0,n.c)("ideaTracker"),x=(0,n.c)("status"),p=(0,P.useRouter)(),[m,h]=(0,l.useState)(null),[f,j]=(0,l.useState)(!0),[v,b]=(0,l.useState)(null),[N,A]=(0,l.useState)([]),[y,C]=(0,l.useState)([]),[w,k]=(0,l.useState)("overview"),[E,F]=(0,l.useState)(new Set(["overview"])),[D,_]=(0,l.useState)(!1),[T,U]=(0,l.useState)(0),[M,R]=(0,l.useState)(!1),[Z,Q]=(0,l.useState)(!1),[W,X]=(0,l.useState)(!1),[Y,ee]=(0,l.useState)(""),[et,es]=(0,l.useState)(""),[ea,el]=(0,l.useState)(!1),[ei,er]=(0,l.useState)(null),[ec,ed]=(0,l.useState)(!1),[eo,ex]=(0,l.useState)(null),[ef,eg]=(0,l.useState)(null),[ej,ev]=(0,l.useState)(null),eb=(0,l.useCallback)(e=>{ev(null),ex(e)},[]),eN=(0,l.useCallback)(e=>{ex(null),eg(null),ev(e)},[]),[eA,ey]=(0,l.useState)(!1);(0,l.useEffect)(()=>{let e=window.matchMedia("(min-width: 960px)");ey(e.matches);let t=e=>ey(e.matches);return e.addEventListener("change",t),()=>e.removeEventListener("change",t)},[]);let[eC,ek]=(0,l.useState)(!1);(0,l.useEffect)(()=>{let e=setTimeout(()=>ek(!0),300);return()=>clearTimeout(e)},[]);let eF=(0,l.useCallback)(e=>{let t=new URLSearchParams(window.location.search);t.set("tab",e),window.history.replaceState(null,"","".concat(window.location.pathname,"?").concat(t.toString()))},[]),eB=(0,l.useCallback)(async()=>{try{let e=await eq(t);e.success?(h(e.data),b(null)):b(o("Not found"===e.error?"panel.notFound":"panel.loadFailed"))}catch(e){b(o("panel.loadFailed"))}finally{j(!1)}},[t,o]);(0,l.useEffect)(()=>{j(!0),eB()},[eB]),(0,u.eV)("idea",eB),(0,u.eV)("proposal",eB),(0,u.eV)("task",eB);let eD=null==m?void 0:m.uuid,e_=null==m?void 0:m.status,eT=(0,l.useCallback)(async()=>{if(!eD||"open"===e_)return void A([]);try{let e=await eu(s,eD);e.success&&A(e.data)}catch(e){em.q.error("Failed to fetch proposals:",e)}},[s,eD,e_]);(0,l.useEffect)(()=>{eT()},[eT]),(0,u.eV)("proposal",eT);let eR=(0,l.useCallback)(async()=>{let e=N.filter(e=>"approved"===e.status);if(0===e.length)return void C([]);try{let t=(await Promise.all(e.map(e=>ep(s,e.uuid)))).flatMap(e=>e.success&&e.data?e.data.map(e=>{var t,s,a;return{uuid:e.uuid,title:e.title,status:e.status,commentCount:null!=(t=e.commentCount)?t:0,assignee:null!=(s=e.assignee)?s:null,acceptanceSummary:null!=(a=e.acceptanceSummary)?a:null}}):[]);C(t)}catch(e){em.q.error("Failed to fetch tasks:",e)}},[s,N]);(0,l.useEffect)(()=>{eR()},[eR]),(0,u.eV)("task",eR);let eO=(0,l.useMemo)(()=>m?function(e,t,s){let a=["overview"];return a.push("elaboration"),t.length>0&&a.push("proposal"),s.length>0&&a.push("tasks"),a.push("activity"),a}(0,N,y):["overview","activity"],[m,N,y]),eH=(0,l.useRef)(new URLSearchParams(window.location.search).get("tab")),eJ=m?function(e){switch(e){case"open":case"researching":case"answer_questions":return"elaboration";case"planning":case"review_proposal":return"proposal";case"building":case"verify_work":return"tasks";default:return"overview"}}(m.badgeHint):"overview";(0,l.useEffect)(()=>{let e;if(!m||D)return;let t=eH.current;if(t)if(!eO.includes(t))return;else e=t,eH.current=null,_(!0);else if(eO.includes(eJ))e=eJ;else{if("overview"!==eJ)return;e="overview"}k(e),F(t=>new Set([...t,e])),eF(e)},[null==m?void 0:m.uuid,eJ,eO]),(0,l.useEffect)(()=>{_(!1)},[t]),(0,l.useEffect)(()=>{eO.includes(w)||k("overview")},[eO,w]);let eG=(0,l.useMemo)(()=>y.filter(e=>"in_progress"===e.status||"assigned"===e.status||"to_verify"===e.status).length,[y]),eK=(0,l.useCallback)(()=>{if(!eo)return void eg(null);e$(eo).then(e=>{e.success&&eg(e.data)}).catch(e=>em.q.error("Failed to load task details:",e))},[eo]);(0,l.useEffect)(()=>{eK()},[eK]),(0,u.eV)("task",eK),(0,l.useEffect)(()=>{X(!1),ee((null==m?void 0:m.title)||""),es((null==m?void 0:m.content)||""),er(null)},[null==m?void 0:m.uuid,null==m?void 0:m.title,null==m?void 0:m.content]);let eZ=()=>{X(!1),ee((null==m?void 0:m.title)||""),es((null==m?void 0:m.content)||""),er(null)},eQ=async()=>{if(!m||!Y.trim())return void er(d("ideas.titleRequired"));el(!0),er(null);let e=await (0,eI.J)({ideaUuid:m.uuid,projectUuid:s,title:Y.trim(),content:et.trim()||null});el(!1),e.success?(X(!1),await eB(),p.refresh()):er(e.error||d("ideas.updateFailed"))},eW=async()=>{if(!m)return;Q(!0);let e=await (0,eL.Z)(m.uuid,s);Q(!1),e.success&&(c(),p.refresh())},eX=(null==m?void 0:m.derivedStatus)||"todo",eY=!!m&&"elaborated"!==m.status,e0=(null==m?void 0:m.elaborationStatus)==="resolved",e2=(null==m?void 0:m.status)==="elaborating"&&!e0;return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"fixed inset-0 z-40 bg-black/20",onClick:c}),(0,a.jsxs)("div",{className:"fixed right-0 top-14 md:top-0 z-50 flex h-[calc(100%-3.5rem)] md:h-full w-full md:w-[480px] flex-col bg-white shadow-xl border-l border-[#E5E0D8] ".concat(eC?"":"animate-in slide-in-from-right duration-300"),children:[(0,a.jsxs)("div",{className:"flex items-center justify-between border-b border-[#F5F2EC] px-6 py-5",children:[(0,a.jsx)("div",{className:"flex-1 min-w-0",children:f?(0,a.jsx)("div",{className:"h-5 w-40 animate-pulse rounded bg-[#F5F2EC]"}):m?W?(0,a.jsx)("h2",{className:"text-base font-semibold text-[#2C2C2C]",children:d("ideas.editIdea")}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("h2",{className:"text-base font-semibold text-[#2C2C2C] truncate",children:m.title}),(0,a.jsxs)("div",{className:"mt-1.5 flex items-center gap-2",children:[(0,a.jsx)(O.E,{className:B._5[eX]||B._5.todo,children:m.badgeHint?o("badge.".concat(B.Wl[m.badgeHint]||"open")):x(B.Bj[eX]||"todo")}),(0,a.jsx)("span",{className:"text-xs text-[#9A9A9A]",children:(0,g.r)(m.createdAt)})]})]}):(0,a.jsx)("h2",{className:"text-base font-semibold text-[#2C2C2C]",children:o("panel.notFound")})}),(0,a.jsxs)("div",{className:"flex items-center gap-2 ml-4",children:[m&&!W&&(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"h-8 w-8 border-[#E5E0D8]",onClick:()=>ed(!0),title:d("ideas.actions.move"),"aria-label":d("ideas.actions.move"),children:(0,a.jsx)(z.A,{className:"h-4 w-4 text-[#6B6B6B]"})}),m&&"elaborated"!==m.status&&!W&&(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"h-8 w-8 border-[#E5E0D8]",onClick:()=>{m&&(ee(m.title),es(m.content||""),er(null),X(!0))},title:d("ideas.editIdea"),children:(0,a.jsx)(I.A,{className:"h-4 w-4 text-[#6B6B6B]"})}),(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"h-8 w-8 border-[#E5E0D8]",onClick:W?eZ:c,children:(0,a.jsx)(L.A,{className:"h-4 w-4 text-[#6B6B6B]"})})]})]}),m&&!f&&!W&&(0,a.jsx)("div",{className:"border-b border-[#F5F2EC] px-6",children:(0,a.jsx)("div",{className:"flex gap-0 -mb-px",children:eO.map(e=>(0,a.jsxs)("button",{onClick:()=>{k(e),_(!0),F(t=>new Set([...t,e])),eF(e)},className:"relative flex items-center gap-1.5 px-3 py-2.5 text-[13px] font-medium transition-colors cursor-pointer ".concat(w===e?"text-[#C67A52] border-b-2 border-[#C67A52]":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:[o("panel.tabs.".concat(e)),"tasks"===e&&eG>0&&(0,a.jsx)("span",{className:"inline-flex items-center justify-center min-w-[18px] h-[18px] px-1 rounded-full bg-[#E3F2FD] text-[#1976D2] text-[10px] font-semibold leading-none",children:eG}),"activity"===e&&T>0&&(0,a.jsx)("span",{className:"inline-flex items-center justify-center min-w-[18px] h-[18px] px-1 rounded-full bg-[#F5F2EC] text-[#6B6B6B] text-[10px] font-semibold leading-none",children:T})]},e))})}),(0,a.jsx)(V.F,{className:"flex-1 min-h-0 [&_[data-slot=scroll-area-viewport]>div]:!block",children:(0,a.jsx)("div",{className:"flex min-h-full flex-col px-6 py-5",children:f?(0,a.jsxs)("div",{className:"flex flex-1 items-center justify-center py-12",children:[(0,a.jsx)(S.A,{className:"h-6 w-6 animate-spin text-[#C67A52]"}),(0,a.jsx)("span",{className:"ml-2 text-sm text-[#9A9A9A]",children:o("loading")})]}):v?(0,a.jsx)("div",{className:"flex flex-1 items-center justify-center py-12",children:(0,a.jsx)("p",{className:"text-sm text-[#9A9A9A]",children:v})}):m?W?(0,a.jsxs)("div",{className:"space-y-5",children:[ei&&(0,a.jsx)("div",{className:"rounded-lg bg-destructive/10 p-3 text-sm text-destructive",children:ei}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(G.J,{htmlFor:"edit-title",className:"text-[13px] font-medium text-[#2C2C2C]",children:d("ideas.titleLabel")}),(0,a.jsx)(H.p,{id:"edit-title",value:Y,onChange:e=>ee(e.target.value),className:"border-[#E5E0D8] text-sm focus-visible:ring-[#C67A52]",autoFocus:!0})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(G.J,{htmlFor:"edit-content",className:"text-[13px] font-medium text-[#2C2C2C]",children:d("common.content")}),(0,a.jsx)(J.T,{id:"edit-content",value:et,onChange:e=>es(e.target.value),rows:8,className:"border-[#E5E0D8] text-sm resize-none focus-visible:ring-[#C67A52]"})]})]}):(0,a.jsxs)(a.Fragment,{children:[E.has("overview")&&(0,a.jsxs)("div",{style:{display:"overview"===w?"block":"none"},children:[(0,a.jsx)(ew,{idea:m,proposals:N,tasks:y,onSelectTask:eb}),(0,a.jsx)(eE,{projectUuid:s,ideaUuid:m.uuid,proposals:N,onDocClick:eN})]}),eO.includes("elaboration")&&E.has("elaboration")&&(0,a.jsx)("div",{style:{display:"elaboration"===w?"block":"none"},children:(0,a.jsx)(en,{idea:m,onRefresh:eB})}),eO.includes("proposal")&&E.has("proposal")&&(0,a.jsx)("div",{style:{display:"proposal"===w?"block":"none"},children:(0,a.jsx)(eh,{idea:m,projectUuid:s,onTaskClick:eb,onDocClick:eN,initialProposals:N})}),eO.includes("tasks")&&E.has("tasks")&&(0,a.jsx)("div",{style:{display:"tasks"===w?"block":"none"},children:(0,a.jsx)(eS,{tasks:y,projectUuid:s,proposalUuids:N.filter(e=>"approved"===e.status).map(e=>e.uuid),onSelectTask:eb})}),E.has("activity")&&(0,a.jsx)("div",{style:{display:"activity"===w?"block":"none"},children:(0,a.jsx)(eU,{ideaUuid:m.uuid,currentUserUuid:i,commentCount:T,onCommentCountChange:U})})]}):null})}),m&&!f&&(0,a.jsx)("div",{className:"border-t border-[#F5F2EC] px-6 py-4",children:W?(0,a.jsxs)("div",{className:"flex items-center justify-end gap-3",children:[(0,a.jsx)(r.$,{variant:"outline",className:"border-[#E5E0D8]",onClick:eZ,disabled:ea,children:d("common.cancel")}),(0,a.jsx)(r.$,{className:"bg-[#C67A52] hover:bg-[#B56A42] text-white",onClick:eQ,disabled:ea||!Y.trim(),children:ea?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(S.A,{className:"mr-2 h-4 w-4 animate-spin"}),d("common.save")]}):d("common.save")})]}):(0,a.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[eY&&(0,a.jsxs)(r.$,{variant:"outline",className:"shrink-0 border-[#E5E0D8] rounded-md px-4 py-2 text-[13px] font-medium",onClick:()=>R(!0),children:[(0,a.jsx)(q.A,{className:"mr-2 h-4 w-4"}),m.assignee?d("common.reassign"):d("common.assign")]}),(0,a.jsx)("div",{className:"flex-1 min-w-0",children:e2&&(0,a.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:d("elaboration.elaborationRequiredHint")})}),(0,a.jsxs)(K.Lt,{children:[(0,a.jsx)(K.tv,{asChild:!0,children:(0,a.jsx)(r.$,{variant:"outline",size:"icon",className:"shrink-0 h-8 w-8 border-[#E5E0D8] text-[#EF4444] hover:bg-[#FFEBEE] hover:text-[#EF4444] hover:border-[#EF4444]",children:(0,a.jsx)($.A,{className:"h-4 w-4"})})}),(0,a.jsxs)(K.EO,{children:[(0,a.jsxs)(K.wd,{children:[(0,a.jsx)(K.r7,{children:d("ideas.deleteIdea")}),(0,a.jsx)(K.$v,{children:d("ideas.deleteIdeaConfirm",{title:m.title})})]}),(0,a.jsxs)(K.ck,{children:[(0,a.jsx)(K.Zr,{children:d("common.cancel")}),(0,a.jsx)(K.Rx,{variant:"destructive",onClick:eW,disabled:Z,children:Z?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(S.A,{className:"mr-2 h-4 w-4 animate-spin"}),d("common.delete")]}):d("common.delete")})]})]})]})]})})]}),(0,a.jsx)(ez.h,{open:ec,onOpenChange:ed,ideaUuid:t,projectUuid:s,onMoved:()=>c()}),M&&m&&(0,a.jsx)(eV.i,{idea:{uuid:m.uuid,title:m.title,content:m.content,status:m.status,assignee:m.assignee?{type:m.assignee.type,uuid:m.assignee.uuid,name:m.assignee.name}:null},projectUuid:s,currentUserUuid:i,onClose:()=>{R(!1),eB()}}),eo&&ef&&(0,a.jsx)(eM.v,{task:ef,projectUuid:s,currentUserUuid:i,mode:eA?"sidebyside":"overlay",onClose:()=>{ex(null),eg(null)},onBack:()=>{ex(null),eg(null)}}),ej&&(0,a.jsx)(eP,{title:ej.title,type:ej.type,content:ej.content,mode:eA?"sidebyside":"overlay",onClose:()=>ev(null),onBack:()=>ev(null)})]})}var eH=s(97438),eJ=s(42305);function eG(e){let{open:t,onOpenChange:s,projectUuid:i,onCreated:c}=e,d=(0,n.c)("ideaTracker"),o=(0,n.c)("common"),[x,u]=(0,l.useState)(""),[p,m]=(0,l.useState)(""),[h,f]=(0,l.useState)(!1),[g,j]=(0,l.useState)(null),v=async()=>{let e=x.trim();if(e){f(!0),j(null);try{var t;let a=await fetch("/api/projects/".concat(i,"/ideas"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({title:e,content:p.trim()||void 0})}),n=await a.json();n.success&&(null==(t=n.data)?void 0:t.uuid)?(u(""),m(""),s(!1),null==c||c(n.data.uuid)):j(n.error||d("error.createFailed"))}catch(e){j(d("error.createFailed"))}finally{f(!1)}}};return(0,a.jsx)(eH.lG,{open:t,onOpenChange:s,children:(0,a.jsxs)(eH.Cf,{className:"sm:max-w-[480px]",children:[(0,a.jsx)(eH.c7,{children:(0,a.jsx)(eH.L3,{children:d("newIdea.title")})}),(0,a.jsxs)("div",{className:"space-y-4 py-2",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)(G.J,{htmlFor:"idea-title",children:d("newIdea.ideaTitle")}),(0,a.jsx)(H.p,{id:"idea-title",value:x,onChange:e=>u(e.target.value),placeholder:d("newIdea.titlePlaceholder"),autoFocus:!0,onKeyDown:e=>{!(0,eJ.P)(e)&&"Enter"===e.key&&!e.shiftKey&&x.trim()&&(e.preventDefault(),v())}})]}),(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsxs)(G.J,{htmlFor:"idea-content",children:[d("newIdea.description"),(0,a.jsxs)("span",{className:"ml-1 text-xs font-normal text-[#9A9A9A]",children:["(",o("optional"),")"]})]}),(0,a.jsx)(J.T,{id:"idea-content",value:p,onChange:e=>m(e.target.value),placeholder:d("newIdea.descriptionPlaceholder"),rows:4,className:"resize-none"})]}),g&&(0,a.jsx)("div",{className:"rounded-lg bg-destructive/10 px-3 py-2 text-[12px] text-destructive",children:g})]}),(0,a.jsxs)(eH.Es,{children:[(0,a.jsx)(r.$,{variant:"outline",onClick:()=>s(!1),disabled:h,children:o("cancel")}),(0,a.jsxs)(r.$,{onClick:v,disabled:h||!x.trim(),className:"bg-[#C67A52] hover:bg-[#B56A42] text-white",children:[h?(0,a.jsx)(S.A,{className:"mr-2 h-4 w-4 animate-spin"}):null,o("create")]})]})]})})}function eK(e){let{projectUuid:t,currentUserUuid:s,initialTrackerData:d,initialStatsData:o,initialSelectedIdeaUuid:x}=e,u=(0,n.c)("ideaTracker"),[p,m]=(0,l.useState)("ideas"),[h,f]=(0,l.useState)(!1),[g,j]=(0,l.useState)(!1),v="/projects/".concat(t,"/dashboard"),{selectedId:b,openPanel:N,closePanel:A}=(0,c.T)(v,x);return(0,a.jsxs)("div",{className:"flex h-full flex-col",children:[!h&&(0,a.jsxs)("div",{className:"mb-4 flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"flex gap-0.5 rounded-lg border border-[#E5E0D8] p-0.5",children:[(0,a.jsx)(r.$,{variant:"ghost",size:"sm",onClick:()=>m("ideas"),className:"rounded-md px-3 py-1 h-auto text-[12px] font-medium transition-colors ".concat("ideas"===p?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:u("tabs.ideas")}),(0,a.jsx)(r.$,{variant:"ghost",size:"sm",onClick:()=>m("stats"),className:"rounded-md px-3 py-1 h-auto text-[12px] font-medium transition-colors ".concat("stats"===p?"bg-white text-[#2C2C2C] shadow-sm":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:u("tabs.stats")})]}),"ideas"===p&&(0,a.jsxs)(r.$,{onClick:()=>j(!0),size:"sm",className:"gap-1.5 rounded-md bg-[#C67A52] px-3.5 py-2 text-white hover:bg-[#B56A42]",children:[(0,a.jsx)(i.A,{className:"h-4 w-4"}),u("actions.newIdea")]})]}),"ideas"===p?(0,a.jsx)(w,{projectUuid:t,initialData:d,onIdeaClick:N,onNewIdea:()=>j(!0),onEmptyChange:f}):(0,a.jsx)(R,{projectUuid:t,initialData:o}),(0,a.jsx)(eG,{open:g,onOpenChange:j,projectUuid:t,onCreated:e=>N(e)}),b&&(0,a.jsx)(eO,{ideaUuid:b,projectUuid:t,currentUserUuid:s,onClose:A})]})}},29767:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("lightbulb",[["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"}]])},32470:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("list-checks",[["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"}]])},37915:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("chevron-left",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]])},38476:(e,t,s)=>{"use strict";s.r(t),s.d(t,{Collapsible:()=>j,CollapsibleContent:()=>A,CollapsibleTrigger:()=>b,Content:()=>E,Root:()=>w,Trigger:()=>k,createCollapsibleScope:()=>h});var a=s(1856),n=s(33328),l=s(21032),i=s(66249),r=s(99457),c=s(34124),d=s(93367),o=s(19900),x=s(40577),u=s(90508),p="Collapsible",[m,h]=(0,l.A)(p),[f,g]=m(p),j=a.forwardRef((e,t)=>{let{__scopeCollapsible:s,open:n,defaultOpen:l,disabled:r,onOpenChange:c,...o}=e,[m,h]=(0,i.i)({prop:n,defaultProp:null!=l&&l,onChange:c,caller:p});return(0,u.jsx)(f,{scope:s,disabled:r,contentId:(0,x.B)(),open:m,onOpenToggle:a.useCallback(()=>h(e=>!e),[h]),children:(0,u.jsx)(d.sG.div,{"data-state":C(m),"data-disabled":r?"":void 0,...o,ref:t})})});j.displayName=p;var v="CollapsibleTrigger",b=a.forwardRef((e,t)=>{let{__scopeCollapsible:s,...a}=e,l=g(v,s);return(0,u.jsx)(d.sG.button,{type:"button","aria-controls":l.contentId,"aria-expanded":l.open||!1,"data-state":C(l.open),"data-disabled":l.disabled?"":void 0,disabled:l.disabled,...a,ref:t,onClick:(0,n.mK)(e.onClick,l.onOpenToggle)})});b.displayName=v;var N="CollapsibleContent",A=a.forwardRef((e,t)=>{let{forceMount:s,...a}=e,n=g(N,e.__scopeCollapsible);return(0,u.jsx)(o.C,{present:s||n.open,children:e=>{let{present:s}=e;return(0,u.jsx)(y,{...a,ref:t,present:s})}})});A.displayName=N;var y=a.forwardRef((e,t)=>{let{__scopeCollapsible:s,present:n,children:l,...i}=e,o=g(N,s),[x,p]=a.useState(n),m=a.useRef(null),h=(0,c.s)(t,m),f=a.useRef(0),j=f.current,v=a.useRef(0),b=v.current,A=o.open||x,y=a.useRef(A),w=a.useRef(void 0);return a.useEffect(()=>{let e=requestAnimationFrame(()=>y.current=!1);return()=>cancelAnimationFrame(e)},[]),(0,r.N)(()=>{let e=m.current;if(e){w.current=w.current||{transitionDuration:e.style.transitionDuration,animationName:e.style.animationName},e.style.transitionDuration="0s",e.style.animationName="none";let t=e.getBoundingClientRect();f.current=t.height,v.current=t.width,y.current||(e.style.transitionDuration=w.current.transitionDuration,e.style.animationName=w.current.animationName),p(n)}},[o.open,n]),(0,u.jsx)(d.sG.div,{"data-state":C(o.open),"data-disabled":o.disabled?"":void 0,id:o.contentId,hidden:!A,...i,ref:h,style:{"--radix-collapsible-content-height":j?"".concat(j,"px"):void 0,"--radix-collapsible-content-width":b?"".concat(b,"px"):void 0,...e.style},children:A&&l})});function C(e){return e?"open":"closed"}var w=j,k=b,E=A},52309:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("settings",[["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"}]])},56669:(e,t,s)=>{Promise.resolve().then(s.bind(s,9715)),Promise.resolve().then(s.bind(s,7045))},57223:(e,t,s)=>{"use strict";s.d(t,{E:()=>l});var a=s(90508),n=s(24377);function l(e){let{className:t,...s}=e;return(0,a.jsx)("div",{"data-slot":"skeleton",className:(0,n.cn)("bg-accent animate-pulse rounded-md",t),...s})}},71921:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("clipboard-list",[["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"}]])},78948:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]])},84247:(e,t,s)=>{"use strict";s.d(t,{Separator:()=>i});var a=s(90508);s(1856);var n=s(5725),l=s(24377);function i(e){let{className:t,orientation:s="horizontal",decorative:i=!0,...r}=e;return(0,a.jsx)(n.b,{"data-slot":"separator",decorative:i,orientation:s,className:(0,l.cn)("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",t),...r})}},95900:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});let a=(0,s(66206).A)("arrow-right-left",[["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"}]])}},e=>{e.O(0,[41282,93151,41752,30996,57084,59764,12079,18944,12790,26885,21932,16544,53298,30724,27201,16551,97784,14753,45532,70552,86944,11207,76803,29660,84541,23466,44046,6028,9562,74951,65496,77358],()=>e(e.s=56669)),_N_E=e.O()}]);
|
package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/page-c36345b80cc5bf5c.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[11709],{9959:(e,s,t)=>{Promise.resolve().then(t.bind(t,30384))},30384:(e,s,t)=>{"use strict";t.r(s),t.d(s,{default:()=>W});var r=t(90508),a=t(1856),n=t(39268),l=t(12790),i=t.n(l),c=t(63964),o=t(1976),d=t(22922),x=t(48416),p=t(57731),m=t(81750),u=t(23217),h=t(29767),g=t(56770),j=t(71388),f=t(17730),b=t(78948),v=t(62898),N=t(5616),w=t(38931),C=t(83064),A=t(51581),y=t(10263),E=t(88634),k=t(5425),D=t(60532),B=t(25373),F=t(55764),G=t(24377);function T(e){let{className:s,value:t,...a}=e;return(0,r.jsx)(F.bL,{"data-slot":"progress",className:(0,G.cn)("bg-[#E5E2DC] relative h-1.5 w-full overflow-hidden rounded-full",s),...a,children:(0,r.jsx)(F.C1,{"data-slot":"progress-indicator",className:"h-full w-full flex-1 rounded-full transition-all duration-500 ease-out",style:{transform:"translateX(-".concat(100-(t||0),"%)"),backgroundColor:"var(--progress-indicator, #C67A52)"}})})}var S=t(95900),P=t(85226),_=t(97438);function O(e){let{open:s,onOpenChange:t,projectName:l,sourceGroupName:i,targetGroupName:c,onConfirm:o}=e,x=(0,n.c)(),[p,m]=(0,a.useTransition)();return(0,r.jsx)(_.lG,{open:s,onOpenChange:t,children:(0,r.jsxs)(_.Cf,{className:"sm:max-w-[440px] gap-0 p-0 rounded-[16px]",showCloseButton:!1,children:[(0,r.jsx)(_.L3,{className:"sr-only",children:x("projectGroups.moveTitle")}),(0,r.jsxs)("div",{className:"flex flex-col items-center gap-4 p-6",children:[(0,r.jsx)("div",{className:"flex h-12 w-12 items-center justify-center rounded-full bg-[#C67A5220]",children:(0,r.jsx)(S.A,{className:"h-[22px] w-[22px] text-[#C67A52]"})}),(0,r.jsx)("p",{className:"text-base font-semibold text-[#2C2C2C]",children:x("projectGroups.moveTitle")}),(0,r.jsx)(_.rr,{className:"text-center text-[13px] leading-[1.5] text-[#6B6B6B]",children:x("projectGroups.moveDescription",{projectName:l,sourceGroupName:i,targetGroupName:c})})]}),(0,r.jsxs)("div",{className:"flex justify-end gap-3 p-[16px_24px] border-t border-[#E5E2DC]",children:[(0,r.jsx)(d.$,{variant:"outline",onClick:()=>t(!1),className:"rounded-lg border-[#E5E2DC] text-[13px]",children:x("common.cancel")}),(0,r.jsxs)(d.$,{onClick:()=>{m(async()=>{await o(),t(!1)})},disabled:p,className:"rounded-lg bg-[#C67A52] hover:bg-[#B56A42] text-white text-[13px] gap-1.5",children:[p?(0,r.jsx)(P.A,{className:"h-3.5 w-3.5 animate-spin"}):(0,r.jsx)(D.A,{className:"h-3.5 w-3.5"}),x(p?"common.processing":"projectGroups.confirmMove")]})]})]})})}var I=t(23675),R=t(14554),U=t(88064),$=t(15972),M=t(42305);function z(e){let{open:s,onOpenChange:t,onCreated:l}=e,i=(0,n.c)(),c=(0,I.useRouter)(),[o,x]=(0,a.useTransition)(),[p,m]=(0,a.useState)(""),[u,h]=(0,a.useState)(""),[g,j]=(0,a.useState)(null),f=()=>{p.trim()&&(j(null),x(async()=>{try{let e=await fetch("/api/project-groups",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:p.trim(),description:u.trim()||void 0})}),s=await e.json();s.success?(m(""),h(""),t(!1),null==l||l(),c.refresh()):j(s.error||i("projectGroups.createFailed"))}catch(e){j(i("common.genericError"))}}))};return(0,r.jsx)(_.lG,{open:s,onOpenChange:t,children:(0,r.jsxs)(_.Cf,{className:"sm:max-w-[480px] gap-0 p-0 rounded-[16px]",showCloseButton:!1,children:[(0,r.jsx)(_.c7,{className:"flex flex-row items-center justify-between p-[20px_24px] border-b border-[#E5E2DC]",children:(0,r.jsxs)("div",{className:"flex items-center gap-2.5",children:[(0,r.jsx)(E.A,{className:"h-5 w-5 text-[#C67A52]"}),(0,r.jsx)(_.L3,{className:"text-lg font-semibold tracking-[-0.3px] text-[#2C2C2C]",children:i("projectGroups.newGroupTitle")})]})}),(0,r.jsx)(_.rr,{className:"sr-only",children:i("projectGroups.newGroupTitle")}),(0,r.jsxs)("div",{className:"flex flex-col gap-5 p-6",children:[g&&(0,r.jsx)("div",{className:"rounded-lg bg-destructive/10 p-3 text-sm text-destructive",children:g}),(0,r.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,r.jsx)(U.J,{className:"text-[13px] font-medium text-[#2C2C2C]",children:i("projectGroups.groupName")}),(0,r.jsx)(R.p,{value:p,onChange:e=>m(e.target.value),placeholder:i("projectGroups.groupNamePlaceholder"),className:"h-10 rounded-lg border-[#E5E2DC]",onKeyDown:e=>{!(0,M.P)(e)&&"Enter"===e.key&&p.trim()&&f()}})]}),(0,r.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,r.jsx)(U.J,{className:"text-[13px] font-medium text-[#2C2C2C]",children:i("projectGroups.descriptionOptional")}),(0,r.jsx)($.T,{value:u,onChange:e=>h(e.target.value),placeholder:i("projectGroups.descriptionPlaceholder"),className:"min-h-[80px] rounded-lg border-[#E5E2DC]"})]})]}),(0,r.jsxs)("div",{className:"flex justify-end gap-3 p-[16px_24px] border-t border-[#E5E2DC]",children:[(0,r.jsx)(d.$,{variant:"outline",onClick:()=>t(!1),className:"rounded-lg border-[#E5E2DC] text-[13px]",children:i("common.cancel")}),(0,r.jsxs)(d.$,{onClick:f,disabled:o||!p.trim(),className:"rounded-lg bg-[#C67A52] hover:bg-[#B56A42] text-white text-[13px] gap-1.5",children:[o?(0,r.jsx)(P.A,{className:"h-3.5 w-3.5 animate-spin"}):(0,r.jsx)(N.A,{className:"h-3.5 w-3.5"}),o?i("common.creating"):i("projectGroups.createGroup")]})]})]})})}var L=t(88738),Z=t(38280);function J(e){return e>=100?{bar:"#1D9E75",text:"#0F6E56"}:e>=60?{bar:"#5DCAA5",text:"#0F6E56"}:e>=30?{bar:"#FAC775",text:"#854F0B"}:{bar:"#F09595",text:"#A32D2D"}}function V(){let e=(0,n.c)("time");return s=>{let t=new Date,r=new Date(s),a=t.getTime()-r.getTime(),n=Math.floor(a/6e4),l=Math.floor(a/36e5),i=Math.floor(a/864e5);return n<1?e("justNow"):n<60?e("minutesAgo",{minutes:n}):l<24?e("hoursAgo",{hours:l}):0===i?e("today"):1===i?e("yesterday"):e("daysAgo",{days:i})}}function K(e){let{counts:s,compact:t=!1}=e,a=(0,n.c)();return(0,r.jsxs)("span",{className:"flex items-center gap-2 text-[#9A9A9A] ".concat(t?"text-[10px]":"text-[11px]"),children:[(0,r.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,r.jsx)(u.A,{className:"text-[#BDBDBD] ".concat(t?"h-[11px] w-[11px]":"h-3 w-3")}),s.tasks,!t&&" ".concat(a("projects.tasks"))]}),(0,r.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,r.jsx)(h.A,{className:"text-[#BDBDBD] ".concat(t?"h-[11px] w-[11px]":"h-3 w-3")}),s.ideas,!t&&" ".concat(a("projects.ideas"))]}),(0,r.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,r.jsx)(g.A,{className:"text-[#BDBDBD] ".concat(t?"h-[11px] w-[11px]":"h-3 w-3")}),s.documents,!t&&" ".concat(a("projects.docs"))]})]})}function H(e){let{project:s}=e,t=(0,n.c)(),a=V(),l=(0,Z.D)(s.name),i=(0,Z.g)(s.name),c=s.counts.tasks>0?Math.round(s.counts.doneTasks/s.counts.tasks*100):0,o=J(c),d=0===s.counts.tasks,x=100===c&&!d;return(0,r.jsxs)("div",{className:"flex flex-col gap-3 rounded-xl border border-[#E5E2DC] bg-white p-4 transition-colors hover:bg-[#F5F2EC]",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2.5",children:[(0,r.jsx)("div",{className:"flex h-8 w-8 shrink-0 items-center justify-center rounded-lg text-[10px] font-bold",style:{backgroundColor:i.bg,color:i.text},children:l}),(0,r.jsx)("span",{className:"truncate text-[13px] font-semibold text-[#2C2C2C]",children:s.name}),d&&(0,r.jsx)(p.E,{variant:"outline",className:"shrink-0 border-0 bg-[#FEF3C7] px-1.5 py-0 text-[10px] font-medium text-[#92400E]",children:t("projects.empty")}),x&&(0,r.jsx)(p.E,{variant:"outline",className:"shrink-0 border-0 bg-[#D1FAE5] px-1.5 py-0 text-[10px] font-medium text-[#065F46]",children:t("projects.complete")})]}),(0,r.jsx)(K,{counts:s.counts}),(0,r.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,r.jsx)(T,{value:c,className:"h-1.5 w-full bg-[#F0EDE8]",style:{"--progress-indicator":o.bar}}),(0,r.jsxs)("div",{className:"flex justify-between",children:[(0,r.jsxs)("span",{className:"text-[11px] font-semibold",style:{color:o.text},children:[c,"%"]}),(0,r.jsx)("span",{className:"text-[11px] text-[#9A9A9A]",children:a(s.updatedAt)})]})]})]})}function X(e){let{project:s,showDivider:t=!0}=e,a=(0,n.c)(),l=V(),i=(0,Z.D)(s.name),c=(0,Z.g)(s.name),o=s.counts.tasks>0?Math.round(s.counts.doneTasks/s.counts.tasks*100):0,d=J(o),x=0===s.counts.tasks,m=100===o&&!x;return(0,r.jsxs)("div",{className:"flex w-full flex-col gap-1.5 px-4 py-2.5 md:flex-row md:items-center md:gap-4 md:px-6 md:py-2",style:t?{borderBottom:"1px solid #0000000a"}:void 0,children:[(0,r.jsxs)("div",{className:"flex items-center gap-2.5 md:min-w-0 md:flex-1 md:gap-4",children:[(0,r.jsx)("div",{className:"flex h-8 w-8 shrink-0 items-center justify-center rounded-lg text-[10px] font-bold md:h-9 md:w-9 md:rounded-[10px] md:text-[11px]",style:{backgroundColor:c.bg,color:c.text},children:i}),(0,r.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)("span",{className:"truncate text-[13px] font-semibold text-[#2C2C2C]",children:s.name}),x&&(0,r.jsx)(p.E,{variant:"outline",className:"shrink-0 border-0 bg-[#FEF3C7] px-1.5 py-0 text-[10px] font-medium text-[#92400E]",children:a("projects.empty")}),m&&(0,r.jsx)(p.E,{variant:"outline",className:"shrink-0 border-0 bg-[#D1FAE5] px-1.5 py-0 text-[10px] font-medium text-[#065F46]",children:a("projects.complete")})]}),(0,r.jsx)("div",{className:"hidden md:block",children:(0,r.jsx)(K,{counts:s.counts})})]})]}),(0,r.jsxs)("div",{className:"flex items-center justify-between md:hidden",children:[(0,r.jsxs)("span",{className:"flex items-center gap-1.5 text-[10px] text-[#9A9A9A]",children:[(0,r.jsx)(K,{counts:s.counts,compact:!0}),(0,r.jsx)("span",{children:"\xb7"}),(0,r.jsx)("span",{children:l(s.updatedAt)})]}),(0,r.jsxs)("span",{className:"text-[10px] font-semibold",style:{color:d.text},children:[o,"%"]})]}),(0,r.jsx)("div",{className:"md:hidden",children:(0,r.jsx)(T,{value:o,className:"h-1 w-full bg-[#F0EDE8]",style:{"--progress-indicator":d.bar}})}),(0,r.jsxs)("div",{className:"hidden w-[200px] shrink-0 items-center gap-2 md:flex",children:[(0,r.jsx)(T,{value:o,className:"h-1.5 flex-1 bg-[#F0EDE8]",style:{"--progress-indicator":d.bar}}),(0,r.jsxs)("span",{className:"w-9 text-right text-[11px] font-semibold",style:{color:d.text},children:[o,"%"]})]}),(0,r.jsx)("span",{className:"hidden w-[80px] shrink-0 text-right text-[11px] text-[#9A9A9A] md:block",children:l(s.updatedAt)})]})}let Y="__ungrouped__";function q(e){let{group:s,projects:t,stats:l,onNewProject:c,defaultOpen:u=!1,viewMode:h}=e,g=(0,n.c)(),[w,C]=(0,a.useState)(u),A=l.totalTasks>0?Math.round(l.completedTasks/l.totalTasks*100):0;return(0,r.jsx)(o.gL,{droppableId:s.uuid,children:(e,a)=>(0,r.jsx)("div",{ref:e.innerRef,...e.droppableProps,children:(0,r.jsx)(m.Nt,{open:w,onOpenChange:C,children:(0,r.jsxs)(x.Zp,{className:"overflow-hidden rounded-2xl border-[#E5E2DC] gap-0 py-0 shadow-none transition-colors hover:border-[#C67A52]/40 ".concat(a.isDraggingOver?"border-[#C67A52] bg-[#C67A5208]":""),children:[(0,r.jsxs)("div",{className:"flex flex-col gap-2 px-4 py-2.5 md:flex-row md:items-center md:justify-between md:px-6 md:py-3",children:[(0,r.jsxs)(m.R6,{className:"flex flex-1 cursor-pointer items-center gap-2.5 text-left md:gap-3",children:[(0,r.jsx)("div",{className:"flex h-8 w-8 shrink-0 items-center justify-center rounded-lg bg-[#C67A5215] md:h-9 md:w-9",children:(0,r.jsx)(j.A,{className:"h-4 w-4 text-[#C67A52]"})}),(0,r.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,r.jsxs)("div",{className:"flex items-center gap-1.5 md:gap-2",children:[(0,r.jsx)("h2",{className:"truncate text-sm font-semibold text-[#2C2C2C] md:text-base",children:s.name}),(0,r.jsx)(p.E,{variant:"secondary",className:"shrink-0 border-0 bg-[#F0EDE8] text-[10px] font-medium text-[#6B6B6B] md:text-[11px]",children:t.length})]}),(0,r.jsxs)("div",{className:"mt-0.5 flex flex-wrap items-center gap-x-3 gap-y-0.5 text-[10px] text-[#9A9A9A] md:text-[11px]",children:[(0,r.jsxs)("span",{children:[l.totalTasks," ",g("projects.tasks")," \xb7"," ",A,"% ",g("projectGroups.complete")]}),(0,r.jsxs)("span",{className:"hidden md:inline",children:[l.openIdeas," ",g("projectGroups.openIdeas")]})]})]}),w?(0,r.jsx)(f.A,{className:"ml-auto h-3.5 w-3.5 shrink-0 text-[#9A9A9A] md:h-4 md:w-4"}):(0,r.jsx)(b.A,{className:"ml-auto h-3.5 w-3.5 shrink-0 text-[#9A9A9A] md:h-4 md:w-4"})]}),(0,r.jsxs)("div",{className:"hidden items-center gap-2 md:flex",children:[(0,r.jsx)(i(),{href:"/project-groups/".concat(s.uuid),children:(0,r.jsxs)(d.$,{variant:"ghost",size:"sm",className:"text-xs text-[#C67A52] hover:text-[#B56A42]",children:[g("projectGroups.viewDashboard"),(0,r.jsx)(v.A,{className:"ml-1 h-3 w-3"})]})}),(0,r.jsxs)(d.$,{variant:"outline",size:"sm",className:"border-[#E5E2DC] text-xs",onClick:c,children:[(0,r.jsx)(N.A,{className:"mr-1 h-3 w-3"}),g("projects.newProject")]})]})]}),(0,r.jsx)(m.Ke,{children:(0,r.jsxs)("div",{className:"border-t border-[#0000000a] py-0",children:[0!==t.length||a.isDraggingOver?(0,r.jsx)("div",{className:"grid"===h?"md:grid md:grid-cols-2 md:gap-4 md:p-5 lg:grid-cols-3":"",children:t.map((e,s)=>(0,r.jsx)(o.sx,{draggableId:e.uuid,index:s,children:(a,n)=>(0,r.jsx)("div",{ref:a.innerRef,...a.draggableProps,...a.dragHandleProps,children:(0,r.jsx)(i(),{href:"/projects/".concat(e.uuid,"/dashboard"),draggable:!1,onClick:e=>{n.isDragging&&e.preventDefault()},children:"grid"===h?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("div",{className:"md:hidden transition-colors hover:bg-[#F5F2EC] ".concat(n.isDragging?"rotate-1 opacity-90 shadow-md rounded-lg bg-white":""),children:(0,r.jsx)(X,{project:e,showDivider:s<t.length-1})}),(0,r.jsx)("div",{className:"hidden md:block ".concat(n.isDragging?"rotate-1 opacity-90 shadow-md":""),children:(0,r.jsx)(H,{project:e})})]}):(0,r.jsx)("div",{className:"transition-colors hover:bg-[#F5F2EC] ".concat(n.isDragging?"rotate-1 opacity-90 shadow-md rounded-lg bg-white":""),children:(0,r.jsx)(X,{project:e,showDivider:s<t.length-1})})})})},e.uuid))}):(0,r.jsx)("p",{className:"py-4 text-center text-sm text-[#9A9A9A]",children:g("projectGroups.noProjectsInGroup")}),e.placeholder]})})]})})})})}function Q(e){let{projects:s,onNewProject:t,viewMode:l}=e,c=(0,n.c)(),[u,h]=(0,a.useState)(!1);return(0,r.jsx)(o.gL,{droppableId:Y,children:(e,a)=>0!==s.length||a.isDraggingOver?(0,r.jsx)("div",{ref:e.innerRef,...e.droppableProps,children:(0,r.jsx)(m.Nt,{open:u,onOpenChange:h,children:(0,r.jsxs)(x.Zp,{className:"overflow-hidden rounded-2xl border-[#E5E2DC] gap-0 py-0 shadow-none transition-colors hover:border-[#C67A52]/40 ".concat(a.isDraggingOver?"border-[#C67A52] bg-[#C67A5208]":""),children:[(0,r.jsxs)("div",{className:"flex items-center justify-between px-4 py-2.5 md:px-6 md:py-3",children:[(0,r.jsxs)(m.R6,{className:"flex flex-1 cursor-pointer items-center gap-2.5 text-left md:gap-3",children:[(0,r.jsx)("div",{className:"flex h-8 w-8 shrink-0 items-center justify-center rounded-lg bg-[#F0EDE8] md:h-9 md:w-9",children:(0,r.jsx)(w.A,{className:"h-4 w-4 text-[#9A9A9A]"})}),(0,r.jsxs)("div",{className:"flex items-center gap-1.5 md:gap-2",children:[(0,r.jsx)("h2",{className:"text-sm font-semibold text-[#6B6B6B] md:text-base",children:c("projectGroups.ungrouped")}),(0,r.jsx)(p.E,{variant:"secondary",className:"shrink-0 border-0 bg-[#F0EDE8] text-[10px] font-medium text-[#6B6B6B] md:text-[11px]",children:s.length})]}),u?(0,r.jsx)(f.A,{className:"ml-auto h-3.5 w-3.5 shrink-0 text-[#9A9A9A] md:h-4 md:w-4"}):(0,r.jsx)(b.A,{className:"ml-auto h-3.5 w-3.5 shrink-0 text-[#9A9A9A] md:h-4 md:w-4"})]}),(0,r.jsx)("div",{className:"hidden items-center gap-2 md:flex",children:(0,r.jsxs)(d.$,{variant:"outline",size:"sm",className:"shrink-0 border-[#E5E2DC] text-xs",onClick:t,children:[(0,r.jsx)(N.A,{className:"mr-1 h-3 w-3"}),c("projects.newProject")]})})]}),(0,r.jsx)(m.Ke,{children:(0,r.jsxs)("div",{className:"border-t border-[#0000000a] py-0",children:[0===s.length?(0,r.jsx)("p",{className:"py-4 text-center text-sm text-[#9A9A9A]",children:c("projectGroups.noProjectsInGroup")}):(0,r.jsx)("div",{className:"grid"===l?"md:grid md:grid-cols-2 md:gap-4 md:p-5 lg:grid-cols-3":"",children:s.map((e,t)=>(0,r.jsx)(o.sx,{draggableId:e.uuid,index:t,children:(a,n)=>(0,r.jsx)("div",{ref:a.innerRef,...a.draggableProps,...a.dragHandleProps,children:(0,r.jsx)(i(),{href:"/projects/".concat(e.uuid,"/dashboard"),draggable:!1,onClick:e=>{n.isDragging&&e.preventDefault()},children:"grid"===l?(0,r.jsx)("div",{className:n.isDragging?"rotate-1 opacity-90 shadow-md":"",children:(0,r.jsx)(H,{project:e})}):(0,r.jsx)("div",{className:"transition-colors hover:bg-[#F5F2EC] ".concat(n.isDragging?"rotate-1 opacity-90 shadow-md rounded-lg bg-white":""),children:(0,r.jsx)(X,{project:e,showDivider:t<s.length-1})})})})},e.uuid))}),e.placeholder]})})]})})}):(0,r.jsx)("div",{ref:e.innerRef,...e.droppableProps,className:"hidden",children:e.placeholder})})}function W(){var e,s,t,l,i;let p=(0,n.c)(),[m,u]=(0,a.useState)([]),[h,g]=(0,a.useState)([]),[j,f]=(0,a.useState)(!0),[b,v]=(0,a.useState)(null),[F,G]=(0,a.useState)(()=>{{let e=localStorage.getItem("chorus_projects_view_mode");if("list"===e||"grid"===e)return e}return"list"});(0,a.useEffect)(()=>{localStorage.setItem("chorus_projects_view_mode",F)},[F]);let[T,S]=(0,a.useState)(!1),[P,_]=(0,a.useState)(null),[I,R]=(0,a.useState)(!1),[U,$]=(0,a.useState)(!1),M=(0,a.useCallback)(async()=>{try{let[e,s]=await Promise.all([fetch("/api/projects?pageSize=200"),fetch("/api/project-groups")]),t=await e.json(),r=await s.json();t.success&&u(t.data.data||t.data||[]),r.success&&g(r.data.groups||[])}catch(e){}finally{f(!1)}},[]);(0,a.useEffect)(()=>{M(),fetch("/api/agents?pageSize=100").then(e=>e.json()).then(e=>{e.success&&R((e.data.data||e.data||[]).some(e=>{var s;return(null!=(s=e.effectivePermissions)?s:[]).includes("project:write")}))}).catch(()=>{})},[M]),(0,c.eV)(["project","project_group"],()=>{M()});let Z=new Map,J=[];for(let e of m)if(e.groupUuid){let s=Z.get(e.groupUuid)||[];s.push(e),Z.set(e.groupUuid,s)}else J.push(e);function V(e){var s;if(!e)return p("projectGroups.ungrouped");let t=h.find(s=>s.uuid===e);return null!=(s=null==t?void 0:t.name)?s:p("projectGroups.ungrouped")}async function K(){if(!b)return;let e=await fetch("/api/projects/".concat(b.projectUuid,"/group"),{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({groupUuid:b.targetGroupUuid})}),s=await e.json();if(!s.success)throw Error(s.error||p("projectGroups.moveFailed"));await M()}return j?(0,r.jsx)("div",{className:"bg-[#FAF8F4] p-4 md:px-8 md:py-6",children:(0,r.jsx)("p",{className:"text-sm text-[#6B6B6B]",children:p("projects.loadingProjects")})}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(o.JY,{onDragEnd:function(e){let{destination:s,source:t,draggableId:r}=e;if(!s||s.droppableId===t.droppableId)return;let a=m.find(e=>e.uuid===r);if(!a)return;let n=s.droppableId===Y?null:s.droppableId,l=a.groupUuid;v({projectUuid:a.uuid,projectName:a.name,sourceGroupName:V(l),targetGroupUuid:n,targetGroupName:V(n)})},children:(0,r.jsxs)("div",{className:"bg-[#FAF8F4] p-4 md:px-8 md:py-6",children:[(0,r.jsxs)("div",{className:"mb-4 md:mb-6",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between",children:[(0,r.jsx)("h1",{className:"text-2xl font-semibold text-[#2C2C2C]",children:p("projects.title")}),(0,r.jsxs)("div",{className:"flex items-center gap-3",children:[(0,r.jsxs)("div",{className:"hidden overflow-hidden rounded-lg border border-[#E5E2DC] md:flex",children:[(0,r.jsxs)(d.$,{variant:"ghost",size:"sm",onClick:()=>G("list"),className:"flex items-center gap-1.5 rounded-none px-2.5 py-1.5 text-xs font-medium transition-colors ".concat("list"===F?"bg-[#F5F2EC] text-[#C67A52]":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:[(0,r.jsx)(C.A,{className:"h-3.5 w-3.5"}),p("projects.listView")]}),(0,r.jsxs)(d.$,{variant:"ghost",size:"sm",onClick:()=>G("grid"),className:"flex items-center gap-1.5 rounded-none px-2.5 py-1.5 text-xs font-medium transition-colors ".concat("grid"===F?"bg-[#F5F2EC] text-[#C67A52]":"text-[#9A9A9A] hover:text-[#6B6B6B]"),children:[(0,r.jsx)(A.A,{className:"h-3.5 w-3.5"}),p("projects.gridView")]})]}),(0,r.jsxs)(d.$,{className:"hidden rounded-xl bg-[#C67A52] px-5 text-white hover:bg-[#B56A42] md:flex",onClick:()=>S(!0),children:[(0,r.jsx)(N.A,{className:"mr-2 h-4 w-4"}),p("projectGroups.newProjectGroup")]})]})]}),(0,r.jsx)("p",{className:"mt-1 text-sm text-[#6B6B6B]",children:p("projects.subtitle")})]}),0===m.length&&0===h.length?(0,r.jsxs)("div",{className:"space-y-5",children:[(0,r.jsx)(x.Zp,{className:"border-[#C67A5230] bg-[#C67A520A] p-6 md:p-8",children:(0,r.jsxs)("div",{className:"flex items-start gap-4",children:[(0,r.jsx)("div",{className:"flex h-11 w-11 shrink-0 items-center justify-center rounded-xl bg-[#C67A5220]",children:(0,r.jsx)(y.A,{className:"h-5 w-5 text-[#C67A52]"})}),(0,r.jsxs)("div",{children:[(0,r.jsx)("h2",{className:"text-lg font-semibold text-[#2C2C2C]",children:p("projects.onboarding.welcomeTitle")}),(0,r.jsx)("p",{className:"mt-1 text-sm text-[#6B6B6B]",children:p("projects.onboarding.welcomeDesc")})]})]})}),(0,r.jsxs)("div",{className:"grid gap-4 md:grid-cols-2",children:[(0,r.jsxs)(x.Zp,{className:"border-[#E5E2DC] p-5",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2.5 mb-2",children:[(0,r.jsx)("div",{className:"flex h-8 w-8 items-center justify-center rounded-lg bg-[#C67A5215]",children:(0,r.jsx)(E.A,{className:"h-4 w-4 text-[#C67A52]"})}),(0,r.jsx)("h3",{className:"text-sm font-semibold text-[#2C2C2C]",children:p("projects.onboarding.whatIsGroupTitle")})]}),(0,r.jsx)("p",{className:"text-[13px] leading-relaxed text-[#6B6B6B]",children:p("projects.onboarding.whatIsGroupDesc")})]}),(0,r.jsxs)(x.Zp,{className:"border-[#E5E2DC] p-5",children:[(0,r.jsxs)("div",{className:"flex items-center gap-2.5 mb-2",children:[(0,r.jsx)("div",{className:"flex h-8 w-8 items-center justify-center rounded-lg bg-[#C67A5215]",children:(0,r.jsx)(w.A,{className:"h-4 w-4 text-[#C67A52]"})}),(0,r.jsx)("h3",{className:"text-sm font-semibold text-[#2C2C2C]",children:p("projects.onboarding.whatIsProjectTitle")})]}),(0,r.jsx)("p",{className:"text-[13px] leading-relaxed text-[#6B6B6B]",children:p("projects.onboarding.whatIsProjectDesc")})]})]}),(0,r.jsx)(x.Zp,{className:"border-[#E5E2DC] p-6 md:p-8",children:(0,r.jsxs)("div",{className:"space-y-6",children:[(0,r.jsxs)("div",{className:"flex gap-4",children:[(0,r.jsxs)("div",{className:"flex flex-col items-center",children:[(0,r.jsx)("div",{className:"flex h-7 w-7 shrink-0 items-center justify-center rounded-full bg-[#C67A52] text-xs font-bold text-white",children:"1"}),(0,r.jsx)("div",{className:"mt-2 h-full w-px bg-[#E5E2DC]"})]}),(0,r.jsxs)("div",{className:"flex-1 pb-6",children:[(0,r.jsx)("h3",{className:"text-sm font-semibold text-[#2C2C2C]",children:p("projects.onboarding.step1Title")}),(0,r.jsx)("p",{className:"mt-1 text-[13px] text-[#6B6B6B]",children:p("projects.onboarding.step1Desc")}),(0,r.jsxs)(d.$,{className:"mt-3 rounded-xl bg-[#C67A52] text-white hover:bg-[#B56A42]",onClick:()=>S(!0),children:[(0,r.jsx)(E.A,{className:"mr-2 h-4 w-4"}),p("projects.onboarding.createGroupBtn")]})]})]}),(0,r.jsxs)("div",{className:"flex gap-4",children:[(0,r.jsx)("div",{className:"flex flex-col items-center",children:(0,r.jsx)("div",{className:"flex h-7 w-7 shrink-0 items-center justify-center rounded-full bg-[#E5E2DC] text-xs font-bold text-[#9A9A9A]",children:"2"})}),(0,r.jsxs)("div",{className:"flex-1",children:[(0,r.jsx)("h3",{className:"text-sm font-semibold text-[#9A9A9A]",children:p("projects.onboarding.step2Title")}),(0,r.jsx)("p",{className:"mt-1 text-[13px] text-[#9A9A9A]",children:p("projects.onboarding.step2Desc")})]})]})]})}),I&&(0,r.jsx)(x.Zp,{className:"border-[#E5E2DC] bg-[#F5F2EC] p-5 md:p-6",children:(0,r.jsxs)("div",{className:"flex items-start gap-3",children:[(0,r.jsx)("div",{className:"flex h-8 w-8 shrink-0 items-center justify-center rounded-lg bg-[#C67A5215]",children:(0,r.jsx)(k.A,{className:"h-4 w-4 text-[#C67A52]"})}),(0,r.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,r.jsx)("h3",{className:"text-sm font-semibold text-[#2C2C2C]",children:p("projects.onboarding.agentTipTitle")}),(0,r.jsx)("p",{className:"mt-1 text-[13px] text-[#6B6B6B]",children:p("projects.onboarding.agentTipDesc")}),(0,r.jsxs)("div",{className:"mt-3 relative",children:[(0,r.jsx)("pre",{className:"rounded-lg bg-white border border-[#E5E2DC] p-3 pr-10 text-xs text-[#2C2C2C] whitespace-pre-wrap break-words",children:p("projects.onboarding.agentPromptDefault")}),(0,r.jsx)(d.$,{variant:"ghost",size:"icon",className:"absolute right-2 top-2 h-7 w-7 text-[#9A9A9A] hover:text-[#C67A52]",onClick:()=>{navigator.clipboard.writeText(p("projects.onboarding.agentPromptDefault")),$(!0),setTimeout(()=>$(!1),2e3)},children:U?(0,r.jsx)(D.A,{className:"h-3.5 w-3.5 text-green-600"}):(0,r.jsx)(B.A,{className:"h-3.5 w-3.5"})})]}),U&&(0,r.jsx)("p",{className:"mt-1.5 text-xs text-green-600",children:p("projects.onboarding.copiedPrompt")})]})]})})]}):(0,r.jsxs)("div",{className:"space-y-4",children:[h.map((e,s)=>{let t=Z.get(e.uuid)||[],a=function(e){let s=0,t=0,r=0;for(let a of e)s+=a.counts.tasks,t+=a.counts.doneTasks,r+=a.counts.ideas;return{totalTasks:s,completedTasks:t,openIdeas:r}}(t);return(0,r.jsx)(q,{group:e,projects:t,stats:a,defaultOpen:0===s,viewMode:F,onNewProject:()=>_({groupUuid:e.uuid,groupName:e.name})},e.uuid)}),(0,r.jsx)(Q,{projects:J,viewMode:F,onNewProject:()=>_({groupUuid:null,groupName:p("projectGroups.ungrouped")})}),(0,r.jsxs)(d.$,{className:"w-full rounded-xl bg-[#C67A52] text-white hover:bg-[#B56A42] md:hidden",onClick:()=>S(!0),children:[(0,r.jsx)(N.A,{className:"mr-2 h-4 w-4"}),p("projectGroups.newProjectGroup")]})]})]})}),(0,r.jsx)(O,{open:null!==b,onOpenChange:e=>{e||v(null)},projectName:null!=(e=null==b?void 0:b.projectName)?e:"",sourceGroupName:null!=(s=null==b?void 0:b.sourceGroupName)?s:"",targetGroupName:null!=(t=null==b?void 0:b.targetGroupName)?t:"",onConfirm:K}),(0,r.jsx)(z,{open:T,onOpenChange:S,onCreated:()=>{S(!1),M()}}),(0,r.jsx)(L.C,{open:null!==P,onOpenChange:e=>{e||_(null)},groupUuid:null!=(l=null==P?void 0:P.groupUuid)?l:null,groupName:null!=(i=null==P?void 0:P.groupName)?i:"",onCreated:()=>{_(null),M()}})]})}},57731:(e,s,t)=>{"use strict";t.d(s,{E:()=>c});var r=t(90508);t(1856);var a=t(49499),n=t(54154),l=t(24377);let i=(0,a.F)("inline-flex items-center justify-center rounded-full border border-transparent px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden",{variants:{variant:{default:"bg-primary text-primary-foreground [a&]:hover:bg-primary/90",secondary:"bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",destructive:"bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",ghost:"[a&]:hover:bg-accent [a&]:hover:text-accent-foreground",link:"text-primary underline-offset-4 [a&]:hover:underline",success:"bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-100",warning:"bg-yellow-100 text-yellow-800 dark:bg-yellow-900 dark:text-yellow-100"}},defaultVariants:{variant:"default"}});function c(e){let{className:s,variant:t="default",asChild:a=!1,...c}=e,o=a?n.bL:"span";return(0,r.jsx)(o,{"data-slot":"badge","data-variant":t,className:(0,l.cn)(i({variant:t}),s),...c})}},63964:(e,s,t)=>{"use strict";t.d(s,{S2:()=>o,eV:()=>c,l9:()=>i,tS:()=>l,w0:()=>d});var r=t(90508),a=t(1856);t(23675);let n=(0,a.createContext)(null);function l(e){let{projectUuid:s,children:t}=e,l=(0,a.useRef)(new Set),i=(0,a.useRef)(new Set),c=(0,a.useRef)(new Set),o=(0,a.useCallback)(()=>{l.current.forEach(e=>e())},[]),d=(0,a.useCallback)(e=>{i.current.forEach(s=>s(e))},[]);(0,a.useEffect)(()=>{let e,t=null,r=0,a={};function n(){l(),(t=new EventSource(s?"/api/events?projectUuid=".concat(s):"/api/events")).onmessage=s=>{let t=null;try{t=JSON.parse(s.data)}catch(e){return}if(!t)return;if("presence"===t.type)return void c.current.forEach(e=>e(t));let n=t;clearTimeout(e);let l=Date.now(),i=l-r;i>=3e3?(r=l,o()):e=setTimeout(()=>{r=Date.now(),o()},Math.max(1e3,3e3-i));let x=n.entityType;clearTimeout(a[x]),a[x]=setTimeout(()=>{d(n)},300)},t.onerror=()=>{}}function l(){t&&(t.close(),t=null)}function i(){if("visible"===document.visibilityState&&(!t||t.readyState===EventSource.CLOSED))for(let e of(n(),o(),["task","idea","proposal","document","project","project_group"]))d({companyUuid:"",projectUuid:"",entityType:e,entityUuid:"",action:"updated"})}return n(),document.addEventListener("visibilitychange",i),()=>{for(let s in l(),clearTimeout(e),a)clearTimeout(a[s]);document.removeEventListener("visibilitychange",i)}},[s,o,d]);let x=(0,a.useCallback)(e=>(l.current.add(e),()=>{l.current.delete(e)}),[]),p=(0,a.useCallback)(e=>(i.current.add(e),()=>{i.current.delete(e)}),[]),m=(0,a.useCallback)(e=>(c.current.add(e),()=>{c.current.delete(e)}),[]),u=(0,a.useMemo)(()=>({subscribe:x,subscribeEntity:p,subscribePresence:m}),[x,p,m]);return(0,r.jsx)(n.Provider,{value:u,children:t})}function i(e){let s=(0,a.useContext)(n),t=(0,a.useRef)(e);t.current=e,(0,a.useEffect)(()=>{if(!s)return;let e=()=>t.current();return e(),s.subscribe(e)},[s])}function c(e,s){let t=(0,a.useContext)(n),r=(0,a.useRef)(s);r.current=s;let l=(0,a.useRef)(e);l.current=e,(0,a.useEffect)(()=>{if(t)return t.subscribeEntity(e=>{let s=l.current;(Array.isArray(s)?s.includes(e.entityType):e.entityType===s)&&r.current(e)})},[t])}function o(e){let s=(0,a.useContext)(n),t=(0,a.useRef)(e);t.current=e,(0,a.useEffect)(()=>{if(s)return s.subscribePresence(e=>t.current(e))},[s])}function d(e,s,t){let r=(0,a.useContext)(n),l=(0,a.useRef)(t);l.current=t,(0,a.useEffect)(()=>{if(r)return r.subscribeEntity(t=>{t.entityType===e&&t.entityUuid===s&&l.current(t)})},[r,e,s])}},81750:(e,s,t)=>{"use strict";t.d(s,{Ke:()=>c,Nt:()=>l,R6:()=>i});var r=t(90508),a=t(38476),n=t(24377);function l(e){let{...s}=e;return(0,r.jsx)(a.Root,{"data-slot":"collapsible",...s})}function i(e){let{...s}=e;return(0,r.jsx)(a.Trigger,{"data-slot":"collapsible-trigger",...s})}function c(e){let{className:s,...t}=e;return(0,r.jsx)(a.Content,{"data-slot":"collapsible-content",className:(0,n.cn)("overflow-hidden data-[state=open]:animate-[collapsible-down_250ms_ease-in-out] data-[state=closed]:animate-[collapsible-up_200ms_ease-in-out]",s),...t})}}},e=>{e.O(0,[8893,12079,18944,12790,21932,16544,56527,37880,4842,93346,74951,65496,77358],()=>e(e.s=9959)),_N_E=e.O()}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(()=>{"use strict";var e={},a={};function c(d){var f=a[d];if(void 0!==f)return f.exports;var b=a[d]={id:d,loaded:!1,exports:{}},t=!0;try{e[d].call(b.exports,b,b.exports,c),t=!1}finally{t&&delete a[d]}return b.loaded=!0,b.exports}c.m=e,(()=>{var e=[];c.O=(a,d,f,b)=>{if(d){b=b||0;for(var t=e.length;t>0&&e[t-1][2]>b;t--)e[t]=e[t-1];e[t]=[d,f,b];return}for(var r=1/0,t=0;t<e.length;t++){for(var[d,f,b]=e[t],n=!0,o=0;o<d.length;o++)(!1&b||r>=b)&&Object.keys(c.O).every(e=>c.O[e](d[o]))?d.splice(o--,1):(n=!1,b<r&&(r=b));if(n){e.splice(t--,1);var i=f();void 0!==i&&(a=i)}}return a}})(),c.n=e=>{var a=e&&e.__esModule?()=>e.default:()=>e;return c.d(a,{a:a}),a},(()=>{var e,a=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__;c.t=function(d,f){if(1&f&&(d=this(d)),8&f||"object"==typeof d&&d&&(4&f&&d.__esModule||16&f&&"function"==typeof d.then))return d;var b=Object.create(null);c.r(b);var t={};e=e||[null,a({}),a([]),a(a)];for(var r=2&f&&d;"object"==typeof r&&!~e.indexOf(r);r=a(r))Object.getOwnPropertyNames(r).forEach(e=>t[e]=()=>d[e]);return t.default=()=>d,c.d(b,t),b}})(),c.d=(e,a)=>{for(var d in a)c.o(a,d)&&!c.o(e,d)&&Object.defineProperty(e,d,{enumerable:!0,get:a[d]})},c.f={},c.e=e=>Promise.all(Object.keys(c.f).reduce((a,d)=>(c.f[d](e,a),a),[])),c.u=e=>70552===e?"static/chunks/"+e+"-0ea3c887937b5b51.js":27201===e?"static/chunks/"+e+"-0228042991534905.js":14753===e?"static/chunks/"+e+"-d911e24624c88fbc.js":26885===e?"static/chunks/"+e+"-00665cb87b9da098.js":45532===e?"static/chunks/"+e+"-12ed13c096e2a88e.js":30724===e?"static/chunks/"+e+"-627b849ed09f9cc5.js":97784===e?"static/chunks/"+e+"-7b90a17294840e32.js":93151===e?"static/chunks/f3524bc3-5c48b74c49ddeca0.js":41752===e?"static/chunks/fcc64ffe-de8d357e657bd162.js":16551===e?"static/chunks/"+e+"-68896c0ca7966ebf.js":"static/chunks/"+(({5571:"4e7df547",14749:"5db68f07",15968:"14860d7c",17203:"7a5af761",19019:"1496d684",20341:"cbbc2011",24364:"fbd0dcbb",32217:"1ccec16d",43245:"48c55e57",49954:"a856cf35",58669:"4f8e262c",65543:"685092b2",69136:"5be1c5d8",77008:"fab3cf95",80039:"f4bf7a28",82346:"273acdc0",83086:"8c93d9a0",95402:"f57f1d5e",95792:"f2442412"})[e]||e)+"."+({123:"b47ce56e923e1dc4",283:"4d4eca86c7abbec9",493:"737fdeba759d415a",1236:"ec9ed804634bb6cf",1697:"58e0d7523fdd2d52",1803:"8e2e63f39906fd1e",1847:"90012f795031fd15",2164:"d977bc7d148f1d9e",2351:"35085ef2663aaa44",2656:"febbce72896f5701",2829:"ae5196f6cb23aa62",2842:"a5f90cf26f897bfc",3333:"74af47ffa6cb4c0e",3709:"a528fc6526bb2f1d",4123:"bf0bc76b87e0a5d0",4151:"b8833633f487c3d5",4435:"0da86212e371da10",4860:"29e14c631b3a4ed0",5020:"e7e6f35316da8d79",5336:"3fcd63f65fab9362",5559:"34e9e404696c82c0",5571:"fa34ffab38ba73b3",6178:"d88e2b68a2a1e09b",6685:"e23946c2ee579a76",7037:"d00688ceefb9f163",7123:"37f20f0e10894a3c",7140:"099e6f0e9722e08f",7317:"1a06bc56028637f6",7387:"f8cf2c36cf9b56dc",8563:"caa84c08a9db867a",8859:"fd4fa52883f05b54",9357:"084ac7f230f031a3",9560:"2e77d2dc6351b105",9634:"14999324d0128b0e",9858:"5eb9e5d689ee1188",9872:"bfcbe3b40e1ba7a3",10171:"8a96856626beb7ab",10667:"c192840fc1b34161",10742:"6cc4d6949065d15a",11160:"058f4a27a4ccab24",11688:"8c27089c45c98079",11966:"36fab6445e33609a",12139:"23195d4025c449dd",12850:"a5f6e9e87d0f9abd",12906:"f2105800b7dc9127",12994:"ea3d4eeb1b15ce47",13131:"e73eb283f14ed397",13437:"0de1f2000c75f497",13462:"b710822936d6d995",14438:"153e2ffb65627b56",14749:"5a8891ea355512a8",15666:"fd13db7fdfc4db46",15736:"4a506a1463e65905",15930:"faf0ba15488aa8ff",15968:"67246c65e7776fa2",16271:"298647c24de4c656",16428:"da33ee8ca31c4d8f",16564:"310c443d14c6e84b",16596:"3c557433b77dc606",16669:"c0967e6ad7401c26",17012:"78f2a6b93e37bf95",17045:"cf6dade16b25ffc7",17093:"ec17cca1979a34c5",17203:"84e2df2bf9d6c4a4",17881:"2eba69b477a8c7f7",18024:"360cc54c2f070fa1",18236:"02c13f95242e1147",18276:"4e4950daea1be290",18291:"6c48a745093c472f",19015:"e0d16d65430522c1",19019:"da3969c029230434",19338:"65cfcfafa18f6aee",19656:"ee0407bae11dd49b",20118:"5e7942f9d596e02b",20171:"9c80c2880256be96",20186:"2a00fa806bf383a5",20341:"a1649a45ba0da5ab",20586:"7cd940a582176e37",20587:"d03a7c9ddae70251",20851:"383095475aa0becf",21063:"5cc29b3160a78147",21233:"fbc3473b758427be",21285:"944c1ff822774352",21290:"ef2762694c3c05e5",21343:"eb8e7aeda8b2b933",21546:"8b2a80eefde810c5",21558:"e72df6c050a17223",21785:"19b23ee028f6262f",21789:"ad6ff228e2917e82",22190:"ee4e8f3ac0189d87",22463:"8f0a0111946c5e37",22485:"9f11764648028b9d",23338:"01f537c5dfd51363",23895:"a3ad3684a5b39547",24021:"e608f829b761ed19",24364:"a59ebe9142818688",24562:"f31cdddfe04624d0",24566:"605ccb37c2b09b7f",24976:"aea37ff8444ce6ca",25018:"51cf65637b375c88",25239:"e13f63bff8d7f459",25934:"45b477fc38b233d5",26558:"337afe8cd6c7f7e2",26594:"9cd92c85c51a3621",26604:"c5f0e687052abb59",27004:"7265fd004542a6ae",27261:"3ad525eea1f52dc3",27509:"8f83a84fed1129f3",27571:"33642de22553efae",27783:"70af75ac091e5b31",27929:"e9a99a263c294b0a",27992:"daf28998ef0714a0",28025:"1025ed4465b8b88e",28244:"3a5e72d3a4048558",28247:"e5faa56338e43301",29047:"664290ff8a84b205",29708:"0f9c08d7ca8a6036",30285:"7b6b107412564a45",30433:"919c34e206690a26",30550:"a8db081db527730d",30682:"c8fc49d63bf75772",31035:"06568e4accfa4664",31135:"8f2dbe06dab9d206",31204:"a8d94d78458557d5",31467:"2013df596c751e6e",31570:"131868ccedfef522",31618:"663e0a27f529a7b5",31635:"fcbdbf0d1e8271e8",31807:"cf2a0cbbe7eedf32",32092:"f10268018cf52339",32217:"31e64d0e8696d298",32411:"6d37c2b4b2f2efb7",32729:"f7ddbed25cb15da4",32800:"6cee7ff19ca516a7",32900:"57aa606259738bd7",33187:"13c12f5c0821ac57",33316:"6b5f8f344baf7a8a",33665:"20ed9144405f8b21",34037:"e8e16348aca40958",34414:"30d095dd419ccded",34500:"58eb096afca7a3d2",34520:"34ba1239c9b5a275",34565:"58e4d12c607709a2",34780:"ddc8d0403f86cd76",34787:"33a6fe2b98db58fd",34966:"dde9356d869e2a0f",35246:"75a72283c3c974e2",35362:"80b6e5545194566a",35733:"cf4ac3f521c0b06d",35901:"aa7ec713edff30e2",35918:"8e970e73c59cd315",36301:"0598cc26dfacc4a8",36531:"4576573d1554d0bc",36622:"2ecd0754a1dd1f10",36884:"6af20de227ae01d6",36989:"9a0a62410bf9ec4e",37697:"9af6ac899a8114c0",37802:"6e3d9ec6ded108e7",38176:"e1818cbc0df1edff",38259:"d83981da5c72c88a",38277:"f24d85bdc720318e",38513:"2edbf8332418852a",38542:"1b0e31f1f0e79950",38843:"bfbf5f2c316123fb",39012:"d1e022d895c7700f",40294:"82b8b706bf8526d2",41333:"464f95d32db59d47",41796:"b775772add38f765",42515:"0879489433824ebb",43203:"0a24d8e1e04b23e1",43245:"fd54cc2dd98a53cf",43335:"71662f3469b367dd",43520:"4abb22e9bfdeedab",44980:"c17d605b4685ba2d",44996:"e5fc9af9e1283894",45025:"bdb2a46a29ea6a7f",45300:"bac57dcaf4b1ae63",45939:"d37b9465101a9a32",45966:"ece098ca2637c63f",46366:"d1d9d65b646509b3",46778:"cbd78e2a3b8eb454",46783:"b9ce59941eb5c767",46965:"2ed4c28224e29499",47066:"7848777fc81f5714",47492:"6b259d6ee0ddf4d8",47613:"946226a67a1e5cd1",47781:"f25170364c271869",47914:"11c71123fcab1d66",47947:"471d5da6bb51de27",48504:"2efb153cab87148c",48782:"5b60e8a0f22f6da1",49114:"19ce7b83efab6d05",49294:"fb738cc8f6f972c0",49307:"9ac8482ed1916e3d",49312:"b4ee106f6ca8df0d",49406:"f77074487dddb735",49515:"c8964ec6f6c710d1",49812:"9bb0091da44f3fb0",49954:"22ac9c291887443d",50681:"5621dcb316c1dbc0",51094:"83d8278e86159ae3",51159:"cd7d830da0e9a7d2",52644:"999d7bbfb0c77212",52786:"cca2f572d4b83716",53012:"8ea1cc9b669d4071",53323:"19d0c542f89ec743",53854:"80e3b10f38882782",53988:"a7e066e48567fceb",54102:"0057304a9b7c36fd",54176:"1c209b5691615c2d",55034:"91a22d75a4896d26",55156:"70eba4bb5853878e",55683:"c52199afe13b15ed",55973:"c413a5ed34ef941e",57041:"8e2e63f39906fd1e",57660:"e59694e7ee1dda97",58401:"3641b4aeb0a1db04",58633:"6d322b2074b1cd5b",58669:"5239eb8dd5a3486c",58699:"fa3b8ce67889f23b",59848:"e7330c096662be59",59865:"a0136e48383160ce",59907:"ad1253ca7a3c3cea",59944:"1c8f7a84b714a678",60206:"130abcb08ea9a564",60238:"36a32788f3ca64fe",60289:"cd3b3bd12d5566c1",60442:"b031854728be46ff",61719:"b6f17cb6498eec77",61728:"c943fe98606d2f24",61963:"18e80afc0dac41e3",62608:"4f3ab017447b17dc",62681:"86ea4a7f1240e2e6",63255:"262cd1e7cd35ffe9",63306:"03cdfc8e5118dd97",64663:"9974d163d89c8e9d",64733:"0790a2c763961b3f",65317:"7179d4bc41c8075a",65543:"a92297193082467c",65635:"f8007956118a4b5f",65838:"acacc76f9932a395",66109:"2a6ffd90bf3c50be",66166:"5d9b6692f44d4789",66420:"ed3b252047bf2d99",66895:"77a113ea7e9e0e19",66962:"e49d2beb52f4ccd7",67100:"6729ae254487b545",67142:"d2c7895f2f0c0ddb",67458:"930b27b1ef06fd49",67633:"7cfc302383a77925",67676:"7e4d1ac29a054c5a",67966:"9baea607f9d83322",67987:"eb24309f5b6a773f",68067:"b108a5ae88fd156b",68906:"e81b3cb0a0eb3c6e",69083:"a8e8997a24b8507c",69136:"7bc0b66e195430ba",69477:"4b854e377a3860cc",69763:"37d07a3035805bc7",70110:"a55f51e24556d059",70488:"dbde26374c2c08a2",70777:"9cde6b69988ac88e",70899:"75cac02cc1311c86",70901:"76003b037a2c2ad2",71547:"6f736dbb3265d938",71587:"942ffd492f15bdd6",71627:"4fa787d284261d08",71762:"0abb31b68e350f6b",72731:"5ac0a9cf8a2a916b",72740:"022c79c58cd39306",72977:"70c698df7ec867d8",73315:"46afbb4c2ae67b44",73354:"5ac4dbd55effe981",73506:"7423a313220e1769",73886:"c398daab959c90db",74250:"637853b68a0bb5dc",74312:"8d075f77e65364f2",74522:"ed3762dbb6b389b0",74962:"c0f9177875e7f100",75493:"5c2f7c166c002ee9",75693:"47f44d601521bc1b",75847:"0a83259a1ed4c4db",75958:"d9640c4cd9cdd74f",76399:"bb1a5dff754b7126",77008:"fe96b7655475e404",77768:"d5b6fe554fd62dbb",78425:"ee8445a0943525f2",78453:"3e109458064b76e4",78931:"2d78541331d4cf71",79035:"a682e63d1a6c820f",79422:"8e2e63f39906fd1e",79581:"3d0cbc1897c20b80",79788:"9cb75de83877d3a4",79806:"d210b93e41d4d7ff",79983:"6a9732776a2b07d1",80039:"b7b8926c9e98f166",80043:"fc4c6fd07c8c702c",80053:"cccea694a8be7b09",80192:"0b53419821781f47",80447:"cbc8dcd0610f9340",80478:"75454fe2622f8d60",80514:"c180393ccbb2f62e",80559:"4d1ea1e2bde6d65b",80653:"ba5596638b5efe48",80934:"cadd9fcd52d99096",81014:"7b65385965b83d33",81078:"d1b12131827159fc",81768:"13a175a018951bc8",82171:"e532a5af5a92acb9",82292:"2fb55f1ea9249601",82346:"d5de461383d78bd3",82666:"805e44c88f89e4f5",83086:"cf3390a953e4e275",83177:"4b3f31d9e183d57a",83561:"8959cb05be5bba5c",83842:"2211d720bd76fa0a",83978:"78a0d317cfb0f7fa",84553:"26f4216de4e92834",85120:"e1418b8e76b49092",85135:"45ba2b68ef521957",85350:"c86c2e91cf3d247e",85947:"cf4ac5dd618283ee",86533:"96712909323ba4fd",86749:"a4033144c9f1db80",86978:"fcbdaf718d4b4cb8",88087:"6ae9d65d22727e7d",88298:"33f9c586ab229ba6",88343:"f95f9ca9ad905248",88439:"528a166b33a003d3",88958:"3f88a829e6ab9f1d",89091:"e6f60560ceac7848",89231:"7bd196023a80ac20",89379:"ccf569c6fdc84136",89486:"ae3ab6537c32a471",90040:"a0d185d54c4405d8",90179:"1fbab23e5d44b4f0",90669:"fea27affbd10509b",90740:"15b9eae85318ce19",91246:"9377a763aead9164",91468:"5a3936bb7fa502b7",91469:"056f34e448b9e3e5",91709:"f7c8eff0c3692bd6",91848:"089cc7d1be73e1ca",92147:"1340020e2f5cbef2",92924:"d50fc7f02672d2e6",92966:"b84b80410d014b96",93008:"7c404d8dceb67ff3",93722:"8500c1244c0aef9d",93996:"d810c0882af7cbe0",94314:"3bd48a7f7f885bb5",94400:"30696ed643217da2",94521:"f712b07f8f7651a9",94568:"2a2be37b4884c8cd",94725:"da1eff47b3e365cc",94867:"0ee353b2db6bf4f7",95305:"440c9cb9053df6bf",95402:"71d2022a2e2d95ba",95470:"c594ecf25a203664",95792:"10f4124238152859",95963:"67eefa12cb90855f",96028:"427c0bd44fa35314",96132:"3bac072bb2743fb5",96230:"bf5cc20b343c438e",96309:"5c0610a0df7eaade",96554:"e768705a9558aa17",96623:"dd689039b85a3f89",96758:"b001e8afcb01a36d",97008:"ccf2a72ddb49895c",97229:"0b004c237f17530f",97543:"f224959967762c0b",97829:"bed98706765262d6",97974:"2157a18e2a93432f",98171:"be964141d5e6052f",98309:"223ad4f3e01558ae",98340:"8d1870938669f76e",99373:"20008a2c9ebbec89",99435:"73c4d651008c0493",99501:"c56a4f18b2fdff6a",99801:"9d73f814d33c5a86"})[e]+".js",c.miniCssF=e=>{},c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=(e,a)=>Object.prototype.hasOwnProperty.call(e,a),(()=>{var e={},a="_N_E:";c.l=(d,f,b,t)=>{if(e[d])return void e[d].push(f);if(void 0!==b)for(var r,n,o=document.getElementsByTagName("script"),i=0;i<o.length;i++){var s=o[i];if(s.getAttribute("src")==d||s.getAttribute("data-webpack")==a+b){r=s;break}}r||(n=!0,(r=document.createElement("script")).charset="utf-8",r.timeout=120,c.nc&&r.setAttribute("nonce",c.nc),r.setAttribute("data-webpack",a+b),r.src=c.tu(d)),e[d]=[f];var u=(a,c)=>{r.onerror=r.onload=null,clearTimeout(l);var f=e[d];if(delete e[d],r.parentNode&&r.parentNode.removeChild(r),f&&f.forEach(e=>e(c)),a)return a(c)},l=setTimeout(u.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=u.bind(null,r.onerror),r.onload=u.bind(null,r.onload),n&&document.head.appendChild(r)}})(),c.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},c.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),(()=>{var e;c.tt=()=>(void 0===e&&(e={createScriptURL:e=>e},"undefined"!=typeof trustedTypes&&trustedTypes.createPolicy&&(e=trustedTypes.createPolicy("nextjs#bundler",e))),e)})(),c.tu=e=>c.tt().createScriptURL(e),c.p="/_next/",(()=>{var e={78068:0,53169:0,32492:0,41282:0};c.f.j=(a,d)=>{var f=c.o(e,a)?e[a]:void 0;if(0!==f)if(f)d.push(f[2]);else if(/^(32492|41282|53169|78068)$/.test(a))e[a]=0;else{var b=new Promise((c,d)=>f=e[a]=[c,d]);d.push(f[2]=b);var t=c.p+c.u(a),r=Error();c.l(t,d=>{if(c.o(e,a)&&(0!==(f=e[a])&&(e[a]=void 0),f)){var b=d&&("load"===d.type?"missing":d.type),t=d&&d.target&&d.target.src;r.message="Loading chunk "+a+" failed.\n("+b+": "+t+")",r.name="ChunkLoadError",r.type=b,r.request=t,f[1](r)}},"chunk-"+a,a)}},c.O.j=a=>0===e[a];var a=(a,d)=>{var f,b,[t,r,n]=d,o=0;if(t.some(a=>0!==e[a])){for(f in r)c.o(r,f)&&(c.m[f]=r[f]);if(n)var i=n(c)}for(a&&a(d);o<t.length;o++)b=t[o],c.o(e,b)&&e[b]&&e[b][0](),e[b]=0;return c.O(i)},d=self.webpackChunk_N_E=self.webpackChunk_N_E||[];d.forEach(a.bind(null,0)),d.push=a.bind(null,d.push.bind(d))})(),c.nc=void 0})();
|
|
1
|
+
(()=>{"use strict";var e={},a={};function c(d){var f=a[d];if(void 0!==f)return f.exports;var b=a[d]={id:d,loaded:!1,exports:{}},t=!0;try{e[d].call(b.exports,b,b.exports,c),t=!1}finally{t&&delete a[d]}return b.loaded=!0,b.exports}c.m=e,(()=>{var e=[];c.O=(a,d,f,b)=>{if(d){b=b||0;for(var t=e.length;t>0&&e[t-1][2]>b;t--)e[t]=e[t-1];e[t]=[d,f,b];return}for(var r=1/0,t=0;t<e.length;t++){for(var[d,f,b]=e[t],n=!0,o=0;o<d.length;o++)(!1&b||r>=b)&&Object.keys(c.O).every(e=>c.O[e](d[o]))?d.splice(o--,1):(n=!1,b<r&&(r=b));if(n){e.splice(t--,1);var i=f();void 0!==i&&(a=i)}}return a}})(),c.n=e=>{var a=e&&e.__esModule?()=>e.default:()=>e;return c.d(a,{a:a}),a},(()=>{var e,a=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__;c.t=function(d,f){if(1&f&&(d=this(d)),8&f||"object"==typeof d&&d&&(4&f&&d.__esModule||16&f&&"function"==typeof d.then))return d;var b=Object.create(null);c.r(b);var t={};e=e||[null,a({}),a([]),a(a)];for(var r=2&f&&d;"object"==typeof r&&!~e.indexOf(r);r=a(r))Object.getOwnPropertyNames(r).forEach(e=>t[e]=()=>d[e]);return t.default=()=>d,c.d(b,t),b}})(),c.d=(e,a)=>{for(var d in a)c.o(a,d)&&!c.o(e,d)&&Object.defineProperty(e,d,{enumerable:!0,get:a[d]})},c.f={},c.e=e=>Promise.all(Object.keys(c.f).reduce((a,d)=>(c.f[d](e,a),a),[])),c.u=e=>70552===e?"static/chunks/"+e+"-0ea3c887937b5b51.js":27201===e?"static/chunks/"+e+"-0228042991534905.js":14753===e?"static/chunks/"+e+"-d911e24624c88fbc.js":26885===e?"static/chunks/"+e+"-00665cb87b9da098.js":45532===e?"static/chunks/"+e+"-12ed13c096e2a88e.js":30724===e?"static/chunks/"+e+"-627b849ed09f9cc5.js":97784===e?"static/chunks/"+e+"-7b90a17294840e32.js":93151===e?"static/chunks/f3524bc3-5c48b74c49ddeca0.js":41752===e?"static/chunks/fcc64ffe-de8d357e657bd162.js":16551===e?"static/chunks/"+e+"-68896c0ca7966ebf.js":"static/chunks/"+(({5571:"4e7df547",14749:"5db68f07",15968:"14860d7c",17203:"7a5af761",19019:"1496d684",20341:"cbbc2011",24364:"fbd0dcbb",32217:"1ccec16d",43245:"48c55e57",49954:"a856cf35",58669:"4f8e262c",65543:"685092b2",69136:"5be1c5d8",77008:"fab3cf95",80039:"f4bf7a28",82346:"273acdc0",83086:"8c93d9a0",95402:"f57f1d5e",95792:"f2442412"})[e]||e)+"."+({123:"b47ce56e923e1dc4",283:"4d4eca86c7abbec9",493:"737fdeba759d415a",1236:"ec9ed804634bb6cf",1697:"58e0d7523fdd2d52",1803:"8e2e63f39906fd1e",1847:"90012f795031fd15",2164:"d977bc7d148f1d9e",2351:"35085ef2663aaa44",2656:"febbce72896f5701",2829:"ae5196f6cb23aa62",2842:"a5f90cf26f897bfc",3333:"74af47ffa6cb4c0e",3709:"a528fc6526bb2f1d",4123:"bf0bc76b87e0a5d0",4151:"b8833633f487c3d5",4435:"0da86212e371da10",4860:"60152a625f2a714f",5020:"e7e6f35316da8d79",5336:"3fcd63f65fab9362",5559:"34e9e404696c82c0",5571:"fa34ffab38ba73b3",6178:"d88e2b68a2a1e09b",6685:"e23946c2ee579a76",7037:"d00688ceefb9f163",7123:"37f20f0e10894a3c",7140:"099e6f0e9722e08f",7317:"1a06bc56028637f6",7387:"f8cf2c36cf9b56dc",8563:"caa84c08a9db867a",8859:"fd4fa52883f05b54",9357:"084ac7f230f031a3",9560:"2e77d2dc6351b105",9634:"14999324d0128b0e",9858:"5eb9e5d689ee1188",9872:"bfcbe3b40e1ba7a3",10171:"8a96856626beb7ab",10667:"c192840fc1b34161",10742:"6cc4d6949065d15a",11160:"058f4a27a4ccab24",11688:"8c27089c45c98079",11966:"36fab6445e33609a",12139:"23195d4025c449dd",12850:"a5f6e9e87d0f9abd",12906:"f2105800b7dc9127",12994:"ea3d4eeb1b15ce47",13131:"e73eb283f14ed397",13437:"0de1f2000c75f497",13462:"b710822936d6d995",14438:"153e2ffb65627b56",14749:"5a8891ea355512a8",15666:"fd13db7fdfc4db46",15736:"4a506a1463e65905",15930:"faf0ba15488aa8ff",15968:"67246c65e7776fa2",16271:"298647c24de4c656",16428:"da33ee8ca31c4d8f",16564:"310c443d14c6e84b",16596:"3c557433b77dc606",16669:"c0967e6ad7401c26",17012:"78f2a6b93e37bf95",17045:"cf6dade16b25ffc7",17093:"ec17cca1979a34c5",17203:"84e2df2bf9d6c4a4",17881:"2eba69b477a8c7f7",18024:"360cc54c2f070fa1",18236:"02c13f95242e1147",18276:"4e4950daea1be290",18291:"6c48a745093c472f",19015:"e0d16d65430522c1",19019:"da3969c029230434",19338:"65cfcfafa18f6aee",19656:"ee0407bae11dd49b",20118:"5e7942f9d596e02b",20171:"9c80c2880256be96",20186:"2a00fa806bf383a5",20341:"a1649a45ba0da5ab",20586:"7cd940a582176e37",20587:"d03a7c9ddae70251",20851:"383095475aa0becf",21063:"5cc29b3160a78147",21233:"fbc3473b758427be",21285:"944c1ff822774352",21290:"ef2762694c3c05e5",21343:"eb8e7aeda8b2b933",21546:"8b2a80eefde810c5",21558:"e72df6c050a17223",21785:"19b23ee028f6262f",21789:"ad6ff228e2917e82",22190:"ee4e8f3ac0189d87",22463:"8f0a0111946c5e37",22485:"9f11764648028b9d",23338:"01f537c5dfd51363",23895:"a3ad3684a5b39547",24021:"e608f829b761ed19",24364:"a59ebe9142818688",24562:"f31cdddfe04624d0",24566:"605ccb37c2b09b7f",24976:"aea37ff8444ce6ca",25018:"51cf65637b375c88",25239:"e13f63bff8d7f459",25934:"45b477fc38b233d5",26558:"337afe8cd6c7f7e2",26594:"9cd92c85c51a3621",26604:"c5f0e687052abb59",27004:"7265fd004542a6ae",27261:"3ad525eea1f52dc3",27509:"8f83a84fed1129f3",27571:"33642de22553efae",27783:"70af75ac091e5b31",27929:"e9a99a263c294b0a",27992:"daf28998ef0714a0",28025:"1025ed4465b8b88e",28244:"3a5e72d3a4048558",28247:"e5faa56338e43301",29047:"664290ff8a84b205",29708:"0f9c08d7ca8a6036",30285:"7b6b107412564a45",30433:"919c34e206690a26",30550:"a8db081db527730d",30682:"c8fc49d63bf75772",31035:"06568e4accfa4664",31135:"8f2dbe06dab9d206",31204:"a8d94d78458557d5",31467:"2013df596c751e6e",31570:"131868ccedfef522",31618:"663e0a27f529a7b5",31635:"fcbdbf0d1e8271e8",31807:"cf2a0cbbe7eedf32",32092:"f10268018cf52339",32217:"31e64d0e8696d298",32411:"6d37c2b4b2f2efb7",32729:"f7ddbed25cb15da4",32800:"6cee7ff19ca516a7",32900:"57aa606259738bd7",33187:"13c12f5c0821ac57",33316:"6b5f8f344baf7a8a",33665:"20ed9144405f8b21",34037:"e8e16348aca40958",34414:"30d095dd419ccded",34500:"58eb096afca7a3d2",34520:"34ba1239c9b5a275",34565:"58e4d12c607709a2",34780:"ddc8d0403f86cd76",34787:"33a6fe2b98db58fd",34966:"dde9356d869e2a0f",35246:"75a72283c3c974e2",35362:"80b6e5545194566a",35733:"cf4ac3f521c0b06d",35901:"aa7ec713edff30e2",35918:"8e970e73c59cd315",36301:"0598cc26dfacc4a8",36531:"4576573d1554d0bc",36622:"2ecd0754a1dd1f10",36884:"6af20de227ae01d6",36989:"9a0a62410bf9ec4e",37697:"9af6ac899a8114c0",37802:"6e3d9ec6ded108e7",38176:"e1818cbc0df1edff",38259:"d83981da5c72c88a",38277:"f24d85bdc720318e",38513:"2edbf8332418852a",38542:"1b0e31f1f0e79950",38843:"bfbf5f2c316123fb",39012:"d1e022d895c7700f",40294:"82b8b706bf8526d2",41333:"464f95d32db59d47",41796:"b775772add38f765",42515:"0879489433824ebb",43203:"0a24d8e1e04b23e1",43245:"fd54cc2dd98a53cf",43335:"71662f3469b367dd",43520:"4abb22e9bfdeedab",44980:"c17d605b4685ba2d",44996:"e5fc9af9e1283894",45025:"bdb2a46a29ea6a7f",45300:"bac57dcaf4b1ae63",45939:"d37b9465101a9a32",45966:"ece098ca2637c63f",46366:"d1d9d65b646509b3",46778:"cbd78e2a3b8eb454",46783:"b9ce59941eb5c767",46965:"2ed4c28224e29499",47066:"7848777fc81f5714",47492:"6b259d6ee0ddf4d8",47613:"946226a67a1e5cd1",47781:"f25170364c271869",47914:"11c71123fcab1d66",47947:"471d5da6bb51de27",48504:"2efb153cab87148c",48782:"5b60e8a0f22f6da1",49114:"19ce7b83efab6d05",49294:"fb738cc8f6f972c0",49307:"9ac8482ed1916e3d",49312:"b4ee106f6ca8df0d",49406:"f77074487dddb735",49515:"c8964ec6f6c710d1",49812:"9bb0091da44f3fb0",49954:"22ac9c291887443d",50681:"5621dcb316c1dbc0",51094:"83d8278e86159ae3",51159:"cd7d830da0e9a7d2",52644:"999d7bbfb0c77212",52786:"cca2f572d4b83716",53012:"8ea1cc9b669d4071",53323:"19d0c542f89ec743",53854:"80e3b10f38882782",53988:"a7e066e48567fceb",54102:"0057304a9b7c36fd",54176:"1c209b5691615c2d",55034:"91a22d75a4896d26",55156:"70eba4bb5853878e",55683:"c52199afe13b15ed",55973:"c413a5ed34ef941e",57041:"8e2e63f39906fd1e",57660:"e59694e7ee1dda97",58401:"3641b4aeb0a1db04",58633:"6d322b2074b1cd5b",58669:"5239eb8dd5a3486c",58699:"fa3b8ce67889f23b",59848:"e7330c096662be59",59865:"a0136e48383160ce",59907:"ad1253ca7a3c3cea",59944:"1c8f7a84b714a678",60206:"130abcb08ea9a564",60238:"36a32788f3ca64fe",60289:"cd3b3bd12d5566c1",60442:"b031854728be46ff",61719:"b6f17cb6498eec77",61728:"c943fe98606d2f24",61963:"18e80afc0dac41e3",62608:"4f3ab017447b17dc",62681:"86ea4a7f1240e2e6",63255:"262cd1e7cd35ffe9",63306:"03cdfc8e5118dd97",64663:"9974d163d89c8e9d",64733:"0790a2c763961b3f",65317:"7179d4bc41c8075a",65543:"a92297193082467c",65635:"f8007956118a4b5f",65838:"acacc76f9932a395",66109:"2a6ffd90bf3c50be",66166:"5d9b6692f44d4789",66420:"ed3b252047bf2d99",66895:"77a113ea7e9e0e19",66962:"e49d2beb52f4ccd7",67100:"6729ae254487b545",67142:"d2c7895f2f0c0ddb",67458:"930b27b1ef06fd49",67633:"7cfc302383a77925",67676:"7e4d1ac29a054c5a",67966:"9baea607f9d83322",67987:"eb24309f5b6a773f",68067:"b108a5ae88fd156b",68906:"e81b3cb0a0eb3c6e",69083:"a8e8997a24b8507c",69136:"7bc0b66e195430ba",69477:"4b854e377a3860cc",69763:"37d07a3035805bc7",70110:"a55f51e24556d059",70488:"dbde26374c2c08a2",70777:"9cde6b69988ac88e",70899:"75cac02cc1311c86",70901:"76003b037a2c2ad2",71547:"6f736dbb3265d938",71587:"942ffd492f15bdd6",71627:"4fa787d284261d08",71762:"0abb31b68e350f6b",72731:"5ac0a9cf8a2a916b",72740:"022c79c58cd39306",72977:"70c698df7ec867d8",73315:"46afbb4c2ae67b44",73354:"5ac4dbd55effe981",73506:"7423a313220e1769",73886:"c398daab959c90db",74250:"637853b68a0bb5dc",74312:"8d075f77e65364f2",74522:"ed3762dbb6b389b0",74962:"c0f9177875e7f100",75493:"5c2f7c166c002ee9",75693:"47f44d601521bc1b",75847:"0a83259a1ed4c4db",75958:"d9640c4cd9cdd74f",76399:"bb1a5dff754b7126",77008:"fe96b7655475e404",77768:"d5b6fe554fd62dbb",78425:"ee8445a0943525f2",78453:"3e109458064b76e4",78931:"2d78541331d4cf71",79035:"a682e63d1a6c820f",79422:"8e2e63f39906fd1e",79581:"3d0cbc1897c20b80",79788:"9cb75de83877d3a4",79806:"d210b93e41d4d7ff",79983:"6a9732776a2b07d1",80039:"b7b8926c9e98f166",80043:"fc4c6fd07c8c702c",80053:"cccea694a8be7b09",80192:"0b53419821781f47",80447:"cbc8dcd0610f9340",80478:"75454fe2622f8d60",80514:"c180393ccbb2f62e",80559:"4d1ea1e2bde6d65b",80653:"ba5596638b5efe48",80934:"cadd9fcd52d99096",81014:"7b65385965b83d33",81078:"d1b12131827159fc",81768:"13a175a018951bc8",82171:"e532a5af5a92acb9",82292:"2fb55f1ea9249601",82346:"d5de461383d78bd3",82666:"805e44c88f89e4f5",83086:"cf3390a953e4e275",83177:"4b3f31d9e183d57a",83561:"8959cb05be5bba5c",83842:"2211d720bd76fa0a",83978:"78a0d317cfb0f7fa",84553:"26f4216de4e92834",85120:"e1418b8e76b49092",85135:"45ba2b68ef521957",85350:"c86c2e91cf3d247e",85947:"cf4ac5dd618283ee",86533:"96712909323ba4fd",86749:"a4033144c9f1db80",86978:"fcbdaf718d4b4cb8",88087:"6ae9d65d22727e7d",88298:"33f9c586ab229ba6",88343:"f95f9ca9ad905248",88439:"528a166b33a003d3",88958:"3f88a829e6ab9f1d",89091:"e6f60560ceac7848",89231:"7bd196023a80ac20",89379:"ccf569c6fdc84136",89486:"ae3ab6537c32a471",90040:"a0d185d54c4405d8",90179:"1fbab23e5d44b4f0",90669:"fea27affbd10509b",90740:"15b9eae85318ce19",91246:"9377a763aead9164",91468:"5a3936bb7fa502b7",91469:"056f34e448b9e3e5",91709:"f7c8eff0c3692bd6",91848:"089cc7d1be73e1ca",92147:"1340020e2f5cbef2",92924:"d50fc7f02672d2e6",92966:"b84b80410d014b96",93008:"7c404d8dceb67ff3",93722:"8500c1244c0aef9d",93996:"d810c0882af7cbe0",94314:"3bd48a7f7f885bb5",94400:"30696ed643217da2",94521:"f712b07f8f7651a9",94568:"2a2be37b4884c8cd",94725:"da1eff47b3e365cc",94867:"0ee353b2db6bf4f7",95305:"440c9cb9053df6bf",95402:"71d2022a2e2d95ba",95470:"c594ecf25a203664",95792:"10f4124238152859",95963:"67eefa12cb90855f",96028:"427c0bd44fa35314",96132:"3bac072bb2743fb5",96230:"bf5cc20b343c438e",96309:"5c0610a0df7eaade",96554:"e768705a9558aa17",96623:"dd689039b85a3f89",96758:"b001e8afcb01a36d",97008:"ccf2a72ddb49895c",97229:"0b004c237f17530f",97543:"f224959967762c0b",97829:"bed98706765262d6",97974:"2157a18e2a93432f",98171:"be964141d5e6052f",98309:"223ad4f3e01558ae",98340:"8d1870938669f76e",99373:"4d93aaaf56fe7819",99435:"73c4d651008c0493",99501:"c56a4f18b2fdff6a",99801:"9d73f814d33c5a86"})[e]+".js",c.miniCssF=e=>{},c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=(e,a)=>Object.prototype.hasOwnProperty.call(e,a),(()=>{var e={},a="_N_E:";c.l=(d,f,b,t)=>{if(e[d])return void e[d].push(f);if(void 0!==b)for(var r,n,o=document.getElementsByTagName("script"),i=0;i<o.length;i++){var s=o[i];if(s.getAttribute("src")==d||s.getAttribute("data-webpack")==a+b){r=s;break}}r||(n=!0,(r=document.createElement("script")).charset="utf-8",r.timeout=120,c.nc&&r.setAttribute("nonce",c.nc),r.setAttribute("data-webpack",a+b),r.src=c.tu(d)),e[d]=[f];var u=(a,c)=>{r.onerror=r.onload=null,clearTimeout(l);var f=e[d];if(delete e[d],r.parentNode&&r.parentNode.removeChild(r),f&&f.forEach(e=>e(c)),a)return a(c)},l=setTimeout(u.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=u.bind(null,r.onerror),r.onload=u.bind(null,r.onload),n&&document.head.appendChild(r)}})(),c.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},c.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),(()=>{var e;c.tt=()=>(void 0===e&&(e={createScriptURL:e=>e},"undefined"!=typeof trustedTypes&&trustedTypes.createPolicy&&(e=trustedTypes.createPolicy("nextjs#bundler",e))),e)})(),c.tu=e=>c.tt().createScriptURL(e),c.p="/_next/",(()=>{var e={78068:0,53169:0,32492:0,41282:0};c.f.j=(a,d)=>{var f=c.o(e,a)?e[a]:void 0;if(0!==f)if(f)d.push(f[2]);else if(/^(32492|41282|53169|78068)$/.test(a))e[a]=0;else{var b=new Promise((c,d)=>f=e[a]=[c,d]);d.push(f[2]=b);var t=c.p+c.u(a),r=Error();c.l(t,d=>{if(c.o(e,a)&&(0!==(f=e[a])&&(e[a]=void 0),f)){var b=d&&("load"===d.type?"missing":d.type),t=d&&d.target&&d.target.src;r.message="Loading chunk "+a+" failed.\n("+b+": "+t+")",r.name="ChunkLoadError",r.type=b,r.request=t,f[1](r)}},"chunk-"+a,a)}},c.O.j=a=>0===e[a];var a=(a,d)=>{var f,b,[t,r,n]=d,o=0;if(t.some(a=>0!==e[a])){for(f in r)c.o(r,f)&&(c.m[f]=r[f]);if(n)var i=n(c)}for(a&&a(d);o<t.length;o++)b=t[o],c.o(e,b)&&e[b]&&e[b][0](),e[b]=0;return c.O(i)},d=self.webpackChunk_N_E=self.webpackChunk_N_E||[];d.forEach(a.bind(null,0)),d.push=a.bind(null,d.push.bind(d))})(),c.nc=void 0})();
|