@agent-spaces/server 0.3.62 → 0.3.64
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/dist/adapters/agent-runtime-types.js +12 -0
- package/dist/adapters/claude-code-runtime/index.js +3 -0
- package/dist/adapters/claude-code-runtime/message-format.js +1 -1
- package/dist/adapters/codex-runtime.js +2 -2
- package/dist/adapters/git.js +161 -57
- package/dist/adapters/langchain-runtime.js +2 -2
- package/dist/adapters/open-agent-sdk-runtime.js +2 -2
- package/dist/agents/agent-designer.js +66 -12
- package/dist/agents/commit-agent.js +1 -0
- package/dist/agents/issue-agent-progress.js +4 -2
- package/dist/agents/issue-agent-runner.js +5 -5
- package/dist/agents/issue-task-controller.js +96 -15
- package/dist/app.js +123 -5
- package/dist/package.json +1 -1
- package/dist/routes/agent-commands.js +72 -0
- package/dist/routes/agent-sse.js +10 -2
- package/dist/routes/agent.js +15 -1
- package/dist/routes/database.js +345 -0
- package/dist/routes/git.js +52 -1
- package/dist/routes/hooks.js +88 -0
- package/dist/routes/issue.js +59 -1
- package/dist/routes/kanban.js +39 -0
- package/dist/routes/output-style.js +48 -0
- package/dist/routes/prompt-template.js +2 -2
- package/dist/routes/skill.js +86 -15
- package/dist/routes/task.js +13 -1
- package/dist/services/agent-commands.js +168 -0
- package/dist/services/builtin-tools/command-tools.js +117 -0
- package/dist/services/builtin-tools/database-tools.js +578 -0
- package/dist/services/builtin-tools/index.js +5 -0
- package/dist/services/builtin-tools/input-helpers.js +26 -0
- package/dist/services/builtin-tools/issue-tools.js +209 -0
- package/dist/services/builtin-tools/kanban-tools.js +277 -0
- package/dist/services/database-vector.js +244 -0
- package/dist/services/hook-engine.js +118 -0
- package/dist/services/issue.js +6 -0
- package/dist/services/kanban.js +50 -0
- package/dist/services/notification-hub/bot-agent.js +1 -0
- package/dist/services/output-style.js +134 -0
- package/dist/services/prompt-template.js +2 -2
- package/dist/services/skill.js +148 -35
- package/dist/storage/database-store.js +365 -0
- package/dist/storage/hook-store.js +55 -0
- package/dist/storage/kanban-store.js +142 -0
- package/dist/web/404.html +1 -1
- package/dist/web/__next.__PAGE__.txt +4 -4
- package/dist/web/__next._full.txt +26 -30
- package/dist/web/__next._head.txt +4 -4
- package/dist/web/__next._index.txt +14 -14
- package/dist/web/__next._tree.txt +3 -8
- package/dist/web/_next/static/chunks/0-9194nbxy_6d.js +1 -0
- package/dist/web/_next/static/chunks/0-f~0xmwl__u5.js +1 -0
- package/dist/web/_next/static/chunks/0.n~yfwf4~6w-.js +1 -0
- package/dist/web/_next/static/chunks/002_j970b9gdx.js +1 -0
- package/dist/web/_next/static/chunks/01iqv28_snwus.js +1 -0
- package/dist/web/_next/static/chunks/01~quun6sefgl.js +1 -0
- package/dist/web/_next/static/chunks/02mf61htij8g0.js +31 -0
- package/dist/web/_next/static/chunks/03scq1-0ykve3.js +1 -0
- package/dist/web/_next/static/chunks/04a4vsq2wknm4.js +1 -0
- package/dist/web/_next/static/chunks/04dg4l4hv11q2.js +3 -0
- package/dist/web/_next/static/chunks/04fxddw-y20~-.js +7 -0
- package/dist/web/_next/static/chunks/04w7~5ooz_pwm.js +1 -0
- package/dist/web/_next/static/chunks/05oc21sj24wtq.js +1 -0
- package/dist/web/_next/static/chunks/{0zd1o3u04~qvo.js → 05psi2gtx~bev.js} +7 -7
- package/dist/web/_next/static/chunks/{0-oog4zg4_m~m.css → 062f9zqctzg.b.css} +0 -3
- package/dist/web/_next/static/chunks/{12odetnu-lyrr.js → 06whz1~s_7pva.js} +12 -12
- package/dist/web/_next/static/chunks/08ckpwmmwlors.js +3 -0
- package/dist/web/_next/static/chunks/08k~meqbd8d6v.js +1 -0
- package/dist/web/_next/static/chunks/099h96wjsdb25.js +2 -0
- package/dist/web/_next/static/chunks/09h23logvq65m.js +1 -0
- package/dist/web/_next/static/chunks/{0njy89g5coeyi.js → 0_8dm7bxp18xo.js} +6 -6
- package/dist/web/_next/static/chunks/0_mvduwjsm35w.js +1 -0
- package/dist/web/_next/static/chunks/0_vi1a~g4wx46.js +3 -0
- package/dist/web/_next/static/chunks/0a5y-vhf4i5id.js +3 -0
- package/dist/web/_next/static/chunks/0ake2f3x2uan4.js +24 -0
- package/dist/web/_next/static/chunks/{0tvd~rxgf0oh_.js → 0bbmx45w_h5np.js} +1 -1
- package/dist/web/_next/static/chunks/0ck8dw_9-1cdx.js +1 -0
- package/dist/web/_next/static/chunks/{07a0rktf_nr5h.js → 0ctg5qmw7uu.1.js} +2 -2
- package/dist/web/_next/static/chunks/0ewceguykiut5.js +1 -0
- package/dist/web/_next/static/chunks/0f7cb9li~3jra.js +67 -0
- package/dist/web/_next/static/chunks/0fttswpzu69qx.js +1 -0
- package/dist/web/_next/static/chunks/0ghs9on7wodrm.js +1 -0
- package/dist/web/_next/static/chunks/0ghx3j_.-gdyd.js +1 -0
- package/dist/web/_next/static/chunks/{0202ia13sijwb.js → 0h18ej5yf974e.js} +1 -1
- package/dist/web/_next/static/chunks/0h9cu-k6z5o08.js +1 -0
- package/dist/web/_next/static/chunks/0i39jifmxla7q.js +1 -0
- package/dist/web/_next/static/chunks/0iuf30t0rjsjv.js +19 -0
- package/dist/web/_next/static/chunks/0jb4~3qqkw2ps.js +1 -0
- package/dist/web/_next/static/chunks/0k4zdm72k_bfy.js +1 -0
- package/dist/web/_next/static/chunks/{08o-zmr-40r5g.js → 0m11vvph7q94-.js} +1 -1
- package/dist/web/_next/static/chunks/0n6_4so_afuwk.js +71 -0
- package/dist/web/_next/static/chunks/0nb8.iteznuvx.js +1 -0
- package/dist/web/_next/static/chunks/0np.d~hc1-pmh.js +4 -0
- package/dist/web/_next/static/chunks/{0qpq0~_58fe9a.js → 0oaq67r7ix.vg.js} +1 -1
- package/dist/web/_next/static/chunks/{0d_dp_4ofz0l3.css → 0ojcao3hdm36s.css} +0 -1
- package/dist/web/_next/static/chunks/0os58q93stt7j.js +3 -0
- package/dist/web/_next/static/chunks/{0gig.k.rq8d0x.js → 0ppr271hz0xoq.js} +1 -1
- package/dist/web/_next/static/chunks/0s9lmk8iauou3.js +1 -0
- package/dist/web/_next/static/chunks/0sp_zbx~w0am7.js +1 -0
- package/dist/web/_next/static/chunks/0tel~zsv4z8l_.js +1 -0
- package/dist/web/_next/static/chunks/0twamv4wr_dbv.js +1 -0
- package/dist/web/_next/static/chunks/0uhol5wafdbl~.js +1 -0
- package/dist/web/_next/static/chunks/0v3a_x4vt42kx.js +5 -0
- package/dist/web/_next/static/chunks/{002-dxhags4dj.js → 0v6hte2z-32ca.js} +2 -2
- package/dist/web/_next/static/chunks/0v7q4mys.mnm..css +1 -0
- package/dist/web/_next/static/chunks/0vbqaynjq8ga..js +3 -0
- package/dist/web/_next/static/chunks/0xbaakj0dfc0..js +1 -0
- package/dist/web/_next/static/chunks/{0..g0jl-8qup7.js → 0xoo17yef_b8g.js} +1 -1
- package/dist/web/_next/static/chunks/0xt-8wk21gs7g.js +1 -0
- package/dist/web/_next/static/chunks/0za1r07-6az6w.js +1 -0
- package/dist/web/_next/static/chunks/0z~vqzbm_q371.js +1 -0
- package/dist/web/_next/static/chunks/0~3xm80~j9ddg.js +1 -0
- package/dist/web/_next/static/chunks/0~u.5r3-t7179.js +1 -0
- package/dist/web/_next/static/chunks/10l-9myrdo3x9.js +1 -0
- package/dist/web/_next/static/chunks/11-czmcci_55y.js +1 -0
- package/dist/web/_next/static/chunks/11k-.49r~1mfm.js +1 -0
- package/dist/web/_next/static/chunks/{0k.8qdk7oi_os.js → 128ugqd34tr_-.js} +1 -1
- package/dist/web/_next/static/chunks/12jm4gwmvq-0q.js +90 -0
- package/dist/web/_next/static/chunks/{0rke_patcovgr.js → 1442stwa0gbxe.js} +1 -1
- package/dist/web/_next/static/chunks/{0jokpgh485~28.js → 14hqmid8q4apf.js} +11 -11
- package/dist/web/_next/static/chunks/14s37n6h0_q3x.js +16 -0
- package/dist/web/_next/static/chunks/161ik5kfyuwtd.js +1 -0
- package/dist/web/_next/static/chunks/16sg-lflc8csx.js +1 -0
- package/dist/web/_next/static/chunks/17k~zbv0_4rep.js +1 -0
- package/dist/web/_next/static/chunks/17oc2l.ekcs8b.css +1 -0
- package/dist/web/_next/static/chunks/{turbopack-0lrdxynxb9-1t.js → turbopack-0ndm2zc_pdptk.js} +1 -1
- package/dist/web/_not-found/__next._full.txt +30 -31
- package/dist/web/_not-found/__next._head.txt +4 -4
- package/dist/web/_not-found/__next._index.txt +14 -14
- package/dist/web/_not-found/__next._not-found.__PAGE__.txt +2 -2
- package/dist/web/_not-found/__next._not-found.txt +3 -3
- package/dist/web/_not-found/__next._tree.txt +3 -3
- package/dist/web/_not-found.html +1 -1
- package/dist/web/_not-found.txt +30 -31
- package/dist/web/index.html +1 -1
- package/dist/web/index.txt +26 -30
- package/dist/web/login/__next._full.txt +32 -36
- package/dist/web/login/__next._head.txt +4 -4
- package/dist/web/login/__next._index.txt +14 -14
- package/dist/web/login/__next._tree.txt +3 -8
- package/dist/web/login/__next.login.__PAGE__.txt +4 -4
- package/dist/web/login/__next.login.txt +3 -3
- package/dist/web/login.html +1 -1
- package/dist/web/login.txt +32 -36
- package/dist/web/settings/__next._full.txt +29 -34
- package/dist/web/settings/__next._head.txt +4 -4
- package/dist/web/settings/__next._index.txt +14 -14
- package/dist/web/settings/__next._tree.txt +3 -8
- package/dist/web/settings/__next.settings.__PAGE__.txt +4 -4
- package/dist/web/settings/__next.settings.txt +5 -5
- package/dist/web/settings/agents/__next._full.txt +27 -32
- package/dist/web/settings/agents/__next._head.txt +4 -4
- package/dist/web/settings/agents/__next._index.txt +14 -14
- package/dist/web/settings/agents/__next._tree.txt +3 -8
- package/dist/web/settings/agents/__next.settings.agents.__PAGE__.txt +4 -4
- package/dist/web/settings/agents/__next.settings.agents.txt +3 -3
- package/dist/web/settings/agents/__next.settings.txt +5 -5
- package/dist/web/settings/agents.html +1 -1
- package/dist/web/settings/agents.txt +27 -32
- package/dist/web/settings/mcps/__next._full.txt +27 -32
- package/dist/web/settings/mcps/__next._head.txt +4 -4
- package/dist/web/settings/mcps/__next._index.txt +14 -14
- package/dist/web/settings/mcps/__next._tree.txt +3 -8
- package/dist/web/settings/mcps/__next.settings.mcps.__PAGE__.txt +4 -4
- package/dist/web/settings/mcps/__next.settings.mcps.txt +3 -3
- package/dist/web/settings/mcps/__next.settings.txt +5 -5
- package/dist/web/settings/mcps.html +1 -1
- package/dist/web/settings/mcps.txt +27 -32
- package/dist/web/settings/models/__next._full.txt +27 -32
- package/dist/web/settings/models/__next._head.txt +4 -4
- package/dist/web/settings/models/__next._index.txt +14 -14
- package/dist/web/settings/models/__next._tree.txt +3 -8
- package/dist/web/settings/models/__next.settings.models.__PAGE__.txt +4 -4
- package/dist/web/settings/models/__next.settings.models.txt +3 -3
- package/dist/web/settings/models/__next.settings.txt +5 -5
- package/dist/web/settings/models.html +1 -1
- package/dist/web/settings/models.txt +27 -32
- package/dist/web/settings/output-styles/__next._full.txt +38 -0
- package/dist/web/settings/output-styles/__next._head.txt +6 -0
- package/dist/web/settings/output-styles/__next._index.txt +15 -0
- package/dist/web/settings/output-styles/__next._tree.txt +3 -0
- package/dist/web/settings/output-styles/__next.settings.output-styles.__PAGE__.txt +9 -0
- package/dist/web/settings/output-styles/__next.settings.output-styles.txt +5 -0
- package/dist/web/settings/output-styles/__next.settings.txt +7 -0
- package/dist/web/settings/output-styles.html +1 -0
- package/dist/web/settings/output-styles.txt +38 -0
- package/dist/web/settings/prompts/__next._full.txt +27 -32
- package/dist/web/settings/prompts/__next._head.txt +4 -4
- package/dist/web/settings/prompts/__next._index.txt +14 -14
- package/dist/web/settings/prompts/__next._tree.txt +3 -8
- package/dist/web/settings/prompts/__next.settings.prompts.__PAGE__.txt +4 -4
- package/dist/web/settings/prompts/__next.settings.prompts.txt +3 -3
- package/dist/web/settings/prompts/__next.settings.txt +5 -5
- package/dist/web/settings/prompts.html +1 -1
- package/dist/web/settings/prompts.txt +27 -32
- package/dist/web/settings/providers/__next._full.txt +27 -32
- package/dist/web/settings/providers/__next._head.txt +4 -4
- package/dist/web/settings/providers/__next._index.txt +14 -14
- package/dist/web/settings/providers/__next._tree.txt +3 -8
- package/dist/web/settings/providers/__next.settings.providers.__PAGE__.txt +4 -4
- package/dist/web/settings/providers/__next.settings.providers.txt +3 -3
- package/dist/web/settings/providers/__next.settings.txt +5 -5
- package/dist/web/settings/providers.html +1 -1
- package/dist/web/settings/providers.txt +27 -32
- package/dist/web/settings/skills/__next._full.txt +27 -32
- package/dist/web/settings/skills/__next._head.txt +4 -4
- package/dist/web/settings/skills/__next._index.txt +14 -14
- package/dist/web/settings/skills/__next._tree.txt +3 -8
- package/dist/web/settings/skills/__next.settings.skills.__PAGE__.txt +4 -4
- package/dist/web/settings/skills/__next.settings.skills.txt +3 -3
- package/dist/web/settings/skills/__next.settings.txt +5 -5
- package/dist/web/settings/skills.html +1 -1
- package/dist/web/settings/skills.txt +27 -32
- package/dist/web/settings/tools/__next._full.txt +38 -0
- package/dist/web/settings/tools/__next._head.txt +6 -0
- package/dist/web/settings/tools/__next._index.txt +15 -0
- package/dist/web/settings/tools/__next._tree.txt +3 -0
- package/dist/web/settings/tools/__next.settings.tools.__PAGE__.txt +9 -0
- package/dist/web/settings/tools/__next.settings.tools.txt +5 -0
- package/dist/web/settings/tools/__next.settings.txt +7 -0
- package/dist/web/settings/tools.html +1 -0
- package/dist/web/settings/tools.txt +38 -0
- package/dist/web/settings.html +1 -1
- package/dist/web/settings.txt +29 -34
- package/dist/web/workflows/__next._full.txt +34 -37
- package/dist/web/workflows/__next._head.txt +4 -4
- package/dist/web/workflows/__next._index.txt +14 -14
- package/dist/web/workflows/__next._tree.txt +3 -8
- package/dist/web/workflows/__next.workflows.__PAGE__.txt +4 -4
- package/dist/web/workflows/__next.workflows.txt +3 -3
- package/dist/web/workflows.html +1 -1
- package/dist/web/workflows.txt +34 -37
- package/dist/web/workspace/_/__next._full.txt +32 -77
- package/dist/web/workspace/_/__next._head.txt +4 -4
- package/dist/web/workspace/_/__next._index.txt +14 -14
- package/dist/web/workspace/_/__next._tree.txt +4 -23
- package/dist/web/workspace/_/__next.workspace.$d$id.__PAGE__.txt +3 -18
- package/dist/web/workspace/_/__next.workspace.$d$id.txt +3 -3
- package/dist/web/workspace/_/__next.workspace.txt +3 -3
- package/dist/web/workspace/_.html +1 -1
- package/dist/web/workspace/_.txt +32 -77
- package/dist/web/workspaces/__next._full.txt +32 -38
- package/dist/web/workspaces/__next._head.txt +4 -4
- package/dist/web/workspaces/__next._index.txt +14 -14
- package/dist/web/workspaces/__next._tree.txt +3 -8
- package/dist/web/workspaces/__next.workspaces.__PAGE__.txt +4 -4
- package/dist/web/workspaces/__next.workspaces.txt +3 -3
- package/dist/web/workspaces.html +1 -1
- package/dist/web/workspaces.txt +32 -38
- package/dist/ws/agent-prompt.js +45 -8
- package/dist/ws/agent-runner.js +10 -6
- package/package.json +11 -10
- package/public/output-styles/carmack-mode.md +381 -0
- package/public/output-styles/codex-rigor-mode.md +114 -0
- package/public/output-styles/dhh-mode.md +265 -0
- package/public/output-styles/evan-you-mode.md +539 -0
- package/public/output-styles/index.json +37 -0
- package/public/output-styles/jobs-mode.md +369 -0
- package/public/output-styles/linus-mode.md +135 -0
- package/public/output-styles/uncle-bob-mode.md +221 -0
- package/public/prompt/andrej-karpathy-skills.md +65 -0
- package/public/prompt/claude-token-efficient-coding.md +35 -0
- package/public/prompt/index.json +12 -0
- package/public/skills/index.json +92 -0
- package/public/skills/planning-with-files/planning-with-files-zh/SKILL.md +243 -0
- package/public/skills/planning-with-files/planning-with-files-zh/scripts/check-complete.ps1 +44 -0
- package/public/skills/planning-with-files/planning-with-files-zh/scripts/check-complete.sh +46 -0
- package/public/skills/planning-with-files/planning-with-files-zh/scripts/init-session.ps1 +124 -0
- package/public/skills/planning-with-files/planning-with-files-zh/scripts/init-session.sh +124 -0
- package/public/skills/planning-with-files/planning-with-files-zh/scripts/session-catchup.py +438 -0
- package/public/skills/planning-with-files/planning-with-files-zh/templates/findings.md +29 -0
- package/public/skills/planning-with-files/planning-with-files-zh/templates/progress.md +40 -0
- package/public/skills/planning-with-files/planning-with-files-zh/templates/task_plan.md +58 -0
- package/public/skills/superpowers/brainstorming/SKILL.md +164 -0
- package/public/skills/superpowers/brainstorming/scripts/frame-template.html +214 -0
- package/public/skills/superpowers/brainstorming/scripts/helper.js +88 -0
- package/public/skills/superpowers/brainstorming/scripts/server.cjs +354 -0
- package/public/skills/superpowers/brainstorming/scripts/start-server.sh +148 -0
- package/public/skills/superpowers/brainstorming/scripts/stop-server.sh +56 -0
- package/public/skills/superpowers/brainstorming/spec-document-reviewer-prompt.md +49 -0
- package/public/skills/superpowers/brainstorming/visual-companion.md +287 -0
- package/public/skills/superpowers/dispatching-parallel-agents/SKILL.md +182 -0
- package/public/skills/superpowers/executing-plans/SKILL.md +70 -0
- package/public/skills/superpowers/finishing-a-development-branch/SKILL.md +251 -0
- package/public/skills/superpowers/receiving-code-review/SKILL.md +213 -0
- package/public/skills/superpowers/requesting-code-review/SKILL.md +103 -0
- package/public/skills/superpowers/requesting-code-review/code-reviewer.md +168 -0
- package/public/skills/superpowers/subagent-driven-development/SKILL.md +279 -0
- package/public/skills/superpowers/subagent-driven-development/code-quality-reviewer-prompt.md +25 -0
- package/public/skills/superpowers/subagent-driven-development/implementer-prompt.md +113 -0
- package/public/skills/superpowers/subagent-driven-development/spec-reviewer-prompt.md +61 -0
- package/public/skills/superpowers/systematic-debugging/CREATION-LOG.md +119 -0
- package/public/skills/superpowers/systematic-debugging/SKILL.md +296 -0
- package/public/skills/superpowers/systematic-debugging/condition-based-waiting-example.ts +158 -0
- package/public/skills/superpowers/systematic-debugging/condition-based-waiting.md +115 -0
- package/public/skills/superpowers/systematic-debugging/defense-in-depth.md +122 -0
- package/public/skills/superpowers/systematic-debugging/find-polluter.sh +63 -0
- package/public/skills/superpowers/systematic-debugging/root-cause-tracing.md +169 -0
- package/public/skills/superpowers/systematic-debugging/test-academic.md +14 -0
- package/public/skills/superpowers/systematic-debugging/test-pressure-1.md +58 -0
- package/public/skills/superpowers/systematic-debugging/test-pressure-2.md +68 -0
- package/public/skills/superpowers/systematic-debugging/test-pressure-3.md +69 -0
- package/public/skills/superpowers/test-driven-development/SKILL.md +371 -0
- package/public/skills/superpowers/test-driven-development/testing-anti-patterns.md +299 -0
- package/public/skills/superpowers/using-git-worktrees/SKILL.md +215 -0
- package/public/skills/superpowers/using-superpowers/SKILL.md +117 -0
- package/public/skills/superpowers/using-superpowers/references/codex-tools.md +59 -0
- package/public/skills/superpowers/using-superpowers/references/copilot-tools.md +42 -0
- package/public/skills/superpowers/using-superpowers/references/gemini-tools.md +51 -0
- package/public/skills/superpowers/verification-before-completion/SKILL.md +139 -0
- package/public/skills/superpowers/writing-plans/SKILL.md +152 -0
- package/public/skills/superpowers/writing-plans/plan-document-reviewer-prompt.md +49 -0
- package/public/skills/superpowers/writing-skills/SKILL.md +655 -0
- package/public/skills/superpowers/writing-skills/anthropic-best-practices.md +1150 -0
- package/public/skills/superpowers/writing-skills/examples/CLAUDE_MD_TESTING.md +189 -0
- package/public/skills/superpowers/writing-skills/graphviz-conventions.dot +172 -0
- package/public/skills/superpowers/writing-skills/persuasion-principles.md +187 -0
- package/public/skills/superpowers/writing-skills/render-graphs.js +168 -0
- package/public/skills/superpowers/writing-skills/testing-skills-with-subagents.md +384 -0
- package/dist/web/_next/static/chunks/0-81wi7xr2nd-.js +0 -270
- package/dist/web/_next/static/chunks/00lca9lsasdm7.js +0 -1
- package/dist/web/_next/static/chunks/01gi~q0c6ez6..js +0 -1
- package/dist/web/_next/static/chunks/02shswpmybici.js +0 -1
- package/dist/web/_next/static/chunks/05tx6hzdtkgi9.js +0 -2
- package/dist/web/_next/static/chunks/07nbyndvzftr1.js +0 -3
- package/dist/web/_next/static/chunks/0bn~onkv~9xza.js +0 -1
- package/dist/web/_next/static/chunks/0g-0n6glz_z6w.js +0 -1
- package/dist/web/_next/static/chunks/0gyede80jpy3n.js +0 -4
- package/dist/web/_next/static/chunks/0hrbuvzuxrjfl.js +0 -1
- package/dist/web/_next/static/chunks/0i51q.5s_-.vh.css +0 -1
- package/dist/web/_next/static/chunks/0qf163pbrwy4z.js +0 -1
- package/dist/web/_next/static/chunks/0rnt-f3pjxb-d.js +0 -5
- package/dist/web/_next/static/chunks/0tgbcgsca9mrg.js +0 -1
- package/dist/web/_next/static/chunks/0tyhv6.y7~yxd.js +0 -1
- package/dist/web/_next/static/chunks/0u7_qd9hzqwac.js +0 -1
- package/dist/web/_next/static/chunks/0vuvql8rloda5.js +0 -1
- package/dist/web/_next/static/chunks/0wv0h27jafag4.js +0 -1
- package/dist/web/_next/static/chunks/0wwvc4zc2q6bn.js +0 -1
- package/dist/web/_next/static/chunks/0xmmk3vebw8xs.js +0 -1
- package/dist/web/_next/static/chunks/0xwqf.llmm_u2.js +0 -31
- package/dist/web/_next/static/chunks/0yo22_w53mo~5.js +0 -1
- package/dist/web/_next/static/chunks/12c0jp0qvlr1t.js +0 -1
- package/dist/web/_next/static/chunks/12pg1nn3v~~5k.js +0 -1
- package/dist/web/_next/static/chunks/16cyr8ilpx1nn.js +0 -1
- package/dist/web/_next/static/media/0a7740363b4d4863-s.1110aazvokzp..woff2 +0 -0
- package/dist/web/_next/static/media/0da9c7f357bd9d4d-s.0ek5sshv8wk3m.woff2 +0 -0
- package/dist/web/_next/static/media/1b99372b3eaef0c8-s.p.0gx2haw2tmll8.woff2 +0 -0
- package/dist/web/_next/static/media/41e95f694c5c4549-s.0r1jrq7neqdsq.woff2 +0 -0
- package/dist/web/_next/static/media/5c285b27cdda1fe8-s.p.0yo6-5yoeeudq.woff2 +0 -0
- package/dist/web/_next/static/media/5f9d24ebef5d5292-s.0esuu2f5si~v8.woff2 +0 -0
- package/dist/web/_next/static/media/6c55a692938ebbbc-s.0g6rbszwfgn9y.woff2 +0 -0
- package/dist/web/_next/static/media/8e6fa89aa22d24ec-s.p.0uvzar8hswo3p.woff2 +0 -0
- package/dist/web/_next/static/media/a218039a3287bcfd-s.p.17-1enzs_j91b.woff2 +0 -0
- package/dist/web/_next/static/media/b2ea385cb5ae8625-s.0kjod.kaq1k69.woff2 +0 -0
- package/dist/web/_next/static/media/bdc7e24a509eb931-s.0apt5mko2.qn3.woff2 +0 -0
- package/dist/web/_next/static/media/c3cb240f9c892514-s.163v2i5cux7-c.woff2 +0 -0
- package/dist/web/_next/static/media/e2334d715941921e-s.p.12skym0rqknxy.woff2 +0 -0
- package/public/avatars/1777813826407-bea0ja-minimax.svg +0 -1
- package/public/avatars/1777813967088-3xlvd0-minimax.svg +0 -1
- package/public/avatars/1777814041714-yp0qeq-minimax.svg +0 -1
- package/public/avatars/1777904986095-rg26je-icon.png +0 -0
- package/public/avatars/1778953228323-5je54x-user.jpg +0 -0
- package/public/avatars/1778954057880-g01q6y-user.jpg +0 -0
- /package/dist/web/_next/static/{GS3b40oeaeLxm7i9-ibaj → e8w3vd9Eov_LDYWj_0zsE}/_buildManifest.js +0 -0
- /package/dist/web/_next/static/{GS3b40oeaeLxm7i9-ibaj → e8w3vd9Eov_LDYWj_0zsE}/_clientMiddlewareManifest.js +0 -0
- /package/dist/web/_next/static/{GS3b40oeaeLxm7i9-ibaj → e8w3vd9Eov_LDYWj_0zsE}/_ssgManifest.js +0 -0
- /package/public/avatars/{1777815865622-08wp9m-user.jpg → user.jpg} +0 -0
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
.monaco-editor.standalone{--monaco-monospace-font:"SF Mono", Monaco, Menlo, Consolas, "Ubuntu Mono", "Liberation Mono", "DejaVu Sans Mono", "Courier New", monospace;font-family:-apple-system,BlinkMacSystemFont,Segoe WPC,Segoe UI,HelveticaNeue-Light,system-ui,Ubuntu,Droid Sans,sans-serif}.monaco-menu .monaco-action-bar.vertical .action-item .action-menu-item:focus .action-label,.monaco-editor.standalone.vs-dark .monaco-menu .monaco-action-bar.vertical .action-menu-item:focus .action-label,.monaco-editor.standalone.hc-black .monaco-menu .monaco-action-bar.vertical .action-menu-item:focus .action-label,.monaco-editor.standalone.hc-light .monaco-menu .monaco-action-bar.vertical .action-menu-item:focus .action-label{stroke-width:1.2px}.monaco-hover p{margin:0}.monaco-aria-container{clip:rect(1px, 1px, 1px, 1px);clip-path:inset(50%);width:1px;height:1px;margin:-1px;padding:0;top:0;overflow:hidden;position:absolute!important}.monaco-editor.standalone .synthetic-focus,.monaco-diff-editor.standalone .synthetic-focus,.monaco-editor.standalone [tabindex="0"]:focus,.monaco-diff-editor.standalone [tabindex="0"]:focus,.monaco-editor.standalone [tabindex="-1"]:focus,.monaco-diff-editor.standalone [tabindex="-1"]:focus,.monaco-editor.standalone button:focus,.monaco-diff-editor.standalone button:focus,.monaco-editor.standalone input[type=button]:focus,.monaco-diff-editor.standalone input[type=button]:focus,.monaco-editor.standalone input[type=checkbox]:focus,.monaco-diff-editor.standalone input[type=checkbox]:focus,.monaco-editor.standalone input[type=search]:focus,.monaco-diff-editor.standalone input[type=search]:focus,.monaco-editor.standalone input[type=text]:focus,.monaco-diff-editor.standalone input[type=text]:focus,.monaco-editor.standalone select:focus,.monaco-diff-editor.standalone select:focus,.monaco-editor.standalone textarea:focus,.monaco-diff-editor.standalone textarea:focus{outline-offset:-1px;outline-width:1px;outline-style:solid;outline-color:var(--vscode-focusBorder);opacity:1}
|
|
2
2
|
.monaco-component.multiDiffEditor{background:var(--vscode-multiDiffEditor-background);width:100%;height:100%;position:relative;overflow-y:hidden}.monaco-component.multiDiffEditor>div{width:100%;height:100%;position:absolute;top:0;left:0}.monaco-component.multiDiffEditor>div.placeholder{visibility:hidden}.monaco-component.multiDiffEditor>div.placeholder.visible{visibility:visible}.monaco-component.multiDiffEditor>div.placeholder{place-content:center;place-items:center;display:grid}.monaco-component.multiDiffEditor>.multi-diff-root-floating-menu{width:auto;height:auto;color:var(--vscode-button-foreground);background-color:var(--vscode-button-background);border:1px solid var(--vscode-contrastBorder);z-index:10;box-shadow:0 3px 12px var(--vscode-widget-shadow);border-radius:4px;align-items:center;padding:4px 6px;display:flex;position:absolute;inset:auto 32px 32px auto;overflow:hidden}.monaco-component.multiDiffEditor .multi-diff-root-floating-menu .action-item>.action-label{border-radius:2px;padding:7px 8px;font-size:15px}.monaco-component.multiDiffEditor .multi-diff-root-floating-menu .action-item>.action-label.codicon{color:var(--vscode-button-foreground)}.monaco-component.multiDiffEditor .multi-diff-root-floating-menu .action-item>.action-label.codicon:not(.separator){padding-top:6px;padding-bottom:6px}.monaco-component.multiDiffEditor .multi-diff-root-floating-menu .action-item:first-child>.action-label{padding-left:7px}.monaco-component.multiDiffEditor .multi-diff-root-floating-menu .action-item:last-child>.action-label{padding-right:7px}.monaco-component.multiDiffEditor .multi-diff-root-floating-menu .action-item .action-label.separator{background-color:var(--vscode-button-separator)}.monaco-component.multiDiffEditor .active{--vscode-multiDiffEditor-border:var(--vscode-focusBorder)}.monaco-component.multiDiffEditor .multiDiffEntry{flex-direction:column;flex:1;display:flex;overflow:hidden}.monaco-component.multiDiffEditor .multiDiffEntry .collapse-button{cursor:pointer;margin:0 5px}.monaco-component.multiDiffEditor .multiDiffEntry .collapse-button a{display:block}.monaco-component.multiDiffEditor .multiDiffEntry .header{z-index:1000;background:var(--vscode-editor-background)}.monaco-component.multiDiffEditor .multiDiffEntry .header:not(.collapsed) .header-content{border-bottom:1px solid var(--vscode-sideBarSectionHeader-border)}.monaco-component.multiDiffEditor .multiDiffEntry .header .header-content{border-top:1px solid var(--vscode-multiDiffEditor-border);color:var(--vscode-foreground);background:var(--vscode-multiDiffEditor-headerBackground);align-items:center;margin:8px 0 0;padding:4px 5px;display:flex}.monaco-component.multiDiffEditor .multiDiffEntry .header .header-content.shadow{box-shadow:var(--vscode-scrollbar-shadow) 0px 6px 6px -6px}.monaco-component.multiDiffEditor .multiDiffEntry .header .header-content .file-path{flex:1;min-width:0;display:flex}.monaco-component.multiDiffEditor .multiDiffEntry .header .header-content .file-path .title{font-size:14px;line-height:22px}.monaco-component.multiDiffEditor .multiDiffEntry .header .header-content .file-path .title.original{text-overflow:ellipsis;flex:1;min-width:0}.monaco-component.multiDiffEditor .multiDiffEntry .header .header-content .file-path .status{opacity:.75;margin:0 10px;font-weight:600;line-height:22px}.monaco-component.multiDiffEditor .multiDiffEntry .header .header-content .actions{padding:0 8px}.monaco-component.multiDiffEditor .multiDiffEntry .editorParent{border-bottom:1px solid var(--vscode-multiDiffEditor-border);flex-direction:column;flex:1;display:flex;overflow:hidden}.monaco-component.multiDiffEditor .multiDiffEntry .editorContainer{flex:1}
|
|
3
|
-
.xterm{cursor:text;-webkit-user-select:none;user-select:none;position:relative}.xterm.focus,.xterm:focus{outline:none}.xterm .xterm-helpers{z-index:5;position:absolute;top:0}.xterm .xterm-helper-textarea{opacity:0;z-index:-5;white-space:nowrap;resize:none;border:0;width:0;height:0;margin:0;padding:0;position:absolute;top:0;left:-9999em;overflow:hidden}.xterm .composition-view{color:#fff;white-space:nowrap;z-index:1;background:#000;display:none;position:absolute}.xterm .composition-view.active{display:block}.xterm .xterm-viewport{cursor:default;background-color:#000;position:absolute;inset:0;overflow-y:scroll}.xterm .xterm-screen{position:relative}.xterm .xterm-screen canvas{position:absolute;top:0;left:0}.xterm-char-measure-element{visibility:hidden;line-height:normal;display:inline-block;position:absolute;top:0;left:-9999em}.xterm.enable-mouse-events{cursor:default}.xterm.xterm-cursor-pointer,.xterm .xterm-cursor-pointer{cursor:pointer}.xterm.column-select.focus{cursor:crosshair}.xterm .xterm-accessibility:not(.debug),.xterm .xterm-message{z-index:10;color:#0000;pointer-events:none;position:absolute;inset:0}.xterm .xterm-accessibility-tree:not(.debug) ::selection{color:#0000}.xterm .xterm-accessibility-tree{-webkit-user-select:text;user-select:text;white-space:pre;font-family:monospace}.xterm .xterm-accessibility-tree>div{transform-origin:0;width:fit-content}.xterm .live-region{width:1px;height:1px;position:absolute;left:-9999px;overflow:hidden}.xterm-dim{opacity:1!important}.xterm-underline-1{text-decoration:underline}.xterm-underline-2{-webkit-text-decoration:underline double;text-decoration:underline double}.xterm-underline-3{-webkit-text-decoration:underline wavy;text-decoration:underline wavy}.xterm-underline-4{-webkit-text-decoration:underline dotted;text-decoration:underline dotted}.xterm-underline-5{-webkit-text-decoration:underline dashed;text-decoration:underline dashed}.xterm-overline{text-decoration:overline}.xterm-overline.xterm-underline-1{text-decoration:underline overline}.xterm-overline.xterm-underline-2{-webkit-text-decoration:overline double underline;text-decoration:overline double underline}.xterm-overline.xterm-underline-3{-webkit-text-decoration:overline wavy underline;text-decoration:overline wavy underline}.xterm-overline.xterm-underline-4{-webkit-text-decoration:overline dotted underline;text-decoration:overline dotted underline}.xterm-overline.xterm-underline-5{-webkit-text-decoration:overline dashed underline;text-decoration:overline dashed underline}.xterm-strikethrough{text-decoration:line-through}.xterm-screen .xterm-decoration-container .xterm-decoration{z-index:6;position:absolute}.xterm-screen .xterm-decoration-container .xterm-decoration.xterm-decoration-top-layer{z-index:7}.xterm-decoration-overview-ruler{z-index:8;pointer-events:none;position:absolute;top:0;right:0}.xterm-decoration-top{z-index:2;position:relative}.xterm .xterm-scrollable-element>.scrollbar{cursor:default}.xterm .xterm-scrollable-element>.scrollbar>.scra{cursor:pointer;font-size:11px!important}.xterm .xterm-scrollable-element>.visible{opacity:1;z-index:11;background:0 0;transition:opacity .1s linear}.xterm .xterm-scrollable-element>.invisible{opacity:0;pointer-events:none}.xterm .xterm-scrollable-element>.invisible.fade{transition:opacity .8s linear}.xterm .xterm-scrollable-element>.shadow{display:none;position:absolute}.xterm .xterm-scrollable-element>.shadow.top{width:100%;height:3px;box-shadow:var(--vscode-scrollbar-shadow,#000) 0 6px 6px -6px inset;display:block;top:0;left:3px}.xterm .xterm-scrollable-element>.shadow.left{width:3px;height:100%;box-shadow:var(--vscode-scrollbar-shadow,#000) 6px 0 6px -6px inset;display:block;top:3px;left:0}.xterm .xterm-scrollable-element>.shadow.top-left-corner{width:3px;height:3px;display:block;top:0;left:0}.xterm .xterm-scrollable-element>.shadow.top.left{box-shadow:var(--vscode-scrollbar-shadow,#000) 6px 0 6px -6px inset}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,940361,e=>{"use strict";var t=e.i(344180);e.s([],2365),e.i(2365);var i=e.i(764556),r=e.i(394822),n=e.i(174465),l=e.i(648224),s=e.i(35359);e.i(8890);var o=e.i(422561),a=e.i(526850),d=e.i(232449),c=e.i(410421),u=e.i(150129),p=e.i(969490),f=e.i(602453),m=e.i(817955),_=e.i(742665),g=e.i(87709);let y=i.forwardRef(function(e,t){let{render:r,className:l,style:y,...h}=e,{setAnchor:x,actionsRef:v,internalBackdropRef:j,backdropRef:b,positionerRef:k,allowMouseUpTriggerRef:C,initialCursorPointRef:w,rootId:M}=(0,n.useContextMenuRootContext)(!1),{store:N}=(0,s.useMenuRootContext)(!1),I=N.useState("open"),P=N.useState("disabled"),S=i.useRef(null),z=i.useRef(null),O=(0,d.useTimeout)(),D=(0,d.useTimeout)(),R=i.useRef(!1);function T(e,t,i){let r=i.type.startsWith("touch");w.current={x:e,y:t},x({getBoundingClientRect:()=>DOMRect.fromRect({width:10*!!r,height:10*!!r,x:e,y:t})}),R.current=!1,v.current?.setOpen(!0,(0,f.createChangeEventDetails)(_.REASONS.triggerPress,i)),D.start(500,()=>{R.current=!0})}function E(){O.clear(),z.current=null}return i.useEffect(()=>{let e=(0,a.ownerDocument)(S.current);return(0,o.addEventListener)(e,"contextmenu",function(e){if(P)return;let t=(0,c.getTarget)(e);((0,c.contains)(S.current,t)||(0,c.contains)(j.current,t)||(0,c.contains)(b.current,t))&&e.preventDefault()})},[b,P,j]),(0,p.useRenderElement)("div",e,{state:{open:I},ref:[S,t],props:[{onContextMenu:function(e){if(P)return;C.current=!0,(0,u.stopEvent)(e),T(e.clientX,e.clientY,e.nativeEvent);let t=(0,a.ownerDocument)(S.current);(0,o.addEventListener)(t,"mouseup",e=>{if(C.current=!1,!R.current)return;D.clear(),R.current=!1;let t=(0,c.getTarget)(e);(0,c.contains)(k.current,t)||M&&t&&(0,g.findRootOwnerId)(t)===M||v.current?.setOpen(!1,(0,f.createChangeEventDetails)(_.REASONS.cancelOpen,e))},{once:!0})},onTouchStart:function(e){if(!P&&(C.current=!1,1===e.touches.length)){e.stopPropagation();let t=e.touches[0];z.current={x:t.clientX,y:t.clientY},O.start(500,()=>{z.current&&T(z.current.x,z.current.y,e.nativeEvent)})}},onTouchMove:function(e){if(O.isStarted()&&z.current&&1===e.touches.length){let t=e.touches[0],i=Math.abs(t.clientX-z.current.x),r=Math.abs(t.clientY-z.current.y);(i>10||r>10)&&O.clear()}},onTouchEnd:E,onTouchCancel:E,style:{WebkitTouchCallout:"none"}},h],stateAttributesMapping:m.pressableTriggerOpenStateMapping})});var h=e.i(487455),x=e.i(293209),v=e.i(503662),j=e.i(33427),b=e.i(324573),k=e.i(582883),C=e.i(277658),w=e.i(349204),M=e.i(28051),N=e.i(597375),I=e.i(81752),P=e.i(59354),S=e.i(300637),z=e.i(281478),O=e.i(65255),D=e.i(327794),R=e.i(362962);e.s(["Arrow",()=>b.MenuArrow,"Backdrop",()=>h.MenuBackdrop,"CheckboxItem",()=>M.MenuCheckboxItem,"CheckboxItemIndicator",()=>N.MenuCheckboxItemIndicator,"Group",()=>k.MenuGroup,"GroupLabel",()=>C.MenuGroupLabel,"Item",()=>w.MenuItem,"LinkItem",()=>I.MenuLinkItem,"Popup",()=>j.MenuPopup,"Portal",()=>x.MenuPortal,"Positioner",()=>v.MenuPositioner,"RadioGroup",()=>P.MenuRadioGroup,"RadioItem",()=>S.MenuRadioItem,"RadioItemIndicator",()=>z.MenuRadioItemIndicator,"Root",0,function(e){let[o,a]=i.useState({getBoundingClientRect:()=>DOMRect.fromRect({width:0,height:0,x:0,y:0})}),d=i.useRef(null),c=i.useRef(null),u=i.useRef(null),p=i.useRef(null),f=i.useRef(!0),m=i.useRef(null),_=(0,r.useId)(),g=i.useMemo(()=>({anchor:o,setAnchor:a,actionsRef:u,backdropRef:d,internalBackdropRef:c,positionerRef:p,allowMouseUpTriggerRef:f,initialCursorPointRef:m,rootId:_}),[o,_]);return(0,t.jsx)(n.ContextMenuRootContext.Provider,{value:g,children:(0,t.jsx)(s.MenuRootContext.Provider,{value:void 0,children:(0,t.jsx)(l.Menu.Root,{...e})})})},"Separator",()=>R.Separator,"SubmenuRoot",()=>O.MenuSubmenuRoot,"SubmenuTrigger",()=>D.MenuSubmenuTrigger,"Trigger",0,y],912001);var T=e.i(912001),T=T,E=e.i(465458),F=e.i(932031);function $({className:e,align:i="start",alignOffset:r=4,side:n="right",sideOffset:l=0,...s}){return(0,t.jsx)(T.Portal,{children:(0,t.jsx)(T.Positioner,{className:"isolate z-50 outline-none",align:i,alignOffset:r,side:n,sideOffset:l,children:(0,t.jsx)(T.Popup,{"data-slot":"context-menu-content",className:(0,E.cn)("z-50 max-h-(--available-height) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...s})})})}e.i(299648),e.s(["ContextMenu",0,function({...e}){return(0,t.jsx)(T.Root,{"data-slot":"context-menu",...e})},"ContextMenuContent",0,$,"ContextMenuItem",0,function({className:e,inset:i,variant:r="default",...n}){return(0,t.jsx)(T.Item,{"data-slot":"context-menu-item","data-inset":i,"data-variant":r,className:(0,E.cn)("group/context-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-inset:pl-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 focus:*:[svg]:text-accent-foreground data-[variant=destructive]:*:[svg]:text-destructive",e),...n})},"ContextMenuSeparator",0,function({className:e,...i}){return(0,t.jsx)(T.Separator,{"data-slot":"context-menu-separator",className:(0,E.cn)("-mx-1 my-1 h-px bg-border",e),...i})},"ContextMenuSub",0,function({...e}){return(0,t.jsx)(T.SubmenuRoot,{"data-slot":"context-menu-sub",...e})},"ContextMenuSubContent",0,function({...e}){return(0,t.jsx)($,{"data-slot":"context-menu-sub-content",className:"shadow-lg",side:"right",...e})},"ContextMenuSubTrigger",0,function({className:e,inset:i,children:r,...n}){return(0,t.jsxs)(T.SubmenuTrigger,{"data-slot":"context-menu-sub-trigger","data-inset":i,className:(0,E.cn)("flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-inset:pl-7 data-open:bg-accent data-open:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...n,children:[r,(0,t.jsx)(F.ChevronRightIcon,{className:"ml-auto"})]})},"ContextMenuTrigger",0,function({className:e,...i}){return(0,t.jsx)(T.Trigger,{"data-slot":"context-menu-trigger",className:(0,E.cn)("select-none",e),...i})}],940361)},486657,e=>{"use strict";let t=(0,e.i(433721).default)("triangle-alert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);e.s(["AlertTriangle",0,t],486657)},450158,e=>{"use strict";let t=(0,e.i(433721).default)("minus",[["path",{d:"M5 12h14",key:"1ays0h"}]]);e.s(["Minus",0,t],450158)},810051,e=>{"use strict";let t=(0,e.i(433721).default)("pen",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]]);e.s(["Edit2",0,t],810051)},579820,e=>{"use strict";let t=(0,e.i(433721).default)("layers",[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]]);e.s(["Layers",0,t],579820)},889445,e=>{"use strict";let t=(0,e.i(433721).default)("play",[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]]);e.s(["Play",0,t],889445)},346038,237597,e=>{"use strict";var t=e.i(433721);let i=(0,t.default)("keyboard",[["path",{d:"M10 8h.01",key:"1r9ogq"}],["path",{d:"M12 12h.01",key:"1mp3jc"}],["path",{d:"M14 8h.01",key:"1primd"}],["path",{d:"M16 12h.01",key:"1l6xoz"}],["path",{d:"M18 8h.01",key:"emo2bl"}],["path",{d:"M6 8h.01",key:"x9i8wu"}],["path",{d:"M7 16h10",key:"wp8him"}],["path",{d:"M8 12h.01",key:"czm47f"}],["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}]]);e.s(["Keyboard",0,i],346038);let r=(0,t.default)("pen-line",[["path",{d:"M13 21h8",key:"1jsn5i"}],["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]]);e.s(["Edit3",0,r],237597)},444204,e=>{"use strict";let t=(0,e.i(433721).default)("clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6l4 2",key:"mmk7yg"}]]);e.s(["Clock",0,t],444204)},583705,e=>{"use strict";let t=(0,e.i(433721).default)("info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);e.s(["Info",0,t],583705)},735207,e=>{"use strict";let t=(0,e.i(433721).default)("book-open",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]]);e.s(["default",0,t])},588785,e=>{"use strict";let t=(0,e.i(433721).default)("maximize-2",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"m21 3-7 7",key:"1l2asr"}],["path",{d:"m3 21 7-7",key:"tjx5ai"}],["path",{d:"M9 21H3v-6",key:"wtvkvv"}]]);e.s(["Maximize2",0,t],588785)},751962,687204,791298,231352,833237,e=>{"use strict";var t=e.i(344180),i=e.i(932031),r=e.i(984178),n=e.i(383171),l=e.i(415955),s=e.i(137340),o=e.i(307858),a=e.i(129981),d=e.i(159619),c=e.i(198699),u=e.i(433721);let p=(0,u.default)("file-plus",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M9 15h6",key:"cctwl0"}],["path",{d:"M12 18v-6",key:"17g6i2"}]]);e.s(["FilePlus",0,p],687204);var f=e.i(486657),m=e.i(962562);let _=(0,u.default)("move-right",[["path",{d:"M18 8L22 12L18 16",key:"1r0oui"}],["path",{d:"M2 12H22",key:"1m8cig"}]]);var g=e.i(764556),y=e.i(256186),h=e.i(940361),x=e.i(209988),v=e.i(260218),j=e.i(465458),b=e.i(193251);let k=(0,u.default)("link",[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]]);e.s(["Link",0,k],791298);var C=e.i(244073);function w({filePath:e,workspaceId:i,boundDir:r,onRename:n,onMove:l,onCopyItem:a,onDelete:c}){let u=(0,C.useTranslations)("editor");return(0,t.jsxs)(h.ContextMenuContent,{children:[n&&(0,t.jsxs)(h.ContextMenuItem,{onClick:n,children:[(0,t.jsx)(m.Pencil,{className:"size-4"}),u("rename")]}),l&&(0,t.jsxs)(h.ContextMenuItem,{onClick:l,children:[(0,t.jsx)(_,{className:"size-4"}),u("move")]}),a&&(0,t.jsxs)(h.ContextMenuItem,{onClick:a,children:[(0,t.jsx)(d.Copy,{className:"size-4"}),u("copyFile")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>{let t=r?r.replace(/\/+$/,"")+"/"+e:e;navigator.clipboard.writeText(t)},children:[(0,t.jsx)(d.Copy,{className:"size-4"}),u("copyPath")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>{fetch(`/api/workspaces/${i}/files/reveal?path=${encodeURIComponent(e)}`,{method:"POST"})},children:[(0,t.jsx)(o.ExternalLink,{className:"size-4"}),u("revealInFinder")]}),c&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(h.ContextMenuSeparator,{}),(0,t.jsxs)(h.ContextMenuItem,{onClick:c,className:"text-destructive focus:text-destructive",children:[(0,t.jsx)(s.Trash2,{className:"size-4"}),u("deleteFileTitle")]})]}),(0,t.jsx)(h.ContextMenuSeparator,{}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>{let t=`/api/workspaces/${i}/files/download?path=${encodeURIComponent(e)}`,r=document.createElement("a");r.href=t,r.download="",document.body.appendChild(r),r.click(),document.body.removeChild(r)},children:[(0,t.jsx)(b.Download,{className:"size-4"}),u("download")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>{let t=`${window.location.origin}/api/workspaces/${i}/files/download?path=${encodeURIComponent(e)}`;navigator.clipboard.writeText(t)},children:[(0,t.jsx)(k,{className:"size-4"}),u("copyDownloadUrl")]})]})}e.s(["FileContextMenu",0,w],231352);var M=e.i(359209);let N=(0,g.createContext)({expandedPaths:new Set,togglePath:()=>void 0}),I=(0,g.createContext)({path:"",name:"",isExpanded:!1,ignored:!1}),P=({path:e,name:r,folderIcon:u,ignored:f,className:b,children:k,...w})=>{let{expandedPaths:M,togglePath:P,selectedPath:S,onFileSelect:z,workspaceId:R,onDelete:T,onImport:E,onCopyPath:F,onCreateFile:$,onCreateFolder:L,onRename:A,onMove:B,onCopyItem:U,onLoadDirectory:q,loadingDirs:G,boundDir:W}=(0,g.useContext)(N),H=(0,g.useContext)(I),V=M.has(e),X=f||H.ignored,K=S===e,J=!!G?.has(e),Y=(0,C.useTranslations)("editor"),Q=(0,C.useTranslations)("common"),[Z,ee]=(0,g.useState)(!1),et=()=>{fetch(`/api/workspaces/${R}/files/reveal?path=${encodeURIComponent(e)}`,{method:"POST"})};return(0,t.jsxs)(I.Provider,{value:{path:e,name:r,isExpanded:V,ignored:X},children:[(0,t.jsxs)(h.ContextMenu,{children:[(0,t.jsx)(y.Collapsible,{onOpenChange:()=>{let t=!V;P(e),t&&q&&q(e)},open:V,children:(0,t.jsxs)("div",{className:b,role:"treeitem","aria-selected":!1,tabIndex:0,...w,children:[(0,t.jsx)(h.ContextMenuTrigger,{className:"contents",children:(0,t.jsxs)("div",{className:"group/folder relative",children:[(0,t.jsxs)(y.CollapsibleTrigger,{className:(0,j.cn)("flex w-full items-center gap-1 rounded px-2 py-1 pr-16 text-left transition-colors hover:bg-muted/50",K&&"bg-muted",X&&"opacity-50"),children:[(0,t.jsx)(i.ChevronRightIcon,{className:(0,j.cn)("size-4 shrink-0 text-muted-foreground transition-transform",V&&"rotate-90")}),(0,t.jsx)(O,{children:u?u(V):V?(0,t.jsx)(l.FolderOpenIcon,{className:"size-4 text-blue-500"}):(0,t.jsx)(n.FolderIcon,{className:"size-4 text-blue-500"})}),(0,t.jsx)(D,{children:r}),J&&(0,t.jsx)("span",{className:"size-3 border border-muted-foreground border-t-transparent rounded-full animate-spin shrink-0"})]}),(0,t.jsxs)("div",{className:"absolute right-1 top-1/2 -translate-y-1/2 flex items-center gap-1 invisible group-hover/folder:visible",onClick:e=>e.stopPropagation(),children:[(0,t.jsx)("button",{onClick:et,className:"p-0.5 rounded hover:bg-accent cursor-pointer",title:Y("revealInFinder"),children:(0,t.jsx)(o.ExternalLink,{className:"size-3 text-muted-foreground"})}),(0,t.jsx)("button",{onClick:()=>ee(!0),className:"p-0.5 rounded hover:bg-accent cursor-pointer",title:Q("delete"),children:(0,t.jsx)(s.Trash2,{className:"size-3 text-muted-foreground hover:text-destructive"})})]})]})}),(0,t.jsx)(y.CollapsibleContent,{children:(0,t.jsx)("div",{className:"ml-4 border-l pl-2",children:J?(0,t.jsxs)("div",{className:"flex items-center gap-2 px-2 py-1.5 text-xs text-muted-foreground",children:[(0,t.jsx)("span",{className:"size-3 border border-muted-foreground border-t-transparent rounded-full animate-spin shrink-0"}),(0,t.jsx)("span",{children:Y("loading")})]}):k})})]})}),(0,t.jsxs)(h.ContextMenuContent,{children:[(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>A?.(e),children:[(0,t.jsx)(m.Pencil,{className:"size-4"}),Y("rename")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>B?.(e),children:[(0,t.jsx)(_,{className:"size-4"}),Y("move")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>U?.(e),children:[(0,t.jsx)(d.Copy,{className:"size-4"}),Y("copyFile")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>E?.(e),children:[(0,t.jsx)(a.Upload,{className:"size-4"}),Y("importFile")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>{let t=W?W.replace(/\/+$/,"")+"/"+e:e;navigator.clipboard.writeText(t)},children:[(0,t.jsx)(d.Copy,{className:"size-4"}),Y("copyPath")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>$?.(e),children:[(0,t.jsx)(p,{className:"size-4"}),Y("newFile")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>L?.(e),children:[(0,t.jsx)(c.FolderPlus,{className:"size-4"}),Y("newFolder")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:et,children:[(0,t.jsx)(o.ExternalLink,{className:"size-4"}),Y("revealInFinder")]}),(0,t.jsxs)(h.ContextMenuItem,{onClick:()=>ee(!0),className:"text-destructive focus:text-destructive",children:[(0,t.jsx)(s.Trash2,{className:"size-4"}),Q("delete")]})]})]}),(0,t.jsx)(x.Dialog,{open:Z,onOpenChange:ee,children:(0,t.jsxs)(x.DialogContent,{className:"sm:max-w-[400px]",children:[(0,t.jsx)(x.DialogHeader,{children:(0,t.jsxs)(x.DialogTitle,{className:"flex items-center gap-2",children:[(0,t.jsx)(s.Trash2,{className:"size-5 text-destructive"}),Y("deleteFolderTitle")]})}),(0,t.jsx)(x.DialogDescription,{children:Y("deleteFolderDesc",{name:r})}),(0,t.jsxs)(x.DialogFooter,{children:[(0,t.jsx)(v.Button,{variant:"outline",onClick:()=>ee(!1),children:Q("cancel")}),(0,t.jsx)(v.Button,{variant:"destructive",onClick:()=>{ee(!1),T?.(e)},children:Q("delete")})]})]})})]})},S=(0,g.createContext)({path:"",name:""}),z=({path:e,name:i,icon:n,ignored:l,className:a,children:d,...c})=>{let{selectedPath:u,onFileSelect:p,workspaceId:m,onDelete:_,onRename:y,onMove:b,onCopyItem:k,fileSizeMap:M,boundDir:P}=(0,g.useContext)(N),z=(0,g.useContext)(I),T=l||z.ignored,E=u===e,F=(0,C.useTranslations)("editor"),$=(0,C.useTranslations)("common"),[L,A]=(0,g.useState)(!1),[B,U]=(0,g.useState)(!1),q=(0,g.useRef)(null);(0,g.useEffect)(()=>{E&&q.current&&q.current.scrollIntoView({block:"nearest",inline:"nearest"})},[E]);let G=M?.[e],W=null!=G&&G>1048576,H=(0,g.useCallback)(()=>{W?A(!0):p?.(e)},[W,p,e]),V=(0,g.useCallback)(()=>{A(!1),p?.(e)},[p,e]);return(0,t.jsxs)(S.Provider,{value:{path:e,name:i},children:[(0,t.jsxs)(h.ContextMenu,{children:[(0,t.jsx)(h.ContextMenuTrigger,{className:"contents",children:(0,t.jsx)("div",{ref:q,className:(0,j.cn)("group/file flex cursor-pointer items-center gap-1 rounded px-2 py-1 transition-colors hover:bg-muted/50",E&&"bg-muted",T&&"opacity-50",a),onClick:H,onKeyDown:e=>{("Enter"===e.key||" "===e.key)&&H()},role:"treeitem","aria-selected":!1,tabIndex:0,...c,children:d??(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("span",{className:"size-4"}),(0,t.jsx)(O,{children:n??(0,t.jsx)(r.FileIcon,{className:"size-4 text-muted-foreground"})}),(0,t.jsx)(D,{children:i}),(0,t.jsxs)(R,{children:[(0,t.jsx)("button",{onClick:()=>{fetch(`/api/workspaces/${m}/files/reveal?path=${encodeURIComponent(e)}`,{method:"POST"})},className:"p-0.5 rounded hover:bg-accent cursor-pointer",title:F("revealInFinder"),children:(0,t.jsx)(o.ExternalLink,{className:"size-3 text-muted-foreground"})}),(0,t.jsx)("button",{onClick:()=>U(!0),className:"p-0.5 rounded hover:bg-accent cursor-pointer",title:$("delete"),children:(0,t.jsx)(s.Trash2,{className:"size-3 text-muted-foreground hover:text-destructive"})})]})]})})}),(0,t.jsx)(w,{filePath:e,workspaceId:m,boundDir:P,onRename:()=>y?.(e),onMove:()=>b?.(e),onCopyItem:()=>k?.(e),onDelete:()=>U(!0)})]}),(0,t.jsx)(x.Dialog,{open:L,onOpenChange:A,children:(0,t.jsxs)(x.DialogContent,{className:"sm:max-w-[400px]",children:[(0,t.jsx)(x.DialogHeader,{children:(0,t.jsxs)(x.DialogTitle,{className:"flex items-center gap-2",children:[(0,t.jsx)(f.AlertTriangle,{className:"size-5 text-yellow-500"}),F("fileTooLargeTitle")]})}),(0,t.jsx)(x.DialogDescription,{className:"break-all",children:F("fileTooLargeDesc",{name:i,size:G<1024?`${G} B`:G<1048576?`${(G/1024).toFixed(1)} KB`:`${(G/1048576).toFixed(1)} MB`})}),(0,t.jsxs)(x.DialogFooter,{children:[(0,t.jsx)(v.Button,{variant:"outline",onClick:()=>A(!1),children:$("cancel")}),(0,t.jsx)(v.Button,{onClick:V,children:F("openAnyway")})]})]})}),(0,t.jsx)(x.Dialog,{open:B,onOpenChange:U,children:(0,t.jsxs)(x.DialogContent,{className:"sm:max-w-[400px]",children:[(0,t.jsx)(x.DialogHeader,{children:(0,t.jsxs)(x.DialogTitle,{className:"flex items-center gap-2",children:[(0,t.jsx)(s.Trash2,{className:"size-5 text-destructive"}),F("deleteFileTitle")]})}),(0,t.jsx)(x.DialogDescription,{children:F("deleteFileDesc",{name:i})}),(0,t.jsxs)(x.DialogFooter,{children:[(0,t.jsx)(v.Button,{variant:"outline",onClick:()=>U(!1),children:$("cancel")}),(0,t.jsx)(v.Button,{variant:"destructive",onClick:()=>{U(!1),_?.(e)},children:$("delete")})]})]})})]})},O=({className:e,children:i,...r})=>(0,t.jsx)("span",{className:(0,j.cn)("shrink-0",e),...r,children:i}),D=({className:e,children:i,...r})=>(0,t.jsx)("span",{className:(0,j.cn)("truncate flex-1 min-w-0",e),...r,children:i}),R=({className:e,children:i,...r})=>(0,t.jsx)("div",{className:(0,j.cn)("ml-auto flex items-center gap-1 shrink-0 invisible group-hover/file:visible",e),onClick:e=>e.stopPropagation(),onKeyDown:e=>e.stopPropagation(),role:"group",...r,children:i});function T({nodes:e,getNodeId:i,getChildren:r,renderNode:n,activeId:l,expandedIds:s,draggedOverId:o,level:a=0,indent:d=12,onDragStart:c,onDragOver:u,onDragLeave:p,onDrop:f,onDragEnd:m,shouldRenderChildren:_}){return e.map(e=>{let y=i(e),h=r(e),x={level:a,hasChildren:h.length>0,isExpanded:!s||!!s[y],isActive:l===y,isDraggedOver:o===y},v={draggable:!!c,style:{paddingLeft:`${Math.max(4,a*d)}px`},onDragStart:c?e=>{e.stopPropagation(),c(e,y)}:void 0,onDragOver:u?e=>{e.stopPropagation(),u(e,y)}:void 0,onDragLeave:p,onDrop:f?e=>{e.stopPropagation(),f(e,y)}:void 0,onDragEnd:m?e=>{e.stopPropagation(),m(e)}:void 0},j=x.hasChildren&&(_?.(e,x)??!0);return(0,t.jsx)(g.Fragment,{children:n({node:e,state:x,rowProps:v,children:j?(0,t.jsx)(T,{nodes:h,getNodeId:i,getChildren:r,renderNode:n,activeId:l,expandedIds:s,draggedOverId:o,level:a+1,indent:d,onDragStart:c,onDragOver:u,onDragLeave:p,onDrop:f,onDragEnd:m,shouldRenderChildren:_}):null})},y)})}e.s(["FileTree",0,({expanded:e,defaultExpanded:i=new Set,selectedPath:r,onFileSelect:n,onExpandedChange:l,workspaceId:s,onDelete:o,onImport:a,onCopyPath:d,onCreateFile:c,onCreateFolder:u,onRename:p,onMove:f,onCopyItem:m,onLoadDirectory:_,loadingDirs:y,boundDir:h,fileSizeMap:x,refreshInterval:v,ignoredPaths:b,draggedOverPath:k,onItemDragStart:C,onItemDragOver:w,onItemDragLeave:M,onItemDrop:I,onItemDragEnd:P,rootDropTargetId:S,onRootDropLineDragOver:z,onRootDropLineDragEnter:O,onRootDropLineDragLeave:D,onRootDropLineDrop:R,className:T,children:E,...F})=>{let[$,L]=(0,g.useState)(i),A=e??$;return(0,g.useEffect)(()=>{if(!v||!_||0===A.size)return;let e=setInterval(()=>{A.forEach(e=>_(e))},v);return()=>clearInterval(e)},[v,_,A]),(0,t.jsx)(N.Provider,{value:{expandedPaths:A,togglePath:e=>{let t=new Set(A);t.has(e)?t.delete(e):t.add(e),L(t),l?.(t)},selectedPath:r,onFileSelect:n,workspaceId:s,onDelete:o,onImport:a,onCopyPath:d,onCreateFile:c,onCreateFolder:u,onRename:p,onMove:f,onCopyItem:m,onLoadDirectory:_,loadingDirs:y,boundDir:h,fileSizeMap:x,ignoredPaths:b,draggedOverPath:k,onItemDragStart:C,onItemDragOver:w,onItemDragLeave:M,onItemDrop:I,onItemDragEnd:P,rootDropTargetId:S,onRootDropLineDragOver:z,onRootDropLineDragEnter:O,onRootDropLineDragLeave:D,onRootDropLineDrop:R},children:(0,t.jsx)("div",{className:(0,j.cn)("flex flex-col bg-background font-mono text-sm h-full",T),role:"tree",...F,children:(0,t.jsx)("div",{className:"p-2 flex-1 min-h-0 overflow-y-auto overflow-x-auto",children:E})})})},"FileTreeNodes",0,function({nodes:e}){let{draggedOverPath:i,onItemDragStart:r,onItemDragOver:n,onItemDragLeave:l,onItemDrop:s,onItemDragEnd:o,rootDropTargetId:a,onRootDropLineDragOver:d,onRootDropLineDragEnter:c,onRootDropLineDragLeave:u,onRootDropLineDrop:p}=(0,g.useContext)(N);return(0,t.jsx)(T,{nodes:e,getNodeId:e=>e.path,getChildren:e=>"directory"===e.type?e.children??[]:[],draggedOverId:i,onDragStart:r,onDragOver:n,onDragLeave:l,onDrop:s,onDragEnd:o,renderNode:({node:e,state:r,rowProps:n,children:l})=>{let s=a?`${a}:${e.path}`:void 0,o=0===r.level&&"directory"===e.type&&p?(0,t.jsx)("div",{className:"flex h-1.5 items-center px-2",draggable:!1,onDragEnterCapture:s?e=>c?.(e,s):void 0,onDragOverCapture:s?e=>d?.(e,s):void 0,onDragLeaveCapture:s?e=>u?.(e,s):void 0,onDropCapture:s?e=>p(e,s):void 0,onDragEnter:s?e=>c?.(e,s):void 0,onDragOver:s?e=>d?.(e,s):void 0,onDragLeave:s?e=>u?.(e,s):void 0,onDrop:s?e=>p(e,s):void 0,children:(0,t.jsx)("div",{className:(0,j.cn)("h-px flex-1 rounded-full bg-primary opacity-0 transition-opacity",s&&i===s&&"opacity-100")})}):null;return"directory"===e.type?(0,t.jsxs)(t.Fragment,{children:[o,(0,t.jsx)(P,{...n,style:void 0,path:e.path,name:e.name,ignored:e.ignored,className:(0,j.cn)(r.isDraggedOver&&"rounded border border-dashed border-primary/40 bg-primary/5",n.className),folderIcon:i=>(0,t.jsx)(M.FolderIconImg,{name:e.name,isOpen:i}),children:l},e.path)]}):(0,t.jsx)(z,{...n,style:void 0,path:e.path,name:e.name,icon:(0,t.jsx)(M.FileIconImg,{name:e.name}),ignored:e.ignored,className:(0,j.cn)(r.isDraggedOver&&"border border-dashed border-primary/40 bg-primary/5",n.className)},e.path)}})},"NestedTree",0,T],751962);var E=e.i(681622),F=e.i(812057),$=e.i(434805),L=e.i(460578),A=e.i(62669),B=e.i(882469);let U=(0,u.default)("folder-input",[["path",{d:"M2 9V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2v-1",key:"fm4g5t"}],["path",{d:"M2 13h10",key:"pgb2dq"}],["path",{d:"m9 16 3-3-3-3",key:"6m91ic"}]]);var q=e.i(437122),G=e.i(360112);e.s(["ImportFileDialog",0,function({open:e,onOpenChange:i,workspaceId:r,targetPath:n,onImported:l,accept:s,onUploadFiles:o}){let d=(0,C.useTranslations)("editor"),[c,u]=(0,g.useState)(!1),[p,f]=(0,g.useState)(""),[m,_]=(0,g.useState)(""),[y,h]=(0,g.useState)([]),j=(0,g.useCallback)(()=>{f(""),_(""),h([]),u(!1)},[]),b=(0,g.useCallback)(e=>{e||j(),i(e)},[i,j]),k=async()=>{if(p.trim()){u(!0);try{(await (0,q.fetchWithAuth)(`/api/workspaces/${r}/files/import-url`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({url:p.trim(),targetDir:n})})).ok?(G.toast.success(d("importSuccess")),l(),b(!1)):G.toast.error(d("importFailed"))}catch{G.toast.error(d("importFailed"))}finally{u(!1)}}},w=async()=>{if(m.trim()){u(!0);try{(await (0,q.fetchWithAuth)(`/api/workspaces/${r}/files/import-path`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({absPath:m.trim(),targetDir:n})})).ok?(G.toast.success(d("importSuccess")),l(),b(!1)):G.toast.error(d("importFailed"))}catch{G.toast.error(d("importFailed"))}finally{u(!1)}}},M=async()=>{if(0!==y.length){u(!0);try{if(o)await o(y.map(e=>e.file)),G.toast.success(d("importSuccess")),l(),b(!1);else{let e=await Promise.all(y.map(async e=>{var t;return{name:e.file.name,content:await (t=e.file,new Promise((e,i)=>{let r=new FileReader;r.onload=()=>{let t=r.result;e(t.split(",")[1]||t)},r.onerror=i,r.readAsDataURL(t)}))}}));(await (0,q.fetchWithAuth)(`/api/workspaces/${r}/files/upload`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({targetDir:n,files:e})})).ok?(G.toast.success(d("importSuccess")),l(),b(!1)):G.toast.error(d("importFailed"))}}catch{G.toast.error(d("importFailed"))}finally{u(!1)}}};return(0,t.jsx)(x.Dialog,{open:e,onOpenChange:b,children:(0,t.jsxs)(x.DialogContent,{className:"sm:max-w-[520px]",children:[(0,t.jsxs)(x.DialogHeader,{children:[(0,t.jsx)(x.DialogTitle,{children:d("importFile")}),(0,t.jsx)(x.DialogDescription,{children:d("importFileDesc")})]}),(0,t.jsxs)(F.Tabs,{defaultValue:"upload",className:"w-full flex flex-col gap-3",children:[(0,t.jsxs)(F.TabsList,{className:"w-full grid grid-cols-3",children:[(0,t.jsxs)(F.TabsTrigger,{value:"upload",className:"gap-1 text-xs",children:[(0,t.jsx)(a.Upload,{className:"size-3"}),d("importUpload")]}),(0,t.jsxs)(F.TabsTrigger,{value:"url",className:"gap-1 text-xs",children:[(0,t.jsx)(B.Globe,{className:"size-3"}),d("importOnline")]}),(0,t.jsxs)(F.TabsTrigger,{value:"internal",className:"gap-1 text-xs",children:[(0,t.jsx)(U,{className:"size-3"}),d("importInternal")]})]}),(0,t.jsxs)(F.TabsContent,{value:"upload",className:"space-y-3 pt-2",children:[(0,t.jsx)(L.FileUpload,{value:y,onChange:h,accept:s}),(0,t.jsx)(v.Button,{className:"w-full",onClick:M,disabled:0===y.length||c,children:c?(0,t.jsx)(A.Loader2,{className:"size-4 animate-spin"}):d("importUpload")})]}),(0,t.jsxs)(F.TabsContent,{value:"url",className:"space-y-3 pt-2",children:[(0,t.jsx)(E.Input,{placeholder:"https://example.com/file.js",value:p,onChange:e=>f(e.target.value),onKeyDown:e=>"Enter"===e.key&&k()}),(0,t.jsx)(v.Button,{className:"w-full",onClick:k,disabled:!p.trim()||c,children:c?(0,t.jsx)(A.Loader2,{className:"size-4 animate-spin"}):d("importOnline")})]}),(0,t.jsxs)(F.TabsContent,{value:"internal",className:"space-y-3 pt-2",children:[(0,t.jsx)($.FolderPicker,{value:m,onChange:_,allowFiles:!0}),(0,t.jsx)(v.Button,{className:"w-full",onClick:w,disabled:!m.trim()||c,children:c?(0,t.jsx)(A.Loader2,{className:"size-4 animate-spin"}):d("importInternal")})]})]})]})})}],833237)},843982,(e,t,i)=>{"use strict";function r({widthInt:e,heightInt:t,blurWidth:i,blurHeight:n,blurDataURL:l,objectFit:s}){let o=i?40*i:e,a=n?40*n:t,d=o&&a?`viewBox='0 0 ${o} ${a}'`:"";return`%3Csvg xmlns='http://www.w3.org/2000/svg' ${d}%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='${d?"none":"contain"===s?"xMidYMid":"cover"===s?"xMidYMid slice":"none"}' style='filter: url(%23b);' href='${l}'/%3E%3C/svg%3E`}Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"getImageBlurSvg",{enumerable:!0,get:function(){return r}})},500680,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0});var r={VALID_LOADERS:function(){return l},imageConfigDefault:function(){return s}};for(var n in r)Object.defineProperty(i,n,{enumerable:!0,get:r[n]});let l=["default","imgix","cloudinary","akamai","custom"],s={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],path:"/_next/image",loader:"default",loaderFile:"",domains:[],disableStaticImages:!1,minimumCacheTTL:14400,formats:["image/webp"],maximumDiskCacheSize:void 0,maximumRedirects:3,maximumResponseBody:5e7,dangerouslyAllowLocalIP:!1,dangerouslyAllowSVG:!1,contentSecurityPolicy:"script-src 'none'; frame-src 'none'; sandbox;",contentDispositionType:"attachment",localPatterns:void 0,remotePatterns:[],qualities:[75],unoptimized:!1,customCacheHandler:!1}},622398,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"getImgProps",{enumerable:!0,get:function(){return d}}),e.r(837121);let r=e.r(745137),n=e.r(843982),l=e.r(500680),s=["-moz-initial","fill","none","scale-down",void 0];function o(e){return void 0!==e.default}function a(e){return void 0===e?e:"number"==typeof e?Number.isFinite(e)?e:NaN:"string"==typeof e&&/^[0-9]+$/.test(e)?parseInt(e,10):NaN}function d({src:e,sizes:t,unoptimized:i=!1,priority:c=!1,preload:u=!1,loading:p,className:f,quality:m,width:_,height:g,fill:y=!1,style:h,overrideSrc:x,onLoad:v,onLoadingComplete:j,placeholder:b="empty",blurDataURL:k,fetchPriority:C,decoding:w="async",layout:M,objectFit:N,objectPosition:I,lazyBoundary:P,lazyRoot:S,...z},O){var D;let R,T,E,{imgConf:F,showAltText:$,blurComplete:L,defaultLoader:A}=O,B=F||l.imageConfigDefault;if("allSizes"in B)R=B;else{let e=[...B.deviceSizes,...B.imageSizes].sort((e,t)=>e-t),t=B.deviceSizes.sort((e,t)=>e-t),i=B.qualities?.sort((e,t)=>e-t);R={...B,allSizes:e,deviceSizes:t,qualities:i}}if(void 0===A)throw Object.defineProperty(Error("images.loaderFile detected but the file is missing default export.\nRead more: https://nextjs.org/docs/messages/invalid-images-config"),"__NEXT_ERROR_CODE",{value:"E163",enumerable:!1,configurable:!0});let U=z.loader||A;delete z.loader,delete z.srcSet;let q="__next_img_default"in U;if(q){if("custom"===R.loader)throw Object.defineProperty(Error(`Image with src "${e}" is missing "loader" prop.
|
|
2
|
+
Read more: https://nextjs.org/docs/messages/next-image-missing-loader`),"__NEXT_ERROR_CODE",{value:"E252",enumerable:!1,configurable:!0})}else{let e=U;U=t=>{let{config:i,...r}=t;return e(r)}}if(M){"fill"===M&&(y=!0);let e={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}}[M];e&&(h={...h,...e});let i={responsive:"100vw",fill:"100vw"}[M];i&&!t&&(t=i)}let G="",W=a(_),H=a(g);if((D=e)&&"object"==typeof D&&(o(D)||void 0!==D.src)){let t=o(e)?e.default:e;if(!t.src)throw Object.defineProperty(Error(`An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received ${JSON.stringify(t)}`),"__NEXT_ERROR_CODE",{value:"E460",enumerable:!1,configurable:!0});if(!t.height||!t.width)throw Object.defineProperty(Error(`An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received ${JSON.stringify(t)}`),"__NEXT_ERROR_CODE",{value:"E48",enumerable:!1,configurable:!0});if(T=t.blurWidth,E=t.blurHeight,k=k||t.blurDataURL,G=t.src,!y)if(W||H){if(W&&!H){let e=W/t.width;H=Math.round(t.height*e)}else if(!W&&H){let e=H/t.height;W=Math.round(t.width*e)}}else W=t.width,H=t.height}let V=!c&&!u&&("lazy"===p||void 0===p);(!(e="string"==typeof e?e:G)||e.startsWith("data:")||e.startsWith("blob:"))&&(i=!0,V=!1),R.unoptimized&&(i=!0),q&&!R.dangerouslyAllowSVG&&e.split("?",1)[0].endsWith(".svg")&&(i=!0);let X=a(m),K=Object.assign(y?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:N,objectPosition:I}:{},$?{}:{color:"transparent"},h),J=L||"empty"===b?null:"blur"===b?`url("data:image/svg+xml;charset=utf-8,${(0,n.getImageBlurSvg)({widthInt:W,heightInt:H,blurWidth:T,blurHeight:E,blurDataURL:k||"",objectFit:K.objectFit})}")`:`url("${b}")`,Y=s.includes(K.objectFit)?"fill"===K.objectFit?"100% 100%":"cover":K.objectFit,Q=J?{backgroundSize:Y,backgroundPosition:K.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:J}:{},Z=function({config:e,src:t,unoptimized:i,width:n,quality:l,sizes:s,loader:o}){if(i){if(t.startsWith("/")&&!t.startsWith("//")){let e=(0,r.getDeploymentId)();if(e){let i=t.indexOf("?");if(-1!==i){let r=new URLSearchParams(t.slice(i+1));r.get("dpl")||(r.append("dpl",e),t=t.slice(0,i)+"?"+r.toString())}else t+=`?dpl=${e}`}}return{src:t,srcSet:void 0,sizes:void 0}}let{widths:a,kind:d}=function({deviceSizes:e,allSizes:t},i,r){if(r){let i=/(^|\s)(1?\d?\d)vw/g,n=[];for(let e;e=i.exec(r);)n.push(parseInt(e[2]));if(n.length){let i=.01*Math.min(...n);return{widths:t.filter(t=>t>=e[0]*i),kind:"w"}}return{widths:t,kind:"w"}}return"number"!=typeof i?{widths:e,kind:"w"}:{widths:[...new Set([i,2*i].map(e=>t.find(t=>t>=e)||t[t.length-1]))],kind:"x"}}(e,n,s),c=a.length-1;return{sizes:s||"w"!==d?s:"100vw",srcSet:a.map((i,r)=>`${o({config:e,src:t,quality:l,width:i})} ${"w"===d?i:r+1}${d}`).join(", "),src:o({config:e,src:t,quality:l,width:a[c]})}}({config:R,src:e,unoptimized:i,width:W,quality:X,sizes:t,loader:U}),ee=V?"lazy":p;return{props:{...z,loading:ee,fetchPriority:C,width:W,height:H,decoding:w,className:f,style:{...K,...Q},sizes:Z.sizes,srcSet:Z.srcSet,src:x||Z.src},meta:{unoptimized:i,preload:u||c,placeholder:b,fill:y}}}},852824,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"default",{enumerable:!0,get:function(){return o}});let r=e.r(764556),n="u"<typeof window,l=n?()=>{}:r.useLayoutEffect,s=n?()=>{}:r.useEffect;function o(e){let{headManager:t,reduceComponentsToState:i}=e;function o(){if(t&&t.mountedInstances){let e=r.Children.toArray(Array.from(t.mountedInstances).filter(Boolean));t.updateHead(i(e))}}return n&&(t?.mountedInstances?.add(e.children),o()),l(()=>(t?.mountedInstances?.add(e.children),()=>{t?.mountedInstances?.delete(e.children)})),l(()=>(t&&(t._pendingUpdate=o),()=>{t&&(t._pendingUpdate=o)})),s(()=>(t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null),()=>{t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null)})),null}},120333,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0});var r={default:function(){return _},defaultHead:function(){return u}};for(var n in r)Object.defineProperty(i,n,{enumerable:!0,get:r[n]});let l=e.r(481258),s=e.r(744066),o=e.r(344180),a=s._(e.r(764556)),d=l._(e.r(852824)),c=e.r(57426);function u(){return[(0,o.jsx)("meta",{charSet:"utf-8"},"charset"),(0,o.jsx)("meta",{name:"viewport",content:"width=device-width"},"viewport")]}function p(e,t){return"string"==typeof t||"number"==typeof t?e:t.type===a.default.Fragment?e.concat(a.default.Children.toArray(t.props.children).reduce((e,t)=>"string"==typeof t||"number"==typeof t?e:e.concat(t),[])):e.concat(t)}e.r(837121);let f=["name","httpEquiv","charSet","itemProp"];function m(e){let t,i,r,n;return e.reduce(p,[]).reverse().concat(u().reverse()).filter((t=new Set,i=new Set,r=new Set,n={},e=>{let l=!0,s=!1;if(e.key&&"number"!=typeof e.key&&e.key.indexOf("$")>0){s=!0;let i=e.key.slice(e.key.indexOf("$")+1);t.has(i)?l=!1:t.add(i)}switch(e.type){case"title":case"base":i.has(e.type)?l=!1:i.add(e.type);break;case"meta":for(let t=0,i=f.length;t<i;t++){let i=f[t];if(e.props.hasOwnProperty(i))if("charSet"===i)r.has(i)?l=!1:r.add(i);else{let t=e.props[i],r=n[i]||new Set;("name"!==i||!s)&&r.has(t)?l=!1:(r.add(t),n[i]=r)}}}return l})).reverse().map((e,t)=>{let i=e.key||t;return a.default.cloneElement(e,{key:i})})}let _=function({children:e}){let t=(0,a.useContext)(c.HeadManagerContext);return(0,o.jsx)(d.default,{reduceComponentsToState:m,headManager:t,children:e})};("function"==typeof i.default||"object"==typeof i.default&&null!==i.default)&&void 0===i.default.__esModule&&(Object.defineProperty(i.default,"__esModule",{value:!0}),Object.assign(i.default,i),t.exports=i.default)},914272,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"ImageConfigContext",{enumerable:!0,get:function(){return l}});let r=e.r(481258)._(e.r(764556)),n=e.r(500680),l=r.default.createContext(n.imageConfigDefault)},338431,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"RouterContext",{enumerable:!0,get:function(){return r}});let r=e.r(481258)._(e.r(764556)).default.createContext(null)},741186,(e,t,i)=>{"use strict";function r(e,t){let i=e||75;return t?.qualities?.length?t.qualities.reduce((e,t)=>Math.abs(t-i)<Math.abs(e-i)?t:e,t.qualities[0]):i}Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"findClosestQuality",{enumerable:!0,get:function(){return r}})},99552,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"default",{enumerable:!0,get:function(){return s}});let r=e.r(741186),n=e.r(745137);function l({config:e,src:t,width:i,quality:s}){let o=(0,n.getDeploymentId)();if(t.startsWith("/")&&!t.startsWith("//")){let e=t.indexOf("?");if(-1!==e){let i=new URLSearchParams(t.slice(e+1)),r=i.get("dpl");if(r){o=r,i.delete("dpl");let n=i.toString();t=t.slice(0,e)+(n?"?"+n:"")}}}if(t.startsWith("/")&&t.includes("?")&&e.localPatterns?.length===1&&"**"===e.localPatterns[0].pathname&&""===e.localPatterns[0].search)throw Object.defineProperty(Error(`Image with src "${t}" is using a query string which is not configured in images.localPatterns.
|
|
3
|
+
Read more: https://nextjs.org/docs/messages/next-image-unconfigured-localpatterns`),"__NEXT_ERROR_CODE",{value:"E871",enumerable:!1,configurable:!0});let a=(0,r.findClosestQuality)(s,e);return`${e.path}?url=${encodeURIComponent(t)}&w=${i}&q=${a}${t.startsWith("/")&&o?`&dpl=${o}`:""}`}l.__next_img_default=!0;let s=l},822862,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"useMergedRef",{enumerable:!0,get:function(){return n}});let r=e.r(764556);function n(e,t){let i=(0,r.useRef)(null),n=(0,r.useRef)(null);return(0,r.useCallback)(r=>{if(null===r){let e=i.current;e&&(i.current=null,e());let t=n.current;t&&(n.current=null,t())}else e&&(i.current=l(e,r)),t&&(n.current=l(t,r))},[e,t])}function l(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let i=e(t);return"function"==typeof i?i:()=>e(null)}}("function"==typeof i.default||"object"==typeof i.default&&null!==i.default)&&void 0===i.default.__esModule&&(Object.defineProperty(i.default,"__esModule",{value:!0}),Object.assign(i.default,i),t.exports=i.default)},810034,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0}),Object.defineProperty(i,"Image",{enumerable:!0,get:function(){return v}});let r=e.r(481258),n=e.r(744066),l=e.r(344180),s=n._(e.r(764556)),o=r._(e.r(106206)),a=r._(e.r(120333)),d=e.r(622398),c=e.r(500680),u=e.r(914272);e.r(837121);let p=e.r(338431),f=r._(e.r(99552)),m=e.r(822862),_={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],qualities:[75],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1};function g(e,t,i,r,n,l,s){let o=e?.src;e&&e["data-loaded-src"]!==o&&(e["data-loaded-src"]=o,("decode"in e?e.decode():Promise.resolve()).catch(()=>{}).then(()=>{if(e.parentElement&&e.isConnected){if("empty"!==t&&n(!0),i?.current){let t=new Event("load");Object.defineProperty(t,"target",{writable:!1,value:e});let r=!1,n=!1;i.current({...t,nativeEvent:t,currentTarget:e,target:e,isDefaultPrevented:()=>r,isPropagationStopped:()=>n,persist:()=>{},preventDefault:()=>{r=!0,t.preventDefault()},stopPropagation:()=>{n=!0,t.stopPropagation()}})}r?.current&&r.current(e)}}))}function y(e){return s.use?{fetchPriority:e}:{fetchpriority:e}}"u"<typeof window&&(globalThis.__NEXT_IMAGE_IMPORTED=!0);let h=(0,s.forwardRef)(({src:e,srcSet:t,sizes:i,height:r,width:n,decoding:o,className:a,style:d,fetchPriority:c,placeholder:u,loading:p,unoptimized:f,fill:_,onLoadRef:h,onLoadingCompleteRef:x,setBlurComplete:v,setShowAltText:j,sizesInput:b,onLoad:k,onError:C,...w},M)=>{let N=(0,s.useCallback)(e=>{e&&(C&&(e.src=e.src),e.complete&&g(e,u,h,x,v,f,b))},[e,u,h,x,v,C,f,b]),I=(0,m.useMergedRef)(M,N);return(0,l.jsx)("img",{...w,...y(c),loading:p,width:n,height:r,decoding:o,"data-nimg":_?"fill":"1",className:a,style:d,sizes:i,srcSet:t,src:e,ref:I,onLoad:e=>{g(e.currentTarget,u,h,x,v,f,b)},onError:e=>{j(!0),"empty"!==u&&v(!0),C&&C(e)}})});function x({isAppRouter:e,imgAttributes:t}){let i={as:"image",imageSrcSet:t.srcSet,imageSizes:t.sizes,crossOrigin:t.crossOrigin,referrerPolicy:t.referrerPolicy,...y(t.fetchPriority)};return e&&o.default.preload?(o.default.preload(t.src,i),null):(0,l.jsx)(a.default,{children:(0,l.jsx)("link",{rel:"preload",href:t.srcSet?void 0:t.src,...i},"__nimg-"+t.src+t.srcSet+t.sizes)})}let v=(0,s.forwardRef)((e,t)=>{let i=(0,s.useContext)(p.RouterContext),r=(0,s.useContext)(u.ImageConfigContext),n=(0,s.useMemo)(()=>{let e=_||r||c.imageConfigDefault,t=[...e.deviceSizes,...e.imageSizes].sort((e,t)=>e-t),i=e.deviceSizes.sort((e,t)=>e-t),n=e.qualities?.sort((e,t)=>e-t);return{...e,allSizes:t,deviceSizes:i,qualities:n,localPatterns:"u"<typeof window?r?.localPatterns:e.localPatterns}},[r]),{onLoad:o,onLoadingComplete:a}=e,m=(0,s.useRef)(o);(0,s.useEffect)(()=>{m.current=o},[o]);let g=(0,s.useRef)(a);(0,s.useEffect)(()=>{g.current=a},[a]);let[y,v]=(0,s.useState)(!1),[j,b]=(0,s.useState)(!1),{props:k,meta:C}=(0,d.getImgProps)(e,{defaultLoader:f.default,imgConf:n,blurComplete:y,showAltText:j});return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(h,{...k,unoptimized:C.unoptimized,placeholder:C.placeholder,fill:C.fill,onLoadRef:m,onLoadingCompleteRef:g,setBlurComplete:v,setShowAltText:b,sizesInput:e.sizes,ref:t}),C.preload?(0,l.jsx)(x,{isAppRouter:!i,imgAttributes:k}):null]})});("function"==typeof i.default||"object"==typeof i.default&&null!==i.default)&&void 0===i.default.__esModule&&(Object.defineProperty(i.default,"__esModule",{value:!0}),Object.assign(i.default,i),t.exports=i.default)},776785,(e,t,i)=>{"use strict";Object.defineProperty(i,"__esModule",{value:!0});var r={default:function(){return c},getImageProps:function(){return d}};for(var n in r)Object.defineProperty(i,n,{enumerable:!0,get:r[n]});let l=e.r(481258),s=e.r(622398),o=e.r(810034),a=l._(e.r(99552));function d(e){let{props:t}=(0,s.getImgProps)(e,{defaultLoader:a.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],qualities:[75],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1}});for(let[e,i]of Object.entries(t))void 0===i&&delete t[e];return{props:t}}let c=o.Image},253937,(e,t,i)=>{t.exports=e.r(776785)},359209,e=>{"use strict";var t=e.i(344180),i=e.i(253937);let r={".ts":"file_type_typescript",".tsx":"file_type_reactts",".js":"file_type_js",".jsx":"file_type_reactjs",".mjs":"file_type_js",".cjs":"file_type_js",".json":"file_type_json",".json5":"file_type_json5",".jsonc":"file_type_json",".md":"file_type_markdown",".mdx":"file_type_mdx",".css":"file_type_css",".scss":"file_type_scss",".less":"file_type_less",".html":"file_type_html",".svg":"file_type_svg",".png":"file_type_image",".jpg":"file_type_image",".jpeg":"file_type_image",".gif":"file_type_image",".webp":"file_type_webp",".ico":"file_type_favicon",".yaml":"file_type_yaml",".yml":"file_type_yaml",".toml":"file_type_toml",".xml":"file_type_xml",".graphql":"file_type_graphql",".gql":"file_type_graphql",".prisma":"file_type_prisma",".sql":"file_type_sql",".sh":"file_type_shell",".bash":"file_type_shell",".zsh":"file_type_shell",".py":"file_type_python",".rb":"file_type_ruby",".go":"file_type_go",".rs":"file_type_rust",".java":"file_type_java",".kt":"file_type_kotlin",".swift":"file_type_swift",".c":"file_type_c",".cpp":"file_type_cpp",".h":"file_type_cheader",".hpp":"file_type_cppheader",".cs":"file_type_csharp",".php":"file_type_php",".vue":"file_type_vue",".svelte":"file_type_svelte",".dart":"file_type_dartlang",".lua":"file_type_lua",".r":"file_type_r",".ex":"file_type_elixir",".exs":"file_type_elixir",".erl":"file_type_erlang",".hs":"file_type_haskell",".scala":"file_type_scala",".clj":"file_type_clojure",".cljs":"file_type_clojurescript",".coffee":"file_type_coffeescript",".dockerfile":"file_type_docker",".makefile":"file_type_makefile",".txt":"file_type_text",".log":"file_type_log",".env":"file_type_config",".gitignore":"file_type_git",".editorconfig":"file_type_editorconfig",".prettierrc":"file_type_prettier",".eslintrc":"file_type_eslint",".lock":"file_type_lock",".wasm":"file_type_wasm",".pdf":"file_type_pdf",".mp4":"file_type_video",".webm":"file_type_video",".mov":"file_type_video",".avi":"file_type_video",".mkv":"file_type_video",".flv":"file_type_video",".mp3":"file_type_audio",".wav":"file_type_audio",".ogg":"file_type_audio",".flac":"file_type_audio",".aac":"file_type_audio",".m4a":"file_type_audio",".wma":"file_type_audio",".zip":"file_type_zip",".tar":"file_type_zip",".gz":"file_type_zip"},n={"tsconfig.json":"file_type_tsconfig","tsconfig.build.json":"file_type_tsconfig","jsconfig.json":"file_type_jsconfig","package.json":"file_type_npm","package-lock.json":"file_type_npm","pnpm-lock.yaml":"file_type_pnpm","pnpm-workspace.yaml":"file_type_pnpm",".pnpmfile.cjs":"file_type_pnpm","yarn.lock":"file_type_yarn",".yarnrc":"file_type_yarn","next.config.ts":"file_type_next","next.config.js":"file_type_next","next.config.mjs":"file_type_next","vite.config.ts":"file_type_vite","vite.config.js":"file_type_vite","tailwind.config.ts":"file_type_tailwind","tailwind.config.js":"file_type_tailwind","postcss.config.mjs":"file_type_postcss","postcss.config.js":"file_type_postcss",".eslintrc":"file_type_eslint",".eslintrc.js":"file_type_eslint",".eslintrc.json":"file_type_eslint",".eslintrc.cjs":"file_type_eslint",".prettierrc":"file_type_prettier",".prettierrc.js":"file_type_prettier",".prettierrc.json":"file_type_prettier",".gitignore":"file_type_git",".gitattributes":"file_type_git",".editorconfig":"file_type_editorconfig",dockerfile:"file_type_docker","docker-compose.yml":"file_type_docker","docker-compose.yaml":"file_type_docker",makefile:"file_type_makefile","readme.md":"file_type_markdown",license:"file_type_license","license.md":"file_type_license",".env":"file_type_config",".env.local":"file_type_config",".env.development":"file_type_config",".env.production":"file_type_config",".env.test":"file_type_config",".npmrc":"file_type_npm",".babelrc":"file_type_babel","babel.config.js":"file_type_babel","babel.config.json":"file_type_babel",".babelrc.js":"file_type_babel",".babelrc.json":"file_type_babel","jest.config.ts":"file_type_jest","jest.config.js":"file_type_jest","vitest.config.ts":"file_type_vite","vitest.config.js":"file_type_vite","webpack.config.js":"file_type_webpack","webpack.config.ts":"file_type_webpack","rollup.config.js":"file_type_rollup","rollup.config.ts":"file_type_rollup","renovate.json":"file_type_renovate",".prettierignore":"file_type_prettier",".eslintignore":"file_type_eslint",".dockerignore":"file_type_docker",prisma:"file_type_prisma"},l={src:"folder_type_src",lib:"folder_type_library",dist:"folder_type_dist",build:"folder_type_dist",out:"folder_type_dist",public:"folder_type_public",assets:"folder_type_asset",static:"folder_type_asset",components:"folder_type_component",pages:"folder_type_view",views:"folder_type_view",routes:"folder_type_route",api:"folder_type_api",server:"folder_type_server",client:"folder_type_client",test:"folder_type_test",tests:"folder_type_test",__tests__:"folder_type_test",spec:"folder_type_test",specs:"folder_type_test",e2e:"folder_type_e2e",docs:"folder_type_docs",config:"folder_type_config",configs:"folder_type_config",scripts:"folder_type_script",styles:"folder_type_style",css:"folder_type_css",images:"folder_type_images",img:"folder_type_images",icons:"folder_type_images",fonts:"folder_type_fonts",types:"folder_type_typescript",typings:"folder_type_typings",hooks:"folder_type_hook",utils:"folder_type_helper",helpers:"folder_type_helper",tools:"folder_type_tools",services:"folder_type_services",middleware:"folder_type_middleware",models:"folder_type_model",store:"folder_type_redux",stores:"folder_type_redux",state:"folder_type_redux",node_modules:"folder_type_node",".git":"folder_type_git",".github":"folder_type_github",".vscode":"folder_type_vscode",".idea":"folder_type_idea",docker:"folder_type_docker",".docker":"folder_type_docker",kubernetes:"folder_type_kubernetes",k8s:"folder_type_kubernetes",".husky":"folder_type_husky",coverage:"folder_type_coverage",".next":"folder_type_next",".nuxt":"folder_type_nuxt",ios:"folder_type_ios",android:"folder_type_android",app:"folder_type_app",packages:"folder_type_package",modules:"folder_type_module",plugins:"folder_type_plugin",templates:"folder_type_template",i18n:"folder_type_locale",locales:"folder_type_locale",lang:"folder_type_locale",translations:"folder_type_locale",prisma:"folder_type_db",db:"folder_type_db",database:"folder_type_db",migrations:"folder_type_db",seeds:"folder_type_db",storybook:"folder_type_story",stories:"folder_type_story",".storybook":"folder_type_story",".cache":"folder_type_temp",temp:"folder_type_temp",tmp:"folder_type_temp"};e.s(["FileIconImg",0,function({name:e}){return(0,t.jsx)(i.default,{src:function(e){let t,i=e.toLowerCase();if(n[i])return`/icons/${n[i]}.svg`;let l=(t=e.lastIndexOf("."))>=0?e.slice(t).toLowerCase():"";return l&&r[l]?`/icons/${r[l]}.svg`:"/icons/default_file.svg"}(e),alt:e,width:16,height:16,className:"size-4 shrink-0",unoptimized:!0})},"FolderIconImg",0,function({name:e,isOpen:r}){let n;return(0,t.jsx)(i.default,{src:(n=l[e.toLowerCase()])?`/icons/${n}${r?"_opened":""}.svg`:r?"/icons/default_folder_opened.svg":"/icons/default_folder.svg",alt:e,width:16,height:16,className:"size-4 shrink-0",unoptimized:!0})}])},867295,e=>{"use strict";let t=(0,e.i(433721).default)("eye",[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);e.s(["default",0,t])},332277,e=>{"use strict";var t=e.i(867295);e.s(["Eye",()=>t.default])},303867,e=>{"use strict";let t=(0,e.i(433721).default)("code",[["path",{d:"m16 18 6-6-6-6",key:"eg8j8"}],["path",{d:"m8 6-6 6 6 6",key:"ppft3o"}]]);e.s(["Code",0,t],303867)}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,360112,t=>{"use strict";var e=t.i(764556),a=t.i(106206);let r=Array(12).fill(0),o=({visible:t,className:a})=>e.default.createElement("div",{className:["sonner-loading-wrapper",a].filter(Boolean).join(" "),"data-visible":t},e.default.createElement("div",{className:"sonner-spinner"},r.map((t,a)=>e.default.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${a}`})))),n=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},e.default.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),s=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},e.default.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),i=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},e.default.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),l=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},e.default.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),d=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},e.default.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),e.default.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),c=1,u=new class{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{let e=this.subscribers.indexOf(t);this.subscribers.splice(e,1)}),this.publish=t=>{this.subscribers.forEach(e=>e(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var e;let{message:a,...r}=t,o="number"==typeof(null==t?void 0:t.id)||(null==(e=t.id)?void 0:e.length)>0?t.id:c++,n=this.toasts.find(t=>t.id===o),s=void 0===t.dismissible||t.dismissible;return this.dismissedToasts.has(o)&&this.dismissedToasts.delete(o),n?this.toasts=this.toasts.map(e=>e.id===o?(this.publish({...e,...t,id:o,title:a}),{...e,...t,id:o,dismissible:s,title:a}):e):this.addToast({title:a,...r,dismissible:s,id:o}),o},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(e=>e({id:t,dismiss:!0})))):this.toasts.forEach(t=>{this.subscribers.forEach(e=>e({id:t.id,dismiss:!0}))}),t),this.message=(t,e)=>this.create({...e,message:t}),this.error=(t,e)=>this.create({...e,message:t,type:"error"}),this.success=(t,e)=>this.create({...e,type:"success",message:t}),this.info=(t,e)=>this.create({...e,type:"info",message:t}),this.warning=(t,e)=>this.create({...e,type:"warning",message:t}),this.loading=(t,e)=>this.create({...e,type:"loading",message:t}),this.promise=(t,a)=>{let r,o;if(!a)return;void 0!==a.loading&&(o=this.create({...a,promise:t,type:"loading",message:a.loading,description:"function"!=typeof a.description?a.description:void 0}));let n=Promise.resolve(t instanceof Function?t():t),s=void 0!==o,i=n.then(async t=>{if(r=["resolve",t],e.default.isValidElement(t))s=!1,this.create({id:o,type:"default",message:t});else if(f(t)&&!t.ok){s=!1;let r="function"==typeof a.error?await a.error(`HTTP error! status: ${t.status}`):a.error,n="function"==typeof a.description?await a.description(`HTTP error! status: ${t.status}`):a.description,i="object"!=typeof r||e.default.isValidElement(r)?{message:r}:r;this.create({id:o,type:"error",description:n,...i})}else if(t instanceof Error){s=!1;let r="function"==typeof a.error?await a.error(t):a.error,n="function"==typeof a.description?await a.description(t):a.description,i="object"!=typeof r||e.default.isValidElement(r)?{message:r}:r;this.create({id:o,type:"error",description:n,...i})}else if(void 0!==a.success){s=!1;let r="function"==typeof a.success?await a.success(t):a.success,n="function"==typeof a.description?await a.description(t):a.description,i="object"!=typeof r||e.default.isValidElement(r)?{message:r}:r;this.create({id:o,type:"success",description:n,...i})}}).catch(async t=>{if(r=["reject",t],void 0!==a.error){s=!1;let r="function"==typeof a.error?await a.error(t):a.error,n="function"==typeof a.description?await a.description(t):a.description,i="object"!=typeof r||e.default.isValidElement(r)?{message:r}:r;this.create({id:o,type:"error",description:n,...i})}}).finally(()=>{s&&(this.dismiss(o),o=void 0),null==a.finally||a.finally.call(a)}),l=()=>new Promise((t,e)=>i.then(()=>"reject"===r[0]?e(r[1]):t(r[1])).catch(e));return"string"!=typeof o&&"number"!=typeof o?{unwrap:l}:Object.assign(o,{unwrap:l})},this.custom=(t,e)=>{let a=(null==e?void 0:e.id)||c++;return this.create({jsx:t(a),id:a,...e}),a},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},f=t=>t&&"object"==typeof t&&"ok"in t&&"boolean"==typeof t.ok&&"status"in t&&"number"==typeof t.status,m=Object.assign((t,e)=>{let a=(null==e?void 0:e.id)||c++;return u.addToast({title:t,...e,id:a}),a},{success:u.success,info:u.info,warning:u.warning,error:u.error,custom:u.custom,message:u.message,promise:u.promise,dismiss:u.dismiss,loading:u.loading},{getHistory:()=>u.toasts,getToasts:()=>u.getActiveToasts()});function p(t){return void 0!==t.label}function h(...t){return t.filter(Boolean).join(" ")}!function(t){if(!t||"u"<typeof document)return;let e=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css",e.appendChild(a),a.styleSheet?a.styleSheet.cssText=t:a.appendChild(document.createTextNode(t))}("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");let g=t=>{var a,r,c,u,f,m,g,v,y,b,x,w,k;let{invert:E,toast:S,unstyled:N,interacting:T,setHeights:j,visibleToasts:M,heights:C,index:B,toasts:I,expanded:z,removeToast:L,defaultRichColors:P,closeButton:$,style:R,cancelButtonStyle:A,actionButtonStyle:D,className:Y="",descriptionClassName:H="",duration:U,position:O,gap:V,expandByDefault:F,classNames:X,icons:q,closeButtonAriaLabel:K="Close toast"}=t,[G,J]=e.default.useState(null),[W,_]=e.default.useState(null),[Q,Z]=e.default.useState(!1),[tt,te]=e.default.useState(!1),[ta,tr]=e.default.useState(!1),[to,tn]=e.default.useState(!1),[ts,ti]=e.default.useState(!1),[tl,td]=e.default.useState(0),[tc,tu]=e.default.useState(0),tf=e.default.useRef(S.duration||U||4e3),tm=e.default.useRef(null),tp=e.default.useRef(null),th=0===B,tg=B+1<=M,tv=S.type,ty=!1!==S.dismissible,tb=S.className||"",tx=S.descriptionClassName||"",tw=e.default.useMemo(()=>C.findIndex(t=>t.toastId===S.id)||0,[C,S.id]),tk=e.default.useMemo(()=>{var t;return null!=(t=S.closeButton)?t:$},[S.closeButton,$]),tE=e.default.useMemo(()=>S.duration||U||4e3,[S.duration,U]),tS=e.default.useRef(0),tN=e.default.useRef(0),tT=e.default.useRef(0),tj=e.default.useRef(null),[tM,tC]=O.split("-"),tB=e.default.useMemo(()=>C.reduce((t,e,a)=>a>=tw?t:t+e.height,0),[C,tw]),tI=(()=>{let[t,a]=e.default.useState(document.hidden);return e.default.useEffect(()=>{let t=()=>{a(document.hidden)};return document.addEventListener("visibilitychange",t),()=>window.removeEventListener("visibilitychange",t)},[]),t})(),tz=S.invert||E,tL="loading"===tv;tN.current=e.default.useMemo(()=>tw*V+tB,[tw,tB]),e.default.useEffect(()=>{tf.current=tE},[tE]),e.default.useEffect(()=>{Z(!0)},[]),e.default.useEffect(()=>{let t=tp.current;if(t){let e=t.getBoundingClientRect().height;return tu(e),j(t=>[{toastId:S.id,height:e,position:S.position},...t]),()=>j(t=>t.filter(t=>t.toastId!==S.id))}},[j,S.id]),e.default.useLayoutEffect(()=>{if(!Q)return;let t=tp.current,e=t.style.height;t.style.height="auto";let a=t.getBoundingClientRect().height;t.style.height=e,tu(a),j(t=>t.find(t=>t.toastId===S.id)?t.map(t=>t.toastId===S.id?{...t,height:a}:t):[{toastId:S.id,height:a,position:S.position},...t])},[Q,S.title,S.description,j,S.id,S.jsx,S.action,S.cancel]);let tP=e.default.useCallback(()=>{te(!0),td(tN.current),j(t=>t.filter(t=>t.toastId!==S.id)),setTimeout(()=>{L(S)},200)},[S,L,j,tN]);e.default.useEffect(()=>{let t;if((!S.promise||"loading"!==tv)&&S.duration!==1/0&&"loading"!==S.type){if(z||T||tI){if(tT.current<tS.current){let t=new Date().getTime()-tS.current;tf.current=tf.current-t}tT.current=new Date().getTime()}else tf.current!==1/0&&(tS.current=new Date().getTime(),t=setTimeout(()=>{null==S.onAutoClose||S.onAutoClose.call(S,S),tP()},tf.current));return()=>clearTimeout(t)}},[z,T,S,tv,tI,tP]),e.default.useEffect(()=>{S.delete&&(tP(),null==S.onDismiss||S.onDismiss.call(S,S))},[tP,S.delete]);let t$=S.icon||(null==q?void 0:q[tv])||(t=>{switch(t){case"success":return n;case"info":return i;case"warning":return s;case"error":return l;default:return null}})(tv);return e.default.createElement("li",{tabIndex:0,ref:tp,className:h(Y,tb,null==X?void 0:X.toast,null==S||null==(a=S.classNames)?void 0:a.toast,null==X?void 0:X.default,null==X?void 0:X[tv],null==S||null==(r=S.classNames)?void 0:r[tv]),"data-sonner-toast":"","data-rich-colors":null!=(b=S.richColors)?b:P,"data-styled":!(S.jsx||S.unstyled||N),"data-mounted":Q,"data-promise":!!S.promise,"data-swiped":ts,"data-removed":tt,"data-visible":tg,"data-y-position":tM,"data-x-position":tC,"data-index":B,"data-front":th,"data-swiping":ta,"data-dismissible":ty,"data-type":tv,"data-invert":tz,"data-swipe-out":to,"data-swipe-direction":W,"data-expanded":!!(z||F&&Q),"data-testid":S.testId,style:{"--index":B,"--toasts-before":B,"--z-index":I.length-B,"--offset":`${tt?tl:tN.current}px`,"--initial-height":F?"auto":`${tc}px`,...R,...S.style},onDragEnd:()=>{tr(!1),J(null),tj.current=null},onPointerDown:t=>{2===t.button||tL||!ty||(tm.current=new Date,td(tN.current),t.target.setPointerCapture(t.pointerId),"BUTTON"!==t.target.tagName&&(tr(!0),tj.current={x:t.clientX,y:t.clientY}))},onPointerUp:()=>{var t,e,a,r,o;if(to||!ty)return;tj.current=null;let n=Number((null==(t=tp.current)?void 0:t.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),s=Number((null==(e=tp.current)?void 0:e.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),i=new Date().getTime()-(null==(a=tm.current)?void 0:a.getTime()),l="x"===G?n:s,d=Math.abs(l)/i;if(Math.abs(l)>=45||d>.11){td(tN.current),null==S.onDismiss||S.onDismiss.call(S,S),"x"===G?_(n>0?"right":"left"):_(s>0?"down":"up"),tP(),tn(!0);return}null==(r=tp.current)||r.style.setProperty("--swipe-amount-x","0px"),null==(o=tp.current)||o.style.setProperty("--swipe-amount-y","0px"),ti(!1),tr(!1),J(null)},onPointerMove:e=>{var a,r,o,n;if(!tj.current||!ty||(null==(a=window.getSelection())?void 0:a.toString().length)>0)return;let s=e.clientY-tj.current.y,i=e.clientX-tj.current.x,l=null!=(n=t.swipeDirections)?n:function(t){let[e,a]=t.split("-"),r=[];return e&&r.push(e),a&&r.push(a),r}(O);!G&&(Math.abs(i)>1||Math.abs(s)>1)&&J(Math.abs(i)>Math.abs(s)?"x":"y");let d={x:0,y:0},c=t=>1/(1.5+Math.abs(t)/20);if("y"===G){if(l.includes("top")||l.includes("bottom"))if(l.includes("top")&&s<0||l.includes("bottom")&&s>0)d.y=s;else{let t=s*c(s);d.y=Math.abs(t)<Math.abs(s)?t:s}}else if("x"===G&&(l.includes("left")||l.includes("right")))if(l.includes("left")&&i<0||l.includes("right")&&i>0)d.x=i;else{let t=i*c(i);d.x=Math.abs(t)<Math.abs(i)?t:i}(Math.abs(d.x)>0||Math.abs(d.y)>0)&&ti(!0),null==(r=tp.current)||r.style.setProperty("--swipe-amount-x",`${d.x}px`),null==(o=tp.current)||o.style.setProperty("--swipe-amount-y",`${d.y}px`)}},tk&&!S.jsx&&"loading"!==tv?e.default.createElement("button",{"aria-label":K,"data-disabled":tL,"data-close-button":!0,onClick:tL||!ty?()=>{}:()=>{tP(),null==S.onDismiss||S.onDismiss.call(S,S)},className:h(null==X?void 0:X.closeButton,null==S||null==(c=S.classNames)?void 0:c.closeButton)},null!=(x=null==q?void 0:q.close)?x:d):null,(tv||S.icon||S.promise)&&null!==S.icon&&((null==q?void 0:q[tv])!==null||S.icon)?e.default.createElement("div",{"data-icon":"",className:h(null==X?void 0:X.icon,null==S||null==(u=S.classNames)?void 0:u.icon)},S.promise||"loading"===S.type&&!S.icon?S.icon||((null==q?void 0:q.loading)?e.default.createElement("div",{className:h(null==X?void 0:X.loader,null==S||null==(k=S.classNames)?void 0:k.loader,"sonner-loader"),"data-visible":"loading"===tv},q.loading):e.default.createElement(o,{className:h(null==X?void 0:X.loader,null==S||null==(w=S.classNames)?void 0:w.loader),visible:"loading"===tv})):null,"loading"!==S.type?t$:null):null,e.default.createElement("div",{"data-content":"",className:h(null==X?void 0:X.content,null==S||null==(f=S.classNames)?void 0:f.content)},e.default.createElement("div",{"data-title":"",className:h(null==X?void 0:X.title,null==S||null==(m=S.classNames)?void 0:m.title)},S.jsx?S.jsx:"function"==typeof S.title?S.title():S.title),S.description?e.default.createElement("div",{"data-description":"",className:h(H,tx,null==X?void 0:X.description,null==S||null==(g=S.classNames)?void 0:g.description)},"function"==typeof S.description?S.description():S.description):null),e.default.isValidElement(S.cancel)?S.cancel:S.cancel&&p(S.cancel)?e.default.createElement("button",{"data-button":!0,"data-cancel":!0,style:S.cancelButtonStyle||A,onClick:t=>{!p(S.cancel)||ty&&(null==S.cancel.onClick||S.cancel.onClick.call(S.cancel,t),tP())},className:h(null==X?void 0:X.cancelButton,null==S||null==(v=S.classNames)?void 0:v.cancelButton)},S.cancel.label):null,e.default.isValidElement(S.action)?S.action:S.action&&p(S.action)?e.default.createElement("button",{"data-button":!0,"data-action":!0,style:S.actionButtonStyle||D,onClick:t=>{!p(S.action)||(null==S.action.onClick||S.action.onClick.call(S.action,t),t.defaultPrevented||tP())},className:h(null==X?void 0:X.actionButton,null==S||null==(y=S.classNames)?void 0:y.actionButton)},S.action.label):null)};function v(){if("u"<typeof window||"u"<typeof document)return"ltr";let t=document.documentElement.getAttribute("dir");return"auto"!==t&&t?t:window.getComputedStyle(document.documentElement).direction}let y=e.default.forwardRef(function(t,r){let{id:o,invert:n,position:s="bottom-right",hotkey:i=["altKey","KeyT"],expand:l,closeButton:d,className:c,offset:f,mobileOffset:m,theme:p="light",richColors:h,duration:y,style:b,visibleToasts:x=3,toastOptions:w,dir:k=v(),gap:E=14,icons:S,containerAriaLabel:N="Notifications"}=t,[T,j]=e.default.useState([]),M=e.default.useMemo(()=>o?T.filter(t=>t.toasterId===o):T.filter(t=>!t.toasterId),[T,o]),C=e.default.useMemo(()=>Array.from(new Set([s].concat(M.filter(t=>t.position).map(t=>t.position)))),[M,s]),[B,I]=e.default.useState([]),[z,L]=e.default.useState(!1),[P,$]=e.default.useState(!1),[R,A]=e.default.useState("system"!==p?p:"u">typeof window&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),D=e.default.useRef(null),Y=i.join("+").replace(/Key/g,"").replace(/Digit/g,""),H=e.default.useRef(null),U=e.default.useRef(!1),O=e.default.useCallback(t=>{j(e=>{var a;return(null==(a=e.find(e=>e.id===t.id))?void 0:a.delete)||u.dismiss(t.id),e.filter(({id:e})=>e!==t.id)})},[]);return e.default.useEffect(()=>u.subscribe(t=>{t.dismiss?requestAnimationFrame(()=>{j(e=>e.map(e=>e.id===t.id?{...e,delete:!0}:e))}):setTimeout(()=>{a.default.flushSync(()=>{j(e=>{let a=e.findIndex(e=>e.id===t.id);return -1!==a?[...e.slice(0,a),{...e[a],...t},...e.slice(a+1)]:[t,...e]})})})}),[T]),e.default.useEffect(()=>{if("system"!==p)return void A(p);if("system"===p&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?A("dark"):A("light")),"u"<typeof window)return;let t=window.matchMedia("(prefers-color-scheme: dark)");try{t.addEventListener("change",({matches:t})=>{t?A("dark"):A("light")})}catch(e){t.addListener(({matches:t})=>{try{t?A("dark"):A("light")}catch(t){console.error(t)}})}},[p]),e.default.useEffect(()=>{T.length<=1&&L(!1)},[T]),e.default.useEffect(()=>{let t=t=>{var e,a;i.every(e=>t[e]||t.code===e)&&(L(!0),null==(a=D.current)||a.focus()),"Escape"===t.code&&(document.activeElement===D.current||(null==(e=D.current)?void 0:e.contains(document.activeElement)))&&L(!1)};return document.addEventListener("keydown",t),()=>document.removeEventListener("keydown",t)},[i]),e.default.useEffect(()=>{if(D.current)return()=>{H.current&&(H.current.focus({preventScroll:!0}),H.current=null,U.current=!1)}},[D.current]),e.default.createElement("section",{ref:r,"aria-label":`${N} ${Y}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},C.map((a,r)=>{var o;let s,[i,u]=a.split("-");return M.length?e.default.createElement("ol",{key:a,dir:"auto"===k?v():k,tabIndex:-1,ref:D,className:c,"data-sonner-toaster":!0,"data-sonner-theme":R,"data-y-position":i,"data-x-position":u,style:{"--front-toast-height":`${(null==(o=B[0])?void 0:o.height)||0}px`,"--width":"356px","--gap":`${E}px`,...b,...(s={},[f,m].forEach((t,e)=>{let a=1===e,r=a?"--mobile-offset":"--offset",o=a?"16px":"24px";function n(t){["top","right","bottom","left"].forEach(e=>{s[`${r}-${e}`]="number"==typeof t?`${t}px`:t})}"number"==typeof t||"string"==typeof t?n(t):"object"==typeof t?["top","right","bottom","left"].forEach(e=>{void 0===t[e]?s[`${r}-${e}`]=o:s[`${r}-${e}`]="number"==typeof t[e]?`${t[e]}px`:t[e]}):n(o)}),s)},onBlur:t=>{U.current&&!t.currentTarget.contains(t.relatedTarget)&&(U.current=!1,H.current&&(H.current.focus({preventScroll:!0}),H.current=null))},onFocus:t=>{!(t.target instanceof HTMLElement&&"false"===t.target.dataset.dismissible)&&(U.current||(U.current=!0,H.current=t.relatedTarget))},onMouseEnter:()=>L(!0),onMouseMove:()=>L(!0),onMouseLeave:()=>{P||L(!1)},onDragEnd:()=>L(!1),onPointerDown:t=>{t.target instanceof HTMLElement&&"false"===t.target.dataset.dismissible||$(!0)},onPointerUp:()=>$(!1)},M.filter(t=>!t.position&&0===r||t.position===a).map((r,o)=>{var s,i;return e.default.createElement(g,{key:r.id,icons:S,index:o,toast:r,defaultRichColors:h,duration:null!=(s=null==w?void 0:w.duration)?s:y,className:null==w?void 0:w.className,descriptionClassName:null==w?void 0:w.descriptionClassName,invert:n,visibleToasts:x,closeButton:null!=(i=null==w?void 0:w.closeButton)?i:d,interacting:P,position:a,style:null==w?void 0:w.style,unstyled:null==w?void 0:w.unstyled,classNames:null==w?void 0:w.classNames,cancelButtonStyle:null==w?void 0:w.cancelButtonStyle,actionButtonStyle:null==w?void 0:w.actionButtonStyle,closeButtonAriaLabel:null==w?void 0:w.closeButtonAriaLabel,removeToast:O,toasts:M.filter(t=>t.position==r.position),heights:B.filter(t=>t.position==r.position),setHeights:I,expandByDefault:l,gap:E,expanded:z,swipeDirections:t.swipeDirections})})):null}))});t.s(["Toaster",0,y,"toast",0,m,"useSonner",0,function(){let[t,r]=e.default.useState([]);return e.default.useEffect(()=>u.subscribe(t=>{t.dismiss?setTimeout(()=>{a.default.flushSync(()=>{r(e=>e.filter(e=>e.id!==t.id))})}):setTimeout(()=>{a.default.flushSync(()=>{r(e=>{let a=e.findIndex(e=>e.id===t.id);return -1!==a?[...e.slice(0,a),{...e[a],...t},...e.slice(a+1)]:[t,...e]})})})}),[]),{toasts:t}}])},842809,203922,t=>{"use strict";let e=new Map;function a(t,a,r){return null==t?"":(function(t,a){let r=JSON.stringify({locale:t,options:a}),o=e.get(r);if(o)return o;let n=new Intl.NumberFormat(t,a);return e.set(r,n),n})(a,r).format(t)}t.s(["formatNumber",0,a,"formatNumberValue",0,function(t,e,r){return null==t?"":r?a(t,e,r):a(t/100,e,{style:"percent"})}],842809),t.s(["valueToPercent",0,function(t,e,a){return(t-e)*100/(a-e)}],203922)},817854,t=>{"use strict";var e=t.i(344180),a=t.i(465458);t.s(["Label",0,function({className:t,...r}){return(0,e.jsx)("label",{"data-slot":"label",className:(0,a.cn)("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",t),...r})}])},517432,t=>{"use strict";var e=t.i(56032),a=t.i(863728);function r(){return a.NOOP}function o(){return!1}function n(){return!0}t.s(["useIsHydrating",0,function(){return(0,e.useSyncExternalStore)(r,o,n)}])},950396,t=>{"use strict";var e=t.i(344180),a=t.i(764556),r=t.i(799543);let o=(0,a.createContext)({theme:"system",setTheme:()=>{},resolvedTheme:"light"}),n="agent-spaces-theme",s={light:"#ffffff",dark:"#0f1117"};function i(){return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}function l(t){var e;let a,r="system"===t?i():t,o=document.documentElement;o.classList.remove("light","dark"),o.classList.add(r),o.style.colorScheme=r,e=r,(a=document.querySelector('meta[name="theme-color"]'))||((a=document.createElement("meta")).name="theme-color",document.head.appendChild(a)),a.content=s[e],window.AgentSpacesStatusBar?.setTheme(e)}t.s(["ThemeProvider",0,function({children:t,defaultTheme:d="system"}){(0,r.useServerInsertedHTML)(()=>(0,e.jsx)("script",{dangerouslySetInnerHTML:{__html:`(function(){try{var t=localStorage.getItem('${n}');var d=t==='dark'||((!t||t==='system')&&matchMedia('(prefers-color-scheme:dark)').matches);var r=d?'dark':'light';document.documentElement.classList.add(r);document.documentElement.style.colorScheme=r;var m=document.querySelector('meta[name="theme-color"]');if(!m){m=document.createElement('meta');m.name='theme-color';document.head.appendChild(m)}m.content=d?'${s.dark}':'${s.light}';if(window.AgentSpacesStatusBar){window.AgentSpacesStatusBar.setTheme(r)}}catch(e){}})()`}},"theme-init"));let c=(0,a.useSyncExternalStore)(t=>{let e=window.matchMedia("(prefers-color-scheme: dark)");return e.addEventListener("change",t),()=>e.removeEventListener("change",t)},()=>i(),()=>"light"),u=(0,a.useSyncExternalStore)(t=>(window.addEventListener("storage",t),()=>window.removeEventListener("storage",t)),()=>localStorage.getItem(n)||d,()=>d),f="system"===u?c:u,m=(0,a.useCallback)(t=>{localStorage.setItem(n,t),l(t),window.dispatchEvent(new StorageEvent("storage",{key:n}))},[]);return(0,a.useEffect)(()=>{l(u)},[u,c]),(0,e.jsx)(o.Provider,{value:{theme:u,setTheme:m,resolvedTheme:f},children:t})},"useTheme",0,function(){return(0,a.useContext)(o)}])},327962,t=>{"use strict";let e=(0,t.i(433721).default)("git-branch",[["path",{d:"M15 6a9 9 0 0 0-9 9V3",key:"1cii5b"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}]]);t.s(["GitBranch",0,e],327962)},951841,t=>{"use strict";let e;var a=t.i(764556);t.s(["useUserAvatar",0,function(){let[t,r]=(0,a.useState)(()=>void 0!==e?e:localStorage.getItem("userAvatarUrl"));return(0,a.useEffect)(()=>{void 0===e&&fetch("/api/user/settings").then(t=>t.json()).then(t=>{t.avatarUrl&&(e=t.avatarUrl,r(t.avatarUrl),localStorage.setItem("userAvatarUrl",t.avatarUrl))}).catch(()=>{})},[]),t}])},92457,t=>{"use strict";let e=(0,t.i(433721).default)("monitor",[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]);t.s(["Monitor",0,e],92457)},882469,551157,t=>{"use strict";let e=(0,t.i(433721).default)("globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]);t.s(["default",0,e],551157),t.s(["Globe",0,e],882469)},964970,t=>{"use strict";var e=t.i(344180),a=t.i(764556),r=t.i(244073),o=t.i(260218),n=t.i(681622),s=t.i(817854),i=t.i(360112),l=t.i(437122);t.s(["GitSettingsForm",0,function({scope:t,workspaceId:d}){let c=(0,r.useTranslations)("git.settings"),u=(0,r.useTranslations)("common"),[f,m]=(0,a.useState)(""),[p,h]=(0,a.useState)(""),[g,v]=(0,a.useState)(""),[y,b]=(0,a.useState)(""),[x,w]=(0,a.useState)(!0),[k,E]=(0,a.useState)(!1),S=async()=>{w(!0);try{let e="global"===t?"/api/git-config":`/api/workspaces/${d}/git/config`,a=await fetch(e,{headers:(0,l.authHeaders)()});if(a.ok){let t=await a.json();m(t.name??""),h(t.email??""),v(t.proxy??"")}if("local"===t&&d){let t=await fetch(`/api/workspaces/${d}/git/remote-url`,{headers:(0,l.authHeaders)()});if(t.ok){let e=await t.json();b(e.url??"")}}}catch{}w(!1)};(0,a.useEffect)(()=>{S()},[t,d]);let N=async()=>{E(!0);try{let e="global"===t?"/api/git-config":`/api/workspaces/${d}/git/config`;if(!(await fetch(e,{method:"POST",headers:{"Content-Type":"application/json",...(0,l.authHeaders)()},body:JSON.stringify({name:f,email:p,proxy:g})})).ok){i.toast.error(c("saveFailed")),E(!1);return}"local"===t&&d&&y&&await fetch(`/api/workspaces/${d}/git/remotes`,{method:"POST",headers:{"Content-Type":"application/json",...(0,l.authHeaders)()},body:JSON.stringify({name:"origin",url:y})}),i.toast.success(c("saved"))}catch{i.toast.error(c("saveFailed"))}E(!1)};return x?(0,e.jsx)("div",{className:"text-xs text-muted-foreground",children:c("loading")}):(0,e.jsxs)("div",{className:"space-y-4",children:[(0,e.jsx)("p",{className:"text-xs text-muted-foreground",children:"global"===t?c("globalScopeDescription"):c("localScopeDescription")}),(0,e.jsxs)("div",{className:"space-y-1",children:[(0,e.jsx)(s.Label,{className:"text-xs text-muted-foreground",children:c("name")}),(0,e.jsx)(n.Input,{className:"h-7 text-xs",value:f,onChange:t=>m(t.target.value),placeholder:c("namePlaceholder")})]}),(0,e.jsxs)("div",{className:"space-y-1",children:[(0,e.jsx)(s.Label,{className:"text-xs text-muted-foreground",children:c("email")}),(0,e.jsx)(n.Input,{className:"h-7 text-xs",value:p,onChange:t=>h(t.target.value),placeholder:c("emailPlaceholder")})]}),(0,e.jsxs)("div",{className:"space-y-1",children:[(0,e.jsx)(s.Label,{className:"text-xs text-muted-foreground",children:c("proxy")}),(0,e.jsx)(n.Input,{className:"h-7 text-xs",value:g,onChange:t=>v(t.target.value),placeholder:c("proxyPlaceholder")})]}),"local"===t&&(0,e.jsxs)("div",{className:"space-y-1",children:[(0,e.jsx)(s.Label,{className:"text-xs text-muted-foreground",children:c("remoteUrl")}),(0,e.jsx)(n.Input,{className:"h-7 text-xs",value:y,onChange:t=>b(t.target.value),placeholder:c("remoteUrlPlaceholder")})]}),(0,e.jsx)(o.Button,{size:"sm",className:"text-xs",onClick:N,disabled:k,children:u(k?"loading":"save")})]})}])}]);
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,360112,t=>{"use strict";var e=t.i(764556),a=t.i(106206);let o=Array(12).fill(0),n=({visible:t,className:a})=>e.default.createElement("div",{className:["sonner-loading-wrapper",a].filter(Boolean).join(" "),"data-visible":t},e.default.createElement("div",{className:"sonner-spinner"},o.map((t,a)=>e.default.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${a}`})))),r=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},e.default.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),s=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},e.default.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),i=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},e.default.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),l=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},e.default.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),d=e.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},e.default.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),e.default.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),c=1,u=new class{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{let e=this.subscribers.indexOf(t);this.subscribers.splice(e,1)}),this.publish=t=>{this.subscribers.forEach(e=>e(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var e;let{message:a,...o}=t,n="number"==typeof(null==t?void 0:t.id)||(null==(e=t.id)?void 0:e.length)>0?t.id:c++,r=this.toasts.find(t=>t.id===n),s=void 0===t.dismissible||t.dismissible;return this.dismissedToasts.has(n)&&this.dismissedToasts.delete(n),r?this.toasts=this.toasts.map(e=>e.id===n?(this.publish({...e,...t,id:n,title:a}),{...e,...t,id:n,dismissible:s,title:a}):e):this.addToast({title:a,...o,dismissible:s,id:n}),n},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(e=>e({id:t,dismiss:!0})))):this.toasts.forEach(t=>{this.subscribers.forEach(e=>e({id:t.id,dismiss:!0}))}),t),this.message=(t,e)=>this.create({...e,message:t}),this.error=(t,e)=>this.create({...e,message:t,type:"error"}),this.success=(t,e)=>this.create({...e,type:"success",message:t}),this.info=(t,e)=>this.create({...e,type:"info",message:t}),this.warning=(t,e)=>this.create({...e,type:"warning",message:t}),this.loading=(t,e)=>this.create({...e,type:"loading",message:t}),this.promise=(t,a)=>{let o,n;if(!a)return;void 0!==a.loading&&(n=this.create({...a,promise:t,type:"loading",message:a.loading,description:"function"!=typeof a.description?a.description:void 0}));let r=Promise.resolve(t instanceof Function?t():t),s=void 0!==n,i=r.then(async t=>{if(o=["resolve",t],e.default.isValidElement(t))s=!1,this.create({id:n,type:"default",message:t});else if(f(t)&&!t.ok){s=!1;let o="function"==typeof a.error?await a.error(`HTTP error! status: ${t.status}`):a.error,r="function"==typeof a.description?await a.description(`HTTP error! status: ${t.status}`):a.description,i="object"!=typeof o||e.default.isValidElement(o)?{message:o}:o;this.create({id:n,type:"error",description:r,...i})}else if(t instanceof Error){s=!1;let o="function"==typeof a.error?await a.error(t):a.error,r="function"==typeof a.description?await a.description(t):a.description,i="object"!=typeof o||e.default.isValidElement(o)?{message:o}:o;this.create({id:n,type:"error",description:r,...i})}else if(void 0!==a.success){s=!1;let o="function"==typeof a.success?await a.success(t):a.success,r="function"==typeof a.description?await a.description(t):a.description,i="object"!=typeof o||e.default.isValidElement(o)?{message:o}:o;this.create({id:n,type:"success",description:r,...i})}}).catch(async t=>{if(o=["reject",t],void 0!==a.error){s=!1;let o="function"==typeof a.error?await a.error(t):a.error,r="function"==typeof a.description?await a.description(t):a.description,i="object"!=typeof o||e.default.isValidElement(o)?{message:o}:o;this.create({id:n,type:"error",description:r,...i})}}).finally(()=>{s&&(this.dismiss(n),n=void 0),null==a.finally||a.finally.call(a)}),l=()=>new Promise((t,e)=>i.then(()=>"reject"===o[0]?e(o[1]):t(o[1])).catch(e));return"string"!=typeof n&&"number"!=typeof n?{unwrap:l}:Object.assign(n,{unwrap:l})},this.custom=(t,e)=>{let a=(null==e?void 0:e.id)||c++;return this.create({jsx:t(a),id:a,...e}),a},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},f=t=>t&&"object"==typeof t&&"ok"in t&&"boolean"==typeof t.ok&&"status"in t&&"number"==typeof t.status,p=Object.assign((t,e)=>{let a=(null==e?void 0:e.id)||c++;return u.addToast({title:t,...e,id:a}),a},{success:u.success,info:u.info,warning:u.warning,error:u.error,custom:u.custom,message:u.message,promise:u.promise,dismiss:u.dismiss,loading:u.loading},{getHistory:()=>u.toasts,getToasts:()=>u.getActiveToasts()});function m(t){return void 0!==t.label}function h(...t){return t.filter(Boolean).join(" ")}!function(t){if(!t||"u"<typeof document)return;let e=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css",e.appendChild(a),a.styleSheet?a.styleSheet.cssText=t:a.appendChild(document.createTextNode(t))}("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");let g=t=>{var a,o,c,u,f,p,g,v,b,y,w,x,F;let{invert:E,toast:k,unstyled:S,interacting:C,setHeights:P,visibleToasts:T,heights:j,index:N,toasts:D,expanded:M,removeToast:B,defaultRichColors:R,closeButton:$,style:z,cancelButtonStyle:I,actionButtonStyle:L,className:Y="",descriptionClassName:A="",duration:O,position:U,gap:H,expandByDefault:V,classNames:X,icons:J,closeButtonAriaLabel:K="Close toast"}=t,[_,W]=e.default.useState(null),[q,G]=e.default.useState(null),[Q,Z]=e.default.useState(!1),[tt,te]=e.default.useState(!1),[ta,to]=e.default.useState(!1),[tn,tr]=e.default.useState(!1),[ts,ti]=e.default.useState(!1),[tl,td]=e.default.useState(0),[tc,tu]=e.default.useState(0),tf=e.default.useRef(k.duration||O||4e3),tp=e.default.useRef(null),tm=e.default.useRef(null),th=0===N,tg=N+1<=T,tv=k.type,tb=!1!==k.dismissible,ty=k.className||"",tw=k.descriptionClassName||"",tx=e.default.useMemo(()=>j.findIndex(t=>t.toastId===k.id)||0,[j,k.id]),tF=e.default.useMemo(()=>{var t;return null!=(t=k.closeButton)?t:$},[k.closeButton,$]),tE=e.default.useMemo(()=>k.duration||O||4e3,[k.duration,O]),tk=e.default.useRef(0),tS=e.default.useRef(0),tC=e.default.useRef(0),tP=e.default.useRef(null),[tT,tj]=U.split("-"),tN=e.default.useMemo(()=>j.reduce((t,e,a)=>a>=tx?t:t+e.height,0),[j,tx]),tD=(()=>{let[t,a]=e.default.useState(document.hidden);return e.default.useEffect(()=>{let t=()=>{a(document.hidden)};return document.addEventListener("visibilitychange",t),()=>window.removeEventListener("visibilitychange",t)},[]),t})(),tM=k.invert||E,tB="loading"===tv;tS.current=e.default.useMemo(()=>tx*H+tN,[tx,tN]),e.default.useEffect(()=>{tf.current=tE},[tE]),e.default.useEffect(()=>{Z(!0)},[]),e.default.useEffect(()=>{let t=tm.current;if(t){let e=t.getBoundingClientRect().height;return tu(e),P(t=>[{toastId:k.id,height:e,position:k.position},...t]),()=>P(t=>t.filter(t=>t.toastId!==k.id))}},[P,k.id]),e.default.useLayoutEffect(()=>{if(!Q)return;let t=tm.current,e=t.style.height;t.style.height="auto";let a=t.getBoundingClientRect().height;t.style.height=e,tu(a),P(t=>t.find(t=>t.toastId===k.id)?t.map(t=>t.toastId===k.id?{...t,height:a}:t):[{toastId:k.id,height:a,position:k.position},...t])},[Q,k.title,k.description,P,k.id,k.jsx,k.action,k.cancel]);let tR=e.default.useCallback(()=>{te(!0),td(tS.current),P(t=>t.filter(t=>t.toastId!==k.id)),setTimeout(()=>{B(k)},200)},[k,B,P,tS]);e.default.useEffect(()=>{let t;if((!k.promise||"loading"!==tv)&&k.duration!==1/0&&"loading"!==k.type){if(M||C||tD){if(tC.current<tk.current){let t=new Date().getTime()-tk.current;tf.current=tf.current-t}tC.current=new Date().getTime()}else tf.current!==1/0&&(tk.current=new Date().getTime(),t=setTimeout(()=>{null==k.onAutoClose||k.onAutoClose.call(k,k),tR()},tf.current));return()=>clearTimeout(t)}},[M,C,k,tv,tD,tR]),e.default.useEffect(()=>{k.delete&&(tR(),null==k.onDismiss||k.onDismiss.call(k,k))},[tR,k.delete]);let t$=k.icon||(null==J?void 0:J[tv])||(t=>{switch(t){case"success":return r;case"info":return i;case"warning":return s;case"error":return l;default:return null}})(tv);return e.default.createElement("li",{tabIndex:0,ref:tm,className:h(Y,ty,null==X?void 0:X.toast,null==k||null==(a=k.classNames)?void 0:a.toast,null==X?void 0:X.default,null==X?void 0:X[tv],null==k||null==(o=k.classNames)?void 0:o[tv]),"data-sonner-toast":"","data-rich-colors":null!=(y=k.richColors)?y:R,"data-styled":!(k.jsx||k.unstyled||S),"data-mounted":Q,"data-promise":!!k.promise,"data-swiped":ts,"data-removed":tt,"data-visible":tg,"data-y-position":tT,"data-x-position":tj,"data-index":N,"data-front":th,"data-swiping":ta,"data-dismissible":tb,"data-type":tv,"data-invert":tM,"data-swipe-out":tn,"data-swipe-direction":q,"data-expanded":!!(M||V&&Q),"data-testid":k.testId,style:{"--index":N,"--toasts-before":N,"--z-index":D.length-N,"--offset":`${tt?tl:tS.current}px`,"--initial-height":V?"auto":`${tc}px`,...z,...k.style},onDragEnd:()=>{to(!1),W(null),tP.current=null},onPointerDown:t=>{2===t.button||tB||!tb||(tp.current=new Date,td(tS.current),t.target.setPointerCapture(t.pointerId),"BUTTON"!==t.target.tagName&&(to(!0),tP.current={x:t.clientX,y:t.clientY}))},onPointerUp:()=>{var t,e,a,o,n;if(tn||!tb)return;tP.current=null;let r=Number((null==(t=tm.current)?void 0:t.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),s=Number((null==(e=tm.current)?void 0:e.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),i=new Date().getTime()-(null==(a=tp.current)?void 0:a.getTime()),l="x"===_?r:s,d=Math.abs(l)/i;if(Math.abs(l)>=45||d>.11){td(tS.current),null==k.onDismiss||k.onDismiss.call(k,k),"x"===_?G(r>0?"right":"left"):G(s>0?"down":"up"),tR(),tr(!0);return}null==(o=tm.current)||o.style.setProperty("--swipe-amount-x","0px"),null==(n=tm.current)||n.style.setProperty("--swipe-amount-y","0px"),ti(!1),to(!1),W(null)},onPointerMove:e=>{var a,o,n,r;if(!tP.current||!tb||(null==(a=window.getSelection())?void 0:a.toString().length)>0)return;let s=e.clientY-tP.current.y,i=e.clientX-tP.current.x,l=null!=(r=t.swipeDirections)?r:function(t){let[e,a]=t.split("-"),o=[];return e&&o.push(e),a&&o.push(a),o}(U);!_&&(Math.abs(i)>1||Math.abs(s)>1)&&W(Math.abs(i)>Math.abs(s)?"x":"y");let d={x:0,y:0},c=t=>1/(1.5+Math.abs(t)/20);if("y"===_){if(l.includes("top")||l.includes("bottom"))if(l.includes("top")&&s<0||l.includes("bottom")&&s>0)d.y=s;else{let t=s*c(s);d.y=Math.abs(t)<Math.abs(s)?t:s}}else if("x"===_&&(l.includes("left")||l.includes("right")))if(l.includes("left")&&i<0||l.includes("right")&&i>0)d.x=i;else{let t=i*c(i);d.x=Math.abs(t)<Math.abs(i)?t:i}(Math.abs(d.x)>0||Math.abs(d.y)>0)&&ti(!0),null==(o=tm.current)||o.style.setProperty("--swipe-amount-x",`${d.x}px`),null==(n=tm.current)||n.style.setProperty("--swipe-amount-y",`${d.y}px`)}},tF&&!k.jsx&&"loading"!==tv?e.default.createElement("button",{"aria-label":K,"data-disabled":tB,"data-close-button":!0,onClick:tB||!tb?()=>{}:()=>{tR(),null==k.onDismiss||k.onDismiss.call(k,k)},className:h(null==X?void 0:X.closeButton,null==k||null==(c=k.classNames)?void 0:c.closeButton)},null!=(w=null==J?void 0:J.close)?w:d):null,(tv||k.icon||k.promise)&&null!==k.icon&&((null==J?void 0:J[tv])!==null||k.icon)?e.default.createElement("div",{"data-icon":"",className:h(null==X?void 0:X.icon,null==k||null==(u=k.classNames)?void 0:u.icon)},k.promise||"loading"===k.type&&!k.icon?k.icon||((null==J?void 0:J.loading)?e.default.createElement("div",{className:h(null==X?void 0:X.loader,null==k||null==(F=k.classNames)?void 0:F.loader,"sonner-loader"),"data-visible":"loading"===tv},J.loading):e.default.createElement(n,{className:h(null==X?void 0:X.loader,null==k||null==(x=k.classNames)?void 0:x.loader),visible:"loading"===tv})):null,"loading"!==k.type?t$:null):null,e.default.createElement("div",{"data-content":"",className:h(null==X?void 0:X.content,null==k||null==(f=k.classNames)?void 0:f.content)},e.default.createElement("div",{"data-title":"",className:h(null==X?void 0:X.title,null==k||null==(p=k.classNames)?void 0:p.title)},k.jsx?k.jsx:"function"==typeof k.title?k.title():k.title),k.description?e.default.createElement("div",{"data-description":"",className:h(A,tw,null==X?void 0:X.description,null==k||null==(g=k.classNames)?void 0:g.description)},"function"==typeof k.description?k.description():k.description):null),e.default.isValidElement(k.cancel)?k.cancel:k.cancel&&m(k.cancel)?e.default.createElement("button",{"data-button":!0,"data-cancel":!0,style:k.cancelButtonStyle||I,onClick:t=>{!m(k.cancel)||tb&&(null==k.cancel.onClick||k.cancel.onClick.call(k.cancel,t),tR())},className:h(null==X?void 0:X.cancelButton,null==k||null==(v=k.classNames)?void 0:v.cancelButton)},k.cancel.label):null,e.default.isValidElement(k.action)?k.action:k.action&&m(k.action)?e.default.createElement("button",{"data-button":!0,"data-action":!0,style:k.actionButtonStyle||L,onClick:t=>{!m(k.action)||(null==k.action.onClick||k.action.onClick.call(k.action,t),t.defaultPrevented||tR())},className:h(null==X?void 0:X.actionButton,null==k||null==(b=k.classNames)?void 0:b.actionButton)},k.action.label):null)};function v(){if("u"<typeof window||"u"<typeof document)return"ltr";let t=document.documentElement.getAttribute("dir");return"auto"!==t&&t?t:window.getComputedStyle(document.documentElement).direction}let b=e.default.forwardRef(function(t,o){let{id:n,invert:r,position:s="bottom-right",hotkey:i=["altKey","KeyT"],expand:l,closeButton:d,className:c,offset:f,mobileOffset:p,theme:m="light",richColors:h,duration:b,style:y,visibleToasts:w=3,toastOptions:x,dir:F=v(),gap:E=14,icons:k,containerAriaLabel:S="Notifications"}=t,[C,P]=e.default.useState([]),T=e.default.useMemo(()=>n?C.filter(t=>t.toasterId===n):C.filter(t=>!t.toasterId),[C,n]),j=e.default.useMemo(()=>Array.from(new Set([s].concat(T.filter(t=>t.position).map(t=>t.position)))),[T,s]),[N,D]=e.default.useState([]),[M,B]=e.default.useState(!1),[R,$]=e.default.useState(!1),[z,I]=e.default.useState("system"!==m?m:"u">typeof window&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),L=e.default.useRef(null),Y=i.join("+").replace(/Key/g,"").replace(/Digit/g,""),A=e.default.useRef(null),O=e.default.useRef(!1),U=e.default.useCallback(t=>{P(e=>{var a;return(null==(a=e.find(e=>e.id===t.id))?void 0:a.delete)||u.dismiss(t.id),e.filter(({id:e})=>e!==t.id)})},[]);return e.default.useEffect(()=>u.subscribe(t=>{t.dismiss?requestAnimationFrame(()=>{P(e=>e.map(e=>e.id===t.id?{...e,delete:!0}:e))}):setTimeout(()=>{a.default.flushSync(()=>{P(e=>{let a=e.findIndex(e=>e.id===t.id);return -1!==a?[...e.slice(0,a),{...e[a],...t},...e.slice(a+1)]:[t,...e]})})})}),[C]),e.default.useEffect(()=>{if("system"!==m)return void I(m);if("system"===m&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?I("dark"):I("light")),"u"<typeof window)return;let t=window.matchMedia("(prefers-color-scheme: dark)");try{t.addEventListener("change",({matches:t})=>{t?I("dark"):I("light")})}catch(e){t.addListener(({matches:t})=>{try{t?I("dark"):I("light")}catch(t){console.error(t)}})}},[m]),e.default.useEffect(()=>{C.length<=1&&B(!1)},[C]),e.default.useEffect(()=>{let t=t=>{var e,a;i.every(e=>t[e]||t.code===e)&&(B(!0),null==(a=L.current)||a.focus()),"Escape"===t.code&&(document.activeElement===L.current||(null==(e=L.current)?void 0:e.contains(document.activeElement)))&&B(!1)};return document.addEventListener("keydown",t),()=>document.removeEventListener("keydown",t)},[i]),e.default.useEffect(()=>{if(L.current)return()=>{A.current&&(A.current.focus({preventScroll:!0}),A.current=null,O.current=!1)}},[L.current]),e.default.createElement("section",{ref:o,"aria-label":`${S} ${Y}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},j.map((a,o)=>{var n;let s,[i,u]=a.split("-");return T.length?e.default.createElement("ol",{key:a,dir:"auto"===F?v():F,tabIndex:-1,ref:L,className:c,"data-sonner-toaster":!0,"data-sonner-theme":z,"data-y-position":i,"data-x-position":u,style:{"--front-toast-height":`${(null==(n=N[0])?void 0:n.height)||0}px`,"--width":"356px","--gap":`${E}px`,...y,...(s={},[f,p].forEach((t,e)=>{let a=1===e,o=a?"--mobile-offset":"--offset",n=a?"16px":"24px";function r(t){["top","right","bottom","left"].forEach(e=>{s[`${o}-${e}`]="number"==typeof t?`${t}px`:t})}"number"==typeof t||"string"==typeof t?r(t):"object"==typeof t?["top","right","bottom","left"].forEach(e=>{void 0===t[e]?s[`${o}-${e}`]=n:s[`${o}-${e}`]="number"==typeof t[e]?`${t[e]}px`:t[e]}):r(n)}),s)},onBlur:t=>{O.current&&!t.currentTarget.contains(t.relatedTarget)&&(O.current=!1,A.current&&(A.current.focus({preventScroll:!0}),A.current=null))},onFocus:t=>{!(t.target instanceof HTMLElement&&"false"===t.target.dataset.dismissible)&&(O.current||(O.current=!0,A.current=t.relatedTarget))},onMouseEnter:()=>B(!0),onMouseMove:()=>B(!0),onMouseLeave:()=>{R||B(!1)},onDragEnd:()=>B(!1),onPointerDown:t=>{t.target instanceof HTMLElement&&"false"===t.target.dataset.dismissible||$(!0)},onPointerUp:()=>$(!1)},T.filter(t=>!t.position&&0===o||t.position===a).map((o,n)=>{var s,i;return e.default.createElement(g,{key:o.id,icons:k,index:n,toast:o,defaultRichColors:h,duration:null!=(s=null==x?void 0:x.duration)?s:b,className:null==x?void 0:x.className,descriptionClassName:null==x?void 0:x.descriptionClassName,invert:r,visibleToasts:w,closeButton:null!=(i=null==x?void 0:x.closeButton)?i:d,interacting:R,position:a,style:null==x?void 0:x.style,unstyled:null==x?void 0:x.unstyled,classNames:null==x?void 0:x.classNames,cancelButtonStyle:null==x?void 0:x.cancelButtonStyle,actionButtonStyle:null==x?void 0:x.actionButtonStyle,closeButtonAriaLabel:null==x?void 0:x.closeButtonAriaLabel,removeToast:U,toasts:T.filter(t=>t.position==o.position),heights:N.filter(t=>t.position==o.position),setHeights:D,expandByDefault:l,gap:E,expanded:M,swipeDirections:t.swipeDirections})})):null}))});t.s(["Toaster",0,b,"toast",0,p,"useSonner",0,function(){let[t,o]=e.default.useState([]);return e.default.useEffect(()=>u.subscribe(t=>{t.dismiss?setTimeout(()=>{a.default.flushSync(()=>{o(e=>e.filter(e=>e.id!==t.id))})}):setTimeout(()=>{a.default.flushSync(()=>{o(e=>{let a=e.findIndex(e=>e.id===t.id);return -1!==a?[...e.slice(0,a),{...e[a],...t},...e.slice(a+1)]:[t,...e]})})})}),[]),{toasts:t}}])},691223,t=>{"use strict";var e=t.i(816709);let a=new Set([".png",".jpg",".jpeg",".gif",".webp",".bmp",".ico"]),o=new Set([".mp4",".webm",".ogg",".mov"]),n=new Set([".mp3",".wav",".flac",".aac",".m4a",".opus"]),r=new Set([".svg"]),s=new Set([".md",".mdx"]);function i(t){let e="."+t.split(".").pop()?.toLowerCase();return a.has(e)?"image":o.has(e)?"video":n.has(e)?"audio":r.has(e)?"svg":s.has(e)?"markdown":null}let l="__commit_diff__:";function d(t){return t.startsWith(l)}function c(t){return t.slice(l.length)}let u=null;function f(){u&&(clearTimeout(u),u=null)}function p(t){f(),u=setTimeout(()=>{u=null,h.getState().saveEditorState(t)},500)}function m(t){return t.replace(/\r\n?/g,"\n")}let h=(0,e.create)((t,e)=>({tree:[],treeLoading:!1,loadingDirs:new Set,openFiles:[],modifiedFileContents:{},activeFilePath:null,pendingJump:null,revealPath:null,commitDiffs:{},loadTree:async e=>{t({treeLoading:!0});try{let a=await fetch(`/api/workspaces/${e}/files/tree?depth=1`),o=await a.json();t({tree:o,treeLoading:!1})}catch{t({treeLoading:!1})}},loadDirectory:async(a,o)=>{let{tree:n,loadingDirs:r}=e(),s=t=>{for(let e of t){if(e.path===o)return e;if(e.children){let t=s(e.children);if(t)return t}}};if(s(n)?.children!==void 0||r.has(o))return;let i=new Set(r);i.add(o),t({loadingDirs:i});try{let n=await fetch(`/api/workspaces/${a}/files/tree?path=${encodeURIComponent(o)}&depth=1`),r=await n.json(),s=t=>t.map(t=>t.path===o?{...t,children:r}:t.children?{...t,children:s(t.children)}:t),i=new Set(e().loadingDirs);i.delete(o),t({tree:s(e().tree),loadingDirs:i})}catch{let a=new Set(e().loadingDirs);a.delete(o),t({loadingDirs:a})}},openFile:async(a,o)=>{if(e().openFiles.find(t=>t.path===o)){t({activeFilePath:o}),p(a);return}let n=o.split("/").pop()||o,r=i(o);if(r&&"svg"!==r&&"markdown"!==r){t(t=>({openFiles:[...t.openFiles,{path:o,name:n,content:"",modified:!1,mediaType:r}],activeFilePath:o})),p(a);return}let s=await fetch(`/api/workspaces/${a}/files/content?path=${encodeURIComponent(o)}`),l=await s.json();t(t=>({openFiles:[...t.openFiles,{path:o,name:n,content:l.content,modified:!1,mediaType:r||void 0}],activeFilePath:o})),p(a)},saveFile:async(a,o)=>{let n=e().openFiles.find(t=>t.path===o);if(!n)return;let r=e().modifiedFileContents[o]??n.content;await fetch(`/api/workspaces/${a}/files/content`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({path:o,content:r})}),t(t=>({openFiles:t.openFiles.map(t=>t.path===o?{...t,content:r,modified:!1}:t),modifiedFileContents:Object.fromEntries(Object.entries(t.modifiedFileContents).filter(([t])=>t!==o))}))},updateContent:(e,a)=>{t(t=>({openFiles:t.openFiles.map(t=>t.path!==e?t:{...t,modified:m(t.content)!==m(a)}),modifiedFileContents:(()=>{let o=t.openFiles.find(t=>t.path===e);if(!o)return t.modifiedFileContents;let n={...t.modifiedFileContents};return m(o.content)===m(a)?delete n[e]:n[e]=a,n})()}))},refreshFile:async(a,o)=>{let n=e().openFiles.find(t=>t.path===o);if(n&&!n.modified)try{let e=await fetch(`/api/workspaces/${a}/files/content?path=${encodeURIComponent(o)}`),r=await e.json();r.content!==n.content&&t(t=>({openFiles:t.openFiles.map(t=>t.path===o?{...t,content:r.content}:t)}))}catch{}},closeFile:(e,a)=>{t(t=>{let e=t.openFiles.filter(t=>t.path!==a),o=t.activeFilePath===a?e.length>0?e[e.length-1].path:null:t.activeFilePath,n={...t.commitDiffs};d(a)&&delete n[c(a)];let r={...t.modifiedFileContents};return delete r[a],{openFiles:e,activeFilePath:o,commitDiffs:n,modifiedFileContents:r}}),p(e)},setActiveFile:(e,a)=>{t({activeFilePath:a}),p(e)},jumpToPosition:async(a,o,n,r,s,i)=>{await e().openFile(a,o),t({pendingJump:{path:o,line:n,column:r,endLine:s,endColumn:i}})},clearPendingJump:()=>t({pendingJump:null}),setRevealPath:e=>t({revealPath:e}),clearRevealPath:()=>t({revealPath:null}),resetEditorState:()=>{f(),t({tree:[],treeLoading:!1,loadingDirs:new Set,openFiles:[],modifiedFileContents:{},activeFilePath:null,pendingJump:null,revealPath:null,commitDiffs:{}})},loadEditorState:async a=>{e().resetEditorState();try{let e=await fetch(`/api/workspaces/${a}/files/editor-state`),{openFilePaths:o=[],activeFilePath:n=null,pinnedPaths:r=[]}=await e.json();if(0===o.length)return void t({openFiles:[],activeFilePath:null,modifiedFileContents:{}});let s=new Set(r),l=[];for(let t of o)try{let e=t.split("/").pop()||t,o=i(t);if(o&&"svg"!==o&&"markdown"!==o)l.push({path:t,name:e,content:"",modified:!1,mediaType:o,pinned:s.has(t)||void 0});else{let n=await fetch(`/api/workspaces/${a}/files/content?path=${encodeURIComponent(t)}`),r=await n.json();l.push({path:t,name:e,content:r.content,modified:!1,mediaType:o||void 0,pinned:s.has(t)||void 0})}}catch{}let d=n&&l.find(t=>t.path===n)?n:l.length>0?l[l.length-1].path:null;t({openFiles:l,activeFilePath:d,commitDiffs:{},modifiedFileContents:{}})}catch{t({openFiles:[],activeFilePath:null,commitDiffs:{},modifiedFileContents:{}})}},saveEditorState:async t=>{let{openFiles:a,activeFilePath:o}=e(),n=a.filter(t=>!d(t.path)),r=o&&!d(o)?o:null,s=n.filter(t=>t.pinned).map(t=>t.path);try{await fetch(`/api/workspaces/${t}/files/editor-state`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({openFilePaths:n.map(t=>t.path),activeFilePath:r,pinnedPaths:s})})}catch{}},openCommitDiff:(e,a,o,n)=>{let r=l+a;t(t=>t.openFiles.find(t=>t.path===r)?{activeFilePath:r,commitDiffs:{...t.commitDiffs,[a]:{diffs:n,message:o}}}:{openFiles:[...t.openFiles,{path:r,name:a.slice(0,7),content:"",modified:!1}],activeFilePath:r,commitDiffs:{...t.commitDiffs,[a]:{diffs:n,message:o}}})},closeCommitDiff:(t,a)=>{let o=l+a;e().closeFile(t,o)},togglePin:(e,a)=>{t(t=>{let e=t.openFiles.map(t=>t.path===a?{...t,pinned:!t.pinned}:t);return{openFiles:[...e.filter(t=>t.pinned),...e.filter(t=>!t.pinned)]}}),p(e)},reorderFiles:(e,a)=>{t({openFiles:a}),p(e)},closeOthers:(e,a)=>{t(t=>{let e=t.openFiles.filter(t=>t.path===a||t.pinned),o=new Set(e.map(t=>t.path)),n=Object.fromEntries(Object.entries(t.modifiedFileContents).filter(([t])=>o.has(t)));return{openFiles:e,activeFilePath:e.some(e=>e.path===t.activeFilePath)?t.activeFilePath:a,modifiedFileContents:n}}),p(e)},closeToLeft:(e,a)=>{t(t=>{let e=t.openFiles.findIndex(t=>t.path===a);if(e<=0)return t;let o=t.openFiles.filter((t,a)=>a>=e||t.pinned),n=new Set(o.map(t=>t.path)),r=Object.fromEntries(Object.entries(t.modifiedFileContents).filter(([t])=>n.has(t)));return{openFiles:o,activeFilePath:o.some(e=>e.path===t.activeFilePath)?t.activeFilePath:a,modifiedFileContents:r}}),p(e)},closeToRight:(e,a)=>{t(t=>{let e=t.openFiles.findIndex(t=>t.path===a);if(e<0||e>=t.openFiles.length-1)return t;let o=t.openFiles.filter((t,a)=>a<=e||t.pinned),n=new Set(o.map(t=>t.path)),r=Object.fromEntries(Object.entries(t.modifiedFileContents).filter(([t])=>n.has(t)));return{openFiles:o,activeFilePath:o.some(e=>e.path===t.activeFilePath)?t.activeFilePath:a,modifiedFileContents:r}}),p(e)}}));t.s(["getCommitHashFromPath",0,c,"getMediaType",0,i,"isCommitDiffPath",0,d,"useEditorStore",0,h])}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,962562,995684,e=>{"use strict";let t=(0,e.i(433721).default)("pencil",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);e.s(["default",0,t],995684),e.s(["Pencil",0,t],962562)},996652,e=>{"use strict";var t,n=e.i(344180);e.s([],739605),e.i(739605);var r=e.i(764556),o=e.i(166392),s=e.i(538501),a=e.i(427396),i=e.i(974578),l=e.i(389124),u=e.i(107164);e.i(8890);var c=e.i(267805);let d=r.createContext(void 0);function p(e){let t=r.useContext(d);if(void 0===t&&!e)throw Error((0,c.default)(47));return t}var f=e.i(106206),g=e.i(493696),h=e.i(332976),m=e.i(232449),x=e.i(549154),v=e.i(130522),S=e.i(742665),y=e.i(695011),b=e.i(561213),C=e.i(576487);let R={...y.popupStoreSelectors,disabled:(0,h.createSelector)(e=>e.disabled),instantType:(0,h.createSelector)(e=>e.instantType),openMethod:(0,h.createSelector)(e=>e.openMethod),openChangeReason:(0,h.createSelector)(e=>e.openChangeReason),modal:(0,h.createSelector)(e=>e.modal),focusManagerModal:(0,h.createSelector)(e=>e.focusManagerModal),stickIfOpen:(0,h.createSelector)(e=>e.stickIfOpen),titleElementId:(0,h.createSelector)(e=>e.titleElementId),descriptionElementId:(0,h.createSelector)(e=>e.descriptionElementId),openOnHover:(0,h.createSelector)(e=>e.openOnHover),closeDelay:(0,h.createSelector)(e=>e.closeDelay),hasViewport:(0,h.createSelector)(e=>e.hasViewport)};class j extends g.ReactStore{constructor(e){const t={...(0,y.createInitialPopupStoreState)(),disabled:!1,modal:!1,focusManagerModal:!1,instantType:void 0,openMethod:null,openChangeReason:null,titleElementId:void 0,descriptionElementId:void 0,stickIfOpen:!0,nested:!1,openOnHover:!1,closeDelay:0,hasViewport:!1,...e};t.open&&e?.mounted===void 0&&(t.mounted=!0),super(t,{popupRef:r.createRef(),backdropRef:r.createRef(),internalBackdropRef:r.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerFocusTargetRef:r.createRef(),beforeContentFocusGuardRef:r.createRef(),stickIfOpenTimeout:new m.Timeout,triggerElements:new b.PopupTriggerMap},R)}setOpen=(e,t)=>{let n=t.reason===S.REASONS.triggerHover,r=t.reason===S.REASONS.triggerPress&&0===t.event.detail,o=!e&&(t.reason===S.REASONS.escapeKey||null==t.reason);if(t.preventUnmountOnClose=()=>{this.set("preventUnmountingOnClose",!0)},this.context.onOpenChange?.(e,t),t.isCanceled)return;this.state.floatingRootContext.dispatchOpenChange(e,t);let s=()=>{let n={open:e,openChangeReason:t.reason},r=t.trigger?.id??null;(r||e)&&(n.activeTriggerId=r,n.activeTriggerElement=t.trigger??null),this.update(n)};n?(this.set("stickIfOpen",!0),this.context.stickIfOpenTimeout.start(C.PATIENT_CLICK_THRESHOLD,()=>{this.set("stickIfOpen",!1)}),f.flushSync(s)):s(),r||o?this.set("instantType",r?"click":"dismiss"):t.reason===S.REASONS.focusOut?this.set("instantType","focus"):this.set("instantType",void 0)};static useStore(e,t){let n=(0,x.useRefWithInit)(()=>new j(t)).current,r=e??n;return(0,v.useOnMount)(n.disposeEffect),r}disposeEffect=()=>this.context.stickIfOpenTimeout.disposeEffect()}var k=e.i(602453),E=e.i(279501),O=e.i(564846);function N({props:e}){let{children:t,open:c,defaultOpen:p=!1,onOpenChange:f,onOpenChangeComplete:g,modal:h=!1,handle:m,triggerId:x,defaultTriggerId:v=null}=e,y=j.useStore(m?.store,{modal:h,open:p,openProp:c,activeTriggerId:v,triggerIdProp:x});(0,o.useOnFirstRender)(()=>{void 0===c&&!1===y.state.open&&!0===p&&y.update({open:!0,activeTriggerId:v})}),y.useControlledProp("openProp",c),y.useControlledProp("triggerIdProp",x);let b=y.useState("open"),C=y.useState("payload");y.useContextCallback("onOpenChange",f),y.useContextCallback("onOpenChangeComplete",g);let{openMethod:R,triggerProps:I}=(0,O.useOpenInteractionType)(b);(0,E.useImplicitActiveTrigger)(y);let{forceUnmount:w}=(0,E.useOpenStateTransitions)(b,y,()=>{y.update({stickIfOpen:!0,openChangeReason:null})});r.useEffect(()=>{b||y.context.stickIfOpenTimeout.clear()},[y,b]);let T=r.useCallback(()=>{y.setOpen(!1,(0,k.createChangeEventDetails)(S.REASONS.imperativeAction))},[y]);r.useImperativeHandle(e.actionsRef,()=>({unmount:w,close:T}),[w,T]);let M=(0,u.useSyncedFloatingRootContext)({popupStore:y,onOpenChange:y.setOpen}),P=(0,s.useDismiss)(M,{outsidePressEvent:{mouse:"trap-focus"===h?"sloppy":"intentional",touch:"sloppy"}}),F=(0,i.useRole)(M),{getReferenceProps:A,getFloatingProps:z,getTriggerProps:H}=(0,a.useInteractions)([P,F]),D=r.useMemo(()=>A(I),[A,I]),L=r.useMemo(()=>H(I),[H,I]),V=r.useMemo(()=>z(),[z]);y.useSyncedValues({modal:h,openMethod:R,activeTriggerProps:D,inactiveTriggerProps:L,popupProps:V,floatingRootContext:M,nested:null!=(0,l.useFloatingParentNodeId)()});let B=r.useMemo(()=>({store:y}),[y]);return(0,n.jsx)(d.Provider,{value:B,children:"function"==typeof t?t({payload:C}):t})}var I=e.i(931709),w=e.i(817955),T=e.i(969490),M=e.i(499198),P=e.i(934940),F=e.i(480283),A=e.i(139236),z=e.i(601957),H=e.i(660079);let D=r.forwardRef(function(e,t){let{render:o,className:s,disabled:i=!1,nativeButton:l=!0,handle:u,payload:d,openOnHover:f=!1,delay:g=300,closeDelay:h=0,id:m,style:x,...v}=e,y=p(!0),b=u?.store??y?.store;if(!b)throw Error((0,c.default)(74));let R=(0,A.useBaseUiId)(m),j=b.useState("isTriggerActive",R),k=b.useState("floatingRootContext"),O=b.useState("isOpenedByTrigger",R),N=r.useRef(null),{registerTrigger:D,isMountedByThisTrigger:L}=(0,E.useTriggerDataForwarding)(R,N,b,{payload:d,disabled:i,openOnHover:f,closeDelay:h}),V=b.useState("openChangeReason"),B=b.useState("stickIfOpen"),U=b.useState("openMethod"),K=b.useState("focusManagerModal"),G=(0,F.useHoverReferenceInteraction)(k,{enabled:null!=k&&f&&("touch"!==U||V!==S.REASONS.triggerPress),mouseOnly:!0,move:!1,handleClose:(0,M.safePolygon)(),restMs:g,delay:{close:h},triggerElementRef:N,isActiveTrigger:j,isClosing:()=>"ending"===b.select("transitionStatus")}),_=(0,P.useClick)(k,{enabled:null!=k,stickIfOpen:B}),$=(0,a.useInteractions)([_]),W=b.useState("triggerProps",L),{getButtonProps:q,buttonRef:Z}=(0,I.useButton)({disabled:i,native:l}),J=r.useMemo(()=>({open:e=>e&&V===S.REASONS.triggerPress?w.pressableTriggerOpenStateMapping.open(e):w.triggerOpenStateMapping.open(e)}),[V]),X=(0,T.useRenderElement)("button",e,{state:{disabled:i,open:O},ref:[Z,t,D,N],props:[$.getReferenceProps(),G,W,{[C.CLICK_TRIGGER_IDENTIFIER]:"",id:R},v,q],stateAttributesMapping:J}),{preFocusGuardRef:Y,handlePreFocusGuardFocus:Q,handleFocusTargetFocus:ee}=(0,H.useTriggerFocusGuards)(b,N);return j&&!K?(0,n.jsxs)(r.Fragment,{children:[(0,n.jsx)(z.FocusGuard,{ref:Y,onFocus:Q}),(0,n.jsx)(r.Fragment,{children:X},R),(0,n.jsx)(z.FocusGuard,{ref:b.context.triggerFocusTargetRef,onFocus:ee})]}):(0,n.jsx)(r.Fragment,{children:X},R)});var L=e.i(128108);let V=r.createContext(void 0),B=r.forwardRef(function(e,t){let{keepMounted:r=!1,...o}=e,{store:s}=p();return s.useState("mounted")||r?(0,n.jsx)(V.Provider,{value:r,children:(0,n.jsx)(L.FloatingPortal,{ref:t,...o})}):null});var U=e.i(677822),K=e.i(277642);let G=r.createContext(void 0);function _(){let e=r.useContext(G);if(!e)throw Error((0,c.default)(46));return e}var $=e.i(576557),W=e.i(251817),q=e.i(427708),Z=e.i(909852),J=e.i(263635),X=e.i(900587);let Y=r.forwardRef(function(e,t){let{render:o,className:s,anchor:a,positionMethod:i="absolute",side:u="bottom",align:d="center",sideOffset:f=0,alignOffset:g=0,collisionBoundary:h="clipping-ancestors",collisionPadding:m=5,arrowPadding:x=5,sticky:v=!1,disableAnchorTracking:y=!1,collisionAvoidance:b=C.POPUP_COLLISION_AVOIDANCE,style:R,...j}=e,{store:k}=p(),E=function(){let e=r.useContext(V);if(void 0===e)throw Error((0,c.default)(45));return e}(),O=(0,l.useFloatingNodeId)(),N=k.useState("floatingRootContext"),I=k.useState("mounted"),w=k.useState("open"),T=k.useState("openChangeReason"),M=k.useState("activeTriggerElement"),P=k.useState("modal"),F=k.useState("openMethod"),A=k.useState("positionerElement"),z=k.useState("instantType"),H=k.useState("transitionStatus"),D=k.useState("hasViewport"),L=r.useRef(null),B=(0,q.useAnimationsFinished)(A,!1,!1),_=(0,$.useAnchorPositioning)({anchor:a,floatingRootContext:N,positionMethod:i,mounted:I,side:u,sideOffset:f,align:d,alignOffset:g,arrowPadding:x,collisionBoundary:h,collisionPadding:m,sticky:v,disableAnchorTracking:y,keepMounted:E,nodeId:O,collisionAvoidance:b,adaptiveOrigin:D?Z.adaptiveOrigin:void 0}),Y=N.useState("domReferenceElement");(0,K.useIsoLayoutEffect)(()=>{let e=L.current;if(Y&&(L.current=Y),e&&Y&&Y!==e){k.set("instantType",void 0);let e=new AbortController;return B(()=>{k.set("instantType","trigger-change")},e.signal),()=>{e.abort()}}},[Y,B,k]);let Q={open:w,side:_.side,align:_.align,anchorHidden:_.anchorHidden,instant:z};(0,X.useAnchoredPopupScrollLock)(w&&!0===P&&T!==S.REASONS.triggerHover,"touch"===F,A,M);let ee=r.useCallback(e=>{k.set("positionerElement",e)},[k]),et=(0,J.usePositioner)(e,Q,{styles:_.positionerStyles,transitionStatus:H,props:j,refs:[t,ee],hidden:!I,inert:!w});return(0,n.jsxs)(G.Provider,{value:_,children:[I&&!0===P&&T!==S.REASONS.triggerHover&&(0,n.jsx)(W.InternalBackdrop,{ref:k.context.internalBackdropRef,inert:(0,U.inertValue)(!w),cutout:M}),(0,n.jsx)(l.FloatingNode,{id:O,children:et})]})});var Q=e.i(92615),ee=e.i(583289),et=e.i(795914),en=e.i(282458),er=e.i(273598),eo=e.i(100229),es=e.i(971109),ea=e.i(328657),ei=e.i(29905);let el=r.createContext(void 0);function eu(e){let{value:t,children:r}=e;return(0,n.jsx)(el.Provider,{value:t,children:r})}let ec={...w.popupStateMapping,...en.transitionStatusMapping},ed=r.forwardRef(function(e,t){let{className:o,render:s,initialFocus:a,finalFocus:i,style:l,...u}=e,{store:c}=p(),d=_(),f=null!=(0,es.useToolbarRootContext)(!0),{context:g,hasClosePart:h}=function(){let[e,t]=r.useState(0),n=(0,ei.useStableCallback)(()=>(t(e=>e+1),()=>{t(e=>Math.max(0,e-1))}));return{context:r.useMemo(()=>({register:n}),[n]),hasClosePart:e>0}}(),m=c.useState("open"),x=c.useState("openMethod"),v=c.useState("instantType"),y=c.useState("transitionStatus"),b=c.useState("popupProps"),C=c.useState("titleElementId"),R=c.useState("descriptionElementId"),j=c.useState("modal"),k=c.useState("mounted"),E=c.useState("openChangeReason"),O=c.useState("activeTriggerElement"),N=c.useState("floatingRootContext");(0,er.useOpenChangeComplete)({open:m,ref:c.context.popupRef,onComplete(){m&&c.context.onOpenChangeComplete?.(!0)}});let I=c.useState("disabled"),w=c.useState("openOnHover"),M=c.useState("closeDelay");(0,et.useHoverFloatingInteraction)(N,{enabled:w&&!I,closeDelay:M});let P=void 0===a?function(e){return"touch"!==e||c.context.popupRef.current}:a,F={open:m,side:d.side,align:d.align,instant:v,transitionStatus:y},A=!1!==j&&h;c.useSyncedValue("focusManagerModal",A);let z=r.useCallback(e=>{c.set("popupElement",e)},[c]),H=(0,T.useRenderElement)("div",e,{state:F,ref:[t,c.context.popupRef,z],props:[b,{"aria-labelledby":C,"aria-describedby":R,onKeyDown(e){f&&eo.COMPOSITE_KEYS.has(e.key)&&e.stopPropagation()}},(0,ea.getDisabledMountTransitionStyles)(y),u],stateAttributesMapping:ec});return(0,n.jsx)(ee.FloatingFocusManager,{context:N,openInteractionType:x,modal:A,disabled:!k||E===S.REASONS.triggerHover,initialFocus:P,returnFocus:i,restoreFocus:"popup",previousFocusableElement:(0,Q.isHTMLElement)(O)?O:void 0,nextFocusableElement:c.context.triggerFocusTargetRef,beforeContentFocusGuardRef:c.context.beforeContentFocusGuardRef,children:(0,n.jsx)(eu,{value:g,children:H})})}),ep=r.forwardRef(function(e,t){let{className:n,render:r,style:o,...s}=e,{store:a}=p(),i=a.useState("open"),{arrowRef:l,side:u,align:c,arrowUncentered:d,arrowStyles:f}=_();return(0,T.useRenderElement)("div",e,{state:{open:i,side:u,align:c,uncentered:d},ref:[t,l],props:[{style:f,"aria-hidden":!0},s],stateAttributesMapping:w.popupStateMapping})}),ef={...w.popupStateMapping,...en.transitionStatusMapping},eg=r.forwardRef(function(e,t){let{className:n,render:r,style:o,...s}=e,{store:a}=p(),i=a.useState("open"),l=a.useState("mounted"),u=a.useState("transitionStatus"),c=a.useState("openChangeReason");return(0,T.useRenderElement)("div",e,{state:{open:i,transitionStatus:u},ref:[a.context.backdropRef,t],props:[{role:"presentation",hidden:!l,style:{pointerEvents:c===S.REASONS.triggerHover?"none":void 0,userSelect:"none",WebkitUserSelect:"none"}},s],stateAttributesMapping:ef})}),eh=r.forwardRef(function(e,t){let{render:n,className:r,style:o,...s}=e,{store:a}=p(),i=(0,A.useBaseUiId)(s.id);return(0,K.useIsoLayoutEffect)(()=>(a.set("titleElementId",i),()=>{a.set("titleElementId",void 0)}),[a,i]),(0,T.useRenderElement)("h2",e,{ref:t,props:[{id:i},s]})}),em=r.forwardRef(function(e,t){let{render:n,className:r,style:o,...s}=e,{store:a}=p(),i=(0,A.useBaseUiId)(s.id);return(0,K.useIsoLayoutEffect)(()=>(a.set("descriptionElementId",i),()=>{a.set("descriptionElementId",void 0)}),[a,i]),(0,T.useRenderElement)("p",e,{ref:t,props:[{id:i},s]})}),ex=r.forwardRef(function(e,t){let n,{render:o,className:s,disabled:a=!1,nativeButton:i=!0,style:l,...u}=e,{buttonRef:c,getButtonProps:d}=(0,I.useButton)({disabled:a,focusableWhenDisabled:!1,native:i}),{store:f}=p();return n=r.useContext(el),(0,K.useIsoLayoutEffect)(()=>n?.register(),[n]),(0,T.useRenderElement)("button",e,{ref:[t,c],props:[{onClick(e){f.setOpen(!1,(0,k.createChangeEventDetails)(S.REASONS.closePress,e.nativeEvent,e.currentTarget))}},u,d]})}),ev=((t={}).popupWidth="--popup-width",t.popupHeight="--popup-height",t);var eS=e.i(3310);let ey={activationDirection:e=>e?{"data-activation-direction":e}:null},eb=r.forwardRef(function(e,t){let{render:n,className:r,style:o,children:s,...a}=e,{store:i}=p(),{side:l}=_(),u=i.useState("instantType"),{children:c,state:d}=(0,eS.usePopupViewport)({store:i,side:l,cssVars:ev,children:s}),f={activationDirection:d.activationDirection,transitioning:d.transitioning,instant:u};return(0,T.useRenderElement)("div",e,{state:f,ref:t,props:[a,{children:c}],stateAttributesMapping:ey})});class eC{constructor(){this.store=new j}open(e){let t=e?this.store.context.triggerElements.getById(e)??void 0:void 0;if(e&&!t)throw Error((0,c.default)(80,e));this.store.setOpen(!0,(0,k.createChangeEventDetails)(S.REASONS.imperativeAction,void 0,t))}close(){this.store.setOpen(!1,(0,k.createChangeEventDetails)(S.REASONS.imperativeAction,void 0,void 0))}get isOpen(){return this.store.state.open}}e.s(["Arrow",0,ep,"Backdrop",0,eg,"Close",0,ex,"Description",0,em,"Handle",0,eC,"Popup",0,ed,"Portal",0,B,"Positioner",0,Y,"Root",0,function(e){return p(!0)?(0,n.jsx)(N,{props:e}):(0,n.jsx)(l.FloatingTree,{children:(0,n.jsx)(N,{props:e})})},"Title",0,eh,"Trigger",0,D,"Viewport",0,eb,"createHandle",0,function(){return new eC}],631858);var eR=e.i(631858),eR=eR,ej=e.i(465458);e.s(["Popover",0,function({...e}){return(0,n.jsx)(eR.Root,{"data-slot":"popover",...e})},"PopoverContent",0,function({className:e,positionerClassName:t,align:r="center",alignOffset:o=0,side:s="bottom",sideOffset:a=4,...i}){return(0,n.jsx)(eR.Portal,{children:(0,n.jsx)(eR.Positioner,{align:r,alignOffset:o,side:s,sideOffset:a,className:(0,ej.cn)("isolate z-50",t),children:(0,n.jsx)(eR.Popup,{"data-slot":"popover-content",className:(0,ej.cn)("z-50 flex w-72 origin-(--transform-origin) flex-col gap-2.5 rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...i})})})},"PopoverTrigger",0,function({...e}){return(0,n.jsx)(eR.Trigger,{"data-slot":"popover-trigger",...e})}],996652)},451534,680422,e=>{"use strict";let t=(0,e.i(433721).default)("folder-open",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]);e.s(["default",0,t],680422),e.s(["FolderOpen",0,t],451534)},992764,e=>{"use strict";var t=e.i(942917);e.s(["ChevronRight",()=>t.default])},973370,220336,e=>{"use strict";let t=(0,e.i(433721).default)("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);e.s(["default",0,t],220336),e.s(["Folder",0,t],973370)},62669,e=>{"use strict";let t=(0,e.i(433721).default)("loader-circle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);e.s(["Loader2",0,t],62669)},378371,e=>{"use strict";let t=(0,e.i(433721).default)("arrow-up",[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]]);e.s(["ArrowUp",0,t],378371)},411649,e=>{"use strict";let t=(0,e.i(433721).default)("house",[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"r6nss1"}]]);e.s(["Home",0,t],411649)},550080,e=>{"use strict";var t=e.i(144988);e.s(["File",()=>t.default])},198699,e=>{"use strict";let t=(0,e.i(433721).default)("folder-plus",[["path",{d:"M12 10v6",key:"1bos4e"}],["path",{d:"M9 13h6",key:"1uhe8q"}],["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);e.s(["FolderPlus",0,t],198699)},434805,e=>{"use strict";var t=e.i(344180),n=e.i(764556),r=e.i(244073),o=e.i(550080),s=e.i(973370),a=e.i(451534),i=e.i(992764),l=e.i(378371),u=e.i(411649),c=e.i(62669),d=e.i(198699),p=e.i(344118),f=e.i(972846),g=e.i(433721);let h=(0,g.default)("shield-check",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]),m=(0,g.default)("shield-alert",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M12 16h.01",key:"1drbdi"}]]),x=(0,g.default)("shield-off",[["path",{d:"m2 2 20 20",key:"1ooewy"}],["path",{d:"M5 5a1 1 0 0 0-1 1v7c0 5 3.5 7.5 7.67 8.94a1 1 0 0 0 .67.01c2.35-.82 4.48-1.97 5.9-3.71",key:"1jlk70"}],["path",{d:"M9.309 3.652A12.252 12.252 0 0 0 11.24 2.28a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1v7a9.784 9.784 0 0 1-.08 1.264",key:"18rp1v"}]]);var v=e.i(465458),S=e.i(681622),y=e.i(996652);e.s(["FolderPicker",0,function({value:e,onChange:g,className:b,placeholder:C="/path/to/project",allowFiles:R=!1,fileFilter:j}){let[k,E]=(0,n.useState)(!1),[O,N]=(0,n.useState)(e||""),[I,w]=(0,n.useState)([]),[T,M]=(0,n.useState)([]),P=(0,r.useTranslations)("folderPicker"),[F,A]=(0,n.useState)(null),[z,H]=(0,n.useState)(!1),[D,L]=(0,n.useState)(""),[V,B]=(0,n.useState)(!1),[U,K]=(0,n.useState)(""),[G,_]=(0,n.useState)(null),[$,W]=(0,n.useState)(!1),q=(0,n.useRef)(null),Z=(0,n.useRef)(null),J=(0,n.useRef)(null),X=(0,n.useCallback)(async e=>{if(!e)return void _(null);W(!0);try{let t=await fetch(`/api/folder/check-permissions?path=${encodeURIComponent(e)}`);if(!t.ok)return void _(null);let n=await t.json();_(n)}catch{_(null)}finally{W(!1)}},[]),Y=(0,n.useCallback)(async e=>{H(!0),L("");try{let t=`/api/folder/browse?path=${encodeURIComponent(e)}`;R&&(t+="&files=1",j&&(t+=`&fileFilter=${encodeURIComponent(j)}`));let n=await fetch(t);if(!n.ok)throw Error((await n.json()).error||"Failed to browse");let r=await n.json();N(r.path),w(r.directories),M(r.files??[]),A(r.parent),X(r.path)}catch(e){L(e instanceof Error?e.message:String(e))}finally{H(!1)}},[X,R,j]);(0,n.useEffect)(()=>{k&&Y(e||"")},[k,Y,e]),(0,n.useEffect)(()=>{V&&J.current&&J.current.focus()},[V]);let Q=e=>{Y(e)},ee=async()=>{let e=U.trim();if(!e)return;let t=O.includes("/")?"/":"\\",n=O?`${O}${t}${e}`:e;try{let e=await fetch("/api/folder/create",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({path:n})});if(!e.ok)throw Error((await e.json()).error||"Failed to create folder");B(!1),K(""),g(n),N(n),E(!1)}catch(e){L(e instanceof Error?e.message:String(e))}},et=I.length>0||T.length>0;return(0,t.jsx)("div",{className:(0,v.cn)("relative",b),children:(0,t.jsxs)("div",{className:"flex gap-1.5",children:[(0,t.jsx)(S.Input,{className:"rounded-xl py-2.5",placeholder:C,value:e,onChange:e=>{g(e.target.value)},onKeyDown:t=>{"Enter"===t.key&&(t.preventDefault(),Y(e))},ref:q}),(0,t.jsxs)(y.Popover,{open:k,onOpenChange:e=>{E(e),e||(B(!1),K(""))},children:[(0,t.jsxs)(y.PopoverTrigger,{className:(0,v.cn)("flex items-center gap-1.5 rounded-xl border px-3 py-2.5 text-sm transition-colors",k?"border-primary bg-primary/5 text-primary":"border-border bg-background text-muted-foreground hover:bg-accent hover:text-accent-foreground"),children:[(0,t.jsx)(a.FolderOpen,{className:"size-4"}),"Browse"]}),(0,t.jsx)(y.PopoverContent,{align:"start",className:"w-[var(--radix-popover-trigger-width)] p-0 overflow-hidden rounded-xl",style:{height:360},children:(0,t.jsxs)("div",{className:"flex h-full flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center gap-1.5 border-b border-border px-3 py-2",children:[(0,t.jsx)("button",{type:"button",onClick:()=>Q(""),className:"flex size-7 items-center justify-center rounded-md hover:bg-accent transition-colors cursor-pointer",title:"Home",children:(0,t.jsx)(u.Home,{className:"size-3.5"})}),(0,t.jsx)("button",{type:"button",onClick:()=>{F&&Y(F)},className:"flex size-7 items-center justify-center rounded-md hover:bg-accent transition-colors cursor-pointer",title:"Go up",children:(0,t.jsx)(l.ArrowUp,{className:"size-3.5"})}),(0,t.jsx)(S.Input,{className:"truncate bg-muted text-xs text-muted-foreground font-mono focus-visible:bg-background h-7",value:O,onChange:e=>N(e.target.value),onKeyDown:e=>{"Enter"===e.key&&(e.preventDefault(),Y(O))}}),(0,t.jsx)("button",{type:"button",onClick:()=>{B(!0),K("")},className:"flex size-7 items-center justify-center rounded-md hover:bg-accent transition-colors cursor-pointer",title:P("newFolder"),children:(0,t.jsx)(d.FolderPlus,{className:"size-3.5"})}),!R&&(0,t.jsx)("button",{type:"button",onClick:()=>{g(O),E(!1)},className:"rounded-lg bg-primary px-3 py-1 text-xs font-medium text-primary-foreground hover:bg-primary/90 transition-colors cursor-pointer",children:P("select")})]}),V&&(0,t.jsxs)("div",{className:"flex items-center gap-1.5 border-b border-border px-3 py-1.5",children:[(0,t.jsx)(d.FolderPlus,{className:"size-4 text-muted-foreground shrink-0"}),(0,t.jsx)(S.Input,{ref:J,className:"flex-1 h-7 text-sm",placeholder:P("folderNamePlaceholder"),value:U,onChange:e=>K(e.target.value),onKeyDown:e=>{"Enter"===e.key?(e.preventDefault(),ee()):"Escape"===e.key&&(B(!1),K(""))}}),(0,t.jsx)("button",{type:"button",onClick:ee,className:"flex size-6 items-center justify-center rounded-md hover:bg-accent transition-colors cursor-pointer",disabled:!U.trim(),children:(0,t.jsx)(p.Check,{className:"size-3.5 text-primary"})}),(0,t.jsx)("button",{type:"button",onClick:()=>{B(!1),K("")},className:"flex size-6 items-center justify-center rounded-md hover:bg-accent transition-colors cursor-pointer",children:(0,t.jsx)(f.X,{className:"size-3.5 text-muted-foreground"})})]}),(0,t.jsx)("div",{ref:Z,className:"flex-1 overflow-y-auto p-1.5",children:z?(0,t.jsxs)("div",{className:"flex items-center justify-center py-8 text-muted-foreground",children:[(0,t.jsx)(c.Loader2,{className:"size-4 animate-spin mr-2"}),"Loading..."]}):D?(0,t.jsx)("div",{className:"px-3 py-8 text-center text-xs text-destructive",children:D}):et?(0,t.jsxs)(t.Fragment,{children:[I.map(e=>(0,t.jsxs)("button",{type:"button",onClick:()=>Q(e.path),onDoubleClick:()=>{g(e.path),E(!1)},className:"flex w-full items-center gap-2 rounded-lg px-2.5 py-1.5 text-sm hover:bg-accent transition-colors text-left",children:[(0,t.jsx)(s.Folder,{className:"size-4 text-muted-foreground shrink-0"}),(0,t.jsx)("span",{className:"flex-1 truncate",children:e.name}),(0,t.jsx)(i.ChevronRight,{className:"size-3 text-muted-foreground shrink-0"})]},e.path)),T.map(e=>(0,t.jsxs)("button",{type:"button",onClick:()=>{g(e.path),E(!1)},className:"flex w-full items-center gap-2 rounded-lg px-2.5 py-1.5 text-sm hover:bg-accent transition-colors text-left",children:[(0,t.jsx)(o.File,{className:"size-4 text-muted-foreground shrink-0"}),(0,t.jsx)("span",{className:"flex-1 truncate font-mono text-xs",children:e.name})]},e.path))]}):(0,t.jsx)("div",{className:"px-3 py-8 text-center text-xs text-muted-foreground",children:"No subdirectories"})}),(0,t.jsx)("div",{className:"border-t border-border px-3 py-1.5 flex items-center gap-2 text-xs",children:$?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(c.Loader2,{className:"size-3 animate-spin text-muted-foreground"}),(0,t.jsx)("span",{className:"text-muted-foreground",children:"Checking permissions..."})]}):G?(0,t.jsx)(t.Fragment,{children:G.readable&&G.writable?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(h,{className:"size-3.5 text-green-500"}),(0,t.jsx)("span",{className:"text-green-600 dark:text-green-400",children:"Read/Write"})]}):G.readable&&!G.writable?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(m,{className:"size-3.5 text-amber-500"}),(0,t.jsx)("span",{className:"text-amber-600 dark:text-amber-400",children:"Read-only — files cannot be written here"})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(x,{className:"size-3.5 text-destructive"}),(0,t.jsx)("span",{className:"text-destructive",children:G.error||"No access"})]})}):(0,t.jsx)("span",{className:"text-muted-foreground",children:P("selectDirectory")})})]})})]})]})})}],434805)}]);
|