@alivault/pico 0.14.0 → 0.16.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.output/public/_shell.html +19 -0
- package/.output/public/assets/PatchDiff-SN-mXa3p.js +343 -0
- package/.output/public/assets/{angular-html-BZNntD0J.js → angular-html-B9LEBPKs.js} +1 -1
- package/.output/public/assets/{angular-ts-SQQMYL2C.js → angular-ts-CD6u-Ij9.js} +1 -1
- package/.output/public/assets/{apl-D5V6uPDr.js → apl-VeDHIFIx.js} +1 -1
- package/.output/public/assets/app-shell-common-0xa28gDm.js +1 -0
- package/.output/public/assets/{astro-DeXKSaFP.js → astro-Dd8L1z6M.js} +1 -1
- package/.output/public/assets/{blade-Bu5re0Vg.js → blade-BNxrbiva.js} +1 -1
- package/.output/public/assets/{bsl-B1qbqNES.js → bsl-B0twaj2j.js} +1 -1
- package/.output/public/assets/{cairo-BDj8wWhy.js → cairo-DASKFAWI.js} +1 -1
- package/.output/public/assets/{cobol-nvZDS9LT.js → cobol-D_qN8j4K.js} +1 -1
- package/.output/public/assets/{coffee-BKLOTq4e.js → coffee-60nIQewd.js} +1 -1
- package/.output/public/assets/{cpp-D6g1DVNt.js → cpp-e1j1tDCV.js} +1 -1
- package/.output/public/assets/{crystal-DfoZI57w.js → crystal-brDfRjQ_.js} +1 -1
- package/.output/public/assets/{edge-DwocGnOF.js → edge-DadfRK3Q.js} +1 -1
- package/.output/public/assets/{elixir-Dtbfds1r.js → elixir-CsoHPmz3.js} +1 -1
- package/.output/public/assets/{elm-CpPtm471.js → elm-BLTa0sZG.js} +1 -1
- package/.output/public/assets/{erb--z3IM9Cb.js → erb-DIR2QRkp.js} +1 -1
- package/.output/public/assets/{erlang-Bc4hQuqa.js → erlang-DnbJbitJ.js} +1 -1
- package/.output/public/assets/{fortran-fixed-form-B02FOYI-.js → fortran-fixed-form-Bse4XUyD.js} +1 -1
- package/.output/public/assets/{fsharp-DhdR18vN.js → fsharp-Dy8OnZ0O.js} +1 -1
- package/.output/public/assets/{gdresource-DgnrMPIx.js → gdresource-BD_7yRHA.js} +1 -1
- package/.output/public/assets/{git-commit-DGJi7qBD.js → git-commit-CIMjlyHf.js} +1 -1
- package/.output/public/assets/{git-rebase-Ce47xoa6.js → git-rebase-DV2DyQK7.js} +1 -1
- package/.output/public/assets/{glimmer-js-C0BuzxQC.js → glimmer-js-DVG5pFvd.js} +1 -1
- package/.output/public/assets/{glimmer-ts-irOZ-cAQ.js → glimmer-ts-BeWaLARz.js} +1 -1
- package/.output/public/assets/{glsl-JAhLUe0P.js → glsl-BrOWUUEh.js} +1 -1
- package/.output/public/assets/{graphql-D2ba3BkR.js → graphql-B_3o81z5.js} +1 -1
- package/.output/public/assets/{hack-CgzUpY8l.js → hack-BW-0PxQy.js} +1 -1
- package/.output/public/assets/{haml-C-oIZcDo.js → haml-DnNXiHAO.js} +1 -1
- package/.output/public/assets/{handlebars-CbP-Mhzf.js → handlebars-CftcPtku.js} +1 -1
- package/.output/public/assets/{html-ddqpqPg0.js → html-D5IqfVuz.js} +1 -1
- package/.output/public/assets/{html-derivative-DWGxf_At.js → html-derivative-QNqmMkaY.js} +1 -1
- package/.output/public/assets/{http-Bg1nG1nG.js → http-Dd7eRKUa.js} +1 -1
- package/.output/public/assets/{hurl-zm47Pi1n.js → hurl-kBs5Ibg1.js} +1 -1
- package/.output/public/assets/{hxml-adC65L_J.js → hxml-CGx66ebi.js} +1 -1
- package/.output/public/assets/index-C-mxWGZ5.css +2 -0
- package/.output/public/assets/index-FOqZaR4L.js +48 -0
- package/.output/public/assets/{jinja-Bnj4awH5.js → jinja-BPoCSjyd.js} +1 -1
- package/.output/public/assets/{jison-CuCNs9Q3.js → jison-WHPVy3Jl.js} +1 -1
- package/.output/public/assets/{julia-DNYHzXlE.js → julia-BaKiQMPf.js} +1 -1
- package/.output/public/assets/{just-BlWkkmf2.js → just-BKMc7tVT.js} +1 -1
- package/.output/public/assets/{latex-DqPzjMIt.js → latex-Cczzu1HI.js} +1 -1
- package/.output/public/assets/{liquid-BURJK16h.js → liquid-DrJZrMEf.js} +1 -1
- package/.output/public/assets/{lua-31hdJClp.js → lua-CFIwCMnP.js} +1 -1
- package/.output/public/assets/{marko-C2ZcdSLh.js → marko-BreagErn.js} +1 -1
- package/.output/public/assets/{mdc-N1ii9pk5.js → mdc-CBcMHZUq.js} +1 -1
- package/.output/public/assets/{nextflow-JEyYUlIq.js → nextflow-CZbrTmS2.js} +1 -1
- package/.output/public/assets/{nginx-BuomO0W8.js → nginx-CMOi8dTH.js} +1 -1
- package/.output/public/assets/{nim-hKoEPsYL.js → nim-DbDZ9Wa-.js} +1 -1
- package/.output/public/assets/{perl-CAGVW6Ra.js → perl-DyRCGnKu.js} +1 -1
- package/.output/public/assets/{php-BycclmzS.js → php-Ciarv7b4.js} +1 -1
- package/.output/public/assets/plus-B1rJPgNv.js +1 -0
- package/.output/public/assets/preload-helper-Csz9R64u.js +5 -0
- package/.output/public/assets/{pug-4maJHz9G.js → pug-CVCqbfEm.js} +1 -1
- package/.output/public/assets/{qml-JLIQfzyb.js → qml-DechmdFA.js} +1 -1
- package/.output/public/assets/query-keys-C9jMaRnO.js +1 -0
- package/.output/public/assets/{razor-P8rbooCh.js → razor-bgzHke67.js} +1 -1
- package/.output/public/assets/right-sidebar-CWvXcZzC.js +1831 -0
- package/.output/public/assets/routes-CXlaorp4.js +23 -0
- package/.output/public/assets/{rst-C6GHyL-N.js → rst-Ce6_XwFd.js} +1 -1
- package/.output/public/assets/{ruby-Cl8PVkbY.js → ruby-BtLKlt8E.js} +1 -1
- package/.output/public/assets/{sas-CXoVwlZN.js → sas-Bco5tnse.js} +1 -1
- package/.output/public/assets/{scss-DNczJ95n.js → scss-KPCA05M8.js} +1 -1
- package/.output/public/assets/{shaderlab-DZ3Lsiak.js → shaderlab-uUHiM5Mm.js} +1 -1
- package/.output/public/assets/{shellsession-COm1V40U.js → shellsession-BnUZVYXU.js} +1 -1
- package/.output/public/assets/{soy-DwewhJ_3.js → soy-Dsrg4bVI.js} +1 -1
- package/.output/public/assets/{sparql-B9c85a_o.js → sparql-D5zsvcbT.js} +1 -1
- package/.output/public/assets/{stata-Bl--TAbZ.js → stata-BdK5CFUf.js} +1 -1
- package/.output/public/assets/{surrealql-BW79EE-U.js → surrealql-Blm5wp47.js} +1 -1
- package/.output/public/assets/{svelte-ziMErdPi.js → svelte-DZrj_gMz.js} +1 -1
- package/.output/public/assets/{templ-C_9I6ncv.js → templ-CJ7sDrtu.js} +1 -1
- package/.output/public/assets/terminal-panel-YGR6v-ZH.js +1 -0
- package/.output/public/assets/{tex-D8LVuLf5.js → tex-CvSRdXZA.js} +1 -1
- package/.output/public/assets/{ts-tags-DKuFCGsc.js → ts-tags-DgGFCSef.js} +1 -1
- package/.output/public/assets/{twig-Bs1kcsO6.js → twig-D8_PS89g.js} +1 -1
- package/.output/public/assets/{vue-Dnf0y5RU.js → vue-KvGEuYod.js} +1 -1
- package/.output/public/assets/{vue-html-CRtKS76J.js → vue-html-qAt9D-IF.js} +1 -1
- package/.output/public/assets/{vue-vine-BxjPqU7T.js → vue-vine-j1nOqxMu.js} +1 -1
- package/.output/public/assets/{xml-eU7M3iZJ.js → xml-BrFkMwfd.js} +1 -1
- package/.output/public/assets/{xsl-DSqe4nTO.js → xsl-OmCo2PyZ.js} +1 -1
- package/.output/public/index.html +19 -0
- package/README.md +171 -46
- package/bin/native-runtime.mjs +265 -0
- package/bin/pico.mjs +289 -222
- package/package.json +34 -31
- package/.output/nitro.json +0 -17
- package/.output/public/assets/index-DBVxXDtw.js +0 -54
- package/.output/public/assets/routes-yUxD2q-l.js +0 -2194
- package/.output/public/assets/styles-CUVz7jV9.css +0 -2
- package/.output/server/__23tanstack-start-plugin-adapters-y_fshQDY.mjs +0 -5
- package/.output/server/_chunks/ssr-renderer.mjs +0 -15
- package/.output/server/_libs/@base-ui/react+[...].mjs +0 -14512
- package/.output/server/_libs/@dnd-kit/core+[...].mjs +0 -2748
- package/.output/server/_libs/@pierre/diffs+[...].mjs +0 -19314
- package/.output/server/_libs/@pierre/trees+[...].mjs +0 -9236
- package/.output/server/_libs/@radix-ui/react-dialog+[...].mjs +0 -1789
- package/.output/server/_libs/@radix-ui/react-primitive+[...].mjs +0 -136
- package/.output/server/_libs/@tanstack/devtools-event-client+[...].mjs +0 -196
- package/.output/server/_libs/@tanstack/hotkeys+[...].mjs +0 -1607
- package/.output/server/_libs/@tanstack/react-router+[...].mjs +0 -13950
- package/.output/server/_libs/@tanstack/react-router-ssr-query+[...].mjs +0 -90
- package/.output/server/_libs/bail.mjs +0 -13
- package/.output/server/_libs/character-entities.mjs +0 -2135
- package/.output/server/_libs/class-variance-authority+clsx.mjs +0 -69
- package/.output/server/_libs/cmdk.mjs +0 -473
- package/.output/server/_libs/crossws.mjs +0 -2929
- package/.output/server/_libs/decode-named-character-reference+[...].mjs +0 -19
- package/.output/server/_libs/devlop.mjs +0 -5
- package/.output/server/_libs/diff.mjs +0 -732
- package/.output/server/_libs/dnd-kit__accessibility.mjs +0 -46
- package/.output/server/_libs/dnd-kit__sortable.mjs +0 -400
- package/.output/server/_libs/entities.mjs +0 -372
- package/.output/server/_libs/escape-string-regexp.mjs +0 -7
- package/.output/server/_libs/estree-util-is-identifier-name.mjs +0 -20
- package/.output/server/_libs/extend.mjs +0 -75
- package/.output/server/_libs/h3+rou3+srvx.mjs +0 -1216
- package/.output/server/_libs/hast-util-from-parse5+[...].mjs +0 -741
- package/.output/server/_libs/hast-util-raw+[...].mjs +0 -7897
- package/.output/server/_libs/hast-util-sanitize.mjs +0 -780
- package/.output/server/_libs/hast-util-to-jsx-runtime+[...].mjs +0 -1165
- package/.output/server/_libs/hookable.mjs +0 -41
- package/.output/server/_libs/html-url-attributes.mjs +0 -44
- package/.output/server/_libs/is-plain-obj.mjs +0 -8
- package/.output/server/_libs/longest-streak.mjs +0 -29
- package/.output/server/_libs/lucide-react.mjs +0 -788
- package/.output/server/_libs/markdown-table.mjs +0 -289
- package/.output/server/_libs/mdast-util-find-and-replace.mjs +0 -198
- package/.output/server/_libs/mdast-util-from-markdown+[...].mjs +0 -8409
- package/.output/server/_libs/mdast-util-gfm+[...].mjs +0 -2062
- package/.output/server/_libs/mdast-util-to-hast+[...].mjs +0 -1771
- package/.output/server/_libs/micromark-extension-gfm+[...].mjs +0 -2234
- package/.output/server/_libs/next-themes.mjs +0 -124
- package/.output/server/_libs/pierre__theme.mjs +0 -10
- package/.output/server/_libs/radix-ui__primitive.mjs +0 -9
- package/.output/server/_libs/radix-ui__react-compose-refs.mjs +0 -30
- package/.output/server/_libs/radix-ui__react-context.mjs +0 -88
- package/.output/server/_libs/react-markdown+[...].mjs +0 -2316
- package/.output/server/_libs/rehype-raw.mjs +0 -37
- package/.output/server/_libs/rehype-sanitize.mjs +0 -27
- package/.output/server/_libs/remark-gfm.mjs +0 -34
- package/.output/server/_libs/shiki.mjs +0 -16
- package/.output/server/_libs/shikijs__langs.mjs +0 -1355
- package/.output/server/_libs/shikijs__themes.mjs +0 -262
- package/.output/server/_libs/sonner.mjs +0 -908
- package/.output/server/_libs/tailwind-merge.mjs +0 -1962
- package/.output/server/_libs/tanstack__history.mjs +0 -342
- package/.output/server/_libs/tanstack__pacer.mjs +0 -1111
- package/.output/server/_libs/tanstack__query-core.mjs +0 -2202
- package/.output/server/_libs/tanstack__react-hotkeys.mjs +0 -152
- package/.output/server/_libs/tanstack__react-query.mjs +0 -180
- package/.output/server/_libs/tanstack__react-store.mjs +0 -39
- package/.output/server/_libs/tanstack__router-core.mjs +0 -6
- package/.output/server/_libs/tanstack__store.mjs +0 -28
- package/.output/server/_libs/ufo.mjs +0 -64
- package/.output/server/_libs/unctx.mjs +0 -82
- package/.output/server/_libs/ungap__structured-clone.mjs +0 -197
- package/.output/server/_libs/vaul.mjs +0 -1250
- package/.output/server/_libs/xterm__addon-fit.mjs +0 -44
- package/.output/server/_libs/xterm__xterm.mjs +0 -10234
- package/.output/server/_libs/zod.mjs +0 -3341
- package/.output/server/_routes/api/terminal/[id]/ws.mjs +0 -8874
- package/.output/server/_runtime.mjs +0 -35
- package/.output/server/_ssr/router-CN4JMm2A.mjs +0 -9733
- package/.output/server/_ssr/routes-BsQ26pbY.mjs +0 -29306
- package/.output/server/_ssr/routes-DbjuMLFI.mjs +0 -3400
- package/.output/server/_ssr/ssr.mjs +0 -5176
- package/.output/server/_ssr/start-jIczsXlR.mjs +0 -4
- package/.output/server/_tanstack-start-manifest_v-Bs4g_j1_.mjs +0 -77
- package/.output/server/index.mjs +0 -2670
- package/.output/server/node_modules/node-pty/LICENSE +0 -69
- package/.output/server/node_modules/node-pty/README.md +0 -165
- package/.output/server/node_modules/node-pty/binding.gyp +0 -111
- package/.output/server/node_modules/node-pty/build/Makefile +0 -369
- package/.output/server/node_modules/node-pty/build/Release/pty.node +0 -0
- package/.output/server/node_modules/node-pty/build/binding.Makefile +0 -6
- package/.output/server/node_modules/node-pty/build/pty.target.mk +0 -168
- package/.output/server/node_modules/node-pty/deps/.editorconfig +0 -2
- package/.output/server/node_modules/node-pty/deps/winpty/.drone.yml +0 -17
- package/.output/server/node_modules/node-pty/deps/winpty/.gitattributes +0 -19
- package/.output/server/node_modules/node-pty/deps/winpty/LICENSE +0 -21
- package/.output/server/node_modules/node-pty/deps/winpty/Makefile +0 -166
- package/.output/server/node_modules/node-pty/deps/winpty/README.md +0 -151
- package/.output/server/node_modules/node-pty/deps/winpty/RELEASES.md +0 -280
- package/.output/server/node_modules/node-pty/deps/winpty/VERSION.txt +0 -1
- package/.output/server/node_modules/node-pty/deps/winpty/configure +0 -167
- package/.output/server/node_modules/node-pty/deps/winpty/misc/BufferResizeTests.cc +0 -90
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ChangeScreenBuffer.cc +0 -53
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ClearConsole.cc +0 -72
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ConinMode.cc +0 -117
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ConinMode.ps1 +0 -116
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ConoutMode.cc +0 -113
- package/.output/server/node_modules/node-pty/deps/winpty/misc/DebugClient.py +0 -42
- package/.output/server/node_modules/node-pty/deps/winpty/misc/DebugServer.py +0 -63
- package/.output/server/node_modules/node-pty/deps/winpty/misc/DumpLines.py +0 -5
- package/.output/server/node_modules/node-pty/deps/winpty/misc/EnableExtendedFlags.txt +0 -46
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP437-Consolas.txt +0 -528
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP437-Lucida.txt +0 -633
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP932.txt +0 -630
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP936.txt +0 -630
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP949.txt +0 -630
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP950.txt +0 -630
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/MinimumWindowWidths.txt +0 -16
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/Results.txt +0 -4
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/Windows10SetFontBugginess.txt +0 -144
- package/.output/server/node_modules/node-pty/deps/winpty/misc/FontSurvey.cc +0 -100
- package/.output/server/node_modules/node-pty/deps/winpty/misc/FormatChar.h +0 -21
- package/.output/server/node_modules/node-pty/deps/winpty/misc/FreezePerfTest.cc +0 -62
- package/.output/server/node_modules/node-pty/deps/winpty/misc/GetCh.cc +0 -20
- package/.output/server/node_modules/node-pty/deps/winpty/misc/GetConsolePos.cc +0 -41
- package/.output/server/node_modules/node-pty/deps/winpty/misc/GetFont.cc +0 -261
- package/.output/server/node_modules/node-pty/deps/winpty/misc/IdentifyConsoleWindow.ps1 +0 -51
- package/.output/server/node_modules/node-pty/deps/winpty/misc/IsNewConsole.cc +0 -87
- package/.output/server/node_modules/node-pty/deps/winpty/misc/MouseInputNotes.txt +0 -90
- package/.output/server/node_modules/node-pty/deps/winpty/misc/MoveConsoleWindow.cc +0 -34
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Notes.txt +0 -219
- package/.output/server/node_modules/node-pty/deps/winpty/misc/OSVersion.cc +0 -27
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ScreenBufferFreezeInactive.cc +0 -101
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ScreenBufferTest.cc +0 -671
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ScreenBufferTest2.cc +0 -151
- package/.output/server/node_modules/node-pty/deps/winpty/misc/SelectAllTest.cc +0 -45
- package/.output/server/node_modules/node-pty/deps/winpty/misc/SetBufferSize.cc +0 -32
- package/.output/server/node_modules/node-pty/deps/winpty/misc/SetCursorPos.cc +0 -10
- package/.output/server/node_modules/node-pty/deps/winpty/misc/SetFont.cc +0 -145
- package/.output/server/node_modules/node-pty/deps/winpty/misc/SetWindowRect.cc +0 -36
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ShowArgv.cc +0 -12
- package/.output/server/node_modules/node-pty/deps/winpty/misc/ShowConsoleInput.cc +0 -40
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Spew.py +0 -5
- package/.output/server/node_modules/node-pty/deps/winpty/misc/TestUtil.cc +0 -172
- package/.output/server/node_modules/node-pty/deps/winpty/misc/UnicodeDoubleWidthTest.cc +0 -102
- package/.output/server/node_modules/node-pty/deps/winpty/misc/UnicodeWideTest1.cc +0 -246
- package/.output/server/node_modules/node-pty/deps/winpty/misc/UnicodeWideTest2.cc +0 -130
- package/.output/server/node_modules/node-pty/deps/winpty/misc/UnixEcho.cc +0 -89
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Utf16Echo.cc +0 -46
- package/.output/server/node_modules/node-pty/deps/winpty/misc/VeryLargeRead.cc +0 -122
- package/.output/server/node_modules/node-pty/deps/winpty/misc/VkEscapeTest.cc +0 -56
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Win10ResizeWhileFrozen.cc +0 -52
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Win10WrapTest1.cc +0 -57
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Win10WrapTest2.cc +0 -30
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Win32Echo1.cc +0 -26
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Win32Echo2.cc +0 -19
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Win32Test1.cc +0 -46
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Win32Test2.cc +0 -70
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Win32Test3.cc +0 -78
- package/.output/server/node_modules/node-pty/deps/winpty/misc/Win32Write1.cc +0 -44
- package/.output/server/node_modules/node-pty/deps/winpty/misc/WindowsBugCrashReader.cc +0 -27
- package/.output/server/node_modules/node-pty/deps/winpty/misc/WriteConsole.cc +0 -106
- package/.output/server/node_modules/node-pty/deps/winpty/misc/build32.sh +0 -9
- package/.output/server/node_modules/node-pty/deps/winpty/misc/build64.sh +0 -9
- package/.output/server/node_modules/node-pty/deps/winpty/misc/color-test.sh +0 -212
- package/.output/server/node_modules/node-pty/deps/winpty/misc/font-notes.txt +0 -300
- package/.output/server/node_modules/node-pty/deps/winpty/misc/winbug-15048.cc +0 -201
- package/.output/server/node_modules/node-pty/deps/winpty/ship/build-pty4j-libpty.bat +0 -36
- package/.output/server/node_modules/node-pty/deps/winpty/ship/common_ship.py +0 -53
- package/.output/server/node_modules/node-pty/deps/winpty/ship/make_msvc_package.py +0 -165
- package/.output/server/node_modules/node-pty/deps/winpty/ship/ship.py +0 -108
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Agent.cc +0 -613
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Agent.h +0 -103
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/AgentCreateDesktop.cc +0 -84
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/AgentCreateDesktop.h +0 -28
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/ConsoleFont.cc +0 -632
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/ConsoleFont.h +0 -28
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/ConsoleInput.cc +0 -852
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/ConsoleInput.h +0 -109
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/ConsoleInputReencoding.cc +0 -121
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/ConsoleInputReencoding.h +0 -36
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/ConsoleLine.cc +0 -152
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/ConsoleLine.h +0 -41
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Coord.h +0 -87
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/DebugShowInput.cc +0 -239
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/DebugShowInput.h +0 -32
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/DefaultInputMap.cc +0 -422
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/DefaultInputMap.h +0 -28
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/DsrSender.h +0 -30
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/EventLoop.cc +0 -99
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/EventLoop.h +0 -47
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/InputMap.cc +0 -246
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/InputMap.h +0 -114
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/LargeConsoleRead.cc +0 -71
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/LargeConsoleRead.h +0 -68
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/NamedPipe.cc +0 -378
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/NamedPipe.h +0 -125
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Scraper.cc +0 -699
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Scraper.h +0 -103
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/SimplePool.h +0 -75
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/SmallRect.h +0 -143
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Terminal.cc +0 -535
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Terminal.h +0 -69
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/UnicodeEncoding.h +0 -157
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/UnicodeEncodingTest.cc +0 -189
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Win32Console.cc +0 -107
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Win32Console.h +0 -67
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Win32ConsoleBuffer.cc +0 -193
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/Win32ConsoleBuffer.h +0 -99
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/main.cc +0 -114
- package/.output/server/node_modules/node-pty/deps/winpty/src/agent/subdir.mk +0 -61
- package/.output/server/node_modules/node-pty/deps/winpty/src/configurations.gypi +0 -60
- package/.output/server/node_modules/node-pty/deps/winpty/src/debugserver/DebugServer.cc +0 -117
- package/.output/server/node_modules/node-pty/deps/winpty/src/debugserver/subdir.mk +0 -41
- package/.output/server/node_modules/node-pty/deps/winpty/src/include/winpty.h +0 -242
- package/.output/server/node_modules/node-pty/deps/winpty/src/include/winpty_constants.h +0 -131
- package/.output/server/node_modules/node-pty/deps/winpty/src/libwinpty/AgentLocation.cc +0 -75
- package/.output/server/node_modules/node-pty/deps/winpty/src/libwinpty/AgentLocation.h +0 -28
- package/.output/server/node_modules/node-pty/deps/winpty/src/libwinpty/LibWinptyException.h +0 -54
- package/.output/server/node_modules/node-pty/deps/winpty/src/libwinpty/WinptyInternal.h +0 -72
- package/.output/server/node_modules/node-pty/deps/winpty/src/libwinpty/subdir.mk +0 -46
- package/.output/server/node_modules/node-pty/deps/winpty/src/libwinpty/winpty.cc +0 -970
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/AgentMsg.h +0 -38
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/BackgroundDesktop.cc +0 -122
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/BackgroundDesktop.h +0 -73
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/Buffer.cc +0 -103
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/Buffer.h +0 -102
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/DebugClient.cc +0 -187
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/DebugClient.h +0 -38
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/GenRandom.cc +0 -138
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/GenRandom.h +0 -55
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/GetCommitHash.bat +0 -13
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/Mutex.h +0 -54
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/OsModule.h +0 -63
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/OwnedHandle.cc +0 -36
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/OwnedHandle.h +0 -45
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/PrecompiledHeader.h +0 -43
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/StringBuilder.h +0 -227
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/StringBuilderTest.cc +0 -114
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/StringUtil.cc +0 -55
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/StringUtil.h +0 -80
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/TimeMeasurement.h +0 -63
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/UnixCtrlChars.h +0 -45
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/UpdateGenVersion.bat +0 -20
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WindowsSecurity.cc +0 -460
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WindowsSecurity.h +0 -104
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WindowsVersion.cc +0 -252
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WindowsVersion.h +0 -29
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WinptyAssert.cc +0 -55
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WinptyAssert.h +0 -64
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WinptyException.cc +0 -57
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WinptyException.h +0 -43
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WinptyVersion.cc +0 -42
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/WinptyVersion.h +0 -27
- package/.output/server/node_modules/node-pty/deps/winpty/src/shared/winpty_snprintf.h +0 -99
- package/.output/server/node_modules/node-pty/deps/winpty/src/subdir.mk +0 -5
- package/.output/server/node_modules/node-pty/deps/winpty/src/tests/subdir.mk +0 -28
- package/.output/server/node_modules/node-pty/deps/winpty/src/tests/trivial_test.cc +0 -158
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/InputHandler.cc +0 -114
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/InputHandler.h +0 -56
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/OutputHandler.cc +0 -80
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/OutputHandler.h +0 -53
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/Util.cc +0 -86
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/Util.h +0 -31
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/WakeupFd.cc +0 -70
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/WakeupFd.h +0 -42
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/main.cc +0 -729
- package/.output/server/node_modules/node-pty/deps/winpty/src/unix-adapter/subdir.mk +0 -41
- package/.output/server/node_modules/node-pty/deps/winpty/src/winpty.gyp +0 -234
- package/.output/server/node_modules/node-pty/deps/winpty/vcbuild.bat +0 -83
- package/.output/server/node_modules/node-pty/lib/conpty_console_list_agent.js +0 -16
- package/.output/server/node_modules/node-pty/lib/conpty_console_list_agent.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/eventEmitter2.js +0 -47
- package/.output/server/node_modules/node-pty/lib/eventEmitter2.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/eventEmitter2.test.js +0 -30
- package/.output/server/node_modules/node-pty/lib/eventEmitter2.test.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/index.js +0 -52
- package/.output/server/node_modules/node-pty/lib/index.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/interfaces.js +0 -7
- package/.output/server/node_modules/node-pty/lib/interfaces.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/shared/conout.js +0 -11
- package/.output/server/node_modules/node-pty/lib/shared/conout.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/terminal.js +0 -190
- package/.output/server/node_modules/node-pty/lib/terminal.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/terminal.test.js +0 -139
- package/.output/server/node_modules/node-pty/lib/terminal.test.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/testUtils.test.js +0 -28
- package/.output/server/node_modules/node-pty/lib/testUtils.test.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/types.js +0 -7
- package/.output/server/node_modules/node-pty/lib/types.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/unixTerminal.js +0 -346
- package/.output/server/node_modules/node-pty/lib/unixTerminal.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/unixTerminal.test.js +0 -351
- package/.output/server/node_modules/node-pty/lib/unixTerminal.test.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/utils.js +0 -39
- package/.output/server/node_modules/node-pty/lib/utils.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/windowsConoutConnection.js +0 -125
- package/.output/server/node_modules/node-pty/lib/windowsConoutConnection.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/windowsPtyAgent.js +0 -320
- package/.output/server/node_modules/node-pty/lib/windowsPtyAgent.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/windowsPtyAgent.test.js +0 -90
- package/.output/server/node_modules/node-pty/lib/windowsPtyAgent.test.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/windowsTerminal.js +0 -199
- package/.output/server/node_modules/node-pty/lib/windowsTerminal.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/windowsTerminal.test.js +0 -219
- package/.output/server/node_modules/node-pty/lib/windowsTerminal.test.js.map +0 -1
- package/.output/server/node_modules/node-pty/lib/worker/conoutSocketWorker.js +0 -22
- package/.output/server/node_modules/node-pty/lib/worker/conoutSocketWorker.js.map +0 -1
- package/.output/server/node_modules/node-pty/package.json +0 -64
- package/.output/server/node_modules/node-pty/prebuilds/darwin-arm64/pty.node +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/darwin-arm64/spawn-helper +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/darwin-x64/pty.node +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/darwin-x64/spawn-helper +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/conpty/OpenConsole.exe +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/conpty/conpty.dll +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/conpty.node +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/conpty.pdb +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/conpty_console_list.node +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/conpty_console_list.pdb +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/pty.node +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/pty.pdb +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/winpty-agent.exe +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/winpty-agent.pdb +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/winpty.dll +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-arm64/winpty.pdb +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/conpty/OpenConsole.exe +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/conpty/conpty.dll +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/conpty.node +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/conpty.pdb +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/conpty_console_list.node +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/conpty_console_list.pdb +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/pty.node +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/pty.pdb +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/winpty-agent.exe +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/winpty-agent.pdb +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/winpty.dll +0 -0
- package/.output/server/node_modules/node-pty/prebuilds/win32-x64/winpty.pdb +0 -0
- package/.output/server/node_modules/node-pty/scripts/gen-compile-commands.js +0 -8
- package/.output/server/node_modules/node-pty/scripts/increment-version.js +0 -54
- package/.output/server/node_modules/node-pty/scripts/post-install.js +0 -80
- package/.output/server/node_modules/node-pty/scripts/prebuild.js +0 -34
- package/.output/server/node_modules/node-pty/src/conpty_console_list_agent.ts +0 -15
- package/.output/server/node_modules/node-pty/src/eventEmitter2.test.ts +0 -30
- package/.output/server/node_modules/node-pty/src/eventEmitter2.ts +0 -48
- package/.output/server/node_modules/node-pty/src/index.ts +0 -52
- package/.output/server/node_modules/node-pty/src/interfaces.ts +0 -130
- package/.output/server/node_modules/node-pty/src/native.d.ts +0 -54
- package/.output/server/node_modules/node-pty/src/shared/conout.ts +0 -15
- package/.output/server/node_modules/node-pty/src/terminal.test.ts +0 -119
- package/.output/server/node_modules/node-pty/src/terminal.ts +0 -211
- package/.output/server/node_modules/node-pty/src/testUtils.test.ts +0 -23
- package/.output/server/node_modules/node-pty/src/tsconfig.json +0 -22
- package/.output/server/node_modules/node-pty/src/types.ts +0 -15
- package/.output/server/node_modules/node-pty/src/unix/pty.cc +0 -799
- package/.output/server/node_modules/node-pty/src/unix/spawn-helper.cc +0 -23
- package/.output/server/node_modules/node-pty/src/unixTerminal.test.ts +0 -367
- package/.output/server/node_modules/node-pty/src/unixTerminal.ts +0 -388
- package/.output/server/node_modules/node-pty/src/utils.ts +0 -29
- package/.output/server/node_modules/node-pty/src/win/conpty.cc +0 -583
- package/.output/server/node_modules/node-pty/src/win/conpty.h +0 -41
- package/.output/server/node_modules/node-pty/src/win/conpty_console_list.cc +0 -44
- package/.output/server/node_modules/node-pty/src/win/path_util.cc +0 -95
- package/.output/server/node_modules/node-pty/src/win/path_util.h +0 -26
- package/.output/server/node_modules/node-pty/src/win/winpty.cc +0 -333
- package/.output/server/node_modules/node-pty/src/windowsConoutConnection.ts +0 -82
- package/.output/server/node_modules/node-pty/src/windowsPtyAgent.test.ts +0 -94
- package/.output/server/node_modules/node-pty/src/windowsPtyAgent.ts +0 -321
- package/.output/server/node_modules/node-pty/src/windowsTerminal.test.ts +0 -229
- package/.output/server/node_modules/node-pty/src/windowsTerminal.ts +0 -203
- package/.output/server/node_modules/node-pty/src/worker/conoutSocketWorker.ts +0 -22
- package/.output/server/node_modules/node-pty/third_party/conpty/1.23.251008001/win10-arm64/OpenConsole.exe +0 -0
- package/.output/server/node_modules/node-pty/third_party/conpty/1.23.251008001/win10-arm64/conpty.dll +0 -0
- package/.output/server/node_modules/node-pty/third_party/conpty/1.23.251008001/win10-x64/OpenConsole.exe +0 -0
- package/.output/server/node_modules/node-pty/third_party/conpty/1.23.251008001/win10-x64/conpty.dll +0 -0
- package/.output/server/node_modules/node-pty/typings/node-pty.d.ts +0 -211
- package/.output/server/node_modules/tslib/modules/index.js +0 -70
- package/.output/server/node_modules/tslib/modules/package.json +0 -3
- package/.output/server/node_modules/tslib/package.json +0 -47
- package/.output/server/node_modules/tslib/tslib.js +0 -484
- package/.output/server/package.json +0 -10
- package/scripts/release.mjs +0 -173
- package/vendor/node-domexception/index.js +0 -3
- package/vendor/node-domexception/package.json +0 -10
- /package/.output/public/assets/{abap-smLpETzL.js → abap-CglpPUUh.js} +0 -0
- /package/.output/public/assets/{actionscript-3-o-aRvjY5.js → actionscript-3-CGv72Q9E.js} +0 -0
- /package/.output/public/assets/{ada-D5RRX1i4.js → ada-CfxXaXwr.js} +0 -0
- /package/.output/public/assets/{addon-fit-CMMXLNsg.js → addon-fit-C9RD8ot3.js} +0 -0
- /package/.output/public/assets/{andromeeda-N4z3YzmR.js → andromeeda-DXsn6mTE.js} +0 -0
- /package/.output/public/assets/{apache-DttKlSqg.js → apache-D5xAQKSB.js} +0 -0
- /package/.output/public/assets/{apex-DL7j-a2n.js → apex-qgfedJV2.js} +0 -0
- /package/.output/public/assets/{applescript-DCbL_2FX.js → applescript-DqumQxTt.js} +0 -0
- /package/.output/public/assets/{ara-DqheWJCe.js → ara-Ditv3ow6.js} +0 -0
- /package/.output/public/assets/{asciidoc-BH2sf2K4.js → asciidoc-DL8QwiT7.js} +0 -0
- /package/.output/public/assets/{asm-rfjOMz3U.js → asm-K6TMxl3o.js} +0 -0
- /package/.output/public/assets/{aurora-x-CND-FqEb.js → aurora-x-DGv-xZaa.js} +0 -0
- /package/.output/public/assets/{awk-CMV5n9Z7.js → awk-CYSfQSDT.js} +0 -0
- /package/.output/public/assets/{ayu-dark-on7xzq_B.js → ayu-dark-DGBaJbpH.js} +0 -0
- /package/.output/public/assets/{ayu-light-DnGeGGc2.js → ayu-light-BQrGPVs2.js} +0 -0
- /package/.output/public/assets/{ayu-mirage-DG3LlYC_.js → ayu-mirage-Do-5o2VL.js} +0 -0
- /package/.output/public/assets/{ballerina-BjMqJjlr.js → ballerina-BE-8n54s.js} +0 -0
- /package/.output/public/assets/{bat-BaVbo_qw.js → bat-B1zTc1QZ.js} +0 -0
- /package/.output/public/assets/{beancount-DBt5Mbc_.js → beancount-DhObrvif.js} +0 -0
- /package/.output/public/assets/{berry-Cyjuxiss.js → berry-Cnbvthv1.js} +0 -0
- /package/.output/public/assets/{bibtex-BV_0nsPq.js → bibtex-pp5SrwZy.js} +0 -0
- /package/.output/public/assets/{bicep-C2gEwu4J.js → bicep-BL6eYxbs.js} +0 -0
- /package/.output/public/assets/{bird2-BRyaEJd0.js → bird2-BQaXYY9n.js} +0 -0
- /package/.output/public/assets/{c-Nc9zJT78.js → c-BHFJ4Jk3.js} +0 -0
- /package/.output/public/assets/{c3-DTTbp5N2.js → c3-BHTco5Hb.js} +0 -0
- /package/.output/public/assets/{cadence-CPz83cmI.js → cadence-CoPxW0qb.js} +0 -0
- /package/.output/public/assets/{catppuccin-frappe-Dr22sraq.js → catppuccin-frappe-9fYwMJCf.js} +0 -0
- /package/.output/public/assets/{catppuccin-latte-C57EeX8c.js → catppuccin-latte-BUiKH1yZ.js} +0 -0
- /package/.output/public/assets/{catppuccin-macchiato-CpheI4uD.js → catppuccin-macchiato-ZmO2e0M_.js} +0 -0
- /package/.output/public/assets/{catppuccin-mocha-D8Lmdks_.js → catppuccin-mocha-CFwbXQfO.js} +0 -0
- /package/.output/public/assets/{clarity-CFJ2Yc3q.js → clarity-DVUGm1xP.js} +0 -0
- /package/.output/public/assets/{clojure-6R01QgJC.js → clojure-BgXJG6FG.js} +0 -0
- /package/.output/public/assets/{cmake-D5rSbMir.js → cmake-CZndsvm6.js} +0 -0
- /package/.output/public/assets/{codeowners-_3A-ClkN.js → codeowners-Dd7a447M.js} +0 -0
- /package/.output/public/assets/{codeql-DlIhJTR7.js → codeql-XJR6llG-.js} +0 -0
- /package/.output/public/assets/{common-lisp-BvQzz173.js → common-lisp-BOMbLvgT.js} +0 -0
- /package/.output/public/assets/{coq-DTNXReIC.js → coq-DnhmQYDa.js} +0 -0
- /package/.output/public/assets/{csharp-BDKQY1K9.js → csharp-BdEyRqBm.js} +0 -0
- /package/.output/public/assets/{css-DRmnABqB.js → css-CsTDDTLq.js} +0 -0
- /package/.output/public/assets/{csv-DNUpVBxl.js → csv-CXchYFbz.js} +0 -0
- /package/.output/public/assets/{cue-DDdBc2s3.js → cue-D7YpBZvd.js} +0 -0
- /package/.output/public/assets/{cypher-CguaznO2.js → cypher-XIm1N8YJ.js} +0 -0
- /package/.output/public/assets/{d-CHcoyjv3.js → d-DvB0pbZH.js} +0 -0
- /package/.output/public/assets/{dark-plus-CqeW_0kH.js → dark-plus-BUdpMFIA.js} +0 -0
- /package/.output/public/assets/{dart-RM3aRphk.js → dart-CwpSKTMB.js} +0 -0
- /package/.output/public/assets/{dax-nbnY1d79.js → dax-CEynWJsU.js} +0 -0
- /package/.output/public/assets/{desktop-BD76cvxT.js → desktop-Dk-YiYS_.js} +0 -0
- /package/.output/public/assets/{diff-CdkWtnkL.js → diff-abLZ-xM1.js} +0 -0
- /package/.output/public/assets/{docker-ZyPHc6zB.js → docker-BT48KsRJ.js} +0 -0
- /package/.output/public/assets/{dotenv-BdJZEwA6.js → dotenv-NOMQQbM0.js} +0 -0
- /package/.output/public/assets/{dracula-CtqCPLGa.js → dracula-BUW0ZyNO.js} +0 -0
- /package/.output/public/assets/{dracula-soft-DmBpwRAy.js → dracula-soft-BMjAt1_u.js} +0 -0
- /package/.output/public/assets/{dream-maker-BJL4qlg3.js → dream-maker-D26TP1Q3.js} +0 -0
- /package/.output/public/assets/{emacs-lisp-_LyYa2Ky.js → emacs-lisp-C2EvfotR.js} +0 -0
- /package/.output/public/assets/{everforest-dark-CrbyKk4n.js → everforest-dark-hC6a272f.js} +0 -0
- /package/.output/public/assets/{everforest-light-DRbSh8Tm.js → everforest-light-BTpbYY5G.js} +0 -0
- /package/.output/public/assets/{fennel-CC2BkRsS.js → fennel-DWOL-Ewx.js} +0 -0
- /package/.output/public/assets/{fish-D2ZCzqcE.js → fish-CQPQq0pQ.js} +0 -0
- /package/.output/public/assets/{fluent-DKAm3m7q.js → fluent-BYdsr2M8.js} +0 -0
- /package/.output/public/assets/{fortran-free-form-BPTf0lbT.js → fortran-free-form-C_EtY4F9.js} +0 -0
- /package/.output/public/assets/{gdscript-CsadCSaZ.js → gdscript-CH_tD-VB.js} +0 -0
- /package/.output/public/assets/{gdshader-PfnN_8tR.js → gdshader-BemFblFP.js} +0 -0
- /package/.output/public/assets/{genie-Bj-orPAV.js → genie-hCPg_eq7.js} +0 -0
- /package/.output/public/assets/{gherkin-COVWpJ-Q.js → gherkin-CO0ypD1P.js} +0 -0
- /package/.output/public/assets/{github-dark-ipGuFGYC.js → github-dark-cA72fqmI.js} +0 -0
- /package/.output/public/assets/{github-dark-default-DX3IG_X0.js → github-dark-default-DiYTFvY5.js} +0 -0
- /package/.output/public/assets/{github-dark-dimmed-CH6p_7ez.js → github-dark-dimmed-D-uBHzyG.js} +0 -0
- /package/.output/public/assets/{github-dark-high-contrast-Bg2sSao5.js → github-dark-high-contrast-BrUSkckI.js} +0 -0
- /package/.output/public/assets/{github-light-default-DwpDd1IQ.js → github-light-default-BT-6Vf7C.js} +0 -0
- /package/.output/public/assets/{github-light-high-contrast-C0QeixPf.js → github-light-high-contrast-DqmEyTTc.js} +0 -0
- /package/.output/public/assets/{github-light-BxjqOQl0.js → github-light-piFPqU8R.js} +0 -0
- /package/.output/public/assets/{gleam-BF2NigGj.js → gleam-CWJA_H5i.js} +0 -0
- /package/.output/public/assets/{gn-CMIt9roj.js → gn-nlTwLSjP.js} +0 -0
- /package/.output/public/assets/{gnuplot-DgWlRTEj.js → gnuplot-wYV0MbPl.js} +0 -0
- /package/.output/public/assets/{go-DLnOLj8q.js → go-BUPBDRDo.js} +0 -0
- /package/.output/public/assets/{groovy-B9qLWIkE.js → groovy-BusafOA8.js} +0 -0
- /package/.output/public/assets/{gruvbox-dark-hard-BIMX9ePb.js → gruvbox-dark-hard-BrrZYoPF.js} +0 -0
- /package/.output/public/assets/{gruvbox-dark-medium-DxuwyVzM.js → gruvbox-dark-medium-DsxcLuUs.js} +0 -0
- /package/.output/public/assets/{gruvbox-dark-soft-ba2fjht0.js → gruvbox-dark-soft-DQXOs_GH.js} +0 -0
- /package/.output/public/assets/{gruvbox-light-hard-DAJK2PqC.js → gruvbox-light-hard-CtHwj_cB.js} +0 -0
- /package/.output/public/assets/{gruvbox-light-medium-WRifDAJD.js → gruvbox-light-medium-CPJMdgXQ.js} +0 -0
- /package/.output/public/assets/{gruvbox-light-soft-B0dBOoVB.js → gruvbox-light-soft-C4Xh9Hc-.js} +0 -0
- /package/.output/public/assets/{haskell-BaGpmm_c.js → haskell-CaDqJkn4.js} +0 -0
- /package/.output/public/assets/{haxe-DfXTCEOz.js → haxe-Dxg-8_J7.js} +0 -0
- /package/.output/public/assets/{hcl-CbCtpSbi.js → hcl-Bjg-rMJ0.js} +0 -0
- /package/.output/public/assets/{hjson-_4-w-pHU.js → hjson-BMbeOOMg.js} +0 -0
- /package/.output/public/assets/{hlsl-DpuYn7pp.js → hlsl-D-cuwCFV.js} +0 -0
- /package/.output/public/assets/{horizon-C5RtD1fY.js → horizon-BofYY9of.js} +0 -0
- /package/.output/public/assets/{horizon-bright-pEOice34.js → horizon-bright-CFOVQsf2.js} +0 -0
- /package/.output/public/assets/{houston-A0zg9vNP.js → houston-BIBYxFpQ.js} +0 -0
- /package/.output/public/assets/{hy-t9zDXBje.js → hy-Cye3Jt7O.js} +0 -0
- /package/.output/public/assets/{imba-Bxu-TDfw.js → imba-CjkQtgD2.js} +0 -0
- /package/.output/public/assets/{ini-D-v34c8N.js → ini-BvMtfDNl.js} +0 -0
- /package/.output/public/assets/{java-DVLnIrqC.js → java-BYO3uQJZ.js} +0 -0
- /package/.output/public/assets/{javascript-Cop1kpy_.js → javascript-BsdGTPv_.js} +0 -0
- /package/.output/public/assets/{json-CTw4n7kn.js → json-Kp2u6f_f.js} +0 -0
- /package/.output/public/assets/{json5-D0XL1D5m.js → json5-BCxDPjxU.js} +0 -0
- /package/.output/public/assets/{jsonc-BBgf3TX3.js → jsonc-BV8VFjqO.js} +0 -0
- /package/.output/public/assets/{jsonl-KrKLbtB7.js → jsonl-DHrr7c-M.js} +0 -0
- /package/.output/public/assets/{jsonnet-B2ZwWMOt.js → jsonnet-xURar8mu.js} +0 -0
- /package/.output/public/assets/{jssm-ByRpI9-B.js → jssm-DtoLUQAt.js} +0 -0
- /package/.output/public/assets/{jsx-0oMUGqZj.js → jsx-CyrO086S.js} +0 -0
- /package/.output/public/assets/{kanagawa-dragon-CtPmcCMp.js → kanagawa-dragon-COwlYgQB.js} +0 -0
- /package/.output/public/assets/{kanagawa-lotus-DpOXEGCa.js → kanagawa-lotus-GZWqyq_E.js} +0 -0
- /package/.output/public/assets/{kanagawa-wave-CLVCyc-n.js → kanagawa-wave-CP4uw3DX.js} +0 -0
- /package/.output/public/assets/{kdl-6FPPEH4H.js → kdl-DGo2N7N5.js} +0 -0
- /package/.output/public/assets/{kotlin-D4L3Nd2D.js → kotlin-Cm4W8Bbs.js} +0 -0
- /package/.output/public/assets/{kusto-D-mmc07O.js → kusto-DQ22_tcT.js} +0 -0
- /package/.output/public/assets/{laserwave-7fEj4XGb.js → laserwave-DfABGYsD.js} +0 -0
- /package/.output/public/assets/{lean-BMVMuP2E.js → lean-D-8a6Wwv.js} +0 -0
- /package/.output/public/assets/{less-C95PyOu0.js → less-B-qZzFKw.js} +0 -0
- /package/.output/public/assets/{light-plus-DHI2dh3p.js → light-plus-DS_rmE1N.js} +0 -0
- /package/.output/public/assets/{llvm-Dy3qORTl.js → llvm-Ch-k6TUk.js} +0 -0
- /package/.output/public/assets/{log-BQop7fzg.js → log-BGwbCG2S.js} +0 -0
- /package/.output/public/assets/{logo-DKtnYmrp.js → logo-DHGHbFWy.js} +0 -0
- /package/.output/public/assets/{luau-Dha4KG0q.js → luau-qsvm_nYh.js} +0 -0
- /package/.output/public/assets/{make-DfmS6buu.js → make-Dlfjp_Q8.js} +0 -0
- /package/.output/public/assets/{markdown-BaI9LyM4.js → markdown-COh4ruD_.js} +0 -0
- /package/.output/public/assets/{material-theme-Dm6ETY8i.js → material-theme-Ccrl1jie.js} +0 -0
- /package/.output/public/assets/{material-theme-darker-BeyjmM5Z.js → material-theme-darker-CcOH0iHe.js} +0 -0
- /package/.output/public/assets/{material-theme-lighter-CCOYYzKL.js → material-theme-lighter-DoKpC7NM.js} +0 -0
- /package/.output/public/assets/{material-theme-ocean-CUtPiiX3.js → material-theme-ocean-BcvBZHgH.js} +0 -0
- /package/.output/public/assets/{material-theme-palenight-2L4zMwIM.js → material-theme-palenight-DIL4EAzl.js} +0 -0
- /package/.output/public/assets/{matlab-BT79Cq_j.js → matlab-CBqMuw7w.js} +0 -0
- /package/.output/public/assets/{mdx-CxGBwLNt.js → mdx-BjoJxHxW.js} +0 -0
- /package/.output/public/assets/{mermaid-DLf3axBN.js → mermaid-DjAh2yR5.js} +0 -0
- /package/.output/public/assets/{min-dark-B8TUPGHg.js → min-dark-CbwghdE5.js} +0 -0
- /package/.output/public/assets/{min-light-BDOoBxcA.js → min-light-_F39d_94.js} +0 -0
- /package/.output/public/assets/{mipsasm-DXuU_0cI.js → mipsasm-DA1H0O78.js} +0 -0
- /package/.output/public/assets/{mojo-1Omp2pIo.js → mojo-BVgjRjTn.js} +0 -0
- /package/.output/public/assets/{monokai-E_VBmXGZ.js → monokai-CxgvaWkX.js} +0 -0
- /package/.output/public/assets/{moonbit-DZzq699o.js → moonbit-tKY94ZOM.js} +0 -0
- /package/.output/public/assets/{move-DxDAOJVd.js → move-B5WspEjG.js} +0 -0
- /package/.output/public/assets/{narrat-CxDcPPb9.js → narrat-CDPRStf_.js} +0 -0
- /package/.output/public/assets/{nextflow-groovy-wvmJO4hi.js → nextflow-groovy-1GYTZoD5.js} +0 -0
- /package/.output/public/assets/{night-owl-DefhalNX.js → night-owl-CCydx7ZR.js} +0 -0
- /package/.output/public/assets/{night-owl-light-byb3AbEn.js → night-owl-light-CLM7UUPY.js} +0 -0
- /package/.output/public/assets/{nix-DsFTDHWT.js → nix-DXFN4IwW.js} +0 -0
- /package/.output/public/assets/{nord-D5rQzHT-.js → nord-CiCWZ1de.js} +0 -0
- /package/.output/public/assets/{nushell-BQ_rO0AM.js → nushell-Ck9o2qOx.js} +0 -0
- /package/.output/public/assets/{objective-c-BMq6JT_m.js → objective-c-4koxci9E.js} +0 -0
- /package/.output/public/assets/{objective-cpp-DRwojuGv.js → objective-cpp-BPFAgSN9.js} +0 -0
- /package/.output/public/assets/{ocaml-e4_gKO6E.js → ocaml-BdlBLhZV.js} +0 -0
- /package/.output/public/assets/{odin-mdTPwYOg.js → odin-BcGOLCqZ.js} +0 -0
- /package/.output/public/assets/{one-dark-pro-DxXww9jg.js → one-dark-pro-DEMdTgiO.js} +0 -0
- /package/.output/public/assets/{one-light-D9c03w7t.js → one-light-Cmpe9X1u.js} +0 -0
- /package/.output/public/assets/{openscad-D2aTdNfr.js → openscad-DBveSHYE.js} +0 -0
- /package/.output/public/assets/{pascal-D4n_G8vj.js → pascal-DxOVE99u.js} +0 -0
- /package/.output/public/assets/{pierre-dark-CizZ1Z5z.js → pierre-dark-DIUCKU6U.js} +0 -0
- /package/.output/public/assets/{pierre-light-CHMWfAMe.js → pierre-light-DVO2KPlh.js} +0 -0
- /package/.output/public/assets/{pkl-DcjhAp0L.js → pkl-pIvtf7Vu.js} +0 -0
- /package/.output/public/assets/{plastic-uOsw7z1x.js → plastic-Dvdf8qVN.js} +0 -0
- /package/.output/public/assets/{plsql-BSy3Ag0J.js → plsql-d50MFTFK.js} +0 -0
- /package/.output/public/assets/{po-Be96RYkA.js → po-CboxWwYg.js} +0 -0
- /package/.output/public/assets/{poimandres-CyO4HORD.js → poimandres-DHgQGH4M.js} +0 -0
- /package/.output/public/assets/{polar-BmhMKWum.js → polar-DNp7Oek8.js} +0 -0
- /package/.output/public/assets/{postcss-BTQso3H9.js → postcss-LpmI6XQv.js} +0 -0
- /package/.output/public/assets/{powerquery-DVyQv3M2.js → powerquery-BNCl8Uwz.js} +0 -0
- /package/.output/public/assets/{powershell-BmtCGJVD.js → powershell-CZ9J0XuS.js} +0 -0
- /package/.output/public/assets/{prisma-CCFA9rEj.js → prisma-AELUiJCl.js} +0 -0
- /package/.output/public/assets/{prolog-DWGEEo78.js → prolog-BlqwejRD.js} +0 -0
- /package/.output/public/assets/{proto-C3eop1kM.js → proto-DRQC3swD.js} +0 -0
- /package/.output/public/assets/{puppet-C0_7Nv5A.js → puppet-DBKR8MlH.js} +0 -0
- /package/.output/public/assets/{purescript-Bv-B8yRw.js → purescript-DItLzxZS.js} +0 -0
- /package/.output/public/assets/{python-CKg5r0C3.js → python-D9t_ETu8.js} +0 -0
- /package/.output/public/assets/{qmldir-Cqfb4Lox.js → qmldir-DP_KD1nk.js} +0 -0
- /package/.output/public/assets/{qss-Csho9BH8.js → qss-CL02opOd.js} +0 -0
- /package/.output/public/assets/{r-UcxRcvcA.js → r-DmmrCFmB.js} +0 -0
- /package/.output/public/assets/{racket-D8-uWeQH.js → racket-K0frLTWj.js} +0 -0
- /package/.output/public/assets/{raku-Cj4JSa8p.js → raku-DwgLlPg9.js} +0 -0
- /package/.output/public/assets/{red-z4H4llUY.js → red-DzDu-aXc.js} +0 -0
- /package/.output/public/assets/{reg-DXGFiJSl.js → reg-B_y3c7di.js} +0 -0
- /package/.output/public/assets/{regexp-3-A0406L.js → regexp--eMB47Xx.js} +0 -0
- /package/.output/public/assets/{rel-CunnVTBK.js → rel-CT65ywJp.js} +0 -0
- /package/.output/public/assets/{riscv-C8BcOCkS.js → riscv-Qv5W2vIg.js} +0 -0
- /package/.output/public/assets/{ron-DiDyR9oa.js → ron-cRHu9zPp.js} +0 -0
- /package/.output/public/assets/{rose-pine-BADquuIH.js → rose-pine-DFmTJHIJ.js} +0 -0
- /package/.output/public/assets/{rose-pine-dawn-BLcEeBoh.js → rose-pine-dawn-YIuK9wUm.js} +0 -0
- /package/.output/public/assets/{rose-pine-moon-BK_tLY1Y.js → rose-pine-moon-BYEHfkUB.js} +0 -0
- /package/.output/public/assets/{rosmsg-CHmL1Uyj.js → rosmsg-_L1z4wrx.js} +0 -0
- /package/.output/public/assets/{rust-DjJFInu3.js → rust-BA5wQ_EY.js} +0 -0
- /package/.output/public/assets/{sass-D3xZ5o-v.js → sass-sd__ov8V.js} +0 -0
- /package/.output/public/assets/{scala-B0IRml5w.js → scala--cVG4U7H.js} +0 -0
- /package/.output/public/assets/{scheme-BhwcV3Av.js → scheme-D6Q1O-kY.js} +0 -0
- /package/.output/public/assets/{sdbl-BmWYR-pI.js → sdbl-jB0DUrL_.js} +0 -0
- /package/.output/public/assets/{shellscript-DaVPunOM.js → shellscript-DyWRuzkj.js} +0 -0
- /package/.output/public/assets/{slack-dark-DOnVms5P.js → slack-dark-DHhAlQBa.js} +0 -0
- /package/.output/public/assets/{slack-ochin-DcRTft4q.js → slack-ochin-PZXbcZaN.js} +0 -0
- /package/.output/public/assets/{smalltalk-DVQuUMII.js → smalltalk-C7VkdTlv.js} +0 -0
- /package/.output/public/assets/{snazzy-light-x9CLJ1W9.js → snazzy-light-CPc_Qts9.js} +0 -0
- /package/.output/public/assets/{solarized-dark-BB1sh-pe.js → solarized-dark-DCCfKtTh.js} +0 -0
- /package/.output/public/assets/{solarized-light-9-RPS998.js → solarized-light-B84T-R9X.js} +0 -0
- /package/.output/public/assets/{solidity-gQ4WXILB.js → solidity-DVsDPpDS.js} +0 -0
- /package/.output/public/assets/{splunk-OB48_RcD.js → splunk-A-BwP6Va.js} +0 -0
- /package/.output/public/assets/{sql-CrTmZCMa.js → sql-CRzu7iKx.js} +0 -0
- /package/.output/public/assets/{ssh-config-DA9YMRGV.js → ssh-config-CFPv6mTy.js} +0 -0
- /package/.output/public/assets/{stylus-sKwvsUaC.js → stylus-CUf3IESt.js} +0 -0
- /package/.output/public/assets/{swift-C72NbAtg.js → swift-CSiiYB_Q.js} +0 -0
- /package/.output/public/assets/{synthwave-84-eJ9uRN_S.js → synthwave-84-uJp1j2Jd.js} +0 -0
- /package/.output/public/assets/{system-verilog-CnWMF7Nq.js → system-verilog-rMjKy-O9.js} +0 -0
- /package/.output/public/assets/{systemd-DMzItW5N.js → systemd-R-KDM4-t.js} +0 -0
- /package/.output/public/assets/{talonscript-DopQCWDL.js → talonscript-D666vCtm.js} +0 -0
- /package/.output/public/assets/{tasl-C28SYKbq.js → tasl-68cbBocU.js} +0 -0
- /package/.output/public/assets/{tcl-DHq7zmoF.js → tcl-Y39dJ_pX.js} +0 -0
- /package/.output/public/assets/{terraform-CogS1YKX.js → terraform-BF7wAo-b.js} +0 -0
- /package/.output/public/assets/{tokyo-night-B9N7LyrF.js → tokyo-night-EeABtN82.js} +0 -0
- /package/.output/public/assets/{toml-BH_iPsgK.js → toml-BrMFN1JF.js} +0 -0
- /package/.output/public/assets/{tsv-BIkdBZX1.js → tsv-Dp2l5v7f.js} +0 -0
- /package/.output/public/assets/{tsx-BjkCKOtw.js → tsx-CQqypS0k.js} +0 -0
- /package/.output/public/assets/{turtle-CqNXyJWZ.js → turtle-_N1aDtpV.js} +0 -0
- /package/.output/public/assets/{typescript-BoHeP9q1.js → typescript-CPmDkqmE.js} +0 -0
- /package/.output/public/assets/{typespec-CQ9LYD_e.js → typespec-ghgF2GAI.js} +0 -0
- /package/.output/public/assets/{typst-T-Fsk-Sv.js → typst-DP_izaNK.js} +0 -0
- /package/.output/public/assets/{v-BhMEOw9x.js → v-CdNC_Wok.js} +0 -0
- /package/.output/public/assets/{vala-DzajMnwt.js → vala-Bu4pYkLC.js} +0 -0
- /package/.output/public/assets/{vb-7Xr8dEYW.js → vb-u84IyWSS.js} +0 -0
- /package/.output/public/assets/{verilog-AvXtwZir.js → verilog-BC33pi7Z.js} +0 -0
- /package/.output/public/assets/{vesper-CtgQQ2sf.js → vesper-7-XtS0Kg.js} +0 -0
- /package/.output/public/assets/{vhdl-BHu0zg1P.js → vhdl-BBxTOQe0.js} +0 -0
- /package/.output/public/assets/{viml-Di0QpLfC.js → viml-X_r-ivXA.js} +0 -0
- /package/.output/public/assets/{vitesse-black-jXdfyqgD.js → vitesse-black-DRdlY-cW.js} +0 -0
- /package/.output/public/assets/{vitesse-dark-B88PxG1r.js → vitesse-dark-Bz0hOFHJ.js} +0 -0
- /package/.output/public/assets/{vitesse-light-BXxZh2iV.js → vitesse-light-7kCLd0yn.js} +0 -0
- /package/.output/public/assets/{vyper-C3R5yXgx.js → vyper-E7qIwMXy.js} +0 -0
- /package/.output/public/assets/{wasm-D_MQmneJ.js → wasm-BqG9CUph.js} +0 -0
- /package/.output/public/assets/{wasm-Chsuwt1A.js → wasm-C18OEcCL.js} +0 -0
- /package/.output/public/assets/{wenyan-BonVcr2i.js → wenyan-siXAC4el.js} +0 -0
- /package/.output/public/assets/{wgsl-D59WYmNq.js → wgsl-BJQt8Uld.js} +0 -0
- /package/.output/public/assets/{wikitext-ariTI2Wk.js → wikitext-Ci0ePJmf.js} +0 -0
- /package/.output/public/assets/{wit-EA4fa3Dt.js → wit-BdDJ7geN.js} +0 -0
- /package/.output/public/assets/{wolfram-DDp7LhyU.js → wolfram-Bi-O1IUM.js} +0 -0
- /package/.output/public/assets/{xterm-CCMwI7sy.js → xterm-TTe2Bv9Z.js} +0 -0
- /package/.output/public/assets/{yaml-BTD1XHJG.js → yaml-DgkO7CC2.js} +0 -0
- /package/.output/public/assets/{zenscript-4WaROUyc.js → zenscript-CnkrxCBw.js} +0 -0
- /package/.output/public/assets/{zig-CJoLJGwV.js → zig-CgMsxF9-.js} +0 -0
|
@@ -0,0 +1,1831 @@
|
|
|
1
|
+
import{r as e}from"./rolldown-runtime-S-ySWqyJ.js";import{At as t,D as n,Dt as r,E as i,Et as a,It as o,Lt as s,Mr as c,Pt as l,T as u,Tn as d,Tt as f,Wt as p,ct as m,di as h,dr as g,kt as _,li as v,si as y,st as b,ti as x,wr as S,wt as C}from"./preload-helper-Csz9R64u.js";import{$ as w,$t as T,An as E,B as D,Bt as O,C as k,Cn as A,D as j,E as M,En as N,Fn as P,G as F,Gt as I,H as L,Ht as R,In as z,It as B,J as V,Jn as ee,Jt as H,K as U,Kn as te,Kt as ne,L as re,Ln as W,Lt as G,M as ie,Mn as ae,Mt as oe,N as se,Nn as ce,Nt as le,On as ue,Ot as de,P as K,Pn as fe,Pt as pe,Q as me,R as he,Rt as ge,S as _e,Sn as ve,Tt as ye,U as be,Ut as xe,V as Se,Vt as Ce,W as we,Wt as Te,X as Ee,Xt as De,Y as Oe,Yt as ke,Z as Ae,Zt as je,_ as Me,_t as Ne,a as Pe,an as Fe,at as Ie,bn as Le,bt as Re,c as ze,cn as Be,d as Ve,dt as He,en as Ue,et as We,f as Ge,fn as Ke,ft as qe,gt as Je,i as Ye,in as Xe,it as Ze,j as Qe,jn as $e,jt as et,k as tt,kn as nt,l as rt,ln as it,lt as at,mt as ot,n as st,nn as ct,nt as lt,o as ut,on as dt,ot as ft,pn as pt,q as mt,qn as ht,qt as gt,r as _t,rt as vt,s as yt,sn as bt,st as xt,t as St,tn as Ct,tt as wt,u as Tt,un as Et,v as Dt,vt as Ot,wn as kt,x as At,xn as jt,xt as Mt,y as Nt,yt as Pt,z as Ft,zt as It}from"./PatchDiff-SN-mXa3p.js";import{A as Lt,C as Rt,D as zt,E as Bt,F as Vt,I as Ht,L as Ut,M as Wt,N as Gt,P as Kt,R as qt,S as Jt,T as Yt,b as Xt,g as Zt,i as Qt,it as $t,r as en,t as tn,tt as nn,v as rn,x as an,y as on,z as sn}from"./query-keys-C9jMaRnO.js";import{t as cn}from"./plus-B1rJPgNv.js";import{n as ln,r as un,s as dn,u as fn}from"./index-FOqZaR4L.js";var q=e(h(),1);function pn(e,t){let n=dn(t),r=n.getQueryCache();return q.useSyncExternalStore(q.useCallback(e=>r.subscribe(fn.batchCalls(e)),[r]),()=>n.isFetching(e),()=>n.isFetching(e))}var mn=o(`arrow-up-right`,[[`path`,{d:`M7 7h10v10`,key:`1tivn9`}],[`path`,{d:`M7 17 17 7`,key:`1vkiza`}]]),hn=o(`external-link`,[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]),gn=o(`file-diff`,[[`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:`M9 10h6`,key:`9gxzsh`}],[`path`,{d:`M12 13V7`,key:`h0r20n`}],[`path`,{d:`M9 17h6`,key:`r8uit2`}]]),_n=o(`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`}]]),vn=o(`minimize-2`,[[`path`,{d:`m14 10 7-7`,key:`oa77jy`}],[`path`,{d:`M20 10h-6V4`,key:`mjg0md`}],[`path`,{d:`m3 21 7-7`,key:`tjx5ai`}],[`path`,{d:`M4 14h6v6`,key:`rmj7iw`}]]),yn=o(`minus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}]]),bn=o(`panel-left-close`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}],[`path`,{d:`m16 15-3-3 3-3`,key:`14y99z`}]]),xn=o(`panel-left-open`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}],[`path`,{d:`m14 9 3 3-3 3`,key:`8010ee`}]]),Sn=o(`tag`,[[`path`,{d:`M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z`,key:`vktsd0`}],[`circle`,{cx:`7.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`kqv944`}]]),Cn=o(`trash-2`,[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]]),wn=o(`undo-2`,[[`path`,{d:`M9 14 4 9l5-5`,key:`102s5s`}],[`path`,{d:`M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11`,key:`f3b9sd`}]]),J=y(),Y=v();function Tn(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(`nav`,{"aria-label":`breadcrumb`,"data-slot":`breadcrumb`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function En(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(`flex flex-wrap items-center gap-1.5 text-sm wrap-break-word text-muted-foreground`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(`ol`,{"data-slot":`breadcrumb-list`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Dn(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(`inline-flex items-center gap-1`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(`li`,{"data-slot":`breadcrumb-item`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function On(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(`font-normal text-foreground`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(`span`,{"data-slot":`breadcrumb-page`,role:`link`,"aria-disabled":`true`,"aria-current":`page`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function kn(e){let t=(0,J.c)(12),n,r,i;t[0]===e?(n=t[1],r=t[2],i=t[3]):({children:n,className:r,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i);let a;t[4]===r?a=t[5]:(a=s(`[&>svg]:size-3.5`,r),t[4]=r,t[5]=a);let o;t[6]===n?o=t[7]:(o=n??(0,Y.jsx)(P,{}),t[6]=n,t[7]=o);let c;return t[8]!==i||t[9]!==a||t[10]!==o?(c=(0,Y.jsx)(`li`,{"data-slot":`breadcrumb-separator`,role:`presentation`,"aria-hidden":`true`,className:a,...i,children:o}),t[8]=i,t[9]=a,t[10]=o,t[11]=c):c=t[11],c}var An={astro:`light-dark(#a631be, #d568ea)`,babel:`light-dark(#d5a910, #ffd452)`,bash:`light-dark(#199f43, #5ecc71)`,biome:`light-dark(#1a85d4, #69b1ff)`,bootstrap:`light-dark(#693acf, #9d6afb)`,browserslist:`light-dark(#d5a910, #ffd452)`,bun:`light-dark(#d32a61, #ff678d)`,claude:`light-dark(#d47628, #ffa359)`,css:`light-dark(#693acf, #9d6afb)`,database:`light-dark(#a631be, #d568ea)`,default:`light-dark(#84848a, #adadb1)`,docker:`light-dark(#1a85d4, #69b1ff)`,eslint:`light-dark(#693acf, #9d6afb)`,git:`light-dark(#ff8c5b, #d5512f)`,go:`light-dark(#1ca1c7, #68cdf2)`,graphql:`light-dark(#d32a61, #ff678d)`,html:`light-dark(#d47628, #ffa359)`,image:`light-dark(#d32a61, #ff678d)`,javascript:`light-dark(#d5a910, #ffd452)`,json:`light-dark(#d47628, #ffa359)`,markdown:`light-dark(#199f43, #5ecc71)`,mcp:`light-dark(#17a5af, #64d1db)`,npm:`light-dark(#d52c36, #ff6762)`,oxc:`light-dark(#1ca1c7, #68cdf2)`,postcss:`light-dark(#d52c36, #ff6762)`,prettier:`light-dark(#17a5af, #64d1db)`,python:`light-dark(#1a85d4, #69b1ff)`,react:`light-dark(#1ca1c7, #68cdf2)`,ruby:`light-dark(#d52c36, #ff6762)`,rust:`light-dark(#d47628, #ffa359)`,sass:`light-dark(#d32a61, #ff678d)`,svg:`light-dark(#d47628, #ffa359)`,svelte:`light-dark(#d52c36, #ff6762)`,svgo:`light-dark(#199f43, #5ecc71)`,swift:`light-dark(#d47628, #ffa359)`,table:`light-dark(#17a5af, #64d1db)`,tailwind:`light-dark(#1ca1c7, #68cdf2)`,terraform:`light-dark(#693acf, #9d6afb)`,text:`light-dark(#84848a, #adadb1)`,typescript:`light-dark(#1a85d4, #69b1ff)`,vite:`light-dark(#a631be, #d568ea)`,vscode:`light-dark(#1a85d4, #69b1ff)`,vue:`light-dark(#199f43, #5ecc71)`,wasm:`light-dark(#693acf, #9d6afb)`,webpack:`light-dark(#1a85d4, #69b1ff)`,yml:`light-dark(#d52c36, #ff6762)`,zig:`light-dark(#d47628, #ffa359)`,zip:`light-dark(#d47628, #ffa359)`},jn=`<svg data-icon-sprite aria-hidden="true" width="0" height="0">
|
|
2
|
+
<symbol id="file-tree-icon-chevron" viewBox="0 0 16 16">
|
|
3
|
+
<path d="M3.47 5.47a.75.75 0 0 1 1.06 0L8 8.94l3.47-3.47a.75.75 0 1 1 1.06 1.06l-4 4a.75.75 0 0 1-1.06 0l-4-4a.75.75 0 0 1 0-1.06" fill="currentcolor"/>
|
|
4
|
+
</symbol>
|
|
5
|
+
<symbol id="file-tree-icon-dot" viewBox="0 0 6 6">
|
|
6
|
+
<circle cx="3" cy="3" r="3" />
|
|
7
|
+
</symbol>
|
|
8
|
+
<symbol id="file-tree-icon-file" viewBox="0 0 16 16">
|
|
9
|
+
<path fill="currentColor" d="M8 1v3a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1z" class="bg" opacity=".5"/>
|
|
10
|
+
<path fill="currentColor" d="M9.5 1a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z" class="fg"/>
|
|
11
|
+
</symbol>
|
|
12
|
+
<symbol id="file-tree-icon-lock" viewBox="0 0 16 16">
|
|
13
|
+
<path fill="currentcolor" d="M4 5.336V4a4 4 0 1 1 8 0v1.336c1.586.54 2 1.843 2 4.664v1c0 4.118-.883 5-5 5H7c-4.117 0-5-.883-5-5v-1c0-2.821.414-4.124 2-4.664M5.5 4v1.054Q6.166 4.998 7 5h2q.834-.002 1.5.054V4a2.5 2.5 0 0 0-5 0m-2 6v1c0 .995.055 1.692.167 2.193.107.483.246.686.35.79s.307.243.79.35c.5.112 1.198.167 2.193.167h2c.995 0 1.692-.055 2.193-.166.483-.108.686-.247.79-.35.104-.105.243-.308.35-.791.112-.5.167-1.198.167-2.193v-1c0-.995-.055-1.692-.166-2.193-.108-.483-.247-.686-.35-.79-.105-.104-.308-.243-.791-.35C10.693 6.555 9.995 6.5 9 6.5H7c-.995 0-1.692.055-2.193.167-.483.107-.686.246-.79.35s-.243.307-.35.79C3.555 8.307 3.5 9.005 3.5 10" />
|
|
14
|
+
</symbol>
|
|
15
|
+
<symbol id="file-tree-icon-ellipsis" viewBox="0 0 16 16">
|
|
16
|
+
<path d="M5 8.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0M9.5 8.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0M14 8.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0" />
|
|
17
|
+
</symbol>
|
|
18
|
+
</svg>`,Mn=`<symbol id="file-tree-builtin-astro" viewBox="0 0 16 16">
|
|
19
|
+
<path fill="currentColor" d="M6.08 13.92c-.63-.57-.81-1.79-.55-2.67.45.56 1.08.73 1.73.83 1 .15 1.99.1 2.92-.37l.32-.19q.13.38.08.78a2.1 2.1 0 0 1-.9 1.5q-.3.24-.61.43c-.64.44-.81.95-.57 1.69l.02.08a1.7 1.7 0 0 1-.74-.64 2 2 0 0 1-.3-.98q0-.27-.02-.52-.07-.61-.61-.62a.7.7 0 0 0-.75.6z" class="bg" opacity=".6"/>
|
|
20
|
+
<path fill="currentColor" d="M2.5 11.1s1.86-.9 3.72-.9l1.4-4.39c.05-.21.2-.36.38-.36s.33.15.38.36l1.4 4.38c2.2 0 3.72.92 3.72.92l-3.16-8.69q-.13-.4-.45-.42H6.11q-.3.02-.45.42z" class="fg"/>
|
|
21
|
+
</symbol>`,Nn=`<symbol id="file-tree-builtin-babel" viewBox="0 0 16 16">
|
|
22
|
+
<path fill="currentColor" fill-rule="evenodd" d="M9.49.5q1.92.05 2.66.54 1.27.6 1.35 1.52v.23a4 4 0 0 1-.53 1.9l-1.38 1.24q-.74.38-.72.63c.77.82 1.33 1.29.85 2.42q-.47 1.1-2.04 2.28c-.5.32-1.88 1.35-2.96 1.86-1.64.77-3.1 1.4-4.65 1.89-.51.16-1.5.16-1.5.16L.5 15A76 76 0 0 0 5.76 3.49q-.1-.08-.1-.2.1 0 .32-.35l-.03-.09q-1.17.39-2.38 1.3l-.13.03q0-.1-.21-.16-.46.31-.82.7l-.13-.19.16-.06-.03-.16-.34.29L2 4.5q.36-.48.72-.54l.04-.1V3.8q.16 0 .15-.06l.13-.06a6 6 0 0 0 1.13-.9v-.03H4.1l-.12.07q0-.1-.1-.1l-.15.07-.04-.1q.93-.52 1.63-1.05Q7.89.65 9.5.5M8.46 7.83l-.32.04c-1.31.54-2.31.82-2.91.88a71 71 0 0 0-2.2 4.54h.07q.58-.04 3.04-1.42.13 0 1.66-1.05L9.18 9.7v.03q.45-.2.81-1.3v-.2q-.5-.46-1.53-.4m.28-5.75c-.5.1-.75.19-.72.38l-1.16 2.6q-.17.1-.34.95-.3.48-.25.77v.1l.22.05A15 15 0 0 1 8.86 6c1.1-.71 2.12-1.38 2.8-2.54q.24-.33.21-.54-.02-.33-.4-.54c-.54 0-1.07-.34-1.63-.28l-.94-.03z" clip-rule="evenodd"/>
|
|
23
|
+
</symbol>`,Pn=`<symbol id="file-tree-builtin-bash" viewBox="0 0 16 16">
|
|
24
|
+
<path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
|
|
25
|
+
<path fill="currentColor" d="M11.5 11a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1zM7 6.75C7 6.42 6.64 6 6 6s-1 .42-1 .75q-.01.25.22.41.26.21.89.35.74.14 1.28.53c.37.29.61.7.61 1.21 0 .87-.68 1.5-1.5 1.7v.55a.5.5 0 0 1-1 0v-.56c-.82-.18-1.5-.82-1.5-1.69a.5.5 0 0 1 1 0c0 .33.36.75 1 .75s1-.42 1-.75q.01-.25-.22-.41a2 2 0 0 0-.89-.35q-.74-.14-1.28-.53A1.5 1.5 0 0 1 4 6.75c0-.87.68-1.5 1.5-1.7V4.5a.5.5 0 0 1 1 0v.56c.82.18 1.5.82 1.5 1.69a.5.5 0 0 1-1 0" class="fg-stroke"/>
|
|
26
|
+
</symbol>`,Fn=`<symbol id="file-tree-builtin-biome" viewBox="0 0 16 16">
|
|
27
|
+
<path fill="currentColor" d="M8 2 4.88 7.35a7 7 0 0 1 3.7-.13l1.04.25-.99 4.16-1.05-.25a2.7 2.7 0 0 0-3.07 1.45l-.98-.47a4 4 0 0 1 1.07-1.31 3.8 3.8 0 0 1 3.23-.71l.5-2.08a6 6 0 0 0-5.07 1.12A5.9 5.9 0 0 0 1 14h14z"/>
|
|
28
|
+
</symbol>`,In=`<symbol id="file-tree-builtin-bootstrap" viewBox="0 0 16 16">
|
|
29
|
+
<path fill="currentColor" fill-rule="evenodd" d="M11.72 1.5A2.5 2.5 0 0 1 14.2 4q.02 1.08.3 2.09c.22.73.56 1.24 1.08 1.45.22.08.4.27.4.5s-.18.43-.4.51q-.76.34-1.08 1.45c-.2.65-.27 1.32-.3 2a2.5 2.5 0 0 1-2.48 2.5H4.25A2.6 2.6 0 0 1 1.7 12c-.04-.85-.1-1.68-.22-2.04C1.26 9.23.92 8.7.4 8.5.18 8.42 0 8.23 0 8s.18-.42.4-.5q.77-.35 1.09-1.46c.1-.36.17-1.19.2-2.04a2.6 2.6 0 0 1 2.56-2.5z" class="bg" clip-rule="evenodd" opacity=".2"/>
|
|
30
|
+
<path fill="currentColor" fill-rule="evenodd" d="M8.47 4.54c1.23 0 2.04.68 2.04 1.73 0 .73-.55 1.39-1.24 1.5v.04c.94.1 1.58.77 1.58 1.7 0 1.2-.9 1.95-2.37 1.95H5.97a.3.3 0 0 1-.2-.08.3.3 0 0 1-.08-.2V4.82a.3.3 0 0 1 .08-.2.3.3 0 0 1 .2-.08zm-1.7 6.04h1.49q1.47-.01 1.49-1.15Q9.74 8.31 8.2 8.3H6.77zm0-5.16v2.06h1.21c.93 0 1.45-.38 1.45-1.06 0-.65-.44-1-1.22-1z" class="fg" clip-rule="evenodd"/>
|
|
31
|
+
</symbol>`,Ln=`<symbol id="file-tree-builtin-browserslist" viewBox="0 0 16 16">
|
|
32
|
+
<path fill="currentColor" d="M8.88 6.96c0 3.82 3.72 4.7 5.7 3.74-.23.9-1.04 1.67-2.35 1.93-.02.4.42 1.28.82 1.63-.9.35-1.94-.12-2.51-.48a5 5 0 0 0-.32 1.87c-.68 0-1.57-1-1.8-1.37-.3.18-.85 1.15-.96 1.72a2.4 2.4 0 0 1-.81-.86 2.4 2.4 0 0 1-.3-1.15c-.38.27-1.48.95-1.99 1.18-.25-.58-.15-1.3 0-2.06-.21.12-1.8.27-2.43.12.32-.36.75-1.19.94-1.57A4.5 4.5 0 0 1 .44 10.6c.48-.22.97-.53 1.49-1.06C1.26 9.17.24 8.64 0 7.7a6 6 0 0 0 1.79-.32C1.28 7.08.44 6.15.6 5.01c.42.21 1.3.37 1.73.3a3.4 3.4 0 0 1-.25-2.75 5 5 0 0 0 1.48 1c-.08-.8.3-2.31.8-2.71.2.46.73 1.21 1.08 1.4.09-.61.87-2.06 1.57-2.25 0 .5.27 1.4.5 1.67.51-.54 2.25-1.44 3.64-1.13-.43.45-.75.61-.86.98 1.05 0 2.78.34 4.27 1.93-2.34-.89-5.69.56-5.69 3.5" class="bg" opacity=".5"/>
|
|
33
|
+
<path fill="currentColor" d="M11.21 3.59a4.1 4.1 0 0 0 2.47 2.89c.24-.22.61-.38.95-.19.76.44.2 1.26-.34 1.66l-.07.06a13 13 0 0 1-4.49 1.61l-.3-.43a10.5 10.5 0 0 0 4.13-1.31 1 1 0 0 0 .23-.25.5.5 0 0 0-.21-.69l-.15-.06a4.5 4.5 0 0 1-1.77-1.31 4.5 4.5 0 0 1-.88-1.77q.2-.12.43-.21"/>
|
|
34
|
+
<path fill="currentColor" d="M10.36 5.18a.4.4 0 0 0-.03.38c.09.2.3.3.46.23s.24-.3.15-.5l-.01-.02q.23.13.34.39a.83.83 0 0 1-.43 1.08.8.8 0 0 1-1.08-.43.83.83 0 0 1 .6-1.13"/>
|
|
35
|
+
</symbol>`,Rn=`<symbol id="file-tree-builtin-bun" viewBox="0 0 16 16">
|
|
36
|
+
<path fill="currentColor" d="M8 14c3.87 0 7-2.46 7-5.49 0-1.88-1.2-3.53-3.04-4.52q-1.1-.61-1.84-1.07C9.2 2.35 8.64 2 8 2s-1.36.45-2.31 1.03A29 29 0 0 1 4.04 4C2.2 4.98 1 6.63 1 8.51 1 11.54 4.13 14 8 14M7.18 3.88q.3-.66.3-1.37c0-.08.11-.1.13-.01.38 1.57-.53 2.35-1.2 2.61-.08.03-.12-.07-.06-.12a3 3 0 0 0 .83-1.12m1.2-.05a3 3 0 0 0-.45-1.3V2.5c-.04-.07.05-.15.1-.1 1.15 1.2.77 2.3.33 2.87-.05.05-.13 0-.11-.08q.21-.67.13-1.37m1.04-.32a3 3 0 0 0-.94-1.02v-.01c-.06-.05-.01-.16.07-.12 1.51.61 1.61 1.8 1.43 2.5l-.03.03a.07.07 0 0 1-.1-.06 3 3 0 0 0-.43-1.32m-2.97.32c-.36.3-.74.43-1.2.56q-.11 0-.1-.1a3.5 3.5 0 0 0 1.76-1.57s.09-.07.1.04c0 .18-.2.76-.56 1.07m2.89 6.36q-.13.52-.55.88a1.3 1.3 0 0 1-.75.35 1.3 1.3 0 0 1-.77-.35 1.7 1.7 0 0 1-.54-.88.13.13 0 0 1 .15-.15h2.31a.14.14 0 0 1 .15.15M6.15 8.95a1.1 1.1 0 0 1-1.39-.14A1.1 1.1 0 0 1 5.12 7a1.1 1.1 0 0 1 1.2.25 1.1 1.1 0 0 1-.17 1.69m4.96 0a1.1 1.1 0 0 1-1.4-.14 1.1 1.1 0 0 1 .37-1.8 1.1 1.1 0 0 1 1.2.25 1.1 1.1 0 0 1 .24 1.2 1 1 0 0 1-.41.5"/>
|
|
37
|
+
</symbol>`,zn=`<symbol id="file-tree-builtin-claude" viewBox="0 0 16 16">
|
|
38
|
+
<path fill="currentColor" d="M3.75 10.31 6.5 8.77l.04-.14-.04-.07h-.14l-.46-.03-1.57-.04-1.38-.07-1.33-.07-.34-.07L1 7.86l.03-.21.28-.18.4.03.89.07 1.33.08.97.06 1.43.16h.22l.03-.1-.07-.05-.06-.06-1.39-.92-1.48-.98-.79-.57-.42-.28-.2-.28-.1-.6.39-.41.52.04.12.03.52.4 1.12.86L6.2 6.04l.2.17.09-.06.01-.04-.1-.15-.76-1.46-.85-1.46-.37-.6-.1-.36a1 1 0 0 1-.06-.42l.42-.59.25-.07.6.08.22.2.36.84.58 1.3.9 1.77.29.53.14.47.04.14h.1v-.07l.07-1 .14-1.22.14-1.57.04-.45.23-.53.42-.28.36.15.28.41-.04.25-.16 1.08-.36 1.7-.21 1.14h.12l.14-.15.58-.76.97-1.2.42-.5.5-.51.32-.25h.6l.44.66-.2.68-.61.79-.52.65-.74 1-.45.8.04.05h.1l1.68-.36.9-.16 1.06-.18.5.23.05.22-.2.48-1.15.28-1.34.28-2 .46-.04.01.03.04.9.09.4.03h.94l1.77.14.46.28.27.37-.04.28-.72.37-.95-.23-2.24-.53-.76-.18h-.11v.06l.64.63L12 10.86l1.48 1.35.07.34-.18.28-.2-.03-1.29-.98-.5-.42-1.12-.95h-.07v.1l.25.38 1.37 2.05.07.63-.1.2-.36.14-.38-.08-.8-1.12-.85-1.26-.66-1.15-.07.05-.4 4.23-.19.21-.42.17-.35-.28-.2-.42.2-.87.23-1.12.18-.9.17-1.1.1-.36v-.03h-.1l-.84 1.16-1.27 1.72-1 1.07-.24.1-.42-.22.04-.39.22-.32 1.4-1.8.84-1.1.57-.64-.02-.07h-.04l-3.7 2.4-.66.09-.28-.28.03-.42.14-.14 1.12-.77z"/>
|
|
39
|
+
</symbol>`,Bn=`<symbol id="file-tree-builtin-css" viewBox="0 0 16 16">
|
|
40
|
+
<path fill="currentColor" d="M8 15c-5.76 0-7-1.24-7-7V2a1 1 0 0 1 1-1h6c5.77 0 7 1.24 7 7s-1.24 7-7 7" class="vector" opacity=".2"/>
|
|
41
|
+
<path fill="currentColor" d="M10.1 9.19h.73c.03.49.22.6 1 .6.76 0 .93-.12.93-.68 0-.52-.17-.67-.94-.85-1.38-.3-1.68-.56-1.68-1.47 0-1.05.3-1.29 1.67-1.29 1.29 0 1.57.2 1.6 1.13h-.74c-.01-.34-.17-.42-.85-.42-.77 0-.94.1-.94.58 0 .42.17.55.96.73 1.36.3 1.66.58 1.66 1.59 0 1.14-.31 1.39-1.73 1.39-1.39 0-1.69-.24-1.67-1.31m-3.9 0h.74c.03.49.21.6.99.6.76 0 .93-.12.93-.68 0-.52-.17-.67-.93-.85-1.39-.3-1.69-.56-1.69-1.47 0-1.05.3-1.29 1.67-1.29 1.3 0 1.58.2 1.6 1.13h-.73c-.02-.34-.18-.42-.85-.42-.78 0-.95.1-.95.58 0 .42.17.55.96.73 1.37.3 1.67.58 1.67 1.59 0 1.14-.32 1.39-1.74 1.39-1.38 0-1.68-.24-1.66-1.31m-1.22 0h.75c-.09 1.07-.37 1.31-1.56 1.31-1.37 0-1.68-.45-1.68-2.5 0-1.96.36-2.5 1.68-2.5 1.16 0 1.44.25 1.52 1.35h-.76c-.08-.52-.22-.64-.76-.64-.74 0-.9.33-.9 1.78 0 1.47.16 1.8.9 1.8.58 0 .74-.11.8-.6"/>
|
|
42
|
+
</symbol>`,Vn=`<symbol id="file-tree-builtin-database" viewBox="0 0 16 16">
|
|
43
|
+
<path fill="currentColor" d="M14.953 9.733a12.4 12.4 0 0 1-.244 1.936c-.207.933-.532 1.58-.996 2.044s-1.11.789-2.044.996C10.73 14.918 9.533 15 8 15s-2.73-.082-3.669-.291c-.933-.207-1.58-.532-2.044-.996s-.789-1.11-.996-2.044c-.122-.547-.2-1.182-.244-1.92q.23.364.532.667c.64.639 1.482 1.031 2.533 1.265 1.046.232 2.33.315 3.884.315 1.555 0 2.838-.083 3.884-.315 1.051-.234 1.893-.626 2.532-1.265a4 4 0 0 0 .541-.683"/>
|
|
44
|
+
<path fill="currentColor" d="M14.93 5.924c-.046.663-.118 1.24-.23 1.743-.207.932-.532 1.579-.995 2.042s-1.11.789-2.042.996c-.938.209-2.135.291-3.667.291-1.531 0-2.729-.082-3.667-.29-.932-.208-1.579-.534-2.042-.997s-.789-1.11-.996-2.042a12 12 0 0 1-.227-1.683l.016-.188a4 4 0 0 0 .5.62c.638.639 1.48 1.031 2.532 1.265 1.046.232 2.33.315 3.884.315 1.555 0 2.838-.083 3.884-.315 1.051-.234 1.893-.626 2.532-1.265.192-.192.357-.404.506-.633z"/>
|
|
45
|
+
<path fill="currentColor" d="M8 1c1.533 0 2.73.082 3.669.291.933.207 1.58.533 2.044.996.403.404.904.944.91 1.695.004.764-.509 1.318-.918 1.727-.463.463-1.11.789-2.042.996-.938.209-2.135.291-3.667.291-1.531 0-2.729-.082-3.667-.29-.932-.208-1.579-.534-2.042-.997-.406-.406-.915-.953-.915-1.71 0-.758.509-1.305.915-1.712.464-.463 1.11-.789 2.044-.996C5.27 1.082 6.467 1 8 1"/>
|
|
46
|
+
</symbol>`,Hn=`<symbol id="file-tree-builtin-default" viewBox="0 0 16 16">
|
|
47
|
+
<path fill="currentColor" d="M8 1v3a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1z" class="bg" opacity=".4"/>
|
|
48
|
+
<path fill="currentColor" d="M9.5 1a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z" class="fg"/>
|
|
49
|
+
</symbol>`,Un=`<symbol id="file-tree-builtin-docker" viewBox="0 0 16 16">
|
|
50
|
+
<path fill="currentColor" d="M15.85 6.54c-.05-.04-.45-.36-1.31-.36q-.34 0-.68.06a2.7 2.7 0 0 0-1.14-1.79l-.23-.14-.15.23a3 3 0 0 0-.4 1q-.24 1.01.26 1.84c-.4.24-1.03.3-1.17.3H.5a.5.5 0 0 0-.5.52q-.01 1.46.46 2.83.55 1.5 1.6 2.18c.79.5 2.08.79 3.54.79q.96 0 1.94-.18a8 8 0 0 0 2.55-.97 7 7 0 0 0 1.73-1.5 10 10 0 0 0 1.7-3.06h.15a2.4 2.4 0 0 0 1.8-.7 2 2 0 0 0 .47-.74l.06-.2z"/>
|
|
51
|
+
<path fill="currentColor" d="M1.48 7.36h1.4a.14.14 0 0 0 .14-.13V5.91q-.01-.12-.13-.14H1.48a.13.13 0 0 0-.13.14v1.32q.02.13.13.13m1.94 0h1.41a.14.14 0 0 0 .13-.13V5.91q-.01-.12-.13-.14h-1.4a.13.13 0 0 0-.13.14v1.32q0 .13.12.13m1.98 0h1.4q.13 0 .14-.13V5.91a.13.13 0 0 0-.14-.14H5.4q-.1.01-.12.14v1.32q0 .13.12.13m1.95 0h1.42q.1 0 .12-.13V5.91q0-.12-.12-.14H7.35q-.1.01-.12.14v1.32q.01.13.12.13M3.42 5.5h1.41c.07 0 .13-.08.13-.15V4.03a.13.13 0 0 0-.13-.14h-1.4q-.12 0-.13.14v1.31q0 .13.12.15m1.98 0h1.4c.08 0 .14-.08.14-.15V4.03q0-.13-.14-.14H5.4q-.1 0-.12.14v1.31q0 .13.12.15m1.95 0h1.42c.06 0 .12-.08.12-.15V4.03q-.01-.13-.12-.14H7.35q-.1 0-.12.14v1.31q.01.13.12.15m0-1.9h1.42q.1-.02.12-.14v-1.3Q8.88 2 8.77 2H7.35q-.1 0-.12.14v1.3q.01.13.12.14m1.97 3.78h1.4a.13.13 0 0 0 .14-.13V5.91q-.01-.12-.13-.14H9.32q-.1.01-.12.14v1.32q.01.13.12.13" opacity=".5"/>
|
|
52
|
+
</symbol>`,Wn=`<symbol id="file-tree-builtin-eslint" viewBox="0 0 16 16">
|
|
53
|
+
<path fill="currentColor" d="M11.16 6.1 8.12 4.35a.3.3 0 0 0-.24 0L4.84 6.1a.3.3 0 0 0-.12.2v3.5q0 .14.12.22l3.04 1.74q.12.08.24 0l3.04-1.74a.2.2 0 0 0 .13-.22V6.3a.3.3 0 0 0-.13-.2" opacity=".5"/>
|
|
54
|
+
<path fill="currentColor" d="m.1 7.69 3.63-6.3A.8.8 0 0 1 4.37 1h7.26c.26 0 .5.17.64.4l3.63 6.27a.8.8 0 0 1 0 .75l-3.63 6.24a.7.7 0 0 1-.64.34H4.37a.7.7 0 0 1-.64-.34L.1 8.41a.7.7 0 0 1 0-.72m3 3.02q.01.15.14.23l4.63 2.66q.13.06.26 0l4.63-2.66a.3.3 0 0 0 .14-.23V5.4a.3.3 0 0 0-.14-.23L8.13 2.52a.3.3 0 0 0-.26 0L3.24 5.17a.3.3 0 0 0-.14.23z"/>
|
|
55
|
+
</symbol>`,Gn=`<symbol id="file-tree-builtin-font" viewBox="0 0 16 16">
|
|
56
|
+
<path fill="currentColor" d="M12.3 13c-1.59 0-2.68-.99-2.68-2.5 0-1.43 1-2.34 2.88-2.35h2.16v-.83c0-1.08-.62-1.68-1.73-1.68-1.05 0-1.66.54-1.73 1.36H9.93c.09-1.43 1.06-2.48 3.05-2.48 1.75 0 3.02.95 3.02 2.68v5.66h-1.29v-1.02h-.04c-.41.66-1.16 1.16-2.37 1.16m.36-1.12c1.14 0 2-.72 2-1.74v-.96H12.6c-1.12 0-1.6.54-1.6 1.28 0 .97.8 1.42 1.66 1.42m-11.24.98H0L3.8 2h1.39l3.8 10.86H7.54l-1.08-3.2H2.5zm3.09-9.25h-.04l-1.6 4.95H6.1z"/>
|
|
57
|
+
</symbol>`,Kn=`<symbol id="file-tree-builtin-git" viewBox="0 0 16 16">
|
|
58
|
+
<path fill="currentColor" d="M14.74 7.38 8.62 1.26a.9.9 0 0 0-1.27 0L6.08 2.53l1.61 1.61a1.07 1.07 0 0 1 1.36 1.37l1.55 1.55a1.07 1.07 0 0 1 1.1 1.77 1.07 1.07 0 0 1-1.74-1.16L8.5 6.22v3.8a1.07 1.07 0 1 1-.89-.02V6.15a1.07 1.07 0 0 1-.58-1.4l-1.58-1.6-4.2 4.2a.9.9 0 0 0 0 1.27l6.12 6.12a.9.9 0 0 0 1.27 0l6.09-6.09a.9.9 0 0 0 0-1.27"/>
|
|
59
|
+
</symbol>`,qn=`<symbol id="file-tree-builtin-go" viewBox="0 0 16 16">
|
|
60
|
+
<path fill="currentColor" fill-rule="evenodd" d="M4.41 4.57A3.2 3.2 0 0 1 6.87 5q.74.49 1.08 1.29.08.12-.1.16l-1.55.4c-.14.03-.15.04-.27-.1a1 1 0 0 0-.44-.34 1.6 1.6 0 0 0-1.68.14q-.95.61-.94 1.73c0 .73.52 1.33 1.25 1.43q.95.1 1.58-.6l.25-.34h-1.8c-.19 0-.24-.12-.17-.27.12-.28.34-.76.47-1a.3.3 0 0 1 .24-.14h2.98a4 4 0 0 1 .64-1.19 4 4 0 0 1 2.6-1.52 3.5 3.5 0 0 1 2.64.46q1.13.73 1.31 2.04a3.5 3.5 0 0 1-1.06 3.09q-.93.92-2.23 1.17l-.74.08a3.5 3.5 0 0 1-2.27-.8 3 3 0 0 1-.93-1.42 4 4 0 0 1-.39.61 4 4 0 0 1-2.64 1.56 3.3 3.3 0 0 1-2.5-.6 3 3 0 0 1-1.18-2.03 3.5 3.5 0 0 1 .8-2.67 4 4 0 0 1 2.6-1.58M13.1 7.5a1.53 1.53 0 0 0-1.9-1.21q-1.3.3-1.62 1.59a1.5 1.5 0 0 0 .85 1.72q.77.33 1.52-.05a2 2 0 0 0 1.18-1.74q0-.17-.03-.3" clip-rule="evenodd"/>
|
|
61
|
+
</symbol>`,Jn=`<symbol id="file-tree-builtin-graphql" viewBox="0 0 16 16">
|
|
62
|
+
<path fill="currentColor" fill-rule="evenodd" d="M8 1a1.25 1.25 0 0 1 1.18 1.65l2.8 1.61q.33-.25.77-.26a1.25 1.25 0 0 1 .48 2.4v3.2a1.25 1.25 0 1 1-1.25 2.13l-2.8 1.62A1.25 1.25 0 0 1 8 15a1.25 1.25 0 0 1-1.18-1.65l-2.8-1.62q-.33.26-.77.27a1.25 1.25 0 0 1-.48-2.4V6.4a1.25 1.25 0 1 1 1.25-2.14l2.8-1.61A1.25 1.25 0 0 1 8 1M4.44 11.14l-.06.13 2.75 1.58a1.25 1.25 0 0 1 1.74 0l2.74-1.58-.05-.13zm3.89-7.68a1.3 1.3 0 0 1-.66 0L4.03 9.77q.37.3.45.78h7.04q.08-.48.45-.78zM4.38 4.73a1.24 1.24 0 0 1-1.02 1.76v3.02l.13.01 3.67-6.35-.03-.02zm4.46-1.56 3.67 6.35.13-.01V6.49a1.25 1.25 0 0 1-1.03-1.76L8.87 3.15z" clip-rule="evenodd"/>
|
|
63
|
+
</symbol>`,Yn=`<symbol id="file-tree-builtin-html" viewBox="0 0 16 16">
|
|
64
|
+
<path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
|
|
65
|
+
<path fill="currentColor" d="M10.48 3.76a.5.5 0 0 1 .4.58L10.6 5.8h1.14a.5.5 0 0 1 0 1h-1.32L10 9.2h1.08a.5.5 0 0 1 0 1H9.8l-.3 1.64a.5.5 0 1 1-.98-.18l.27-1.46H6.4l-.3 1.64a.5.5 0 1 1-.98-.18l.27-1.46H4.25a.5.5 0 0 1 0-1h1.32L6 6.8H4.93a.5.5 0 0 1 0-1H6.2l.3-1.64a.5.5 0 1 1 .98.18L7.2 5.8h2.4l.3-1.64a.5.5 0 0 1 .58-.4M6.58 9.2h2.4l.44-2.4h-2.4z" class="fg"/>
|
|
66
|
+
</symbol>`,Xn=`<symbol id="file-tree-builtin-image" viewBox="0 0 16 16">
|
|
67
|
+
<path fill="currentColor" d="M12.5 2A2.5 2.5 0 0 1 15 4.5v4.67l-4.05-3.54-4.08 4.08-3-2L1 10.6V4.5A2.5 2.5 0 0 1 3.5 2z" opacity=".3"/>
|
|
68
|
+
<path fill="currentColor" d="M15 10.5v1a2.5 2.5 0 0 1-2.5 2.5h-9a2.5 2.5 0 0 1-2.46-2.04L4 9l3 2 4-4zm-7-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0"/>
|
|
69
|
+
</symbol>`,Zn=`<symbol id="file-tree-builtin-javascript" viewBox="0 0 16 16">
|
|
70
|
+
<path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
|
|
71
|
+
<path fill="currentColor" d="M8.1 9.64h.95c.04.62.28.76 1.28.76s1.2-.14 1.2-.85c0-.66-.2-.85-1.2-1.07-1.79-.38-2.18-.7-2.18-1.86C8.15 5.3 8.54 5 10.31 5c1.67 0 2.04.26 2.07 1.42h-.95c-.02-.43-.23-.53-1.1-.53-1 0-1.22.14-1.22.74 0 .52.22.7 1.24.92 1.76.38 2.15.73 2.15 2 0 1.44-.4 1.75-2.24 1.75-1.8 0-2.18-.3-2.15-1.66M3.5 9.5h.98c0 .76.15.92.85.92.77 0 .94-.18.94-1.02V5.1h1v4.34c0 1.54-.35 1.87-1.92 1.87-1.55 0-1.89-.32-1.86-1.8"/>
|
|
72
|
+
</symbol>`,Qn=`<symbol id="file-tree-builtin-json" viewBox="0 0 16 16">
|
|
73
|
+
<path fill="currentColor" d="M13.25 11.5V9.75a.5.5 0 0 1 .36-.48l.55-.15a1.16 1.16 0 0 0 0-2.24l-.55-.15a.5.5 0 0 1-.36-.48V4.5a2.5 2.5 0 0 0-2.5-2.5h-.25a.5.5 0 0 0 0 1h.25a1.5 1.5 0 0 1 1.5 1.5v1.75a1.5 1.5 0 0 0 1.09 1.44l.54.15a.16.16 0 0 1 0 .32l-.54.15a1.5 1.5 0 0 0-1.09 1.44v1.75a1.5 1.5 0 0 1-1.5 1.5h-.25a.5.5 0 0 0 0 1h.25a2.5 2.5 0 0 0 2.5-2.5m-10.5 0V9.75a.5.5 0 0 0-.36-.48l-.55-.15a1.16 1.16 0 0 1 0-2.24l.55-.15a.5.5 0 0 0 .36-.48V4.5A2.5 2.5 0 0 1 5.25 2h.25a.5.5 0 0 1 0 1h-.25a1.5 1.5 0 0 0-1.5 1.5v1.75a1.5 1.5 0 0 1-1.09 1.44l-.54.15a.16.16 0 0 0 0 .32l.54.15a1.5 1.5 0 0 1 1.09 1.45v1.74a1.5 1.5 0 0 0 1.5 1.5h.25a.5.5 0 0 1 0 1h-.25a2.5 2.5 0 0 1-2.5-2.5"/>
|
|
74
|
+
</symbol>`,$n=`<symbol id="file-tree-builtin-markdown" viewBox="0 0 16 16">
|
|
75
|
+
<path fill="currentColor" d="M1 12V4h2l2 2.5L7 4h2v8H7V7.5l-2 2-2-2V12zm9-3 3 3.5L16 9h-2V4h-2v5z"/>
|
|
76
|
+
</symbol>`,er=`<symbol id="file-tree-builtin-mcp" viewBox="0 0 16 16">
|
|
77
|
+
<path fill="currentColor" d="M9.26-.04a3 3 0 0 1 2 .82 2.8 2.8 0 0 1 .8 2.35 2.9 2.9 0 0 1 2.41.8l.03.02a2.74 2.74 0 0 1 0 3.94l-5.8 5.69-.04.06-.02.07q0 .04.02.07.01.04.04.06l1.2 1.17a.55.55 0 0 1 0 .79.6.6 0 0 1-.81 0l-1.2-1.17a1.3 1.3 0 0 1 0-1.84L13.7 7.1a1.65 1.65 0 0 0 .37-1.82 2 2 0 0 0-.37-.54l-.03-.03a1.73 1.73 0 0 0-2.4 0L6.47 9.4l-.07.06a.58.58 0 0 1-.92-.18.6.6 0 0 1 .12-.6l4.85-4.76a1.65 1.65 0 0 0 0-2.36 1.73 1.73 0 0 0-2.4 0l-6.43 6.3a.6.6 0 0 1-.8 0 .55.55 0 0 1 0-.8L7.25.79a3 3 0 0 1 2-.82"/>
|
|
78
|
+
<path fill="currentColor" d="M9.26 2.19a.6.6 0 0 1 .52.34.6.6 0 0 1 0 .43l-.12.18L4.9 7.79a1.65 1.65 0 0 0 0 2.36 1.73 1.73 0 0 0 2.4 0l4.75-4.66a.58.58 0 0 1 .93.18.6.6 0 0 1-.12.61l-4.75 4.66a2.9 2.9 0 0 1-4.01 0 2.75 2.75 0 0 1-.62-3.04A3 3 0 0 1 4.1 7l4.74-4.65a.6.6 0 0 1 .4-.16"/>
|
|
79
|
+
</symbol>`,tr=`<symbol id="file-tree-builtin-nextjs" viewBox="0 0 16 16">
|
|
80
|
+
<defs>
|
|
81
|
+
<linearGradient id="a" x1="4.522" x2="14" y1="3.943" y2="16" gradientUnits="userSpaceOnUse">
|
|
82
|
+
<stop stop-color="currentColor"/>
|
|
83
|
+
<stop offset="1" stop-color="currentColor" stop-opacity="0"/>
|
|
84
|
+
</linearGradient>
|
|
85
|
+
</defs>
|
|
86
|
+
<path fill="currentColor" d="M3 2h1.522v9.09H3z"/>
|
|
87
|
+
<path fill="url(#a)" d="M4.903 2 15 15.075q-.565.5-1.195.925L4.522 3.943z"/>
|
|
88
|
+
<path fill="currentColor" d="M12.172 2h-1.508v9.094h1.508z"/>
|
|
89
|
+
</symbol>`,nr=`<symbol id="file-tree-builtin-npm" viewBox="0 0 16 16">
|
|
90
|
+
<path fill="currentColor" d="M2 1a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1z" class="vector" opacity=".2"/>
|
|
91
|
+
<path fill="currentColor" d="M10.5 13H13V3H3v10h5V5.5h2.5z"/>
|
|
92
|
+
</symbol>`,rr=`<symbol id="file-tree-builtin-oxc" viewBox="0 0 16 16">
|
|
93
|
+
<path fill="currentColor" d="M9.5 1a.5.5 0 0 1 .5.5V3h3.5a.5.5 0 0 1 .38.83L10.5 7.69v1.44q.41.04.95-.16a4 4 0 0 0 .72-.35l.04-.03h.01a.5.5 0 0 1 .67.1l2 2.5a.5.5 0 0 1 0 .62c-.76.96-3.14 2.69-6.89 2.69s-6.13-1.73-6.89-2.69a.5.5 0 0 1 0-.62l2-2.5a.5.5 0 0 1 .67-.1l.05.03.16.09q.22.13.56.26.54.2.95.16V7.69L2.12 3.83A.5.5 0 0 1 2.5 3H6V1.5a.5.5 0 0 1 .5-.5zM7 3.5a.5.5 0 0 1-.5.5H3.6l2.78 3.17a.5.5 0 0 1 .12.33v2a.5.5 0 0 1-.28.45c-.7.35-1.5.15-2.02-.05a5 5 0 0 1-.58-.26l-1.46 1.84c.82.78 2.8 2.02 5.84 2.02s5.02-1.24 5.84-2.02l-1.46-1.83a5 5 0 0 1-.58.26c-.52.2-1.33.39-2.02.04a.5.5 0 0 1-.28-.45v-2a.5.5 0 0 1 .12-.33L12.4 4H9.5a.5.5 0 0 1-.5-.5V2H7z"/>
|
|
94
|
+
</symbol>`,ir=`<symbol id="file-tree-builtin-postcss" viewBox="0 0 16 16">
|
|
95
|
+
<path fill="currentColor" d="M14.5 8a6.5 6.5 0 0 0-5.9-6.47l5.42 8.93A7 7 0 0 0 14.5 8M2.88 12A6.5 6.5 0 0 0 8 14.5c2.08 0 3.93-.98 5.12-2.5zm8.62-1h1.68L11.5 8.24zm-1-.55a4 4 0 0 1-.7.55h.7zM8 5.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5M5.5 11h.7a4 4 0 0 1-.7-.55zm-2.68 0H4.5V8.24zm3.76-6.2A4 4 0 0 1 8 4.5q.76 0 1.42.3L8 2.46zM1.5 8q0 1.31.48 2.46L7.4 1.53A6.5 6.5 0 0 0 1.5 8m14 0a7.5 7.5 0 0 1-.99 3.72l-.01.03-.02.03A7.5 7.5 0 0 1 8 15.5a7.5 7.5 0 0 1-6.5-3.75l-.01-.03A7.5 7.5 0 1 1 15.5 8"/>
|
|
96
|
+
</symbol>`,ar=`<symbol id="file-tree-builtin-prettier" viewBox="0 0 16 16">
|
|
97
|
+
<path fill="currentColor" d="M6 12v1H4.93v-1zm1-2v1H2v-1zm6-4v1h-3V6zm-1-4v1H9V2z"/>
|
|
98
|
+
<path fill="currentColor" d="M11.5 10v1H8v-1zM5 6v1H2V6zm5-2v1H9V4z" opacity=".8"/>
|
|
99
|
+
<path fill="currentColor" d="M6 14v1H2v-1zm-.5-6v1H2V8zM13 4v1h-3V4zM4.93 2v1H2V2z" opacity=".6"/>
|
|
100
|
+
<path fill="currentColor" d="M4.93 12v1H2v-1zM13 8v1H9V8zM5.5 4v1H2V4zM9 2v1H4.93V2z" opacity=".4"/>
|
|
101
|
+
</symbol>`,or=`<symbol id="file-tree-builtin-python" viewBox="0 0 16 16">
|
|
102
|
+
<path fill="currentColor" d="M8.33 8.4H10c1.16 0 1.9-.73 1.9-1.86V5.08q0-.24.25-.24h.74c.75 0 1.33.32 1.66.97q.4.73.41 1.46c.09.9.09 1.78-.24 2.67-.25.73-.75 1.3-1.58 1.46h-4.8c-.08 0-.25 0-.25.08v.4s.17.09.25.09h2.82q.34-.02.33.32v1.06c0 .56-.25.97-.75 1.13-.41.16-.83.33-1.24.4a7 7 0 0 1-2.98-.07 3 3 0 0 1-1.16-.49c-.33-.32-.58-.65-.5-1.14v-2.91c0-1.13.67-1.78 1.82-1.78q.89-.1 1.66-.08m2.32 4.86a.65.65 0 0 0-.66-.65c-.34 0-.67.33-.67.65s.33.57.67.65a.65.65 0 0 0 .66-.65" class="bg" opacity=".8"/>
|
|
103
|
+
<path fill="currentColor" d="M7.67 7.6H6c-1.16 0-1.9.73-1.9 1.86v1.46q0 .24-.25.24h-.74c-.75 0-1.33-.32-1.66-.97a3 3 0 0 1-.41-1.46 6 6 0 0 1 .24-2.67c.25-.73.75-1.3 1.58-1.46h4.8c.08 0 .25 0 .25-.08v-.4s-.17-.09-.25-.09H4.85c-.24 0-.33-.08-.33-.32V2.65c0-.56.25-.97.75-1.13.41-.16.83-.33 1.24-.4a7 7 0 0 1 2.98.07c.41.09.83.25 1.16.49.33.32.58.65.5 1.13v2.92c0 1.14-.67 1.78-1.82 1.78-.58.08-1.16.08-1.66.08M5.35 2.73c0 .33.25.65.66.65.33 0 .66-.32.66-.65 0-.32-.33-.56-.66-.64a.65.65 0 0 0-.66.64" class="fg"/>
|
|
104
|
+
</symbol>`,sr=`<symbol id="file-tree-builtin-react" viewBox="0 0 16 16">
|
|
105
|
+
<path fill="currentColor" d="M8 6.65c.73 0 1.31.6 1.31 1.35S8.73 9.35 8 9.35 6.69 8.75 6.69 8 7.27 6.65 8 6.65"/>
|
|
106
|
+
<path fill="currentColor" fill-rule="evenodd" d="M8 2.55c1.3-.99 2.59-1.34 3.5-.8.92.55 1.27 1.87 1.08 3.53C14.06 5.94 15 6.9 15 8s-.94 2.06-2.42 2.72c.19 1.65-.16 2.98-1.08 3.52-.91.55-2.2.2-3.5-.8-1.3 1-2.58 1.35-3.5.8-.91-.54-1.27-1.87-1.08-3.52C1.94 10.06 1 9.1 1 8s.94-2.06 2.42-2.72c-.19-1.66.17-2.98 1.08-3.52s2.2-.2 3.5.8M4.26 11.2c-.08 1.34.28 2.03.68 2.26s1.15.22 2.25-.52l.11-.09a12 12 0 0 1-1.24-1.39 11 11 0 0 1-1.8-.41zm7.47-.15q-.83.27-1.79.41-.6.8-1.24 1.4l.11.08c1.1.74 1.86.76 2.25.52.4-.23.76-.92.68-2.26zm-3.04.54a14 14 0 0 1-1.38 0q.34.38.69.7.35-.32.7-.7M8 5.29q-.76 0-1.47.1A13 13 0 0 0 5.07 8a14 14 0 0 0 1.46 2.62 13 13 0 0 0 2.94 0A13 13 0 0 0 10.93 8a14 14 0 0 0-1.46-2.62A13 13 0 0 0 8 5.3M4.64 9.18q-.15.5-.25.96.44.16.94.27a15 15 0 0 1-.7-1.23m6.73 0a15 15 0 0 1-.7 1.23q.5-.11.95-.27a10 10 0 0 0-.25-.96M3.44 6.26C2.27 6.86 1.87 7.53 1.87 8s.4 1.14 1.57 1.74l.13.07q.18-.88.55-1.81a12 12 0 0 1-.55-1.8q-.07.02-.13.06m8.99-.07A12 12 0 0 1 11.88 8q.36.94.55 1.8l.13-.06c1.17-.6 1.56-1.27 1.56-1.74s-.39-1.14-1.56-1.74zm-7.1-.6q-.5.11-.94.27.1.46.25.96a15 15 0 0 1 .69-1.23m5.34 0a15 15 0 0 1 .7 1.23q.14-.5.24-.96-.44-.15-.94-.27M7.18 3.06c-1.09-.74-1.85-.76-2.24-.52s-.76.92-.69 2.26l.01.15a11 11 0 0 1 1.8-.41q.6-.8 1.24-1.4zm3.88-.52c-.4-.24-1.15-.22-2.25.52l-.12.08q.65.6 1.25 1.4.96.15 1.8.41v-.14c.08-1.35-.28-2.04-.68-2.27M8 3.7a10 10 0 0 0-.7.7 14 14 0 0 1 1.4 0 10 10 0 0 0-.7-.7" clip-rule="evenodd"/>
|
|
107
|
+
</symbol>`,cr=`<symbol id="file-tree-builtin-ruby" viewBox="0 0 16 16">
|
|
108
|
+
<path fill="currentColor" fill-rule="evenodd" d="M11.04 2c.48 0 .92.23 1.18.6l2.54 3.65c.37.52.3 1.23-.15 1.69l-5.58 5.64a1.47 1.47 0 0 1-2.06 0L1.39 7.94a1.3 1.3 0 0 1-.15-1.7l2.54-3.63q.2-.3.5-.45.33-.16.68-.16zm.84 2.17a.5.5 0 0 0-.7-.05L8 6.84 4.83 4.12a.5.5 0 0 0-.65.76L6.65 7H3.5a.5.5 0 0 0 0 1h9a.5.5 0 0 0 0-1H9.35l2.48-2.12a.5.5 0 0 0 .05-.7" clip-rule="evenodd"/>
|
|
109
|
+
</symbol>`,lr=`<symbol id="file-tree-builtin-rust" viewBox="0 0 16 16">
|
|
110
|
+
<path fill="currentColor" fill-rule="evenodd" d="M8 .8a.2.2 0 0 1 .18.1l.38.6.16.02.5-.53.01-.01a.2.2 0 0 1 .33.08l.25.68.16.05.59-.43h.02a.2.2 0 0 1 .3.14l.12.71.15.08.65-.3a.2.2 0 0 1 .2.02.2.2 0 0 1 .1.18l-.03.72.12.1.71-.16a.2.2 0 0 1 .25.25l-.17.7q.06.06.1.13l.73-.03A.2.2 0 0 1 14 4a.2.2 0 0 1 .02.2l-.3.66.08.14.71.12a.2.2 0 0 1 .14.32l-.43.59.05.16.68.25a.2.2 0 0 1 .07.35l-.53.49.01.16.62.38a.2.2 0 0 1 0 .36l-.62.38-.01.16.53.5a.2.2 0 0 1-.07.34l-.68.25-.05.16.43.59a.2.2 0 0 1-.14.32l-.72.12-.07.15.3.65a.2.2 0 0 1-.02.2.2.2 0 0 1-.18.1l-.72-.03-.1.13.16.7a.2.2 0 0 1-.25.25l-.7-.17-.13.1.03.73a.2.2 0 0 1-.1.18.2.2 0 0 1-.2.02l-.66-.3-.14.08-.12.71a.2.2 0 0 1-.32.14l-.59-.43-.16.05-.25.68a.2.2 0 0 1-.34.07l-.5-.53-.16.01-.38.62a.2.2 0 0 1-.36 0l-.38-.62-.16-.01-.5.53a.2.2 0 0 1-.34-.07l-.25-.68-.16-.05-.59.43a.2.2 0 0 1-.32-.14L5 13.78l-.15-.07-.65.3a.2.2 0 0 1-.2-.02.2.2 0 0 1-.1-.18l.03-.72-.13-.1-.7.16a.2.2 0 0 1-.25-.25l.17-.7-.1-.13-.73.03a.2.2 0 0 1-.2-.3l.3-.66-.08-.14-.71-.12a.2.2 0 0 1-.14-.32l.43-.59-.05-.16-.68-.25A.2.2 0 0 1 1 9.22l.53-.5-.02-.16-.6-.38A.2.2 0 0 1 .8 8a.2.2 0 0 1 .1-.18l.6-.38.02-.16-.53-.5a.2.2 0 0 1 .07-.34l.68-.25.05-.16-.43-.59a.2.2 0 0 1 .14-.32L2.2 5l.08-.15L2 4.2a.2.2 0 0 1 .2-.3l.72.03.1-.13-.16-.7a.2.2 0 0 1 .25-.25l.7.16.13-.1-.03-.72A.2.2 0 0 1 4 2a.2.2 0 0 1 .2-.02l.65.3L5 2.2l.12-.71v-.03a.2.2 0 0 1 .32-.1l.59.41.16-.04.25-.68.01-.02A.2.2 0 0 1 6.8.99l.49.53.16-.02.38-.61.02-.02A.2.2 0 0 1 8 .79M6.8 9.45h1.26l.06.01q.03.01.03.05v1.52q0 .07-.09.06h-4.5A5.4 5.4 0 0 0 8 13.42a5.4 5.4 0 0 0 4.45-2.33h-2.42c-.36 0-.68-.5-.77-.75-.08-.22-.2-.91-.25-1.12-.15-.61-.59-.71-.78-.73H6.8zM8 2.58a5.4 5.4 0 0 0-4.07 1.85h5.74l.17.02c.23.03.6.12.96.35.34.23.83.68.83 1.4 0 .66-.55 1.16-1.08 1.5.42.33.7.53.86 1.44.04.17.34.32.62.29.29-.03.62-.16.62-.75v-.24q0-.1.07-.1h.68A5.43 5.43 0 0 0 8 2.59M2.96 6.03a5.4 5.4 0 0 0-.19 3.37h1.66V6.03zM6.8 7.06h1.66c.35 0 .77-.12.77-.47 0-.42-.55-.53-.65-.53H6.8z" clip-rule="evenodd"/>
|
|
111
|
+
</symbol>`,ur=`<symbol id="file-tree-builtin-sass" viewBox="0 0 16 16">
|
|
112
|
+
<path fill="currentColor" fill-rule="evenodd" d="M8.08 1.44c2.41-.91 4.96-.37 5.35 1.27.39 1.62-.92 3.56-2.6 4.25a5 5 0 0 1-3.26.35c-.58-.2-.92-.62-1-.85-.03-.09-.09-.24 0-.3.05-.03.08-.02.22.15s.7.6 1.75.48c2.78-.34 4.45-2.64 3.92-3.88-.37-.87-2.5-1.26-5.18.16C4.03 4.81 3.85 6.24 3.82 6.8c-.08 1.5 1.73 2.28 2.7 3.4q.04.03.07.08c.3-.12.7-.19 1.35-.2 1.58-.03 2.47 1.08 2.43 2.08-.03.78-.7 1.1-.82 1.13-.1.01-.14.02-.15-.06q-.03-.06.13-.15c.16-.09.42-.3.48-.72.05-.43-.24-1.44-1.76-1.63a3 3 0 0 0-1.33.08c.27.62.32 1.87-.29 2.83-.63 1-1.8 1.61-2.93 1.27-.37-.1-.93-.92-.45-2.05.46-1.07 2.4-2.12 2.66-2.26-.9-.83-3.08-1.95-3.4-3.65-.08-.49.13-1.65 1.46-2.98a12 12 0 0 1 4.11-2.52m-1.88 9.7c-.01.01-.9.47-1.52 1.17-.59.66-.75 1.48-.43 1.69.3.18 1-.04 1.51-.62a3 3 0 0 0 .5-.9q.2-.64.02-1.39z" clip-rule="evenodd"/>
|
|
113
|
+
</symbol>`,dr=`<symbol id="file-tree-builtin-stylelint" viewBox="0 0 16 16">
|
|
114
|
+
<path fill="currentColor" d="M4 3v3.5l1.5-1L7 15 .5 6l1-1.5L0 3l2.5-2h1zm12 0-1.5 1.5 1 1.5L9 15l1.5-9.5 1.5 1V3l.5-2h1zm-8 8.5a.5.5 0 1 1 0 1 .5.5 0 0 1 0-1m0-3a.5.5 0 1 1 0 1 .5.5 0 0 1 0-1m0-3a.5.5 0 1 1 0 1 .5.5 0 0 1 0-1"/>
|
|
115
|
+
<path fill="currentColor" d="M6.5 2.5V4l-2 1.5v-4zm5 3L9.5 4V2.5l2-1zM9 4H7V2.5h2z"/>
|
|
116
|
+
</symbol>`,fr=`<symbol id="file-tree-builtin-svelte" viewBox="0 0 16 16">
|
|
117
|
+
<path fill="currentColor" d="m3.98 3.7 3.36-2.08a4.5 4.5 0 0 1 5.9 1.23 4 4 0 0 1 .7 3.02q-.16.75-.58 1.4c.42.77.56 1.66.4 2.52a3.7 3.7 0 0 1-1.57 2.4l-.17.1-3.36 2.09a4.5 4.5 0 0 1-5.9-1.23 4 4 0 0 1-.66-1.44 4 4 0 0 1-.04-1.58 4 4 0 0 1 .58-1.4 4 4 0 0 1-.4-2.52 3.7 3.7 0 0 1 1.57-2.4zl3.36-2.08zm7.87 0a2.7 2.7 0 0 0-1.26-.95 2.7 2.7 0 0 0-1.6-.07 3 3 0 0 0-.52.2l-.16.09-3.36 2.08a2 2 0 0 0-.69.64 2 2 0 0 0-.36.86 2.3 2.3 0 0 0 .42 1.81A2.7 2.7 0 0 0 7.18 9.4q.28-.06.53-.2l.16-.09 1.28-.79.2-.09a.8.8 0 0 1 .87.31.7.7 0 0 1 .13.55.7.7 0 0 1-.24.4l-.08.05-3.36 2.08-.2.09a1 1 0 0 1-.49-.02 1 1 0 0 1-.38-.3 1 1 0 0 1-.13-.37v-.1l.01-.13-.13-.03a4 4 0 0 1-1.1-.5l-.2-.14-.18-.12-.07.18-.08.3a2.3 2.3 0 0 0 .43 1.82q.45.64 1.19.93.73.28 1.51.14l.16-.04q.27-.07.52-.2l.16-.09 3.36-2.08q.4-.25.69-.64.27-.4.36-.86a2.3 2.3 0 0 0-.42-1.82 2.7 2.7 0 0 0-1.27-.95 2.7 2.7 0 0 0-1.6-.08q-.27.07-.52.2l-.16.1-1.28.79-.2.09a1 1 0 0 1-.49-.03 1 1 0 0 1-.38-.29.7.7 0 0 1-.13-.54.7.7 0 0 1 .24-.4l.08-.06L9.33 4.4l.2-.1a.8.8 0 0 1 .87.32 1 1 0 0 1 .13.38v.22l.11.04q.6.18 1.12.5l.2.14.17.12.06-.19.08-.3a2.3 2.3 0 0 0-.42-1.81z"/>
|
|
118
|
+
</symbol>`,pr=`<symbol id="file-tree-builtin-svg" viewBox="0 0 16 16">
|
|
119
|
+
<path fill="currentColor" d="M5 7a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2z"/>
|
|
120
|
+
<path fill="currentColor" d="M6 1a5 5 0 0 1 4.58 3H7a3 3 0 0 0-3 3v3.58A5 5 0 0 1 6 1" opacity=".5"/>
|
|
121
|
+
</symbol>`,mr=`<symbol id="file-tree-builtin-svgo" viewBox="0 0 16 16">
|
|
122
|
+
<path fill="currentColor" d="M9.43 4.8A.6.6 0 1 1 9.19 6l-.56.96a1.2 1.2 0 0 1 .32 1.58l.7.53a.89.89 0 1 1-.17.22l-.7-.52a1.2 1.2 0 0 1-1.4.25l-.56.87a.75.75 0 1 1-.57-.2 1 1 0 0 1 .32.05l.56-.87a1.2 1.2 0 0 1-.4-1.24l-1.2-.47a.56.56 0 1 1 .1-.28v.02l1.2.47a1.2 1.2 0 0 1 1.56-.55l.56-.97a.6.6 0 0 1-.15-.64.6.6 0 0 1 .63-.4"/>
|
|
123
|
+
<path fill="currentColor" fill-rule="evenodd" d="M9.17 1q.16.63.27 1.26a6 6 0 0 1 1.61.67q.52-.38 1.08-.71l1.65 1.64q-.32.56-.68 1.05.48.78.72 1.67.6.09 1.18.25v2.32q-.55.15-1.11.24a6 6 0 0 1-.7 1.82q.31.44.59.91l-1.65 1.65-.85-.55a6 6 0 0 1-1.9.83q-.08.47-.2.95H6.84q-.12-.46-.2-.93a6 6 0 0 1-1.96-.81q-.39.27-.8.51l-1.65-1.65q.25-.43.53-.84a6 6 0 0 1-.75-1.9L1 9.16V6.83q.54-.14 1.09-.24a6 6 0 0 1 .77-1.74q-.33-.47-.63-.98l1.65-1.65q.54.32 1.03.68a6 6 0 0 1 1.66-.66q.1-.61.26-1.24zM7.96 3.73a4 4 0 0 0-1.74.36 4.5 4.5 0 0 0-2.3 2.3 4.4 4.4 0 0 0-.1 3.29l.03.06a4.4 4.4 0 0 0 2.4 2.47 4.4 4.4 0 0 0 3.48-.02l.03-.02a4.4 4.4 0 0 0 2.3-2.42l.06-.14a4.4 4.4 0 0 0-.2-3.4 4.4 4.4 0 0 0-2.13-2.07L9.47 4a4 4 0 0 0-1.51-.27" clip-rule="evenodd"/>
|
|
124
|
+
</symbol>`,hr=`<symbol id="file-tree-builtin-swift" viewBox="0 0 16 16">
|
|
125
|
+
<path fill="currentColor" d="M9.63 1c6.15 4.35 4.16 9.15 4.16 9.15s1.75 2.05 1.04 3.85c0 0-.72-1.26-1.93-1.26-1.17 0-1.85 1.26-4.2 1.26C3.47 14 1 9.46 1 9.46c4.71 3.22 7.93.94 7.93.94C6.8 9.12 2.29 3 2.29 3c3.93 3.47 5.63 4.39 5.63 4.39-1.01-.87-3.86-5.13-3.86-5.13C6.34 4.66 10.86 8 10.86 8c1.28-3.7-1.23-7-1.23-7"/>
|
|
126
|
+
</symbol>`,gr=`<symbol id="file-tree-builtin-table" viewBox="0 0 16 16">
|
|
127
|
+
<path fill="currentColor" d="M8 4a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1H8z" class="bg" opacity=".4"/>
|
|
128
|
+
<path fill="currentColor" d="M11.5 8a.5.5 0 0 1 .5.5v4a.5.5 0 0 1-.5.5h-7a.5.5 0 0 1-.5-.5v-4a.5.5 0 0 1 .5-.5zM5 12h2.5v-1H5zm3.5 0H11v-1H8.5zM5 10h2.5V9H5zm3.5 0H11V9H8.5zm1-9a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z" class="fg"/>
|
|
129
|
+
</symbol>`,_r=`<symbol id="file-tree-builtin-tailwind" viewBox="0 0 16 16">
|
|
130
|
+
<path fill="currentColor" fill-rule="evenodd" d="M8 4Q5.2 4 4.5 6.67q1.05-1.34 2.45-1c.53.12.91.5 1.33.9C8.98 7.23 9.77 8 11.5 8q2.8 0 3.5-2.67-1.05 1.34-2.45 1c-.53-.12-.91-.5-1.33-.9C10.52 4.77 9.73 4 8 4M4.5 8Q1.7 8 1 10.67q1.05-1.34 2.45-1c.53.12.91.5 1.33.9C5.48 11.23 6.26 12 8 12q2.8 0 3.5-2.67-1.05 1.34-2.45 1c-.53-.12-.91-.5-1.33-.9C7.02 8.77 6.24 8 4.5 8" clip-rule="evenodd"/>
|
|
131
|
+
</symbol>`,vr=`<symbol id="file-tree-builtin-terraform" viewBox="0 0 16 16">
|
|
132
|
+
<path fill="currentColor" d="M1 0v5.05l4.35 2.53V2.53zm9.18 5.34L5.83 2.82v5.05l4.35 2.53zm.47 5.06V5.34L15 2.82v5.05zm-.48 5.6-4.35-2.53V8.42l4.35 2.53z"/>
|
|
133
|
+
</symbol>`,yr=`<symbol id="file-tree-builtin-text" viewBox="0 0 16 16">
|
|
134
|
+
<path fill="currentColor" fill-rule="evenodd" d="M8 4a3 3 0 0 0 3 3h3v5.5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 2 12.5v-9A2.5 2.5 0 0 1 4.5 1H8z" class="bg" clip-rule="evenodd" opacity=".4"/>
|
|
135
|
+
<path fill="currentColor" d="M8.5 11a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1zm2-2a.5.5 0 0 1 0 1h-5a.5.5 0 0 1 0-1zm-1-8a.5.5 0 0 1 .354.146l4 4A.5.5 0 0 1 14 5.5V6h-3a2 2 0 0 1-2-2V1z"/>
|
|
136
|
+
</symbol>`,br=`<symbol id="file-tree-builtin-typescript" viewBox="0 0 16 16">
|
|
137
|
+
<path fill="currentColor" d="M8 1C2.24 1 1 2.24 1 8s1.24 7 7 7 7-1.24 7-7-1.24-7-7-7" class="bg" opacity=".2"/>
|
|
138
|
+
<path fill="currentColor" d="M8.1 9.64h.95c.04.62.28.76 1.28.76s1.2-.14 1.2-.85c0-.66-.2-.85-1.2-1.07-1.79-.38-2.18-.7-2.18-1.86C8.15 5.3 8.54 5 10.31 5c1.67 0 2.04.26 2.07 1.42h-.95c-.02-.43-.23-.53-1.1-.53-1 0-1.22.14-1.22.74 0 .52.22.7 1.24.92 1.76.38 2.15.73 2.15 2 0 1.44-.4 1.75-2.24 1.75-1.8 0-2.18-.3-2.15-1.66m-3 1.57V5.99H3.5v-.9h4.21v.9H6.1v5.22z"/>
|
|
139
|
+
</symbol>`,xr=`<symbol id="file-tree-builtin-vite" viewBox="0 0 16 16">
|
|
140
|
+
<path fill="currentColor" d="M8.57 14.87c-.18.26-.55.11-.55-.22v-3.18l-.05-.27-.13-.22-.2-.15-.24-.06H4.29c-.26 0-.4-.32-.26-.55L6.08 7c.3-.46 0-1.1-.5-1.1H1.8c-.25 0-.4-.32-.25-.56l2.65-4.2A.3.3 0 0 1 4.46 1h7.9c.26 0 .4.32.26.55l-2.05 3.23c-.29.46 0 1.1.5 1.1h3.12c.26 0 .4.34.24.57z"/>
|
|
141
|
+
</symbol>`,Sr=`<symbol id="file-tree-builtin-vscode" viewBox="0 0 16 16">
|
|
142
|
+
<path fill="currentColor" d="m5.11 9.68-2.4 1.84a.6.6 0 0 1-.75-.04l-.77-.7a.6.6 0 0 1 0-.87L3.28 8zm5.52-8.42a.51.51 0 0 1 .87.36V4.8L7.32 8 5.1 6.32z" opacity=".75"/>
|
|
143
|
+
<path fill="currentColor" d="M11.1 14.99h.03zM1.96 4.52a.6.6 0 0 1 .75-.04l8.8 6.71v3.19a.51.51 0 0 1-.88.36L1.19 6.1a.6.6 0 0 1 0-.87z" opacity=".65"/>
|
|
144
|
+
<path fill="currentColor" d="M11.62 14.91a.9.9 0 0 1-1-.17.51.51 0 0 0 .88-.36V1.62a.51.51 0 0 0-.87-.36.9.9 0 0 1 1-.17l2.87 1.39a.9.9 0 0 1 .5.8v9.44a.9.9 0 0 1-.5.8z"/>
|
|
145
|
+
</symbol>`,Cr=`<symbol id="file-tree-builtin-vue" viewBox="0 0 16 16">
|
|
146
|
+
<path fill="currentColor" d="M9.62 2.25 8 5.02 6.38 2.25H1l7 12 7-12z" opacity=".5"/>
|
|
147
|
+
<path fill="currentColor" d="M9.54 2.25 8 4.95l-1.54-2.7H4l4 7 4-7z"/>
|
|
148
|
+
</symbol>`,wr=`<symbol id="file-tree-builtin-wasm" viewBox="0 0 16 16">
|
|
149
|
+
<path fill="currentColor" d="M13 1a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2V3a2 2 0 0 1 2-2h3a2 2 0 1 0 4 0z" class="subtract" opacity=".2"/>
|
|
150
|
+
<path fill="currentColor" d="M4.64 11.4h.02l.8-3.4h.91l.73 3.45L7.88 8h.96l-1.25 5h-.97L5.9 9.6 5.1 13h-1L3 8h.98z"/>
|
|
151
|
+
<path fill="currentColor" fill-rule="evenodd" d="M13 13h-1.02l-.33-1.11H9.9L9.64 13h-.97l1.26-5h1.54zm-2.49-3.77-.42 1.84h1.32l-.49-1.84z" clip-rule="evenodd"/>
|
|
152
|
+
</symbol>`,Tr=`<symbol id="file-tree-builtin-webpack" viewBox="0 0 16 16">
|
|
153
|
+
<path fill="currentColor" d="M14.1 11.79 8.26 15v-2.5l3.64-1.94zm.4-.35V4.73l-2.14 1.2v4.3zm-12.6.35L7.74 15v-2.5L4.1 10.56zm-.4-.35V4.73l2.14 1.2v4.3zm.25-7.15 6-3.29v2.42L3.9 5.47l-.03.01zm12.5 0L8.25 1v2.42l3.85 2.05.03.01z" class="bg" opacity=".4"/>
|
|
154
|
+
<path fill="currentColor" d="m7.74 11.93-3.59-1.92v-3.8l3.6 2.02zm.52 0 3.59-1.92v-3.8l-3.6 2.02zM4.4 5.77 8 3.85l3.6 1.93L8 7.8z" class="fg"/>
|
|
155
|
+
</symbol>`,Er=`<symbol id="file-tree-builtin-yml" viewBox="0 0 16 16">
|
|
156
|
+
<path fill="currentColor" d="M7.5 2A1.5 1.5 0 0 1 9 3.5v3A1.5 1.5 0 0 1 7.5 8h-2v2A1.5 1.5 0 0 0 7 11.5v-1A1.5 1.5 0 0 1 8.5 9h5a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1-1.5 1.5h-5A1.5 1.5 0 0 1 7 13.5v-1A2.5 2.5 0 0 1 4.5 10V8h-2A1.5 1.5 0 0 1 1 6.5v-3A1.5 1.5 0 0 1 2.5 2zm1 8a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h5a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5zm-6-7a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h5a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5z"/>
|
|
157
|
+
</symbol>`,Dr=`<symbol id="file-tree-builtin-zig" viewBox="0 0 16 16">
|
|
158
|
+
<path fill="currentColor" d="m14.73 1.5-7.29 8.82h4.17l-1.73 2.04H5.76L1.27 14.5l7.3-8.91H4.39l1.73-2.05h4.12z"/>
|
|
159
|
+
<path fill="currentColor" d="M5.21 3.54 3.56 5.6h-.55v4.73h.83L2.1 12.36H1V3.54zm9.79 0v8.82h-4.3l1.74-2.04h.55V5.68h-.83l1.74-2.14z"/>
|
|
160
|
+
</symbol>`,Or=[Pn,Bn,Vn,Hn,Gn,Kn,qn,Yn,Xn,Zn,Qn,$n,er,or,cr,lr,hr,gr,yr,br,`<symbol id="file-tree-builtin-zip" viewBox="0 0 16 16">
|
|
161
|
+
<path fill="currentColor" d="M4.585 2a2 2 0 0 1 1.028.285l1.788 1.072a1 1 0 0 0 .514.143H12A2 2 0 0 1 13.935 5H0V4a2 2 0 0 1 2-2z" class="bg" opacity=".5"/>
|
|
162
|
+
<path fill="currentColor" fill-rule="evenodd" d="M14 12a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2v-1.25h1v-1H0V6h14zM9.9 8.25c-.883 0-1.9.5-1.9.5H7v1h1v1s1.017.5 1.9.5c.884 0 1.6-.672 1.6-1.5s-.716-1.5-1.6-1.5M2 9.75v1h1v-1zm2 0v1h1v-1zm2 0v1h1v-1zm-5-1v1h1v-1zm2 0v1h1v-1zm2 0v1h1v-1z" class="fg" clip-rule="evenodd"/>
|
|
163
|
+
</symbol>`],kr=[Mn,Nn,Fn,In,Ln,Rn,zn,Un,Wn,Jn,tr,nr,rr,ir,ar,sr,ur,dr,fr,pr,mr,_r,vr,xr,Sr,Cr,wr,Tr,Er,Dr];function Ar(e,t){return t.length===0?e:e.replace(`</svg>`,`\n ${t.join(`
|
|
164
|
+
`)}\n</svg>`)}var jr=Ar(jn,Or),Mr={minimal:jn,standard:jr,complete:Ar(jr,kr)},Nr={".babelrc":`babel`,".babelrc.json":`babel`,".bash_profile":`bash`,".bashrc":`bash`,".browserslistrc":`browserslist`,".dockerignore":`docker`,".eslintignore":`eslint`,".eslintrc":`eslint`,".eslintrc.cjs":`eslint`,".eslintrc.js":`eslint`,".eslintrc.json":`eslint`,".eslintrc.yaml":`eslint`,".eslintrc.yml":`eslint`,".gitattributes":`git`,".gitignore":`git`,".gitkeep":`git`,".gitmodules":`git`,".oxlintrc.json":`oxc`,".postcssrc":`postcss`,".postcssrc.json":`postcss`,".postcssrc.yaml":`postcss`,".postcssrc.yml":`postcss`,".prettierignore":`prettier`,".prettierrc":`prettier`,".prettierrc.cjs":`prettier`,".prettierrc.js":`prettier`,".prettierrc.json":`prettier`,".prettierrc.mjs":`prettier`,".prettierrc.toml":`prettier`,".prettierrc.yaml":`prettier`,".prettierrc.yml":`prettier`,".stylelintignore":`stylelint`,".stylelintrc":`stylelint`,".stylelintrc.cjs":`stylelint`,".stylelintrc.js":`stylelint`,".stylelintrc.json":`stylelint`,".stylelintrc.mjs":`stylelint`,".stylelintrc.yaml":`stylelint`,".stylelintrc.yml":`stylelint`,".terraform.lock.hcl":`terraform`,".zprofile":`bash`,".zshenv":`bash`,".zshrc":`bash`,"babel.config.cjs":`babel`,"babel.config.js":`babel`,"babel.config.json":`babel`,"babel.config.mjs":`babel`,"biome.json":`biome`,"biome.jsonc":`biome`,"bootstrap.bundle.js":`bootstrap`,"bootstrap.bundle.min.js":`bootstrap`,"bootstrap.css":`bootstrap`,"bootstrap.js":`bootstrap`,"bootstrap.min.css":`bootstrap`,"bootstrap.min.js":`bootstrap`,"bun.lock":`bun`,"bun.lockb":`bun`,"bunfig.toml":`bun`,"claude.md":`claude`,"compose.yaml":`docker`,"compose.yml":`docker`,"docker-compose.override.yml":`docker`,"docker-compose.yaml":`docker`,"docker-compose.yml":`docker`,dockerfile:`docker`,"eslint.config.cjs":`eslint`,"eslint.config.js":`eslint`,"eslint.config.mjs":`eslint`,"eslint.config.mts":`eslint`,"eslint.config.ts":`eslint`,gemfile:`ruby`,"next.config.js":`nextjs`,"next.config.mjs":`nextjs`,"next.config.mts":`nextjs`,"next.config.ts":`nextjs`,"postcss.config.cjs":`postcss`,"postcss.config.js":`postcss`,"postcss.config.mjs":`postcss`,"postcss.config.ts":`postcss`,"prettier.config.cjs":`prettier`,"prettier.config.js":`prettier`,"prettier.config.mjs":`prettier`,rakefile:`ruby`,"readme.md":`markdown`,"stylelint.config.cjs":`stylelint`,"stylelint.config.js":`stylelint`,"stylelint.config.mjs":`stylelint`,"svgo.config.cjs":`svgo`,"svgo.config.js":`svgo`,"svgo.config.mjs":`svgo`,"svgo.config.ts":`svgo`,"tailwind.config.cjs":`tailwind`,"tailwind.config.js":`tailwind`,"tailwind.config.mjs":`tailwind`,"tailwind.config.ts":`tailwind`,"vite.config.js":`vite`,"vite.config.mjs":`vite`,"vite.config.mts":`vite`,"vite.config.ts":`vite`,"webpack.config.babel.js":`webpack`,"webpack.config.cjs":`webpack`,"webpack.config.js":`webpack`,"webpack.config.mjs":`webpack`,"webpack.config.ts":`webpack`},Pr={"7z":`zip`,astro:`astro`,AUTHORS:`text`,avif:`image`,bash:`bash`,bmp:`image`,bz2:`zip`,cfg:`text`,CHANGELOG:`text`,cjs:`javascript`,"code-workspace":`vscode`,conf:`text`,CONTRIBUTORS:`text`,csh:`bash`,css:`css`,csv:`table`,cts:`typescript`,db:`database`,editorconfig:`text`,env:`text`,"env.development":`text`,"env.local":`text`,"env.production":`text`,eot:`font`,erb:`ruby`,fish:`bash`,gemspec:`ruby`,gif:`image`,go:`go`,gql:`graphql`,graphql:`graphql`,gz:`zip`,htm:`html`,html:`html`,icns:`image`,ico:`image`,ini:`text`,jar:`zip`,jpeg:`image`,jpg:`image`,js:`javascript`,json:`json`,json5:`json`,jsonc:`json`,jsonl:`json`,jsx:`javascript`,ksh:`bash`,less:`css`,LICENSE:`text`,log:`text`,markdown:`markdown`,mcp:`mcp`,md:`markdown`,mdx:`markdown`,"mdx.tsx":`markdown`,mjs:`javascript`,mts:`typescript`,ods:`table`,otf:`font`,png:`image`,postcss:`css`,py:`python`,pyi:`python`,pyw:`python`,pyx:`python`,rake:`ruby`,rar:`zip`,rb:`ruby`,rs:`rust`,rst:`text`,rtf:`text`,sass:`css`,scss:`css`,sh:`bash`,sql:`database`,sqlite:`database`,sqlite3:`database`,styl:`css`,svelte:`svelte`,svg:`svg`,swift:`swift`,tar:`zip`,tf:`terraform`,tfstate:`terraform`,tfvars:`terraform`,tgz:`zip`,tif:`image`,tiff:`image`,ts:`typescript`,tsv:`table`,tsx:`typescript`,ttf:`font`,txt:`text`,vue:`vue`,war:`zip`,wasm:`wasm`,wast:`wasm`,wat:`wasm`,webp:`image`,woff:`font`,woff2:`font`,xhtml:`html`,xls:`table`,xlsx:`table`,xz:`zip`,yaml:`yml`,yml:`yml`,zig:`zig`,zip:`zip`,zsh:`bash`},Fr={jsx:`react`,sass:`sass`,scss:`sass`,tsx:`react`},Ir=new Set([`bash`,`css`,`database`,`default`,`font`,`git`,`go`,`html`,`image`,`javascript`,`json`,`markdown`,`mcp`,`python`,`ruby`,`rust`,`swift`,`table`,`text`,`typescript`,`zip`]),Lr=new Set([`complete`]);function Rr(e){return Mr[e===`none`?`minimal`:e]}function zr(e){return`file-tree-builtin-${e}`}function Br(e){let t=An[e];if(t!=null)return`var(--trees-file-icon-color-${e}, var(--trees-file-icon-color, ${t}))`}function Vr(e){return e!==`none`&&Lr.has(e)}function Hr(e,t,n){if(e===`minimal`||e===`none`)return;let r=e===`complete`,i=Nr[t.toLowerCase()];if(i!=null&&(r||Ir.has(i)))return i;for(let e of n){if(r){let t=Fr[e];if(t!=null)return t}let t=Pr[e];if(t!=null&&(r||Ir.has(t)))return t}return`default`}var Ur=`file-tree-container`,Wr=`data-file-tree-style`,Gr=`data-file-tree-unsafe-css`,Kr=`data-file-tree-scrollbar-measure`,qr=`data-file-tree-scrollbar-gutter-measured`,Jr=`--trees-scrollbar-gutter-measured`,Yr=`header`,Xr=`context-menu`,Zr=`context-menu-trigger`;function Qr(e){return e.spriteSheet!=null||e.remap!=null||e.byFileName!=null||e.byFileExtension!=null||e.byFileNameContains!=null}function $r(e){return e==null?{set:`complete`,colored:!0}:typeof e==`string`?{set:e,colored:!0}:{...e,set:e.set??(Qr(e)?`none`:`complete`),colored:e.colored??!0}}var ei=e=>e.trim().toLowerCase(),ti=e=>e.split(`/`).at(-1)??e,ni=e=>{let t=e.toLowerCase().split(`.`),n=[];for(let e=1;e<t.length;e+=1)n.push(t.slice(e).join(`.`));return n};function ri(e,t){return typeof e==`string`?{name:e,remappedFrom:t}:{...e,remappedFrom:t}}function ii(e){let t=$r(e),n=t.remap,r=new Map;for(let[e,n]of Object.entries(t.byFileName??{}))r.set(e.toLowerCase(),n);let i=new Map;for(let[e,n]of Object.entries(t.byFileExtension??{}))i.set(ei(e),n);let a=Object.entries(t.byFileNameContains??{}).map(([e,t])=>[e.toLowerCase(),t]);return{resolveIcon:(e,o)=>{if(e===`file-tree-icon-file`&&o!=null){let n=ti(o),s=n.toLowerCase(),c=r.get(s);if(c!=null)return ri(c,e);for(let[t,n]of a)if(s.includes(t))return ri(n,e);let l=ni(n);for(let t of l){let n=i.get(t);if(n!=null)return ri(n,e)}let u=Hr(t.set,n,l);if(u!=null&&t.set!==`none`)return{name:zr(u),remappedFrom:e,token:u}}let s=n?.[e];return s==null?{name:e}:ri(s,e)}}}var ai=5,oi=1<<ai,si=oi*4;function ci(){return{childIdByNameId:new Map,childIds:[],childPositionById:new Map,childVisibleChunkSums:null,totalChildSubtreeNodeCount:0,totalChildVisibleSubtreeCount:0}}function li(){return{childIdByNameId:null,childIds:[],childPositionById:null,childVisibleChunkSums:null,totalChildSubtreeNodeCount:0,totalChildVisibleSubtreeCount:0}}function ui(e,t){if(t.childIdByNameId!=null)return t.childIdByNameId;let n=new Map;for(let r of t.childIds){let t=e[r];t!=null&&n.set(t.nameId,r)}return t.childIdByNameId=n,n}function di(e){if(e.childPositionById!=null)return e.childPositionById;let t=new Map;for(let n=0;n<e.childIds.length;n++){let r=e.childIds[n];r!=null&&t.set(r,n)}return e.childPositionById=t,t}function fi(e,t){e.childPositionById!=null&&e.childPositionById.set(t,e.childIds.length),e.childIds.push(t)}function pi(e,t){if(e.childPositionById!=null)for(let n=t;n<e.childIds.length;n++){let t=e.childIds[n];t!=null&&e.childPositionById.set(t,n)}}function mi(e,t){let n=0,r=0;for(let i of t.childIds){let t=e[i];t!=null&&(n+=t.subtreeNodeCount,r+=t.visibleSubtreeCount)}t.totalChildSubtreeNodeCount=n,t.totalChildVisibleSubtreeCount=r,vi(e,t)}function hi(e,t,n,r){if(e.totalChildSubtreeNodeCount+=n,e.totalChildVisibleSubtreeCount+=r,e.childVisibleChunkSums==null||r===0)return;let i=di(e).get(t);if(i===void 0)return;let a=i>>ai;e.childVisibleChunkSums[a]+=r}function gi(e,t,n){let r=t.childVisibleChunkSums;if(r!=null){let i=n,a=0;for(let o of r){if(i<o){let r=yi(e,t,a,i);return{...r,childVisibleIndex:n-r.localVisibleIndex}}i-=o,a+=oi}throw Error(`Visible child index ${String(n)} is out of range`)}let i=n;for(let r=0;r<t.childIds.length;r++){let a=t.childIds[r];if(a==null)continue;let o=e[a];if(o!=null){if(i<o.visibleSubtreeCount)return{childIndex:r,childVisibleIndex:n-i,localVisibleIndex:i};i-=o.visibleSubtreeCount}}throw Error(`Visible child index ${String(n)} is out of range`)}function _i(e,t,n){let r=0,i=t.childVisibleChunkSums,a=0;if(i!=null){let e=n>>ai;for(let t=0;t<e;t+=1)r+=i[t]??0;a=e<<ai}for(let i=a;i<n;i+=1){let n=t.childIds[i];if(n==null)continue;let a=e[n];a!=null&&(r+=a.visibleSubtreeCount)}return r}function vi(e,t){if(t.childIds.length<si){t.childVisibleChunkSums=null;return}let n=Math.ceil(t.childIds.length/oi),r=new Int32Array(n);for(let n=0;n<t.childIds.length;n++){let i=t.childIds[n];if(i==null)continue;let a=e[i];a!=null&&(r[n>>ai]+=a.visibleSubtreeCount)}t.childVisibleChunkSums=r}function yi(e,t,n,r){let i=Math.min(t.childIds.length,n+oi),a=r;for(let r=n;r<i;r++){let n=t.childIds[r];if(n==null)continue;let i=e[n];if(i!=null){if(a<i.visibleSubtreeCount)return{childIndex:r,localVisibleIndex:a};a-=i.visibleSubtreeCount}}throw Error(`Visible child index ${String(r)} is out of range`)}var bi=7,xi=3,Si=1<<xi,Ci=4;function wi(e,t,n=0){return e<<Ci|n<<xi|t}function Ti(e){return e.depthAndFlags>>>Ci}function Ei(e){return(e.depthAndFlags&Si)>>xi}function X(e){return(e.depthAndFlags&Si)!==0}function Di(e){return e.depthAndFlags&bi}function Oi(e,t){return(Di(e)&t)!==0}function ki(e,t){e.depthAndFlags|=t}function Ai(e,t){e.depthAndFlags=wi(t,Di(e),Ei(e))}var ji=Symbol(`benchmarkInstrumentation`);function Mi(e,t){return t==null||Object.defineProperty(e,ji,{configurable:!0,enumerable:!1,value:t,writable:!1}),e}function Ni(e){return e==null?null:e[ji]??null}function Z(e,t,n){return e==null?n():e.measurePhase(t,n)}function Pi(e,t,n){!Number.isFinite(n)||e==null||e.setCounter(t,n)}function Fi(e){return e>=48&&e<=57}function Ii(e){let t=[],n=0,r=0;for(;r<e.length;){for(;r<e.length&&!Fi(e.charCodeAt(r));)r+=1;if(r>=e.length)break;r>n&&t.push(e.slice(n,r));let i=0;for(;r<e.length&&Fi(e.charCodeAt(r));)i=i*10+(e.charCodeAt(r)-48),r+=1;t.push(i),n=r}return(n<e.length||t.length===0)&&t.push(e.slice(n)),t}function Li(e){let t=e.toLowerCase();return{lowerValue:t,tokens:Ii(t)}}function Ri(e,t){let n=Math.min(e.length,t.length);for(let r=0;r<n;r++){let n=e[r],i=t[r];if(n===i)continue;if(typeof n==`number`&&typeof i==`number`)return n<i?-1:1;let a=String(n),o=String(i);if(a!==o)return a<o?-1:1}return e.length===t.length?0:e.length<t.length?-1:1}function zi(e,t){if(e.tokens.length===1&&t.tokens.length===1&&typeof e.tokens[0]==`string`&&typeof t.tokens[0]==`string`)return e.lowerValue===t.lowerValue?0:e.lowerValue<t.lowerValue?-1:1;let n=Ri(e.tokens,t.tokens);return n===0?e.lowerValue===t.lowerValue?0:e.lowerValue<t.lowerValue?-1:1:n}function Bi(e,t,n){let r=zi(n(e),n(t));return r===0?e===t?0:e<t?-1:1:r}function Vi(e,t){return Bi(e,t,Li)}function Hi(e,t){return t===e.segments.length-1?+!!e.isDirectory:1}function Ui(e,t){let n=Math.min(e.segments.length,t.segments.length);for(let r=0;r<n;r++){let n=e.segments[r],i=t.segments[r];if(n===i)continue;let a=Hi(e,r);return a===Hi(t,r)?Vi(n,i):a===1?-1:1}return e.segments.length===t.segments.length?e.isDirectory===t.isDirectory?0:e.isDirectory?-1:1:e.segments.length<t.segments.length?-1:1}function Wi(e,t){return Ui(e,t)}function Gi(e,t,n){let r=e=>{let t=n.get(e);if(t!=null)return t;let r=Li(e);return n.set(e,r),r},i=Math.min(e.segments.length,t.segments.length);for(let n=0;n<i;n++){let i=e.segments[n],a=t.segments[n];if(i===a)continue;let o=Hi(e,n);return o===Hi(t,n)?Bi(i,a,r):o===1?-1:1}return e.segments.length===t.segments.length?e.isDirectory===t.isDirectory?0:e.isDirectory?-1:1:e.segments.length<t.segments.length?-1:1}function Ki(e,t){let n=e.sortKeyById[t];if(n!==void 0)return n;let r=e.valueById[t],i=Li(r);return e.sortKeyById[t]=i,i}function qi(e={}){return{flattenEmptyDirectories:e.flattenEmptyDirectories!==!1,sort:e.sort??`default`}}function Ji(e){let t=e.length>0&&e.charCodeAt(e.length-1)===47,n=t?e.length-1:e.length,r=[],i=0;for(let t=0;t<n;t++)e.charCodeAt(t)===47&&(r.push(e.slice(i,t)),i=t+1);return r.push(e.slice(i,n)),{hasTrailingSlash:t,segments:r}}function Yi(e){let{hasTrailingSlash:t,segments:n}=Ji(e);return{basename:n[n.length-1]??``,isDirectory:t,path:e,segments:n}}function Xi(e){if(e.length===0)return{requiresDirectory:!1,segments:[]};let{hasTrailingSlash:t,segments:n}=Ji(e);return{requiresDirectory:t,segments:n}}var Zi=``;function Qi(){let e=new Map;return e.set(Zi,0),{idByValue:e,valueById:[Zi],sortKeyById:[Li(Zi)]}}function $i(e,t){let n=e.idByValue.get(t);if(n!==void 0)return n;let r=e.valueById.length;return e.idByValue.set(t,r),e.valueById.push(t),r}function ea(e,t){let n=e.valueById[t];if(n===void 0)throw Error(`Unknown segment ID: ${String(t)}`);return n}var ta=Symbol(`pathStorePreparedInputKind`);function na(e,t){return e[ta]=t,e}function ra(e){return{basename:e.basename,depth:e.segments.length,isDirectory:e.isDirectory,path:e.path,segments:e.segments}}function ia(e,t,n){return n===`default`?Wi(e,t):n(ra(e),ra(t))}function aa(){return{depthAndFlags:wi(0,3,1),nameId:0,parentId:0,subtreeNodeCount:1,visibleSubtreeCount:1}}function oa(e,t){let n=Math.min(e.length,t.length);for(let r=0;r<n;r++)if(e[r]!==t[r])return r;return n}function sa(e){return e.isDirectory?e.segments.length:e.segments.length-1}function ca(e){return Array.isArray(e)&&e.every(e=>typeof e==`object`&&!!e&&typeof e.path==`string`&&Array.isArray(e.segments)&&typeof e.basename==`string`&&typeof e.isDirectory==`boolean`)}function la(e){return Array.isArray(e)&&e.every(e=>typeof e==`string`)}function ua(e,t={}){return ga(e,t).map(e=>e.path)}function da(e,t={}){let n=ga(e,t);return na({paths:n.map(e=>e.path),preparedPaths:n},`prepared`)}function fa(e){let t=e.length,n=!1;for(let r=0;r<t;r+=1){let t=e[r];if(t.length>0&&t.charCodeAt(t.length-1)===47){n=!0;break}}return na({paths:e,presortedPaths:e,presortedPathsContainDirectories:n},`presorted`)}function pa(e){let t=e,n=t.preparedPaths;if(t[ta]===`prepared`&&n!=null)return n;if(!ca(n))throw Error(`preparedInput must come from PathStore.prepareInput()`);return n}function ma(e){let t=e;return t[ta]===`presorted`&&t.presortedPaths!=null||la(t.presortedPaths)?t.presortedPaths:null}function ha(e){let t=e;return typeof t.presortedPathsContainDirectories==`boolean`?t.presortedPathsContainDirectories:null}function ga(e,t={}){let n=qi(t),r=Ni(t);Pi(r,`workload.inputFiles`,e.length);let i=Z(r,`store.preparePathEntries.parse`,()=>e.map(e=>Yi(e)));return Z(r,`store.preparePathEntries.sort`,()=>i.sort((e,t)=>ia(e,t,n.sort))),i}var _a=class{directories=new Map;directoryStack=[0];presortedDirectoryNodeIds=[];initialExpandedPathSet;createdDirectoriesAllExpanded=!1;createdDirectoryCount=0;lastPreparedPath=null;nodes=[aa()];options;instrumentation;segmentSortKeyCache=new Map;segmentTable=Qi();hasDeferredDirectoryIndexes=!1;constructor(e={}){this.instrumentation=Ni(e),this.options=qi(e);let t=e.initialExpandedPaths??null;if(t==null||t.length===0)this.initialExpandedPathSet=null;else{let e=new Set,n=t.length;for(let r=0;r<n;r+=1){let n=t[r],i=n.length;e.add(i>0&&n.charCodeAt(i-1)===47?n.slice(0,i-1):n)}this.initialExpandedPathSet=e,this.createdDirectoriesAllExpanded=!0}this.directories.set(0,ci())}appendPaths(e){return Z(this.instrumentation,`store.builder.appendPaths.parse`,()=>this.appendPreparedPaths(e.map(e=>Yi(e))))}appendPreparedPaths(e,t=!0){return this.createdDirectoriesAllExpanded=!1,Z(this.instrumentation,`store.builder.appendPreparedPaths`,()=>{for(let n of e)this.appendPreparedPath(n,t)}),this}appendPresortedPaths(e,t=null){return Z(this.instrumentation,`store.builder.appendPresortedPaths`,()=>{if(t===!1){this.appendPresortedFilePaths(e);return}this.createdDirectoriesAllExpanded=!1;let n=null,r=0,i=this.nodes,a=this.segmentTable,o=a.idByValue,s=a.valueById,c=this.directoryStack,l=0,u=``,d=0;for(let t of e){if(n===t)throw Error(`Duplicate path: "${t}"`);let e=t.length>0&&t.charCodeAt(t.length-1)===47,a=e?t.length-1:t.length,f=0,p=0;if(n!=null)if(u.length>0&&t.length>u.length&&t.startsWith(u))f=d,p=u.length;else{let r=Math.min(a,n.length),i=!0;for(let e=0;e<r;e++){let r=t.charCodeAt(e);if(r!==n.charCodeAt(e)){i=!1;break}r===47&&(f++,p=e+1)}i&&e&&r===a&&n.length>a&&n.charCodeAt(a)===47&&(f++,p=a+1)}l=f,r=f;let m=p,h=t.indexOf(`/`,m);for(;h>=0&&h<a;){let e=c[l];if(e===void 0)throw Error(`Directory stack underflow while building the path store`);r++;let n=t.slice(m,h),a=o.get(n);a===void 0&&(a=s.length,o.set(n,a),s.push(n));let u=i.length;i.push({depthAndFlags:wi(r,0,1),nameId:a,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),this.recordCreatedDirectoryPath(t.slice(0,h)),l++,c[l]=u,m=h+1,h=t.indexOf(`/`,m)}if(e){if(m<a){let e=c[l];if(e===void 0)throw Error(`Unable to resolve directory parent for "${t}"`);r++;let n=t.slice(m,a),u=o.get(n);u===void 0&&(u=s.length,o.set(n,u),s.push(n));let d=i.length;i.push({depthAndFlags:wi(r,0,1),nameId:u,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),l++,c[l]=d}let e=c[l];if(e===void 0)throw Error(`Unable to resolve directory node for "${t}"`);this.promoteDirectoryToExplicit(e,t)}else{let e=c[l];if(e===void 0)throw Error(`Unable to resolve file parent for "${t}"`);let n=t.slice(m),a=o.get(n);a===void 0&&(a=s.length,o.set(n,a),s.push(n)),i.push({depthAndFlags:wi(r+1,0),nameId:a,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1})}m!==u.length&&(u=t.substring(0,m),d=r),n=t}c.length=l+1,n!=null&&(this.lastPreparedPath=Yi(n)),this.hasDeferredDirectoryIndexes=!0}),this}appendPresortedFilePaths(e){let t=null,n=0,r=this.nodes,i=this.segmentTable,a=i.idByValue,o=i.valueById,s=this.directoryStack,c=0,l=``,u=0;for(let i of e){if(t===i)throw Error(`Duplicate path: "${i}"`);let e=i.length,d=0,f=0;if(t!=null)if(l.length>0&&i.length>l.length&&i.startsWith(l))d=u,f=l.length;else{let n=Math.min(e,t.length);for(let e=0;e<n;e++){let n=i.charCodeAt(e);if(n!==t.charCodeAt(e))break;n===47&&(d++,f=e+1)}}c=d,n=d;let p=f,m=i.indexOf(`/`,p);for(;m>=0;){let e=s[c];if(e===void 0)throw Error(`Directory stack underflow while building the path store`);n++;let t=i.slice(p,m),l=a.get(t);l===void 0&&(l=o.length,a.set(t,l),o.push(t));let u=r.length;r.push({depthAndFlags:wi(n,0,1),nameId:l,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),this.recordCreatedDirectoryPath(i.slice(0,m)),this.presortedDirectoryNodeIds.push(u),c++,s[c]=u,p=m+1,m=i.indexOf(`/`,p)}let h=s[c];if(h===void 0)throw Error(`Unable to resolve file parent for "${i}"`);let g=i.slice(p),_=a.get(g);_===void 0&&(_=o.length,a.set(g,_),o.push(g)),r.push({depthAndFlags:wi(n+1,0),nameId:_,parentId:h,subtreeNodeCount:1,visibleSubtreeCount:1}),p!==l.length&&(l=i.substring(0,p),u=n),t=i}s.length=c+1,t!=null&&(this.lastPreparedPath=Yi(t)),this.hasDeferredDirectoryIndexes=!0}finish(e={}){let t=e.skipSubtreeCountPass===!0;return this.hasDeferredDirectoryIndexes?(Z(this.instrumentation,`store.builder.buildDirectoryIndexes`,()=>this.buildPresortedFinish(t)),this.hasDeferredDirectoryIndexes=!1):t||Z(this.instrumentation,`store.builder.computeSubtreeCounts`,()=>this.computeSubtreeCounts(0)),{directories:this.directories,nodes:this.nodes,options:this.options,rootId:0,segmentTable:this.segmentTable,presortedDirectoryNodeIds:this.presortedDirectoryNodeIds.length>0?this.presortedDirectoryNodeIds:null}}didMatchAllInitialExpandedPaths(){return this.createdDirectoriesAllExpanded&&this.initialExpandedPathSet!=null&&this.createdDirectoryCount===this.initialExpandedPathSet.size}appendPreparedPath(e,t){if(this.hasDeferredDirectoryIndexes&&=(this.buildDirectoryIndexes(),!1),this.lastPreparedPath!=null){if(e.path===this.lastPreparedPath.path)throw Error(`Duplicate path: "${e.path}"`);if(t&&(this.options.sort===`default`?Gi(this.lastPreparedPath,e,this.segmentSortKeyCache):ia(this.lastPreparedPath,e,this.options.sort))>0)throw Error(`Builder input must be sorted before appendPaths(): "${e.path}"`)}let n=this.lastPreparedPath,r=sa(e),i=n==null?0:sa(n),a=n==null?0:oa(n.segments,e.segments),o=Math.min(a,r,i);this.directoryStack.length=o+1;for(let n=o;n<r;n++){let r=this.directoryStack[this.directoryStack.length-1];if(r===void 0)throw Error(`Directory stack underflow while building the path store`);let i=t?this.getOrCreateDirectoryChild(r,e.segments[n]):this.createDirectoryChild(r,e.segments[n]);this.directoryStack.push(i)}if(e.isDirectory){let t=this.directoryStack[this.directoryStack.length-1];if(t===void 0)throw Error(`Unable to resolve directory node for "${e.path}"`);this.promoteDirectoryToExplicit(t,e.path),this.lastPreparedPath=e;return}let s=this.directoryStack[this.directoryStack.length-1];if(s===void 0)throw Error(`Unable to resolve file parent for "${e.path}"`);t?this.createFileChild(s,e.basename,e.path):this.createFileChildUnchecked(s,e.basename),this.lastPreparedPath=e}recordCreatedDirectoryPath(e){!this.createdDirectoriesAllExpanded||this.initialExpandedPathSet==null||(this.createdDirectoryCount+=1,this.initialExpandedPathSet.has(e)||(this.createdDirectoriesAllExpanded=!1))}createFileChild(e,t,n){let r=$i(this.segmentTable,t),i=this.getDirectoryIndex(e),a=i.childIdByNameId;if(a!=null&&a.get(r)!==void 0)throw Error(`Path collides with an existing entry: "${n}"`);let o=this.nodes[e];if(o===void 0)throw Error(`Unknown parent node ID: ${String(e)}`);let s=this.nodes.length;return this.nodes.push({depthAndFlags:wi(Ti(o)+1,0),nameId:r,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),a?.set(r,s),fi(i,s),s}createFileChildUnchecked(e,t){let n=$i(this.segmentTable,t),r=this.getDirectoryIndex(e),i=this.nodes[e];if(i===void 0)throw Error(`Unknown parent node ID: ${String(e)}`);let a=this.nodes.length;return this.nodes.push({depthAndFlags:wi(Ti(i)+1,0),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),r.childIdByNameId!=null&&r.childIdByNameId.set(n,a),fi(r,a),a}getOrCreateDirectoryChild(e,t){let n=$i(this.segmentTable,t),r=this.getDirectoryIndex(e);if(r.childIdByNameId!=null){let e=r.childIdByNameId.get(n);if(e!==void 0){let n=this.nodes[e];if(n!=null&&!X(n))throw Error(`Path collides with an existing file while creating directory "${t}"`);return e}}let i=this.nodes[e];if(i===void 0)throw Error(`Unknown parent node ID: ${String(e)}`);let a=this.nodes.length;return this.nodes.push({depthAndFlags:wi(Ti(i)+1,0,1),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),r.childIdByNameId!=null&&r.childIdByNameId.set(n,a),fi(r,a),this.directories.set(a,ci()),a}createDirectoryChild(e,t){let n=$i(this.segmentTable,t),r=this.getDirectoryIndex(e),i=this.nodes[e];if(i===void 0)throw Error(`Unknown parent node ID: ${String(e)}`);let a=this.nodes.length;return this.nodes.push({depthAndFlags:wi(Ti(i)+1,0,1),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),r.childIdByNameId!=null&&r.childIdByNameId.set(n,a),fi(r,a),this.directories.set(a,ci()),a}promoteDirectoryToExplicit(e,t){let n=this.nodes[e];if(n===void 0)throw Error(`Unknown directory node ID: ${String(e)}`);if(!X(n))throw Error(`Path is not a directory: "${t}"`);if(Oi(n,1))throw Error(`Duplicate path: "${t}"`);ki(n,1)}getDirectoryIndex(e){let t=this.directories.get(e);if(t!==void 0)return t;throw Error(`Unknown directory child index for node ${String(e)}`)}buildPresortedFinish(e){let t=this.nodes,n=this.directories;n.set(0,li());let r=-1,i=null;for(let e=1;e<t.length;e++){let a=t[e];if(a==null)continue;if(X(a)){let t=li();n.set(e,t),r=e,i=t}let o;a.parentId===r?o=i:(o=n.get(a.parentId),r=a.parentId,i=o??null),o?.childIds.push(e)}if(!e)for(let e=t.length-1;e>=1;e--){let n=t[e];if(n==null)continue;let r=t[n.parentId];r!=null&&(r.subtreeNodeCount+=n.subtreeNodeCount,r.visibleSubtreeCount+=n.visibleSubtreeCount)}}buildDirectoryIndexes(){let e=this.nodes;for(let t=1;t<e.length;t++){let n=e[t];if(n==null)continue;X(n)&&this.directories.set(t,ci());let r=this.directories.get(n.parentId);r!=null&&(r.childIdByNameId!=null&&r.childIdByNameId.set(n.nameId,t),fi(r,t))}}computeSubtreeCounts(e){let t=this.nodes[e];if(t===void 0)throw Error(`Unknown node ID: ${String(e)}`);if(!X(t))return t.subtreeNodeCount=1,t.visibleSubtreeCount=1,1;let n=this.getDirectoryIndex(e),r=1;for(let e of n.childIds)r+=this.computeSubtreeCounts(e);return mi(this.nodes,n),t.subtreeNodeCount=r,t.visibleSubtreeCount=r,r}};function va(e,t=`closed`,n=null){let r=ba(t);return{activeNodeCount:e.nodes.length-1,collapsedDirectoryIds:new Set,collapseNewDirectoriesByDefault:!1,defaultExpansion:r,directoriesOpenByDefault:r===`open`,hasCollapsedDirectoryOverrides:!1,directoryLoadInfoById:new Map,expandedDirectoryIds:new Set,instrumentation:n,listeners:new Map,pathCacheByNodeId:new Map([[e.rootId,{path:``,version:0}]]),pathCacheVersion:0,snapshot:e,transactionStack:[]}}function ya(){return{affectedAncestorIds:new Set,affectedNodeIds:new Set,events:[]}}function ba(e){if(typeof e!=`number`)return e;if(!Number.isInteger(e)||e<0)throw Error(`initialExpansion must be "open", "closed", or a non-negative integer depth. Received: ${String(e)}`);return e}function xa(e,t){return Oi(t,2)||e.defaultExpansion===`open`?!0:e.defaultExpansion===`closed`?!1:Ti(t)<=e.defaultExpansion}function Sa(e,t,n=e.snapshot.nodes[t]){return n==null||!X(n)?!1:e.directoriesOpenByDefault&&!e.hasCollapsedDirectoryOverrides?!0:e.collapsedDirectoryIds.has(t)?!1:e.expandedDirectoryIds.has(t)?!0:xa(e,n)}function Ca(e,t,n,r=e.snapshot.nodes[t]){if(r==null||!X(r))return;let i=xa(e,r);if(n){if(i){e.collapsedDirectoryIds.delete(t),e.hasCollapsedDirectoryOverrides=e.collapsedDirectoryIds.size>0;return}e.expandedDirectoryIds.add(t);return}if(i){e.collapsedDirectoryIds.add(t),e.hasCollapsedDirectoryOverrides=!0;return}e.expandedDirectoryIds.delete(t)}function wa(e,t){let n=e.directoryLoadInfoById.get(t);if(n!=null)return n;let r={activeAttemptId:null,errorMessage:null,nextAttemptId:1,state:`loaded`};return e.directoryLoadInfoById.set(t,r),r}function Ta(e,t){return e.directoryLoadInfoById.get(t)?.state??`loaded`}function Ea(e,t){let n=wa(e,t);if(n.state===`loading`&&n.activeAttemptId!=null)return{attemptId:n.activeAttemptId,nodeId:t,reused:!0};let r=n.nextAttemptId;return n.activeAttemptId=r,n.errorMessage=null,n.nextAttemptId+=1,n.state=`loading`,{attemptId:r,nodeId:t,reused:!1}}function Da(e,t){let n=wa(e,t);n.activeAttemptId=null,n.errorMessage=null,n.state=`unloaded`}function Oa(e,t,n){let r=e.directoryLoadInfoById.get(t);return r==null||r.activeAttemptId!==n?!1:(r.activeAttemptId=null,r.errorMessage=null,r.state=`loaded`,!0)}function ka(e,t,n){return e.directoryLoadInfoById.get(t)?.activeAttemptId===n}function Aa(e,t,n,r){let i=e.directoryLoadInfoById.get(t);return i==null||i.activeAttemptId!==n?!1:(i.activeAttemptId=null,i.errorMessage=r??null,i.state=`error`,!0)}function ja(e,t){e.directoryLoadInfoById.delete(t)}function Ma(e,t,n){let r=n,i=e.listeners.get(t);return i==null?e.listeners.set(t,new Set([r])):i.add(r),()=>{let n=e.listeners.get(t);n!=null&&(n.delete(r),n.size===0&&e.listeners.delete(t))}}function Na(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!0,operation:`add`,path:e.path,projectionChanged:e.projectionChanged,visibleCountDelta:null}}function Pa(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!0,operation:`remove`,path:e.path,projectionChanged:e.projectionChanged,recursive:e.recursive,visibleCountDelta:null}}function Fa(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!0,from:e.from,operation:`move`,projectionChanged:e.projectionChanged,to:e.to,visibleCountDelta:null}}function Ia(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!1,operation:`expand`,path:e.path,projectionChanged:!0,visibleCountDelta:null}}function La(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!1,operation:`collapse`,path:e.path,projectionChanged:!0,visibleCountDelta:null}}function Ra(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],canonicalChanged:!1,operation:`mark-directory-unloaded`,path:e.path,projectionChanged:e.projectionChanged,visibleCountDelta:null}}function za(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:!1,operation:`begin-child-load`,path:e.path,projectionChanged:e.projectionChanged,reused:e.reused,visibleCountDelta:null}}function Ba(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:e.childEvents.some(e=>e.canonicalChanged),childEvents:e.childEvents,operation:`apply-child-patch`,path:e.path,projectionChanged:e.projectionChanged,visibleCountDelta:null}}function Va(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:!1,operation:`complete-child-load`,path:e.path,projectionChanged:e.projectionChanged,stale:e.stale,visibleCountDelta:null}}function Ha(e){return{affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],attemptId:e.attemptId,canonicalChanged:!1,errorMessage:e.errorMessage,operation:`fail-child-load`,path:e.path,projectionChanged:e.projectionChanged,stale:e.stale,visibleCountDelta:null}}function Ua(e){return{activeNodeCountAfter:e.activeNodeCountAfter,activeNodeCountBefore:e.activeNodeCountBefore,affectedAncestorIds:e.affectedAncestorIds??[],affectedNodeIds:e.affectedNodeIds??[],cachedPathEntryCountAfter:e.cachedPathEntryCountAfter,cachedPathEntryCountBefore:e.cachedPathEntryCountBefore,canonicalChanged:!1,idsPreserved:e.idsPreserved,loadInfoEntryCountAfter:e.loadInfoEntryCountAfter,loadInfoEntryCountBefore:e.loadInfoEntryCountBefore,mode:e.mode,operation:`cleanup`,projectionChanged:e.projectionChanged,reclaimedCachedPathEntryCount:e.reclaimedCachedPathEntryCount,reclaimedLoadInfoEntryCount:e.reclaimedLoadInfoEntryCount,reclaimedNodeSlotCount:e.reclaimedNodeSlotCount,reclaimedSegmentCount:e.reclaimedSegmentCount,segmentCountAfter:e.segmentCountAfter,segmentCountBefore:e.segmentCountBefore,totalNodeSlotCountAfter:e.totalNodeSlotCountAfter,totalNodeSlotCountBefore:e.totalNodeSlotCountBefore,visibleCountDelta:null}}function Wa(e,t,n){return{...n,visibleCountDelta:to(e)-t}}function Ga(e,t){let n=to(e),r=ya();e.transactionStack.push(r);try{t()}catch(t){throw Ja(e,r,!1),t}Ja(e,r,!0,to(e)-n)}function Ka(e,t){let n=e.instrumentation;if(n==null){qa(e,t);return}Z(n,`store.events.record`,()=>qa(e,t))}function qa(e,t){let n=e.transactionStack[e.transactionStack.length-1]??null;if(n==null){$a(e,t);return}n.events.push(t),Qa(n,t)}function Ja(e,t,n,r=null){if(e.transactionStack.pop()!==t)throw Error(`Transaction stack underflow`);if(!n)return;let i=e.transactionStack[e.transactionStack.length-1]??null;if(i!=null){let n=e.instrumentation;n==null?Za(i,t):Z(n,`store.events.batch.merge`,()=>Za(i,t));return}let a=Ya(t,r),o=e.instrumentation;if(o==null){$a(e,a);return}Z(o,`store.events.batch.commit`,()=>$a(e,a))}function Ya(e,t){return{affectedAncestorIds:[...e.affectedAncestorIds],affectedNodeIds:[...e.affectedNodeIds],canonicalChanged:e.events.some(e=>e.canonicalChanged),events:[...e.events],operation:`batch`,projectionChanged:e.events.some(e=>e.projectionChanged),visibleCountDelta:t}}function Xa(e,t){for(let n of t.affectedAncestorIds)e.affectedAncestorIds.add(n);for(let n of t.affectedNodeIds)e.affectedNodeIds.add(n)}function Za(e,t){for(let n of t.events)e.events.push(n);Xa(e,t)}function Qa(e,t){for(let n of t.affectedNodeIds)e.affectedNodeIds.add(n);for(let n of t.affectedAncestorIds)e.affectedAncestorIds.add(n)}function $a(e,t){let n=e.instrumentation;if(n==null){eo(e,t);return}Z(n,`store.events.emit`,()=>eo(e,t))}function eo(e,t){e.listeners.get(t.operation)?.forEach(e=>e(t)),e.listeners.get(`*`)?.forEach(e=>e(t))}function to(e){return e.snapshot.nodes[e.snapshot.rootId]?.visibleSubtreeCount??0}function no(e,t){if(e.snapshot.options.flattenEmptyDirectories!==!0)return null;let n=e.snapshot.nodes[t];if(n==null||!X(n)||Oi(n,2))return null;let r=e.snapshot.directories.get(t);if(r==null||r.childIds.length!==1)return null;let i=r.childIds[0];if(i==null)return null;let a=e.snapshot.nodes[i];return a==null||!X(a)?null:i}function ro(e,t){let n=t;for(;;){let t=no(e,n);if(t==null)return n;n=t}}function io(e,t){let n=[t],r=t;for(;;){let t=no(e,r);if(t==null)return n;n.push(t),r=t}}function ao(e,t){let n=t==null?e.snapshot.rootId:go(e,t);return n==null?[]:yo(e,n)}function oo(e,t){let n=Yi(t),r=n.isDirectory?n.segments:n.segments.slice(0,-1),i=Po(e,No(e,r)),{createdNodeIds:a,directoryId:o}=bo(e,r),s=new Set(a),c=o;if(n.isDirectory){let n=Q(e,o);if(Oi(n,1))throw Error(`Path already exists: "${t}"`);ki(n,1),e.pathCacheByNodeId.set(o,{path:t,version:e.pathCacheVersion}),s.add(o)}else c=So(e,o,n.basename),s.add(c);po(e,o);let l=Po(e,o);return Na({affectedAncestorIds:ho(e,c),affectedNodeIds:[...s],path:t,projectionChanged:Fo(i,l)})}function so(e,t,n){let r=go(e,t);if(r==null)throw Error(`Path does not exist: "${t}"`);let i=Q(e,r);if(Oi(i,2))throw Error(`The root node cannot be removed`);if(X(i)&&vo(e,r).childIds.length>0&&n.recursive!==!0)throw Error(`Cannot remove a non-empty directory without recursive: "${t}"`);let a=i.parentId,o=Po(e,a),s=jo(e,r);To(e,a,r,i.nameId),Mo(e,a),po(e,a);let c=Po(e,a);return Pa({affectedAncestorIds:ho(e,a),affectedNodeIds:s,path:t,projectionChanged:Fo(o,c),recursive:n.recursive===!0})}function co(e,t,n,r){let i=go(e,t);if(i==null)throw Error(`Source path does not exist: "${t}"`);let a=Q(e,i);if(Oi(a,2))throw Error(`The root node cannot be moved`);let o=r.collision??`error`,s=ko(e,i,n),c=Po(e,a.parentId),l=Po(e,s.parentId),u=ea(e.snapshot.segmentTable,a.nameId),d=$i(e.snapshot.segmentTable,s.basename);if(s.parentId===a.parentId&&u===s.basename)return null;if(X(a)&&zo(e,i,s.parentId))throw Error(`Cannot move a directory into one of its descendants`);let f=ui(e.snapshot.nodes,vo(e,s.parentId)).get(d),p=s.existingNodeId??f??null;if(p!=null&&p!==i&&Ao(e,p,o,Ei(a))===`skip`)return null;let m=a.parentId;To(e,m,i,a.nameId),a.parentId=s.parentId,a.nameId=d,e.pathCacheByNodeId.delete(i),Ro(e,i),wo(e,s.parentId,i),Mo(e,m),e.pathCacheVersion++,po(e,m),s.parentId!==m&&po(e,s.parentId);let h=Po(e,m),g=Po(e,s.parentId);return Fa({affectedAncestorIds:[...new Set([...ho(e,m),...ho(e,s.parentId)])],affectedNodeIds:[i],from:t,projectionChanged:Io([c,l],[h,g]),to:fo(e,i)})}function lo(e,t){let n=e.pathCacheByNodeId.get(t);return n!=null&&n.version===e.pathCacheVersion?n.path:null}function uo(e,t,n){return e.pathCacheByNodeId.set(t,{path:n,version:e.pathCacheVersion}),n}function fo(e,t){let n=Q(e,t),r=lo(e,t);if(r!=null)return r;if(Oi(n,2))return uo(e,t,``);let i=fo(e,n.parentId),a=ea(e.snapshot.segmentTable,n.nameId),o=i.length===0?a:`${i}${a}`;return uo(e,t,X(n)?`${o}/`:o)}function po(e,t){let n=e.instrumentation;if(n==null){Vo(e,t);return}Z(n,`store.recomputeCountsUpwardFrom`,()=>Vo(e,t))}function mo(e,t){let n=[[t,0]],{nodes:r,directories:i}=e.snapshot;for(;n.length>0;){let t=n[n.length-1],a=t[0],o=r[a];if(o==null||!X(o)){Bo(e,a,o,!0),n.pop();continue}let s=i.get(a);if(s==null||t[1]>=s.childIds.length){Bo(e,a,o,!0),n.pop();continue}let c=s.childIds[t[1]++];n.push([c,0])}}function ho(e,t){let n=[],r=t;for(;r!=null;){let t=Q(e,r);if(n.push(r),r===e.snapshot.rootId)break;r=t.parentId}return n}function go(e,t){if(t.length===0)return e.snapshot.rootId;let n=Xi(t);return _o(e,n.segments,n.requiresDirectory)}function _o(e,t,n){let r=e.snapshot.rootId;for(let n of t){let t=e.snapshot.segmentTable.idByValue.get(n);if(t===void 0)return null;let i=vo(e,r),a=ui(e.snapshot.nodes,i).get(t);if(a===void 0)return null;r=a}let i=Q(e,r);return n&&!X(i)?null:r}function vo(e,t){let n=e.snapshot.directories.get(t);if(n===void 0)throw Error(`Unknown directory child index for node ${String(t)}`);return n}function Q(e,t){let n=e.snapshot.nodes[t];if(n===void 0||Oi(n,4))throw Error(`Unknown node ID: ${String(t)}`);return n}function yo(e,t){let n=e.snapshot.nodes[t];if(n===void 0||Oi(n,4))return[];if(!X(n))return[fo(e,t)];if(vo(e,t).childIds.length===0)return Oi(n,1)&&!Oi(n,2)?[fo(e,t)]:[];let r=[],i=[{childIndex:0,nodeId:t}];for(;i.length>0;){let t=i[i.length-1];if(t==null)break;let n=e.snapshot.nodes[t.nodeId];if(n===void 0||Oi(n,4)){i.pop();continue}if(!X(n)){r.push(fo(e,t.nodeId)),i.pop();continue}let a=vo(e,t.nodeId);if(a.childIds.length===0){Oi(n,1)&&!Oi(n,2)&&r.push(fo(e,t.nodeId)),i.pop();continue}let o=a.childIds[t.childIndex];if(o==null){i.pop();continue}t.childIndex++,i.push({childIndex:0,nodeId:o})}return r}function bo(e,t){let n=[],r=e.snapshot.rootId;for(let i of t){let t=$i(e.snapshot.segmentTable,i),a=vo(e,r),o=ui(e.snapshot.nodes,a).get(t);if(o!==void 0){if(!X(Q(e,o)))throw Error(`Cannot create a directory that collides with an existing file: "${i}"`);r=o;continue}r=xo(e,r,t),n.push(r)}return{createdNodeIds:n,directoryId:r}}function xo(e,t,n){let r=Q(e,t),i=e.snapshot.nodes.length;return e.snapshot.nodes.push({depthAndFlags:wi(Ti(r)+1,0,1),nameId:n,parentId:t,subtreeNodeCount:1,visibleSubtreeCount:1}),e.snapshot.directories.set(i,ci()),wo(e,t,i),e.collapseNewDirectoriesByDefault&&(e.collapsedDirectoryIds.add(i),e.hasCollapsedDirectoryOverrides=!0),e.activeNodeCount++,i}function So(e,t,n){let r=$i(e.snapshot.segmentTable,n),i=vo(e,t);if(ui(e.snapshot.nodes,i).has(r))throw Error(`Path already exists: "${Uo(e,t,n)}"`);let a=Q(e,t),o=e.snapshot.nodes.length;return e.snapshot.nodes.push({depthAndFlags:wi(Ti(a)+1,0),nameId:r,parentId:t,subtreeNodeCount:1,visibleSubtreeCount:1}),wo(e,t,o),e.activeNodeCount++,o}function Co(e,t,n){let r=0,i=t.childIds.length;for(;r<i;){let a=r+i>>>1,o=t.childIds[a];if(o==null){i=a;continue}Eo(e,n,o)<0?i=a:r=a+1}return r}function wo(e,t,n){let r=vo(e,t),i=Q(e,n);ui(e.snapshot.nodes,r).set(i.nameId,n),hi(r,n,i.subtreeNodeCount,i.visibleSubtreeCount);let a=Co(e,r,n);r.childIds.splice(a,0,n),pi(r,a),vi(e.snapshot.nodes,r)}function To(e,t,n,r){let i=vo(e,t),a=di(i),o=a.get(n)??-1;ui(e.snapshot.nodes,i).delete(r),a.delete(n);let s=e.snapshot.nodes[n];s!=null&&hi(i,n,-s.subtreeNodeCount,-s.visibleSubtreeCount),o>=0&&(i.childIds.splice(o,1),pi(i,o),vi(e.snapshot.nodes,i))}function Eo(e,t,n){let r=e.snapshot.options.sort;return r===`default`?Do(e,t,n):r(Oo(e,t),Oo(e,n))}function Do(e,t,n){let r=Q(e,t),i=Q(e,n),a=X(r);if(a!==X(i))return a?-1:1;let o=zi(Ki(e.snapshot.segmentTable,r.nameId),Ki(e.snapshot.segmentTable,i.nameId));if(o!==0)return o;let s=ea(e.snapshot.segmentTable,r.nameId),c=ea(e.snapshot.segmentTable,i.nameId);return s===c?t<n?-1:1:s<c?-1:1}function Oo(e,t){let n=Q(e,t),r=fo(e,t),i=X(n),a=i?r.slice(0,-1):r;return{basename:ea(e.snapshot.segmentTable,n.nameId),depth:Ti(n),isDirectory:i,path:r,segments:a.length===0?[]:a.split(`/`)}}function ko(e,t,n){let r=Q(e,t),i=go(e,n);if(i!=null){let t=Q(e,i);if(X(t))return{basename:ea(e.snapshot.segmentTable,r.nameId),existingNodeId:null,parentId:i};let a=Xi(n).segments;return{basename:a[a.length-1]??``,existingNodeId:i,parentId:t.parentId}}let a=Xi(n),o=a.segments[a.segments.length-1]??``,s=a.segments.slice(0,-1),c=s.length===0?e.snapshot.rootId:_o(e,s,!0);if(c==null)throw Error(`Destination parent does not exist: "${n}"`);return{basename:o,existingNodeId:null,parentId:c}}function Ao(e,t,n,r){if(n===`skip`)return`skip`;if(n===`error`)throw Error(`Destination already exists: "${fo(e,t)}"`);let i=Q(e,t);if(Ei(i)!==r)throw Error(`replace collision requires the same source and destination kinds`);if(X(i)&&vo(e,t).childIds.length>0)throw Error(`replace collision does not support non-empty directories`);let a=i.parentId,o=i.nameId;return jo(e,t),To(e,a,t,o),Mo(e,a),po(e,a),`handled`}function jo(e,t){let n=[],r=[{nodeId:t,visitedChildren:!1}];for(;r.length>0;){let t=r.pop();if(t==null)break;let i=Q(e,t.nodeId);if(t.visitedChildren||!X(i)){X(i)&&e.snapshot.directories.delete(t.nodeId),ki(i,4),e.pathCacheByNodeId.delete(t.nodeId),e.collapsedDirectoryIds.delete(t.nodeId)&&(e.hasCollapsedDirectoryOverrides=e.collapsedDirectoryIds.size>0),e.expandedDirectoryIds.delete(t.nodeId),ja(e,t.nodeId),e.activeNodeCount--,n.push(t.nodeId);continue}r.push({nodeId:t.nodeId,visitedChildren:!0});let a=vo(e,t.nodeId);for(let e=a.childIds.length-1;e>=0;e--){let t=a.childIds[e];t!=null&&r.push({nodeId:t,visitedChildren:!1})}}return n}function Mo(e,t){let n=t;for(;n!=null;){let t=Q(e,n);if(!X(t)||Oi(t,2)||vo(e,n).childIds.length>0)return;ki(t,1),n=t.parentId===n?null:t.parentId}}function No(e,t){let n=e.snapshot.rootId;for(let r of t){let t=e.snapshot.segmentTable.idByValue.get(r);if(t==null)break;let i=ui(e.snapshot.nodes,vo(e,n)).get(t);if(i==null||!X(Q(e,i)))break;n=i}return n}function Po(e,t){let n=Lo(e,t);if(n==null)return null;let r=ro(e,n),i=Q(e,r),a=n===r?null:io(e,n).map(t=>fo(e,t));return JSON.stringify({flattenedSegmentPaths:a,hasChildren:vo(e,r).childIds.length>0,path:fo(e,r),terminalKind:Ei(i)})}function Fo(e,t){return Io([e],[t])}function Io(e,t){for(let n=0;n<e.length;n+=1){let r=e[n],i=t[n];if(r==null||i==null||r!==i)return!0}return!1}function Lo(e,t){let n=t;for(;n!=null;){let t=Q(e,n);if(!X(t)||Oi(t,2))return null;if(!Sa(e,n,t))return n;n=t.parentId}return null}function Ro(e,t){let n=Q(e,t);if(Ai(n,(t===e.snapshot.rootId?-1:Ti(Q(e,n.parentId)))+1),!X(n))return;let r=vo(e,t);for(let t of r.childIds)Ro(e,t)}function zo(e,t,n){let r=n;for(;r!=null;){if(r===t)return!0;let n=Q(e,r);if(r===e.snapshot.rootId)return!1;r=n.parentId}return!1}function Bo(e,t,n=Q(e,t),r=!1){let i=e.instrumentation;if(i==null){Ho(e,t,n,r);return}Z(i,`store.recomputeNodeCounts`,()=>Ho(e,t,n,r))}function Vo(e,t){let n=t;for(;n!=null;){let t=Q(e,n),r=t.subtreeNodeCount,i=t.visibleSubtreeCount;if(Bo(e,n,t),n===e.snapshot.rootId)return;let a=t.subtreeNodeCount-r,o=t.visibleSubtreeCount-i,s=t.parentId;(a!==0||o!==0)&&hi(vo(e,s),n,a,o),n=s}}function Ho(e,t,n,r){if(!X(n)){n.subtreeNodeCount=1,n.visibleSubtreeCount=1;return}let i=vo(e,t);if(r){let t=e.instrumentation;t==null?mi(e.snapshot.nodes,i):Z(t,`store.recomputeNodeCounts.rebuildChildAggregates`,()=>mi(e.snapshot.nodes,i))}let a=1+i.totalChildSubtreeNodeCount,o=i.totalChildVisibleSubtreeCount;if(n.subtreeNodeCount=a,Oi(n,2)){n.visibleSubtreeCount=o;return}n.visibleSubtreeCount=no(e,t)==null?Sa(e,t,n)?1+o:1:o}function Uo(e,t,n){let r=fo(e,t);return r.length===0?n:`${r}${n}`}function Wo(e){return e!=null&&!Oi(e,4)}function Go(e,t){let n=e.snapshot.nodes[t];return!Wo(n)||!X(n)||Oi(n,2)?null:n}function Ko(e){let t=0;for(let[n,r]of e.pathCacheByNodeId)r.version===e.pathCacheVersion&&Wo(e.snapshot.nodes[n])&&(t+=1);return t}function qo(e){return Math.max(0,e.valueById.length-1)}function Jo(e){return{activeNodeCount:e.activeNodeCount,cachedPathEntryCount:Ko(e),loadInfoEntryCount:e.directoryLoadInfoById.size,segmentCount:qo(e.snapshot.segmentTable),totalNodeSlotCount:Math.max(0,e.snapshot.nodes.length-1)}}function Yo(e,t,n,r){return{activeNodeCountAfter:r.activeNodeCount,activeNodeCountBefore:n.activeNodeCount,cachedPathEntryCountAfter:r.cachedPathEntryCount,cachedPathEntryCountBefore:n.cachedPathEntryCount,idsPreserved:t,loadInfoEntryCountAfter:r.loadInfoEntryCount,loadInfoEntryCountBefore:n.loadInfoEntryCount,mode:e,reclaimedCachedPathEntryCount:n.cachedPathEntryCount-r.cachedPathEntryCount,reclaimedLoadInfoEntryCount:n.loadInfoEntryCount-r.loadInfoEntryCount,reclaimedNodeSlotCount:n.totalNodeSlotCount-r.totalNodeSlotCount,reclaimedSegmentCount:n.segmentCount-r.segmentCount,segmentCountAfter:r.segmentCount,segmentCountBefore:n.segmentCount,totalNodeSlotCountAfter:r.totalNodeSlotCount,totalNodeSlotCountBefore:n.totalNodeSlotCount}}function Xo(e){let t=[],n=[];for(let n of e.collapsedDirectoryIds)Go(e,n)!=null&&t.push(fo(e,n));for(let t of e.expandedDirectoryIds)Go(e,t)!=null&&n.push(fo(e,t));return{collapsedPaths:t,expandedPaths:n}}function Zo(e){let t=[];for(let[n,r]of e.directoryLoadInfoById)Go(e,n)==null||Ta(e,n)===`loaded`||t.push({info:{activeAttemptId:null,errorMessage:r.errorMessage,nextAttemptId:r.nextAttemptId,state:r.state},path:fo(e,n)});return t}function Qo(e,t){e.collapsedDirectoryIds.clear(),e.hasCollapsedDirectoryOverrides=!1,e.expandedDirectoryIds.clear();for(let n of t.expandedPaths){let t=go(e,n);t!=null&&Ca(e,t,!0,Q(e,t))}for(let n of t.collapsedPaths){let t=go(e,n);t!=null&&Ca(e,t,!1,Q(e,t))}}function $o(e,t){e.directoryLoadInfoById.clear();for(let n of t){let t=go(e,n.path);t!=null&&Go(e,t)!=null&&e.directoryLoadInfoById.set(t,{activeAttemptId:null,errorMessage:n.info.errorMessage,nextAttemptId:n.info.nextAttemptId,state:n.info.state})}}function es(e){e.pathCacheVersion+=1,e.pathCacheByNodeId.clear(),e.pathCacheByNodeId.set(e.snapshot.rootId,{path:``,version:e.pathCacheVersion})}function ts(e){let t=e.snapshot.segmentTable,n=Qi();for(let r of e.snapshot.nodes)if(Wo(r)){if(Oi(r,2)){r.nameId=0;continue}r.nameId=$i(n,ea(t,r.nameId))}e.snapshot.segmentTable=n}function ns(e){for(let[t,n]of e.snapshot.directories){let r=e.snapshot.nodes[t];if(!Wo(r)||!X(r)){e.snapshot.directories.delete(t);continue}let i=n.childIds.filter(n=>{let r=e.snapshot.nodes[n];return Wo(r)&&r.parentId===t});n.childIds=i,n.childIdByNameId=new Map(i.map(t=>[Q(e,t).nameId,t])),n.childPositionById=new Map(i.map((e,t)=>[e,t])),mi(e.snapshot.nodes,n)}}function rs(e){let t=e.snapshot.nodes.length-1;for(;t>e.snapshot.rootId;){let n=e.snapshot.nodes[t];if(Wo(n))break;--t}e.snapshot.nodes.length=t+1}function is(e){let t=Xo(e),n=Zo(e);Z(e.instrumentation,`store.cleanup.stable.clearPathCaches`,()=>es(e)),Z(e.instrumentation,`store.cleanup.stable.rebuildSegmentTable`,()=>ts(e)),Z(e.instrumentation,`store.cleanup.stable.rebuildDirectoryIndexes`,()=>ns(e)),Z(e.instrumentation,`store.cleanup.stable.trimTrailingRemovedNodeSlots`,()=>rs(e)),Z(e.instrumentation,`store.cleanup.stable.restoreExpansionOverrides`,()=>Qo(e,t)),Z(e.instrumentation,`store.cleanup.stable.restoreDirectoryLoadInfos`,()=>$o(e,n)),Z(e.instrumentation,`store.cleanup.stable.recomputeCounts`,()=>mo(e,e.snapshot.rootId))}function as(e){let t=Xo(e),n=Zo(e),r=Z(e.instrumentation,`store.cleanup.aggressive.listPaths`,()=>ao(e)),i=Mi({...e.snapshot.options},e.instrumentation),a=Z(e.instrumentation,`store.cleanup.aggressive.rebuildSnapshot`,()=>{let e=new _a(i);return e.appendPaths(r),e.finish()});e.snapshot=a,e.activeNodeCount=a.nodes.length-1,e.pathCacheByNodeId=new Map([[a.rootId,{path:``,version:0}]]),e.pathCacheVersion=0,Z(e.instrumentation,`store.cleanup.aggressive.restoreExpansionOverrides`,()=>Qo(e,t)),Z(e.instrumentation,`store.cleanup.aggressive.restoreDirectoryLoadInfos`,()=>$o(e,n)),Z(e.instrumentation,`store.cleanup.aggressive.recomputeCounts`,()=>mo(e,e.snapshot.rootId))}function os(e){for(let t of e.directoryLoadInfoById.values())if(t.state===`loading`&&t.activeAttemptId!=null)return!0;return!1}function ss(e,t){let n=Jo(e);t===`stable`?Z(e.instrumentation,`store.cleanup.stable`,()=>is(e)):Z(e.instrumentation,`store.cleanup.aggressive`,()=>as(e));let r=Jo(e);return Yo(t,t===`stable`,n,r)}var cs=64;function ls(e,t){let n=t+2;if(n<=e.length)return e;let r=e.length;for(;r<n;)r*=2;let i=new Int32Array(r);return i.fill(-1),i.set(e),i}function us(e){return Q(e,e.snapshot.rootId).visibleSubtreeCount}function ds(e,t,n,r){let i=Q(e,t.terminalNodeId),a=Math.max(1,i.visibleSubtreeCount);return Math.min(r-1,n+a-1)}function fs(e,t,n,r){return{ancestorPaths:r,index:t.index,posInSet:t.posInSet,row:js(e,t.cursor),setSize:t.setSize,subtreeEndIndex:ds(e,t.cursor,t.index,n)}}function ps(e,t,n,r,i,a){let o=vo(e,t),{childIndex:s,childVisibleIndex:c,localVisibleIndex:l}=gi(e.snapshot.nodes,o,n),u=o.childIds[s];if(u==null)throw Error(`Visible index ${String(n)} is out of range`);return ms(e,u,l,r+c,i+1,s,o.childIds.length,a)}function ms(e,t,n,r,i,a,o,s){if(!X(Q(e,t))){if(n===0)return{ancestors:s,cursor:{headNodeId:t,terminalNodeId:t,visibleDepth:i},index:r,posInSet:a,setSize:o};throw Error(`Visible index ${String(n)} is out of range for file`)}let c=Ts(e,t,i);if(n===0)return{ancestors:s,cursor:c,index:r,posInSet:a,setSize:o};let l=Q(e,c.terminalNodeId);if(!X(l)||!Sa(e,c.terminalNodeId,l))throw Error(`Visible index ${String(n)} is out of range for collapsed directory`);return ps(e,c.terminalNodeId,n-1,r+1,c.visibleDepth,[...s,{cursor:c,index:r,posInSet:a,setSize:o}])}function hs(e,t){let n=us(e);if(t<0||t>=n)return null;let r=ps(e,e.snapshot.rootId,t,0,-1,[]),i=r.ancestors.map(t=>fo(e,t.cursor.terminalNodeId)),a=null;return{ancestorPaths:i,get ancestorRows(){if(a!=null)return a;let t=[],i=[];for(let a of r.ancestors){let r=fs(e,a,n,[...i]);t.push(r),i.push(r.row.path)}return a=t,a},index:r.index,posInSet:r.posInSet,row:js(e,r.cursor),setSize:r.setSize,subtreeEndIndex:ds(e,r.cursor,r.index,n)}}function gs(e,t,n){let r=e.instrumentation,i=us(e);if(i<=0||n<t)return[];let a=Math.max(0,Math.min(t,i-1)),o=Math.max(a,Math.min(n,i-1));if(r==null){if(a===0)return As(e,o+1);let t=[],n=Ss(e,a);for(let r=a;r<=o&&n!=null;r++){let r=js(e,n);t.push(r),n=Ds(e,n)}return t}let s=[],c=0,l=0,u=Z(r,`store.getVisibleSlice.selectFirstRow`,()=>Ss(e,a));for(let t=a;t<=o&&u!=null;t++){let t=Z(r,`store.getVisibleSlice.materializeRow`,()=>js(e,u));s.push(t),t.isFlattened&&(c++,l+=t.flattenedSegments?.length??0),u=Z(r,`store.getVisibleSlice.advanceCursor`,()=>Ds(e,u))}return Pi(r,`workload.visibleRowsRead`,s.length),Pi(r,`workload.flattenedRowsRead`,c),Pi(r,`workload.flattenedSegmentsRead`,l),s}function _s(e,t=us(e)){let n=e.instrumentation;return n==null?ks(e,t):Z(n,`store.getVisibleTreeProjection`,()=>ks(e,t))}function vs(e){return Os(_s(e))}function ys(e,t){let n=go(e,t);if(n==null||n===e.snapshot.rootId||X(Q(e,n))&&ro(e,n)!==n)return null;let r=0,i=n,{nodes:a,rootId:o}=e.snapshot;for(;i!==o;){let t=Q(e,i).parentId,n=vo(e,t),s=di(n).get(i);if(s==null)throw Error(`Child ${String(i)} was not found in its parent index`);if(r+=_i(a,n,s),t!==o){let n=Q(e,t),a=no(e,t);if(!Sa(e,t,n)&&a!==i)return null;ro(e,t)===t&&(r+=1)}i=t}return r}function bs(e,t){let n=go(e,t);if(n==null)throw Error(`Path does not exist: "${t}"`);let r=Q(e,n);if(!X(r))throw Error(`Path is not a directory: "${t}"`);return Sa(e,n,r)?null:(Ca(e,n,!0,r),po(e,n),Ia({affectedAncestorIds:ho(e,n),affectedNodeIds:[n],path:t,projectionChanged:!0}))}function xs(e,t){let n=go(e,t);if(n==null)throw Error(`Path does not exist: "${t}"`);let r=Q(e,n);if(!X(r))throw Error(`Path is not a directory: "${t}"`);return Sa(e,n,r)?(Ca(e,n,!1,r),po(e,n),La({affectedAncestorIds:ho(e,n),affectedNodeIds:[n],path:t,projectionChanged:!0})):null}function Ss(e,t){return t<0||t>=us(e)?null:Cs(e,e.snapshot.rootId,t,-1)}function Cs(e,t,n,r){let i=vo(e,t),a=e.instrumentation,{childIndex:o,localVisibleIndex:s}=a==null?gi(e.snapshot.nodes,i,n):Z(a,`store.getVisibleSlice.selectChildIndex`,()=>gi(e.snapshot.nodes,i,n)),c=i.childIds[o];if(c!=null)return ws(e,c,s,r+1);throw Error(`Visible index ${String(n)} is out of range`)}function ws(e,t,n,r){if(!X(Q(e,t))){if(n===0)return{headNodeId:t,terminalNodeId:t,visibleDepth:r};throw Error(`Visible index ${String(n)} is out of range for file`)}let i=Ts(e,t,r);if(n===0)return i;let a=Q(e,i.terminalNodeId);if(!X(a)||!Sa(e,i.terminalNodeId,a))throw Error(`Visible index ${String(n)} is out of range for collapsed directory`);return Cs(e,i.terminalNodeId,n-1,i.visibleDepth)}function Ts(e,t,n){return X(Q(e,t))?e.instrumentation==null?{headNodeId:t,terminalNodeId:ro(e,t),visibleDepth:n}:{headNodeId:t,terminalNodeId:Z(e.instrumentation,`store.getVisibleSlice.flatten.resolveTerminalDirectory`,()=>ro(e,t)),visibleDepth:n}:{headNodeId:t,terminalNodeId:t,visibleDepth:n}}function Es(e,t){let n=Q(e,t);if(!X(n))return!0;let r=n.parentId;return r===e.snapshot.rootId?!0:no(e,r)!==t}function Ds(e,t){let n=Q(e,t.terminalNodeId);if(X(n)){let r=vo(e,t.terminalNodeId);if(Sa(e,t.terminalNodeId,n)&&r.childIds.length>0){let n=r.childIds[0];return n==null?null:ws(e,n,0,t.visibleDepth+1)}}let r=t.terminalNodeId,i=t.visibleDepth;for(;;){let t=Q(e,r);if(r===e.snapshot.rootId)return null;let n=t.parentId,a=vo(e,n),o=di(a).get(r)??-1;if(o<0)throw Error(`Child ${String(r)} was not found in its parent index`);let s=a.childIds[o+1]??null;if(s!=null)return ws(e,s,0,i);Es(e,r)&&i--,r=n}}function Os(e){let t=e.paths.length,n=Array(t);for(let r=0;r<t;r+=1){let t=e.getParentIndex(r);n[r]={index:r,parentPath:t>=0?e.paths[t]??null:null,path:e.paths[r]??``,posInSet:e.posInSetByIndex[r]??0,setSize:e.setSizeByIndex[r]??0}}return{getParentIndex:e.getParentIndex,rows:n,get visibleIndexByPath(){return e.visibleIndexByPath}}}function ks(e,t){let n=Array(t),r=new Int32Array(t),i=new Int32Array(t),a=new Int32Array(t),o=new Int32Array(cs);o.fill(-1);let s=0,{nodes:c,directories:l,segmentTable:u}=e.snapshot,d=[[l.get(e.snapshot.rootId),0,-1,``]],f=e.snapshot.options.flattenEmptyDirectories,p=e.pathCacheByNodeId,m=e.pathCacheVersion,h=u.valueById;for(;d.length>0&&s<t;){let t=d[d.length-1],u=t[0];if(t[1]>=u.childIds.length){d.pop();continue}let g=t[1],_=u.childIds[t[1]++],v=c[_],y=t[2]+1,b=t[3];o=ls(o,y);let x,S=_;if(X(v))S=f?ro(e,_):_,x=S===_?`${b}${h[v.nameId]}/`:fo(e,S);else{let e=p.get(_);x=e!=null&&e.version===m?e.path:`${b}${h[v.nameId]}`}r[s]=o[y],n[s]=x,i[s]=g,a[s]=u.childIds.length,o[y+1]=s,s+=1;let C=c[S];C!=null&&X(C)&&Sa(e,S,C)&&d.push([l.get(S),0,y,x])}s<t&&(n.length=s);let g=r.subarray(0,s),_=i.subarray(0,s),v=a.subarray(0,s),y=null;return{getParentIndex(e){return e<0||e>=s?-1:g[e]??-1},paths:n,posInSetByIndex:_,setSizeByIndex:v,get visibleIndexByPath(){if(y==null){y=new Map;for(let e=0;e<s;e+=1)y.set(n[e]??``,e)}return y}}}function As(e,t){let n=Array(t),r=0,{nodes:i,directories:a,segmentTable:o}=e.snapshot,s=[[a.get(e.snapshot.rootId),0,-1]],c=o.valueById,l=e.snapshot.options.flattenEmptyDirectories,u=e.pathCacheByNodeId,d=e.pathCacheVersion;for(;s.length>0&&r<t;){let t=s[s.length-1],o=t[0];if(t[1]>=o.childIds.length){s.pop();continue}let f=o.childIds[t[1]++],p=i[f],m=t[2]+1;if(!X(p)){let t=u.get(f);n[r++]={depth:m,flattenedSegments:void 0,hasChildren:!1,id:f,isExpanded:!1,isFlattened:!1,isLoading:!1,kind:`file`,loadState:void 0,name:c[p.nameId],path:t!=null&&t.version===d?t.path:fo(e,f)};continue}let h=l?ro(e,f):f,g={headNodeId:f,terminalNodeId:h,visibleDepth:m};n[r++]=js(e,g);let _=i[h];_!=null&&X(_)&&Sa(e,h,_)&&s.push([a.get(h),0,m])}return r<t&&(n.length=r),n}function js(e,t){let n=Q(e,t.terminalNodeId),r=X(n)?Ms(e,t):null,i=fo(e,t.terminalNodeId),a=ea(e.snapshot.segmentTable,n.nameId),o=X(n)&&vo(e,t.terminalNodeId).childIds.length>0,s=t.headNodeId!==t.terminalNodeId,c=e.instrumentation,l=s?c==null?io(e,t.headNodeId).map(n=>{let r=Q(e,n);return{isTerminal:n===t.terminalNodeId,name:ea(e.snapshot.segmentTable,r.nameId),nodeId:n,path:fo(e,n)}}):Z(c,`store.getVisibleSlice.flatten.collectSegments`,()=>io(e,t.headNodeId).map(n=>{let r=Q(e,n);return{isTerminal:n===t.terminalNodeId,name:ea(e.snapshot.segmentTable,r.nameId),nodeId:n,path:fo(e,n)}})):void 0;return{depth:t.visibleDepth,flattenedSegments:l,hasChildren:o,id:t.terminalNodeId,isExpanded:X(n)&&Sa(e,t.terminalNodeId,n),isFlattened:s,isLoading:r===`loading`,kind:X(n)?`directory`:`file`,loadState:r==null||r===`loaded`?void 0:r,name:a,path:i}}function Ms(e,t){if(t.headNodeId===t.terminalNodeId)return Ta(e,t.terminalNodeId);let n=io(e,t.headNodeId),r=!1,i=!1;for(let t of n){let n=Ta(e,t);if(n===`loading`)return`loading`;if(n===`error`){i=!0;continue}n===`unloaded`&&(r=!0)}return i?`error`:r?`unloaded`:`loaded`}function Ns(e){let{directories:t,nodes:n,options:r,rootId:i,presortedDirectoryNodeIds:a}=e.snapshot,o=r.flattenEmptyDirectories===!0,s=e=>{let r=n[e];if(r==null||!X(r))return;let i=t.get(e);if(i==null)throw Error(`Unknown directory child index for node ${String(e)}`);let a=i.childIds,s=a.length,c=0,l=0;for(let e=0;e<s;e++){let t=a[e];if(t==null)continue;let r=n[t];c+=r.subtreeNodeCount,l+=r.visibleSubtreeCount}i.totalChildSubtreeNodeCount=c,i.totalChildVisibleSubtreeCount=l,s>=128&&vi(n,i),r.subtreeNodeCount=1+c;let u;if(o&&s===1){let e=n[a[0]];u=e!=null&&X(e)?l:1+l}else u=1+l;r.visibleSubtreeCount=u};if(a!=null)for(let e=a.length-1;e>=0;e--)s(a[e]);else for(let e=n.length-1;e>=1;e--)s(e);let c=n[i],l=t.get(i);if(c==null||l==null)return;let u=l.childIds,d=0,f=0;for(let e=0;e<u.length;e++){let t=u[e];if(t==null)continue;let r=n[t];d+=r.subtreeNodeCount,f+=r.visibleSubtreeCount}l.totalChildSubtreeNodeCount=d,l.totalChildVisibleSubtreeCount=f,vi(n,l),c.subtreeNodeCount=1+d,c.visibleSubtreeCount=f}function Ps(e){return e.initialExpansion===`open`&&(e.initialExpandedPaths==null||e.initialExpandedPaths.length===0)}var Fs=class e{#e;constructor(e={}){let t=Ni(e),n=Z(t,`store.builder.create`,()=>new _a(e));if(e.preparedInput!=null){let t=ma(e.preparedInput);t==null?n.appendPreparedPaths(pa(e.preparedInput),!1):n.appendPresortedPaths(t,ha(e.preparedInput))}else{let r=e.paths??[];e.presorted===!0?n.appendPaths(r):n.appendPreparedPaths(Z(t,`store.preparePathEntries`,()=>ga(r,e)))}let r=Z(t,`store.builder.finish`,()=>n.finish({skipSubtreeCountPass:!0})),i=Z(t,`store.state.detectAllDirectoriesExpanded`,()=>(e.initialExpansion??`closed`)===`closed`&&n.didMatchAllInitialExpandedPaths());this.#e=Z(t,`store.state.create`,()=>va(r,i?`open`:e.initialExpansion??`closed`,t)),i&&(this.#e.collapseNewDirectoriesByDefault=!0);let a=i?this.#e.snapshot.directories.size-1:Z(t,`store.state.initializeExpandedPaths`,()=>this.initializeExpandedPaths(e.initialExpandedPaths));i||Ps(e)||(e.initialExpansion??`closed`)===`closed`&&a===this.#e.snapshot.directories.size-1||(e.initialExpandedPaths?.length??0)>0&&Z(t,`store.state.checkAllDirectoriesExpanded`,()=>this.hasAllDirectoriesExpanded())?Z(t,`store.state.initializeOpenVisibleCounts`,()=>Ns(this.#e)):Z(t,`store.state.recomputeCounts`,()=>mo(this.#e,this.#e.snapshot.rootId))}static preparePaths(e,t={}){return ua(e,t)}static prepareInput(e,t={}){return da(e,t)}static preparePresortedInput(e){return fa(e)}list(e){return Z(this.#e.instrumentation,`store.list`,()=>ao(this.#e,e))}add(e){Z(this.#e.instrumentation,`store.add`,()=>{let t=us(this.#e);Ka(this.#e,Wa(this.#e,t,oo(this.#e,e)))})}remove(e,t={}){Z(this.#e.instrumentation,`store.remove`,()=>{let n=us(this.#e);Ka(this.#e,Wa(this.#e,n,so(this.#e,e,t)))})}move(e,t,n={}){Z(this.#e.instrumentation,`store.move`,()=>{let r=us(this.#e),i=co(this.#e,e,t,n);i!=null&&Ka(this.#e,Wa(this.#e,r,i))})}batch(e){Ga(this.#e,()=>{if(typeof e==`function`){e(this);return}for(let t of e)switch(t.type){case`add`:this.add(t.path);break;case`remove`:this.remove(t.path,{recursive:t.recursive});break;case`move`:this.move(t.from,t.to,{collision:t.collision});break}})}getVisibleCount(){return Z(this.#e.instrumentation,`store.getVisibleCount`,()=>us(this.#e))}getVisibleSlice(e,t){return Z(this.#e.instrumentation,`store.getVisibleSlice`,()=>gs(this.#e,e,t))}getVisibleRowContext(e){return Z(this.#e.instrumentation,`store.getVisibleRowContext`,()=>hs(this.#e,e))}getVisibleTreeProjection(){return vs(this.#e)}getVisibleTreeProjectionData(e){return _s(this.#e,e)}getVisibleIndex(e){return Z(this.#e.instrumentation,`store.getVisibleIndex`,()=>ys(this.#e,e))}getPathInfo(e){return Z(this.#e.instrumentation,`store.getPathInfo`,()=>{let t=go(this.#e,e);if(t==null)return null;let n=Q(this.#e,t);return{depth:Ti(n),kind:X(n)?`directory`:`file`,path:fo(this.#e,t)}})}isExpanded(e){return Z(this.#e.instrumentation,`store.isExpanded`,()=>{let t=this.requireDirectoryNodeId(e),n=Q(this.#e,t);return Sa(this.#e,t,n)})}expand(e){Z(this.#e.instrumentation,`store.expand`,()=>{let t=us(this.#e),n=bs(this.#e,e);n!=null&&Ka(this.#e,Wa(this.#e,t,n))})}collapse(e){Z(this.#e.instrumentation,`store.collapse`,()=>{let t=us(this.#e),n=xs(this.#e,e);n!=null&&Ka(this.#e,Wa(this.#e,t,n))})}on(e,t){return Ma(this.#e,e,t)}getDirectoryLoadState(e){let t=this.requireDirectoryNodeId(e);return Ta(this.#e,t)}markDirectoryUnloaded(e){Z(this.#e.instrumentation,`store.markDirectoryUnloaded`,()=>{let t=this.requireDirectoryNodeId(e);if(vo(this.#e,t).childIds.length>0)throw Error(`Cannot mark a directory with known children as unloaded: "${e}"`);let n=us(this.#e);Da(this.#e,t),Ka(this.#e,Wa(this.#e,n,Ra({affectedAncestorIds:ho(this.#e,t),affectedNodeIds:[t],path:e,projectionChanged:this.isDirectoryProjectionVisible(t)})))})}beginChildLoad(e){return Z(this.#e.instrumentation,`store.beginChildLoad`,()=>{let t=this.requireDirectoryNodeId(e),n=us(this.#e),r=Ea(this.#e,t);return Ka(this.#e,Wa(this.#e,n,za({affectedAncestorIds:ho(this.#e,t),affectedNodeIds:[t],attemptId:r.attemptId,path:e,projectionChanged:this.isDirectoryProjectionVisible(t),reused:r.reused}))),r})}applyChildPatch(e,t){return Z(this.#e.instrumentation,`store.applyChildPatch`,()=>{let n=this.resolveActiveDirectoryNodeId(e.nodeId);if(n==null||Ta(this.#e,n)!==`loading`||!ka(this.#e,n,e.attemptId))return!1;let r=fo(this.#e,n);this.validateChildPatch(r,t);let i=us(this.#e),a=[];for(let e of t.operations){Is(r,e);let t=us(this.#e);switch(e.type){case`add`:a.push(Wa(this.#e,t,oo(this.#e,e.path)));break;case`remove`:a.push(Wa(this.#e,t,so(this.#e,e.path,{recursive:e.recursive})));break;case`move`:{let n=co(this.#e,e.from,e.to,{collision:e.collision});n!=null&&a.push(Wa(this.#e,t,n));break}}}let o=a.some(e=>e.projectionChanged)||this.isDirectoryProjectionVisible(n);return Ka(this.#e,Wa(this.#e,i,Ba({affectedAncestorIds:ho(this.#e,n),affectedNodeIds:[n],attemptId:e.attemptId,childEvents:a,path:fo(this.#e,n),projectionChanged:o}))),!0})}completeChildLoad(e){return Z(this.#e.instrumentation,`store.completeChildLoad`,()=>{let t=this.resolveActiveDirectoryNodeId(e.nodeId);if(t==null)return!1;let n=us(this.#e),r=Oa(this.#e,t,e.attemptId);return Ka(this.#e,Wa(this.#e,n,Va({affectedAncestorIds:ho(this.#e,t),affectedNodeIds:[t],attemptId:e.attemptId,path:fo(this.#e,t),projectionChanged:this.isDirectoryProjectionVisible(t),stale:!r}))),r})}failChildLoad(e,t){return Z(this.#e.instrumentation,`store.failChildLoad`,()=>{let n=this.resolveActiveDirectoryNodeId(e.nodeId);if(n==null)return!1;let r=us(this.#e),i=Aa(this.#e,n,e.attemptId,t);return Ka(this.#e,Wa(this.#e,r,Ha({affectedAncestorIds:ho(this.#e,n),affectedNodeIds:[n],attemptId:e.attemptId,errorMessage:t,path:fo(this.#e,n),projectionChanged:this.isDirectoryProjectionVisible(n),stale:!i}))),i})}cleanup(e={}){return Z(this.#e.instrumentation,`store.cleanup`,()=>{if(this.#e.transactionStack.length>0)throw Error(`Cleanup cannot run during an open batch or transaction.`);if(os(this.#e))throw Error(`Cleanup cannot run while directory loads are active.`);let t=us(this.#e),n=ss(this.#e,e.mode??`stable`);return Ka(this.#e,Wa(this.#e,t,Ua({...n,affectedAncestorIds:[],affectedNodeIds:[],projectionChanged:n.idsPreserved===!1}))),n})}getNodeCount(){return this.#e.activeNodeCount}initializeExpandedPaths(e){if(e==null||e.length===0)return 0;let t=0,n=[],r=[],i=0,a=null,o=this.#e.snapshot.segmentTable,s=o.valueById,c=this.#e.snapshot.nodes,l=new Map;for(let u of e){a!=null&&u<a&&(a=null,i=0,n.length=0,r.length=0);let e=u.length>0&&u.charCodeAt(u.length-1)===47?u.length-1:u.length;if(e===0){a=u,i=e,n.length=0,r.length=0;continue}let d=0,f=0;if(a!=null){let t=Math.min(e,i),n=!0;for(let e=0;e<t;e+=1){let t=u.charCodeAt(e);if(t!==a.charCodeAt(e)){n=!1;break}t===47&&(d+=1,f=e+1)}n&&(t===i&&e>t&&u.charCodeAt(t)===47?(d+=1,f=t+1):t===e&&i>t&&a.charCodeAt(t)===47&&(d+=1,f=e+1)),d=Math.min(d,r.length)}let p=d===0?this.#e.snapshot.rootId:r[d-1]??this.#e.snapshot.rootId,m=d,h=!0,g=f;for(;g<=e;){let t=u.indexOf(`/`,g),i=t===-1||t>e?e:t,a=u.slice(g,i),f=vo(this.#e,p).childIds,_=m===d?n[m]??0:0,v=_,y,b=l.get(a)??Li(a);l.set(a,b);let x=(e,t)=>{for(v=e;v<t;v+=1){let e=f[v],t=c[e],n=s[t.nameId];if(n===a)return y=e,!0;let r=zi(Ki(o,t.nameId),b);if(r>0||r===0&&n>a)return!1}return!1};if(!x(_,f.length)&&_>0&&x(0,_),y===void 0){h=!1;break}if(!X(Q(this.#e,y))){h=!1;break}if(n[m]=v,r[m]=y,p=y,m+=1,i===e)break;g=i+1}if(a=u,i=e,n.length=m,r.length=m,!h){a=null,i=0,n.length=0,r.length=0;continue}for(let e=d;e<m;e+=1){let n=r[e];if(n==null)continue;let i=Q(this.#e,n);Sa(this.#e,n,i)||(Ca(this.#e,n,!0,i),t+=1)}}return t}hasAllDirectoriesExpanded(){for(let e of this.#e.snapshot.directories.keys()){if(e===this.#e.snapshot.rootId)continue;let t=Q(this.#e,e);if(!Sa(this.#e,e,t))return!1}return!0}requireDirectoryNodeId(e){let t=go(this.#e,e);if(t==null)throw Error(`Path does not exist: "${e}"`);if(!X(Q(this.#e,t)))throw Error(`Path is not a directory: "${e}"`);return t}resolveActiveDirectoryNodeId(e){try{if(!X(Q(this.#e,e)))throw Error(`Node is not a directory: ${String(e)}`);return e}catch{return null}}isDirectoryProjectionVisible(e){let t=e;for(;t!==this.#e.snapshot.rootId;){let e=Q(this.#e,t).parentId;if(e!==this.#e.snapshot.rootId){let n=Q(this.#e,e),r=no(this.#e,e);if(!Sa(this.#e,e,n)&&r!==t)return!1}t=e}return!0}validateChildPatch(t,n){new e({paths:this.list(t),presorted:!0,sort:this.#e.snapshot.options.sort}).batch(n.operations)}};function Is(e,t){switch(t.type){case`add`:case`remove`:if(!t.path.startsWith(e)||t.path===e)throw Error(`Child patch operation must stay within ${e}: "${t.path}"`);break;case`move`:if(!t.from.startsWith(e)||!t.to.startsWith(e)||t.from===e||t.to===e)throw Error(`Child patch move must stay within ${e}: "${t.from}" -> "${t.to}"`);break}}var Ls={compact:{itemHeight:24,factor:.8},default:{itemHeight:30,factor:1},relaxed:{itemHeight:36,factor:1.2}};function Rs(e,t){if(typeof e==`number`)return{itemHeight:t??Ls.default.itemHeight,factor:e};let n=Ls[e??`default`];return{itemHeight:t??n.itemHeight,factor:n.factor}}var zs=Ls.default.itemHeight,Bs=`@layer base, theme, unsafe;
|
|
165
|
+
|
|
166
|
+
@layer base {
|
|
167
|
+
:host {
|
|
168
|
+
/*
|
|
169
|
+
CSS variables use a fallback stack to ensure user and theme colors slot
|
|
170
|
+
in with ease. User colors take precedence over theme colors, which take
|
|
171
|
+
precedence over defaults.
|
|
172
|
+
|
|
173
|
+
Fallback order:
|
|
174
|
+
|
|
175
|
+
1. --trees-*-override (explicit)
|
|
176
|
+
2. --trees-theme-* (e.g. Shiki/VS Code tokens)
|
|
177
|
+
3. defaults
|
|
178
|
+
|
|
179
|
+
Theme variable names mirror Shiki/VS Code theme file JSON tokens.
|
|
180
|
+
|
|
181
|
+
// Available CSS Color Overrides
|
|
182
|
+
--trees-fg-override
|
|
183
|
+
--trees-fg-muted-override
|
|
184
|
+
--trees-bg-override
|
|
185
|
+
--trees-bg-muted-override
|
|
186
|
+
--trees-accent-override
|
|
187
|
+
--trees-border-color-override
|
|
188
|
+
|
|
189
|
+
--trees-focus-ring-color-override
|
|
190
|
+
--trees-focus-ring-width-override
|
|
191
|
+
--trees-focus-ring-offset-override
|
|
192
|
+
|
|
193
|
+
--trees-search-fg-override
|
|
194
|
+
--trees-search-font-weight-override
|
|
195
|
+
--trees-search-bg-override
|
|
196
|
+
|
|
197
|
+
--trees-selected-fg-override
|
|
198
|
+
--trees-selected-bg-override
|
|
199
|
+
--trees-selected-focused-border-color-override
|
|
200
|
+
|
|
201
|
+
// Git Status Color Overrides
|
|
202
|
+
--trees-status-added-override
|
|
203
|
+
--trees-status-ignored-override
|
|
204
|
+
--trees-status-modified-override
|
|
205
|
+
--trees-status-renamed-override
|
|
206
|
+
--trees-status-untracked-override
|
|
207
|
+
--trees-status-deleted-override
|
|
208
|
+
--trees-git-added-color-override
|
|
209
|
+
--trees-git-ignored-color-override
|
|
210
|
+
--trees-git-modified-color-override
|
|
211
|
+
--trees-git-renamed-color-override
|
|
212
|
+
--trees-git-untracked-color-override
|
|
213
|
+
--trees-git-deleted-color-override
|
|
214
|
+
|
|
215
|
+
// Built-in File Icon Color Overrides
|
|
216
|
+
--trees-file-icon-color
|
|
217
|
+
--trees-file-icon-color-astro
|
|
218
|
+
--trees-file-icon-color-babel
|
|
219
|
+
--trees-file-icon-color-bash
|
|
220
|
+
--trees-file-icon-color-biome
|
|
221
|
+
--trees-file-icon-color-bootstrap
|
|
222
|
+
--trees-file-icon-color-browserslist
|
|
223
|
+
--trees-file-icon-color-bun
|
|
224
|
+
--trees-file-icon-color-claude
|
|
225
|
+
--trees-file-icon-color-css
|
|
226
|
+
--trees-file-icon-color-database
|
|
227
|
+
--trees-file-icon-color-default
|
|
228
|
+
--trees-file-icon-color-docker
|
|
229
|
+
--trees-file-icon-color-eslint
|
|
230
|
+
--trees-file-icon-color-git
|
|
231
|
+
--trees-file-icon-color-go
|
|
232
|
+
--trees-file-icon-color-graphql
|
|
233
|
+
--trees-file-icon-color-html
|
|
234
|
+
--trees-file-icon-color-image
|
|
235
|
+
--trees-file-icon-color-javascript
|
|
236
|
+
--trees-file-icon-color-json
|
|
237
|
+
--trees-file-icon-color-markdown
|
|
238
|
+
--trees-file-icon-color-mcp
|
|
239
|
+
--trees-file-icon-color-npm
|
|
240
|
+
--trees-file-icon-color-oxc
|
|
241
|
+
--trees-file-icon-color-postcss
|
|
242
|
+
--trees-file-icon-color-prettier
|
|
243
|
+
--trees-file-icon-color-python
|
|
244
|
+
--trees-file-icon-color-react
|
|
245
|
+
--trees-file-icon-color-ruby
|
|
246
|
+
--trees-file-icon-color-rust
|
|
247
|
+
--trees-file-icon-color-sass
|
|
248
|
+
--trees-file-icon-color-svg
|
|
249
|
+
--trees-file-icon-color-svelte
|
|
250
|
+
--trees-file-icon-color-svgo
|
|
251
|
+
--trees-file-icon-color-swift
|
|
252
|
+
--trees-file-icon-color-table
|
|
253
|
+
--trees-file-icon-color-text
|
|
254
|
+
--trees-file-icon-color-tailwind
|
|
255
|
+
--trees-file-icon-color-terraform
|
|
256
|
+
--trees-file-icon-color-typescript
|
|
257
|
+
--trees-file-icon-color-vite
|
|
258
|
+
--trees-file-icon-color-vscode
|
|
259
|
+
--trees-file-icon-color-vue
|
|
260
|
+
--trees-file-icon-color-wasm
|
|
261
|
+
--trees-file-icon-color-webpack
|
|
262
|
+
--trees-file-icon-color-yml
|
|
263
|
+
--trees-file-icon-color-zig
|
|
264
|
+
--trees-file-icon-color-zip
|
|
265
|
+
|
|
266
|
+
// Density
|
|
267
|
+
//
|
|
268
|
+
// A unitless scale factor for padding, gaps, and indentation. Usually
|
|
269
|
+
// set via \`density\` on useFileTree. Individual overrides take precedence.
|
|
270
|
+
//
|
|
271
|
+
// Compact: 0.8
|
|
272
|
+
// Default: 1
|
|
273
|
+
// Relaxed: 1.2
|
|
274
|
+
//
|
|
275
|
+
--trees-density-override
|
|
276
|
+
|
|
277
|
+
// Available CSS Layout Overrides
|
|
278
|
+
--trees-gap-override
|
|
279
|
+
--trees-border-radius-override
|
|
280
|
+
--trees-font-family-override
|
|
281
|
+
--trees-font-size-override
|
|
282
|
+
--trees-font-weight-regular-override
|
|
283
|
+
--trees-font-weight-semibold-override
|
|
284
|
+
--trees-level-gap-override
|
|
285
|
+
--trees-item-padding-x-override
|
|
286
|
+
--trees-item-margin-x-override
|
|
287
|
+
--trees-item-row-gap-override
|
|
288
|
+
--trees-icon-width-override
|
|
289
|
+
--trees-icon-nudge-override
|
|
290
|
+
--trees-scrollbar-gutter-override
|
|
291
|
+
--trees-padding-inline-override
|
|
292
|
+
*/
|
|
293
|
+
|
|
294
|
+
--trees-accent: var(--trees-accent-override, #009fff);
|
|
295
|
+
--trees-fg: var(
|
|
296
|
+
--trees-fg-override,
|
|
297
|
+
var(--trees-theme-sidebar-fg, light-dark(#6c6c71, #adadb1))
|
|
298
|
+
);
|
|
299
|
+
--trees-fg-muted: var(
|
|
300
|
+
--trees-fg-muted-override,
|
|
301
|
+
var(--trees-theme-sidebar-header-fg, light-dark(#84848a, #84848a))
|
|
302
|
+
);
|
|
303
|
+
--trees-bg: var(
|
|
304
|
+
--trees-bg-override,
|
|
305
|
+
var(--trees-theme-sidebar-bg, light-dark(#f8f8f8, #141415))
|
|
306
|
+
);
|
|
307
|
+
/* var(--trees-theme-list-hover-bg, light-dark(#dfebff59, #19283c59)) */
|
|
308
|
+
--trees-bg-muted: var(
|
|
309
|
+
--trees-bg-muted-override,
|
|
310
|
+
var(
|
|
311
|
+
--trees-theme-list-hover-bg,
|
|
312
|
+
light-dark(
|
|
313
|
+
color-mix(
|
|
314
|
+
in lab,
|
|
315
|
+
var(--trees-accent) var(--trees-bg-alpha-light, 8%),
|
|
316
|
+
var(--trees-bg)
|
|
317
|
+
),
|
|
318
|
+
color-mix(
|
|
319
|
+
in lab,
|
|
320
|
+
var(--trees-accent) var(--trees-bg-alpha-dark, 10%),
|
|
321
|
+
var(--trees-bg)
|
|
322
|
+
)
|
|
323
|
+
)
|
|
324
|
+
)
|
|
325
|
+
);
|
|
326
|
+
--trees-input-bg: var(
|
|
327
|
+
--trees-input-bg-override,
|
|
328
|
+
light-dark(#f8f8f8, #070707)
|
|
329
|
+
);
|
|
330
|
+
|
|
331
|
+
--trees-added-light: #16a994;
|
|
332
|
+
--trees-added-dark: #00cab1;
|
|
333
|
+
--trees-ignored-light: #adadb1;
|
|
334
|
+
--trees-ignored-dark: #4a4a4e;
|
|
335
|
+
--trees-modified-light: #1ca1c7;
|
|
336
|
+
--trees-modified-dark: #08c0ef;
|
|
337
|
+
--trees-renamed-light: #d5a910;
|
|
338
|
+
--trees-renamed-dark: #ffd452;
|
|
339
|
+
--trees-untracked-light: #16a994;
|
|
340
|
+
--trees-untracked-dark: #00cab1;
|
|
341
|
+
--trees-deleted-light: #ff2e3f;
|
|
342
|
+
--trees-deleted-dark: #ff6762;
|
|
343
|
+
|
|
344
|
+
--trees-border-color: var(
|
|
345
|
+
--trees-border-color-override,
|
|
346
|
+
var(--trees-theme-sidebar-border, light-dark(#eeeeef, #070707))
|
|
347
|
+
);
|
|
348
|
+
--trees-indent-guide-bg: var(
|
|
349
|
+
--trees-indent-guide-bg-override,
|
|
350
|
+
color-mix(in lab, var(--trees-fg-muted) 25%, transparent)
|
|
351
|
+
);
|
|
352
|
+
--trees-density: var(--trees-density-override, 1);
|
|
353
|
+
--trees-border-radius: var(
|
|
354
|
+
--trees-border-radius-override,
|
|
355
|
+
calc(6px * var(--trees-density))
|
|
356
|
+
);
|
|
357
|
+
|
|
358
|
+
--trees-font-family: var(--trees-font-family-override, system-ui);
|
|
359
|
+
--trees-font-size: var(--trees-font-size-override, 13px);
|
|
360
|
+
--trees-font-weight-regular: var(--trees-font-weight-regular-override, 400);
|
|
361
|
+
--trees-font-weight-semibold: var(
|
|
362
|
+
--trees-font-weight-semibold-override,
|
|
363
|
+
600
|
|
364
|
+
);
|
|
365
|
+
|
|
366
|
+
--trees-focus-ring-color: var(
|
|
367
|
+
--trees-focus-ring-color-override,
|
|
368
|
+
var(--trees-theme-focus-ring, var(--trees-accent))
|
|
369
|
+
);
|
|
370
|
+
--trees-focus-ring-width: var(--trees-focus-ring-width-override, 1px);
|
|
371
|
+
--trees-focus-ring-offset: var(--trees-focus-ring-offset-override, -1px);
|
|
372
|
+
|
|
373
|
+
--trees-search-fg: var(
|
|
374
|
+
--trees-search-fg-override,
|
|
375
|
+
var(--trees-theme-input-fg, var(--trees-fg))
|
|
376
|
+
);
|
|
377
|
+
--trees-search-font-weight: var(--trees-search-font-weight-override, 600);
|
|
378
|
+
--trees-search-bg: var(
|
|
379
|
+
--trees-search-bg-override,
|
|
380
|
+
var(--trees-theme-input-bg, var(--trees-input-bg))
|
|
381
|
+
);
|
|
382
|
+
|
|
383
|
+
--trees-scrollbar-thumb: var(
|
|
384
|
+
--trees-scrollbar-thumb-override,
|
|
385
|
+
var(
|
|
386
|
+
--trees-theme-scrollbar-thumb,
|
|
387
|
+
color-mix(in lab, var(--trees-fg) 25%, var(--trees-bg))
|
|
388
|
+
)
|
|
389
|
+
);
|
|
390
|
+
|
|
391
|
+
--trees-selected-fg: var(
|
|
392
|
+
--trees-selected-fg-override,
|
|
393
|
+
var(--trees-theme-list-active-selection-fg, var(--trees-fg))
|
|
394
|
+
);
|
|
395
|
+
--trees-selected-bg: var(
|
|
396
|
+
--trees-selected-bg-override,
|
|
397
|
+
var(
|
|
398
|
+
--trees-theme-list-active-selection-bg,
|
|
399
|
+
light-dark(
|
|
400
|
+
color-mix(in lab, var(--trees-accent) 12%, var(--trees-bg)),
|
|
401
|
+
color-mix(in lab, var(--trees-accent) 15%, var(--trees-bg))
|
|
402
|
+
)
|
|
403
|
+
)
|
|
404
|
+
);
|
|
405
|
+
--trees-selected-focused-border-color: var(
|
|
406
|
+
--trees-selected-focused-border-color-override,
|
|
407
|
+
var(--trees-theme-focus-ring, var(--trees-accent))
|
|
408
|
+
);
|
|
409
|
+
|
|
410
|
+
/* Git status (e.g. from Shiki theme gitDecoration.*) */
|
|
411
|
+
--trees-status-added: var(
|
|
412
|
+
--trees-status-added-override,
|
|
413
|
+
var(
|
|
414
|
+
--trees-theme-git-added-fg,
|
|
415
|
+
light-dark(var(--trees-added-light), var(--trees-added-dark))
|
|
416
|
+
)
|
|
417
|
+
);
|
|
418
|
+
--trees-status-ignored: var(
|
|
419
|
+
--trees-status-ignored-override,
|
|
420
|
+
var(
|
|
421
|
+
--trees-theme-git-ignored-fg,
|
|
422
|
+
light-dark(var(--trees-ignored-light), var(--trees-ignored-dark))
|
|
423
|
+
)
|
|
424
|
+
);
|
|
425
|
+
--trees-status-modified: var(
|
|
426
|
+
--trees-status-modified-override,
|
|
427
|
+
var(
|
|
428
|
+
--trees-theme-git-modified-fg,
|
|
429
|
+
light-dark(var(--trees-modified-light), var(--trees-modified-dark))
|
|
430
|
+
)
|
|
431
|
+
);
|
|
432
|
+
--trees-status-renamed: var(
|
|
433
|
+
--trees-status-renamed-override,
|
|
434
|
+
var(
|
|
435
|
+
--trees-theme-git-renamed-fg,
|
|
436
|
+
light-dark(var(--trees-renamed-light), var(--trees-renamed-dark))
|
|
437
|
+
)
|
|
438
|
+
);
|
|
439
|
+
--trees-status-untracked: var(
|
|
440
|
+
--trees-status-untracked-override,
|
|
441
|
+
var(
|
|
442
|
+
--trees-theme-git-untracked-fg,
|
|
443
|
+
light-dark(var(--trees-untracked-light), var(--trees-untracked-dark))
|
|
444
|
+
)
|
|
445
|
+
);
|
|
446
|
+
--trees-status-deleted: var(
|
|
447
|
+
--trees-status-deleted-override,
|
|
448
|
+
var(
|
|
449
|
+
--trees-theme-git-deleted-fg,
|
|
450
|
+
light-dark(var(--trees-deleted-light), var(--trees-deleted-dark))
|
|
451
|
+
)
|
|
452
|
+
);
|
|
453
|
+
--trees-git-modified-color: var(
|
|
454
|
+
--trees-git-modified-color-override,
|
|
455
|
+
var(--trees-status-modified)
|
|
456
|
+
);
|
|
457
|
+
--trees-git-added-color: var(
|
|
458
|
+
--trees-git-added-color-override,
|
|
459
|
+
var(--trees-status-added)
|
|
460
|
+
);
|
|
461
|
+
--trees-git-ignored-color: var(
|
|
462
|
+
--trees-git-ignored-color-override,
|
|
463
|
+
var(--trees-status-ignored)
|
|
464
|
+
);
|
|
465
|
+
--trees-git-deleted-color: var(
|
|
466
|
+
--trees-git-deleted-color-override,
|
|
467
|
+
var(--trees-status-deleted)
|
|
468
|
+
);
|
|
469
|
+
--trees-git-renamed-color: var(
|
|
470
|
+
--trees-git-renamed-color-override,
|
|
471
|
+
var(--trees-status-renamed)
|
|
472
|
+
);
|
|
473
|
+
--trees-git-untracked-color: var(
|
|
474
|
+
--trees-git-untracked-color-override,
|
|
475
|
+
var(--trees-status-untracked)
|
|
476
|
+
);
|
|
477
|
+
|
|
478
|
+
--trees-icon-gray: light-dark(#84848a, #adadb1);
|
|
479
|
+
--trees-icon-red: light-dark(#d52c36, #ff6762);
|
|
480
|
+
--trees-icon-vermilion: light-dark(#ff8c5b, #d5512f);
|
|
481
|
+
--trees-icon-orange: light-dark(#d47628, #ffa359);
|
|
482
|
+
--trees-icon-yellow: light-dark(#d5a910, #ffd452);
|
|
483
|
+
--trees-icon-green: light-dark(#199f43, #5ecc71);
|
|
484
|
+
--trees-icon-teal: light-dark(#17a5af, #64d1db);
|
|
485
|
+
--trees-icon-cyan: light-dark(#1ca1c7, #68cdf2);
|
|
486
|
+
--trees-icon-blue: light-dark(#1a85d4, #69b1ff);
|
|
487
|
+
--trees-icon-indigo: light-dark(#693acf, #9d6afb);
|
|
488
|
+
--trees-icon-purple: light-dark(#a631be, #d568ea);
|
|
489
|
+
--trees-icon-pink: light-dark(#d32a61, #ff678d);
|
|
490
|
+
--trees-icon-mauve: light-dark(#594c5b, #79697b);
|
|
491
|
+
|
|
492
|
+
--trees-file-icon-color-default: var(
|
|
493
|
+
--trees-file-icon-color,
|
|
494
|
+
var(--trees-icon-gray)
|
|
495
|
+
);
|
|
496
|
+
--trees-file-icon-color-astro: var(
|
|
497
|
+
--trees-file-icon-color,
|
|
498
|
+
var(--trees-icon-purple)
|
|
499
|
+
);
|
|
500
|
+
--trees-file-icon-color-babel: var(
|
|
501
|
+
--trees-file-icon-color,
|
|
502
|
+
var(--trees-icon-yellow)
|
|
503
|
+
);
|
|
504
|
+
--trees-file-icon-color-bash: var(
|
|
505
|
+
--trees-file-icon-color,
|
|
506
|
+
var(--trees-icon-green)
|
|
507
|
+
);
|
|
508
|
+
--trees-file-icon-color-biome: var(
|
|
509
|
+
--trees-file-icon-color,
|
|
510
|
+
var(--trees-icon-blue)
|
|
511
|
+
);
|
|
512
|
+
--trees-file-icon-color-bootstrap: var(
|
|
513
|
+
--trees-file-icon-color,
|
|
514
|
+
var(--trees-icon-indigo)
|
|
515
|
+
);
|
|
516
|
+
--trees-file-icon-color-browserslist: var(
|
|
517
|
+
--trees-file-icon-color,
|
|
518
|
+
var(--trees-icon-yellow)
|
|
519
|
+
);
|
|
520
|
+
--trees-file-icon-color-bun: var(
|
|
521
|
+
--trees-file-icon-color,
|
|
522
|
+
var(--trees-icon-mauve)
|
|
523
|
+
);
|
|
524
|
+
--trees-file-icon-color-claude: var(
|
|
525
|
+
--trees-file-icon-color,
|
|
526
|
+
var(--trees-icon-orange)
|
|
527
|
+
);
|
|
528
|
+
--trees-file-icon-color-css: var(
|
|
529
|
+
--trees-file-icon-color,
|
|
530
|
+
var(--trees-icon-indigo)
|
|
531
|
+
);
|
|
532
|
+
--trees-file-icon-color-database: var(
|
|
533
|
+
--trees-file-icon-color,
|
|
534
|
+
var(--trees-icon-purple)
|
|
535
|
+
);
|
|
536
|
+
--trees-file-icon-color-docker: var(
|
|
537
|
+
--trees-file-icon-color,
|
|
538
|
+
var(--trees-icon-blue)
|
|
539
|
+
);
|
|
540
|
+
--trees-file-icon-color-eslint: var(
|
|
541
|
+
--trees-file-icon-color,
|
|
542
|
+
var(--trees-icon-indigo)
|
|
543
|
+
);
|
|
544
|
+
--trees-file-icon-color-git: var(
|
|
545
|
+
--trees-file-icon-vermilion,
|
|
546
|
+
var(--trees-icon-vermilion)
|
|
547
|
+
);
|
|
548
|
+
--trees-file-icon-color-go: var(
|
|
549
|
+
--trees-file-icon-color,
|
|
550
|
+
var(--trees-icon-cyan)
|
|
551
|
+
);
|
|
552
|
+
--trees-file-icon-color-graphql: var(
|
|
553
|
+
--trees-file-icon-color,
|
|
554
|
+
var(--trees-icon-pink)
|
|
555
|
+
);
|
|
556
|
+
--trees-file-icon-color-html: var(
|
|
557
|
+
--trees-file-icon-color,
|
|
558
|
+
var(--trees-icon-orange)
|
|
559
|
+
);
|
|
560
|
+
--trees-file-icon-color-image: var(
|
|
561
|
+
--trees-file-icon-color,
|
|
562
|
+
var(--trees-icon-pink)
|
|
563
|
+
);
|
|
564
|
+
--trees-file-icon-color-javascript: var(
|
|
565
|
+
--trees-file-icon-color,
|
|
566
|
+
var(--trees-icon-yellow)
|
|
567
|
+
);
|
|
568
|
+
--trees-file-icon-color-json: var(
|
|
569
|
+
--trees-file-icon-color,
|
|
570
|
+
var(--trees-icon-orange)
|
|
571
|
+
);
|
|
572
|
+
--trees-file-icon-color-markdown: var(
|
|
573
|
+
--trees-file-icon-color,
|
|
574
|
+
var(--trees-icon-green)
|
|
575
|
+
);
|
|
576
|
+
--trees-file-icon-color-mcp: var(
|
|
577
|
+
--trees-file-icon-color,
|
|
578
|
+
var(--trees-icon-teal)
|
|
579
|
+
);
|
|
580
|
+
--trees-file-icon-color-npm: var(
|
|
581
|
+
--trees-file-icon-color,
|
|
582
|
+
var(--trees-icon-red)
|
|
583
|
+
);
|
|
584
|
+
--trees-file-icon-color-oxc: var(
|
|
585
|
+
--trees-file-icon-cyan,
|
|
586
|
+
var(--trees-icon-cyan)
|
|
587
|
+
);
|
|
588
|
+
--trees-file-icon-color-postcss: var(
|
|
589
|
+
--trees-file-icon-color,
|
|
590
|
+
var(--trees-icon-red)
|
|
591
|
+
);
|
|
592
|
+
--trees-file-icon-color-prettier: var(
|
|
593
|
+
--trees-file-icon-color,
|
|
594
|
+
var(--trees-icon-teal)
|
|
595
|
+
);
|
|
596
|
+
--trees-file-icon-color-python: var(
|
|
597
|
+
--trees-file-icon-color,
|
|
598
|
+
var(--trees-icon-blue)
|
|
599
|
+
);
|
|
600
|
+
--trees-file-icon-color-react: var(
|
|
601
|
+
--trees-file-icon-color,
|
|
602
|
+
var(--trees-icon-cyan)
|
|
603
|
+
);
|
|
604
|
+
--trees-file-icon-color-ruby: var(
|
|
605
|
+
--trees-file-icon-color,
|
|
606
|
+
var(--trees-icon-red)
|
|
607
|
+
);
|
|
608
|
+
--trees-file-icon-color-rust: var(
|
|
609
|
+
--trees-file-icon-color,
|
|
610
|
+
var(--trees-icon-orange)
|
|
611
|
+
);
|
|
612
|
+
--trees-file-icon-color-sass: var(
|
|
613
|
+
--trees-file-icon-color,
|
|
614
|
+
var(--trees-icon-pink)
|
|
615
|
+
);
|
|
616
|
+
--trees-file-icon-color-svg: var(
|
|
617
|
+
--trees-file-icon-color,
|
|
618
|
+
var(--trees-icon-orange)
|
|
619
|
+
);
|
|
620
|
+
--trees-file-icon-color-svelte: var(
|
|
621
|
+
--trees-file-icon-color,
|
|
622
|
+
var(--trees-icon-red)
|
|
623
|
+
);
|
|
624
|
+
--trees-file-icon-color-svgo: var(
|
|
625
|
+
--trees-file-icon-color,
|
|
626
|
+
var(--trees-icon-green)
|
|
627
|
+
);
|
|
628
|
+
--trees-file-icon-color-swift: var(
|
|
629
|
+
--trees-file-icon-color,
|
|
630
|
+
var(--trees-icon-orange)
|
|
631
|
+
);
|
|
632
|
+
--trees-file-icon-color-table: var(
|
|
633
|
+
--trees-file-icon-color,
|
|
634
|
+
var(--trees-icon-teal)
|
|
635
|
+
);
|
|
636
|
+
--trees-file-icon-color-text: var(
|
|
637
|
+
--trees-file-icon-color,
|
|
638
|
+
var(--trees-icon-gray)
|
|
639
|
+
);
|
|
640
|
+
--trees-file-icon-color-tailwind: var(
|
|
641
|
+
--trees-file-icon-color,
|
|
642
|
+
var(--trees-icon-cyan)
|
|
643
|
+
);
|
|
644
|
+
--trees-file-icon-color-terraform: var(
|
|
645
|
+
--trees-file-icon-color,
|
|
646
|
+
var(--trees-icon-indigo)
|
|
647
|
+
);
|
|
648
|
+
--trees-file-icon-color-typescript: var(
|
|
649
|
+
--trees-file-icon-color,
|
|
650
|
+
var(--trees-icon-blue)
|
|
651
|
+
);
|
|
652
|
+
--trees-file-icon-color-vite: var(
|
|
653
|
+
--trees-file-icon-color,
|
|
654
|
+
var(--trees-icon-purple)
|
|
655
|
+
);
|
|
656
|
+
--trees-file-icon-color-vscode: var(
|
|
657
|
+
--trees-file-icon-color,
|
|
658
|
+
var(--trees-icon-blue)
|
|
659
|
+
);
|
|
660
|
+
--trees-file-icon-color-vue: var(
|
|
661
|
+
--trees-file-icon-color,
|
|
662
|
+
var(--trees-icon-green)
|
|
663
|
+
);
|
|
664
|
+
--trees-file-icon-color-wasm: var(
|
|
665
|
+
--trees-file-icon-color,
|
|
666
|
+
var(--trees-icon-indigo)
|
|
667
|
+
);
|
|
668
|
+
--trees-file-icon-color-webpack: var(
|
|
669
|
+
--trees-file-icon-color,
|
|
670
|
+
var(--trees-icon-blue)
|
|
671
|
+
);
|
|
672
|
+
--trees-file-icon-color-yml: var(
|
|
673
|
+
--trees-file-icon-color,
|
|
674
|
+
var(--trees-icon-red)
|
|
675
|
+
);
|
|
676
|
+
--trees-file-icon-color-zig: var(
|
|
677
|
+
--trees-file-icon-color,
|
|
678
|
+
var(--trees-icon-orange)
|
|
679
|
+
);
|
|
680
|
+
--trees-file-icon-color-zip: var(
|
|
681
|
+
--trees-file-icon-color,
|
|
682
|
+
var(--trees-icon-orange)
|
|
683
|
+
);
|
|
684
|
+
|
|
685
|
+
--trees-level-gap: var(
|
|
686
|
+
--trees-level-gap-override,
|
|
687
|
+
calc(8px * var(--trees-density))
|
|
688
|
+
);
|
|
689
|
+
--trees-item-padding-x: var(
|
|
690
|
+
--trees-item-padding-x-override,
|
|
691
|
+
calc(8px * var(--trees-density))
|
|
692
|
+
);
|
|
693
|
+
--trees-item-margin-x: var(
|
|
694
|
+
--trees-item-margin-x-override,
|
|
695
|
+
calc(2px * var(--trees-density))
|
|
696
|
+
);
|
|
697
|
+
--trees-item-row-gap: var(
|
|
698
|
+
--trees-item-row-gap-override,
|
|
699
|
+
calc(6px * var(--trees-density))
|
|
700
|
+
);
|
|
701
|
+
--trees-icon-width: var(--trees-icon-width-override, 16px);
|
|
702
|
+
--trees-icon-nudge: var(
|
|
703
|
+
--trees-icon-nudge-override,
|
|
704
|
+
calc(1px * var(--trees-density))
|
|
705
|
+
);
|
|
706
|
+
--trees-row-height: var(--trees-item-height, 30px);
|
|
707
|
+
--trees-git-lane-width: var(--trees-git-lane-width-override, 12px);
|
|
708
|
+
--trees-action-lane-width: var(
|
|
709
|
+
--trees-action-lane-width-override,
|
|
710
|
+
calc(var(--trees-icon-width) + 2px)
|
|
711
|
+
);
|
|
712
|
+
/* Keep the floating trigger aligned with the row's action lane. Going in
|
|
713
|
+
from the root's right edge: the scroll container reserves
|
|
714
|
+
\`--trees-padding-inline\` of effective inset on each side (its asymmetric
|
|
715
|
+
padding formula cancels the scrollbar gutter on the right), the row
|
|
716
|
+
sits inside that inset, and its trailing \`--trees-item-padding-x\` is the
|
|
717
|
+
action lane itself. The trigger's own focus-ring margin then trims one
|
|
718
|
+
pixel back so the button's visible right edge lines up with the lane. */
|
|
719
|
+
--trees-context-menu-trigger-inline-offset: calc(
|
|
720
|
+
var(--trees-padding-inline) + var(--trees-item-padding-x) -
|
|
721
|
+
var(--trees-focus-ring-width)
|
|
722
|
+
);
|
|
723
|
+
|
|
724
|
+
--trees-scrollbar-gutter: var(--trees-scrollbar-gutter-override, 6px);
|
|
725
|
+
--trees-padding-inline: var(--trees-padding-inline-override, 16px);
|
|
726
|
+
|
|
727
|
+
color-scheme: light dark;
|
|
728
|
+
display: flex;
|
|
729
|
+
flex-direction: column;
|
|
730
|
+
font-size: var(--trees-font-size);
|
|
731
|
+
color: var(--trees-fg);
|
|
732
|
+
background-color: var(--trees-bg);
|
|
733
|
+
--truncate-marker-background-color: var(--trees-bg);
|
|
734
|
+
--truncate-marker-background-overlay-color: transparent;
|
|
735
|
+
font-family: var(--trees-font-family);
|
|
736
|
+
font-weight: var(--trees-font-weight-regular);
|
|
737
|
+
}
|
|
738
|
+
|
|
739
|
+
:host([data-file-tree-virtualized='true']) {
|
|
740
|
+
height: 100%;
|
|
741
|
+
overflow: hidden;
|
|
742
|
+
}
|
|
743
|
+
|
|
744
|
+
[data-file-tree-virtualized-wrapper='true'] {
|
|
745
|
+
height: 100%;
|
|
746
|
+
overflow: hidden;
|
|
747
|
+
display: flex;
|
|
748
|
+
flex-direction: column;
|
|
749
|
+
}
|
|
750
|
+
|
|
751
|
+
[data-file-tree-virtualized-root='true'] {
|
|
752
|
+
height: 100%;
|
|
753
|
+
display: flex;
|
|
754
|
+
flex-direction: column;
|
|
755
|
+
overflow: hidden;
|
|
756
|
+
}
|
|
757
|
+
|
|
758
|
+
[data-file-tree-virtualized-scroll='true'],
|
|
759
|
+
[data-file-tree-scrollbar-measure='true'] {
|
|
760
|
+
overflow-y: auto;
|
|
761
|
+
scrollbar-gutter: stable;
|
|
762
|
+
|
|
763
|
+
&::-webkit-scrollbar {
|
|
764
|
+
width: var(--trees-scrollbar-gutter);
|
|
765
|
+
height: var(--trees-scrollbar-gutter);
|
|
766
|
+
}
|
|
767
|
+
|
|
768
|
+
&::-webkit-scrollbar-track {
|
|
769
|
+
background: transparent;
|
|
770
|
+
}
|
|
771
|
+
|
|
772
|
+
&::-webkit-scrollbar-thumb {
|
|
773
|
+
background-color: var(--trees-scrollbar-thumb);
|
|
774
|
+
border: 1px solid transparent;
|
|
775
|
+
background-clip: content-box;
|
|
776
|
+
border-radius: calc(var(--trees-scrollbar-gutter) / 2);
|
|
777
|
+
}
|
|
778
|
+
|
|
779
|
+
&::-webkit-scrollbar-corner {
|
|
780
|
+
background-color: transparent;
|
|
781
|
+
}
|
|
782
|
+
}
|
|
783
|
+
|
|
784
|
+
/* These are styles for a temporarily generated element to measure the size
|
|
785
|
+
* of the scrollbar. It's intended to be somewhat similar in scrollbar style
|
|
786
|
+
* scope to the scrollable tree so \`--trees-scrollbar-gutter-measured\` is an
|
|
787
|
+
* accurate reflection of the size the scrollbar gutter takes up. */
|
|
788
|
+
[data-file-tree-scrollbar-measure='true'] {
|
|
789
|
+
position: absolute;
|
|
790
|
+
top: 0;
|
|
791
|
+
left: 0;
|
|
792
|
+
visibility: hidden;
|
|
793
|
+
pointer-events: none;
|
|
794
|
+
width: 100px;
|
|
795
|
+
height: 100px;
|
|
796
|
+
}
|
|
797
|
+
|
|
798
|
+
@supports (-moz-appearance: none) {
|
|
799
|
+
[data-file-tree-virtualized-scroll='true'],
|
|
800
|
+
[data-file-tree-scrollbar-measure='true'] {
|
|
801
|
+
scrollbar-width: thin;
|
|
802
|
+
scrollbar-color: var(--trees-scrollbar-thumb) transparent;
|
|
803
|
+
}
|
|
804
|
+
}
|
|
805
|
+
|
|
806
|
+
[data-file-tree-virtualized-scroll='true'] {
|
|
807
|
+
position: relative;
|
|
808
|
+
overflow-y: auto;
|
|
809
|
+
flex: 1 1 0;
|
|
810
|
+
min-height: 0;
|
|
811
|
+
padding-inline: max(
|
|
812
|
+
calc(var(--trees-padding-inline) - var(--trees-item-margin-x)),
|
|
813
|
+
0px
|
|
814
|
+
)
|
|
815
|
+
/* NOTE(amadeus): We can assume that all Webkit based browser gutters
|
|
816
|
+
* will align to the value of '--trees-scrollbar-gutter', however if not, then
|
|
817
|
+
* \`--trees-scrollbar-gutter-measured\` should correct it. Mostly we are
|
|
818
|
+
* hoping to avoid SSR alignment jumps if possible. In non-SSR'd environments
|
|
819
|
+
* \`--trees-scrollbar-gutter-measured\` should always be immediately available.
|
|
820
|
+
*/
|
|
821
|
+
max(
|
|
822
|
+
calc(
|
|
823
|
+
var(--trees-padding-inline) - var(--trees-item-margin-x) -
|
|
824
|
+
var(
|
|
825
|
+
--trees-scrollbar-gutter-measured,
|
|
826
|
+
var(--trees-scrollbar-gutter)
|
|
827
|
+
)
|
|
828
|
+
),
|
|
829
|
+
0px
|
|
830
|
+
);
|
|
831
|
+
}
|
|
832
|
+
|
|
833
|
+
@supports (-moz-appearance: none) {
|
|
834
|
+
[data-file-tree-virtualized-scroll='true'] {
|
|
835
|
+
padding-inline: max(
|
|
836
|
+
calc(var(--trees-padding-inline) - var(--trees-item-margin-x)),
|
|
837
|
+
0px
|
|
838
|
+
)
|
|
839
|
+
/* NOTE(amadeus): However on Firefox it can vary a little bit, but most
|
|
840
|
+
* likely the majority of cases will default to a 0px width scrollbar lets
|
|
841
|
+
* inherit that first to avoid SSR jumps. In non-SSR'd environments
|
|
842
|
+
* \`--trees-scrollbar-gutter-measured\` should always be immediately available.
|
|
843
|
+
*/
|
|
844
|
+
max(
|
|
845
|
+
calc(
|
|
846
|
+
var(--trees-padding-inline) - var(--trees-item-margin-x) -
|
|
847
|
+
var(--trees-scrollbar-gutter-measured, 0px)
|
|
848
|
+
),
|
|
849
|
+
0px
|
|
850
|
+
);
|
|
851
|
+
}
|
|
852
|
+
}
|
|
853
|
+
|
|
854
|
+
[data-file-tree-sticky-overlay='true'] {
|
|
855
|
+
position: sticky;
|
|
856
|
+
top: 0;
|
|
857
|
+
height: 0;
|
|
858
|
+
z-index: 4;
|
|
859
|
+
overflow: visible;
|
|
860
|
+
pointer-events: none;
|
|
861
|
+
}
|
|
862
|
+
|
|
863
|
+
/* The overlay DOM is kept populated even at scrollTop=0 so the browser has
|
|
864
|
+
* the rendered rows on hand the moment scrolling begins — otherwise the
|
|
865
|
+
* compositor paints a scrolled frame before React can mount the overlay,
|
|
866
|
+
* and the topmost sticky folder jumps up by a couple of pixels before it
|
|
867
|
+
* "snaps" into its pinned position. We hide it via CSS whenever the scroll
|
|
868
|
+
* is at the top and no scroll is in progress, so the preview doesn't leak
|
|
869
|
+
* through at rest. \`data-overlay-reveal\` is stamped on the root only when
|
|
870
|
+
* the user initiates a scroll while already at the top — exactly the case
|
|
871
|
+
* where we need the pre-mounted overlay to be visible through the first
|
|
872
|
+
* compositor frame. It is deliberately distinct from the general
|
|
873
|
+
* \`data-is-scrolling\` flag so a scroll that ends at the top (e.g. ArrowUp
|
|
874
|
+
* navigation) re-hides the overlay the instant the scroll lands, rather
|
|
875
|
+
* than waiting for the hover-suppression timer to elapse. */
|
|
876
|
+
[data-file-tree-virtualized-root='true'][data-scroll-at-top='true']:not(
|
|
877
|
+
[data-overlay-reveal]
|
|
878
|
+
)
|
|
879
|
+
[data-file-tree-sticky-overlay='true'] {
|
|
880
|
+
visibility: hidden;
|
|
881
|
+
}
|
|
882
|
+
|
|
883
|
+
[data-file-tree-sticky-overlay-content='true'] {
|
|
884
|
+
background-color: var(--trees-bg);
|
|
885
|
+
position: relative;
|
|
886
|
+
pointer-events: none;
|
|
887
|
+
}
|
|
888
|
+
|
|
889
|
+
[data-file-tree-virtualized-list='true'] {
|
|
890
|
+
background-color: var(--trees-bg);
|
|
891
|
+
position: relative;
|
|
892
|
+
min-height: 100%;
|
|
893
|
+
width: 100%;
|
|
894
|
+
overflow-anchor: none;
|
|
895
|
+
|
|
896
|
+
&[data-is-scrolling] {
|
|
897
|
+
pointer-events: none;
|
|
898
|
+
}
|
|
899
|
+
}
|
|
900
|
+
|
|
901
|
+
[data-file-tree-virtualized-sticky-offset='true'] {
|
|
902
|
+
contain: layout size;
|
|
903
|
+
}
|
|
904
|
+
|
|
905
|
+
[data-file-tree-virtualized-sticky='true'] {
|
|
906
|
+
position: sticky;
|
|
907
|
+
top: 0;
|
|
908
|
+
width: 100%;
|
|
909
|
+
display: flex;
|
|
910
|
+
flex-direction: column;
|
|
911
|
+
isolation: isolate;
|
|
912
|
+
/* Promote to its own compositor layer so text inside the window is
|
|
913
|
+
* rasterized once and GPU-translated during scroll. Without this, the
|
|
914
|
+
* browser re-paints the window (and its text) at every scroll frame,
|
|
915
|
+
* which produces visible 1px shake / character tearing. */
|
|
916
|
+
will-change: transform;
|
|
917
|
+
}
|
|
918
|
+
|
|
919
|
+
[data-file-tree-search-container] {
|
|
920
|
+
display: flex;
|
|
921
|
+
padding: 0;
|
|
922
|
+
padding-inline: var(--trees-padding-inline);
|
|
923
|
+
margin-bottom: var(--trees-item-row-gap);
|
|
924
|
+
}
|
|
925
|
+
|
|
926
|
+
[data-file-tree-search-input] {
|
|
927
|
+
--trees-focus-ring-width: 2px;
|
|
928
|
+
font-family: var(--trees-font-family);
|
|
929
|
+
font-size: var(--trees-font-size);
|
|
930
|
+
flex: 1;
|
|
931
|
+
height: var(--trees-row-height);
|
|
932
|
+
/* 1px breathing room so the focus-visible outline isn't clipped when the
|
|
933
|
+
* input sits flush against the top of the scroll container. */
|
|
934
|
+
margin-block: 1px;
|
|
935
|
+
padding-inline: var(--trees-item-padding-x);
|
|
936
|
+
line-height: var(--trees-row-height);
|
|
937
|
+
color: var(--trees-search-fg);
|
|
938
|
+
background-color: var(--trees-search-bg);
|
|
939
|
+
border: 1px solid var(--trees-border-color);
|
|
940
|
+
border-radius: var(--trees-border-radius);
|
|
941
|
+
outline: none;
|
|
942
|
+
|
|
943
|
+
&::placeholder {
|
|
944
|
+
color: color-mix(
|
|
945
|
+
in lab,
|
|
946
|
+
var(--trees-search-fg) 65%,
|
|
947
|
+
var(--trees-search-bg)
|
|
948
|
+
);
|
|
949
|
+
}
|
|
950
|
+
|
|
951
|
+
&:focus-visible,
|
|
952
|
+
&[data-file-tree-search-input-fake-focus='true'] {
|
|
953
|
+
outline: var(--trees-focus-ring-width) solid var(--trees-focus-ring-color);
|
|
954
|
+
outline-offset: var(--trees-focus-ring-offset);
|
|
955
|
+
}
|
|
956
|
+
}
|
|
957
|
+
|
|
958
|
+
/* The wrapper for the tree items */
|
|
959
|
+
[role='tree'] {
|
|
960
|
+
position: relative;
|
|
961
|
+
display: flex;
|
|
962
|
+
flex-direction: column;
|
|
963
|
+
gap: var(--trees-gap-override, 0);
|
|
964
|
+
}
|
|
965
|
+
|
|
966
|
+
/* LIST ITEM */
|
|
967
|
+
[data-type='item'] {
|
|
968
|
+
color: inherit;
|
|
969
|
+
font-family: var(--trees-font-family);
|
|
970
|
+
font-size: var(--trees-font-size);
|
|
971
|
+
text-align: start;
|
|
972
|
+
outline: none;
|
|
973
|
+
background-color: var(--trees-bg);
|
|
974
|
+
border: none;
|
|
975
|
+
position: relative;
|
|
976
|
+
|
|
977
|
+
padding: 0 var(--trees-item-padding-x);
|
|
978
|
+
margin: 0 var(--trees-item-margin-x);
|
|
979
|
+
cursor: pointer;
|
|
980
|
+
-webkit-user-select: none;
|
|
981
|
+
user-select: none;
|
|
982
|
+
-webkit-touch-callout: none;
|
|
983
|
+
touch-action: manipulation;
|
|
984
|
+
display: flex;
|
|
985
|
+
flex: 0 0 var(--trees-row-height);
|
|
986
|
+
align-items: center;
|
|
987
|
+
height: var(--trees-row-height);
|
|
988
|
+
line-height: var(--trees-row-height);
|
|
989
|
+
gap: var(--trees-item-row-gap);
|
|
990
|
+
border-radius: var(--trees-border-radius);
|
|
991
|
+
/* Row states may be translucent, so markers paint the tree background first
|
|
992
|
+
* and then the state color on top to avoid compositing the same alpha twice. */
|
|
993
|
+
--truncate-marker-background-color: var(--trees-bg);
|
|
994
|
+
--truncate-marker-background-overlay-color: transparent;
|
|
995
|
+
--truncate-marker-block-inset: 0px;
|
|
996
|
+
|
|
997
|
+
&:hover,
|
|
998
|
+
&[data-item-context-hover='true'] {
|
|
999
|
+
background-color: var(--trees-bg-muted);
|
|
1000
|
+
--truncate-marker-background-overlay-color: var(--trees-bg-muted);
|
|
1001
|
+
}
|
|
1002
|
+
|
|
1003
|
+
&[data-item-focused='true'],
|
|
1004
|
+
&:focus-visible {
|
|
1005
|
+
z-index: 2;
|
|
1006
|
+
|
|
1007
|
+
/* Flattened segment markers sit high enough to cover the row outline unless
|
|
1008
|
+
* their painted background is inset by the focus ring width. */
|
|
1009
|
+
[data-item-flattened-subitems] {
|
|
1010
|
+
--truncate-marker-block-inset: var(--trees-focus-ring-width);
|
|
1011
|
+
}
|
|
1012
|
+
|
|
1013
|
+
&::before {
|
|
1014
|
+
position: absolute;
|
|
1015
|
+
inset: 0;
|
|
1016
|
+
content: '';
|
|
1017
|
+
display: block;
|
|
1018
|
+
border-radius: var(--trees-border-radius);
|
|
1019
|
+
outline: var(--trees-focus-ring-width) solid
|
|
1020
|
+
var(--trees-focus-ring-color);
|
|
1021
|
+
outline-offset: var(--trees-focus-ring-offset);
|
|
1022
|
+
pointer-events: none;
|
|
1023
|
+
}
|
|
1024
|
+
|
|
1025
|
+
&[data-item-selected='true']::before {
|
|
1026
|
+
outline-color: var(--trees-selected-focused-border-color);
|
|
1027
|
+
}
|
|
1028
|
+
}
|
|
1029
|
+
|
|
1030
|
+
&[data-item-selected='true'] {
|
|
1031
|
+
color: var(--trees-selected-fg);
|
|
1032
|
+
background-color: var(--trees-selected-bg);
|
|
1033
|
+
--truncate-marker-background-overlay-color: var(--trees-selected-bg);
|
|
1034
|
+
z-index: 3;
|
|
1035
|
+
|
|
1036
|
+
[data-item-section='icon'] {
|
|
1037
|
+
color: var(--trees-selected-fg);
|
|
1038
|
+
}
|
|
1039
|
+
}
|
|
1040
|
+
|
|
1041
|
+
&[data-item-search-match='true'] {
|
|
1042
|
+
font-weight: var(--trees-search-font-weight);
|
|
1043
|
+
}
|
|
1044
|
+
}
|
|
1045
|
+
|
|
1046
|
+
[data-type='item'][data-file-tree-sticky-row='true'] {
|
|
1047
|
+
pointer-events: auto;
|
|
1048
|
+
}
|
|
1049
|
+
|
|
1050
|
+
/* Sticky rows opt back into pointer events because the overlay wrapper is
|
|
1051
|
+
* inert. During scroll, put them back under the same hover suppression as
|
|
1052
|
+
* the virtualized list so translucent hover states and menu triggers do not
|
|
1053
|
+
* paint over rows moving beneath the sticky stack. */
|
|
1054
|
+
[data-file-tree-virtualized-root='true'][data-is-scrolling]
|
|
1055
|
+
[data-type='item'][data-file-tree-sticky-row='true'] {
|
|
1056
|
+
pointer-events: none;
|
|
1057
|
+
}
|
|
1058
|
+
|
|
1059
|
+
[data-file-tree-virtualized-root='true'][data-is-scrolling]
|
|
1060
|
+
[data-type='item'][data-file-tree-sticky-row='true']:hover:not(
|
|
1061
|
+
[data-item-selected='true']
|
|
1062
|
+
),
|
|
1063
|
+
[data-file-tree-virtualized-root='true'][data-is-scrolling]
|
|
1064
|
+
[data-type='item'][data-file-tree-sticky-row='true'][data-item-context-hover='true']:not(
|
|
1065
|
+
[data-item-selected='true']
|
|
1066
|
+
) {
|
|
1067
|
+
background-color: var(--trees-bg);
|
|
1068
|
+
--truncate-marker-background-overlay-color: transparent;
|
|
1069
|
+
}
|
|
1070
|
+
|
|
1071
|
+
[data-item-selected='true']:has(+ [data-item-selected='true']) {
|
|
1072
|
+
border-bottom-left-radius: 0;
|
|
1073
|
+
border-bottom-right-radius: 0;
|
|
1074
|
+
}
|
|
1075
|
+
|
|
1076
|
+
[data-item-selected='true'] + [data-item-selected='true'] {
|
|
1077
|
+
border-top-left-radius: 0;
|
|
1078
|
+
border-top-right-radius: 0;
|
|
1079
|
+
}
|
|
1080
|
+
|
|
1081
|
+
/* Flattened Directory Parts */
|
|
1082
|
+
[data-item-flattened-subitems] {
|
|
1083
|
+
display: inline-flex;
|
|
1084
|
+
align-items: center;
|
|
1085
|
+
gap: 2px;
|
|
1086
|
+
}
|
|
1087
|
+
[data-item-flattened-subitem]:hover,
|
|
1088
|
+
[data-item-flattened-subitem-drag-target='true'] {
|
|
1089
|
+
text-decoration: underline;
|
|
1090
|
+
}
|
|
1091
|
+
|
|
1092
|
+
/* Icon for each item */
|
|
1093
|
+
[data-item-section='icon'] {
|
|
1094
|
+
flex-shrink: 0;
|
|
1095
|
+
display: flex;
|
|
1096
|
+
align-items: center;
|
|
1097
|
+
justify-content: center;
|
|
1098
|
+
color: var(--trees-fg-muted);
|
|
1099
|
+
fill: currentColor;
|
|
1100
|
+
width: var(--trees-icon-width);
|
|
1101
|
+
}
|
|
1102
|
+
|
|
1103
|
+
:where([data-item-section='icon'] > [data-icon-token]) {
|
|
1104
|
+
color: var(--trees-fg-muted);
|
|
1105
|
+
}
|
|
1106
|
+
|
|
1107
|
+
[data-file-tree-colored-icons='true'] {
|
|
1108
|
+
[data-icon-token='astro'] {
|
|
1109
|
+
color: var(--trees-file-icon-color-astro);
|
|
1110
|
+
}
|
|
1111
|
+
[data-icon-token='babel'] {
|
|
1112
|
+
color: var(--trees-file-icon-color-babel);
|
|
1113
|
+
}
|
|
1114
|
+
[data-icon-token='bash'] {
|
|
1115
|
+
color: var(--trees-file-icon-color-bash);
|
|
1116
|
+
}
|
|
1117
|
+
[data-icon-token='biome'] {
|
|
1118
|
+
color: var(--trees-file-icon-color-biome);
|
|
1119
|
+
}
|
|
1120
|
+
[data-icon-token='bootstrap'] {
|
|
1121
|
+
color: var(--trees-file-icon-color-bootstrap);
|
|
1122
|
+
}
|
|
1123
|
+
[data-icon-token='browserslist'] {
|
|
1124
|
+
color: var(--trees-file-icon-color-browserslist);
|
|
1125
|
+
}
|
|
1126
|
+
[data-icon-token='bun'] {
|
|
1127
|
+
color: var(--trees-file-icon-color-bun);
|
|
1128
|
+
}
|
|
1129
|
+
[data-icon-token='claude'] {
|
|
1130
|
+
color: var(--trees-file-icon-color-claude);
|
|
1131
|
+
}
|
|
1132
|
+
[data-icon-token='css'] {
|
|
1133
|
+
color: var(--trees-file-icon-color-css);
|
|
1134
|
+
}
|
|
1135
|
+
[data-icon-token='database'] {
|
|
1136
|
+
color: var(--trees-file-icon-color-database);
|
|
1137
|
+
}
|
|
1138
|
+
[data-icon-token='default'] {
|
|
1139
|
+
color: var(--trees-file-icon-color-default);
|
|
1140
|
+
}
|
|
1141
|
+
[data-icon-token='docker'] {
|
|
1142
|
+
color: var(--trees-file-icon-color-docker);
|
|
1143
|
+
}
|
|
1144
|
+
[data-icon-token='eslint'] {
|
|
1145
|
+
color: var(--trees-file-icon-color-eslint);
|
|
1146
|
+
}
|
|
1147
|
+
[data-icon-token='git'] {
|
|
1148
|
+
color: var(--trees-file-icon-color-git);
|
|
1149
|
+
}
|
|
1150
|
+
[data-icon-token='go'] {
|
|
1151
|
+
color: var(--trees-file-icon-color-go);
|
|
1152
|
+
}
|
|
1153
|
+
[data-icon-token='graphql'] {
|
|
1154
|
+
color: var(--trees-file-icon-color-graphql);
|
|
1155
|
+
}
|
|
1156
|
+
[data-icon-token='html'] {
|
|
1157
|
+
color: var(--trees-file-icon-color-html);
|
|
1158
|
+
}
|
|
1159
|
+
[data-icon-token='image'] {
|
|
1160
|
+
color: var(--trees-file-icon-color-image);
|
|
1161
|
+
}
|
|
1162
|
+
[data-icon-token='javascript'] {
|
|
1163
|
+
color: var(--trees-file-icon-color-javascript);
|
|
1164
|
+
}
|
|
1165
|
+
[data-icon-token='json'] {
|
|
1166
|
+
color: var(--trees-file-icon-color-json);
|
|
1167
|
+
}
|
|
1168
|
+
[data-icon-token='markdown'] {
|
|
1169
|
+
color: var(--trees-file-icon-color-markdown);
|
|
1170
|
+
}
|
|
1171
|
+
[data-icon-token='mcp'] {
|
|
1172
|
+
color: var(--trees-file-icon-color-mcp);
|
|
1173
|
+
}
|
|
1174
|
+
[data-icon-token='npm'] {
|
|
1175
|
+
color: var(--trees-file-icon-color-npm);
|
|
1176
|
+
}
|
|
1177
|
+
[data-icon-token='oxc'] {
|
|
1178
|
+
color: var(--trees-file-icon-color-oxc);
|
|
1179
|
+
}
|
|
1180
|
+
[data-icon-token='postcss'] {
|
|
1181
|
+
color: var(--trees-file-icon-color-postcss);
|
|
1182
|
+
}
|
|
1183
|
+
[data-icon-token='prettier'] {
|
|
1184
|
+
color: var(--trees-file-icon-color-prettier);
|
|
1185
|
+
}
|
|
1186
|
+
[data-icon-token='python'] {
|
|
1187
|
+
color: var(--trees-file-icon-color-python);
|
|
1188
|
+
}
|
|
1189
|
+
[data-icon-token='react'] {
|
|
1190
|
+
color: var(--trees-file-icon-color-react);
|
|
1191
|
+
}
|
|
1192
|
+
[data-icon-token='ruby'] {
|
|
1193
|
+
color: var(--trees-file-icon-color-ruby);
|
|
1194
|
+
}
|
|
1195
|
+
[data-icon-token='rust'] {
|
|
1196
|
+
color: var(--trees-file-icon-color-rust);
|
|
1197
|
+
}
|
|
1198
|
+
[data-icon-token='sass'] {
|
|
1199
|
+
color: var(--trees-file-icon-color-sass);
|
|
1200
|
+
}
|
|
1201
|
+
[data-icon-token='svg'] {
|
|
1202
|
+
color: var(--trees-file-icon-color-svg);
|
|
1203
|
+
}
|
|
1204
|
+
[data-icon-token='svelte'] {
|
|
1205
|
+
color: var(--trees-file-icon-color-svelte);
|
|
1206
|
+
}
|
|
1207
|
+
[data-icon-token='svgo'] {
|
|
1208
|
+
color: var(--trees-file-icon-color-svgo);
|
|
1209
|
+
}
|
|
1210
|
+
[data-icon-token='swift'] {
|
|
1211
|
+
color: var(--trees-file-icon-color-swift);
|
|
1212
|
+
}
|
|
1213
|
+
[data-icon-token='table'] {
|
|
1214
|
+
color: var(--trees-file-icon-color-table);
|
|
1215
|
+
}
|
|
1216
|
+
[data-icon-token='text'] {
|
|
1217
|
+
color: var(--trees-file-icon-color-text);
|
|
1218
|
+
}
|
|
1219
|
+
[data-icon-token='tailwind'] {
|
|
1220
|
+
color: var(--trees-file-icon-color-tailwind);
|
|
1221
|
+
}
|
|
1222
|
+
[data-icon-token='terraform'] {
|
|
1223
|
+
color: var(--trees-file-icon-color-terraform);
|
|
1224
|
+
}
|
|
1225
|
+
[data-icon-token='typescript'] {
|
|
1226
|
+
color: var(--trees-file-icon-color-typescript);
|
|
1227
|
+
}
|
|
1228
|
+
[data-icon-token='vite'] {
|
|
1229
|
+
color: var(--trees-file-icon-color-vite);
|
|
1230
|
+
}
|
|
1231
|
+
[data-icon-token='vscode'] {
|
|
1232
|
+
color: var(--trees-file-icon-color-vscode);
|
|
1233
|
+
}
|
|
1234
|
+
[data-icon-token='vue'] {
|
|
1235
|
+
color: var(--trees-file-icon-color-vue);
|
|
1236
|
+
}
|
|
1237
|
+
[data-icon-token='wasm'] {
|
|
1238
|
+
color: var(--trees-file-icon-color-wasm);
|
|
1239
|
+
}
|
|
1240
|
+
[data-icon-token='webpack'] {
|
|
1241
|
+
color: var(--trees-file-icon-color-webpack);
|
|
1242
|
+
}
|
|
1243
|
+
[data-icon-token='yml'] {
|
|
1244
|
+
color: var(--trees-file-icon-color-yml);
|
|
1245
|
+
}
|
|
1246
|
+
[data-icon-token='zig'] {
|
|
1247
|
+
color: var(--trees-file-icon-color-zig);
|
|
1248
|
+
}
|
|
1249
|
+
[data-icon-token='zip'] {
|
|
1250
|
+
color: var(--trees-file-icon-color-zip);
|
|
1251
|
+
}
|
|
1252
|
+
}
|
|
1253
|
+
|
|
1254
|
+
/* Chevron rotation and visual alignment */
|
|
1255
|
+
/* Chevron pointing down */
|
|
1256
|
+
[data-icon-name='file-tree-icon-chevron'] {
|
|
1257
|
+
&[data-align-capitals='false'] {
|
|
1258
|
+
transform: translate(0, var(--trees-icon-nudge));
|
|
1259
|
+
}
|
|
1260
|
+
&[data-align-capitals='true'] {
|
|
1261
|
+
transform: translate(0, 0);
|
|
1262
|
+
}
|
|
1263
|
+
}
|
|
1264
|
+
|
|
1265
|
+
[data-item-section='content'] {
|
|
1266
|
+
flex: 0 1 auto;
|
|
1267
|
+
text-align: start;
|
|
1268
|
+
min-width: 0;
|
|
1269
|
+
max-width: 100%;
|
|
1270
|
+
overflow: hidden;
|
|
1271
|
+
text-overflow: ellipsis;
|
|
1272
|
+
/* Breaks middle truncate component to also set this */
|
|
1273
|
+
/* white-space: nowrap; */
|
|
1274
|
+
}
|
|
1275
|
+
|
|
1276
|
+
[data-item-section='decoration'] {
|
|
1277
|
+
flex: 1 1 0;
|
|
1278
|
+
min-width: 0;
|
|
1279
|
+
display: flex;
|
|
1280
|
+
justify-content: flex-end;
|
|
1281
|
+
text-align: end;
|
|
1282
|
+
overflow: hidden;
|
|
1283
|
+
color: var(--trees-fg-muted);
|
|
1284
|
+
}
|
|
1285
|
+
|
|
1286
|
+
[data-item-section='decoration'] > span {
|
|
1287
|
+
min-width: 0;
|
|
1288
|
+
max-width: 100%;
|
|
1289
|
+
display: inline-flex;
|
|
1290
|
+
align-items: center;
|
|
1291
|
+
justify-content: flex-end;
|
|
1292
|
+
overflow: hidden;
|
|
1293
|
+
text-overflow: ellipsis;
|
|
1294
|
+
white-space: nowrap;
|
|
1295
|
+
}
|
|
1296
|
+
|
|
1297
|
+
[data-item-section='git'],
|
|
1298
|
+
[data-item-section='action'] {
|
|
1299
|
+
flex: 0 0 auto;
|
|
1300
|
+
display: flex;
|
|
1301
|
+
align-items: center;
|
|
1302
|
+
justify-content: center;
|
|
1303
|
+
}
|
|
1304
|
+
|
|
1305
|
+
[data-item-section='git'] {
|
|
1306
|
+
width: var(--trees-git-lane-width);
|
|
1307
|
+
}
|
|
1308
|
+
|
|
1309
|
+
[data-item-section='action'] {
|
|
1310
|
+
width: var(--trees-action-lane-width);
|
|
1311
|
+
color: var(--trees-fg-muted);
|
|
1312
|
+
fill: currentColor;
|
|
1313
|
+
pointer-events: none;
|
|
1314
|
+
}
|
|
1315
|
+
|
|
1316
|
+
[data-item-section='git'] > span,
|
|
1317
|
+
[data-item-section='action'] > span {
|
|
1318
|
+
width: 100%;
|
|
1319
|
+
display: inline-flex;
|
|
1320
|
+
align-items: center;
|
|
1321
|
+
justify-content: center;
|
|
1322
|
+
}
|
|
1323
|
+
|
|
1324
|
+
[data-item-action-affordance='decorative'] {
|
|
1325
|
+
opacity: 0.85;
|
|
1326
|
+
}
|
|
1327
|
+
|
|
1328
|
+
[data-item-rename-input] {
|
|
1329
|
+
appearance: none;
|
|
1330
|
+
width: 100%;
|
|
1331
|
+
min-width: 0;
|
|
1332
|
+
height: calc(var(--trees-row-height) - 4px);
|
|
1333
|
+
font-family: inherit;
|
|
1334
|
+
font-size: inherit;
|
|
1335
|
+
/* line-height: calc(var(--trees-row-height) - 8px); */
|
|
1336
|
+
color: inherit;
|
|
1337
|
+
background-color: transparent;
|
|
1338
|
+
border: 0;
|
|
1339
|
+
padding-inline: 6px;
|
|
1340
|
+
outline: none;
|
|
1341
|
+
box-sizing: border-box;
|
|
1342
|
+
}
|
|
1343
|
+
|
|
1344
|
+
[data-item-section='content']:has([data-item-rename-input])
|
|
1345
|
+
~ [data-item-section='action'],
|
|
1346
|
+
[data-item-section='content']:has([data-item-rename-input])
|
|
1347
|
+
~ [data-item-section='decoration'] {
|
|
1348
|
+
display: none;
|
|
1349
|
+
}
|
|
1350
|
+
|
|
1351
|
+
/* Chevron pointing right */
|
|
1352
|
+
[aria-expanded='false'][data-item-type='folder']
|
|
1353
|
+
> [data-item-section='icon']
|
|
1354
|
+
> [data-icon-name='file-tree-icon-chevron'] {
|
|
1355
|
+
&[data-align-capitals='true'] {
|
|
1356
|
+
transform: rotate(-90deg)
|
|
1357
|
+
translate(
|
|
1358
|
+
calc(var(--trees-icon-nudge) / 2),
|
|
1359
|
+
calc(var(--trees-icon-nudge) / 2)
|
|
1360
|
+
);
|
|
1361
|
+
}
|
|
1362
|
+
&[data-align-capitals='false'] {
|
|
1363
|
+
transform: rotate(-90deg)
|
|
1364
|
+
translate(
|
|
1365
|
+
calc(var(--trees-icon-nudge) / 2 * -1),
|
|
1366
|
+
calc(var(--trees-icon-nudge) / 2)
|
|
1367
|
+
);
|
|
1368
|
+
}
|
|
1369
|
+
}
|
|
1370
|
+
|
|
1371
|
+
/* LIST IDENTATION */
|
|
1372
|
+
/* Spacing container */
|
|
1373
|
+
[data-item-section='spacing'] {
|
|
1374
|
+
display: flex;
|
|
1375
|
+
flex-direction: row;
|
|
1376
|
+
align-items: center;
|
|
1377
|
+
justify-content: center;
|
|
1378
|
+
height: var(--trees-row-height);
|
|
1379
|
+
padding-left: calc(calc(var(--trees-icon-width) / 2) - 0.5px);
|
|
1380
|
+
|
|
1381
|
+
&:empty {
|
|
1382
|
+
padding-left: 0;
|
|
1383
|
+
}
|
|
1384
|
+
}
|
|
1385
|
+
|
|
1386
|
+
/* Spacing per level */
|
|
1387
|
+
[data-item-section='spacing-item'] {
|
|
1388
|
+
transform: translateX(-0.25px);
|
|
1389
|
+
display: inline-block;
|
|
1390
|
+
border-left: 1px solid var(--trees-indent-guide-bg);
|
|
1391
|
+
height: 100%;
|
|
1392
|
+
margin-right: calc(var(--trees-level-gap) - 1px);
|
|
1393
|
+
opacity: 0;
|
|
1394
|
+
transition: opacity 150ms ease;
|
|
1395
|
+
|
|
1396
|
+
& + & {
|
|
1397
|
+
margin-left: calc(
|
|
1398
|
+
var(--trees-item-row-gap) + calc(var(--trees-icon-width) / 2) - 0.5px
|
|
1399
|
+
);
|
|
1400
|
+
}
|
|
1401
|
+
}
|
|
1402
|
+
|
|
1403
|
+
:host(:hover) [data-item-section='spacing-item'] {
|
|
1404
|
+
opacity: 0.75;
|
|
1405
|
+
}
|
|
1406
|
+
|
|
1407
|
+
/* Git status indicator */
|
|
1408
|
+
|
|
1409
|
+
/* This is a folder that contains a git change */
|
|
1410
|
+
[data-item-contains-git-change='true'] > [data-item-section='git'] {
|
|
1411
|
+
color: var(--trees-git-modified-color);
|
|
1412
|
+
opacity: 0.5;
|
|
1413
|
+
fill: currentColor;
|
|
1414
|
+
}
|
|
1415
|
+
|
|
1416
|
+
/* These are files that have a git change */
|
|
1417
|
+
[data-item-git-status] {
|
|
1418
|
+
&
|
|
1419
|
+
> :where([data-item-section='icon'])
|
|
1420
|
+
> :where(:not([data-icon-name='file-tree-icon-chevron'])) {
|
|
1421
|
+
color: var(--trees-item-git-status-color);
|
|
1422
|
+
}
|
|
1423
|
+
& > [data-item-section='content'] {
|
|
1424
|
+
color: var(--trees-item-git-status-color);
|
|
1425
|
+
}
|
|
1426
|
+
& > [data-item-section='git'] {
|
|
1427
|
+
color: var(--trees-item-git-status-color);
|
|
1428
|
+
font-weight: var(--trees-font-weight-semibold);
|
|
1429
|
+
}
|
|
1430
|
+
}
|
|
1431
|
+
|
|
1432
|
+
[data-item-git-status='added'] {
|
|
1433
|
+
--trees-item-git-status-color: var(--trees-git-added-color);
|
|
1434
|
+
}
|
|
1435
|
+
|
|
1436
|
+
[data-item-git-status='deleted'] {
|
|
1437
|
+
--trees-item-git-status-color: var(--trees-git-deleted-color);
|
|
1438
|
+
}
|
|
1439
|
+
|
|
1440
|
+
[data-item-git-status='ignored'] {
|
|
1441
|
+
--trees-item-git-status-color: var(--trees-git-ignored-color);
|
|
1442
|
+
|
|
1443
|
+
& > [data-item-section='icon'] {
|
|
1444
|
+
opacity: 0.5;
|
|
1445
|
+
}
|
|
1446
|
+
}
|
|
1447
|
+
|
|
1448
|
+
[data-item-section='git'] [data-icon-name='file-tree-icon-dot'] {
|
|
1449
|
+
/* this is a nudge to align the dot with the likely lowercase text. it's slightly
|
|
1450
|
+
generalizable, but other fonts are gonna need other nudges i assume */
|
|
1451
|
+
transform: translateY(calc(0.65ex - 50%));
|
|
1452
|
+
}
|
|
1453
|
+
|
|
1454
|
+
[data-item-git-status='modified'] {
|
|
1455
|
+
--trees-item-git-status-color: var(--trees-git-modified-color);
|
|
1456
|
+
}
|
|
1457
|
+
|
|
1458
|
+
[data-item-git-status='renamed'] {
|
|
1459
|
+
--trees-item-git-status-color: var(--trees-git-renamed-color);
|
|
1460
|
+
}
|
|
1461
|
+
|
|
1462
|
+
[data-item-git-status='untracked'] {
|
|
1463
|
+
--trees-item-git-status-color: var(--trees-git-untracked-color);
|
|
1464
|
+
}
|
|
1465
|
+
|
|
1466
|
+
/* Drag and drop */
|
|
1467
|
+
[data-item-drag-target='true'] {
|
|
1468
|
+
background-color: var(--trees-selected-bg);
|
|
1469
|
+
}
|
|
1470
|
+
|
|
1471
|
+
[data-item-dragging='true'] {
|
|
1472
|
+
opacity: 0.5;
|
|
1473
|
+
}
|
|
1474
|
+
|
|
1475
|
+
/* Lock icon for locked paths (sibling of content) */
|
|
1476
|
+
[data-item-section='lock'] {
|
|
1477
|
+
flex: 0 0 auto;
|
|
1478
|
+
margin-left: auto;
|
|
1479
|
+
display: flex;
|
|
1480
|
+
align-items: center;
|
|
1481
|
+
color: var(--trees-fg-muted);
|
|
1482
|
+
}
|
|
1483
|
+
[data-item-section='lock'] svg {
|
|
1484
|
+
display: block;
|
|
1485
|
+
}
|
|
1486
|
+
|
|
1487
|
+
[data-type='header-slot'] {
|
|
1488
|
+
display: block;
|
|
1489
|
+
flex: 0 0 auto;
|
|
1490
|
+
}
|
|
1491
|
+
|
|
1492
|
+
[data-type='context-menu-wash'] {
|
|
1493
|
+
position: absolute;
|
|
1494
|
+
inset: 0;
|
|
1495
|
+
z-index: 3;
|
|
1496
|
+
background-color: transparent;
|
|
1497
|
+
touch-action: none;
|
|
1498
|
+
}
|
|
1499
|
+
|
|
1500
|
+
[data-type='context-menu-anchor'] {
|
|
1501
|
+
position: absolute;
|
|
1502
|
+
top: 0;
|
|
1503
|
+
right: var(--trees-context-menu-trigger-inline-offset);
|
|
1504
|
+
z-index: 4;
|
|
1505
|
+
display: none;
|
|
1506
|
+
align-items: center;
|
|
1507
|
+
|
|
1508
|
+
&[data-visible='true'] {
|
|
1509
|
+
display: flex;
|
|
1510
|
+
}
|
|
1511
|
+
}
|
|
1512
|
+
|
|
1513
|
+
/* Hide the floating trigger while the scroll container is actively moving.
|
|
1514
|
+
* The anchor is positioned against the root, not the scroll content, so its
|
|
1515
|
+
* \`top\` follows the row via a React state update — one frame behind the
|
|
1516
|
+
* compositor. That delay is visible as the trigger hovering over the wrong
|
|
1517
|
+
* row during the first frame of a scroll. The \`data-is-scrolling\` flag on
|
|
1518
|
+
* the root is flipped synchronously on \`wheel\`/\`touchmove\`/\`keydown\` before
|
|
1519
|
+
* the compositor commits the next paint, so this selector hides the anchor
|
|
1520
|
+
* in the same frame the scroll begins. */
|
|
1521
|
+
[data-file-tree-virtualized-root='true'][data-is-scrolling]
|
|
1522
|
+
[data-type='context-menu-anchor'] {
|
|
1523
|
+
display: none;
|
|
1524
|
+
}
|
|
1525
|
+
|
|
1526
|
+
[data-type='context-menu-anchor'] > slot[name='context-menu'] {
|
|
1527
|
+
display: block;
|
|
1528
|
+
width: 0;
|
|
1529
|
+
min-width: 0;
|
|
1530
|
+
flex: 0 0 0;
|
|
1531
|
+
overflow: visible;
|
|
1532
|
+
}
|
|
1533
|
+
|
|
1534
|
+
/* Single floating context menu trigger */
|
|
1535
|
+
[data-type='context-menu-trigger'] {
|
|
1536
|
+
all: unset;
|
|
1537
|
+
align-items: center;
|
|
1538
|
+
justify-content: center;
|
|
1539
|
+
width: var(--trees-action-lane-width);
|
|
1540
|
+
color: var(--trees-fg-muted);
|
|
1541
|
+
fill: currentColor;
|
|
1542
|
+
cursor: pointer;
|
|
1543
|
+
font-family: var(--trees-font-family);
|
|
1544
|
+
font-size: var(--trees-font-size);
|
|
1545
|
+
border-top-right-radius: var(--trees-border-radius);
|
|
1546
|
+
border-bottom-right-radius: var(--trees-border-radius);
|
|
1547
|
+
margin: var(--trees-focus-ring-width);
|
|
1548
|
+
height: calc(var(--trees-row-height) - var(--trees-focus-ring-width) * 2);
|
|
1549
|
+
border-width: 0;
|
|
1550
|
+
transition: color 120ms ease;
|
|
1551
|
+
|
|
1552
|
+
display: flex;
|
|
1553
|
+
}
|
|
1554
|
+
|
|
1555
|
+
[data-type='context-menu-trigger']:hover,
|
|
1556
|
+
[data-type='context-menu-trigger'][aria-expanded='true'] {
|
|
1557
|
+
color: var(--trees-fg);
|
|
1558
|
+
}
|
|
1559
|
+
|
|
1560
|
+
/** @pierre/truncate css here, manually copy pasted for now */
|
|
1561
|
+
[data-truncate-container] {
|
|
1562
|
+
/* CUSTOM TO TREES, TO SUPPORT THE OUTLINE */
|
|
1563
|
+
margin-top: -1px;
|
|
1564
|
+
margin-bottom: -1px;
|
|
1565
|
+
|
|
1566
|
+
/* Width of the fade from default marker to text */
|
|
1567
|
+
--truncate-internal-marker-fade-width: var(
|
|
1568
|
+
--truncate-marker-fade-width,
|
|
1569
|
+
2px
|
|
1570
|
+
);
|
|
1571
|
+
/* Width of the solid color between the fade from the default marker to the text */
|
|
1572
|
+
--truncate-internal-marker-gap: var(--truncate-marker-gap, 0px);
|
|
1573
|
+
/* Opacity of the marker 'color' property, not of the element itself */
|
|
1574
|
+
--truncate-internal-marker-opacity: var(--truncate-marker-opacity, 50%);
|
|
1575
|
+
/* Opacity of the marker 'color' property specifically for the middle truncate, not opacity of the element itself */
|
|
1576
|
+
--truncate-internal-middle-marker-opacity: var(
|
|
1577
|
+
--truncate-middle-marker-opacity,
|
|
1578
|
+
80%
|
|
1579
|
+
);
|
|
1580
|
+
/* Background color of the default marker */
|
|
1581
|
+
--truncate-internal-marker-background-color: var(
|
|
1582
|
+
--truncate-marker-background-color,
|
|
1583
|
+
light-dark(white, black)
|
|
1584
|
+
);
|
|
1585
|
+
--truncate-internal-marker-background-overlay-color: var(
|
|
1586
|
+
--truncate-marker-background-overlay-color,
|
|
1587
|
+
transparent
|
|
1588
|
+
);
|
|
1589
|
+
--truncate-internal-marker-block-inset: var(
|
|
1590
|
+
--truncate-marker-block-inset,
|
|
1591
|
+
0px
|
|
1592
|
+
);
|
|
1593
|
+
/* Duration of the fade out animation for the marker */
|
|
1594
|
+
--truncate-internal-marker-fade-out-duration: var(
|
|
1595
|
+
--truncate-marker-fade-out-duration,
|
|
1596
|
+
0ms
|
|
1597
|
+
);
|
|
1598
|
+
/* Duration of the fade in animation for the marker */
|
|
1599
|
+
--truncate-internal-marker-fade-in-duration: var(
|
|
1600
|
+
--truncate-marker-fade-in-duration,
|
|
1601
|
+
100ms
|
|
1602
|
+
);
|
|
1603
|
+
|
|
1604
|
+
/* FADE Variant specifics */
|
|
1605
|
+
--truncate-internal-fade-marker-color: var(
|
|
1606
|
+
--truncate-fade-marker-color,
|
|
1607
|
+
#000
|
|
1608
|
+
);
|
|
1609
|
+
--truncate-internal-fade-marker-width: var(
|
|
1610
|
+
--truncate-fade-marker-width,
|
|
1611
|
+
0.2lh
|
|
1612
|
+
);
|
|
1613
|
+
|
|
1614
|
+
/*
|
|
1615
|
+
In some special cases people might be adding spacing in other ways
|
|
1616
|
+
that would benefit from being able to override this, however the container
|
|
1617
|
+
query below can't use this and would need to be redeclared with the overridden
|
|
1618
|
+
value. It's a bad time, but better than nothing.
|
|
1619
|
+
*/
|
|
1620
|
+
--truncate-internal-single-line-height: 1lh;
|
|
1621
|
+
|
|
1622
|
+
height: var(--truncate-internal-single-line-height);
|
|
1623
|
+
min-width: 0;
|
|
1624
|
+
overflow: hidden;
|
|
1625
|
+
}
|
|
1626
|
+
|
|
1627
|
+
[data-truncate-marker] {
|
|
1628
|
+
display: flex;
|
|
1629
|
+
position: absolute;
|
|
1630
|
+
height: var(--truncate-internal-single-line-height);
|
|
1631
|
+
padding-block: var(--truncate-internal-marker-block-inset);
|
|
1632
|
+
box-sizing: border-box;
|
|
1633
|
+
align-items: center;
|
|
1634
|
+
background-clip: content-box;
|
|
1635
|
+
z-index: 2;
|
|
1636
|
+
color: color-mix(
|
|
1637
|
+
in srgb,
|
|
1638
|
+
currentColor var(--truncate-internal-marker-opacity),
|
|
1639
|
+
transparent
|
|
1640
|
+
);
|
|
1641
|
+
|
|
1642
|
+
/* Core trick for hiding the marker until overflow occurs */
|
|
1643
|
+
opacity: 0;
|
|
1644
|
+
transition: opacity var(--truncate-internal-marker-fade-out-duration)
|
|
1645
|
+
ease-in-out;
|
|
1646
|
+
}
|
|
1647
|
+
|
|
1648
|
+
@container measure (height > 1lh) {
|
|
1649
|
+
[data-truncate-marker] {
|
|
1650
|
+
opacity: 1;
|
|
1651
|
+
transition: opacity var(--truncate-internal-marker-fade-in-duration)
|
|
1652
|
+
ease-in-out;
|
|
1653
|
+
}
|
|
1654
|
+
}
|
|
1655
|
+
|
|
1656
|
+
[data-truncate-grid] {
|
|
1657
|
+
display: grid;
|
|
1658
|
+
position: relative;
|
|
1659
|
+
}
|
|
1660
|
+
|
|
1661
|
+
[data-truncate-content='visible'] {
|
|
1662
|
+
white-space: nowrap;
|
|
1663
|
+
}
|
|
1664
|
+
|
|
1665
|
+
[data-truncate-content='overflow'] {
|
|
1666
|
+
opacity: 0;
|
|
1667
|
+
pointer-events: none;
|
|
1668
|
+
-webkit-user-select: none;
|
|
1669
|
+
user-select: none;
|
|
1670
|
+
word-break: break-all;
|
|
1671
|
+
margin-top: calc(-1 * var(--truncate-internal-single-line-height));
|
|
1672
|
+
}
|
|
1673
|
+
|
|
1674
|
+
[data-truncate-marker-cell] {
|
|
1675
|
+
container: measure / size;
|
|
1676
|
+
overflow: visible;
|
|
1677
|
+
-webkit-user-select: none;
|
|
1678
|
+
user-select: none;
|
|
1679
|
+
pointer-events: none;
|
|
1680
|
+
}
|
|
1681
|
+
|
|
1682
|
+
[data-truncate-container='truncate'] {
|
|
1683
|
+
& [data-truncate-grid] {
|
|
1684
|
+
grid-template-columns: minmax(0, max-content) 0;
|
|
1685
|
+
}
|
|
1686
|
+
& [data-truncate-marker] {
|
|
1687
|
+
right: 0;
|
|
1688
|
+
}
|
|
1689
|
+
& [data-truncate-fade] {
|
|
1690
|
+
margin-right: calc(-2 * var(--truncate-internal-fade-marker-width));
|
|
1691
|
+
}
|
|
1692
|
+
}
|
|
1693
|
+
|
|
1694
|
+
[data-truncate-container='fruncate'] {
|
|
1695
|
+
& [data-truncate-grid] {
|
|
1696
|
+
grid-template-columns: 0 minmax(0, max-content) auto;
|
|
1697
|
+
}
|
|
1698
|
+
& [data-truncate-content] {
|
|
1699
|
+
direction: rtl;
|
|
1700
|
+
}
|
|
1701
|
+
& [data-truncate-content] > span {
|
|
1702
|
+
unicode-bidi: plaintext;
|
|
1703
|
+
}
|
|
1704
|
+
& [data-truncate-fade] {
|
|
1705
|
+
margin-left: calc(-2 * var(--truncate-internal-fade-marker-width));
|
|
1706
|
+
}
|
|
1707
|
+
}
|
|
1708
|
+
|
|
1709
|
+
[data-truncate-variant='default'] {
|
|
1710
|
+
& [data-truncate-marker] {
|
|
1711
|
+
background-color: var(--truncate-internal-marker-background-color);
|
|
1712
|
+
background-image: linear-gradient(
|
|
1713
|
+
var(--truncate-internal-marker-background-overlay-color),
|
|
1714
|
+
var(--truncate-internal-marker-background-overlay-color)
|
|
1715
|
+
);
|
|
1716
|
+
}
|
|
1717
|
+
& [data-truncate-marker]::after,
|
|
1718
|
+
& [data-truncate-marker]::before {
|
|
1719
|
+
content: '';
|
|
1720
|
+
position: absolute;
|
|
1721
|
+
width: calc(
|
|
1722
|
+
var(--truncate-internal-marker-fade-width) +
|
|
1723
|
+
var(--truncate-internal-marker-gap)
|
|
1724
|
+
);
|
|
1725
|
+
inset-block-start: var(--truncate-internal-marker-block-inset);
|
|
1726
|
+
height: max(
|
|
1727
|
+
0px,
|
|
1728
|
+
calc(
|
|
1729
|
+
var(--truncate-internal-single-line-height) -
|
|
1730
|
+
var(--truncate-internal-marker-block-inset) * 2
|
|
1731
|
+
)
|
|
1732
|
+
);
|
|
1733
|
+
background-color: var(--truncate-internal-marker-background-color);
|
|
1734
|
+
background-image: linear-gradient(
|
|
1735
|
+
var(--truncate-internal-marker-background-overlay-color),
|
|
1736
|
+
var(--truncate-internal-marker-background-overlay-color)
|
|
1737
|
+
);
|
|
1738
|
+
mask-image: linear-gradient(
|
|
1739
|
+
var(--truncate-internal-fade-dir),
|
|
1740
|
+
#000 0%,
|
|
1741
|
+
#000 var(--truncate-internal-marker-gap),
|
|
1742
|
+
transparent 100%
|
|
1743
|
+
);
|
|
1744
|
+
}
|
|
1745
|
+
& [data-truncate-marker]::after {
|
|
1746
|
+
--truncate-internal-fade-dir: to right;
|
|
1747
|
+
right: calc(
|
|
1748
|
+
-1 *
|
|
1749
|
+
(
|
|
1750
|
+
var(--truncate-internal-marker-fade-width) +
|
|
1751
|
+
var(--truncate-internal-marker-gap)
|
|
1752
|
+
)
|
|
1753
|
+
);
|
|
1754
|
+
}
|
|
1755
|
+
& [data-truncate-marker]::before {
|
|
1756
|
+
--truncate-internal-fade-dir: to left;
|
|
1757
|
+
left: calc(
|
|
1758
|
+
-1 *
|
|
1759
|
+
(
|
|
1760
|
+
var(--truncate-internal-marker-fade-width) +
|
|
1761
|
+
var(--truncate-internal-marker-gap)
|
|
1762
|
+
)
|
|
1763
|
+
);
|
|
1764
|
+
}
|
|
1765
|
+
}
|
|
1766
|
+
|
|
1767
|
+
[data-truncate-variant='fade'] {
|
|
1768
|
+
& [data-truncate-marker] {
|
|
1769
|
+
background: transparent;
|
|
1770
|
+
}
|
|
1771
|
+
}
|
|
1772
|
+
|
|
1773
|
+
[data-truncate-fade] {
|
|
1774
|
+
box-shadow:
|
|
1775
|
+
0 0 calc(var(--truncate-internal-fade-marker-width) / 2)
|
|
1776
|
+
var(--truncate-internal-fade-marker-color),
|
|
1777
|
+
0 0 var(--truncate-internal-fade-marker-width)
|
|
1778
|
+
var(--truncate-internal-fade-marker-color);
|
|
1779
|
+
width: calc(var(--truncate-internal-fade-marker-width) * 2);
|
|
1780
|
+
height: calc(
|
|
1781
|
+
var(--truncate-internal-single-line-height) -
|
|
1782
|
+
(var(--truncate-internal-fade-marker-width) * 2)
|
|
1783
|
+
);
|
|
1784
|
+
margin: var(--truncate-internal-fade-marker-width) 0;
|
|
1785
|
+
}
|
|
1786
|
+
|
|
1787
|
+
[data-truncate-group-container='middle'] {
|
|
1788
|
+
& [data-truncate-container] {
|
|
1789
|
+
--truncate-marker-opacity: var(--truncate-internal-middle-marker-opacity);
|
|
1790
|
+
}
|
|
1791
|
+
|
|
1792
|
+
display: flex;
|
|
1793
|
+
min-width: 0;
|
|
1794
|
+
|
|
1795
|
+
& > div {
|
|
1796
|
+
min-width: 0;
|
|
1797
|
+
}
|
|
1798
|
+
|
|
1799
|
+
& > div[data-truncate-segment-priority='1'] {
|
|
1800
|
+
flex: 0 1 max-content;
|
|
1801
|
+
}
|
|
1802
|
+
& > div[data-truncate-segment-priority='2'] {
|
|
1803
|
+
flex: 0 999999 max-content;
|
|
1804
|
+
}
|
|
1805
|
+
}
|
|
1806
|
+
}
|
|
1807
|
+
`,Vs=`@layer base, unsafe;`;function Hs(e){return`${Vs}
|
|
1808
|
+
@layer base {
|
|
1809
|
+
${e}
|
|
1810
|
+
}`}function Us(e){return`${Vs}
|
|
1811
|
+
@layer unsafe {
|
|
1812
|
+
${e}
|
|
1813
|
+
}`}var Ws=new WeakMap;function Gs(e){let t=Ws.get(e);if(t!=null)return t;let n=document.createElement(`div`);n.setAttribute(Kr,`true`);let r=document.createElement(`div`);r.style.position=`relative`,r.style.height=`200%`,n.appendChild(r),e.appendChild(n);let i=Math.max(n.offsetWidth-n.clientWidth,0);return n.remove(),Ws.set(e,i),i}function Ks(e,t){if(!e.isConnected)return;let n=Gs(t);if(n==null)return;let r=t.querySelector(`style[${qr}]`),i=r instanceof HTMLStyleElement?r:document.createElement(`style`);r instanceof HTMLStyleElement||(i.setAttribute(qr,``),t.appendChild(i)),i.textContent=`:host { ${Jr}: ${n}px; }`}var qs;function Js(e){if(typeof CSSStyleSheet<`u`&&typeof CSSStyleSheet.prototype.replaceSync==`function`&&`adoptedStyleSheets`in e){qs??(qs=new CSSStyleSheet,qs.replaceSync(Hs(Bs)));let t=!1;try{e.adoptedStyleSheets=[qs],t=!0}catch{}if(t){e.querySelector(`style[${Wr}]`)?.remove();return}}if(e.querySelector(`style[data-file-tree-style]`)==null){let t=document.createElement(`style`);t.setAttribute(Wr,``),t.textContent=Hs(Bs),e.prepend(t)}}function Ys(e,t){Xs(e,t),Js(t),Ks(e,t)}function Xs(e,t){let n=e.querySelector(`template[shadowrootmode="open"], template[data-file-tree-shadowrootmode="open"]`);n instanceof HTMLTemplateElement&&(t.childNodes.length>0||(t.appendChild(n.content.cloneNode(!0)),n.hasAttribute(`shadowrootmode`)&&n.remove()))}if(typeof HTMLElement<`u`&&customElements.get(`file-tree-container`)==null){class e extends HTMLElement{constructor(){super()}connectedCallback(){let e=this.shadowRoot??this.attachShadow({mode:`open`});Ys(this,e)}}if(customElements.define(Ur,e),typeof document<`u`)for(let e of Array.from(document.querySelectorAll(Ur)))e instanceof HTMLElement&&Ys(e,e.shadowRoot??e.attachShadow({mode:`open`}))}var Zs=e=>e.startsWith(`f::`)?e.slice(3):e;function Qs(e){let t=e.lastIndexOf(`/`);return t<0?{parentPath:``,baseName:e}:{parentPath:e.slice(0,t),baseName:e.slice(t+1)}}function $s(e,t){return e===``?t:`${e}/${t}`}function ec({files:e,path:t,isFolder:n,nextBasename:r}){let i=Zs(t),a=r.trim();if(a.length===0)return{error:`Name cannot be empty.`};if(a.includes(`/`))return{error:`Name cannot include "/".`};let{parentPath:o,baseName:s}=Qs(i);if(a===s)return{nextFiles:e,sourcePath:i,destinationPath:i,isFolder:n};let c=$s(o,a),l=Array(e.length),u=new Set;if(!n){let t=`${c}/`,r=!1;for(let n=0;n<e.length;n++){let a=e[n];if(a!==i&&a.startsWith(t))return{error:`"${c}" already exists.`};let o=a===i?c:a;if(u.has(o))return{error:`"${c}" already exists.`};u.add(o),l[n]=o,a===i&&(r=!0)}return r?{nextFiles:l,sourcePath:i,destinationPath:c,isFolder:n}:{error:`Could not find the selected file to rename.`}}let d=`${i}/`,f=`${c}/`,p=0;for(let t=0;t<e.length;t++){let n=e[t],r=n===i||n.startsWith(d);if(!r&&(n===c||n.startsWith(f)))return{error:`"${c}" already exists.`};let a=r?`${c}${n.slice(i.length)}`:n;if(u.has(a))return{error:`"${c}" already exists.`};u.add(a),l[t]=a,r&&p++}return p===0?{error:`Could not find the selected folder to rename.`}:{nextFiles:l,sourcePath:i,destinationPath:c,isFolder:n}}function tc(e){return e.endsWith(`/`)}function nc(e){let t=e.endsWith(`/`)?e.slice(0,-1):e,n=t.lastIndexOf(`/`),r=n<0?t:t.slice(n+1);return e.endsWith(`/`)?`${r}/`:r}function rc(e){let t=[],n=new Set;for(let r of e)n.has(r)||(n.add(r),t.push(r));let r=new Set;for(let e of t.toSorted((e,t)=>e.length===t.length?e.localeCompare(t):e.length-t.length)){let t=(e.endsWith(`/`)?e.slice(0,-1):e).split(`/`),n=!1;for(let e=0;e<t.length-1;e+=1){let i=`${t.slice(0,e+1).join(`/`)}/`;if(r.has(i)){n=!0;break}}n||r.add(e)}return t.filter(e=>r.has(e))}function ic(e,t){return t.includes(e)?rc(t):[e]}function ac(e,t){return e===t?!0:e==null||t==null?!1:e.kind===t.kind&&e.directoryPath===t.directoryPath&&e.flattenedSegmentPath===t.flattenedSegmentPath&&e.hoveredPath===t.hoveredPath}function oc(e,t){return{draggedPaths:e,target:t}}function sc(e,t){if(t.kind!==`directory`||t.directoryPath==null)return!1;for(let n of e)if(tc(n)&&(t.directoryPath===n||t.directoryPath.startsWith(n)))return!0;return!1}function cc(e,t){return t.kind===`root`||t.directoryPath==null?nc(e):t.directoryPath}function lc(e,t){let n=e.map(e=>{let n=cc(e,t);return n===e?null:{from:e,to:n,type:`move`}}).filter(e=>e!=null);return n.length===0?null:{operations:n,result:{draggedPaths:e,operation:n.length===1?`move`:`batch`,target:t}}}var uc=Symbol(`FILE_TREE_RENAME_VIEW`);function dc(e){return e.operation===`add`||e.operation===`remove`||e.operation===`move`||e.operation===`batch`}var fc=512,pc=512;function mc(e,t){if(e.size!==t.length)return!1;for(let n of t)if(!e.has(n))return!1;return!0}function hc(e){let t=e.endsWith(`/`)?e.slice(0,-1):e;if(t.length===0)return[];let n=t.split(`/`);return n.slice(0,-1).map((e,t)=>`${n.slice(0,t+1).join(`/`)}/`)}function gc(e){return hc(e).at(-1)??null}function _c(e,t){return t==null?e:e.startsWith(t)?e.slice(t.length):e}var vc=e=>{let t=e.trim();return t.length===0?``:(t.includes(`\\`)?t.replaceAll(`\\`,`/`):t).toLowerCase()},yc=e=>e.toLowerCase();function bc(e){return e.endsWith(`/`)}function xc(e){let t=e.endsWith(`/`)?e.slice(0,-1):e,n=t.lastIndexOf(`/`);return n<0?t:t.slice(n+1)}function Sc(e){return e.endsWith(`/`)?e.slice(0,-1):e}function Cc(e,t){return t&&!e.endsWith(`/`)?`${e}/`:e}function wc(e,t,n){if(e===t)return n;let r=t.endsWith(`/`)?t:`${t}/`;return e.startsWith(r)?`${n.endsWith(`/`)?n:`${n}/`}${e.slice(r.length)}`:e}function Tc(e,t){if(e===t)return!0;let n=t.endsWith(`/`)?t:`${t}/`;return e.startsWith(n)}function Ec(e,t,n=!1){if(e==null)return null;switch(t.operation){case`add`:case`expand`:case`collapse`:case`mark-directory-unloaded`:case`begin-child-load`:case`apply-child-patch`:case`complete-child-load`:case`fail-child-load`:case`cleanup`:return e;case`remove`:return Tc(e,t.path)?n?e:null:e;case`move`:return wc(e,t.from,t.to);case`batch`:{let r=e;for(let e of t.events)if(r=Ec(r,e,n),r==null)return null;return r}}}function Dc(e){return{canonicalChanged:e.canonicalChanged,projectionChanged:e.projectionChanged,visibleCountDelta:e.visibleCountDelta}}function Oc(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n<e.length;n+=1)if(e[n]!==t[n])return!1;return!0}function kc(e,t,n){let{paths:r,preparedInput:i}=e;if(i==null){if(r==null)throw Error(`FileTree requires paths or preparedInput`);return{paths:r,preparedInput:void 0}}let a=i.paths;if(r==null)return{paths:a,preparedInput:i};if(!Oc(Fs.preparePaths(r,n==null?{}:{sort:n}),a))throw Error(`FileTree ${t} received paths and preparedInput for different path lists`);return{paths:a,preparedInput:i}}function Ac(e){switch(e.operation){case`add`:return{...Dc(e),operation:`add`,path:e.path};case`remove`:return{...Dc(e),operation:`remove`,path:e.path,recursive:e.recursive};case`move`:return{...Dc(e),from:e.from,operation:`move`,to:e.to}}}function jc(e){return{...Dc(e),events:e.events.filter(e=>e.operation===`add`||e.operation===`remove`||e.operation===`move`).map(e=>Ac(e)),operation:`batch`}}function Mc(e){switch(e.operation){case`add`:case`remove`:case`move`:return Ac(e);case`batch`:return jc(e);default:return null}}function Nc(e,t,n){if(e===0)return-1;if(n!=null){let e=t(n);if(e!=null)return e;let r=hc(n);for(let e=r.length-1;e>=0;--e){let n=r[e];if(n==null)continue;let i=t(n);if(i!=null)return i}}return 0}function Pc(e,t,n){if(e.paths.length===0)return{focusedIndex:-1,getParentIndex:e.getParentIndex,paths:e.paths,posInSetByIndex:e.posInSetByIndex,setSizeByIndex:e.setSizeByIndex};if(t==null)return{focusedIndex:0,getParentIndex:e.getParentIndex,paths:e.paths,posInSetByIndex:e.posInSetByIndex,setSizeByIndex:e.setSizeByIndex};let r=n??(t=>e.visibleIndexByPath.get(t)??null);return{focusedIndex:Nc(e.paths.length,r,t),getParentIndex:e.getParentIndex,paths:e.paths,posInSetByIndex:e.posInSetByIndex,setSizeByIndex:e.setSizeByIndex}}var Fc=class{#e;#t=new Set;#n=new Map;#r=null;#i=null;#a=new Map;#o=new Map;#s=-1;#c=null;#l=!1;#u=e=>-1;#d=new Map;#f=null;#p=null;#m=null;#h=null;#g=null;#_;#v;#y;#b=[];#x=new Int32Array;#S=new Int32Array;#C=void 0;#w=!1;#T=null;#E=``;#D=!1;#O=new Set;#k=[];#A;#j=null;#M=null;#N=null;#P=null;#F=null;#I=null;#L=null;#R=new Set;#z=0;#B;#V=0;#H=!1;#U=0;#W;constructor(e){let{dragAndDrop:t,fileTreeSearchMode:n,initialSearchQuery:r,initialSelectedPaths:i,renaming:a,onSearchChange:o,paths:s,preparedInput:c,...l}=e,u=kc({paths:s,preparedInput:c},`constructor`,l.sort);this.#e=l,t!=null&&t!==!1&&(this.#r=t===!0?{}:t),this.#w=a!=null&&a!==!1,a!=null&&a!==!1&&a!==!0&&(this.#C=a.canRename,this.#v=a.onError,this.#_=a.onRename),this.#y=o,this.#A=n??`hide-non-matches`,this.#B=this.#se(u.paths,u.preparedInput);let d=i?.map(e=>this.#Ae(e)).filter(e=>e!=null)??[],f=d.at(-1)??null;d.length>0&&(this.#R=new Set(d),this.#L=f,this.#z=1),this.#Oe(f,!1),r!=null&&this.#Se(r,!1),this.#W=this.#Fe()}destroy(){this.#W?.(),this.#W=null,this.#n.clear(),this.#t.clear(),this.#d.clear(),this.#i=null,this.#pe()}focusFirstItem(){this.#ve().length>0&&this.#Me(0)}focusLastItem(){this.#U<=0||(this.#Ne(),this.#Me(this.#U-1))}focusNextItem(){this.#De(1)}focusParentItem(){if(this.#c==null)return;let e=gc(this.#c);if(e==null)return;let t=this.#Y(e);t>=0&&this.#Me(t)}focusPath(e){let t=this.#B.getPathInfo(e)?.path??null;if(t==null)return;this.#Ne();let n=this.#Y(t);n>=0&&this.#Me(n)}focusNearestPath(e){let t=this.resolveNearestVisiblePath(e);if(t==null)return null;let n=this.#Y(t);return n>=0?(this.#Me(n),this.#ve()[n]??t):null}focusPreviousItem(){this.#De(-1)}getFocusedIndex(){return this.#s}getFocusedItem(){return this.#c==null?null:this.#X(this.#c)}getFocusedPath(){return this.#c}resolveNearestVisiblePath(e){let t=this.#ve();if(this.#U===0)return null;if(e==null)return this.#c??t[0]??null;let n=this.#B.getPathInfo(e)?.path??e,r=this.#Y(n);return r>=0?t[r]??n:this.#J(n)??this.#c??t[0]??null}getSelectedPaths(){return[...this.#R]}getSelectionVersion(){return this.#z}getVisibleCount(){return this.#U}getVisibleRows(e,t){if(t<e||this.#U===0)return[];let n=Math.max(0,e),r=Math.min(this.#U-1,t);if(r<n)return[];let i=r-n+1;if(this.#F==null&&!this.#l&&r>=this.#b.length&&i<=pc){let e=[];for(let t=n;t<=r;t+=1){let n=this.#B.getVisibleRowContext(t);if(n==null)break;e.push(this.#Q(n))}return e}if(!this.#l&&r>=this.#b.length&&this.#Ne(),this.#F!=null){let e=Array.from({length:r-n+1},(e,t)=>this.#ye(n+t)),t=new Map,i=e[0]??-1,a=i;for(let n=1;n<=e.length;n+=1){let r=e[n];if(r!=null&&r===a+1){a=r;continue}if(i>=0&&this.#B.getVisibleSlice(i,a).forEach((e,n)=>{t.set(i+n,e)}),r==null){i=-1,a=-1;continue}i=r,a=r}return Array.from({length:r-n+1},(e,r)=>{let i=n+r,a=this.#ye(i),o=t.get(a),s=this.#b[a];if(o==null||s==null)throw Error(`Missing projection row for filtered visible index ${String(i)}`);return this.#Z(o,i,a,{ancestorPaths:this.#te(a),path:s})})}return this.#B.getVisibleSlice(n,r).map((e,t)=>{let r=n+t,i=this.#b[r];if(i==null)throw Error(`Missing projection path for visible index ${String(r)}`);return this.#Z(e,r,r,{ancestorPaths:this.#te(r),path:i})})}getStickyRowCandidates(e,t){if(this.#F!=null)return null;if(this.#U===0||e<=0||t<=0)return[];let n=[];for(let r=0;r<this.#U;r+=1){let i=e+r*t,a=Math.min(this.#U-1,Math.floor(i/t)),o=this.#$(a,r)??(a>0?this.#$(a-1,r):void 0);if(o==null)break;n.push({row:this.#Q(o),subtreeEndIndex:o.subtreeEndIndex})}return n}getItem(e){let t=this.#B.getPathInfo(e);return t==null?null:this.#X(t.path,t)}selectAllVisiblePaths(){this.#Ne();let e=[...this.#ve()];this.#re(e,this.#c??this.#L)}selectOnlyPath(e){let t=this.#Ae(e);t!=null&&this.#re([t],t)}selectPath(e){let t=this.#Ae(e);t==null||this.#R.has(t)||this.#re([...this.#R,t])}deselectPath(e){let t=this.#Ae(e);t==null||!this.#R.has(t)||this.#re([...this.#R].filter(e=>e!==t))}toggleFocusedSelection(){this.#c!=null&&this.togglePathSelectionFromInput(this.#c)}togglePathSelection(e){let t=this.#Ae(e);if(t!=null){if(this.#R.has(t)){this.deselectPath(t);return}this.selectPath(t)}}togglePathSelectionFromInput(e){let t=this.#Ae(e);if(t!=null){if(this.#R.has(t)){this.#re([...this.#R].filter(e=>e!==t),t);return}this.#re([...this.#R,t],t)}}selectPathRange(e,t){let n=this.#Ae(e);if(n==null)return;this.#Ne();let r=this.#L,i=r==null?-1:this.#be(r),a=this.#be(n);if(i===-1||a===-1){let e=t?[...this.#R,n]:[n];this.#re(e,n);return}let[o,s]=i<=a?[i,a]:[a,i],c=this.#ve().slice(o,s+1),l=t?[...this.#R,...c]:c;this.#re(l,r)}extendSelectionFromFocused(e){if(this.#c==null)return;let t=this.#s;if(t===-1)return;let n=Math.min(this.#U-1,Math.max(0,t+e));if(n===t)return;!this.#l&&n>=this.#b.length&&this.#Ne();let r=this.#ve(),i=r[t]??null,a=r[n]??null;if(i==null||a==null)return;let o=new Set(this.#R);o.has(i)&&o.has(a)?o.delete(i):o.add(a),this.#re([...o],this.#L??i,!1),this.#Me(n)}getDragAndDropConfig(){return this.#r}isDragAndDropEnabled(){return this.#r!=null}getDragSession(){return this.#i==null?null:{draggedPaths:[...this.#i.draggedPaths],primaryPath:this.#i.primaryPath,target:this.#i.target==null?null:{...this.#i.target}}}startDrag(e){if(this.#r==null)return!1;let t=this.#Ae(e);if(t==null||this.#M!=null&&this.#M.length>0)return!1;let n=this.getSelectedPaths(),r=ic(t,n);return this.#r.canDrag?.(r)===!1?!1:(n.includes(t)||this.#re([t],t,!1),this.#je(t),this.#i={draggedPaths:r,primaryPath:t,target:null},this.#we(),!0)}setDragTarget(e){let t=this.#i;if(t==null)return;let n=e;if(n!=null){let e=oc(t.draggedPaths,n);(sc(t.draggedPaths,n)||this.#r?.canDrop?.(e)===!1)&&(n=null)}ac(t.target,n)||(this.#i={...t,target:n},this.#we())}cancelDrag(){this.#i!=null&&(this.#i=null,this.#we())}completeDrag(){let e=this.#i;if(e==null)return!1;this.#i=null;let t=e.target==null?null:{...e.target};if(t==null)return this.#we(),!1;let n=oc(e.draggedPaths,t);if(sc(e.draggedPaths,t)||this.#r?.canDrop?.(n)===!1)return this.#we(),!1;let r=lc(e.draggedPaths,t);if(r==null)return this.#we(),!1;try{if(r.operations.length===1){let e=r.operations[0];if(e==null||e.type!==`move`)throw Error(`Expected a single move operation for one-item drops`);this.#B.move(e.from,e.to,{collision:e.collision})}else this.#oe(r.operations),this.#B.batch(r.operations)}catch(e){return this.#we(),this.#r?.onDropError?.(e instanceof Error?e.message:String(e),n),!1}return this.#r?.onDropComplete?.(r.result),!0}subscribe(e){return this.#t.add(e),e(),()=>{this.#t.delete(e)}}add(e){this.#B.add(e)}remove(e,t={}){this.#B.remove(e,t)}move(e,t,n={}){this.#B.move(e,t,n)}batch(e){this.#B.batch(e)}onMutation(e,t){let n=e,r=t,i=this.#n.get(n);return i??(i=new Set,this.#n.set(n,i)),i.add(r),()=>{let e=this.#n.get(n);e?.delete(r),e?.size===0&&this.#n.delete(n)}}setSearch(e){this.#Se(e,!0)}openSearch(e=``){this.#Se(e,!0)}closeSearch(){this.#Se(null,!0)}isSearchOpen(){return this.#M!==null}getSearchValue(){return this.#M??``}getSearchMatchingPaths(){return this.#k}focusNextSearchMatch(){this.#xe(1)}focusPreviousSearchMatch(){this.#xe(-1)}startRenaming(e=this.#c??``,t={}){if(!this.#w)return!1;let n=this.#B.getPathInfo(e);if(n==null)return!1;let r=n.path,i=bc(r),a=Sc(r);if(this.#C?.({isFolder:i,path:a})===!1)return!1;for(let e of hc(r))this.#B.isExpanded(e)||this.#B.expand(e);return this.#re([r],r,!1),this.#M!=null&&(this.#Se(null,!1),this.#y?.(this.#M)),this.#je(r),this.#T=r,this.#E=xc(r),this.#D=t.removeIfCanceled??!1,this.#we(),!0}[uc](){return{cancel:()=>{this.#G()},commit:()=>{this.#K()},getPath:()=>this.#T,getValue:()=>this.#E,isActive:()=>this.#T!=null,setValue:e=>{this.#q(e)}}}#G(){if(this.#T==null)return;let e=this.#T,t=this.#D;if(this.#T=null,this.#E=``,this.#D=!1,t){this.remove(e,bc(e)?{recursive:!0}:void 0);return}this.#je(e),this.#we()}#K(){let e=this.#T;if(e==null)return;if(this.#D&&this.#E.trim().length===0){this.#T=null,this.#E=``,this.#D=!1,this.remove(e,bc(e)?{recursive:!0}:void 0);return}let t=bc(e),n=ec({files:this.#B.list(),isFolder:t,nextBasename:this.#E,path:Sc(e)});if(this.#T=null,this.#E=``,this.#D=!1,`error`in n){this.#je(e),this.#v?.(n.error),this.#we();return}if(n.sourcePath===n.destinationPath){this.#je(e),this.#we();return}this.#_?.({destinationPath:n.destinationPath,isFolder:n.isFolder,sourcePath:n.sourcePath}),this.move(Cc(n.sourcePath,t),Cc(n.destinationPath,t))}#q(e){this.#T==null||this.#E===e||(this.#E=e,this.#we())}resetPaths(e,t={}){let n=this.#B.list().length,r=this.#U,i=kc({paths:e,preparedInput:t.preparedInput},`resetPaths`,this.#e.sort),a=this.#se(i.paths,i.preparedInput,t.initialExpandedPaths),o=this.#c,s=this.#T,c=this.getSelectedPaths(),l=this.#L;this.#W?.(),this.#B=a,this.#d.clear(),this.#pe();let u=c.map(e=>a.getPathInfo(e)?.path??null).filter(e=>e!=null),d=!mc(this.#R,u);this.#R=new Set(u),d&&(this.#z+=1),this.#L=l==null?null:a.getPathInfo(l)?.path??null,this.#T=s==null?null:a.getPathInfo(s)?.path??null,this.#T??(this.#E=``,this.#D=!1),this.#Oe(o,o!=null||u.length>0||this.#L!=null),this.#W=this.#Fe(),this.#we(),this.#Te({canonicalChanged:!0,operation:`reset`,pathCountAfter:i.paths.length,pathCountBefore:n,projectionChanged:!0,usedPreparedInput:t.preparedInput!=null,visibleCountDelta:this.#U-r})}#J(e){this.#Ne();let t=gc(e),n=_c(e,t),r=null,i=null;for(let e of this.#ve()){if(gc(e)!==t)continue;let a=_c(e,t);if(a<n){r=e;continue}if(a>n){i=e;break}}return r??i}#Y(e){let t=this.#be(e);if(t!==-1)return t;let n=hc(e);for(let e=n.length-1;e>=0;--e){let t=n[e];if(t==null)continue;let r=this.#be(t);if(r!==-1)return r}return this.#ve().length>0?0:-1}#X(e,t){let n=this.#d.get(e);if(n!=null)return n;let r=t??this.#B.getPathInfo(e);if(r==null)return null;let i=r.kind===`directory`?this.#ie(r.path):this.#ae(r.path);return this.#d.set(r.path,i),i}#Z(e,t,n,r){return{ancestorPaths:r.ancestorPaths,depth:e.depth,flattenedSegments:e.flattenedSegments?.map(e=>({isTerminal:e.isTerminal,name:e.name,path:e.path})),hasChildren:e.hasChildren,index:t,isExpanded:e.isExpanded,isFlattened:e.isFlattened,isFocused:r.path===this.#c,isSelected:this.#R.has(r.path),kind:e.kind,level:e.depth,name:e.name,path:r.path,posInSet:r.posInSet??this.#x[n]??0,setSize:r.setSize??this.#S[n]??0}}#Q(e){return this.#Z(e.row,e.index,e.index,{ancestorPaths:e.ancestorPaths,path:e.row.path,posInSet:e.posInSet,setSize:e.setSize})}#$(e,t){let n=this.#B.getVisibleRowContext(e);return n==null?void 0:n.ancestorRows[t]??(t===n.ancestorRows.length&&n.row.kind===`directory`&&n.row.isExpanded?n:void 0)}#ee(e){let t=this.#a.get(e);if(t!=null)return t;let n=this.#u(e),r=n<0?[]:[...this.#ee(n),n];return this.#a.set(e,r),r}#te(e){let t=this.#o.get(e);if(t!=null)return t;let n=this.#ee(e).map(e=>this.#b[e]??``).filter(e=>e!==``);return this.#o.set(e,n),n}#ne(e){this.#B.collapse(e)}#re(e,t=this.#L,n=!0){let r=[...new Set(e)],i=!mc(this.#R,r),a=this.#L!==t;!i&&!a||(this.#R=new Set(r),this.#L=t,i&&(this.#z+=1),n&&this.#we())}#ie(e){return{collapse:()=>{this.#ne(e)},deselect:()=>{this.deselectPath(e)},expand:()=>{this.#Ee(e)},focus:()=>{this.focusPath(e)},getPath:()=>e,isDirectory:()=>!0,isExpanded:()=>this.#B.isExpanded(e),isFocused:()=>this.#c===e,isSelected:()=>this.#R.has(e),select:()=>{this.selectPath(e)},toggleSelect:()=>{this.togglePathSelection(e)},toggle:()=>{this.#Ie(e)}}}#ae(e){return{deselect:()=>{this.deselectPath(e)},focus:()=>{this.focusPath(e)},getPath:()=>e,isDirectory:()=>!1,isFocused:()=>this.#c===e,isSelected:()=>this.#R.has(e),select:()=>{this.selectPath(e)},toggleSelect:()=>{this.togglePathSelection(e)}}}#oe(e){let t=this.#B.list();this.#se(t).batch(e)}#se(e,t,n){return new Fs({...this.#e,paths:e,preparedInput:t??void 0,...n===void 0?{}:{initialExpandedPaths:n}})}#ce(){return this.#h??=this.#B.list(),this.#h}#le(){if(this.#m!=null)return this.#m;let e=new Set;for(let t of this.#ce()){e.add(t);for(let n of hc(t))e.add(n)}return this.#m=[...e].sort(),this.#m}#ue(){return this.#g??=this.#ce().map(yc),this.#g}#de(){return this.#f??=this.#le().filter(e=>e.endsWith(`/`)),this.#f}#fe(){return this.#p??=this.#de().map(yc),this.#p}#pe(){this.#f=null,this.#p=null,this.#m=null,this.#h=null,this.#g=null}#me(){return this.#de().filter(e=>this.#B.isExpanded(e))}#he(e){let t=new Set(this.#j??[]);if(e)for(let e of this.#R)for(let n of hc(e))t.add(n);this.#ge(t)}#ge(e){this.#H=!0;try{for(let t of this.#de()){let n=e.has(t),r=this.#B.isExpanded(t);n&&!r?this.#B.expand(t):!n&&r&&this.#B.collapse(t)}}finally{this.#H=!1}}#_e(){let e=this.#b;if(this.#k=e.filter(e=>this.#O.has(e)),this.#M==null||this.#M.length===0||this.#A!==`hide-non-matches`||this.#O.size===0){this.#F=null,this.#I=null,this.#P=null,this.#U=this.#V;return}let t=[],n=[],r=new Map;for(let[i,a]of e.entries())this.#N?.has(a)===!0&&(r.set(a,n.length),t.push(i),n.push(a));this.#F=t,this.#I=n,this.#P=r,this.#U=n.length}#ve(){return this.#I??this.#b}#ye(e){return this.#F?.[e]??e}#be(e){return this.#P?.get(e)??this.#B.getVisibleIndex(e)??-1}#xe(e){let t=this.#k;if(t.length===0)return;let n=this.#c,r=n==null?-1:t.indexOf(n),i=t[r<0?e>0?0:t.length-1:Math.min(t.length-1,Math.max(0,r+e))];i!=null&&this.focusPath(i)}#Se(e,t){let n=e==null?null:vc(e),r=this.#M;if(r!==n){if(r==null&&n!=null&&(this.#j=this.#me()),this.#M=n,n==null)this.#he(!0),this.#j=null,this.#O.clear(),this.#N=null,this.#Oe(this.#c,!0);else if(n.length===0)this.#he(!1),this.#O.clear(),this.#N=null,this.#Oe(this.#c,!0);else{let e=this.#Ce();this.#Oe(e,!0)}t&&(this.#y?.(this.#M),this.#we())}}#Ce(){if(this.#M==null||this.#M.length===0)return this.#O.clear(),this.#c;let e=this.#M,t=this.#ce(),n=this.#ue(),r=[],i=new Set,a=null;for(let o=0;o<t.length;o+=1){if(!n[o].includes(e))continue;let s=t[o];r.push(s),i.add(s),a??=s}let o=this.#de(),s=this.#fe();for(let t=0;t<o.length;t+=1){if(!s[t].includes(e))continue;let n=o[t];i.has(n)||(r.push(n),i.add(n),a??=n)}this.#O=i;let c=this.#A===`hide-non-matches`&&r.length>0?new Set:null;this.#N=c;let l=this.#A===`expand-matches`?new Set(this.#j??[]):new Set;for(let e of r){c?.add(e),e.endsWith(`/`)&&l.add(e);for(let t of hc(e))l.add(t),c?.add(t)}return this.#ge(l),a??this.#c}#we(){for(let e of this.#t)e()}#Te(e){this.#n.get(e.operation)?.forEach(t=>{t(e)}),this.#n.get(`*`)?.forEach(t=>{t(e)})}#Ee(e){for(let t of hc(e))this.#B.isExpanded(t)||this.#B.expand(t);this.#B.isExpanded(e)||this.#B.expand(e)}#De(e){let t=this.#U;if(t===0)return;let n=this.#s===-1?0:this.#s,r=Math.min(t-1,Math.max(0,n+e));(r!==n||this.#s===-1)&&(!this.#l&&this.#F==null&&r>=this.#b.length&&this.#Ne(),this.#Me(r))}#Oe(e,t=!0){let n=this.#B.getVisibleCount();this.#V=n;let r=Pc(this.#B.getVisibleTreeProjectionData(t?void 0:Math.min(n,fc)),e,t?e=>this.#B.getVisibleIndex(e):void 0);this.#a.clear(),this.#o.clear(),this.#l=r.paths.length>=n,this.#u=r.getParentIndex,this.#b=r.paths,this.#x=r.posInSetByIndex,this.#S=r.setSizeByIndex,this.#_e(),this.#s=e==null?this.#ve().length>0?0:-1:this.#Y(e),this.#c=this.#s<0?null:this.#ke(this.#s)}#ke(e){return this.#ve()[e]??(this.#F==null?this.#B.getVisibleRowContext(e)?.row.path??null:null)}#Ae(e){return this.#B.getPathInfo(e)?.path??null}#je(e){if(e==null)return;let t=this.#Y(e);t>=0&&this.#Me(t,!1)}#Me(e,t=!0){let n=this.#ke(e);n!=null&&(this.#s===e&&this.#c===n||(this.#s=e,this.#c=n,t&&this.#we()))}#Ne(){this.#l||this.#Oe(this.#c,!0)}#Pe(e){let t=Ec(this.#T,e);t==null&&this.#T!=null&&(this.#E=``),this.#T=t;let n=Ec(this.#c,e,!0),r=[...this.#R].map(t=>Ec(t,e)).filter(e=>e!=null).map(e=>this.#B.getPathInfo(e)?.path??null).filter(e=>e!=null),i=Ec(this.#L,e),a=i==null?null:this.#B.getPathInfo(i)?.path??null,o=[...new Set(r)];return mc(this.#R,o)||(this.#R=new Set(o),this.#z+=1),this.#L=a,n}#Fe(){return this.#B.on(`*`,e=>{if(this.#H)return;e.canonicalChanged&&(this.#d.clear(),this.#pe()),this.#i!=null&&dc(e)&&(this.#i=null);let t=dc(e)?this.#Pe(e):this.#c,n=this.#M!=null&&this.#M.length>0?this.#Ce():this.#M===``?this.#c:t,r=this.#M!=null||e.operation!==`expand`&&e.operation!==`collapse`;this.#Oe(n,r),this.#we();let i=Mc(e);i!=null&&this.#Te(i)})}#Ie(e){if(this.#B.isExpanded(e)){this.#ne(e);return}this.#Ee(e)}},Ic=e=>{if(e==null||e.length===0)return`0`;let t=`${e.length}`;for(let n of e)t+=`\0${n.path}\0${n.status}`;return t};function Lc(e){let t=e.endsWith(`/`),n=``,r=-1;for(let t=0;t<=e.length;t+=1){if(!(e[t]===`/`||t===e.length)){r===-1&&(r=t);continue}r!==-1&&(n!==``&&(n+=`/`),n+=e.slice(r,t),r=-1)}return n===``?null:{isDirectory:t,path:n}}function Rc(e){let t=e.endsWith(`/`)?e.slice(0,-1):e;if(t.length===0)return[];let n=t.split(`/`);return n.slice(0,-1).map((e,t)=>`${n.slice(0,t+1).join(`/`)}/`)}function zc(e,t){return t?`${e}/`:e}function Bc(e,t=null){let n=Ic(e==null?void 0:[...e]);if(n===`0`)return null;if(t?.signature===n)return t;let r=new Map,i=new Set,a=new Set;for(let t of e??[]){let e=Lc(t.path);if(e==null)continue;let n=zc(e.path,e.isDirectory);r.set(n,t.status),t.status===`ignored`&&e.isDirectory?a.add(n):e.isDirectory&&a.delete(n);for(let t of Rc(e.path))i.add(t)}return{directoriesWithChanges:i,ignoredDirectoryPaths:a,signature:n,statusByPath:r}}var Vc,Hc,Uc,Wc,Gc,Kc,qc,Jc,Yc,Xc,Zc={},Qc=[],$c=Array.isArray,el=Qc.slice,tl=Object.assign;function nl(e){e&&e.parentNode&&e.remove()}function rl(e,t,n){var r,i,a,o={};for(a in t)a==`key`?r=t[a]:a==`ref`&&typeof e!=`function`?i=t[a]:o[a]=t[a];return arguments.length>2&&(o.children=arguments.length>3?el.call(arguments,2):n),il(e,o,r,i,null)}function il(e,t,n,r,i){var a={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:i??++Hc,__i:-1,__u:0};return i==null&&Vc.vnode!=null&&Vc.vnode(a),a}function al(e){return e.children}function ol(e,t){this.props=e,this.context=t,this.__g=0}function sl(e,t){if(t==null)return e.__?sl(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type==`function`?sl(e):null}function cl(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=n.__e;break}return cl(e)}}function ll(e){(8&e.__g||!(e.__g|=8)||!Uc.push(e)||Gc++)&&Wc==Vc.debounceRendering||((Wc=Vc.debounceRendering)||queueMicrotask)(ul)}function ul(){for(var e,t,n,r,i,a,o,s,c=1;Uc.length;)Uc.length>c&&Uc.sort(Kc),e=Uc.shift(),c=Uc.length,8&e.__g&&(n=void 0,i=(r=(t=e).__v).__e,a=[],o=[],(s=t.__P)&&((n=tl({},r)).__v=r.__v+1,Vc.vnode&&Vc.vnode(n),vl(s,n,r,t.__n,s.namespaceURI,32&r.__u?[i]:null,a,i??sl(r),!!(32&r.__u),o,s.ownerDocument),n.__v=r.__v,n.__.__k[n.__i]=n,bl(a,n,o),n.__e!=i&&cl(n)));Gc=0}function dl(e,t,n,r,i,a,o,s,c,l,u,d){var f,p,m,h,g,_,v,y=r&&r.__k||Qc,b=t.length;for(c=fl(n,t,y,c,b),f=0;f<b;f++)(m=n.__k[f])!=null&&(p=m.__i==-1?Zc:y[m.__i]||Zc,m.__i=f,_=vl(e,m,p,i,a,o,s,c,l,u,d),h=m.__e,m.ref&&p.ref!=m.ref&&(p.ref&&Cl(p.ref,null,m),u.push(m.ref,m.__c||h,m)),g==null&&h!=null&&(g=h),(v=!!(4&m.__u))||p.__k===m.__k?c=pl(m,c,e,v):typeof m.type==`function`&&_!==void 0?c=_:h&&(c=h.nextSibling),m.__u&=-7);return n.__e=g,c}function fl(e,t,n,r,i){var a,o,s,c,l,u=n.length,d=u,f=0;for(e.__k=Array(i),a=0;a<i;a++)(o=t[a])!=null&&typeof o!=`boolean`&&typeof o!=`function`?(c=a+f,(o=e.__k[a]=typeof o==`string`||typeof o==`number`||typeof o==`bigint`||o.constructor==String?il(null,o,null,null,null):$c(o)?il(al,{children:o},null,null,null):o.constructor==null&&o.__b>0?il(o.type,o.props,o.key,o.ref?o.ref:null,o.__v):o).__=e,o.__b=e.__b+1,s=null,(l=o.__i=ml(o,n,c,d))!=-1&&(d--,(s=n[l])&&(s.__u|=2)),s==null||s.__v==null?(l==-1&&(i>u?f--:i<u&&f++),typeof o.type!=`function`&&(o.__u|=4)):l!=c&&(l==c-1?f--:l==c+1?f++:(l>c?f--:f++,o.__u|=4))):e.__k[a]=null;if(d)for(a=0;a<u;a++)(s=n[a])!=null&&!(2&s.__u)&&(s.__e==r&&(r=sl(s)),wl(s,s));return r}function pl(e,t,n,r){var i,a;if(typeof e.type==`function`){for(i=e.__k,a=0;i&&a<i.length;a++)i[a]&&(i[a].__=e,t=pl(i[a],t,n,r));return t}e.__e!=t&&(r&&(t&&e.type&&!t.parentNode&&(t=sl(e)),n.insertBefore(e.__e,t||null)),t=e.__e);do t&&=t.nextSibling;while(t!=null&&t.nodeType==8);return t}function ml(e,t,n,r){var i,a,o,s=e.key,c=e.type,l=t[n],u=l!=null&&(2&l.__u)==0;if(l===null&&e.key==null||u&&s==l.key&&c==l.type)return n;if(r>+!!u){for(i=n-1,a=n+1;i>=0||a<t.length;)if((l=t[o=i>=0?i--:a++])!=null&&!(2&l.__u)&&s==l.key&&c==l.type)return o}return-1}function hl(e,t,n){t[0]==`-`?e.setProperty(t,n??``):e[t]=n??``}function gl(e,t,n,r,i){var a;n:if(t==`style`)if(typeof n==`string`)e.style.cssText=n;else{if(typeof r==`string`&&(e.style.cssText=r=``),r)for(t in r)n&&t in n||hl(e.style,t,``);if(n)for(t in n)r&&n[t]==r[t]||hl(e.style,t,n[t])}else if(t[0]==`o`&&t[1]==`n`)a=t!=(t=t.replace(qc,`$1`)),(t=t.slice(2))[0].toLowerCase()!=t[0]&&(t=t.toLowerCase()),e.__l||={},e.__l[t+a]=n,n?r?n.l=r.l:(n.l=Jc,e.addEventListener(t,a?Xc:Yc,a)):e.removeEventListener(t,a?Xc:Yc,a);else{if(i==`http://www.w3.org/2000/svg`)t=t.replace(/xlink(H|:h)/,`h`).replace(/sName$/,`s`);else if(t!=`width`&&t!=`height`&&t!=`href`&&t!=`list`&&t!=`form`&&t!=`tabIndex`&&t!=`download`&&t!=`rowSpan`&&t!=`colSpan`&&t!=`role`&&t!=`popover`&&t in e)try{e[t]=n??``;break n}catch{}typeof n==`function`||(n==null||!1===n&&t[4]!=`-`?e.removeAttribute(t):e.setAttribute(t,t==`popover`&&n==1?``:n))}}function _l(e){return function(t){if(this.__l){var n=this.__l[t.type+e];if(t.u==null)t.u=Jc++;else if(t.u<n.l)return;return n(Vc.event?Vc.event(t):t)}}}function vl(e,t,n,r,i,a,o,s,c,l,u){var d,f,p,m,h,g,_,v,y,b,x,S,C,w,T,E,D,O,k,A,j,M=t.type;if(t.constructor!=null)return null;128&n.__u&&(c=!!(32&n.__u),n.__c.__z&&(s=t.__e=n.__e=(a=n.__c.__z)[0],n.__c.__z=null)),(d=Vc.__b)&&d(t);n:if(typeof M==`function`)try{if(v=t.props,y=`prototype`in M&&M.prototype.render,b=(d=M.contextType)&&r[d.__c],x=d?b?b.props.value:d.__:r,n.__c?2&(f=t.__c=n.__c).__g&&(f.__g|=1,_=!0):(y?t.__c=f=new M(v,x):(t.__c=f=new ol(v,x),f.constructor=M,f.render=Tl),b&&b.sub(f),f.props=v,f.state||={},f.context=x,f.__n=r,p=!0,f.__g|=8,f.__h=[],f._sb=[]),y&&f.__s==null&&(f.__s=f.state),y&&M.getDerivedStateFromProps!=null&&(f.__s==f.state&&(f.__s=tl({},f.__s)),tl(f.__s,M.getDerivedStateFromProps(v,f.__s))),m=f.props,h=f.state,f.__v=t,p)y&&M.getDerivedStateFromProps==null&&f.componentWillMount!=null&&f.componentWillMount(),y&&f.componentDidMount!=null&&f.__h.push(f.componentDidMount);else{if(y&&M.getDerivedStateFromProps==null&&v!==m&&f.componentWillReceiveProps!=null&&f.componentWillReceiveProps(v,x),!(4&f.__g)&&f.shouldComponentUpdate!=null&&!1===f.shouldComponentUpdate(v,f.__s,x)||t.__v==n.__v){for(t.__v!=n.__v&&(f.props=v,f.state=f.__s,f.__g&=-9),t.__e=n.__e,t.__k=n.__k,t.__k.some(function(e){e&&(e.__=t)}),S=0;S<f._sb.length;S++)f.__h.push(f._sb[S]);f._sb=[],f.__h.length&&o.push(f);break n}f.componentWillUpdate!=null&&f.componentWillUpdate(v,f.__s,x),y&&f.componentDidUpdate!=null&&f.__h.push(function(){f.componentDidUpdate(m,h,g)})}if(f.context=x,f.props=v,f.__P=e,f.__g&=-5,C=Vc.__r,w=0,y){for(f.state=f.__s,f.__g&=-9,C&&C(t),d=f.render(f.props,f.state,f.context),T=0;T<f._sb.length;T++)f.__h.push(f._sb[T]);f._sb=[]}else do f.__g&=-9,C&&C(t),d=f.render(f.props,f.state,f.context),f.state=f.__s;while(8&f.__g&&++w<25);f.state=f.__s,f.getChildContext!=null&&(r=tl({},r,f.getChildContext())),y&&!p&&f.getSnapshotBeforeUpdate!=null&&(g=f.getSnapshotBeforeUpdate(m,h)),E=d,d!=null&&d.type===al&&d.key==null&&(E=xl(d.props.children)),s=dl(e,$c(E)?E:[E],t,n,r,i,a,o,s,c,l,u),t.__u&=-161,f.__h.length&&o.push(f),_&&(f.__g&=-4)}catch(e){if(t.__v=null,c||a!=null)if(e.then){for(D=0,O=!1,t.__u|=c?160:128,t.__c.__z=[],k=0;k<a.length;k++)(A=a[k])==null||O||(A.nodeType==8&&A.data==`$s`?(D>0&&t.__c.__z.push(A),D++,a[k]=null):A.nodeType==8&&A.data==`/$s`?(--D>0&&t.__c.__z.push(A),O=D===0,s=a[k],a[k]=null):D>0&&(t.__c.__z.push(A),a[k]=null));if(!O){for(;s&&s.nodeType==8&&s.nextSibling;)s=s.nextSibling;a[a.indexOf(s)]=null,t.__c.__z=[s]}t.__e=s}else{for(j=a.length;j--;)nl(a[j]);yl(t)}else t.__e=n.__e,t.__k=n.__k,e.then||yl(t);Vc.__e(e,t,n)}else s=t.__e=Sl(n.__e,t,n,r,i,a,o,c,l,u);return(d=Vc.diffed)&&d(t),128&t.__u?void 0:s}function yl(e){e&&e.__c&&(e.__c.__g|=4),e&&e.__k&&e.__k.forEach(yl)}function bl(e,t,n){for(var r=0;r<n.length;r++)Cl(n[r],n[++r],n[++r]);Vc.__c&&Vc.__c(t,e),e.some(function(t){try{e=t.__h,t.__h=[],e.some(function(e){e.call(t)})}catch(e){Vc.__e(e,t.__v)}})}function xl(e){return typeof e!=`object`||!e||e.__b&&e.__b>0?e:$c(e)?e.map(xl):tl({},e)}function Sl(e,t,n,r,i,a,o,s,c,l){var u,d,f,p,m,h,g,_,v=n.props,y=t.props,b=t.type;if(b==`svg`?i=`http://www.w3.org/2000/svg`:b==`math`?i=`http://www.w3.org/1998/Math/MathML`:i||=`http://www.w3.org/1999/xhtml`,a!=null){for(u=0;u<a.length;u++)if((m=a[u])&&`setAttribute`in m==!!b&&(b?m.localName==b:m.nodeType==3)){e=m,a[u]=null;break}}if(e==null){if(b==null)return l.createTextNode(y);e=l.createElementNS(i,b,y.is&&y),s&&=(Vc.__m&&Vc.__m(t,a),!1),a=null}if(b==null)v===y||s&&e.data==y||(e.data=y);else{if(a&&=el.call(e.childNodes),v=n.props||Zc,!s&&a!=null)for(v={},u=0;u<e.attributes.length;u++)v[(m=e.attributes[u]).name]=m.value;for(u in v)if(m=v[u],u!=`children`){if(u==`dangerouslySetInnerHTML`)f=m;else if(!(u in y)){if(u==`value`&&`defaultValue`in y||u==`checked`&&`defaultChecked`in y)continue;gl(e,u,null,m,i)}}for(u in _=1&n.__u,y)m=y[u],u==`children`?p=m:u==`dangerouslySetInnerHTML`?d=m:u==`value`?h=m:u==`checked`?g=m:s&&typeof m!=`function`||v[u]===m&&!_||gl(e,u,m,v[u],i);if(d)s||f&&(d.__html==f.__html||d.__html==e.innerHTML)||(e.innerHTML=d.__html),t.__k=[];else if(f&&(e.innerHTML=``),dl(b==`template`?e.content:e,$c(p)?p:[p],t,n,r,b==`foreignObject`?`http://www.w3.org/1999/xhtml`:i,a,o,a?a[0]:n.__k&&sl(n,0),s,c,l),a!=null)for(u=a.length;u--;)nl(a[u]);s||(u=`value`,b==`progress`&&h==null?e.removeAttribute(`value`):h==null||h===e[u]&&(b!==`progress`||h)||gl(e,u,h,v[u],i),u=`checked`,g!=null&&g!=e[u]&&gl(e,u,g,v[u],i))}return e}function Cl(e,t,n){try{if(typeof e==`function`){var r=typeof e.__u==`function`;r&&e.__u(),r&&t==null||(e.__u=e(t))}else e.current=t}catch(e){Vc.__e(e,n)}}function wl(e,t,n){var r,i;if(Vc.unmount&&Vc.unmount(e),(r=e.ref)&&(r.current&&r.current!=e.__e||Cl(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(e){Vc.__e(e,t)}r.__P=null}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&wl(r[i],t,n||typeof e.type!=`function`);n||nl(e.__e),e.__e&&e.__e.__l&&(e.__e.__l=null),e.__e=e.__c=e.__=null}function Tl(e,t,n){return this.constructor(e,n)}function El(e,t){var n,r,i,a;t==document&&(t=document.documentElement),Vc.__&&Vc.__(e,t),r=(n=!!(e&&32&e.__u))?null:t.__k,e=t.__k=rl(al,null,[e]),i=[],a=[],vl(t,e,r||Zc,Zc,t.namespaceURI,r?null:t.firstChild?el.call(t.childNodes):null,i,r?r.__e:t.firstChild,n,a,t.ownerDocument),bl(i,e,a)}function Dl(e,t){e.__u|=32,El(e,t)}Vc={__e:function(e,t,n,r){for(var i,a,o;t=t.__;)if((i=t.__c)&&!(1&i.__g)){i.__g|=4;try{if((a=i.constructor)&&a.getDerivedStateFromError!=null&&(i.setState(a.getDerivedStateFromError(e)),o=8&i.__g),i.componentDidCatch!=null&&(i.componentDidCatch(e,r||{}),o=8&i.__g),o)return void(i.__g|=2)}catch(t){e=t}}throw Gc=0,e}},Hc=0,ol.prototype.setState=function(e,t){var n=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=tl({},this.state);typeof e==`function`&&(e=e(tl({},n),this.props)),e&&tl(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),ll(this))},ol.prototype.forceUpdate=function(e){this.__v&&(this.__g|=4,e&&this.__h.push(e),ll(this))},ol.prototype.render=al,Uc=[],Gc=0,Kc=function(e,t){return e.__v.__b-t.__v.__b},qc=/(PointerCapture)$|Capture$/i,Jc=0,Yc=_l(!1),Xc=_l(!0);var Ol=0;Array.isArray;function $(e,t,n,r,i,a){t||={};var o,s,c=t;if(`ref`in c&&typeof e!=`function`)for(s in c={},t)s==`ref`?o=t[s]:c[s]=t[s];var l={type:e,props:c,key:n,ref:o,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--Ol,__i:-1,__u:0,__source:i,__self:a};return Vc.vnode&&Vc.vnode(l),l}var kl=16,Al=16,jl={};function Ml({name:e,remappedFrom:t,token:n,width:r,height:i,viewBox:a,label:o,alignCapitals:s=!1}){"use no memo";let c=`#${e.replace(/^#/,``)}`,{width:l,height:u,viewBox:d}=jl[e]??{width:kl,height:Al},f=r??l,p=i??u,m=a??d??`0 0 ${l} ${u}`;return $(`svg`,{"data-icon-name":t??e,"data-icon-token":n,"data-align-capitals":s,...o==null?{"aria-hidden":!0}:{"aria-label":o,role:`img`},viewBox:m,width:f,height:p,children:$(`use`,{href:c})})}var Nl=e=>{if(e.length<2)return[e,``];let t=Math.ceil(e.length/2);return[e.slice(0,t),e.slice(t)]},Pl=e=>{if(e.length<4)return[e,``];let t=e.lastIndexOf(`.`)+1,n=e.length-t>10,r=t>=1&&!n?t:Math.ceil(e.length/2);return[e.slice(0,r),e.slice(r)]},Fl=e=>{if(e.length<4)return[e,``];let t=e.lastIndexOf(`/`)+1,n=e.length-t>25,r=t>=1&&!n?t:Math.ceil(e.length/2);return[e.slice(0,r),e.slice(r)]},Il=(e,{splitIndex:t}={})=>{if(typeof t!=`number`){let t=Math.ceil(e.length/2);return[e.slice(0,t),e.slice(t)]}return[e.slice(0,t),e.slice(t)]},Ll=(e,{splitOffset:t}={})=>{if(typeof t!=`number`||t<=0||t>=e.length){let t=Math.ceil(e.length/2);return[e.slice(0,t),e.slice(t)]}let n=e.length-t;return[e.slice(0,n),e.slice(n)]},Rl=(e,{splitOffset:t}={})=>{if(typeof t!=`number`||t<=0||t>=e.length){let t=Math.ceil(e.length/2);return[e.slice(0,t),e.slice(t)]}let n=t;return[e.slice(0,n),e.slice(n)]};function zl({children:e,marker:t,variant:n=`default`}){"use no memo";return $(`div`,{"aria-hidden":!0,"data-truncate-marker-cell":!0,children:$(`div`,{"data-truncate-marker":!0,children:typeof t==`function`?t({children:e}):n===`fade`?$(`span`,{"data-truncate-fade":!0}):t})})}function Bl(e){"use no memo";let{mode:t,children:n}=e;return $(`div`,{children:[$(`div`,{"data-truncate-content":`visible`,children:t===`fruncate`?$(`span`,{children:n}):n}),$(`div`,{"data-truncate-content":`overflow`,"aria-hidden":!0,children:t===`fruncate`?$(`span`,{children:n}):n})]})}function Vl({children:e,mode:t=`truncate`,marker:n=`…`,variant:r=`default`,...i}){"use no memo";let a=$(Bl,{mode:t,children:e},`content`),o=$(zl,{marker:n,mode:t,variant:r},`marker`),s=$(`div`,{"data-truncate-fill":!0},`fill`);return $(`div`,{"data-truncate-container":t,"data-truncate-variant":r,...i,children:$(`div`,{"data-truncate-grid":!0,children:t===`truncate`?[a,o]:[o,a,s]})})}function Hl({children:e,...t}){"use no memo";return $(Vl,{mode:`truncate`,...t,children:e})}function Ul({children:e,...t}){"use no memo";return $(Vl,{mode:`fruncate`,...t,children:e})}function Wl({children:e,contents:t,priority:n=`end`,split:r=`center`,minimumLength:i=12,className:a,style:o,...s}){"use no memo";let c=null,l=null;if(Array.isArray(t)){if(t.length!==2)return console.error(`MiddleTruncate: contents must be an array of two items`),null;c=$(Hl,{...s,children:t[0]}),l=$(Ul,{...s,children:t[1]})}else{if(typeof e!=`string`)return console.error(`MiddleTruncate: children must be a string`),null;if(e.length===0)return $(`div`,{className:a,style:o});if(e.length<i)return $(n===`end`?Ul:Hl,{...s,className:a,style:o,children:e});let t=null,u=null,d=null;if(typeof r==`string`)r===`center`?t=Nl:r===`extension`?t=Pl:r===`leaf-path`&&(t=Fl);else if(typeof r==`number`)t=Il,u=r;else if(Array.isArray(r)){let[e,n]=r;d=n,e===`last`?t=Ll:e===`first`&&(t=Rl)}else typeof r==`function`&&(t=r);t??=Nl;let[f,p]=t(e,{priority:n,variant:s.variant,splitIndex:typeof u==`number`?u:void 0,splitOffset:typeof d==`number`?d:void 0}),m=f.length>=p.length,h=n===`equal`&&!m,g=n===`equal`&&m,_={},v={};h&&(_.marker=``),g&&(v.marker=``),c=$(Hl,{...s,..._,children:f}),l=$(Ul,{...s,...v,children:p})}return $(`div`,{"data-truncate-group-container":`middle`,className:a,style:o,children:[$(`div`,{"data-truncate-segment-priority":n===`start`||n===`equal`?`1`:`2`,children:c}),$(`div`,{"data-truncate-segment-priority":n===`end`||n===`equal`?`1`:`2`,children:l})]})}var Gl={endIndex:-1,startIndex:-1};function Kl(e,t,n){return Math.min(Math.max(e,t),n)}function ql(e,t){return e<0||t<e?Gl:{endIndex:t,startIndex:e}}function Jl(e){return e.startIndex<0||e.endIndex<e.startIndex}function Yl(e,t){return Jl(e)?0:(e.endIndex-e.startIndex+1)*t}function Xl(e,t,n){if(t<=0)return-1;let r=t*n;return e<=0?0:e>=r?t:Math.floor(e/n)}function Zl(e,t,n){return t<=0||e<=0?-1:e>=t*n?t-1:Math.ceil(e/n)-1}function Ql(e){let t=new Map;return e.forEach((e,n)=>{if(e.kind!==`directory`||!e.isExpanded)return;let r=e.ancestorPaths.length,i=t.get(r);if(i==null){t.set(r,[n]);return}i.push(n)}),t}function $l(e,t){let n=0,r=e.length-1,i=-1;for(;n<=r;){let a=Math.floor((n+r)/2),o=e[a];if(o==null)break;if(o<=t){i=a,n=a+1;continue}r=a-1}return i}function eu(e){let t=new Map,n=[];for(let r=0;r<e.length;r+=1){let i=e[r];if(i==null)continue;let a=i.kind===`directory`&&i.isExpanded?[...i.ancestorPaths,i.path]:i.ancestorPaths,o=0;for(;o<n.length&&o<a.length&&n[o]===a[o];)o+=1;for(let e=n.length-1;e>=o;--e){let i=n[e];i!=null&&t.set(i,r-1)}n.length=o;for(let e=o;e<a.length;e+=1){let t=a[e];t!=null&&n.push(t)}}let r=e.length-1;for(let e of n)t.set(e,r);return t}function tu(e,t,n){if(e.length===0||t<=0)return[];let r=eu(e),i=Ql(e),a=[];for(let r=0;r<e.length;r+=1){let o=i.get(r);if(o==null||o.length===0)break;let s=t+r*n,c=$l(o,Math.min(e.length-1,Math.floor(s/n))),l=null;for(;c>=0;){let t=o[c],n=t==null?null:e[t]??null;if(n!=null&&(r===0||n.ancestorPaths[r-1]===a[r-1]?.path)){l=n;break}--c}if(l==null)break;a.push(l)}return a.map((i,a)=>{let o=a*n,s=(r.get(i.path)??e.length-1)+1;if(s>=e.length)return{row:i,top:o};let c=s*n-t;return{row:i,top:Math.min(o,c-n)}}).filter(e=>e.top+n>0)}function nu(e,t){let n=t.totalRowCount??e.length,r=n*t.itemHeight,i=Math.max(0,t.viewportHeight),a=Math.max(0,Math.floor(t.overscan)),o=Math.max(0,r-i),s=Kl(t.scrollTop,0,o),c=t.stickyRows??tu(e,s,t.itemHeight),l=c.reduce((e,n)=>Math.max(e,n.top+t.itemHeight),0),u=Math.min(r,s+l),d=Math.max(0,i-l),f=Math.max(0,r-u),p=Xl(s,n,t.itemHeight),m=Xl(u,n,t.itemHeight),h=l<=0||p<0||p>=n?-1:p,g=h===-1?-1:Math.min(n-1,m-1),_=h===-1||g<h?0:g-h+1,v=d<=0||m>=n?Gl:ql(m,Zl(u+d,n,t.itemHeight)),y=g+1,b=Jl(v)?Gl:ql(Math.max(y,v.startIndex-a),Math.min(n-1,v.endIndex+a)),x=Yl(b,t.itemHeight);return{occlusion:{firstOccludedIndex:h,lastOccludedIndex:g,occludedCount:_},physical:{itemHeight:t.itemHeight,maxScrollTop:o,overscan:a,scrollTop:s,totalHeight:r,totalRowCount:n,viewportHeight:i},projected:{contentHeight:f,paneHeight:d,paneTop:u},sticky:{height:l,rows:c},visible:v,window:{endIndex:b.endIndex,height:x,offsetTop:Jl(b)?0:b.startIndex*t.itemHeight,startIndex:b.startIndex}}}var ru={added:`A`,deleted:`D`,ignored:null,modified:`M`,renamed:`R`,untracked:`U`},iu={added:`Git status: added`,deleted:`Git status: deleted`,ignored:`Git status: ignored`,modified:`Git status: modified`,renamed:`Git status: renamed`,untracked:`Git status: untracked`},au=`Contains git status items`;function ou(e){let{renamingPath:t,previousRenamingPath:n,hasRenderedInput:r}=e;return t==null?`reset`:r?n===t?`ignore`:`focus-input`:`reveal-canonical`}function su(e){let{row:t,mode:n,targetPath:r,ariaLabel:i,domId:a,isParked:o,itemHeight:s,features:c,state:l,extraStyle:u}=e,d=n===`sticky`,f=t.ancestorPaths.at(-1)??``,p={};return l.isFocusRinged&&(p[`data-item-focused`]=!0),t.isSelected&&(p[`data-item-selected`]=!0),l.isContextHovered&&(p[`data-item-context-hover`]=`true`),l.isDragTarget&&(p[`data-item-drag-target`]=!0),l.isDragging&&(p[`data-item-dragging`]=!0),l.effectiveGitStatus!=null&&(p[`data-item-git-status`]=l.effectiveGitStatus),l.containsGitChange&&(p[`data-item-contains-git-change`]=`true`),{"aria-expanded":!d&&t.kind===`directory`?t.isExpanded:void 0,"aria-haspopup":c.contextMenuEnabled?`menu`:void 0,"aria-label":i,"aria-level":d?void 0:t.level+1,"aria-posinset":d?void 0:t.posInSet+1,"aria-selected":d?void 0:t.isSelected?`true`:`false`,"aria-setsize":d?void 0:t.setSize,"data-file-tree-sticky-path":d?r:void 0,"data-file-tree-sticky-row":d?`true`:void 0,"data-item-context-menu-button-visibility":c.actionLaneEnabled?c.contextMenuButtonVisibility:void 0,"data-item-context-menu-trigger-mode":c.contextMenuEnabled?c.contextMenuTriggerMode:void 0,"data-item-has-context-menu-action-lane":c.actionLaneEnabled?`true`:void 0,"data-item-has-git-lane":c.gitLaneActive?`true`:void 0,"data-item-parent-path":f.length>0?f:void 0,"data-item-parked":o?`true`:void 0,"data-item-path":r,"data-item-type":t.kind===`directory`?`folder`:`file`,"data-type":`item`,id:d?void 0:a,role:d?void 0:`treeitem`,style:{minHeight:`${s}px`,...u},tabIndex:!d&&t.isFocused?0:-1,...p}}function cu(e){let{event:t,mode:n,isSearchOpen:r,isDirectory:i}=e,a=t.ctrlKey||t.metaKey,o=t.shiftKey||a,s=t.shiftKey?{additive:a,kind:`range`}:a?{kind:`toggle`}:{kind:`single`};return{closeSearch:r,revealCanonical:n===`sticky`,selection:s,toggleDirectory:!o&&i}}function lu(e){let{currentScrollTop:t,focusedIndex:n,itemHeight:r,topInset:i=0,viewportHeight:a}=e;if(n<0)return null;let o=Math.max(0,i),s=n*r,c=s+r;if(s<t+o){let e=Math.max(0,s-o);return e===t?null:e}if(c>t+a){let e=c-a;return e===t?null:e}return null}function uu(e){let{currentScrollTop:t,focusedIndex:n,itemHeight:r,targetViewportOffset:i,totalHeight:a,viewportHeight:o}=e;if(n<0)return null;let s=Math.max(0,i),c=n*r,l=c+r,u=t+s,d=t+o;if(c>=u&&l<=d)return null;let f=Math.max(0,a-o),p=Math.max(0,Math.min(c-s,f));return p===t?null:p}var du,fu,pu,mu,hu=Object.is,gu=0,_u=[],vu=Vc,yu=vu.__b,bu=vu.__r,xu=vu.diffed,Su=vu.__c,Cu=vu.unmount,wu=vu.__;function Tu(e,t){vu.__h&&vu.__h(fu,e,gu||t),gu=0;var n=fu.__H||={__:[],__h:[]};return e>=n.__.length&&n.__.push({}),n.__[e]}function Eu(e){return gu=1,Du(zu,e)}function Du(e,t,n){var r=Tu(du++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):zu(void 0,t),function(e){var t=r.__N?r.__N[0]:r.__[0],n=r.t(t,e);hu(t,n)||(r.__N=[n,r.__[1]],r.__c.setState({}))}],r.__c=fu,!fu.__f)){var i=function(e,t,n){if(!r.__c.__H)return!0;var i=r.__c.__H.__.filter(function(e){return!!e.__c});if(i.every(function(e){return!e.__N}))return!a||a.call(this,e,t,n);var o=r.__c.props!==e;return i.forEach(function(e){if(e.__N){var t=e.__[0];e.__=e.__N,e.__N=void 0,hu(t,e.__[0])||(o=!0)}}),a&&a.call(this,e,t,n)||o};fu.__f=!0;var a=fu.shouldComponentUpdate,o=fu.componentWillUpdate;fu.componentWillUpdate=function(e,t,n){if(4&this.__g){var r=a;a=void 0,i(e,t,n),a=r}o&&o.call(this,e,t,n)},fu.shouldComponentUpdate=i}return r.__N||r.__}function Ou(e,t){var n=Tu(du++,3);!vu.__s&&Ru(n.__H,t)&&(n.__=e,n.u=t,fu.__H.__h.push(n))}function ku(e,t){var n=Tu(du++,4);!vu.__s&&Ru(n.__H,t)&&(n.__=e,n.u=t,fu.__h.push(n))}function Au(e){return gu=5,ju(function(){return{current:e}},[])}function ju(e,t){var n=Tu(du++,7);return Ru(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function Mu(e,t){return gu=8,ju(function(){return e},t)}function Nu(){for(var e;e=_u.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(Iu),e.__H.__h.forEach(Lu),e.__H.__h=[]}catch(t){e.__H.__h=[],vu.__e(t,e.__v)}}vu.__b=function(e){fu=null,yu&&yu(e)},vu.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),wu&&wu(e,t)},vu.__r=function(e){bu&&bu(e),du=0;var t=(fu=e.__c).__H;t&&(pu===fu?(t.__h=[],fu.__h=[],t.__.forEach(function(e){e.__N&&(e.__=e.__N),e.u=e.__N=void 0})):(t.__h.forEach(Iu),t.__h.forEach(Lu),t.__h=[],du=0)),pu=fu},vu.diffed=function(e){xu&&xu(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(_u.push(t)!==1&&mu===vu.requestAnimationFrame||((mu=vu.requestAnimationFrame)||Fu)(Nu)),t.__H.__.forEach(function(e){e.u&&(e.__H=e.u),e.u=void 0})),pu=fu=null},vu.__c=function(e,t){t.some(function(e){try{e.__h.forEach(Iu),e.__h=e.__h.filter(function(e){return!e.__||Lu(e)})}catch(n){t.some(function(e){e.__h&&=[]}),t=[],vu.__e(n,e.__v)}}),Su&&Su(e,t)},vu.unmount=function(e){Cu&&Cu(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(e){try{Iu(e)}catch(e){t=e}}),n.__H=void 0,t&&vu.__e(t,n.__v))};var Pu=typeof requestAnimationFrame==`function`;function Fu(e){var t,n=function(){clearTimeout(r),Pu&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,35);Pu&&(t=requestAnimationFrame(n))}function Iu(e){var t=fu,n=e.__c;typeof n==`function`&&(e.__c=void 0,n()),fu=t}function Lu(e){var t=fu;e.__c=e.__(),fu=t}function Ru(e,t){return!e||e.length!==t.length||t.some(function(t,n){return!hu(t,e[n])})}function zu(e,t){return typeof t==`function`?t(e):t}function Bu(e){if(e==null||!e.isConnected||e===document.body||e===document.documentElement)return!1;e.focus({preventScroll:!0});let t=e.getRootNode();return t instanceof ShadowRoot?t.activeElement===e:document.activeElement===e}function Vu(e){let t=e.getRootNode();if(t instanceof ShadowRoot){let e=t.activeElement;return e instanceof HTMLElement?e:null}let n=document.activeElement;return n instanceof HTMLElement&&e.contains(n)?n:null}function Hu({ariaLabel:e,isFlattened:t=!1,ref:n,value:r,onBlur:i,onInput:a}){return $(`input`,{ref:n,"data-item-rename-input":!0,...t?{"data-item-flattened-rename-input":!0}:{},"aria-label":e,value:r,onBlur:i,onInput:a,onClick:e=>e.stopPropagation(),onMouseDown:e=>e.stopPropagation(),onPointerDown:e=>e.stopPropagation()})}function Uu(e,t=null,n=null){"use no memo";let r=e.flattenedSegments;return r==null||r.length===0?t??e.name:$(`span`,{"data-item-flattened-subitems":!0,children:r.map((e,i)=>{let a=i===r.length-1;return $(al,{children:[$(`span`,{"data-item-flattened-subitem":e.path,"data-item-flattened-subitem-drag-target":n===e.path?`true`:void 0,children:a&&t!=null?t:$(Hl,{children:e.name})}),i<r.length-1?` / `:``]},e.path)})})}function Wu(e){return e.isFlattened?e.flattenedSegments?.findLast(e=>e.isTerminal)?.path??e.path:e.path}function Gu(e){let t=e.flattenedSegments;return t==null||t.length===0?e.name:t.map(e=>e.name).join(` / `)}function Ku(e,t,n,r){return e.map((e,i)=>{let a=i*n,o=e.subtreeEndIndex+1;if(o>=r)return{row:e.row,top:a};let s=o*n-t;return{row:e.row,top:Math.min(a,s-n)}}).filter(e=>e.top+n>0)}function qu({controller:e,itemHeight:t,overscan:n,scrollTop:r,stickyFolders:i,viewportHeight:a}){let o=e.getVisibleCount(),s=i&&o>0?e.getStickyRowCandidates(r,t):[],c=s==null&&i&&o>0?e.getVisibleRows(0,o-1):[],l=nu(c,{itemHeight:t,overscan:n,scrollTop:r,stickyRows:s==null?void 0:Ku(s,r,t,o),totalRowCount:o,viewportHeight:a}),u=i&&r<=0&&o>0?e.getStickyRowCandidates(1,t):[],d=u!=null&&r<=0?Ku(u,1,t,o):i&&r<=0&&c.length>0?tu(c,1,t):l.sticky.rows;return{overlayHeight:d.reduce((e,n)=>Math.max(e,n.top+t),0),overlayRows:d,snapshot:l,visibleRows:c}}var Ju=400,Yu=10,Xu=40,Zu=18;function Qu(e,t,n){let r=e,i=document.elementFromPoint?.bind(document)??null,a=r.elementFromPoint?.(t,n)??i?.(t,n)??null;return e instanceof ShadowRoot&&(a==null||!e.contains(a))?$u(e,t,n):a instanceof HTMLElement?a:null}function $u(e,t,n){let r=Array.from(e.querySelectorAll(`[data-type="item"], [data-item-flattened-subitem]`));for(let e=r.length-1;e>=0;e--){let i=r[e],a=i.getBoundingClientRect();if(t>=a.left&&t<=a.right&&n>=a.top&&n<=a.bottom)return i}return null}function ed(e){let t=e?.closest?.(`[data-type="item"]`);if(!(t instanceof HTMLElement))return null;let n=t.dataset.itemPath??null;if(n==null)return null;let r=e?.closest?.(`[data-item-flattened-subitem]`),i=r instanceof HTMLElement?r.getAttribute(`data-item-flattened-subitem`)??null:null;if(i!=null&&i.endsWith(`/`))return{directoryPath:i,flattenedSegmentPath:i,hoveredPath:n,kind:`directory`};if(t.dataset.itemType===`folder`)return{directoryPath:n,flattenedSegmentPath:null,hoveredPath:n,kind:`directory`};let a=t.dataset.itemParentPath??null;return a==null||a.length===0?{directoryPath:null,flattenedSegmentPath:null,hoveredPath:n,kind:`root`}:{directoryPath:a,flattenedSegmentPath:null,hoveredPath:n,kind:`directory`}}function td(e){let t=e.cloneNode(!0);return t.removeAttribute(`id`),t.dataset.fileTreeDragPreview=`true`,t.setAttribute(`aria-hidden`,`true`),t.tabIndex=-1,Object.assign(t.style,{boxShadow:`0 4px 12px rgba(0, 0, 0, 0.15)`,left:`0px`,margin:`0`,pointerEvents:`none`,position:`fixed`,top:`0px`,willChange:`transform`,zIndex:`10000`}),t}function nd(){return navigator.vendor!==`Apple Computer, Inc.`}function rd(e,t){let n=e-t.top;if(n<Xu)return-Math.ceil((Xu-Math.max(0,n))/Xu*Zu);let r=t.bottom-e;return r<Xu?Math.ceil((Xu-Math.max(0,r))/Xu*Zu):0}function id(e,t){if(e!=null){let t=ru[e];return t==null?null:{text:t,title:iu[e]}}return t?{icon:{name:`file-tree-icon-dot`,width:6,height:6},title:au}:null}function ad(e,t,n){if(t==null||t.size===0)return null;let r=[];for(let i=e.length-1;i>=0;--i){let a=e[i],o=n.get(a);if(o!=null){for(let e of r)n.set(e,o);return o?`ignored`:null}if(t.has(a)){n.set(a,!0);for(let e of r)n.set(e,!0);return`ignored`}r.push(a)}for(let e of r)n.set(e,!1);return null}function od(e){return e!=null&&`toggle`in e}function sd(e){return e.code===`Space`||e.key===` `||e.key===`Spacebar`}function cd(e){return e.key.length===1&&/^[\p{L}\p{N}]$/u.test(e.key)&&!e.ctrlKey&&!e.metaKey&&!e.altKey}function ld(e,t){if(e==null)return t;let n=e.getBoundingClientRect().height;return n>0?n:e.clientHeight>0?e.clientHeight:t}function ud(e,t){return e!=null&&e>0?e:t}function dd(e){let t=e.borderBoxSize,n=Array.isArray(t)?t[0]:t;return n!=null&&Number.isFinite(n.blockSize)&&n.blockSize>0?n.blockSize:e.contentRect.height>0?e.contentRect.height:null}function fd(e,t,n,r,i=0){let a=lu({currentScrollTop:e.scrollTop,focusedIndex:t,itemHeight:n,topInset:i,viewportHeight:r});return a==null?!1:(e.scrollTop=a,!0)}function pd(e,t,n,r,i,a){let o=uu({currentScrollTop:e.scrollTop,focusedIndex:t,itemHeight:n,targetViewportOffset:a,totalHeight:i,viewportHeight:r});return o==null?!1:(e.scrollTop=o,!0)}function md(e,t,n,r){return n.end<n.start?null:e<n.start?-t:e>n.end?r:null}function hd(e){return e==null?``:`[data-item-section="spacing-item"][data-ancestor-path="${e.replaceAll(`\\`,`\\\\`).replaceAll(`"`,`\\"`)}"] { opacity: 1; }`}function gd(e){return e.shiftKey&&e.key===`F10`||e.key===`ContextMenu`}function _d(e,t){return t&&gd(e)||(e.ctrlKey||e.metaKey)&&sd(e)?!0:e.key===`ArrowDown`||e.key===`ArrowLeft`||e.key===`ArrowRight`||e.key===`ArrowUp`}var vd=new Set([`ArrowDown`,`ArrowLeft`,`ArrowRight`,`ArrowUp`,`End`,`Home`,`PageDown`,`PageUp`]);function yd(e){for(let t of e.composedPath())if(t instanceof HTMLElement&&(t.dataset.fileTreeContextMenuRoot===`true`||t.dataset.type===`context-menu-anchor`||t.dataset.type===`context-menu-trigger`||t.getAttribute(`slot`)===`context-menu`))return!0;return!1}function bd(e){return{bottom:e.bottom,height:e.height,left:e.left,right:e.right,top:e.top,width:e.width,x:e.x,y:e.y}}function xd(e,t){return{bottom:t,height:0,left:e,right:e,top:t,width:0,x:e,y:t}}function Sd(e,t){if(e==null)return t.offsetTop;let n=t.getBoundingClientRect(),r=e.getBoundingClientRect();return n.top-r.top}function Cd(e,t,n){if(n==null){e.delete(t);return}e.set(t,n)}function wd(e,t,n){if(e==null)return null;let r=t.get(e)??null;if(r!=null)return r;let i=n.get(e)??null;return i?.dataset.itemParked===`true`?null:i}function Td(e){if(e==null)return[];let t=[];for(let n of e.querySelectorAll(`button[data-file-tree-sticky-row="true"]`)){if(!(n instanceof HTMLElement))continue;let e=n.dataset.fileTreeStickyPath;e!=null&&t.push(e)}return t}function Ed(e,t){if(e==null||t==null)return null;for(let n of e.querySelectorAll(`button[data-item-focused="true"][data-item-parked="true"]`))if(n instanceof HTMLElement&&n.dataset.itemPath===t)return n;return null}function Dd(e,t,n,r,i,a,o){let s=Math.max(0,a-i),c=t?.getBoundingClientRect()??null,l=c==null||n==null?null:n.getBoundingClientRect().top-c.top,u=Ed(e,r),d=c==null||u==null?null:u.getBoundingClientRect().top-c.top;return Math.max(0,Math.min(d??Math.max(l??0,s),Math.max(0,o-i)))}function Od(e,t){return{kind:e.kind,name:Gu(e),path:t}}function kd(e){return e==null?void 0:`${e}__tree`}function Ad(e,t,n){if(e!=null)return`${e}__focused-item-${encodeURIComponent(t)}${n?`__parked`:``}`}function jd(e){return e===`file-tree-icon-chevron`||e===`file-tree-icon-dot`||e===`file-tree-icon-file`||e===`file-tree-icon-lock`}function Md(e,t){if(e==null)return null;if(`text`in e)return $(`span`,{title:e.title,children:e.text});let n=typeof e.icon==`string`?jd(e.icon)?t(e.icon):{name:e.icon}:jd(e.icon.name)?(()=>{let n=t(e.icon.name),{name:r,...i}=e.icon;return{...n,...i}})():e.icon;return $(`span`,{title:e.title,children:$(Ml,{...n})})}function Nd(e){e!=null&&Bu(e.querySelector([`button:not([disabled])`,`[href]`,`input:not([disabled])`,`select:not([disabled])`,`textarea:not([disabled])`,`[tabindex]:not([tabindex="-1"])`].join(`, `))??e)}function Pd(e,t,{actionLaneEnabled:n=!1,customDecoration:r=null,decorationLaneEnabled:i=!1,dragTargetFlattenedSegmentPath:a=null,gitDecoration:o=null,gitLaneActive:s=!1,renameInput:c=null,showDecorativeActionAffordance:l=!1}={}){let u=Wu(e);return $(al,{children:[e.depth>0?$(`div`,{"data-item-section":`spacing`,children:Array.from({length:e.depth}).map((t,n)=>$(`div`,{"data-item-section":`spacing-item`,"data-ancestor-path":e.ancestorPaths[n]},n))}):null,$(`div`,{"data-item-section":`icon`,children:e.kind===`directory`?$(Ml,{...t(`file-tree-icon-chevron`)}):$(Ml,{...t(`file-tree-icon-file`,u)})}),$(`div`,{"data-item-section":`content`,children:e.isFlattened?Uu(e,c,a):c??$(Wl,{minimumLength:5,split:`extension`,children:e.name})}),i?$(`div`,{"data-item-section":`decoration`,children:r==null?null:Md(r,t)}):null,s?$(`div`,{"data-item-section":`git`,children:Md(o,t)}):null,n?$(`div`,{"data-item-section":`action`,children:l?$(`span`,{"aria-hidden":`true`,"data-item-action-affordance":`decorative`,children:$(Ml,{...t(`file-tree-icon-ellipsis`)})}):null}):null]})}function Fd(e,t,n,r={}){let{controller:i,renameView:a,visualFocusPath:o,contextHoverPath:s,draggedPathSet:c,dragTarget:l,dragAndDropEnabled:u,shouldSuppressContextMenu:d,handleRowDragStart:f,handleRowDragEnd:p,handleRowTouchStart:m,instanceId:h,itemHeight:g,gitStatusByPath:_,ignoredGitDirectories:v,ignoredInheritanceCache:y,directoriesWithGitChanges:b,gitLaneActive:x,contextMenuEnabled:S,contextMenuTriggerMode:C,contextMenuButtonTriggerEnabled:w,contextMenuButtonVisibility:T,contextMenuRightClickEnabled:E,registerRenameInput:D,registerButton:O,resolveIcon:k,renderDecorationForRow:A,openContextMenuForRow:j,onRowClick:M,onKeyDown:N}=e,P=Wu(t),{isParked:F=!1,mode:I=`flow`,style:L}=r,R=I===`sticky`,z=_?.get(P)??null??ad(t.ancestorPaths,v,y),B=t.kind===`directory`&&(b?.has(P)??!1),V=A(t,P),ee=id(z,B),H=S&&w,U=V!=null||x||H,te=H&&T===`always`,ne=a.getPath()===P,re=ne?a.getValue():``,W=R||!ne?null:$(Hu,{ref:D,ariaLabel:`Rename ${Gu(t)}`,isFlattened:t.isFlattened,value:re,onBlur:()=>{a.commit()},onInput:e=>{a.setValue(e.currentTarget.value)}}),G=Pd(t,k,{actionLaneEnabled:H,customDecoration:V,decorationLaneEnabled:U,dragTargetFlattenedSegmentPath:l?.flattenedSegmentPath??null,gitDecoration:ee,gitLaneActive:x,renameInput:W,showDecorativeActionAffordance:te}),ie={...su({ariaLabel:Gu(t),domId:t.isFocused?Ad(h,P,F):void 0,extraStyle:L,features:{actionLaneEnabled:H,contextMenuButtonVisibility:H?T:null,contextMenuEnabled:S,contextMenuTriggerMode:S?C:null,gitLaneActive:x},isParked:F,itemHeight:g,mode:I,row:t,state:{containsGitChange:B,effectiveGitStatus:z,isContextHovered:s===P,isDragTarget:l?.kind===`directory`&&l.directoryPath===P,isDragging:c?.has(P)===!0,isFocusRinged:t.isFocused&&o===P},targetPath:P}),key:n,onContextMenu:S||u?e=>{if(d()){e.preventDefault();return}S&&(e.preventDefault(),E&&(i.focusPath(P),j(t,P,{anchorRect:xd(e.clientX,e.clientY),source:`right-click`})))}:void 0,onFocus:R?void 0:()=>{i.focusPath(P)},onKeyDown:R?void 0:N,ref:e=>{O(P,e)}};return!R&&ne?$(`div`,{...ie,children:G}):$(`button`,{...ie,type:`button`,draggable:u&&!F,onDragEnd:u&&!F?p:void 0,onDragStart:u&&!F?e=>{f(e,t,P)}:void 0,onMouseDown:e=>{if(R){e.preventDefault();return}i.isSearchOpen()&&e.preventDefault()},onTouchStart:u&&!F?e=>{m(e,t,P)}:void 0,onClick:e=>{M(e,t,P,I)},children:G})}function Id(e,t,n){return t.end<t.start?[]:e.controller.getVisibleRows(t.start,t.end).filter(e=>!n.has(Wu(e))).map((n,r)=>Fd(e,n,t.start+r))}function Ld({composition:e,controller:t,gitStatusByPath:n,ignoredGitDirectories:r,directoriesWithGitChanges:i,icons:a,instanceId:o,itemHeight:s=zs,overscan:c=10,renamingEnabled:l=!1,renderRowDecoration:u,searchBlurBehavior:d=`close`,searchEnabled:f=!1,searchFakeFocus:p=!1,slotHost:m,stickyFolders:h=!1,initialViewportHeight:g=420}){"use no memo";let _=Au(null),v=Au(null),y=Au(!1),b=Au(null),x=Au(null),S=Au(null),C=Au(null),w=Au(null),T=Au(new Map),E=Au(new Map),D=Au(()=>{}),O=Au(null),k=Au(!1),A=Au(null),j=Au(null),M=Au(!1),N=Au(null),P=Au(null),F=Au(null),I=Au(null),L=Au(null),R=Au(null),z=Au(null),B=Au(null),V=Au(!1),ee=Au(null),H=Au(null),U=Au(null),te=Au(null),ne=ju(()=>new Map,[]),[,re]=Eu(0),[W,G]=Eu(null),[ie,ae]=Eu(null),[oe,se]=Eu(null),[ce,le]=Eu(null),[ue,de]=Eu(0),[K,fe]=Eu(null),pe=Au(K);pe.current=K;let me=Au(null),he=Au(null),ge=Au(null),_e=Au(null),ve=Au(null),ye=Au(!1),be=()=>{he.current=null,ge.current=null,_e.current=null},xe=(e,t)=>{he.current=e,ge.current=null,_e.current=t==null?null:{path:e,scrollTop:t}},Se=(e,t)=>{he.current=null,ge.current={path:e,viewportOffset:t},_e.current=null},Ce=Au(d===`retain`&&t.isSearchOpen()),[we,Te]=Eu(p);Ou(()=>{p||Te(!1)},[p]);let Ee=Au(!1),De=Mu(()=>{Ee.current=!0,Te(e=>e&&!1)},[]),[Oe,ke]=Eu(()=>qu({controller:t,itemHeight:s,overscan:c,scrollTop:0,stickyFolders:h,viewportHeight:g})),[Ae,je]=Eu(!1);Ou(()=>{je(!0)},[]);let Me=e?.contextMenu?.enabled===!0||e?.contextMenu?.render!=null||e?.contextMenu?.onOpen!=null||e?.contextMenu?.onClose!=null,Ne=e?.contextMenu?.triggerMode??(Me?`right-click`:`both`),Pe=Ne===`both`||Ne===`button`,Fe=e?.contextMenu?.buttonVisibility??`when-needed`,Ie=Ne===`both`||Ne===`right-click`;ku(()=>{let e=S.current;if(e==null)return;let t=e=>{if(!(e instanceof CustomEvent))return;let t=e.detail?.path??null;ve.current=t,ae(t),le(t==null?null:`pointer`)},n=e=>{e instanceof CustomEvent&&(ye.current=e.detail?.disabled===!0)};return e.addEventListener(`file-tree-debug-set-context-menu-trigger`,t),e.addEventListener(`file-tree-debug-set-scroll-suppression`,n),()=>{e.removeEventListener(`file-tree-debug-set-context-menu-trigger`,t),e.removeEventListener(`file-tree-debug-set-scroll-suppression`,n)}},[]);let Le=Mu((e,t)=>{Cd(T.current,e,t)},[]),Re=Mu((e,t)=>{Cd(E.current,e,t)},[]),ze=Mu(e=>{x.current=e},[]),Be=Mu(e=>wd(e,E.current,T.current),[]),Ve=n!=null||r!=null||i!=null,{resolveIcon:He}=ju(()=>ii(a),[a]),Ue=t[uc](),We=Ue.getPath(),Ge=We!=null,Ke=t.isSearchOpen(),qe=t.getSearchValue(),Je=t.getFocusedPath(),Ye=t.getFocusedIndex(),Xe=t.isDragAndDropEnabled(),Ze=t.getDragSession(),Qe=ju(()=>Ze==null?null:new Set(Ze.draggedPaths),[Ze]),$e=Ze?.target??null,et=Ze?.primaryPath??null,tt=kd(o),{overlayHeight:nt,overlayRows:rt,snapshot:it,visibleRows:at}=Oe,ot=it.physical.viewportHeight,st=ju(()=>({end:it.window.endIndex,start:it.window.startIndex}),[it.window.endIndex,it.window.startIndex]),ct=rt,lt=it.sticky.rows,ut=it.physical.totalHeight,dt=it.sticky.height,ft=ju(()=>new Set(lt.map(e=>Wu(e.row))),[lt]),pt=Ye>=0&&Ye>=st.start&&Ye<=st.end,mt=Mu((e,t)=>u?.({item:Od(e,t),row:e})??null,[u]),ht=Mu(e=>Bu(e==null?null:T.current.get(e)??null)?!0:Bu(S.current),[]),gt=Mu(e=>{ht(t.focusNearestPath(e))},[t,ht]),_t=Au(gt);_t.current=gt;let vt=Au(!0),yt=Au(()=>{}),bt=Mu((t=!0)=>{let n=pe.current;n!=null&&(vt.current=vt.current&&t,fe(null),e?.contextMenu?.onClose?.(),vt.current&>(n.path))},[e?.contextMenu,gt]);yt.current=bt;let xt=Mu(e=>{let t=e==null?null:Sd(S.current,e);se(e=>e===t?e:t)},[]),St=Mu((e,n,r)=>{let i=t.getItem(n);if(i==null)return;let a=Be(n);if(a?.dataset.fileTreeStickyRow===`true`){let e=C.current;xe(n,e?.scrollTop??null),k.current=!0,G(e=>e===n?e:n)}i.focus(),xt(a),vt.current=!0,fe({anchorRect:r?.anchorRect??null,item:Od(e,n),path:n,source:r?.source??`keyboard`})},[t,Be,xt]),Ct=Mu(e=>{if(l){if(t.isSearchOpen()){let e=C.current,t=ld(e,ot);N.current=Ye<0||e==null?null:Math.max(0,Math.min(Ye*s-e.scrollTop,Math.max(0,t-s))),M.current=!0}t.startRenaming(e)!==!1&&(le(`focus`),re(e=>e+1))}},[t,Ye,s,l,ot]),wt=Mu((e,{restoreTreeFocus:n=!0,targetOffset:r=`live-overlay`}={})=>{let i=C.current;if(i==null)return!1;t.focusPath(e);let a=t.getFocusedIndex();if(a<0)return!1;let o=t.getVisibleRows(a,a)[0]??null;if(o==null)return!1;let l=ld(i,ot),u=t.getVisibleCount()*s,d=r===`sticky-parents`?o.ancestorPaths.length*s:qu({controller:t,itemHeight:s,overscan:c,scrollTop:i.scrollTop,stickyFolders:h,viewportHeight:l}).snapshot.sticky.height;return k.current=!0,pd(i,a,s,l,u,d),D.current(),me.current=n?e:null,!0},[t,s,c,ot,h]),Tt=()=>y.current===!0||te.current!=null||V.current===!0,Et=e=>typeof window.requestAnimationFrame==`function`?window.requestAnimationFrame(()=>{e()}):window.setTimeout(e,16),Dt=e=>{if(e!=null){if(typeof window.cancelAnimationFrame==`function`){window.cancelAnimationFrame(e);return}window.clearTimeout(e)}},Ot=()=>{I.current!=null&&(clearTimeout(I.current),I.current=null),F.current=null},kt=()=>{R.current?.remove(),R.current=null},At=()=>{Dt(P.current),P.current=null,L.current=null},jt=e=>{let t=S.current?.getRootNode();if(t instanceof ShadowRoot){t.append(e);return}document.body.append(e)},Mt=()=>{B.current?.(),B.current=null,te.current!=null&&(clearTimeout(te.current),te.current=null),V.current=!1,ee.current=null,U.current=null,H.current!=null&&(H.current.setAttribute(`draggable`,`true`),H.current.style.removeProperty(`touch-action`),H.current=null),kt(),Ot(),At(),z.current=null},Nt=(e,n)=>{let r=S.current?.getRootNode(),i=ed(Qu(r instanceof ShadowRoot?r:document,e,n));return t.setDragTarget(i),t.getDragSession()?.target??null},Pt=e=>{let n=t.getDragAndDropConfig()?.openOnDropDelay??800;if(e==null||e.kind!==`directory`||e.directoryPath==null||n<=0){Ot();return}let r=t.getItem(e.directoryPath),i=od(r)?r:null;if(i==null||i.isExpanded()){Ot();return}let a=`${e.directoryPath}::${e.flattenedSegmentPath??``}`;F.current!==a&&(Ot(),F.current=a,I.current=setTimeout(()=>{let n=t.getDragSession()?.target;n?.kind!==`directory`||n.directoryPath!==e.directoryPath||n.flattenedSegmentPath!==e.flattenedSegmentPath||i.expand()},n))},Ft=()=>{P.current=null;let e=L.current,n=C.current;if(e==null||n==null||t.getDragSession()==null)return;let r=n.getBoundingClientRect(),i=rd(e.clientY,r);if(i===0)return;let a=Math.max(0,n.scrollHeight-n.clientHeight),o=Math.max(0,Math.min(a,n.scrollTop+i));o!==n.scrollTop&&(n.scrollTop=o,D.current()),Pt(Nt(e.clientX,e.clientY)),P.current=Et(Ft)},It=(e,t)=>{L.current={clientX:e,clientY:t},P.current??=Et(Ft)},Lt=(e,n,r)=>{let i=e.currentTarget;if(i!=null){if(Mt(),kt(),Ot(),At(),t.startDrag(r)===!1){e.preventDefault();return}if(z.current=n,e.dataTransfer!=null&&(e.dataTransfer.effectAllowed=`move`,e.dataTransfer.dropEffect=`move`,e.dataTransfer.setData(`text/plain`,r),nd())){let t=td(i),n=i.getBoundingClientRect();Object.assign(t.style,{height:`${n.height}px`,opacity:`0.85`,transform:`translate3d(-9999px, 0px, 0)`,width:`${n.width}px`}),jt(t),R.current=t,e.dataTransfer.setDragImage(t,Math.max(0,e.clientX-n.left),Math.max(0,e.clientY-n.top))}}},Rt=()=>{kt(),Ot(),At(),z.current=null,t.cancelDrag()},zt=(e,n,r)=>{if(te.current!=null||V.current)return;let i=e.touches[0],a=e.currentTarget;if(i==null||a==null)return;U.current={clientX:i.clientX,clientY:i.clientY},H.current=a,a.setAttribute(`draggable`,`false`);let o=(e={})=>{let t=e.restoreNativeDraggable??!V.current;te.current!=null&&(clearTimeout(te.current),te.current=null),document.removeEventListener(`touchmove`,s),document.removeEventListener(`touchend`,c),document.removeEventListener(`touchcancel`,c),B.current===o&&(B.current=null),t&&(a.setAttribute(`draggable`,`true`),H.current===a&&(H.current=null),U.current=null)},s=e=>{let t=e.touches[0],n=U.current;if(t==null||n==null)return;let r=t.clientX-n.clientX,i=t.clientY-n.clientY;r*r+i*i<=Yu*Yu||o()},c=()=>{o()};document.addEventListener(`touchmove`,s,{passive:!0}),document.addEventListener(`touchend`,c),document.addEventListener(`touchcancel`,c),B.current=o,te.current=setTimeout(()=>{if(o({restoreNativeDraggable:!1}),t.startDrag(r)===!1){a.setAttribute(`draggable`,`true`),H.current===a&&(H.current=null),U.current=null;return}V.current=!0,H.current=a,a.setAttribute(`draggable`,`false`),a.style.setProperty(`touch-action`,`none`),z.current=n;let e=a.getBoundingClientRect(),s=td(a);Object.assign(s.style,{height:`${e.height}px`,opacity:`0.85`,transform:`translate3d(${e.left}px, ${e.top}px, 0)`,width:`${e.width}px`}),jt(s),R.current=s,ee.current={x:i.clientX-e.left,y:i.clientY-e.top};let c=e=>{let t=e.touches[0];if(t==null)return;e.preventDefault();let n=ee.current;n!=null&&R.current!=null&&(R.current.style.transform=`translate3d(${t.clientX-n.x}px, ${t.clientY-n.y}px, 0)`),Pt(Nt(t.clientX,t.clientY)),It(t.clientX,t.clientY)},l=e=>{let n=e.changedTouches[0];n!=null&&Nt(n.clientX,n.clientY),t.completeDrag(),Mt()},u=()=>{t.cancelDrag(),Mt()};B.current=()=>{document.removeEventListener(`touchmove`,c),document.removeEventListener(`touchend`,l),document.removeEventListener(`touchcancel`,u)},document.addEventListener(`touchmove`,c,{passive:!1}),document.addEventListener(`touchend`,l),document.addEventListener(`touchcancel`,u)},Ju)},Bt=e=>{if(K!=null){if(e.key===`Escape`){bt(),e.preventDefault(),e.stopPropagation();return}vd.has(e.key)&&(e.preventDefault(),e.stopPropagation());return}if(Ue.isActive()){if(e.key===`Escape`)Ue.cancel();else if(e.key===`Enter`)Ue.commit();else return;le(`focus`),re(e=>e+1),e.preventDefault(),e.stopPropagation();return}if(l&&e.key===`F2`){Ct(Je??void 0),e.preventDefault(),e.stopPropagation();return}if(Ke){if(e.key===`Escape`)M.current=!1,N.current=null,t.closeSearch();else if(e.key===`Enter`){let e=t.getFocusedPath();e!=null&&t.selectOnlyPath(e);let n=C.current,r=ld(n,ot);N.current=Ye<0||n==null?null:Math.max(0,Math.min(Ye*s-n.scrollTop,Math.max(0,r-s))),M.current=!0,t.closeSearch()}else if(e.key===`ArrowDown`)t.focusNextSearchMatch();else if(e.key===`ArrowUp`)t.focusPreviousSearchMatch();else return;le(`focus`),re(e=>e+1),e.preventDefault(),e.stopPropagation();return}if(f&&cd(e)){t.openSearch(e.key),re(e=>e+1),e.preventDefault(),e.stopPropagation();return}let n=Me&&gd(e),r=_d(e,Me),i=r&&S.current!=null?Vu(S.current):null,a=r?new Set(Td(S.current)):new Set,o=i?.dataset.fileTreeStickyPath??null,c=i?.dataset.fileTreeStickyRow===`true`&&o!=null;if(c&&o!==Je&&a.has(o)){let e=C.current;xe(o,e?.scrollTop??null),t.focusPath(o)}let u=t.getFocusedPath(),d=t.getFocusedIndex(),p=t.getFocusedItem();if(p==null)return;let m=od(p)?p:null,h=u!=null&&(ft.has(u)||c&&o===u&&a.has(u)),g=e.key===`ArrowDown`||e.key===`ArrowUp`||e.key===`ArrowRight`&&m!=null&&m.isExpanded(),_=e.key===`ArrowLeft`&&h&&m!=null&&m.isExpanded(),v=C.current,y=!0;if(e.shiftKey&&e.key===`ArrowDown`)t.extendSelectionFromFocused(1);else if(e.shiftKey&&e.key===`ArrowUp`)t.extendSelectionFromFocused(-1);else if(n&&u!=null&&d>=0){let e=t.getVisibleRows(d,d)[0]??null,n=wd(u,E.current,T.current);e==null||n==null?y=!1:St(e,u)}else if((e.ctrlKey||e.metaKey)&&sd(e))t.toggleFocusedSelection();else if((e.ctrlKey||e.metaKey)&&e.key.toLowerCase()===`a`)t.selectAllVisiblePaths();else switch(e.key){case`ArrowDown`:t.focusNextItem();break;case`ArrowUp`:t.focusPreviousItem();break;case`ArrowRight`:m==null||m.isExpanded()?t.focusNextItem():m.expand();break;case`ArrowLeft`:m!=null&&m.isExpanded()?m.collapse():t.focusParentItem();break;case`Home`:t.focusFirstItem();break;case`End`:t.focusLastItem();break;default:y=!1}if(!y)return;le(`focus`);let b=t.getFocusedPath(),x=b!=null&&(ft.has(b)||a.has(b)),w=g&&b!==u,D=n&&c&&o===u&&b===u;if((h||D)&&b!=null&&(w&&x||D))xe(b,v?.scrollTop??null),k.current=!0,G(e=>e===b?e:b);else{let t=e.key===`ArrowUp`&&h&&b!==u;b!=null&&(t||_&&b===u)?(Se(b,Dd(S.current,v,i,u,s,dt,ot)),k.current=!0,G(e=>e===b?e:b)):be()}re(e=>e+1),e.preventDefault(),e.stopPropagation()};ku(()=>{if(!(!f||!Ke)){if(Ce.current){Ce.current=!1;return}Bu(w.current)}},[Ke,f]),ku(()=>{let e=x.current;switch(ou({hasRenderedInput:e!=null,previousRenamingPath:j.current,renamingPath:We})){case`reset`:j.current=null;return;case`reveal-canonical`:We!=null&&wt(We,{restoreTreeFocus:!1,targetOffset:`live-overlay`});return;case`ignore`:return;case`focus-input`:e!=null&&(me.current=null,j.current=We,Bu(e),e.select());return}},[st.end,st.start,We,wt,ft]),ku(()=>{let e=S.current;if(e==null)return;let t=null,n=()=>{t!=null&&(clearTimeout(t),t=null)},r=()=>{let t=Vu(e)?.dataset.itemPath??null;G(e=>e===t?e:t)},i=()=>{n(),k.current=!0,r()},a=i=>{let a=i.relatedTarget;if(a==null){n(),t=setTimeout(()=>{if(t=null,Vu(e)!=null){r();return}k.current=!1,G(null)},0);return}if(!(a instanceof Node)||!e.contains(a)){n(),k.current=!1,G(null);return}let o=a instanceof HTMLElement?a.dataset.itemPath??null:null;G(e=>e===o?e:o)};return e.addEventListener(`focusin`,i),e.addEventListener(`focusout`,a),()=>{n(),e.removeEventListener(`focusin`,i),e.removeEventListener(`focusout`,a)}},[]),ku(()=>{let e=S.current;e!=null&&(it.physical.scrollTop<=0?e.dataset.scrollAtTop=`true`:delete e.dataset.scrollAtTop)},[it.physical.scrollTop]),ku(()=>{let e=null,n=C.current,r=b.current,i=S.current;if(n==null)return;O.current=ld(n,g);let a=()=>{let e=t.getVisibleCount(),r=ud(O.current,g),i=Math.max(0,e*s-r);n.scrollTop>i&&(n.scrollTop=i),ke(qu({controller:t,itemHeight:s,overscan:c,scrollTop:Math.min(n.scrollTop,i),stickyFolders:h,viewportHeight:r}))};D.current=a;let o=!1,l=t.subscribe(()=>{o?re(e=>e+1):o=!0,a()}),u=()=>{ye.current!==!0&&(r!=null&&(r.dataset.isScrolling??=``),i!=null&&(i.dataset.isScrolling??=``),y.current=!0,e!=null&&clearTimeout(e),e=setTimeout(()=>{r!=null&&delete r.dataset.isScrolling,i!=null&&delete i.dataset.isScrolling,y.current=!1,de(e=>e+1),e=null},50))},d=null,f=()=>{i!=null&&delete i.dataset.overlayReveal,d!=null&&(clearTimeout(d),d=null)},p=()=>{i==null||ye.current===!0||n.scrollTop>0||(i.dataset.overlayReveal=`true`,d!=null&&clearTimeout(d),d=setTimeout(()=>{f()},200))},m=()=>{if(a(),n.scrollTop>0&&f(),pe.current!=null&&y.current&&yt.current(),ye.current===!0){y.current=!1;return}ae(e=>e==null?e:null),u()},_=()=>{u(),p()},v=new Set([`ArrowUp`,`ArrowDown`,`ArrowLeft`,`ArrowRight`,`PageUp`,`PageDown`,`Home`,`End`,` `,`Spacebar`]),x=e=>{v.has(e.key)&&_()};n.addEventListener(`scroll`,m,{passive:!0}),n.addEventListener(`wheel`,_,{passive:!0}),n.addEventListener(`touchmove`,_,{passive:!0}),n.addEventListener(`keydown`,x);let w=typeof ResizeObserver<`u`?new ResizeObserver(e=>{O.current=(e[0]==null?null:dd(e[0]))??ld(n,g),a()}):null;return w?.observe(n),()=>{D.current=()=>{},l(),n.removeEventListener(`scroll`,m),n.removeEventListener(`wheel`,_),n.removeEventListener(`touchmove`,_),n.removeEventListener(`keydown`,x),e!=null&&clearTimeout(e),d!=null&&clearTimeout(d),r!=null&&delete r.dataset.isScrolling,i!=null&&(delete i.dataset.isScrolling,delete i.dataset.overlayReveal),y.current=!1,O.current=null,w?.disconnect()}},[t,g,s,c,h]),ku(()=>{Me||K==null||bt(!1)},[bt,Me,K]);let Vt=ju(()=>K==null?null:`${K.path}::${K.source}`,[K]);ku(()=>{if(Vt==null){m?.clearSlotContent(Xr);return}let t=pe.current;if(t==null)return;let n=v.current??_.current;if(n==null)return;let r={anchorElement:n,anchorRect:t.anchorRect??bd(n.getBoundingClientRect()),close:e=>{yt.current(e?.restoreFocus??!0)},restoreFocus:()=>{vt.current&&_t.current(pe.current?.path??null)}},i=e?.contextMenu?.render?.(t.item,r)??null;return m?.setSlotContent(Xr,i),e?.contextMenu?.onOpen?.(t.item,r),Nd(i),queueMicrotask(()=>{i==null||!i.isConnected||document.activeElement===i&&Nd(i)}),()=>{m?.clearSlotContent(Xr)}},[Vt,e?.contextMenu,m]),ku(()=>{K!=null&&t.getItem(K.path)==null&&bt()},[bt,K,t]),ku(()=>{if(K==null)return;let e=S.current?.getRootNode(),t=e instanceof ShadowRoot?e.host:S.current,n=e=>{let n=e.target;n instanceof Node&&(yd(e)||_.current?.contains(n)!==!0&&t?.contains(n)!==!0&&bt())},r=e=>{e.key===`Escape`&&(e.preventDefault(),e.stopPropagation(),bt())};return document.addEventListener(`mousedown`,n,!0),document.addEventListener(`keydown`,r,!0),()=>{document.removeEventListener(`mousedown`,n,!0),document.removeEventListener(`keydown`,r,!0)}},[bt,K]),ku(()=>{let e=C.current,t=S.current;if(e==null||t==null){A.current=Je;return}let n=Je==null?null:T.current.get(Je)??null,r=Vu(t),i=r?.dataset.itemPath??null,a=Ge&&x.current===r,o=f&&w.current===r,c=M.current&&!Ke,l=N.current??0,u=me.current,d=he.current,p=ge.current,m=_e.current,h=r!=null,g=k.current||h,_=A.current!==Je,v=d!=null&&d===Je&&Je!=null,y=c&&pd(e,Ye,s,ot,ut,l),b=u!=null&&u===Je&&pd(e,Ye,s,ot,ut,dt),E=p!=null&&p.path===Je&&pd(e,Ye,s,ot,ut,p.viewportOffset),O=m!=null&&m.path===Je&&e.scrollTop!==m.scrollTop;if(O&&(e.scrollTop=m.scrollTop),(O||b||E||y||g&&_&&u!==Je&&!v&&fd(e,Ye,s,ot,dt))&&D.current(),!g){A.current=Je;return}if(a){A.current=Je;return}if(o&&!c){A.current=Je;return}if(n==null){c&&Ye>=0&&(pd(e,Ye,s,ot,ut,l),D.current()),A.current=Je;return}(_||c||u===Je||d===Je||p?.path===Je||m?.path===Je||i==null||i!==Je)&&(Bu(n),u===Je&&(me.current=null),d===Je&&(he.current=null),p?.path===Je&&(ge.current=null),m?.path===Je&&(_e.current=null),M.current=!1,N.current=null),A.current=Je},[t,Ye,Je,pt,s,Ge,Ke,st,ot,f,dt,ut,at]);let Ht=Ye>=0&&Ye>=it.visible.startIndex&&Ye<=it.visible.endIndex,Ut=Je!=null&&ct.some(e=>Wu(e.row)===Je),Wt=Ht||Ut,Gt=Pe&&k.current===!0&&Wt?Je:null,Kt=ce===`pointer`?ie:null,qt=K?.path??ve.current??Kt??Gt??ie,Jt=K?.source===`right-click`;ku(()=>{y.current&&K==null||xt(Be(qt))},[K,Be,st,ot,ue,ct,qt,xt,at]);let Yt=Mu(e=>{if(y.current||yd(e))return;let t=e.target;if(!(t instanceof HTMLElement)||t.closest?.(`[data-type="context-menu-trigger"]`)!=null)return;let n=t.closest?.(`[data-file-tree-sticky-row="true"]`),r=t.closest?.(`[data-type="item"]`),i=n instanceof HTMLElement?n.dataset.fileTreeStickyPath??null:r instanceof HTMLElement?r.dataset.itemPath??null:null;i!=null&&le(e=>e===`pointer`?e:`pointer`),ae(e=>e===i?e:i)},[]),Xt=Mu(()=>{ae(null)},[]);ku(()=>{if(!Xe)return;let e=()=>{Mt(),t.cancelDrag()};return window.addEventListener(`dragend`,e),()=>{window.removeEventListener(`dragend`,e),Mt(),t.cancelDrag()}},[t,Xe]);let Zt=e=>{if(!Xe||t.getDragSession()==null||V.current)return;let n=ed(e.target instanceof HTMLElement?e.target:null);t.setDragTarget(n),Pt(t.getDragSession()?.target??null),It(e.clientX,e.clientY),e.dataTransfer!=null&&(e.dataTransfer.dropEffect=`move`),e.preventDefault()},Qt=e=>{if(!Xe||t.getDragSession()==null||V.current)return;let n=e.relatedTarget;n instanceof Node&&S.current?.contains(n)===!0||(Ot(),At(),t.setDragTarget(null))},$t=e=>{!Xe||t.getDragSession()==null||V.current||(e.preventDefault(),Nt(e.clientX,e.clientY),t.completeDrag(),kt(),Ot(),At(),z.current=null)},en=it.window.height,tn=it.window.offsetTop,nn=Math.min(0,ot-en-dt),rn=W===Je||M.current,an=Je!=null&&rn&&!pt&&Ye>=0?at[Ye]??t.getVisibleRows(Ye,Ye)[0]??null:null,on=an==null?null:md(Ye,s,st,en),sn=z.current,cn=et!=null&&sn!=null&&sn.path===et&&sn.index>=st.start&&sn.index<=st.end,ln=et!=null&&sn!=null&&sn.path===et&&!cn&&sn.path!==an?.path?sn:null,un=ln==null?null:md(ln.index,s,st,en),dn=hd((Ye>=0?at[Ye]??t.getVisibleRows(Ye,Ye)[0]??null:null)?.ancestorPaths.at(-1)??null),fn=Ke&&Je!=null?Ad(o,Je,!pt):void 0,q=K?.path??(Ke?Je:W),pn=K?.path??ie,mn=Be(qt),hn=Me&&Pe&&!Jt&&!Ge&&mn!=null&&oe!=null&&qt!=null,gn=Me&&(hn||K!=null),_n=K?.anchorRect,vn=_n==null&&mn!=null&&oe!=null&&(K!=null||hn)?oe:null,yn=_n==null?vn==null?void 0:{top:`${vn}px`}:{left:`${_n.left}px`,position:`fixed`,right:`auto`,top:`${_n.top}px`},bn=Jt?{opacity:`0`}:void 0,xn=Mu((e,n,r,i)=>{let a=t.getItem(r),o=cu({event:{ctrlKey:e.ctrlKey,metaKey:e.metaKey,shiftKey:e.shiftKey},isDirectory:n.kind===`directory`,isSearchOpen:t.isSearchOpen(),mode:i});switch(o.selection.kind){case`range`:t.selectPathRange(r,o.selection.additive);break;case`toggle`:t.togglePathSelectionFromInput(r);break;case`single`:t.selectOnlyPath(r);break}let s=e.currentTarget instanceof HTMLElement?e.currentTarget:null,c=n.index>=it.visible.startIndex&&n.index<=it.visible.endIndex,l=i===`flow`&&c&&s!=null&&s.dataset.itemParked!==`true`;a?.focus(),l&&(k.current=!0,G(e=>e===r?e:r),le(`focus`)),o.toggleDirectory&&od(a)&&a.toggle(),o.closeSearch&&t.closeSearch(),o.revealCanonical&&wt(r,{targetOffset:`sticky-parents`})},[t,it.visible.endIndex,it.visible.startIndex,wt]),Sn=()=>{if(y.current||!Pe||qt==null||mn==null)return;let e=t.getItem(qt);e!=null&&(xt(mn),vt.current=!0,fe({anchorRect:null,item:{kind:e.isDirectory()?`directory`:`file`,name:mn.getAttribute(`aria-label`)??qt,path:e.getPath()},path:e.getPath(),source:`button`}))},Cn={contextHoverPath:pn,contextMenuButtonTriggerEnabled:Pe,contextMenuButtonVisibility:Fe,contextMenuEnabled:Me,contextMenuRightClickEnabled:Ie,contextMenuTriggerMode:Ne,controller:t,directoriesWithGitChanges:i,dragAndDropEnabled:Xe,draggedPathSet:Qe,dragTarget:$e,gitLaneActive:Ve,gitStatusByPath:n,handleRowDragEnd:Rt,handleRowDragStart:Lt,handleRowTouchStart:zt,ignoredGitDirectories:r,ignoredInheritanceCache:ne,instanceId:o,itemHeight:s,onKeyDown:Bt,onRowClick:xn,openContextMenuForRow:St,registerButton:Le,registerRenameInput:ze,renameView:Ue,renderDecorationForRow:mt,resolveIcon:He,shouldSuppressContextMenu:Tt,visualFocusPath:q},wn={...Cn,registerButton:Re};return $(`div`,{ref:S,id:tt,"data-file-tree-context-menu-button-visibility":Me&&Pe?Fe:void 0,"data-file-tree-context-menu-trigger-mode":Me?Ne:void 0,"data-file-tree-has-context-menu-action-lane":Me&&Pe?`true`:void 0,"data-file-tree-has-git-lane":Ve?`true`:void 0,"data-file-tree-virtualized-root":`true`,onDragLeave:Xe?Qt:void 0,onDragOver:Xe?Zt:void 0,onDrop:Xe?$t:void 0,onKeyDown:Bt,onPointerLeave:Me?Xt:void 0,onPointerOver:Me?Yt:void 0,role:`tree`,tabIndex:-1,style:{outline:`none`,position:`relative`},children:[$(`style`,{"data-file-tree-guide-style":`true`,dangerouslySetInnerHTML:{__html:dn}}),$(`slot`,{name:Yr,"data-type":`header-slot`}),f?$(`div`,{"data-file-tree-search-container":!0,"data-open":Ke?`true`:`false`,children:$(`input`,{ref:w,"aria-activedescendant":fn,"aria-controls":tt,placeholder:`Search…`,"data-file-tree-search-input":!0,"data-file-tree-search-input-fake-focus":we?`true`:void 0,value:qe,onBlur:()=>{d===`retain`&&!Ee.current||t.closeSearch()},onFocus:De,onPointerDown:De,onInput:e=>{De();let n=e.currentTarget;t.setSearch(n.value)}})}):null,$(`div`,{ref:C,"data-file-tree-virtualized-scroll":`true`,children:[h&&Ae&&ct.length>0?$(`div`,{"aria-hidden":`true`,"data-file-tree-sticky-overlay":`true`,children:$(`div`,{"data-file-tree-sticky-overlay-content":`true`,style:{height:`${nt}px`},children:ct.map((e,t)=>Fd(wn,e.row,`sticky:${Wu(e.row)}`,{mode:`sticky`,style:{left:`0`,position:`absolute`,right:`0`,top:`${e.top}px`,zIndex:`${ct.length-t}`}}))})}):null,$(`div`,{ref:b,"data-file-tree-virtualized-list":`true`,style:{height:`${ut}px`},children:[$(`div`,{"data-file-tree-virtualized-sticky-offset":`true`,"aria-hidden":`true`,style:{height:`${tn}px`}}),$(`div`,{"data-file-tree-virtualized-sticky":`true`,style:{height:`${en}px`,top:`${nn}px`,bottom:`${nn}px`},children:[Id(Cn,st,ft),an!=null&&on!=null?Fd(Cn,an,`parked:${an.path}`,{isParked:!0,style:{left:`0`,opacity:`0`,pointerEvents:et===an.path?`none`:void 0,position:`absolute`,right:`0`,top:`${on}px`}}):null,ln!=null&&un!=null?Fd(Cn,ln,`parked-drag:${ln.path}`,{isParked:!0,style:{left:`0`,opacity:`0`,pointerEvents:`none`,position:`absolute`,right:`0`,top:`${un}px`}}):null]})]})]}),Me?$(`div`,{ref:_,"data-type":`context-menu-anchor`,"data-visible":gn?`true`:`false`,style:yn,children:[$(`button`,{ref:v,type:`button`,"data-type":Zr,"aria-label":`Options`,"aria-haspopup":`menu`,"aria-expanded":K==null?`false`:`true`,"data-visible":hn?`true`:`false`,onMouseDown:e=>{e.preventDefault()},onClick:e=>{if(e.preventDefault(),e.stopPropagation(),K!=null){bt();return}Sn()},tabIndex:-1,style:bn,children:$(Ml,{...He(`file-tree-icon-ellipsis`)})}),K==null?null:$(`slot`,{name:Xr})]}):null,K==null?null:$(`div`,{"data-type":`context-menu-wash`,"aria-hidden":`true`,onMouseDownCapture:e=>{e.preventDefault(),bt()},onTouchStartCapture:e=>{e.preventDefault(),e.stopPropagation(),bt()},onTouchMoveCapture:e=>{e.preventDefault(),e.stopPropagation()},onWheelCapture:e=>{e.preventDefault(),e.stopPropagation()}})]})}var Rd={hydrateRoot:(e,t)=>{Dl(rl(Ld,t),e)},renderRoot:(e,t)=>{El(rl(Ld,t),e)},unmountRoot:e=>{El(null,e)}};function zd(e,t){Rd.renderRoot(e,t)}function Bd(e,t){Rd.hydrateRoot(e,t)}function Vd(e){Rd.unmountRoot(e)}var Hd=class{#e=new Map;#t=null;clearAll(){for(let e of this.#e.values())e.remove();this.#e.clear()}clearSlotContent(e){let t=this.#n(e);t!=null&&(t.remove(),this.#e.delete(e))}setHost(e){if(this.#t=e,e!=null){this.#i(e);for(let[e,t]of this.#e)this.#r(e,t)}}setSlotContent(e,t){let n=this.#n(e);if(n===t){t!=null&&(this.#e.set(e,t),this.#r(e,t));return}if(n?.remove(),t==null){this.#e.delete(e);return}this.#e.set(e,t),this.#r(e,t)}setSlotHtml(e,t){let n=t?.trim()??``;if(n.length===0){this.setSlotContent(e,null);return}let r=this.#n(e);if(r!=null&&r.innerHTML===n){this.#e.set(e,r),this.#r(e,r);return}let i=document.createElement(`div`);i.innerHTML=n,this.setSlotContent(e,i)}#n(e){let t=this.#e.get(e)??null;if(t!=null)return t;let n=this.#t;if(n==null)return null;for(let t of Array.from(n.children))if(t instanceof HTMLElement&&t.dataset.fileTreeManagedSlot===e)return t;return null}#r(e,t){t.slot=e,t.dataset.fileTreeManagedSlot=e,this.#t!=null&&t.parentNode!==this.#t&&this.#t.appendChild(t)}#i(e){for(let t of Array.from(e.children)){if(!(t instanceof HTMLElement))continue;let e=t.dataset.fileTreeManagedSlot;e==null||this.#e.has(e)||this.#e.set(e,t)}}},Ud=`__c`,Wd=`__k`,Gd=`__d`,Kd=`__s`,qd=/[\s\n\\/='"\0<>]/,Jd=/^(xlink|xmlns|xml)([A-Z])/,Yd=/^(?:accessK|auto[A-Z]|cell|ch|col|cont|cross|dateT|encT|form[A-Z]|frame|hrefL|inputM|maxL|minL|noV|playsI|popoverT|readO|rowS|src[A-Z]|tabI|useM|item[A-Z])/,Xd=/^ac|^ali|arabic|basel|cap|clipPath$|clipRule$|color|dominant|enable|fill|flood|font|glyph[^R]|horiz|image|letter|lighting|marker[^WUH]|overline|panose|pointe|paint|rendering|shape|stop|strikethrough|stroke|text[^L]|transform|underline|unicode|units|^v[^i]|^w|^xH/,Zd=new Set([`draggable`,`spellcheck`]);function Qd(e){e.__g===void 0?e[Gd]=!0:e.__g|=8}function $d(e){e.__g===void 0?e[Gd]=!1:e.__g&=-9}function ef(e){return e.__g===void 0?!0===e[Gd]:!!(8&e.__g)}var tf=/["&<]/;function nf(e){if(e.length===0||!1===tf.test(e))return e;for(var t=0,n=0,r=``,i=``;n<e.length;n++){switch(e.charCodeAt(n)){case 34:i=`"`;break;case 38:i=`&`;break;case 60:i=`<`;break;default:continue}n!==t&&(r+=e.slice(t,n)),r+=i,t=n+1}return n!==t&&(r+=e.slice(t,n)),r}var rf={},af=new Set(`animation-iteration-count.border-image-outset.border-image-slice.border-image-width.box-flex.box-flex-group.box-ordinal-group.column-count.fill-opacity.flex.flex-grow.flex-negative.flex-order.flex-positive.flex-shrink.flood-opacity.font-weight.grid-column.grid-row.line-clamp.line-height.opacity.order.orphans.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-miterlimit.stroke-opacity.stroke-width.tab-size.widows.z-index.zoom`.split(`.`)),of=/[A-Z]/g;function sf(e){var t=``;for(var n in e){var r=e[n];if(r!=null&&r!==``){var i=n[0]==`-`?n:rf[n]||(rf[n]=n.replace(of,`-$&`).toLowerCase()),a=`;`;typeof r!=`number`||i.startsWith(`--`)||af.has(i)||(a=`px;`),t=t+i+`:`+r+a}}return t||void 0}function cf(){this.__d=!0}function lf(e,t){return{__v:e,context:t,props:e.props,setState:cf,forceUpdate:cf,__d:!0,__h:[]}}function uf(e,t,n){if(!e.s){if(n instanceof df){if(!n.s)return void(n.o=uf.bind(null,e,t));1&t&&(t=n.s),n=n.v}if(n&&n.then)return void n.then(uf.bind(null,e,t),uf.bind(null,e,2));e.s=t,e.v=n;let r=e.o;r&&r(e)}}var df=function(){function e(){}return e.prototype.then=function(t,n){var r=new e,i=this.s;if(i){var a=1&i?t:n;if(a){try{uf(r,1,a(this.v))}catch(e){uf(r,2,e)}return r}return this}return this.o=function(e){try{var i=e.v;1&e.s?uf(r,1,t?t(i):i):n?uf(r,1,n(i)):uf(r,2,i)}catch(e){uf(r,2,e)}},r},e}(),ff,pf,mf,hf,gf={},_f=Array.isArray,vf=Object.assign,yf=``,bf=`<!--$s-->`,xf=`<!--/$s-->`;function Sf(e,t){var n,r=e.type,i=!0;return e[Ud]?(i=!1,(n=e[Ud]).state=n[Kd]):n=new r(e.props,t),e[Ud]=n,n.__v=e,n.props=e.props,n.context=t,Qd(n),n.state??=gf,n[Kd]??(n[Kd]=n.state),r.getDerivedStateFromProps?n.state=vf({},n.state,r.getDerivedStateFromProps(n.props,n.state)):i&&n.componentWillMount?(n.componentWillMount(),n.state=n[Kd]===n.state?n.state:n[Kd]):!i&&n.componentWillUpdate&&n.componentWillUpdate(),mf&&mf(e),n.render(n.props,n.state,t)}function Cf(e,t,n,r,i,a,o){if(e==null||!0===e||!1===e||e===yf)return yf;var s=typeof e;if(s!=`object`)return s==`function`?yf:s==`string`?nf(e):e+yf;if(_f(e)){var c,l=yf;i[Wd]=e;for(var u=e.length,d=0;d<u;d++){var f=e[d];if(f!=null&&typeof f!=`boolean`){var p,m=Cf(f,t,n,r,i,a,o);typeof m==`string`?l+=m:(c||=Array(u),l&&c.push(l),l=yf,_f(m)?(p=c).push.apply(p,m):c.push(m))}}return c?(l&&c.push(l),c):l}if(e.constructor!==void 0)return yf;e.__=i,ff&&ff(e);var h=e.type,g=e.props;if(typeof h==`function`){var _,v,y,b=t;if(h===al){if(`tpl`in g){for(var x=yf,S=0;S<g.tpl.length;S++)if(x+=g.tpl[S],g.exprs&&S<g.exprs.length){var C=g.exprs[S];if(C==null)continue;typeof C!=`object`||C.constructor!==void 0&&!_f(C)?x+=C:x+=Cf(C,t,n,r,e,a,o)}return x}if(`UNSTABLE_comment`in g)return`<!--`+nf(g.UNSTABLE_comment)+`-->`;v=g.children}else{if((_=h.contextType)!=null){var w=t[_.__c];b=w?w.props.value:_.__}var T=h.prototype&&typeof h.prototype.render==`function`;if(T)v=Sf(e,b),y=e[Ud];else{e[Ud]=y=lf(e,b);for(var E=0;ef(y)&&E++<25;){$d(y),mf&&mf(e);try{v=h.call(y,g,b)}catch(t){throw a&&t&&typeof t.then==`function`&&(e._suspended=!0),t}}Qd(y)}if(y.getChildContext!=null&&(t=vf({},t,y.getChildContext())),T&&Vc.errorBoundaries&&(h.getDerivedStateFromError||y.componentDidCatch)){v=v!=null&&v.type===al&&v.key==null&&v.props.tpl==null?v.props.children:v;try{return Cf(v,t,n,r,e,a,!1)}catch(i){return h.getDerivedStateFromError&&(y[Kd]=h.getDerivedStateFromError(i)),y.componentDidCatch&&y.componentDidCatch(i,gf),ef(y)?(v=Sf(e,t),(y=e[Ud]).getChildContext!=null&&(t=vf({},t,y.getChildContext())),Cf(v=v!=null&&v.type===al&&v.key==null&&v.props.tpl==null?v.props.children:v,t,n,r,e,a,o)):yf}finally{pf&&pf(e),hf&&hf(e)}}}v=v!=null&&v.type===al&&v.key==null&&v.props.tpl==null?v.props.children:v;try{var D=Cf(v,t,n,r,e,a,o);return pf&&pf(e),Vc.unmount&&Vc.unmount(e),e._suspended?typeof D==`string`?bf+D+xf:_f(D)?(D.unshift(bf),D.push(xf),D):D.then(function(e){return bf+e+xf}):D}catch(i){if(!a&&o&&o.onError){var O=function i(s){return o.onError(s,e,function(e,s){try{return Cf(e,t,n,r,s,a,o)}catch(e){return i(e)}})}(i);if(O!==void 0)return O;var k=Vc.__e;return k&&k(i,e),yf}if(!a||!i||typeof i.then!=`function`)throw i;return i.then(function i(){try{var s=Cf(v,t,n,r,e,a,o);return e._suspended?bf+s+xf:s}catch(e){if(!e||typeof e.then!=`function`)throw e;return e.then(i)}})}}var A,j=`<`+h,M=yf;for(var N in g){var P=g[N];if(typeof(P=Tf(P)?P.value:P)!=`function`||N===`class`||N===`className`){switch(N){case`children`:A=P;continue;case`key`:case`ref`:case`__self`:case`__source`:continue;case`htmlFor`:if(`for`in g)continue;N=`for`;break;case`className`:if(`class`in g)continue;N=`class`;break;case`defaultChecked`:N=`checked`;break;case`defaultSelected`:N=`selected`;break;case`defaultValue`:case`value`:switch(N=`value`,h){case`textarea`:A=P;continue;case`select`:r=P;continue;case`option`:r!=P||`selected`in g||(j+=` selected`)}break;case`dangerouslySetInnerHTML`:M=P&&P.__html;continue;case`style`:typeof P==`object`&&(P=sf(P));break;case`acceptCharset`:N=`accept-charset`;break;case`httpEquiv`:N=`http-equiv`;break;default:if(Jd.test(N))N=N.replace(Jd,`$1:$2`).toLowerCase();else{if(qd.test(N))continue;N[4]!==`-`&&!Zd.has(N)||P==null?n?Xd.test(N)&&(N=N===`panose1`?`panose-1`:N.replace(/([A-Z])/g,`-$1`).toLowerCase()):Yd.test(N)&&(N=N.toLowerCase()):P+=yf}}P!=null&&!1!==P&&(j=!0===P||P===yf?j+` `+N:j+` `+N+`="`+(typeof P==`string`?nf(P):P+yf)+`"`)}}if(qd.test(h))throw Error(h+` is not a valid HTML tag name in `+j+`>`);if(M||(typeof A==`string`?M=nf(A):A!=null&&!1!==A&&!0!==A&&(M=Cf(A,t,h===`svg`||h!==`foreignObject`&&n,r,e,a,o))),pf&&pf(e),hf&&hf(e),!M&&wf.has(h))return j+`/>`;var F=`</`+h+`>`,I=j+`>`;return _f(M)?[I].concat(M,[F]):typeof M==`string`?I+M+F:[I,M,F]}var wf=new Set([`area`,`base`,`br`,`col`,`command`,`embed`,`hr`,`img`,`input`,`keygen`,`link`,`meta`,`param`,`source`,`track`,`wbr`]);function Tf(e){return typeof e==`object`&&!!e&&typeof e.peek==`function`&&`value`in e}var Ef=0;function Df(e){return e!=null&&e.length>0?e:(Ef+=1,`pst_ft_${Ef}`)}function Of({initialVisibleRowCount:e,itemHeight:t}){return e==null?420:Math.max(0,e)*(t??zs)}function kf(e){if(typeof document>`u`)return;let t=document.createElement(`div`);t.innerHTML=e;let n=t.querySelector(`svg`);return n instanceof SVGElement?n:void 0}function Af(e){return e.querySelector(`#file-tree-icon-chevron`)instanceof SVGElement&&e.querySelector(`#file-tree-icon-file`)instanceof SVGElement&&e.querySelector(`#file-tree-icon-dot`)instanceof SVGElement&&e.querySelector(`#file-tree-icon-lock`)instanceof SVGElement}function jf(e){return Array.from(e.children).filter(e=>e instanceof SVGElement)}var Mf=class{static LoadedCustomComponent=!0;#e;#t;#n;#r;#i;#a;#o;#s;#c;#l=new Hd;#u;#d;#f;#p;#m;#h;#g;#_;#v;#y=null;#b;#x=!1;#S=!1;constructor(e){let{composition:t,density:n,fileTreeSearchMode:r,gitStatus:i,id:a,initialSearchQuery:o,icons:s,itemHeight:c,onSearchChange:l,onSelectionChange:u,overscan:d,renderRowDecoration:f,renaming:p,search:m,searchBlurBehavior:h,searchFakeFocus:g,stickyFolders:_,unsafeCSS:v,initialVisibleRowCount:y,...b}=e;this.#e=t,this.#n=Df(a),this.#p=Bc(i),this.#m=s,this.#h=v,this.#r=u,this.#i=f,this.#a=p!=null&&p!==!1,this.#o=h,this.#s=m===!0,this.#c=g===!0,this.#u=Rs(n,c),this.#d={itemHeight:this.#u.itemHeight,overscan:d,stickyFolders:_,initialVisibleRowCount:y},this.#t=new Fc({...b,fileTreeSearchMode:r,initialSearchQuery:o,onSearchChange:l,renaming:p}),this.#v=this.#t.getSelectionVersion(),this.#y=this.#r==null?null:this.subscribe(()=>{this.#D()})}unmount(){this.#b!=null&&(Vd(this.#b),delete this.#b.dataset.fileTreeVirtualizedWrapper,this.#b=void 0),this.#l.clearAll(),this.#l.setHost(null),this.#f!=null&&(delete this.#f.dataset.fileTreeVirtualized,this.#I(this.#f),this.#f=void 0)}cleanUp(){this.unmount(),this.#y?.(),this.#y=null,this.#t.destroy()}getFileTreeContainer(){return this.#f}getItem(e){return this.#t.getItem(e)}getFocusedItem(){return this.#t.getFocusedItem()}getFocusedPath(){return this.#t.getFocusedPath()}getSelectedPaths(){return this.#t.getSelectedPaths()}getComposition(){return this.#e}getItemHeight(){return this.#u.itemHeight}getDensityFactor(){return this.#u.factor}subscribe(e){let t=!1;return this.#t.subscribe(()=>{if(!t){t=!0;return}e()})}focusPath(e){this.#t.focusPath(e)}focusNearestPath(e){return this.#t.focusNearestPath(e)}add(e){this.#t.add(e)}batch(e){this.#t.batch(e)}move(e,t,n){this.#t.move(e,t,n)}onMutation(e,t){return this.#t.onMutation(e,t)}setSearch(e){this.#t.setSearch(e)}openSearch(e){this.#t.openSearch(e)}closeSearch(){this.#t.closeSearch()}isSearchOpen(){return this.#t.isSearchOpen()}getSearchValue(){return this.#t.getSearchValue()}getSearchMatchingPaths(){return this.#t.getSearchMatchingPaths()}focusNextSearchMatch(){this.#t.focusNextSearchMatch()}focusPreviousSearchMatch(){this.#t.focusPreviousSearchMatch()}startRenaming(e,t){return this.#t.startRenaming(e,t)}remove(e,t){this.#t.remove(e,t)}resetPaths(e,t){this.#t.resetPaths(e,t)}setComposition(e){this.#e=e;let t=this.#T();t!=null&&(this.#O(),zd(t.wrapper,this.#w()))}setGitStatus(e){this.#p=Bc(e,this.#p);let t=this.#T();t!=null&&zd(t.wrapper,this.#w())}setIcons(e){this.#m=e;let t=this.#T();t!=null&&(this.#E(t.host,t.wrapper),zd(t.wrapper,this.#w()))}hydrate({fileTreeContainer:e}){let t=this.#P(e),n=this.#N(t);this.#O(),Bd(n,this.#w())}render({containerWrapper:e,fileTreeContainer:t}){let n=this.#P(t??this.#f,e),r=this.#N(n);this.#O(),zd(r,this.#w())}#C(){return{initialViewportHeight:Of({initialVisibleRowCount:this.#d.initialVisibleRowCount,itemHeight:this.#d.itemHeight}),itemHeight:this.#d.itemHeight,overscan:this.#d.overscan,stickyFolders:this.#d.stickyFolders}}#w(){return{composition:this.#e,controller:this.#t,gitStatusByPath:this.#p?.statusByPath,ignoredGitDirectories:this.#p?.ignoredDirectoryPaths,directoriesWithGitChanges:this.#p?.directoriesWithChanges,icons:this.#m,instanceId:this.#n,renamingEnabled:this.#a,renderRowDecoration:this.#i,searchBlurBehavior:this.#o,searchEnabled:this.#s,searchFakeFocus:this.#c,slotHost:this.#l,...this.#C()}}#T(){let e=this.#f,t=this.#b;return e==null||t==null?null:{host:e,wrapper:t}}#E(e,t){let n=e.shadowRoot;n!=null&&(this.#k(n),this.#A(n)),this.#j(t)}#D(){let e=this.#r;if(e==null)return;let t=this.#t.getSelectionVersion();t!==this.#v&&(this.#v=t,e(this.#t.getSelectedPaths()))}#O(){let e=this.#e?.header?.render;if(e!=null){this.#l.setSlotContent(Yr,e());return}this.#l.setSlotHtml(Yr,this.#e?.header?.html??null)}#k(e){let t=jf(e).find(e=>Af(e)),n=kf(Rr($r(this.#m).set));n!=null&&(t!=null&&t.outerHTML===n.outerHTML||(t==null?e.prepend(n):t.replaceWith(n)))}#A(e){let t=jf(e),n=t.find(e=>Af(e)),r=t.filter(e=>e!==n),i=$r(this.#m).spriteSheet?.trim()??``;if(i.length===0){for(let e of r)e.remove();return}let a=kf(i);if(a==null){for(let e of r)e.remove();return}if(!(r.length===1&&r[0].outerHTML===a.outerHTML)){for(let e of r)e.remove();e.appendChild(a)}}#j(e){let t=$r(this.#m);t.colored&&Vr(t.set)?e.dataset.fileTreeColoredIcons=`true`:delete e.dataset.fileTreeColoredIcons}#M(e){let t=e.querySelector(`style[${Gr}]`);if(this.#g==null&&t instanceof HTMLStyleElement&&(this.#g=t),this.#h==null||this.#h===``){this.#g?.remove(),this.#g=void 0,this.#_=void 0;return}this.#g?.parentNode===e&&this.#_===this.#h||(this.#g??=document.createElement(`style`),this.#g.setAttribute(Gr,``),this.#g.parentNode!==e&&e.appendChild(this.#g),this.#g.textContent=Us(this.#h),this.#_=this.#h)}#N(e){if(this.#b!=null)return this.#b;let t=e.shadowRoot;if(t==null)throw Error(`FileTree requires a shadow root`);let n=Array.from(t.children).filter(e=>e instanceof HTMLDivElement&&typeof e.dataset.fileTreeId==`string`&&e.dataset.fileTreeId.length>0),r=n.find(e=>e.dataset.fileTreeId===this.#n)??n[0];return r!=null&&(this.#n=r.dataset.fileTreeId??this.#n),this.#b=r??document.createElement(`div`),this.#b.dataset.fileTreeId=this.#n,this.#b.dataset.fileTreeVirtualizedWrapper=`true`,this.#E(e,this.#b),this.#b.parentNode!==t&&t.appendChild(this.#b),this.#b}#P(e,t){let n=e??this.#f??document.createElement(`file-tree-container`);t!=null&&n.parentNode!==t&&t.appendChild(n);let r=n.shadowRoot??n.attachShadow({mode:`open`});return Ys(n,r),this.#M(r),n.dataset.fileTreeVirtualized=`true`,n.style.display=`flex`,this.#F(n),this.#l.setHost(n),this.#f=n,n}#F(e){e.style.getPropertyValue(`--trees-item-height`)===``&&(e.style.setProperty(`--trees-item-height`,`${String(this.#u.itemHeight)}px`),this.#x=!0),e.style.getPropertyValue(`--trees-density-override`)===``&&(e.style.setProperty(`--trees-density-override`,String(this.#u.factor)),this.#S=!0)}#I(e){this.#x&&=(e.style.removeProperty(`--trees-item-height`),!1),this.#S&&=(e.style.removeProperty(`--trees-density-override`),!1)}},Nf=typeof window>`u`?q.useEffect:q.useLayoutEffect;function Pf(e,t,n){let r=e==null?null:(0,Y.jsx)(`div`,{slot:Yr,children:e}),i=t!=null&&n!=null?(0,Y.jsx)(`div`,{slot:Xr,children:t(n.item,n.context)}):null;return r==null&&i==null?null:(0,Y.jsxs)(Y.Fragment,{children:[r,i]})}function Ff(e,t){return typeof window>`u`&&t!=null?(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(`template`,{shadowrootmode:`open`,dangerouslySetInnerHTML:{__html:t.shadowHtml}}),e]}):(0,Y.jsx)(Y.Fragment,{children:e})}function If(e){let t=e.shadowRoot;return t?.querySelector(`[data-file-tree-id]`)instanceof HTMLElement||t?.querySelector(`[data-file-tree-id]`)instanceof SVGElement?!0:e.querySelector(`template[shadowrootmode="open"]`)instanceof HTMLTemplateElement}function Lf(e,t,n,r,i){let a={...e??{}};if(t!=null&&delete a.header,n){let t=e?.contextMenu,n=t?.onClose,o=t?.onOpen;a.contextMenu={...t??{},enabled:!0,onClose:()=>{n?.(),r()},onOpen:(e,t)=>{i(e,t),o?.(e,t)}},delete a.contextMenu.render}return a.header!=null||a.contextMenu!=null?a:void 0}function Rf({header:e,id:t,model:n,preloadedData:r,renderContextMenu:i,...a}){let[o,s]=(0,q.useState)(null),[c,l]=(0,q.useState)(null),u=(0,q.useRef)(n.getComposition()),d=(0,q.useRef)(n);d.current!==n&&(d.current=n,u.current=n.getComposition());let f=i!=null,p=(0,q.useCallback)(()=>{s(null)},[]),m=(0,q.useCallback)((e,t)=>{s({context:t,item:e})},[]),h=u.current,g=(0,q.useMemo)(()=>Lf(h,e,f,p,m),[h,p,m,f,e]),_=(0,q.useCallback)(e=>{l(e)},[]);(0,q.useEffect)(()=>{f||s(null)},[f]),Nf(()=>{n.setComposition(g)},[g,n]),Nf(()=>{if(c!=null)return r!=null&&If(c)?n.hydrate({fileTreeContainer:c}):n.render({fileTreeContainer:c}),()=>{n.unmount(),n.setComposition(h)}},[h,c,n,r]);let v=Ff(Pf(e,i,o),r),y=t??r?.id,b={"--trees-item-height":`${String(n.getItemHeight())}px`,"--trees-density-override":n.getDensityFactor(),...a.style};return(0,Y.jsx)(Ur,{...a,id:y,ref:_,style:b,suppressHydrationWarning:r!=null,children:v})}function zf(e){let t=(0,q.useRef)(null);return t.current??=new Mf(e),(0,q.useEffect)(()=>{let e=t.current;return()=>{e?.cleanUp(),t.current=null}},[]),{model:t.current}}var Bf=q.createContext(void 0);function Vf(e=!0){let t=q.useContext(Bf);if(t===void 0&&!e)throw Error(x(7));return t}var Hf=q.forwardRef(function(e,t){let{className:n,defaultPressed:r=!1,disabled:i=!1,form:a,onPressedChange:o,pressed:s,render:l,type:u,value:f,nativeButton:m=!0,style:h,..._}=e,v=p(f||void 0),y=Vf(),b=y?.value??[],x=y?void 0:r,C=(i||y?.disabled)??!1,[w,T]=Le({controlled:y?v!==void 0&&b.indexOf(v)>-1:s,default:x,name:`Toggle`,state:`pressed`}),E=g((e,t)=>{v&&y?.setGroupValue?.(v,e,t),o?.(e,t)}),{getButtonProps:D,buttonRef:O}=nn({disabled:C,native:m}),k={disabled:C,pressed:w},A=[O,t],j=[{"aria-pressed":w,onClick(e){let t=!w,n=S(c,e.nativeEvent);E(t,n),!n.isCanceled&&T(t)}},_,D],M=d(`button`,e,{enabled:!y,state:k,ref:A,props:j});return y?(0,Y.jsx)(de,{tag:`button`,render:l,className:n,style:h,state:k,refs:A,props:j}):M}),Uf=function(e){return e.disabled=`data-disabled`,e.orientation=`data-orientation`,e.multiple=`data-multiple`,e}({}),Wf={multiple(e){return e?{[Uf.multiple]:``}:null}},Gf=q.forwardRef(function(e,t){let{defaultValue:n,disabled:r=!1,loopFocus:i=!0,onValueChange:a,orientation:o=`horizontal`,multiple:s=!1,value:c,className:l,render:u,style:f,...p}=e,m=et(!0),h=q.useMemo(()=>{if(c===void 0)return n??[]},[c,n]),_=q.useMemo(()=>c!==void 0||n!==void 0,[c,n]),v=(m?.disabled??!1)||r,[y,b]=Le({controlled:c,default:h,name:`ToggleGroup`,state:`value`}),x=g((e,t,n)=>{let r;if(s?(r=y.slice(),t?r.push(e):r.splice(y.indexOf(e),1)):r=t?[e]:[],Array.isArray(r)){if(a?.(r,n),n.isCanceled)return;b(r)}}),S={disabled:v,multiple:s,orientation:o},C=q.useMemo(()=>({disabled:v,orientation:o,setGroupValue:x,value:y,isValueInitialized:_}),[v,o,x,y,_]),w={role:`group`},T=d(`div`,e,{enabled:!!m,state:S,ref:t,props:[w,p],stateAttributesMapping:Wf});return(0,Y.jsx)(Bf.Provider,{value:C,children:m?T:(0,Y.jsx)(qe,{render:u,className:l,style:f,state:S,refs:[t],props:[w,p],stateAttributesMapping:Wf,loopFocus:i,enableHomeAndEndKeys:!0,orientation:o})})}),Kf=sn(`group/toggle inline-flex items-center justify-center gap-1 rounded-lg text-sm font-medium whitespace-nowrap transition-all outline-none hover:bg-muted hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 aria-pressed:bg-muted data-[state=on]:bg-muted dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,{variants:{variant:{default:`bg-transparent`,outline:`border border-input bg-transparent hover:bg-muted`},size:{default:`h-8 min-w-8 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2`,sm:`h-7 min-w-7 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5`,lg:`h-9 min-w-9 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2`}},defaultVariants:{variant:`default`,size:`default`}}),qf=q.createContext({size:`default`,variant:`default`,spacing:0,orientation:`horizontal`});function Jf(e){let t=(0,J.c)(29),n,r,i,a,o,c,l;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5],c=t[6],l=t[7]):({className:r,variant:l,size:a,spacing:o,orientation:c,children:n,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o,t[6]=c,t[7]=l);let u=o===void 0?0:o,d=c===void 0?`horizontal`:c,f;t[8]===u?f=t[9]:(f={"--gap":u},t[8]=u,t[9]=f);let p=f,m;t[10]===r?m=t[11]:(m=s(`group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] rounded-lg data-[size=sm]:rounded-[min(var(--radius-md),10px)] data-vertical:flex-col data-vertical:items-stretch`,r),t[10]=r,t[11]=m);let h;t[12]!==d||t[13]!==a||t[14]!==u||t[15]!==l?(h={variant:l,size:a,spacing:u,orientation:d},t[12]=d,t[13]=a,t[14]=u,t[15]=l,t[16]=h):h=t[16];let g;t[17]!==n||t[18]!==h?(g=(0,Y.jsx)(qf.Provider,{value:h,children:n}),t[17]=n,t[18]=h,t[19]=g):g=t[19];let _;return t[20]!==d||t[21]!==i||t[22]!==a||t[23]!==u||t[24]!==p||t[25]!==m||t[26]!==g||t[27]!==l?(_=(0,Y.jsx)(Gf,{"data-slot":`toggle-group`,"data-variant":l,"data-size":a,"data-spacing":u,"data-orientation":d,style:p,className:m,...i,children:g}),t[20]=d,t[21]=i,t[22]=a,t[23]=u,t[24]=p,t[25]=m,t[26]=g,t[27]=l,t[28]=_):_=t[28],_}function Yf(e){let t=(0,J.c)(19),n,r,i,a,o;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5]):({className:r,children:n,variant:a,size:o,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o);let c=a===void 0?`default`:a,l=o===void 0?`default`:o,u=q.use(qf),d=u.variant||c,f=u.size||l,p=u.spacing,m;t[6]!==r||t[7]!==u.size||t[8]!==u.variant||t[9]!==l||t[10]!==c?(m=s(`shrink-0 group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 focus:z-10 focus-visible:z-10 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-end]:pr-1.5 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-start]:pl-1.5 group-data-horizontal/toggle-group:data-[spacing=0]:first:rounded-l-lg group-data-vertical/toggle-group:data-[spacing=0]:first:rounded-t-lg group-data-horizontal/toggle-group:data-[spacing=0]:last:rounded-r-lg group-data-vertical/toggle-group:data-[spacing=0]:last:rounded-b-lg group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-l-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-l group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t`,Kf({variant:u.variant||c,size:u.size||l}),r),t[6]=r,t[7]=u.size,t[8]=u.variant,t[9]=l,t[10]=c,t[11]=m):m=t[11];let h;return t[12]!==n||t[13]!==u.spacing||t[14]!==i||t[15]!==d||t[16]!==f||t[17]!==m?(h=(0,Y.jsx)(Hf,{"data-slot":`toggle-group-item`,"data-variant":d,"data-size":f,"data-spacing":p,className:m,...i,children:n}),t[12]=n,t[13]=u.spacing,t[14]=i,t[15]=d,t[16]=f,t[17]=m,t[18]=h):h=t[18],h}var Xf=Rr(`complete`),Zf=ii({set:`complete`,colored:!0});function Qf(e){if(!e||e.firstChild)return;let t=document.createElement(`template`);return t.innerHTML=Xf,e.replaceChildren(t.content.cloneNode(!0)),()=>{e.replaceChildren()}}function $f(){let e=(0,J.c)(1),t;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,Y.jsx)(`span`,{ref:Qf,"aria-hidden":`true`,className:`pointer-events-none absolute size-0 overflow-hidden`}),e[0]=t):t=e[0],t}function ep(e){let t=(0,J.c)(25),{path:n}=e,r,i,a,o,s,c,l,u,d,f;if(t[0]!==n){let e=Zf.resolveIcon(`file-tree-icon-file`,n),p=e.token?Br(e.token):void 0;a=`true`,o=`size-4 shrink-0 text-muted-foreground`,s=e.remappedFrom??e.name,c=e.token,l=`false`,u=p?{color:p}:void 0,d=e.viewBox??`0 0 ${e.width??16} ${e.height??16}`,f=e.width??16,i=e.height??16;let m;t[11]===Symbol.for(`react.memo_cache_sentinel`)?(m=/^#/,t[11]=m):m=t[11],r=e.name.replace(m,``),t[0]=n,t[1]=r,t[2]=i,t[3]=a,t[4]=o,t[5]=s,t[6]=c,t[7]=l,t[8]=u,t[9]=d,t[10]=f}else r=t[1],i=t[2],a=t[3],o=t[4],s=t[5],c=t[6],l=t[7],u=t[8],d=t[9],f=t[10];let p=`#${r}`,m;t[12]===p?m=t[13]:(m=(0,Y.jsx)(`use`,{href:p}),t[12]=p,t[13]=m);let h;return t[14]!==i||t[15]!==m||t[16]!==a||t[17]!==o||t[18]!==s||t[19]!==c||t[20]!==l||t[21]!==u||t[22]!==d||t[23]!==f?(h=(0,Y.jsx)(`svg`,{"aria-hidden":a,className:o,"data-icon-name":s,"data-icon-token":c,focusable:l,style:u,viewBox:d,width:f,height:i,children:m}),t[14]=i,t[15]=m,t[16]=a,t[17]=o,t[18]=s,t[19]=c,t[20]=l,t[21]=u,t[22]=d,t[23]=f,t[24]=h):h=t[24],h}function tp(e){let t=(0,J.c)(6),{children:n,tone:r,className:i}=e,a=(r===void 0?`muted`:r)===`destructive`?`text-destructive`:`text-muted-foreground`,o;t[0]!==i||t[1]!==a?(o=s(`flex min-h-8 items-center gap-2 text-sm leading-6`,a,i),t[0]=i,t[1]=a,t[2]=o):o=t[2];let c;return t[3]!==n||t[4]!==o?(c=(0,Y.jsx)(`div`,{className:o,children:n}),t[3]=n,t[4]=o,t[5]=c):c=t[5],c}var np=[],rp=[],ip=[],ap=[],op=1e3*30,sp=1e3*60*10,cp=320,lp=220,up=720,dp=[({transform:e})=>({...e,y:0})],fp=new Map,pp={c:`c`,cc:`c`,cpp:`c`,cs:`c`,css:`css`,go:`go`,h:`c`,htm:`html`,html:`html`,java:`java`,js:`javascript`,jsx:`jsx`,json:`json`,markdown:`markdown`,md:`markdown`,jsonc:`jsonc`,mjs:`javascript`,mdx:`mdx`,py:`python`,rs:`rust`,ts:`typescript`,tsx:`tsx`,xml:`xml`,yaml:`yaml`,yml:`yaml`};function mp(e){return(e.split(/[?#]/)[0]||``).match(/\.([A-Za-z0-9]+)$/)?.[1]?.toLowerCase()}function hp(e){let t=mp(e);if(t)return pp[t]}function gp(e){let t=mp(e);return t===`md`||t===`markdown`}function _p(e){return!!(e&&`html`in e&&e.html)}function vp(e,t){switch(t.type){case`clear`:return e&&null;case`loaded`:return t.payload;case`unavailable`:return{ok:!0,unavailable:!0};default:return e}}async function yp(e,t){if(!t)return{ok:!0,skipped:!0};let n=`${t}\u0000${e}`,r=fp.get(n);if(r)return await r;let i=Qt(`/api/highlight`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({code:e,language:t})});fp.set(n,i);let a=await i;return fp.set(n,a),a}function bp({viewerContextId:e,cwd:t}){return{queryKey:tn.projectFileTree(e,t),queryFn:()=>Qt(en(`/api/files/tree?cwd=${encodeURIComponent(t)}`,{contextId:e})),staleTime:op,gcTime:sp}}function xp({viewerContextId:e,cwd:t,path:n}){return{queryKey:tn.projectFileRead(e,t,n),queryFn:()=>Qt(en(`/api/files/read?cwd=${encodeURIComponent(t)}&path=${encodeURIComponent(n)}`,{contextId:e})),staleTime:op,gcTime:sp}}var Sp=`
|
|
1814
|
+
:host {
|
|
1815
|
+
--trees-bg-override: var(--background);
|
|
1816
|
+
--trees-fg-override: var(--foreground);
|
|
1817
|
+
--trees-border-color-override: var(--border);
|
|
1818
|
+
--trees-fg-muted-override: var(--muted-foreground);
|
|
1819
|
+
--trees-selected-bg-override: var(--accent);
|
|
1820
|
+
--trees-selected-fg-override: var(--accent-foreground);
|
|
1821
|
+
--trees-padding-inline-override: 0px;
|
|
1822
|
+
}
|
|
1823
|
+
|
|
1824
|
+
[data-file-tree-virtualized-scroll='true'] {
|
|
1825
|
+
padding-inline: 0 16px;
|
|
1826
|
+
}
|
|
1827
|
+
|
|
1828
|
+
[data-file-tree-search-input] {
|
|
1829
|
+
font-size: 16px;
|
|
1830
|
+
}
|
|
1831
|
+
`;function Cp(e){return e?.isDirectory()===!0}function wp(e){return e.nativeEvent.composedPath().some(e=>e instanceof Element&&e.getAttribute(`data-type`)===`item`)}function Tp(e){let t=e[0]||` `,n=e[1]||` `;return e===`??`?`untracked`:e===`!!`?`ignored`:t===`R`||n===`R`||t===`C`||n===`C`?`renamed`:t===`D`||n===`D`?`deleted`:t===`A`||n===`A`?`added`:`modified`}function Ep(e){return e.map(e=>({path:e.path,status:Tp(e.status)}))}function Dp(e,t){if(t.length===0)return e;let n=new Set(e),r=!1;for(let e of t)Tp(e.status)===`deleted`&&(!e.path||n.has(e.path)||(n.add(e.path),r=!0));return r?[...n]:e}function Op(e){let t=new Set;for(let n of e){let e=n.split(`/`).filter(Boolean);for(let n=1;n<e.length;n+=1)t.add(`${e.slice(0,n).join(`/`)}/`)}return Array.from(t).toSorted((e,t)=>t.split(`/`).length-e.split(`/`).length||t.length-e.length||t.localeCompare(e))}function kp({collapseAllRevision:e,gitStatus:t,paths:n,selectedPath:r,onSelectFile:i}){let a=q.useRef(new Set(n)),o=q.useRef(i),s=q.useRef(0);a.current=new Set(n),o.current=i;let{model:c}=zf({paths:n,flattenEmptyDirectories:!0,gitStatus:t,initialExpansion:1,initialSelectedPaths:r?[r]:[],onSelectionChange:e=>{let[t]=e;!t||!a.current.has(t)||o.current(t)},search:!0,unsafeCSS:Sp});q.useEffect(()=>{c.resetPaths(n)},[c,n]),q.useEffect(()=>{c.setGitStatus(t)},[t,c]),q.useEffect(()=>{if(!r)return;let e=c.getItem(r);if(e){for(let e of c.getSelectedPaths())e!==r&&c.getItem(e)?.deselect();e.select(),e.focus()}},[c,r]),q.useEffect(()=>{if(!(e<=0||e===s.current||n.length===0)){s.current=e;for(let e of Op(n)){let t=c.getItem(e);!Cp(t)||!t.isExpanded()||t.collapse()}c.focusNearestPath(r||c.getFocusedPath())}},[e,c,n,r]);let l=()=>{window.requestAnimationFrame(()=>{let e=c.getFocusedPath();!e||!a.current.has(e)||o.current(e)})};return(0,Y.jsx)(Rf,{model:c,className:`block h-full min-h-0 w-full overflow-hidden`,onClick:e=>{wp(e)&&l()},onKeyUp:e=>{e.key!==`Enter`&&e.key!==` `||wp(e)&&l()}})}function Ap(e){let t=(0,J.c)(61),{viewerContextId:n,cwd:r,active:i,activeFilePath:a,onCloseFile:o,onOpenFile:c,previewMode:u}=e,d=u===void 0?`external`:u,p=xt(r),[m,h]=q.useState(!1),[g,_]=q.useState(0),v=d===`inline`,y=v&&!!a,b=ee({...bp({viewerContextId:n,cwd:p}),enabled:!!(i&&n&&p),select:Np,notifyOnChangeProps:[`data`,`isPending`,`error`]}),x=re({viewerContextId:n,cwd:p,scope:`files`}),S=!!(i&&n&&p),w;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(w=[`data`],t[0]=w):w=t[0];let T;t[1]!==x||t[2]!==S?(T={...x,enabled:S,select:Mp,notifyOnChangeProps:w},t[1]=x,t[2]=S,t[3]=T):T=t[3];let E=ee(T),D=b.data??np,O=E.data??rp,k;t[4]!==O||t[5]!==D?(k=Dp(D,O),t[4]=O,t[5]=D,t[6]=k):k=t[6];let A=k,j;t[7]===O?j=t[8]:(j=Ep(O),t[7]=O,t[8]=j);let M=j,N=v?`relative flex flex-col`:`flex flex-col`,P;t[9]===N?P=t[10]:(P=s(`h-full min-h-0 overflow-hidden`,N),t[9]=N,t[10]=P);let F;t[11]===A.length?F=t[12]:(F=A.length.toLocaleString(),t[11]=A.length,t[12]=F);let I;t[13]===F?I=t[14]:(I=(0,Y.jsxs)(`div`,{className:`text-xs font-bold tracking-[0.04em] text-muted-foreground uppercase`,children:[F,` files`]}),t[13]=F,t[14]=I);let L=A.length===0,R;t[15]===_?R=t[16]:(R=()=>{_(jp)},t[15]=_,t[16]=R);let z;t[17]===Symbol.for(`react.memo_cache_sentinel`)?(z=(0,Y.jsx)(fe,{className:`size-4`}),t[17]=z):z=t[17];let B;t[18]!==L||t[19]!==R?(B=(0,Y.jsx)(f,{title:`Collapse all folders`,children:(0,Y.jsx)(qt,{type:`button`,variant:`outline`,size:`icon`,"aria-label":`Collapse all folders`,disabled:L,onClick:R,children:z})}),t[18]=L,t[19]=R,t[20]=B):B=t[20];let V;t[21]===h?V=t[22]:(V=(0,Y.jsx)(qt,{type:`button`,variant:`outline`,onClick:()=>{h(!0)},children:`Open File`}),t[21]=h,t[22]=V);let H;t[23]!==B||t[24]!==V?(H=(0,Y.jsxs)(`div`,{className:`flex shrink-0 items-center gap-2`,children:[B,V]}),t[23]=B,t[24]=V,t[25]=H):H=t[25];let U;t[26]!==I||t[27]!==H?(U=(0,Y.jsxs)(`div`,{className:`flex shrink-0 items-center justify-between gap-2 border-b border-border/70 p-2`,children:[I,H]}),t[26]=I,t[27]=H,t[28]=U):U=t[28];let te;t[29]!==a||t[30]!==g||t[31]!==b.data||t[32]!==b.error||t[33]!==b.isPending||t[34]!==M||t[35]!==p||t[36]!==c||t[37]!==A||t[38]!==n?(te=(0,Y.jsx)(`div`,{className:`min-h-0 flex-1 overflow-hidden p-2`,children:p?n?b.isPending&&b.data===void 0?(0,Y.jsxs)(tp,{children:[(0,Y.jsx)(C,{}),` Loading files…`]}):b.error?(0,Y.jsx)(tp,{tone:`destructive`,children:ft(b.error,`Failed to load files`)}):A.length>0?(0,Y.jsx)(kp,{collapseAllRevision:g,gitStatus:M,paths:A,selectedPath:a,onSelectFile:c}):(0,Y.jsx)(tp,{children:`No files found.`}):(0,Y.jsx)(tp,{children:`Waiting for viewer context…`}):(0,Y.jsx)(tp,{children:`No directory selected.`})}),t[29]=a,t[30]=g,t[31]=b.data,t[32]=b.error,t[33]=b.isPending,t[34]=M,t[35]=p,t[36]=c,t[37]=A,t[38]=n,t[39]=te):te=t[39];let ne;t[40]!==U||t[41]!==te?(ne=(0,Y.jsxs)(`div`,{className:`flex min-h-0 flex-1 flex-col overflow-hidden bg-background`,children:[U,te]}),t[40]=U,t[41]=te,t[42]=ne):ne=t[42];let W;t[43]!==i||t[44]!==a||t[45]!==v||t[46]!==p||t[47]!==o||t[48]!==y||t[49]!==n?(W=v?(0,Y.jsxs)(`div`,{"aria-hidden":!y,inert:!y,className:s(`absolute inset-0 z-20 flex min-h-0 flex-col overflow-hidden bg-background transition-transform duration-200 ease-out`,y?`translate-x-0 shadow-xl`:`pointer-events-none translate-x-full`),children:[(0,Y.jsxs)(`div`,{className:`flex h-10 shrink-0 items-center gap-2 border-b border-border/70 px-2 text-xs font-medium text-muted-foreground`,children:[(0,Y.jsxs)(`button`,{type:`button`,"aria-label":`Back to file tree`,className:`inline-flex h-8 shrink-0 items-center gap-1.5 rounded-md px-2 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,onClick:o,children:[(0,Y.jsx)(l,{className:`size-4`}),(0,Y.jsx)(`span`,{children:`Files`})]}),(0,Y.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,title:a,children:a})]}),(0,Y.jsx)(`div`,{className:`min-h-0 flex-1 overflow-hidden`,children:(0,Y.jsx)(Fp,{viewerContextId:n,cwd:p,active:i&&y,path:a})})]}):null,t[43]=i,t[44]=a,t[45]=v,t[46]=p,t[47]=o,t[48]=y,t[49]=n,t[50]=W):W=t[50];let G;t[51]!==c||t[52]!==m||t[53]!==A||t[54]!==h?(G=(0,Y.jsx)(Pp,{open:m,onOpenChange:h,paths:A,onOpenFile:c}),t[51]=c,t[52]=m,t[53]=A,t[54]=h,t[55]=G):G=t[55];let ie;return t[56]!==ne||t[57]!==W||t[58]!==G||t[59]!==P?(ie=(0,Y.jsxs)(`div`,{className:P,children:[ne,W,G]}),t[56]=ne,t[57]=W,t[58]=G,t[59]=P,t[60]=ie):ie=t[60],ie}function jp(e){return e+1}function Mp(e){return e.files??[]}function Np(e){return e.paths}function Pp(e){let t=(0,J.c)(38),{open:n,onOpenChange:r,paths:i,onOpenFile:a}=e,[o,c]=q.useState(``),l=tt(),u,d;t[0]===n?(u=t[1],d=t[2]):(u=()=>{n||c(``)},d=[n],t[0]=n,t[1]=u,t[2]=d),q.useEffect(u,d);let f=l&&`min-h-0 flex-1`,p;t[3]===f?p=t[4]:(p=s(f),t[3]=f,t[4]=p);let m;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(m=(0,Y.jsx)($f,{}),t[5]=m):m=t[5];let h;t[6]===o?h=t[7]:(h=(0,Y.jsx)(R,{value:o,onValueChange:c,placeholder:`Search files…`,className:`text-base md:text-sm`}),t[6]=o,t[7]=h);let g=l&&`max-h-none min-h-0 flex-1`,_;t[8]===g?_=t[9]:(_=s(g),t[8]=g,t[9]=_);let v;t[10]===Symbol.for(`react.memo_cache_sentinel`)?(v=(0,Y.jsx)(O,{children:`No files found.`}),t[10]=v):v=t[10];let y;if(t[11]!==r||t[12]!==a||t[13]!==i){let e;t[15]!==r||t[16]!==a?(e=e=>(0,Y.jsxs)(xe,{value:e,keywords:[e],onSelect:()=>{a(e),r(!1)},children:[(0,Y.jsx)(ep,{path:e}),(0,Y.jsx)(`span`,{className:`min-w-0 truncate font-mono text-xs`,children:e})]},e),t[15]=r,t[16]=a,t[17]=e):e=t[17],y=i.map(e),t[11]=r,t[12]=a,t[13]=i,t[14]=y}else y=t[14];let b;t[18]===y?b=t[19]:(b=(0,Y.jsx)(Ce,{heading:`Files`,children:y}),t[18]=y,t[19]=b);let x;t[20]!==b||t[21]!==_?(x=(0,Y.jsxs)(Te,{className:_,children:[v,b]}),t[20]=b,t[21]=_,t[22]=x):x=t[22];let S;t[23]!==x||t[24]!==p||t[25]!==h?(S=(0,Y.jsxs)(ge,{shouldFilter:!0,className:p,children:[m,h,x]}),t[23]=x,t[24]=p,t[25]=h,t[26]=S):S=t[26];let C=S;if(l){let e;t[27]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsxs)(B,{children:[(0,Y.jsx)(G,{children:`Open Files`}),(0,Y.jsx)(pe,{children:`Search project files to open.`})]}),t[27]=e):e=t[27];let i;t[28]===C?i=t[29]:(i=(0,Y.jsxs)(le,{className:`max-h-[90svh] overflow-hidden`,children:[e,(0,Y.jsx)(`div`,{className:`flex min-h-0 flex-1 flex-col overflow-hidden px-4 pb-4`,children:C})]}),t[28]=C,t[29]=i);let a;return t[30]!==r||t[31]!==n||t[32]!==i?(a=(0,Y.jsx)(oe,{open:n,onOpenChange:r,restorePromptFocusOnClose:!1,children:i}),t[30]=r,t[31]=n,t[32]=i,t[33]=a):a=t[33],a}let w;return t[34]!==C||t[35]!==r||t[36]!==n?(w=(0,Y.jsx)(It,{open:n,onOpenChange:r,title:`Open Files`,description:`Search project files to open.`,children:C}),t[34]=C,t[35]=r,t[36]=n,t[37]=w):w=t[37],w}function Fp(e){let t=(0,J.c)(37),{viewerContextId:n,cwd:r,active:i,path:a}=e,o,s,c;t[0]!==r||t[1]!==a||t[2]!==n?(o=xt(r),c=ee,s=xp({viewerContextId:n,cwd:o,path:a}),t[0]=r,t[1]=a,t[2]=n,t[3]=o,t[4]=s,t[5]=c):(o=t[3],s=t[4],c=t[5]);let l=!!(i&&n&&o&&a),u;t[6]===Symbol.for(`react.memo_cache_sentinel`)?(u=[`data`,`isPending`,`error`],t[6]=u):u=t[6];let d;t[7]!==s||t[8]!==l?(d={...s,enabled:l,notifyOnChangeProps:u},t[7]=s,t[8]=l,t[9]=d):d=t[9];let f=c(d),p=f.data?.content??``,m;t[10]===a?m=t[11]:(m=hp(a),t[10]=a,t[11]=m);let h=m,g;t[12]===a?g=t[13]:(g=gp(a),t[12]=a,t[13]=g);let _=g,v;t[14]===Symbol.for(`react.memo_cache_sentinel`)?(v={},t[14]=v):v=t[14];let[y,b]=q.useState(v),x=_?y[a]||`preview`:`source`,S=_&&x===`preview`,[w,T]=q.useReducer(vp,null),E,D;if(t[15]!==i||t[16]!==p||t[17]!==h||t[18]!==S?(D=()=>{let e=!1;if(!i||!p||!h||S){T({type:`clear`});return}return T({type:`clear`}),yp(p,h).then(t=>{e||T({type:`loaded`,payload:t})}).catch(()=>{e||T({type:`unavailable`})}),()=>{e=!0}},E=[i,p,h,S],t[15]=i,t[16]=p,t[17]=h,t[18]=S,t[19]=E,t[20]=D):(E=t[19],D=t[20]),q.useEffect(D,E),!a){let e;return t[21]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(`div`,{className:`flex h-full items-center justify-center p-6 text-center text-sm text-muted-foreground`,children:`Select a file to preview it.`}),t[21]=e):e=t[21],e}let O;t[22]!==_||t[23]!==x||t[24]!==a?(O=_?(0,Y.jsxs)(`div`,{className:`flex shrink-0 items-center justify-between gap-3 border-b border-border/70 px-3 py-2`,children:[(0,Y.jsx)(`div`,{className:`truncate text-xs font-medium text-muted-foreground`,children:`Markdown`}),(0,Y.jsxs)(Jf,{variant:`outline`,value:[x],onValueChange:e=>{let t=e[0];(t===`preview`||t===`source`)&&b(e=>({...e,[a]:t}))},children:[(0,Y.jsx)(Yf,{value:`preview`,children:`Preview`}),(0,Y.jsx)(Yf,{value:`source`,children:`Source`})]})]}):null,t[22]=_,t[23]=x,t[24]=a,t[25]=O):O=t[25];let k;t[26]!==p||t[27]!==f.data||t[28]!==f.error||t[29]!==f.isPending||t[30]!==w||t[31]!==h||t[32]!==S?(k=(0,Y.jsx)(`div`,{className:`min-h-0 flex-1 overflow-auto`,children:f.isPending&&!f.data?(0,Y.jsx)(`div`,{className:`p-4`,children:(0,Y.jsxs)(tp,{children:[(0,Y.jsx)(C,{}),` Loading file…`]})}):f.error?(0,Y.jsx)(`div`,{className:`p-4`,children:(0,Y.jsx)(tp,{tone:`destructive`,children:ft(f.error,`Failed to load file`)})}):S?(0,Y.jsx)(`div`,{className:`min-h-full p-4 text-foreground`,children:(0,Y.jsx)(at,{text:p})}):_p(w)?(0,Y.jsx)(`pre`,{className:`m-0 min-h-full p-4 font-mono text-[13px] leading-5 whitespace-pre-wrap text-foreground`,children:(0,Y.jsx)(He,{html:w.html,language:h})}):(0,Y.jsx)(`pre`,{className:`m-0 min-h-full p-4 font-mono text-[13px] leading-5 whitespace-pre-wrap text-foreground`,children:(0,Y.jsx)(`code`,{children:p})})}),t[26]=p,t[27]=f.data,t[28]=f.error,t[29]=f.isPending,t[30]=w,t[31]=h,t[32]=S,t[33]=k):k=t[33];let A;return t[34]!==O||t[35]!==k?(A=(0,Y.jsxs)(`div`,{className:`flex h-full min-h-0 flex-col bg-background`,children:[O,k]}),t[34]=O,t[35]=k,t[36]=A):A=t[36],A}function Ip(e){let t=(0,J.c)(62),{active:n,dragging:r,dragListeners:i,dragAttributes:a,index:o,onActiveFileChange:c,onActiveTabChange:l,onCloseAllFiles:u,onCloseFile:d,onCloseFilesToRight:f,onCloseOtherFiles:p,path:m,preview:h,tabCount:g}=e,_=r===void 0?!1:r,v=n&&`bg-muted text-foreground`,y=_&&`border-transparent shadow-none ring-0`,b;t[0]!==v||t[1]!==y?(b=s(`inline-flex h-8 shrink-0 items-center rounded-md border border-transparent text-sm font-medium text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,v,y),t[0]=v,t[1]=y,t[2]=b):b=t[2];let x;t[3]!==c||t[4]!==l||t[5]!==m?(x=()=>{l(`files`),c?.(m)},t[3]=c,t[4]=l,t[5]=m,t[6]=x):x=t[6];let S;t[7]===m?S=t[8]:(S=(0,Y.jsx)(ep,{path:m}),t[7]=m,t[8]=S);let C=h&&`italic`,w;t[9]===C?w=t[10]:(w=s(`block min-w-0 truncate`,C),t[9]=C,t[10]=w);let T;t[11]===m?T=t[12]:(T=lm(m),t[11]=m,t[12]=T);let E;t[13]!==w||t[14]!==T?(E=(0,Y.jsx)(`span`,{className:w,children:T}),t[13]=w,t[14]=T,t[15]=E):E=t[15];let D;t[16]!==m||t[17]!==E||t[18]!==x||t[19]!==S?(D=(0,Y.jsxs)(`button`,{type:`button`,title:m,className:`flex min-w-0 flex-1 items-center gap-1.5 px-2.5 text-left`,onClick:x,children:[S,E]}),t[16]=m,t[17]=E,t[18]=x,t[19]=S,t[20]=D):D=t[20];let O=`Close ${m}`,k;t[21]!==d||t[22]!==m?(k=()=>{d?.(m)},t[21]=d,t[22]=m,t[23]=k):k=t[23];let A;t[24]===Symbol.for(`react.memo_cache_sentinel`)?(A=(0,Y.jsx)($t,{className:`size-3`}),t[24]=A):A=t[24];let j;t[25]!==O||t[26]!==k?(j=(0,Y.jsx)(`button`,{type:`button`,"aria-label":O,className:`mr-1 inline-flex size-4 shrink-0 items-center justify-center rounded-sm text-muted-foreground hover:bg-muted hover:text-foreground`,onClick:k,children:A}),t[25]=O,t[26]=k,t[27]=j):j=t[27];let M;t[28]!==a||t[29]!==i||t[30]!==D||t[31]!==j||t[32]!==b?(M=(0,Y.jsxs)(`div`,{className:b,...a,...i,children:[D,j]}),t[28]=a,t[29]=i,t[30]=D,t[31]=j,t[32]=b,t[33]=M):M=t[33];let N=M,P;t[34]===N?P=t[35]:(P=(0,Y.jsx)(ye,{render:N}),t[34]=N,t[35]=P);let F;t[36]!==d||t[37]!==m?(F=(0,Y.jsx)(Pt,{onClick:()=>d?.(m),children:`Close`}),t[36]=d,t[37]=m,t[38]=F):F=t[38];let I=g<=1,L;t[39]!==p||t[40]!==m?(L=()=>p?.(m),t[39]=p,t[40]=m,t[41]=L):L=t[41];let R;t[42]!==I||t[43]!==L?(R=(0,Y.jsx)(Pt,{disabled:I,onClick:L,children:`Close others`}),t[42]=I,t[43]=L,t[44]=R):R=t[44];let z=o>=g-1,B;t[45]!==f||t[46]!==m?(B=()=>f?.(m),t[45]=f,t[46]=m,t[47]=B):B=t[47];let V;t[48]!==z||t[49]!==B?(V=(0,Y.jsx)(Pt,{disabled:z,onClick:B,children:`Close to the right`}),t[48]=z,t[49]=B,t[50]=V):V=t[50];let ee;t[51]===Symbol.for(`react.memo_cache_sentinel`)?(ee=(0,Y.jsx)(Mt,{}),t[51]=ee):ee=t[51];let H;t[52]===u?H=t[53]:(H=(0,Y.jsx)(Pt,{onClick:()=>u?.(),children:`Close all`}),t[52]=u,t[53]=H);let U;t[54]!==F||t[55]!==R||t[56]!==V||t[57]!==H?(U=(0,Y.jsxs)(Ne,{className:`w-44`,children:[F,R,V,ee,H]}),t[54]=F,t[55]=R,t[56]=V,t[57]=H,t[58]=U):U=t[58];let te;return t[59]!==P||t[60]!==U?(te=(0,Y.jsxs)(Je,{children:[P,U]}),t[59]=P,t[60]=U,t[61]=te):te=t[61],te}function Lp(e){return`file:${e}`}function Rp(e){return`commit-diff:${e}`}function zp(e){return e.startsWith(`file:`)?e.slice(5):``}function Bp(e){return e.startsWith(`commit-diff:`)?e.slice(12):``}function Vp(e){let t=(0,J.c)(20),n;t[0]===e.path?n=t[1]:(n=Lp(e.path),t[0]=e.path,t[1]=n);let r;t[2]===n?r=t[3]:(r={id:n},t[2]=n,t[3]=r);let{attributes:i,isDragging:a,listeners:o,setNodeRef:c,transform:l,transition:u}=je(r),d;t[4]===l?d=t[5]:(d=dt.Transform.toString(l),t[4]=l,t[5]=d);let f;t[6]!==d||t[7]!==u?(f={transform:d,transition:u},t[6]=d,t[7]=u,t[8]=f):f=t[8];let p=f,m=a&&`opacity-0`,h;t[9]===m?h=t[10]:(h=s(`shrink-0`,m),t[9]=m,t[10]=h);let g;t[11]!==i||t[12]!==o||t[13]!==e?(g=(0,Y.jsx)(Ip,{...e,dragAttributes:i,dragListeners:o}),t[11]=i,t[12]=o,t[13]=e,t[14]=g):g=t[14];let _;return t[15]!==c||t[16]!==p||t[17]!==h||t[18]!==g?(_=(0,Y.jsx)(`div`,{ref:c,style:p,className:h,children:g}),t[15]=c,t[16]=p,t[17]=h,t[18]=g,t[19]=_):_=t[19],_}function Hp(e){let t=(0,J.c)(57),{active:n,dragging:r,dragListeners:i,dragAttributes:a,index:o,onActiveCommitDiffChange:c,onActiveTabChange:l,onCloseAllCommitDiffs:u,onCloseCommitDiff:d,onCloseCommitDiffsToRight:f,onCloseOtherCommitDiffs:p,tab:m,tabCount:h}=e,g=r===void 0?!1:r,_=n&&`bg-muted text-foreground`,v=g&&`border-transparent shadow-none ring-0`,y;t[0]!==_||t[1]!==v?(y=s(`inline-flex h-8 shrink-0 items-center rounded-md border border-transparent text-sm font-medium text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,_,v),t[0]=_,t[1]=v,t[2]=y):y=t[2];let b;t[3]!==c||t[4]!==l||t[5]!==m.key?(b=()=>{c?.(m.key),l(`commit-diff`)},t[3]=c,t[4]=l,t[5]=m.key,t[6]=b):b=t[6];let x;t[7]===m.path?x=t[8]:(x=m.path?(0,Y.jsx)(ep,{path:m.path}):(0,Y.jsx)(gn,{className:`size-4 shrink-0 text-muted-foreground`}),t[7]=m.path,t[8]=x);let S;t[9]===m.title?S=t[10]:(S=(0,Y.jsx)(`span`,{className:`block min-w-0 truncate`,children:m.title}),t[9]=m.title,t[10]=S);let C;t[11]!==b||t[12]!==x||t[13]!==S||t[14]!==m.title?(C=(0,Y.jsxs)(`button`,{type:`button`,title:m.title,className:`flex min-w-0 flex-1 items-center gap-1.5 px-2.5 text-left`,onClick:b,children:[x,S]}),t[11]=b,t[12]=x,t[13]=S,t[14]=m.title,t[15]=C):C=t[15];let w=`Close ${m.title}`,T;t[16]!==d||t[17]!==m.key?(T=()=>{d?.(m.key)},t[16]=d,t[17]=m.key,t[18]=T):T=t[18];let E;t[19]===Symbol.for(`react.memo_cache_sentinel`)?(E=(0,Y.jsx)($t,{className:`size-3`}),t[19]=E):E=t[19];let D;t[20]!==T||t[21]!==w?(D=(0,Y.jsx)(`button`,{type:`button`,"aria-label":w,className:`mr-1 inline-flex size-4 shrink-0 items-center justify-center rounded-sm text-muted-foreground hover:bg-muted hover:text-foreground`,onClick:T,children:E}),t[20]=T,t[21]=w,t[22]=D):D=t[22];let O;t[23]!==a||t[24]!==i||t[25]!==D||t[26]!==y||t[27]!==C?(O=(0,Y.jsxs)(`div`,{className:y,...a,...i,children:[C,D]}),t[23]=a,t[24]=i,t[25]=D,t[26]=y,t[27]=C,t[28]=O):O=t[28];let k=O,A;t[29]===k?A=t[30]:(A=(0,Y.jsx)(ye,{render:k}),t[29]=k,t[30]=A);let j;t[31]!==d||t[32]!==m.key?(j=(0,Y.jsx)(Pt,{onClick:()=>d?.(m.key),children:`Close`}),t[31]=d,t[32]=m.key,t[33]=j):j=t[33];let M=h<=1,N;t[34]!==p||t[35]!==m.key?(N=()=>p?.(m.key),t[34]=p,t[35]=m.key,t[36]=N):N=t[36];let P;t[37]!==M||t[38]!==N?(P=(0,Y.jsx)(Pt,{disabled:M,onClick:N,children:`Close others`}),t[37]=M,t[38]=N,t[39]=P):P=t[39];let F=o>=h-1,I;t[40]!==f||t[41]!==m.key?(I=()=>f?.(m.key),t[40]=f,t[41]=m.key,t[42]=I):I=t[42];let L;t[43]!==F||t[44]!==I?(L=(0,Y.jsx)(Pt,{disabled:F,onClick:I,children:`Close to the right`}),t[43]=F,t[44]=I,t[45]=L):L=t[45];let R;t[46]===Symbol.for(`react.memo_cache_sentinel`)?(R=(0,Y.jsx)(Mt,{}),t[46]=R):R=t[46];let z;t[47]===u?z=t[48]:(z=(0,Y.jsx)(Pt,{onClick:()=>u?.(),children:`Close all`}),t[47]=u,t[48]=z);let B;t[49]!==j||t[50]!==P||t[51]!==L||t[52]!==z?(B=(0,Y.jsxs)(Ne,{className:`w-44`,children:[j,P,L,R,z]}),t[49]=j,t[50]=P,t[51]=L,t[52]=z,t[53]=B):B=t[53];let V;return t[54]!==A||t[55]!==B?(V=(0,Y.jsxs)(Je,{children:[A,B]}),t[54]=A,t[55]=B,t[56]=V):V=t[56],V}function Up(e){let t=(0,J.c)(20),n;t[0]===e.tab.key?n=t[1]:(n=Rp(e.tab.key),t[0]=e.tab.key,t[1]=n);let r;t[2]===n?r=t[3]:(r={id:n},t[2]=n,t[3]=r);let{attributes:i,isDragging:a,listeners:o,setNodeRef:c,transform:l,transition:u}=je(r),d;t[4]===l?d=t[5]:(d=dt.Transform.toString(l),t[4]=l,t[5]=d);let f;t[6]!==d||t[7]!==u?(f={transform:d,transition:u},t[6]=d,t[7]=u,t[8]=f):f=t[8];let p=f,m=a&&`opacity-0`,h;t[9]===m?h=t[10]:(h=s(`shrink-0`,m),t[9]=m,t[10]=h);let g;t[11]!==i||t[12]!==o||t[13]!==e?(g=(0,Y.jsx)(Hp,{...e,dragAttributes:i,dragListeners:o}),t[11]=i,t[12]=o,t[13]=e,t[14]=g):g=t[14];let _;return t[15]!==c||t[16]!==p||t[17]!==h||t[18]!==g?(_=(0,Y.jsx)(`div`,{ref:c,style:p,className:h,children:g}),t[15]=c,t[16]=p,t[17]=h,t[18]=g,t[19]=_):_=t[19],_}function Wp(e){let t=(0,J.c)(6),{activeFilePath:n,activePath:r,filePreviewPath:i,fileTabs:a}=e,o=a.indexOf(r);if(o<0)return null;let s=n===r,c=i===r,l;return t[0]!==r||t[1]!==a.length||t[2]!==o||t[3]!==s||t[4]!==c?(l=(0,Y.jsx)(Ip,{active:s,dragging:!0,index:o,onActiveTabChange:Gp,path:r,preview:c,tabCount:a.length}),t[0]=r,t[1]=a.length,t[2]=o,t[3]=s,t[4]=c,t[5]=l):l=t[5],l}function Gp(){}function Kp(e){let t=(0,J.c)(3),{active:n,tab:r}=e,i;return t[0]!==n||t[1]!==r?(i=(0,Y.jsx)(Hp,{active:n,dragging:!0,index:0,onActiveTabChange:qp,tab:r,tabCount:1}),t[0]=n,t[1]=r,t[2]=i):i=t[2],i}function qp(){}function Jp(e){let t=(0,J.c)(40),{activeCommitDiffKey:n,activeFilePath:r,activeTab:i,commitDiffTabs:a,filePreviewPath:o,fileTabs:c,onActiveCommitDiffChange:l,onActiveFileChange:u,onActiveTabChange:d,onCloseAllCommitDiffs:p,onCloseAllFiles:m,onCloseCommitDiff:h,onCloseCommitDiffsToRight:g,onCloseFile:_,onCloseFilesToRight:v,onCloseOtherCommitDiffs:y,onCloseOtherFiles:b,onOpenFileDialog:x,onReorderCommitDiffs:S,onReorderFiles:C,showFiles:w,showHistory:E,showReview:D}=e,O=n===void 0?``:n,k=a===void 0?ap:a,A=o===void 0?``:o,j=c===void 0?ip:c,M=w===void 0?!1:w,N=E===void 0?!1:E,P=D===void 0?!1:D,F;t[0]!==i||t[1]!==d?(F=e=>{let{active:t,label:n,value:r}=e,a=t??i===r;return(0,Y.jsx)(`button`,{type:`button`,"aria-pressed":a,className:s(`inline-flex h-8 shrink-0 items-center rounded-md border border-transparent px-2.5 text-sm font-medium text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,a&&`bg-muted text-foreground`),onClick:()=>{d(r)},children:n},r)},t[0]=i,t[1]=d,t[2]=F):F=t[2];let I=F,L=j.map(Lp),R=k.map(Qp),z=[...L,...R],B=new Set(z),V;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(V=[],t[3]=V):V=t[3];let[ee,U]=q.useState(V),[te,ne]=q.useState(``),re=[...ee.filter(e=>B.has(e)),...z.filter(e=>!ee.includes(e))],W=j.length>0,G=k.length>0,ie;t[4]!==k||t[5]!==W?(ie=W||k.some(Zp),t[4]=k,t[5]=W,t[6]=ie):ie=t[6];let ae=ie,oe=re.length>0,se;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(se={activationConstraint:{distance:6}},t[7]=se):se=t[7];let ce=Fe(Xe(Ct,se)),le=z.join(`\0`),ue;t[8]===le?ue=t[9]:(ue=[le],t[8]=le,t[9]=ue),q.useEffect(()=>{U(e=>{let t=[...e.filter(e=>B.has(e)),...z.filter(t=>!e.includes(t))];return t.length===e.length&&t.every((t,n)=>t===e[n])?e:t})},ue);let de;t[10]===Symbol.for(`react.memo_cache_sentinel`)?(de=e=>{ne(String(e.active.id))},t[10]=de):de=t[10];let K=de,fe=e=>{let t=String(e.active.id),n=e.over?String(e.over.id):``;if(!t||!n||t===n){ne(``);return}let r=re.indexOf(t),i=re.indexOf(n);if(r===-1||i===-1){ne(``);return}let a=ke(re,r,i);U(a),C?.(a.flatMap(Xp)),S?.(a.flatMap(Yp)),ne(``)},pe;t[11]===Symbol.for(`react.memo_cache_sentinel`)?(pe=()=>{ne(``)},t[11]=pe):pe=t[11];let me=pe,he;t[12]===ae?he=t[13]:(he=ae?(0,Y.jsx)($f,{}):null,t[12]=ae,t[13]=he);let ge;t[14]!==I||t[15]!==P?(ge=P?I({label:`Changes`,value:`review`}):null,t[14]=I,t[15]=P,t[16]=ge):ge=t[16];let _e;t[17]!==I||t[18]!==N?(_e=N?I({label:`History`,value:`history`}):null,t[17]=I,t[18]=N,t[19]=_e):_e=t[19];let ve;t[20]!==r||t[21]!==i||t[22]!==W||t[23]!==I||t[24]!==M?(ve=!W||M?I({active:i===`files`&&(!W||!r),label:`Files`,value:`files`}):null,t[20]=r,t[21]=i,t[22]=W,t[23]=I,t[24]=M,t[25]=ve):ve=t[25];let ye;t[26]!==G||t[27]!==W?(ye=W||G?(0,Y.jsx)(`span`,{className:`mx-1 shrink-0 text-xs text-border`,"aria-hidden":`true`,children:`|`}):null,t[26]=G,t[27]=W,t[28]=ye):ye=t[28];let be=oe?(0,Y.jsxs)(T,{sensors:ce,collisionDetection:ct,onDragStart:K,onDragEnd:fe,onDragCancel:me,children:[(0,Y.jsx)(H,{items:re,strategy:De,children:re.map(e=>{let t=zp(e);if(t)return(0,Y.jsx)(Vp,{active:i===`files`&&r===t,index:j.indexOf(t),onActiveFileChange:u,onActiveTabChange:d,onCloseAllFiles:m,onCloseFile:_,onCloseFilesToRight:v,onCloseOtherFiles:b,path:t,preview:A===t,tabCount:j.length},e);let n=Bp(e),a=k.find(e=>e.key===n);return a?(0,Y.jsx)(Up,{active:i===`commit-diff`&&O===a.key,index:k.findIndex(e=>e.key===a.key),onActiveCommitDiffChange:l,onActiveTabChange:d,onCloseAllCommitDiffs:p,onCloseCommitDiff:h,onCloseCommitDiffsToRight:g,onCloseOtherCommitDiffs:y,tab:a,tabCount:k.length},e):null})}),(0,Y.jsx)(Ue,{dropAnimation:null,modifiers:dp,children:zp(te)?(0,Y.jsx)(Wp,{activeFilePath:r,activePath:zp(te),filePreviewPath:A,fileTabs:j}):Bp(te)?(0,Y.jsx)(Kp,{active:i===`commit-diff`&&O===Bp(te),tab:k.find(e=>e.key===Bp(te))||k[0]}):null})]}):null,xe;t[29]!==W||t[30]!==x?(xe=W?(0,Y.jsx)(f,{title:`Open another file`,children:(0,Y.jsx)(`button`,{type:`button`,"aria-label":`Open another file`,className:`inline-flex size-7 shrink-0 items-center justify-center rounded-md border border-transparent text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,onClick:x,children:`+`})}):null,t[29]=W,t[30]=x,t[31]=xe):xe=t[31];let Se;return t[32]!==he||t[33]!==ge||t[34]!==_e||t[35]!==ve||t[36]!==ye||t[37]!==be||t[38]!==xe?(Se=(0,Y.jsxs)(`div`,{className:`flex shrink-0 items-center gap-2 overflow-x-auto border-b border-border/70 bg-background p-2`,children:[he,ge,_e,ve,ye,be,xe]}),t[32]=he,t[33]=ge,t[34]=_e,t[35]=ve,t[36]=ye,t[37]=be,t[38]=xe,t[39]=Se):Se=t[39],Se}function Yp(e){let t=Bp(e);return t?[t]:[]}function Xp(e){let t=zp(e);return t?[t]:[]}function Zp(e){return!!e.path}function Qp(e){return Rp(e.key)}function $p(e){return Number.isFinite(e)?Math.round(Math.min(up,Math.max(lp,e))):cp}function em(){let e=b(u);return e==null?cp:$p(Number(e))}var tm=new Set;function nm(e){return tm.add(e),()=>{tm.delete(e)}}function rm(){return cp}function im(e){m(u,String($p(e)));for(let e of tm)e()}function am(e){let t=(0,J.c)(6),{onResize:n,width:r}=e,i;t[0]===n?i=t[1]:(i=e=>{n($p(e))},t[0]=n,t[1]=i);let a=i,o;t[2]===Symbol.for(`react.memo_cache_sentinel`)?(o=s(`absolute inset-y-0 right-0 z-20 w-3 translate-x-1/2 cursor-col-resize touch-none bg-transparent outline-hidden after:absolute after:inset-y-0 after:left-1/2 after:w-px after:bg-border/70 focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1`,ot),t[2]=o):o=t[2];let c;return t[3]!==a||t[4]!==r?(c=(0,Y.jsx)(`div`,{role:`separator`,"aria-label":`Resize file tree`,"aria-orientation":`vertical`,tabIndex:0,className:o,onKeyDown:e=>{if(e.key!==`ArrowLeft`&&e.key!==`ArrowRight`)return;e.preventDefault();let t=e.shiftKey?48:16;a(r+(e.key===`ArrowRight`?t:-t))},onPointerDown:e=>{if(e.button!==0)return;e.preventDefault();let t=e.clientX,n=r,i=document.body.style.cursor,o=document.body.style.userSelect,s=j(`col-resize`);Object.assign(document.body.style,{cursor:`col-resize`,userSelect:`none`});let c=e=>{a(n+e.clientX-t)},l=()=>{s(),Object.assign(document.body.style,{cursor:i,userSelect:o}),document.removeEventListener(`pointermove`,c),document.removeEventListener(`pointerup`,l),document.removeEventListener(`pointercancel`,l)};document.addEventListener(`pointermove`,c),document.addEventListener(`pointerup`,l),document.addEventListener(`pointercancel`,l)}}),t[3]=a,t[4]=r,t[5]=c):c=t[5],c}function om(e){let t=(0,J.c)(15),{viewerContextId:n,cwd:r,active:i,activeFilePath:a,onOpenFile:o,previewMode:s}=e,c=q.useSyncExternalStore(nm,em,rm),l=cm,u=`${c}px`,d;t[0]===u?d=t[1]:(d={width:u,maxWidth:`70%`},t[0]=u,t[1]=d);let f;t[2]!==i||t[3]!==a||t[4]!==r||t[5]!==o||t[6]!==s||t[7]!==n?(f=(0,Y.jsx)(`div`,{className:`h-full min-h-0 overflow-hidden`,children:(0,Y.jsx)(Ap,{viewerContextId:n,cwd:r,active:i,activeFilePath:a,onCloseFile:sm,onOpenFile:o,previewMode:s})}),t[2]=i,t[3]=a,t[4]=r,t[5]=o,t[6]=s,t[7]=n,t[8]=f):f=t[8];let p;t[9]===c?p=t[10]:(p=(0,Y.jsx)(am,{width:c,onResize:l}),t[9]=c,t[10]=p);let m;return t[11]!==d||t[12]!==f||t[13]!==p?(m=(0,Y.jsxs)(`div`,{className:`relative min-h-0 shrink-0 overflow-visible border-r border-border/70`,style:d,children:[f,p]}),t[11]=d,t[12]=f,t[13]=p,t[14]=m):m=t[14],m}function sm(){}function cm(e){im(e)}function lm(e){return e.split(`/`).filter(Boolean).at(-1)||e}function um(e){let t=(0,J.c)(30),{fileTreeCollapsed:n,onFileTreeCollapsedChange:r,path:i}=e,a=n===void 0?!1:n,o,s,c,l,u,d,p,m,h;if(t[0]!==a||t[1]!==r||t[2]!==i){h=Symbol.for(`react.early_return_sentinel`);bb0:{let e=i.split(`/`).filter(Boolean);if(e.length===0){h=null;break bb0}p=`flex h-10 shrink-0 items-center gap-2 border-b border-border/70 bg-background px-3`,t[12]!==a||t[13]!==r?(m=r?(0,Y.jsx)(f,{title:a?`Show file tree`:`Collapse file tree`,children:(0,Y.jsx)(`button`,{type:`button`,"aria-pressed":a,"aria-label":a?`Show file tree`:`Collapse file tree`,className:`inline-flex size-7 shrink-0 items-center justify-center rounded-md border border-transparent text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,onClick:()=>{r(!a)},children:a?(0,Y.jsx)(xn,{className:`size-4`}):(0,Y.jsx)(bn,{className:`size-4`})})}):null,t[12]=a,t[13]=r,t[14]=m):m=t[14],d=`min-w-0 flex-1 overflow-x-auto`,s=Tn,u=i,o=En,c=`flex-nowrap gap-1 font-mono text-xs whitespace-nowrap`,l=e.map((t,n)=>{let r=n===e.length-1,i=`${n}:${t}`;return(0,Y.jsxs)(q.Fragment,{children:[n>0?(0,Y.jsx)(kn,{className:`text-muted-foreground/60`}):null,(0,Y.jsx)(Dn,{className:`min-w-0 shrink-0`,children:r?(0,Y.jsx)(On,{className:`max-w-80 truncate font-mono text-xs font-medium`,children:t}):(0,Y.jsx)(`span`,{className:`max-w-40 truncate text-muted-foreground`,children:t})})]},i)})}t[0]=a,t[1]=r,t[2]=i,t[3]=o,t[4]=s,t[5]=c,t[6]=l,t[7]=u,t[8]=d,t[9]=p,t[10]=m,t[11]=h}else o=t[3],s=t[4],c=t[5],l=t[6],u=t[7],d=t[8],p=t[9],m=t[10],h=t[11];if(h!==Symbol.for(`react.early_return_sentinel`))return h;let g;t[15]!==o||t[16]!==c||t[17]!==l?(g=(0,Y.jsx)(o,{className:c,children:l}),t[15]=o,t[16]=c,t[17]=l,t[18]=g):g=t[18];let _;t[19]!==s||t[20]!==u||t[21]!==g?(_=(0,Y.jsx)(s,{title:u,children:g}),t[19]=s,t[20]=u,t[21]=g,t[22]=_):_=t[22];let v;t[23]!==_||t[24]!==d?(v=(0,Y.jsx)(`div`,{className:d,children:_}),t[23]=_,t[24]=d,t[25]=v):v=t[25];let y;return t[26]!==v||t[27]!==p||t[28]!==m?(y=(0,Y.jsxs)(`div`,{className:p,children:[m,v]}),t[26]=v,t[27]=p,t[28]=m,t[29]=y):y=t[29],y}var dm={query:``,stage:`browse`,selectedValue:``,createBranchName:``};function fm(e,t){switch(t.type){case`reset`:return dm;case`set-query`:return{...e,query:t.query};case`set-stage`:return{...e,stage:t.stage};case`set-selected-value`:return{...e,selectedValue:t.selectedValue};case`set-create-branch-name`:return{...e,createBranchName:t.createBranchName}}}function pm(e){let n=(0,J.c)(2),{children:r}=e,i;return n[0]===r?i=n[1]:(i=(0,Y.jsx)(t,{children:r}),n[0]=r,n[1]=i),i}function mm({localBranches:e,remoteBranches:t}){let n=e.find(e=>e.current);return n?`local:${n.name}`:e[0]?`local:${e[0].name}`:t[0]?`remote:${t[0].name}`:`action:create`}function hm(e){let t=(0,J.c)(37),{query:n,selectedValue:r,localBranches:i,remoteBranches:a,localBranchNames:o,branchesPending:s,checkoutPending:c,isMobile:l,onQueryChange:u,onSelectedValueChange:d,onCreateStage:f,onSwitchLocalBranch:p,onSwitchRemoteBranch:m}=e,h;t[0]===f?h=t[1]:(h=e=>{_e(e.nativeEvent,`Control+N`)&&(e.preventDefault(),f())},t[0]=f,t[1]=h);let g;t[2]!==u||t[3]!==n?(g=(0,Y.jsx)(R,{value:n,onValueChange:u,placeholder:`Search branches`,className:`text-base md:text-sm`}),t[2]=u,t[3]=n,t[4]=g):g=t[4];let _=s?`Loading branches…`:`No branches found.`,v;t[5]===_?v=t[6]:(v=(0,Y.jsx)(O,{children:_}),t[5]=_,t[6]=v);let y;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(y=[`new`,`create`,`branch`],t[7]=y):y=t[7];let b,x;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(b=(0,Y.jsx)(ue,{className:`size-4 text-muted-foreground`}),x=(0,Y.jsx)(`span`,{className:`font-medium`,children:`Create new branch…`}),t[8]=b,t[9]=x):(b=t[8],x=t[9]);let S;t[10]===Symbol.for(`react.memo_cache_sentinel`)?(S=(0,Y.jsx)(I,{children:At(`Control+N`)}),t[10]=S):S=t[10];let C;t[11]===f?C=t[12]:(C=(0,Y.jsx)(Ce,{heading:`Actions`,children:(0,Y.jsxs)(xe,{value:`action:create`,keywords:y,onSelect:f,children:[b,x,S]})}),t[11]=f,t[12]=C);let w;t[13]!==s||t[14]!==c||t[15]!==i||t[16]!==p?(w=(0,Y.jsx)(gm,{branches:i,branchesPending:s,checkoutPending:c,onSwitchBranch:p}),t[13]=s,t[14]=c,t[15]=i,t[16]=p,t[17]=w):w=t[17];let T;t[18]!==c||t[19]!==o||t[20]!==m||t[21]!==a?(T=(0,Y.jsx)(_m,{branches:a,localBranchNames:o,checkoutPending:c,onSwitchBranch:m}),t[18]=c,t[19]=o,t[20]=m,t[21]=a,t[22]=T):T=t[22];let E;t[23]!==w||t[24]!==T||t[25]!==v||t[26]!==C?(E=(0,Y.jsxs)(Te,{className:`max-h-none min-h-0 flex-1 md:max-h-[min(70vh,28rem)]`,children:[v,C,w,T]}),t[23]=w,t[24]=T,t[25]=v,t[26]=C,t[27]=E):E=t[27];let D;t[28]===l?D=t[29]:(D=l?null:(0,Y.jsx)(vm,{}),t[28]=l,t[29]=D);let k;return t[30]!==d||t[31]!==r||t[32]!==h||t[33]!==E||t[34]!==D||t[35]!==g?(k=(0,Y.jsxs)(ge,{shouldFilter:!0,loop:!0,value:r,onValueChange:d,onKeyDown:h,className:`min-h-0 flex-1`,children:[g,E,D]}),t[30]=d,t[31]=r,t[32]=h,t[33]=E,t[34]=D,t[35]=g,t[36]=k):k=t[36],k}function gm(e){let t=(0,J.c)(14),{branches:n,branchesPending:r,checkoutPending:i,onSwitchBranch:a}=e,o=`Local branches · ${n.length}`,c;t[0]!==n.length||t[1]!==r?(c=r&&n.length===0?(0,Y.jsxs)(xe,{value:`loading:branches`,disabled:!0,children:[(0,Y.jsx)(C,{className:`text-primary`}),(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:`Loading branches…`})]}):null,t[0]=n.length,t[1]=r,t[2]=c):c=t[2];let l;if(t[3]!==n||t[4]!==i||t[5]!==a){let e;t[7]!==i||t[8]!==a?(e=e=>{let t=Oe(e),n=e.current?`current`:K(e.relativeDate),r=[e.name,e.upstream,e.subject].filter(Boolean).join(` · `)||e.name;return(0,Y.jsxs)(xe,{value:`local:${e.name}`,keywords:[e.name,e.upstream??``,e.subject??``],disabled:i,onSelect:()=>a(e),className:`items-start py-2`,children:[(0,Y.jsx)(`span`,{className:`mt-0.5 flex size-4 shrink-0 items-center justify-center`,children:e.current?(0,Y.jsx)(W,{className:`size-3.5 text-emerald-500`}):null}),(0,Y.jsxs)(`div`,{className:`min-w-0 flex-1`,title:r,children:[(0,Y.jsx)(`div`,{className:`truncate font-mono text-[13px] font-medium`,children:e.name}),(0,Y.jsx)(`div`,{className:`truncate text-xs text-muted-foreground`,children:[e.upstream,e.subject].filter(Boolean).join(` · `)||`Local branch`})]}),(0,Y.jsx)(I,{className:s(`shrink-0 tracking-normal normal-case`,t&&V(e,t)),children:t||n})]},e.name)},t[7]=i,t[8]=a,t[9]=e):e=t[9],l=n.map(e),t[3]=n,t[4]=i,t[5]=a,t[6]=l}else l=t[6];let u;return t[10]!==o||t[11]!==c||t[12]!==l?(u=(0,Y.jsxs)(Ce,{heading:o,children:[c,l]}),t[10]=o,t[11]=c,t[12]=l,t[13]=u):u=t[13],u}function _m(e){let t=(0,J.c)(12),{branches:n,localBranchNames:r,checkoutPending:i,onSwitchBranch:a}=e,o=`Remote branches · ${n.length}`,s;if(t[0]!==n||t[1]!==i||t[2]!==r||t[3]!==a){let e;t[5]!==i||t[6]!==r||t[7]!==a?(e=e=>{let t=Ae(e.name),n=t.branch||e.name,o=r.has(n);return(0,Y.jsxs)(xe,{value:`remote:${e.name}`,keywords:[e.name,n,e.subject??``],disabled:i,onSelect:()=>a(e),className:`items-start py-2`,children:[(0,Y.jsx)(ue,{className:`mt-0.5 size-4 shrink-0 text-muted-foreground`}),(0,Y.jsxs)(`div`,{className:`min-w-0 flex-1`,title:e.name,children:[(0,Y.jsxs)(`div`,{className:`truncate font-mono text-[13px] font-medium`,children:[t.remote?(0,Y.jsxs)(`span`,{className:`text-muted-foreground/70`,children:[t.remote,`/`]}):null,t.branch||e.name]}),(0,Y.jsx)(`div`,{className:`truncate text-xs text-muted-foreground`,children:e.subject||`Remote branch`})]}),(0,Y.jsx)(I,{className:`shrink-0 tracking-normal normal-case`,children:o?`Switch`:`Track`})]},e.name)},t[5]=i,t[6]=r,t[7]=a,t[8]=e):e=t[8],s=n.map(e),t[0]=n,t[1]=i,t[2]=r,t[3]=a,t[4]=s}else s=t[4];let c;return t[9]!==o||t[10]!==s?(c=(0,Y.jsx)(Ce,{heading:o,children:s}),t[9]=o,t[10]=s,t[11]=c):c=t[11],c}function vm(){let e=(0,J.c)(3),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,Y.jsxs)(`span`,{className:`inline-flex items-center gap-1`,children:[(0,Y.jsx)(pm,{children:`Enter`}),` Switch`]}),e[0]=t):t=e[0];let n;e[1]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,Y.jsxs)(`span`,{className:`inline-flex items-center gap-1`,children:[(0,Y.jsx)(pm,{children:At(`Control+N`)}),` `,`New branch`]}),e[1]=n):n=e[1];let r;return e[2]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,Y.jsxs)(`div`,{className:`hidden flex-wrap items-center gap-x-3 gap-y-1 border-t border-border/70 px-3 py-2 text-xs text-muted-foreground md:flex`,children:[t,n,(0,Y.jsxs)(`span`,{className:`inline-flex items-center gap-1`,children:[(0,Y.jsx)(pm,{children:`Esc`}),` Close`]})]}),e[2]=r):r=e[2],r}function ym(e){let t=(0,J.c)(33),{createBranchName:n,checkoutPending:r,isMobile:i,onBranchNameChange:a,onBrowseStage:o,onCreateBranch:s}=e,c;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,Y.jsx)(l,{}),t[0]=c):c=t[0];let u;t[1]===o?u=t[2]:(u=(0,Y.jsx)(qt,{type:`button`,variant:`ghost`,size:`icon`,onClick:o,"aria-label":`Back to branches`,children:c}),t[1]=o,t[2]=u);let d;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(d=(0,Y.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,Y.jsx)(`div`,{className:`truncate text-sm font-medium`,children:`Create branch`}),(0,Y.jsx)(`div`,{className:`truncate text-xs text-muted-foreground`,children:`From the current HEAD`})]}),t[3]=d):d=t[3];let f;t[4]===u?f=t[5]:(f=(0,Y.jsxs)(`div`,{className:`flex items-center gap-2 border-b border-border/70 px-3 py-2`,children:[u,d]}),t[4]=u,t[5]=f);let p;t[6]===a?p=t[7]:(p=e=>a(e.target.value),t[6]=a,t[7]=p);let m;t[8]!==o||t[9]!==s?(m=e=>{if(e.key===`Escape`){e.preventDefault(),e.stopPropagation(),o();return}e.key!==`Enter`||e.nativeEvent.isComposing||(e.preventDefault(),e.stopPropagation(),s())},t[8]=o,t[9]=s,t[10]=m):m=t[10];let h;t[11]!==n||t[12]!==p||t[13]!==m?(h=(0,Y.jsx)(gt,{value:n,onChange:p,onKeyDown:m,placeholder:`branch-name`,className:`min-w-0 flex-1`}),t[11]=n,t[12]=p,t[13]=m,t[14]=h):h=t[14];let g;t[15]!==r||t[16]!==n?(g=!n.trim()||r,t[15]=r,t[16]=n,t[17]=g):g=t[17];let _;t[18]===r?_=t[19]:(_=r?(0,Y.jsx)(C,{}):null,t[18]=r,t[19]=_);let v;t[20]!==s||t[21]!==g||t[22]!==_?(v=(0,Y.jsxs)(qt,{type:`button`,disabled:g,onClick:s,children:[_,`Create`]}),t[20]=s,t[21]=g,t[22]=_,t[23]=v):v=t[23];let y;t[24]!==v||t[25]!==h?(y=(0,Y.jsxs)(`div`,{className:`flex min-h-0 flex-1 items-center gap-2 p-3`,children:[h,v]}),t[24]=v,t[25]=h,t[26]=y):y=t[26];let b;t[27]===i?b=t[28]:(b=i?null:(0,Y.jsx)(bm,{}),t[27]=i,t[28]=b);let x;return t[29]!==y||t[30]!==b||t[31]!==f?(x=(0,Y.jsxs)(`div`,{className:`flex min-h-0 flex-1 flex-col`,children:[f,y,b]}),t[29]=y,t[30]=b,t[31]=f,t[32]=x):x=t[32],x}function bm(){let e=(0,J.c)(2),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,Y.jsxs)(`span`,{className:`inline-flex items-center gap-1`,children:[(0,Y.jsx)(pm,{children:`Enter`}),` Create`]}),e[0]=t):t=e[0];let n;return e[1]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,Y.jsxs)(`div`,{className:`hidden flex-wrap items-center gap-x-3 gap-y-1 border-t border-border/70 px-3 py-2 text-xs text-muted-foreground md:flex`,children:[t,(0,Y.jsxs)(`span`,{className:`inline-flex items-center gap-1`,children:[(0,Y.jsx)(pm,{children:`Esc`}),` Back`]})]}),e[1]=n):n=e[1],n}function xm(e){let t=(0,J.c)(9),{stage:n,createBranchName:r,checkoutPending:i,isMobile:a,browseProps:o,onBranchNameChange:s,onBrowseStage:c,onCreateBranch:l}=e;if(n===`create`){let e;return t[0]!==i||t[1]!==r||t[2]!==a||t[3]!==s||t[4]!==c||t[5]!==l?(e=(0,Y.jsx)(ym,{createBranchName:r,checkoutPending:i,isMobile:a,onBranchNameChange:s,onBrowseStage:c,onCreateBranch:l}),t[0]=i,t[1]=r,t[2]=a,t[3]=s,t[4]=c,t[5]=l,t[6]=e):e=t[6],e}let u;return t[7]===o?u=t[8]:(u=(0,Y.jsx)(hm,{...o}),t[7]=o,t[8]=u),u}function Sm(e){let t=(0,J.c)(77),{viewerContextId:n,cwd:r,active:i,gitStatus:a,open:o,onOpenChange:s}=e,c=dn(),l=tt(),u=xt(r),[d,f]=q.useReducer(fm,dm),p=re({viewerContextId:n,cwd:u,scope:`branches`}),m=!!(o&&i&&n&&u),h;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(h=[`data`,`isPending`,`error`],t[0]=h):h=t[0];let g;t[1]!==p||t[2]!==m?(g={...p,enabled:m,notifyOnChangeProps:h},t[1]=p,t[2]=m,t[3]=g):g=t[3];let _=ee(g),v=_.data,y,b,x,S;t[4]!==v?.localBranches||t[5]!==v?.remoteBranches||t[6]!==d.selectedValue||t[7]!==a?(b=Ee(v?.localBranches,a),x=(v?.remoteBranches??[]).filter(Tm),y=new Set(b.map(wm)),S=d.selectedValue||mm({localBranches:b,remoteBranches:x}),t[4]=v?.localBranches,t[5]=v?.remoteBranches,t[6]=d.selectedValue,t[7]=a,t[8]=y,t[9]=b,t[10]=x,t[11]=S):(y=t[8],b=t[9],x=t[10],S=t[11]);let C=S,w;t[12]!==f||t[13]!==o?(w=()=>{o||f({type:`reset`})},t[12]=f,t[13]=o,t[14]=w):w=t[14];let T;t[15]===o?T=t[16]:(T=[o],t[15]=o,t[16]=T),q.useEffect(w,T);let E;t[17]!==u||t[18]!==n?(E=async e=>await Qt(en(`/api/git-checkout`,{contextId:n}),{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({cwd:u,...e})}),t[17]=u,t[18]=n,t[19]=E):E=t[19];let D;t[20]!==u||t[21]!==s||t[22]!==c||t[23]!==n?(D=async(e,t)=>{await c.invalidateQueries({queryKey:tn.gitStatus(n,u),exact:!0,refetchType:`active`}),await We({queryClient:c,viewerContextId:n,cwd:u}),s(!1),ln.success(t.create?`Created and switched to ${t.branch}`:`Switched to ${t.branch}`)},t[20]=u,t[21]=s,t[22]=c,t[23]=n,t[24]=D):D=t[24];let O;t[25]!==E||t[26]!==D?(O={mutationFn:E,onSuccess:D,onError:Cm},t[25]=E,t[26]=D,t[27]=O):O=t[27];let k=te(O),A;t[28]===k?A=t[29]:(A=e=>{e.current||k.isPending||k.mutate({branch:e.name})},t[28]=k,t[29]=A);let j=A,M;t[30]!==k||t[31]!==y?(M=e=>{if(k.isPending)return;let t=Ae(e.name).branch||e.name;if(y.has(t)){k.mutate({branch:t});return}k.mutate({branch:t,create:!0,startPoint:e.name,track:!0})},t[30]=k,t[31]=y,t[32]=M):M=t[32];let N=M,P;t[33]!==k||t[34]!==d.createBranchName?(P=()=>{let e=d.createBranchName.trim();!e||k.isPending||k.mutate({branch:e,create:!0})},t[33]=k,t[34]=d.createBranchName,t[35]=P):P=t[35];let F=P,I,L,R;t[36]===f?(I=t[37],L=t[38],R=t[39]):(I=e=>f({type:`set-query`,query:e}),L=e=>f({type:`set-selected-value`,selectedValue:e}),R=()=>f({type:`set-stage`,stage:`create`}),t[36]=f,t[37]=I,t[38]=L,t[39]=R);let z;t[40]!==_.isPending||t[41]!==k.isPending||t[42]!==d.query||t[43]!==l||t[44]!==y||t[45]!==b||t[46]!==x||t[47]!==C||t[48]!==j||t[49]!==N||t[50]!==I||t[51]!==L||t[52]!==R?(z={query:d.query,selectedValue:C,localBranches:b,remoteBranches:x,localBranchNames:y,branchesPending:_.isPending,checkoutPending:k.isPending,isMobile:l,onQueryChange:I,onSelectedValueChange:L,onCreateStage:R,onSwitchLocalBranch:j,onSwitchRemoteBranch:N},t[40]=_.isPending,t[41]=k.isPending,t[42]=d.query,t[43]=l,t[44]=y,t[45]=b,t[46]=x,t[47]=C,t[48]=j,t[49]=N,t[50]=I,t[51]=L,t[52]=R,t[53]=z):z=t[53];let V,H;t[54]===f?(V=t[55],H=t[56]):(V=e=>f({type:`set-create-branch-name`,createBranchName:e}),H=()=>f({type:`set-stage`,stage:`browse`}),t[54]=f,t[55]=V,t[56]=H);let U;t[57]!==k.isPending||t[58]!==F||t[59]!==d.createBranchName||t[60]!==d.stage||t[61]!==l||t[62]!==z||t[63]!==V||t[64]!==H?(U=(0,Y.jsx)(xm,{stage:d.stage,createBranchName:d.createBranchName,checkoutPending:k.isPending,isMobile:l,browseProps:z,onBranchNameChange:V,onBrowseStage:H,onCreateBranch:F}),t[57]=k.isPending,t[58]=F,t[59]=d.createBranchName,t[60]=d.stage,t[61]=l,t[62]=z,t[63]=V,t[64]=H,t[65]=U):U=t[65];let ne=U;if(l){let e;t[66]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsxs)(B,{children:[(0,Y.jsx)(G,{children:`Branches`}),(0,Y.jsx)(pe,{children:`Switch branches or create a new branch.`})]}),t[66]=e):e=t[66];let n;t[67]===ne?n=t[68]:(n=(0,Y.jsxs)(le,{className:`max-h-[90svh] overflow-hidden`,children:[e,(0,Y.jsx)(`div`,{className:`flex min-h-0 flex-1 flex-col overflow-hidden px-4 pb-4`,children:ne})]}),t[67]=ne,t[68]=n);let r;return t[69]!==s||t[70]!==o||t[71]!==n?(r=(0,Y.jsx)(oe,{open:o,onOpenChange:s,children:n}),t[69]=s,t[70]=o,t[71]=n,t[72]=r):r=t[72],r}let W;return t[73]!==ne||t[74]!==s||t[75]!==o?(W=(0,Y.jsx)(It,{open:o,onOpenChange:s,title:`Branches`,description:`Switch branches or create a new branch.`,className:`sm:max-w-2xl`,initialFocus:!0,children:ne}),t[73]=ne,t[74]=s,t[75]=o,t[76]=W):W=t[76],W}function Cm(e,t){ln.error(ft(e,t.create?`Failed to create branch`:`Failed to switch branch`))}function wm(e){return e.name}function Tm(e){return!e.name.endsWith(`/HEAD`)}function Em(e){let t=(0,J.c)(20),{viewerContextId:n,cwd:r,active:i}=e,a=xt(r),o=!!(i&&n&&a),s=ee({...w({viewerContextId:n,cwd:a}),enabled:o,notifyOnChangeProps:[`error`,`errorUpdatedAt`]}),c=ee({...re({viewerContextId:n,cwd:a,scope:`files`}),enabled:o,notifyOnChangeProps:[`error`,`errorUpdatedAt`]}),l=ee({...re({viewerContextId:n,cwd:a,scope:`branches`}),enabled:o,notifyOnChangeProps:[`error`,`errorUpdatedAt`]}),u=re({viewerContextId:n,cwd:a,scope:`commits`}),d;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(d=[`error`,`errorUpdatedAt`],t[0]=d):d=t[0];let f;t[1]!==o||t[2]!==u?(f={...u,enabled:o,notifyOnChangeProps:d},t[1]=o,t[2]=u,t[3]=f):f=t[3];let p=ee(f),m;t[4]!==i||t[5]!==l.error||t[6]!==p.error||t[7]!==c.error||t[8]!==s.error?(m=()=>{if(!i)return;let e=c.error||l.error||p.error||s.error;e&&ln.error(ft(e,`Failed to load git view`))},t[4]=i,t[5]=l.error,t[6]=p.error,t[7]=c.error,t[8]=s.error,t[9]=m):m=t[9];let h;return t[10]!==i||t[11]!==l.error||t[12]!==l.errorUpdatedAt||t[13]!==p.error||t[14]!==p.errorUpdatedAt||t[15]!==c.error||t[16]!==c.errorUpdatedAt||t[17]!==s.error||t[18]!==s.errorUpdatedAt?(h=[i,l.error,l.errorUpdatedAt,p.error,p.errorUpdatedAt,c.error,c.errorUpdatedAt,s.error,s.errorUpdatedAt],t[10]=i,t[11]=l.error,t[12]=l.errorUpdatedAt,t[13]=p.error,t[14]=p.errorUpdatedAt,t[15]=c.error,t[16]=c.errorUpdatedAt,t[17]=s.error,t[18]=s.errorUpdatedAt,t[19]=h):h=t[19],q.useEffect(m,h),null}function Dm(e){let t=(0,J.c)(29),{viewerContextId:n,cwd:r,active:i,onBranchClick:a}=e,o=xt(r),s=!!(i&&n&&o),c=ee({...w({viewerContextId:n,cwd:o}),enabled:s,select:vt,notifyOnChangeProps:[`data`,`isPending`,`error`]});if(!o){let e;return t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(tp,{children:`No directory selected.`}),t[0]=e):e=t[0],e}if(!n){let e;return t[1]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(tp,{children:`Waiting for viewer context…`}),t[1]=e):e=t[1],e}if(c.isPending&&c.data===void 0){let e;return t[2]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsxs)(tp,{children:[(0,Y.jsx)(C,{}),` Loading repository status…`]}),t[2]=e):e=t[2],e}if(c.error){let e;t[3]===c.error?e=t[4]:(e=ft(c.error,`Failed to load repository status`),t[3]=c.error,t[4]=e);let n;return t[5]===e?n=t[6]:(n=(0,Y.jsx)(tp,{tone:`destructive`,children:e}),t[5]=e,t[6]=n),n}let l=c.data;if(!l){let e;return t[7]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(tp,{children:`No git repository detected.`}),t[7]=e):e=t[7],e}let u=l.detached?`Detached HEAD${l.revision?` (${l.revision})`:``}`:l.branch||l.label,d=Ie(o),f=l.ahead===0&&l.behind===0,p=Ze(o),m;t[8]!==l.title||t[9]!==p?(m=[p,l.title].filter(Boolean),t[8]=l.title,t[9]=p,t[10]=m):m=t[10];let h=m.join(` · `),g;t[11]===f?g=t[12]:(g=f?(0,Y.jsx)(W,{className:`size-3 shrink-0 text-emerald-500`}):null,t[11]=f,t[12]=g);let _;t[13]===l.behind?_=t[14]:(_=l.behind>0?(0,Y.jsxs)(`span`,{className:`shrink-0 font-medium text-sky-500 tabular-nums`,children:[`↓`,l.behind]}):null,t[13]=l.behind,t[14]=_);let v;t[15]===l.ahead?v=t[16]:(v=l.ahead>0?(0,Y.jsxs)(`span`,{className:`shrink-0 font-medium text-amber-500 tabular-nums`,children:[`↑`,l.ahead]}):null,t[15]=l.ahead,t[16]=v);let y=d||`No cwd`,b;t[17]===y?b=t[18]:(b=(0,Y.jsx)(`span`,{className:`min-w-0 truncate font-medium`,children:y}),t[17]=y,t[18]=b);let x;t[19]!==u||t[20]!==a?(x=u?(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(`span`,{className:`shrink-0 text-muted-foreground`,children:`→`}),a?(0,Y.jsxs)(`button`,{type:`button`,"aria-label":`Switch branch`,className:`-mx-1 inline-flex min-w-0 items-center gap-1 rounded-md px-1 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,onClick:a,children:[(0,Y.jsx)(`span`,{className:`min-w-0 truncate`,children:u}),(0,Y.jsx)(ce,{className:`size-3 shrink-0`})]}):(0,Y.jsx)(`span`,{className:`min-w-0 truncate text-muted-foreground`,children:u})]}):null,t[19]=u,t[20]=a,t[21]=x):x=t[21];let S;return t[22]!==g||t[23]!==_||t[24]!==v||t[25]!==b||t[26]!==x||t[27]!==h?(S=(0,Y.jsxs)(`div`,{className:`flex min-w-0 items-center gap-1.5 text-xs leading-5`,title:h,children:[g,_,v,b,x]}),t[22]=g,t[23]=_,t[24]=v,t[25]=b,t[26]=x,t[27]=h,t[28]=S):S=t[28],S}function Om(e){let t=(0,J.c)(51),{viewerContextId:n,cwd:r,active:i}=e,a=dn(),o=tt(),s=xt(r),[c,l]=q.useState(!1),[u,d]=q.useState(!1),p=ee({...w({viewerContextId:n,cwd:s}),enabled:!!(i&&n&&s),select:vt,notifyOnChangeProps:[`data`]}),m=ee({...re({viewerContextId:n,cwd:s,scope:`files`}),enabled:!!(i&&n&&s),select:lt,notifyOnChangeProps:[`data`]}),h=pn({queryKey:tn.gitStatus(n,s),exact:!0}),g=pn({queryKey:tn.gitFiles(n,s),exact:!0}),_=pn({queryKey:tn.gitBranches(n,s),exact:!0}),v=pn({queryKey:tn.gitCommits(n,s),exact:!1}),y=h+g+_+v>0,b=p.data,x;t[0]===m.data?x=t[1]:(x=Array.isArray(m.data)?m.data:[],t[0]=m.data,t[1]=x);let S=x,T=!!b,E=!!(b?.dirty||S.length>0),D=!!(T&&!b?.detached&&(b?.ahead||0)>0),O;t[2]===b?O=t[3]:(O=me(b),t[2]=b,t[3]=O);let A=O,j=!!(T&&!b?.detached&&(b?.behind||0)>0),M=te({mutationFn:async e=>await Qt(en(e===`pull`?`/api/git-pull`:`/api/git-push`,{contextId:n}),{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({cwd:s,force:e===`force-push`})}),onSuccess:async(e,t)=>{await a.invalidateQueries({queryKey:tn.gitStatus(n,s),exact:!0,refetchType:`active`}),await We({queryClient:a,viewerContextId:n,cwd:s}),t!==`pull`&&k({response:e,force:t===`force-push`})},onError:km}),P=ht({mutationKey:tn.gitAction(n,s,`push`)}),F=ht({mutationKey:tn.gitAction(n,s,`force-push`)}),I=tn.gitAction(n,s,`pull`),L;t[4]===I?L=t[5]:(L={mutationKey:I},t[4]=I,t[5]=L);let R=ht(L),z=M.isPending&&M.variables===`push`||P>0,B=M.isPending&&M.variables===`force-push`||F>0,V=M.isPending&&M.variables===`pull`||R>0,H=M.isPending||z||B||V,U=!!(n&&s&&E),ne=!!(n&&s&&D&&(!H||z)),W=!!(n&&s&&A&&(!H||B)),G=!!(n&&s&&j&&(!H||V)),ie=U||ne||W||G,ae;t[6]===l?ae=t[7]:(ae=()=>{l(!0)},t[6]=l,t[7]=ae);let oe;t[8]!==i||t[9]!==s||t[10]!==ae||t[11]!==n?(oe=(0,Y.jsx)(Dm,{viewerContextId:n,cwd:s,active:i,onBranchClick:ae}),t[8]=i,t[9]=s,t[10]=ae,t[11]=n,t[12]=oe):oe=t[12];let se;t[13]!==i||t[14]!==y?(se=i&&y?(0,Y.jsx)(C,{size:`xs`,className:`shrink-0 text-primary`}):null,t[13]=i,t[14]=y,t[15]=se):se=t[15];let ce;t[16]!==oe||t[17]!==se?(ce=(0,Y.jsxs)(`div`,{className:`flex min-w-0 items-center gap-1.5`,children:[oe,se]}),t[16]=oe,t[17]=se,t[18]=ce):ce=t[18];let le;t[19]!==B||t[20]!==H||t[21]!==M||t[22]!==o||t[23]!==V||t[24]!==z||t[25]!==d||t[26]!==ie||t[27]!==U||t[28]!==W||t[29]!==G||t[30]!==ne?(le=ie?(0,Y.jsxs)(`div`,{className:`flex flex-wrap items-center justify-end gap-2`,children:[U?(0,Y.jsx)(f,{title:`Commit`,kbd:At(`Control+C`),children:(0,Y.jsxs)(qt,{variant:`outline`,size:o?`default`:`sm`,onClick:()=>{d(!0)},children:[(0,Y.jsx)(nt,{}),` Commit…`]})}):null,ne?(0,Y.jsx)(f,{title:`Push`,kbd:At(`Control+P`),children:(0,Y.jsxs)(qt,{variant:`outline`,size:o?`default`:`sm`,disabled:H,onClick:()=>{M.mutate(`push`)},children:[z?(0,Y.jsx)(C,{}):(0,Y.jsx)(N,{}),`Push`]})}):null,W?(0,Y.jsx)(f,{title:`Force push`,kbd:At(`Control+Shift+P`),children:(0,Y.jsxs)(qt,{variant:`outline`,size:o?`default`:`sm`,disabled:H,onClick:()=>{M.mutate(`force-push`)},children:[B?(0,Y.jsx)(C,{}):(0,Y.jsx)(N,{}),`Force Push`]})}):null,G?(0,Y.jsx)(f,{title:`Pull`,kbd:At(`Alt+P`),children:(0,Y.jsxs)(qt,{variant:`outline`,size:o?`default`:`sm`,disabled:H,onClick:()=>{M.mutate(`pull`)},children:[V?(0,Y.jsx)(C,{}):(0,Y.jsx)($e,{}),`Pull`]})}):null]}):null,t[19]=B,t[20]=H,t[21]=M,t[22]=o,t[23]=V,t[24]=z,t[25]=d,t[26]=ie,t[27]=U,t[28]=W,t[29]=G,t[30]=ne,t[31]=le):le=t[31];let ue;t[32]!==i||t[33]!==c||t[34]!==b||t[35]!==s||t[36]!==l||t[37]!==n?(ue=(0,Y.jsx)(Sm,{viewerContextId:n,cwd:s,active:i,gitStatus:b,open:c,onOpenChange:l}),t[32]=i,t[33]=c,t[34]=b,t[35]=s,t[36]=l,t[37]=n,t[38]=ue):ue=t[38];let de;t[39]!==u||t[40]!==S||t[41]!==b||t[42]!==s||t[43]!==d||t[44]!==n?(de=(0,Y.jsx)(Nt,{viewerContextId:n,cwd:s,files:S,gitStatus:b,open:u,onOpenChange:d}),t[39]=u,t[40]=S,t[41]=b,t[42]=s,t[43]=d,t[44]=n,t[45]=de):de=t[45];let K;return t[46]!==ue||t[47]!==de||t[48]!==ce||t[49]!==le?(K=(0,Y.jsxs)(`div`,{className:`flex flex-wrap items-center justify-between gap-2`,children:[ce,le,ue,de]}),t[46]=ue,t[47]=de,t[48]=ce,t[49]=le,t[50]=K):K=t[50],K}function km(e,t){ln.error(ft(e,t===`pull`?`Failed to pull changes`:t===`force-push`?`Failed to force push changes`:`Failed to push changes`))}function Am(e){let{children:t,open:n,defaultOpen:r=!1,onOpenChange:i,onOpenChangeComplete:a,actionsRef:o,handle:s,triggerId:c,defaultTriggerId:l=null}=e,u=Ut(!0),d=!!u,f=Bt.useStore(s?.store,{open:r,openProp:n,activeTriggerId:l,triggerIdProp:c,modal:!0,disablePointerDismissal:!0,nested:d,role:`alertdialog`});f.useControlledProp(`openProp`,n),f.useControlledProp(`triggerIdProp`,c),f.useSyncedValue(`nested`,d),f.useContextCallback(`onOpenChange`,i),f.useContextCallback(`onOpenChangeComplete`,a);let p=f.useState(`payload`);zt({store:f,actionsRef:o,parentContext:u?.store.context,isDrawer:!1,onOpenChange:i,triggerIdProp:c});let m=q.useMemo(()=>({store:f}),[f]);return(0,Y.jsx)(Yt.Provider,{value:!1,children:(0,Y.jsx)(Ht.Provider,{value:m,children:typeof t==`function`?t({payload:p}):t})})}function jm(e){let t=(0,J.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,Y.jsx)(Am,{"data-slot":`alert-dialog`,...n}),t[2]=n,t[3]=r),r}function Mm(e){let t=(0,J.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,Y.jsx)(Lt,{"data-slot":`alert-dialog-portal`,...n}),t[2]=n,t[3]=r),r}function Nm(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(`fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(Vt,{"data-slot":`alert-dialog-overlay`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Pm(e){let t=(0,J.c)(11),n,r,i;t[0]===e?(n=t[1],r=t[2],i=t[3]):({className:n,size:i,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i);let a=i===void 0?`default`:i,o;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(o=(0,Y.jsx)(Nm,{}),t[4]=o):o=t[4];let c;t[5]===n?c=t[6]:(c=s(`group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm 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`,n),t[5]=n,t[6]=c);let l;return t[7]!==r||t[8]!==a||t[9]!==c?(l=(0,Y.jsxs)(Mm,{children:[o,(0,Y.jsx)(Wt,{"data-slot":`alert-dialog-content`,"data-size":a,className:c,...r})]}),t[7]=r,t[8]=a,t[9]=c,t[10]=l):l=t[10],l}function Fm(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(`grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(`div`,{"data-slot":`alert-dialog-header`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Im(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(`-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(`div`,{"data-slot":`alert-dialog-footer`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Lm(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(`mb-2 inline-flex size-10 items-center justify-center rounded-md bg-muted sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-6`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(`div`,{"data-slot":`alert-dialog-media`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Rm(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(`font-heading text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(Rt,{"data-slot":`alert-dialog-title`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function zm(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(`text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(Gt,{"data-slot":`alert-dialog-description`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Bm(e){let t=(0,J.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=s(n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,Y.jsx)(qt,{"data-slot":`alert-dialog-action`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Vm(e){let t=(0,J.c)(14),n,r,i,a;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4]):({className:n,variant:i,size:a,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a);let o=i===void 0?`outline`:i,c=a===void 0?`default`:a,l;t[5]===n?l=t[6]:(l=s(n),t[5]=n,t[6]=l);let u;t[7]!==c||t[8]!==o?(u=(0,Y.jsx)(qt,{variant:o,size:c}),t[7]=c,t[8]=o,t[9]=u):u=t[9];let d;return t[10]!==r||t[11]!==l||t[12]!==u?(d=(0,Y.jsx)(Kt,{"data-slot":`alert-dialog-cancel`,className:l,render:u,...r}),t[10]=r,t[11]=l,t[12]=u,t[13]=d):d=t[13],d}function Hm(e){let t=(0,J.c)(23),{title:n,meta:r,controls:i,className:a,bodyClassName:o,children:c}=e,l;t[0]===a?l=t[1]:(l=s(`overflow-hidden rounded-xl border border-border/80 bg-card/50`,a),t[0]=a,t[1]=l);let u;t[2]===n?u=t[3]:(u=(0,Y.jsx)(`div`,{className:`text-xs font-bold tracking-[0.04em] text-muted-foreground uppercase`,children:n}),t[2]=n,t[3]=u);let d;t[4]===r?d=t[5]:(d=r?(0,Y.jsx)(`div`,{className:`min-w-0 truncate text-xs text-muted-foreground/80`,children:r}):null,t[4]=r,t[5]=d);let f;t[6]!==u||t[7]!==d?(f=(0,Y.jsxs)(`div`,{className:`flex min-w-0 items-baseline gap-3`,children:[u,d]}),t[6]=u,t[7]=d,t[8]=f):f=t[8];let p;t[9]===i?p=t[10]:(p=i?(0,Y.jsx)(`div`,{className:`shrink-0`,children:i}):null,t[9]=i,t[10]=p);let m;t[11]!==f||t[12]!==p?(m=(0,Y.jsxs)(`div`,{className:`flex min-h-10 items-center justify-between gap-3 border-b border-border/70 bg-background px-3 py-2`,children:[f,p]}),t[11]=f,t[12]=p,t[13]=m):m=t[13];let h;t[14]===o?h=t[15]:(h=s(`grid gap-2 px-3 py-2.5`,o),t[14]=o,t[15]=h);let g;t[16]!==c||t[17]!==h?(g=(0,Y.jsx)(`div`,{className:h,children:c}),t[16]=c,t[17]=h,t[18]=g):g=t[18];let _;return t[19]!==l||t[20]!==m||t[21]!==g?(_=(0,Y.jsxs)(`section`,{className:l,children:[m,g]}),t[19]=l,t[20]=m,t[21]=g,t[22]=_):_=t[22],_}var Um=[`#0ea5e9`,`#db2777`,`#22c55e`,`#f59e0b`,`#8b5cf6`,`#14b8a6`],Wm=-1,Gm=32,Km=200,qm=14,Jm=12,Ym={hashCopied:!1,messageCopied:!1,formDialog:null,confirmDialog:null,contextMenuOpen:!1,contextMenuKey:0};function Xm(e,t){switch(t.type){case`set-hash-copied`:return e.hashCopied===t.copied?e:{...e,hashCopied:t.copied};case`set-message-copied`:return e.messageCopied===t.copied?e:{...e,messageCopied:t.copied};case`set-form-dialog`:return e.formDialog===t.formDialog?e:{...e,formDialog:t.formDialog};case`set-form-dialog-value`:return!e.formDialog||e.formDialog.value===t.value?e:{...e,formDialog:{...e.formDialog,value:t.value}};case`set-confirm-dialog`:return e.confirmDialog===t.confirmDialog?e:{...e,confirmDialog:t.confirmDialog};case`set-context-menu-open`:return e.contextMenuOpen===t.open?e:{...e,contextMenuOpen:t.open};case`reset-context-menu`:return{...e,contextMenuOpen:!1,contextMenuKey:e.contextMenuKey+1}}}function Zm(e,t=!1){return t?`var(--warning)`:Um[e%Um.length]}var Qm=class{colour;lines=[];constructor(e){this.colour=e}addLine(e,t){this.lines.push({p1:e,p2:t})}getColour(){return this.colour}getLines(){return this.lines}},$m=class{id;connections=[];nextParent=0;nextX=0;onBranch=null;parents=[];x=0;constructor(e){this.id=e}addParent(e){this.parents.push(e)}getNextParent(){return this.parents[this.nextParent]??null}registerParentProcessed(){this.nextParent+=1}isMerge(){return this.parents.length>1}addToBranch(e,t){this.onBranch===null&&(this.onBranch=e,this.x=t)}isNotOnBranch(){return this.onBranch===null}getBranch(){return this.onBranch}getPoint(){return{x:this.x,y:this.id}}getNextPoint(){return{x:this.nextX,y:this.id}}getPointConnectingTo(e,t){for(let n=0;n<this.connections.length;n++){let r=this.connections[n];if(r?.connectsTo===e&&r.onBranch===t)return{x:n,y:this.id}}return null}registerUnavailablePoint(e,t,n){e===this.nextX&&(this.nextX=e+1,this.connections[e]={connectsTo:t,onBranch:n})}};function eh(e){let t=e.map(e=>wt(e)),n=new Map;t.forEach((e,t)=>{e.fullHash&&n.set(e.fullHash,t)});let r=new $m(Wm),i=t.map((e,t)=>new $m(t)),a=[],o=[];t.forEach((e,t)=>{if(!e.fullHash)return;let a=i[t];e.parents.forEach(e=>{let t=n.get(e);if(typeof t==`number`){let e=i[t];a.addParent(e)}else a.addParent(r)})});let s=e=>{for(let t=0;t<o.length;t++)if(e>(o[t]??0))return t;return o.push(0),o.length-1},c=e=>{let t=e,n=i[t],r=n.getNextParent(),c=n.isNotOnBranch()?n.getNextPoint():n.getPoint();if(r!==null&&r.id!==Wm&&n.isMerge()&&!n.isNotOnBranch()&&!r.isNotOnBranch()){let a=r.getBranch(),o=!1;for(t=e+1;t<i.length;t++){let e=i[t],s=e.getPointConnectingTo(r,a),l=s??e.getNextPoint();if(a.addLine(c,l),e.registerUnavailablePoint(l.x,r,a),c=l,s!==null){n.registerParentProcessed(),o=!0;break}}o||n.registerParentProcessed();return}let l=new Qm(s(e));for(n.addToBranch(l,c.x),n.registerUnavailablePoint(c.x,n,l),t=e+1;t<i.length;t++){let e=i[t],a=r===e&&!r.isNotOnBranch()?e.getPoint():e.getNextPoint();if(l.addLine(c,a),e.registerUnavailablePoint(a.x,r,l),c=a,r===e){n.registerParentProcessed();let e=!r.isNotOnBranch();if(r.addToBranch(l,a.x),n=r,r=n.getNextParent(),r===null||e)break}}t===i.length&&r!==null&&r.id===Wm&&n.registerParentProcessed(),a.push(l),o[l.getColour()]=t},l=0;for(;l<i.length;){let e=i[l];t[l].fullHash&&(e.getNextParent()!==null||e.isNotOnBranch())?c(l):l+=1}let u=t.map((e,t)=>{let n=i[t]?.getBranch()??null;return{colour:n?.getColour()??0,commitLane:e.fullHash&&n?i[t].getPoint().x:-1,parsed:e}});return{branches:a,maxLaneCount:Math.max(1,...i.map(e=>e.getNextPoint().x)),rows:u}}function th(e,t){return e.parsed.fullHash||`commit-row:${t}`}function nh(e,t){let n=new Set(t);return e.map((e,t)=>n.has(th(e,t))?Gm+Km:Gm)}function rh(e){let t=0;return e.map(e=>{let n=t;return t+=e,n})}function ih(e){return e.reduce((e,t)=>e+t,0)}function ah(e,t){return(e[t]??t*Gm)+Gm/2}function oh({line:e,rowTops:t}){let n=e.p1.x*qm+Jm,r=ah(t,e.p1.y),i=e.p2.x*qm+Jm,a=ah(t,e.p2.y);if(n===i)return`M ${n} ${r} L ${i} ${a}`;let o=Gm*.8;return`M ${n} ${r} C ${n} ${r+o}, ${i} ${a-o}, ${i} ${a}`}function sh(e){return e.trim().toLowerCase().replace(/[^a-z0-9._-]+/g,`-`).replace(/^-+|-+$/g,``).slice(0,48)}function ch(e,t){return`commit/${sh(e)||t}`}function lh(e){return`v-${e}`}function uh(e){switch(e){case`checkout`:return`Checked out commit`;case`cherry-pick`:return`Cherry-picked commit`;case`revert`:return`Reverted commit`;case`tag`:return`Tagged commit`;case`reset`:return`Reset branch`;case`rebase`:return`Rebased branch`;case`drop`:return`Dropped commit`;case`squash`:return`Squashed commits`}}function dh(e){let t=(0,J.c)(15),{lines:n,openCommitValues:r,unpushedCommitHashes:i}=e,a,o,s,c;if(t[0]!==n||t[1]!==r||t[2]!==i){let{branches:e,maxLaneCount:l,rows:u}=eh(n),d=nh(u,r),f=rh(d);c=Math.max(24,l*qm+4),o=Math.max(Gm,ih(d)),s=[],a=[],e.forEach((e,t)=>{e.getLines().forEach((n,r)=>{s.push((0,Y.jsx)(`path`,{d:oh({line:n,rowTops:f}),fill:`none`,stroke:Zm(e.getColour()),strokeLinecap:`round`,strokeWidth:`2`},`path:${t}:${r}`))})}),u.forEach((e,t)=>{if(e.commitLane<0)return;let n=e.commitLane*qm+Jm,r=ah(f,t),o=!!(e.parsed.fullHash&&i.has(e.parsed.fullHash));a.push((0,Y.jsx)(`circle`,{cx:n,cy:r,r:`4`,fill:Zm(e.colour,o)},`circle:${t}:${e.parsed.fullHash}`))}),t[0]=n,t[1]=r,t[2]=i,t[3]=a,t[4]=o,t[5]=s,t[6]=c}else a=t[3],o=t[4],s=t[5],c=t[6];let l=`0 0 ${c} ${o}`,u;t[7]!==o||t[8]!==c?(u={width:c,height:o},t[7]=o,t[8]=c,t[9]=u):u=t[9];let d;return t[10]!==a||t[11]!==s||t[12]!==l||t[13]!==u?(d=(0,Y.jsxs)(`svg`,{"aria-hidden":!0,viewBox:l,className:`pointer-events-none absolute top-0 left-0 z-10 overflow-visible`,style:u,children:[s,a]}),t[10]=a,t[11]=s,t[12]=l,t[13]=u,t[14]=d):d=t[14],d}function fh(e){let t=(0,J.c)(137),{disabled:n,busy:r,canCopyMessage:i,onViewDiff:a,onCompareHead:o,onComparePrevious:s,onCopyHash:c,onCopyMessage:l,onCreateBranch:u,onCheckout:d,onCherryPick:f,onRevert:p,onTag:m,onOpenRemote:h,onReset:g,onRebase:_,onDrop:v,onSquash:y}=e,[b,x]=q.useState(!1),[S,w]=q.useState(0),T=q.useRef(null),D;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(D=e=>{T.current?.close(),T.current?.unmount(),x(!1),w(ph),e()},t[0]=D):D=t[0];let O=D,k=n||r,A;t[1]===k?A=t[2]:(A=(0,Y.jsx)(qt,{type:`button`,size:`icon-xs`,variant:`outline`,"aria-label":`Commit actions`,disabled:k}),t[1]=k,t[2]=A);let j;t[3]===r?j=t[4]:(j=r?(0,Y.jsx)(C,{size:`xs`}):(0,Y.jsx)(E,{}),t[3]=r,t[4]=j);let M;t[5]!==A||t[6]!==j?(M=(0,Y.jsx)(Me,{render:A,children:j}),t[5]=A,t[6]=j,t[7]=M):M=t[7];let N;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(N=(0,Y.jsx)(Ve,{children:`Commit`}),t[8]=N):N=t[8];let P;t[9]===a?P=t[10]:(P=()=>O(a),t[9]=a,t[10]=P);let F;t[11]===Symbol.for(`react.memo_cache_sentinel`)?(F=(0,Y.jsx)(gn,{}),t[11]=F):F=t[11];let I;t[12]!==n||t[13]!==P?(I=(0,Y.jsxs)(Tt,{disabled:n,onClick:P,children:[F,`View diff`]}),t[12]=n,t[13]=P,t[14]=I):I=t[14];let L;t[15]===o?L=t[16]:(L=()=>O(o),t[15]=o,t[16]=L);let R;t[17]===Symbol.for(`react.memo_cache_sentinel`)?(R=(0,Y.jsx)(gn,{}),t[17]=R):R=t[17];let z;t[18]!==n||t[19]!==L?(z=(0,Y.jsxs)(Tt,{disabled:n,onClick:L,children:[R,`Compare with HEAD`]}),t[18]=n,t[19]=L,t[20]=z):z=t[20];let B;t[21]===s?B=t[22]:(B=()=>O(s),t[21]=s,t[22]=B);let V;t[23]===Symbol.for(`react.memo_cache_sentinel`)?(V=(0,Y.jsx)(gn,{}),t[23]=V):V=t[23];let ee;t[24]!==n||t[25]!==B?(ee=(0,Y.jsxs)(Tt,{disabled:n,onClick:B,children:[V,`Compare with previous commit`]}),t[24]=n,t[25]=B,t[26]=ee):ee=t[26];let H;t[27]===h?H=t[28]:(H=()=>O(h),t[27]=h,t[28]=H);let U;t[29]===Symbol.for(`react.memo_cache_sentinel`)?(U=(0,Y.jsx)(hn,{}),t[29]=U):U=t[29];let te;t[30]!==n||t[31]!==H?(te=(0,Y.jsxs)(Tt,{disabled:n,onClick:H,children:[U,`Open on remote`]}),t[30]=n,t[31]=H,t[32]=te):te=t[32];let ne;t[33]!==z||t[34]!==ee||t[35]!==te||t[36]!==I?(ne=(0,Y.jsxs)(rt,{children:[N,I,z,ee,te]}),t[33]=z,t[34]=ee,t[35]=te,t[36]=I,t[37]=ne):ne=t[37];let re;t[38]===Symbol.for(`react.memo_cache_sentinel`)?(re=(0,Y.jsx)(Ge,{}),t[38]=re):re=t[38];let W;t[39]===c?W=t[40]:(W=()=>O(c),t[39]=c,t[40]=W);let G;t[41]===Symbol.for(`react.memo_cache_sentinel`)?(G=(0,Y.jsx)(ae,{}),t[41]=G):G=t[41];let ie;t[42]!==n||t[43]!==W?(ie=(0,Y.jsxs)(Tt,{disabled:n,onClick:W,children:[G,`Copy commit hash`]}),t[42]=n,t[43]=W,t[44]=ie):ie=t[44];let oe=!i,se;t[45]===l?se=t[46]:(se=()=>O(l),t[45]=l,t[46]=se);let ce;t[47]===Symbol.for(`react.memo_cache_sentinel`)?(ce=(0,Y.jsx)(ae,{}),t[47]=ce):ce=t[47];let le;t[48]!==oe||t[49]!==se?(le=(0,Y.jsxs)(Tt,{disabled:oe,onClick:se,children:[ce,`Copy commit message`]}),t[48]=oe,t[49]=se,t[50]=le):le=t[50];let de;t[51]!==ie||t[52]!==le?(de=(0,Y.jsxs)(rt,{children:[ie,le]}),t[51]=ie,t[52]=le,t[53]=de):de=t[53];let K;t[54]===Symbol.for(`react.memo_cache_sentinel`)?(K=(0,Y.jsx)(Ge,{}),t[54]=K):K=t[54];let fe;t[55]===u?fe=t[56]:(fe=()=>O(u),t[55]=u,t[56]=fe);let pe;t[57]===Symbol.for(`react.memo_cache_sentinel`)?(pe=(0,Y.jsx)(ue,{}),t[57]=pe):pe=t[57];let me;t[58]!==n||t[59]!==fe?(me=(0,Y.jsxs)(Tt,{disabled:n,onClick:fe,children:[pe,`Create branch from commit…`]}),t[58]=n,t[59]=fe,t[60]=me):me=t[60];let he;t[61]===d?he=t[62]:(he=()=>O(d),t[61]=d,t[62]=he);let ge;t[63]!==n||t[64]!==he?(ge=(0,Y.jsx)(Tt,{disabled:n,onClick:he,children:`Checkout commit`}),t[63]=n,t[64]=he,t[65]=ge):ge=t[65];let _e;t[66]===f?_e=t[67]:(_e=()=>O(f),t[66]=f,t[67]=_e);let ve;t[68]!==n||t[69]!==_e?(ve=(0,Y.jsx)(Tt,{disabled:n,onClick:_e,children:`Cherry-pick commit`}),t[68]=n,t[69]=_e,t[70]=ve):ve=t[70];let ye;t[71]===p?ye=t[72]:(ye=()=>O(p),t[71]=p,t[72]=ye);let be;t[73]!==n||t[74]!==ye?(be=(0,Y.jsx)(Tt,{disabled:n,onClick:ye,children:`Revert commit`}),t[73]=n,t[74]=ye,t[75]=be):be=t[75];let xe;t[76]===m?xe=t[77]:(xe=()=>O(m),t[76]=m,t[77]=xe);let Se;t[78]===Symbol.for(`react.memo_cache_sentinel`)?(Se=(0,Y.jsx)(Sn,{}),t[78]=Se):Se=t[78];let Ce;t[79]!==n||t[80]!==xe?(Ce=(0,Y.jsxs)(Tt,{disabled:n,onClick:xe,children:[Se,`Tag commit…`]}),t[79]=n,t[80]=xe,t[81]=Ce):Ce=t[81];let we;t[82]!==me||t[83]!==ge||t[84]!==ve||t[85]!==be||t[86]!==Ce?(we=(0,Y.jsxs)(rt,{children:[me,ge,ve,be,Ce]}),t[82]=me,t[83]=ge,t[84]=ve,t[85]=be,t[86]=Ce,t[87]=we):we=t[87];let Te;t[88]===Symbol.for(`react.memo_cache_sentinel`)?(Te=(0,Y.jsx)(Ge,{}),t[88]=Te):Te=t[88];let Ee;t[89]===Symbol.for(`react.memo_cache_sentinel`)?(Ee=(0,Y.jsx)(Ve,{children:`Dangerous`}),t[89]=Ee):Ee=t[89];let De;t[90]===g?De=t[91]:(De=()=>O(()=>g(`soft`)),t[90]=g,t[91]=De);let Oe;t[92]!==n||t[93]!==De?(Oe=(0,Y.jsx)(Tt,{disabled:n,onClick:De,children:`Reset soft to commit`}),t[92]=n,t[93]=De,t[94]=Oe):Oe=t[94];let ke;t[95]===g?ke=t[96]:(ke=()=>O(()=>g(`mixed`)),t[95]=g,t[96]=ke);let Ae;t[97]!==n||t[98]!==ke?(Ae=(0,Y.jsx)(Tt,{disabled:n,onClick:ke,children:`Reset mixed to commit`}),t[97]=n,t[98]=ke,t[99]=Ae):Ae=t[99];let je;t[100]===g?je=t[101]:(je=()=>O(()=>g(`hard`)),t[100]=g,t[101]=je);let Ne;t[102]!==n||t[103]!==je?(Ne=(0,Y.jsx)(Tt,{disabled:n,variant:`destructive`,onClick:je,children:`Reset hard to commit`}),t[102]=n,t[103]=je,t[104]=Ne):Ne=t[104];let Pe;t[105]===_?Pe=t[106]:(Pe=()=>O(_),t[105]=_,t[106]=Pe);let Fe;t[107]!==n||t[108]!==Pe?(Fe=(0,Y.jsx)(Tt,{disabled:n,onClick:Pe,children:`Rebase onto this commit`}),t[107]=n,t[108]=Pe,t[109]=Fe):Fe=t[109];let Ie;t[110]===v?Ie=t[111]:(Ie=()=>O(v),t[110]=v,t[111]=Ie);let Le;t[112]!==n||t[113]!==Ie?(Le=(0,Y.jsx)(Tt,{disabled:n,variant:`destructive`,onClick:Ie,children:`Drop commit`}),t[112]=n,t[113]=Ie,t[114]=Le):Le=t[114];let Re;t[115]===y?Re=t[116]:(Re=()=>O(y),t[115]=y,t[116]=Re);let Be;t[117]!==n||t[118]!==Re?(Be=(0,Y.jsx)(Tt,{disabled:n,variant:`destructive`,onClick:Re,children:`Squash commits after this…`}),t[117]=n,t[118]=Re,t[119]=Be):Be=t[119];let He;t[120]!==Oe||t[121]!==Ae||t[122]!==Ne||t[123]!==Fe||t[124]!==Le||t[125]!==Be?(He=(0,Y.jsxs)(rt,{children:[Ee,Oe,Ae,Ne,Fe,Le,Be]}),t[120]=Oe,t[121]=Ae,t[122]=Ne,t[123]=Fe,t[124]=Le,t[125]=Be,t[126]=He):He=t[126];let Ue;t[127]!==ne||t[128]!==de||t[129]!==we||t[130]!==He?(Ue=(0,Y.jsxs)(ze,{align:`end`,className:`w-64`,children:[ne,re,de,K,we,Te,He]}),t[127]=ne,t[128]=de,t[129]=we,t[130]=He,t[131]=Ue):Ue=t[131];let We;return t[132]!==S||t[133]!==b||t[134]!==M||t[135]!==Ue?(We=(0,Y.jsxs)(yt,{open:b,onOpenChange:x,actionsRef:T,children:[M,Ue]},S),t[132]=S,t[133]=b,t[134]=M,t[135]=Ue,t[136]=We):We=t[136],We}function ph(e){return e+1}function mh(e){let t=(0,J.c)(141),{disabled:n,busy:r,canCopyMessage:i,onViewDiff:a,onCompareHead:o,onComparePrevious:s,onCopyHash:c,onCopyMessage:l,onCreateBranch:u,onCheckout:d,onCherryPick:f,onRevert:p,onTag:m,onOpenRemote:h,onReset:g,onRebase:_,onDrop:v,onSquash:y,runAction:b}=e,x=n||r,S;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(S=(0,Y.jsx)(Re,{children:`Commit`}),t[0]=S):S=t[0];let C;t[1]!==a||t[2]!==b?(C=()=>b(a),t[1]=a,t[2]=b,t[3]=C):C=t[3];let w;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(w=(0,Y.jsx)(gn,{}),t[4]=w):w=t[4];let T;t[5]!==x||t[6]!==C?(T=(0,Y.jsxs)(Pt,{disabled:x,onClick:C,children:[w,`View diff`]}),t[5]=x,t[6]=C,t[7]=T):T=t[7];let E;t[8]!==o||t[9]!==b?(E=()=>b(o),t[8]=o,t[9]=b,t[10]=E):E=t[10];let D;t[11]===Symbol.for(`react.memo_cache_sentinel`)?(D=(0,Y.jsx)(gn,{}),t[11]=D):D=t[11];let O;t[12]!==x||t[13]!==E?(O=(0,Y.jsxs)(Pt,{disabled:x,onClick:E,children:[D,`Compare with HEAD`]}),t[12]=x,t[13]=E,t[14]=O):O=t[14];let k;t[15]!==s||t[16]!==b?(k=()=>b(s),t[15]=s,t[16]=b,t[17]=k):k=t[17];let A;t[18]===Symbol.for(`react.memo_cache_sentinel`)?(A=(0,Y.jsx)(gn,{}),t[18]=A):A=t[18];let j;t[19]!==x||t[20]!==k?(j=(0,Y.jsxs)(Pt,{disabled:x,onClick:k,children:[A,`Compare with previous commit`]}),t[19]=x,t[20]=k,t[21]=j):j=t[21];let M;t[22]!==h||t[23]!==b?(M=()=>b(h),t[22]=h,t[23]=b,t[24]=M):M=t[24];let N;t[25]===Symbol.for(`react.memo_cache_sentinel`)?(N=(0,Y.jsx)(hn,{}),t[25]=N):N=t[25];let P;t[26]!==x||t[27]!==M?(P=(0,Y.jsxs)(Pt,{disabled:x,onClick:M,children:[N,`Open on remote`]}),t[26]=x,t[27]=M,t[28]=P):P=t[28];let F;t[29]!==j||t[30]!==P||t[31]!==T||t[32]!==O?(F=(0,Y.jsxs)(Ot,{children:[S,T,O,j,P]}),t[29]=j,t[30]=P,t[31]=T,t[32]=O,t[33]=F):F=t[33];let I;t[34]===Symbol.for(`react.memo_cache_sentinel`)?(I=(0,Y.jsx)(Mt,{}),t[34]=I):I=t[34];let L;t[35]!==c||t[36]!==b?(L=()=>b(c),t[35]=c,t[36]=b,t[37]=L):L=t[37];let R;t[38]===Symbol.for(`react.memo_cache_sentinel`)?(R=(0,Y.jsx)(ae,{}),t[38]=R):R=t[38];let z;t[39]!==x||t[40]!==L?(z=(0,Y.jsxs)(Pt,{disabled:x,onClick:L,children:[R,`Copy commit hash`]}),t[39]=x,t[40]=L,t[41]=z):z=t[41];let B=!i||r,V;t[42]!==l||t[43]!==b?(V=()=>b(l),t[42]=l,t[43]=b,t[44]=V):V=t[44];let ee;t[45]===Symbol.for(`react.memo_cache_sentinel`)?(ee=(0,Y.jsx)(ae,{}),t[45]=ee):ee=t[45];let H;t[46]!==B||t[47]!==V?(H=(0,Y.jsxs)(Pt,{disabled:B,onClick:V,children:[ee,`Copy commit message`]}),t[46]=B,t[47]=V,t[48]=H):H=t[48];let U;t[49]!==z||t[50]!==H?(U=(0,Y.jsxs)(Ot,{children:[z,H]}),t[49]=z,t[50]=H,t[51]=U):U=t[51];let te;t[52]===Symbol.for(`react.memo_cache_sentinel`)?(te=(0,Y.jsx)(Mt,{}),t[52]=te):te=t[52];let ne;t[53]!==u||t[54]!==b?(ne=()=>b(u),t[53]=u,t[54]=b,t[55]=ne):ne=t[55];let re;t[56]===Symbol.for(`react.memo_cache_sentinel`)?(re=(0,Y.jsx)(ue,{}),t[56]=re):re=t[56];let W;t[57]!==x||t[58]!==ne?(W=(0,Y.jsxs)(Pt,{disabled:x,onClick:ne,children:[re,`Create branch from commit…`]}),t[57]=x,t[58]=ne,t[59]=W):W=t[59];let G;t[60]!==d||t[61]!==b?(G=()=>b(d),t[60]=d,t[61]=b,t[62]=G):G=t[62];let ie;t[63]!==x||t[64]!==G?(ie=(0,Y.jsx)(Pt,{disabled:x,onClick:G,children:`Checkout commit`}),t[63]=x,t[64]=G,t[65]=ie):ie=t[65];let oe;t[66]!==f||t[67]!==b?(oe=()=>b(f),t[66]=f,t[67]=b,t[68]=oe):oe=t[68];let se;t[69]!==x||t[70]!==oe?(se=(0,Y.jsx)(Pt,{disabled:x,onClick:oe,children:`Cherry-pick commit`}),t[69]=x,t[70]=oe,t[71]=se):se=t[71];let ce;t[72]!==p||t[73]!==b?(ce=()=>b(p),t[72]=p,t[73]=b,t[74]=ce):ce=t[74];let le;t[75]!==x||t[76]!==ce?(le=(0,Y.jsx)(Pt,{disabled:x,onClick:ce,children:`Revert commit`}),t[75]=x,t[76]=ce,t[77]=le):le=t[77];let de;t[78]!==m||t[79]!==b?(de=()=>b(m),t[78]=m,t[79]=b,t[80]=de):de=t[80];let K;t[81]===Symbol.for(`react.memo_cache_sentinel`)?(K=(0,Y.jsx)(Sn,{}),t[81]=K):K=t[81];let fe;t[82]!==x||t[83]!==de?(fe=(0,Y.jsxs)(Pt,{disabled:x,onClick:de,children:[K,`Tag commit…`]}),t[82]=x,t[83]=de,t[84]=fe):fe=t[84];let pe;t[85]!==W||t[86]!==ie||t[87]!==se||t[88]!==le||t[89]!==fe?(pe=(0,Y.jsxs)(Ot,{children:[W,ie,se,le,fe]}),t[85]=W,t[86]=ie,t[87]=se,t[88]=le,t[89]=fe,t[90]=pe):pe=t[90];let me;t[91]===Symbol.for(`react.memo_cache_sentinel`)?(me=(0,Y.jsx)(Mt,{}),t[91]=me):me=t[91];let he;t[92]===Symbol.for(`react.memo_cache_sentinel`)?(he=(0,Y.jsx)(Re,{children:`Dangerous`}),t[92]=he):he=t[92];let ge;t[93]!==g||t[94]!==b?(ge=()=>b(()=>g(`soft`)),t[93]=g,t[94]=b,t[95]=ge):ge=t[95];let _e;t[96]!==x||t[97]!==ge?(_e=(0,Y.jsx)(Pt,{disabled:x,onClick:ge,children:`Reset soft to commit`}),t[96]=x,t[97]=ge,t[98]=_e):_e=t[98];let ve;t[99]!==g||t[100]!==b?(ve=()=>b(()=>g(`mixed`)),t[99]=g,t[100]=b,t[101]=ve):ve=t[101];let ye;t[102]!==x||t[103]!==ve?(ye=(0,Y.jsx)(Pt,{disabled:x,onClick:ve,children:`Reset mixed to commit`}),t[102]=x,t[103]=ve,t[104]=ye):ye=t[104];let be;t[105]!==g||t[106]!==b?(be=()=>b(()=>g(`hard`)),t[105]=g,t[106]=b,t[107]=be):be=t[107];let xe;t[108]!==x||t[109]!==be?(xe=(0,Y.jsx)(Pt,{disabled:x,variant:`destructive`,onClick:be,children:`Reset hard to commit`}),t[108]=x,t[109]=be,t[110]=xe):xe=t[110];let Se;t[111]!==_||t[112]!==b?(Se=()=>b(_),t[111]=_,t[112]=b,t[113]=Se):Se=t[113];let Ce;t[114]!==x||t[115]!==Se?(Ce=(0,Y.jsx)(Pt,{disabled:x,onClick:Se,children:`Rebase onto this commit`}),t[114]=x,t[115]=Se,t[116]=Ce):Ce=t[116];let we;t[117]!==v||t[118]!==b?(we=()=>b(v),t[117]=v,t[118]=b,t[119]=we):we=t[119];let Te;t[120]!==x||t[121]!==we?(Te=(0,Y.jsx)(Pt,{disabled:x,variant:`destructive`,onClick:we,children:`Drop commit`}),t[120]=x,t[121]=we,t[122]=Te):Te=t[122];let Ee;t[123]!==y||t[124]!==b?(Ee=()=>b(y),t[123]=y,t[124]=b,t[125]=Ee):Ee=t[125];let De;t[126]!==x||t[127]!==Ee?(De=(0,Y.jsx)(Pt,{disabled:x,variant:`destructive`,onClick:Ee,children:`Squash commits after this…`}),t[126]=x,t[127]=Ee,t[128]=De):De=t[128];let Oe;t[129]!==_e||t[130]!==ye||t[131]!==xe||t[132]!==Ce||t[133]!==Te||t[134]!==De?(Oe=(0,Y.jsxs)(Ot,{children:[he,_e,ye,xe,Ce,Te,De]}),t[129]=_e,t[130]=ye,t[131]=xe,t[132]=Ce,t[133]=Te,t[134]=De,t[135]=Oe):Oe=t[135];let ke;return t[136]!==F||t[137]!==U||t[138]!==pe||t[139]!==Oe?(ke=(0,Y.jsxs)(Ne,{className:`w-64`,children:[F,I,U,te,pe,me,Oe]}),t[136]=F,t[137]=U,t[138]=pe,t[139]=Oe,t[140]=ke):ke=t[140],ke}function hh(e){return typeof e==`number`&&Number.isFinite(e)?e:0}function gh(e){let t=(0,J.c)(2),{status:n}=e,r;if(t[0]!==n){let[e,i]=we(n),a=`${e}${i}`.trim();r=(0,Y.jsx)(`span`,{className:`inline-flex w-[2ch] shrink-0 items-center whitespace-pre text-muted-foreground/70`,children:[[`index`,e],[`worktree`,i]].map(e=>{let[t,n]=e;return(0,Y.jsx)(`span`,{className:s(`w-[1ch] text-center whitespace-pre`,U(F(t,n))),children:n||(a?` `:`·`)},t)})}),t[0]=n,t[1]=r}else r=t[1];return r}function _h(e){let t=(0,J.c)(7),{file:n}=e,r=hh(n.linesAdded),i=hh(n.linesDeleted);if(r===0&&i===0)return null;let a;t[0]===r?a=t[1]:(a=r>0?(0,Y.jsxs)(`span`,{className:`text-emerald-500`,children:[`+`,r]}):null,t[0]=r,t[1]=a);let o;t[2]===i?o=t[3]:(o=i>0?(0,Y.jsxs)(`span`,{className:`text-red-500`,children:[`-`,i]}):null,t[2]=i,t[3]=o);let s;return t[4]!==a||t[5]!==o?(s=(0,Y.jsxs)(`span`,{className:`inline-flex min-w-0 gap-2 justify-self-end whitespace-nowrap tabular-nums`,children:[a,o]}),t[4]=a,t[5]=o,t[6]=s):s=t[6],s}function vh(e){let t=(0,J.c)(38),{viewerContextId:n,cwd:r,commit:i,shortHash:a,previousShortHash:o,subject:s,disabled:c,onOpenCommitDiff:l}=e,u;t[0]!==i||t[1]!==r||t[2]!==n?(u=i?tn.gitCommitFiles(n,r,i):[`pico`,`git-commit-files`,n,r,``],t[0]=i,t[1]=r,t[2]=n,t[3]=u):u=t[3];let d;t[4]!==i||t[5]!==r||t[6]!==n?(d=()=>Qt(en(`/api/git-commit-files?cwd=${encodeURIComponent(r)}&commit=${encodeURIComponent(i)}`,{contextId:n})),t[4]=i,t[5]=r,t[6]=n,t[7]=d):d=t[7];let f=!!(!c&&n&&r&&i),p;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(p=[`data`,`isPending`,`error`],t[8]=p):p=t[8];let m;t[9]!==u||t[10]!==d||t[11]!==f?(m={queryKey:u,queryFn:d,enabled:f,notifyOnChangeProps:p},t[9]=u,t[10]=d,t[11]=f,t[12]=m):m=t[12];let h=ee(m),g;t[13]===h.data?.files?g=t[14]:(g=h.data?.files??[],t[13]=h.data?.files,t[14]=g);let _=g;if(h.isPending&&!h.data){let e;return t[15]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsxs)(tp,{className:`px-2 py-1.5`,children:[(0,Y.jsx)(C,{}),` Loading changed files…`]}),t[15]=e):e=t[15],e}if(h.error){let e;t[16]===h.error?e=t[17]:(e=ft(h.error,`Failed to load changed files`),t[16]=h.error,t[17]=e);let n;return t[18]===e?n=t[19]:(n=(0,Y.jsx)(tp,{tone:`destructive`,className:`px-2 py-1.5`,children:e}),t[18]=e,t[19]=n),n}if(_.length===0)return null;let v;t[20]===Symbol.for(`react.memo_cache_sentinel`)?(v=(0,Y.jsx)(`div`,{className:`font-sans text-[11px] font-medium tracking-[0.04em] text-muted-foreground uppercase`,children:`Changed files`}),t[20]=v):v=t[20];let y;if(t[21]!==i||t[22]!==c||t[23]!==_||t[24]!==l||t[25]!==o||t[26]!==a||t[27]!==s){let e;t[29]!==i||t[30]!==c||t[31]!==l||t[32]!==o||t[33]!==a||t[34]!==s?(e=e=>(0,Y.jsxs)(`button`,{type:`button`,className:`grid min-w-0 grid-cols-[auto_minmax(0,1fr)_auto] items-baseline gap-2 border-b border-border/60 px-2 py-1.5 text-left last:border-b-0 hover:bg-muted/70 focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none`,disabled:c,onClick:()=>{l?.({commit:i,shortHash:a,subject:s,mode:`commit`,path:e.path,previousPath:e.previousPath,leftRevisionLabel:o||`${a}^`,rightRevisionLabel:a})},children:[(0,Y.jsx)(gh,{status:e.status}),(0,Y.jsx)(`span`,{className:`min-w-0 truncate`,children:e.previousPath?(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:e.previousPath}),(0,Y.jsx)(`span`,{className:`text-muted-foreground/70`,children:` → `}),(0,Y.jsx)(`span`,{children:e.path})]}):e.path}),(0,Y.jsxs)(`span`,{className:`inline-flex min-w-0 items-center gap-2 justify-self-end`,children:[(0,Y.jsx)(_h,{file:e}),(0,Y.jsx)(mn,{className:`size-3.5 shrink-0 text-muted-foreground/70`})]})]},`${e.previousPath||``}:${e.path}`),t[29]=i,t[30]=c,t[31]=l,t[32]=o,t[33]=a,t[34]=s,t[35]=e):e=t[35],y=_.map(e),t[21]=i,t[22]=c,t[23]=_,t[24]=l,t[25]=o,t[26]=a,t[27]=s,t[28]=y}else y=t[28];let b;return t[36]===y?b=t[37]:(b=(0,Y.jsxs)(`div`,{className:`grid gap-1 pt-1`,children:[v,(0,Y.jsx)(`div`,{className:`grid overflow-hidden rounded-lg border border-border/70 bg-background/60`,children:y})]}),t[36]=y,t[37]=b),b}function yh(e){return bh(e)}function bh(e){let t=(0,J.c)(250),{viewerContextId:n,cwd:r,graphWidth:i,line:a,value:o,onOpenCommitDiff:c}=e,l=wt(a),u=dn(),[d,p]=q.useReducer(Xm,Ym),m=q.useRef(void 0),h=q.useRef(void 0),g=q.useRef(null),{bottomHeight:_,onScroll:v,setScrollElement:y,topHeight:b}=ut(),x=l.subject.trim(),S=ie(l.relativeDate),C=se(l.fullDate),w=he(l.stats,`insertions`),T=he(l.stats,`deletions`),E=l.hash||l.fullHash.slice(0,7),D=!!(n&&r&&l.fullHash),{hashCopied:O,messageCopied:k,formDialog:A,confirmDialog:j,contextMenuOpen:M,contextMenuKey:N}=d,P,F;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(P=()=>()=>{typeof m.current==`number`&&window.clearTimeout(m.current),typeof h.current==`number`&&window.clearTimeout(h.current)},F=[],t[0]=P,t[1]=F):(P=t[0],F=t[1]),q.useEffect(P,F);let I;t[2]!==r||t[3]!==n?(I=async e=>await Qt(en(`/api/git-commit-action`,{contextId:n}),{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({cwd:r,...e})}),t[2]=r,t[3]=n,t[4]=I):I=t[4];let L;t[5]!==r||t[6]!==u||t[7]!==n?(L=async(e,t)=>{await u.invalidateQueries({queryKey:tn.gitStatus(n,r),exact:!0,refetchType:`active`}),await We({queryClient:u,viewerContextId:n,cwd:r}),ln.success(t.label||uh(t.action))},t[5]=r,t[6]=u,t[7]=n,t[8]=L):L=t[8];let R;t[9]!==I||t[10]!==L?(R={mutationFn:I,onSuccess:L,onError:wh},t[9]=I,t[10]=L,t[11]=R):R=t[11];let z=te(R),B;t[12]!==r||t[13]!==l.fullHash||t[14]!==n?(B=async e=>await Qt(en(`/api/git-checkout`,{contextId:n}),{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({cwd:r,branch:e,create:!0,startPoint:l.fullHash})}),t[12]=r,t[13]=l.fullHash,t[14]=n,t[15]=B):B=t[15];let V;t[16]!==r||t[17]!==u||t[18]!==n?(V=async()=>{await u.invalidateQueries({queryKey:tn.gitStatus(n,r),exact:!0,refetchType:`active`}),await We({queryClient:u,viewerContextId:n,cwd:r}),ln.success(`Created and checked out branch`)},t[16]=r,t[17]=u,t[18]=n,t[19]=V):V=t[19];let ee;t[20]!==B||t[21]!==V?(ee={mutationFn:B,onSuccess:V,onError:Ch},t[20]=B,t[21]=V,t[22]=ee):ee=t[22];let H=te(ee),U;t[23]!==p||t[24]!==l.fullHash?(U=()=>{l.fullHash&&Qe(l.fullHash).then(e=>{e&&(p({type:`set-hash-copied`,copied:!0}),typeof m.current==`number`&&window.clearTimeout(m.current),m.current=window.setTimeout(()=>{p({type:`set-hash-copied`,copied:!1})},1200))})},t[23]=p,t[24]=l.fullHash,t[25]=U):U=t[25];let re=U,G;t[26]!==p||t[27]!==x?(G=()=>{x&&Qe(x).then(e=>{e&&(p({type:`set-message-copied`,copied:!0}),typeof h.current==`number`&&window.clearTimeout(h.current),h.current=window.setTimeout(()=>{p({type:`set-message-copied`,copied:!1})},1200))})},t[26]=p,t[27]=x,t[28]=G):G=t[28];let oe=G,ce;t[29]!==c||t[30]!==l.fullHash||t[31]!==E||t[32]!==x?(ce=e=>{l.fullHash&&c?.({commit:l.fullHash,shortHash:E,subject:x,mode:e})},t[29]=c,t[30]=l.fullHash,t[31]=E,t[32]=x,t[33]=ce):ce=t[33];let le=ce,ue;t[34]!==r||t[35]!==l.fullHash||t[36]!==n?(ue=()=>{l.fullHash&&Qt(en(`/api/git-commit-remote-url?cwd=${encodeURIComponent(r)}&commit=${encodeURIComponent(l.fullHash)}`,{contextId:n})).then(Sh).catch(xh)},t[34]=r,t[35]=l.fullHash,t[36]=n,t[37]=ue):ue=t[37];let de=ue,K;t[38]!==j||t[39]!==p||t[40]!==z?(K=()=>{j&&(z.mutate(j),p({type:`set-confirm-dialog`,confirmDialog:null}))},t[38]=j,t[39]=p,t[40]=z,t[41]=K):K=t[41];let fe=K,pe;t[42]!==H||t[43]!==p||t[44]!==A||t[45]!==z||t[46]!==l.fullHash?(pe=e=>{if(e.preventDefault(),!A||!l.fullHash)return;let t=A.value.trim();t&&(A.kind===`branch`?H.mutate(t):A.kind===`tag`?z.mutate({action:`tag`,commit:l.fullHash,tagName:t,label:`Tagged commit`}):z.mutate({action:`squash`,commit:l.fullHash,message:t,label:`Squashed commits`}),p({type:`set-form-dialog`,formDialog:null}))},t[42]=H,t[43]=p,t[44]=A,t[45]=z,t[46]=l.fullHash,t[47]=pe):pe=t[47];let me=pe,ge;t[48]===p?ge=t[49]:(ge=e=>{p({type:`set-confirm-dialog`,confirmDialog:e})},t[48]=p,t[49]=ge);let _e=ge,ve;t[50]!==l.fullHash||t[51]!==E||t[52]!==_e?(ve=e=>{l.fullHash&&_e({action:`reset`,commit:l.fullHash,resetMode:e,label:`Reset branch (${e})`,title:`Reset branch to ${E}?`,description:e===`hard`?`Hard reset moves the current branch and discards working tree and staged changes. This cannot be undone from Pico.`:e===`soft`?`Soft reset moves the current branch and keeps changes staged.`:`Mixed reset moves the current branch and keeps changes in the working tree.`,confirmLabel:`Reset ${e}`,destructive:e===`hard`})},t[50]=l.fullHash,t[51]=E,t[52]=_e,t[53]=ve):ve=t[53];let be=ve;if(!l.hash&&!l.subject){let e;t[54]===l.subject?e=t[55]:(e=l.subject?(0,Y.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-foreground`,children:l.subject}):null,t[54]=l.subject,t[55]=e);let n;return t[56]===e?n=t[57]:(n=(0,Y.jsx)(`div`,{className:`flex h-8 max-w-full min-w-0 items-center text-[13px] leading-5`,children:e}),t[56]=e,t[57]=n),n}let xe;t[58]===Symbol.for(`react.memo_cache_sentinel`)?(xe=s(`h-8 min-h-8 w-full items-center gap-2 rounded-none px-1.5 py-0 text-[13px] leading-5 font-normal transition-[background-color,box-shadow,color] hover:no-underline focus-visible:ring-0 aria-expanded:bg-muted/50 **:data-[slot=accordion-trigger-icon]:size-4`),t[58]=xe):xe=t[58];let Se;t[59]===i?Se=t[60]:(Se={paddingLeft:i},t[59]=i,t[60]=Se);let Ce=x||l.hash||`Commit`,we;t[61]!==Se||t[62]!==Ce?(we=(0,Y.jsx)(Et,{headerClassName:`min-w-0`,className:xe,children:(0,Y.jsx)(`span`,{className:`min-w-0 flex-1 truncate pr-8 text-foreground`,style:Se,children:Ce})}),t[61]=Se,t[62]=Ce,t[63]=we):we=t[63];let Te=we,Ee=!D,De,Oe,ke;t[64]===le?(De=t[65],Oe=t[66],ke=t[67]):(De=()=>le(`commit`),Oe=()=>le(`head`),ke=()=>le(`previous`),t[64]=le,t[65]=De,t[66]=Oe,t[67]=ke);let Ae;t[68]===l.fullHash?Ae=t[69]:(Ae=()=>{Qe(l.fullHash)},t[68]=l.fullHash,t[69]=Ae);let je;t[70]===x?je=t[71]:(je=()=>{Qe(x)},t[70]=x,t[71]=je);let Me;t[72]!==p||t[73]!==E||t[74]!==x?(Me=()=>{p({type:`set-form-dialog`,formDialog:{kind:`branch`,title:`Create branch from commit`,description:`Create and check out a new branch at ${E}.`,value:ch(x,E)}})},t[72]=p,t[73]=E,t[74]=x,t[75]=Me):Me=t[75];let Ne,Fe,Ie;t[76]!==l.fullHash||t[77]!==E||t[78]!==_e?(Ne=()=>{l.fullHash&&_e({action:`checkout`,commit:l.fullHash,label:`Checked out commit`,title:`Checkout ${E}?`,description:`This switches to a detached HEAD at the selected commit. Commit or stash local changes first.`,confirmLabel:`Checkout`})},Fe=()=>{l.fullHash&&_e({action:`cherry-pick`,commit:l.fullHash,label:`Cherry-picked commit`,title:`Cherry-pick ${E}?`,description:`This applies the selected commit on top of the current branch.`,confirmLabel:`Cherry-pick`})},Ie=()=>{l.fullHash&&_e({action:`revert`,commit:l.fullHash,label:`Reverted commit`,title:`Revert ${E}?`,description:`This creates a new commit that reverses the selected commit.`,confirmLabel:`Revert`})},t[76]=l.fullHash,t[77]=E,t[78]=_e,t[79]=Ne,t[80]=Fe,t[81]=Ie):(Ne=t[79],Fe=t[80],Ie=t[81]);let Le;t[82]!==p||t[83]!==E?(Le=()=>{p({type:`set-form-dialog`,formDialog:{kind:`tag`,title:`Tag commit`,description:`Create a lightweight tag at ${E}.`,value:lh(E)}})},t[82]=p,t[83]=E,t[84]=Le):Le=t[84];let Re,ze;t[85]!==l.fullHash||t[86]!==E||t[87]!==_e?(Re=()=>{l.fullHash&&_e({action:`rebase`,commit:l.fullHash,label:`Rebased branch`,title:`Rebase onto ${E}?`,description:`This rebases the current branch onto the selected commit. Conflicts may need to be resolved from the terminal.`,confirmLabel:`Rebase`,destructive:!0})},ze=()=>{l.fullHash&&_e({action:`drop`,commit:l.fullHash,label:`Dropped commit`,title:`Drop ${E}?`,description:`This rewrites the current branch by replaying commits after the selected commit onto its parent.`,confirmLabel:`Drop commit`,destructive:!0})},t[85]=l.fullHash,t[86]=E,t[87]=_e,t[88]=Re,t[89]=ze):(Re=t[88],ze=t[89]);let Ve;t[90]!==p||t[91]!==E||t[92]!==x?(Ve=()=>{p({type:`set-form-dialog`,formDialog:{kind:`squash`,title:`Squash commits after this commit`,description:`Soft reset to ${E}, then create one replacement commit from all newer commits.`,value:x?`Squash changes after ${x}`:`Squash after ${E}`}})},t[90]=p,t[91]=E,t[92]=x,t[93]=Ve):Ve=t[93];let He=!!x,Ue=z.isPending||H.isPending,Ge;t[94]!==de||t[95]!==be||t[96]!==Ee||t[97]!==De||t[98]!==Oe||t[99]!==ke||t[100]!==Ae||t[101]!==je||t[102]!==Me||t[103]!==Ne||t[104]!==Fe||t[105]!==Ie||t[106]!==Le||t[107]!==Re||t[108]!==ze||t[109]!==Ve||t[110]!==He||t[111]!==Ue?(Ge={disabled:Ee,onViewDiff:De,onCompareHead:Oe,onComparePrevious:ke,onCopyHash:Ae,onCopyMessage:je,onCreateBranch:Me,onCheckout:Ne,onCherryPick:Fe,onRevert:Ie,onTag:Le,onOpenRemote:de,onReset:be,onRebase:Re,onDrop:ze,onSquash:Ve,canCopyMessage:He,busy:Ue},t[94]=de,t[95]=be,t[96]=Ee,t[97]=De,t[98]=Oe,t[99]=ke,t[100]=Ae,t[101]=je,t[102]=Me,t[103]=Ne,t[104]=Fe,t[105]=Ie,t[106]=Le,t[107]=Re,t[108]=ze,t[109]=Ve,t[110]=He,t[111]=Ue,t[112]=Ge):Ge=t[112];let Ke=Ge,qe;t[113]===p?qe=t[114]:(qe=e=>{g.current?.close(),g.current?.unmount(),p({type:`reset-context-menu`}),e()},t[113]=p,t[114]=qe);let Ye=qe,Xe;t[115]===p?Xe=t[116]:(Xe=e=>{p({type:`set-context-menu-open`,open:e})},t[115]=p,t[116]=Xe);let Ze;t[117]===Te?Ze=t[118]:(Ze=(0,Y.jsx)(ye,{render:Te}),t[117]=Te,t[118]=Ze);let $e;t[119]!==Ke||t[120]!==Ye?($e=(0,Y.jsx)(mh,{...Ke,runAction:Ye}),t[119]=Ke,t[120]=Ye,t[121]=$e):$e=t[121];let et;t[122]!==N||t[123]!==M||t[124]!==Xe||t[125]!==Ze||t[126]!==$e?(et=(0,Y.jsx)(`div`,{className:`group/commit-row relative min-w-0`,children:(0,Y.jsxs)(Je,{open:M,onOpenChange:Xe,actionsRef:g,children:[Ze,$e]},N)}),t[122]=N,t[123]=M,t[124]=Xe,t[125]=Ze,t[126]=$e,t[127]=et):et=t[127];let tt;t[128]===i?tt=t[129]:(tt={paddingLeft:i},t[128]=i,t[129]=tt);let nt=!D,rt;t[130]===le?rt=t[131]:(rt=()=>le(`commit`),t[130]=le,t[131]=rt);let at;t[132]===Symbol.for(`react.memo_cache_sentinel`)?(at=(0,Y.jsx)(gn,{}),t[132]=at):at=t[132];let ot;t[133]!==nt||t[134]!==rt?(ot=(0,Y.jsxs)(qt,{type:`button`,size:`xs`,variant:`outline`,disabled:nt,onClick:rt,children:[at,`View diff`]}),t[133]=nt,t[134]=rt,t[135]=ot):ot=t[135];let st;t[136]===Ke?st=t[137]:(st=(0,Y.jsx)(fh,{...Ke}),t[136]=Ke,t[137]=st);let ct;t[138]!==ot||t[139]!==st?(ct=(0,Y.jsxs)(`div`,{className:`flex min-w-0 flex-wrap items-center gap-1.5 font-sans`,children:[ot,st]}),t[138]=ot,t[139]=st,t[140]=ct):ct=t[140];let lt;t[141]!==re||t[142]!==C||t[143]!==O||t[144]!==l.author||t[145]!==l.fullHash||t[146]!==E||t[147]!==S?(lt=l.author||S||l.fullHash?(0,Y.jsxs)(`div`,{className:`flex max-w-full flex-wrap items-center gap-x-2 gap-y-1 text-muted-foreground`,children:[l.author?(0,Y.jsx)(`span`,{children:l.author}):null,l.author&&S?(0,Y.jsx)(`span`,{"aria-hidden":!0,children:`·`}):null,S?(0,Y.jsx)(f,{title:C,side:`top`,children:(0,Y.jsx)(`span`,{children:S})}):null,(l.author||S)&&l.fullHash?(0,Y.jsx)(`span`,{"aria-hidden":!0,children:`·`}):null,l.fullHash?(0,Y.jsxs)(`span`,{className:`inline-flex min-w-0 items-center gap-1.5`,children:[(0,Y.jsx)(`span`,{className:`min-w-0 truncate`,children:E}),(0,Y.jsx)(f,{title:O?`Copied`:`Copy full commit hash`,side:`top`,children:(0,Y.jsx)(`button`,{type:`button`,"aria-label":`Copy full commit hash`,className:`inline-flex size-5 shrink-0 items-center justify-center rounded-sm text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,onClick:e=>{e.preventDefault(),e.stopPropagation(),re()},children:O?(0,Y.jsx)(W,{className:`size-3.5 text-emerald-500`}):(0,Y.jsx)(ae,{className:`size-3.5`})})})]}):null]}):null,t[141]=re,t[142]=C,t[143]=O,t[144]=l.author,t[145]=l.fullHash,t[146]=E,t[147]=S,t[148]=lt):lt=t[148];let dt=x||`No commit message`,ft;t[149]!==oe||t[150]!==k||t[151]!==x?(ft=x?(0,Y.jsx)(f,{title:k?`Copied`:`Copy commit message`,side:`top`,children:(0,Y.jsx)(`button`,{type:`button`,"aria-label":`Copy commit message`,className:`ml-1 inline-flex size-4 items-center justify-center rounded-sm align-middle text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,onClick:e=>{e.preventDefault(),e.stopPropagation(),oe()},children:k?(0,Y.jsx)(W,{className:`size-3.5 text-emerald-500`}):(0,Y.jsx)(ae,{className:`size-3.5`})})}):null,t[149]=oe,t[150]=k,t[151]=x,t[152]=ft):ft=t[152];let pt;t[153]!==dt||t[154]!==ft?(pt=(0,Y.jsxs)(`div`,{className:`max-w-full break-words whitespace-normal text-foreground`,children:[dt,ft]}),t[153]=dt,t[154]=ft,t[155]=pt):pt=t[155];let mt=w===1?``:`s`,ht;t[156]!==w||t[157]!==mt?(ht=(0,Y.jsxs)(`span`,{className:`text-emerald-500`,children:[`+`,w,` addition`,mt]}),t[156]=w,t[157]=mt,t[158]=ht):ht=t[158];let _t=T===1?``:`s`,vt;t[159]!==T||t[160]!==_t?(vt=(0,Y.jsxs)(`span`,{className:`text-red-400`,children:[`-`,T,` deletion`,_t]}),t[159]=T,t[160]=_t,t[161]=vt):vt=t[161];let yt;t[162]!==ht||t[163]!==vt?(yt=(0,Y.jsxs)(`div`,{className:`flex min-w-0 flex-wrap items-center gap-x-3 gap-y-1`,children:[ht,vt]}),t[162]=ht,t[163]=vt,t[164]=yt):yt=t[164];let bt;t[165]!==D||t[166]!==r||t[167]!==c||t[168]!==l.fullHash||t[169]!==l.parents||t[170]!==E||t[171]!==x||t[172]!==n?(bt=l.fullHash?(0,Y.jsx)(vh,{viewerContextId:n,cwd:r,commit:l.fullHash,shortHash:E,previousShortHash:l.parents[0]?.slice(0,7)||``,subject:x,disabled:!D,onOpenCommitDiff:c}):null,t[165]=D,t[166]=r,t[167]=c,t[168]=l.fullHash,t[169]=l.parents,t[170]=E,t[171]=x,t[172]=n,t[173]=bt):bt=t[173];let xt;t[174]!==tt||t[175]!==ct||t[176]!==lt||t[177]!==pt||t[178]!==yt||t[179]!==bt?(xt=(0,Y.jsxs)(`div`,{className:`grid content-start gap-1.5 pt-1 text-xs leading-4`,style:tt,children:[ct,lt,pt,yt,bt]}),t[174]=tt,t[175]=ct,t[176]=lt,t[177]=pt,t[178]=yt,t[179]=bt,t[180]=xt):xt=t[180];let St;t[181]!==v||t[182]!==y||t[183]!==xt?(St=(0,Y.jsx)(`div`,{ref:y,className:`h-full overflow-y-auto pr-2 pb-2`,onScroll:v,children:xt}),t[181]=v,t[182]=y,t[183]=xt,t[184]=St):St=t[184];let Ct;t[185]!==_||t[186]!==b?(Ct=(0,Y.jsx)(Pe,{bottomHeight:_,topHeight:b}),t[185]=_,t[186]=b,t[187]=Ct):Ct=t[187];let Tt;t[188]!==St||t[189]!==Ct?(Tt=(0,Y.jsxs)(Be,{className:`relative h-[200px] border-b border-border/70 bg-muted/50 p-0`,children:[St,Ct]}),t[188]=St,t[189]=Ct,t[190]=Tt):Tt=t[190];let Dt=A!==null,Ot;t[191]===p?Ot=t[192]:(Ot=e=>{e||p({type:`set-form-dialog`,formDialog:null})},t[191]=p,t[192]=Ot);let kt=A?.title||`Commit action`,At;t[193]===kt?At=t[194]:(At=(0,Y.jsx)(Jt,{children:kt}),t[193]=kt,t[194]=At);let jt=A?.description,Mt;t[195]===jt?Mt=t[196]:(Mt=(0,Y.jsx)(on,{children:jt}),t[195]=jt,t[196]=Mt);let Nt;t[197]!==At||t[198]!==Mt?(Nt=(0,Y.jsxs)(an,{children:[At,Mt]}),t[197]=At,t[198]=Mt,t[199]=Nt):Nt=t[199];let Pt;t[200]!==p||t[201]!==A?(Pt=A?.kind===`squash`?(0,Y.jsx)(ne,{value:A.value,rows:4,onChange:e=>{p({type:`set-form-dialog-value`,value:e.target.value})}}):(0,Y.jsx)(gt,{value:A?.value||``,onChange:e=>{p({type:`set-form-dialog-value`,value:e.target.value})}}),t[200]=p,t[201]=A,t[202]=Pt):Pt=t[202];let Ft;t[203]===p?Ft=t[204]:(Ft=(0,Y.jsx)(qt,{type:`button`,variant:`outline`,onClick:()=>{p({type:`set-form-dialog`,formDialog:null})},children:`Cancel`}),t[203]=p,t[204]=Ft);let It;t[205]===A?.value?It=t[206]:(It=A?.value.trim(),t[205]=A?.value,t[206]=It);let Lt=!It,Rt=A?.kind===`branch`?`Create branch`:A?.kind===`tag`?`Create tag`:`Squash`,zt;t[207]!==Lt||t[208]!==Rt?(zt=(0,Y.jsx)(qt,{type:`submit`,disabled:Lt,children:Rt}),t[207]=Lt,t[208]=Rt,t[209]=zt):zt=t[209];let Bt;t[210]!==Ft||t[211]!==zt?(Bt=(0,Y.jsxs)(Xt,{children:[Ft,zt]}),t[210]=Ft,t[211]=zt,t[212]=Bt):Bt=t[212];let Vt;t[213]!==me||t[214]!==Nt||t[215]!==Pt||t[216]!==Bt?(Vt=(0,Y.jsx)(rn,{className:`sm:max-w-md`,children:(0,Y.jsxs)(`form`,{className:`grid gap-4`,onSubmit:me,children:[Nt,Pt,Bt]})}),t[213]=me,t[214]=Nt,t[215]=Pt,t[216]=Bt,t[217]=Vt):Vt=t[217];let Ht;t[218]!==Dt||t[219]!==Ot||t[220]!==Vt?(Ht=(0,Y.jsx)(Zt,{open:Dt,focusPromptOnClose:!1,onOpenChange:Ot,children:Vt}),t[218]=Dt,t[219]=Ot,t[220]=Vt,t[221]=Ht):Ht=t[221];let Ut=j!==null,Wt;t[222]===p?Wt=t[223]:(Wt=e=>{e||p({type:`set-confirm-dialog`,confirmDialog:null})},t[222]=p,t[223]=Wt);let Gt;t[224]===Symbol.for(`react.memo_cache_sentinel`)?(Gt=(0,Y.jsx)(Lm,{children:(0,Y.jsx)(un,{})}),t[224]=Gt):Gt=t[224];let Kt=j?.title||`Run commit action?`,Yt;t[225]===Kt?Yt=t[226]:(Yt=(0,Y.jsx)(Rm,{children:Kt}),t[225]=Kt,t[226]=Yt);let $t=j?.description,nn;t[227]===$t?nn=t[228]:(nn=(0,Y.jsx)(zm,{children:$t}),t[227]=$t,t[228]=nn);let sn;t[229]!==Yt||t[230]!==nn?(sn=(0,Y.jsxs)(Fm,{children:[Gt,Yt,nn]}),t[229]=Yt,t[230]=nn,t[231]=sn):sn=t[231];let cn;t[232]===Symbol.for(`react.memo_cache_sentinel`)?(cn=(0,Y.jsx)(Vm,{children:`Cancel`}),t[232]=cn):cn=t[232];let fn=j?.destructive?`destructive`:`default`,pn=j?.confirmLabel||`Continue`,mn;t[233]!==fe||t[234]!==fn||t[235]!==pn?(mn=(0,Y.jsxs)(Im,{children:[cn,(0,Y.jsx)(Bm,{variant:fn,onClick:fe,children:pn})]}),t[233]=fe,t[234]=fn,t[235]=pn,t[236]=mn):mn=t[236];let hn;t[237]!==sn||t[238]!==mn?(hn=(0,Y.jsxs)(Pm,{children:[sn,mn]}),t[237]=sn,t[238]=mn,t[239]=hn):hn=t[239];let _n;t[240]!==Ut||t[241]!==Wt||t[242]!==hn?(_n=(0,Y.jsx)(jm,{open:Ut,onOpenChange:Wt,children:hn}),t[240]=Ut,t[241]=Wt,t[242]=hn,t[243]=_n):_n=t[243];let vn;return t[244]!==et||t[245]!==Tt||t[246]!==Ht||t[247]!==_n||t[248]!==o?(vn=(0,Y.jsxs)(it,{value:o,className:`border-0`,children:[et,Tt,Ht,_n]}),t[244]=et,t[245]=Tt,t[246]=Ht,t[247]=_n,t[248]=o,t[249]=vn):vn=t[249],vn}function xh(e){ln.error(ft(e,`Failed to open remote commit`))}function Sh(e){window.open(e.remoteUrl,`_blank`,`noopener,noreferrer`)}function Ch(e){ln.error(ft(e,`Failed to create branch`))}function wh(e,t){ln.error(ft(e,`Failed to ${t.label}`))}function Th(e){let t=(0,J.c)(29),{viewerContextId:n,cwd:r,lines:i,unpushedCommitHashes:a,onOpenCommitDiff:o}=e,{maxLaneCount:s,rows:c}=eh(i),l=Math.max(24,s*qm+4),u=c.map(Eh),d;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(d=[],t[0]=d):d=t[0];let[f,p]=q.useState(d),m=f.filter(e=>u.includes(e)),h=nh(c,m),g;t[1]!==i||t[2]!==a||t[3]!==m?(g=(0,Y.jsx)(dh,{lines:i,openCommitValues:m,unpushedCommitHashes:a}),t[1]=i,t[2]=a,t[3]=m,t[4]=g):g=t[4];let _;t[5]===p?_=t[6]:(_=e=>{p(e.slice(-1))},t[5]=p,t[6]=_);let v;if(t[7]!==r||t[8]!==l||t[9]!==i||t[10]!==o||t[11]!==h||t[12]!==u||t[13]!==n){let e;t[15]!==r||t[16]!==l||t[17]!==o||t[18]!==h||t[19]!==u||t[20]!==n?(e=(e,t)=>(0,Y.jsx)(`div`,{className:`min-w-0`,style:{minHeight:h[t]??Gm},children:(0,Y.jsx)(yh,{viewerContextId:n,cwd:r,graphWidth:l,line:e,value:u[t]??`${t}`,onOpenCommitDiff:o})},u[t]??e),t[15]=r,t[16]=l,t[17]=o,t[18]=h,t[19]=u,t[20]=n,t[21]=e):e=t[21],v=i.map(e),t[7]=r,t[8]=l,t[9]=i,t[10]=o,t[11]=h,t[12]=u,t[13]=n,t[14]=v}else v=t[14];let y;t[22]!==_||t[23]!==v||t[24]!==m?(y=(0,Y.jsx)(bt,{multiple:!0,value:m,onValueChange:_,className:`grid min-w-0 gap-0`,children:v}),t[22]=_,t[23]=v,t[24]=m,t[25]=y):y=t[25];let b;return t[26]!==g||t[27]!==y?(b=(0,Y.jsxs)(`div`,{className:`relative min-w-0`,children:[g,y]}),t[26]=g,t[27]=y,t[28]=b):b=t[28],b}function Eh(e,t){return th(e,t)}function Dh(e){let t=(0,J.c)(11),{onRestoreEmbedded:n}=e,[i,o]=q.useState(!1),s;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(s=()=>o(!1),t[0]=s):s=t[0];let c=s,l;t[1]===Symbol.for(`react.memo_cache_sentinel`)?(l=e=>o(e),t[1]=l):l=t[1];let u;t[2]===n?u=t[3]:(u=()=>{c(),n()},t[2]=n,t[3]=u);let d;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(d=(0,Y.jsx)(vn,{className:`size-4`}),t[4]=d):d=t[4];let f;t[5]===u?f=t[6]:(f=(0,Y.jsx)(_,{render:(0,Y.jsx)(qt,{type:`button`,variant:`ghost`,size:`icon`,className:`size-8 shrink-0`,"aria-label":`Restore history accordion`,onPointerDown:c,onClick:u,children:d})}),t[5]=u,t[6]=f);let p;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(p=(0,Y.jsx)(r,{children:`Restore history accordion`}),t[7]=p):p=t[7];let m;return t[8]!==f||t[9]!==i?(m=(0,Y.jsxs)(a,{open:i,onOpenChange:l,children:[f,p]}),t[8]=f,t[9]=i,t[10]=m):m=t[10],m}function Oh(e){let t=(0,J.c)(55),{viewerContextId:n,cwd:r,active:i,onOpenCommitDiff:a,onRestoreEmbedded:o,embedded:s,flush:c}=e,l=s===void 0?!1:s,u=c===void 0?!1:c,d=xt(r),[f,p]=q.useState(50),m=q.useRef(null),h;t[0]===p?h=t[1]:(h=()=>{p(50)},t[0]=p,t[1]=h),q.useEffect(h,[d]);let g=tn.gitCommits(n,d),_=re({viewerContextId:n,cwd:d,scope:`commits`,commitsLimit:f}),v=!!(i&&n&&d),y;t[2]===g?y=t[3]:(y=(e,t)=>{let n=t?.queryKey;return Array.isArray(n)&&n.length>=g.length&&g.every((e,t)=>n[t]===e)?e:void 0},t[2]=g,t[3]=y);let b;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(b=[`data`,`isFetching`,`isPending`,`error`],t[4]=b):b=t[4];let x;t[5]!==_||t[6]!==v||t[7]!==y?(x={..._,enabled:v,placeholderData:y,notifyOnChangeProps:b},t[5]=_,t[6]=v,t[7]=y,t[8]=x):x=t[8];let S=ee(x),w=S.data,T=w?.commits,E=!!w?.commitsHasMore,D;t[9]===T?D=t[10]:(D=Array.isArray(T)?Ft(T):``,t[9]=T,t[10]=D);let O=D,k;t[11]===w?.unpushedCommitHashes?k=t[12]:(k=w?.unpushedCommitHashes??[],t[11]=w?.unpushedCommitHashes,t[12]=k);let A;t[13]===k?A=t[14]:(A=new Set(k),t[13]=k,t[14]=A);let j=A,M;t[15]!==i||t[16]!==E||t[17]!==S.isFetching||t[18]!==p?(M=()=>{let e=m.current;if(!e||!i||!E||S.isFetching||typeof IntersectionObserver>`u`)return;let t=!1,n=new IntersectionObserver(e=>{let[n]=e;!n?.isIntersecting||t||(t=!0,p(kh))},{rootMargin:`320px 0px`});return n.observe(e),()=>n.disconnect()},t[15]=i,t[16]=E,t[17]=S.isFetching,t[18]=p,t[19]=M):M=t[19];let N;t[20]!==i||t[21]!==E||t[22]!==S.isFetching||t[23]!==d?(N=[i,E,S.isFetching,d],t[20]=i,t[21]=E,t[22]=S.isFetching,t[23]=d,t[24]=N):N=t[24],q.useEffect(M,N);let P;t[25]!==T||t[26]!==E||t[27]!==S.error||t[28]!==S.isFetching||t[29]!==S.isPending||t[30]!==d||t[31]!==a||t[32]!==j||t[33]!==n?(P=d?n?S.isPending&&T===void 0||S.isFetching&&T===null?(0,Y.jsxs)(tp,{className:`px-3 py-2.5`,children:[(0,Y.jsx)(C,{}),` Loading commits…`]}):S.error?(0,Y.jsx)(tp,{tone:`destructive`,className:`px-3 py-2.5`,children:ft(S.error,`Failed to load commits`)}):T===null?(0,Y.jsx)(tp,{className:`px-3 py-2.5`,children:`No git repository detected.`}):Array.isArray(T)&&T.length>0?(0,Y.jsxs)(`div`,{className:`grid min-w-0 gap-0`,children:[(0,Y.jsx)(Th,{viewerContextId:n,cwd:d,lines:T,unpushedCommitHashes:j,onOpenCommitDiff:a}),E?(0,Y.jsx)(`div`,{ref:m,className:`flex min-h-8 items-center`,children:S.isFetching?(0,Y.jsxs)(`div`,{role:`status`,"aria-label":`Loading more commits`,className:`inline-flex items-center gap-2 px-1 text-xs text-muted-foreground`,children:[(0,Y.jsx)(C,{size:`xs`}),`Loading more commits…`]}):null}):null]}):(0,Y.jsx)(tp,{className:`px-3 py-2.5`,children:`No commits on this branch yet.`}):(0,Y.jsx)(tp,{className:`px-3 py-2.5`,children:`Waiting for viewer context…`}):(0,Y.jsx)(tp,{className:`px-3 py-2.5`,children:`No directory selected.`}),t[25]=T,t[26]=E,t[27]=S.error,t[28]=S.isFetching,t[29]=S.isPending,t[30]=d,t[31]=a,t[32]=j,t[33]=n,t[34]=P):P=t[34];let F=P;if(l){let e;return t[35]===F?e=t[36]:(e=(0,Y.jsx)(`div`,{className:`grid min-w-0 gap-2 overflow-x-hidden`,children:F}),t[35]=F,t[36]=e),e}if(u){let e;t[37]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(`div`,{className:`text-xs font-bold tracking-[0.04em] text-muted-foreground uppercase`,children:`History`}),t[37]=e):e=t[37];let n;t[38]===O?n=t[39]:(n=O?(0,Y.jsx)(`div`,{className:`min-w-0 truncate text-xs text-muted-foreground/80`,children:O}):null,t[38]=O,t[39]=n);let r;t[40]===n?r=t[41]:(r=(0,Y.jsxs)(`div`,{className:`flex min-w-0 items-baseline gap-3`,children:[e,n]}),t[40]=n,t[41]=r);let i;t[42]===o?i=t[43]:(i=o?(0,Y.jsx)(Dh,{onRestoreEmbedded:o}):null,t[42]=o,t[43]=i);let a;t[44]!==r||t[45]!==i?(a=(0,Y.jsxs)(`div`,{className:`flex min-h-10 items-center justify-between gap-3 border-b border-border/70 bg-background px-3 py-1.5`,children:[r,i]}),t[44]=r,t[45]=i,t[46]=a):a=t[46];let s;t[47]===F?s=t[48]:(s=(0,Y.jsx)(`div`,{className:`grid min-h-0 min-w-0 flex-1 gap-2 overflow-x-hidden overflow-y-auto`,children:F}),t[47]=F,t[48]=s);let c;return t[49]!==a||t[50]!==s?(c=(0,Y.jsxs)(`section`,{className:`flex h-full min-h-0 flex-col bg-background`,children:[a,s]}),t[49]=a,t[50]=s,t[51]=c):c=t[51],c}let I;return t[52]!==F||t[53]!==O?(I=(0,Y.jsx)(Hm,{title:`Commits`,meta:O,className:`overflow-x-hidden`,bodyClassName:`min-w-0 overflow-x-hidden p-0`,children:F}),t[52]=F,t[53]=O,t[54]=I):I=t[54],I}function kh(e){return e+50}function Ah({oldFile:e,newFile:t,options:n,metrics:r,lineAnnotations:i,selectedLines:a,className:o,style:s,prerenderedHTML:c,renderAnnotation:l,renderCustomHeader:u,renderHeaderPrefix:d,renderHeaderMetadata:f,renderGutterUtility:p,renderHoverUtility:m,disableWorkerPool:h=!1}){let g=(0,q.useMemo)(()=>ve(e,t,n?.parseDiffOptions),[e,t,n?.parseDiffOptions]),{ref:_,getHoveredLine:v}=st({fileDiff:g,options:n,metrics:r,lineAnnotations:i,selectedLines:a,prerenderedHTML:c,hasGutterRenderUtility:p!=null||m!=null,hasCustomHeader:u!=null,disableWorkerPool:h});return(0,Y.jsx)(kt,{ref:_,className:o,style:s,children:Ye(_t({fileDiff:g,renderCustomHeader:u,renderHeaderPrefix:d,renderHeaderMetadata:f,renderAnnotation:l,lineAnnotations:i,renderGutterUtility:p,renderHoverUtility:m,getHoveredLine:v}),c)})}function jh(e,t){e(e=>Object.is(e,t)?e:t)}function Mh(e){return!!(e&&e.scrollTop>0)}function Nh({getValue:e,scrollElement:t,selector:n}){if(!t||t.scrollTop<=0)return``;let r=t.getBoundingClientRect().top,i=Array.from(t.querySelectorAll(n));for(let t of i){let n=t.getBoundingClientRect();if(n.top<=r+1&&n.bottom>r+1)return e(t)}return``}function Ph(e){let t=(0,J.c)(2),{status:n}=e,r;if(t[0]!==n){let[e,i]=we(n);r=(0,Y.jsx)(`span`,{className:`inline-flex w-[2ch] shrink-0 items-center whitespace-pre text-muted-foreground/70`,children:[[`index`,e],[`worktree`,i]].map(e=>{let[t,r]=e,i=mt({character:r,column:t,status:n}),a=(0,Y.jsx)(`span`,{"aria-label":i||void 0,className:s(`w-[1ch] text-center whitespace-pre`,i&&`cursor-help`,U(F(t,r))),children:r},t);return i?(0,Y.jsx)(f,{title:i,side:`top`,children:a},t):a})}),t[0]=n,t[1]=r}else r=t[1];return r}function Fh(e){let t=(0,J.c)(8),{file:n}=e;if(!Se(n)){let e;return t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(`span`,{className:`min-w-0`}),t[0]=e):e=t[0],e}let r=L(n.linesAdded),i=L(n.linesDeleted),a;t[1]===r?a=t[2]:(a=r>0?(0,Y.jsxs)(`span`,{className:`text-emerald-500`,children:[`+`,r]}):null,t[1]=r,t[2]=a);let o;t[3]===i?o=t[4]:(o=i>0?(0,Y.jsxs)(`span`,{className:`text-red-500`,children:[`-`,i]}):null,t[3]=i,t[4]=o);let s;return t[5]!==a||t[6]!==o?(s=(0,Y.jsxs)(`span`,{className:`inline-flex min-w-0 gap-2 justify-self-end whitespace-nowrap tabular-nums`,children:[a,o]}),t[5]=a,t[6]=o,t[7]=s):s=t[7],s}function Ih(e){let[t,n]=we(e.status);return n!==` `||t===`?`}function Lh(e){let[t]=we(e.status);return t!==` `&&t!==`?`}function Rh(e){switch(e){case`discard-all`:return`Discarded all changes`;case`nuke-working-tree`:return`Nuked working tree`;case`unstage-all`:return`Unstaged all changes`;case`stage-all`:return`Staged all changes`}}function zh(e){switch(e){case`discard-all`:return`Failed to discard changes`;case`nuke-working-tree`:return`Failed to nuke working tree`;case`unstage-all`:return`Failed to unstage changes`;case`stage-all`:return`Failed to stage changes`}}function Bh(e){return e===`deletions`?`old`:`new`}function Vh(e){return Math.min(e.start,e.end)}function Hh(e){return e.side||e.endSide||`additions`}function Uh(e,t){return t===`deletions`&&e.previousPath||e.path}function Wh(e){return`changes:${ag(e)}`}function Gh({comments:e,pendingComment:t}){let n=e.map(e=>({lineNumber:e.lineNumber,metadata:e,side:e.side}));return t&&n.push({lineNumber:t.lineNumber,metadata:t,side:t.side}),n}function Kh(e){let t=(0,J.c)(39),{comment:n}=e,[r,i]=q.useState(``),a=q.useRef(null),o,s;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(o=()=>{a.current?.focus()},s=[],t[0]=o,t[1]=s):(o=t[0],s=t[1]),q.useEffect(o,s);let c;t[2]!==n||t[3]!==r?(c=()=>{let e=r.trim();e&&n.onSubmit(e)},t[2]=n,t[3]=r,t[4]=c):c=t[4];let l=c,u;t[5]===l?u=t[6]:(u=e=>{e.preventDefault(),l()},t[5]=l,t[6]=u);let d=n.path,f=n.lineNumber,p;t[7]===n.side?p=t[8]:(p=Bh(n.side),t[7]=n.side,t[8]=p);let m;t[9]!==n.lineNumber||t[10]!==n.path||t[11]!==p?(m=(0,Y.jsxs)(`span`,{className:`min-w-0 truncate`,children:[`Comment on `,d,`:L`,f,` (`,p,`)`]}),t[9]=n.lineNumber,t[10]=n.path,t[11]=p,t[12]=m):m=t[12];let h;t[13]===n.onCancel?h=t[14]:(h=(0,Y.jsx)(qt,{type:`button`,variant:`ghost`,size:`icon-sm`,"aria-label":`Cancel line comment`,onClick:n.onCancel,children:`×`}),t[13]=n.onCancel,t[14]=h);let g;t[15]!==m||t[16]!==h?(g=(0,Y.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center justify-between gap-2 text-xs text-muted-foreground`,children:[m,h]}),t[15]=m,t[16]=h,t[17]=g):g=t[17];let _;t[18]===Symbol.for(`react.memo_cache_sentinel`)?(_=e=>i(e.target.value),t[18]=_):_=t[18];let v;t[19]!==n||t[20]!==l?(v=e=>{e.key===`Enter`&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),l()),e.key===`Escape`&&(e.preventDefault(),n.onCancel())},t[19]=n,t[20]=l,t[21]=v):v=t[21];let y;t[22]!==v||t[23]!==r?(y=(0,Y.jsx)(ne,{ref:a,value:r,rows:2,placeholder:`Add a note for the prompt…`,className:`min-h-16 resize-none text-sm`,onChange:_,onKeyDown:v}),t[22]=v,t[23]=r,t[24]=y):y=t[24];let b;t[25]===n.onCancel?b=t[26]:(b=(0,Y.jsx)(qt,{type:`button`,variant:`ghost`,onClick:n.onCancel,children:`Cancel`}),t[25]=n.onCancel,t[26]=b);let x;t[27]===r?x=t[28]:(x=r.trim(),t[27]=r,t[28]=x);let S=!x,C;t[29]===S?C=t[30]:(C=(0,Y.jsx)(qt,{type:`submit`,disabled:S,children:`Add to prompt`}),t[29]=S,t[30]=C);let w;t[31]!==b||t[32]!==C?(w=(0,Y.jsxs)(`div`,{className:`mt-2 flex flex-wrap justify-end gap-2`,children:[b,C]}),t[31]=b,t[32]=C,t[33]=w):w=t[33];let T;return t[34]!==g||t[35]!==y||t[36]!==w||t[37]!==u?(T=(0,Y.jsxs)(`form`,{className:`m-2 w-[calc(100%_-_1rem)] max-w-[38rem] rounded-lg border border-border/70 bg-background p-2 shadow-sm`,onPointerDown:qh,onSubmit:u,children:[g,y,w]}),t[34]=g,t[35]=y,t[36]=w,t[37]=u,t[38]=T):T=t[38],T}function qh(e){return e.stopPropagation()}function Jh(e){let t=(0,J.c)(5),{annotation:n}=e,r=n.metadata;if(!r)return null;if(r.kind===`pending`){let e=r,n;return t[0]===e?n=t[1]:(n=(0,Y.jsx)(Kh,{comment:e}),t[0]=e,t[1]=n),n}let i=r,a;t[2]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,Y.jsx)(`span`,{className:`shrink-0`,children:`💬`}),t[2]=a):a=t[2];let o;return t[3]===i.text?o=t[4]:(o=(0,Y.jsxs)(`div`,{className:`my-1 ml-2 inline-flex max-w-[min(32rem,calc(100vw_-_5rem),90%)] items-center gap-1 rounded-full border border-amber-500/20 bg-amber-500/10 px-2 py-1 text-[11px] text-amber-800 dark:text-amber-200`,children:[a,(0,Y.jsx)(`span`,{className:`truncate`,children:i.text})]}),t[3]=i.text,t[4]=o),o}var Yh=160,Xh=1600;function Zh(e){if(Number.isFinite(e))return Math.round(Math.min(Xh,Math.max(Yh,e)))}function Qh(){let e=b(i);if(e!=null)return Zh(Number(e))}function $h(e){let t=Zh(e);typeof t==`number`&&m(i,String(t))}var eg={diffStyle:`unified`,historyOpen:!0,historyPanelHeight:void 0,defaultHistoryPanelHeight:void 0,openFiles:[],stickyReviewFileValue:``,historyHeaderShadowed:!1};function tg(e,t){return typeof t==`function`?t(e):t}function ng(e,t){switch(t.type){case`diffStyleChanged`:return e.diffStyle===t.diffStyle?e:{...e,diffStyle:t.diffStyle};case`historyOpenToggled`:return{...e,historyOpen:!e.historyOpen};case`historyPanelHeightChanged`:return Object.is(e.historyPanelHeight,t.height)?e:{...e,historyPanelHeight:t.height};case`historyPanelLayoutChanged`:{let n=typeof e.historyPanelHeight==`number`?Math.min(t.maxHeight,Math.max(t.minHeight,e.historyPanelHeight)):e.historyPanelHeight;return Object.is(e.defaultHistoryPanelHeight,t.defaultHeight)&&Object.is(e.historyPanelHeight,n)?e:{...e,defaultHistoryPanelHeight:t.defaultHeight,historyPanelHeight:n}}case`openFilesChanged`:return e.openFiles===t.openFiles?e:{...e,openFiles:t.openFiles};case`cwdChanged`:return{...e,historyOpen:!0,historyPanelHeight:t.historyPanelHeight,defaultHistoryPanelHeight:void 0,openFiles:[],stickyReviewFileValue:``,historyHeaderShadowed:!1};case`stickyReviewFileValueChanged`:{let n=tg(e.stickyReviewFileValue,t.value);return Object.is(e.stickyReviewFileValue,n)?e:{...e,stickyReviewFileValue:n}}case`historyHeaderShadowedChanged`:{let n=tg(e.historyHeaderShadowed,t.value);return Object.is(e.historyHeaderShadowed,n)?e:{...e,historyHeaderShadowed:n}}default:return e}}function rg(){return()=>{}}function ig(){return`row-resize`}function ag(e){return`${e.status}:${e.previousPath||``}:${e.path}`}function og(e){return L(e.linesAdded)+L(e.linesDeleted)}function sg(e){return typeof e.sizeBytes==`number`&&e.sizeBytes>1e4||og(e)>100}function cg(e){return lg(e)}function lg(e){let t=(0,J.c)(206),{viewerContextId:n,cwd:r,active:i,diffLineComments:a,onAddDiffLineComment:o,onMaximizeHistory:c,onOpenCommitDiff:l,onOpenFile:u,showEmbeddedHistory:d}=e,p;t[0]===a?p=t[1]:(p=a===void 0?[]:a,t[0]=a,t[1]=p);let m=p,h=d===void 0?!0:d,g=xt(r),_=dn(),v=tt(),[y,b]=q.useReducer(ng,eg,pg),{diffStyle:x,historyOpen:S,historyPanelHeight:w,defaultHistoryPanelHeight:T,openFiles:D,stickyReviewFileValue:O,historyHeaderShadowed:k}=y,A=q.useSyncExternalStore(rg,M,ig),N;t[2]===b?N=t[3]:(N=e=>{b({type:`stickyReviewFileValueChanged`,value:e})},t[2]=b,t[3]=N);let F=N,I;t[4]===b?I=t[5]:(I=e=>{b({type:`historyHeaderShadowedChanged`,value:e})},t[4]=b,t[5]=I);let L=I,R=q.useRef(null),{bottomHeight:B,onScroll:V,setScrollElement:H,topHeight:U}=ut(),ne;t[6]===H?ne=t[7]:(ne=e=>{R.current=e,H(e)},t[6]=H,t[7]=ne);let W=ne,G=q.useRef(null),ie=q.useRef(null),ae=q.useRef(null),oe=q.useRef(g),se=re({viewerContextId:n,cwd:g,scope:`files`}),le=!!(i&&n&&g),ue;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(ue=[`data`,`isPending`,`error`],t[8]=ue):ue=t[8];let de;t[9]!==se||t[10]!==le?(de={...se,enabled:le,select:lt,notifyOnChangeProps:ue},t[9]=se,t[10]=le,t[11]=de):de=t[11];let K=ee(de),pe=K.data,me;t[12]===pe?me=t[13]:(me=Array.isArray(pe)?pe:[],t[12]=pe,t[13]=me);let he=me,ge;t[14]===he?ge=t[15]:(ge=he.some(Ih),t[14]=he,t[15]=ge);let _e=ge,ve;t[16]===he?ve=t[17]:(ve=he.some(Lh),t[16]=he,t[17]=ve);let ye=ve,be=he.length>0,[xe,Se]=q.useState(!1),Ce;t[18]!==g||t[19]!==n?(Ce=async e=>await Qt(en(e===`discard-all`||e===`nuke-working-tree`?`/api/git-discard`:`/api/git-stage`,{contextId:n}),{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({action:e,cwd:g})}),t[18]=g,t[19]=n,t[20]=Ce):Ce=t[20];let we;t[21]!==g||t[22]!==_||t[23]!==n?(we=async(e,t)=>{await We({queryClient:_,viewerContextId:n,cwd:g}),ln.success(Rh(t))},t[21]=g,t[22]=_,t[23]=n,t[24]=we):we=t[24];let Te;t[25]!==Ce||t[26]!==we?(Te={mutationFn:Ce,onSuccess:we,onError:fg},t[25]=Ce,t[26]=we,t[27]=Te):Te=t[27];let Ee=te(Te),De;t[28]!==b||t[29]!==g||t[30]!==oe?(De=()=>{oe.current!==g&&(oe.current=g,b({type:`cwdChanged`,historyPanelHeight:Qh()}))},t[28]=b,t[29]=g,t[30]=oe,t[31]=De):De=t[31];let Oe;t[32]===g?Oe=t[33]:(Oe=[g],t[32]=g,t[33]=Oe),q.useEffect(De,Oe);let ke;t[34]===F?ke=t[35]:(ke=e=>{jh(F,Nh({getValue:dg,scrollElement:e,selector:`[data-review-file-trigger]`}))},t[34]=F,t[35]=ke);let Ae=ke,je;t[36]===L?je=t[37]:(je=e=>{jh(L,Mh(e))},t[36]=L,t[37]=je);let Ne=je,Fe;t[38]===Ae?Fe=t[39]:(Fe=()=>{Ae(R.current)},t[38]=Ae,t[39]=Fe);let Ie;t[40]===D?Ie=t[41]:(Ie=[D],t[40]=D,t[41]=Ie),q.useEffect(Fe,Ie);let Le;t[42]!==S||t[43]!==L||t[44]!==Ne?(Le=()=>{if(!S){jh(L,!1);return}Ne(ae.current)},t[42]=S,t[43]=L,t[44]=Ne,t[45]=Le):Le=t[45];let Re;t[46]===S?Re=t[47]:(Re=[S],t[46]=S,t[47]=Re),q.useEffect(Le,Re);let Be;t[48]===Symbol.for(`react.memo_cache_sentinel`)?(Be=()=>{let e=G.current?.getBoundingClientRect().height||0;if(e<=0)return{minHeight:Yh,maxHeight:1/0};let t=Math.min(Yh,e/2);return{minHeight:t,maxHeight:Math.max(t,e-t)}},t[48]=Be):Be=t[48];let Ve=Be,He;t[49]!==b||t[50]!==v?(He=e=>{if(v||e.button!==0)return;e.preventDefault();let{maxHeight:t,minHeight:n}=Ve(),r=ie.current?.getBoundingClientRect().height||n,i=e.clientY,a=document.body.style.cursor,o=document.body.style.userSelect,s=M(),c=j(s),l=Math.min(t,Math.max(n,r));Object.assign(document.body.style,{cursor:s,userSelect:`none`});let u=e=>{let a=r-(e.clientY-i);l=Math.min(t,Math.max(n,a)),b({type:`historyPanelHeightChanged`,height:l})},d=()=>{$h(l),c(),Object.assign(document.body.style,{cursor:a,userSelect:o}),document.removeEventListener(`pointermove`,u),document.removeEventListener(`pointerup`,d),document.removeEventListener(`pointercancel`,d)};document.addEventListener(`pointermove`,u),document.addEventListener(`pointerup`,d),document.addEventListener(`pointercancel`,d)},t[49]=b,t[50]=v,t[51]=He):He=t[51];let Ue=He,Ke;t[52]!==b||t[53]!==S||t[54]!==v?(Ke=()=>{if(v||!S)return;let e=()=>{let e=G.current?.getBoundingClientRect().height||0,{maxHeight:t,minHeight:n}=Ve(),r=e>0?e*.5:0;b({type:`historyPanelLayoutChanged`,defaultHeight:r>0?Math.min(t,Math.max(n,r)):void 0,maxHeight:t,minHeight:n})};return e(),window.addEventListener(`resize`,e),()=>{window.removeEventListener(`resize`,e)}},t[52]=b,t[53]=S,t[54]=v,t[55]=Ke):Ke=t[55];let qe;t[56]!==S||t[57]!==v||t[58]!==g?(qe=[S,v,g],t[56]=S,t[57]=v,t[58]=g,t[59]=qe):qe=t[59],q.useEffect(Ke,qe);let Je=D.length>0,Ye=Ee.isPending,Xe=Ye||!n||!g||pe==null||!!K.error,Ze=Ee.isPending&&Ee.variables===`discard-all`,Qe=Ee.isPending&&Ee.variables===`nuke-working-tree`,$e=Ee.isPending&&Ee.variables===`stage-all`,et=Ee.isPending&&Ee.variables===`unstage-all`,nt;t[60]!==he||t[61]!==b||t[62]!==Je?(nt=()=>{b({type:`openFilesChanged`,openFiles:Je?[]:he.map(ag)})},t[60]=he,t[61]=b,t[62]=Je,t[63]=nt):nt=t[63];let it=nt,at;t[64]===Ee?at=t[65]:(at=e=>{Ee.mutate(e)},t[64]=Ee,t[65]=at);let st=at,ct;t[66]===Symbol.for(`react.memo_cache_sentinel`)?(ct=()=>{Se(!0)},t[66]=ct):ct=t[66];let dt=ct,pt;t[67]===Ee?pt=t[68]:(pt=()=>{Ee.mutate(`nuke-working-tree`),Se(!1)},t[67]=Ee,t[68]=pt);let mt=pt,ht;t[69]===Symbol.for(`react.memo_cache_sentinel`)?(ht=(0,Y.jsx)($f,{}),t[69]=ht):ht=t[69];let gt;t[70]!==i||t[71]!==g||t[72]!==n?(gt=(0,Y.jsx)(`div`,{className:`flex min-h-12 shrink-0 flex-col justify-center gap-2 border-b border-border/70 bg-background p-2`,children:(0,Y.jsx)(Om,{viewerContextId:n,cwd:g,active:i})}),t[70]=i,t[71]=g,t[72]=n,t[73]=gt):gt=t[73];let _t;t[74]===Symbol.for(`react.memo_cache_sentinel`)?(_t=(0,Y.jsx)(`div`,{className:`flex min-w-0 items-center`,children:(0,Y.jsx)(`span`,{className:`text-xs font-bold tracking-[0.04em] text-muted-foreground uppercase`,children:`Diffs`})}),t[74]=_t):_t=t[74];let vt=v?`icon`:`icon-sm`,St;t[75]!==Xe||t[76]!==vt?(St=(0,Y.jsx)(qt,{variant:`outline`,size:vt,"aria-label":`Diff actions`,disabled:Xe}),t[75]=Xe,t[76]=vt,t[77]=St):St=t[77];let Ct;t[78]===Ye?Ct=t[79]:(Ct=Ye?(0,Y.jsx)(C,{size:`xs`}):(0,Y.jsx)(E,{className:`size-4`}),t[78]=Ye,t[79]=Ct);let wt;t[80]!==St||t[81]!==Ct?(wt=(0,Y.jsx)(Me,{render:St,children:Ct}),t[80]=St,t[81]=Ct,t[82]=wt):wt=t[82];let Et=Xe||!_e,Dt;t[83]===st?Dt=t[84]:(Dt=()=>st(`stage-all`),t[83]=st,t[84]=Dt);let Ot;t[85]===$e?Ot=t[86]:(Ot=$e?(0,Y.jsx)(C,{size:`xs`}):(0,Y.jsx)(cn,{}),t[85]=$e,t[86]=Ot);let kt;t[87]!==Et||t[88]!==Dt||t[89]!==Ot?(kt=(0,Y.jsxs)(Tt,{disabled:Et,onClick:Dt,children:[Ot,`Stage all`]}),t[87]=Et,t[88]=Dt,t[89]=Ot,t[90]=kt):kt=t[90];let At=Xe||!ye,jt;t[91]===st?jt=t[92]:(jt=()=>st(`unstage-all`),t[91]=st,t[92]=jt);let Mt;t[93]===et?Mt=t[94]:(Mt=et?(0,Y.jsx)(C,{size:`xs`}):(0,Y.jsx)(yn,{}),t[93]=et,t[94]=Mt);let Nt;t[95]!==At||t[96]!==jt||t[97]!==Mt?(Nt=(0,Y.jsxs)(Tt,{disabled:At,onClick:jt,children:[Mt,`Unstage all`]}),t[95]=At,t[96]=jt,t[97]=Mt,t[98]=Nt):Nt=t[98];let Pt=Xe||!be,Ft;t[99]===st?Ft=t[100]:(Ft=()=>st(`discard-all`),t[99]=st,t[100]=Ft);let It;t[101]===Ze?It=t[102]:(It=Ze?(0,Y.jsx)(C,{size:`xs`}):(0,Y.jsx)(wn,{}),t[101]=Ze,t[102]=It);let Lt;t[103]!==Pt||t[104]!==Ft||t[105]!==It?(Lt=(0,Y.jsxs)(Tt,{variant:`destructive`,disabled:Pt,onClick:Ft,children:[It,`Discard all`]}),t[103]=Pt,t[104]=Ft,t[105]=It,t[106]=Lt):Lt=t[106];let Rt;t[107]===Symbol.for(`react.memo_cache_sentinel`)?(Rt=(0,Y.jsx)(Ge,{}),t[107]=Rt):Rt=t[107];let zt;t[108]===Qe?zt=t[109]:(zt=Qe?(0,Y.jsx)(C,{size:`xs`}):(0,Y.jsx)(Cn,{}),t[108]=Qe,t[109]=zt);let Bt;t[110]!==Xe||t[111]!==zt?(Bt=(0,Y.jsxs)(Tt,{variant:`destructive`,disabled:Xe,onClick:dt,children:[zt,`Nuke working tree`]}),t[110]=Xe,t[111]=zt,t[112]=Bt):Bt=t[112];let Vt;t[113]!==kt||t[114]!==Nt||t[115]!==Lt||t[116]!==Bt?(Vt=(0,Y.jsx)(ze,{align:`end`,className:`w-52`,children:(0,Y.jsxs)(rt,{children:[kt,Nt,Lt,Rt,Bt]})}),t[113]=kt,t[114]=Nt,t[115]=Lt,t[116]=Bt,t[117]=Vt):Vt=t[117];let Ht;t[118]!==wt||t[119]!==Vt?(Ht=(0,Y.jsxs)(yt,{children:[wt,Vt]}),t[118]=wt,t[119]=Vt,t[120]=Ht):Ht=t[120];let Ut=Je?`Collapse all`:`Expand all`,Wt=v?`icon`:`icon-sm`,Gt=Je?`Collapse all`:`Expand all`,Kt=he.length===0,Jt;t[121]===Je?Jt=t[122]:(Jt=Je?(0,Y.jsx)(fe,{className:`size-4`}):(0,Y.jsx)(ce,{className:`size-4`}),t[121]=Je,t[122]=Jt);let Yt;t[123]!==Wt||t[124]!==Gt||t[125]!==Kt||t[126]!==Jt||t[127]!==it?(Yt=(0,Y.jsx)(qt,{variant:`outline`,size:Wt,"aria-label":Gt,disabled:Kt,onClick:it,children:Jt}),t[123]=Wt,t[124]=Gt,t[125]=Kt,t[126]=Jt,t[127]=it,t[128]=Yt):Yt=t[128];let Xt;t[129]!==Ut||t[130]!==Yt?(Xt=(0,Y.jsx)(f,{title:Ut,children:Yt}),t[129]=Ut,t[130]=Yt,t[131]=Xt):Xt=t[131];let Zt=v?`default`:`sm`,$t;t[132]===x?$t=t[133]:($t=[x],t[132]=x,t[133]=$t);let tn;t[134]===b?tn=t[135]:(tn=e=>{let t=e[0];(t===`unified`||t===`split`)&&b({type:`diffStyleChanged`,diffStyle:t})},t[134]=b,t[135]=tn);let nn;t[136]===Symbol.for(`react.memo_cache_sentinel`)?(nn=[`unified`,`split`],t[136]=nn):nn=t[136];let rn;t[137]===Symbol.for(`react.memo_cache_sentinel`)?(rn=nn.map(ug),t[137]=rn):rn=t[137];let an;t[138]!==Zt||t[139]!==$t||t[140]!==tn?(an=(0,Y.jsx)(Jf,{variant:`outline`,size:Zt,value:$t,onValueChange:tn,children:rn}),t[138]=Zt,t[139]=$t,t[140]=tn,t[141]=an):an=t[141];let on;t[142]!==Ht||t[143]!==Xt||t[144]!==an?(on=(0,Y.jsxs)(`div`,{className:`flex shrink-0 flex-wrap items-center justify-between gap-2 border-b border-border/70 bg-background p-2`,children:[_t,(0,Y.jsxs)(`div`,{className:`flex shrink-0 flex-wrap items-center justify-end gap-2`,children:[Ht,Xt,an]})]}),t[142]=Ht,t[143]=Xt,t[144]=an,t[145]=on):on=t[145];let sn;t[146]!==V||t[147]!==Ae?(sn=e=>{Ae(e.currentTarget),V(e)},t[146]=V,t[147]=Ae,t[148]=sn):sn=t[148];let fn;t[149]!==i||t[150]!==he||t[151]!==m||t[152]!==x||t[153]!==b||t[154]!==pe||t[155]!==K.error||t[156]!==K.isPending||t[157]!==g||t[158]!==o||t[159]!==u||t[160]!==D||t[161]!==O||t[162]!==n?(fn=g?n?K.isPending&&pe===void 0?(0,Y.jsxs)(tp,{className:`px-3 py-2.5`,children:[(0,Y.jsx)(C,{}),` Loading changes…`]}):K.error?(0,Y.jsx)(tp,{tone:`destructive`,className:`px-3 py-2.5`,children:ft(K.error,`Failed to load changes`)}):pe===null?(0,Y.jsx)(tp,{className:`px-3 py-2.5`,children:`No git repository detected.`}):he.length>0?(0,Y.jsx)(bt,{multiple:!0,value:D,onValueChange:e=>{b({type:`openFilesChanged`,openFiles:e})},className:`border-b border-border/80`,children:he.map(e=>(0,Y.jsx)(mg,{viewerContextId:n,cwd:g,active:i,diffLineComments:m,diffStyle:x,file:e,open:D.includes(ag(e)),stuck:O===ag(e),onAddDiffLineComment:o,onOpenFile:u},ag(e)))}):(0,Y.jsx)(tp,{className:`px-3 py-2.5`,children:`Working tree clean.`}):(0,Y.jsx)(tp,{className:`px-3 py-2.5`,children:`Waiting for viewer context…`}):(0,Y.jsx)(tp,{className:`px-3 py-2.5`,children:`No directory selected.`}),t[149]=i,t[150]=he,t[151]=m,t[152]=x,t[153]=b,t[154]=pe,t[155]=K.error,t[156]=K.isPending,t[157]=g,t[158]=o,t[159]=u,t[160]=D,t[161]=O,t[162]=n,t[163]=fn):fn=t[163];let pn;t[164]!==W||t[165]!==sn||t[166]!==fn?(pn=(0,Y.jsx)(`div`,{ref:W,className:`h-full overflow-auto`,onScroll:sn,children:fn}),t[164]=W,t[165]=sn,t[166]=fn,t[167]=pn):pn=t[167];let mn;t[168]!==B||t[169]!==U?(mn=(0,Y.jsx)(Pe,{bottomHeight:B,topHeight:U}),t[168]=B,t[169]=U,t[170]=mn):mn=t[170];let hn;t[171]!==pn||t[172]!==mn?(hn=(0,Y.jsxs)(`div`,{className:`relative min-h-0 flex-1`,children:[pn,mn]}),t[171]=pn,t[172]=mn,t[173]=hn):hn=t[173];let gn;t[174]!==i||t[175]!==T||t[176]!==b||t[177]!==pe||t[178]!==K.error||t[179]!==k||t[180]!==S||t[181]!==w||t[182]!==v||t[183]!==g||t[184]!==c||t[185]!==l||t[186]!==h||t[187]!==Ue||t[188]!==Ne||t[189]!==A||t[190]!==n?(gn=h&&g&&n&&pe!==null&&!K.error?(0,Y.jsxs)(`div`,{ref:ie,className:`relative flex max-h-[50%] min-h-0 shrink-0 flex-col overflow-hidden border-t border-border/70 bg-card/50 md:max-h-none`,style:!v&&S?{height:w??T}:void 0,children:[S?(0,Y.jsx)(`div`,{role:`separator`,"aria-label":`Resize history panel`,"aria-orientation":`horizontal`,style:{cursor:A},className:s(`absolute inset-x-0 top-0 z-10 hidden h-2 -translate-y-1/2 touch-none bg-transparent after:absolute after:inset-x-0 after:top-1/2 after:h-px after:bg-transparent md:block`,ot,A===`ns-resize`?`cursor-ns-resize`:`cursor-row-resize`),onPointerDown:Ue}):null,(0,Y.jsxs)(`div`,{className:s(`flex min-h-10 shrink-0 items-center bg-background transition-shadow`,k&&`shadow-sm`),children:[(0,Y.jsxs)(`button`,{type:`button`,"aria-expanded":S,className:`flex min-h-10 min-w-0 flex-1 items-center justify-between gap-3 px-3 py-2 text-left transition-colors hover:bg-muted/60`,onClick:()=>{b({type:`historyOpenToggled`})},children:[(0,Y.jsx)(`span`,{className:`flex min-w-0 items-center`,children:(0,Y.jsx)(`span`,{className:`text-xs font-bold tracking-[0.04em] text-muted-foreground uppercase`,children:`History`})}),S?(0,Y.jsx)(z,{className:`size-4 shrink-0 text-muted-foreground`}):(0,Y.jsx)(P,{className:`size-4 shrink-0 text-muted-foreground`})]}),c?(0,Y.jsx)(f,{title:`Open history tab`,children:(0,Y.jsx)(qt,{type:`button`,variant:`ghost`,size:`icon`,className:`mr-1 size-8 shrink-0`,"aria-label":`Open history tab`,onClick:c,children:(0,Y.jsx)(_n,{className:`size-4`})})}):null]}),S?(0,Y.jsx)(`div`,{ref:ae,className:`min-h-0 flex-1 touch-pan-y overflow-x-hidden overflow-y-auto overscroll-contain border-t border-border/70`,onScroll:e=>{Ne(e.currentTarget)},children:(0,Y.jsx)(Oh,{viewerContextId:n,cwd:g,active:i&&S,embedded:!0,onOpenCommitDiff:l})}):null]}):null,t[174]=i,t[175]=T,t[176]=b,t[177]=pe,t[178]=K.error,t[179]=k,t[180]=S,t[181]=w,t[182]=v,t[183]=g,t[184]=c,t[185]=l,t[186]=h,t[187]=Ue,t[188]=Ne,t[189]=A,t[190]=n,t[191]=gn):gn=t[191];let vn;t[192]===Symbol.for(`react.memo_cache_sentinel`)?(vn=(0,Y.jsxs)(Fm,{children:[(0,Y.jsx)(Lm,{children:(0,Y.jsx)(un,{})}),(0,Y.jsx)(Rm,{children:`Nuke working tree?`}),(0,Y.jsx)(zm,{children:`This restores tracked files to HEAD and deletes untracked and ignored files in this repository. This cannot be undone from Pico.`})]}),t[192]=vn):vn=t[192];let bn;t[193]===Symbol.for(`react.memo_cache_sentinel`)?(bn=(0,Y.jsx)(Vm,{children:`Cancel`}),t[193]=bn):bn=t[193];let xn;t[194]!==Xe||t[195]!==mt?(xn=(0,Y.jsxs)(Pm,{children:[vn,(0,Y.jsxs)(Im,{children:[bn,(0,Y.jsx)(Bm,{variant:`destructive`,disabled:Xe,onClick:mt,children:`Nuke working tree`})]})]}),t[194]=Xe,t[195]=mt,t[196]=xn):xn=t[196];let Sn;t[197]!==xe||t[198]!==xn?(Sn=(0,Y.jsx)(jm,{open:xe,onOpenChange:Se,children:xn}),t[197]=xe,t[198]=xn,t[199]=Sn):Sn=t[199];let Tn;return t[200]!==gt||t[201]!==on||t[202]!==hn||t[203]!==gn||t[204]!==Sn?(Tn=(0,Y.jsxs)(`div`,{ref:G,className:`flex h-full min-h-0 flex-col bg-background`,children:[ht,gt,on,hn,gn,Sn]}),t[200]=gt,t[201]=on,t[202]=hn,t[203]=gn,t[204]=Sn,t[205]=Tn):Tn=t[205],Tn}function ug(e){return(0,Y.jsx)(Yf,{value:e,children:e===`unified`?`Unified`:`Split`},e)}function dg(e){return e.dataset.reviewFileValue||``}function fg(e,t){ln.error(ft(e,zh(t)))}function pg(e){return{...e,historyPanelHeight:Qh()}}function mg(e){let t=(0,J.c)(180),{viewerContextId:n,cwd:r,active:i,diffLineComments:a,diffStyle:o,file:c,open:l,stuck:u,onAddDiffLineComment:d,onOpenFile:f}=e,p=a===void 0?[]:a,m=xt(r),h=dn(),g;t[0]===c?g=t[1]:(g=ag(c),t[0]=c,t[1]=g);let _=g,v;t[2]===c?v=t[3]:(v=Wh(c),t[2]=c,t[3]=v);let y=v,[b,x]=q.useState(null),[S,w]=q.useState(!1),T;t[4]!==c||t[5]!==S?(T=sg(c)&&!S,t[4]=c,t[5]=S,t[6]=T):T=t[6];let E=T,O=ee({...D({viewerContextId:n,cwd:m,path:c.path}),enabled:!!(E&&l&&i&&n&&m),notifyOnChangeProps:[`data`,`isPending`,`error`]}),k=be({viewerContextId:n,cwd:m,path:c.path,previousPath:c.previousPath}),A=!!(!E&&l&&i&&n&&m),j;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(j=[`data`,`isPending`,`error`],t[7]=j):j=t[7];let M;t[8]!==k||t[9]!==A?(M={...k,enabled:A,notifyOnChangeProps:j},t[8]=k,t[9]=A,t[10]=M):M=t[10];let N=ee(M),F=N.data?.oldContent??``,I=N.data?.newContent??``,L=O.data?.patch??``,R;t[11]!==y||t[12]!==m?(R=e=>e.cwd===m&&e.tabKey===y,t[11]=y,t[12]=m,t[13]=R):R=t[13];let B=p.filter(R),V;t[14]!==y||t[15]!==c||t[16]!==d||t[17]!==x?(V=e=>{if(!d)return;let t=Hh(e);x({commit:`working-tree`,lineNumber:Vh(e),mode:`head`,path:Uh(c,t),shortHash:`working tree`,side:t,tabKey:y,tabTitle:`Working tree changes`})},t[14]=y,t[15]=c,t[16]=d,t[17]=x,t[18]=V):V=t[18];let H=V,U=Gh({comments:B,pendingComment:b?{...b,kind:`pending`,onCancel:()=>x(null),onSubmit:e=>{d?.({...b,text:e}),x(null)}}:null}),ne;t[19]!==d||t[20]!==H?(ne=d?{enableGutterUtility:!0,onGutterUtilityClick:H}:{},t[19]=d,t[20]=H,t[21]=ne):ne=t[21];let re=ne,W=Dt(),G;t[22]===c?G=t[23]:(G=Ih(c),t[22]=c,t[23]=G);let ie=G,ae;t[24]===c?ae=t[25]:(ae=Lh(c),t[24]=c,t[25]=ae);let oe=ae,se;t[26]!==m||t[27]!==h||t[28]!==n?(se=async()=>{await We({queryClient:h,viewerContextId:n,cwd:m})},t[26]=m,t[27]=h,t[28]=n,t[29]=se):se=t[29];let ce=se,le;t[30]!==c.path||t[31]!==c.previousPath||t[32]!==m||t[33]!==n?(le=async e=>await Qt(en(`/api/git-stage`,{contextId:n}),{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({action:e,cwd:m,path:c.path,previousPath:c.previousPath})}),t[30]=c.path,t[31]=c.previousPath,t[32]=m,t[33]=n,t[34]=le):le=t[34];let ue;t[35]!==c.path||t[36]!==ce||t[37]!==m||t[38]!==h||t[39]!==n?(ue=async(e,t)=>{await h.invalidateQueries({queryKey:tn.gitStatus(n,m),exact:!0,refetchType:`active`}),await ce(),ln.success(t===`unstage`?`Unstaged changes`:`Staged changes`,{description:c.path})},t[35]=c.path,t[36]=ce,t[37]=m,t[38]=h,t[39]=n,t[40]=ue):ue=t[40];let de;t[41]!==le||t[42]!==ue?(de={mutationFn:le,onSuccess:ue,onError:vg},t[41]=le,t[42]=ue,t[43]=de):de=t[43];let K=te(de),fe;t[44]!==c.path||t[45]!==c.previousPath||t[46]!==c.status||t[47]!==m||t[48]!==n?(fe=async()=>await Qt(en(`/api/git-discard`,{contextId:n}),{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({cwd:m,path:c.path,previousPath:c.previousPath,status:c.status})}),t[44]=c.path,t[45]=c.previousPath,t[46]=c.status,t[47]=m,t[48]=n,t[49]=fe):fe=t[49];let pe;t[50]!==c.path||t[51]!==ce||t[52]!==m||t[53]!==h||t[54]!==n?(pe=async()=>{await h.invalidateQueries({queryKey:tn.gitStatus(n,m),exact:!0,refetchType:`active`}),await ce(),ln.success(`Discarded changes`,{description:c.path})},t[50]=c.path,t[51]=ce,t[52]=m,t[53]=h,t[54]=n,t[55]=pe):pe=t[55];let me;t[56]!==fe||t[57]!==pe?(me={mutationFn:fe,onSuccess:pe,onError:_g},t[56]=fe,t[57]=pe,t[58]=me):me=t[58];let he=te(me),ge=K.isPending||he.isPending,_e;t[59]===x?_e=t[60]:(_e=()=>{x(null)},t[59]=x,t[60]=_e);let ve;t[61]!==I||t[62]!==F||t[63]!==L||t[64]!==E||t[65]!==_?(ve=[_,E,L,F,I],t[61]=I,t[62]=F,t[63]=L,t[64]=E,t[65]=_,t[66]=ve):ve=t[66],q.useEffect(_e,ve);let xe=ge||!n||!m,Se=K.isPending&&K.variables===`stage`,Ce=K.isPending&&K.variables===`unstage`,we;t[67]!==c.path||t[68]!==f?(we=e=>{e?.stopPropagation(),f?.(c.path,{pin:!0})},t[67]=c.path,t[68]=f,t[69]=we):we=t[69];let Te=we,Ee;t[70]===he?Ee=t[71]:(Ee=e=>{e?.stopPropagation(),he.mutate()},t[70]=he,t[71]=Ee);let De=Ee,Oe;t[72]===K?Oe=t[73]:(Oe=e=>{e?.stopPropagation(),K.mutate(`stage`)},t[72]=K,t[73]=Oe);let ke=Oe,Ae;t[74]===K?Ae=t[75]:(Ae=e=>{e?.stopPropagation(),K.mutate(`unstage`)},t[74]=K,t[75]=Ae);let je=Ae,Me;t[76]===c.status?Me=t[77]:(Me=(0,Y.jsx)(Ph,{status:c.status}),t[76]=c.status,t[77]=Me);let Pe;t[78]===c.path?Pe=t[79]:(Pe=(0,Y.jsx)(ep,{path:c.path}),t[78]=c.path,t[79]=Pe);let Fe;t[80]!==c.path||t[81]!==c.previousPath?(Fe=c.previousPath?(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:c.previousPath}),(0,Y.jsx)(`span`,{className:`text-muted-foreground/70`,children:` → `}),(0,Y.jsx)(`span`,{children:c.path})]}):c.path,t[80]=c.path,t[81]=c.previousPath,t[82]=Fe):Fe=t[82];let Ie;t[83]===Fe?Ie=t[84]:(Ie=(0,Y.jsx)(`span`,{className:`min-w-0 truncate text-left`,children:Fe}),t[83]=Fe,t[84]=Ie);let Le;t[85]===c?Le=t[86]:(Le=(0,Y.jsx)(Fh,{file:c}),t[85]=c,t[86]=Le);let Re;t[87]!==Me||t[88]!==Pe||t[89]!==Ie||t[90]!==Le?(Re=(0,Y.jsxs)(`span`,{className:`grid min-w-0 flex-1 grid-cols-[auto_auto_minmax(0,1fr)_auto] items-center gap-2`,children:[Me,Pe,Ie,Le]}),t[87]=Me,t[88]=Pe,t[89]=Ie,t[90]=Le,t[91]=Re):Re=t[91];let ze,Ve;t[92]===Symbol.for(`react.memo_cache_sentinel`)?(ze=(0,Y.jsx)(P,{"data-slot":`accordion-trigger-icon`,className:`pointer-events-none size-4 shrink-0 group-aria-expanded/review-file-trigger:hidden`}),Ve=(0,Y.jsx)(z,{"data-slot":`accordion-trigger-icon`,className:`pointer-events-none hidden size-4 shrink-0 group-aria-expanded/review-file-trigger:inline`}),t[92]=ze,t[93]=Ve):(ze=t[92],Ve=t[93]);let He;t[94]!==Re||t[95]!==_?(He=(0,Y.jsxs)(Ke,{"data-review-file-trigger":!0,"data-review-file-value":_,className:`group/review-file-trigger relative flex min-h-10 min-w-0 flex-1 items-center justify-between gap-3 rounded-none border border-transparent bg-background px-3 py-2 text-left text-[13px] font-medium transition-all outline-none hover:no-underline focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 aria-disabled:pointer-events-none aria-disabled:opacity-50 **:data-[slot=accordion-trigger-icon]:ml-auto **:data-[slot=accordion-trigger-icon]:size-4 **:data-[slot=accordion-trigger-icon]:text-muted-foreground`,children:[Re,ze,Ve]}),t[94]=Re,t[95]=_,t[96]=He):He=t[96];let Ue=He,Ge=u&&`shadow-sm`,qe;t[97]===Ge?qe=t[98]:(qe=s(`group/review-file-header sticky top-0 z-20 flex bg-background transition-shadow`,Ge),t[97]=Ge,t[98]=qe);let Ye;t[99]===Ue?Ye=t[100]:(Ye=(0,Y.jsx)(ye,{render:Ue}),t[99]=Ue,t[100]=Ye);let Xe=!f,Ze;t[101]===Symbol.for(`react.memo_cache_sentinel`)?(Ze=(0,Y.jsx)(mn,{}),t[101]=Ze):Ze=t[101];let Qe;t[102]!==Te||t[103]!==Xe?(Qe=(0,Y.jsxs)(Pt,{disabled:Xe,onClick:Te,children:[Ze,`Open file`]}),t[102]=Te,t[103]=Xe,t[104]=Qe):Qe=t[104];let $e;t[105]===Symbol.for(`react.memo_cache_sentinel`)?($e=(0,Y.jsx)(Mt,{}),t[105]=$e):$e=t[105];let et=xe||!ie,tt;t[106]===Se?tt=t[107]:(tt=Se?(0,Y.jsx)(C,{size:`xs`}):(0,Y.jsx)(cn,{}),t[106]=Se,t[107]=tt);let nt;t[108]!==ke||t[109]!==et||t[110]!==tt?(nt=(0,Y.jsxs)(Pt,{disabled:et,onClick:ke,children:[tt,`Stage changes`]}),t[108]=ke,t[109]=et,t[110]=tt,t[111]=nt):nt=t[111];let rt=xe||!oe,at;t[112]===Ce?at=t[113]:(at=Ce?(0,Y.jsx)(C,{size:`xs`}):(0,Y.jsx)(yn,{}),t[112]=Ce,t[113]=at);let ot;t[114]!==rt||t[115]!==at||t[116]!==je?(ot=(0,Y.jsxs)(Pt,{disabled:rt,onClick:je,children:[at,`Unstage changes`]}),t[114]=rt,t[115]=at,t[116]=je,t[117]=ot):ot=t[117];let st;t[118]===he.isPending?st=t[119]:(st=he.isPending?(0,Y.jsx)(C,{size:`xs`}):(0,Y.jsx)(wn,{}),t[118]=he.isPending,t[119]=st);let ct;t[120]!==De||t[121]!==xe||t[122]!==st?(ct=(0,Y.jsxs)(Pt,{variant:`destructive`,disabled:xe,onClick:De,children:[st,`Discard changes`]}),t[120]=De,t[121]=xe,t[122]=st,t[123]=ct):ct=t[123];let lt;t[124]!==Qe||t[125]!==nt||t[126]!==ot||t[127]!==ct?(lt=(0,Y.jsxs)(Ne,{className:`w-48`,children:[Qe,$e,nt,ot,ct]}),t[124]=Qe,t[125]=nt,t[126]=ot,t[127]=ct,t[128]=lt):lt=t[128];let ut;t[129]!==Ye||t[130]!==lt?(ut=(0,Y.jsxs)(Je,{children:[Ye,lt]}),t[129]=Ye,t[130]=lt,t[131]=ut):ut=t[131];let dt;t[132]!==qe||t[133]!==ut?(dt=(0,Y.jsx)(pt,{className:qe,children:ut}),t[132]=qe,t[133]=ut,t[134]=dt):dt=t[134];let mt;t[135]!==c.path||t[136]!==f||t[137]!==Te?(mt=f?(0,Y.jsxs)(qt,{type:`button`,variant:`outline`,"aria-label":`Open ${c.path}`,className:`min-w-0 flex-1`,onClick:Te,children:[(0,Y.jsx)(mn,{className:`size-3.5`}),(0,Y.jsx)(`span`,{children:`Open file`})]}):null,t[135]=c.path,t[136]=f,t[137]=Te,t[138]=mt):mt=t[138];let ht=`Discard changes to ${c.path}`,gt=ge||!n||!m,_t,vt;t[139]===Symbol.for(`react.memo_cache_sentinel`)?(_t=(0,Y.jsx)(wn,{className:`size-3.5`}),vt=(0,Y.jsx)(`span`,{children:`Discard`}),t[139]=_t,t[140]=vt):(_t=t[139],vt=t[140]);let yt;t[141]!==De||t[142]!==ht||t[143]!==gt?(yt=(0,Y.jsxs)(qt,{type:`button`,variant:`outline`,"aria-label":ht,className:`min-w-0 flex-1 text-muted-foreground hover:text-destructive`,disabled:gt,onClick:De,children:[_t,vt]}),t[141]=De,t[142]=ht,t[143]=gt,t[144]=yt):yt=t[144];let bt=`Stage changes to ${c.path}`,Ct=ge||!ie||!n||!m,wt,Tt;t[145]===Symbol.for(`react.memo_cache_sentinel`)?(wt=(0,Y.jsx)(cn,{className:`size-3.5`}),Tt=(0,Y.jsx)(`span`,{children:`Stage`}),t[145]=wt,t[146]=Tt):(wt=t[145],Tt=t[146]);let Et;t[147]!==ke||t[148]!==bt||t[149]!==Ct?(Et=(0,Y.jsxs)(qt,{type:`button`,variant:`outline`,"aria-label":bt,className:`min-w-0 flex-1 text-muted-foreground hover:text-emerald-500`,disabled:Ct,onClick:ke,children:[wt,Tt]}),t[147]=ke,t[148]=bt,t[149]=Ct,t[150]=Et):Et=t[150];let Ot;t[151]!==mt||t[152]!==yt||t[153]!==Et?(Ot=(0,Y.jsxs)(`div`,{className:`flex gap-2 border-b border-border/70 bg-card/40 p-2`,children:[mt,yt,Et]}),t[151]=mt,t[152]=yt,t[153]=Et,t[154]=Ot):Ot=t[154];let kt;t[155]!==re||t[156]!==O.data||t[157]!==O.error||t[158]!==O.isPending||t[159]!==o||t[160]!==c.path||t[161]!==c.previousPath||t[162]!==U||t[163]!==I||t[164]!==F||t[165]!==L||t[166]!==E||t[167]!==N.data||t[168]!==N.error||t[169]!==N.isPending||t[170]!==w||t[171]!==W?(kt=E?O.isPending&&!O.data?(0,Y.jsx)(`div`,{className:`p-3`,children:(0,Y.jsxs)(tp,{children:[(0,Y.jsx)(C,{}),` Loading hunk…`]})}):O.error?(0,Y.jsx)(`div`,{className:`p-3`,children:(0,Y.jsx)(tp,{tone:`destructive`,children:ft(O.error,`Failed to load hunk`)})}):L?(0,Y.jsxs)(`div`,{children:[(0,Y.jsxs)(`div`,{className:`flex items-center justify-between gap-3 border-b border-border/70 bg-background px-3 py-2 text-xs text-muted-foreground`,children:[(0,Y.jsx)(`span`,{children:`Showing changed hunks only for this large change.`}),(0,Y.jsx)(qt,{variant:`outline`,className:`shrink-0`,onClick:()=>{w(!0)},children:`Load full context`})]}),(0,Y.jsx)(St,{patch:L,disableWorkerPool:!0,lineAnnotations:U,renderAnnotation:gg,options:{...W,diffStyle:o,disableFileHeader:!0,...re,overflow:`wrap`}})]}):(0,Y.jsx)(`div`,{className:`p-3`,children:(0,Y.jsx)(tp,{children:`No line changes.`})}):N.isPending&&!N.data?(0,Y.jsx)(`div`,{className:`p-3`,children:(0,Y.jsxs)(tp,{children:[(0,Y.jsx)(C,{}),` Loading hunk…`]})}):N.error?(0,Y.jsx)(`div`,{className:`p-3`,children:(0,Y.jsx)(tp,{tone:`destructive`,children:ft(N.error,`Failed to load hunk`)})}):F===I?(0,Y.jsx)(`div`,{className:`p-3`,children:(0,Y.jsx)(tp,{children:`No line changes.`})}):(0,Y.jsx)(Ah,{oldFile:{name:c.previousPath||c.path,contents:F},newFile:{name:c.path,contents:I},disableWorkerPool:!0,lineAnnotations:U,renderAnnotation:hg,options:{...W,diffStyle:o,disableFileHeader:!0,...re,overflow:`wrap`}}),t[155]=re,t[156]=O.data,t[157]=O.error,t[158]=O.isPending,t[159]=o,t[160]=c.path,t[161]=c.previousPath,t[162]=U,t[163]=I,t[164]=F,t[165]=L,t[166]=E,t[167]=N.data,t[168]=N.error,t[169]=N.isPending,t[170]=w,t[171]=W,t[172]=kt):kt=t[172];let At;t[173]!==Ot||t[174]!==kt?(At=(0,Y.jsxs)(Be,{className:`bg-background p-0`,children:[Ot,kt]}),t[173]=Ot,t[174]=kt,t[175]=At):At=t[175];let jt;return t[176]!==dt||t[177]!==At||t[178]!==_?(jt=(0,Y.jsxs)(it,{value:_,className:`border-border/70`,children:[dt,At]}),t[176]=dt,t[177]=At,t[178]=_,t[179]=jt):jt=t[179],jt}function hg(e){return(0,Y.jsx)(Jh,{annotation:e})}function gg(e){return(0,Y.jsx)(Jh,{annotation:e})}function _g(e){ln.error(ft(e,`Failed to discard changes`))}function vg(e,t){ln.error(ft(e,t===`unstage`?`Failed to unstage changes`:`Failed to stage changes`))}var yg=[],bg=[];function xg(){return b(n)===`1`}function Sg(e){m(n,e?`1`:`0`)}function Cg(e,t,n=``){return`commit-diff:${t}:${e}:${n}`}function wg(e){let t=e.split(`/`).filter(Boolean);return t[t.length-1]||e}function Tg(e){if(e.path){let t=e.previousPath||e.path,n=e.leftRevisionLabel||(e.mode===`head`?e.shortHash:`${e.shortHash}^`),r=e.rightRevisionLabel||(e.mode===`head`?`HEAD`:e.shortHash);return`${wg(t)} (${n}) → ${wg(e.path)} (${r})`}return e.mode===`head`?`${e.shortHash}..HEAD`:e.mode===`previous`?`${e.shortHash}^..${e.shortHash}`:`Diff ${e.shortHash}`}function Eg(e){return{key:Cg(e.commit,e.mode,e.path),commit:e.commit,shortHash:e.shortHash,title:Tg(e),mode:e.mode,...e.path?{path:e.path}:{},...e.previousPath?{previousPath:e.previousPath}:{},...e.leftRevisionLabel?{leftRevisionLabel:e.leftRevisionLabel}:{},...e.rightRevisionLabel?{rightRevisionLabel:e.rightRevisionLabel}:{}}}var Dg={uncontrolledActiveTab:`review`,inlineActiveFilePath:``,openFileDialogOpen:!1,commitDiffTabs:[],activeCommitDiffKey:``};function Og(e,t){switch(t.type){case`set-active-tab`:return{...e,uncontrolledActiveTab:t.tab};case`set-inline-active-file`:return{...e,inlineActiveFilePath:t.path};case`set-open-file-dialog-open`:return{...e,openFileDialogOpen:t.open};case`upsert-commit-diff-tab`:return{...e,commitDiffTabs:e.commitDiffTabs.some(e=>e.key===t.tab.key)?e.commitDiffTabs.map(e=>e.key===t.tab.key?t.tab:e):[...e.commitDiffTabs,t.tab],activeCommitDiffKey:t.tab.key,uncontrolledActiveTab:`commit-diff`};case`set-active-commit-diff-key`:return{...e,activeCommitDiffKey:t.key};case`close-commit-diff-keys`:{let n=new Set(t.keys),r=e.commitDiffTabs.findIndex(e=>n.has(e.key)),i=e.commitDiffTabs.filter(e=>!n.has(e.key)),a=n.has(e.activeCommitDiffKey)?i[Math.max(0,r-1)]||i[0]:void 0;return{...e,commitDiffTabs:i,activeCommitDiffKey:n.has(e.activeCommitDiffKey)?a?.key||``:e.activeCommitDiffKey,uncontrolledActiveTab:a?e.uncontrolledActiveTab:e.uncontrolledActiveTab===`commit-diff`?`review`:e.uncontrolledActiveTab}}case`close-other-commit-diffs`:return{...e,commitDiffTabs:e.commitDiffTabs.filter(e=>e.key===t.key),activeCommitDiffKey:t.key,uncontrolledActiveTab:`commit-diff`};case`reorder-commit-diffs`:{let n=new Map(e.commitDiffTabs.map(e=>[e.key,e])),r=t.keys.flatMap(e=>{let t=n.get(e);return t?[t]:[]}),i=new Set(t.keys),a=e.commitDiffTabs.filter(e=>!i.has(e.key));return{...e,commitDiffTabs:[...r,...a]}}case`reset-navigation`:return{...e,inlineActiveFilePath:``,commitDiffTabs:[],activeCommitDiffKey:``,uncontrolledActiveTab:t.resetActiveTab?`review`:e.uncontrolledActiveTab}}}function kg(e,t){return`${t}:${e.prevName||``}:${e.name}`}function Ag(e){return e.hunks.reduce((e,t)=>({additions:e.additions+t.additionLines,deletions:e.deletions+t.deletionLines}),{additions:0,deletions:0})}function jg(e){return e===`deletions`?`old`:`new`}function Mg({comments:e,pendingComment:t}){let n=e.map(e=>({lineNumber:e.lineNumber,metadata:e,side:e.side}));return t&&n.push({lineNumber:t.lineNumber,metadata:t,side:t.side}),n}function Ng(e,t){for(let n of t.split(/\s+/))n&&e.classList.add(n)}function Pg(e){let t=document.createElement(`form`);Ng(t,`m-2 w-[calc(100%_-_1rem)] max-w-[38rem] rounded-lg border border-border/70 bg-background p-2 shadow-sm`);let n=document.createElement(`div`);Ng(n,`mb-2 flex min-w-0 items-center justify-between gap-2 text-xs text-muted-foreground`);let r=document.createElement(`span`);r.textContent=`Comment on ${e.path}:L${e.lineNumber} (${jg(e.side)})`,Ng(r,`min-w-0 truncate`);let i=document.createElement(`button`);i.type=`button`,i.textContent=`×`,i.setAttribute(`aria-label`,`Cancel line comment`),Ng(i,`inline-flex size-7 shrink-0 items-center justify-center rounded-md text-muted-foreground hover:bg-muted hover:text-foreground`),i.addEventListener(`click`,()=>e.onCancel()),n.append(r,i);let a=document.createElement(`textarea`);a.rows=2,a.placeholder=`Add a note for the prompt…`,Ng(a,`flex min-h-16 w-full resize-none rounded-lg border border-input bg-transparent px-2.5 py-2 text-sm outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50`),a.addEventListener(`keydown`,t=>{t.key===`Enter`&&(t.metaKey||t.ctrlKey)&&(t.preventDefault(),u()),t.key===`Escape`&&(t.preventDefault(),e.onCancel())});let o=document.createElement(`div`);Ng(o,`mt-2 flex flex-wrap justify-end gap-2`);let s=document.createElement(`button`);s.type=`button`,s.textContent=`Cancel`,Ng(s,`inline-flex h-8 items-center rounded-md px-3 text-sm hover:bg-muted`),s.addEventListener(`click`,()=>e.onCancel());let c=document.createElement(`button`);c.type=`submit`,c.textContent=`Add to prompt`,Ng(c,`inline-flex h-8 items-center rounded-md bg-primary px-3 text-sm font-medium text-primary-foreground disabled:pointer-events-none disabled:opacity-50`);function l(){c.disabled=a.value.trim().length===0}function u(){let t=a.value.trim();t&&e.onSubmit(t)}return a.addEventListener(`input`,l),t.addEventListener(`submit`,e=>{e.preventDefault(),u()}),o.append(s,c),t.append(n,a,o),l(),window.setTimeout(()=>a.focus(),0),t}function Fg(e){let t=e.metadata;if(!t)return;if(t.kind===`pending`)return Pg(t);let n=t,r=document.createElement(`div`);Ng(r,`my-1 ml-2 inline-flex max-w-[min(32rem,calc(100vw_-_5rem),90%)] items-center gap-1 rounded-full border border-amber-500/20 bg-amber-500/10 px-2 py-1 text-[11px] text-amber-800 dark:text-amber-200`);let i=document.createElement(`span`);i.textContent=`💬`,Ng(i,`shrink-0`);let a=document.createElement(`span`);return a.textContent=n.text,Ng(a,`truncate`),r.append(i,a),r}function Ig(e){let t=(0,J.c)(21),{comments:n,diffStyle:r,disableFileHeader:i,fileDiff:a,onStartComment:o,pendingComment:s}=e,c=i===void 0?!1:i,[l,u]=q.useState(null),d=q.useRef(null),f;t[0]!==n||t[1]!==s?(f=Mg({comments:n,pendingComment:s}),t[0]=n,t[1]=s,t[2]=f):f=t[2];let p=f,m=Dt(),h,g;t[3]!==a||t[4]!==o?(h=e=>{o({lineNumber:Math.min(e.start,e.end),path:a.name,side:e.side||e.endSide||`additions`})},g=e=>{o({lineNumber:e.lineNumber,path:a.name,side:e.annotationSide})},t[3]=a,t[4]=o,t[5]=h,t[6]=g):(h=t[5],g=t[6]);let _;t[7]!==r||t[8]!==c||t[9]!==h||t[10]!==g||t[11]!==m?(_={...m,diffStyle:r,disableFileHeader:c,enableGutterUtility:!0,lineDiffType:`word-alt`,lineHoverHighlight:`both`,maxLineDiffLength:1e3,onGutterUtilityClick:h,onLineNumberClick:g,overflow:`wrap`,renderAnnotation:Fg},t[7]=r,t[8]=c,t[9]=h,t[10]=g,t[11]=m,t[12]=_):_=t[12];let v=_,y;t[13]!==l||t[14]!==a||t[15]!==p||t[16]!==v?(y=()=>{if(!l)return;let e=d.current;if(e){e.setOptions(v),e.render({containerWrapper:l,fileDiff:a,forceRender:!0,lineAnnotations:p});return}let t=new jt(v,void 0,!1);d.current=t,t.render({containerWrapper:l,fileDiff:a,lineAnnotations:p})},t[13]=l,t[14]=a,t[15]=p,t[16]=v,t[17]=y):y=t[17],q.useLayoutEffect(y);let b,x;t[18]===Symbol.for(`react.memo_cache_sentinel`)?(b=()=>()=>{d.current?.cleanUp(),d.current=null},x=[],t[18]=b,t[19]=x):(b=t[18],x=t[19]),q.useLayoutEffect(b,x);let S;return t[20]===Symbol.for(`react.memo_cache_sentinel`)?(S=q.createElement(`div`,{ref:u}),t[20]=S):S=t[20],S}function Lg(e){let t=(0,J.c)(40),{comments:n,diffStyle:r,fileDiff:i,index:a,onStartComment:o,pendingComment:c,stuck:l}=e,u;t[0]!==i||t[1]!==a?(u=kg(i,a),t[0]=i,t[1]=a,t[2]=u):u=t[2];let d=u,f;t[3]===i?f=t[4]:(f=Ag(i),t[3]=i,t[4]=f);let p=f,m=l&&`shadow-sm`,h;t[5]===m?h=t[6]:(h=s(`sticky top-0 z-20 flex bg-background transition-shadow`,m),t[5]=m,t[6]=h);let g;t[7]!==i.name||t[8]!==i.prevName?(g=i.prevName?(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:i.prevName}),(0,Y.jsx)(`span`,{className:`text-muted-foreground/70`,children:` → `}),(0,Y.jsx)(`span`,{children:i.name})]}):i.name,t[7]=i.name,t[8]=i.prevName,t[9]=g):g=t[9];let _;t[10]===g?_=t[11]:(_=(0,Y.jsx)(`span`,{className:`min-w-0 truncate text-left`,children:g}),t[10]=g,t[11]=_);let v;t[12]===p.additions?v=t[13]:(v=p.additions>0?(0,Y.jsxs)(`span`,{className:`text-emerald-500`,children:[`+`,p.additions]}):null,t[12]=p.additions,t[13]=v);let y;t[14]===p.deletions?y=t[15]:(y=p.deletions>0?(0,Y.jsxs)(`span`,{className:`text-red-500`,children:[`-`,p.deletions]}):null,t[14]=p.deletions,t[15]=y);let b;t[16]!==v||t[17]!==y?(b=(0,Y.jsxs)(`span`,{className:`inline-flex min-w-0 gap-2 justify-self-end whitespace-nowrap tabular-nums`,children:[v,y]}),t[16]=v,t[17]=y,t[18]=b):b=t[18];let x;t[19]!==_||t[20]!==b?(x=(0,Y.jsxs)(`span`,{className:`grid min-w-0 flex-1 grid-cols-[minmax(0,1fr)_auto] items-baseline gap-3`,children:[_,b]}),t[19]=_,t[20]=b,t[21]=x):x=t[21];let S,C;t[22]===Symbol.for(`react.memo_cache_sentinel`)?(S=(0,Y.jsx)(P,{"data-slot":`accordion-trigger-icon`,className:`pointer-events-none size-4 shrink-0 group-aria-expanded/commit-file-trigger:hidden`}),C=(0,Y.jsx)(z,{"data-slot":`accordion-trigger-icon`,className:`pointer-events-none hidden size-4 shrink-0 group-aria-expanded/commit-file-trigger:inline`}),t[22]=S,t[23]=C):(S=t[22],C=t[23]);let w;t[24]!==x||t[25]!==d?(w=(0,Y.jsxs)(Ke,{"data-commit-file-trigger":!0,"data-commit-file-value":d,className:`group/commit-file-trigger relative flex min-h-10 min-w-0 flex-1 items-center justify-between gap-3 rounded-none border border-transparent bg-background px-3 py-2 text-left text-[13px] font-medium transition-all outline-none hover:no-underline focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 aria-disabled:pointer-events-none aria-disabled:opacity-50 **:data-[slot=accordion-trigger-icon]:ml-auto **:data-[slot=accordion-trigger-icon]:size-4 **:data-[slot=accordion-trigger-icon]:text-muted-foreground`,children:[x,S,C]}),t[24]=x,t[25]=d,t[26]=w):w=t[26];let T;t[27]!==w||t[28]!==h?(T=(0,Y.jsx)(pt,{className:h,children:w}),t[27]=w,t[28]=h,t[29]=T):T=t[29];let E;t[30]!==n||t[31]!==r||t[32]!==i||t[33]!==o||t[34]!==c?(E=(0,Y.jsx)(Be,{className:`bg-background p-0`,children:(0,Y.jsx)(Ig,{comments:n,diffStyle:r,disableFileHeader:!0,fileDiff:i,onStartComment:o,pendingComment:c})}),t[30]=n,t[31]=r,t[32]=i,t[33]=o,t[34]=c,t[35]=E):E=t[35];let D;return t[36]!==T||t[37]!==E||t[38]!==d?(D=(0,Y.jsxs)(it,{value:d,className:`border-border/70`,children:[T,E]}),t[36]=T,t[37]=E,t[38]=d,t[39]=D):D=t[39],D}function Rg(e){let t=(0,J.c)(10),{comments:n,diffStyle:r,onStartComment:i,patch:a,pendingComment:o}=e,s;t[0]===a?s=t[1]:(s=A(a).flatMap(zg),t[0]=a,t[1]=s);let c=s[0];if(!c){let e;return t[2]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(`div`,{className:`p-4`,children:(0,Y.jsx)(tp,{children:`No line changes.`})}),t[2]=e):e=t[2],e}let l;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(l={"--diffs-font-family":`var(--font-mono, ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace)`},t[3]=l):l=t[3];let u;return t[4]!==n||t[5]!==r||t[6]!==c||t[7]!==i||t[8]!==o?(u=(0,Y.jsx)(`div`,{className:`min-h-full text-xs`,style:l,children:(0,Y.jsx)(Ig,{comments:n,diffStyle:r,fileDiff:c,onStartComment:i,pendingComment:o})}),t[4]=n,t[5]=r,t[6]=c,t[7]=i,t[8]=o,t[9]=u):u=t[9],u}function zg(e){return e.files}function Bg(e){let t=(0,J.c)(32),{comments:n,diffStyle:r,onStartComment:i,patch:a,pendingComment:o,stuckFileValue:s}=e,c,l,u,d,f,p,m,h;if(t[0]!==n||t[1]!==r||t[2]!==i||t[3]!==a||t[4]!==o||t[5]!==s){h=Symbol.for(`react.early_return_sentinel`);bb0:{let e=A(a).flatMap(Vg),g=e[0]?kg(e[0],0):void 0;if(e.length===0){let e;t[14]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(`div`,{className:`p-4`,children:(0,Y.jsx)(tp,{children:`No line changes.`})}),t[14]=e):e=t[14],h=e;break bb0}p=`min-h-full text-xs`;let _;t[15]===Symbol.for(`react.memo_cache_sentinel`)?(_={"--diffs-font-family":`var(--font-mono, ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace)`},t[15]=_):_=t[15],m=_,c=bt,l=!0,u=g?[g]:[],d=`border-b border-border/80`;let v;t[16]!==n||t[17]!==r||t[18]!==i||t[19]!==o||t[20]!==s?(v=(e,t)=>(0,Y.jsx)(Lg,{comments:n.filter(t=>t.path===e.name),diffStyle:r,fileDiff:e,index:t,onStartComment:i,pendingComment:o?.path===e.name?o:null,stuck:s===kg(e,t)},kg(e,t)),t[16]=n,t[17]=r,t[18]=i,t[19]=o,t[20]=s,t[21]=v):v=t[21],f=e.map(v)}t[0]=n,t[1]=r,t[2]=i,t[3]=a,t[4]=o,t[5]=s,t[6]=c,t[7]=l,t[8]=u,t[9]=d,t[10]=f,t[11]=p,t[12]=m,t[13]=h}else c=t[6],l=t[7],u=t[8],d=t[9],f=t[10],p=t[11],m=t[12],h=t[13];if(h!==Symbol.for(`react.early_return_sentinel`))return h;let g;t[22]!==c||t[23]!==l||t[24]!==u||t[25]!==d||t[26]!==f?(g=(0,Y.jsx)(c,{multiple:l,defaultValue:u,className:d,children:f}),t[22]=c,t[23]=l,t[24]=u,t[25]=d,t[26]=f,t[27]=g):g=t[27];let _;return t[28]!==p||t[29]!==m||t[30]!==g?(_=(0,Y.jsx)(`div`,{className:p,style:m,children:g}),t[28]=p,t[29]=m,t[30]=g,t[31]=_):_=t[31],_}function Vg(e){return e.files}function Hg(e){let t=(0,J.c)(15),{path:n}=e,r,i,a,o,s,c;if(t[0]!==n){c=Symbol.for(`react.early_return_sentinel`);bb0:{let e=n.split(`/`).filter(Boolean);if(e.length===0){c=null;break bb0}i=Tn,s=n,r=En,a=`flex-nowrap gap-1 font-mono text-xs whitespace-nowrap`,o=e.map((t,n)=>{let r=n===e.length-1,i=`${n}:${t}`;return(0,Y.jsxs)(q.Fragment,{children:[n>0?(0,Y.jsx)(kn,{className:`text-muted-foreground/60`}):null,(0,Y.jsx)(Dn,{className:`min-w-0 shrink-0`,children:r?(0,Y.jsx)(On,{className:`max-w-80 truncate font-mono text-xs font-medium`,children:t}):(0,Y.jsx)(`span`,{className:`max-w-40 truncate text-muted-foreground`,children:t})})]},i)})}t[0]=n,t[1]=r,t[2]=i,t[3]=a,t[4]=o,t[5]=s,t[6]=c}else r=t[1],i=t[2],a=t[3],o=t[4],s=t[5],c=t[6];if(c!==Symbol.for(`react.early_return_sentinel`))return c;let l;t[7]!==r||t[8]!==a||t[9]!==o?(l=(0,Y.jsx)(r,{className:a,children:o}),t[7]=r,t[8]=a,t[9]=o,t[10]=l):l=t[10];let u;return t[11]!==i||t[12]!==s||t[13]!==l?(u=(0,Y.jsx)(i,{title:s,children:l}),t[11]=i,t[12]=s,t[13]=l,t[14]=u):u=t[14],u}function Ug(e){let t=(0,J.c)(5),{tab:n}=e;if(!n.path){let e;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(`div`,{className:`truncate text-xs font-bold tracking-[0.04em] text-muted-foreground uppercase`,children:`Commit diff`}),t[0]=e):e=t[0];let r;return t[1]===n.title?r=t[2]:(r=(0,Y.jsxs)(`div`,{className:`min-w-0`,children:[e,(0,Y.jsx)(`div`,{className:`mt-0.5 truncate font-mono text-xs text-muted-foreground`,children:n.title})]}),t[1]=n.title,t[2]=r),r}let r;return t[3]===n.path?r=t[4]:(r=(0,Y.jsx)(`div`,{className:`min-w-0 flex-1 overflow-x-auto`,children:(0,Y.jsx)(Hg,{path:n.path})}),t[3]=n.path,t[4]=r),r}function Wg(e){let t=(0,J.c)(55),{viewerContextId:n,cwd:r,active:i,diffLineComments:a,onAddDiffLineComment:o,tab:s}=e,[c,l]=q.useState(`unified`),[u,d]=q.useState(``),f=tt(),[p,m]=q.useState(null),h=q.useRef(null),{bottomHeight:g,onScroll:_,setScrollElement:v,topHeight:y}=ut(),b;t[0]===v?b=t[1]:(b=e=>{h.current=e,v(e)},t[0]=v,t[1]=b);let x=b,S;t[2]===Symbol.for(`react.memo_cache_sentinel`)?(S=e=>{jh(d,Nh({getValue:Gg,scrollElement:e,selector:`[data-commit-file-trigger]`}))},t[2]=S):S=t[2];let w=S,T;t[3]!==r||t[4]!==s||t[5]!==n?(T=s?tn.gitCommitDiff(n,r,s.commit,s.mode,s.path,s.previousPath):[`pico`,`git-commit-diff`,n,r,``,``],t[3]=r,t[4]=s,t[5]=n,t[6]=T):T=t[6];let E;t[7]!==r||t[8]!==s||t[9]!==n?(E=()=>Qt(en(`/api/git-commit-diff?cwd=${encodeURIComponent(r)}&commit=${encodeURIComponent(s?.commit||``)}&mode=${encodeURIComponent(s?.mode||`commit`)}${s?.path?`&path=${encodeURIComponent(s.path)}`:``}${s?.previousPath?`&previousPath=${encodeURIComponent(s.previousPath)}`:``}`,{contextId:n})),t[7]=r,t[8]=s,t[9]=n,t[10]=E):E=t[10];let D=!!(i&&n&&r&&s?.commit),O;t[11]===Symbol.for(`react.memo_cache_sentinel`)?(O=[`data`,`isPending`,`error`],t[11]=O):O=t[11];let k;t[12]!==T||t[13]!==E||t[14]!==D?(k={queryKey:T,queryFn:E,enabled:D,notifyOnChangeProps:O},t[12]=T,t[13]=E,t[14]=D,t[15]=k):k=t[15];let A=ee(k),j=s?a.filter(e=>e.tabKey===s.key&&e.commit===s.commit&&e.mode===s.mode):yg,M;t[16]!==o||t[17]!==s?(M=e=>{!s||!o||m({commit:s.commit,lineNumber:e.lineNumber,mode:s.mode,path:e.path,shortHash:s.shortHash,side:e.side,tabKey:s.key,tabTitle:s.title})},t[16]=o,t[17]=s,t[18]=M):M=t[18];let N=M,P;t[19]!==p||t[20]!==o?(P=p?{...p,kind:`pending`,onCancel:()=>m(null),onSubmit:e=>{o?.({...p,text:e}),m(null)}}:null,t[19]=p,t[20]=o,t[21]=P):P=t[21];let F=P,I;t[22]===Symbol.for(`react.memo_cache_sentinel`)?(I=()=>{m(null),jh(d,``),w(h.current)},t[22]=I):I=t[22];let L=s?.key,R=A.data?.patch,z;if(t[23]!==L||t[24]!==R?(z=[L,R],t[23]=L,t[24]=R,t[25]=z):z=t[25],q.useEffect(I,z),!s){let e;return t[26]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Y.jsx)(`div`,{className:`flex h-full items-center justify-center p-6 text-center text-sm text-muted-foreground`,children:`Select a commit diff tab.`}),t[26]=e):e=t[26],e}let B;t[27]===s?B=t[28]:(B=(0,Y.jsx)(Ug,{tab:s}),t[27]=s,t[28]=B);let V=f?`default`:`sm`,H;t[29]===c?H=t[30]:(H=[c],t[29]=c,t[30]=H);let U,te,ne;t[31]===Symbol.for(`react.memo_cache_sentinel`)?(U=e=>{let t=e[0];(t===`unified`||t===`split`)&&l(t)},te=(0,Y.jsx)(Yf,{value:`unified`,children:`Unified`}),ne=(0,Y.jsx)(Yf,{value:`split`,children:`Split`}),t[31]=U,t[32]=te,t[33]=ne):(U=t[31],te=t[32],ne=t[33]);let re;t[34]!==V||t[35]!==H?(re=(0,Y.jsxs)(Jf,{variant:`outline`,size:V,value:H,onValueChange:U,children:[te,ne]}),t[34]=V,t[35]=H,t[36]=re):re=t[36];let W;t[37]!==B||t[38]!==re?(W=(0,Y.jsxs)(`div`,{className:`flex min-h-10 shrink-0 items-center justify-between gap-2 border-b border-border/70 bg-background p-2`,children:[B,re]}),t[37]=B,t[38]=re,t[39]=W):W=t[39];let G;t[40]===_?G=t[41]:(G=e=>{w(e.currentTarget),_(e)},t[40]=_,t[41]=G);let ie=A.isPending&&!A.data?(0,Y.jsx)(`div`,{className:`p-4`,children:(0,Y.jsxs)(tp,{children:[(0,Y.jsx)(C,{}),` Loading commit diff…`]})}):A.error?(0,Y.jsx)(`div`,{className:`p-4`,children:(0,Y.jsx)(tp,{tone:`destructive`,children:ft(A.error,`Failed to load commit diff`)})}):A.data?.patch&&s.path?(0,Y.jsx)(Rg,{comments:j.filter(e=>s.path?e.path===s.path||e.path===s.previousPath:!0),diffStyle:c,onStartComment:N,patch:A.data.patch,pendingComment:F}):A.data?.patch?(0,Y.jsx)(Bg,{comments:j,diffStyle:c,onStartComment:N,patch:A.data.patch,pendingComment:F,stuckFileValue:u},`${A.data.commit}:${A.data.mode}`):(0,Y.jsx)(`div`,{className:`p-4`,children:(0,Y.jsx)(tp,{children:`No line changes.`})}),ae;t[42]!==x||t[43]!==G||t[44]!==ie?(ae=(0,Y.jsx)(`div`,{ref:x,className:`h-full overflow-auto`,onScroll:G,children:ie}),t[42]=x,t[43]=G,t[44]=ie,t[45]=ae):ae=t[45];let oe;t[46]!==g||t[47]!==y?(oe=(0,Y.jsx)(Pe,{bottomHeight:g,topHeight:y}),t[46]=g,t[47]=y,t[48]=oe):oe=t[48];let se;t[49]!==ae||t[50]!==oe?(se=(0,Y.jsxs)(`div`,{className:`relative min-h-0 flex-1`,children:[ae,oe]}),t[49]=ae,t[50]=oe,t[51]=se):se=t[51];let ce;return t[52]!==W||t[53]!==se?(ce=(0,Y.jsxs)(`div`,{className:`flex h-full min-h-0 flex-col bg-background`,children:[W,se]}),t[52]=W,t[53]=se,t[54]=ce):ce=t[54],ce}function Gg(e){return e.dataset.commitFileValue||``}function Kg({viewerContextId:e,cwd:t,active:n,activeFilePath:r=``,activeTab:i,diffLineComments:a=yg,filePreviewPath:o=``,fileTabs:c=bg,fileTreeCollapsed:l=!1,onActiveFileChange:u,onActiveTabChange:d,onAddDiffLineComment:f,onCloseAllFiles:p,onCloseFile:m,onCloseFilesToRight:h,onCloseOtherFiles:g,onFileTreeCollapsedChange:_,onOpenFile:v,onReorderFiles:y,showToolbar:b=!0}){let x=xt(t),S=tt(),[C,w]=q.useReducer(Og,Dg),[T,E]=q.useState(xg),D=i!==void 0,O=i??C.uncontrolledActiveTab,k=q.useRef(O);k.current=O;let A=q.useEffectEvent(e=>{d?.(e)}),j=e=>{w({type:`set-active-tab`,tab:e}),d?.(e)},M=e=>{E(e),Sg(e)},N=`external`,P=b&&!S,F=r,I=c.length>0,L=C.commitDiffTabs.find(e=>e.key===C.activeCommitDiffKey)??C.commitDiffTabs[0],R=ee({...bp({viewerContextId:e,cwd:x}),enabled:!!(n&&I&&e&&x),select:e=>e.paths,notifyOnChangeProps:[`data`]}).data??[],z=(e,t)=>{e&&(j(`files`),v?.(e,t),u?.(e))},B=e=>{e.commit&&(w({type:`upsert-commit-diff-tab`,tab:Eg(e)}),d?.(`commit-diff`))},V=e=>{let t=new Set(e),n=t.has(C.activeCommitDiffKey),r=C.commitDiffTabs.filter(e=>!t.has(e.key));w({type:`close-commit-diff-keys`,keys:e}),n&&r.length===0&&d?.(`review`)};return q.useEffect(()=>{w({type:`reset-navigation`,resetActiveTab:!D}),k.current===`commit-diff`&&A(`review`)},[D,S,x]),(0,Y.jsxs)(`div`,{className:`h-full min-h-[520px] w-full min-w-0`,children:[(0,Y.jsx)(Em,{viewerContextId:e,cwd:x,active:n}),(0,Y.jsxs)(`div`,{className:s(`flex h-full min-h-[520px] min-w-0 flex-col overflow-hidden bg-card/50`,P?`rounded-xl border border-border/80`:`rounded-none border-0`),children:[(0,Y.jsx)(Jp,{activeCommitDiffKey:L?.key||``,activeFilePath:F,activeTab:O,commitDiffTabs:C.commitDiffTabs,filePreviewPath:o,fileTabs:c,onActiveCommitDiffChange:e=>w({type:`set-active-commit-diff-key`,key:e}),onActiveFileChange:u,onActiveTabChange:e=>{S&&e===`files`&&u?.(``),j(e)},onCloseAllCommitDiffs:()=>{V(C.commitDiffTabs.map(e=>e.key))},onCloseAllFiles:p,onCloseCommitDiff:e=>{V([e])},onCloseCommitDiffsToRight:e=>{let t=C.commitDiffTabs.findIndex(t=>t.key===e);t<0||V(C.commitDiffTabs.slice(t+1).map(e=>e.key))},onCloseFile:m,onCloseFilesToRight:h,onCloseOtherCommitDiffs:e=>{w({type:`close-other-commit-diffs`,key:e}),d?.(`commit-diff`)},onCloseOtherFiles:g,onOpenFileDialog:()=>{w({type:`set-open-file-dialog-open`,open:!0})},onReorderCommitDiffs:e=>{w({type:`reorder-commit-diffs`,keys:e})},onReorderFiles:y,showFiles:S&&I,showHistory:T,showReview:!0}),(0,Y.jsx)(`div`,{className:O===`review`?`min-h-0 flex-1 overflow-hidden`:`hidden`,children:(0,Y.jsx)(cg,{viewerContextId:e,cwd:x,active:n&&O===`review`,diffLineComments:a,onMaximizeHistory:()=>{M(!0),j(`history`)},onAddDiffLineComment:f,onOpenCommitDiff:B,onOpenFile:z,showEmbeddedHistory:!T})}),(0,Y.jsx)(`div`,{className:O===`history`?`min-h-0 flex-1 overflow-hidden`:`hidden`,children:(0,Y.jsx)(Oh,{viewerContextId:e,cwd:x,active:n&&O===`history`,flush:!0,onOpenCommitDiff:B,onRestoreEmbedded:()=>{M(!1),j(`review`)}})}),(0,Y.jsx)(`div`,{className:O===`commit-diff`?`min-h-0 flex-1 overflow-hidden`:`hidden`,children:(0,Y.jsx)(Wg,{viewerContextId:e,cwd:x,active:n&&O===`commit-diff`,diffLineComments:a,onAddDiffLineComment:f,tab:L})}),(0,Y.jsx)(`div`,{className:O===`files`?`min-h-0 flex-1 overflow-hidden`:`hidden`,children:S?F?(0,Y.jsxs)(`div`,{className:`flex h-full min-h-0 min-w-0 flex-col overflow-hidden`,children:[(0,Y.jsx)(um,{path:F}),(0,Y.jsx)(`div`,{className:`min-h-0 min-w-0 flex-1 overflow-hidden`,children:(0,Y.jsx)(Fp,{viewerContextId:e,cwd:x,active:n&&O===`files`,path:F})})]}):(0,Y.jsx)(Ap,{viewerContextId:e,cwd:x,active:n&&O===`files`,activeFilePath:F,onOpenFile:z,previewMode:N}):I?(0,Y.jsxs)(`div`,{className:`flex h-full min-h-0 min-w-0 flex-col overflow-hidden`,children:[F?(0,Y.jsx)(um,{path:F,fileTreeCollapsed:l,onFileTreeCollapsedChange:_}):null,(0,Y.jsxs)(`div`,{className:`flex min-h-0 flex-1 overflow-hidden`,children:[l?null:(0,Y.jsx)(om,{viewerContextId:e,cwd:x,active:n&&O===`files`,activeFilePath:F,onOpenFile:z,previewMode:N}),F?(0,Y.jsx)(`div`,{className:`min-h-0 min-w-0 flex-1 overflow-hidden`,children:(0,Y.jsx)(Fp,{viewerContextId:e,cwd:x,active:n&&O===`files`,path:F})}):null]})]}):(0,Y.jsx)(Ap,{viewerContextId:e,cwd:x,active:n&&O===`files`,activeFilePath:F,onOpenFile:z,previewMode:N})}),(0,Y.jsx)(Pp,{open:C.openFileDialogOpen,onOpenChange:e=>w({type:`set-open-file-dialog-open`,open:e}),paths:R,onOpenFile:e=>{z(e,{pin:!0})}})]})]})}export{Kg as RightSidebar};
|