opencami 1.0.0
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/LICENSE +22 -0
- package/README.md +111 -0
- package/bin/opencami.js +155 -0
- package/dist/client/apple-touch-icon-180x180.png +0 -0
- package/dist/client/assets/_sessionKey-B-MBYHgD.js +95 -0
- package/dist/client/assets/abap-BdImnpbu.js +1 -0
- package/dist/client/assets/actionscript-3-CfeIJUat.js +1 -0
- package/dist/client/assets/ada-bCR0ucgS.js +1 -0
- package/dist/client/assets/andromeeda-C-Jbm3Hp.js +1 -0
- package/dist/client/assets/angular-html-CU67Zn6k.js +1 -0
- package/dist/client/assets/angular-ts-BwZT4LLn.js +1 -0
- package/dist/client/assets/apache-Pmp26Uib.js +1 -0
- package/dist/client/assets/apex-D8_7TLub.js +1 -0
- package/dist/client/assets/apl-dKokRX4l.js +1 -0
- package/dist/client/assets/applescript-Co6uUVPk.js +1 -0
- package/dist/client/assets/ara-BRHolxvo.js +1 -0
- package/dist/client/assets/asciidoc-Dv7Oe6Be.js +1 -0
- package/dist/client/assets/asm-D_Q5rh1f.js +1 -0
- package/dist/client/assets/astro-CbQHKStN.js +1 -0
- package/dist/client/assets/aurora-x-D-2ljcwZ.js +1 -0
- package/dist/client/assets/awk-DMzUqQB5.js +1 -0
- package/dist/client/assets/ayu-dark-CmMr59Fi.js +1 -0
- package/dist/client/assets/ballerina-BFfxhgS-.js +1 -0
- package/dist/client/assets/bat-BkioyH1T.js +1 -0
- package/dist/client/assets/beancount-k_qm7-4y.js +1 -0
- package/dist/client/assets/berry-uYugtg8r.js +1 -0
- package/dist/client/assets/bibtex-CHM0blh-.js +1 -0
- package/dist/client/assets/bicep-Bmn6On1c.js +1 -0
- package/dist/client/assets/blade-D4QpJJKB.js +1 -0
- package/dist/client/assets/bsl-BO_Y6i37.js +1 -0
- package/dist/client/assets/button-D_9OBT_f.js +1 -0
- package/dist/client/assets/c-BIGW1oBm.js +1 -0
- package/dist/client/assets/c3-VCDPK7BO.js +1 -0
- package/dist/client/assets/cadence-Bv_4Rxtq.js +1 -0
- package/dist/client/assets/cairo-KRGpt6FW.js +1 -0
- package/dist/client/assets/catppuccin-frappe-DFWUc33u.js +1 -0
- package/dist/client/assets/catppuccin-latte-C9dUb6Cb.js +1 -0
- package/dist/client/assets/catppuccin-macchiato-DQyhUUbL.js +1 -0
- package/dist/client/assets/catppuccin-mocha-D87Tk5Gz.js +1 -0
- package/dist/client/assets/clarity-D53aC0YG.js +1 -0
- package/dist/client/assets/clojure-P80f7IUj.js +1 -0
- package/dist/client/assets/cmake-D1j8_8rp.js +1 -0
- package/dist/client/assets/cobol-nwyudZeR.js +1 -0
- package/dist/client/assets/codeowners-Bp6g37R7.js +1 -0
- package/dist/client/assets/codeql-DsOJ9woJ.js +1 -0
- package/dist/client/assets/coffee-Ch7k5sss.js +1 -0
- package/dist/client/assets/common-lisp-Cg-RD9OK.js +1 -0
- package/dist/client/assets/connect-BRasuRbB.js +2 -0
- package/dist/client/assets/coq-DkFqJrB1.js +1 -0
- package/dist/client/assets/cpp-CofmeUqb.js +1 -0
- package/dist/client/assets/crystal-tKQVLTB8.js +1 -0
- package/dist/client/assets/csharp-K5feNrxe.js +1 -0
- package/dist/client/assets/css-DPfMkruS.js +1 -0
- package/dist/client/assets/csv-fuZLfV_i.js +1 -0
- package/dist/client/assets/cue-D82EKSYY.js +1 -0
- package/dist/client/assets/cypher-COkxafJQ.js +1 -0
- package/dist/client/assets/d-85-TOEBH.js +1 -0
- package/dist/client/assets/dark-plus-C3mMm8J8.js +1 -0
- package/dist/client/assets/dart-CF10PKvl.js +1 -0
- package/dist/client/assets/dax-CEL-wOlO.js +1 -0
- package/dist/client/assets/desktop-BmXAJ9_W.js +1 -0
- package/dist/client/assets/diff-D97Zzqfu.js +1 -0
- package/dist/client/assets/docker-BcOcwvcX.js +1 -0
- package/dist/client/assets/dotenv-Da5cRb03.js +1 -0
- package/dist/client/assets/dracula-BzJJZx-M.js +1 -0
- package/dist/client/assets/dracula-soft-BXkSAIEj.js +1 -0
- package/dist/client/assets/dream-maker-BtqSS_iP.js +1 -0
- package/dist/client/assets/edge-BkV0erSs.js +1 -0
- package/dist/client/assets/elixir-CDX3lj18.js +1 -0
- package/dist/client/assets/elm-DbKCFpqz.js +1 -0
- package/dist/client/assets/emacs-lisp-C9XAeP06.js +1 -0
- package/dist/client/assets/erb-BOJIQeun.js +1 -0
- package/dist/client/assets/erlang-DsQrWhSR.js +1 -0
- package/dist/client/assets/everforest-dark-BgDCqdQA.js +1 -0
- package/dist/client/assets/everforest-light-C8M2exoo.js +1 -0
- package/dist/client/assets/fennel-BYunw83y.js +1 -0
- package/dist/client/assets/file-explorer-screen-Daf4rIq9.js +1 -0
- package/dist/client/assets/files-ByeIMLfw.js +2 -0
- package/dist/client/assets/fish-BvzEVeQv.js +1 -0
- package/dist/client/assets/fluent-C4IJs8-o.js +1 -0
- package/dist/client/assets/fortran-fixed-form-CkoXwp7k.js +1 -0
- package/dist/client/assets/fortran-free-form-BxgE0vQu.js +1 -0
- package/dist/client/assets/fsharp-CXgrBDvD.js +1 -0
- package/dist/client/assets/gdresource-B7Tvp0Sc.js +1 -0
- package/dist/client/assets/gdscript-DTMYz4Jt.js +1 -0
- package/dist/client/assets/gdshader-DkwncUOv.js +1 -0
- package/dist/client/assets/genie-D0YGMca9.js +1 -0
- package/dist/client/assets/gherkin-DyxjwDmM.js +1 -0
- package/dist/client/assets/git-commit-F4YmCXRG.js +1 -0
- package/dist/client/assets/git-rebase-r7XF79zn.js +1 -0
- package/dist/client/assets/github-dark-DHJKELXO.js +1 -0
- package/dist/client/assets/github-dark-default-Cuk6v7N8.js +1 -0
- package/dist/client/assets/github-dark-dimmed-DH5Ifo-i.js +1 -0
- package/dist/client/assets/github-dark-high-contrast-E3gJ1_iC.js +1 -0
- package/dist/client/assets/github-light-DAi9KRSo.js +1 -0
- package/dist/client/assets/github-light-default-D7oLnXFd.js +1 -0
- package/dist/client/assets/github-light-high-contrast-BfjtVDDH.js +1 -0
- package/dist/client/assets/gleam-BspZqrRM.js +1 -0
- package/dist/client/assets/glimmer-js-Rg0-pVw9.js +1 -0
- package/dist/client/assets/glimmer-ts-U6CK756n.js +1 -0
- package/dist/client/assets/glsl-DplSGwfg.js +1 -0
- package/dist/client/assets/gn-n2N0HUVH.js +1 -0
- package/dist/client/assets/gnuplot-DdkO51Og.js +1 -0
- package/dist/client/assets/go-Dn2_MT6a.js +1 -0
- package/dist/client/assets/graphql-ChdNCCLP.js +1 -0
- package/dist/client/assets/groovy-gcz8RCvz.js +1 -0
- package/dist/client/assets/gruvbox-dark-hard-CFHQjOhq.js +1 -0
- package/dist/client/assets/gruvbox-dark-medium-GsRaNv29.js +1 -0
- package/dist/client/assets/gruvbox-dark-soft-CVdnzihN.js +1 -0
- package/dist/client/assets/gruvbox-light-hard-CH1njM8p.js +1 -0
- package/dist/client/assets/gruvbox-light-medium-DRw_LuNl.js +1 -0
- package/dist/client/assets/gruvbox-light-soft-hJgmCMqR.js +1 -0
- package/dist/client/assets/hack-CaT9iCJl.js +1 -0
- package/dist/client/assets/haml-B8DHNrY2.js +1 -0
- package/dist/client/assets/handlebars-BL8al0AC.js +1 -0
- package/dist/client/assets/haskell-Df6bDoY_.js +1 -0
- package/dist/client/assets/haxe-CzTSHFRz.js +1 -0
- package/dist/client/assets/hcl-BWvSN4gD.js +1 -0
- package/dist/client/assets/hjson-D5-asLiD.js +1 -0
- package/dist/client/assets/hlsl-D3lLCCz7.js +1 -0
- package/dist/client/assets/houston-DnULxvSX.js +1 -0
- package/dist/client/assets/html-GMplVEZG.js +1 -0
- package/dist/client/assets/html-derivative-BFtXZ54Q.js +1 -0
- package/dist/client/assets/http-jrhK8wxY.js +1 -0
- package/dist/client/assets/hurl-irOxFIW8.js +1 -0
- package/dist/client/assets/hxml-Bvhsp5Yf.js +1 -0
- package/dist/client/assets/hy-DFXneXwc.js +1 -0
- package/dist/client/assets/imba-DGztddWO.js +1 -0
- package/dist/client/assets/index-ByUDBI-n.js +14 -0
- package/dist/client/assets/index-DHGnKfAU.js +1 -0
- package/dist/client/assets/ini-BEwlwnbL.js +1 -0
- package/dist/client/assets/java-CylS5w8V.js +1 -0
- package/dist/client/assets/javascript-wDzz0qaB.js +1 -0
- package/dist/client/assets/jinja-4LBKfQ-Z.js +1 -0
- package/dist/client/assets/jison-wvAkD_A8.js +1 -0
- package/dist/client/assets/json-Cp-IABpG.js +1 -0
- package/dist/client/assets/json5-C9tS-k6U.js +1 -0
- package/dist/client/assets/jsonc-Des-eS-w.js +1 -0
- package/dist/client/assets/jsonl-DcaNXYhu.js +1 -0
- package/dist/client/assets/jsonnet-DFQXde-d.js +1 -0
- package/dist/client/assets/jssm-C2t-YnRu.js +1 -0
- package/dist/client/assets/jsx-g9-lgVsj.js +1 -0
- package/dist/client/assets/julia-CxzCAyBv.js +1 -0
- package/dist/client/assets/kanagawa-dragon-CkXjmgJE.js +1 -0
- package/dist/client/assets/kanagawa-lotus-CfQXZHmo.js +1 -0
- package/dist/client/assets/kanagawa-wave-DWedfzmr.js +1 -0
- package/dist/client/assets/kdl-DV7GczEv.js +1 -0
- package/dist/client/assets/keyboard-shortcuts-dialog-agsWJ36q.js +1 -0
- package/dist/client/assets/kotlin-BdnUsdx6.js +1 -0
- package/dist/client/assets/kusto-DZf3V79B.js +1 -0
- package/dist/client/assets/laserwave-DUszq2jm.js +1 -0
- package/dist/client/assets/latex-B4uzh10-.js +1 -0
- package/dist/client/assets/lean-BZvkOJ9d.js +1 -0
- package/dist/client/assets/less-B1dDrJ26.js +1 -0
- package/dist/client/assets/light-plus-B7mTdjB0.js +1 -0
- package/dist/client/assets/liquid-DYVedYrR.js +1 -0
- package/dist/client/assets/llvm-BtvRca6l.js +1 -0
- package/dist/client/assets/log-2UxHyX5q.js +1 -0
- package/dist/client/assets/logo-BtOb2qkB.js +1 -0
- package/dist/client/assets/lua-BbnMAYS6.js +1 -0
- package/dist/client/assets/luau-C-HG3fhB.js +1 -0
- package/dist/client/assets/main-BAHT5yqU.js +81 -0
- package/dist/client/assets/make-CHLpvVh8.js +1 -0
- package/dist/client/assets/markdown-Cvjx9yec.js +1 -0
- package/dist/client/assets/marko-DZsq8hO1.js +1 -0
- package/dist/client/assets/material-theme-D5KoaKCx.js +1 -0
- package/dist/client/assets/material-theme-darker-BfHTSMKl.js +1 -0
- package/dist/client/assets/material-theme-lighter-B0m2ddpp.js +1 -0
- package/dist/client/assets/material-theme-ocean-CyktbL80.js +1 -0
- package/dist/client/assets/material-theme-palenight-Csfq5Kiy.js +1 -0
- package/dist/client/assets/matlab-D7o27uSR.js +1 -0
- package/dist/client/assets/mdc-DUICxH0z.js +1 -0
- package/dist/client/assets/mdx-Cmh6b_Ma.js +1 -0
- package/dist/client/assets/menu-BhVaz8Ly.js +20 -0
- package/dist/client/assets/mermaid-mWjccvbQ.js +1 -0
- package/dist/client/assets/min-dark-CafNBF8u.js +1 -0
- package/dist/client/assets/min-light-CTRr51gU.js +1 -0
- package/dist/client/assets/mipsasm-CKIfxQSi.js +1 -0
- package/dist/client/assets/mojo-B93PlW-d.js +1 -0
- package/dist/client/assets/monokai-D4h5O-jR.js +1 -0
- package/dist/client/assets/moonbit-Ba13S78F.js +1 -0
- package/dist/client/assets/move-Bu9oaDYs.js +1 -0
- package/dist/client/assets/narrat-DRg8JJMk.js +1 -0
- package/dist/client/assets/new-DLlBm66g.js +1 -0
- package/dist/client/assets/nextflow-BrzmwbiE.js +1 -0
- package/dist/client/assets/nginx-DknmC5AR.js +1 -0
- package/dist/client/assets/night-owl-C39BiMTA.js +1 -0
- package/dist/client/assets/nim-CVrawwO9.js +1 -0
- package/dist/client/assets/nix-CwoSXNpI.js +1 -0
- package/dist/client/assets/nord-Ddv68eIx.js +1 -0
- package/dist/client/assets/nushell-C-sUppwS.js +1 -0
- package/dist/client/assets/objective-c-DXmwc3jG.js +1 -0
- package/dist/client/assets/objective-cpp-CLxacb5B.js +1 -0
- package/dist/client/assets/ocaml-C0hk2d4L.js +1 -0
- package/dist/client/assets/one-dark-pro-DVMEJ2y_.js +1 -0
- package/dist/client/assets/one-light-PoHY5YXO.js +1 -0
- package/dist/client/assets/openscad-C4EeE6gA.js +1 -0
- package/dist/client/assets/pascal-D93ZcfNL.js +1 -0
- package/dist/client/assets/perl-C0TMdlhV.js +1 -0
- package/dist/client/assets/php-CDn_0X-4.js +1 -0
- package/dist/client/assets/pkl-u5AG7uiY.js +1 -0
- package/dist/client/assets/plastic-3e1v2bzS.js +1 -0
- package/dist/client/assets/plsql-ChMvpjG-.js +1 -0
- package/dist/client/assets/po-BTJTHyun.js +1 -0
- package/dist/client/assets/poimandres-CS3Unz2-.js +1 -0
- package/dist/client/assets/polar-C0HS_06l.js +1 -0
- package/dist/client/assets/postcss-CXtECtnM.js +1 -0
- package/dist/client/assets/powerquery-CEu0bR-o.js +1 -0
- package/dist/client/assets/powershell-Dpen1YoG.js +1 -0
- package/dist/client/assets/prisma-Dd19v3D-.js +1 -0
- package/dist/client/assets/prolog-CbFg5uaA.js +1 -0
- package/dist/client/assets/proto-C7zT0LnQ.js +1 -0
- package/dist/client/assets/pug-CGlum2m_.js +1 -0
- package/dist/client/assets/puppet-BMWR74SV.js +1 -0
- package/dist/client/assets/purescript-CklMAg4u.js +1 -0
- package/dist/client/assets/python-B6aJPvgy.js +1 -0
- package/dist/client/assets/qml-3beO22l8.js +1 -0
- package/dist/client/assets/qmldir-C8lEn-DE.js +1 -0
- package/dist/client/assets/qss-IeuSbFQv.js +1 -0
- package/dist/client/assets/r-Dspwwk_N.js +1 -0
- package/dist/client/assets/racket-BqYA7rlc.js +1 -0
- package/dist/client/assets/raku-DXvB9xmW.js +1 -0
- package/dist/client/assets/razor-C1TweQQi.js +1 -0
- package/dist/client/assets/red-bN70gL4F.js +1 -0
- package/dist/client/assets/reg-C-SQnVFl.js +1 -0
- package/dist/client/assets/regexp-CDVJQ6XC.js +1 -0
- package/dist/client/assets/rel-C3B-1QV4.js +1 -0
- package/dist/client/assets/riscv-BM1_JUlF.js +1 -0
- package/dist/client/assets/rose-pine-dawn-DHQR4-dF.js +1 -0
- package/dist/client/assets/rose-pine-moon-D4_iv3hh.js +1 -0
- package/dist/client/assets/rose-pine-qdsjHGoJ.js +1 -0
- package/dist/client/assets/rosmsg-BJDFO7_C.js +1 -0
- package/dist/client/assets/rst-B0xPkSld.js +1 -0
- package/dist/client/assets/ruby-BvKwtOVI.js +1 -0
- package/dist/client/assets/rust-B1yitclQ.js +1 -0
- package/dist/client/assets/sas-cz2c8ADy.js +1 -0
- package/dist/client/assets/sass-Cj5Yp3dK.js +1 -0
- package/dist/client/assets/scala-C151Ov-r.js +1 -0
- package/dist/client/assets/scheme-C98Dy4si.js +1 -0
- package/dist/client/assets/scss-OYdSNvt2.js +1 -0
- package/dist/client/assets/sdbl-DVxCFoDh.js +1 -0
- package/dist/client/assets/search-dialog-CHwnOyPS.js +1 -0
- package/dist/client/assets/session-export-dialog-uOlDUzgX.js +1 -0
- package/dist/client/assets/settings-dialog-D0aYDkAM.js +1 -0
- package/dist/client/assets/shaderlab-Dg9Lc6iA.js +1 -0
- package/dist/client/assets/shellscript-Yzrsuije.js +1 -0
- package/dist/client/assets/shellsession-BADoaaVG.js +1 -0
- package/dist/client/assets/slack-dark-BthQWCQV.js +1 -0
- package/dist/client/assets/slack-ochin-DqwNpetd.js +1 -0
- package/dist/client/assets/smalltalk-BERRCDM3.js +1 -0
- package/dist/client/assets/snazzy-light-Bw305WKR.js +1 -0
- package/dist/client/assets/solarized-dark-DXbdFlpD.js +1 -0
- package/dist/client/assets/solarized-light-L9t79GZl.js +1 -0
- package/dist/client/assets/solidity-rGO070M0.js +1 -0
- package/dist/client/assets/soy-Brmx7dQM.js +1 -0
- package/dist/client/assets/sparql-rVzFXLq3.js +1 -0
- package/dist/client/assets/splunk-BtCnVYZw.js +1 -0
- package/dist/client/assets/sql-BLtJtn59.js +1 -0
- package/dist/client/assets/ssh-config-_ykCGR6B.js +1 -0
- package/dist/client/assets/stata-BH5u7GGu.js +1 -0
- package/dist/client/assets/styles-7aVSlb6l.css +1 -0
- package/dist/client/assets/stylus-BEDo0Tqx.js +1 -0
- package/dist/client/assets/svelte-zxCyuUbr.js +1 -0
- package/dist/client/assets/swift-Dg5xB15N.js +1 -0
- package/dist/client/assets/synthwave-84-CbfX1IO0.js +1 -0
- package/dist/client/assets/system-verilog-CnnmHF94.js +1 -0
- package/dist/client/assets/systemd-4A_iFExJ.js +1 -0
- package/dist/client/assets/talonscript-CkByrt1z.js +1 -0
- package/dist/client/assets/tasl-QIJgUcNo.js +1 -0
- package/dist/client/assets/tcl-dwOrl1Do.js +1 -0
- package/dist/client/assets/templ-W15q3VgB.js +1 -0
- package/dist/client/assets/terraform-BETggiCN.js +1 -0
- package/dist/client/assets/tex-CvyZ59Mk.js +1 -0
- package/dist/client/assets/tokyo-night-hegEt444.js +1 -0
- package/dist/client/assets/toml-vGWfd6FD.js +1 -0
- package/dist/client/assets/ts-tags-zn1MmPIZ.js +1 -0
- package/dist/client/assets/tsv-B_m7g4N7.js +1 -0
- package/dist/client/assets/tsx-COt5Ahok.js +1 -0
- package/dist/client/assets/turtle-BsS91CYL.js +1 -0
- package/dist/client/assets/twig-CO9l9SDP.js +1 -0
- package/dist/client/assets/typescript-BPQ3VLAy.js +1 -0
- package/dist/client/assets/typespec-BGHnOYBU.js +1 -0
- package/dist/client/assets/typst-DHCkPAjA.js +1 -0
- package/dist/client/assets/v-BcVCzyr7.js +1 -0
- package/dist/client/assets/vala-CsfeWuGM.js +1 -0
- package/dist/client/assets/vb-D17OF-Vu.js +1 -0
- package/dist/client/assets/verilog-BQ8w6xss.js +1 -0
- package/dist/client/assets/vesper-DU1UobuO.js +1 -0
- package/dist/client/assets/vhdl-CeAyd5Ju.js +1 -0
- package/dist/client/assets/viml-CJc9bBzg.js +1 -0
- package/dist/client/assets/vitesse-black-Bkuqu6BP.js +1 -0
- package/dist/client/assets/vitesse-dark-D0r3Knsf.js +1 -0
- package/dist/client/assets/vitesse-light-CVO1_9PV.js +1 -0
- package/dist/client/assets/vue-DN_0RTcg.js +1 -0
- package/dist/client/assets/vue-html-AaS7Mt5G.js +1 -0
- package/dist/client/assets/vue-vine-CQOfvN7w.js +1 -0
- package/dist/client/assets/vyper-CDx5xZoG.js +1 -0
- package/dist/client/assets/wasm-CG6Dc4jp.js +1 -0
- package/dist/client/assets/wasm-MzD3tlZU.js +1 -0
- package/dist/client/assets/wenyan-BV7otONQ.js +1 -0
- package/dist/client/assets/wgsl-Dx-B1_4e.js +1 -0
- package/dist/client/assets/wikitext-BhOHFoWU.js +1 -0
- package/dist/client/assets/wit-5i3qLPDT.js +1 -0
- package/dist/client/assets/wolfram-lXgVvXCa.js +1 -0
- package/dist/client/assets/xml-sdJ4AIDG.js +1 -0
- package/dist/client/assets/xsl-CtQFsRM5.js +1 -0
- package/dist/client/assets/yaml-Buea-lGh.js +1 -0
- package/dist/client/assets/zenscript-DVFEvuxE.js +1 -0
- package/dist/client/assets/zig-VOosw3JB.js +1 -0
- package/dist/client/cover.jpg +0 -0
- package/dist/client/cover.webp +0 -0
- package/dist/client/favicon.svg +4 -0
- package/dist/client/manifest.json +40 -0
- package/dist/client/pwa-192x192.png +0 -0
- package/dist/client/pwa-512x512.png +0 -0
- package/dist/client/pwa-maskable-512x512.png +0 -0
- package/dist/client/robots.txt +3 -0
- package/dist/client/screenshot-file-explorer.png +0 -0
- package/dist/client/sw.js +165 -0
- package/dist/server/assets/_sessionKey-qlAPF_Ft.js +6130 -0
- package/dist/server/assets/_tanstack-start-manifest_v-El8F-kd-.js +4 -0
- package/dist/server/assets/button-DtQ3rV1m.js +53 -0
- package/dist/server/assets/connect-BWI_6rCm.js +80 -0
- package/dist/server/assets/file-explorer-screen-DJXPEG_J.js +2450 -0
- package/dist/server/assets/files-CONoVTGD.js +11 -0
- package/dist/server/assets/index-Bp8QskbI.js +28 -0
- package/dist/server/assets/index-COu2idHm.js +226 -0
- package/dist/server/assets/keyboard-shortcuts-dialog-D5hqVX2v.js +69 -0
- package/dist/server/assets/menu-D6n4DB0U.js +156 -0
- package/dist/server/assets/new-Dzk5YxE9.js +6 -0
- package/dist/server/assets/router-DbxyvprK.js +2749 -0
- package/dist/server/assets/search-dialog-JY8C3mqa.js +443 -0
- package/dist/server/assets/session-export-dialog-D87uafPD.js +80 -0
- package/dist/server/assets/settings-dialog-CBj7njLM.js +568 -0
- package/dist/server/assets/start-HYkvq4Ni.js +4 -0
- package/dist/server/server.js +1013 -0
- package/package.json +93 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as e,r as t,L as se,u as L}from"./main-BAHT5yqU.js";import{L as F,N as $,O as A,P as B,Q as W,R as O,M as be,H as ve,I as ye,J as ae,S as ie,K as R,D as Q,a as V,b as _,c as H,d as G,U as je,V as we,W as ne}from"./menu-BhVaz8Ly.js";import{o as Ne,s as ke,c as f,i as te,B as D,H as y,I as Ce,t as De,j as Se,l as Fe,v as Ee,n as ze,y as Me,z as re,m as le,F as ce,C as Te,E as Le,G as Re,U as Pe,J as Ue,K as de,P as ue,L as Ke,M as Ie,N as $e,O as Ae,R as Be,Y as We,S as ee,Z as Oe,V as qe}from"./button-D_9OBT_f.js";function Qe({className:s}){return e.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"80",height:"80",viewBox:"0 0 80 80",fill:"none",className:s,children:[e.jsx("rect",{width:"80",height:"80",fill:"currentColor",className:"text-transparent"}),e.jsx("path",{d:"M61.9624 45.5729C62.5862 44.3371 63.0907 43.3377 63.4782 41.9826C69.8221 28.8286 70.5847 14.0975 67.1723 4.32469C65.8317 0.249835 62.7688 0.254311 62.6374 3.58605C61.355 12.189 58.9061 17.6275 57.1756 21.0554C52.8087 29.7058 45.9949 37.7278 39.3706 42.7305C28.6217 50.8021 25.0716 44.614 24.3711 37.8823C23.8822 32.1203 24.7206 25.5721 26.24 18.2889C27.102 15.3261 24.3944 13.9592 22.5223 16.4122C20.4062 19.3487 18.5586 22.4209 17.1838 25.7318C12.9928 33.4462 10.3896 45.3332 11.4505 57.6273C12.2296 63.5357 13.1688 68.4057 14.1079 73.2757C15.2695 79.0941 19.1598 79.5073 24.3117 78.0088C39.7921 74.0789 54.143 58.872 59.7093 49.1011C60.7255 48.0229 61.3494 46.7872 61.9624 45.5729Z",fill:"currentColor",className:"text-primary-950"})]})}const P=Ne((s,i)=>({currentPath:"/",viewMode:"list",sortBy:"name",sortAsc:!0,selectedFiles:new Set,navigateTo:a=>{s({currentPath:a,selectedFiles:new Set})},setViewMode:a=>{s({viewMode:a})},setSortBy:a=>{const n=i().sortBy;s({sortBy:a,sortAsc:n===a?!i().sortAsc:!0})},toggleSort:()=>{s(a=>({sortAsc:!a.sortAsc}))},selectFile:a=>{s(n=>{const l=new Set(n.selectedFiles);return l.add(a),{selectedFiles:l}})},deselectFile:a=>{s(n=>{const l=new Set(n.selectedFiles);return l.delete(a),{selectedFiles:l}})},clearSelection:()=>{s({selectedFiles:new Set})},toggleFileSelection:a=>{const{selectedFiles:n,selectFile:l,deselectFile:c}=i();n.has(a)?c(a):l(a)}}));function Ve(){return t.useMemo(()=>typeof window>"u"?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches,[])}function _e({isCollapsed:s,onToggleCollapse:i,onSelectAction:a}){const{navigateTo:n,currentPath:l}=P(),c=Ve(),r=t.useMemo(()=>({duration:c?0:.15,ease:s?"easeIn":"easeOut"}),[s,c]),o=t.useCallback(d=>{n(d)},[n]),p=t.useCallback((d,k)=>{(d.key==="Enter"||d.key===" ")&&(d.preventDefault(),k())},[]),w=t.useMemo(()=>[{path:"/",icon:ke,label:"Home",id:"home"}],[]),v=t.useMemo(()=>({className:"border-r border-primary-200 h-full overflow-hidden bg-primary-100 flex flex-col"}),[]),h=48,u=300;return e.jsxs(F.aside,{initial:!1,animate:{width:c?s?h:u:void 0},style:{width:c?void 0:s?h:u},transition:r,className:v.className,role:"navigation","aria-label":"File explorer navigation",children:[e.jsxs(F.div,{layout:!0,transition:{layout:r},className:f("flex items-center h-12 px-2 justify-between"),children:[e.jsx($,{initial:!1,children:s?null:e.jsx(F.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:r,children:e.jsxs(se,{to:"/new",className:f(te({variant:"ghost",size:"sm"}),"w-full pl-1.5 justify-start","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),children:[e.jsx(Qe,{className:"size-5 rounded-sm","aria-hidden":"true"}),e.jsx("span",{children:"WebClaw"})]})})}),e.jsx(A,{children:e.jsxs(B,{children:[e.jsx(W,{onClick:i,onKeyDown:d=>p(d,i),render:e.jsx(D,{size:"icon-sm",variant:"ghost","aria-label":s?"Expand sidebar":"Collapse sidebar",className:f("focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),children:e.jsx(y,{icon:Ce,size:20,strokeWidth:1.5,"aria-hidden":"true"})})}),e.jsx(O,{side:"right",children:s?"Expand sidebar":"Collapse sidebar"})]})})]}),e.jsx("div",{className:"px-2 mb-4",children:e.jsx(F.div,{layout:!0,transition:{layout:r},className:"w-full",children:e.jsx(A,{children:e.jsxs(B,{children:[e.jsx(W,{asChild:!0,children:e.jsxs(se,{to:"/chat/main",className:f(te({variant:"ghost",size:"sm"}),"w-full pl-1.5 justify-start","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),onClick:a,children:[e.jsx(y,{icon:De,size:20,strokeWidth:1.5,className:"min-w-5","aria-hidden":"true"}),e.jsx($,{initial:!1,mode:"wait",children:s?null:e.jsx(F.span,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:r,className:"overflow-hidden whitespace-nowrap",children:"Back to Chat"})})]})}),s?e.jsx(O,{side:"right",children:"Back to Chat"}):null]})})})}),e.jsx("div",{className:"flex-1 min-h-0 relative overflow-hidden",children:e.jsx($,{initial:!1,children:s?e.jsx(F.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:r,className:"px-2 space-y-1",children:w.map(d=>e.jsx(A,{children:e.jsxs(B,{children:[e.jsx(W,{onClick:()=>o(d.path),onKeyDown:k=>p(k,()=>o(d.path)),render:e.jsx(D,{size:"icon-sm",variant:"ghost","aria-current":l===d.path?"page":void 0,"aria-label":`Navigate to ${d.label}`,className:f("w-full text-primary-600 hover:text-primary-900","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",l===d.path&&"bg-primary-200 text-primary-900"),children:e.jsx(y,{icon:d.icon,size:20,strokeWidth:1.5,"aria-hidden":"true"})})}),e.jsx(O,{side:"right",children:d.label})]})},d.id))},"collapsed-content"):e.jsx(F.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:r,className:"absolute inset-0 pt-0 flex flex-col w-[300px] min-h-0",children:e.jsxs("div",{className:"flex-1 min-h-0 px-2",children:[e.jsx("div",{className:"mb-4",children:e.jsx("h2",{className:"text-sm font-medium text-primary-700 mb-3 px-1.5",children:"Quick Access"})}),e.jsx("nav",{className:"space-y-1",role:"list","aria-label":"Quick access folders",children:w.map(d=>e.jsx("div",{role:"listitem",children:e.jsxs(D,{variant:"ghost",size:"sm",onClick:()=>o(d.path),onKeyDown:k=>p(k,()=>o(d.path)),"aria-current":l===d.path?"page":void 0,className:f("w-full pl-1.5 justify-start text-primary-600 hover:text-primary-900","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",l===d.path&&"bg-primary-200 text-primary-900 font-medium"),"aria-label":`Navigate to ${d.label}`,children:[e.jsx(y,{icon:d.icon,size:20,strokeWidth:1.5,className:"min-w-5","aria-hidden":"true"}),e.jsx("span",{className:"overflow-hidden whitespace-nowrap min-w-0 truncate",children:d.label})]})},d.id))})]})},"content")})}),e.jsx("div",{className:"px-2 py-3 border-t border-primary-200 bg-primary-100",children:e.jsx(F.div,{layout:!0,transition:{layout:r},className:"w-full",children:e.jsx(A,{children:e.jsxs(B,{children:[e.jsx(W,{asChild:!0,children:e.jsxs(D,{variant:"ghost",size:s?"icon-sm":"sm",className:f(s?"w-full":"w-full justify-start pl-1.5","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),"aria-label":"Settings",children:[e.jsx(y,{icon:Se,size:20,strokeWidth:1.5,className:"min-w-5","aria-hidden":"true"}),e.jsx($,{initial:!1,mode:"wait",children:s?null:e.jsx(F.span,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:r,className:"overflow-hidden whitespace-nowrap",children:"Settings"})})]})}),s?e.jsx(O,{side:"right",children:"Settings"}):null]})})})})]})}function He(s,i){return s.isCollapsed===i.isCollapsed}const Ge=t.memo(_e,He);function Je({path:s}){const{navigateTo:i}=P(),a=s==="/"?[]:s.split("/").filter(Boolean),n=[{name:"Home",path:"/"},...a.map((r,o)=>({name:r,path:"/"+a.slice(0,o+1).join("/")}))],l=t.useCallback(r=>{i(r)},[i]),c=t.useCallback((r,o)=>{(r.key==="Enter"||r.key===" ")&&(r.preventDefault(),i(o))},[i]);return e.jsx("nav",{"aria-label":"File navigation",className:"text-sm text-primary-600",children:e.jsx("ol",{className:"flex items-center gap-1",children:n.map((r,o)=>e.jsxs("li",{className:"flex items-center gap-1",children:[o>0?e.jsx(y,{icon:Fe,size:16,strokeWidth:1.5,className:"text-primary-400","aria-hidden":"true"}):null,e.jsxs("button",{type:"button",onClick:()=>l(r.path),onKeyDown:p=>c(p,r.path),"aria-current":o===n.length-1?"page":void 0,className:f("flex items-center gap-1.5 rounded-md px-2 py-1","transition-colors duration-150 ease-out","hover:bg-primary-100 hover:text-primary-900","focus-visible:bg-primary-100 focus-visible:text-primary-900","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",o===n.length-1?"text-primary-900 font-medium":"text-primary-600"),children:[o===0?e.jsx(y,{icon:Ee,size:16,strokeWidth:1.5,"aria-hidden":"true"}):null,e.jsx("span",{className:"whitespace-nowrap",children:r.name})]})]},r.path))})})}const Z=[{label:"Name",value:"name"},{label:"Size",value:"size"},{label:"Modified",value:"modified"}];function Xe({onUpload:s,onCreateFolder:i}){const{viewMode:a,sortBy:n,sortAsc:l,setViewMode:c,setSortBy:r,toggleSort:o}=P(),p=t.useCallback(()=>{c("list")},[c]),w=t.useCallback(()=>{c("grid")},[c]),v=t.useCallback(u=>{r(u)},[r]),h=t.useCallback((u,d)=>{(u.key==="Enter"||u.key===" ")&&(u.preventDefault(),d())},[]);return e.jsxs("div",{className:"flex items-center justify-between gap-4",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("div",{className:"flex items-center border border-primary-200 rounded-lg overflow-hidden",role:"group","aria-label":"View mode",children:[e.jsx(D,{size:"sm",variant:a==="list"?"default":"ghost",onClick:p,onKeyDown:u=>h(u,p),"aria-label":"Switch to list view","aria-pressed":a==="list",className:f("rounded-none border-0","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),children:e.jsx(y,{icon:ze,size:18,strokeWidth:1.5,"aria-hidden":"true"})}),e.jsx(D,{size:"sm",variant:a==="grid"?"default":"ghost",onClick:w,onKeyDown:u=>h(u,w),"aria-label":"Switch to grid view","aria-pressed":a==="grid",className:f("rounded-none border-0 border-l border-primary-200","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),children:e.jsx(y,{icon:Me,size:18,strokeWidth:1.5,"aria-hidden":"true"})})]}),e.jsxs(be,{children:[e.jsx(ve,{render:e.jsxs(D,{variant:"ghost",size:"sm",className:f("gap-1","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),"aria-label":`Sort by ${Z.find(u=>u.value===n)?.label}, ${l?"ascending":"descending"}`,children:[e.jsxs("span",{children:["Sort: ",Z.find(u=>u.value===n)?.label]}),e.jsx(y,{icon:l?re:le,size:16,strokeWidth:1.5,"aria-hidden":"true"})]})}),e.jsxs(ye,{side:"bottom",align:"start",children:[Z.map(u=>e.jsx(ae,{onClick:()=>v(u.value),className:f(n===u.value&&"bg-primary-100 text-primary-900","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none"),"aria-current":n===u.value?"true":"false",children:u.label},u.value)),e.jsxs(ae,{onClick:o,className:"focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none",children:[e.jsx(y,{icon:l?le:re,size:16,strokeWidth:1.5,"aria-hidden":"true"}),l?"Sort Descending":"Sort Ascending"]})]})]})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs(D,{variant:"ghost",size:"sm",onClick:s,onKeyDown:u=>h(u,s),className:f("gap-2","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),"aria-label":"Upload files",children:[e.jsx(y,{icon:ce,size:18,strokeWidth:1.5,"aria-hidden":"true"}),e.jsx("span",{children:"Upload"})]}),e.jsxs(D,{variant:"ghost",size:"sm",onClick:i,onKeyDown:u=>h(u,i),className:f("gap-2","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),"aria-label":"Create new folder",children:[e.jsx(y,{icon:Te,size:18,strokeWidth:1.5,"aria-hidden":"true"}),e.jsx("span",{children:"New Folder"})]})]})]})}const E={all:["files"],listing:s=>["files","listing",s],content:s=>["files","content",s]};function Ye(s){return ie({queryKey:E.content(s||""),queryFn:async()=>{const i=await fetch(`/api/files/read?path=${encodeURIComponent(s)}`);if(!i.ok){const a=await i.json().catch(()=>({error:"Failed to read file"}));throw new Error(a.error||"Failed to read file")}return i.json()},enabled:!!s,staleTime:30*1e3,gcTime:300*1e3})}function Ze(){const s=L();return R({mutationFn:async({path:i,content:a})=>{const n=await fetch("/api/files/save",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({path:i,content:a})});if(!n.ok){const l=await n.json().catch(()=>({error:"Failed to save file"}));throw new Error(l.error||"Failed to save file")}return n.json()},onSuccess:(i,a)=>{s.invalidateQueries({queryKey:E.content(a.path)});const n=a.path.split("/").slice(0,-1).join("/")||"/";s.invalidateQueries({queryKey:E.listing(n)})}})}function ei(s){return ie({queryKey:E.listing(s),queryFn:async()=>{const i=await fetch(`/api/files/list?path=${encodeURIComponent(s)}`);if(!i.ok){const a=await i.text();throw new Error(`Failed to load files: ${a}`)}return i.json()},staleTime:300*1e3,gcTime:600*1e3,retry:3,onError:i=>{console.error("Failed to load file listing:",i)}})}function ii(){const s=new Set;return t.useEffect(()=>()=>{s.forEach(i=>URL.revokeObjectURL(i)),s.clear()},[]),R({mutationFn:async i=>{const a=await fetch(`/api/files/download?path=${encodeURIComponent(i)}`);if(!a.ok){const o=await a.text();throw new Error(`Download failed: ${o}`)}const n=await a.blob(),l=window.URL.createObjectURL(n);s.add(l);const c=i.split("/").pop()||"download",r=document.createElement("a");r.href=l,r.download=c,document.body.appendChild(r),r.click(),document.body.removeChild(r),setTimeout(()=>{s.has(l)&&(URL.revokeObjectURL(l),s.delete(l))},100)},onError:i=>{console.error("Download failed:",i)}})}function si(){const s=L();return R({mutationFn:async({files:i,path:a})=>{const n=[];for(let l=0;l<i.length;l++){const c=new FormData;c.append("path",a),c.append("file",i[l]);const r=await fetch("/api/files/upload",{method:"POST",body:c});if(!r.ok){const o=await r.text();throw new Error(`Upload failed for ${i[l].name}: ${o}`)}n.push(await r.json())}return n},onSuccess:(i,a)=>{s.invalidateQueries({queryKey:E.listing(a.path)})},onError:i=>{console.error("Upload failed:",i)}})}function ai(){const s=L();return R({mutationFn:async i=>{const a=await fetch(`/api/files/delete?path=${encodeURIComponent(i)}`,{method:"DELETE"});if(!a.ok){const n=await a.text();throw new Error(`Delete failed: ${n}`)}return a.json()},onSuccess:(i,a)=>{const n=a.split("/").slice(0,-1).join("/")||"/";s.invalidateQueries({queryKey:E.listing(n)})},onError:i=>{console.error("Delete failed:",i)}})}function ni(){const s=L();return R({mutationFn:async({path:i,name:a})=>{const n=await fetch("/api/files/mkdir",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({path:`${i}/${a}`})});if(!n.ok){const l=await n.text();throw new Error(`Create folder failed: ${l}`)}return n.json()},onSuccess:(i,a)=>{s.invalidateQueries({queryKey:E.listing(a.path)})},onError:i=>{console.error("Create folder failed:",i)}})}function ti(){const s=L();return R({mutationFn:async({oldPath:i,newName:a})=>{const l=`${i.split("/").slice(0,-1).join("/")}/${a}`,c=await fetch("/api/files/rename",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({src:i,dst:l})});if(!c.ok){const r=await c.text();throw new Error(`Rename failed: ${r}`)}return c.json()},onSuccess:(i,a)=>{const n=a.oldPath.split("/").slice(0,-1).join("/")||"/";s.invalidateQueries({queryKey:E.listing(n)})},onError:i=>{console.error("Rename failed:",i)}})}const ri=new Set(["txt","md","log","json","xml","yaml","yml","csv","ini","conf","cfg","js","ts","jsx","tsx","py","java","cpp","c","h","css","html","htm","php","rb","go","rs","sh","bash","zsh","toml","env","gitignore","dockerfile","makefile","sql","graphql","svelte","vue","scss","less"]);function me({item:s,children:i,onOpenFile:a}){const[n,l]=t.useState(!1),[c,r]=t.useState({x:0,y:0}),[o,p]=t.useState(!1),[w,v]=t.useState(!1),[h,u]=t.useState(s.name),[d,k]=t.useState(""),N=t.useRef(null),{navigateTo:j}=P(),m=ii(),x=ai(),C=ti(),z=t.useCallback(b=>{switch(b){case"open":s.isDir&&j(s.path);break;case"edit":a&&a(s.path);break;case"download":s.isDir||m.mutate(s.path);break;case"rename":u(s.name),k(""),p(!0);break;case"delete":v(!0);break}},[s,m,j]),X=t.useCallback(b=>{b.preventDefault(),b.stopPropagation(),r({x:b.clientX,y:b.clientY}),l(!0)},[]),U=t.useCallback(async()=>{if(!h||h===s.name){p(!1);return}k("");try{await C.mutateAsync({oldPath:s.path,newName:h.trim()}),p(!1)}catch(b){const T=b instanceof Error?b.message:"Failed to rename";k(T)}},[h,s,C]),K=t.useCallback(async()=>{try{await x.mutateAsync(s.path),v(!1)}catch(b){console.error("Delete failed:",b)}},[s.path,x]),Y=t.useCallback(b=>{b.key==="Enter"?(b.preventDefault(),U()):b.key==="Escape"&&(b.preventDefault(),p(!1))},[U]),g=t.useCallback(b=>{u(b.target.value),d&&k("")},[d]);t.useEffect(()=>{if(o&&N.current){const b=N.current;if(b.focus(),!s.isDir&&s.extension){const T=s.name.replace(new RegExp(`\\.${s.extension}$`),"");b.setSelectionRange(0,T.length)}else b.select()}},[o,s]);const S=h.trim().length>0&&!/[<>:"/\\|?*]/.test(h)&&!h.includes("..")&&h!==s.name,M=()=>m.isPending?"Downloading…":"Download",he=()=>C.isPending?"Renaming…":"Rename",fe=()=>x.isPending?"Deleting…":"Delete";t.useEffect(()=>{if(!n)return;const b=()=>l(!1),T=ge=>{ge.key==="Escape"&&l(!1)},xe=setTimeout(()=>{document.addEventListener("click",b),document.addEventListener("contextmenu",b),document.addEventListener("keydown",T)},0);return()=>{clearTimeout(xe),document.removeEventListener("click",b),document.removeEventListener("contextmenu",b),document.removeEventListener("keydown",T)}},[n]);const I=t.useCallback(b=>{l(!1),z(b)},[z]);return e.jsxs(e.Fragment,{children:[e.jsx("div",{onContextMenu:X,children:i}),n?e.jsx("div",{className:"fixed inset-0 z-50","aria-modal":"true",role:"dialog",children:e.jsxs("div",{className:"fixed min-w-[140px] rounded-lg bg-primary-50 p-1 text-sm text-primary-900 shadow-lg outline outline-primary-900/10 z-50",style:{left:c.x,top:c.y},role:"menu",onClick:b=>b.stopPropagation(),children:[s.isDir?e.jsxs("button",{type:"button",role:"menuitem",onClick:()=>I("open"),className:f("flex w-full items-center gap-2 rounded-md px-2 py-1.5 text-sm text-primary-900","hover:bg-primary-100 select-none font-[450]","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none"),children:[e.jsx(y,{icon:Le,size:16,strokeWidth:1.5,"aria-hidden":"true"}),"Open"]}):null,s.isDir?null:e.jsxs("button",{type:"button",role:"menuitem",onClick:()=>I("download"),disabled:m.isPending,className:f("flex w-full items-center gap-2 rounded-md px-2 py-1.5 text-sm text-primary-900","hover:bg-primary-100 select-none font-[450]","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none"),children:[e.jsx(y,{icon:Re,size:16,strokeWidth:1.5,"aria-hidden":"true"}),M()]}),!s.isDir&&ri.has(s.extension.toLowerCase())?e.jsxs("button",{type:"button",role:"menuitem",onClick:()=>I("edit"),className:f("flex w-full items-center gap-2 rounded-md px-2 py-1.5 text-sm text-primary-900","hover:bg-primary-100 select-none font-[450]","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none"),children:[e.jsx(y,{icon:Pe,size:16,strokeWidth:1.5,"aria-hidden":"true"}),"Edit"]}):null,e.jsxs("button",{type:"button",role:"menuitem",onClick:()=>I("rename"),className:f("flex w-full items-center gap-2 rounded-md px-2 py-1.5 text-sm text-primary-900","hover:bg-primary-100 select-none font-[450]","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none"),children:[e.jsx(y,{icon:Ue,size:16,strokeWidth:1.5,"aria-hidden":"true"}),"Rename"]}),e.jsxs("button",{type:"button",role:"menuitem",onClick:()=>I("delete"),className:f("flex w-full items-center gap-2 rounded-md px-2 py-1.5 text-sm","text-red-600 hover:bg-red-50 select-none font-[450]","focus-visible:ring-2 focus-visible:ring-red-300 focus-visible:outline-none"),children:[e.jsx(y,{icon:de,size:16,strokeWidth:1.5,"aria-hidden":"true"}),"Delete"]})]})}):null,e.jsx(Q,{open:o,onOpenChange:p,children:e.jsx(V,{children:e.jsxs("div",{className:"p-6",children:[e.jsxs(_,{className:"mb-2",children:["Rename ",s.isDir?"Folder":"File"]}),e.jsxs(H,{className:"mb-4",children:['Enter a new name for "',s.name,'"']}),e.jsxs("div",{className:"mb-6",children:[e.jsxs("label",{htmlFor:"rename-input",className:"block text-sm font-medium text-primary-900 mb-2",children:[s.isDir?"Folder":"File"," Name"]}),e.jsx("input",{id:"rename-input",ref:N,type:"text",value:h,onChange:g,onKeyDown:Y,autoFocus:!0,spellCheck:!1,"aria-describedby":d?"rename-error":void 0,"aria-invalid":d?"true":"false",className:f("w-full px-3 py-2 border rounded-lg","transition-colors duration-150 ease-out","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",d?"border-red-300 focus-visible:ring-red-300":"border-primary-200 focus:border-primary-300")}),d?e.jsx("p",{id:"rename-error",className:"text-sm text-red-600 mt-1",role:"alert","aria-live":"polite",children:d}):null]}),C.isPending?e.jsx("div",{className:"mb-4 p-3 bg-primary-50 rounded-lg","aria-live":"polite",children:e.jsx("p",{className:"text-sm text-primary-600",children:"Renaming…"})}):null,e.jsxs("div",{className:"flex justify-end gap-2",children:[e.jsx(G,{disabled:C.isPending,className:f("focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),children:"Cancel"}),e.jsx(D,{onClick:U,disabled:!S||C.isPending,className:f("focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",(!S||C.isPending)&&"opacity-50 cursor-not-allowed"),children:he()})]})]})})}),e.jsx(Q,{open:w,onOpenChange:v,children:e.jsx(V,{children:e.jsxs("div",{className:"p-6",children:[e.jsxs(_,{className:"mb-2",children:["Delete ",s.isDir?"Folder":"File"]}),e.jsxs(H,{className:"mb-4",children:['Are you sure you want to delete "',s.name,'"?',s.isDir?" This will delete the folder and all its contents.":""," ","This action cannot be undone."]}),x.isPending?e.jsx("div",{className:"mb-4 p-3 bg-red-50 rounded-lg","aria-live":"polite",children:e.jsx("p",{className:"text-sm text-red-700",children:"Deleting…"})}):null,e.jsxs("div",{className:"flex justify-end gap-2",children:[e.jsx(G,{disabled:x.isPending,className:f("focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),children:"Cancel"}),e.jsx(D,{variant:"destructive",onClick:K,disabled:x.isPending,className:f("focus-visible:ring-2 focus-visible:ring-red-300 focus-visible:outline-none","touch-manipulation",x.isPending&&"opacity-50 cursor-not-allowed"),children:fe()})]})]})})})]})}const li=new Set(["txt","md","log","json","xml","yaml","yml","csv","ini","conf","cfg","js","ts","jsx","tsx","py","java","cpp","c","h","css","html","htm","php","rb","go","rs","sh","bash","zsh","toml","env","gitignore","dockerfile","makefile","sql","graphql","svelte","vue","scss","less"]);function J(s){if(s===0)return"0 B";const i=1024,a=["B","KB","MB","GB","TB"],n=Math.floor(Math.log(s)/Math.log(i));return parseFloat((s/Math.pow(i,n)).toFixed(1))+" "+a[n]}function q(s){const i=new Date(s),n=new Date().getTime()-i.getTime(),l=Math.floor(n/1e3),c=Math.floor(l/60),r=Math.floor(c/60),o=Math.floor(r/24);return o>7?i.toLocaleDateString():o>0?o===1?"yesterday":`${o} days ago`:r>0?r===1?"1 hour ago":`${r} hours ago`:c>0?c===1?"1 minute ago":`${c} minutes ago`:"just now"}function pe(s){if(s.isDir)return ue;const i=s.extension.toLowerCase();return["jpg","jpeg","png","gif","webp","svg","bmp"].includes(i)?Ke:["mp4","avi","mkv","mov","wmv","flv","webm"].includes(i)?Ie:["mp3","wav","flac","aac","ogg","m4a"].includes(i)?$e:["zip","rar","7z","tar","gz","bz2"].includes(i)?Ae:["txt","md","log","json","xml","yaml","yml"].includes(i)?Be:["js","ts","jsx","tsx","py","java","cpp","c","h","css","html","php","rb","go","rs"].includes(i)?We:ee}function oi(s,i,a){return t.useMemo(()=>[...s].sort((l,c)=>{if(l.isDir&&!c.isDir)return-1;if(!l.isDir&&c.isDir)return 1;let r=0;switch(i){case"name":r=l.name.localeCompare(c.name);break;case"size":r=l.size-c.size;break;case"modified":r=new Date(l.modified).getTime()-new Date(c.modified).getTime();break;default:r=l.name.localeCompare(c.name)}return a?r:-r}),[s,i,a])}function ci(){return t.useMemo(()=>typeof window>"u"?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches,[])}function di({viewMode:s}){const i=s==="grid"?12:8;return s==="grid"?e.jsx("div",{className:"grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-6 xl:grid-cols-8 gap-3 p-4","aria-busy":"true","aria-label":"Loading files",children:Array.from({length:i},(a,n)=>e.jsxs("div",{className:"flex flex-col items-center p-3 rounded-lg",children:[e.jsx("div",{className:"w-12 h-12 bg-primary-200 rounded animate-pulse mb-2"}),e.jsx("div",{className:"w-16 h-4 bg-primary-200 rounded animate-pulse"})]},n))}):e.jsx("div",{className:"divide-y divide-primary-200","aria-busy":"true","aria-label":"Loading files",children:Array.from({length:i},(a,n)=>e.jsxs("div",{className:"flex items-center gap-3 px-4 py-3",children:[e.jsx("div",{className:"w-6 h-6 bg-primary-200 rounded animate-pulse"}),e.jsx("div",{className:"flex-1 min-w-0 h-4 bg-primary-200 rounded animate-pulse"}),e.jsx("div",{className:"w-16 h-4 bg-primary-200 rounded animate-pulse"}),e.jsx("div",{className:"w-20 h-4 bg-primary-200 rounded animate-pulse"})]},n))})}const ui=t.memo(function({item:i,isSelected:a,onClick:n,onDoubleClick:l,onKeyDown:c,onOpenFile:r,reduceMotion:o}){const p=t.useCallback(()=>{n(i)},[n,i]),w=t.useCallback(()=>{l(i)},[l,i]),v=t.useCallback(d=>{c(d,i)},[c,i]),h=()=>i.isDir?`${i.name}, folder`:`${i.name}, ${i.extension} file, ${J(i.size)}, modified ${q(i.modified)}`,u=e.jsxs(F.button,{type:"button",whileHover:o?{}:{scale:1.02},whileTap:o?{}:{scale:.98},transition:{duration:o?0:.1},onClick:p,onDoubleClick:w,onKeyDown:v,"aria-label":h(),className:f("flex flex-col items-center p-3 rounded-lg w-full","transition-colors duration-150 ease-out","hover:bg-primary-100 focus-visible:bg-primary-100","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",a&&"bg-primary-200"),children:[e.jsx(y,{icon:pe(i),size:48,strokeWidth:1,className:f("mb-2",i.isDir?"text-blue-500":"text-primary-600"),"aria-hidden":"true"}),e.jsx("span",{className:"text-xs text-center text-primary-900 font-medium truncate w-full min-w-0",children:i.name}),i.isDir?null:e.jsx("span",{className:"text-xs text-primary-500 mt-1 tabular-nums",children:J(i.size)})]});return e.jsx(me,{item:i,onOpenFile:r,children:u})}),mi=t.memo(function({item:i,isSelected:a,onClick:n,onDoubleClick:l,onKeyDown:c,onOpenFile:r,reduceMotion:o}){const p=t.useCallback(()=>{n(i)},[n,i]),w=t.useCallback(()=>{l(i)},[l,i]),v=t.useCallback(d=>{c(d,i)},[c,i]),h=()=>i.isDir?`${i.name}, folder, modified ${q(i.modified)}`:`${i.name}, ${i.extension} file, ${J(i.size)}, modified ${q(i.modified)}`,u=e.jsxs(F.button,{type:"button",whileHover:o?{}:{backgroundColor:"rgb(248 250 252)"},transition:{duration:o?0:.1},onClick:p,onDoubleClick:w,onKeyDown:v,"aria-label":h(),className:f("w-full grid grid-cols-[auto_1fr_auto_auto] gap-4 px-4 py-3 text-left","transition-colors duration-150 ease-out","hover:bg-primary-100 focus-visible:bg-primary-100","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",a&&"bg-primary-200"),children:[e.jsx(y,{icon:pe(i),size:20,strokeWidth:1.5,className:f("mt-0.5 shrink-0",i.isDir?"text-blue-500":"text-primary-600"),"aria-hidden":"true"}),e.jsx("div",{className:"min-w-0 flex-1",children:e.jsx("span",{className:"text-primary-900 font-medium truncate block",children:i.name})}),e.jsx("div",{className:"text-sm text-primary-600 text-right w-16 tabular-nums shrink-0",children:i.isDir?"—":J(i.size)}),e.jsx("div",{className:"text-sm text-primary-600 text-right w-20 tabular-nums shrink-0",children:q(i.modified)})]});return e.jsx(me,{item:i,onOpenFile:r,children:u})}),pi=e.jsx("div",{className:"flex items-center justify-center h-full",children:e.jsxs("div",{className:"text-center",children:[e.jsx(y,{icon:ue,size:48,strokeWidth:1,className:"mx-auto text-primary-400 mb-3","aria-hidden":"true"}),e.jsx("p",{className:"text-primary-600 font-medium",children:"This folder is empty"}),e.jsx("p",{className:"text-sm text-primary-500 mt-1",children:"Upload files or create a new folder to get started"})]})});function hi({listing:s,loading:i,onOpenFile:a}){const{viewMode:n,sortBy:l,sortAsc:c,selectedFiles:r,navigateTo:o,toggleFileSelection:p}=P(),[w,v]=t.useState(0),h=t.useRef(null),u=ci(),d=oi(s?.items||[],l,c),k=t.useCallback(m=>{p(m.path)},[p]),N=t.useCallback(m=>{m.isDir?o(m.path):a&&li.has(m.extension.toLowerCase())&&a(m.path)},[o,a]),j=t.useCallback((m,x)=>{m.key==="Enter"?(m.preventDefault(),x.isDir?o(x.path):p(x.path)):m.key===" "&&(m.preventDefault(),p(x.path))},[o,p]);return t.useEffect(()=>{const m=x=>{if(d.length)switch(x.key){case"ArrowDown":x.preventDefault(),v(C=>Math.min(C+1,d.length-1));break;case"ArrowUp":x.preventDefault(),v(C=>Math.max(C-1,0));break;case"Home":x.preventDefault(),v(0);break;case"End":x.preventDefault(),v(d.length-1);break}};if(h.current)return h.current.addEventListener("keydown",m),()=>{h.current?.removeEventListener("keydown",m)}},[d.length]),i?e.jsx(di,{viewMode:n}):s?d.length===0?pi:n==="grid"?e.jsx("div",{ref:h,className:"grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-6 xl:grid-cols-8 gap-3 p-4 overflow-y-auto",role:"grid","aria-label":"Files grid",tabIndex:0,children:d.map((m,x)=>e.jsx("div",{role:"gridcell",children:e.jsx(ui,{item:m,isSelected:r.has(m.path),onClick:k,onDoubleClick:N,onKeyDown:j,onOpenFile:a,reduceMotion:u})},m.path))}):e.jsx("div",{ref:h,className:"overflow-y-auto",role:"table","aria-label":"Files list",tabIndex:0,children:e.jsxs("div",{className:"divide-y divide-primary-200",children:[e.jsxs("div",{className:"grid grid-cols-[auto_1fr_auto_auto] gap-4 px-4 py-2 text-sm font-medium text-primary-600 bg-primary-50",role:"row",children:[e.jsx("div",{className:"w-6",role:"columnheader","aria-label":"File type"}),e.jsx("div",{role:"columnheader",children:"Name"}),e.jsx("div",{className:"w-16 text-right tabular-nums",role:"columnheader",children:"Size"}),e.jsx("div",{className:"w-20 text-right tabular-nums",role:"columnheader",children:"Modified"})]}),d.map((m,x)=>e.jsx("div",{role:"row",children:e.jsx(mi,{item:m,isSelected:r.has(m.path),onClick:k,onDoubleClick:N,onKeyDown:j,onOpenFile:a,reduceMotion:u})},m.path))]})}):e.jsx("div",{className:"flex items-center justify-center h-full",children:e.jsx("p",{className:"text-primary-500",children:"No listing available"})})}function oe(s){if(s===0)return"0 B";const i=1024,a=["B","KB","MB","GB"],n=Math.floor(Math.log(s)/Math.log(i));return parseFloat((s/Math.pow(i,n)).toFixed(1))+" "+a[n]}function fi({open:s,onOpenChange:i,currentPath:a}){const[n,l]=t.useState([]),[c,r]=t.useState(!1),[o,p]=t.useState("idle"),w=t.useRef(null),v=si(),h=t.useCallback(()=>{l([]),p("idle"),w.current&&(w.current.value="")},[]),u=t.useCallback(g=>{if(!g)return;const S=Array.from(g).map(M=>({file:M,id:Math.random().toString(36).substr(2,9)}));l(M=>[...M,...S])},[]),d=t.useCallback(g=>{u(g.target.files)},[u]),k=t.useCallback(g=>{g.preventDefault(),r(!1),u(g.dataTransfer.files)},[u]),N=t.useCallback(g=>{g.preventDefault(),r(!0)},[]),j=t.useCallback(g=>{g.preventDefault(),r(!1)},[]),m=t.useCallback(g=>{l(S=>S.filter(M=>M.id!==g))},[]),x=t.useCallback(()=>{w.current?.click()},[]),C=t.useCallback(g=>{(g.key==="Enter"||g.key===" ")&&(g.preventDefault(),x())},[x]),z=t.useCallback(async()=>{if(n.length===0)return;const g=new DataTransfer;n.forEach(({file:S})=>{g.items.add(S)}),p("uploading");try{await v.mutateAsync({files:g.files,path:a}),p("success"),h(),i(!1)}catch(S){p("error"),console.error("Upload failed:",S)}},[n,a,v,h,i]),X=t.useCallback(g=>{g||h(),i(g)},[h,i]),U=n.reduce((g,{file:S})=>g+S.size,0),K=n.length,Y=()=>v.isPending||o==="uploading"?"Uploading…":K===0?"Upload":K===1?"Upload 1 File":`Upload ${K} Files`;return e.jsx(Q,{open:s,onOpenChange:X,children:e.jsx(V,{className:"w-[min(500px,92vw)]",children:e.jsxs("div",{className:"p-6",children:[e.jsx(_,{className:"mb-2",children:"Upload Files"}),e.jsxs(H,{className:"mb-6",children:["Upload files to ",a==="/"?"root directory":a]}),e.jsxs("div",{onDrop:k,onDragOver:N,onDragLeave:j,onClick:x,onKeyDown:C,tabIndex:0,role:"button","aria-label":"Drop files here or click to choose files",className:f("border-2 border-dashed rounded-lg p-8 text-center cursor-pointer","transition-colors duration-150 ease-out","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",c?"border-primary-400 bg-primary-50":"border-primary-200 hover:border-primary-300 hover:bg-primary-50"),children:[e.jsx(y,{icon:ce,size:48,strokeWidth:1,className:"mx-auto text-primary-400 mb-4","aria-hidden":"true"}),e.jsx("p",{className:"text-primary-600 font-medium mb-2",children:"Drag and drop files here"}),e.jsx("p",{className:"text-sm text-primary-500 mb-4",children:"or"}),e.jsxs(D,{variant:"outline",className:f("gap-2","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),"aria-label":"Choose files from computer",children:[e.jsx(y,{icon:ee,size:18,strokeWidth:1.5,"aria-hidden":"true"}),e.jsx("span",{children:"Choose Files"})]}),e.jsx("input",{ref:w,type:"file",multiple:!0,onChange:d,className:"hidden","aria-hidden":"true"})]}),e.jsx($,{children:n.length>0?e.jsxs(F.div,{initial:{opacity:0,height:0},animate:{opacity:1,height:"auto"},exit:{opacity:0,height:0},className:"mt-6",children:[e.jsxs("h4",{className:"text-sm font-medium text-primary-900 mb-3",children:["Selected Files (",n.length,")"]}),e.jsx("div",{className:"max-h-32 overflow-y-auto border border-primary-200 rounded-lg",children:n.map(({file:g,id:S})=>e.jsxs(F.div,{initial:{opacity:0,x:-10},animate:{opacity:1,x:0},exit:{opacity:0,x:10},className:"flex items-center justify-between p-2 border-b border-primary-100 last:border-b-0",children:[e.jsxs("div",{className:"flex items-center gap-2 min-w-0 flex-1",children:[e.jsx(y,{icon:ee,size:16,strokeWidth:1.5,className:"text-primary-600 shrink-0","aria-hidden":"true"}),e.jsx("span",{className:"text-sm text-primary-900 truncate min-w-0",children:g.name}),e.jsx("span",{className:"text-xs text-primary-500 shrink-0 tabular-nums",children:oe(g.size)})]}),e.jsx(D,{size:"icon-sm",variant:"ghost",onClick:()=>m(S),className:f("text-primary-500 hover:text-red-600 shrink-0","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),"aria-label":`Remove ${g.name} from upload list`,children:e.jsx(y,{icon:de,size:14,strokeWidth:1.5,"aria-hidden":"true"})})]},S))}),e.jsxs("p",{className:"text-xs text-primary-600 mt-2 tabular-nums",children:["Total size: ",oe(U)]})]}):null}),v.isPending||o==="uploading"?e.jsxs(F.div,{initial:{opacity:0},animate:{opacity:1},className:"mt-4 p-3 bg-primary-50 rounded-lg","aria-live":"polite",children:[e.jsx("p",{className:"text-sm text-primary-600 mb-2",children:"Uploading files…"}),e.jsx("div",{className:"bg-primary-200 rounded-full h-2",role:"progressbar","aria-label":"Upload progress",children:e.jsx("div",{className:"bg-primary-600 h-2 rounded-full w-1/2 animate-pulse"})})]}):null,o==="success"?e.jsx("div",{className:"mt-4 p-3 bg-green-50 rounded-lg","aria-live":"polite",children:e.jsx("p",{className:"text-sm text-green-700",children:"Files uploaded successfully!"})}):null,o==="error"?e.jsx("div",{className:"mt-4 p-3 bg-red-50 rounded-lg","aria-live":"polite",children:e.jsx("p",{className:"text-sm text-red-700",children:"Upload failed. Please try again."})}):null,e.jsxs("div",{className:"flex justify-end gap-2 mt-6",children:[e.jsx(G,{disabled:v.isPending||o==="uploading",className:f("focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),children:"Cancel"}),e.jsx(D,{onClick:z,disabled:n.length===0||v.isPending||o==="uploading",className:f("focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),children:Y()})]})]})})})}function xi({open:s,onOpenChange:i,currentPath:a}){const[n,l]=t.useState(""),[c,r]=t.useState(""),o=ni(),p=t.useCallback(async()=>{if(n.trim()){r("");try{await o.mutateAsync({path:a,name:n.trim()}),l(""),i(!1)}catch(m){const x=m instanceof Error?m.message:"Failed to create folder";r(x),console.error("Create folder failed:",m)}}},[n,a,o,i]),w=t.useCallback(m=>{m||(l(""),r("")),i(m)},[i]),v=t.useCallback(m=>{m.key==="Enter"&&(m.preventDefault(),p())},[p]),h=t.useCallback(m=>{const x=m.target.value;l(x),c&&r("")},[c]),u=n.trim().length>0&&!/[<>:"/\\|?*]/.test(n)&&!n.includes(".."),d=()=>o.isPending?"Creating…":"Create Folder",N=n.trim()?n.includes("..")?'Folder name cannot contain ".."':/[<>:"/\\|?*]/.test(n)?'Invalid characters: < > : " / \\ | ? *':"":"",j=c||N;return e.jsx(Q,{open:s,onOpenChange:w,children:e.jsx(V,{children:e.jsxs("div",{className:"p-6",children:[e.jsx(_,{className:"mb-2",children:"Create New Folder"}),e.jsxs(H,{className:"mb-4",children:["Create a new folder in ",a==="/"?"root directory":a]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{htmlFor:"folder-name",className:"block text-sm font-medium text-primary-900 mb-2",children:"Folder Name"}),e.jsx("input",{id:"folder-name",type:"text",value:n,onChange:h,onKeyDown:v,placeholder:"Enter folder name",autoComplete:"off",spellCheck:!1,autoFocus:!0,"aria-describedby":j?"folder-name-error":void 0,"aria-invalid":j?"true":"false",className:f("w-full px-3 py-2 border rounded-lg","transition-colors duration-150 ease-out","focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",j?"border-red-300 focus-visible:ring-red-300":"border-primary-200 focus:border-primary-300")}),j?e.jsx("p",{id:"folder-name-error",className:"text-sm text-red-600 mt-1",role:"alert","aria-live":"polite",children:c||N}):null]}),o.isPending?e.jsx("div",{className:"mb-4 p-3 bg-primary-50 rounded-lg","aria-live":"polite",children:e.jsx("p",{className:"text-sm text-primary-600",children:"Creating folder…"})}):null,e.jsxs("div",{className:"flex justify-end gap-2",children:[e.jsx(G,{disabled:o.isPending,className:f("focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation"),children:"Cancel"}),e.jsx(D,{onClick:p,disabled:!u||o.isPending,className:f("focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none","touch-manipulation",(!u||o.isPending)&&"opacity-50 cursor-not-allowed"),"aria-describedby":u?void 0:"create-button-help",children:d()})]}),!u&&n.length>0?e.jsx("p",{id:"create-button-help",className:"text-xs text-primary-500 mt-2",children:"Please enter a valid folder name"}):null]})})})}const gi={js:"JavaScript",ts:"TypeScript",jsx:"JSX",tsx:"TSX",py:"Python",json:"JSON",yaml:"YAML",yml:"YAML",md:"Markdown",html:"HTML",css:"CSS",scss:"SCSS",sh:"Shell",bash:"Bash",sql:"SQL",xml:"XML",toml:"TOML",ini:"INI",conf:"Config",cfg:"Config",env:"Env",txt:"Text",log:"Log",csv:"CSV",go:"Go",rs:"Rust",rb:"Ruby",php:"PHP",java:"Java",c:"C",cpp:"C++",h:"Header",dockerfile:"Dockerfile",makefile:"Makefile",graphql:"GraphQL",svelte:"Svelte",vue:"Vue"};function bi({filePath:s,onClose:i}){const a=Ye(s),n=Ze(),l=t.useRef(null),[c,r]=t.useState(null),[o,p]=t.useState(!1);t.useEffect(()=>{a.data&&c===null&&r(a.data.content)},[a.data,c]);const w=t.useMemo(()=>a.data?gi[a.data.extension.toLowerCase()]||a.data.extension.toUpperCase():"",[a.data]),v=t.useCallback(N=>{r(N.target.value),p(N.target.value!==a.data?.content)},[a.data]),h=t.useCallback(async()=>{if(c!==null)try{await n.mutateAsync({path:s,content:c}),p(!1)}catch{}},[s,c,n]),u=t.useCallback(()=>{o&&!window.confirm("You have unsaved changes. Discard them?")||i()},[o,i]);t.useEffect(()=>{const N=j=>{(j.ctrlKey||j.metaKey)&&j.key==="s"&&(j.preventDefault(),o&&h()),j.key==="Escape"&&u()};return window.addEventListener("keydown",N),()=>window.removeEventListener("keydown",N)},[h,u,o]);const d=t.useCallback(N=>{if(N.key==="Tab"){N.preventDefault();const j=N.currentTarget,m=j.selectionStart,x=j.selectionEnd,C=j.value,z=C.substring(0,m)+" "+C.substring(x);r(z),p(z!==a.data?.content),requestAnimationFrame(()=>{j.selectionStart=j.selectionEnd=m+2})}},[a.data]),k=s.split("/").pop()||s;return e.jsxs("div",{className:"fixed inset-0 z-50 bg-surface flex flex-col",children:[e.jsxs("header",{className:"flex items-center justify-between px-4 py-2 border-b border-primary-200 bg-primary-50",children:[e.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[e.jsx("h2",{className:"text-sm font-semibold text-primary-900 truncate",children:k}),w?e.jsx("span",{className:"text-xs text-primary-500 bg-primary-100 px-2 py-0.5 rounded-full shrink-0",children:w}):null,o?e.jsx("span",{className:"text-xs text-amber-600 bg-amber-50 px-2 py-0.5 rounded-full shrink-0",children:"Unsaved"}):null,n.isError?e.jsx("span",{className:"text-xs text-red-600",children:n.error.message}):null]}),e.jsxs("div",{className:"flex items-center gap-2 shrink-0",children:[e.jsxs(D,{size:"sm",variant:"default",onClick:h,disabled:!o||n.isPending,className:f((!o||n.isPending)&&"opacity-50 cursor-not-allowed"),children:[e.jsx(y,{icon:Oe,size:16,strokeWidth:1.5,"aria-hidden":"true"}),n.isPending?"Saving…":"Save"]}),e.jsx(D,{size:"icon-sm",variant:"ghost",onClick:u,"aria-label":"Close editor",children:e.jsx(y,{icon:qe,size:20,strokeWidth:1.5,"aria-hidden":"true"})})]})]}),e.jsx("div",{className:"flex-1 min-h-0 overflow-hidden",children:a.isLoading?e.jsx("div",{className:"flex items-center justify-center h-full",children:e.jsx("p",{className:"text-primary-500 text-sm",children:"Loading file…"})}):a.isError?e.jsx("div",{className:"flex items-center justify-center h-full",children:e.jsxs("div",{className:"text-center",children:[e.jsx("p",{className:"text-red-600 text-sm mb-2",children:a.error instanceof Error?a.error.message:"Failed to load file"}),e.jsx(D,{size:"sm",variant:"secondary",onClick:()=>{a.refetch()},children:"Retry"})]})}):e.jsx("textarea",{ref:l,value:c??"",onChange:v,onKeyDown:d,spellCheck:!1,autoFocus:!0,className:f("w-full h-full p-4 resize-none","bg-primary-950 text-primary-100","font-mono text-sm leading-relaxed","focus:outline-none","selection:bg-blue-800/50")})}),a.data?e.jsxs("footer",{className:"flex items-center justify-between px-4 py-1 border-t border-primary-200 bg-primary-50 text-xs text-primary-500",children:[e.jsx("span",{children:s}),e.jsx("span",{children:vi(a.data.size)})]}):null]})}function vi(s){return s<1024?`${s} B`:s<1024*1024?`${(s/1024).toFixed(1)} KB`:`${(s/(1024*1024)).toFixed(1)} MB`}function Ni(){const s=L(),{currentPath:i}=P(),[a,n]=t.useState(!1),[l,c]=t.useState(!1),[r,o]=t.useState(null),p=ei(i),v=ie({queryKey:we,queryFn:function(){return ne(s)},initialData:function(){return ne(s)},staleTime:1/0}).data?.isSidebarCollapsed??!1,h=t.useCallback(()=>{je(s,function(C){return{...C,isSidebarCollapsed:!C.isSidebarCollapsed}})},[s]),u=t.useCallback(()=>{n(!0)},[]),d=t.useCallback(()=>{c(!0)},[]),k=t.useCallback(x=>{o(x)},[]),N=t.useCallback(()=>{o(null)},[]),j=t.useMemo(()=>({display:"flex",flexDirection:"column",height:"100%",minHeight:0}),[]),m=e.jsx(Ge,{isCollapsed:v,onToggleCollapse:h,onSelectAction:()=>{}});return e.jsxs("div",{className:"h-screen bg-surface text-primary-900",children:[e.jsxs("div",{className:f("h-full overflow-hidden grid grid-cols-[auto_1fr]"),children:[m,e.jsxs("main",{"aria-label":"File explorer",style:j,children:[e.jsxs("header",{className:"border-b border-primary-200 px-4 py-3",children:[e.jsx("div",{className:"flex items-center justify-between mb-2",children:e.jsx(Je,{path:i})}),e.jsx(Xe,{onUpload:u,onCreateFolder:d})]}),e.jsxs("div",{className:"flex-1 min-h-0 overflow-auto",children:[e.jsx(hi,{listing:p.data,loading:p.isLoading,onOpenFile:k}),p.isError?e.jsxs("div",{className:"p-4 text-center","aria-live":"polite",children:[e.jsx("p",{className:"text-red-600 text-sm",children:p.error instanceof Error?p.error.message:"Failed to load files"}),e.jsx("button",{onClick:()=>{p.refetch()},className:"mt-2 text-sm text-primary-600 hover:text-primary-900 underline focus-visible:ring-2 focus-visible:ring-primary-300 focus-visible:outline-none rounded-sm",children:"Retry"})]}):null]}),e.jsx(fi,{open:a,onOpenChange:n,currentPath:i}),e.jsx(xi,{open:l,onOpenChange:c,currentPath:i})]})]}),r?e.jsx(bi,{filePath:r,onClose:N}):null]})}export{Ni as FileExplorerScreen};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/file-explorer-screen-Daf4rIq9.js","assets/main-BAHT5yqU.js","assets/menu-BhVaz8Ly.js","assets/button-D_9OBT_f.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{j as e,r,_ as s}from"./main-BAHT5yqU.js";const n=r.lazy(()=>s(()=>import("./file-explorer-screen-Daf4rIq9.js"),__vite__mapDeps([0,1,2,3])).then(t=>({default:t.FileExplorerScreen})));function o(){return e.jsx(r.Suspense,{fallback:e.jsx("div",{className:"flex h-screen items-center justify-center text-primary-500 text-sm",children:"Loading…"}),children:e.jsx(n,{})})}export{o as component};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=Object.freeze(JSON.parse(`{"displayName":"Fish","name":"fish","patterns":[{"include":"#string-double"},{"include":"#string-single"},{"include":"#comment"},{"include":"#subshell-bare"},{"include":"#subshell"},{"include":"#command"},{"include":"#keywords"},{"include":"#io-redirection"},{"include":"#operators"},{"include":"#options"},{"include":"#variable"},{"include":"#escape"}],"repository":{"command":{"captures":{"2":{"name":"keyword.operator.pipe.fish"},"3":{"name":"keyword.control.fish"},"5":{"name":"support.function.command.fish"}},"match":"(^\\\\s*|&&\\\\s*|(\\\\|)\\\\s*|\\\\(\\\\s*|;\\\\s*|\\\\b(if|while)\\\\b\\\\s+)(?!(?<!\\\\.)\\\\b(function|while|if|else|switch|case|for|in|begin|end|continue|break|return|source|exit|wait|and|or|not)\\\\b(?![!?]))([-\\\\].0-9A-\\\\[_a-z]+)"},"command-subshell":{"captures":{"2":{"name":"keyword.operator.pipe.fish"},"3":{"name":"keyword.control.fish"},"5":{"name":"support.function.command.fish"}},"match":"(\\\\G\\\\s*|&&\\\\s*|(\\\\|)\\\\s*|\\\\(\\\\s*|;\\\\s*|\\\\b(if|while)\\\\b\\\\s+)(?!(?<!\\\\.)\\\\b(function|while|if|else|switch|case|for|in|begin|end|continue|break|return|source|exit|wait|and|or|not)\\\\b(?![!?]))([-\\\\].0-9A-\\\\[_a-z]+)"},"comment":{"captures":{"1":{"name":"punctuation.definition.comment.fish"}},"match":"(?<!\\\\$)(#)(?!\\\\{).*$\\\\n?","name":"comment.line.number-sign.fish"},"escape":{"patterns":[{"match":"\\\\\\\\[] \\"#$\\\\&-*;<>?\\\\[^abefnrtv{-~]","name":"constant.character.escape.string.fish"},{"match":"\\\\\\\\x\\\\h{1,2}","name":"constant.character.escape.hex-ascii.fish"},{"match":"\\\\\\\\X\\\\h{1,2}","name":"constant.character.escape.hex-byte.fish"},{"match":"\\\\\\\\[0-7]{1,3}","name":"constant.character.escape.octal.fish"},{"match":"\\\\\\\\u\\\\h{1,4}","name":"constant.character.escape.unicode-16-bit.fish"},{"match":"\\\\\\\\U\\\\h{1,8}","name":"constant.character.escape.unicode-32-bit.fish"},{"match":"\\\\\\\\c[A-Za-z]","name":"constant.character.escape.control.fish"}]},"io-redirection":{"patterns":[{"captures":{"1":{"name":"keyword.operator.redirect.fish"},"2":{"name":"keyword.operator.redirect.target.fish"}},"match":"(<|(?:[>^]|>>|\\\\^\\\\^)(?:&[-012])?|[012](?:[<>]|>>)(?:&[-012])?)\\\\s*(?!\\\\()([\\\\--9A-Z_a-z]+)"},{"match":"<|([>^]|>>|\\\\^\\\\^)(&[-012])?|[012]([<>]|>>)(&[-012])?","name":"keyword.operator.redirect.fish"}]},"keywords":{"patterns":[{"captures":{"2":{"name":"keyword.control.fish"}},"match":"(^\\\\s*|&&\\\\s*|(?<=\\\\|)\\\\s*|\\\\(\\\\s*|;\\\\s*|(?<=\\\\bwhile\\\\b)\\\\s+|(?<=\\\\bif\\\\b)\\\\s+|(?<=\\\\band\\\\b)\\\\s+|(?<=\\\\bor\\\\b)\\\\s+|(?<=\\\\bnot\\\\b)\\\\s+)(?<!\\\\.)\\\\b(while|if|and|or|not)\\\\b(?![!?])"},{"captures":{"2":{"name":"keyword.control.fish"}},"match":"(^\\\\s*|&&\\\\s*|(?<=\\\\|)\\\\s*|\\\\(\\\\s*|;\\\\s*)(?<!\\\\.)\\\\b(function|else|switch|case|for|begin|end|continue|break|return|source|exit|wait)\\\\b(?![!?])"},{"match":"\\\\b(in)\\\\b(?![!?])","name":"keyword.control.fish"}]},"keywords-subshell":{"patterns":[{"captures":{"2":{"name":"keyword.control.fish"}},"match":"(\\\\G\\\\s*|&&\\\\s*|(?<=\\\\|)\\\\s*|\\\\(\\\\s*|;\\\\s*|(?<=\\\\bwhile\\\\b)\\\\s+|(?<=\\\\bif\\\\b)\\\\s+|(?<=\\\\band\\\\b)\\\\s+|(?<=\\\\bor\\\\b)\\\\s+|(?<=\\\\bnot\\\\b)\\\\s+)(?<!\\\\.)\\\\b(while|if|and|or|not)\\\\b(?![!?])"},{"captures":{"2":{"name":"keyword.control.fish"}},"match":"(\\\\G\\\\s*|&&\\\\s*|(?<=\\\\|)\\\\s*|\\\\(\\\\s*|;\\\\s*)(?<!\\\\.)\\\\b(function|else|switch|case|for|begin|end|continue|break|return|source|exit|wait)\\\\b(?![!?])"},{"match":"\\\\b(in)\\\\b(?![!?])","name":"keyword.control.fish"}]},"operators":{"patterns":[{"match":"&","name":"keyword.operator.background.fish"},{"match":"\\\\*\\\\*|[*?]","name":"keyword.operator.glob.fish"}]},"options":{"captures":{"1":{"name":"source.option.fish"}},"match":"\\\\s(-{1,2}[-0-9A-Z_a-z]+|-\\\\w)\\\\b"},"slice":{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.slice.begin.fish"}},"end":"(?<!\\\\\\\\)((\\\\\\\\\\\\\\\\)*)(])","endCaptures":{"1":{"name":"constant.character.escape.string.fish"},"3":{"name":"punctuation.definition.slice.end.fish"}},"name":"meta.embedded.slice.fish variable.interpolation.fish","patterns":[{"include":"#string-double"},{"include":"#string-single"},{"include":"#subshell-bare"},{"include":"#subshell"},{"include":"#variable"},{"include":"#escape"}]},"slice-string-double":{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.slice.begin.fish"}},"end":"(?<!\\\\\\\\)((\\\\\\\\\\\\\\\\)*)(])","endCaptures":{"1":{"name":"constant.character.escape.string.fish"},"3":{"name":"punctuation.definition.slice.end.fish"}},"name":"meta.embedded.slice.fish variable.interpolation.string.fish","patterns":[{"include":"#subshell"},{"include":"#variable"},{"match":"\\\\\\\\([\\"$]|$|\\\\\\\\)","name":"constant.character.escape.fish"}]},"string-double":{"begin":"\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.fish"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.fish"}},"name":"string.quoted.double.fish","patterns":[{"include":"#subshell"},{"include":"#variable-string-double"},{"match":"\\\\\\\\([\\"$]|$|\\\\\\\\)","name":"constant.character.escape.fish"}]},"string-single":{"begin":"'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.fish"}},"end":"'","endCaptures":{"0":{"name":"punctuation.definition.string.end.fish"}},"name":"string.quoted.single.fish","patterns":[{"match":"\\\\\\\\(['\\\\\\\\\`])","name":"constant.character.escape.fish"}]},"subshell":{"begin":"\\\\$\\\\(","beginCaptures":{"0":{"name":"punctuation.definition.subshell.begin.fish"}},"end":"(?<!\\\\\\\\)((\\\\\\\\\\\\\\\\)*)(\\\\))","endCaptures":{"1":{"name":"constant.character.escape.string.fish"},"3":{"name":"punctuation.definition.subshell.end.fish"}},"name":"meta.embedded.subshell.fish","patterns":[{"include":"#string-double"},{"include":"#string-single"},{"include":"#comment"},{"include":"#keywords-subshell"},{"include":"#command-subshell"},{"include":"#io-redirection"},{"include":"#operators"},{"include":"#options"},{"include":"#subshell"},{"include":"#variable"},{"include":"#escape"}]},"subshell-bare":{"begin":"\\\\(","beginCaptures":{"0":{"name":"punctuation.definition.subshell.begin.fish"}},"end":"(?<!\\\\\\\\)((\\\\\\\\\\\\\\\\)*)(\\\\))","endCaptures":{"1":{"name":"constant.character.escape.string.fish"},"3":{"name":"punctuation.definition.subshell.end.fish"}},"name":"meta.embedded.subshell.fish","patterns":[{"include":"#string-double"},{"include":"#string-single"},{"include":"#comment"},{"include":"#keywords-subshell"},{"include":"#command-subshell"},{"include":"#io-redirection"},{"include":"#operators"},{"include":"#options"},{"include":"#subshell-bare"},{"include":"#subshell"},{"include":"#variable"},{"include":"#escape"}]},"variable":{"patterns":[{"begin":"(\\\\$)(argv|CMD_DURATION|COLUMNS|fish_bind_mode|fish_color_autosuggestion|fish_color_cancel|fish_color_command|fish_color_comment|fish_color_cwd|fish_color_cwd_root|fish_color_end|fish_color_error|fish_color_escape|fish_color_hg_added|fish_color_hg_clean|fish_color_hg_copied|fish_color_hg_deleted|fish_color_hg_dirty|fish_color_hg_modified|fish_color_hg_renamed|fish_color_hg_unmerged|fish_color_hg_untracked|fish_color_history_current|fish_color_host|fish_color_host_remote|fish_color_match|fish_color_normal|fish_color_operator|fish_color_param|fish_color_quote|fish_color_redirection|fish_color_search_match|fish_color_selection|fish_color_status|fish_color_user|fish_color_valid_path|fish_complete_path|fish_function_path|fish_greeting|fish_key_bindings|fish_pager_color_completion|fish_pager_color_description|fish_pager_color_prefix|fish_pager_color_progress|fish_pid|fish_prompt_hg_status_added|fish_prompt_hg_status_copied|fish_prompt_hg_status_deleted|fish_prompt_hg_status_modified|fish_prompt_hg_status_order|fish_prompt_hg_status_unmerged|fish_prompt_hg_status_untracked|FISH_VERSION|history|hostname|IFS|LINES|pipestatus|status|umask|version)\\\\b(?=\\\\[)","beginCaptures":{"1":{"name":"punctuation.definition.variable.fish"},"2":{"name":"variable.language.fish"}},"end":"(?<=])","name":"variable.language.fish","patterns":[{"include":"#slice"}]},{"captures":{"1":{"name":"punctuation.definition.variable.fish"}},"match":"(\\\\$)(argv|CMD_DURATION|COLUMNS|fish_bind_mode|fish_color_autosuggestion|fish_color_cancel|fish_color_command|fish_color_comment|fish_color_cwd|fish_color_cwd_root|fish_color_end|fish_color_error|fish_color_escape|fish_color_hg_added|fish_color_hg_clean|fish_color_hg_copied|fish_color_hg_deleted|fish_color_hg_dirty|fish_color_hg_modified|fish_color_hg_renamed|fish_color_hg_unmerged|fish_color_hg_untracked|fish_color_history_current|fish_color_host|fish_color_host_remote|fish_color_match|fish_color_normal|fish_color_operator|fish_color_param|fish_color_quote|fish_color_redirection|fish_color_search_match|fish_color_selection|fish_color_status|fish_color_user|fish_color_valid_path|fish_complete_path|fish_function_path|fish_greeting|fish_key_bindings|fish_pager_color_completion|fish_pager_color_description|fish_pager_color_prefix|fish_pager_color_progress|fish_pid|fish_prompt_hg_status_added|fish_prompt_hg_status_copied|fish_prompt_hg_status_deleted|fish_prompt_hg_status_modified|fish_prompt_hg_status_order|fish_prompt_hg_status_unmerged|fish_prompt_hg_status_untracked|FISH_VERSION|history|hostname|IFS|LINES|pipestatus|status|umask|version)\\\\b","name":"variable.language.fish"},{"begin":"(\\\\$)([A-Z_a-z][0-9A-Z_a-z]*)(?=\\\\[)","beginCaptures":{"1":{"name":"punctuation.definition.variable.fish"},"2":{"name":"variable.other.normal.fish"}},"end":"(?<=])","name":"variable.other.normal.fish","patterns":[{"include":"#slice"}]},{"captures":{"1":{"name":"punctuation.definition.variable.fish"}},"match":"(\\\\$)[A-Z_a-z][0-9A-Z_a-z]*","name":"variable.other.normal.fish"}]},"variable-string-double":{"patterns":[{"begin":"(\\\\$)(argv|CMD_DURATION|COLUMNS|fish_bind_mode|fish_color_autosuggestion|fish_color_cancel|fish_color_command|fish_color_comment|fish_color_cwd|fish_color_cwd_root|fish_color_end|fish_color_error|fish_color_escape|fish_color_hg_added|fish_color_hg_clean|fish_color_hg_copied|fish_color_hg_deleted|fish_color_hg_dirty|fish_color_hg_modified|fish_color_hg_renamed|fish_color_hg_unmerged|fish_color_hg_untracked|fish_color_history_current|fish_color_host|fish_color_host_remote|fish_color_match|fish_color_normal|fish_color_operator|fish_color_param|fish_color_quote|fish_color_redirection|fish_color_search_match|fish_color_selection|fish_color_status|fish_color_user|fish_color_valid_path|fish_complete_path|fish_function_path|fish_greeting|fish_key_bindings|fish_pager_color_completion|fish_pager_color_description|fish_pager_color_prefix|fish_pager_color_progress|fish_pid|fish_prompt_hg_status_added|fish_prompt_hg_status_copied|fish_prompt_hg_status_deleted|fish_prompt_hg_status_modified|fish_prompt_hg_status_order|fish_prompt_hg_status_unmerged|fish_prompt_hg_status_untracked|FISH_VERSION|history|hostname|IFS|LINES|pipestatus|status|umask|version)\\\\b(?=\\\\[)","beginCaptures":{"1":{"name":"punctuation.definition.variable.fish"},"2":{"name":"variable.language.fish"}},"end":"(?<=])","name":"variable.language.fish","patterns":[{"include":"#slice-string-double"}]},{"captures":{"1":{"name":"punctuation.definition.variable.fish"}},"match":"(\\\\$)(argv|CMD_DURATION|COLUMNS|fish_bind_mode|fish_color_autosuggestion|fish_color_cancel|fish_color_command|fish_color_comment|fish_color_cwd|fish_color_cwd_root|fish_color_end|fish_color_error|fish_color_escape|fish_color_hg_added|fish_color_hg_clean|fish_color_hg_copied|fish_color_hg_deleted|fish_color_hg_dirty|fish_color_hg_modified|fish_color_hg_renamed|fish_color_hg_unmerged|fish_color_hg_untracked|fish_color_history_current|fish_color_host|fish_color_host_remote|fish_color_match|fish_color_normal|fish_color_operator|fish_color_param|fish_color_quote|fish_color_redirection|fish_color_search_match|fish_color_selection|fish_color_status|fish_color_user|fish_color_valid_path|fish_complete_path|fish_function_path|fish_greeting|fish_key_bindings|fish_pager_color_completion|fish_pager_color_description|fish_pager_color_prefix|fish_pager_color_progress|fish_pid|fish_prompt_hg_status_added|fish_prompt_hg_status_copied|fish_prompt_hg_status_deleted|fish_prompt_hg_status_modified|fish_prompt_hg_status_order|fish_prompt_hg_status_unmerged|fish_prompt_hg_status_untracked|FISH_VERSION|history|hostname|IFS|LINES|pipestatus|status|umask|version)\\\\b","name":"variable.language.fish"},{"begin":"(\\\\$)([A-Z_a-z][0-9A-Z_a-z]*)(?=\\\\[)","beginCaptures":{"1":{"name":"punctuation.definition.variable.fish"},"2":{"name":"variable.other.normal.fish"}},"end":"(?<=])","name":"variable.other.normal.fish","patterns":[{"include":"#slice-string-double"}]},{"captures":{"1":{"name":"punctuation.definition.variable.fish"}},"match":"(\\\\$)[A-Z_a-z][0-9A-Z_a-z]*","name":"variable.other.normal.fish"}]}},"scopeName":"source.fish"}`)),i=[e];export{i as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=Object.freeze(JSON.parse('{"displayName":"Fluent","name":"fluent","patterns":[{"include":"#comment"},{"include":"#message"},{"include":"#wrong-line"}],"repository":{"attributes":{"begin":"\\\\s*(\\\\.[A-Za-z][-0-9A-Z_a-z]*\\\\s*=\\\\s*)","beginCaptures":{"1":{"name":"support.class.attribute-begin.fluent"}},"end":"^(?=\\\\s*[^.])","patterns":[{"include":"#placeable"}]},"comment":{"match":"^##?#?\\\\s.*$","name":"comment.fluent"},"function-comma":{"match":",","name":"support.function.function-comma.fluent"},"function-named-argument":{"begin":"([0-9A-Za-z]+:)\\\\s*([\\"0-9A-Za-z]+)","beginCaptures":{"1":{"name":"support.function.named-argument.name.fluent"},"2":{"name":"variable.other.named-argument.value.fluent"}},"end":"(?=[),\\\\s])","name":"variable.other.named-argument.fluent"},"function-positional-argument":{"match":"\\\\$[-0-9A-Z_a-z]+","name":"variable.other.function.positional-argument.fluent"},"invalid-placeable-string-missing-end-quote":{"match":"\\"[^\\"]+$","name":"invalid.illegal.wrong-placeable-missing-end-quote.fluent"},"invalid-placeable-wrong-placeable-missing-end":{"match":"([^A-Z}]*|[^-][^>])$\\\\b","name":"invalid.illegal.wrong-placeable-missing-end.fluent"},"message":{"begin":"^(-?[A-Za-z][-0-9A-Z_a-z]*\\\\s*=\\\\s*)","beginCaptures":{"1":{"name":"support.class.message-identifier.fluent"}},"contentName":"string.fluent","end":"^(?=\\\\S)","patterns":[{"include":"#attributes"},{"include":"#placeable"}]},"placeable":{"begin":"(\\\\{)","beginCaptures":{"1":{"name":"keyword.placeable.begin.fluent"}},"contentName":"variable.other.placeable.content.fluent","end":"(})","endCaptures":{"1":{"name":"keyword.placeable.end.fluent"}},"patterns":[{"include":"#placeable-string"},{"include":"#placeable-function"},{"include":"#placeable-reference-or-number"},{"include":"#selector"},{"include":"#invalid-placeable-wrong-placeable-missing-end"},{"include":"#invalid-placeable-string-missing-end-quote"},{"include":"#invalid-placeable-wrong-function-name"}]},"placeable-function":{"begin":"([A-Z][-0-9A-Z_]*\\\\()","beginCaptures":{"1":{"name":"support.function.placeable-function.call.begin.fluent"}},"contentName":"string.placeable-function.fluent","end":"(\\\\))","endCaptures":{"1":{"name":"support.function.placeable-function.call.end.fluent"}},"patterns":[{"include":"#function-comma"},{"include":"#function-positional-argument"},{"include":"#function-named-argument"}]},"placeable-reference-or-number":{"match":"(([-$])[-0-9A-Z_a-z]+|[A-Za-z][-0-9A-Z_a-z]*|[0-9]+)","name":"variable.other.placeable.reference-or-number.fluent"},"placeable-string":{"begin":"(\\")(?=[^\\\\n]*\\")","beginCaptures":{"1":{"name":"variable.other.placeable-string-begin.fluent"}},"contentName":"string.placeable-string-content.fluent","end":"(\\")","endCaptures":{"1":{"name":"variable.other.placeable-string-end.fluent"}}},"selector":{"begin":"(->)","beginCaptures":{"1":{"name":"support.function.selector.begin.fluent"}},"contentName":"string.selector.content.fluent","end":"^(?=\\\\s*})","patterns":[{"include":"#selector-item"}]},"selector-item":{"begin":"(\\\\s*\\\\*?\\\\[)([-0-9A-Z_a-z]+)(]\\\\s*)","beginCaptures":{"1":{"name":"support.function.selector-item.begin.fluent"},"2":{"name":"variable.other.selector-item.begin.fluent"},"3":{"name":"support.function.selector-item.begin.fluent"}},"contentName":"string.selector-item.content.fluent","end":"^(?=(\\\\s*})|(\\\\s*\\\\[)|(\\\\s*\\\\*))","patterns":[{"include":"#placeable"}]},"wrong-line":{"match":".*","name":"invalid.illegal.wrong-line.fluent"}},"scopeName":"source.ftl","aliases":["ftl"]}')),n=[e];export{n as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import e from"./fortran-free-form-BxgE0vQu.js";const n=Object.freeze(JSON.parse('{"displayName":"Fortran (Fixed Form)","fileTypes":["f","F","f77","F77","for","FOR"],"injections":{"source.fortran.fixed - ( string | comment )":{"patterns":[{"include":"#line-header"},{"include":"#line-end-comment"}]}},"name":"fortran-fixed-form","patterns":[{"include":"#comments"},{"begin":"(?i)^(?=.{5}|(?<!^)\\\\t)\\\\s*(?:([0-9]{1,5})\\\\s+)?(format)\\\\b","beginCaptures":{"1":{"name":"constant.numeric.fortran"},"2":{"name":"keyword.control.format.fortran"}},"end":"(?=^(?![^\\\\n!#]{5}\\\\S))","name":"meta.statement.IO.fortran","patterns":[{"include":"#comments"},{"include":"#line-header"},{"match":"!.*$","name":"comment.line.fortran"},{"include":"source.fortran.free#string-constant"},{"include":"source.fortran.free#numeric-constant"},{"include":"source.fortran.free#operators"},{"include":"source.fortran.free#format-parentheses"}]},{"include":"#line-header"},{"include":"source.fortran.free"}],"repository":{"comments":{"patterns":[{"begin":"^[*Cc]","end":"\\\\n","name":"comment.line.fortran"},{"begin":"^ *!","end":"\\\\n","name":"comment.line.fortran"}]},"line-end-comment":{"begin":"(?<=^.{72})(?!\\\\n)","end":"(?=\\\\n)","name":"comment.line-end.fortran"},"line-header":{"captures":{"1":{"name":"constant.numeric.fortran"},"2":{"name":"keyword.line-continuation-operator.fortran"},"3":{"name":"source.fortran.free"},"4":{"name":"invalid.error.fortran"}},"match":"^(?!\\\\s*[!#])(?:([ \\\\d]{5} )|( {5}.)|(\\\\t)|(.{1,5}))"}},"scopeName":"source.fortran.fixed","embeddedLangs":["fortran-free-form"],"aliases":["f","for","f77"]}')),t=[...e,n];export{t as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=Object.freeze(JSON.parse(`{"displayName":"Fortran (Free Form)","fileTypes":["f90","F90","f95","F95","f03","F03","f08","F08","f18","F18","fpp","FPP",".pf",".PF"],"firstLineMatch":"(?i)-\\\\*- mode: fortran free -\\\\*-","injections":{"source.fortran.free - ( string | comment | meta.preprocessor )":{"patterns":[{"include":"#line-continuation-operator"},{"include":"#preprocessor"}]},"string.quoted.double.fortran":{"patterns":[{"include":"#string-line-continuation-operator"}]},"string.quoted.single.fortran":{"patterns":[{"include":"#string-line-continuation-operator"}]}},"name":"fortran-free-form","patterns":[{"include":"#preprocessor"},{"include":"#comments"},{"include":"#constants"},{"include":"#operators"},{"include":"#array-constructor"},{"include":"#parentheses"},{"include":"#include-statement"},{"include":"#import-statement"},{"include":"#block-data-definition"},{"include":"#function-definition"},{"include":"#module-definition"},{"include":"#program-definition"},{"include":"#submodule-definition"},{"include":"#subroutine-definition"},{"include":"#procedure-definition"},{"include":"#derived-type-definition"},{"include":"#enum-block-construct"},{"include":"#interface-block-constructs"},{"include":"#procedure-specification-statement"},{"include":"#type-specification-statements"},{"include":"#specification-statements"},{"include":"#control-constructs"},{"include":"#control-statements"},{"include":"#execution-statements"},{"include":"#intrinsic-functions"},{"include":"#variable"}],"repository":{"IO-item-list":{"begin":"(?i)(?=\\\\s*[\\"'0-9a-z])","contentName":"meta.name-list.fortran","end":"(?=[\\\\n!);])","patterns":[{"include":"#constants"},{"include":"#operators"},{"include":"#intrinsic-functions"},{"include":"#array-constructor"},{"include":"#parentheses"},{"include":"#brackets"},{"include":"#assignment-keyword"},{"include":"#operator-keyword"},{"include":"#variable"}]},"IO-keywords":{"begin":"(?i)\\\\G\\\\s*\\\\b(?:(read)|(write))\\\\s*(\\\\()","beginCaptures":{"1":{"name":"keyword.control.generic-spec.read.fortran"},"2":{"name":"keyword.control.generic-spec.write.fortran"},"3":{"name":"punctuation.parentheses.left.fortran"}},"end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"captures":{"1":{"name":"keyword.control.generic-spec.formatted.fortran"},"2":{"name":"keyword.control.generic-spec.unformatted.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(?:(formatted)|(unformatted))\\\\b"},{"include":"#invalid-word"}]},"IO-statements":{"patterns":[{"begin":"(?i)\\\\b(format)(?=\\\\s*[!\\\\&(])","beginCaptures":{"1":{"name":"keyword.control.format.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.IO.fortran","patterns":[{"include":"#comments"},{"include":"#line-continuation-operator"},{"include":"#format-parentheses"}]},{"begin":"(?i)\\\\b(?:(backspace)|(close)|(endfile)|(inquire)|(open)|(read)|(rewind)|(write))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"keyword.control.backspace.fortran"},"2":{"name":"keyword.control.close.fortran"},"3":{"name":"keyword.control.endfile.fortran"},"4":{"name":"keyword.control.inquire.fortran"},"5":{"name":"keyword.control.open.fortran"},"6":{"name":"keyword.control.read.fortran"},"7":{"name":"keyword.control.rewind.fortran"},"8":{"name":"keyword.control.write.fortran"},"9":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?=[\\\\n!;])","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"name":"meta.statement.IO.fortran","patterns":[{"include":"#parentheses-dummy-variables"},{"include":"#IO-item-list"}]},{"captures":{"1":{"name":"keyword.control.backspace.fortran"},"2":{"name":"keyword.control.endfile.fortran"},"3":{"name":"keyword.control.format.fortran"},"4":{"name":"keyword.control.print.fortran"},"5":{"name":"keyword.control.read.fortran"},"6":{"name":"keyword.control.rewind.fortran"}},"match":"(?i)\\\\b(?:(backspace)|(endfile)|(format)|(print)|(read)|(rewind))\\\\b"},{"begin":"(?i)\\\\b(?:(flush)|(wait))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"keyword.control.flush.fortran"},"2":{"name":"keyword.control.wait.fortran"},"3":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"captures":{"1":{"name":"keyword.control.flush.fortran"}},"match":"(?i)\\\\b(flush)\\\\b"}]},"abstract-attribute":{"captures":{"1":{"name":"storage.modifier.fortran.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(abstract)\\\\b"},"abstract-interface-block-construct":{"begin":"(?i)\\\\b(abstract)\\\\s+(interface)\\\\b","beginCaptures":{"1":{"name":"keyword.other.attribute.fortran.modern"},"2":{"name":"keyword.control.interface.fortran"}},"end":"(?i)\\\\b(end\\\\s*interface)\\\\b","endCaptures":{"1":{"name":"keyword.control.endinterface.fortran.modern"}},"name":"meta.interface.abstract.fortran","patterns":[{"include":"$base"}]},"access-attribute":{"patterns":[{"include":"#private-attribute"},{"include":"#public-attribute"}]},"allocatable-attribute":{"captures":{"1":{"name":"storage.modifier.allocatable.fortran"}},"match":"(?i)\\\\s*\\\\b(allocatable)\\\\b"},"allocate-statement":{"begin":"(?i)\\\\b(allocate)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"keyword.control.allocate.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"name":"meta.statement.allocate.fortran","patterns":[{"include":"#parentheses-dummy-variables"}]},"arithmetic-operators":{"captures":{"1":{"name":"keyword.operator.subtraction.fortran"},"2":{"name":"keyword.operator.addition.fortran"},"3":{"name":"keyword.operator.division.fortran"},"4":{"name":"keyword.operator.power.fortran"},"5":{"name":"keyword.operator.multiplication.fortran"}},"match":"(-)|(\\\\+)|/(?![/=\\\\\\\\])|(\\\\*\\\\*)|(\\\\*)"},"array-constructor":{"begin":"(?<!\\\\n)(?=\\\\s*(\\\\[|\\\\(/))","end":"(?<!\\\\G)","name":"meta.contructor.array","patterns":[{"include":"#brackets"},{"begin":"\\\\s*(\\\\(/)","beginCaptures":{"1":{"name":"punctuation.bracket.left.fortran"}},"end":"(/\\\\))","endCaptures":{"1":{"name":"punctuation.bracket.left.fortran"}},"patterns":[{"include":"#comments"},{"include":"#constants"},{"include":"#operators"},{"include":"#array-constructor"},{"include":"#parentheses"},{"include":"#intrinsic-functions"},{"include":"#variable"}]}]},"assign-statement":{"patterns":[{"begin":"(?i)\\\\b(assign)\\\\b","beginCaptures":{"1":{"name":"keyword.control.assign.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.assign.fortran","patterns":[{"captures":{"1":{"name":"keyword.control.to.fortran"}},"match":"(?i)\\\\s*\\\\b(to)\\\\b"},{"include":"$base"}]}]},"assignment-keyword":{"begin":"(?i)\\\\G\\\\s*\\\\b(assignment)\\\\s*(\\\\()","beginCaptures":{"1":{"name":"keyword.control.generic-spec.assignment.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#assignment-operator"},{"include":"#invalid-word"}]},"assignment-operator":{"match":"(?<![/<=>])(=)(?![=>])","name":"keyword.operator.assignment.fortran"},"associate-construct":{"begin":"(?i)\\\\b(associate)\\\\b(?=\\\\s*\\\\()","beginCaptures":{"1":{"name":"keyword.control.associate.fortran"}},"contentName":"meta.block.associate.fortran","end":"(?i)\\\\b(end\\\\s*associate)\\\\b","endCaptures":{"1":{"name":"keyword.control.endassociate.fortran"}},"patterns":[{"include":"$base"}]},"asynchronous-attribute":{"captures":{"1":{"name":"storage.modifier.asynchronous.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(asynchronous)\\\\b"},"attribute-specification-statement":{"begin":"(?i)(?=\\\\b(?:allocatable|asynchronous|contiguous|external|intrinsic|optional|parameter|pointer|private|protected|public|save|target|value|volatile)\\\\b|(bind|dimension|intent)\\\\s*\\\\(|(codimension)\\\\s*\\\\[)","end":"(?=[\\\\n!;])","name":"meta.statement.attribute-specification.fortran","patterns":[{"include":"#access-attribute"},{"include":"#allocatable-attribute"},{"include":"#asynchronous-attribute"},{"include":"#codimension-attribute"},{"include":"#contiguous-attribute"},{"include":"#dimension-attribute"},{"include":"#external-attribute"},{"include":"#intent-attribute"},{"include":"#intrinsic-attribute"},{"include":"#language-binding-attribute"},{"include":"#optional-attribute"},{"include":"#parameter-attribute"},{"include":"#pointer-attribute"},{"include":"#protected-attribute"},{"include":"#save-attribute"},{"include":"#target-attribute"},{"include":"#value-attribute"},{"include":"#volatile-attribute"},{"begin":"(?=\\\\s*::)","contentName":"meta.attribute-list.normal.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"include":"#invalid-word"}]},{"include":"#name-list"}]},"block-construct":{"begin":"(?i)\\\\b(block)\\\\b(?!\\\\s*\\\\bdata\\\\b)","beginCaptures":{"1":{"name":"keyword.control.associate.fortran"}},"contentName":"meta.block.block.fortran","end":"(?i)\\\\b(end\\\\s*block)\\\\b","endCaptures":{"1":{"name":"keyword.control.endassociate.fortran"}},"patterns":[{"include":"$base"}]},"block-data-definition":{"begin":"(?i)\\\\b(block\\\\s*data)\\\\b(?:\\\\s+([a-z]\\\\w*)\\\\b)?","beginCaptures":{"1":{"name":"keyword.control.block-data.fortran"},"2":{"name":"entity.name.block-data.fortran"}},"end":"(?i)\\\\b(?:(end\\\\s*block\\\\s*data)(?:\\\\s+(\\\\2))?|(end))\\\\b(?:\\\\s*(\\\\S((?!\\\\n).)*))?","endCaptures":{"1":{"name":"keyword.control.end-block-data.fortran"},"2":{"name":"entity.name.block-data.fortran"},"3":{"name":"keyword.control.end-block-data.fortran"},"4":{"name":"invalid.error.block-data-definition.fortran"}},"name":"meta.block-data.fortran","patterns":[{"include":"$base"}]},"brackets":{"begin":"\\\\s*(\\\\[)","beginCaptures":{"1":{"name":"punctuation.bracket.left.fortran"}},"end":"(])","endCaptures":{"1":{"name":"punctuation.bracket.left.fortran"}},"patterns":[{"include":"#comments"},{"include":"#constants"},{"include":"#operators"},{"include":"#array-constructor"},{"include":"#parentheses"},{"include":"#intrinsic-functions"},{"include":"#variable"}]},"call-statement":{"patterns":[{"applyEndPatternLast":1,"begin":"(?i)\\\\s*\\\\b(call)\\\\b","beginCaptures":{"1":{"name":"keyword.control.call.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.call.fortran","patterns":[{"begin":"(?i)(?=\\\\s*[a-z]\\\\w*\\\\s*%)","end":"(?=[\\\\n!;])","patterns":[{"include":"#comments"},{"include":"#line-continuation-operator"},{"captures":{"1":{"name":"variable.other.fortran"},"2":{"name":"keyword.accessor.fortran"}},"match":"(?i)\\\\s*([a-z]\\\\w*)\\\\s*(%)"},{"captures":{"1":{"name":"entity.name.function.subroutine.fortran"}},"match":"(?i)\\\\s*([a-z]\\\\w*)"},{"include":"#parentheses-dummy-variables"}]},{"include":"#intrinsic-subroutines"},{"begin":"(?i)\\\\G\\\\s*\\\\b([a-z]\\\\w*)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"entity.name.function.subroutine.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"captures":{"1":{"name":"entity.name.function.subroutine.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b([a-z]\\\\w*)\\\\b(?=\\\\s*[\\\\n!;])"},{"include":"$base"}]}]},"character-type":{"patterns":[{"begin":"(?i)\\\\b(character)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"storage.type.character.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"contentName":"meta.type-spec.fortran","end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"captures":{"1":{"name":"storage.type.character.fortran"},"2":{"name":"keyword.operator.multiplication.fortran"},"3":{"name":"constant.numeric.fortran"}},"match":"(?i)\\\\b(character)\\\\b(?:\\\\s*(\\\\*)\\\\s*(\\\\d*))?"}]},"codimension-attribute":{"begin":"(?i)\\\\G\\\\s*\\\\b(codimension)(?=\\\\s*\\\\[)","beginCaptures":{"1":{"name":"storage.modifier.codimension.fortran"}},"end":"(?<!\\\\G)","patterns":[{"include":"#brackets"}]},"comments":{"begin":"!","end":"(?=\\\\n)","name":"comment.line.fortran"},"common-statement":{"begin":"(?i)\\\\b(common)\\\\b","beginCaptures":{"1":{"name":"keyword.control.common.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"$base"}]},"concurrent-attribute":{"begin":"(?i)\\\\G\\\\s*\\\\b(concurrent)\\\\b","beginCaptures":{"1":{"name":"keyword.control.while.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#parentheses"},{"include":"#invalid-word"}]},"constants":{"patterns":[{"include":"#logical-constant"},{"include":"#numeric-constant"},{"include":"#string-constant"}]},"contiguous-attribute":{"captures":{"1":{"name":"storage.modifier.contigous.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(contiguous)\\\\b"},"continue-statement":{"patterns":[{"begin":"(?i)\\\\s*\\\\b(continue)\\\\b","beginCaptures":{"1":{"name":"keyword.control.continue.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.continue.fortran","patterns":[{"include":"#invalid-character"}]}]},"control-constructs":{"patterns":[{"include":"#named-control-constructs"},{"include":"#unnamed-control-constructs"}]},"control-statements":{"patterns":[{"include":"#assign-statement"},{"include":"#call-statement"},{"include":"#continue-statement"},{"include":"#cycle-statement"},{"include":"#entry-statement"},{"include":"#error-stop-statement"},{"include":"#exit-statement"},{"include":"#goto-statement"},{"include":"#pause-statement"},{"include":"#return-statement"},{"include":"#stop-statement"},{"include":"#where-statement"},{"include":"#image-control-statement"}]},"cpp-numeric-constant":{"captures":{"0":{"patterns":[{"begin":"(?=.)","beginCaptures":{},"end":"$","endCaptures":{},"patterns":[{"captures":{"1":{"name":"keyword.other.unit.hexadecimal.cpp"},"2":{"name":"constant.numeric.hexadecimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"3":{"name":"punctuation.separator.constant.numeric.cpp"},"4":{"name":"constant.numeric.hexadecimal.cpp"},"5":{"name":"constant.numeric.hexadecimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"6":{"name":"punctuation.separator.constant.numeric.cpp"},"7":{"name":"keyword.other.unit.exponent.hexadecimal.cpp"},"8":{"name":"keyword.operator.plus.exponent.hexadecimal.cpp"},"9":{"name":"keyword.operator.minus.exponent.hexadecimal.cpp"},"10":{"name":"constant.numeric.exponent.hexadecimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"11":{"name":"keyword.other.unit.suffix.floating-point.cpp"},"12":{"name":"keyword.other.unit.user-defined.cpp"}},"match":"\\\\G(0[Xx])(\\\\h(?:\\\\h|((?<=\\\\h)'(?=\\\\h)))*)?((?<=\\\\h)\\\\.|\\\\.(?=\\\\h))(\\\\h(?:\\\\h|((?<=\\\\h)'(?=\\\\h)))*)?(?:(?<!')([Pp])(\\\\+?)(-?)([0-9](?:[0-9]|(?<=\\\\h)'(?=\\\\h))*))?([FLfl](?!\\\\w))?((?:\\\\w(?<![Pp\\\\h])\\\\w*)?)$"},{"captures":{"1":{"name":"constant.numeric.decimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"2":{"name":"punctuation.separator.constant.numeric.cpp"},"3":{"name":"constant.numeric.decimal.point.cpp"},"4":{"name":"constant.numeric.decimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"5":{"name":"punctuation.separator.constant.numeric.cpp"},"6":{"name":"keyword.other.unit.exponent.decimal.cpp"},"7":{"name":"keyword.operator.plus.exponent.decimal.cpp"},"8":{"name":"keyword.operator.minus.exponent.decimal.cpp"},"9":{"name":"constant.numeric.exponent.decimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"10":{"name":"keyword.other.unit.suffix.floating-point.cpp"},"11":{"name":"keyword.other.unit.user-defined.cpp"}},"match":"\\\\G(?=[.0-9])(?!0[BXbx])([0-9](?:[0-9]|((?<=\\\\h)'(?=\\\\h)))*)?((?<=[0-9])\\\\.|\\\\.(?=[0-9]))([0-9](?:[0-9]|((?<=\\\\h)'(?=\\\\h)))*)?(?:(?<!')([Ee])(\\\\+?)(-?)([0-9](?:[0-9]|(?<=\\\\h)'(?=\\\\h))*))?([FLfl](?!\\\\w))?((?:\\\\w(?<![0-9Ee])\\\\w*)?)$"},{"captures":{"1":{"name":"keyword.other.unit.binary.cpp"},"2":{"name":"constant.numeric.binary.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"3":{"name":"punctuation.separator.constant.numeric.cpp"},"4":{"name":"keyword.other.unit.suffix.integer.cpp"},"5":{"name":"keyword.other.unit.user-defined.cpp"}},"match":"\\\\G(0[Bb])([01](?:[01]|((?<=\\\\h)'(?=\\\\h)))*)((?:[Uu]|[Uu]ll?|[Uu]LL?|ll?[Uu]?|LL?[Uu]?|[Ff])(?!\\\\w))?((?:\\\\w(?<![0-9])\\\\w*)?)$"},{"captures":{"1":{"name":"keyword.other.unit.octal.cpp"},"2":{"name":"constant.numeric.octal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"3":{"name":"punctuation.separator.constant.numeric.cpp"},"4":{"name":"keyword.other.unit.suffix.integer.cpp"},"5":{"name":"keyword.other.unit.user-defined.cpp"}},"match":"\\\\G(0)((?:[0-7]|((?<=\\\\h)'(?=\\\\h)))+)((?:[Uu]|[Uu]ll?|[Uu]LL?|ll?[Uu]?|LL?[Uu]?|[Ff])(?!\\\\w))?((?:\\\\w(?<![0-9])\\\\w*)?)$"},{"captures":{"1":{"name":"keyword.other.unit.hexadecimal.cpp"},"2":{"name":"constant.numeric.hexadecimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"3":{"name":"punctuation.separator.constant.numeric.cpp"},"4":{"name":"keyword.other.unit.exponent.hexadecimal.cpp"},"5":{"name":"keyword.operator.plus.exponent.hexadecimal.cpp"},"6":{"name":"keyword.operator.minus.exponent.hexadecimal.cpp"},"7":{"name":"constant.numeric.exponent.hexadecimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"8":{"name":"keyword.other.unit.suffix.integer.cpp"},"9":{"name":"keyword.other.unit.user-defined.cpp"}},"match":"\\\\G(0[Xx])(\\\\h(?:\\\\h|((?<=\\\\h)'(?=\\\\h)))*)(?:(?<!')([Pp])(\\\\+?)(-?)([0-9](?:[0-9]|(?<=\\\\h)'(?=\\\\h))*))?((?:[Uu]|[Uu]ll?|[Uu]LL?|ll?[Uu]?|LL?[Uu]?|[Ff])(?!\\\\w))?((?:\\\\w(?<![Pp\\\\h])\\\\w*)?)$"},{"captures":{"1":{"name":"constant.numeric.decimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"2":{"name":"punctuation.separator.constant.numeric.cpp"},"3":{"name":"keyword.other.unit.exponent.decimal.cpp"},"4":{"name":"keyword.operator.plus.exponent.decimal.cpp"},"5":{"name":"keyword.operator.minus.exponent.decimal.cpp"},"6":{"name":"constant.numeric.exponent.decimal.cpp","patterns":[{"match":"(?<=\\\\h)'(?=\\\\h)","name":"punctuation.separator.constant.numeric.cpp"}]},"7":{"name":"keyword.other.unit.suffix.integer.cpp"},"8":{"name":"keyword.other.unit.user-defined.cpp"}},"match":"\\\\G(?=[.0-9])(?!0[BXbx])([0-9](?:[0-9]|((?<=\\\\h)'(?=\\\\h)))*)(?:(?<!')([Ee])(\\\\+?)(-?)([0-9](?:[0-9]|(?<=\\\\h)'(?=\\\\h))*))?((?:[Uu]|[Uu]ll?|[Uu]LL?|ll?[Uu]?|LL?[Uu]?|[Ff])(?!\\\\w))?((?:\\\\w(?<![0-9Ee])\\\\w*)?)$"},{"match":"(?:['.0-9A-Z_a-z]|(?<=[EPep])[-+])+","name":"invalid.illegal.constant.numeric.cpp"}]}]}},"match":"(?<!\\\\w)\\\\.?\\\\d(?:['.0-9A-Z_a-z]|(?<=[EPep])[-+])*"},"critical-construct":{"begin":"(?i)\\\\b(critical)\\\\b","beginCaptures":{"1":{"name":"keyword.control.associate.fortran"}},"contentName":"meta.block.critical.fortran","end":"(?i)\\\\b(end\\\\s*critical)\\\\b","endCaptures":{"1":{"name":"keyword.control.endassociate.fortran"}},"patterns":[{"include":"$base"}]},"cycle-statement":{"patterns":[{"begin":"(?i)\\\\s*\\\\b(cycle)\\\\b","beginCaptures":{"1":{"name":"keyword.control.cycle.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.fortran","patterns":[]}]},"data-statement":{"begin":"(?i)\\\\b(data)\\\\b","beginCaptures":{"1":{"name":"keyword.control.data.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"$base"}]},"deallocate-statement":{"begin":"(?i)\\\\b(deallocate)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"keyword.control.deallocate.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"name":"meta.statement.deallocate.fortran","patterns":[{"include":"#parentheses-dummy-variables"}]},"deferred-attribute":{"captures":{"1":{"name":"storage.modifier.deferred.fortran"}},"match":"(?i)\\\\s*\\\\b(deferred)\\\\b"},"derived-type":{"begin":"(?i)\\\\b(?:(class)|(type))\\\\s*(\\\\()\\\\s*(([a-z]\\\\w*)|\\\\*)","beginCaptures":{"1":{"name":"storage.type.class.fortran"},"2":{"name":"storage.type.type.fortran"},"3":{"name":"punctuation.parentheses.left.fortran"},"4":{"name":"entity.name.type.fortran"}},"contentName":"meta.type-spec.fortran","end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"name":"meta.specification.type.derived.fortran","patterns":[{"include":"#parentheses-dummy-variables"}]},"derived-type-component-attribute-specification":{"begin":"(?i)(?=\\\\s*\\\\b(?:private|sequence)\\\\b)","end":"(?=[\\\\n!;])","name":"meta.statement.attribute-specification.fortran","patterns":[{"include":"#access-attribute"},{"include":"#sequence-attribute"},{"include":"#invalid-character"}]},"derived-type-component-parameter-specification":{"captures":{"1":{"name":"storage.type.integer.fortran"},"2":{"name":"punctuation.comma.fortran"},"3":{"name":"keyword.other.attribute.derived-type.parameter.fortran"},"4":{"name":"keyword.operator.double-colon.fortran"},"5":{"name":"entity.name.derived-type.parameter.fortran"}},"match":"(?i)\\\\b(integer)\\\\s*(,)\\\\s*(kind|len)\\\\s*(?:(::)\\\\s*([a-z]\\\\w*)?)?\\\\s*(?=[\\\\n!;])"},"derived-type-component-procedure-specification":{"begin":"(?i)(?=\\\\bprocedure\\\\b)","end":"(?=[\\\\n!;])","name":"meta.specification.procedure.fortran","patterns":[{"include":"#procedure-type"},{"begin":"(?=\\\\s*(,|::|\\\\())","contentName":"meta.attribute-list.derived-type-component-procedure.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"begin":"(,)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=::|[\\\\n!,;])","patterns":[{"include":"#access-attribute"},{"include":"#pass-attribute"},{"include":"#nopass-attribute"},{"include":"#invalid-word"},{"include":"#pointer-attribute"}]}]},{"include":"#procedure-name-list"}]},"derived-type-component-type-specification":{"begin":"(?i)(?=\\\\b(?:character|class|complex|double\\\\s*precision|double\\\\s*complex|integer|logical|real|type)\\\\b(?![^\\\\n!\\"':;]*\\\\bfunction\\\\b))","end":"(?=[\\\\n!;])","name":"meta.specification.derived-type.fortran","patterns":[{"include":"#types"},{"include":"#line-continuation-operator"},{"begin":"(?=\\\\s*(,|::))","contentName":"meta.attribute-list.derived-type-component-type.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"begin":"(,)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=::|[\\\\n!,;])","patterns":[{"include":"#access-attribute"},{"include":"#allocatable-attribute"},{"include":"#codimension-attribute"},{"include":"#contiguous-attribute"},{"include":"#dimension-attribute"},{"include":"#pointer-attribute"},{"include":"#invalid-word"}]}]},{"include":"#name-list"}]},"derived-type-contains-attribute-specification":{"begin":"(?i)(?=\\\\bprivate\\\\b)","end":"(?=[\\\\n!;])","name":"meta.statement.attribute-specification.fortran","patterns":[{"include":"#access-attribute"},{"include":"#invalid-character"}]},"derived-type-contains-final-procedure-specification":{"begin":"(?i)\\\\b(final)\\\\b","beginCaptures":{"1":{"name":"storage.type.final-procedure.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.specification.procedure.final.fortran","patterns":[{"begin":"(?=\\\\s*(::))","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"name":"meta.attribute-list.derived-type-contains-final-procedure.fortran","patterns":[{"include":"#invalid-word"}]},{"include":"#procedure-name"}]},"derived-type-contains-generic-procedure-specification":{"begin":"(?i)\\\\b(generic)\\\\b","beginCaptures":{"1":{"name":"storage.type.procedure.generic.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.specification.procedure.generic.fortran","patterns":[{"begin":"(?=\\\\s*(,|::|\\\\())","contentName":"meta.attribute-list.derived-type-contains-generic-procedure.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"begin":"(,)|^|(?<=&)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=::|[\\\\n!\\\\&,;])","patterns":[{"include":"#access-attribute"},{"include":"#invalid-word"}]}]},{"begin":"(?=\\\\s*[a-z])","contentName":"meta.name-list.fortran","end":"(?=[\\\\n!;])","patterns":[{"include":"#IO-keywords"},{"include":"#assignment-keyword"},{"include":"#operator-keyword"},{"include":"#procedure-name"},{"include":"#pointer-operators"}]}]},"derived-type-contains-procedure-specification":{"begin":"(?i)(?=\\\\bprocedure\\\\b)","end":"(?=[\\\\n!;])","name":"meta.specification.procedure.fortran","patterns":[{"include":"#procedure-type"},{"begin":"(?=\\\\s*(,|::|\\\\())","contentName":"meta.attribute-list.derived-type-contains-procedure.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"begin":"(,)|^|(?<=&)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=::|[\\\\n!\\\\&,;])","name":"meta.something.fortran","patterns":[{"include":"#access-attribute"},{"include":"#deferred-attribute"},{"include":"#non-overridable-attribute"},{"include":"#nopass-attribute"},{"include":"#pass-attribute"},{"include":"#invalid-word"}]}]},{"include":"#procedure-name-list"}]},"derived-type-definition":{"begin":"(?i)\\\\b(type)\\\\b(?!\\\\s*(\\\\(|is\\\\b|=))","beginCaptures":{"1":{"name":"keyword.control.type.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.derived-type.definition.fortran","patterns":[{"begin":"\\\\G(?=\\\\s*(,|::))","contentName":"meta.attribute-list.derived-type.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"begin":"(,)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=::|[\\\\n!,;])","patterns":[{"include":"#access-attribute"},{"include":"#abstract-attribute"},{"include":"#language-binding-attribute"},{"include":"#extends-attribute"},{"include":"#invalid-word"}]}]},{"begin":"(?i)\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.type.fortran"}},"end":"(?i)(?:^|(?<=;))\\\\s*(end\\\\s*type)(?:\\\\s+(?:(\\\\1)|(\\\\w+)))?\\\\b","endCaptures":{"1":{"name":"keyword.control.endtype.fortran"},"2":{"name":"entity.name.type.fortran"},"3":{"name":"invalid.error.derived-type.fortran"}},"patterns":[{"include":"#dummy-variable-list"},{"include":"#comments"},{"begin":"(?i)^(?!\\\\s*\\\\b(?:contains|end\\\\s*type)\\\\b)","end":"(?i)^(?=\\\\s*\\\\b(?:contains|end\\\\s*type)\\\\b)","name":"meta.block.specification.derived-type.fortran","patterns":[{"include":"#comments"},{"include":"#derived-type-component-attribute-specification"},{"include":"#derived-type-component-parameter-specification"},{"include":"#derived-type-component-procedure-specification"},{"include":"#derived-type-component-type-specification"}]},{"begin":"(?i)\\\\b(contains)\\\\b","beginCaptures":{"1":{"name":"keyword.control.contains.fortran"}},"end":"(?i)(?=\\\\s*end\\\\s*type\\\\b)","name":"meta.block.contains.fortran","patterns":[{"include":"#comments"},{"include":"#derived-type-contains-attribute-specification"},{"include":"#derived-type-contains-final-procedure-specification"},{"include":"#derived-type-contains-generic-procedure-specification"},{"include":"#derived-type-contains-procedure-specification"}]}]}]},"derived-type-operators":{"captures":{"1":{"name":"keyword.other.selector.fortran"}},"match":"\\\\s*(%)"},"dimension-attribute":{"begin":"(?i)\\\\s*\\\\b(dimension)(?=\\\\s*\\\\()","beginCaptures":{"1":{"name":"storage.modifier.dimension.fortran"}},"end":"(?<!\\\\G)","patterns":[{"include":"#parentheses-dummy-variables"}]},"do-construct":{"patterns":[{"captures":{"1":{"name":"keyword.control.enddo.fortran"}},"match":"(?i)\\\\b(end\\\\s*do)\\\\b"},{"begin":"(?i)\\\\b(do)\\\\s+(\\\\d{1,5})","beginCaptures":{"1":{"name":"keyword.control.do.fortran"},"2":{"name":"constant.numeric.fortran"}},"end":"(?i)(?:^|(?<=;))(?=\\\\s*\\\\b\\\\2\\\\b)","name":"meta.do.labeled.fortran","patterns":[{"begin":"(?i)\\\\G(?:\\\\s*(,)|(?!\\\\s*[\\\\n!;]))","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#concurrent-attribute"},{"include":"#while-attribute"},{"include":"$base"}]},{"include":"$base"}]},{"begin":"(?i)\\\\b(do)\\\\b","beginCaptures":{"1":{"name":"keyword.control.do.fortran"}},"end":"(?i)\\\\b(?:(continue)|(end\\\\s*do))\\\\b","endCaptures":{"1":{"name":"keyword.control.continue.fortran"},"2":{"name":"keyword.control.enddo.fortran"}},"name":"meta.block.do.unlabeled.fortran","patterns":[{"begin":"(?i)\\\\G(?:\\\\s*(,)|(?!\\\\s*[\\\\n!;]))","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.loop-control.fortran","patterns":[{"include":"#concurrent-attribute"},{"include":"#while-attribute"},{"include":"$base"}]},{"begin":"(?i)(?!\\\\s*\\\\b(continue|end\\\\s*do)\\\\b)","end":"(?i)(?=\\\\s*\\\\b(continue|end\\\\s*do)\\\\b)","patterns":[{"include":"$base"}]}]}]},"dummy-variable":{"captures":{"1":{"name":"variable.parameter.fortran"}},"match":"(?i)(?:^|(?<=[\\\\&(,]))\\\\s*([a-z]\\\\w*)"},"dummy-variable-list":{"begin":"\\\\G\\\\s*(\\\\()","beginCaptures":{"1":{"name":"punctuation.definition.parameters.begin.fortran"}},"end":"\\\\)|(?=\\\\n)","endCaptures":{"0":{"name":"punctuation.definition.parameters.end.fortran"}},"name":"meta.dummy-variable-list","patterns":[{"include":"#dummy-variable"}]},"elemental-attribute":{"captures":{"1":{"name":"storage.modifier.elemental.fortran"}},"match":"(?i)\\\\s*\\\\b(elemental)\\\\b"},"entry-statement":{"patterns":[{"begin":"(?i)\\\\s*\\\\b(entry)\\\\b","beginCaptures":{"1":{"name":"keyword.control.entry.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.entry.fortran","patterns":[{"begin":"(?i)\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.function.entry.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#dummy-variable-list"},{"include":"#result-statement"},{"include":"#language-binding-attribute"}]}]}]},"enum-block-construct":{"begin":"(?i)\\\\b(enum)\\\\b","beginCaptures":{"1":{"name":"keyword.control.enum.fortran"}},"end":"(?i)\\\\b(end\\\\s*enum)\\\\b","endCaptures":{"1":{"name":"keyword.control.end-enum.fortran"}},"name":"meta.enum.fortran","patterns":[{"begin":"\\\\G\\\\s*(,)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#language-binding-attribute"},{"include":"#invalid-word"}]},{"begin":"(?i)(?!\\\\s*\\\\b(end\\\\s*enum)\\\\b)","end":"(?i)(?=\\\\b(end\\\\s*enum)\\\\b)","name":"meta.block.specification.enum.fortran","patterns":[{"include":"#comments"},{"begin":"(?i)\\\\b(enumerator)\\\\b","beginCaptures":{"1":{"name":"keyword.other.enumerator.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.enumerator-specification.fortran","patterns":[{"begin":"(?=\\\\s*(,|::))","contentName":"meta.attribute-list.enum.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"include":"#invalid-word"}]},{"include":"#comments"},{"include":"#name-list"}]}]}]},"equivalence-statement":{"begin":"(?i)\\\\b(equivalence)\\\\b","beginCaptures":{"1":{"name":"keyword.control.common.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"begin":"\\\\G|(,)","beginCaptures":{"1":{"name":"puntuation.comma.fortran"}},"end":"(?=[\\\\n!,;])","patterns":[{"include":"#parentheses-dummy-variables"}]}]},"error-stop-statement":{"begin":"(?i)\\\\s*\\\\b(error\\\\s+stop)\\\\b","beginCaptures":{"1":{"name":"keyword.control.errorstop.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.errorstop.fortran","patterns":[{"include":"#constants"},{"include":"#string-operators"},{"include":"#variable"},{"include":"#invalid-character"}]},"event-statement":{"begin":"(?i)\\\\b(event (?:post|wait))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"keyword.control.event.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"name":"meta.statement.event.fortran","patterns":[{"include":"#parentheses-dummy-variables"}]},"execution-statements":{"patterns":[{"include":"#allocate-statement"},{"include":"#deallocate-statement"},{"include":"#IO-statements"},{"include":"#nullify-statement"}]},"exit-statement":{"begin":"(?i)\\\\s*\\\\b(exit)\\\\b","beginCaptures":{"1":{"name":"keyword.control.exit.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.exit.fortran","patterns":[]},"explicit-interface-block-construct":{"begin":"(?i)\\\\b(interface)\\\\b(?=\\\\s*[\\\\n!;])","beginCaptures":{"1":{"name":"keyword.control.interface.fortran"}},"end":"(?i)\\\\b(end\\\\s*interface)\\\\b","endCaptures":{"1":{"name":"keyword.control.endinterface.fortran.modern"}},"name":"meta.interface.explicit.fortran","patterns":[{"include":"$base"}]},"extends-attribute":{"begin":"(?i)\\\\s*\\\\b(extends)\\\\s*\\\\(","beginCaptures":{"1":{"name":"storage.modifier.extends.fortran"}},"end":"\\\\)|(?=\\\\n)","patterns":[{"match":"(?i)\\\\s*\\\\b([a-z]\\\\w*)\\\\b","name":"entity.name.type.fortran"}]},"external-attribute":{"captures":{"1":{"name":"storage.modifier.external.fortran"}},"match":"(?i)\\\\s*\\\\b(external)\\\\b"},"fail-image-statement":{"captures":{"1":{"name":"keyword.control.fail-image.fortran"}},"match":"\\\\b(fail image)\\\\b","name":"meta.statement.fail-image.fortran"},"forall-construct":{"applyEndPatternLast":1,"begin":"(?i)\\\\b(forall)\\\\b","beginCaptures":{"1":{"name":"keyword.control.forall.fortran"}},"end":"(?<!\\\\G)","patterns":[{"begin":"(?i)\\\\G(?!\\\\s*[\\\\n!;])","end":"(?<!\\\\G)","name":"meta.loop-control.fortran","patterns":[{"include":"#parentheses"},{"include":"#invalid-word"}]},{"begin":"(?<=\\\\))(?=\\\\s*[\\\\n!;])","end":"(?i)\\\\b(end\\\\s*forall)\\\\b","endCaptures":{"1":{"name":"keyword.control.endforall.fortran"}},"name":"meta.block.forall.fortran","patterns":[{"include":"$base"}]},{"begin":"(?i)(?<=\\\\))(?!\\\\s*[\\\\n!;])","end":"\\\\n","name":"meta.statement.control.forall.fortran","patterns":[{"include":"$base"}]}]},"form-team-statement":{"begin":"(?i)\\\\b(form team)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"keyword.control.form-team.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"name":"meta.statement.form-team.fortran","patterns":[{"include":"#parentheses-dummy-variables"}]},"format-descriptor":{"begin":"\\\\(/","beginCaptures":{"0":{"name":"punctuation.bracket.left.fortran"}},"contentName":"meta.format-descriptor.fortran","end":"\\\\)","endCaptures":{"0":{"name":"punctuation.bracket.right.fortran"}},"patterns":[{"include":"#comments"},{"include":"#constants"},{"include":"#operators"},{"include":"#parentheses"},{"include":"#intrinsic-functions"},{"include":"#variable"}]},"format-descriptors":{"patterns":[{"captures":{"1":{"name":"keyword.other.format-descriptor.fortran"}},"match":"(?i)(?:\\\\b|(?<=\\\\d)|(?<=P))(EN|ES|EX|DT|DC|DP|RC|RD|RN|RP|RU|RZ|BN|BZ|SP|SS|TL|TR|[ABD-GILOPQSTXZ])(?=$|[^A-Z_a-z]|[D-G](?i))"},{"match":"/","name":"keyword.operator.format.newline.fortran"},{"match":":","name":"keyword.operator.format.separator.fortran"},{"match":"[$\\\\\\\\]","name":"keyword.other.format-descriptor.nonstandard.fortran"},{"match":"(?i)(?:\\\\b|(?<=\\\\d))\\\\d+H","name":"keyword.other.format-descriptor.legacy.fortran"}]},"format-parentheses":{"begin":"\\\\s*(\\\\()","beginCaptures":{"1":{"name":"punctuation.parentheses.left.fortran"}},"end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#comments"},{"include":"#line-continuation-operator"},{"match":"(?:\\\\b|[-+])\\\\d+(?=[A-Za-z])","name":"constant.numeric.fortran"},{"include":"#format-descriptors"},{"include":"#format-parentheses"},{"include":"#parentheses-common"}]},"function-definition":{"begin":"(?i)(?=([^\\\\n!\\"':;](?!\\\\bend)(?!\\\\bsubroutine\\\\b))*\\\\bfunction\\\\b)","end":"(?=[\\\\n!;])","name":"meta.function.fortran","patterns":[{"begin":"(?i)(?=\\\\G\\\\s*(?!\\\\bfunction\\\\b))","end":"(?i)(?=\\\\bfunction\\\\b)","name":"meta.attribute-list.function.fortran","patterns":[{"include":"#elemental-attribute"},{"include":"#module-attribute"},{"include":"#pure-attribute"},{"include":"#recursive-attribute"},{"include":"#types"},{"include":"#invalid-word"}]},{"begin":"(?i)\\\\b(function)\\\\b","beginCaptures":{"1":{"name":"keyword.other.function.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"begin":"(?i)\\\\G\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.function.fortran"}},"end":"(?i)\\\\s*\\\\b(?:(end\\\\s*function)(?:\\\\s+([_a-z]\\\\w*))?|(end))\\\\b\\\\s*([^\\\\n!;]+)?(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.other.endfunction.fortran"},"2":{"name":"entity.name.function.fortran"},"3":{"name":"keyword.other.endfunction.fortran"},"4":{"name":"invalid.error.function.fortran"}},"patterns":[{"begin":"\\\\G(?!\\\\s*[\\\\n!;])","end":"(?=[\\\\n!;])","name":"meta.function.first-line.fortran","patterns":[{"include":"#dummy-variable-list"},{"include":"#result-statement"},{"include":"#language-binding-attribute"}]},{"begin":"(?i)(?!\\\\bend(?:\\\\s*[\\\\n!;]|\\\\s*function\\\\b))","end":"(?i)(?=\\\\bend(?:\\\\s*[\\\\n!;]|\\\\s*function\\\\b))","name":"meta.block.specification.function.fortran","patterns":[{"begin":"(?i)\\\\b(contains)\\\\b","beginCaptures":{"1":{"name":"keyword.control.contains.fortran"}},"end":"(?i)(?=end(?:\\\\s*[\\\\n!;]|\\\\s*function\\\\b))","name":"meta.block.contains.fortran","patterns":[{"include":"$base"}]},{"include":"$base"}]}]}]}]},"generic-interface-block-construct":{"begin":"(?i)\\\\b(interface)\\\\b","beginCaptures":{"1":{"name":"keyword.control.interface.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.interface.generic.fortran","patterns":[{"begin":"(?i)\\\\G\\\\s*\\\\b(assignment)\\\\s*(\\\\()\\\\s*(?:(=)|(\\\\S.*))\\\\s*(\\\\))","beginCaptures":{"1":{"name":"keyword.other.assignment.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"},"3":{"name":"keyword.operator.assignment.fortran"},"4":{"name":"invalid.error.generic-interface.fortran"},"5":{"name":"punctuation.parentheses.right.fortran"}},"end":"(?i)\\\\b(end\\\\s*interface)\\\\b(?:\\\\s*\\\\b(\\\\1)\\\\b\\\\s*(\\\\()\\\\s*(?:(\\\\3)|(\\\\S.*))\\\\s*(\\\\)))?","endCaptures":{"1":{"name":"keyword.control.endinterface.fortran"},"2":{"name":"keyword.other.assignment.fortran"},"3":{"name":"punctuation.parentheses.left.fortran"},"4":{"name":"keyword.operator.assignment.fortran"},"5":{"name":"invalid.error.generic-interface-end.fortran"},"6":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#interface-procedure-statement"},{"include":"$base"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(operator)\\\\s*(\\\\()\\\\s*(?:(\\\\.[a-z]+\\\\.|==|/=|>=|[<>]|<=|[-+/]|//|\\\\*\\\\*?)|(\\\\S.*))\\\\s*(\\\\))","beginCaptures":{"1":{"name":"keyword.other.operator.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"},"3":{"name":"keyword.operator.fortran"},"4":{"name":"invalid.error.generic-interface-block-op.fortran"},"5":{"name":"punctuation.parentheses.right.fortran"}},"end":"(?i)\\\\b(end\\\\s*interface)\\\\b(?:\\\\s*\\\\b(\\\\1)\\\\b\\\\s*(\\\\()\\\\s*(?:(\\\\3)|(\\\\S.*))\\\\s*(\\\\)))?","endCaptures":{"1":{"name":"keyword.control.endinterface.fortran"},"2":{"name":"keyword.other.operator.fortran"},"3":{"name":"punctuation.parentheses.left.fortran"},"4":{"name":"keyword.operator.fortran"},"5":{"name":"invalid.error.generic-interface-block-op-end.fortran"},"6":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#interface-procedure-statement"},{"include":"$base"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(?:(read)|(write))\\\\s*(\\\\()\\\\s*(?:(formatted)|(unformatted)|(\\\\S.*))\\\\s*(\\\\))","beginCaptures":{"1":{"name":"keyword.other.read.fortran"},"2":{"name":"keyword.other.write.fortran"},"3":{"name":"punctuation.parentheses.left.fortran"},"4":{"name":"keyword.other.formatted.fortran"},"5":{"name":"keyword.other.unformatted.fortran"},"6":{"name":"invalid.error.generic-interface-block.fortran"},"7":{"name":"punctuation.parentheses.right.fortran"}},"end":"(?i)\\\\b(end\\\\s*interface)\\\\b(?:\\\\s*\\\\b(?:(\\\\2)|(\\\\3))\\\\b\\\\s*(\\\\()\\\\s*(?:(\\\\4)|(\\\\5)|(\\\\S.*))\\\\s*(\\\\)))?","endCaptures":{"1":{"name":"keyword.control.endinterface.fortran"},"2":{"name":"keyword.other.read.fortran"},"3":{"name":"keyword.other.write.fortran"},"4":{"name":"punctuation.parentheses.left.fortran"},"5":{"name":"keyword.other.formatted.fortran"},"6":{"name":"keyword.other.unformatted.fortran"},"7":{"name":"invalid.error.generic-interface-block-end.fortran"},"8":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#interface-procedure-statement"},{"include":"$base"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.function.fortran"}},"end":"(?i)\\\\b(end\\\\s*interface)\\\\b(?:\\\\s*\\\\b(\\\\1)\\\\b)?","endCaptures":{"1":{"name":"keyword.control.endinterface.fortran"},"2":{"name":"entity.name.function.fortran"}},"patterns":[{"include":"#interface-procedure-statement"},{"include":"$base"}]}]},"goto-statement":{"begin":"(?i)\\\\s*\\\\b(go\\\\s*to)\\\\b","beginCaptures":{"1":{"name":"keyword.control.goto.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.goto.fortran","patterns":[{"include":"$base"}]},"if-construct":{"patterns":[{"begin":"(?i)\\\\b(if)\\\\b","beginCaptures":{"1":{"name":"keyword.control.if.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#logical-control-expression"},{"begin":"(?i)\\\\s*\\\\b(then)\\\\b","beginCaptures":{"1":{"name":"keyword.control.then.fortran"}},"contentName":"meta.block.if.fortran","end":"(?i)\\\\b(end\\\\s*if)\\\\b","endCaptures":{"1":{"name":"keyword.control.endif.fortran"}},"patterns":[{"begin":"(?i)\\\\b(else\\\\s*if)\\\\b","beginCaptures":{"1":{"name":"keyword.control.elseif.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#parentheses"},{"captures":{"1":{"name":"keyword.control.then.fortran"},"2":{"name":"meta.label.elseif.fortran"}},"match":"(?i)\\\\b(then)\\\\b(\\\\s*[a-z]\\\\w*)?"},{"include":"#invalid-word"}]},{"begin":"(?i)\\\\b(else)\\\\b","beginCaptures":{"1":{"name":"keyword.control.else.fortran"}},"end":"(?i)(?=\\\\b(end\\\\s*if)\\\\b)","patterns":[{"begin":"(?!(\\\\s*([\\\\n!;])))","end":"\\\\s*(?=[\\\\n!;])","patterns":[{"captures":{"1":{"name":"meta.label.else.fortran"},"2":{"name":"invalid.error.label.else.fortran"}},"match":"(?i)\\\\s*([a-z]\\\\w*)?\\\\s*\\\\b(\\\\w*)\\\\b"},{"include":"#invalid-word"}]},{"begin":"(?i)(?!\\\\b(end\\\\s*if)\\\\b)","end":"(?i)(?=\\\\b(end\\\\s*if)\\\\b)","patterns":[{"include":"$base"}]}]},{"include":"$base"}]},{"begin":"(?i)(?=\\\\s*[a-z])","end":"(?=[\\\\n!;])","name":"meta.statement.control.if.fortran","patterns":[{"include":"$base"}]}]}]},"image-control-statement":{"patterns":[{"include":"#sync-all-statement"},{"include":"#sync-statement"},{"include":"#event-statement"},{"include":"#form-team-statement"},{"include":"#fail-image-statement"}]},"implicit-statement":{"begin":"(?i)\\\\b(implicit)\\\\b","beginCaptures":{"1":{"name":"keyword.other.implicit.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.implicit.fortran","patterns":[{"captures":{"1":{"name":"keyword.other.none.fortran"}},"match":"(?i)\\\\s*\\\\b(none)\\\\b"},{"include":"$base"}]},"import-statement":{"begin":"(?i)\\\\b(import)\\\\b","beginCaptures":{"1":{"name":"keyword.control.include.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.include.fortran","patterns":[{"begin":"(?i)\\\\G\\\\s*(?:(::)|(?=[a-z]))","beginCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#name-list"}]},{"begin":"\\\\G\\\\s*(,)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"captures":{"1":{"name":"keyword.other.all.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(all)\\\\b"},{"captures":{"1":{"name":"keyword.other.none.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(none)\\\\b"},{"begin":"(?i)\\\\G\\\\s*\\\\b(only)\\\\s*(:)","beginCaptures":{"1":{"name":"keyword.other.only.fortran"},"2":{"name":"keyword.other.colon.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#name-list"}]},{"include":"#invalid-word"}]}]},"include-statement":{"begin":"(?i)\\\\b(include)\\\\b","beginCaptures":{"1":{"name":"keyword.control.include.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.include.fortran","patterns":[{"include":"#string-constant"},{"include":"#invalid-character"}]},"intent-attribute":{"begin":"(?i)\\\\s*\\\\b(intent)\\\\s*(\\\\()","beginCaptures":{"1":{"name":"storage.modifier.intent.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(\\\\))|(?=[\\\\n!;])","endCaptures":{"1":{"name":"punctuation.parentheses.left.fortran"}},"patterns":[{"captures":{"1":{"name":"storage.modifier.intent.in-out.fortran"},"2":{"name":"storage.modifier.intent.in.fortran"},"3":{"name":"storage.modifier.intent.out.fortran"}},"match":"(?i)\\\\b(?:(in\\\\s*out)|(in)|(out))\\\\b"},{"include":"#invalid-word"}]},"interface-block-constructs":{"patterns":[{"include":"#abstract-interface-block-construct"},{"include":"#explicit-interface-block-construct"},{"include":"#generic-interface-block-construct"}]},"interface-procedure-statement":{"begin":"(?i)(?=[^\\\\n!\\"';]*\\\\bprocedure\\\\b)","end":"(?=[\\\\n!;])","name":"meta.statement.procedure.fortran","patterns":[{"begin":"(?i)(?=\\\\G\\\\s*(?!\\\\bprocedure\\\\b))","end":"(?i)(?=\\\\bprocedure\\\\b)","name":"meta.attribute-list.interface.fortran","patterns":[{"include":"#module-attribute"},{"include":"#invalid-word"}]},{"begin":"(?i)\\\\s*\\\\b(procedure)\\\\b","beginCaptures":{"1":{"name":"keyword.other.procedure.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"captures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"match":"\\\\G\\\\s*(::)"},{"include":"#procedure-name-list"}]}]},"intrinsic-attribute":{"captures":{"1":{"name":"storage.modifier.intrinsic.fortran"}},"match":"(?i)\\\\s*\\\\b(intrinsic)\\\\b"},"intrinsic-functions":{"patterns":[{"begin":"(?i)\\\\b(acosh|asinh|atanh|bge|bgt|ble|blt|dshiftl|dshiftr|findloc|hypot|iall|iany|image_index|iparity|is_contiguous|lcobound|leadz|mask[lr]|merge_bits|norm2|num_images|parity|popcnt|poppar|shift[alr]|storage_size|this_image|trailz|ucobound)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\b(bessel_[jy][01n]|erf(c(_scaled)?)?|gamma|log_gamma)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\b(command_argument_count|extends_type_of|is_iostat_end|is_iostat_eor|new_line|same_type_as|selected_char_kind)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\b(ieee_(class|copy_sign|is_(finite|nan|negative|normal)|logb|next_after|rem|rint|scalb|selected_real_kind|support_(datatype|denormal|divide|inf|io|nan|rounding|sqrt|standard|underflow_control)|unordered|value))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\b(ieee_support_(flag|halting))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\b(c_(associated|funloc|loc|sizeof))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\b(compiler_(options|version))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\b(null)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\b(achar|adjustl|adjustr|all|allocated|associated|any|bit_size|btest|ceiling|count|cshift|digits|dot_product|eoshift|epsilon|exponent|floor|fraction|huge|iachar|iand|ibclr|ibits|ibset|ieor|ior|ishftc?|kind|lbound|len_trim|logical|matmul|maxexponent|maxloc|maxval|merge|minexponent|minloc|minval|modulo|nearest|not|pack|precision|present|product|radix|range|repeat|reshape|rrspacing|scale|scan|selected_(int|real)_kind|set_exponent|shape|size|spacing|spread|sum|tiny|transfer|transpose|trim|ubound|unpack|verify)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\b([cdi]?abs|acos|[ad]int|[ad]nint|aimag|amax[01]|amin[01]|d?asin|d?atan|d?atan2|char|conjg|[cd]?cos|d?cosh|cmplx|dble|i?dim|dmax1|dmin1|dprod|[cd]?exp|float|ichar|idint|ifix|index|int|len|lge|lgt|lle|llt|[acd]?log|[ad]?log10|max[01]?|min[01]?|[ad]?mod|(id)?nint|real|[di]?sign|[cd]?sin|d?sinh|sngl|[cd]?sqrt|d?tan|d?tanh)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"support.function.intrinsic.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]}]},"intrinsic-subroutines":{"patterns":[{"begin":"(?i)\\\\G\\\\s*\\\\b(date_and_time|mvbits|random_number|random_seed|system_clock)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"entity.name.function.subroutine.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(cpu_time)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"entity.name.function.subroutine.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(ieee_([gs]et)_(rounding|underflow)_mode)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"entity.name.function.subroutine.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(ieee_([gs]et)_(flag|halting_mode|status))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"entity.name.function.subroutine.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(c_f_(p(?:|rocp)ointer))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"entity.name.function.subroutine.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(execute_command_line|get_command|get_command_argument|get_environment_variable|move_alloc)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"entity.name.function.subroutine.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]}]},"invalid-character":{"match":"(?i)[^\\\\n!;\\\\s]+","name":"invalid.error.character.fortran"},"invalid-word":{"match":"(?i)\\\\b\\\\w+\\\\b","name":"invalid.error.word.fortran"},"language-binding-attribute":{"begin":"(?i)\\\\s*\\\\b(bind)\\\\s*\\\\(","beginCaptures":{"1":{"name":"storage.modifier.bind.fortran"}},"end":"\\\\)|(?=\\\\n)","patterns":[{"match":"(?i)\\\\b(c)\\\\b","name":"variable.parameter.fortran"},{"include":"#dummy-variable"},{"include":"$base"}]},"line-continuation-operator":{"patterns":[{"captures":{"1":{"name":"keyword.operator.line-continuation.fortran"}},"match":"(?:^|(?<=;))\\\\s*(&)"},{"begin":"\\\\s*(&)","beginCaptures":{"1":{"name":"keyword.operator.line-continuation.fortran"}},"contentName":"meta.line-continuation.fortran","end":"(?i)^(?:\\\\s*(&))?","endCaptures":{"1":{"name":"keyword.operator.line-continuation.fortran"}},"patterns":[{"include":"#comments"},{"match":"\\\\S[^!]*","name":"invalid.error.line-cont.fortran"}]}]},"logical-constant":{"captures":{"1":{"name":"constant.language.logical.false.fortran"},"2":{"name":"constant.language.logical.true.fortran"}},"match":"(?i)\\\\s*(?:(\\\\.false\\\\.)|(\\\\.true\\\\.))"},"logical-control-expression":{"begin":"\\\\G(?=\\\\s*\\\\()","end":"(?<!\\\\G)","name":"meta.expression.control.logical.fortran","patterns":[{"include":"#parentheses"}]},"logical-operators":{"patterns":[{"match":"(?i)(\\\\s*\\\\.(and|eqv??|le|lt|ge|gt|ne|neqv|not|or)\\\\.)","name":"keyword.logical.fortran"},{"match":"(==|/=|>=|(?<!=)>|<=?)","name":"keyword.logical.fortran.modern"}]},"logical-type":{"patterns":[{"begin":"(?i)\\\\b(logical)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"storage.type.logical.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"contentName":"meta.type-spec.fortran","end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"captures":{"1":{"name":"storage.type.character.fortran"},"2":{"name":"keyword.operator.multiplication.fortran"},"3":{"name":"constant.numeric.fortran"}},"match":"(?i)\\\\b(logical)\\\\b(?:\\\\s*(\\\\*)\\\\s*(\\\\d*))?"}]},"module-attribute":{"captures":{"1":{"name":"storage.modifier.module.fortran"}},"match":"(?i)\\\\s*\\\\b(module)\\\\b(?=\\\\s*(?:[\\\\n!;]|[^\\\\n!\\"';]*\\\\b(?:function|procedure|subroutine)\\\\b))"},"module-definition":{"begin":"(?i)(?=\\\\b(module)\\\\b)(?![^\\\\n!\\"';]*\\\\b(?:function|procedure|subroutine)\\\\b)","end":"(?=[\\\\n!;])","name":"meta.module.fortran","patterns":[{"captures":{"1":{"name":"keyword.other.program.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(module)\\\\b"},{"applyEndPatternLast":1,"begin":"(?i)\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.class.module.fortran"}},"end":"(?i)\\\\b(?:(end\\\\s*module)(?:\\\\s+([_a-z]\\\\w*))?|(end))\\\\b\\\\s*([^\\\\n!;]+)?(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.other.endmodule.fortran"},"2":{"name":"entity.name.class.module.fortran"},"3":{"name":"keyword.other.endmodule.fortran"},"4":{"name":"invalid.error.module-definition.fortran"}},"patterns":[{"begin":"\\\\G","end":"(?i)(?=\\\\bend(?:\\\\s*[\\\\n!;]|\\\\s*module\\\\b))","name":"meta.block.specification.module.fortran","patterns":[{"begin":"(?i)\\\\b(contains)\\\\b","beginCaptures":{"1":{"name":"keyword.control.contains.fortran"}},"end":"(?i)(?=\\\\s*end(?:\\\\s*[\\\\n!;]|\\\\s*module\\\\b))","name":"meta.block.contains.fortran","patterns":[{"include":"$base"}]},{"include":"$base"}]}]}]},"name-list":{"begin":"(?i)(?=\\\\s*[a-z])","contentName":"meta.name-list.fortran","end":"(?=[\\\\n!);])","patterns":[{"include":"#constants"},{"include":"#operators"},{"include":"#intrinsic-functions"},{"include":"#array-constructor"},{"include":"#parentheses"},{"include":"#brackets"},{"include":"#assignment-keyword"},{"include":"#operator-keyword"},{"include":"#variable"}]},"named-control-constructs":{"applyEndPatternLast":1,"begin":"(?i)([a-z]\\\\w*)\\\\s*(:)(?=\\\\s*(?:associate|block(?!\\\\s*data)|critical|do|forall|if|select\\\\s*case|select\\\\s*type|select\\\\s*rank|where)\\\\b)","contentName":"meta.named-construct.fortran.modern","end":"(?i)(?!\\\\s*\\\\b(?:associate|block(?!\\\\s*data)|critical|do|forall|if|select\\\\s*case|select\\\\s*type|select\\\\s*rank|where)\\\\b)(?:\\\\b(\\\\1)\\\\b)?([^\\\\n!;\\\\s]*?)?(?=\\\\s*[\\\\n!;])","endCaptures":{"1":{"name":"meta.label.end.name.fortran"},"2":{"name":"invalid.error.named-control-constructs.fortran.modern"}},"patterns":[{"include":"#unnamed-control-constructs"}]},"namelist-statement":{"begin":"(?i)\\\\b(namelist)\\\\b","beginCaptures":{"1":{"name":"keyword.control.namelist.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"$base"}]},"non-intrinsic-attribute":{"captures":{"1":{"name":"storage.modifier.non-intrinsic.fortran"}},"match":"(?i)\\\\s*\\\\b(non_intrinsic)\\\\b"},"non-overridable-attribute":{"captures":{"1":{"name":"storage.modifier.non-overridable.fortran"}},"match":"(?i)\\\\s*\\\\b(non_overridable)\\\\b"},"nopass-attribute":{"captures":{"1":{"name":"storage.modifier.nopass.fortran"}},"match":"(?i)\\\\s*\\\\b(nopass)\\\\b"},"nullify-statement":{"begin":"(?i)\\\\b(nullify)\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"keyword.control.nullify.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"name":"meta.statement.nullify.fortran","patterns":[{"include":"#parentheses-dummy-variables"}]},"numeric-constant":{"match":"(?i)[-+]?(\\\\b\\\\d+\\\\.?\\\\d*|\\\\.\\\\d+)(_\\\\w+|d[-+]?\\\\d+|e[-+]?\\\\d+(_\\\\w+)?)?(?![_a-z])","name":"constant.numeric.fortran"},"numeric-type":{"patterns":[{"begin":"(?i)\\\\b(?:(complex)|(double\\\\s*precision)|(double\\\\s*complex)|(integer)|(real))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"storage.type.complex.fortran"},"2":{"name":"storage.type.double.fortran"},"3":{"name":"storage.type.doublecomplex.fortran"},"4":{"name":"storage.type.integer.fortran"},"5":{"name":"storage.type.real.fortran"},"6":{"name":"punctuation.parentheses.left.fortran"}},"contentName":"meta.type-spec.fortran","end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#parentheses-dummy-variables"}]},{"captures":{"1":{"name":"storage.type.complex.fortran"},"2":{"name":"storage.type.double.fortran"},"3":{"name":"storage.type.doublecomplex.fortran"},"4":{"name":"storage.type.integer.fortran"},"5":{"name":"storage.type.real.fortran"},"6":{"name":"storage.type.dimension.fortran"},"7":{"name":"keyword.operator.multiplication.fortran"},"8":{"name":"constant.numeric.fortran"}},"match":"(?i)\\\\b(?:(complex)|(double\\\\s*precision)|(double\\\\s*complex)|(integer)|(real)|(dimension))\\\\b(?:\\\\s*(\\\\*)\\\\s*(\\\\d*))?"}]},"operator-keyword":{"begin":"(?i)\\\\s*\\\\b(operator)\\\\s*(\\\\()","beginCaptures":{"1":{"name":"keyword.control.generic-spec.operator.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#arithmetic-operators"},{"include":"#logical-operators"},{"include":"#user-defined-operators"},{"include":"#invalid-word"}]},"operators":{"patterns":[{"include":"#arithmetic-operators"},{"include":"#assignment-operator"},{"include":"#derived-type-operators"},{"include":"#logical-operators"},{"include":"#pointer-operators"},{"include":"#string-operators"},{"include":"#user-defined-operators"}]},"optional-attribute":{"captures":{"1":{"name":"storage.modifier.optional.fortran"}},"match":"(?i)\\\\s*\\\\b(optional)\\\\b"},"parameter-attribute":{"captures":{"1":{"name":"storage.modifier.parameter.fortran"}},"match":"(?i)\\\\s*\\\\b(parameter)\\\\b"},"parentheses":{"begin":"\\\\s*(\\\\()","beginCaptures":{"1":{"name":"punctuation.parentheses.left.fortran"}},"end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#array-constructor"},{"include":"#parentheses"},{"include":"#parentheses-common"}]},"parentheses-common":{"patterns":[{"include":"#comments"},{"include":"#constants"},{"include":"#operators"},{"include":"#intrinsic-functions"},{"include":"#variable"}]},"parentheses-dummy-variables":{"begin":"\\\\s*(\\\\()","beginCaptures":{"1":{"name":"punctuation.parentheses.left.fortran"}},"end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#procedure-call-dummy-variable"},{"include":"#array-constructor"},{"include":"#parentheses"},{"include":"#parentheses-common"}]},"pass-attribute":{"patterns":[{"begin":"(?i)\\\\s*\\\\b(pass)\\\\s*\\\\(","beginCaptures":{"1":{"name":"storage.modifier.pass.fortran"}},"end":"\\\\)|(?=\\\\n)","patterns":[]},{"captures":{"1":{"name":"storage.modifier.pass.fortran"}},"match":"(?i)\\\\s*\\\\b(pass)\\\\b"}]},"pause-statement":{"begin":"(?i)\\\\s*\\\\b(pause)\\\\b","beginCaptures":{"1":{"name":"keyword.control.pause.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.pause.fortran","patterns":[{"include":"#constants"},{"include":"#invalid-character"}]},"pointer-attribute":{"captures":{"1":{"name":"storage.modifier.pointer.fortran"}},"match":"(?i)\\\\s*\\\\b(pointer)\\\\b"},"pointer-operators":{"match":"(=>)","name":"keyword.other.point.fortran"},"preprocessor":{"begin":"^\\\\s*(#:?)","beginCaptures":{"1":{"name":"keyword.control.preprocessor.indicator.fortran"}},"end":"\\\\n","name":"meta.preprocessor","patterns":[{"include":"#preprocessor-if-construct"},{"include":"#preprocessor-statements"}]},"preprocessor-arithmetic-operators":{"captures":{"1":{"name":"keyword.operator.subtraction.fortran"},"2":{"name":"keyword.operator.addition.fortran"},"3":{"name":"keyword.operator.division.fortran"},"4":{"name":"keyword.operator.multiplication.fortran"}},"match":"(-)|(\\\\+)|(/)|(\\\\*)"},"preprocessor-assignment-operator":{"match":"(?<!=)(=)(?!=)","name":"keyword.operator.assignment.preprocessor.fortran"},"preprocessor-comments":{"begin":"/\\\\*","end":"\\\\*/","name":"comment.preprocessor"},"preprocessor-constants":{"patterns":[{"include":"#cpp-numeric-constant"},{"include":"#preprocessor-string-constant"}]},"preprocessor-define-statement":{"begin":"(?i)\\\\G\\\\s*\\\\b(define)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.define.fortran"}},"end":"(?=\\\\n)","name":"meta.preprocessor.macro.fortran","patterns":[{"include":"#preprocessor-comments"},{"include":"#preprocessor-constants"},{"include":"#preprocessor-line-continuation-operator"}]},"preprocessor-defined-function":{"captures":{"1":{"name":"keyword.control.preprocessor.defined.fortran"}},"match":"(?i)\\\\b(defined)\\\\b"},"preprocessor-error-statement":{"begin":"(?i)\\\\G\\\\s*(error)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.error.fortran"}},"end":"(?=\\\\n)","name":"meta.preprocessor.macro.fortran","patterns":[{"include":"#preprocessor-comments"},{"include":"#preprocessor-string-constant"},{"include":"#preprocessor-line-continuation-operator"}]},"preprocessor-if-construct":{"patterns":[{"begin":"(?i)\\\\G\\\\s*\\\\b(if)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.if.fortran"}},"end":"(?=\\\\n)","name":"meta.preprocessor.conditional.fortran","patterns":[{"include":"#preprocessor-comments"},{"include":"#cpp-numeric-constant"},{"include":"#preprocessor-logical-operators"},{"include":"#preprocessor-arithmetic-operators"},{"include":"#preprocessor-defined-function"},{"include":"#preprocessor-line-continuation-operator"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(ifdef)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.ifdef.fortran"}},"end":"(?=\\\\n)","patterns":[{"include":"#preprocessor-comments"},{"include":"#cpp-numeric-constant"},{"include":"#preprocessor-logical-operators"},{"include":"#preprocessor-arithmetic-operators"},{"include":"#preprocessor-line-continuation-operator"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(ifndef)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.ifndef.fortran"}},"end":"(?=\\\\n)","patterns":[{"include":"#preprocessor-comments"},{"include":"#cpp-numeric-constant"},{"include":"#preprocessor-logical-operators"},{"include":"#preprocessor-arithmetic-operators"},{"include":"#preprocessor-line-continuation-operator"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(else)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.else.fortran"}},"end":"(?=\\\\n)","patterns":[{"include":"#preprocessor-comments"},{"include":"#cpp-numeric-constant"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(elif)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.elif.fortran"}},"end":"(?=\\\\n)","patterns":[{"include":"#preprocessor-comments"},{"include":"#cpp-numeric-constant"},{"include":"#preprocessor-logical-operators"},{"include":"#preprocessor-arithmetic-operators"},{"include":"#preprocessor-defined-function"},{"include":"#preprocessor-line-continuation-operator"}]},{"begin":"(?i)\\\\G\\\\s*\\\\b(endif)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.endif.fortran"}},"end":"(?=\\\\n)","patterns":[{"include":"#preprocessor-comments"}]}]},"preprocessor-include-statement":{"begin":"(?i)\\\\G\\\\s*(include)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.include.fortran"}},"end":"(?=\\\\n)","name":"meta.preprocessor.include.fortran","patterns":[{"include":"#preprocessor-comments"},{"include":"#preprocessor-string-constant"},{"begin":"<","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.preprocessor.fortran"}},"end":">","endCaptures":{"0":{"name":"punctuation.definition.string.end.preprocessor.fortran"}},"name":"string.quoted.other.lt-gt.include.preprocessor.fortran"},{"include":"#line-continuation-operator"}]},"preprocessor-line-continuation-operator":{"begin":"\\\\s*(\\\\\\\\)","beginCaptures":{"1":{"name":"constant.character.escape.line-continuation.preprocessor.fortran"}},"end":"(?i)^"},"preprocessor-logical-operators":{"captures":{"1":{"name":"keyword.operator.logical.preprocessor.and.fortran"},"2":{"name":"keyword.operator.logical.preprocessor.equals.fortran"},"3":{"name":"keyword.operator.logical.preprocessor.not_equals.fortran"},"4":{"name":"keyword.operator.logical.preprocessor.or.fortran"},"5":{"name":"keyword.operator.logical.preprocessor.less_eq.fortran"},"6":{"name":"keyword.operator.logical.preprocessor.more_eq.fortran"},"7":{"name":"keyword.operator.logical.preprocessor.less.fortran"},"8":{"name":"keyword.operator.logical.preprocessor.more.fortran"},"9":{"name":"keyword.operator.logical.preprocessor.complementary.fortran"},"10":{"name":"keyword.operator.logical.preprocessor.xor.fortran"},"11":{"name":"keyword.operator.logical.preprocessor.bitand.fortran"},"12":{"name":"keyword.operator.logical.preprocessor.not.fortran"},"13":{"name":"keyword.operator.logical.preprocessor.bitor.fortran"}},"match":"(&&)|(==)|(!=)|(\\\\|\\\\|)|(<=)|(>=)|(<)|(>)|(~)|(\\\\^)|(&)|(!)|(\\\\|)","name":"keyword.operator.logical.preprocessor.fortran"},"preprocessor-operators":{"patterns":[{"include":"#preprocessor-line-continuation-operator"},{"include":"#preprocessor-logical-operators"},{"include":"#preprocessor-arithmetic-operators"}]},"preprocessor-pragma-statement":{"begin":"(?i)\\\\G\\\\s*\\\\b(pragma)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.pragma.fortran"}},"end":"(?=\\\\n)","name":"meta.preprocessor.pragma.fortran","patterns":[{"include":"#preprocessor-comments"},{"include":"#preprocessor-string-constant"}]},"preprocessor-statements":{"patterns":[{"include":"#preprocessor-define-statement"},{"include":"#preprocessor-error-statement"},{"include":"#preprocessor-include-statement"},{"include":"#preprocessor-preprocessor-pragma-statement"},{"include":"#preprocessor-undefine-statement"}]},"preprocessor-string-constant":{"patterns":[{"begin":"\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.preprocessor.fortran"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.preprocessor.fortran"}},"name":"string.quoted.double.include.preprocessor.fortran"},{"begin":"'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.preprocessor.fortran"}},"end":"'","endCaptures":{"0":{"name":"punctuation.definition.string.end.preprocessor.fortran"}},"name":"string.quoted.single.include.preprocessor.fortran"}]},"preprocessor-undefine-statement":{"begin":"(?i)\\\\G\\\\s*\\\\b(undef)\\\\b","beginCaptures":{"1":{"name":"keyword.control.preprocessor.undef.fortran"}},"end":"(?=\\\\n)","name":"meta.preprocessor.undef.fortran","patterns":[{"include":"#preprocessor-comments"},{"include":"#preprocessor-line-continuation-operator"}]},"private-attribute":{"captures":{"1":{"name":"storage.modifier.private.fortran"}},"match":"(?i)\\\\s*\\\\b(private)\\\\b"},"procedure-call-dummy-variable":{"match":"(?i)\\\\s*([a-z]\\\\w*)(?=\\\\s*=)(?!\\\\s*==)","name":"variable.parameter.dummy-variable.fortran.modern"},"procedure-definition":{"begin":"(?i)(?=[^\\\\n!\\"';]*\\\\bmodule\\\\s+procedure\\\\b)","end":"(?=[\\\\n!;])","name":"meta.procedure.fortran","patterns":[{"begin":"(?i)\\\\s*\\\\b(module\\\\s+procedure)\\\\b","beginCaptures":{"1":{"name":"keyword.other.procedure.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"begin":"(?i)\\\\G\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.function.procedure.fortran"}},"end":"(?i)\\\\s*\\\\b(?:(end\\\\s*procedure)(?:\\\\s+([_a-z]\\\\w*))?|(end))\\\\b\\\\s*([^\\\\n!;]+)?(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.other.endprocedure.fortran"},"2":{"name":"entity.name.function.procedure.fortran"},"3":{"name":"keyword.other.endprocedure.fortran"},"4":{"name":"invalid.error.procedure-definition.fortran"}},"patterns":[{"begin":"\\\\G(?!\\\\s*[\\\\n!;])","end":"(?=[\\\\n!;])","name":"meta.first-line.fortran","patterns":[{"include":"#invalid-character"}]},{"begin":"(?i)(?!\\\\s*(?:contains\\\\b|end\\\\s*[\\\\n!;]|end\\\\s*procedure\\\\b))","end":"(?i)(?=\\\\s*(?:contains\\\\b|end\\\\s*[\\\\n!;]|end\\\\s*procedure\\\\b))","name":"meta.block.specification.procedure.fortran","patterns":[{"include":"$self"}]},{"begin":"(?i)\\\\s*(contains)\\\\b","beginCaptures":{"1":{"name":"keyword.control.contains.fortran"}},"end":"(?i)(?=\\\\s*end(?:\\\\s*[\\\\n!;]|\\\\s*procedure\\\\b))","name":"meta.block.contains.fortran","patterns":[{"include":"$self"}]}]}]}]},"procedure-name":{"captures":{"1":{"name":"entity.name.function.procedure.fortran"}},"match":"(?i)\\\\s*\\\\b([a-z]\\\\w*)\\\\b"},"procedure-name-list":{"begin":"(?i)(?=\\\\s*[a-z])","contentName":"meta.name-list.fortran","end":"(?=[\\\\n!;])","patterns":[{"begin":"(?!\\\\s*\\\\n)","end":"(,)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"punctuation.comma.fortran"}},"patterns":[{"include":"#procedure-name"},{"include":"#pointer-operators"}]}]},"procedure-specification-statement":{"begin":"(?i)(?=\\\\bprocedure\\\\b)","end":"(?=[\\\\n!;])","name":"meta.specification.procedure.fortran","patterns":[{"include":"#procedure-type"},{"begin":"(?=\\\\s*(,|::|\\\\())","contentName":"meta.attribute-list.procedure.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"begin":"(,)|^|(?<=&)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=::|[\\\\n!\\\\&,;])","patterns":[{"include":"#access-attribute"},{"include":"#intent-attribute"},{"include":"#optional-attribute"},{"include":"#pointer-attribute"},{"include":"#protected-attribute"},{"include":"#save-attribute"},{"include":"#invalid-word"}]}]},{"include":"#procedure-name-list"}]},"procedure-type":{"patterns":[{"begin":"(?i)\\\\b(procedure)\\\\s*(\\\\()","beginCaptures":{"1":{"name":"storage.type.procedure.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"contentName":"meta.type-spec.fortran","end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#types"},{"include":"#procedure-name"}]},{"captures":{"1":{"name":"storage.type.procedure.fortran"}},"match":"(?i)\\\\b(procedure)\\\\b"}]},"program-definition":{"begin":"(?i)(?=\\\\b(program)\\\\b)","end":"(?=[\\\\n!;])","name":"meta.program.fortran","patterns":[{"captures":{"1":{"name":"keyword.control.program.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(program)\\\\b"},{"applyEndPatternLast":1,"begin":"(?i)\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.program.fortran"}},"end":"(?i)\\\\b(?:(end\\\\s*program)(?:\\\\s+([_a-z]\\\\w*))?|(end))\\\\b\\\\s*([^\\\\n!;]+)?(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.control.endprogram.fortran"},"2":{"name":"entity.name.program.fortran"},"3":{"name":"keyword.control.endprogram.fortran"},"4":{"name":"invalid.error.program-definition.fortran"}},"patterns":[{"begin":"\\\\G","end":"(?i)(?=\\\\bend(?:\\\\s*[\\\\n!;]|\\\\s*program\\\\b))","name":"meta.block.specification.program.fortran","patterns":[{"begin":"(?i)\\\\b(contains)\\\\b","beginCaptures":{"1":{"name":"keyword.control.contains.fortran"}},"end":"(?i)(?=end(?:\\\\s*[\\\\n!;]|\\\\s*program\\\\b))","name":"meta.block.contains.fortran","patterns":[{"include":"$base"}]},{"include":"$base"}]}]}]},"protected-attribute":{"captures":{"1":{"name":"storage.modifier.protected.fortran"}},"match":"(?i)\\\\s*\\\\b(protected)\\\\b"},"public-attribute":{"captures":{"1":{"name":"storage.modifier.public.fortran"}},"match":"(?i)\\\\s*\\\\b(public)\\\\b"},"pure-attribute":{"captures":{"1":{"name":"storage.modifier.impure.fortran"},"2":{"name":"storage.modifier.pure.fortran"}},"match":"(?i)\\\\s*\\\\b(?:(impure)|(pure))\\\\b"},"recursive-attribute":{"captures":{"1":{"name":"storage.modifier.non_recursive.fortran"},"2":{"name":"storage.modifier.recursive.fortran"}},"match":"(?i)\\\\s*\\\\b(?:(non_recursive)|(recursive))\\\\b"},"result-statement":{"begin":"(?i)\\\\s*\\\\b(result)\\\\s*(\\\\()","beginCaptures":{"1":{"name":"keyword.control.result.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"patterns":[{"include":"#dummy-variable"}]},"return-statement":{"begin":"(?i)\\\\s*\\\\b(return)\\\\b","beginCaptures":{"1":{"name":"keyword.control.return.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.return.fortran","patterns":[{"include":"#invalid-character"}]},"save-attribute":{"captures":{"1":{"name":"storage.modifier.save.fortran"}},"match":"(?i)\\\\s*\\\\b(save)\\\\b"},"select-case-construct":{"begin":"(?i)\\\\b(select\\\\s*case)\\\\b","beginCaptures":{"1":{"name":"keyword.control.selectcase.fortran"}},"end":"(?i)\\\\b(end\\\\s*select)\\\\b","endCaptures":{"1":{"name":"keyword.control.endselect.fortran"}},"name":"meta.block.select.case.fortran","patterns":[{"include":"#parentheses"},{"begin":"(?i)\\\\b(case)\\\\b","beginCaptures":{"1":{"name":"keyword.control.case.fortran"}},"end":"(?i)(?=[\\\\n!;])","patterns":[{"captures":{"1":{"name":"keyword.control.default.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(default)\\\\b"},{"include":"#parentheses"},{"include":"#invalid-word"}]},{"include":"$base"}]},"select-rank-construct":{"begin":"(?i)\\\\b(select\\\\s*rank)\\\\b","beginCaptures":{"1":{"name":"keyword.control.selectrank.fortran"}},"end":"(?i)\\\\b(end\\\\s*select)\\\\b","endCaptures":{"1":{"name":"keyword.control.endselect.fortran"}},"name":"meta.block.select.rank.fortran","patterns":[{"include":"#parentheses"},{"begin":"(?i)\\\\b(rank)\\\\b","beginCaptures":{"1":{"name":"keyword.control.rank.fortran"}},"end":"(?i)(?=[\\\\n!;])","patterns":[{"captures":{"1":{"name":"keyword.control.default.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(default)\\\\b"},{"include":"#parentheses"},{"include":"#invalid-word"}]},{"include":"$base"}]},"select-type-construct":{"begin":"(?i)\\\\b(select\\\\s*type)\\\\b","beginCaptures":{"1":{"name":"keyword.control.selecttype.fortran"}},"end":"(?i)\\\\b(end\\\\s*select)\\\\b","endCaptures":{"1":{"name":"keyword.control.endselect.fortran"}},"name":"meta.block.select.type.fortran","patterns":[{"include":"#parentheses"},{"begin":"(?i)\\\\b(?:(class)|(type))\\\\b","beginCaptures":{"1":{"name":"keyword.control.class.fortran"},"2":{"name":"keyword.control.type.fortran"}},"end":"(?i)(?=[\\\\n!;])","patterns":[{"captures":{"1":{"name":"keyword.control.default.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(default)\\\\b"},{"captures":{"1":{"name":"keyword.control.is.fortran"}},"match":"(?i)\\\\G\\\\s*\\\\b(is)\\\\b"},{"include":"#parentheses"},{"include":"#invalid-word"}]},{"include":"$base"}]},"sequence-attribute":{"captures":{"1":{"name":"storage.modifier.sequence.fortran"}},"match":"(?i)\\\\s*\\\\b(sequence)\\\\b"},"specification-statements":{"patterns":[{"include":"#attribute-specification-statement"},{"include":"#common-statement"},{"include":"#data-statement"},{"include":"#equivalence-statement"},{"include":"#implicit-statement"},{"include":"#namelist-statement"},{"include":"#use-statement"}]},"stop-statement":{"begin":"(?i)\\\\s*\\\\b(stop)\\\\b(?:\\\\s*\\\\b([a-z]\\\\w*)\\\\b)?","beginCaptures":{"1":{"name":"keyword.control.stop.fortran"},"2":{"name":"meta.label.stop.stop"}},"end":"(?=[\\\\n!;])","name":"meta.statement.control.stop.fortran","patterns":[{"include":"#constants"},{"include":"#string-operators"},{"include":"#invalid-character"}]},"string-constant":{"patterns":[{"applyEndPatternLast":1,"begin":"'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.fortran"}},"end":"'","endCaptures":{"0":{"name":"punctuation.definition.string.end.fortran"}},"name":"string.quoted.single.fortran","patterns":[{"match":"''","name":"constant.character.escape.apostrophe.fortran"}]},{"applyEndPatternLast":1,"begin":"\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.fortran"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.fortran"}},"name":"string.quoted.double.fortran","patterns":[{"match":"\\"\\"","name":"constant.character.escape.quote.fortran"}]}]},"string-line-continuation-operator":{"begin":"(&)(?=\\\\s*\\\\n)","beginCaptures":{"1":{"name":"keyword.operator.line-continuation.fortran"}},"end":"(?i)^(?:(?=\\\\s*[^!\\\\&\\\\s])|\\\\s*(&))","endCaptures":{"1":{"name":"keyword.operator.line-continuation.fortran"}},"patterns":[{"include":"#comments"},{"match":"\\\\S.*","name":"invalid.error.string-line-cont.fortran"}]},"string-operators":{"match":"(//)","name":"keyword.other.concatination.fortran"},"submodule-definition":{"begin":"(?i)(?=\\\\b(submodule)\\\\s*\\\\()","end":"(?=[\\\\n!;])","name":"meta.submodule.fortran","patterns":[{"begin":"(?i)\\\\G\\\\s*\\\\b(submodule)\\\\s*(\\\\()\\\\s*(\\\\w+)","beginCaptures":{"1":{"name":"keyword.other.submodule.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"},"3":{"name":"entity.name.class.submodule.fortran"}},"end":"(\\\\))","endCaptures":{"1":{"name":"punctuation.parentheses.left.fortran"}},"patterns":[]},{"applyEndPatternLast":1,"begin":"(?i)\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.module.submodule.fortran"}},"end":"(?i)\\\\s*\\\\b(?:(end\\\\s*submodule)(?:\\\\s+([_a-z]\\\\w*))?|(end))\\\\b\\\\s*([^\\\\n!;]+)?(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.other.endsubmodule.fortran"},"2":{"name":"entity.name.module.submodule.fortran"},"3":{"name":"keyword.other.endsubmodule.fortran"},"4":{"name":"invalid.error.submodule.fortran"}},"patterns":[{"begin":"\\\\G","end":"(?i)(?=\\\\bend(?:\\\\s*[\\\\n!;]|\\\\s*submodule\\\\b))","name":"meta.block.specification.submodule.fortran","patterns":[{"begin":"(?i)\\\\b(contains)\\\\b","beginCaptures":{"1":{"name":"keyword.control.contains.fortran"}},"end":"(?i)(?=\\\\s*end(?:\\\\s*[\\\\n!;]|\\\\s*submodule\\\\b))","name":"meta.block.contains.fortran","patterns":[{"include":"$base"}]},{"include":"$base"}]}]}]},"subroutine-definition":{"begin":"(?i)(?=([^\\\\n!\\"':;](?!\\\\bend))*\\\\bsubroutine\\\\b)","end":"(?=[\\\\n!;])","name":"meta.subroutine.fortran","patterns":[{"begin":"(?i)(?=\\\\G\\\\s*(?!\\\\bsubroutine\\\\b))","end":"(?i)(?=\\\\bsubroutine\\\\b)","name":"meta.attribute-list.subroutine.fortran","patterns":[{"include":"#elemental-attribute"},{"include":"#module-attribute"},{"include":"#pure-attribute"},{"include":"#recursive-attribute"},{"include":"#invalid-word"}]},{"begin":"(?i)\\\\s*\\\\b(subroutine)\\\\b","beginCaptures":{"1":{"name":"keyword.other.subroutine.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"begin":"(?i)\\\\G\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.function.subroutine.fortran"}},"end":"(?i)\\\\b(?:(end\\\\s*subroutine)(?:\\\\s+([_a-z]\\\\w*))?|(end))\\\\b\\\\s*([^\\\\n!;]+)?(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.other.endsubroutine.fortran"},"2":{"name":"entity.name.function.subroutine.fortran"},"3":{"name":"keyword.other.endsubroutine.fortran"},"4":{"name":"invalid.error.subroutine.fortran"}},"patterns":[{"begin":"\\\\G(?!\\\\s*[\\\\n!;])","end":"(?=[\\\\n!;])","name":"meta.first-line.fortran","patterns":[{"include":"#dummy-variable-list"},{"include":"#language-binding-attribute"}]},{"begin":"(?i)(?!\\\\bend(?:\\\\s*[\\\\n!;]|\\\\s*subroutine\\\\b))","end":"(?i)(?=\\\\bend(?:\\\\s*[\\\\n!;]|\\\\s*subroutine\\\\b))","name":"meta.block.specification.subroutine.fortran","patterns":[{"begin":"(?i)\\\\b(contains)\\\\b","beginCaptures":{"1":{"name":"keyword.control.contains.fortran"}},"end":"(?i)(?=end(?:\\\\s*[\\\\n!;]|\\\\s*subroutine\\\\b))","name":"meta.block.contains.fortran","patterns":[{"include":"$base"}]},{"include":"$base"}]}]}]}]},"sync-all-statement":{"begin":"(?i)\\\\b(sync (?:all|memory))(\\\\s*(?=\\\\())?","beginCaptures":{"1":{"name":"keyword.control.sync-all-memory.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"name":"meta.statement.sync-all-memory.fortran","patterns":[{"include":"#parentheses-dummy-variables"}]},"sync-statement":{"begin":"(?i)\\\\b(sync (?:images|team))\\\\s*(?=\\\\()","beginCaptures":{"1":{"name":"keyword.control.sync-images-team.fortran"},"2":{"name":"punctuation.parentheses.left.fortran"}},"end":"(?<!\\\\G)","endCaptures":{"1":{"name":"punctuation.parentheses.right.fortran"}},"name":"meta.statement.sync-images-team.fortran","patterns":[{"include":"#parentheses-dummy-variables"}]},"target-attribute":{"captures":{"1":{"name":"storage.modifier.target.fortran"}},"match":"(?i)\\\\s*\\\\b(target)\\\\b"},"type-specification-statements":{"begin":"(?i)(?=\\\\b(?:character|class|complex|double\\\\s*precision|double\\\\s*complex|integer|logical|real|type|dimension)\\\\b(?![^\\\\n!\\"':;]*\\\\bfunction\\\\b))","end":"(?=[\\\\n!);])","name":"meta.specification.type.fortran","patterns":[{"include":"#types"},{"begin":"(?=\\\\s*(,|::))","contentName":"meta.attribute-list.type-specification-statements.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"begin":"(,)|^|(?<=&)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=::|[\\\\n!\\\\&,;])","patterns":[{"include":"#access-attribute"},{"include":"#allocatable-attribute"},{"include":"#asynchronous-attribute"},{"include":"#codimension-attribute"},{"include":"#contiguous-attribute"},{"include":"#dimension-attribute"},{"include":"#external-attribute"},{"include":"#intent-attribute"},{"include":"#intrinsic-attribute"},{"include":"#language-binding-attribute"},{"include":"#optional-attribute"},{"include":"#parameter-attribute"},{"include":"#pointer-attribute"},{"include":"#protected-attribute"},{"include":"#save-attribute"},{"include":"#target-attribute"},{"include":"#value-attribute"},{"include":"#volatile-attribute"},{"include":"#invalid-word"}]}]},{"include":"#name-list"}]},"types":{"patterns":[{"include":"#character-type"},{"include":"#derived-type"},{"include":"#logical-type"},{"include":"#numeric-type"}]},"unnamed-control-constructs":{"patterns":[{"include":"#associate-construct"},{"include":"#block-construct"},{"include":"#critical-construct"},{"include":"#do-construct"},{"include":"#forall-construct"},{"include":"#if-construct"},{"include":"#select-case-construct"},{"include":"#select-type-construct"},{"include":"#select-rank-construct"},{"include":"#where-construct"}]},"use-statement":{"begin":"(?i)\\\\b(use)\\\\b","beginCaptures":{"1":{"name":"keyword.control.use.fortran"}},"end":"(?=[\\\\n!;])","name":"meta.statement.use.fortran","patterns":[{"begin":"(?=\\\\s*(,|::|\\\\())","contentName":"meta.attribute-list.namelist.fortran","end":"(::)|(?=[\\\\n!;])","endCaptures":{"1":{"name":"keyword.operator.double-colon.fortran"}},"patterns":[{"begin":"(,)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=::|[\\\\n!,;])","patterns":[{"include":"#intrinsic-attribute"},{"include":"#non-intrinsic-attribute"},{"include":"#invalid-word"}]}]},{"begin":"(?i)\\\\s*\\\\b([a-z]\\\\w*)\\\\b","beginCaptures":{"1":{"name":"entity.name.class.module.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"begin":"(,)","beginCaptures":{"1":{"name":"punctuation.comma.fortran"}},"end":"(?=::|[\\\\n!;])","patterns":[{"begin":"(?i)\\\\s*\\\\b(only\\\\s*:)","beginCaptures":{"1":{"name":"keyword.control.only.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#operator-keyword"},{"include":"$base"}]},{"begin":"(?i)(?=\\\\s*[a-z])","contentName":"meta.name-list.fortran","end":"(?=[\\\\n!;])","patterns":[{"include":"#operator-keyword"},{"include":"$base"}]}]}]}]},"user-defined-operators":{"captures":{"1":{"name":"keyword.operator.user-defined.fortran"}},"match":"(?i)\\\\s*(\\\\.[a-z]+\\\\.)"},"value-attribute":{"captures":{"1":{"name":"storage.modifier.value.fortran"}},"match":"(?i)\\\\s*\\\\b(value)\\\\b"},"variable":{"applyEndPatternLast":1,"begin":"(?i)\\\\b(?=[a-z])","end":"(?<!\\\\G)","name":"meta.parameter.fortran","patterns":[{"include":"#brackets"},{"include":"#derived-type-operators"},{"include":"#parentheses-dummy-variables"},{"include":"#word"}]},"volatile-attribute":{"captures":{"1":{"name":"storage.modifier.volatile.fortran"}},"match":"(?i)\\\\s*\\\\b(volatile)\\\\b"},"where-construct":{"patterns":[{"applyEndPatternLast":1,"begin":"(?i)\\\\b(where)\\\\b","beginCaptures":{"1":{"name":"keyword.control.where.fortran"}},"end":"(?<!\\\\G)","patterns":[{"include":"#logical-control-expression"},{"begin":"(?<=\\\\))(?=\\\\s*[\\\\n!;])","end":"(?i)\\\\b(end\\\\s*where)\\\\b","endCaptures":{"1":{"name":"keyword.control.endwhere.fortran"}},"name":"meta.block.where.fortran","patterns":[{"begin":"(?i)\\\\s*\\\\b(else\\\\s*where)\\\\b","beginCaptures":{"1":{"name":"keyword.control.elsewhere.fortran"}},"end":"\\\\s*(?=[\\\\n!;])","patterns":[{"include":"#parentheses"},{"captures":{"1":{"name":"meta.label.elsewhere.fortran"}},"match":"(?i)(\\\\s*[a-z]\\\\w*)?"},{"include":"#invalid-word"}]},{"include":"$base"}]},{"begin":"(?i)(?<=\\\\))(?!\\\\s*[\\\\n!;])","end":"\\\\n","name":"meta.statement.control.where.fortran","patterns":[{"include":"$base"}]}]}]},"while-attribute":{"begin":"(?i)\\\\G\\\\s*\\\\b(while)\\\\b","beginCaptures":{"1":{"name":"keyword.control.while.fortran"}},"end":"(?=[\\\\n!;])","patterns":[{"include":"#parentheses"},{"include":"#invalid-word"}]},"word":{"patterns":[{"match":"(?i)(?:\\\\G|(?<=%))\\\\s*\\\\b([a-z]\\\\w*)\\\\b"}]}},"scopeName":"source.fortran.free","aliases":["f90","f95","f03","f08","f18"]}`)),n=[e];export{n as default};
|