@vite-hub/ui 0.5.0 → 0.5.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/dist/andromeeda-DaUPZ4_A.js +147 -0
- package/dist/{announce-Cy_Tn9wW.js → announce-B0DLwflT.js} +1 -2
- package/dist/{attachments-BzTwqRTU.js → attachments-DgwoQZKY.js} +3 -5
- package/dist/aurora-x-B5RPZ9i5.js +162 -0
- package/dist/{avatar-stack-DXmCQhxd.d.ts → avatar-stack-C0IKwj6g.d.ts} +0 -2
- package/dist/ayu-dark-DXTaGA7I.js +137 -0
- package/dist/ayu-light-BCYi80Fe.js +137 -0
- package/dist/ayu-mirage-CgbXz-N5.js +137 -0
- package/dist/catppuccin-frappe-MV2xzv44.js +266 -0
- package/dist/catppuccin-latte-CL6jjlVD.js +266 -0
- package/dist/catppuccin-macchiato-Bp6oZJVK.js +266 -0
- package/dist/catppuccin-mocha-DOHrQ4dw.js +266 -0
- package/dist/{choices-input-ByXJvDn1.d.ts → choices-input-BUf-QqGj.d.ts} +0 -2
- package/dist/{code-view-DsU-xzic.js → code-view-Cg4nyTNA.js} +6 -8
- package/dist/{colors-BghReA9C-CjF9gnmy.js → colors-BghReA9C-DEq4bhEP.js} +1 -2
- package/dist/{comment-attachments-C4yNbcx5.js → comment-attachments-CMpYOJod.js} +1 -2
- package/dist/{comment-composer-DvKMTrAi.d.ts → comment-composer-BI6CNJyO.d.ts} +1 -3
- package/dist/{comment-composer-D7ZytyER.js → comment-composer-CzU7DdfD.js} +11 -14
- package/dist/{comment-layer-GTsLdABl.d.ts → comment-layer-DyVstrs-.d.ts} +5 -7
- package/dist/{comment-list-BI96empx.d.ts → comment-list-CSK5o-Ua.d.ts} +3 -5
- package/dist/{comment-panel-CsKWTms_.d.ts → comment-panel-CEvOI3gk.d.ts} +2 -4
- package/dist/{comment-person-CLPlW_SS.js → comment-person-D_IyIjXo.js} +1 -2
- package/dist/{comment-pin-CvwgRSDR.d.ts → comment-pin-C5UeLPTa.d.ts} +0 -2
- package/dist/{comment-row-JmTC0uXr.js → comment-row-DPMWI5Z0.js} +3 -4
- package/dist/{comment-selection-bar-CyVBNYl9.d.ts → comment-selection-bar-CVuS-FNL.d.ts} +0 -2
- package/dist/{comment-send-7bg4NEEM.js → comment-send-DPzV9B8S.js} +6 -8
- package/dist/{comment-send-C45dHC22.d.ts → comment-send-MmxFsOQf.d.ts} +0 -2
- package/dist/{comment-thread-B_Sc2QX6.js → comment-thread-CbPtoi8-.js} +13 -14
- package/dist/{comment-thread-C6U-bsK_.d.ts → comment-thread-DGm1cGJt.d.ts} +4 -8
- package/dist/{comment-visibility-DsVuVndP.d.ts → comment-visibility-CYctacNx.d.ts} +0 -2
- package/dist/{comments-B88zg9gC.js → comments-C0OdHh_F.js} +5 -8
- package/dist/{comments-D8hulVPy.d.ts → comments-DrE9DU-E.d.ts} +1 -3
- package/dist/{comments-context-DhbIdYQ1.js → comments-context-CrjhleVA.js} +2 -4
- package/dist/{config-B1u7zqMB.js → config-DztmAYYn.js} +3 -4
- package/dist/{config-pHazYdq6.d.ts → config-xL4EBeXw.d.ts} +0 -4
- package/dist/dark-plus-CXEBSjk4.js +148 -0
- package/dist/dracula-Bvyz6eCo.js +165 -0
- package/dist/dracula-soft-a9indxAQ.js +115 -0
- package/dist/{draw-DzSmD7uo-Dwz8zoH2.js → draw-DzSmD7uo-Cb7s9kxJ.js} +359 -708
- package/dist/{drop-field-3CDRFFRm.js → drop-field-CNZgwFVO.js} +2 -3
- package/dist/{editor-BHYGLgty.js → editor-CGiEVOnB.js} +5 -6
- package/dist/{effects-Ql6VzCRa.js → effects-g4QucvgO.js} +20 -36
- package/dist/{error-diagnostics-SXtnk6bz.js → error-diagnostics-BlgA9rI2.js} +1 -2
- package/dist/everforest-dark-9sVAxG7I.js +99 -0
- package/dist/everforest-light-BocTn_Hd.js +99 -0
- package/dist/{file-tree-C4OYgbV-.js → file-tree-CRFIdtzw.js} +58 -116
- package/dist/{file-tree-DlT9RGhu.d.ts → file-tree-DOtkeBaq.d.ts} +0 -14
- package/dist/{format-orwcdZL_.js → format-Bc9m7-r0.js} +1 -2
- package/dist/{getSingularPatch-Dsb8EgxR.js → getSingularPatch-C7LmmBrW.js} +375 -79
- package/dist/github-dark-BO9SXswM.js +142 -0
- package/dist/github-dark-default-XB_RHfBI.js +90 -0
- package/dist/github-dark-dimmed-BoGxaWUQ.js +137 -0
- package/dist/github-dark-high-contrast-B3X6t2fG.js +137 -0
- package/dist/github-light-D7VHHlUH.js +142 -0
- package/dist/github-light-default-BuDsGtcR.js +137 -0
- package/dist/github-light-high-contrast-GodZiAwh.js +137 -0
- package/dist/gruvbox-dark-hard-CU4LuKJc.js +140 -0
- package/dist/gruvbox-dark-medium-DjAsuXuH.js +140 -0
- package/dist/gruvbox-dark-soft-D3Zttj6R.js +140 -0
- package/dist/gruvbox-light-hard-4M_9onwE.js +140 -0
- package/dist/gruvbox-light-medium-D9QwS4kQ.js +140 -0
- package/dist/gruvbox-light-soft-DhYcfQql.js +140 -0
- package/dist/{handlers-DMl-Na3x.js → handlers-CnbkvXjX.js} +1 -2
- package/dist/headless.d.ts +4 -4
- package/dist/headless.js +1 -1
- package/dist/highlights-C2AbEdDI.js +2630 -0
- package/dist/{hold-to-delete-DjWzRDyY.d.ts → hold-to-delete-BSMrpE-i.d.ts} +0 -2
- package/dist/{hold-to-delete-ROLQRZg_.js → hold-to-delete-Cludb56v.js} +6 -7
- package/dist/horizon-bright-B9u59onx.js +97 -0
- package/dist/horizon-tItY9ATR.js +97 -0
- package/dist/houston-BqKrKNQv.js +207 -0
- package/dist/{icon-c5Jb_Tl7.d.ts → icon-XZaCUZTG.d.ts} +0 -2
- package/dist/{image-preview-BigoAvb3.js → image-preview-DrLXrHpp.js} +3 -4
- package/dist/{index-CNY1uNTh.d.ts → index-B2cbt3py.d.ts} +3945 -2445
- package/dist/{index-YUvL2nV8.d.ts → index-B_PSX-5h.d.ts} +0 -4
- package/dist/index.d.ts +29 -31
- package/dist/index.js +42 -45
- package/dist/{install-D5f6msEU.js → install-Ba9mkkqI.js} +2 -3
- package/dist/kanagawa-dragon-BH1K3aMw.js +159 -0
- package/dist/kanagawa-lotus-C-4JB2io.js +159 -0
- package/dist/kanagawa-wave-DTQqNe5k.js +159 -0
- package/dist/laserwave-BkV0uIaG.js +84 -0
- package/dist/light-plus-CxYgEz7U.js +149 -0
- package/dist/{list-RCbNZ14q.js → list-DUTAo0uC.js} +5 -6
- package/dist/loader-CYMEjzwc.js +79 -0
- package/dist/{markdown-editor-Dfl2DgPS.js → markdown-editor-3gY9MLvy.js} +237 -38
- package/dist/{markdown-editor-wQF0yD5o.d.ts → markdown-editor-B7gD60tp.d.ts} +0 -6
- package/dist/markdown-editor.d.ts +1 -5
- package/dist/markdown-editor.js +2 -2
- package/dist/markdown-renderer-DFS1vf1h.js +26578 -0
- package/dist/material-theme-Xdm37UUJ.js +105 -0
- package/dist/material-theme-darker-Blaz0cgN.js +105 -0
- package/dist/material-theme-lighter-BddVxBVA.js +105 -0
- package/dist/material-theme-ocean-C4qhfFHi.js +105 -0
- package/dist/material-theme-palenight-ChHDqoiA.js +105 -0
- package/dist/{message-scroller-Bm1YWTeY.d.ts → message-scroller-a6qaYHno.d.ts} +0 -2
- package/dist/min-dark-DpGSNjaW.js +125 -0
- package/dist/min-light-BMfJUsU2.js +122 -0
- package/dist/monokai-DW19E-zg.js +162 -0
- package/dist/motion/core.d.ts +3 -3
- package/dist/motion/core.js +10 -10
- package/dist/{motion-core-lHRF8PZz.d.ts → motion-core-DNl7TR1T.d.ts} +0 -54
- package/dist/motion.d.ts +3 -5
- package/dist/motion.js +11 -11
- package/dist/night-owl-B7Of8ee9.js +188 -0
- package/dist/night-owl-light-Vu9tTNpS.js +189 -0
- package/dist/nord-CDzJumeN.js +128 -0
- package/dist/{nuxt-ui-CgvMzO5v.js → nuxt-ui-7ByUrymx.js} +1 -2
- package/dist/nuxt.d.ts +1 -7
- package/dist/nuxt.js +4 -8
- package/dist/one-dark-pro-hS_sNo5p.js +124 -0
- package/dist/one-light-CD4ItzSC.js +153 -0
- package/dist/{opt-out-b6bnUjIT.js → opt-out-D66l60sg.js} +3 -6
- package/dist/parts/components/agent-session.d.ts +1 -3
- package/dist/parts/components/agent-session.js +3 -4
- package/dist/parts/components/attachment.d.ts +1 -3
- package/dist/parts/components/attachment.js +3 -4
- package/dist/parts/components/avatar-stack.d.ts +1 -1
- package/dist/parts/components/avatar-stack.js +2 -3
- package/dist/parts/components/bubble.d.ts +1 -3
- package/dist/parts/components/bubble.js +2 -3
- package/dist/parts/components/chat-message.d.ts +1 -3
- package/dist/parts/components/chat-message.js +1 -2
- package/dist/parts/components/chat-session.d.ts +2 -4
- package/dist/parts/components/chat-session.js +1 -2
- package/dist/parts/components/chat.d.ts +1 -3
- package/dist/parts/components/chat.js +4 -5
- package/dist/parts/components/code-block.d.ts +1 -3
- package/dist/parts/components/code-block.js +2 -3
- package/dist/parts/components/code-view.d.ts +1 -3
- package/dist/parts/components/code-view.js +1 -2
- package/dist/parts/components/comment-composer.d.ts +1 -1
- package/dist/parts/components/comment-composer.js +1 -2
- package/dist/parts/components/comment-layer.d.ts +1 -1
- package/dist/parts/components/comment-layer.js +10 -11
- package/dist/parts/components/comment-list.d.ts +1 -1
- package/dist/parts/components/comment-list.js +5 -6
- package/dist/parts/components/comment-panel.d.ts +1 -1
- package/dist/parts/components/comment-panel.js +9 -10
- package/dist/parts/components/comment-pin.d.ts +1 -1
- package/dist/parts/components/comment-pin.js +2 -3
- package/dist/parts/components/comment-selection-bar.d.ts +1 -1
- package/dist/parts/components/comment-selection-bar.js +3 -4
- package/dist/parts/components/comment-send.d.ts +1 -1
- package/dist/parts/components/comment-send.js +1 -2
- package/dist/parts/components/comment-thread.d.ts +1 -1
- package/dist/parts/components/comment-thread.js +2 -2
- package/dist/parts/components/comments.d.ts +8 -8
- package/dist/parts/components/comments.js +6 -6
- package/dist/parts/components/connection-status.d.ts +1 -3
- package/dist/parts/components/connection-status.js +1 -2
- package/dist/parts/components/copy-button.d.ts +1 -3
- package/dist/parts/components/copy-button.js +6 -7
- package/dist/parts/components/device-frame.d.ts +1 -3
- package/dist/parts/components/device-frame.js +1 -2
- package/dist/parts/components/drop-field.d.ts +1 -3
- package/dist/parts/components/drop-field.js +2 -3
- package/dist/parts/components/file-tree.d.ts +1 -1
- package/dist/parts/components/file-tree.js +1 -2
- package/dist/parts/components/filter-search.d.ts +2 -4
- package/dist/parts/components/filter-search.js +2 -3
- package/dist/parts/components/hold-to-delete.d.ts +2 -4
- package/dist/parts/components/hold-to-delete.js +2 -3
- package/dist/parts/components/markdown-editor.d.ts +1 -1
- package/dist/parts/components/markdown-editor.js +1 -2
- package/dist/parts/components/markdown-renderer.d.ts +1 -3
- package/dist/parts/components/markdown-renderer.js +1 -23077
- package/dist/parts/components/markdown.d.ts +1 -3
- package/dist/parts/components/markdown.js +2 -3
- package/dist/parts/components/marker.d.ts +1 -3
- package/dist/parts/components/marker.js +2 -3
- package/dist/parts/components/message-parts.d.ts +1 -3
- package/dist/parts/components/message-parts.js +2 -3
- package/dist/parts/components/message.d.ts +1 -3
- package/dist/parts/components/message.js +2 -3
- package/dist/parts/components/motion-list.d.ts +1 -3
- package/dist/parts/components/motion-list.js +2 -3
- package/dist/parts/components/motion.d.ts +2 -4
- package/dist/parts/components/motion.js +4 -5
- package/dist/parts/components/patch-parsers.d.ts +1 -1
- package/dist/parts/components/patch-parsers.js +1 -2
- package/dist/parts/components/progress.d.ts +1 -3
- package/dist/parts/components/progress.js +2 -3
- package/dist/parts/components/prompt-input.d.ts +2 -4
- package/dist/parts/components/prompt-input.js +5 -6
- package/dist/parts/components/relative-time.d.ts +1 -3
- package/dist/parts/components/relative-time.js +1 -2
- package/dist/parts/components/status.d.ts +1 -3
- package/dist/parts/components/status.js +1 -2
- package/dist/parts/components/sync-status.d.ts +1 -3
- package/dist/parts/components/sync-status.js +1 -2
- package/dist/parts/components/tool-list.d.ts +2 -4
- package/dist/parts/components/tool-list.js +2 -3
- package/dist/parts/components/trace-run.d.ts +2 -4
- package/dist/parts/components/trace-run.js +4 -5
- package/dist/parts/components/trace.d.ts +1 -3
- package/dist/parts/components/trace.js +2 -3
- package/dist/parts/composables/attachments.d.ts +1 -3
- package/dist/parts/composables/attachments.js +1 -2
- package/dist/parts/composables/highlighted-code.d.ts +1 -3
- package/dist/parts/composables/highlighted-code.js +1 -2
- package/dist/parts/headless/choices-input.d.ts +1 -1
- package/dist/parts/headless/choices-input.js +3 -4
- package/dist/parts/headless/comment-visibility.d.ts +1 -1
- package/dist/parts/headless/comment-visibility.js +1 -2
- package/dist/parts/headless/comments.d.ts +1 -1
- package/dist/parts/headless/comments.js +1 -2
- package/dist/parts/headless/message-scroller.d.ts +1 -1
- package/dist/parts/headless/message-scroller.js +2 -3
- package/dist/parts/playground/paths.d.ts +1 -3
- package/dist/parts/playground/paths.js +1 -2
- package/dist/parts/playground/share.d.ts +1 -3
- package/dist/parts/playground/share.js +1 -2
- package/dist/parts/playground/zip.d.ts +1 -3
- package/dist/parts/playground/zip.js +2 -3
- package/dist/parts/workspace/browser-support-notice.d.ts +1 -3
- package/dist/parts/workspace/browser-support-notice.js +3 -4
- package/dist/parts/workspace/codemirror.d.ts +1 -3
- package/dist/parts/workspace/codemirror.js +3 -4
- package/dist/parts/workspace/connect-panel.d.ts +1 -3
- package/dist/parts/workspace/connect-panel.js +2 -3
- package/dist/parts/workspace/connect-store.d.ts +1 -3
- package/dist/parts/workspace/connect-store.js +1 -2
- package/dist/parts/workspace/file-icons.d.ts +1 -3
- package/dist/parts/workspace/file-icons.js +1 -2
- package/dist/parts/workspace/icons.d.ts +1 -2
- package/dist/parts/workspace/icons.js +1 -2
- package/dist/parts/workspace/runners/render.d.ts +1 -3
- package/dist/parts/workspace/runners/render.js +1 -2
- package/dist/parts/workspace/runners/web-container.d.ts +1 -3
- package/dist/parts/workspace/runners/web-container.js +1 -2
- package/dist/parts/workspace/workspace-bar.d.ts +1 -3
- package/dist/parts/workspace/workspace-bar.js +2 -3
- package/dist/parts/workspace/workspace-boot-status.d.ts +1 -2
- package/dist/parts/workspace/workspace-boot-status.js +2 -3
- package/dist/parts/workspace/workspace-editor-head.d.ts +1 -3
- package/dist/parts/workspace/workspace-editor-head.js +3 -4
- package/dist/parts/workspace/workspace-editor.d.ts +1 -3
- package/dist/parts/workspace/workspace-editor.js +1 -2
- package/dist/parts/workspace/workspace-examples.d.ts +1 -3
- package/dist/parts/workspace/workspace-examples.js +2 -3
- package/dist/parts/workspace/workspace-file-link.d.ts +1 -3
- package/dist/parts/workspace/workspace-file-link.js +1 -2
- package/dist/parts/workspace/workspace-file-tree.d.ts +1 -3
- package/dist/parts/workspace/workspace-file-tree.js +2 -3
- package/dist/parts/workspace/workspace-guide.d.ts +2 -4
- package/dist/parts/workspace/workspace-guide.js +2 -3
- package/dist/parts/workspace/workspace-issues.d.ts +1 -3
- package/dist/parts/workspace/workspace-issues.js +1 -2
- package/dist/parts/workspace/workspace-preview.d.ts +1 -3
- package/dist/parts/workspace/workspace-preview.js +2 -3
- package/dist/parts/workspace/workspace-shell.d.ts +1 -1
- package/dist/parts/workspace/workspace-shell.js +2 -3
- package/dist/parts/workspace/workspace-sidebar.d.ts +2 -4
- package/dist/parts/workspace/workspace-sidebar.js +3 -4
- package/dist/parts/workspace/workspace-start.d.ts +1 -3
- package/dist/parts/workspace/workspace-start.js +2 -3
- package/dist/parts/workspace/workspace-status.d.ts +1 -3
- package/dist/parts/workspace/workspace-status.js +1 -2
- package/dist/parts/workspace/workspace-steps.d.ts +1 -1
- package/dist/parts/workspace/workspace-steps.js +2 -3
- package/dist/parts/workspace/workspace-task.d.ts +1 -3
- package/dist/parts/workspace/workspace-task.js +1 -2
- package/dist/parts/workspace/workspace-terminal.d.ts +1 -3
- package/dist/parts/workspace/workspace-terminal.js +1 -2
- package/dist/parts/workspace/workspace.d.ts +3 -5
- package/dist/parts/workspace/workspace.js +6 -7
- package/dist/{payload-text-sjkYAwvw.js → payload-text-DQNRbJY5.js} +1 -2
- package/dist/{pierre-code-view-NE35tkmR.js → pierre-code-view-C49BVDrc.js} +11333 -6718
- package/dist/pierre-dark-BtKHt2e4.js +166 -0
- package/dist/pierre-dark-CXW3KeKO.js +5 -0
- package/dist/pierre-dark-protanopia-deuteranopia-CS0Gs25Q.js +166 -0
- package/dist/pierre-dark-protanopia-deuteranopia-DajNv_A3.js +3 -0
- package/dist/pierre-dark-soft-BUFoeBEf.js +3 -0
- package/dist/pierre-dark-soft-D__0FtYP.js +166 -0
- package/dist/pierre-dark-tritanopia-C6fHROmA.js +166 -0
- package/dist/pierre-dark-tritanopia-oa3gpgIR.js +3 -0
- package/dist/pierre-dark-vibrant-COXpyAHb.js +166 -0
- package/dist/pierre-dark-vibrant-CYRHyDoW.js +3 -0
- package/dist/pierre-light-BD28C_vh.js +166 -0
- package/dist/pierre-light-BN0rL1e5.js +5 -0
- package/dist/pierre-light-protanopia-deuteranopia-CYsDHJt0.js +3 -0
- package/dist/pierre-light-protanopia-deuteranopia-CwWH1xGL.js +166 -0
- package/dist/pierre-light-soft-BkKY4pMj.js +166 -0
- package/dist/pierre-light-soft-F2QIpNbb.js +3 -0
- package/dist/pierre-light-tritanopia-BbKKIkua.js +3 -0
- package/dist/pierre-light-tritanopia-Mpubahl7.js +166 -0
- package/dist/pierre-light-vibrant-CdV9Besm.js +3 -0
- package/dist/pierre-light-vibrant-x11J3_aO.js +166 -0
- package/dist/plastic-BQnXkmvK.js +137 -0
- package/dist/playground.d.ts +1 -1
- package/dist/poimandres-DEfG-8RI.js +124 -0
- package/dist/{progress-C7afI5vq.js → progress-DL9k-ERG.js} +3 -4
- package/dist/red-BfKrAjYG.js +169 -0
- package/dist/{registry-D3-ysX7l.js → registry-DAIjCjWd.js} +2 -3
- package/dist/{relative-time-DgSS3zKN.js → relative-time-DJnw45tr.js} +5 -8
- package/dist/{ring-B7Qxu7zd.js → ring-BN4d8vtw.js} +4 -6
- package/dist/{rolldown-runtime-C9mWXvCC.js → rolldown-runtime-CahUhzF3.js} +2 -3
- package/dist/rose-pine-D0rhGGFg.js +136 -0
- package/dist/rose-pine-dawn-7jVaYUiD.js +136 -0
- package/dist/rose-pine-moon-CFyS0Mvu.js +136 -0
- package/dist/runtime/nuxt-plugin.d.ts +0 -2
- package/dist/runtime/nuxt-plugin.js +3 -4
- package/dist/{sankey-CAYwt82B-D4uDQoMR.js → sankey-CAYwt82B-BAAk7WkJ.js} +147 -151
- package/dist/shiki-CbfEu_Az.js +607 -0
- package/dist/slack-dark-Bv-KFSBD.js +87 -0
- package/dist/slack-ochin-Dg2BAv1D.js +107 -0
- package/dist/{slot-part-Doic71uh.js → slot-part-BWHvQ3mK.js} +1 -2
- package/dist/snazzy-light-sYDdR9rx.js +93 -0
- package/dist/solarized-dark-COt2tTmN.js +160 -0
- package/dist/solarized-light-BJrwFarZ.js +160 -0
- package/dist/stream-tokenizer-ByC3l0HQ.js +263 -0
- package/dist/styles.css +4 -0
- package/dist/synthwave-84-NUDBykTM.js +410 -0
- package/dist/{temml-BilSAAws.js → temml-m3ad3bfq.js} +2 -3
- package/dist/{text-BCJflBJf.js → text-BWzZFnGY.js} +8 -12
- package/dist/theme.d.ts +1 -3
- package/dist/theme.js +1 -2
- package/dist/themes-DKugPHlg.js +323 -0
- package/dist/tokyo-night-DD3B2QcO.js +153 -0
- package/dist/{travel-C87xd5Wh.js → travel-CwVhU_GS.js} +6 -8
- package/dist/{tween-CO24nMpf.js → tween-Dv3IIIQG.js} +2 -3
- package/dist/{types-BX64qHlV.d.ts → types-Ceh7h7NT.d.ts} +1 -3
- package/dist/vesper-oVQYrv8Y.js +99 -0
- package/dist/{visual-copy-CrVc3z4n.js → visual-copy-CHHBfJ6O.js} +1 -2
- package/dist/vite.d.ts +1 -3
- package/dist/vite.js +13 -3
- package/dist/vitesse-black-D84DQZAP.js +196 -0
- package/dist/vitesse-dark-CMZ6olk_.js +196 -0
- package/dist/vitesse-light-D9d8hLOY.js +196 -0
- package/dist/{vue-DGstVdGn.js → vue-BlknIGIm.js} +43 -34
- package/dist/{vue-BDmSCtay.js → vue-kCdzBu0N.js} +4 -7
- package/dist/{workspace-shell-BJGnoF3p.d.ts → workspace-shell-ChCwWPyv.d.ts} +0 -2
- package/dist/{workspace-steps-Bgph2rpr.d.ts → workspace-steps-BKByX9DW.d.ts} +0 -2
- package/dist/workspace.d.ts +6 -8
- package/dist/workspace.js +6 -6
- package/package.json +52 -52
- package/dist/pierre-dark-CzUmjETS.js +0 -6
- package/dist/pierre-dark-protanopia-deuteranopia-C35UMuvO.js +0 -4
- package/dist/pierre-dark-soft-Bb-4-biO.js +0 -4
- package/dist/pierre-dark-tritanopia-CIJISGWF.js +0 -4
- package/dist/pierre-dark-vibrant-8oZzB3gw.js +0 -4
- package/dist/pierre-light-Dn6E0sWv.js +0 -6
- package/dist/pierre-light-protanopia-deuteranopia-u0U7N4Hn.js +0 -4
- package/dist/pierre-light-soft-BCU6fuhO.js +0 -4
- package/dist/pierre-light-tritanopia-3c8Yx3co.js +0 -4
- package/dist/pierre-light-vibrant-Cwh332o_.js +0 -4
|
@@ -0,0 +1,607 @@
|
|
|
1
|
+
import { a as moveLineEntries, c as createDiffsThemeResolver, d as AttachedLanguages, f as RegisteredCustomLanguages, i as lineChangesOf, m as ResolvingLanguages, n as appendItems, p as ResolvedLanguages, t as debounce, u as isWorkerContext } from "./pierre-code-view-C49BVDrc.js";
|
|
2
|
+
import { n as DiffsHighlighter, r as DiffsEditorTokenizer, t as BaseStreamTokenizer } from "./stream-tokenizer-ByC3l0HQ.js";
|
|
3
|
+
import { EncodedTokenMetadata, INITIAL } from "shiki/textmate";
|
|
4
|
+
import { createCssVariablesTheme, createHighlighterCore } from "shiki/core";
|
|
5
|
+
// ../../node_modules/.pnpm/@pierre+diffs@1.7.1_@shikijs+themes@4.6.0_react-dom@19.2.8_react@19.2.6__react@19.2.6/node_modules/@pierre/diffs/dist/highlighter/languages/attachResolvedLanguages.js
|
|
6
|
+
/**
|
|
7
|
+
* Record resolved grammars in the shared language cache and attach them to a
|
|
8
|
+
* highlighter. Highlights bundles its lexers and ignores the grammars.
|
|
9
|
+
*/
|
|
10
|
+
function attachResolvedLanguages(resolvedLanguages, highlighter) {
|
|
11
|
+
for (const resolvedLang of Array.isArray(resolvedLanguages) ? resolvedLanguages : [resolvedLanguages]) {
|
|
12
|
+
let lang = ResolvedLanguages.get(resolvedLang.name);
|
|
13
|
+
if (lang == null) {
|
|
14
|
+
lang = resolvedLang;
|
|
15
|
+
ResolvedLanguages.set(resolvedLang.name, lang);
|
|
16
|
+
}
|
|
17
|
+
highlighter.attachLanguages([lang]);
|
|
18
|
+
AttachedLanguages.add(lang.name);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
// ../../node_modules/.pnpm/@pierre+diffs@1.7.1_@shikijs+themes@4.6.0_react-dom@19.2.8_react@19.2.6__react@19.2.6/node_modules/@pierre/diffs/dist/highlighter/languages/resolveLanguage.js
|
|
22
|
+
async function resolveLanguage(lang) {
|
|
23
|
+
if (typeof __DIFFS_WORKER__ !== "undefined" ? __DIFFS_WORKER__ : isWorkerContext()) throw new Error(`resolveLanguage("${lang}") cannot be called from a worker context. Languages must be pre-resolved on the main thread and passed to the worker via the resolvedLanguages parameter.`);
|
|
24
|
+
const pending = ResolvingLanguages.get(lang);
|
|
25
|
+
if (pending != null) return pending;
|
|
26
|
+
const resolver = (async () => {
|
|
27
|
+
let loader = RegisteredCustomLanguages.get(lang);
|
|
28
|
+
if (loader == null) {
|
|
29
|
+
const { bundledLanguages } = await import("shiki/langs");
|
|
30
|
+
if (Object.prototype.hasOwnProperty.call(bundledLanguages, lang)) loader = bundledLanguages[lang];
|
|
31
|
+
}
|
|
32
|
+
if (loader == null) throw new Error(`resolveLanguage: "${lang}" not found in bundled or custom languages`);
|
|
33
|
+
const { default: data } = await loader();
|
|
34
|
+
const resolvedLang = {
|
|
35
|
+
name: lang,
|
|
36
|
+
data
|
|
37
|
+
};
|
|
38
|
+
if (!ResolvedLanguages.has(lang)) ResolvedLanguages.set(lang, resolvedLang);
|
|
39
|
+
return resolvedLang;
|
|
40
|
+
})();
|
|
41
|
+
ResolvingLanguages.set(lang, resolver);
|
|
42
|
+
try {
|
|
43
|
+
return await resolver;
|
|
44
|
+
} finally {
|
|
45
|
+
if (ResolvingLanguages.get(lang) === resolver) ResolvingLanguages.delete(lang);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
// ../../node_modules/.pnpm/@pierre+diffs@1.7.1_@shikijs+themes@4.6.0_react-dom@19.2.8_react@19.2.6__react@19.2.6/node_modules/@pierre/diffs/dist/highlighter/languages/getResolvedOrResolveLanguage.js
|
|
49
|
+
function getResolvedOrResolveLanguage(language) {
|
|
50
|
+
return ResolvedLanguages.get(language) ?? resolveLanguage(language);
|
|
51
|
+
}
|
|
52
|
+
// ../../node_modules/.pnpm/@pierre+diffs@1.7.1_@shikijs+themes@4.6.0_react-dom@19.2.8_react@19.2.6__react@19.2.6/node_modules/@pierre/diffs/dist/highlighter/languages/resolveLanguages.js
|
|
53
|
+
async function resolveLanguages(languages) {
|
|
54
|
+
const resolvedLanguages = [];
|
|
55
|
+
const languagesToResolve = [];
|
|
56
|
+
for (const language of languages) {
|
|
57
|
+
if (language === "text" || language === "ansi") continue;
|
|
58
|
+
const maybeResolvedLanguage = getResolvedOrResolveLanguage(language) ?? resolveLanguage(language);
|
|
59
|
+
if ("then" in maybeResolvedLanguage) languagesToResolve.push(maybeResolvedLanguage);
|
|
60
|
+
else resolvedLanguages.push(maybeResolvedLanguage);
|
|
61
|
+
}
|
|
62
|
+
if (languagesToResolve.length > 0) await Promise.all(languagesToResolve).then((_resolvedLanguages) => {
|
|
63
|
+
for (const resolvedLanguage of _resolvedLanguages) {
|
|
64
|
+
if (resolvedLanguage == null) throw new Error("resolvedLanguages: unable to resolve language");
|
|
65
|
+
resolvedLanguages.push(resolvedLanguage);
|
|
66
|
+
}
|
|
67
|
+
});
|
|
68
|
+
return resolvedLanguages;
|
|
69
|
+
}
|
|
70
|
+
// ../../node_modules/.pnpm/@pierre+diffs@1.7.1_@shikijs+themes@4.6.0_react-dom@19.2.8_react@19.2.6__react@19.2.6/node_modules/@pierre/diffs/dist/highlighter/shiki-editor.js
|
|
71
|
+
const TOKENIZE_TIME_LIMIT = 0;
|
|
72
|
+
const SLICE_BUDGET_MS = 1;
|
|
73
|
+
let nextTokenizerId = 0;
|
|
74
|
+
/**
|
|
75
|
+
* Colors an editable document with a TextMate grammar, a line at a time.
|
|
76
|
+
*
|
|
77
|
+
* Every line has a record with the grammar state at its start, moved with
|
|
78
|
+
* the line when lines are added or removed above it. The state in a record
|
|
79
|
+
* is the state the line was last colored from. Edits mark lines dirty;
|
|
80
|
+
* `advance` colors dirty lines in order, delivers them, and stops once a
|
|
81
|
+
* line's end state matches the state the next line was colored from, since
|
|
82
|
+
* everything below is then unaffected. Lines that have never been colored
|
|
83
|
+
* show the highlight result, which is right for their text, so reaching one
|
|
84
|
+
* of them only needs its state.
|
|
85
|
+
*/
|
|
86
|
+
var ShikiEditorTokenizer = class {
|
|
87
|
+
backend;
|
|
88
|
+
#highlighter;
|
|
89
|
+
#grammar;
|
|
90
|
+
#themeName;
|
|
91
|
+
#colorMap;
|
|
92
|
+
#textDocument;
|
|
93
|
+
#tokenizeMaxLineLength;
|
|
94
|
+
#onDeferTokenize;
|
|
95
|
+
#matchBrackets;
|
|
96
|
+
#debug;
|
|
97
|
+
#disposed = false;
|
|
98
|
+
#lines = [{
|
|
99
|
+
state: INITIAL,
|
|
100
|
+
brackets: void 0
|
|
101
|
+
}];
|
|
102
|
+
#dirty = [];
|
|
103
|
+
#coldTarget = -1;
|
|
104
|
+
#paused = false;
|
|
105
|
+
#generation = 0;
|
|
106
|
+
#tokenizerId = ++nextTokenizerId;
|
|
107
|
+
#listening = false;
|
|
108
|
+
#primeLater = debounce(async (end) => {
|
|
109
|
+
if (this.#disposed) return;
|
|
110
|
+
if (this.#grammar == null && !isGrammarlessLanguage(this.#textDocument.languageId)) {
|
|
111
|
+
await this.backend?.loadLanguages([this.#textDocument.languageId]);
|
|
112
|
+
if (this.#disposed) return;
|
|
113
|
+
this.#grammar = this.#highlighter.getLanguage(this.#textDocument.languageId);
|
|
114
|
+
}
|
|
115
|
+
this.#ensureActiveTheme();
|
|
116
|
+
this.#coldTarget = Math.max(this.#coldTarget, end);
|
|
117
|
+
this.#schedule();
|
|
118
|
+
}, 500);
|
|
119
|
+
#onMessage = ({ data }) => {
|
|
120
|
+
if (typeof data !== "object" || data === null) return;
|
|
121
|
+
const { type, tokenizerId, jobId } = data;
|
|
122
|
+
if (type === "tokenize" && tokenizerId === this.#tokenizerId && jobId === this.#generation) this.#slice();
|
|
123
|
+
};
|
|
124
|
+
constructor(highlighter, options, backend) {
|
|
125
|
+
this.backend = backend;
|
|
126
|
+
this.#highlighter = highlighter;
|
|
127
|
+
this.#textDocument = options.textDocument;
|
|
128
|
+
this.#themeName = options.theme;
|
|
129
|
+
this.#colorMap = [];
|
|
130
|
+
this.#tokenizeMaxLineLength = options.tokenizeMaxLineLength ?? 1e3;
|
|
131
|
+
this.#onDeferTokenize = options.onDeferTokenize;
|
|
132
|
+
this.#matchBrackets = options.matchBrackets !== false;
|
|
133
|
+
this.#debug = options.__debug ?? false;
|
|
134
|
+
this.#ensureGrammar();
|
|
135
|
+
this.#ensureActiveTheme();
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Takes an edit: marks its lines dirty, moves the states and dirty lines
|
|
139
|
+
* below it, and colors from the first dirty line for up to a millisecond.
|
|
140
|
+
* Returns every line colored, in and above `window`. The rest continues
|
|
141
|
+
* in the background.
|
|
142
|
+
*/
|
|
143
|
+
applyChange(change, window) {
|
|
144
|
+
this.#ensureGrammar();
|
|
145
|
+
this.#ensureActiveTheme();
|
|
146
|
+
if (this.#grammar == null && !isGrammarlessLanguage(this.#textDocument.languageId)) throw new Error(`Grammar for language "${this.#textDocument.languageId}" not loaded`);
|
|
147
|
+
const lineChanges = lineChangesOf(change);
|
|
148
|
+
this.#lines = moveLineEntries(this.#lines, lineChanges, () => void 0).entries;
|
|
149
|
+
this.#moveDirtyLines(lineChanges);
|
|
150
|
+
this.#addDirty(change.changedLineRanges ?? [[change.startLine, change.endLine]]);
|
|
151
|
+
this.#paused = false;
|
|
152
|
+
const until = window == null ? this.#textDocument.lineCount : window[1];
|
|
153
|
+
const lines = this.advance(until, window == null ? void 0 : SLICE_BUDGET_MS);
|
|
154
|
+
this.#schedule();
|
|
155
|
+
return lines;
|
|
156
|
+
}
|
|
157
|
+
/**
|
|
158
|
+
* Colors every dirty line before `end` now and returns them. A pause stays
|
|
159
|
+
* in force: the rest waits for `resume`.
|
|
160
|
+
*/
|
|
161
|
+
flush(end) {
|
|
162
|
+
this.#ensureGrammar();
|
|
163
|
+
this.#ensureActiveTheme();
|
|
164
|
+
const lines = this.advance(end);
|
|
165
|
+
this.#schedule();
|
|
166
|
+
return lines;
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Builds the states of the lines up to the attach window's end in the
|
|
170
|
+
* background, so the first edit there starts from a known state. The rows
|
|
171
|
+
* keep what they show until an edit colors them.
|
|
172
|
+
*/
|
|
173
|
+
prime(window) {
|
|
174
|
+
this.#ensureGrammar();
|
|
175
|
+
this.#primeLater(window[1]);
|
|
176
|
+
}
|
|
177
|
+
/**
|
|
178
|
+
* The string, comment and regexp ranges of a line, from its last coloring,
|
|
179
|
+
* or lexed now for a line never colored. Null without a grammar.
|
|
180
|
+
*/
|
|
181
|
+
bracketIgnoredRanges(line) {
|
|
182
|
+
this.#ensureGrammar();
|
|
183
|
+
if (this.#grammar == null) return null;
|
|
184
|
+
if (this.#lines[line]?.brackets === void 0) {
|
|
185
|
+
const state = this.#lexState(line, this.#stateAt(line));
|
|
186
|
+
if (this.#lines[line + 1] == null) this.#setState(line + 1, state);
|
|
187
|
+
}
|
|
188
|
+
return this.#lines[line]?.brackets ?? null;
|
|
189
|
+
}
|
|
190
|
+
setTheme(themeName) {
|
|
191
|
+
if (this.#themeName === themeName) return;
|
|
192
|
+
this.#themeName = themeName;
|
|
193
|
+
this.#ensureActiveTheme();
|
|
194
|
+
this.#addDirty([[0, this.#textDocument.lineCount - 1]]);
|
|
195
|
+
this.#schedule();
|
|
196
|
+
}
|
|
197
|
+
pause() {
|
|
198
|
+
if (this.#paused) return;
|
|
199
|
+
if (typeof process !== "undefined" && process.env.NODE_ENV === "development" && this.#debug) console.log("[diffs/editor] background tokenization paused");
|
|
200
|
+
this.#paused = true;
|
|
201
|
+
this.#generation++;
|
|
202
|
+
}
|
|
203
|
+
resume() {
|
|
204
|
+
if (!this.#paused) return;
|
|
205
|
+
if (typeof process !== "undefined" && process.env.NODE_ENV === "development" && this.#debug) console.log("[diffs/editor] background tokenization resumed");
|
|
206
|
+
this.#paused = false;
|
|
207
|
+
this.#schedule();
|
|
208
|
+
}
|
|
209
|
+
dispose() {
|
|
210
|
+
this.#disposed = true;
|
|
211
|
+
this.#generation++;
|
|
212
|
+
this.#dirty = [];
|
|
213
|
+
this.#coldTarget = -1;
|
|
214
|
+
this.#stopListening();
|
|
215
|
+
}
|
|
216
|
+
/**
|
|
217
|
+
* Colors dirty lines in order until they settle, `until` is reached, or
|
|
218
|
+
* the budget runs out, and returns what it colored. A dirty range settles
|
|
219
|
+
* once a line past its end ends in the state the next line was colored
|
|
220
|
+
* from; a range whose start state is unknown first builds the states of
|
|
221
|
+
* the lines leading to it.
|
|
222
|
+
*/
|
|
223
|
+
advance(until, budgetMs) {
|
|
224
|
+
const lines = /* @__PURE__ */ new Map();
|
|
225
|
+
if (this.#grammar == null && !isGrammarlessLanguage(this.#textDocument.languageId)) return lines;
|
|
226
|
+
const startedAt = budgetMs == null ? 0 : performance.now();
|
|
227
|
+
const end = Math.min(until, this.#textDocument.lineCount);
|
|
228
|
+
while (this.#dirty.length > 0) {
|
|
229
|
+
const range = this.#dirty[0];
|
|
230
|
+
let line = range[0];
|
|
231
|
+
if (line >= end) break;
|
|
232
|
+
let state = this.#stateAt(line);
|
|
233
|
+
let settled = false;
|
|
234
|
+
while (line < end) {
|
|
235
|
+
const previous = this.#lines[line + 1]?.state;
|
|
236
|
+
const result = this.#tokenizeLineAt(line, state);
|
|
237
|
+
lines.set(line, result.resolvedTokens);
|
|
238
|
+
state = result.state;
|
|
239
|
+
this.#setState(line + 1, state);
|
|
240
|
+
line++;
|
|
241
|
+
if (line > range[1] && previous != null && state.equals(previous)) {
|
|
242
|
+
settled = true;
|
|
243
|
+
break;
|
|
244
|
+
}
|
|
245
|
+
if (budgetMs != null && performance.now() - startedAt > budgetMs) break;
|
|
246
|
+
}
|
|
247
|
+
if (settled || line >= this.#textDocument.lineCount) {
|
|
248
|
+
this.#dirty.shift();
|
|
249
|
+
while (this.#dirty.length > 0 && this.#dirty[0][1] < line) this.#dirty.shift();
|
|
250
|
+
if (this.#dirty.length > 0 && this.#dirty[0][0] < line) this.#dirty[0][0] = line;
|
|
251
|
+
continue;
|
|
252
|
+
}
|
|
253
|
+
range[0] = line;
|
|
254
|
+
if (range[1] < line) range[1] = line;
|
|
255
|
+
break;
|
|
256
|
+
}
|
|
257
|
+
return lines;
|
|
258
|
+
}
|
|
259
|
+
#slice() {
|
|
260
|
+
if (this.#paused || this.#disposed) return;
|
|
261
|
+
this.#ensureActiveTheme();
|
|
262
|
+
const startedAt = performance.now();
|
|
263
|
+
const lines = this.advance(this.#textDocument.lineCount, SLICE_BUDGET_MS);
|
|
264
|
+
if (lines.size > 0) this.#onDeferTokenize(lines);
|
|
265
|
+
if (this.#dirty.length === 0 && this.#coldTarget >= 0) {
|
|
266
|
+
const target = Math.min(this.#coldTarget, this.#textDocument.lineCount);
|
|
267
|
+
let line = this.#knownThrough();
|
|
268
|
+
let state = this.#lines[line]?.state ?? INITIAL;
|
|
269
|
+
while (line < target) {
|
|
270
|
+
state = this.#lexState(line, state);
|
|
271
|
+
line++;
|
|
272
|
+
this.#setState(line, state);
|
|
273
|
+
if (performance.now() - startedAt > SLICE_BUDGET_MS) break;
|
|
274
|
+
}
|
|
275
|
+
if (line >= target) this.#coldTarget = -1;
|
|
276
|
+
}
|
|
277
|
+
this.#schedule();
|
|
278
|
+
}
|
|
279
|
+
#schedule() {
|
|
280
|
+
if (this.#paused || this.#disposed || this.#dirty.length === 0 && this.#coldTarget < 0 || isGrammarlessLanguage(this.#textDocument.languageId)) {
|
|
281
|
+
this.#stopListening();
|
|
282
|
+
return;
|
|
283
|
+
}
|
|
284
|
+
const jobId = ++this.#generation;
|
|
285
|
+
if (!this.#listening) {
|
|
286
|
+
globalThis.addEventListener("message", this.#onMessage);
|
|
287
|
+
this.#listening = true;
|
|
288
|
+
}
|
|
289
|
+
globalThis.postMessage({
|
|
290
|
+
type: "tokenize",
|
|
291
|
+
tokenizerId: this.#tokenizerId,
|
|
292
|
+
jobId
|
|
293
|
+
});
|
|
294
|
+
}
|
|
295
|
+
#stopListening() {
|
|
296
|
+
if (!this.#listening) return;
|
|
297
|
+
globalThis.removeEventListener("message", this.#onMessage);
|
|
298
|
+
this.#listening = false;
|
|
299
|
+
}
|
|
300
|
+
#addDirty(ranges) {
|
|
301
|
+
const merged = [];
|
|
302
|
+
let mine = 0;
|
|
303
|
+
let theirs = 0;
|
|
304
|
+
while (mine < this.#dirty.length || theirs < ranges.length) {
|
|
305
|
+
const own = this.#dirty[mine];
|
|
306
|
+
const added = ranges[theirs];
|
|
307
|
+
let next;
|
|
308
|
+
if (added == null || own != null && own[0] <= added[0]) {
|
|
309
|
+
next = own;
|
|
310
|
+
mine++;
|
|
311
|
+
} else {
|
|
312
|
+
next = added;
|
|
313
|
+
theirs++;
|
|
314
|
+
}
|
|
315
|
+
if (next[1] < next[0]) continue;
|
|
316
|
+
const last = merged[merged.length - 1];
|
|
317
|
+
if (last != null && next[0] <= last[1] + 1) last[1] = Math.max(last[1], next[1]);
|
|
318
|
+
else merged.push([next[0], next[1]]);
|
|
319
|
+
}
|
|
320
|
+
this.#dirty = merged;
|
|
321
|
+
}
|
|
322
|
+
#moveDirtyLines(lineChanges) {
|
|
323
|
+
for (const [start, end, lineDelta] of lineChanges) {
|
|
324
|
+
const oldEnd = end - lineDelta;
|
|
325
|
+
for (const range of this.#dirty) {
|
|
326
|
+
if (range[1] < start) continue;
|
|
327
|
+
if (range[0] > oldEnd) {
|
|
328
|
+
range[0] += lineDelta;
|
|
329
|
+
range[1] += lineDelta;
|
|
330
|
+
} else {
|
|
331
|
+
range[0] = Math.min(range[0], start);
|
|
332
|
+
range[1] = Math.max(range[1] + lineDelta, end);
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
#knownThrough() {
|
|
338
|
+
let line = Math.min(this.#lines.length - 1, this.#textDocument.lineCount);
|
|
339
|
+
while (line > 0 && this.#lines[line] == null) line--;
|
|
340
|
+
return line;
|
|
341
|
+
}
|
|
342
|
+
#stateAt(line) {
|
|
343
|
+
const known = this.#lines[line]?.state;
|
|
344
|
+
if (known != null) return known;
|
|
345
|
+
let at = this.#knownThrough();
|
|
346
|
+
if (at > line) {
|
|
347
|
+
at = line;
|
|
348
|
+
while (at > 0 && this.#lines[at] == null) at--;
|
|
349
|
+
}
|
|
350
|
+
let state = this.#lines[at]?.state ?? INITIAL;
|
|
351
|
+
for (; at < line; at++) {
|
|
352
|
+
state = this.#lexState(at, state);
|
|
353
|
+
this.#setState(at + 1, state);
|
|
354
|
+
}
|
|
355
|
+
return state;
|
|
356
|
+
}
|
|
357
|
+
#setState(line, state) {
|
|
358
|
+
const record = this.#lines[line];
|
|
359
|
+
if (record == null) this.#lines[line] = {
|
|
360
|
+
state,
|
|
361
|
+
brackets: void 0
|
|
362
|
+
};
|
|
363
|
+
else record.state = state;
|
|
364
|
+
}
|
|
365
|
+
#ensureActiveTheme() {
|
|
366
|
+
if (this.#themeName === "") return;
|
|
367
|
+
this.backend?.getTheme(this.#themeName);
|
|
368
|
+
const { colorMap } = this.#highlighter.setTheme(this.#themeName);
|
|
369
|
+
this.#colorMap = colorMap;
|
|
370
|
+
}
|
|
371
|
+
#ensureGrammar() {
|
|
372
|
+
if (this.#grammar == null && !isGrammarlessLanguage(this.#textDocument.languageId) && this.#highlighter.getLoadedLanguages().includes(this.#textDocument.languageId)) this.#grammar = this.#highlighter.getLanguage(this.#textDocument.languageId);
|
|
373
|
+
}
|
|
374
|
+
#tokenizeLineAt(line, state) {
|
|
375
|
+
const lineText = this.#textDocument.getLineText(line);
|
|
376
|
+
if (lineText.length >= this.#tokenizeMaxLineLength) {
|
|
377
|
+
console.warn(`[diffs] Line(${line}) too long to tokenize: ${lineText.length}`);
|
|
378
|
+
this.#cacheBracketRanges(line, null);
|
|
379
|
+
return {
|
|
380
|
+
resolvedTokens: [[
|
|
381
|
+
0,
|
|
382
|
+
"",
|
|
383
|
+
lineText
|
|
384
|
+
]],
|
|
385
|
+
state
|
|
386
|
+
};
|
|
387
|
+
}
|
|
388
|
+
if (this.#grammar == null || lineText === "" || lineText.trim() === "") {
|
|
389
|
+
this.#cacheBracketRanges(line, null);
|
|
390
|
+
return {
|
|
391
|
+
resolvedTokens: [[
|
|
392
|
+
0,
|
|
393
|
+
"",
|
|
394
|
+
lineText
|
|
395
|
+
]],
|
|
396
|
+
state
|
|
397
|
+
};
|
|
398
|
+
}
|
|
399
|
+
const result = tokenizeLine(this.#grammar, this.#colorMap, lineText, state, TOKENIZE_TIME_LIMIT, this.#matchBrackets);
|
|
400
|
+
this.#cacheBracketRanges(line, result.bracketIgnoredRanges);
|
|
401
|
+
return {
|
|
402
|
+
resolvedTokens: result.resolvedTokens,
|
|
403
|
+
state: result.ruleStack
|
|
404
|
+
};
|
|
405
|
+
}
|
|
406
|
+
#lexState(line, state) {
|
|
407
|
+
const lineText = this.#textDocument.getLineText(line);
|
|
408
|
+
if (this.#grammar == null || lineText.length >= this.#tokenizeMaxLineLength || lineText === "" || lineText.trim() === "") {
|
|
409
|
+
this.#cacheBracketRanges(line, null);
|
|
410
|
+
return state;
|
|
411
|
+
}
|
|
412
|
+
const result = tokenizeLine(this.#grammar, this.#colorMap, lineText, state, TOKENIZE_TIME_LIMIT, this.#matchBrackets, false);
|
|
413
|
+
this.#cacheBracketRanges(line, result.bracketIgnoredRanges);
|
|
414
|
+
return result.ruleStack;
|
|
415
|
+
}
|
|
416
|
+
#cacheBracketRanges(line, ranges) {
|
|
417
|
+
if (!this.#matchBrackets) return;
|
|
418
|
+
const record = this.#lines[line];
|
|
419
|
+
if (record == null) throw new Error(`ShikiEditorTokenizer: line ${line} has no record`);
|
|
420
|
+
record.brackets = ranges;
|
|
421
|
+
}
|
|
422
|
+
};
|
|
423
|
+
function tokenizeLine(grammar, colorMap, lineText, stateStack, timeLimit, collectBracketIgnoredRanges = true, resolveTokens = true) {
|
|
424
|
+
const result = grammar.tokenizeLine2(lineText, stateStack, timeLimit);
|
|
425
|
+
if (result.stoppedEarly) console.warn(`[diffs] Time limit reached when tokenizing line: ${lineText.substring(0, 100)}`);
|
|
426
|
+
const rawTokens = result.tokens;
|
|
427
|
+
const tokensLength = rawTokens.length / 2;
|
|
428
|
+
const resolvedTokens = [];
|
|
429
|
+
const bracketIgnoredRanges = [];
|
|
430
|
+
if (!resolveTokens && !collectBracketIgnoredRanges) return {
|
|
431
|
+
ruleStack: result.ruleStack,
|
|
432
|
+
resolvedTokens,
|
|
433
|
+
bracketIgnoredRanges
|
|
434
|
+
};
|
|
435
|
+
for (let j = 0; j < tokensLength; j++) {
|
|
436
|
+
const offset = rawTokens[2 * j];
|
|
437
|
+
const nextOffset = j + 1 < tokensLength ? rawTokens[2 * j + 2] : lineText.length;
|
|
438
|
+
if (offset === nextOffset) continue;
|
|
439
|
+
const metadata = rawTokens[2 * j + 1];
|
|
440
|
+
if (resolveTokens) {
|
|
441
|
+
const fg = EncodedTokenMetadata.getForeground(metadata);
|
|
442
|
+
resolvedTokens.push([
|
|
443
|
+
offset,
|
|
444
|
+
colorMap[fg],
|
|
445
|
+
lineText.slice(offset, nextOffset)
|
|
446
|
+
]);
|
|
447
|
+
}
|
|
448
|
+
if (collectBracketIgnoredRanges && EncodedTokenMetadata.getTokenType(metadata) > 0) bracketIgnoredRanges.push([offset, nextOffset]);
|
|
449
|
+
}
|
|
450
|
+
return {
|
|
451
|
+
ruleStack: result.ruleStack,
|
|
452
|
+
resolvedTokens,
|
|
453
|
+
bracketIgnoredRanges
|
|
454
|
+
};
|
|
455
|
+
}
|
|
456
|
+
function isGrammarlessLanguage(languageId) {
|
|
457
|
+
return languageId === "text" || languageId === "ansi";
|
|
458
|
+
}
|
|
459
|
+
// ../../node_modules/.pnpm/@pierre+diffs@1.7.1_@shikijs+themes@4.6.0_react-dom@19.2.8_react@19.2.6__react@19.2.6/node_modules/@pierre/diffs/dist/highlighter/shiki-stream.js
|
|
460
|
+
var ShikiStreamTokenizer = class ShikiStreamTokenizer extends BaseStreamTokenizer {
|
|
461
|
+
highlighter;
|
|
462
|
+
options;
|
|
463
|
+
#tail = "";
|
|
464
|
+
#grammarState;
|
|
465
|
+
constructor(highlighter, options) {
|
|
466
|
+
super();
|
|
467
|
+
this.highlighter = highlighter;
|
|
468
|
+
this.options = options;
|
|
469
|
+
}
|
|
470
|
+
tokenizeChunk(chunk, stable) {
|
|
471
|
+
const chunkLines = (this.#tail + chunk).split(/(\r\n|\r|\n)/);
|
|
472
|
+
let unstable = [];
|
|
473
|
+
for (let i = 0; i < chunkLines.length; i += 2) {
|
|
474
|
+
const line = chunkLines[i];
|
|
475
|
+
const result = this.highlighter.codeToTokens(line, {
|
|
476
|
+
...this.options,
|
|
477
|
+
grammarState: this.#grammarState
|
|
478
|
+
});
|
|
479
|
+
const tokens = result.tokens[0].map((token) => ({
|
|
480
|
+
...token,
|
|
481
|
+
offset: token.offset + this.stableOffset
|
|
482
|
+
}));
|
|
483
|
+
if (i + 1 < chunkLines.length) {
|
|
484
|
+
appendItems(stable, tokens);
|
|
485
|
+
this.pushLineBreak(stable, line.length, chunkLines[i + 1]);
|
|
486
|
+
this.#grammarState = result.grammarState;
|
|
487
|
+
} else {
|
|
488
|
+
unstable = tokens;
|
|
489
|
+
this.#tail = line;
|
|
490
|
+
}
|
|
491
|
+
}
|
|
492
|
+
return {
|
|
493
|
+
unstable,
|
|
494
|
+
tailLength: this.#tail.length
|
|
495
|
+
};
|
|
496
|
+
}
|
|
497
|
+
clone() {
|
|
498
|
+
this.assertActive();
|
|
499
|
+
const clone = new ShikiStreamTokenizer(this.highlighter, this.options);
|
|
500
|
+
this.copyStateTo(clone);
|
|
501
|
+
clone.#tail = this.#tail;
|
|
502
|
+
clone.#grammarState = this.#grammarState;
|
|
503
|
+
return clone;
|
|
504
|
+
}
|
|
505
|
+
resetSource() {
|
|
506
|
+
this.#tail = "";
|
|
507
|
+
this.#grammarState = void 0;
|
|
508
|
+
}
|
|
509
|
+
releaseSource() {
|
|
510
|
+
this.resetSource();
|
|
511
|
+
}
|
|
512
|
+
};
|
|
513
|
+
// ../../node_modules/.pnpm/@pierre+diffs@1.7.1_@shikijs+themes@4.6.0_react-dom@19.2.8_react@19.2.6__react@19.2.6/node_modules/@pierre/diffs/dist/highlighter/backends/shiki.js
|
|
514
|
+
var ShikiHighlighter = class ShikiHighlighter extends DiffsHighlighter {
|
|
515
|
+
raw;
|
|
516
|
+
loadedThemes = /* @__PURE__ */ new Map();
|
|
517
|
+
attachedLanguages = /* @__PURE__ */ new Set(["text", "ansi"]);
|
|
518
|
+
static async create(name) {
|
|
519
|
+
const engine = name === "shiki-wasm" ? (await import("shiki/engine/oniguruma")).createOnigurumaEngine(import("shiki/wasm")) : (await import("shiki/engine/javascript")).createJavaScriptRegexEngine();
|
|
520
|
+
const raw = await createHighlighterCore({
|
|
521
|
+
themes: [],
|
|
522
|
+
langs: [],
|
|
523
|
+
engine
|
|
524
|
+
});
|
|
525
|
+
return new ShikiHighlighter(name, raw);
|
|
526
|
+
}
|
|
527
|
+
constructor(name, raw) {
|
|
528
|
+
super(name, createDiffsThemeResolver(name));
|
|
529
|
+
this.raw = raw;
|
|
530
|
+
}
|
|
531
|
+
getTheme(themeName) {
|
|
532
|
+
this.assertNotDisposed();
|
|
533
|
+
const loaded = this.loadedThemes.get(themeName);
|
|
534
|
+
const theme = this.themeResolver.getResolvedTheme(themeName) ?? loaded;
|
|
535
|
+
if (theme == null) throw new Error(`Theme "${themeName}" has not been resolved`);
|
|
536
|
+
if (loaded !== theme) {
|
|
537
|
+
const textmate = theme.textmate ?? (theme.cssVariables != null ? createCssVariablesTheme(theme.cssVariables) : void 0);
|
|
538
|
+
if (textmate == null) throw new Error(`Theme "${themeName}" does not support Shiki`);
|
|
539
|
+
this.raw.setTheme({
|
|
540
|
+
...textmate,
|
|
541
|
+
name: themeName
|
|
542
|
+
});
|
|
543
|
+
this.loadedThemes.set(themeName, theme);
|
|
544
|
+
}
|
|
545
|
+
return theme;
|
|
546
|
+
}
|
|
547
|
+
codeToTokens(code, options) {
|
|
548
|
+
return this.raw.codeToTokens(code, this.resolveOptions(options));
|
|
549
|
+
}
|
|
550
|
+
createEditorTokenizer(options) {
|
|
551
|
+
return new DiffsEditorTokenizer(new ShikiEditorTokenizer(this.raw, options, this), options);
|
|
552
|
+
}
|
|
553
|
+
createStreamTokenizer(options) {
|
|
554
|
+
return new ShikiStreamTokenizer(this.raw, this.resolveOptions(options));
|
|
555
|
+
}
|
|
556
|
+
async loadLanguages(languages) {
|
|
557
|
+
this.assertNotDisposed();
|
|
558
|
+
attachResolvedLanguages(await resolveLanguages(languages.filter((language) => !this.attachedLanguages.has(language))), this);
|
|
559
|
+
}
|
|
560
|
+
hasLoadedLanguages(languages) {
|
|
561
|
+
if (this.disposed) return false;
|
|
562
|
+
let loaded;
|
|
563
|
+
return languages.every((lang) => {
|
|
564
|
+
if (this.attachedLanguages.has(lang)) return true;
|
|
565
|
+
if (RegisteredCustomLanguages.has(lang)) return false;
|
|
566
|
+
loaded ??= this.raw.getLoadedLanguages();
|
|
567
|
+
return loaded.includes(lang);
|
|
568
|
+
});
|
|
569
|
+
}
|
|
570
|
+
attachLanguages(languages) {
|
|
571
|
+
this.assertNotDisposed();
|
|
572
|
+
for (const lang of languages) {
|
|
573
|
+
if (this.attachedLanguages.has(lang.name)) continue;
|
|
574
|
+
const grammar = lang.data.find((grammar) => grammar.name === lang.name || grammar.aliases?.includes(lang.name) === true);
|
|
575
|
+
if (grammar == null) throw new Error(`attachResolvedLanguages: No returned grammar declares "${lang.name}" as its name or an alias.`);
|
|
576
|
+
this.raw.loadLanguageSync(lang.data);
|
|
577
|
+
try {
|
|
578
|
+
this.raw.getLanguage(lang.name);
|
|
579
|
+
} catch {
|
|
580
|
+
throw new Error(`attachResolvedLanguages: "${grammar.name}" is already loaded without alias "${lang.name}". Load the alias first or give the grammar a unique name.`);
|
|
581
|
+
}
|
|
582
|
+
this.attachedLanguages.add(lang.name);
|
|
583
|
+
}
|
|
584
|
+
}
|
|
585
|
+
releaseResources() {
|
|
586
|
+
this.loadedThemes.clear();
|
|
587
|
+
this.attachedLanguages.clear();
|
|
588
|
+
this.raw.dispose();
|
|
589
|
+
}
|
|
590
|
+
resolveOptions({ theme, themes, ...options }) {
|
|
591
|
+
this.assertNotDisposed();
|
|
592
|
+
if (theme != null) {
|
|
593
|
+
this.getTheme(theme);
|
|
594
|
+
return {
|
|
595
|
+
...options,
|
|
596
|
+
theme
|
|
597
|
+
};
|
|
598
|
+
}
|
|
599
|
+
if (themes == null) throw new Error("A theme or themes option is required");
|
|
600
|
+
for (const name of Object.values(themes)) this.getTheme(name);
|
|
601
|
+
return {
|
|
602
|
+
...options,
|
|
603
|
+
themes
|
|
604
|
+
};
|
|
605
|
+
}
|
|
606
|
+
};
|
|
607
|
+
export { ShikiHighlighter };
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
// ../../node_modules/.pnpm/@pierre+highlights@0.5.2/node_modules/@pierre/highlights/dist/themes/slack-dark.js
|
|
2
|
+
var slack_dark_default = {
|
|
3
|
+
"name": "Slack Dark",
|
|
4
|
+
"appearance": "dark",
|
|
5
|
+
"style": {
|
|
6
|
+
"background": "#222222",
|
|
7
|
+
"editor.background": "#222222",
|
|
8
|
+
"text": "#E6E6E6",
|
|
9
|
+
"editor.foreground": "#E6E6E6",
|
|
10
|
+
"editor.active_line.background": "#141414",
|
|
11
|
+
"players": [{ "cursor": "#E6E6E6" }],
|
|
12
|
+
"created": "#ECB22E",
|
|
13
|
+
"deleted": "#FFF",
|
|
14
|
+
"modified": "#ECB22E",
|
|
15
|
+
"terminal.ansi.black": "#000000",
|
|
16
|
+
"terminal.ansi.red": "#cd3131",
|
|
17
|
+
"terminal.ansi.green": "#0dbc79",
|
|
18
|
+
"terminal.ansi.yellow": "#e5e510",
|
|
19
|
+
"terminal.ansi.blue": "#2472c8",
|
|
20
|
+
"terminal.ansi.magenta": "#bc3fbc",
|
|
21
|
+
"terminal.ansi.cyan": "#11a8cd",
|
|
22
|
+
"terminal.ansi.white": "#e5e5e5",
|
|
23
|
+
"terminal.ansi.bright_black": "#666666",
|
|
24
|
+
"terminal.ansi.bright_red": "#f14c4c",
|
|
25
|
+
"terminal.ansi.bright_green": "#23d18b",
|
|
26
|
+
"terminal.ansi.bright_yellow": "#f5f543",
|
|
27
|
+
"terminal.ansi.bright_blue": "#3b8eea",
|
|
28
|
+
"terminal.ansi.bright_magenta": "#d670d6",
|
|
29
|
+
"terminal.ansi.bright_cyan": "#29b8db",
|
|
30
|
+
"terminal.ansi.bright_white": "#e5e5e5",
|
|
31
|
+
"syntax": {
|
|
32
|
+
"attribute": { "color": "#9cdcfe" },
|
|
33
|
+
"boolean": { "color": "#569cd6" },
|
|
34
|
+
"comment": { "color": "#6A9955" },
|
|
35
|
+
"comment.doc": { "color": "#6A9955" },
|
|
36
|
+
"constant": { "color": "#569cd6" },
|
|
37
|
+
"constructor": { "color": "#569cd6" },
|
|
38
|
+
"embedded": { "color": "#D4D4D4" },
|
|
39
|
+
"emphasis.strong": {
|
|
40
|
+
"color": "#569cd6",
|
|
41
|
+
"font_weight": 700
|
|
42
|
+
},
|
|
43
|
+
"function": { "color": "#DCDCAA" },
|
|
44
|
+
"keyword": { "color": "#569cd6" },
|
|
45
|
+
"number": { "color": "#b5cea8" },
|
|
46
|
+
"operator": { "color": "#d4d4d4" },
|
|
47
|
+
"preproc": { "color": "#569cd6" },
|
|
48
|
+
"property": { "color": "#9cdcfe" },
|
|
49
|
+
"punctuation": { "color": "#808080" },
|
|
50
|
+
"punctuation.bracket": { "color": "#808080" },
|
|
51
|
+
"punctuation.delimiter": { "color": "#808080" },
|
|
52
|
+
"punctuation.list_marker": { "color": "#808080" },
|
|
53
|
+
"punctuation.special": { "color": "#808080" },
|
|
54
|
+
"string": { "color": "#ce9178" },
|
|
55
|
+
"string.escape": { "color": "#569cd6" },
|
|
56
|
+
"string.regex": { "color": "#ce9178" },
|
|
57
|
+
"string.special": { "color": "#ce9178" },
|
|
58
|
+
"string.special.symbol": { "color": "#ce9178" },
|
|
59
|
+
"tag": { "color": "#569cd6" },
|
|
60
|
+
"text.literal": { "color": "#ce9178" },
|
|
61
|
+
"type": { "color": "#4EC9B0" },
|
|
62
|
+
"variable": { "color": "#9CDCFE" },
|
|
63
|
+
"variable.special": { "color": "#569cd6" },
|
|
64
|
+
"emphasis": {
|
|
65
|
+
"color": "#E6E6E6",
|
|
66
|
+
"font_style": "italic"
|
|
67
|
+
},
|
|
68
|
+
"label": { "color": "#9CDCFE" },
|
|
69
|
+
"namespace": { "color": "#4EC9B0" },
|
|
70
|
+
"predictive": { "color": "#6A9955" },
|
|
71
|
+
"primary": { "color": "#E6E6E6" },
|
|
72
|
+
"selector": { "color": "#D7BA7D" },
|
|
73
|
+
"title": {
|
|
74
|
+
"color": "#569CD6",
|
|
75
|
+
"font_weight": 700
|
|
76
|
+
},
|
|
77
|
+
"enum": { "color": "#4EC9B0" },
|
|
78
|
+
"hint": { "color": "#6A9955" },
|
|
79
|
+
"link_text": { "color": "#CE9178" },
|
|
80
|
+
"link_uri": { "color": "#E6E6E6" },
|
|
81
|
+
"variant": { "color": "#9CDCFE" },
|
|
82
|
+
"diff.minus": { "color": "#CE9178" },
|
|
83
|
+
"diff.plus": { "color": "#B5CEA8" }
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
export { slack_dark_default as default };
|