@backmatter/studio 0.0.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/chunks/UiKitPage-CgNMOqfE.js +172 -0
- package/dist/chunks/WorkspaceRoutes-DgRtdie8.js +87297 -0
- package/dist/chunks/abap-Y8Dl9g_6.js +6 -0
- package/dist/chunks/actionscript-3-DQVEcJUW.js +6 -0
- package/dist/chunks/ada-vP6ak0IW.js +6 -0
- package/dist/chunks/andromeeda-BbmzSJq1.js +4 -0
- package/dist/chunks/angular-html-DPB4Rf0C.js +32 -0
- package/dist/chunks/angular-ts-CTOR2ofC.js +21 -0
- package/dist/chunks/apache-BUjz-sD2.js +6 -0
- package/dist/chunks/apex-OyTfjCYK.js +6 -0
- package/dist/chunks/apl-CjNiDgad.js +16 -0
- package/dist/chunks/applescript-BPx7YFFu.js +6 -0
- package/dist/chunks/ara-Z2fSOxSw.js +6 -0
- package/dist/chunks/asciidoc-C1T9ziH6.js +6 -0
- package/dist/chunks/asm-BTWLY5ym.js +6 -0
- package/dist/chunks/astro-CFFExE8Q.js +18 -0
- package/dist/chunks/aurora-x-BwoVEUWZ.js +4 -0
- package/dist/chunks/awk-Fb0P9dkn.js +6 -0
- package/dist/chunks/ayu-dark-DJoqd4M9.js +4 -0
- package/dist/chunks/ayu-light-BzXEJRJ-.js +4 -0
- package/dist/chunks/ayu-mirage-BJ2oZGzi.js +4 -0
- package/dist/chunks/ballerina-oZK-YekG.js +6 -0
- package/dist/chunks/bat-0FvbqU9S.js +6 -0
- package/dist/chunks/beancount-DqJEb89h.js +6 -0
- package/dist/chunks/berry-DODBq_Ff.js +6 -0
- package/dist/chunks/bibtex-EULQRLY5.js +6 -0
- package/dist/chunks/bicep-BorU73w0.js +6 -0
- package/dist/chunks/bird2-CIjBSNj3.js +6 -0
- package/dist/chunks/blade-D0HyNvCw.js +20 -0
- package/dist/chunks/bsl-NkNNwerW.js +8 -0
- package/dist/chunks/c-eeMepfLm.js +6 -0
- package/dist/chunks/c3-BY5XW5ym.js +6 -0
- package/dist/chunks/cadence-02UX7mW8.js +6 -0
- package/dist/chunks/cairo-DM6WF2e3.js +8 -0
- package/dist/chunks/catppuccin-frappe-D3cH2rXe.js +4 -0
- package/dist/chunks/catppuccin-latte-C0LRGUW4.js +4 -0
- package/dist/chunks/catppuccin-macchiato-c5wQ11TT.js +4 -0
- package/dist/chunks/catppuccin-mocha-WMD6Qvya.js +4 -0
- package/dist/chunks/clarity-PKm5CwqM.js +6 -0
- package/dist/chunks/clojure-CXJfHrL3.js +6 -0
- package/dist/chunks/cmake-BJz8BOTU.js +6 -0
- package/dist/chunks/cobol-HihOMwht.js +10 -0
- package/dist/chunks/codeowners-Bt9yU6NX.js +6 -0
- package/dist/chunks/codeql-DHkodjjI.js +6 -0
- package/dist/chunks/coffee-DGBR_nr_.js +8 -0
- package/dist/chunks/common-lisp-EVqT9Zhp.js +6 -0
- package/dist/chunks/coq-B0L9upzn.js +6 -0
- package/dist/chunks/cpp-Cj177cuW.js +18 -0
- package/dist/chunks/crystal-CRJyc4G-.js +18 -0
- package/dist/chunks/csharp-CCgA4A09.js +6 -0
- package/dist/chunks/css-CECN5uSL.js +6 -0
- package/dist/chunks/csv-CmYOceLb.js +6 -0
- package/dist/chunks/cue-ZzumE7IT.js +6 -0
- package/dist/chunks/cypher-jpdmjtA6.js +6 -0
- package/dist/chunks/d-CBagWSwH.js +6 -0
- package/dist/chunks/dark-plus-pUHDTVV0.js +4 -0
- package/dist/chunks/dart-6ObCrKr9.js +6 -0
- package/dist/chunks/dashboard-XKKZuJGm.js +1736 -0
- package/dist/chunks/dax-CcDT-8dH.js +6 -0
- package/dist/chunks/define-studio-BYtYDGLX.js +33 -0
- package/dist/chunks/desktop-B93p9R9O.js +6 -0
- package/dist/chunks/diff-BxzP2J8R.js +6 -0
- package/dist/chunks/docker-CsHqm9tx.js +6 -0
- package/dist/chunks/dotenv-BMjVjUL1.js +6 -0
- package/dist/chunks/dracula-BtZx2Kac.js +4 -0
- package/dist/chunks/dracula-soft-BKa-aqBv.js +4 -0
- package/dist/chunks/dream-maker-PAx17jaB.js +6 -0
- package/dist/chunks/edge-BYQkOzbF.js +12 -0
- package/dist/chunks/elixir-Dh036GMp.js +8 -0
- package/dist/chunks/elm-BtNbw_Cd.js +8 -0
- package/dist/chunks/emacs-lisp-Cfxdx5D-.js +6 -0
- package/dist/chunks/erb-ScVOXVpH.js +10 -0
- package/dist/chunks/erlang-DNcDT8Hi.js +8 -0
- package/dist/chunks/everforest-dark-DMCBqXCK.js +4 -0
- package/dist/chunks/everforest-light-BbXl82Em.js +4 -0
- package/dist/chunks/fennel-N4WcXuKx.js +6 -0
- package/dist/chunks/fish-BTDEUgqH.js +6 -0
- package/dist/chunks/fluent-BMXUxfv1.js +6 -0
- package/dist/chunks/fortran-fixed-form-B67KFkXH.js +8 -0
- package/dist/chunks/fortran-free-form-CwqYvCLJ.js +6 -0
- package/dist/chunks/fsharp-CYOiIVNx.js +8 -0
- package/dist/chunks/gdresource-CvCIUjhi.js +10 -0
- package/dist/chunks/gdscript-DSAxJ_aS.js +6 -0
- package/dist/chunks/gdshader-Bk8fF6yr.js +6 -0
- package/dist/chunks/genie-DzUvd7U9.js +6 -0
- package/dist/chunks/gherkin-DHRaV0YP.js +6 -0
- package/dist/chunks/git-commit-Bd32YZ0K.js +8 -0
- package/dist/chunks/git-rebase-ZWUFO_T4.js +8 -0
- package/dist/chunks/github-dark-DenFmJkN.js +4 -0
- package/dist/chunks/github-dark-default-BJPUVz4H.js +4 -0
- package/dist/chunks/github-dark-dimmed-DUshB20C.js +4 -0
- package/dist/chunks/github-dark-high-contrast-D3aGCnF8.js +4 -0
- package/dist/chunks/github-light-JYsPkUQd.js +4 -0
- package/dist/chunks/github-light-default-D99KPAby.js +4 -0
- package/dist/chunks/github-light-high-contrast-BbmZE-Mp.js +4 -0
- package/dist/chunks/gleam-Bv284lvN.js +6 -0
- package/dist/chunks/glimmer-js-DkxNrfPT.js +14 -0
- package/dist/chunks/glimmer-ts-D6YZEmK_.js +14 -0
- package/dist/chunks/glsl-CkUcVZNK.js +8 -0
- package/dist/chunks/gn-XtJxiLa4.js +6 -0
- package/dist/chunks/gnuplot-yPG9-sE_.js +6 -0
- package/dist/chunks/go-CvFNMTvu.js +6 -0
- package/dist/chunks/graphql-CBu2ehBn.js +14 -0
- package/dist/chunks/groovy-CJQTphOW.js +6 -0
- package/dist/chunks/gruvbox-dark-hard-C5HOtKIh.js +4 -0
- package/dist/chunks/gruvbox-dark-medium-FVgwJHuz.js +4 -0
- package/dist/chunks/gruvbox-dark-soft-B46F314v.js +4 -0
- package/dist/chunks/gruvbox-light-hard-CJD38wDZ.js +4 -0
- package/dist/chunks/gruvbox-light-medium-BlIhMYTA.js +4 -0
- package/dist/chunks/gruvbox-light-soft-DoPHyLVZ.js +4 -0
- package/dist/chunks/hack-ItRNKiEb.js +10 -0
- package/dist/chunks/haml-NZLVzu_R.js +10 -0
- package/dist/chunks/handlebars-mxStpSE7.js +14 -0
- package/dist/chunks/haskell-WeIwNIP6.js +6 -0
- package/dist/chunks/haxe-TztHsm5T.js +6 -0
- package/dist/chunks/hcl-D438OF-I.js +6 -0
- package/dist/chunks/hjson-DYBUbqOl.js +6 -0
- package/dist/chunks/hlsl-Bk8TCZNL.js +6 -0
- package/dist/chunks/horizon-CJQ10nlf.js +4 -0
- package/dist/chunks/horizon-bright-CdkBZOMB.js +4 -0
- package/dist/chunks/houston-BDYrDoDW.js +4 -0
- package/dist/chunks/html-B50bmoVb.js +10 -0
- package/dist/chunks/html-derivative-C6bxFbFW.js +8 -0
- package/dist/chunks/http-DLvAkeD-.js +14 -0
- package/dist/chunks/hurl-CgkFN90t.js +12 -0
- package/dist/chunks/hxml-GbqSQCLa.js +8 -0
- package/dist/chunks/hy-Brt5EZ7-.js +6 -0
- package/dist/chunks/imba-CimUv-Uh.js +6 -0
- package/dist/chunks/index-CFAIR8GH.js +18924 -0
- package/dist/chunks/ini-BZIuRIvJ.js +6 -0
- package/dist/chunks/java-DY6VlHhP.js +6 -0
- package/dist/chunks/javascript-C25yR2R2.js +6 -0
- package/dist/chunks/jinja-CFW5uAwY.js +11 -0
- package/dist/chunks/jison-DdreslRX.js +8 -0
- package/dist/chunks/json-DxJze_jm.js +6 -0
- package/dist/chunks/json5-BT4Fjg39.js +6 -0
- package/dist/chunks/jsonc-CHjZD8gR.js +6 -0
- package/dist/chunks/jsonl-BGuvDmy9.js +6 -0
- package/dist/chunks/jsonnet-Bx2cfsXg.js +6 -0
- package/dist/chunks/jssm-BcADi6EI.js +6 -0
- package/dist/chunks/jsx-BtKADgXT.js +6 -0
- package/dist/chunks/julia-CZiKXNNP.js +16 -0
- package/dist/chunks/just-CEK2SJ_k.js +18 -0
- package/dist/chunks/kanagawa-dragon-CiKur4Hl.js +4 -0
- package/dist/chunks/kanagawa-lotus-BKu-smKu.js +4 -0
- package/dist/chunks/kanagawa-wave-CQwozSzG.js +4 -0
- package/dist/chunks/kdl-BNOv9TC3.js +6 -0
- package/dist/chunks/kotlin-ByBMgTeR.js +6 -0
- package/dist/chunks/kusto-DH_XitHS.js +6 -0
- package/dist/chunks/laserwave-6a00oqik.js +4 -0
- package/dist/chunks/latex-B8Egmqc5.js +8 -0
- package/dist/chunks/lean-BnVxaZxY.js +6 -0
- package/dist/chunks/less-B1GLI2Di.js +6 -0
- package/dist/chunks/light-plus-CZuVqSLX.js +4 -0
- package/dist/chunks/liquid-CHzkx3jT.js +14 -0
- package/dist/chunks/llvm-Bk2XctFf.js +6 -0
- package/dist/chunks/log-Al8wyEFV.js +6 -0
- package/dist/chunks/logo-DBa4JDzV.js +6 -0
- package/dist/chunks/lua-Bp3IRv7I.js +8 -0
- package/dist/chunks/luau-UQyhudEE.js +6 -0
- package/dist/chunks/make-CsMclxtr.js +6 -0
- package/dist/chunks/markdown-CrScaQ96.js +6 -0
- package/dist/chunks/marko-CJBA24Ri.js +14 -0
- package/dist/chunks/material-theme-D6KBX41T.js +4 -0
- package/dist/chunks/material-theme-darker-CkRroheE.js +4 -0
- package/dist/chunks/material-theme-lighter-BUBw43Yz.js +4 -0
- package/dist/chunks/material-theme-ocean-ClGX14Ja.js +4 -0
- package/dist/chunks/material-theme-palenight-C1RVm8K1.js +4 -0
- package/dist/chunks/matlab-BOAaUVP0.js +6 -0
- package/dist/chunks/mdc-C9YSUwVC.js +12 -0
- package/dist/chunks/mdx-BOhZZUJ8.js +6 -0
- package/dist/chunks/mermaid-C3rz4dYh.js +6 -0
- package/dist/chunks/min-dark-C7ak0t6c.js +4 -0
- package/dist/chunks/min-light-CKFxVcPp.js +4 -0
- package/dist/chunks/mipsasm-CTx18fBl.js +6 -0
- package/dist/chunks/mojo-EIZIZRTQ.js +6 -0
- package/dist/chunks/monokai-C1KBYcO0.js +4 -0
- package/dist/chunks/moonbit-B1TV0fG3.js +6 -0
- package/dist/chunks/move-Db4ltDq1.js +6 -0
- package/dist/chunks/narrat-DmhDCBs-.js +6 -0
- package/dist/chunks/nextflow-47kAzSl1.js +8 -0
- package/dist/chunks/nextflow-groovy-Drz_2V0j.js +6 -0
- package/dist/chunks/nginx-D7O4WoB1.js +8 -0
- package/dist/chunks/night-owl-Bm2rzalh.js +4 -0
- package/dist/chunks/night-owl-light-CBI5u5kw.js +4 -0
- package/dist/chunks/nim-QAjRdh9w.js +20 -0
- package/dist/chunks/nix-fTRXMGic.js +9 -0
- package/dist/chunks/nord-CC5OiUXg.js +4 -0
- package/dist/chunks/nushell-BGCPRlV5.js +6 -0
- package/dist/chunks/objective-c-Itk8tzmv.js +6 -0
- package/dist/chunks/objective-cpp-DGt5UKRO.js +6 -0
- package/dist/chunks/ocaml-eSVK32Eg.js +6 -0
- package/dist/chunks/odin-BItnF517.js +6 -0
- package/dist/chunks/one-dark-pro-DTA3VF0_.js +4 -0
- package/dist/chunks/one-light-LkMrt1Cf.js +4 -0
- package/dist/chunks/openscad-Sp5uZ6f2.js +6 -0
- package/dist/chunks/pascal-xy8pJNns.js +6 -0
- package/dist/chunks/perl-DkVrgJBg.js +16 -0
- package/dist/chunks/php-BIzsF_5x.js +18 -0
- package/dist/chunks/pkl-C-zSNmaA.js +6 -0
- package/dist/chunks/plastic-CSTz3KZp.js +4 -0
- package/dist/chunks/plsql-pVbGZfOv.js +6 -0
- package/dist/chunks/po-BNfHvqmm.js +6 -0
- package/dist/chunks/poimandres-C-VADXHD.js +4 -0
- package/dist/chunks/polar-CAZahv3u.js +6 -0
- package/dist/chunks/postcss-05aHdL-n.js +6 -0
- package/dist/chunks/powerquery-DI9HkTvs.js +6 -0
- package/dist/chunks/powershell-Clc4ydu-.js +6 -0
- package/dist/chunks/prisma-FZjmVtSl.js +6 -0
- package/dist/chunks/prolog-C5-yg4TO.js +6 -0
- package/dist/chunks/proto-C7QgialS.js +6 -0
- package/dist/chunks/pug-XOw9Q1Ho.js +12 -0
- package/dist/chunks/puppet-CUJHmnxV.js +6 -0
- package/dist/chunks/purescript-rUfGld-4.js +6 -0
- package/dist/chunks/python-BFNSHbwJ.js +6 -0
- package/dist/chunks/qml-rTNXsquU.js +8 -0
- package/dist/chunks/qmldir-BInDYbpo.js +6 -0
- package/dist/chunks/qss-AeJTysr_.js +6 -0
- package/dist/chunks/r-CSmzDPi7.js +6 -0
- package/dist/chunks/racket-B83wSAja.js +6 -0
- package/dist/chunks/raku-nEQ4ZJJ7.js +6 -0
- package/dist/chunks/razor-Ci8D0dQK.js +10 -0
- package/dist/chunks/red-7y8PH7HH.js +4 -0
- package/dist/chunks/reg-m_s_Kiip.js +6 -0
- package/dist/chunks/regexp-BazyLpPg.js +6 -0
- package/dist/chunks/rel-BcRfyd6Q.js +6 -0
- package/dist/chunks/riscv-Ce8MAQLP.js +6 -0
- package/dist/chunks/ron-DCEEQypA.js +6 -0
- package/dist/chunks/rose-pine-BKc3yVeu.js +4 -0
- package/dist/chunks/rose-pine-dawn-BulJcPZT.js +4 -0
- package/dist/chunks/rose-pine-moon-j6jiXKV8.js +4 -0
- package/dist/chunks/rosmsg-Cz0w1km8.js +6 -0
- package/dist/chunks/rst-DM32Wy3O.js +22 -0
- package/dist/chunks/ruby-BeqCs27h.js +30 -0
- package/dist/chunks/rust-CLzF9zIN.js +6 -0
- package/dist/chunks/sas-fpEvgATw.js +8 -0
- package/dist/chunks/sass-DxHp5rTx.js +6 -0
- package/dist/chunks/scala-D4grkFkl.js +6 -0
- package/dist/chunks/scheme-BCRWuEm4.js +6 -0
- package/dist/chunks/scss-B1FaCqwR.js +8 -0
- package/dist/chunks/sdbl-B7T8abf4.js +6 -0
- package/dist/chunks/shaderlab-Cr62-Wb4.js +8 -0
- package/dist/chunks/shellscript-InADTalH.js +6 -0
- package/dist/chunks/shellsession-DiDJNQdy.js +8 -0
- package/dist/chunks/slack-dark-i7wN4OET.js +4 -0
- package/dist/chunks/slack-ochin-ndHf0LoP.js +4 -0
- package/dist/chunks/smalltalk-BlI1_OkM.js +6 -0
- package/dist/chunks/snazzy-light-BlSJXAu4.js +4 -0
- package/dist/chunks/solarized-dark-UTmkh7lw.js +4 -0
- package/dist/chunks/solarized-light-BheCkDPT.js +4 -0
- package/dist/chunks/solidity-DUWnFhS6.js +6 -0
- package/dist/chunks/soy-C1-6njHa.js +8 -0
- package/dist/chunks/sparql-B0KWFEri.js +8 -0
- package/dist/chunks/splunk-CRXR8A9s.js +6 -0
- package/dist/chunks/sql-Cn_v3PB0.js +6 -0
- package/dist/chunks/ssh-config-DP-hNVbF.js +6 -0
- package/dist/chunks/stata-B8c5fTjX.js +8 -0
- package/dist/chunks/stylus-CyKEU1Ej.js +6 -0
- package/dist/chunks/surrealql-CQi7GQN7.js +8 -0
- package/dist/chunks/svelte-rYri41WT.js +14 -0
- package/dist/chunks/swift-DJpUqPLg.js +6 -0
- package/dist/chunks/synthwave-84-NU3C_KFZ.js +4 -0
- package/dist/chunks/system-verilog-BCm7smPJ.js +6 -0
- package/dist/chunks/systemd-C-4qm6XH.js +6 -0
- package/dist/chunks/talonscript-CFF3LF_O.js +6 -0
- package/dist/chunks/tasl-Cg_WBUAe.js +6 -0
- package/dist/chunks/tcl-DN7buRTF.js +6 -0
- package/dist/chunks/templ-Crs9Ui8q.js +12 -0
- package/dist/chunks/terraform-DGvcn9zM.js +6 -0
- package/dist/chunks/tex-AHxmLTL0.js +8 -0
- package/dist/chunks/tokyo-night-DP4TmcQl.js +4 -0
- package/dist/chunks/toml-DY62mUL_.js +6 -0
- package/dist/chunks/ts-tags-ioVe2PKw.js +41 -0
- package/dist/chunks/tsv-BtvSkaG0.js +6 -0
- package/dist/chunks/tsx-B8rCNbgL.js +6 -0
- package/dist/chunks/turtle-_H59FV7D.js +6 -0
- package/dist/chunks/twig-DwV2Fi4L.js +18 -0
- package/dist/chunks/typescript-RycA9KXf.js +6 -0
- package/dist/chunks/typespec-DWqp-kUU.js +6 -0
- package/dist/chunks/typst-D_1QKWns.js +6 -0
- package/dist/chunks/v-BPCNiyYe.js +6 -0
- package/dist/chunks/vala-uxaPR7d1.js +6 -0
- package/dist/chunks/vb-D8_c5-KN.js +6 -0
- package/dist/chunks/verilog-B-bybjPF.js +6 -0
- package/dist/chunks/vesper-BckBta1U.js +4 -0
- package/dist/chunks/vhdl-CUlNa8ac.js +6 -0
- package/dist/chunks/viml-DsfA-sWm.js +6 -0
- package/dist/chunks/vitesse-black-BoGvW84i.js +4 -0
- package/dist/chunks/vitesse-dark-Cym-eLtO.js +4 -0
- package/dist/chunks/vitesse-light-CcmG315c.js +4 -0
- package/dist/chunks/vue-DXEmyXn9.js +31 -0
- package/dist/chunks/vue-html-j9xNEdu3.js +8 -0
- package/dist/chunks/vue-vine-D41-N99t.js +18 -0
- package/dist/chunks/vyper-CPQuu50u.js +6 -0
- package/dist/chunks/wasm-BBXxrAl7.js +6 -0
- package/dist/chunks/wasm-DQxwEHae.js +7 -0
- package/dist/chunks/wenyan-pbVjoM9_.js +6 -0
- package/dist/chunks/wgsl-DY4iK1q1.js +6 -0
- package/dist/chunks/wikitext-Z-MoUasO.js +6 -0
- package/dist/chunks/wit-CQMQOlTg.js +6 -0
- package/dist/chunks/wolfram-Dz4KXISs.js +6 -0
- package/dist/chunks/xml-C2J0sS9M.js +8 -0
- package/dist/chunks/xsl-BmSZphgC.js +8 -0
- package/dist/chunks/yaml-DaO7k5B1.js +6 -0
- package/dist/chunks/zenscript-CxBjpf9c.js +6 -0
- package/dist/chunks/zig-Vm0PO9wB.js +6 -0
- package/dist/dashboard.js +8 -0
- package/dist/define.js +4 -0
- package/dist/index.js +317 -0
- package/dist/studio.css +2272 -0
- package/dist/styles.js +1 -0
- package/package.json +88 -0
- package/prose-node-shims/fs.ts +6 -0
- package/prose-node-shims/path.ts +16 -0
- package/prose-node-shims/sharp.ts +4 -0
- package/prose-ui-node-shim.ts +26 -0
- package/src/App.tsx +173 -0
- package/src/WorkspaceRoutes.tsx +38 -0
- package/src/api.ts +833 -0
- package/src/auth-client.ts +15 -0
- package/src/chat/ChangeCard.tsx +330 -0
- package/src/chat/ChatBar.tsx +238 -0
- package/src/chat/ChatMessage.tsx +478 -0
- package/src/chat/ChatPanel.tsx +406 -0
- package/src/chat/ChatProvider.tsx +661 -0
- package/src/chat/Composer.tsx +461 -0
- package/src/chat/DocListCard.tsx +322 -0
- package/src/chat/LiveStatus.tsx +83 -0
- package/src/chat/MentionPopover.tsx +164 -0
- package/src/chat/ModelPicker.tsx +113 -0
- package/src/chat/Shimmer.tsx +39 -0
- package/src/chat/ThreadHistory.tsx +268 -0
- package/src/chat/chat-context.ts +41 -0
- package/src/chat/chat-helpers.ts +402 -0
- package/src/chat/chat-state.ts +59 -0
- package/src/chat/icons.tsx +171 -0
- package/src/chat/useStickToBottom.ts +110 -0
- package/src/chrome/AppShell.tsx +100 -0
- package/src/chrome/AppSidebar.tsx +305 -0
- package/src/chrome/CommandPalette.tsx +559 -0
- package/src/chrome/ContentApiPopover.tsx +215 -0
- package/src/chrome/EditorActionsContext.tsx +63 -0
- package/src/chrome/EditorFocusContext.tsx +80 -0
- package/src/chrome/EditorStatusContext.tsx +84 -0
- package/src/chrome/NavItem.tsx +75 -0
- package/src/chrome/OpenSiteButton.tsx +148 -0
- package/src/chrome/StatusBar.tsx +73 -0
- package/src/chrome/UserMenu.tsx +130 -0
- package/src/chrome/WorkspaceNavContext.tsx +60 -0
- package/src/chrome/WorkspaceStatusBar.tsx +940 -0
- package/src/chrome/content-api-url.ts +111 -0
- package/src/chrome/content-type-groups.ts +32 -0
- package/src/chrome/hotkeys.ts +79 -0
- package/src/chrome/icons.tsx +191 -0
- package/src/chrome/open-site.ts +30 -0
- package/src/chrome/status-bar-action.ts +24 -0
- package/src/components/AppChromeContext.tsx +32 -0
- package/src/components/Shell.tsx +18 -0
- package/src/components/WorkspaceSwitcher.tsx +345 -0
- package/src/content-blocks/index.tsx +262 -0
- package/src/css.d.ts +2 -0
- package/src/dashboard.ts +5 -0
- package/src/define-studio.tsx +98 -0
- package/src/define.ts +12 -0
- package/src/index.css +123 -0
- package/src/index.ts +19 -0
- package/src/last-user.ts +40 -0
- package/src/last-workspace.ts +57 -0
- package/src/mcp/McpConnectorsPanel.tsx +872 -0
- package/src/mcp/parse-json.ts +52 -0
- package/src/pages/AcceptInvitePage.tsx +99 -0
- package/src/pages/BlockSettingsDialog.tsx +303 -0
- package/src/pages/BlocksList.tsx +402 -0
- package/src/pages/BodyProse.tsx +236 -0
- package/src/pages/DocEditorPage.tsx +1394 -0
- package/src/pages/EmbedChatPage.tsx +110 -0
- package/src/pages/EmbedPublishPage.tsx +259 -0
- package/src/pages/EnterPage.tsx +96 -0
- package/src/pages/GithubConnectPage.tsx +142 -0
- package/src/pages/LegacyWorkspaceRedirect.tsx +57 -0
- package/src/pages/LoginPage.tsx +335 -0
- package/src/pages/NewWorkspacePage.tsx +74 -0
- package/src/pages/RenderedBody.tsx +598 -0
- package/src/pages/ResumeHome.tsx +18 -0
- package/src/pages/SelectionBar.tsx +277 -0
- package/src/pages/SettingsGeneralPage.tsx +403 -0
- package/src/pages/SettingsGithubPage.tsx +277 -0
- package/src/pages/SettingsLayout.tsx +127 -0
- package/src/pages/SettingsMcpPage.tsx +30 -0
- package/src/pages/SettingsSchemaPage.tsx +93 -0
- package/src/pages/SettingsUsersPage.tsx +363 -0
- package/src/pages/TypeDocsPage.tsx +225 -0
- package/src/pages/UiKitPage.tsx +331 -0
- package/src/pages/UserSettingsPage.tsx +94 -0
- package/src/pages/WorkspaceHomeRedirect.tsx +17 -0
- package/src/pages/WorkspaceLayout.tsx +103 -0
- package/src/pages/WorkspacesPage.tsx +35 -0
- package/src/pages/blocks-list.ts +73 -0
- package/src/pages/body-blocks.ts +233 -0
- package/src/pages/body-mdx.tsx +82 -0
- package/src/pages/compile-body.ts +37 -0
- package/src/pages/host-env.ts +22 -0
- package/src/pages/html-to-markdown.ts +99 -0
- package/src/pages/preview-bridge.ts +46 -0
- package/src/pages/preview-split.ts +30 -0
- package/src/pages/preview-url.ts +92 -0
- package/src/pages/selection-format.ts +179 -0
- package/src/pages/type-docs.ts +9 -0
- package/src/replica/BootstrapSplash.tsx +80 -0
- package/src/replica/ReplicaProvider.tsx +267 -0
- package/src/replica/cache.ts +30 -0
- package/src/replica/idb.ts +89 -0
- package/src/replica/instance.ts +39 -0
- package/src/replica/pull.ts +23 -0
- package/src/replica/store.ts +497 -0
- package/src/replica/sync-cache.ts +51 -0
- package/src/replica/types.ts +119 -0
- package/src/replica/useReplica.ts +13 -0
- package/src/site.tsx +230 -0
- package/src/studio-config.ts +81 -0
- package/src/styles/themes.ts +49 -0
- package/src/styles/tokens.stylex.ts +58 -0
- package/src/styles.ts +11 -0
- package/src/theme/AccentOverride.tsx +29 -0
- package/src/theme/ThemeProvider.tsx +130 -0
- package/src/theme/apply-theme-class.ts +12 -0
- package/src/ui/BackLink.tsx +28 -0
- package/src/ui/Button.tsx +167 -0
- package/src/ui/ConfirmDialog.tsx +141 -0
- package/src/ui/Field.tsx +45 -0
- package/src/ui/Input.tsx +183 -0
- package/src/ui/ListRow.tsx +88 -0
- package/src/ui/Page.tsx +151 -0
- package/src/ui/Text.tsx +77 -0
- package/src/ui/Tooltip.tsx +85 -0
- package/src/ui/popup.ts +216 -0
- package/src/workspace/permissions.ts +17 -0
- package/src/workspace/types.ts +12 -0
- package/src/workspace-path.ts +98 -0
|
@@ -0,0 +1,461 @@
|
|
|
1
|
+
// packages/studio/src/chat/Composer.tsx
|
|
2
|
+
import { useCallback, useEffect, useRef, useState } from "react";
|
|
3
|
+
import * as stylex from "@stylexjs/stylex";
|
|
4
|
+
import { docKey, type DocRef } from "../chrome/EditorFocusContext";
|
|
5
|
+
import { colors, radius, space, type } from "../styles/tokens.stylex";
|
|
6
|
+
import { Tooltip } from "../ui/Tooltip";
|
|
7
|
+
import { useChatSession, useChatUI } from "./ChatProvider";
|
|
8
|
+
import { MentionPopover, type MentionKey } from "./MentionPopover";
|
|
9
|
+
import { ModelPicker } from "./ModelPicker";
|
|
10
|
+
import { AtIcon, CloseIcon, FileIcon, FocusIcon, SendIcon, StopIcon } from "./icons";
|
|
11
|
+
import { mentionQueryAt } from "./chat-helpers";
|
|
12
|
+
|
|
13
|
+
const hover = "@media (hover: hover)";
|
|
14
|
+
|
|
15
|
+
/** Height of one row in the context bar; the bar adds 8px of vertical padding. */
|
|
16
|
+
export const CONTEXT_ROW_HEIGHT = 30;
|
|
17
|
+
export const CONTEXT_BAR_PADDING = 8;
|
|
18
|
+
|
|
19
|
+
const MENTION_KEYS: ReadonlySet<string> = new Set(["ArrowDown", "ArrowUp", "Enter", "Tab", "Escape"]);
|
|
20
|
+
|
|
21
|
+
function isMentionKey(key: string): key is MentionKey {
|
|
22
|
+
return MENTION_KEYS.has(key);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export function Composer({ autoFocus }: { autoFocus: boolean }) {
|
|
26
|
+
const ui = useChatUI();
|
|
27
|
+
const session = useChatSession();
|
|
28
|
+
const [text, setText] = useState("");
|
|
29
|
+
const [mention, setMention] = useState<{ start: number; query: string } | null>(null);
|
|
30
|
+
const ref = useRef<HTMLTextAreaElement>(null);
|
|
31
|
+
const boxRef = useRef<HTMLDivElement>(null);
|
|
32
|
+
const mentionKeys = useRef<((key: MentionKey) => void) | null>(null);
|
|
33
|
+
const busy = session.status === "streaming" || session.status === "submitted";
|
|
34
|
+
const canSend = text.trim().length > 0 && !busy && ui.aiAvailable === true;
|
|
35
|
+
|
|
36
|
+
// Auto-grow.
|
|
37
|
+
useEffect(() => {
|
|
38
|
+
const el = ref.current;
|
|
39
|
+
if (!el) return;
|
|
40
|
+
el.style.height = "0px";
|
|
41
|
+
el.style.height = `${Math.min(el.scrollHeight, 180)}px`;
|
|
42
|
+
}, [text]);
|
|
43
|
+
|
|
44
|
+
useEffect(() => {
|
|
45
|
+
if (!autoFocus) return;
|
|
46
|
+
const id = requestAnimationFrame(() => ref.current?.focus());
|
|
47
|
+
return () => cancelAnimationFrame(id);
|
|
48
|
+
}, [autoFocus, session.threadId]);
|
|
49
|
+
|
|
50
|
+
useEffect(() => {
|
|
51
|
+
function onFocus() {
|
|
52
|
+
ref.current?.focus();
|
|
53
|
+
}
|
|
54
|
+
window.addEventListener("backmatter:chat-focus", onFocus);
|
|
55
|
+
return () => window.removeEventListener("backmatter:chat-focus", onFocus);
|
|
56
|
+
}, []);
|
|
57
|
+
|
|
58
|
+
// Suggestion chips ending with "…" prefill the composer.
|
|
59
|
+
useEffect(() => {
|
|
60
|
+
function onPrefill(e: Event) {
|
|
61
|
+
const detail = (e as CustomEvent<{ text: string }>).detail;
|
|
62
|
+
setText(detail.text);
|
|
63
|
+
requestAnimationFrame(() => {
|
|
64
|
+
const el = ref.current;
|
|
65
|
+
if (!el) return;
|
|
66
|
+
el.focus();
|
|
67
|
+
el.setSelectionRange(el.value.length, el.value.length);
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
window.addEventListener("backmatter:chat-prefill", onPrefill);
|
|
71
|
+
return () => window.removeEventListener("backmatter:chat-prefill", onPrefill);
|
|
72
|
+
}, []);
|
|
73
|
+
|
|
74
|
+
const submit = useCallback(() => {
|
|
75
|
+
const value = text.trim();
|
|
76
|
+
if (!value || busy) return;
|
|
77
|
+
setText("");
|
|
78
|
+
setMention(null);
|
|
79
|
+
void session.send(value);
|
|
80
|
+
}, [text, busy, session]);
|
|
81
|
+
|
|
82
|
+
function updateMention(el: HTMLTextAreaElement) {
|
|
83
|
+
setMention(mentionQueryAt(el.value, el.selectionStart ?? el.value.length));
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
function pickMention(refDoc: DocRef) {
|
|
87
|
+
ui.addMention(refDoc);
|
|
88
|
+
if (mention) {
|
|
89
|
+
const el = ref.current;
|
|
90
|
+
const caret = el?.selectionStart ?? text.length;
|
|
91
|
+
const next = `${text.slice(0, mention.start)}${text.slice(caret)}`;
|
|
92
|
+
setText(next);
|
|
93
|
+
requestAnimationFrame(() => {
|
|
94
|
+
el?.focus();
|
|
95
|
+
el?.setSelectionRange(mention.start, mention.start);
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
setMention(null);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
const focusChip = ui.focus && ui.includeFocus ? ui.focus.docRef : null;
|
|
102
|
+
const selectionActive =
|
|
103
|
+
ui.focus?.selection && ui.focus.selection.end > ui.focus.selection.start;
|
|
104
|
+
const hasContext = Boolean(focusChip || ui.mentions.length > 0);
|
|
105
|
+
|
|
106
|
+
return (
|
|
107
|
+
<div {...stylex.props(styles.wrap)}>
|
|
108
|
+
{mention ? (
|
|
109
|
+
<MentionPopover
|
|
110
|
+
workspaceId={ui.workspaceId}
|
|
111
|
+
anchor={boxRef}
|
|
112
|
+
query={mention.query}
|
|
113
|
+
exclude={[...ui.mentions, ...(ui.focus ? [ui.focus.docRef] : [])]}
|
|
114
|
+
keyHandlerRef={mentionKeys}
|
|
115
|
+
onSelect={pickMention}
|
|
116
|
+
onClose={() => setMention(null)}
|
|
117
|
+
/>
|
|
118
|
+
) : null}
|
|
119
|
+
{hasContext ? (
|
|
120
|
+
<div {...stylex.props(styles.context)} aria-label="Context">
|
|
121
|
+
{focusChip ? (
|
|
122
|
+
<ContextRow
|
|
123
|
+
icon={<FileIcon size={13} />}
|
|
124
|
+
type={focusChip.type}
|
|
125
|
+
slug={focusChip.slug}
|
|
126
|
+
meta={selectionActive ? "selection" : "open in editor"}
|
|
127
|
+
removeLabel="Remove open document from context"
|
|
128
|
+
onRemove={() => ui.setIncludeFocus(false)}
|
|
129
|
+
/>
|
|
130
|
+
) : null}
|
|
131
|
+
{ui.mentions.map((m) => (
|
|
132
|
+
<ContextRow
|
|
133
|
+
key={docKey(m)}
|
|
134
|
+
icon={<AtIcon size={13} />}
|
|
135
|
+
type={m.type}
|
|
136
|
+
slug={m.slug}
|
|
137
|
+
removeLabel={`Remove ${m.type}/${m.slug}`}
|
|
138
|
+
onRemove={() => ui.removeMention(m)}
|
|
139
|
+
/>
|
|
140
|
+
))}
|
|
141
|
+
</div>
|
|
142
|
+
) : null}
|
|
143
|
+
<div ref={boxRef} {...stylex.props(styles.box)}>
|
|
144
|
+
<textarea
|
|
145
|
+
ref={ref}
|
|
146
|
+
value={text}
|
|
147
|
+
rows={1}
|
|
148
|
+
placeholder={
|
|
149
|
+
ui.aiAvailable === false
|
|
150
|
+
? "AI is not configured on this server"
|
|
151
|
+
: ui.tier === "ask"
|
|
152
|
+
? "Ask about your content…"
|
|
153
|
+
: "Ask or describe a change…"
|
|
154
|
+
}
|
|
155
|
+
aria-label="Message the AI assistant"
|
|
156
|
+
data-no-ring=""
|
|
157
|
+
disabled={ui.aiAvailable !== true}
|
|
158
|
+
onChange={(e) => {
|
|
159
|
+
setText(e.target.value);
|
|
160
|
+
updateMention(e.target);
|
|
161
|
+
}}
|
|
162
|
+
onClick={(e) => updateMention(e.currentTarget)}
|
|
163
|
+
onKeyDown={(e) => {
|
|
164
|
+
if (mention && isMentionKey(e.key)) {
|
|
165
|
+
e.preventDefault();
|
|
166
|
+
mentionKeys.current?.(e.key);
|
|
167
|
+
return;
|
|
168
|
+
}
|
|
169
|
+
if (e.key === "Enter" && !e.shiftKey && !e.nativeEvent.isComposing) {
|
|
170
|
+
e.preventDefault();
|
|
171
|
+
submit();
|
|
172
|
+
} else if (e.key === "Escape") {
|
|
173
|
+
ui.dispatch({ type: "minimize" });
|
|
174
|
+
}
|
|
175
|
+
}}
|
|
176
|
+
{...stylex.props(styles.textarea)}
|
|
177
|
+
/>
|
|
178
|
+
<div {...stylex.props(styles.footer)}>
|
|
179
|
+
<Tooltip label="Mention a document (@)">
|
|
180
|
+
<button
|
|
181
|
+
type="button"
|
|
182
|
+
aria-label="Mention a document"
|
|
183
|
+
disabled={ui.aiAvailable !== true}
|
|
184
|
+
onClick={() => {
|
|
185
|
+
const el = ref.current;
|
|
186
|
+
if (!el) return;
|
|
187
|
+
const caret = el.selectionStart ?? text.length;
|
|
188
|
+
const needsSpace = caret > 0 && !/\s/.test(text[caret - 1] ?? " ");
|
|
189
|
+
const insert = `${needsSpace ? " " : ""}@`;
|
|
190
|
+
const next = `${text.slice(0, caret)}${insert}${text.slice(caret)}`;
|
|
191
|
+
setText(next);
|
|
192
|
+
const pos = caret + insert.length;
|
|
193
|
+
requestAnimationFrame(() => {
|
|
194
|
+
el.focus();
|
|
195
|
+
el.setSelectionRange(pos, pos);
|
|
196
|
+
setMention({ start: pos - 1, query: "" });
|
|
197
|
+
});
|
|
198
|
+
}}
|
|
199
|
+
{...stylex.props(styles.iconBtn)}
|
|
200
|
+
>
|
|
201
|
+
<AtIcon />
|
|
202
|
+
</button>
|
|
203
|
+
</Tooltip>
|
|
204
|
+
<span {...stylex.props(styles.spacer)} />
|
|
205
|
+
{ui.focus ? (
|
|
206
|
+
<Tooltip
|
|
207
|
+
label={
|
|
208
|
+
ui.includeFocus
|
|
209
|
+
? "Stop including the open document"
|
|
210
|
+
: `Include ${ui.focus.docRef.type}/${ui.focus.docRef.slug}`
|
|
211
|
+
}
|
|
212
|
+
>
|
|
213
|
+
<button
|
|
214
|
+
type="button"
|
|
215
|
+
aria-label="Include the open document in context"
|
|
216
|
+
aria-pressed={ui.includeFocus}
|
|
217
|
+
disabled={ui.aiAvailable !== true}
|
|
218
|
+
onClick={() => ui.setIncludeFocus(!ui.includeFocus)}
|
|
219
|
+
{...stylex.props(styles.iconBtn, ui.includeFocus && styles.iconBtnActive)}
|
|
220
|
+
>
|
|
221
|
+
<FocusIcon />
|
|
222
|
+
</button>
|
|
223
|
+
</Tooltip>
|
|
224
|
+
) : null}
|
|
225
|
+
<ModelPicker />
|
|
226
|
+
{busy ? (
|
|
227
|
+
<Tooltip label="Stop generating">
|
|
228
|
+
<button
|
|
229
|
+
type="button"
|
|
230
|
+
aria-label="Stop generating"
|
|
231
|
+
onClick={() => session.stop()}
|
|
232
|
+
{...stylex.props(styles.sendBtn, styles.stopBtn)}
|
|
233
|
+
>
|
|
234
|
+
<StopIcon />
|
|
235
|
+
</button>
|
|
236
|
+
</Tooltip>
|
|
237
|
+
) : (
|
|
238
|
+
<Tooltip label="Send (Enter)">
|
|
239
|
+
<button
|
|
240
|
+
type="button"
|
|
241
|
+
aria-label="Send message"
|
|
242
|
+
disabled={!canSend}
|
|
243
|
+
onClick={submit}
|
|
244
|
+
{...stylex.props(styles.sendBtn)}
|
|
245
|
+
>
|
|
246
|
+
<SendIcon />
|
|
247
|
+
</button>
|
|
248
|
+
</Tooltip>
|
|
249
|
+
)}
|
|
250
|
+
</div>
|
|
251
|
+
</div>
|
|
252
|
+
</div>
|
|
253
|
+
);
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
function ContextRow({
|
|
257
|
+
icon,
|
|
258
|
+
type,
|
|
259
|
+
slug,
|
|
260
|
+
meta,
|
|
261
|
+
removeLabel,
|
|
262
|
+
onRemove,
|
|
263
|
+
}: {
|
|
264
|
+
icon: React.ReactNode;
|
|
265
|
+
type: string;
|
|
266
|
+
slug: string;
|
|
267
|
+
meta?: string;
|
|
268
|
+
removeLabel: string;
|
|
269
|
+
onRemove: () => void;
|
|
270
|
+
}) {
|
|
271
|
+
return (
|
|
272
|
+
<div {...stylex.props(styles.row)}>
|
|
273
|
+
<span {...stylex.props(styles.rowIcon)}>{icon}</span>
|
|
274
|
+
<span {...stylex.props(styles.rowText)}>
|
|
275
|
+
<span {...stylex.props(styles.rowType)}>{type}/</span>
|
|
276
|
+
<span {...stylex.props(styles.rowSlug)}>{slug}</span>
|
|
277
|
+
</span>
|
|
278
|
+
{meta ? <span {...stylex.props(styles.rowMeta)}>{meta}</span> : null}
|
|
279
|
+
<button
|
|
280
|
+
type="button"
|
|
281
|
+
aria-label={removeLabel}
|
|
282
|
+
onClick={onRemove}
|
|
283
|
+
{...stylex.props(styles.rowRemove)}
|
|
284
|
+
>
|
|
285
|
+
<CloseIcon size={11} />
|
|
286
|
+
</button>
|
|
287
|
+
</div>
|
|
288
|
+
);
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
const styles = stylex.create({
|
|
292
|
+
wrap: {
|
|
293
|
+
position: "relative",
|
|
294
|
+
padding: space.md,
|
|
295
|
+
paddingTop: 0,
|
|
296
|
+
},
|
|
297
|
+
// Floats above the input box (its bottom tucked behind it) so toggling it never
|
|
298
|
+
// reflows the message area; ChatPanel reserves matching space (CONTEXT_ROW_HEIGHT).
|
|
299
|
+
context: {
|
|
300
|
+
position: "absolute",
|
|
301
|
+
left: space.md,
|
|
302
|
+
right: space.md,
|
|
303
|
+
bottom: "calc(100% - 12px)",
|
|
304
|
+
zIndex: 1,
|
|
305
|
+
display: "flex",
|
|
306
|
+
flexDirection: "column",
|
|
307
|
+
paddingInline: space.sm,
|
|
308
|
+
paddingTop: space.xs,
|
|
309
|
+
paddingBottom: `calc(${space.xs} + 12px)`,
|
|
310
|
+
borderRadius: 12,
|
|
311
|
+
backgroundColor: colors.bgPanelInset,
|
|
312
|
+
},
|
|
313
|
+
row: {
|
|
314
|
+
display: "flex",
|
|
315
|
+
alignItems: "center",
|
|
316
|
+
gap: space.sm,
|
|
317
|
+
height: CONTEXT_ROW_HEIGHT,
|
|
318
|
+
paddingInline: space.sm,
|
|
319
|
+
borderRadius: radius.md,
|
|
320
|
+
color: colors.text,
|
|
321
|
+
fontSize: type.sm,
|
|
322
|
+
},
|
|
323
|
+
rowIcon: {
|
|
324
|
+
display: "inline-flex",
|
|
325
|
+
flexShrink: 0,
|
|
326
|
+
color: colors.textMuted,
|
|
327
|
+
},
|
|
328
|
+
rowText: {
|
|
329
|
+
display: "inline-flex",
|
|
330
|
+
minWidth: 0,
|
|
331
|
+
flex: 1,
|
|
332
|
+
gap: 0,
|
|
333
|
+
overflow: "hidden",
|
|
334
|
+
whiteSpace: "nowrap",
|
|
335
|
+
},
|
|
336
|
+
rowType: {
|
|
337
|
+
flexShrink: 0,
|
|
338
|
+
color: colors.textMuted,
|
|
339
|
+
},
|
|
340
|
+
rowSlug: {
|
|
341
|
+
overflow: "hidden",
|
|
342
|
+
textOverflow: "ellipsis",
|
|
343
|
+
fontWeight: 500,
|
|
344
|
+
},
|
|
345
|
+
rowMeta: {
|
|
346
|
+
flexShrink: 0,
|
|
347
|
+
fontSize: type.xs,
|
|
348
|
+
color: colors.textMuted,
|
|
349
|
+
},
|
|
350
|
+
rowRemove: {
|
|
351
|
+
display: "inline-flex",
|
|
352
|
+
alignItems: "center",
|
|
353
|
+
justifyContent: "center",
|
|
354
|
+
flexShrink: 0,
|
|
355
|
+
width: 20,
|
|
356
|
+
height: 20,
|
|
357
|
+
padding: 0,
|
|
358
|
+
borderWidth: 0,
|
|
359
|
+
borderRadius: radius.sm,
|
|
360
|
+
backgroundColor: "transparent",
|
|
361
|
+
color: colors.textMuted,
|
|
362
|
+
cursor: "pointer",
|
|
363
|
+
[hover]: {
|
|
364
|
+
":hover": { backgroundColor: colors.bgHover, color: colors.text },
|
|
365
|
+
},
|
|
366
|
+
},
|
|
367
|
+
box: {
|
|
368
|
+
position: "relative",
|
|
369
|
+
zIndex: 2,
|
|
370
|
+
display: "flex",
|
|
371
|
+
flexDirection: "column",
|
|
372
|
+
gap: space.sm,
|
|
373
|
+
padding: space.md,
|
|
374
|
+
borderWidth: 1,
|
|
375
|
+
borderStyle: "solid",
|
|
376
|
+
borderColor: colors.border,
|
|
377
|
+
borderRadius: 12,
|
|
378
|
+
backgroundColor: colors.bgSurface,
|
|
379
|
+
transitionProperty: "border-color",
|
|
380
|
+
transitionDuration: "120ms",
|
|
381
|
+
":focus-within": {
|
|
382
|
+
borderColor: `color-mix(in srgb, ${colors.textMuted} 45%, ${colors.border})`,
|
|
383
|
+
},
|
|
384
|
+
},
|
|
385
|
+
textarea: {
|
|
386
|
+
display: "block",
|
|
387
|
+
width: "100%",
|
|
388
|
+
minHeight: 24,
|
|
389
|
+
maxHeight: 180,
|
|
390
|
+
resize: "none",
|
|
391
|
+
borderWidth: 0,
|
|
392
|
+
padding: 0,
|
|
393
|
+
backgroundColor: "transparent",
|
|
394
|
+
color: colors.text,
|
|
395
|
+
fontFamily: type.sans,
|
|
396
|
+
fontSize: type.md,
|
|
397
|
+
lineHeight: 1.5,
|
|
398
|
+
outline: "none",
|
|
399
|
+
"::placeholder": {
|
|
400
|
+
color: colors.textMuted,
|
|
401
|
+
},
|
|
402
|
+
":disabled": {
|
|
403
|
+
cursor: "not-allowed",
|
|
404
|
+
},
|
|
405
|
+
},
|
|
406
|
+
footer: {
|
|
407
|
+
display: "flex",
|
|
408
|
+
alignItems: "center",
|
|
409
|
+
gap: space.xs,
|
|
410
|
+
},
|
|
411
|
+
spacer: {
|
|
412
|
+
flex: 1,
|
|
413
|
+
},
|
|
414
|
+
iconBtn: {
|
|
415
|
+
display: "inline-flex",
|
|
416
|
+
alignItems: "center",
|
|
417
|
+
justifyContent: "center",
|
|
418
|
+
width: 28,
|
|
419
|
+
height: 28,
|
|
420
|
+
borderWidth: 0,
|
|
421
|
+
borderRadius: 999,
|
|
422
|
+
backgroundColor: "transparent",
|
|
423
|
+
color: colors.textMuted,
|
|
424
|
+
cursor: "pointer",
|
|
425
|
+
[hover]: {
|
|
426
|
+
":hover": { backgroundColor: colors.bgHover, color: colors.text },
|
|
427
|
+
},
|
|
428
|
+
":disabled": { opacity: 0.5, cursor: "default" },
|
|
429
|
+
},
|
|
430
|
+
iconBtnActive: {
|
|
431
|
+
backgroundColor: colors.bgActive,
|
|
432
|
+
color: colors.text,
|
|
433
|
+
[hover]: {
|
|
434
|
+
":hover": { backgroundColor: colors.bgActive },
|
|
435
|
+
},
|
|
436
|
+
},
|
|
437
|
+
sendBtn: {
|
|
438
|
+
display: "inline-flex",
|
|
439
|
+
alignItems: "center",
|
|
440
|
+
justifyContent: "center",
|
|
441
|
+
width: 28,
|
|
442
|
+
height: 28,
|
|
443
|
+
borderWidth: 0,
|
|
444
|
+
borderRadius: 999,
|
|
445
|
+
backgroundColor: colors.text,
|
|
446
|
+
color: colors.textInverse,
|
|
447
|
+
cursor: "pointer",
|
|
448
|
+
transitionProperty: "opacity",
|
|
449
|
+
transitionDuration: "120ms",
|
|
450
|
+
":disabled": { opacity: 0.35, cursor: "default" },
|
|
451
|
+
":focus-visible": {
|
|
452
|
+
outlineWidth: 2,
|
|
453
|
+
outlineStyle: "solid",
|
|
454
|
+
outlineColor: colors.focus,
|
|
455
|
+
outlineOffset: 1,
|
|
456
|
+
},
|
|
457
|
+
},
|
|
458
|
+
stopBtn: {
|
|
459
|
+
backgroundColor: colors.danger,
|
|
460
|
+
},
|
|
461
|
+
});
|