@reviewflow/app 6.22.2 → 6.23.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.
Files changed (249) hide show
  1. package/build/index-node.mjs +6 -4
  2. package/client/_expo/static/css/markdown-editor-d136c3bf58017f1b41842876da69354a.css +1 -0
  3. package/client/_expo/static/js/web/{AppEntry-5631ffef29e14c51e35ea01c7bfdd90c.js → AppEntry-56b020d721460c20da7131ac49619d4b.js} +230 -229
  4. package/client/_expo/static/js/web/{__common-edea2c7718fddaf3a2043fadeabab584.js → __common-2ee53328484f79476c3b7d7e030cc0b6.js} +84 -84
  5. package/client/_expo/static/js/web/{abap-769adef5e34cab6671c956ab6d547154.js → abap-c8e5f799ff27a4d852c22eb99f7a3885.js} +1 -1
  6. package/client/_expo/static/js/web/{actionscript-3-b7b82073a4fb91d60ccaa82985313f35.js → actionscript-3-78b5daa203ae39cd56a0e0ed6facae15.js} +1 -1
  7. package/client/_expo/static/js/web/{ada-56f02e5fb550dc451bd17dc7f9bdecfd.js → ada-1ca05fad160da9a8fbdf0a2ba1252bdb.js} +1 -1
  8. package/client/_expo/static/js/web/{ahk-86707baa6d5a495fa7c3885de5786066.js → ahk-2d2ae3661bd29086e62aeeded55ec585.js} +1 -1
  9. package/client/_expo/static/js/web/{ahk2-06ba852a3ebd2e71a8d79e805ee7c234.js → ahk2-391089886649d8052f41a5fd98ada264.js} +1 -1
  10. package/client/_expo/static/js/web/{andromeeda-8258b4411ce6088326ba17be957b1177.js → andromeeda-f3de934480916d158e567ff8a424f834.js} +1 -1
  11. package/client/_expo/static/js/web/{angular-ts-0cbb1ba3aaa05e95401c274a25d340b4.js → angular-ts-9a03c67bc1e12fd75cf15cac149aaed5.js} +3 -3
  12. package/client/_expo/static/js/web/{apache-baf649bc9ad0ea3f9a1f1a806458b9f8.js → apache-85d18adf7e6cda7358ca3874c4f0b193.js} +1 -1
  13. package/client/_expo/static/js/web/{apex-a9ddc0c307db86d37467a212195c1253.js → apex-4bb2e5a287229694317bc424a04a0672.js} +1 -1
  14. package/client/_expo/static/js/web/{apl-9d0344bf46ae609aab04bb84df468890.js → apl-1478a2a47288ba2697aff4af14d0c322.js} +1 -1
  15. package/client/_expo/static/js/web/{applescript-cc4af6a5d3647ec21b64cc9ae69f3d7a.js → applescript-4863f8f9ae55fc93d8177e49dc56d892.js} +1 -1
  16. package/client/_expo/static/js/web/{ara-ae4fc6817ded87f92914ef7b37223b62.js → ara-36ae84b99a4eeeded5f9a92886ab4dba.js} +1 -1
  17. package/client/_expo/static/js/web/{asciidoc-3bb3161f3a50a1c7e2cecf470a59d34f.js → asciidoc-a62806a8e8ff6d72e2c837183449a750.js} +1 -1
  18. package/client/_expo/static/js/web/{asm-2a1ff8cabc76a2419ed0213e9c387c2a.js → asm-76e0d93cba4e941a437081604b2c651f.js} +1 -1
  19. package/client/_expo/static/js/web/{astro-1bc753a5feda558c20a06147e14e62e0.js → astro-fcf78b5fb3635ca5d2c1ce4306dcc605.js} +1 -1
  20. package/client/_expo/static/js/web/{aurora-x-bdc0740469538665d8c5fd9d7a0133f4.js → aurora-x-d4d9109def53edc9243caa63b5efc525.js} +1 -1
  21. package/client/_expo/static/js/web/{awk-813723529c4acfb1bfba75a4f341ff65.js → awk-0a308d1b821b7480f001877ccccd41b5.js} +1 -1
  22. package/client/_expo/static/js/web/{ayu-dark-3b6569226dcc93ab6f4e53aff808726c.js → ayu-dark-10efaa20e99d7bcc94b76a8da1502480.js} +1 -1
  23. package/client/_expo/static/js/web/{ayu-light-91ebd140e7460af0c0f2109b8b79c86a.js → ayu-light-671de0bfbd9b0255c72ca367cecc2457.js} +1 -1
  24. package/client/_expo/static/js/web/{ayu-mirage-c2762ebd55aa3e432d05907e607cdb07.js → ayu-mirage-0be2196dfc7fa32dee0a3e0eaf816563.js} +1 -1
  25. package/client/_expo/static/js/web/{ballerina-ab51ce783269a72a67132203c49ec44e.js → ballerina-c83ea45066475e2f52cbeef63e21a733.js} +1 -1
  26. package/client/_expo/static/js/web/{beancount-dbc34b83c0cc3c7ce946d4af66ba67a0.js → beancount-693091ecdcd287facbe21376bfd92aa3.js} +1 -1
  27. package/client/_expo/static/js/web/{berry-5ba6c68a015f73824da320fa9e12a868.js → berry-f1bacd2be0a024ba7310aa8bf3309103.js} +1 -1
  28. package/client/_expo/static/js/web/{bicep-c8585f0cbd88acbcd952cce456edbba1.js → bicep-9074c2681e12e339099c761b003bc3a6.js} +1 -1
  29. package/client/_expo/static/js/web/{bird2-72901e2b80e29553aff5fdacd5416ed1.js → bird2-82e3813f0f848caea7975b9bc18dbd51.js} +1 -1
  30. package/client/_expo/static/js/web/{blade-eeaf31f47667bc2e0b323a69a17f6c16.js → blade-65edcf12568163601255cc09237f75ca.js} +1 -1
  31. package/client/_expo/static/js/web/{bsl-90ed342c7724af4534bc56610e734c83.js → bsl-b618b8c72e486130034fc019abf1cdd4.js} +1 -1
  32. package/client/_expo/static/js/web/{c3-7cc2608644ba1a1ef015f7978bb6fa5b.js → c3-0cb886a52af1b94ed6a32ab01f3c70b3.js} +1 -1
  33. package/client/_expo/static/js/web/{cadence-74b0a48f10040a5c060b2ef3fe223347.js → cadence-4eff46dc53d1663c0e4b3815cd593c0c.js} +1 -1
  34. package/client/_expo/static/js/web/{cairo-ef00974f0dd8dd29d22c736abf4df8ff.js → cairo-e049863be43b68ae694b1f0f27243c96.js} +1 -1
  35. package/client/_expo/static/js/web/{catppuccin-frappe-d702b9345480370d5731f5a5da57b291.js → catppuccin-frappe-36242dc37e4ddac8f8735906b1e79b71.js} +1 -1
  36. package/client/_expo/static/js/web/{catppuccin-latte-a38f2be62ab340702261b512b4395873.js → catppuccin-latte-73a45590aa8f979cc92ffcb0ca2dfe3a.js} +1 -1
  37. package/client/_expo/static/js/web/{catppuccin-macchiato-c0bb95a9e7cc63b44708070523c0d380.js → catppuccin-macchiato-f6b29b308b271701690c4e50b65340fe.js} +1 -1
  38. package/client/_expo/static/js/web/{catppuccin-mocha-7369531bc8204fd0102e08759ab6bc24.js → catppuccin-mocha-0ce923798409f1d6f9aab31bd5f48468.js} +1 -1
  39. package/client/_expo/static/js/web/{chapel-39b6a02ba101bc9b18b6527522110f1e.js → chapel-778cda2e840ca8ebd7536ba90ac5dacd.js} +1 -1
  40. package/client/_expo/static/js/web/{clarity-d902cf4c81f8171f9705bf053f3f6983.js → clarity-193cd65a646549c3be6a3448b4e9ef88.js} +1 -1
  41. package/client/_expo/static/js/web/{cobol-93092f11932545e9436668f9448a95b8.js → cobol-f1c1f06f0b0973424867e16c89158fc6.js} +1 -1
  42. package/client/_expo/static/js/web/{codeowners-4fa4ca3f295a76ee38123852fb5ab3bb.js → codeowners-6d9dd7de6943fff8c4a8a6b58f3feee2.js} +1 -1
  43. package/client/_expo/static/js/web/{codeql-3f5ecab83d7a2b30a255fe0079ac9f0b.js → codeql-24527dced5b401ecc8f507c6c51dbfc6.js} +1 -1
  44. package/client/_expo/static/js/web/{common-lisp-9f9faa5b185d2dfc7a8492a673bcfdd9.js → common-lisp-edc5fd942f5641eee065fbc536bf8fda.js} +1 -1
  45. package/client/_expo/static/js/web/{coq-3cf85537c4b51a70f8bca8a0b83e09b9.js → coq-51e20ccdd19db874a79a3a57c6d00e38.js} +1 -1
  46. package/client/_expo/static/js/web/{crystal-2816654ba69407f6307d34dbee6df4fa.js → crystal-72ddf59939c9bb3d670b36c685c7be19.js} +1 -1
  47. package/client/_expo/static/js/web/{cue-b17d112f30d57eef3e00cd46bb19566c.js → cue-c976b908c7035b266b45f2678482653d.js} +1 -1
  48. package/client/_expo/static/js/web/{cypher-8a728ded3f5d491fff1162b45a84e35c.js → cypher-d0bf596354716d42747a4670730edfbe.js} +1 -1
  49. package/client/_expo/static/js/web/{d-0cde7b0f83412978f4ee5d52a1dc749f.js → d-f01322166ebba2bd8688e9fb614cd758.js} +1 -1
  50. package/client/_expo/static/js/web/{dark-plus-76cf5b97f2a662594240309145952d5a.js → dark-plus-e1f28cea9f04234dedc922bebc1757ff.js} +1 -1
  51. package/client/_expo/static/js/web/{dax-5edba9509a07fb9150b5ae75f4f60059.js → dax-45eb7d31be9f9de64b201978b35f7b6f.js} +1 -1
  52. package/client/_expo/static/js/web/{desktop-3e6e3aa72cefc4ec35336c9ec431ab79.js → desktop-41e33a25b1301d63eb0a72709fc4fb91.js} +1 -1
  53. package/client/_expo/static/js/web/{diff-worker-cc5e2731673002d078861f6937705979.js → diff-worker-67a46521b3c2eaef9f025488c88ebb16.js} +5 -5
  54. package/client/_expo/static/js/web/{dotenv-c4a6862effea6ce5c9680a5252dd579e.js → dotenv-ae605c1e02d4457efa22334d4cbcfd1c.js} +1 -1
  55. package/client/_expo/static/js/web/{dracula-89374b0b86a05a19bf875cada55b6d46.js → dracula-55d681df623fcbb87a6da97876b76898.js} +1 -1
  56. package/client/_expo/static/js/web/{dracula-soft-421f709ee0ff39ac631d59e94b06b00f.js → dracula-soft-6e02236d94c7be45bb7d319b9312d744.js} +1 -1
  57. package/client/_expo/static/js/web/{dream-maker-aecf6a9eea27a713aa720bcce56b0e55.js → dream-maker-876f0aefd9addb5ff1182d2f3cd5f711.js} +1 -1
  58. package/client/_expo/static/js/web/{edge-110b22d0629352e10af9ae23ba5d369c.js → edge-c6be5d681bc1ab9b059b45f0b78b31cd.js} +1 -1
  59. package/client/_expo/static/js/web/{elm-4635c57528483168a23fd667c54eeb56.js → elm-628caf17b5d054a208256c9f154d31b7.js} +1 -1
  60. package/client/_expo/static/js/web/{emacs-lisp-aa3d388cb507b40f658c5e9069e9beba.js → emacs-lisp-9a5956786418676d5714d404e4affd61.js} +1 -1
  61. package/client/_expo/static/js/web/{erb-6fe0d436c64af2f2acccd80764efc8a8.js → erb-01bc8de5cc2beac097e02299eab45650.js} +1 -1
  62. package/client/_expo/static/js/web/{everforest-dark-63904431ab281916219e2a75c29f1e62.js → everforest-dark-3731cb049c252b329bf4d554b656a8dc.js} +1 -1
  63. package/client/_expo/static/js/web/{everforest-light-ed8aab439f424298c1968e7e2bb87856.js → everforest-light-4c17b572037f528de4d6799e4912a6e4.js} +1 -1
  64. package/client/_expo/static/js/web/{fennel-1ad1e7fabe88c381972070f083767758.js → fennel-d6afd69acf78f3324a0599485ddc7096.js} +1 -1
  65. package/client/_expo/static/js/web/{fish-35962daa272edd76cc7699504d54d4df.js → fish-9f4e218a4ebb0d3499dc2dd1f0a07cd6.js} +1 -1
  66. package/client/_expo/static/js/web/{fluent-6ea67003e6a98f971349bb707a18a2d5.js → fluent-a8c7a12943c29f3c009901f7cc6f65c3.js} +1 -1
  67. package/client/_expo/static/js/web/{fortran-fixed-form-f03d92d7ca85272af90d31625d8f84b2.js → fortran-fixed-form-f1ef0def320b3f138c99983001cda7f0.js} +1 -1
  68. package/client/_expo/static/js/web/{gdresource-5e08d9e92f133aa5c8d6ccfb71eee4d9.js → gdresource-72a50cfb5664ad687a3712d7ef5455da.js} +1 -1
  69. package/client/_expo/static/js/web/{genie-2381adcf565c170334809784b9133fb1.js → genie-2afc9b8ffb59be76e2ca88aabc9a7059.js} +1 -1
  70. package/client/_expo/static/js/web/{gherkin-48a009a1d4c4bbab9860d3fe71ea0cdf.js → gherkin-f83cdc55d61d4d8332e4b73ac5721c86.js} +1 -1
  71. package/client/_expo/static/js/web/{github-dark-8d8f9728ae76e3ba039ae042d810df42.js → github-dark-a83e3311f8069e5b2c4ee6e863a4df01.js} +1 -1
  72. package/client/_expo/static/js/web/{github-dark-default-92096de2a0f8ae50d918d6a247498616.js → github-dark-default-c1ae07a1457c502f850f4a0952a3b99a.js} +1 -1
  73. package/client/_expo/static/js/web/{github-dark-dimmed-53cc25f8c227323feeec9f34a687a67c.js → github-dark-dimmed-56d9701c31932f2e4b84a494b6cad090.js} +1 -1
  74. package/client/_expo/static/js/web/{github-dark-high-contrast-74f3438e581a5e4ffdafafc56dd712a5.js → github-dark-high-contrast-6abff8d8b915b84688b956c24a3e3248.js} +1 -1
  75. package/client/_expo/static/js/web/{github-light-default-db32089ee8cdc865f33610d9b796ab7c.js → github-light-default-e8457016e255a2bc83b2730b982735e9.js} +1 -1
  76. package/client/_expo/static/js/web/{github-light-5fe9b7c0a7a3026f8286372ee4b61bfb.js → github-light-e3076f130b4ffa1195071ca687d9e6de.js} +1 -1
  77. package/client/_expo/static/js/web/{github-light-high-contrast-076de49429a3ff821bda36e950163521.js → github-light-high-contrast-978ad0bbcff1f0d0958d7b15a7a80112.js} +1 -1
  78. package/client/_expo/static/js/web/{gleam-95d68a4f0bd24e7fbe076c950cb99c8f.js → gleam-6b9486766b3ad3e21d9ef86fa7ec19b6.js} +1 -1
  79. package/client/_expo/static/js/web/{glimmer-js-183f0542934f09a5490330b577515c72.js → glimmer-js-734c359eaef586072cf024434804c740.js} +1 -1
  80. package/client/_expo/static/js/web/{glimmer-ts-6f98f398820b5766e7e77be62d76874f.js → glimmer-ts-9a3571cb9221e4961c7a84e2bf0769b5.js} +1 -1
  81. package/client/_expo/static/js/web/{gn-5f3cde72a90e0934c65c41bd748af712.js → gn-28eb0cb7cec68ef59963a1b6d54aee26.js} +1 -1
  82. package/client/_expo/static/js/web/{gnuplot-869f41854f3e8c1a922beb4e75acd4d3.js → gnuplot-ff73f16e5770a0588765529596c64844.js} +1 -1
  83. package/client/_expo/static/js/web/{gruvbox-dark-hard-86fe86c4668b7b751191ff0c1ea90f7a.js → gruvbox-dark-hard-90cf0e1954ab90e2e80207e60f30a824.js} +1 -1
  84. package/client/_expo/static/js/web/{gruvbox-dark-medium-4f523956ee7b4cdaa29200227370986c.js → gruvbox-dark-medium-8b79df5471a246f4f34d13371f13f00c.js} +1 -1
  85. package/client/_expo/static/js/web/{gruvbox-dark-soft-a79ad82c2438477acb083bc7b1ae5ffb.js → gruvbox-dark-soft-26deede25a7498e07edc05f95785d2f1.js} +1 -1
  86. package/client/_expo/static/js/web/{gruvbox-light-hard-24e2877be0afd465bf130bae9e76a33b.js → gruvbox-light-hard-9a6d0b1918faa1246a4284aad067de37.js} +1 -1
  87. package/client/_expo/static/js/web/{gruvbox-light-medium-f5ce9e15f21f6b6374f4c3b29fbdb9be.js → gruvbox-light-medium-7020772bd00c889dbebe1432f34b355c.js} +1 -1
  88. package/client/_expo/static/js/web/{gruvbox-light-soft-1304c221207b3b6b4165cfc0dbe76000.js → gruvbox-light-soft-fecb0e4e8a7864682f10f06f5e91a997.js} +1 -1
  89. package/client/_expo/static/js/web/{hack-6ffcd55aa688203464d0134f62729dda.js → hack-5e5735fcc45b79a20c621e0ca94b5f24.js} +1 -1
  90. package/client/_expo/static/js/web/{haskell-f27148e5a0837c4fee3868ce15451c04.js → haskell-efba761bc16695dfda7d9ec3fd539362.js} +1 -1
  91. package/client/_expo/static/js/web/{hcl-e7812908454b576b10f0471683fa4936.js → hcl-d0535eec277891d438631f0bf1db4c73.js} +1 -1
  92. package/client/_expo/static/js/web/{hjson-f83493107932a6df91fec7c9490546e8.js → hjson-0bbcfc9763af47e98a937ec82fc24d6b.js} +1 -1
  93. package/client/_expo/static/js/web/{horizon-93f47699b0622e11aa46b48fbf2c6b67.js → horizon-40ef53e15d06ca010153d9641b3c0057.js} +1 -1
  94. package/client/_expo/static/js/web/{horizon-bright-ca884eb660f5187b779e5a84a450877f.js → horizon-bright-a0e246df0bed24e1363105620fb7eac8.js} +1 -1
  95. package/client/_expo/static/js/web/{houston-2f73a40d5bed1dee8b3fe252c8fa8056.js → houston-c0e3169a513a1282ed418b1046a90517.js} +1 -1
  96. package/client/_expo/static/js/web/{http-378dcd80daeb6baac607f67f0a9201a4.js → http-f4213bde6b87eb8466dab707cc1c3e3c.js} +1 -1
  97. package/client/_expo/static/js/web/{hurl-b21655b7368865e268a3014cb1e4b1b1.js → hurl-3ae569ae090ae0781e29d0494ba4c982.js} +1 -1
  98. package/client/_expo/static/js/web/{hxml-9cb8ed960b45bc43f7ac81ac76822762.js → hxml-2f01a287c636e9edd0aa67aea4aaf416.js} +1 -1
  99. package/client/_expo/static/js/web/{hy-36f45b3b385511f8bfa6732436405a1c.js → hy-4dea9d8fb410716996ae58eadbd5a022.js} +1 -1
  100. package/client/_expo/static/js/web/{imba-0a45ed774d4b8fafe740a84d6ce73d12.js → imba-f86c529235b432e1fa71a4eb6926b5d9.js} +1 -1
  101. package/client/_expo/static/js/web/{jinja-22511338ca611a1656cac3ba758c7c4a.js → jinja-0129ee187ee4e04baf2f261ac8d85ab9.js} +2 -2
  102. package/client/_expo/static/js/web/{jison-f371a06ba690d7c2c1f123c41a20072b.js → jison-73d0ccbdfb3952f956b5cbfeff27cdee.js} +1 -1
  103. package/client/_expo/static/js/web/{json5-f1d3d89f6d81a311a719e5804821617f.js → json5-09750af6818858197ad6268603fd123d.js} +1 -1
  104. package/client/_expo/static/js/web/{jsonl-33699f5027bcaf5f389d93766b0f9371.js → jsonl-75ddf8395718f7c89d61ec202365d37c.js} +1 -1
  105. package/client/_expo/static/js/web/{jsonnet-e80d1b7d1e12ca38651d2da3b5e6e291.js → jsonnet-09be283e6761829d599b964a17eb302b.js} +1 -1
  106. package/client/_expo/static/js/web/{jssm-387167bacd84c1438f0d90259972cb34.js → jssm-00bb4a0f587d9eb3f52af2ad05507ff8.js} +1 -1
  107. package/client/_expo/static/js/web/{just-671df0888fd3cb1ab27585abc5a02348.js → just-a021aac383470eb54cc9b72ad804cdb4.js} +1 -1
  108. package/client/_expo/static/js/web/{kanagawa-dragon-af8e47a946c93f68169c833b186da9ad.js → kanagawa-dragon-6164706d0defa0c3fa2b0ec78ed91de2.js} +1 -1
  109. package/client/_expo/static/js/web/{kanagawa-lotus-02c311a5335df8170d003bc5632c8365.js → kanagawa-lotus-42a848f1dfae53eb6462db8bfe27aa11.js} +1 -1
  110. package/client/_expo/static/js/web/{kanagawa-wave-76d4634fdade5ec886b4106fdb58d544.js → kanagawa-wave-55f94bfbadee99196e170ec53e35c90b.js} +1 -1
  111. package/client/_expo/static/js/web/{kdl-5494639040937970f1479e2e2f5c8618.js → kdl-7180f7b4fbec34e5b2120ea6d72e2f85.js} +1 -1
  112. package/client/_expo/static/js/web/{kotlin-414157118aed30d1c79cc221dd1f9e89.js → kotlin-ca2b35ee850e45c669e5af9c59b238ce.js} +1 -1
  113. package/client/_expo/static/js/web/{kusto-8038426dd2b14d65bc39e2347969407b.js → kusto-5e7bfe2c438b96bbb97493fb2900ec74.js} +1 -1
  114. package/client/_expo/static/js/web/{laserwave-ab499c85292e494ef57f630f6aac5a05.js → laserwave-a06b791a8ea5ba179797703cf39a400b.js} +1 -1
  115. package/client/_expo/static/js/web/{lean-9f6efeb4b03224ccd752320fd9e2f49e.js → lean-f4087e3012b6fbccf05ac5fdc31a7e7c.js} +1 -1
  116. package/client/_expo/static/js/web/{light-plus-5e7976265eb1dc30888856f5452d6eb7.js → light-plus-3198390e6118402d3324af43dae3c25d.js} +1 -1
  117. package/client/_expo/static/js/web/{liquid-b5e604a585bd46ed2142a2373835359b.js → liquid-7e0c12e0b67daceb82e09275e8781b7e.js} +1 -1
  118. package/client/_expo/static/js/web/{llvm-382c32cd1ae793bd8e36621b4b5257a8.js → llvm-b575a4c05ee8c9f39ce18c09e30e737d.js} +1 -1
  119. package/client/_expo/static/js/web/{logo-b1754a7da7661ad6c0aa0e39a7f00d6e.js → logo-a3a0757a2febb714a800d136ce4746cc.js} +1 -1
  120. package/client/_expo/static/js/web/{luau-efc9907c8454fe09f7f120734c44d1bf.js → luau-78e558c6eb3cd9455af7c525dd75807d.js} +1 -1
  121. package/client/_expo/static/js/web/{marko-4d442465d03b8a634f243030d8f01535.js → marko-435efee9add66ab177a5c1930f0520fa.js} +1 -1
  122. package/client/_expo/static/js/web/{material-theme-b49fb267453c4c2ce2bfa96492dd1e21.js → material-theme-ad13f436178b698bb02f7052610224a9.js} +1 -1
  123. package/client/_expo/static/js/web/{material-theme-darker-1172b69b37d34097bac241cb36b7cc04.js → material-theme-darker-b1750204daae9d24254b4fdbddef44ae.js} +1 -1
  124. package/client/_expo/static/js/web/{material-theme-lighter-49a34444f6b11fc2ffe3910899fede20.js → material-theme-lighter-9c0a93814d7d0754a9b69d6839d26c0c.js} +1 -1
  125. package/client/_expo/static/js/web/{material-theme-ocean-36bf87771f8883d2d1a173ad7e2bb0dd.js → material-theme-ocean-fdefae578b2fab14869e409d577cf0ad.js} +1 -1
  126. package/client/_expo/static/js/web/{material-theme-palenight-e8df01f0e170ee67a3c91da1a1607c35.js → material-theme-palenight-cd4c46fb0414187a9ff925f5c5c6b4b3.js} +1 -1
  127. package/client/_expo/static/js/web/{matlab-14575aa28e0f907b622d5cbfeb4674b7.js → matlab-8554733b6dc2f18ca9ee48e60b965a07.js} +1 -1
  128. package/client/_expo/static/js/web/{mdc-70f6c698577151b032a7bf9521427a83.js → mdc-0eea570ba8c38df2c084ef5306fbed20.js} +1 -1
  129. package/client/_expo/static/js/web/{mdx-091ffb5fdbb044d6af1191897a8c7656.js → mdx-3834352237dd49f996898a90732bbe10.js} +1 -1
  130. package/client/_expo/static/js/web/{mermaid-455d0d76a93653051cb56cf15dd40d65.js → mermaid-80581387cd2e2a38f879142ab165df55.js} +1 -1
  131. package/client/_expo/static/js/web/{min-dark-9b48aee498ba4481c6d752393f2b8b99.js → min-dark-4fd6f0987b9a0926da093d115bea03dd.js} +1 -1
  132. package/client/_expo/static/js/web/{min-light-b28ecca546bbfea749ab4d736d5326cf.js → min-light-d40c0ba5aee57268aa1399010de927ec.js} +1 -1
  133. package/client/_expo/static/js/web/{mipsasm-5e39c87c3f20d5d346d0147d5b79bd61.js → mipsasm-47bdbf39b789b45677ca328a8684624c.js} +1 -1
  134. package/client/_expo/static/js/web/{mojo-023c3b96d5d806616efb04c26359998f.js → mojo-f68d5303eaaf4f154c5baa783e99db84.js} +1 -1
  135. package/client/_expo/static/js/web/{monokai-673abae396dcafc0225ae052a8bb200d.js → monokai-c580f39255a304c1419d960300c16a1f.js} +1 -1
  136. package/client/_expo/static/js/web/{moonbit-bce17d24b4e5282657b595cfa15648cc.js → moonbit-c88d60ee22cfb32c62c5b9b143283bf0.js} +1 -1
  137. package/client/_expo/static/js/web/{move-cca76082a912b158b1d642e5b5199c56.js → move-27a43395f3b7cdd7f91301b3307f22b2.js} +1 -1
  138. package/client/_expo/static/js/web/{narrat-16747d11d4014b09973d308364d68550.js → narrat-d4e11eb1912eb0409888b29ac2bee0e5.js} +1 -1
  139. package/client/_expo/static/js/web/{nextflow-418e67bd0d2a1c15008db5fb8618d505.js → nextflow-25bab2858b0dceafbfd02f1a3fb5e6a3.js} +1 -1
  140. package/client/_expo/static/js/web/{nginx-442af891ee03eddfcfae8f648b413870.js → nginx-c7cfacbbc3aa48be3832eb11de44e438.js} +1 -1
  141. package/client/_expo/static/js/web/{night-owl-06b717d3f87dd89ead465c1a3daed461.js → night-owl-f61a96eec048da27b3856e1f359845fd.js} +1 -1
  142. package/client/_expo/static/js/web/{night-owl-light-aa060b3526f6ead229ca7bfc5034eb40.js → night-owl-light-9efed9187c3033132d9bb3ac31674b37.js} +1 -1
  143. package/client/_expo/static/js/web/{nix-1cee76f90aad55886e805604dac62717.js → nix-421c3c7af085b0e1b7108017d921ad15.js} +2 -2
  144. package/client/_expo/static/js/web/{nord-5079aa1bd2ba9b4c12e3680274d6a8ff.js → nord-febdaec42d29f2b8bc2cea8efe02ad2a.js} +1 -1
  145. package/client/_expo/static/js/web/{nsis-00c4e352b0bd096093f1f97418fcf28f.js → nsis-76c479499cfc68bb7dba667670e3cc81.js} +1 -1
  146. package/client/_expo/static/js/web/{nushell-ae3b259c7125dfc685150b60c99a6d38.js → nushell-d5812d413b145ef6e571666296f2ce20.js} +1 -1
  147. package/client/_expo/static/js/web/{objective-cpp-dc7eec9f5dd784483073424f07eca3fb.js → objective-cpp-8df5b6179e924b03a6688ec3dd163c5a.js} +1 -1
  148. package/client/_expo/static/js/web/{odin-59882d99ebaffaf049bc51886dd1664c.js → odin-e301d292f155fc1e87cc333f4990e5f6.js} +1 -1
  149. package/client/_expo/static/js/web/{one-dark-pro-ec8d19c689af7067ed93aa7be9f6518c.js → one-dark-pro-a79f0e19bc165873ffdf2fa5b5b9968f.js} +1 -1
  150. package/client/_expo/static/js/web/{one-light-a326bc947ee9b389d48e32f4ecaf20d7.js → one-light-3c253a74883f8c098ebd62e5509965dd.js} +1 -1
  151. package/client/_expo/static/js/web/{openscad-1db5e83726ac425dc46422f977269fbb.js → openscad-416eb1e6514fcd36370bff6658650182.js} +1 -1
  152. package/client/_expo/static/js/web/{org-e198afd889aa4d7a4c5af30f81ff2a9b.js → org-22f8b0891c9016f69433e59cc99605e2.js} +1 -1
  153. package/client/_expo/static/js/web/{pascal-8ced528d3ab6a89a3631963f42c84928.js → pascal-523ebfd3eb85c0e92512e4f8e6427b44.js} +1 -1
  154. package/client/_expo/static/js/web/{pierre-dark-fac5b6729b71683c6d36dff29f193362.js → pierre-dark-6bb857d93ce605dbda12510dc01fc80e.js} +1 -1
  155. package/client/_expo/static/js/web/{pierre-dark-protanopia-deuteranopia-4b0d2ca238867771bcdd17497a522330.js → pierre-dark-protanopia-deuteranopia-470accb7dc6f03caefce50db3fef9b98.js} +1 -1
  156. package/client/_expo/static/js/web/{pierre-dark-soft-a26d9ac93cb8cc9c813f90cc773f1aa3.js → pierre-dark-soft-944c9c6c0caa56a50d81acfdf96c2890.js} +1 -1
  157. package/client/_expo/static/js/web/{pierre-dark-tritanopia-e07fb124d79bf06c774431c7d17115b4.js → pierre-dark-tritanopia-0be41932cf15dde1012e9502b0862656.js} +1 -1
  158. package/client/_expo/static/js/web/{pierre-dark-vibrant-704a64276fa06a11cc7a0b5dad389044.js → pierre-dark-vibrant-7b0d754275fbd0605b74d11d1e911337.js} +1 -1
  159. package/client/_expo/static/js/web/{pierre-light-34894f98c43b9715de2a4ed374c2e230.js → pierre-light-528cb29695c275bdfcd8aee9d4a9e6d8.js} +1 -1
  160. package/client/_expo/static/js/web/{pierre-light-protanopia-deuteranopia-a4f3a86a75e6371191b2d4fafeca87de.js → pierre-light-protanopia-deuteranopia-c85b1e3dc121c211a3d8564b6ff7ef0f.js} +1 -1
  161. package/client/_expo/static/js/web/{pierre-light-soft-cccd20680b781ef907854cae48865b6e.js → pierre-light-soft-35b9fc39135e9376ddc71e1420a3d00f.js} +1 -1
  162. package/client/_expo/static/js/web/{pierre-light-tritanopia-700508863d04ffdb9b4df487ed80895c.js → pierre-light-tritanopia-8a2893cce4664ba01e2afd9c5017c17c.js} +1 -1
  163. package/client/_expo/static/js/web/{pierre-light-vibrant-283da5c2c906862630034a48abc24b7a.js → pierre-light-vibrant-47c506db3587341a9d5b35c6bc6201c5.js} +1 -1
  164. package/client/_expo/static/js/web/{pkl-80cc7915560714a43cde8cfd889687b1.js → pkl-a5faa1d1c122498175db598c82ffaaf0.js} +1 -1
  165. package/client/_expo/static/js/web/{plastic-38a5bd1f3c57cfecb18c3736f4320498.js → plastic-51a33d6513c366ebe6ae88e8854fd340.js} +1 -1
  166. package/client/_expo/static/js/web/{plsql-5605d62aab704621bd54e427eb39f241.js → plsql-ddcc4eef36e027dbc3373ea388788e2b.js} +1 -1
  167. package/client/_expo/static/js/web/{po-4eaea6020e0daa45dbd45c9cbd51844a.js → po-50fb4abdc5661036e6ad0bfbbf3d374e.js} +1 -1
  168. package/client/_expo/static/js/web/{poimandres-62f704484859f6e27fc78d1457011626.js → poimandres-7c463ecee2915bbfbb55076af5c9b594.js} +1 -1
  169. package/client/_expo/static/js/web/{polar-0c5e78385dbbfe3ca75b54cf54f0a908.js → polar-3379b2758c24bc265943233669a5f0c2.js} +1 -1
  170. package/client/_expo/static/js/web/{powerquery-746318fcbf4cd1a7aefea9e104d4adb7.js → powerquery-293ab3894e8efa201aba2781a46a1789.js} +1 -1
  171. package/client/_expo/static/js/web/{prisma-91a5ae340614d53bf3ac249c16579f2f.js → prisma-692d3709acb5822918b96003322fa48f.js} +1 -1
  172. package/client/_expo/static/js/web/{prolog-5e77a3c791e8be999f226d34d7e54038.js → prolog-5a207aada9b5e853ab99a9462e026624.js} +1 -1
  173. package/client/_expo/static/js/web/{proto-82cfc6f1aa9fdc36c7f61ea07c314434.js → proto-116fcd2b56ff62b87dc28e44ac023cae.js} +1 -1
  174. package/client/_expo/static/js/web/{pull-request-diff-viewer-bac010d11f01f993bebe2fec58ac854c.js → pull-request-diff-viewer-168ed472204e1f9004a4bdc268709a83.js} +304 -304
  175. package/client/_expo/static/js/web/{puppet-b478e548b158c225f1760bca64a86ee3.js → puppet-72a805cf4958cf3228556774599a99a3.js} +1 -1
  176. package/client/_expo/static/js/web/{purescript-c11edff58ec320358c7527fb9b6ab7a7.js → purescript-d684cad68ea7217d63b4ad41db25e6e5.js} +1 -1
  177. package/client/_expo/static/js/web/{qml-f589a9c6839eccf3deb07d9aa062bcb7.js → qml-895282cdfbb139545a0ce2473456848f.js} +1 -1
  178. package/client/_expo/static/js/web/{qmldir-966f507a3e2eb053344c58a6ec3033f6.js → qmldir-1267f6146338cb532d63209a37404a40.js} +1 -1
  179. package/client/_expo/static/js/web/{qss-60f8431f5feabeea1cad4442e1ae2447.js → qss-fab8332a83faddc3c1b110d7b2ef8052.js} +1 -1
  180. package/client/_expo/static/js/web/{racket-30d4736f5b54c7997f04c002205d56f7.js → racket-650e074df9390bffd7f0caeebb391020.js} +1 -1
  181. package/client/_expo/static/js/web/{razor-c857aae4fd3930683512cb5354a5fdd9.js → razor-d965966d9e78d38fb68d88f532de7181.js} +1 -1
  182. package/client/_expo/static/js/web/{rbs-7fb6115a963d0451cd2ebd99ef70ca46.js → rbs-3e59cc86cdc47b9526ce39ba07e0818c.js} +1 -1
  183. package/client/_expo/static/js/web/{red-8a92b1997a2b2986b625ac677d43c524.js → red-35ec880b85d34cd7467ee3faff61cb7b.js} +1 -1
  184. package/client/_expo/static/js/web/{reg-d4ad14ff1b1730328cb36af6888f71e3.js → reg-cb0a847bc1c388d011f56df60db1ab81.js} +1 -1
  185. package/client/_expo/static/js/web/{rel-26d6c58867c48a954e84130f9263a252.js → rel-823cc397a0faca80e50cf2f99dabd22c.js} +1 -1
  186. package/client/_expo/static/js/web/{riscv-c2d2f8d6d0de789dbe6abee73b83a725.js → riscv-ba8c5091a8be31b5138fbdb2e230315a.js} +1 -1
  187. package/client/_expo/static/js/web/{ron-b4e0a20ead5cb77418313ab8aa040e05.js → ron-9e84837277aa6c0201a9cdeb8a920d98.js} +1 -1
  188. package/client/_expo/static/js/web/{rose-pine-f462113a6b561dc53603886c3204ce27.js → rose-pine-111e98c7d3d90b74159979947fd7d822.js} +1 -1
  189. package/client/_expo/static/js/web/{rose-pine-dawn-892d15882bad5f528b3bb9059681df56.js → rose-pine-dawn-f10f1a4ca49bc5e55acbdb85e5460c0f.js} +1 -1
  190. package/client/_expo/static/js/web/{rose-pine-moon-62647938f3455a7525e8acaf1ffcc59f.js → rose-pine-moon-9a46be70b75c0cfd47eea7c5db5e8c06.js} +1 -1
  191. package/client/_expo/static/js/web/{rosmsg-75bbbf19c9b336505a9c8079ed07ae6c.js → rosmsg-35de660d59570a2946da7f5222c4caf5.js} +1 -1
  192. package/client/_expo/static/js/web/{rst-f3fd7fbb764b14ca3fee357f29327d62.js → rst-1a16a7d1bf0ca71e73035ae226247ffd.js} +1 -1
  193. package/client/_expo/static/js/web/{sas-9203a3f1d1c1f66f509d33d1c13a3d6a.js → sas-f915cac6dd0c8721b94f714a825c6bea.js} +1 -1
  194. package/client/_expo/static/js/web/{sass-a6560343ea9861b57126090be08b210a.js → sass-924825266b1214209ccb81eddf2185e7.js} +1 -1
  195. package/client/_expo/static/js/web/{scheme-5cd092a32f627b1e6305becf61895c80.js → scheme-cc0afa3e32d688687b5929ae1a61c3de.js} +1 -1
  196. package/client/_expo/static/js/web/{shaderlab-0026275171b288e7cf52656da1658aa6.js → shaderlab-34d2d691dd55f12a45d25b62e8ee3029.js} +1 -1
  197. package/client/_expo/static/js/web/{shellsession-39a1b543dc344f6be8aa93e432cb65ed.js → shellsession-80f7c856962cb7eb6283fd4ea48c5221.js} +1 -1
  198. package/client/_expo/static/js/web/{slack-dark-35d9b5d88ee7904714f81050e02ebe42.js → slack-dark-9a940b28bb1a84622be0939b0d7f41fa.js} +1 -1
  199. package/client/_expo/static/js/web/{slack-ochin-54a43794047d31260224af78f87f14b1.js → slack-ochin-dfdf3fd0db95d51522ab60d58ec3ea43.js} +1 -1
  200. package/client/_expo/static/js/web/{smalltalk-aa11d3f66d469dcb3b63a900040d9958.js → smalltalk-04a2f91b0c669ae15363bb463f1664b6.js} +1 -1
  201. package/client/_expo/static/js/web/{smithy-d44cb989cc60c86581b3b2d8e46cc88e.js → smithy-8c7b5fb0e53c6eadd2d8febd8dbd5242.js} +1 -1
  202. package/client/_expo/static/js/web/{snazzy-light-f9a546ae9548ae72ab7154d375680883.js → snazzy-light-5d6b05898b07489a1abdd7f3659e0699.js} +1 -1
  203. package/client/_expo/static/js/web/{solarized-dark-14d7b4d7d8d4a90accb3a5d0d9c5408c.js → solarized-dark-dfeda2f4537b0d97775893b3b8ccfa51.js} +1 -1
  204. package/client/_expo/static/js/web/{solarized-light-0207b4dee5cb7a84f6c6bffd2c501b83.js → solarized-light-9f5216a9643b3eb82a553c2d15b44794.js} +1 -1
  205. package/client/_expo/static/js/web/{solidity-507f91395412ae84052eba9f9c0e2ad4.js → solidity-264effb0755a1fb601000d3964284f73.js} +1 -1
  206. package/client/_expo/static/js/web/{soy-361d9d108f535f8b5fbb3725063854b3.js → soy-f87724f8aa4b5c436d5381df4b205f31.js} +1 -1
  207. package/client/_expo/static/js/web/{sparql-faf8934698d27b442c98549dbd6ea89f.js → sparql-338033ebb6ef952b9ef4c8a548e1baee.js} +1 -1
  208. package/client/_expo/static/js/web/{splunk-a350d7d4407a4c713a021d4a959fe90f.js → splunk-7cc3c2b50df2497e9a12eaf9f35d6e1b.js} +1 -1
  209. package/client/_expo/static/js/web/{ssh-config-2a8d995da684a7ab0a81bca3aaed3568.js → ssh-config-18d5cc129cf386b20ab4d9899a383749.js} +1 -1
  210. package/client/_expo/static/js/web/{stata-eb269e0d1bf893c3753558fb815450a5.js → stata-5980ede9af0ef92b0fc9bac37d22346a.js} +1 -1
  211. package/client/_expo/static/js/web/{surrealql-c1e466ba490ce683ddb83e5d10515b20.js → surrealql-87d99ad93765dd947e0c6d8dda437d07.js} +1 -1
  212. package/client/_expo/static/js/web/{svelte-0c532a4224f9ca040e2a51ced74a419a.js → svelte-6571f84b30b0f543f7c019ed774f82c9.js} +1 -1
  213. package/client/_expo/static/js/web/{synthwave-84-aa1f05a883fc69d5c75a71403ab18d75.js → synthwave-84-72dfc0810acced8ddf3ce17873c0e038.js} +1 -1
  214. package/client/_expo/static/js/web/{systemd-6567da5597d94a8372030f6b49ce7fe2.js → systemd-36bd90d1106032f31cb5ccedee44847f.js} +1 -1
  215. package/client/_expo/static/js/web/{talonscript-8ebe80f6d02a7d00590342515dd6fead.js → talonscript-4ed15fb77976e40ca926ecd025f05547.js} +1 -1
  216. package/client/_expo/static/js/web/{tasl-b50e20457ab7533427874c33b13e8ccc.js → tasl-916e8be27c9621555916aedd0e3b3b4c.js} +1 -1
  217. package/client/_expo/static/js/web/{tcl-878a99f7dc14a475103f200766cb5478.js → tcl-605dd36a79b1e76a4ebf0bdc429a072d.js} +1 -1
  218. package/client/_expo/static/js/web/{templ-12a83656cd0d1a922eab321d179db612.js → templ-dac78f2b2fa0866cb5024bb29e6e0e9b.js} +1 -1
  219. package/client/_expo/static/js/web/{terraform-c670de87bdeba9f335ff7e94aac99044.js → terraform-7eef2e5255b019ba40ad77a0a856e6b9.js} +1 -1
  220. package/client/_expo/static/js/web/{tokyo-night-a7d30c2372c3318449f1b60f605c437f.js → tokyo-night-7c849b9e5aca62716f2db65f1d5b9ab6.js} +1 -1
  221. package/client/_expo/static/js/web/{toml-3ac514f4d9edf38b023e469fd298e7e8.js → toml-f071e78f2658b19195a21bf2ee32b3c8.js} +1 -1
  222. package/client/_expo/static/js/web/{ts-tags-331c9d1410f19ce7813877818861020d.js → ts-tags-4c20ddd60578a466fdf5f0d25dcdf636.js} +6 -6
  223. package/client/_expo/static/js/web/{tsv-c1e08a3902330dd31cb08b8695fe1912.js → tsv-0be09e67d8737eaf37f7ce8ee9635ede.js} +1 -1
  224. package/client/_expo/static/js/web/{typespec-74b1083d1b2cd47f048086a0fbf1ac8a.js → typespec-e0e3a5f082aa44c545f75f48208938f2.js} +1 -1
  225. package/client/_expo/static/js/web/{typst-5e6b9cd8887ac15e5300853aa72dbaf7.js → typst-643bcc94b440984f71dcfa283d344c9f.js} +1 -1
  226. package/client/_expo/static/js/web/{v-6cea322409be7ff269aec4cf3cc76066.js → v-286b673e1e07e579dc34f28274019e1e.js} +1 -1
  227. package/client/_expo/static/js/web/{vala-2b08d82af850a28f36caf7ca9f664b52.js → vala-0317bd87c52435825cd26c0ca35a682d.js} +1 -1
  228. package/client/_expo/static/js/web/{vesper-0fd33af0a5dbe874cba6f0721b9cec78.js → vesper-b6e895e722701e2beb365c966e8eec83.js} +1 -1
  229. package/client/_expo/static/js/web/{vhdl-5297dce8056f2b679408bcc5ce45a010.js → vhdl-4076d1a2a1fc47ae3fa9fec1089b4367.js} +1 -1
  230. package/client/_expo/static/js/web/{viml-16f5a8516fe0c29ff2f71f5a09096432.js → viml-a3197f6c04931952b603f0fc8f84c74e.js} +1 -1
  231. package/client/_expo/static/js/web/{vitesse-black-c80c1a0802c9950709c3a7e9f17db839.js → vitesse-black-5b189504699618b907f3642fc3447839.js} +1 -1
  232. package/client/_expo/static/js/web/{vitesse-dark-ff9e01a7e621f18dafd62e381f9b5e82.js → vitesse-dark-02dde9b66e9ba1adc1e1f8b7190ab830.js} +1 -1
  233. package/client/_expo/static/js/web/{vitesse-light-76bf678edbb2970576a045d09146dddf.js → vitesse-light-c8dfaba887e3c0904b1613d9a0f888b5.js} +1 -1
  234. package/client/_expo/static/js/web/{vue-6eaa6fadcd52a8f423fd2df66aa7206a.js → vue-3f43c897b4d550f9286246e84c2f75ce.js} +5 -5
  235. package/client/_expo/static/js/web/{vue-html-d9f05710e3ae1dd5986edd7b9e56442c.js → vue-html-b2eca99d39cc103ded2296bd5dffa962.js} +1 -1
  236. package/client/_expo/static/js/web/{vue-vine-46586e45ec94acf1850b5ab85bfa6dfc.js → vue-vine-3e97e6655cff1cd0d41642c88f97fa01.js} +1 -1
  237. package/client/_expo/static/js/web/{vyper-3b318e2a779fc2260d2ffbb2d89d005d.js → vyper-46a1585d3187e692b310da955280770c.js} +1 -1
  238. package/client/_expo/static/js/web/{wasm-4dbcd0e26afde57dd6c8f95ac22eb479.js → wasm-24a780325a3e9b1e4886419ba647f184.js} +2 -2
  239. package/client/_expo/static/js/web/{wasm-d5f8ac003a6340b522f5ca4abc79e306.js → wasm-842c77890bf8ae6a3d4396f92f8f698e.js} +1 -1
  240. package/client/_expo/static/js/web/{wasm-B9ZqxnKj-2becd88758f5fc2a4baf4892deedd634.js → wasm-B9ZqxnKj-fe539fe6cce1e3674f7b3773ad969f71.js} +1 -1
  241. package/client/_expo/static/js/web/{wenyan-87c368e58eab106ea71d9c6a29f1c48e.js → wenyan-72b1f6bea1b1ed08d1931fa3d42ceee9.js} +1 -1
  242. package/client/_expo/static/js/web/{wgsl-44c6445a73c51023d7bac7780ca289a7.js → wgsl-86fd3608286c990f980d8ffdfeb037fc.js} +1 -1
  243. package/client/_expo/static/js/web/{wikitext-bccf76de5d350b06d9566eac73ef9ec2.js → wikitext-06b6f7002105dee52573ad9414256a17.js} +1 -1
  244. package/client/_expo/static/js/web/{wit-e300715b0e55ff0ce8b0fe5e0dd6d57d.js → wit-51d7e27322b337b8b60322c15588f304.js} +1 -1
  245. package/client/_expo/static/js/web/{wolfram-0e2bbc827b4d4e765d45abcb59029c71.js → wolfram-2f95e5499405f80a97e1fa9b1777a38c.js} +1 -1
  246. package/client/_expo/static/js/web/{zenscript-92cdd71e9894e84aef837ccde3926e39.js → zenscript-96eb63fda2513a10ff725e023c228e5e.js} +1 -1
  247. package/client/index.html +3 -3
  248. package/package.json +2 -2
  249. package/client/_expo/static/css/markdown-editor-c7d01b900dca5674c4231847027038b2.css +0 -1
@@ -6,9 +6,9 @@ var __BUNDLE_START_TIME__=globalThis.nativePerformanceNow?nativePerformanceNow()
6
6
  __d(function(g,_r,i,a,m,_e,d){m.exports=function(r,e){if(null==r)return{};var n={};for(var t in r)if({}.hasOwnProperty.call(r,t)){if(-1!==e.indexOf(t))continue;n[t]=r[t]}return n},m.exports.__esModule=!0,m.exports.default=m.exports},25,[]);
7
7
  __d(function(g,r,i,a,m,_e,d){m.exports=function(e,t){if(!{}.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e},m.exports.__esModule=!0,m.exports.default=m.exports},30,[]);
8
8
  __d(function(g,r,i,a,m,_e,d){var e=0;m.exports=function(t){return"__private_"+e+++"_"+t},m.exports.__esModule=!0,m.exports.default=m.exports},31,[]);
9
- __d(function(g,r,i,a,m,e,d){m.exports=r(d[0])},982,[983]);
10
- __d(function(g,r,i,a,m,e,d){function n(n,t){const o=globalThis[`${__METRO_GLOBAL_PREFIX__??''}__loadBundleAsync`];if(null!=o){const s=String(n);if(null!=t){const n=t[s];if(null!=n)return o(n)}}}function t(t,o,s){const u=()=>r.importAll(t,s);try{return u()}catch(s){const c=n(t,o);if(null!=c)return c.then(u);throw s}const c=n(t,o);return null!=c?c.then(u):u()}function o(n,o,s){const u=t(n,o,s),c=Promise.resolve(u);return c._result=u,c}o.unstable_importMaybeSync=function(n,o){return t(n,o)},o.prefetch=function(t,o,s){n(t,o)?.then(()=>{},()=>{})},o.unstable_resolve=function(n,t){if(!t)throw new Error('Bundle splitting is required for Web Worker imports');const o=t[n];if(!o)throw new Error('Worker import is missing from split bundle paths: '+o);return o},o.unstable_createWorker=function(n,t){if('undefined'==typeof crossOriginIsolated||!crossOriginIsolated)return new Worker(n,t);try{const s=(o=n,`\n const ASYNC_WORKER_BASE = ${JSON.stringify(o)};\n const IMPORT_SCRIPTS = importScripts;\n const FETCH = fetch;\n const fromBaseURL = (input) => new URL(input, ASYNC_WORKER_BASE).href;\n self.fetch = function(input, init) {\n return FETCH(typeof input === 'string' ? fromBaseURL(input) : input, init);\n };\n self.importScripts = function(...urls) {\n return IMPORT_SCRIPTS.apply(self, urls.map(fromBaseURL));\n };\n importScripts(ASYNC_WORKER_BASE);\n `);return n=URL.createObjectURL(new Blob([s],{type:'text/javascript'})),new Worker(n,t)}finally{URL.revokeObjectURL(n)}var o},m.exports=o},983,[]);
11
- __d(function(g,r,i,a,m,e,d){"use strict";r(d[0])},1765,[1784]);
9
+ __d(function(g,r,i,a,m,e,d){m.exports=r(d[0])},985,[986]);
10
+ __d(function(g,r,i,a,m,e,d){function n(n,t){const o=globalThis[`${__METRO_GLOBAL_PREFIX__??''}__loadBundleAsync`];if(null!=o){const s=String(n);if(null!=t){const n=t[s];if(null!=n)return o(n)}}}function t(t,o,s){const u=()=>r.importAll(t,s);try{return u()}catch(s){const c=n(t,o);if(null!=c)return c.then(u);throw s}const c=n(t,o);return null!=c?c.then(u):u()}function o(n,o,s){const u=t(n,o,s),c=Promise.resolve(u);return c._result=u,c}o.unstable_importMaybeSync=function(n,o){return t(n,o)},o.prefetch=function(t,o,s){n(t,o)?.then(()=>{},()=>{})},o.unstable_resolve=function(n,t){if(!t)throw new Error('Bundle splitting is required for Web Worker imports');const o=t[n];if(!o)throw new Error('Worker import is missing from split bundle paths: '+o);return o},o.unstable_createWorker=function(n,t){if('undefined'==typeof crossOriginIsolated||!crossOriginIsolated)return new Worker(n,t);try{const s=(o=n,`\n const ASYNC_WORKER_BASE = ${JSON.stringify(o)};\n const IMPORT_SCRIPTS = importScripts;\n const FETCH = fetch;\n const fromBaseURL = (input) => new URL(input, ASYNC_WORKER_BASE).href;\n self.fetch = function(input, init) {\n return FETCH(typeof input === 'string' ? fromBaseURL(input) : input, init);\n };\n self.importScripts = function(...urls) {\n return IMPORT_SCRIPTS.apply(self, urls.map(fromBaseURL));\n };\n importScripts(ASYNC_WORKER_BASE);\n `);return n=URL.createObjectURL(new Blob([s],{type:'text/javascript'})),new Worker(n,t)}finally{URL.revokeObjectURL(n)}var o},m.exports=o},986,[]);
11
+ __d(function(g,r,i,a,m,e,d){"use strict";r(d[0])},1766,[1785]);
12
12
  __d(function(e,t,n,r,o,s,i){var a,l,c,u,d,h,p=t(i[0]).default,f=t(i[1]).default,g=t(i[2]).default;const m=["content","explanation","offset"],y=["lazyCompile"],b=["theme"];var w=Object.defineProperty,k=(e,t)=>{let n={};for(var r in e)w(n,r,{get:e[r],enumerable:!0});return t||w(n,Symbol.toStringTag,{value:"Module"}),n},C=Object.defineProperty,v=Object.getOwnPropertyDescriptor,x=Object.getOwnPropertyNames,S=Object.prototype.hasOwnProperty,_=(e,t)=>{let n={};for(var r in e)C(n,r,{get:e[r],enumerable:!0});return t||C(n,Symbol.toStringTag,{value:"Module"}),n},A=(e,t,n,r)=>{if(t&&"object"==typeof t||"function"==typeof t)for(var o,s=x(t),i=0,a=s.length;i<a;i++)o=s[i],S.call(e,o)||o===n||C(e,o,{get:(e=>t[e]).bind(null,o),enumerable:!(r=v(t,o))||r.enumerable});return e},E=class extends Error{constructor(e){super(e),this.name="ShikiError"}};function L(e){return Array.isArray(e)?I(e):e instanceof RegExp?e:"object"==typeof e?N(e):e}function I(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=L(e[n]);return t}function N(e){let t={};for(let n in e)t[n]=L(e[n]);return t}function P(e,...t){return t.forEach(t=>{for(let n in t)e[n]=t[n]}),e}function O(e){const t=~e.lastIndexOf("/")||~e.lastIndexOf("\\");return 0===t?e:~t===e.length-1?O(e.substring(0,e.length-1)):e.substr(1+~t)}var T=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,$=class{static hasCaptures(e){return null!==e&&(T.lastIndex=0,T.test(e))}static replaceCaptures(e,t,n){return e.replace(T,(e,r,o,s)=>{let i=n[parseInt(r||o,10)];if(!i)return e;{let e=t.substring(i.start,i.end);for(;"."===e[0];)e=e.substring(1);switch(s){case"downcase":return e.toLowerCase();case"upcase":return e.toUpperCase();default:return e}}})}};function R(e,t){return e<t?-1:e>t?1:0}function M(e,t){if(null===e&&null===t)return 0;if(!e)return-1;if(!t)return 1;let n=e.length,r=t.length;if(n===r){for(let r=0;r<n;r++){let n=R(e[r],t[r]);if(0!==n)return n}return 0}return n-r}function j(e){return!!/^#[0-9a-f]{6}$/i.test(e)||(!!/^#[0-9a-f]{8}$/i.test(e)||(!!/^#[0-9a-f]{3}$/i.test(e)||!!/^#[0-9a-f]{4}$/i.test(e)))}function D(e){return e.replace(/[\-\\\{\}\*\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,"\\$&")}var B=class{constructor(e){this.fn=e}cache=new Map;get(e){if(this.cache.has(e))return this.cache.get(e);const t=this.fn(e);return this.cache.set(e,t),t}},F=class{constructor(e,t,n){this._colorMap=e,this._defaults=t,this._root=n}static createFromRawTheme(e,t){return this.createFromParsedTheme(q(e),t)}static createFromParsedTheme(e,t){return X(e,t)}_cachedMatchRoot=new B(e=>this._root.match(e));getColorMap(){return this._colorMap.getColorMap()}getDefaults(){return this._defaults}match(e){if(null===e)return this._defaults;const t=e.scopeName,n=this._cachedMatchRoot.get(t).find(t=>U(e.parent,t.parentScopes));return n?new z(n.fontStyle,n.foreground,n.background):null}},G=class e{constructor(e,t){this.parent=e,this.scopeName=t}static push(t,n){for(const r of n)t=new e(t,r);return t}static from(...t){let n=null;for(let r=0;r<t.length;r++)n=new e(n,t[r]);return n}push(t){return new e(this,t)}getSegments(){let e=this;const t=[];for(;e;)t.push(e.scopeName),e=e.parent;return t.reverse(),t}toString(){return this.getSegments().join(" ")}extends(e){return this===e||null!==this.parent&&this.parent.extends(e)}getExtensionIfDefined(e){const t=[];let n=this;for(;n&&n!==e;)t.push(n.scopeName),n=n.parent;return n===e?t.reverse():void 0}};function U(e,t){if(0===t.length)return!0;for(let n=0;n<t.length;n++){let r=t[n],o=!1;if(">"===r){if(n===t.length-1)return!1;r=t[++n],o=!0}for(;e&&!W(e.scopeName,r);){if(o)return!1;e=e.parent}if(!e)return!1;e=e.parent}return!0}function W(e,t){return t===e||e.startsWith(t)&&"."===e[t.length]}var z=class{constructor(e,t,n){this.fontStyle=e,this.foregroundId=t,this.backgroundId=n}};function q(e){if(!e)return[];if(!e.settings||!Array.isArray(e.settings))return[];let t=e.settings,n=[],r=0;for(let e=0,o=t.length;e<o;e++){let o,s=t[e];if(!s.settings)continue;if("string"==typeof s.scope){let e=s.scope;e=e.replace(/^[,]+/,""),e=e.replace(/[,]+$/,""),o=e.split(",")}else o=Array.isArray(s.scope)?s.scope:[""];let i=-1;if("string"==typeof s.settings.fontStyle){i=0;let e=s.settings.fontStyle.split(" ");for(let t=0,n=e.length;t<n;t++)switch(e[t]){case"italic":i|=1;break;case"bold":i|=2;break;case"underline":i|=4;break;case"strikethrough":i|=8}}let a=null;"string"==typeof s.settings.foreground&&j(s.settings.foreground)&&(a=s.settings.foreground);let l=null;"string"==typeof s.settings.background&&j(s.settings.background)&&(l=s.settings.background);for(let t=0,s=o.length;t<s;t++){let s=o[t].trim().split(" "),c=s[s.length-1],u=null;s.length>1&&(u=s.slice(0,s.length-1),u.reverse()),n[r++]=new H(c,u,e,i,a,l)}}return n}var H=class{constructor(e,t,n,r,o,s){this.scope=e,this.parentScopes=t,this.index=n,this.fontStyle=r,this.foreground=o,this.background=s}},V=(e=>(e[e.NotSet=-1]="NotSet",e[e.None=0]="None",e[e.Italic=1]="Italic",e[e.Bold=2]="Bold",e[e.Underline=4]="Underline",e[e.Strikethrough=8]="Strikethrough",e))(V||{});function X(e,t){e.sort((e,t)=>{let n=R(e.scope,t.scope);return 0!==n?n:(n=M(e.parentScopes,t.parentScopes),0!==n?n:e.index-t.index)});let n=0,r="#000000",o="#ffffff";for(;e.length>=1&&""===e[0].scope;){let t=e.shift();-1!==t.fontStyle&&(n=t.fontStyle),null!==t.foreground&&(r=t.foreground),null!==t.background&&(o=t.background)}let s=new K(t),i=new z(n,s.getId(r),s.getId(o)),a=new Q(new J(0,null,-1,0,0),[]);for(let t=0,n=e.length;t<n;t++){let n=e[t];a.insert(0,n.scope,n.parentScopes,n.fontStyle,s.getId(n.foreground),s.getId(n.background))}return new F(s,i,a)}var K=class{constructor(e){if(this._lastColorId=0,this._id2color=[],this._color2id=Object.create(null),Array.isArray(e)){this._isFrozen=!0;for(let t=0,n=e.length;t<n;t++)this._color2id[e[t]]=t,this._id2color[t]=e[t]}else this._isFrozen=!1}getId(e){if(null===e)return 0;e=e.toUpperCase();let t=this._color2id[e];if(t)return t;if(this._isFrozen)throw new Error(`Missing color in color map - ${e}`);return t=++this._lastColorId,this._color2id[e]=t,this._id2color[t]=e,t}getColorMap(){return this._id2color.slice(0)}},Z=Object.freeze([]),J=class e{constructor(e,t,n,r,o){this.scopeDepth=e,this.parentScopes=t||Z,this.fontStyle=n,this.foreground=r,this.background=o}clone(){return new e(this.scopeDepth,this.parentScopes,this.fontStyle,this.foreground,this.background)}static cloneArr(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=e[n].clone();return t}acceptOverwrite(e,t,n,r){this.scopeDepth>e?console.log("how did this happen?"):this.scopeDepth=e,-1!==t&&(this.fontStyle=t),0!==n&&(this.foreground=n),0!==r&&(this.background=r)}},Q=class e{constructor(e,t=[],n={}){this._mainRule=e,this._children=n,this._rulesWithParentScopes=t}static _cmpBySpecificity(e,t){if(e.scopeDepth!==t.scopeDepth)return t.scopeDepth-e.scopeDepth;let n=0,r=0;for(;">"===e.parentScopes[n]&&n++,">"===t.parentScopes[r]&&r++,!(n>=e.parentScopes.length||r>=t.parentScopes.length);){const o=t.parentScopes[r].length-e.parentScopes[n].length;if(0!==o)return o;n++,r++}return t.parentScopes.length-e.parentScopes.length}match(t){if(""!==t){let e,n,r=t.indexOf(".");if(-1===r?(e=t,n=""):(e=t.substring(0,r),n=t.substring(r+1)),this._children.hasOwnProperty(e))return this._children[e].match(n)}const n=this._rulesWithParentScopes.concat(this._mainRule);return n.sort(e._cmpBySpecificity),n}insert(t,n,r,o,s,i){if(""===n)return void this._doInsertHere(t,r,o,s,i);let a,l,c,u=n.indexOf(".");-1===u?(a=n,l=""):(a=n.substring(0,u),l=n.substring(u+1)),this._children.hasOwnProperty(a)?c=this._children[a]:(c=new e(this._mainRule.clone(),J.cloneArr(this._rulesWithParentScopes)),this._children[a]=c),c.insert(t+1,l,r,o,s,i)}_doInsertHere(e,t,n,r,o){if(null!==t){for(let s=0,i=this._rulesWithParentScopes.length;s<i;s++){let i=this._rulesWithParentScopes[s];if(0===M(i.parentScopes,t))return void i.acceptOverwrite(e,n,r,o)}-1===n&&(n=this._mainRule.fontStyle),0===r&&(r=this._mainRule.foreground),0===o&&(o=this._mainRule.background),this._rulesWithParentScopes.push(new J(e,t,n,r,o))}else this._mainRule.acceptOverwrite(e,n,r,o)}},Y=class e{static toBinaryStr(e){return e.toString(2).padStart(32,"0")}static print(t){const n=e.getLanguageId(t),r=e.getTokenType(t),o=e.getFontStyle(t),s=e.getForeground(t),i=e.getBackground(t);console.log({languageId:n,tokenType:r,fontStyle:o,foreground:s,background:i})}static getLanguageId(e){return(255&e)>>>0}static getTokenType(e){return(768&e)>>>8}static containsBalancedBrackets(e){return!!(1024&e)}static getFontStyle(e){return(30720&e)>>>11}static getForeground(e){return(16744448&e)>>>15}static getBackground(e){return(4278190080&e)>>>24}static set(t,n,r,o,s,i,a){let l=e.getLanguageId(t),c=e.getTokenType(t),u=e.containsBalancedBrackets(t)?1:0,d=e.getFontStyle(t),h=e.getForeground(t),p=e.getBackground(t);return 0!==n&&(l=n),8!==r&&(c=r),null!==o&&(u=o?1:0),-1!==s&&(d=s),0!==i&&(h=i),0!==a&&(p=a),(l|c<<8|u<<10|d<<11|h<<15|p<<24)>>>0}};function ee(e){return e}function te(e,t){const n=[],r=re(e);let o=r.next();for(;null!==o;){let e=0;if(2===o.length&&":"===o.charAt(1)){switch(o.charAt(0)){case"R":e=1;break;case"L":e=-1;break;default:console.log(`Unknown priority ${o} in scope selector`)}o=r.next()}let t=i();if(n.push({matcher:t,priority:e}),","!==o)break;o=r.next()}return n;function s(){if("-"===o){o=r.next();const e=s();return t=>!!e&&!e(t)}if("("===o){o=r.next();const e=a();return")"===o&&(o=r.next()),e}if(ne(o)){const e=[];do{e.push(o),o=r.next()}while(ne(o));return n=>t(e,n)}return null}function i(){const e=[];let t=s();for(;t;)e.push(t),t=s();return t=>e.every(e=>e(t))}function a(){const e=[];let t=i();for(;t&&(e.push(t),"|"===o||","===o);){do{o=r.next()}while("|"===o||","===o);t=i()}return t=>e.some(e=>e(t))}}function ne(e){return!!e&&!!e.match(/[\w\.:]+/)}function re(e){let t=/([LR]:|[\w\.:][\w\.:\-]*|[\,\|\-\(\)])/g,n=t.exec(e);return{next:()=>{if(!n)return null;const r=n[0];return n=t.exec(e),r}}}function oe(e){"function"==typeof e.dispose&&e.dispose()}var se=class{constructor(e){this.scopeName=e}toKey(){return this.scopeName}},ie=class{constructor(e,t){this.scopeName=e,this.ruleName=t}toKey(){return`${this.scopeName}#${this.ruleName}`}},ae=class{_references=[];_seenReferenceKeys=new Set;get references(){return this._references}visitedRule=new Set;add(e){const t=e.toKey();this._seenReferenceKeys.has(t)||(this._seenReferenceKeys.add(t),this._references.push(e))}},le=class{constructor(e,t){this.repo=e,this.initialScopeName=t,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new se(this.initialScopeName)]}seenFullScopeRequests=new Set;seenPartialScopeRequests=new Set;processQueue(){const e=this.Q;this.Q=[];const t=new ae;for(const n of e)ce(n,this.initialScopeName,this.repo,t);for(const e of t.references)if(e instanceof se){if(this.seenFullScopeRequests.has(e.scopeName))continue;this.seenFullScopeRequests.add(e.scopeName),this.Q.push(e)}else{if(this.seenFullScopeRequests.has(e.scopeName))continue;if(this.seenPartialScopeRequests.has(e.toKey()))continue;this.seenPartialScopeRequests.add(e.toKey()),this.Q.push(e)}}};function ce(e,t,n,r){const o=n.lookup(e.scopeName);if(!o){if(e.scopeName===t)throw new Error(`No grammar provided for <${t}>`);return}const s=n.lookup(t);e instanceof se?de({baseGrammar:s,selfGrammar:o},r):ue(e.ruleName,{baseGrammar:s,selfGrammar:o,repository:o.repository},r);const i=n.injections(e.scopeName);if(i)for(const e of i)r.add(new se(e))}function ue(e,t,n){if(t.repository&&t.repository[e]){he([t.repository[e]],t,n)}}function de(e,t){e.selfGrammar.patterns&&Array.isArray(e.selfGrammar.patterns)&&he(e.selfGrammar.patterns,Object.assign({},e,{repository:e.selfGrammar.repository}),t),e.selfGrammar.injections&&he(Object.values(e.selfGrammar.injections),Object.assign({},e,{repository:e.selfGrammar.repository}),t)}function he(e,t,n){for(const r of e){if(n.visitedRule.has(r))continue;n.visitedRule.add(r);const e=r.repository?P({},t.repository,r.repository):t.repository;Array.isArray(r.patterns)&&he(r.patterns,Object.assign({},t,{repository:e}),n);const o=r.include;if(!o)continue;const s=be(o);switch(s.kind){case 0:de(Object.assign({},t,{selfGrammar:t.baseGrammar}),n);break;case 1:de(t,n);break;case 2:ue(s.ruleName,Object.assign({},t,{repository:e}),n);break;case 3:case 4:const r=s.scopeName===t.selfGrammar.scopeName?t.selfGrammar:s.scopeName===t.baseGrammar.scopeName?t.baseGrammar:void 0;if(r){const o={baseGrammar:t.baseGrammar,selfGrammar:r,repository:e};4===s.kind?ue(s.ruleName,o,n):de(o,n)}else 4===s.kind?n.add(new ie(s.scopeName,s.ruleName)):n.add(new se(s.scopeName))}}}var pe=class{kind=0},fe=class{kind=1},ge=class{constructor(e){this.ruleName=e}kind=2},me=class{constructor(e){this.scopeName=e}kind=3},ye=class{constructor(e,t){this.scopeName=e,this.ruleName=t}kind=4};function be(e){if("$base"===e)return new pe;if("$self"===e)return new fe;const t=e.indexOf("#");return-1===t?new me(e):0===t?new ge(e.substring(1)):new ye(e.substring(0,t),e.substring(t+1))}var we=/\\(\d+)/,ke=/\\(\d+)/g;var Ce=class{constructor(e,t,n,r){this.$location=e,this.id=t,this._name=n||null,this._nameIsCapturing=$.hasCaptures(this._name),this._contentName=r||null,this._contentNameIsCapturing=$.hasCaptures(this._contentName)}get debugName(){const e=this.$location?`${O(this.$location.filename)}:${this.$location.line}`:"unknown";return`${this.constructor.name}#${this.id} @ ${e}`}getName(e,t){return this._nameIsCapturing&&null!==this._name&&null!==e&&null!==t?$.replaceCaptures(this._name,e,t):this._name}getContentName(e,t){return this._contentNameIsCapturing&&null!==this._contentName?$.replaceCaptures(this._contentName,e,t):this._contentName}},ve=class extends Ce{constructor(e,t,n,r,o){super(e,t,n,r),this.retokenizeCapturedWithRuleId=o}dispose(){}collectPatterns(e,t){throw new Error("Not supported!")}compile(e,t){throw new Error("Not supported!")}compileAG(e,t,n,r){throw new Error("Not supported!")}},xe=class extends Ce{constructor(e,t,n,r,o){super(e,t,n,null),this._match=new Le(r,this.id),this.captures=o,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugMatchRegExp(){return`${this._match.source}`}collectPatterns(e,t){t.push(this._match)}compile(e,t){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e).compileAG(e,n,r)}_getCachedCompiledPatterns(e){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new Ie,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Se=class extends Ce{constructor(e,t,n,r,o){super(e,t,n,r),this.patterns=o.patterns,this.hasMissingPatterns=o.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}collectPatterns(e,t){for(const n of this.patterns)e.getRule(n).collectPatterns(e,t)}compile(e,t){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e).compileAG(e,n,r)}_getCachedCompiledPatterns(e){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new Ie,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},_e=class extends Ce{constructor(e,t,n,r,o,s,i,a,l,c){super(e,t,n,r),this._begin=new Le(o,this.id),this.beginCaptures=s,this._end=new Le(i||"\uffff",-1),this.endHasBackReferences=this._end.hasBackReferences,this.endCaptures=a,this.applyEndPatternLast=l||!1,this.patterns=c.patterns,this.hasMissingPatterns=c.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugEndRegExp(){return`${this._end.source}`}getEndWithResolvedBackReferences(e,t){return this._end.resolveBackReferences(e,t)}collectPatterns(e,t){t.push(this._begin)}compile(e,t){return this._getCachedCompiledPatterns(e,t).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e,t).compileAG(e,n,r)}_getCachedCompiledPatterns(e,t){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new Ie;for(const t of this.patterns)e.getRule(t).collectPatterns(e,this._cachedCompiledPatterns);this.applyEndPatternLast?this._cachedCompiledPatterns.push(this._end.hasBackReferences?this._end.clone():this._end):this._cachedCompiledPatterns.unshift(this._end.hasBackReferences?this._end.clone():this._end)}return this._end.hasBackReferences&&(this.applyEndPatternLast?this._cachedCompiledPatterns.setSource(this._cachedCompiledPatterns.length()-1,t):this._cachedCompiledPatterns.setSource(0,t)),this._cachedCompiledPatterns}},Ae=class extends Ce{constructor(e,t,n,r,o,s,i,a,l){super(e,t,n,r),this._begin=new Le(o,this.id),this.beginCaptures=s,this.whileCaptures=a,this._while=new Le(i,-2),this.whileHasBackReferences=this._while.hasBackReferences,this.patterns=l.patterns,this.hasMissingPatterns=l.hasMissingPatterns,this._cachedCompiledPatterns=null,this._cachedCompiledWhilePatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null),this._cachedCompiledWhilePatterns&&(this._cachedCompiledWhilePatterns.dispose(),this._cachedCompiledWhilePatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugWhileRegExp(){return`${this._while.source}`}getWhileWithResolvedBackReferences(e,t){return this._while.resolveBackReferences(e,t)}collectPatterns(e,t){t.push(this._begin)}compile(e,t){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e).compileAG(e,n,r)}_getCachedCompiledPatterns(e){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new Ie;for(const t of this.patterns)e.getRule(t).collectPatterns(e,this._cachedCompiledPatterns)}return this._cachedCompiledPatterns}compileWhile(e,t){return this._getCachedCompiledWhilePatterns(e,t).compile(e)}compileWhileAG(e,t,n,r){return this._getCachedCompiledWhilePatterns(e,t).compileAG(e,n,r)}_getCachedCompiledWhilePatterns(e,t){return this._cachedCompiledWhilePatterns||(this._cachedCompiledWhilePatterns=new Ie,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,t||"\uffff"),this._cachedCompiledWhilePatterns}},Ee=class e{static createCaptureRule(e,t,n,r,o){return e.registerRule(e=>new ve(t,e,n,r,o))}static getCompiledRuleId(t,n,r){return t.id||n.registerRule(o=>{if(t.id=o,t.match)return new xe(t.$vscodeTextmateLocation,t.id,t.name,t.match,e._compileCaptures(t.captures,n,r));if(void 0===t.begin){t.repository&&(r=P({},r,t.repository));let o=t.patterns;return void 0===o&&t.include&&(o=[{include:t.include}]),new Se(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,e._compilePatterns(o,n,r))}return t.while?new Ae(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,e._compileCaptures(t.beginCaptures||t.captures,n,r),t.while,e._compileCaptures(t.whileCaptures||t.captures,n,r),e._compilePatterns(t.patterns,n,r)):new _e(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,e._compileCaptures(t.beginCaptures||t.captures,n,r),t.end,e._compileCaptures(t.endCaptures||t.captures,n,r),t.applyEndPatternLast,e._compilePatterns(t.patterns,n,r))}),t.id}static _compileCaptures(t,n,r){let o=[];if(t){let s=0;for(const e in t){if("$vscodeTextmateLocation"===e)continue;const t=parseInt(e,10);t>s&&(s=t)}for(let e=0;e<=s;e++)o[e]=null;for(const s in t){if("$vscodeTextmateLocation"===s)continue;const i=parseInt(s,10);let a=0;t[s].patterns&&(a=e.getCompiledRuleId(t[s],n,r)),o[i]=e.createCaptureRule(n,t[s].$vscodeTextmateLocation,t[s].name,t[s].contentName,a)}}return o}static _compilePatterns(t,n,r){let o=[];if(t)for(let s=0,i=t.length;s<i;s++){const i=t[s];let a=-1;if(i.include){const t=be(i.include);switch(t.kind){case 0:case 1:a=e.getCompiledRuleId(r[i.include],n,r);break;case 2:let o=r[t.ruleName];o&&(a=e.getCompiledRuleId(o,n,r));break;case 3:case 4:const s=t.scopeName,l=4===t.kind?t.ruleName:null,c=n.getExternalGrammar(s,r);if(c)if(l){let t=c.repository[l];t&&(a=e.getCompiledRuleId(t,n,c.repository))}else a=e.getCompiledRuleId(c.repository.$self,n,c.repository)}}else a=e.getCompiledRuleId(i,n,r);if(-1!==a){const e=n.getRule(a);let t=!1;if((e instanceof Se||e instanceof _e||e instanceof Ae)&&e.hasMissingPatterns&&0===e.patterns.length&&(t=!0),t)continue;o.push(a)}}return{patterns:o,hasMissingPatterns:(t?t.length:0)!==o.length}}},Le=class e{constructor(e,t){if(e&&"string"==typeof e){const t=e.length;let n=0,r=[],o=!1;for(let s=0;s<t;s++)if("\\"===e.charAt(s)&&s+1<t){const t=e.charAt(s+1);"z"===t?(r.push(e.substring(n,s)),r.push("$(?!\\n)(?<!\\n)"),n=s+2):"A"!==t&&"G"!==t||(o=!0),s++}this.hasAnchor=o,0===n?this.source=e:(r.push(e.substring(n,t)),this.source=r.join(""))}else this.hasAnchor=!1,this.source=e;this.hasAnchor?this._anchorCache=this._buildAnchorCache():this._anchorCache=null,this.ruleId=t,"string"==typeof this.source?this.hasBackReferences=we.test(this.source):this.hasBackReferences=!1}clone(){return new e(this.source,this.ruleId)}setSource(e){this.source!==e&&(this.source=e,this.hasAnchor&&(this._anchorCache=this._buildAnchorCache()))}resolveBackReferences(e,t){if("string"!=typeof this.source)throw new Error("This method should only be called if the source is a string");let n=t.map(t=>e.substring(t.start,t.end));return ke.lastIndex=0,this.source.replace(ke,(e,t)=>D(n[parseInt(t,10)]||""))}_buildAnchorCache(){if("string"!=typeof this.source)throw new Error("This method should only be called if the source is a string");let e,t,n,r,o=[],s=[],i=[],a=[];for(e=0,t=this.source.length;e<t;e++)n=this.source.charAt(e),o[e]=n,s[e]=n,i[e]=n,a[e]=n,"\\"===n&&e+1<t&&(r=this.source.charAt(e+1),"A"===r?(o[e+1]="\uffff",s[e+1]="\uffff",i[e+1]="A",a[e+1]="A"):"G"===r?(o[e+1]="\uffff",s[e+1]="G",i[e+1]="\uffff",a[e+1]="G"):(o[e+1]=r,s[e+1]=r,i[e+1]=r,a[e+1]=r),e++);return{A0_G0:o.join(""),A0_G1:s.join(""),A1_G0:i.join(""),A1_G1:a.join("")}}resolveAnchors(e,t){return this.hasAnchor&&this._anchorCache&&"string"==typeof this.source?e?t?this._anchorCache.A1_G1:this._anchorCache.A1_G0:t?this._anchorCache.A0_G1:this._anchorCache.A0_G0:this.source}},Ie=class{constructor(){this._items=[],this._hasAnchors=!1,this._cached=null,this._anchorCache={A0_G0:null,A0_G1:null,A1_G0:null,A1_G1:null}}dispose(){this._disposeCaches()}_disposeCaches(){this._cached&&(this._cached.dispose(),this._cached=null),this._anchorCache.A0_G0&&(this._anchorCache.A0_G0.dispose(),this._anchorCache.A0_G0=null),this._anchorCache.A0_G1&&(this._anchorCache.A0_G1.dispose(),this._anchorCache.A0_G1=null),this._anchorCache.A1_G0&&(this._anchorCache.A1_G0.dispose(),this._anchorCache.A1_G0=null),this._anchorCache.A1_G1&&(this._anchorCache.A1_G1.dispose(),this._anchorCache.A1_G1=null)}push(e){this._items.push(e),this._hasAnchors=this._hasAnchors||e.hasAnchor}unshift(e){this._items.unshift(e),this._hasAnchors=this._hasAnchors||e.hasAnchor}length(){return this._items.length}setSource(e,t){this._items[e].source!==t&&(this._disposeCaches(),this._items[e].setSource(t))}compile(e){if(!this._cached){let t=this._items.map(e=>e.source);this._cached=new Ne(e,t,this._items.map(e=>e.ruleId))}return this._cached}compileAG(e,t,n){return this._hasAnchors?t?n?(this._anchorCache.A1_G1||(this._anchorCache.A1_G1=this._resolveAnchors(e,t,n)),this._anchorCache.A1_G1):(this._anchorCache.A1_G0||(this._anchorCache.A1_G0=this._resolveAnchors(e,t,n)),this._anchorCache.A1_G0):n?(this._anchorCache.A0_G1||(this._anchorCache.A0_G1=this._resolveAnchors(e,t,n)),this._anchorCache.A0_G1):(this._anchorCache.A0_G0||(this._anchorCache.A0_G0=this._resolveAnchors(e,t,n)),this._anchorCache.A0_G0):this.compile(e)}_resolveAnchors(e,t,n){return new Ne(e,this._items.map(e=>e.resolveAnchors(t,n)),this._items.map(e=>e.ruleId))}},Ne=class{constructor(e,t,n){this.regExps=t,this.rules=n,this.scanner=e.createOnigScanner(t)}dispose(){"function"==typeof this.scanner.dispose&&this.scanner.dispose()}toString(){const e=[];for(let t=0,n=this.rules.length;t<n;t++)e.push(" - "+this.rules[t]+": "+this.regExps[t]);return e.join("\n")}findNextMatchSync(e,t,n){const r=this.scanner.findNextMatchSync(e,t,n);return r?{ruleId:this.rules[r.index],captureIndices:r.captureIndices}:null}},Pe=class{constructor(e,t){this.languageId=e,this.tokenType=t}},Oe=class e{constructor(e,t){this._defaultAttributes=new Pe(e,8),this._embeddedLanguagesMatcher=new Te(Object.entries(t||{}))}getDefaultAttributes(){return this._defaultAttributes}getBasicScopeAttributes(t){return null===t?e._NULL_SCOPE_METADATA:this._getBasicScopeAttributes.get(t)}static _NULL_SCOPE_METADATA=new Pe(0,0);_getBasicScopeAttributes=new B(e=>new Pe(this._scopeToLanguage(e),this._toStandardTokenType(e)));_scopeToLanguage(e){return this._embeddedLanguagesMatcher.match(e)||0}_toStandardTokenType(t){const n=t.match(e.STANDARD_TOKEN_TYPE_REGEXP);if(!n)return 8;switch(n[1]){case"comment":return 1;case"string":return 2;case"regex":return 3;case"meta.embedded":return 0}throw new Error("Unexpected match for standard token type!")}static STANDARD_TOKEN_TYPE_REGEXP=/\b(comment|string|regex|meta\.embedded)\b/},Te=class{constructor(e){if(0===e.length)this.values=null,this.scopesRegExp=null;else{this.values=new Map(e);const t=e.map(([e,t])=>D(e));t.sort(),t.reverse(),this.scopesRegExp=new RegExp(`^((${t.join(")|(")}))($|\\.)`,"")}}match(e){if(!this.scopesRegExp)return;const t=e.match(this.scopesRegExp);return t?this.values.get(t[1]):void 0}};"undefined"!=typeof process&&process.env.VSCODE_TEXTMATE_DEBUG;var $e=class{constructor(e,t){this.stack=e,this.stoppedEarly=t}};function Re(e,t,n,r,o,s,i,a){const l=t.content.length;let c=!1,u=-1;if(i){const i=Me(e,t,n,r,o,s);o=i.stack,r=i.linePos,n=i.isFirstLine,u=i.anchorPosition}const d=Date.now();for(;!c;){if(0!==a&&Date.now()-d>a)return new $e(o,!0);h()}return new $e(o,!1);function h(){const i=je(e,t,n,r,o,u);if(!i)return s.produce(o,l),void(c=!0);const a=i.captureIndices,d=i.matchedRuleId,h=!!(a&&a.length>0)&&a[0].end>r;if(-1===d){const i=o.getRule(e);s.produce(o,a[0].start),o=o.withContentNameScopesList(o.nameScopesList),Ue(e,t,n,o,s,i.endCaptures,a),s.produce(o,a[0].end);const d=o;if(o=o.parent,u=d.getAnchorPos(),!h&&d.getEnterPos()===r)return o=d,s.produce(o,l),void(c=!0)}else{const i=e.getRule(d);s.produce(o,a[0].start);const p=o,f=i.getName(t.content,a),g=o.contentNameScopesList.pushAttributed(f,e);if(o=o.push(d,r,u,a[0].end===l,null,g,g),i instanceof _e){const r=i;Ue(e,t,n,o,s,r.beginCaptures,a),s.produce(o,a[0].end),u=a[0].end;const d=r.getContentName(t.content,a),f=g.pushAttributed(d,e);if(o=o.withContentNameScopesList(f),r.endHasBackReferences&&(o=o.withEndRule(r.getEndWithResolvedBackReferences(t.content,a))),!h&&p.hasSameRuleAs(o))return o=o.pop(),s.produce(o,l),void(c=!0)}else if(i instanceof Ae){const r=i;Ue(e,t,n,o,s,r.beginCaptures,a),s.produce(o,a[0].end),u=a[0].end;const d=r.getContentName(t.content,a),f=g.pushAttributed(d,e);if(o=o.withContentNameScopesList(f),r.whileHasBackReferences&&(o=o.withEndRule(r.getWhileWithResolvedBackReferences(t.content,a))),!h&&p.hasSameRuleAs(o))return o=o.pop(),s.produce(o,l),void(c=!0)}else if(Ue(e,t,n,o,s,i.captures,a),s.produce(o,a[0].end),o=o.pop(),!h)return o=o.safePop(),s.produce(o,l),void(c=!0)}a[0].end>r&&(r=a[0].end,n=!1)}}function Me(e,t,n,r,o,s){let i=o.beginRuleCapturedEOL?0:-1;const a=[];for(let t=o;t;t=t.pop()){const n=t.getRule(e);n instanceof Ae&&a.push({rule:n,stack:t})}for(let l=a.pop();l;l=a.pop()){const{ruleScanner:a,findOptions:c}=Ge(l.rule,e,l.stack.endRule,n,r===i),u=a.findNextMatchSync(t,r,c);if(!u){o=l.stack.pop();break}if(-2!==u.ruleId){o=l.stack.pop();break}u.captureIndices&&u.captureIndices.length&&(s.produce(l.stack,u.captureIndices[0].start),Ue(e,t,n,l.stack,s,l.rule.whileCaptures,u.captureIndices),s.produce(l.stack,u.captureIndices[0].end),i=u.captureIndices[0].end,u.captureIndices[0].end>r&&(r=u.captureIndices[0].end,n=!1))}return{stack:o,linePos:r,anchorPosition:i,isFirstLine:n}}function je(e,t,n,r,o,s){const i=De(e,t,n,r,o,s),a=e.getInjections();if(0===a.length)return i;const l=Be(a,e,t,n,r,o,s);if(!l)return i;if(!i)return l;const c=i.captureIndices[0].start,u=l.captureIndices[0].start;return u<c||l.priorityMatch&&u===c?l:i}function De(e,t,n,r,o,s){const{ruleScanner:i,findOptions:a}=Fe(o.getRule(e),e,o.endRule,n,r===s),l=i.findNextMatchSync(t,r,a);return l?{captureIndices:l.captureIndices,matchedRuleId:l.ruleId}:null}function Be(e,t,n,r,o,s,i){let a,l=Number.MAX_VALUE,c=null,u=0;const d=s.contentNameScopesList.getScopeNames();for(let s=0,h=e.length;s<h;s++){const h=e[s];if(!h.matcher(d))continue;const{ruleScanner:p,findOptions:f}=Fe(t.getRule(h.ruleId),t,null,r,o===i),g=p.findNextMatchSync(n,o,f);if(!g)continue;const m=g.captureIndices[0].start;if(!(m>=l)&&(l=m,c=g.captureIndices,a=g.ruleId,u=h.priority,l===o))break}return c?{priorityMatch:-1===u,captureIndices:c,matchedRuleId:a}:null}function Fe(e,t,n,r,o){return{ruleScanner:e.compileAG(t,n,r,o),findOptions:0}}function Ge(e,t,n,r,o){return{ruleScanner:e.compileWhileAG(t,n,r,o),findOptions:0}}function Ue(e,t,n,r,o,s,i){if(0===s.length)return;const a=t.content,l=Math.min(s.length,i.length),c=[],u=i[0].end;for(let t=0;t<l;t++){const l=s[t];if(null===l)continue;const d=i[t];if(0===d.length)continue;if(d.start>u)break;for(;c.length>0&&c[c.length-1].endPos<=d.start;)o.produceFromScopes(c[c.length-1].scopes,c[c.length-1].endPos),c.pop();if(c.length>0?o.produceFromScopes(c[c.length-1].scopes,d.start):o.produce(r,d.start),l.retokenizeCapturedWithRuleId){const t=l.getName(a,i),s=r.contentNameScopesList.pushAttributed(t,e),c=l.getContentName(a,i),u=s.pushAttributed(c,e),h=r.push(l.retokenizeCapturedWithRuleId,d.start,-1,!1,null,s,u),p=e.createOnigString(a.substring(0,d.end));Re(e,p,n&&0===d.start,d.start,h,o,!1,0),oe(p);continue}const h=l.getName(a,i);if(null!==h){const t=(c.length>0?c[c.length-1].scopes:r.contentNameScopesList).pushAttributed(h,e);c.push(new We(t,d.end))}}for(;c.length>0;)o.produceFromScopes(c[c.length-1].scopes,c[c.length-1].endPos),c.pop()}var We=class{constructor(e,t){this.scopes=e,this.endPos=t}};function ze(e,t,n,r,o,s,i,a){return new Xe(e,t,n,r,o,s,i,a)}function qe(e,t,n,r,o){const s=te(t,He),i=Ee.getCompiledRuleId(n,r,o.repository);for(const n of s)e.push({debugSelector:t,matcher:n.matcher,ruleId:i,grammar:o,priority:n.priority})}function He(e,t){if(t.length<e.length)return!1;let n=0;return e.every(e=>{for(let r=n;r<t.length;r++)if(Ve(t[r],e))return n=r+1,!0;return!1})}function Ve(e,t){if(!e)return!1;if(e===t)return!0;const n=t.length;return e.length>n&&e.substr(0,n)===t&&"."===e[n]}var Xe=class{constructor(e,t,n,r,o,s,i,a){if(this._rootScopeName=e,this.balancedBracketSelectors=s,this._onigLib=a,this._basicScopeAttributesProvider=new Oe(n,r),this._rootId=-1,this._lastRuleId=0,this._ruleId2desc=[null],this._includedGrammars={},this._grammarRepository=i,this._grammar=Ke(t,null),this._injections=null,this._tokenTypeMatchers=[],o)for(const e of Object.keys(o)){const t=te(e,He);for(const n of t)this._tokenTypeMatchers.push({matcher:n.matcher,type:o[e]})}}get themeProvider(){return this._grammarRepository}dispose(){for(const e of this._ruleId2desc)e&&e.dispose()}createOnigScanner(e){return this._onigLib.createOnigScanner(e)}createOnigString(e){return this._onigLib.createOnigString(e)}getMetadataForScope(e){return this._basicScopeAttributesProvider.getBasicScopeAttributes(e)}_collectInjections(){const e=e=>e===this._rootScopeName?this._grammar:this.getExternalGrammar(e),t=[],n=this._rootScopeName,r=e(n);if(r){const e=r.injections;if(e)for(let n in e)qe(t,n,e[n],this,r);const o=this._grammarRepository.injections(n);o&&o.forEach(e=>{const n=this.getExternalGrammar(e);if(n){const e=n.injectionSelector;e&&qe(t,e,n,this,n)}})}return t.sort((e,t)=>e.priority-t.priority),t}getInjections(){return null===this._injections&&(this._injections=this._collectInjections()),this._injections}registerRule(e){const t=++this._lastRuleId,n=e(t);return this._ruleId2desc[t]=n,n}getRule(e){return this._ruleId2desc[e]}getExternalGrammar(e,t){if(this._includedGrammars[e])return this._includedGrammars[e];if(this._grammarRepository){const n=this._grammarRepository.lookup(e);if(n)return this._includedGrammars[e]=Ke(n,t&&t.$base),this._includedGrammars[e]}}tokenizeLine(e,t,n=0){const r=this._tokenize(e,t,!1,n);return{tokens:r.lineTokens.getResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}tokenizeLine2(e,t,n=0){const r=this._tokenize(e,t,!0,n);return{tokens:r.lineTokens.getBinaryResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}_tokenize(e,t,n,r){let o;if(-1===this._rootId&&(this._rootId=Ee.getCompiledRuleId(this._grammar.repository.$self,this,this._grammar.repository),this.getInjections()),t&&t!==Je.NULL)o=!1,t.reset();else{o=!0;const e=this._basicScopeAttributesProvider.getDefaultAttributes(),n=this.themeProvider.getDefaults(),r=Y.set(0,e.languageId,e.tokenType,null,n.fontStyle,n.foregroundId,n.backgroundId),s=this.getRule(this._rootId).getName(null,null);let i;i=s?Ze.createRootAndLookUpScopeName(s,r,this):Ze.createRoot("unknown",r),t=new Je(null,this._rootId,-1,-1,!1,null,i,i)}e+="\n";const s=this.createOnigString(e),i=s.content.length,a=new Ye(n,e,this._tokenTypeMatchers,this.balancedBracketSelectors),l=Re(this,s,o,0,t,a,!0,r);return oe(s),{lineLength:i,lineTokens:a,ruleStack:l.stack,stoppedEarly:l.stoppedEarly}}};function Ke(e,t){return(e=L(e)).repository=e.repository||{},e.repository.$self={$vscodeTextmateLocation:e.$vscodeTextmateLocation,patterns:e.patterns,name:e.scopeName},e.repository.$base=t||e.repository.$self,e}var Ze=class e{constructor(e,t,n){this.parent=e,this.scopePath=t,this.tokenAttributes=n}static fromExtension(t,n){let r=t,o=t?.scopePath??null;for(const t of n)o=G.push(o,t.scopeNames),r=new e(r,o,t.encodedTokenAttributes);return r}static createRoot(t,n){return new e(null,new G(null,t),n)}static createRootAndLookUpScopeName(t,n,r){const o=r.getMetadataForScope(t),s=new G(null,t),i=r.themeProvider.themeMatch(s),a=e.mergeAttributes(n,o,i);return new e(null,s,a)}get scopeName(){return this.scopePath.scopeName}toString(){return this.getScopeNames().join(" ")}equals(t){return e.equals(this,t)}static equals(e,t){for(;;){if(e===t)return!0;if(!e&&!t)return!0;if(!e||!t)return!1;if(e.scopeName!==t.scopeName||e.tokenAttributes!==t.tokenAttributes)return!1;e=e.parent,t=t.parent}}static mergeAttributes(e,t,n){let r=-1,o=0,s=0;return null!==n&&(r=n.fontStyle,o=n.foregroundId,s=n.backgroundId),Y.set(e,t.languageId,t.tokenType,null,r,o,s)}pushAttributed(t,n){if(null===t)return this;if(-1===t.indexOf(" "))return e._pushAttributed(this,t,n);const r=t.split(/ /g);let o=this;for(const t of r)o=e._pushAttributed(o,t,n);return o}static _pushAttributed(t,n,r){const o=r.getMetadataForScope(n),s=t.scopePath.push(n),i=r.themeProvider.themeMatch(s),a=e.mergeAttributes(t.tokenAttributes,o,i);return new e(t,s,a)}getScopeNames(){return this.scopePath.getSegments()}getExtensionIfDefined(e){const t=[];let n=this;for(;n&&n!==e;)t.push({encodedTokenAttributes:n.tokenAttributes,scopeNames:n.scopePath.getExtensionIfDefined(n.parent?.scopePath??null)}),n=n.parent;return n===e?t.reverse():void 0}},Je=class e{constructor(e,t,n,r,o,s,i,a){this.parent=e,this.ruleId=t,this.beginRuleCapturedEOL=o,this.endRule=s,this.nameScopesList=i,this.contentNameScopesList=a,this.depth=this.parent?this.parent.depth+1:1,this._enterPos=n,this._anchorPos=r}_stackElementBrand=void 0;static NULL=new e(null,0,0,0,!1,null,null,null);equals(t){return null!==t&&e._equals(this,t)}static _equals(e,t){return e===t||!!this._structuralEquals(e,t)&&Ze.equals(e.contentNameScopesList,t.contentNameScopesList)}static _structuralEquals(e,t){for(;;){if(e===t)return!0;if(!e&&!t)return!0;if(!e||!t)return!1;if(e.depth!==t.depth||e.ruleId!==t.ruleId||e.endRule!==t.endRule)return!1;e=e.parent,t=t.parent}}clone(){return this}static _reset(e){for(;e;)e._enterPos=-1,e._anchorPos=-1,e=e.parent}reset(){e._reset(this)}pop(){return this.parent}safePop(){return this.parent?this.parent:this}push(t,n,r,o,s,i,a){return new e(this,t,n,r,o,s,i,a)}getEnterPos(){return this._enterPos}getAnchorPos(){return this._anchorPos}getRule(e){return e.getRule(this.ruleId)}toString(){const e=[];return this._writeString(e,0),"["+e.join(",")+"]"}_writeString(e,t){return this.parent&&(t=this.parent._writeString(e,t)),e[t++]=`(${this.ruleId}, ${this.nameScopesList?.toString()}, ${this.contentNameScopesList?.toString()})`,t}withContentNameScopesList(e){return this.contentNameScopesList===e?this:this.parent.push(this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,this.endRule,this.nameScopesList,e)}withEndRule(t){return this.endRule===t?this:new e(this.parent,this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,t,this.nameScopesList,this.contentNameScopesList)}hasSameRuleAs(e){let t=this;for(;t&&t._enterPos===e._enterPos;){if(t.ruleId===e.ruleId)return!0;t=t.parent}return!1}toStateStackFrame(){return{ruleId:this.ruleId,beginRuleCapturedEOL:this.beginRuleCapturedEOL,endRule:this.endRule,nameScopesList:this.nameScopesList?.getExtensionIfDefined(this.parent?.nameScopesList??null)??[],contentNameScopesList:this.contentNameScopesList?.getExtensionIfDefined(this.nameScopesList)??[]}}static pushFrame(t,n){const r=Ze.fromExtension(t?.nameScopesList??null,n.nameScopesList);return new e(t,n.ruleId,n.enterPos??-1,n.anchorPos??-1,n.beginRuleCapturedEOL,n.endRule,r,Ze.fromExtension(r,n.contentNameScopesList))}},Qe=class{allowAny=!1;constructor(e,t){this.balancedBracketScopes=e.flatMap(e=>"*"===e?(this.allowAny=!0,[]):te(e,He).map(e=>e.matcher)),this.unbalancedBracketScopes=t.flatMap(e=>te(e,He).map(e=>e.matcher))}get matchesAlways(){return this.allowAny&&0===this.unbalancedBracketScopes.length}get matchesNever(){return 0===this.balancedBracketScopes.length&&!this.allowAny}match(e){for(const t of this.unbalancedBracketScopes)if(t(e))return!1;for(const t of this.balancedBracketScopes)if(t(e))return!0;return this.allowAny}},Ye=class{constructor(e,t,n,r){this.balancedBracketSelectors=r,this._emitBinaryTokens=e,this._tokenTypeOverrides=n,this._lineText=null,this._tokens=[],this._binaryTokens=[],this._lastTokenEndIndex=0}produce(e,t){this.produceFromScopes(e.contentNameScopesList,t)}produceFromScopes(e,t){if(this._lastTokenEndIndex>=t)return;if(this._emitBinaryTokens){let n=e?.tokenAttributes??0,r=!1;if(this.balancedBracketSelectors?.matchesAlways&&(r=!0),this._tokenTypeOverrides.length>0||this.balancedBracketSelectors&&!this.balancedBracketSelectors.matchesAlways&&!this.balancedBracketSelectors.matchesNever){const t=e?.getScopeNames()??[];for(const e of this._tokenTypeOverrides)e.matcher(t)&&(n=Y.set(n,0,ee(e.type),null,-1,0,0));this.balancedBracketSelectors&&(r=this.balancedBracketSelectors.match(t))}return r&&(n=Y.set(n,0,8,r,-1,0,0)),this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-1]===n?void(this._lastTokenEndIndex=t):(this._binaryTokens.push(this._lastTokenEndIndex),this._binaryTokens.push(n),void(this._lastTokenEndIndex=t))}const n=e?.getScopeNames()??[];this._tokens.push({startIndex:this._lastTokenEndIndex,endIndex:t,scopes:n}),this._lastTokenEndIndex=t}getResult(e,t){return this._tokens.length>0&&this._tokens[this._tokens.length-1].startIndex===t-1&&this._tokens.pop(),0===this._tokens.length&&(this._lastTokenEndIndex=-1,this.produce(e,t),this._tokens[this._tokens.length-1].startIndex=0),this._tokens}getBinaryResult(e,t){this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-2]===t-1&&(this._binaryTokens.pop(),this._binaryTokens.pop()),0===this._binaryTokens.length&&(this._lastTokenEndIndex=-1,this.produce(e,t),this._binaryTokens[this._binaryTokens.length-2]=0);const n=new Uint32Array(this._binaryTokens.length);for(let e=0,t=this._binaryTokens.length;e<t;e++)n[e]=this._binaryTokens[e];return n}},et=class{constructor(e,t){this._onigLib=t,this._theme=e}_grammars=new Map;_rawGrammars=new Map;_injectionGrammars=new Map;dispose(){for(const e of this._grammars.values())e.dispose()}setTheme(e){this._theme=e}getColorMap(){return this._theme.getColorMap()}addGrammar(e,t){this._rawGrammars.set(e.scopeName,e),t&&this._injectionGrammars.set(e.scopeName,t)}lookup(e){return this._rawGrammars.get(e)}injections(e){return this._injectionGrammars.get(e)}getDefaults(){return this._theme.getDefaults()}themeMatch(e){return this._theme.match(e)}grammarForScopeName(e,t,n,r,o){if(!this._grammars.has(e)){let s=this._rawGrammars.get(e);if(!s)return null;this._grammars.set(e,ze(e,s,t,n,r,o,this,this._onigLib))}return this._grammars.get(e)}},tt=class{constructor(e){this._options=e,this._syncRegistry=new et(F.createFromRawTheme(e.theme,e.colorMap),e.onigLib),this._ensureGrammarCache=new Map}dispose(){this._syncRegistry.dispose()}setTheme(e,t){this._syncRegistry.setTheme(F.createFromRawTheme(e,t))}getColorMap(){return this._syncRegistry.getColorMap()}loadGrammarWithEmbeddedLanguages(e,t,n){return this.loadGrammarWithConfiguration(e,t,{embeddedLanguages:n})}loadGrammarWithConfiguration(e,t,n){return this._loadGrammar(e,t,n.embeddedLanguages,n.tokenTypes,new Qe(n.balancedBracketSelectors||[],n.unbalancedBracketSelectors||[]))}loadGrammar(e){return this._loadGrammar(e,0,null,null,null)}_loadGrammar(e,t,n,r,o){const s=new le(this._syncRegistry,e);for(;s.Q.length>0;)s.Q.map(e=>this._loadSingleGrammar(e.scopeName)),s.processQueue();return this._grammarForScopeName(e,t,n,r,o)}_loadSingleGrammar(e){this._ensureGrammarCache.has(e)||(this._doLoadSingleGrammar(e),this._ensureGrammarCache.set(e,!0))}_doLoadSingleGrammar(e){const t=this._options.loadGrammar(e);if(t){const n="function"==typeof this._options.getInjections?this._options.getInjections(e):void 0;this._syncRegistry.addGrammar(t,n)}}addGrammar(e,t=[],n=0,r=null){return this._syncRegistry.addGrammar(e,t),this._grammarForScopeName(e.scopeName,n,r)}_grammarForScopeName(e,t=0,n=null,r=null,o=null){return this._syncRegistry.grammarForScopeName(e,t,n,r,o)}},nt=Je.NULL;function rt(e,t){const n="string"==typeof e?{}:Object.assign({},e.colorReplacements),r="string"==typeof e?e:e.name;for(const[e,o]of Object.entries(t?.colorReplacements||{}))"string"==typeof o?n[e]=o:e===r&&Object.assign(n,o);return n}function ot(e,t){return e&&t?.[e?.toLowerCase()]||e}function st(e){return Array.isArray(e)?e:[e]}async function it(e){return Promise.resolve("function"==typeof e?e():e).then(e=>e.default||e)}function at(e){return!e||["plaintext","txt","text","plain"].includes(e)}function lt(e){return"none"===e}function ct(e){return lt(e)}const ut=/(\r?\n)/g;function dt(e,t=!1){if(0===e.length)return[["",0]];const n=e.split(ut);let r=0;const o=[];for(let e=0;e<n.length;e+=2){const s=t?n[e]+(n[e+1]||""):n[e];o.push([s,r]),r+=n[e].length,r+=n[e+1]?.length||0}return o}const ht="#333333",pt="#bbbbbb",ft="#fffffe",gt="#1e1e1e",mt="__shiki_resolved";function yt(e){if(e?.[mt])return e;const t=Object.assign({},e);t.tokenColors&&!t.settings&&(t.settings=t.tokenColors,delete t.tokenColors),t.type||="dark",t.colorReplacements=Object.assign({},t.colorReplacements),t.settings||=[];let{bg:n,fg:r}=t;if(!n||!r){const e=t.settings?t.settings.find(e=>!e.name&&!e.scope):void 0;e?.settings?.foreground&&(r=e.settings.foreground),e?.settings?.background&&(n=e.settings.background),!r&&t?.colors?.["editor.foreground"]&&(r=t.colors["editor.foreground"]),!n&&t?.colors?.["editor.background"]&&(n=t.colors["editor.background"]),r||(r="light"===t.type?ht:pt),n||(n="light"===t.type?ft:gt),t.fg=r,t.bg=n}t.settings[0]&&t.settings[0].settings&&!t.settings[0].scope||t.settings.unshift({settings:{foreground:t.fg,background:t.bg}});let o=0;const s=new Map;function i(e){if(s.has(e))return s.get(e);o+=1;const n=`#${o.toString(16).padStart(8,"0").toLowerCase()}`;return t.colorReplacements?.[`#${n}`]?i(e):(s.set(e,n),n)}t.settings=t.settings.map(e=>{const n=e.settings?.foreground&&!e.settings.foreground.startsWith("#"),r=e.settings?.background&&!e.settings.background.startsWith("#");if(!n&&!r)return e;const o=Object.assign({},e,{settings:Object.assign({},e.settings)});if(n){const n=i(e.settings.foreground);t.colorReplacements[n]=e.settings.foreground,o.settings.foreground=n}if(r){const n=i(e.settings.background);t.colorReplacements[n]=e.settings.background,o.settings.background=n}return o});for(const e of Object.keys(t.colors||{}))if(("editor.foreground"===e||"editor.background"===e||e.startsWith("terminal.ansi"))&&!t.colors[e]?.startsWith("#")){const n=i(t.colors[e]);t.colorReplacements[n]=t.colors[e],t.colors[e]=n}return Object.defineProperty(t,mt,{enumerable:!1,writable:!1,value:!0}),t}async function bt(e){return[...new Set((await Promise.all(e.filter(e=>{return!("ansi"===(t=e)||at(t));var t}).map(async e=>await it(e).then(e=>Array.isArray(e)?e:[e])))).flat())]}async function wt(e){return(await Promise.all(e.map(async e=>ct(e)?null:yt(await it(e))))).filter(e=>!!e)}function kt(e,t){if(!t)return e;if(t[e]){const n=new Set([e]);for(;t[e];){if(e=t[e],n.has(e))throw new E(`Circular alias \`${[...n].join(" -> ")} -> ${e}\``);n.add(e)}}return e}var Ct=class extends tt{_resolvedThemes=new Map;_resolvedGrammars=new Map;_langMap=new Map;_langGraph=new Map;_textmateThemeCache=new WeakMap;_loadedThemesCache=null;_loadedLanguagesCache=null;constructor(e,t,n,r={}){super(e),this._resolver=e,this._themes=t,this._langs=n,this._alias=r,this._themes.map(e=>this.loadTheme(e)),this.loadLanguages(this._langs)}getTheme(e){return"string"==typeof e?this._resolvedThemes.get(e):this.loadTheme(e)}loadTheme(e){const t=yt(e);return t.name&&(this._resolvedThemes.set(t.name,t),this._loadedThemesCache=null),t}getLoadedThemes(){return this._loadedThemesCache||(this._loadedThemesCache=[...this._resolvedThemes.keys()]),this._loadedThemesCache}setTheme(e){let t=this._textmateThemeCache.get(e);t||(t=F.createFromRawTheme(e),this._textmateThemeCache.set(e,t)),this._syncRegistry.setTheme(t)}getGrammar(e){return e=kt(e,this._alias),this._resolvedGrammars.get(e)}loadLanguage(e){if(this.getGrammar(e.name))return;const t=new Set([...this._langMap.values()].filter(t=>t.embeddedLangsLazy?.includes(e.name)));this._resolver.addLanguage(e);const n={balancedBracketSelectors:e.balancedBracketSelectors||["*"],unbalancedBracketSelectors:e.unbalancedBracketSelectors||[]};this._syncRegistry._rawGrammars.set(e.scopeName,e);const r=this.loadGrammarWithConfiguration(e.scopeName,1,n);if(r.name=e.name,this._resolvedGrammars.set(e.name,r),e.aliases&&e.aliases.forEach(t=>{this._alias[t]=e.name}),this._loadedLanguagesCache=null,t.size)for(const e of t)this._resolvedGrammars.delete(e.name),this._loadedLanguagesCache=null,this._syncRegistry?._injectionGrammars?.delete(e.scopeName),this._syncRegistry?._grammars?.delete(e.scopeName),this.loadLanguage(this._langMap.get(e.name))}dispose(){super.dispose(),this._resolvedThemes.clear(),this._resolvedGrammars.clear(),this._langMap.clear(),this._langGraph.clear(),this._loadedThemesCache=null}loadLanguages(e){for(const t of e)this.resolveEmbeddedLanguages(t);const t=[...this._langGraph.entries()],n=t.filter(([e,t])=>!t);if(n.length){const e=t.filter(([e,t])=>!!t&&(t.embeddedLanguages||t.embeddedLangs)?.some(e=>n.map(([e])=>e).includes(e))).filter(e=>!n.includes(e));throw new E(`Missing languages ${n.map(([e])=>`\`${e}\``).join(", ")}, required by ${e.map(([e])=>`\`${e}\``).join(", ")}`)}for(const[e,n]of t)this._resolver.addLanguage(n);for(const[e,n]of t)this.loadLanguage(n)}getLoadedLanguages(){return this._loadedLanguagesCache||(this._loadedLanguagesCache=[...new Set([...this._resolvedGrammars.keys(),...Object.keys(this._alias)])]),this._loadedLanguagesCache}resolveEmbeddedLanguages(e){this._langMap.set(e.name,e),this._langGraph.set(e.name,e);const t=e.embeddedLanguages??e.embeddedLangs;if(t)for(const e of t)this._langGraph.set(e,this._langMap.get(e))}},vt=class{_langs=new Map;_scopeToLang=new Map;_injections=new Map;constructor(e,t){this._onigLib={createOnigScanner:t=>e.createScanner(t),createOnigString:t=>e.createString(t)},t.forEach(e=>this.addLanguage(e))}get onigLib(){return this._onigLib}getLangRegistration(e){return this._langs.get(e)}loadGrammar(e){return this._scopeToLang.get(e)}addLanguage(e){this._langs.set(e.name,e),e.aliases&&e.aliases.forEach(t=>{this._langs.set(t,e)}),this._scopeToLang.set(e.scopeName,e),e.injectTo&&e.injectTo.forEach(t=>{this._injections.get(t)||this._injections.set(t,[]),this._injections.get(t).push(e.scopeName)})}getInjections(e){const t=e.split(".");let n=[];for(let e=1;e<=t.length;e++){const r=t.slice(0,e).join(".");n=[...n,...this._injections.get(r)||[]]}return n}};let xt=0;function St(e){xt+=1,!1!==e.warnings&&xt>=10&&xt%10==0&&console.warn(`[Shiki] ${xt} instances have been created. Shiki is supposed to be used as a singleton, consider refactoring your code to cache your highlighter instance; Or call \`highlighter.dispose()\` to release unused instances.`);let t=!1;if(!e.engine)throw new E("`engine` option is required for synchronous mode");const n=(e.langs||[]).flat(1),r=(e.themes||[]).flat(1).map(yt),o=new Ct(new vt(e.engine,n),r,n,e.langAlias);let s;function i(e){if("none"===e)return{bg:"",fg:"",name:"none",settings:[],type:"dark"};c();const t=o.getTheme(e);if(!t)throw new E(`Theme \`${e}\` not found, you may need to load it first`);return t}function a(...e){c(),o.loadLanguages(e.flat(1))}function l(...e){c();for(const t of e.flat(1))o.loadTheme(t)}function c(){if(t)throw new E("Shiki instance has been disposed")}function u(){t||(t=!0,o.dispose(),xt-=1)}return{setTheme:function(e){c();const t=i(e);return s!==e&&(o.setTheme(t),s=e),{theme:t,colorMap:o.getColorMap()}},getTheme:i,getLanguage:function(e){c();const t=o.getGrammar("string"==typeof e?e:e.name);if(!t)throw new E(`Language \`${e}\` not found, you may need to load it first`);return t},getLoadedThemes:function(){return c(),o.getLoadedThemes()},getLoadedLanguages:function(){return c(),o.getLoadedLanguages()},resolveLangAlias:function(t){return kt(t,e.langAlias)},loadLanguage:async function(...e){return a(await bt(e))},loadLanguageSync:a,loadTheme:async function(...e){return c(),l(await wt(e))},loadThemeSync:l,dispose:u,[Symbol.dispose]:u}}async function _t(e){e.engine||console.warn("`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.");const[t,n,r]=await Promise.all([wt(e.themes||[]),bt(e.langs||[]),e.engine]);return St(Object.assign({},e,{themes:t,langs:n,engine:r}))}const At=new WeakMap;function Et(e,t){At.set(e,t)}function Lt(e){return At.get(e)}var It=class e{_stacks={};get themes(){return Object.keys(this._stacks)}get theme(){return this.themes[0]}get _stack(){return this._stacks[this.theme]}static initial(t,n){return new e(Object.fromEntries(st(n).map(e=>[e,nt])),t)}constructor(...e){if(2===e.length){const[t,n]=e;this.lang=n,this._stacks=t}else{const[t,n,r]=e;this.lang=n,this._stacks={[r]:t}}}getInternalStack(e=this.theme){return this._stacks[e]}getScopes(e=this.theme){return Nt(this._stacks[e])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.getScopes()}}};function Nt(e){const t=[],n=new Set;return(function e(r){if(n.has(r))return;n.add(r);const o=r?.nameScopesList?.scopeName;o&&t.push(o),r.parent&&e(r.parent)})(e),t}function Pt(e,t){if(!(e instanceof It))throw new E("Invalid grammar state");return e.getInternalStack(t)}const Ot=/,/,Tt=/ /;function $t(e,t,n={}){const{theme:r=e.getLoadedThemes()[0]}=n;if(at(e.resolveLangAlias(n.lang||"text"))||lt(r))return dt(t).map(e=>[{content:e[0],offset:e[1]}]);const{theme:o,colorMap:s}=e.setTheme(r),i=e.getLanguage(n.lang||"text");if(n.grammarState){if(n.grammarState.lang!==i.name)throw new E(`Grammar state language "${n.grammarState.lang}" does not match highlight language "${i.name}"`);if(!n.grammarState.themes.includes(o.name))throw new E(`Grammar state themes "${n.grammarState.themes}" do not contain highlight theme "${o.name}"`)}return Mt(t,i,o,s,n)}function Rt(...e){if(2===e.length)return Lt(e[1]);const[t,n,r={}]=e,{lang:o="text",theme:s=t.getLoadedThemes()[0]}=r;if(at(o)||lt(s))throw new E("Plain language does not have grammar state");if("ansi"===o)throw new E("ANSI language does not have grammar state");const{theme:i,colorMap:a}=t.setTheme(s),l=t.getLanguage(o);return new It(jt(n,l,i,a,r).stateStack,l.name,i.name)}function Mt(e,t,n,r,o){const s=jt(e,t,n,r,o),i=new It(s.stateStack,t.name,n.name);return Et(s.tokens,i),s.tokens}function jt(e,t,n,r,o){const s=rt(n,o),{tokenizeMaxLineLength:i=0,tokenizeTimeLimit:a=500,includeExplanation:l=!1}=o,c=dt(e);let u=o.grammarState?Pt(o.grammarState,n.name)??nt:null!=o.grammarContextCode?jt(o.grammarContextCode,t,n,r,Object.assign({},o,{grammarState:void 0,grammarContextCode:void 0})).stateStack:nt,d=[];const h=[];for(let e=0,o=c.length;e<o;e++){const[o,p]=c[e];if(""===o){d=[],h.push([]);continue}if(i>0&&o.length>=i){d=[],h.push([{content:o,offset:p,color:"",fontStyle:0}]);continue}let f,g,m;l&&"tokenType"!==l&&(f=t.tokenizeLine(o,u,a),g=f.tokens,m=0);const y=t.tokenizeLine2(o,u,a),b=y.tokens.length/2;for(let e=0;e<b;e++){const t=y.tokens[2*e],i=e+1<b?y.tokens[2*e+2]:o.length;if(t===i)continue;const a=y.tokens[2*e+1],c=ot(r[Y.getForeground(a)],s),u=Y.getFontStyle(a),h={content:o.substring(t,i),offset:p+t,color:c,fontStyle:u};if("tokenType"===l)h.type=Y.getTokenType(a);else if(l){const e=[];if("scopeName"!==l)for(const t of n.settings){let n;switch(typeof t.scope){case"string":n=t.scope.split(Ot).map(e=>e.trim());break;case"object":n=t.scope;break;default:continue}e.push({settings:t,selectors:n.map(e=>e.split(Tt))})}h.explanation=[];let r=0;for(;t+r<i;){const t=g[m],n=o.substring(t.startIndex,t.endIndex);r+=n.length,h.explanation.push({content:n,scopes:"scopeName"===l?Dt(t.scopes):Bt(e,t.scopes)}),m+=1}}d.push(h)}h.push(d),d=[],u=y.ruleStack}return{tokens:h,stateStack:u}}function Dt(e){return e.map(e=>({scopeName:e}))}function Bt(e,t){const n=[];for(let r=0,o=t.length;r<o;r++){const o=t[r];n[r]={scopeName:o,themeMatches:Ut(e,o,t.slice(0,r))}}return n}function Ft(e,t){return e===t||t.substring(0,e.length)===e&&"."===t[e.length]}function Gt(e,t,n){if(!Ft(e.at(-1),t))return!1;let r=e.length-2,o=n.length-1;for(;r>=0&&o>=0;)Ft(e[r],n[o])&&(r-=1),o-=1;return-1===r}function Ut(e,t,n){const r=[];for(const{selectors:o,settings:s}of e)for(const e of o)if(Gt(e,t,n)){r.push(s);break}return r}function Wt(e,t,n,r=$t){const o=Object.entries(n.themes).filter(e=>e[1]).map(e=>({color:e[0],theme:e[1]})),s=o.map(o=>{const s=r(e,t,Object.assign({},n,{theme:o.theme}));return{tokens:s,state:Lt(s),theme:"string"==typeof o.theme?o.theme:o.theme.name}}),i=zt(...s.map(e=>e.tokens)),a=i[0].map((e,t)=>e.map((e,r)=>{const s={content:e.content,variants:{},offset:e.offset};return"includeExplanation"in n&&n.includeExplanation&&(s.explanation=e.explanation),i.forEach((e,n)=>{const i=e[t][r],a=g(i,m);s.variants[o[n].color]=a}),s})),l=s[0].state?new It(Object.fromEntries(s.map(e=>[e.theme,e.state?.getInternalStack(e.theme)])),s[0].state.lang):void 0;return l&&Et(a,l),a}function zt(...e){const t=e.map(()=>[]),n=e.length;for(let r=0;r<e[0].length;r++){const o=e.map(e=>e[r]),s=t.map(()=>[]);t.forEach((e,t)=>e.push(s[t]));const i=o.map(()=>0),a=o.map(e=>e[0]);for(;a.every(e=>e);){const e=Math.min(...a.map(e=>e.content.length));for(let t=0;t<n;t++){const n=a[t];n.content.length===e?(s[t].push(n),i[t]+=1,a[t]=o[t][i[t]]):(s[t].push(Object.assign({},n,{content:n.content.slice(0,e)})),a[t]=Object.assign({},n,{content:n.content.slice(e),offset:n.offset+e}))}}}return t}const qt=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"];var Ht=class{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}};function Vt(e,t){const n={},r={};for(const t of e)Object.assign(n,t.property),Object.assign(r,t.normal);return new Ht(n,r,t)}function Xt(e){return e.toLowerCase()}Ht.prototype.normal={},Ht.prototype.property={},Ht.prototype.space=void 0;var Kt=class{constructor(e,t){this.attribute=t,this.property=e}};Kt.prototype.attribute="",Kt.prototype.booleanish=!1,Kt.prototype.boolean=!1,Kt.prototype.commaOrSpaceSeparated=!1,Kt.prototype.commaSeparated=!1,Kt.prototype.defined=!1,Kt.prototype.mustUseProperty=!1,Kt.prototype.number=!1,Kt.prototype.overloadedBoolean=!1,Kt.prototype.property="",Kt.prototype.spaceSeparated=!1,Kt.prototype.space=void 0;var Zt=k({boolean:()=>Qt,booleanish:()=>Yt,commaOrSpaceSeparated:()=>on,commaSeparated:()=>rn,number:()=>tn,overloadedBoolean:()=>en,spaceSeparated:()=>nn});let Jt=0;const Qt=sn(),Yt=sn(),en=sn(),tn=sn(),nn=sn(),rn=sn(),on=sn();function sn(){return 2**++Jt}const an=Object.keys(Zt);var ln=class extends Kt{constructor(e,t,n,r){let o=-1;if(super(e,t),cn(this,"space",r),"number"==typeof n)for(;++o<an.length;){const e=an[o];cn(this,an[o],(n&Zt[e])===Zt[e])}}};function cn(e,t,n){n&&(e[t]=n)}function un(e){const t={},n={};for(const[r,o]of Object.entries(e.properties)){const s=new ln(r,e.transform(e.attributes||{},r),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(s.mustUseProperty=!0),t[r]=s,n[Xt(r)]=r,n[Xt(s.attribute)]=r}return new Ht(t,n,e.space)}ln.prototype.defined=!0;const dn=un({properties:{ariaActiveDescendant:null,ariaAtomic:Yt,ariaAutoComplete:null,ariaBusy:Yt,ariaChecked:Yt,ariaColCount:tn,ariaColIndex:tn,ariaColSpan:tn,ariaControls:nn,ariaCurrent:null,ariaDescribedBy:nn,ariaDetails:null,ariaDisabled:Yt,ariaDropEffect:nn,ariaErrorMessage:null,ariaExpanded:Yt,ariaFlowTo:nn,ariaGrabbed:Yt,ariaHasPopup:null,ariaHidden:Yt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:nn,ariaLevel:tn,ariaLive:null,ariaModal:Yt,ariaMultiLine:Yt,ariaMultiSelectable:Yt,ariaOrientation:null,ariaOwns:nn,ariaPlaceholder:null,ariaPosInSet:tn,ariaPressed:Yt,ariaReadOnly:Yt,ariaRelevant:null,ariaRequired:Yt,ariaRoleDescription:nn,ariaRowCount:tn,ariaRowIndex:tn,ariaRowSpan:tn,ariaSelected:Yt,ariaSetSize:tn,ariaSort:null,ariaValueMax:tn,ariaValueMin:tn,ariaValueNow:tn,ariaValueText:null,role:null},transform:(e,t)=>"role"===t?t:"aria-"+t.slice(4).toLowerCase()});function hn(e,t){return t in e?e[t]:t}function pn(e,t){return hn(e,t.toLowerCase())}const fn=un({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:rn,acceptCharset:nn,accessKey:nn,action:null,allow:null,allowFullScreen:Qt,allowPaymentRequest:Qt,allowUserMedia:Qt,alpha:Qt,alt:null,as:null,async:Qt,autoCapitalize:null,autoComplete:nn,autoFocus:Qt,autoPlay:Qt,blocking:nn,capture:null,charSet:null,checked:Qt,cite:null,className:nn,closedBy:null,colorSpace:null,cols:tn,colSpan:tn,command:null,commandFor:null,content:null,contentEditable:Yt,controls:Qt,controlsList:nn,coords:tn|rn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Qt,defer:Qt,dir:null,dirName:null,disabled:Qt,download:en,draggable:Yt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Qt,formTarget:null,headers:nn,height:tn,hidden:en,high:tn,href:null,hrefLang:null,htmlFor:nn,httpEquiv:nn,id:null,imageSizes:null,imageSrcSet:null,inert:Qt,inputMode:null,integrity:null,is:null,isMap:Qt,itemId:null,itemProp:nn,itemRef:nn,itemScope:Qt,itemType:nn,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Qt,low:tn,manifest:null,max:null,maxLength:tn,media:null,method:null,min:null,minLength:tn,multiple:Qt,muted:Qt,name:null,nonce:null,noModule:Qt,noValidate:Qt,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:Qt,optimum:tn,pattern:null,ping:nn,placeholder:null,playsInline:Qt,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Qt,referrerPolicy:null,rel:nn,required:Qt,reversed:Qt,rows:tn,rowSpan:tn,sandbox:nn,scope:null,scoped:Qt,seamless:Qt,selected:Qt,shadowRootClonable:Qt,shadowRootCustomElementRegistry:Qt,shadowRootDelegatesFocus:Qt,shadowRootMode:null,shadowRootSerializable:Qt,shape:null,size:tn,sizes:null,slot:null,span:tn,spellCheck:Yt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:tn,step:null,style:null,tabIndex:tn,target:null,title:null,translate:null,type:null,typeMustMatch:Qt,useMap:null,value:Yt,width:tn,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:nn,axis:null,background:null,bgColor:null,border:tn,borderColor:null,bottomMargin:tn,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Qt,declare:Qt,event:null,face:null,frame:null,frameBorder:null,hSpace:tn,leftMargin:tn,link:null,longDesc:null,lowSrc:null,marginHeight:tn,marginWidth:tn,noResize:Qt,noHref:Qt,noShade:Qt,noWrap:Qt,object:null,profile:null,prompt:null,rev:null,rightMargin:tn,rules:null,scheme:null,scrolling:Yt,standby:null,summary:null,text:null,topMargin:tn,valueType:null,version:null,vAlign:null,vLink:null,vSpace:tn,allowTransparency:null,autoCorrect:null,autoSave:null,credentialless:Qt,disablePictureInPicture:Qt,disableRemotePlayback:Qt,exportParts:rn,part:nn,prefix:null,property:null,results:tn,security:null,unselectable:null},space:"html",transform:pn}),gn=un({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",maskType:"mask-type",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:on,accentHeight:tn,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:tn,amplitude:tn,arabicForm:null,ascent:tn,attributeName:null,attributeType:null,azimuth:tn,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:tn,by:null,calcMode:null,capHeight:tn,className:nn,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:tn,diffuseConstant:tn,direction:null,display:null,dur:null,divisor:tn,dominantBaseline:null,download:Qt,dx:null,dy:null,edgeMode:null,editable:null,elevation:tn,enableBackground:null,end:null,event:null,exponent:tn,externalResourcesRequired:null,fill:null,fillOpacity:tn,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:rn,g2:rn,glyphName:rn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:tn,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:tn,horizOriginX:tn,horizOriginY:tn,id:null,ideographic:tn,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:tn,k:tn,k1:tn,k2:tn,k3:tn,k4:tn,kernelMatrix:on,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:tn,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskType:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:tn,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:tn,overlineThickness:tn,paintOrder:null,panose1:null,path:null,pathLength:tn,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:nn,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:tn,pointsAtY:tn,pointsAtZ:tn,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:on,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:on,rev:on,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:on,requiredFeatures:on,requiredFonts:on,requiredFormats:on,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:tn,specularExponent:tn,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:tn,strikethroughThickness:tn,string:null,stroke:null,strokeDashArray:on,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:tn,strokeOpacity:tn,strokeWidth:null,style:null,surfaceScale:tn,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:on,tabIndex:tn,tableValues:null,target:null,targetX:tn,targetY:tn,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:on,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:tn,underlineThickness:tn,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:tn,values:null,vAlphabetic:tn,vMathematical:tn,vectorEffect:null,vHanging:tn,vIdeographic:tn,version:null,vertAdvY:tn,vertOriginX:tn,vertOriginY:tn,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:tn,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:hn}),mn=un({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform:(e,t)=>"xlink:"+t.slice(5).toLowerCase()}),yn=un({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:pn}),bn=un({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform:(e,t)=>"xml:"+t.slice(3).toLowerCase()}),wn=/[A-Z]/g,kn=/-[a-z]/g,Cn=/^data[-\w.:]+$/i;function vn(e,t){const n=Xt(t);let r=t,o=Kt;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&"data"===n.slice(0,4)&&Cn.test(t)){if("-"===t.charAt(4)){const e=t.slice(5).replace(kn,Sn);r="data"+e.charAt(0).toUpperCase()+e.slice(1)}else{const e=t.slice(4);if(!kn.test(e)){let n=e.replace(wn,xn);"-"!==n.charAt(0)&&(n="-"+n),t="data"+n}}o=ln}return new o(r,t)}function xn(e){return"-"+e.toLowerCase()}function Sn(e){return e.charAt(1).toUpperCase()}const _n=Vt([dn,fn,mn,yn,bn],"html"),An=Vt([dn,gn,mn,yn,bn],"svg"),En={}.hasOwnProperty;const Ln=/["&'<>`]/g,In=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Nn=/[\x01-\t\v\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,Pn=/[|\\{}()[\]^$+*?.]/g,On=new WeakMap;function Tn(e,t){return e=e.replace(t.subset?$n(t.subset):Ln,n),t.subset||t.escapeOnly?e:e.replace(In,function(e,n,r){return t.format(1024*(e.charCodeAt(0)-55296)+e.charCodeAt(1)-56320+65536,r.charCodeAt(n+2),t)}).replace(Nn,n);function n(e,n,r){return t.format(e.charCodeAt(0),r.charCodeAt(n+1),t)}}function $n(e){let t=On.get(e);return t||(t=Rn(e),On.set(e,t)),t}function Rn(e){const t=[];let n=-1;for(;++n<e.length;)t.push(e[n].replace(Pn,"\\$&"));return new RegExp("(?:"+t.join("|")+")","g")}const Mn=/[\dA-Fa-f]/;function jn(e,t,n){const r="&#x"+e.toString(16).toUpperCase();return n&&t&&!Mn.test(String.fromCharCode(t))?r:r+";"}const Dn=/\d/;function Bn(e,t,n){const r="&#"+String(e);return n&&t&&!Dn.test(String.fromCharCode(t))?r:r+";"}const Fn=["AElig","AMP","Aacute","Acirc","Agrave","Aring","Atilde","Auml","COPY","Ccedil","ETH","Eacute","Ecirc","Egrave","Euml","GT","Iacute","Icirc","Igrave","Iuml","LT","Ntilde","Oacute","Ocirc","Ograve","Oslash","Otilde","Ouml","QUOT","REG","THORN","Uacute","Ucirc","Ugrave","Uuml","Yacute","aacute","acirc","acute","aelig","agrave","amp","aring","atilde","auml","brvbar","ccedil","cedil","cent","copy","curren","deg","divide","eacute","ecirc","egrave","eth","euml","frac12","frac14","frac34","gt","iacute","icirc","iexcl","igrave","iquest","iuml","laquo","lt","macr","micro","middot","nbsp","not","ntilde","oacute","ocirc","ograve","ordf","ordm","oslash","otilde","ouml","para","plusmn","pound","quot","raquo","reg","sect","shy","sup1","sup2","sup3","szlig","thorn","times","uacute","ucirc","ugrave","uml","uuml","yacute","yen","yuml"],Gn={nbsp:"\xa0",iexcl:"\xa1",cent:"\xa2",pound:"\xa3",curren:"\xa4",yen:"\xa5",brvbar:"\xa6",sect:"\xa7",uml:"\xa8",copy:"\xa9",ordf:"\xaa",laquo:"\xab",not:"\xac",shy:"\xad",reg:"\xae",macr:"\xaf",deg:"\xb0",plusmn:"\xb1",sup2:"\xb2",sup3:"\xb3",acute:"\xb4",micro:"\xb5",para:"\xb6",middot:"\xb7",cedil:"\xb8",sup1:"\xb9",ordm:"\xba",raquo:"\xbb",frac14:"\xbc",frac12:"\xbd",frac34:"\xbe",iquest:"\xbf",Agrave:"\xc0",Aacute:"\xc1",Acirc:"\xc2",Atilde:"\xc3",Auml:"\xc4",Aring:"\xc5",AElig:"\xc6",Ccedil:"\xc7",Egrave:"\xc8",Eacute:"\xc9",Ecirc:"\xca",Euml:"\xcb",Igrave:"\xcc",Iacute:"\xcd",Icirc:"\xce",Iuml:"\xcf",ETH:"\xd0",Ntilde:"\xd1",Ograve:"\xd2",Oacute:"\xd3",Ocirc:"\xd4",Otilde:"\xd5",Ouml:"\xd6",times:"\xd7",Oslash:"\xd8",Ugrave:"\xd9",Uacute:"\xda",Ucirc:"\xdb",Uuml:"\xdc",Yacute:"\xdd",THORN:"\xde",szlig:"\xdf",agrave:"\xe0",aacute:"\xe1",acirc:"\xe2",atilde:"\xe3",auml:"\xe4",aring:"\xe5",aelig:"\xe6",ccedil:"\xe7",egrave:"\xe8",eacute:"\xe9",ecirc:"\xea",euml:"\xeb",igrave:"\xec",iacute:"\xed",icirc:"\xee",iuml:"\xef",eth:"\xf0",ntilde:"\xf1",ograve:"\xf2",oacute:"\xf3",ocirc:"\xf4",otilde:"\xf5",ouml:"\xf6",divide:"\xf7",oslash:"\xf8",ugrave:"\xf9",uacute:"\xfa",ucirc:"\xfb",uuml:"\xfc",yacute:"\xfd",thorn:"\xfe",yuml:"\xff",fnof:"\u0192",Alpha:"\u0391",Beta:"\u0392",Gamma:"\u0393",Delta:"\u0394",Epsilon:"\u0395",Zeta:"\u0396",Eta:"\u0397",Theta:"\u0398",Iota:"\u0399",Kappa:"\u039a",Lambda:"\u039b",Mu:"\u039c",Nu:"\u039d",Xi:"\u039e",Omicron:"\u039f",Pi:"\u03a0",Rho:"\u03a1",Sigma:"\u03a3",Tau:"\u03a4",Upsilon:"\u03a5",Phi:"\u03a6",Chi:"\u03a7",Psi:"\u03a8",Omega:"\u03a9",alpha:"\u03b1",beta:"\u03b2",gamma:"\u03b3",delta:"\u03b4",epsilon:"\u03b5",zeta:"\u03b6",eta:"\u03b7",theta:"\u03b8",iota:"\u03b9",kappa:"\u03ba",lambda:"\u03bb",mu:"\u03bc",nu:"\u03bd",xi:"\u03be",omicron:"\u03bf",pi:"\u03c0",rho:"\u03c1",sigmaf:"\u03c2",sigma:"\u03c3",tau:"\u03c4",upsilon:"\u03c5",phi:"\u03c6",chi:"\u03c7",psi:"\u03c8",omega:"\u03c9",thetasym:"\u03d1",upsih:"\u03d2",piv:"\u03d6",bull:"\u2022",hellip:"\u2026",prime:"\u2032",Prime:"\u2033",oline:"\u203e",frasl:"\u2044",weierp:"\u2118",image:"\u2111",real:"\u211c",trade:"\u2122",alefsym:"\u2135",larr:"\u2190",uarr:"\u2191",rarr:"\u2192",darr:"\u2193",harr:"\u2194",crarr:"\u21b5",lArr:"\u21d0",uArr:"\u21d1",rArr:"\u21d2",dArr:"\u21d3",hArr:"\u21d4",forall:"\u2200",part:"\u2202",exist:"\u2203",empty:"\u2205",nabla:"\u2207",isin:"\u2208",notin:"\u2209",ni:"\u220b",prod:"\u220f",sum:"\u2211",minus:"\u2212",lowast:"\u2217",radic:"\u221a",prop:"\u221d",infin:"\u221e",ang:"\u2220",and:"\u2227",or:"\u2228",cap:"\u2229",cup:"\u222a",int:"\u222b",there4:"\u2234",sim:"\u223c",cong:"\u2245",asymp:"\u2248",ne:"\u2260",equiv:"\u2261",le:"\u2264",ge:"\u2265",sub:"\u2282",sup:"\u2283",nsub:"\u2284",sube:"\u2286",supe:"\u2287",oplus:"\u2295",otimes:"\u2297",perp:"\u22a5",sdot:"\u22c5",lceil:"\u2308",rceil:"\u2309",lfloor:"\u230a",rfloor:"\u230b",lang:"\u2329",rang:"\u232a",loz:"\u25ca",spades:"\u2660",clubs:"\u2663",hearts:"\u2665",diams:"\u2666",quot:"\"",amp:"&",lt:"<",gt:">",OElig:"\u0152",oelig:"\u0153",Scaron:"\u0160",scaron:"\u0161",Yuml:"\u0178",circ:"\u02c6",tilde:"\u02dc",ensp:"\u2002",emsp:"\u2003",thinsp:"\u2009",zwnj:"\u200c",zwj:"\u200d",lrm:"\u200e",rlm:"\u200f",ndash:"\u2013",mdash:"\u2014",lsquo:"\u2018",rsquo:"\u2019",sbquo:"\u201a",ldquo:"\u201c",rdquo:"\u201d",bdquo:"\u201e",dagger:"\u2020",Dagger:"\u2021",permil:"\u2030",lsaquo:"\u2039",rsaquo:"\u203a",euro:"\u20ac"},Un=["cent","copy","divide","gt","lt","not","para","times"],Wn={}.hasOwnProperty,zn={};let qn;for(qn in Gn)Wn.call(Gn,qn)&&(zn[Gn[qn]]=qn);const Hn=/[^\dA-Za-z]/;function Vn(e,t,n,r){const o=String.fromCharCode(e);if(Wn.call(zn,o)){const e=zn[o],s="&"+e;return n&&Fn.includes(e)&&!Un.includes(e)&&(!r||t&&61!==t&&Hn.test(String.fromCharCode(t)))?s:s+";"}return""}function Xn(e,t,n){let r,o=jn(e,t,n.omitOptionalSemicolons);if((n.useNamedReferences||n.useShortestReferences)&&(r=Vn(e,t,n.omitOptionalSemicolons,n.attribute)),(n.useShortestReferences||!r)&&n.useShortestReferences){const r=Bn(e,t,n.omitOptionalSemicolons);r.length<o.length&&(o=r)}return r&&(!n.useShortestReferences||r.length<o.length)?r:o}function Kn(e,t){return Tn(e,Object.assign({format:Xn},t))}const Zn=/^>|^->|<!--|-->|--!>|<!-$/g,Jn=[">"],Qn=["<",">"];function Yn(e,t){const n=String(e);if("string"!=typeof t)throw new TypeError("Expected character");let r=0,o=n.indexOf(t);for(;-1!==o;)r++,o=n.indexOf(t,o+t.length);return r}function er(e,t){const n=t||{};return(""===e[e.length-1]?[...e,""]:e).join((n.padRight?" ":"")+","+(!1===n.padLeft?"":" ")).trim()}function tr(e){return e.join(" ").trim()}const nr=/[ \t\n\f\r]/g;function rr(e){return"object"==typeof e?"text"===e.type&&or(e.value):or(e)}function or(e){return""===e.replace(nr,"")}const sr=lr(1),ir=lr(-1),ar=[];function lr(e){return function(t,n,r){const o=t?t.children:ar;let s=(n||0)+e,i=o[s];if(!r)for(;i&&rr(i);)s+=e,i=o[s];return i}}const cr={}.hasOwnProperty;function ur(e){return function(t,n,r){return cr.call(e,t.tagName)&&e[t.tagName](t,n,r)}}const dr=ur({body:function(e,t,n){const r=sr(n,t);return!r||"comment"!==r.type},caption:hr,colgroup:hr,dd:function(e,t,n){const r=sr(n,t);return!r||"element"===r.type&&("dt"===r.tagName||"dd"===r.tagName)},dt:function(e,t,n){const r=sr(n,t);return Boolean(r&&"element"===r.type&&("dt"===r.tagName||"dd"===r.tagName))},head:hr,html:function(e,t,n){const r=sr(n,t);return!r||"comment"!==r.type},li:function(e,t,n){const r=sr(n,t);return!r||"element"===r.type&&"li"===r.tagName},optgroup:function(e,t,n){const r=sr(n,t);return!r||"element"===r.type&&"optgroup"===r.tagName},option:function(e,t,n){const r=sr(n,t);return!r||"element"===r.type&&("option"===r.tagName||"optgroup"===r.tagName)},p:function(e,t,n){const r=sr(n,t);return r?"element"===r.type&&("address"===r.tagName||"article"===r.tagName||"aside"===r.tagName||"blockquote"===r.tagName||"details"===r.tagName||"div"===r.tagName||"dl"===r.tagName||"fieldset"===r.tagName||"figcaption"===r.tagName||"figure"===r.tagName||"footer"===r.tagName||"form"===r.tagName||"h1"===r.tagName||"h2"===r.tagName||"h3"===r.tagName||"h4"===r.tagName||"h5"===r.tagName||"h6"===r.tagName||"header"===r.tagName||"hgroup"===r.tagName||"hr"===r.tagName||"main"===r.tagName||"menu"===r.tagName||"nav"===r.tagName||"ol"===r.tagName||"p"===r.tagName||"pre"===r.tagName||"section"===r.tagName||"table"===r.tagName||"ul"===r.tagName):!n||!("element"===n.type&&("a"===n.tagName||"audio"===n.tagName||"del"===n.tagName||"ins"===n.tagName||"map"===n.tagName||"noscript"===n.tagName||"video"===n.tagName))},rp:pr,rt:pr,tbody:function(e,t,n){const r=sr(n,t);return!r||"element"===r.type&&("tbody"===r.tagName||"tfoot"===r.tagName)},td:fr,tfoot:function(e,t,n){return!sr(n,t)},th:fr,thead:function(e,t,n){const r=sr(n,t);return Boolean(r&&"element"===r.type&&("tbody"===r.tagName||"tfoot"===r.tagName))},tr:function(e,t,n){const r=sr(n,t);return!r||"element"===r.type&&"tr"===r.tagName}});function hr(e,t,n){const r=sr(n,t,!0);return!r||"comment"!==r.type&&!("text"===r.type&&rr(r.value.charAt(0)))}function pr(e,t,n){const r=sr(n,t);return!r||"element"===r.type&&("rp"===r.tagName||"rt"===r.tagName)}function fr(e,t,n){const r=sr(n,t);return!r||"element"===r.type&&("td"===r.tagName||"th"===r.tagName)}const gr=ur({body:function(e){const t=sr(e,-1,!0);return!(t&&("comment"===t.type||"text"===t.type&&rr(t.value.charAt(0))||"element"===t.type&&("meta"===t.tagName||"link"===t.tagName||"script"===t.tagName||"style"===t.tagName||"template"===t.tagName)))},colgroup:function(e,t,n){const r=ir(n,t),o=sr(e,-1,!0);return!(n&&r&&"element"===r.type&&"colgroup"===r.tagName&&dr(r,n.children.indexOf(r),n))&&Boolean(o&&"element"===o.type&&"col"===o.tagName)},head:function(e){const t=new Set;for(const n of e.children)if("element"===n.type&&("base"===n.tagName||"title"===n.tagName)){if(t.has(n.tagName))return!1;t.add(n.tagName)}const n=e.children[0];return!n||"element"===n.type},html:function(e){const t=sr(e,-1);return!t||"comment"!==t.type},tbody:function(e,t,n){const r=ir(n,t),o=sr(e,-1);return(!n||!r||"element"!==r.type||"thead"!==r.tagName&&"tbody"!==r.tagName||!dr(r,n.children.indexOf(r),n))&&Boolean(o&&"element"===o.type&&"tr"===o.tagName)}});const mr={name:[["\t\n\f\r &/=>".split(""),"\t\n\f\r \"&'/=>`".split("")],["\0\t\n\f\r \"&'/<=>".split(""),"\0\t\n\f\r \"&'/<=>`".split("")]],unquoted:[["\t\n\f\r &>".split(""),"\0\t\n\f\r \"&'<=>`".split("")],["\0\t\n\f\r \"&'<=>`".split(""),"\0\t\n\f\r \"&'<=>`".split("")]],single:[["&'".split(""),"\"&'`".split("")],["\0&'".split(""),"\0\"&'`".split("")]],double:[["\"&".split(""),"\"&'`".split("")],["\0\"&".split(""),"\0\"&'`".split("")]]};function yr(e,t){const n=[];let r,o=-1;if(t)for(r in t)if(null!==t[r]&&void 0!==t[r]){const o=br(e,r,t[r]);o&&n.push(o)}for(;++o<n.length;){const t=e.settings.tightAttributes?n[o].charAt(n[o].length-1):void 0;o!==n.length-1&&"\""!==t&&"'"!==t&&(n[o]+=" ")}return n.join("")}function br(e,t,n){const r=vn(e.schema,t),o=e.settings.allowParseErrors&&"html"===e.schema.space?0:1,s=e.settings.allowDangerousCharacters?0:1;let i,a=e.quote;if(!r.overloadedBoolean||n!==r.attribute&&""!==n?!r.boolean&&!r.overloadedBoolean||"string"==typeof n&&n!==r.attribute&&""!==n||(n=Boolean(n)):n=!0,null==n||!1===n||"number"==typeof n&&Number.isNaN(n))return"";const l=Kn(r.attribute,Object.assign({},e.settings.characterReferences,{subset:mr.name[o][s]}));return!0===n?l:(n=Array.isArray(n)?(r.commaSeparated?er:tr)(n,{padLeft:!e.settings.tightCommaSeparatedLists}):String(n),e.settings.collapseEmptyAttributes&&!n?l:(e.settings.preferUnquoted&&(i=Kn(n,Object.assign({},e.settings.characterReferences,{attribute:!0,subset:mr.unquoted[o][s]}))),i!==n&&(e.settings.quoteSmart&&Yn(n,a)>Yn(n,e.alternative)&&(a=e.alternative),i=a+Kn(n,Object.assign({},e.settings.characterReferences,{subset:("'"===a?mr.single:mr.double)[o][s],attribute:!0}))+a),l+(i?"="+i:i)))}const wr=["<","&"];function kr(e,t,n,r){return!n||"element"!==n.type||"script"!==n.tagName&&"style"!==n.tagName?Kn(e.value,Object.assign({},r.settings.characterReferences,{subset:wr})):e.value}const Cr=(function(e,t){const n=t||{};function r(t,...n){let o=r.invalid;const s=r.handlers;if(t&&En.call(t,e)){const n=String(t[e]);o=En.call(s,n)?s[n]:r.unknown}if(o)return o.call(this,t,...n)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r})("type",{invalid:function(e){throw new Error("Expected node, not `"+e+"`")},unknown:function(e){throw new Error("Cannot compile unknown node `"+e.type+"`")},handlers:{comment:function(e,t,n,r){return r.settings.bogusComments?"<?"+Kn(e.value,Object.assign({},r.settings.characterReferences,{subset:Jn}))+">":"\x3c!--"+e.value.replace(Zn,function(e){return Kn(e,Object.assign({},r.settings.characterReferences,{subset:Qn}))})+"--\x3e"},doctype:function(e,t,n,r){return"<!"+(r.settings.upperDoctype?"DOCTYPE":"doctype")+(r.settings.tightDoctype?"":" ")+"html>"},element:function(e,t,n,r){const o=r.schema,s="svg"!==o.space&&r.settings.omitOptionalTags;let i="svg"===o.space?r.settings.closeEmptyElements:r.settings.voids.includes(e.tagName.toLowerCase());const a=[];let l;"html"===o.space&&"svg"===e.tagName&&(r.schema=An);const c=yr(r,e.properties),u=r.all("html"===o.space&&"template"===e.tagName?e.content:e);return r.schema=o,u&&(i=!1),!c&&s&&gr(e,t,n)||(a.push("<",e.tagName,c?" "+c:""),i&&("svg"===o.space||r.settings.closeSelfClosing)&&(l=c.charAt(c.length-1),(!r.settings.tightSelfClosing||"/"===l||l&&"\""!==l&&"'"!==l)&&a.push(" "),a.push("/")),a.push(">")),a.push(u),i||s&&dr(e,t,n)||a.push("</"+e.tagName+">"),a.join("")},raw:function(e,t,n,r){return r.settings.allowDangerousHtml?e.value:kr(e,0,n,r)},root:function(e,t,n,r){return r.all(e)},text:kr}});const vr={},xr={},Sr=[];function _r(e,t,n){return Cr(e,t,n,this)}function Ar(e){const t=[],n=e&&e.children||Sr;let r=-1;for(;++r<n.length;)t[r]=this.one(n[r],r,e);return t.join("")}const Er=/\s+/g;function Lr(e,t){if(!t)return e;e.properties||={},e.properties.class||=[],"string"==typeof e.properties.class&&(e.properties.class=e.properties.class.split(Er)),Array.isArray(e.properties.class)||(e.properties.class=[]);const n=Array.isArray(t)?t:t.split(Er);for(const t of n)t&&!e.properties.class.includes(t)&&e.properties.class.push(t);return e}function Ir(e){const t=dt(e,!0).map(([e])=>e);return{lines:t,indexToPos:function(n){if(n===e.length)return{line:t.length-1,character:t.at(-1).length};let r=n,o=0;for(const e of t){if(r<e.length)break;r-=e.length,o++}return{line:o,character:r}},posToIndex:function(e,n){let r=0;for(let n=0;n<e;n++)r+=t[n].length;return r+=n,r}}}const Nr=["color","background-color"];function Pr(e,t){let n=0;const r=[];for(const o of t)o>n&&r.push(Object.assign({},e,{content:e.content.slice(n,o),offset:e.offset+n})),n=o;return n<e.content.length&&r.push(Object.assign({},e,{content:e.content.slice(n),offset:e.offset+n})),r}function Or(e,t){const n=[...t instanceof Set?t:new Set(t)].sort((e,t)=>e-t);return n.length?e.map(e=>e.flatMap(e=>{const t=n.filter(t=>e.offset<t&&t<e.offset+e.content.length).map(t=>t-e.offset).sort((e,t)=>e-t);return t.length?Pr(e,t):e})):e}function Tr(e,t,n,r,o="css-vars"){const s={content:e.content,explanation:e.explanation,offset:e.offset},i=t.map(t=>$r(e.variants[t])),a=new Set(i.flatMap(e=>Object.keys(e))),l={},c=(e,r)=>{const o="color"===r?"":"background-color"===r?"-bg":`-${r}`;return n+t[e]+("color"===r?"":o)};return i.forEach((e,n)=>{for(const s of a){const a=e[s]||"inherit";if(0===n&&r&&Nr.includes(s))if("light-dark()"===r&&i.length>1){const e=t.findIndex(e=>"light"===e),r=t.findIndex(e=>"dark"===e);if(-1===e||-1===r)throw new E("When using `defaultColor: \"light-dark()\"`, you must provide both `light` and `dark` themes");const u=i[e][s]||"inherit",d=i[r][s]||"inherit";l[s]=`light-dark(${u}, ${d})`,"css-vars"===o&&(l[c(n,s)]=a)}else l[s]=a;else"css-vars"===o&&(l[c(n,s)]=a)}}),s.htmlStyle=l,s}function $r(e){const t={};if(e.color&&(t.color=e.color),e.bgColor&&(t["background-color"]=e.bgColor),e.fontStyle){e.fontStyle&V.Italic&&(t["font-style"]="italic"),e.fontStyle&V.Bold&&(t["font-weight"]="bold");const n=[];e.fontStyle&V.Underline&&n.push("underline"),e.fontStyle&V.Strikethrough&&n.push("line-through"),n.length&&(t["text-decoration"]=n.join(" "))}return t}function Rr(e){return"string"==typeof e?e:Object.entries(e).map(([e,t])=>`${e}:${t}`).join(";")}function Mr(){const e=new WeakMap;function t(t){if(!e.has(t.meta)){const r=Ir(t.source);function n(e){if("number"==typeof e){if(e<0||e>t.source.length)throw new E(`Invalid decoration offset: ${e}. Code length: ${t.source.length}`);return Object.assign({},r.indexToPos(e),{offset:e})}{const t=r.lines[e.line];if(void 0===t)throw new E(`Invalid decoration position ${JSON.stringify(e)}. Lines length: ${r.lines.length}`);let n=e.character;if(n<0&&(n=t.length+n),n<0||n>t.length)throw new E(`Invalid decoration position ${JSON.stringify(e)}. Line ${e.line} length: ${t.length}`);return Object.assign({},e,{character:n,offset:r.posToIndex(e.line,n)})}}const o=(t.options.decorations||[]).map(e=>Object.assign({},e,{start:n(e.start),end:n(e.end)}));jr(o),e.set(t.meta,{decorations:o,converter:r,source:t.source})}return e.get(t.meta)}return{name:"shiki:decorations",tokens(e){if(this.options.decorations?.length)return Or(e,t(this).decorations.flatMap(e=>[e.start.offset,e.end.offset]))},code(e){if(!this.options.decorations?.length)return;const n=t(this),r=[...e.children].filter(e=>"element"===e.type&&"span"===e.tagName);if(r.length!==n.converter.lines.length)throw new E(`Number of lines in code element (${r.length}) does not match the number of lines in the source (${n.converter.lines.length}). Failed to apply decorations.`);function o(e,t,n,o){const s=r[e];let a="",l=-1,c=-1;if(0===t&&(l=0),0===n&&(c=0),n===Number.POSITIVE_INFINITY&&(c=s.children.length),-1===l||-1===c)for(let e=0;e<s.children.length;e++)a+=Dr(s.children[e]),-1===l&&a.length===t&&(l=e+1),-1===c&&a.length===n&&(c=e+1);if(-1===l)throw new E(`Failed to find start index for decoration ${JSON.stringify(o.start)}`);if(-1===c)throw new E(`Failed to find end index for decoration ${JSON.stringify(o.end)}`);const u=s.children.slice(l,c);if(o.alwaysWrap||u.length!==s.children.length)if(o.alwaysWrap||1!==u.length||"element"!==u[0].type){const e={type:"element",tagName:"span",properties:{},children:u};i(e,o,"wrapper"),s.children.splice(l,u.length,e)}else i(u[0],o,"token");else i(s,o,"line")}function s(e,t){r[e]=i(r[e],t,"line")}function i(e,t,n){const r=t.properties||{},o=t.transform||(e=>e);return e.tagName=t.tagName||"span",e.properties=Object.assign({},e.properties,r,{class:e.properties.class}),t.properties?.class&&Lr(e,t.properties.class),e=o(e,n)||e}const a=[],l=n.decorations.sort((e,t)=>t.start.offset-e.start.offset||e.end.offset-t.end.offset);for(const e of l){const{start:t,end:n}=e;if(t.line===n.line)o(t.line,t.character,n.character,e);else if(t.line<n.line){o(t.line,t.character,Number.POSITIVE_INFINITY,e);for(let r=t.line+1;r<n.line;r++)a.unshift(()=>s(r,e));o(n.line,0,n.character,e)}}a.forEach(e=>e())}}}function jr(e){for(let t=0;t<e.length;t++){const n=e[t];if(n.start.offset>n.end.offset)throw new E(`Invalid decoration range: ${JSON.stringify(n.start)} - ${JSON.stringify(n.end)}`);for(let r=t+1;r<e.length;r++){const t=e[r],o=n.start.offset<=t.start.offset&&t.start.offset<n.end.offset,s=n.start.offset<t.end.offset&&t.end.offset<=n.end.offset,i=t.start.offset<=n.start.offset&&n.start.offset<t.end.offset,a=t.start.offset<n.end.offset&&n.end.offset<=t.end.offset;if(o||s||i||a){if(o&&s)continue;if(i&&a)continue;if(i&&n.start.offset===n.end.offset)continue;if(s&&t.start.offset===t.end.offset)continue;throw new E(`Decorations ${JSON.stringify(n.start)} and ${JSON.stringify(t.start)} intersect.`)}}}}function Dr(e){return"text"===e.type?e.value:"element"===e.type?e.children.map(Dr).join(""):""}const Br=[Mr()];function Fr(e){const t=Gr(e.transformers||[]);return[...t.pre,...t.normal,...t.post,...Br]}function Gr(e){const t=[],n=[],r=[];for(const o of e)switch(o.enforce){case"pre":t.push(o);break;case"post":n.push(o);break;default:r.push(o)}return{pre:t,post:n,normal:r}}var Ur=["black","red","green","yellow","blue","magenta","cyan","white","brightBlack","brightRed","brightGreen","brightYellow","brightBlue","brightMagenta","brightCyan","brightWhite"],Wr={1:"bold",2:"dim",3:"italic",4:"underline",7:"reverse",8:"hidden",9:"strikethrough"};function zr(e,t){const n=e.indexOf("\x1b",t);if(-1!==n&&"["===e[n+1]){const t=e.indexOf("m",n);if(-1!==t)return{sequence:e.substring(n+2,t).split(";"),startPosition:n,position:t+1}}return{position:e.length}}function qr(e){const t=e.shift();if("2"===t){const t=e.splice(0,3).map(e=>Number.parseInt(e));if(3!==t.length||t.some(e=>Number.isNaN(e)))return;return{type:"rgb",rgb:t}}if("5"===t){const t=e.shift();if(t)return{type:"table",index:Number(t)}}}function Hr(e){const t=[];for(;e.length>0;){const n=e.shift();if(!n)continue;const r=Number.parseInt(n);if(!Number.isNaN(r))if(0===r)t.push({type:"resetAll"});else if(r<=9)Wr[r]&&t.push({type:"setDecoration",value:Wr[r]});else if(r<=29){const e=Wr[r-20];e&&(t.push({type:"resetDecoration",value:e}),"dim"===e&&t.push({type:"resetDecoration",value:"bold"}))}else if(r<=37)t.push({type:"setForegroundColor",value:{type:"named",name:Ur[r-30]}});else if(38===r){const n=qr(e);n&&t.push({type:"setForegroundColor",value:n})}else if(39===r)t.push({type:"resetForegroundColor"});else if(r<=47)t.push({type:"setBackgroundColor",value:{type:"named",name:Ur[r-40]}});else if(48===r){const n=qr(e);n&&t.push({type:"setBackgroundColor",value:n})}else 49===r?t.push({type:"resetBackgroundColor"}):53===r?t.push({type:"setDecoration",value:"overline"}):55===r?t.push({type:"resetDecoration",value:"overline"}):r>=90&&r<=97?t.push({type:"setForegroundColor",value:{type:"named",name:Ur[r-90+8]}}):r>=100&&r<=107&&t.push({type:"setBackgroundColor",value:{type:"named",name:Ur[r-100+8]}})}return t}function Vr(){let e=null,t=null,n=new Set;return{parse(r){const o=[];let s=0;do{const i=zr(r,s),a=i.sequence?r.substring(s,i.startPosition):r.substring(s);if(a.length>0&&o.push({value:a,foreground:e,background:t,decorations:new Set(n)}),i.sequence){const r=Hr(i.sequence);for(const o of r)"resetAll"===o.type?(e=null,t=null,n.clear()):"resetForegroundColor"===o.type?e=null:"resetBackgroundColor"===o.type?t=null:"resetDecoration"===o.type&&n.delete(o.value);for(const o of r)"setForegroundColor"===o.type?e=o.value:"setBackgroundColor"===o.type?t=o.value:"setDecoration"===o.type&&n.add(o.value)}s=i.position}while(s<r.length);return o}}}var Xr={black:"#000000",red:"#bb0000",green:"#00bb00",yellow:"#bbbb00",blue:"#0000bb",magenta:"#ff00ff",cyan:"#00bbbb",white:"#eeeeee",brightBlack:"#555555",brightRed:"#ff5555",brightGreen:"#00ff00",brightYellow:"#ffff55",brightBlue:"#5555ff",brightMagenta:"#ff55ff",brightCyan:"#55ffff",brightWhite:"#ffffff"};function Kr(e=Xr){function t(t){return e[t]}function n(e){return`#${e.map(e=>Math.max(0,Math.min(e,255)).toString(16).padStart(2,"0")).join("")}`}let r;function o(){if(r)return r;r=[];for(let e=0;e<Ur.length;e++)r.push(t(Ur[e]));let e=[0,95,135,175,215,255];for(let t=0;t<6;t++)for(let o=0;o<6;o++)for(let s=0;s<6;s++)r.push(n([e[t],e[o],e[s]]));let o=8;for(let e=0;e<24;e++,o+=10)r.push(n([o,o,o]));return r}return{value:function(e){switch(e.type){case"named":return t(e.name);case"rgb":return n(e.rgb);case"table":return r=e.index,o()[r]}var r}}}const Zr=/#([0-9a-f]{3,8})/i,Jr=/var\((--[\w-]+-ansi-[\w-]+)\)/,Qr={black:"#000000",red:"#cd3131",green:"#0DBC79",yellow:"#E5E510",blue:"#2472C8",magenta:"#BC3FBC",cyan:"#11A8CD",white:"#E5E5E5",brightBlack:"#666666",brightRed:"#F14C4C",brightGreen:"#23D18B",brightYellow:"#F5F543",brightBlue:"#3B8EEA",brightMagenta:"#D670D6",brightCyan:"#29B8DB",brightWhite:"#FFFFFF"};function Yr(e,t,n){const r=rt(e,n),o=dt(t),s=Kr(Object.fromEntries(Ur.map(t=>{const n=`terminal.ansi${t[0].toUpperCase()}${t.substring(1)}`;return[t,e.colors?.[n]||Qr[t]]}))),i=Vr();return o.map(t=>i.parse(t[0]).map(n=>{let o,i;n.decorations.has("reverse")?(o=n.background?s.value(n.background):e.bg,i=n.foreground?s.value(n.foreground):e.fg):(o=n.foreground?s.value(n.foreground):e.fg,i=n.background?s.value(n.background):void 0),o=ot(o,r),i=ot(i,r),n.decorations.has("dim")&&(o=eo(o));let a=V.None;return n.decorations.has("bold")&&(a|=V.Bold),n.decorations.has("italic")&&(a|=V.Italic),n.decorations.has("underline")&&(a|=V.Underline),n.decorations.has("strikethrough")&&(a|=V.Strikethrough),{content:n.value,offset:t[1],color:o,bgColor:i,fontStyle:a}}))}function eo(e){const t=e.match(Zr);if(t){const e=t[1];if(8===e.length){const t=Math.round(Number.parseInt(e.slice(6,8),16)/2).toString(16).padStart(2,"0");return`#${e.slice(0,6)}${t}`}if(6===e.length)return`#${e}80`;if(4===e.length){const t=e[0],n=e[1],r=e[2],o=e[3];return`#${t}${t}${n}${n}${r}${r}${Math.round(Number.parseInt(`${o}${o}`,16)/2).toString(16).padStart(2,"0")}`}if(3===e.length){const t=e[0],n=e[1],r=e[2];return`#${t}${t}${n}${n}${r}${r}80`}}const n=e.match(Jr);return n?`var(${n[1]}-dim)`:e}function to(e,t,n={}){const r=e.resolveLangAlias(n.lang||"text"),{theme:o=e.getLoadedThemes()[0]}=n;if(!at(r)&&!lt(o)&&"ansi"===r){const{theme:r}=e.setTheme(o);return Yr(r,t,n)}return $t(e,t,n)}function no(e,t,n){let r,o,s,i,a,l;if("themes"in n){const{defaultColor:c="light",cssVariablePrefix:u="--shiki-",colorsRendering:d="css-vars"}=n,h=Object.entries(n.themes).filter(e=>e[1]).map(e=>({color:e[0],theme:e[1]})).sort((e,t)=>e.color===c?-1:t.color===c?1:0);if(0===h.length)throw new E("`themes` option must not be empty");const p=Wt(e,t,n,to);if(l=Lt(p),c&&"light-dark()"!==c&&!h.some(e=>e.color===c))throw new E(`\`themes\` option must contain the defaultColor key \`${c}\``);const f=h.map(t=>e.getTheme(t.theme)),g=h.map(e=>e.color);s=p.map(e=>e.map(e=>Tr(e,g,u,c,d))),l&&Et(s,l);const m=h.map(e=>rt(e.theme,n));o=ro(h,f,m,u,c,"fg",d),r=ro(h,f,m,u,c,"bg",d),i=`shiki-themes ${f.map(e=>e.name).join(" ")}`,a=c?void 0:[o,r].join(";")}else{if(!("theme"in n))throw new E("Invalid options, either `theme` or `themes` must be provided");{const a=rt(n.theme,n);s=to(e,t,n);const c=e.getTheme(n.theme);r=ot(c.bg,a),o=ot(c.fg,a),i=c.name,l=Lt(s)}}return{tokens:s,fg:o,bg:r,themeName:i,rootStyle:a,grammarState:l}}function ro(e,t,n,r,o,s,i){return e.map((a,l)=>{const c=ot(t[l][s],n[l])||"inherit",u=`${r+a.color}${"bg"===s?"-bg":""}:${c}`;if(0===l&&o){if("light-dark()"===o&&e.length>1){const r=e.findIndex(e=>"light"===e.color),o=e.findIndex(e=>"dark"===e.color);if(-1===r||-1===o)throw new E("When using `defaultColor: \"light-dark()\"`, you must provide both `light` and `dark` themes");return`light-dark(${ot(t[r][s],n[r])||"inherit"}, ${ot(t[o][s],n[o])||"inherit"});${u}`}return c}return"css-vars"===i?u:null}).filter(e=>!!e).join(";")}const oo=/^\s+$/,so=/^(\s*)(.*?)(\s*)$/;function io(e,t,n,r={meta:{},options:n,codeToHast:(t,n)=>io(e,t,n),codeToTokens:(t,n)=>no(e,t,n)}){let o=t;for(const e of Fr(n))o=e.preprocess?.call(r,o,n)||o;let{tokens:s,fg:i,bg:a,themeName:l,rootStyle:c,grammarState:u}=no(e,o,n);const{mergeWhitespaces:d=!0,mergeSameStyleTokens:h=!1}=n;!0===d?s=lo(s):"never"===d&&(s=co(s)),h&&(s=uo(s));const p=Object.assign({},r,{get source(){return o}});for(const e of Fr(n))s=e.tokens?.call(p,s)||s;return ao(s,Object.assign({},n,{fg:i,bg:a,themeName:l,rootStyle:!1!==n.rootStyle&&(n.rootStyle??c)}),p,u)}function ao(e,t,n,r=Lt(e)){const o=Fr(t),s=[],i={type:"root",children:[]},{structure:a="classic",tabindex:l="0"}=t,c={class:`shiki ${t.themeName||""}`};!1!==t.rootStyle&&(null!=t.rootStyle?c.style=t.rootStyle:c.style=`background-color:${t.bg};color:${t.fg}`),!1!==l&&null!=l&&(c.tabindex=l.toString());for(const[e,n]of Object.entries(t.meta||{}))e.startsWith("_")||(c[e]=n);let u={type:"element",tagName:"pre",properties:c,children:[],data:t.data},d={type:"element",tagName:"code",properties:{},children:s};const h=[],p=Object.assign({},n,{structure:a,addClassToHast:Lr,get source(){return n.source},get tokens(){return e},get options(){return t},get root(){return i},get pre(){return u},get code(){return d},get lines(){return h}});if(e.forEach((e,t)=>{t&&("inline"===a?i.children.push({type:"element",tagName:"br",properties:{},children:[]}):"classic"===a&&s.push({type:"text",value:"\n"}));let n={type:"element",tagName:"span",properties:{class:"line"},children:[]},r=0;for(const s of e){let e={type:"element",tagName:"span",properties:Object.assign({},s.htmlAttrs),children:[{type:"text",value:s.content}]};const l=Rr(s.htmlStyle||$r(s));l&&(e.properties.style=l);for(const i of o)e=i?.span?.call(p,e,t+1,r,n,s)||e;"inline"===a?i.children.push(e):"classic"===a&&n.children.push(e),r+=s.content.length}if("classic"===a){for(const e of o)n=e?.line?.call(p,n,t+1)||n;h.push(n),s.push(n)}else"inline"===a&&h.push(n)}),"classic"===a){for(const e of o)d=e?.code?.call(p,d)||d;u.children.push(d);for(const e of o)u=e?.pre?.call(p,u)||u;i.children.push(u)}else if("inline"===a){const e=[];let t={type:"element",tagName:"span",properties:{class:"line"},children:[]};for(const n of i.children)"element"===n.type&&"br"===n.tagName?(e.push(t),t={type:"element",tagName:"span",properties:{class:"line"},children:[]}):"element"!==n.type&&"text"!==n.type||t.children.push(n);e.push(t);let n={type:"element",tagName:"code",properties:{},children:e};for(const e of o)n=e?.code?.call(p,n)||n;i.children=[];for(let e=0;e<n.children.length;e++){e>0&&i.children.push({type:"element",tagName:"br",properties:{},children:[]});const t=n.children[e];"element"===t.type&&i.children.push(...t.children)}}let f=i;for(const e of o)f=e?.root?.call(p,f)||f;return r&&Et(f,r),f}function lo(e){return e.map(e=>{const t=[];let n,r="";return e.forEach((o,s)=>{const i=!(o.fontStyle&&(o.fontStyle&V.Underline||o.fontStyle&V.Strikethrough));i&&oo.test(o.content)&&e[s+1]?(void 0===n&&(n=o.offset),r+=o.content):r?(i?t.push(Object.assign({},o,{offset:n,content:r+o.content})):t.push({content:r,offset:n},o),n=void 0,r=""):t.push(o)}),t})}function co(e){return e.map(e=>e.flatMap(e=>{if(oo.test(e.content))return e;const t=e.content.match(so);if(!t)return e;const[,n,r,o]=t;if(!n&&!o)return e;const s=[Object.assign({},e,{offset:e.offset+n.length,content:r})];return n&&s.unshift({content:n,offset:e.offset}),o&&s.push({content:o,offset:e.offset+n.length+r.length}),s}))}function uo(e){return e.map(e=>{const t=[];for(const n of e){if(0===t.length){t.push(Object.assign({},n));continue}const e=t.at(-1),r=Rr(e.htmlStyle||$r(e)),o=Rr(n.htmlStyle||$r(n)),s=e.fontStyle&&(e.fontStyle&V.Underline||e.fontStyle&V.Strikethrough),i=n.fontStyle&&(n.fontStyle&V.Underline||n.fontStyle&V.Strikethrough);s||i||r!==o?t.push(Object.assign({},n)):e.content+=n.content}return t})}const ho=function(e,t){const n=t||vr,r=n.quote||"\"",o="\""===r?"'":"\"";if("\""!==r&&"'"!==r)throw new Error("Invalid quote `"+r+"`, expected `'` or `\"`");return{one:_r,all:Ar,settings:{omitOptionalTags:n.omitOptionalTags||!1,allowParseErrors:n.allowParseErrors||!1,allowDangerousCharacters:n.allowDangerousCharacters||!1,quoteSmart:n.quoteSmart||!1,preferUnquoted:n.preferUnquoted||!1,tightAttributes:n.tightAttributes||!1,upperDoctype:n.upperDoctype||!1,tightDoctype:n.tightDoctype||!1,bogusComments:n.bogusComments||!1,tightCommaSeparatedLists:n.tightCommaSeparatedLists||!1,tightSelfClosing:n.tightSelfClosing||!1,collapseEmptyAttributes:n.collapseEmptyAttributes||!1,allowDangerousHtml:n.allowDangerousHtml||!1,voids:n.voids||qt,characterReferences:n.characterReferences||xr,closeSelfClosing:n.closeSelfClosing||!1,closeEmptyElements:n.closeEmptyElements||!1},schema:"svg"===n.space?An:_n,quote:r,alternative:o}.one(Array.isArray(e)?{type:"root",children:e}:e,void 0,void 0)};function po(e,t,n){const r={meta:{},options:n,codeToHast:(t,n)=>io(e,t,n),codeToTokens:(t,n)=>no(e,t,n)};let o=ho(io(e,t,n,r));for(const e of Fr(n))o=e.postprocess?.call(r,o,n)||o;return o}async function fo(e){const t=await _t(e);return Object.assign({getLastGrammarState:(...e)=>Rt(t,...e),codeToTokensBase:(e,n)=>to(t,e,n),codeToTokensWithThemes:(e,n)=>Wt(t,e,n),codeToTokens:(e,n)=>no(t,e,n),codeToHast:(e,n)=>io(t,e,n),codeToHtml:(e,n)=>po(t,e,n),getBundledLanguages:()=>({}),getBundledThemes:()=>({})},t,{getInternalContext:()=>t})}const go=4294967295;var mo=class{constructor(e,t={}){this.patterns=e,this.options=t;const{forgiving:n=!1,cache:r,regexConstructor:o}=t;if(!o)throw new Error("Option `regexConstructor` is not provided");this.regexps=e.map(e=>{if("string"!=typeof e)return e;const t=r?.get(e);if(t){if(t instanceof RegExp)return t;if(n)return null;throw t}try{const t=o(e);return r?.set(e,t),t}catch(t){if(r?.set(e,t),n)return null;throw t}})}findNextMatchSync(e,t,n){const r="string"==typeof e?e:e.content,o=[];function s(e,t,n=0){return{index:e,captureIndices:t.indices.map(e=>null==e?{start:go,end:go,length:0}:{start:e[0]+n,end:e[1]+n,length:e[1]-e[0]})}}for(let e=0;e<this.regexps.length;e++){const n=this.regexps[e];if(n)try{n.lastIndex=t;const i=n.exec(r);if(!i)continue;if(i.index===t)return s(e,i,0);o.push([e,i,0])}catch(e){if(this.options.forgiving)continue;throw e}}if(o.length){const e=Math.min(...o.map(e=>e[1].index));for(const[t,n,r]of o)if(n.index===e)return s(t,n,r)}return null}};function yo(e){if(1!==[...e].length)throw new Error(`Expected "${e}" to be a single code point`);return e.codePointAt(0)}function bo(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}const wo=new Set(["alnum","alpha","ascii","blank","cntrl","digit","graph","lower","print","punct","space","upper","word","xdigit"]),ko=String.raw;function Co(e,t){if(null==e)throw new Error(t??"Value expected");return e}const vo=ko`\[\^?`,xo=`c.? | C(?:-.?)?|${ko`[pP]\{(?:\^?[-\x20_]*[A-Za-z][-\x20\w]*\})?`}|${ko`x[89A-Fa-f]\p{AHex}(?:\\x[89A-Fa-f]\p{AHex})*`}|${ko`u(?:\p{AHex}{4})? | x\{[^\}]*\}? | x\p{AHex}{0,2}`}|${ko`o\{[^\}]*\}?`}|${ko`\d{1,3}`}`,So=/[?*+][?+]?|\{(?:\d+(?:,\d*)?|,\d+)\}\??/,_o=new RegExp(ko`
13
13
  \\ (?:
14
14
  ${xo}
@@ -55,5 +55,5 @@ __d(function(e,t,n,r,o,s,i){var a,l,c,u,d,h,p=t(i[0]).default,f=t(i[1]).default,
55
55
  ))?
56
56
  | (?<qBase>${li})(?<qMod>[?+]?)(?<invalidQ>[?*+\{]?)
57
57
  | \\?.
58
- `.replace(/\s+/g,""),"gsu");function ui(e){if(!new RegExp(`${li}\\+`).test(e))return{pattern:e};const t=[];let n,r=null,o=null,s="",i=0;for(ci.lastIndex=0;n=ci.exec(e);){const{0:a,index:l,groups:{qBase:c,qMod:u,invalidQ:d}}=n;if("["===a)i||(o=l),i++;else if("]"===a)i?i--:o=null;else if(!i)if("+"===u&&s&&!s.startsWith("(")){if(d)throw new Error(`Invalid quantifier "${a}"`);let t=-1;if(/^\{\d+\}$/.test(c))e=Ys(e,l+c.length,u,"");else{if(")"===s||"]"===s){const t=")"===s?r:o;if(null===t)throw new Error(`Invalid unmatched "${s}"`);e=`${e.slice(0,t)}(?>${e.slice(t,l)}${c})${e.slice(l+a.length)}`}else e=`${e.slice(0,l-s.length)}(?>${s}${c})${e.slice(l+a.length)}`;t+=4}ci.lastIndex+=t}else"("===a[0]?t.push(l):")"===a&&(r=t.length?t.pop():null);s=a}return{pattern:e}}const di=String.raw,hi=di`\(\?R=(?<rDepth>[^\)]+)\)|${di`\\g<(?<gRNameOrNum>[^>&]+)&R=(?<gRDepth>[^>]+)>`}`,pi=di`\(\?<(?![=!])(?<captureName>[^>]+)>`,fi=di`${pi}|(?<unnamed>\()(?!\?)`,gi=new RegExp(di`${pi}|${hi}|\(\?|\\?.`,"gsu"),mi="Cannot use multiple overlapping recursions";function yi(e,t){const{hiddenCaptures:n,mode:r}=Object.assign({hiddenCaptures:[],mode:"plugin"},t);let o=t?.captureTransfers??new Map;if(!new RegExp(hi,"su").test(e))return{pattern:e,captureTransfers:o,hiddenCaptures:n};if("plugin"===r&&oi(e,di`\(\?\(DEFINE\)`,ei.DEFAULT))throw new Error("DEFINE groups cannot be used with recursion");const s=[],i=oi(e,di`\\[1-9]`,ei.DEFAULT),a=new Map,l=[];let c,u=!1,d=0,h=0;for(gi.lastIndex=0;c=gi.exec(e);){const{0:t,groups:{captureName:p,rDepth:f,gRNameOrNum:g,gRDepth:m}}=c;if("["===t)d++;else if(d)"]"===t&&d--;else{if(f){if(bi(f),u)throw new Error(mi);if(i)throw new Error(("external"===r?"Backrefs":"Numbered backrefs")+" cannot be used with global recursion");const t=e.slice(0,c.index),a=e.slice(gi.lastIndex);if(oi(a,hi,ei.DEFAULT))throw new Error(mi);const l=+f-1;e=wi(t,a,l,!1,n,s,h),o=vi(o,t,l,s.length,0,h);break}if(g){bi(m);let d=!1;for(const e of l)if(e.name===g||e.num===+g){if(d=!0,e.hasRecursedWithin)throw new Error(mi);break}if(!d)throw new Error(di`Recursive \g cannot be used outside the referenced group "${"external"===r?g:di`\g<${g}&R=${m}>`}"`);const p=a.get(g),f=si(e,p);if(i&&oi(f,di`${pi}|\((?!\?)`,ei.DEFAULT))throw new Error(("external"===r?"Backrefs":"Numbered backrefs")+" cannot be used with recursion of capturing groups");const y=e.slice(p,c.index),b=f.slice(y.length+t.length),w=s.length,k=+m-1,C=wi(y,b,k,!0,n,s,h);o=vi(o,y,k,s.length-w,w,h),e=`${e.slice(0,p)}${C}${e.slice(p+f.length)}`,gi.lastIndex+=C.length-t.length-y.length-b.length,l.forEach(e=>e.hasRecursedWithin=!0),u=!0}else if(p)h++,a.set(String(h),gi.lastIndex),a.set(p,gi.lastIndex),l.push({num:h,name:p});else if("("===t[0]){const e="("===t;e&&(h++,a.set(String(h),gi.lastIndex)),l.push(e?{num:h}:{})}else")"===t&&l.pop()}}return n.push(...s),{pattern:e,captureTransfers:o,hiddenCaptures:n}}function bi(e){const t=`Max depth must be integer between 2 and 100; used ${e}`;if(!/^[1-9]\d*$/.test(e))throw new Error(t);if((e=+e)<2||e>100)throw new Error(t)}function wi(e,t,n,r,o,s,i){const a=new Set;r&&ni(e+t,pi,({groups:{captureName:e}})=>{a.add(e)},ei.DEFAULT);const l=[n,r?a:null,o,s,i];return`${e}${ki(`(?:${e}`,"forward",...l)}(?:)${ki(`${t})`,"backward",...l)}${t}`}function ki(e,t,n,r,o,s,i){const a=e=>"forward"===t?e+2:n-e+2-1;let l="";for(let t=0;t<n;t++){const n=a(t);l+=ti(e,di`${fi}|\\k<(?<backref>[^>]+)>`,({0:e,groups:{captureName:t,unnamed:a,backref:l}})=>{if(l&&r&&!r.has(l))return e;const c=`_$${n}`;if(a||t){const n=i+s.length+1;return s.push(n),Ci(o,n),a?e:`(?<${t}${c}>`}return di`\k<${l}${c}>`},ei.DEFAULT)}return l}function Ci(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function vi(e,t,n,r,o,s){if(e.size&&r){let i=0;ni(t,fi,()=>i++,ei.DEFAULT);const a=s-i+o,l=new Map;return e.forEach((e,t)=>{const o=(r-i*n)/n,s=i*n,c=t>a+i?t+r:t,u=[];for(const t of e)if(t<=a)u.push(t);else if(t>a+i+o)u.push(t+r);else if(t<=a+i)for(let e=0;e<=n;e++)u.push(t+i*e);else for(let e=0;e<=n;e++)u.push(t+s+o*e);l.set(c,u)}),l}return e}var xi=String.fromCodePoint,Si=String.raw,_i={},Ai=globalThis.RegExp;function Ei(e,{enable:t,disable:n}){return{dotAll:!(n?.dotAll||!t?.dotAll&&!e.dotAll),ignoreCase:!(n?.ignoreCase||!t?.ignoreCase&&!e.ignoreCase)}}function Li(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}function Ii(e,t){return Pi[e]>=Pi[t]}function Ni(e,t){if(null==e)throw new Error(t??"Value expected");return e}_i.flagGroups=(()=>{try{new Ai("(?i:)")}catch{return!1}return!0})(),_i.unicodeSets=(()=>{try{new Ai("[[]]","v")}catch{return!1}return!0})(),_i.bugFlagVLiteralHyphenIsRange=!!_i.unicodeSets&&(()=>{try{new Ai(Si`[\d\-a]`,"v")}catch{return!0}return!1})(),_i.bugNestedClassIgnoresNegation=_i.unicodeSets&&new Ai("[[^a]]","v").test("a");var Pi={ES2025:2025,ES2024:2024,ES2018:2018},Oi={auto:"auto",ES2025:"ES2025",ES2024:"ES2024",ES2018:"ES2018"};function Ti(e={}){if("[object Object]"!=={}.toString.call(e))throw new Error("Unexpected options");if(void 0!==e.target&&!Oi[e.target])throw new Error(`Unexpected target "${e.target}"`);const t=Object.assign({accuracy:"default",avoidSubclass:!1,flags:"",global:!1,hasIndices:!1,lazyCompileLength:1/0,target:"auto",verbose:!1},e,{rules:Object.assign({allowOrphanBackrefs:!1,asciiWordBoundaries:!1,captureGroup:!1,recursionLimit:20,singleline:!1},e.rules)});return"auto"===t.target&&(t.target=_i.flagGroups?"ES2025":_i.unicodeSets?"ES2024":"ES2018"),t}var $i=new Set([xi(304),xi(305)]),Ri=Si`[\p{L}\p{M}\p{N}\p{Pc}]`;function Mi(e){if($i.has(e))return[e];const t=new Set,n=e.toLowerCase(),r=n.toUpperCase(),o=Fi.get(n),s=Di.get(n),i=Bi.get(n);return 1===[...r].length&&t.add(r),i&&t.add(i),o&&t.add(o),t.add(n),s&&t.add(s),[...t]}var ji=new Map("C Other\nCc Control cntrl\nCf Format\nCn Unassigned\nCo Private_Use\nCs Surrogate\nL Letter\nLC Cased_Letter\nLl Lowercase_Letter\nLm Modifier_Letter\nLo Other_Letter\nLt Titlecase_Letter\nLu Uppercase_Letter\nM Mark Combining_Mark\nMc Spacing_Mark\nMe Enclosing_Mark\nMn Nonspacing_Mark\nN Number\nNd Decimal_Number digit\nNl Letter_Number\nNo Other_Number\nP Punctuation punct\nPc Connector_Punctuation\nPd Dash_Punctuation\nPe Close_Punctuation\nPf Final_Punctuation\nPi Initial_Punctuation\nPo Other_Punctuation\nPs Open_Punctuation\nS Symbol\nSc Currency_Symbol\nSk Modifier_Symbol\nSm Math_Symbol\nSo Other_Symbol\nZ Separator\nZl Line_Separator\nZp Paragraph_Separator\nZs Space_Separator\nASCII\nASCII_Hex_Digit AHex\nAlphabetic Alpha\nAny\nAssigned\nBidi_Control Bidi_C\nBidi_Mirrored Bidi_M\nCase_Ignorable CI\nCased\nChanges_When_Casefolded CWCF\nChanges_When_Casemapped CWCM\nChanges_When_Lowercased CWL\nChanges_When_NFKC_Casefolded CWKCF\nChanges_When_Titlecased CWT\nChanges_When_Uppercased CWU\nDash\nDefault_Ignorable_Code_Point DI\nDeprecated Dep\nDiacritic Dia\nEmoji\nEmoji_Component EComp\nEmoji_Modifier EMod\nEmoji_Modifier_Base EBase\nEmoji_Presentation EPres\nExtended_Pictographic ExtPict\nExtender Ext\nGrapheme_Base Gr_Base\nGrapheme_Extend Gr_Ext\nHex_Digit Hex\nIDS_Binary_Operator IDSB\nIDS_Trinary_Operator IDST\nID_Continue IDC\nID_Start IDS\nIdeographic Ideo\nJoin_Control Join_C\nLogical_Order_Exception LOE\nLowercase Lower\nMath\nNoncharacter_Code_Point NChar\nPattern_Syntax Pat_Syn\nPattern_White_Space Pat_WS\nQuotation_Mark QMark\nRadical\nRegional_Indicator RI\nSentence_Terminal STerm\nSoft_Dotted SD\nTerminal_Punctuation Term\nUnified_Ideograph UIdeo\nUppercase Upper\nVariation_Selector VS\nWhite_Space space\nXID_Continue XIDC\nXID_Start XIDS".split(/\s/).map(e=>[qs(e),e])),Di=new Map([["s",xi(383)],[xi(383),"s"]]),Bi=new Map([[xi(223),xi(7838)],[xi(107),xi(8490)],[xi(229),xi(8491)],[xi(969),xi(8486)]]),Fi=new Map([Wi(453),Wi(456),Wi(459),Wi(498),...zi(8072,8079),...zi(8088,8095),...zi(8104,8111),Wi(8124),Wi(8140),Wi(8188)]),Gi=new Map([["alnum",Si`[\p{Alpha}\p{Nd}]`],["alpha",Si`\p{Alpha}`],["ascii",Si`\p{ASCII}`],["blank",Si`[\p{Zs}\t]`],["cntrl",Si`\p{Cc}`],["digit",Si`\p{Nd}`],["graph",Si`[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]`],["lower",Si`\p{Lower}`],["print",Si`[[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]\p{Zs}]`],["punct",Si`[\p{P}\p{S}]`],["space",Si`\p{space}`],["upper",Si`\p{Upper}`],["word",Si`[\p{Alpha}\p{M}\p{Nd}\p{Pc}]`],["xdigit",Si`\p{AHex}`]]);function Ui(e,t){const n=[];for(let r=e;r<=t;r++)n.push(r);return n}function Wi(e){const t=xi(e);return[t.toLowerCase(),t]}function zi(e,t){return Ui(e,t).map(e=>Wi(e))}var qi=new Set(["Lower","Lowercase","Upper","Uppercase","Ll","Lowercase_Letter","Lt","Titlecase_Letter","Lu","Uppercase_Letter"]);function Hi(e,t){const n=Object.assign({accuracy:"default",asciiWordBoundaries:!1,avoidSubclass:!1,bestEffortTarget:"ES2025"},t);Zi(e);const r={accuracy:n.accuracy,asciiWordBoundaries:n.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,flagDirectivesByAlt:new Map,jsGroupNameMap:new Map,minTargetEs2024:Ii(n.bestEffortTarget,"ES2024"),passedLookbehind:!1,strategy:null,subroutineRefMap:new Map,supportedGNodes:new Set,digitIsAscii:e.flags.digitIsAscii,spaceIsAscii:e.flags.spaceIsAscii,wordIsAscii:e.flags.wordIsAscii};Xs(e,Vi,r);const o={dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},s={currentFlags:o,prevFlags:null,globalFlags:o,groupOriginByCopy:new Map,groupsByName:new Map,multiplexCapturesToLeftByRef:new Map,openRefs:new Map,reffedNodesByReferencer:new Map,subroutineRefMap:r.subroutineRefMap};return Xs(e,Xi,s),Xs(e,Ki,{groupsByName:s.groupsByName,highestOrphanBackref:0,numCapturesToLeft:0,reffedNodesByReferencer:s.reffedNodesByReferencer}),e._originMap=s.groupOriginByCopy,e._strategy=r.strategy,e}var Vi={AbsenceFunction({node:e,parent:t,replaceWith:n}){const{body:r,kind:o}=e;if("repeater"!==o)throw new Error("Unsupported absence function \"(?~|\"");{const e=Ns();e.body[0].body.push(Ps({negate:!0,body:r}),js("Any"));const o=Ns();o.body[0].body.push($s("greedy",0,1/0,e)),n(ga(o,t),{traverse:!0})}},Alternative:{enter({node:e,parent:t,key:n},{flagDirectivesByAlt:r}){const o=e.body.filter(e=>"flags"===e.kind);for(let e=n+1;e<t.body.length;e++){Li(r,t.body[e],[]).push(...o)}},exit({node:e},{flagDirectivesByAlt:t}){if(t.get(e)?.length){const n=ra(t.get(e));if(n){const t=Ns({flags:n});t.body[0].body=e.body,e.body=[ga(t,e)]}}}},Assertion({node:e,parent:t,key:n,container:r,root:o,remove:s,replaceWith:i},a){const{kind:l,negate:c}=e,{asciiWordBoundaries:u,avoidSubclass:d,supportedGNodes:h,wordIsAscii:p}=a;if("text_segment_boundary"===l)throw new Error(`Unsupported text segment boundary "\\${c?"Y":"y"}"`);if("line_end"===l)i(ga(Ps({body:[ks({body:[Cs("string_end")]}),ks({body:[Ss(10)]})]}),t));else if("line_start"===l)i(ga(ha(Si`(?<=\A|\n(?!\z))`,{skipLookbehindValidation:!0}),t));else if("search_start"===l)if(h.has(e))o.flags.sticky=!0,s();else{const e=r[n-1];if(e&&ca(e))i(ga(Ps({negate:!0}),t));else{if(d)throw new Error(Si`Uses "\G" in a way that requires a subclass`);i(fa(Cs("string_start"),t)),a.strategy="clip_search"}}else if("string_end"===l||"string_start"===l);else if("string_end_newline"===l)i(ga(ha(Si`(?=\n?\z)`),t));else{if("word_boundary"!==l)throw new Error(`Unexpected assertion kind "${l}"`);if(!p&&!u){i(ga(ha(c?`(?:(?<=${Ri})(?=${Ri})|(?<!${Ri})(?!${Ri}))`:`(?:(?<=${Ri})(?!${Ri})|(?<!${Ri})(?=${Ri}))`),t))}}},Backreference({node:e},{jsGroupNameMap:t}){let{ref:n}=e;"string"!=typeof n||da(n)||(n=na(n,t),e.ref=n)},CapturingGroup({node:e},{jsGroupNameMap:t,subroutineRefMap:n}){let{name:r}=e;r&&!da(r)&&(r=na(r,t),e.name=r),n.set(e.number,e),r&&n.set(r,e)},CharacterClassRange({node:e,parent:t,replaceWith:n}){"intersection"===t.kind&&n(ga(_s({body:[e]}),t),{traverse:!0})},CharacterSet({node:e,parent:t,replaceWith:n},{accuracy:r,minTargetEs2024:o,digitIsAscii:s,spaceIsAscii:i,wordIsAscii:a}){const{kind:l,negate:c,value:u}=e;if(!s||"digit"!==l&&"digit"!==u)if(!i||"space"!==l&&"space"!==u)if(!a||"word"!==l&&"word"!==u)if("any"===l)n(fa(js("Any"),t));else if("digit"===l)n(fa(js("Nd",{negate:c}),t));else if("dot"===l);else if("text_segment"===l){if("strict"===r)throw new Error(Si`Use of "\X" requires non-strict accuracy`);const e="\\p{Emoji}(?:\\p{EMod}|\\uFE0F\\u20E3?|[\\x{E0020}-\\x{E007E}]+\\x{E007F})?",s=Si`\p{RI}{2}|${e}(?:\u200D${e})*`;n(ga(ha(Si`(?>\r\n|${o?Si`\p{RGI_Emoji}`:s}|\P{M}\p{M}*)`,{skipPropertyNameValidation:!0}),t))}else if("hex"===l)n(fa(js("AHex",{negate:c}),t));else if("newline"===l)n(ga(ha(c?"[^\n]":"(?>\r\n?|[\n\v\f\x85\u2028\u2029])"),t));else if("posix"===l)if(o||"graph"!==u&&"print"!==u)n(ga(pa(ha(Gi.get(u)),c),t));else{if("strict"===r)throw new Error(`POSIX class "${u}" requires min target ES2024 or non-strict accuracy`);let e={graph:"!-~",print:" -~"}[u];c&&(e=`\0-${xi(e.codePointAt(0)-1)}${xi(e.codePointAt(2)+1)}-\udbff\udfff`),n(ga(ha(`[${e}]`),t))}else if("property"===l)ji.has(qs(u))||(e.key="sc");else if("space"===l)n(fa(js("space",{negate:c}),t));else{if("word"!==l)throw new Error(`Unexpected character set kind "${l}"`);n(ga(pa(ha(Ri),c),t))}else n(fa(Es("word",{negate:c}),t));else n(ga(pa(ha("[\t-\r ]"),c),t));else n(fa(Es("digit",{negate:c}),t))},Directive({node:e,parent:t,root:n,remove:r,replaceWith:o,removeAllPrevSiblings:s,removeAllNextSiblings:i}){const{kind:a,flags:l}=e;if("flags"===a)if(l.enable||l.disable){const e=Ns({flags:l});e.body[0].body=i(),o(ga(e,t),{traverse:!0})}else r();else{if("keep"!==a)throw new Error(`Unexpected directive kind "${a}"`);{const e=n.body[0],r=1===n.body.length&&as(e,{type:"Group"})&&1===e.body[0].body.length?e.body[0]:n;if(t.parent!==r||r.body.length>1)throw new Error(Si`Uses "\K" in a way that's unsupported`);const i=Ps({behind:!0});i.body[0].body=s(),o(ga(i,t))}}},Flags({node:e,parent:t}){if(e.posixIsAscii)throw new Error("Unsupported flag \"P\"");if("word"===e.textSegmentMode)throw new Error("Unsupported flag \"y{w}\"");["digitIsAscii","extended","posixIsAscii","spaceIsAscii","wordIsAscii","textSegmentMode"].forEach(t=>delete e[t]),Object.assign(e,{global:!1,hasIndices:!1,multiline:!1,sticky:e.sticky??!1}),t.options={disable:{x:!0,n:!0},force:{v:!0}}},Group({node:e}){if(!e.flags)return;const{enable:t,disable:n}=e.flags;t?.extended&&delete t.extended,n?.extended&&delete n.extended,t?.dotAll&&n?.dotAll&&delete t.dotAll,t?.ignoreCase&&n?.ignoreCase&&delete t.ignoreCase,t&&!Object.keys(t).length&&delete e.flags.enable,n&&!Object.keys(n).length&&delete e.flags.disable,!e.flags.enable&&!e.flags.disable&&delete e.flags},LookaroundAssertion({node:e},t){const{kind:n}=e;"lookbehind"===n&&(t.passedLookbehind=!0)},NamedCallout({node:e,parent:t,replaceWith:n}){const{kind:r}=e;if("fail"!==r)throw new Error(`Unsupported named callout "(*${r.toUpperCase()}"`);n(ga(Ps({negate:!0}),t))},Quantifier({node:e}){if("Quantifier"===e.body.type){const t=Ns();t.body[0].body.push(e.body),e.body=ga(t,e)}},Regex:{enter({node:e},{supportedGNodes:t}){const n=[];let r=!1,o=!1;for(const t of e.body)if(1===t.body.length&&"search_start"===t.body[0].kind)t.body.pop();else{const e=ia(t.body);e?(r=!0,Array.isArray(e)?n.push(...e):n.push(e)):o=!0}r&&!o&&n.forEach(e=>t.add(e))},exit(e,{accuracy:t,passedLookbehind:n,strategy:r}){if("strict"===t&&n&&r)throw new Error(Si`Uses "\G" in a way that requires non-strict accuracy`)}},Subroutine({node:e},{jsGroupNameMap:t}){let{ref:n}=e;"string"!=typeof n||da(n)||(n=na(n,t),e.ref=n)}},Xi={Backreference({node:e},{multiplexCapturesToLeftByRef:t,reffedNodesByReferencer:n}){const{orphan:r,ref:o}=e;r||n.set(e,[...t.get(o).map(({node:e})=>e)])},CapturingGroup:{enter({node:e,parent:t,replaceWith:n,skip:r},{groupOriginByCopy:o,groupsByName:s,multiplexCapturesToLeftByRef:i,openRefs:a,reffedNodesByReferencer:l}){const c=o.get(e);if(c&&a.has(e.number)){const r=fa(ea(e.number),t);return l.set(r,a.get(e.number)),void n(r)}a.set(e.number,e),i.set(e.number,[]),e.name&&Li(i,e.name,[]);const u=i.get(e.name??e.number);for(let t=0;t<u.length;t++){const n=u[t];if(c===n.node||c&&c===n.origin||e===n.origin){u.splice(t,1);break}}if(i.get(e.number).push({node:e,origin:c}),e.name&&i.get(e.name).push({node:e,origin:c}),e.name){const t=Li(s,e.name,new Map);let n=!1;if(c)n=!0;else for(const e of t.values())if(!e.hasDuplicateNameToRemove){n=!0;break}s.get(e.name).set(e,{node:e,hasDuplicateNameToRemove:n})}},exit({node:e},{openRefs:t}){t.get(e.number)===e&&t.delete(e.number)}},Group:{enter({node:e},t){t.prevFlags=t.currentFlags,e.flags&&(t.currentFlags=Ei(t.currentFlags,e.flags))},exit(e,t){t.currentFlags=t.prevFlags}},Subroutine({node:e,parent:t,replaceWith:n},r){const{isRecursive:o,ref:s}=e;if(o){let n=t;for(;(n=n.parent)&&("CapturingGroup"!==n.type||n.name!==s&&n.number!==s););return void r.reffedNodesByReferencer.set(e,n)}const i=r.subroutineRefMap.get(s),a=0===s,l=a?ea(0):Yi(i,r.groupOriginByCopy,null);let c=l;if(!a){const e=ra(ta(i,e=>"Group"===e.type&&!!e.flags)),t=e?Ei(r.globalFlags,e):r.globalFlags;Ji(t,r.currentFlags)||(c=Ns({flags:oa(t)}),c.body[0].body.push(l))}n(ga(c,t),{traverse:!a})}},Ki={Backreference({node:e,parent:t,replaceWith:n},r){if(e.orphan)return void(r.highestOrphanBackref=Math.max(r.highestOrphanBackref,e.ref));const o=r.reffedNodesByReferencer.get(e).filter(t=>Qi(t,e));o.length?o.length>1?n(ga(Ns({atomic:!0,body:o.reverse().map(e=>ks({body:[vs(e.number)]}))}),t)):e.ref=o[0].number:n(ga(Ps({negate:!0}),t))},CapturingGroup({node:e},t){e.number=++t.numCapturesToLeft,e.name&&t.groupsByName.get(e.name).get(e).hasDuplicateNameToRemove&&delete e.name},Regex:{exit({node:e},t){const n=Math.max(t.highestOrphanBackref-t.numCapturesToLeft,0);for(let t=0;t<n;t++){const t=xs();e.body.at(-1).body.push(t)}}},Subroutine({node:e},t){e.isRecursive&&0!==e.ref&&(e.ref=t.reffedNodesByReferencer.get(e).number)}};function Zi(e){Xs(e,{"*"({node:e,parent:t}){e.parent=t}})}function Ji(e,t){return e.dotAll===t.dotAll&&e.ignoreCase===t.ignoreCase}function Qi(e,t){let n=t;do{if("Regex"===n.type)return!1;if("Alternative"===n.type)continue;if(n===e)return!1;const t=sa(n.parent);for(const r of t){if(r===n)break;if(r===e||aa(r,e))return!0}}while(n=n.parent);throw new Error("Unexpected path")}function Yi(e,t,n,r){const o=Array.isArray(e)?[]:{};for(const[s,i]of Object.entries(e))"parent"===s?o.parent=Array.isArray(n)?r:n:i&&"object"==typeof i?o[s]=Yi(i,t,o,n):("type"===s&&"CapturingGroup"===i&&t.set(o,t.get(e)??e),o[s]=i);return o}function ea(e){const t=Ms(e);return t.isRecursive=!0,t}function ta(e,t){const n=[];for(;e=e.parent;)t&&!t(e)||n.push(e);return n}function na(e,t){if(t.has(e))return t.get(e);const n=`$${t.size}_${e.replace(/^[^$_\p{IDS}]|[^$\u200C\u200D\p{IDC}]/gu,"_")}`;return t.set(e,n),n}function ra(e){const t=["dotAll","ignoreCase"],n={enable:{},disable:{}};return e.forEach(({flags:e})=>{t.forEach(t=>{e.enable?.[t]&&(delete n.disable[t],n.enable[t]=!0),e.disable?.[t]&&(n.disable[t]=!0)})}),Object.keys(n.enable).length||delete n.enable,Object.keys(n.disable).length||delete n.disable,n.enable||n.disable?n:null}function oa({dotAll:e,ignoreCase:t}){const n={};return(e||t)&&(n.enable={},e&&(n.enable.dotAll=!0),t&&(n.enable.ignoreCase=!0)),e&&t||(n.disable={},!e&&(n.disable.dotAll=!0),!t&&(n.disable.ignoreCase=!0)),n}function sa(e){if(!e)throw new Error("Node expected");const{body:t}=e;return Array.isArray(t)?t:t?[t]:null}function ia(e){const t=e.find(e=>"search_start"===e.kind||ua(e,{negate:!1})||!la(e));if(!t)return null;if("search_start"===t.kind)return t;if("LookaroundAssertion"===t.type)return t.body[0].body[0];if("CapturingGroup"===t.type||"Group"===t.type){const e=[];for(const n of t.body){const t=ia(n.body);if(!t)return null;Array.isArray(t)?e.push(...t):e.push(t)}return e}return null}function aa(e,t){const n=sa(e)??[];for(const e of n)if(e===t||aa(e,t))return!0;return!1}function la({type:e}){return"Assertion"===e||"Directive"===e||"LookaroundAssertion"===e}function ca(e){const t=["Character","CharacterClass","CharacterSet"];return t.includes(e.type)||"Quantifier"===e.type&&e.min&&t.includes(e.body.type)}function ua(e,t){const n=Object.assign({negate:null},t);return"LookaroundAssertion"===e.type&&(null===n.negate||e.negate===n.negate)&&1===e.body.length&&as(e.body[0],{type:"Assertion",kind:"search_start"})}function da(e){return/^[$_\p{IDS}][$\u200C\u200D\p{IDC}]*$/u.test(e)}function ha(e,t){const n=us(e,Object.assign({},t,{unicodePropertyMap:ji})).body;return n.length>1||n[0].body.length>1?Ns({body:n}):n[0].body[0]}function pa(e,t){return e.negate=t,e}function fa(e,t){return e.parent=t,e}function ga(e,t){return Zi(e),e.parent=t,e}function ma(e,t){const n=Ti(t),r=Ii(n.target,"ES2024"),o=Ii(n.target,"ES2025"),s=n.rules.recursionLimit;if(!Number.isInteger(s)||s<2||s>20)throw new Error("Invalid recursionLimit; use 2-20");let i=null,a=null;if(!o){const t=[e.flags.ignoreCase];Xs(e,ya,{getCurrentModI:()=>t.at(-1),popModI(){t.pop()},pushModI(e){t.push(e)},setHasCasedChar(){t.at(-1)?i=!0:a=!0}})}const l={dotAll:e.flags.dotAll,ignoreCase:!(!e.flags.ignoreCase&&!i||a)};let c=e;const u={accuracy:n.accuracy,appliedGlobalFlags:l,captureMap:new Map,currentFlags:{dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},inCharClass:!1,lastNode:c,originMap:e._originMap,recursionLimit:s,useAppliedIgnoreCase:!(o||!i||!a),useFlagMods:o,useFlagV:r,verbose:n.verbose};function d(e){return u.lastNode=c,c=e,Ni(ba[e.type],`Unexpected node type "${e.type}"`)(e,u,d)}const h={pattern:e.body.map(d).join("|"),flags:d(e.flags),options:Object.assign({},e.options)};return r||(delete h.options.force.v,h.options.disable.v=!0,h.options.unicodeSetsPlugin=null),h._captureTransfers=new Map,h._hiddenCaptures=[],u.captureMap.forEach((e,t)=>{e.hidden&&h._hiddenCaptures.push(t),e.transferTo&&Li(h._captureTransfers,e.transferTo,[]).push(t)}),h}var ya={"*":{enter({node:e},t){if(Na(e)){const n=t.getCurrentModI();t.pushModI(e.flags?Ei({ignoreCase:n},e.flags).ignoreCase:n)}},exit({node:e},t){Na(e)&&t.popModI()}},Backreference(e,t){t.setHasCasedChar()},Character({node:e},t){Sa(xi(e.value))&&t.setHasCasedChar()},CharacterClassRange({node:e,skip:t},n){t(),_a(e,{firstOnly:!0}).length&&n.setHasCasedChar()},CharacterSet({node:e},t){"property"===e.kind&&qi.has(e.value)&&t.setHasCasedChar()}},ba={Alternative:({body:e},t,n)=>e.map(n).join(""),Assertion({kind:e,negate:t}){if("string_end"===e)return"$";if("string_start"===e)return"^";if("word_boundary"===e)return t?Si`\B`:Si`\b`;throw new Error(`Unexpected assertion kind "${e}"`)},Backreference({ref:e},t){if("number"!=typeof e)throw new Error("Unexpected named backref in transformed AST");if(!t.useFlagMods&&"strict"===t.accuracy&&t.currentFlags.ignoreCase&&!t.captureMap.get(e).ignoreCase)throw new Error("Use of case-insensitive backref to case-sensitive group requires target ES2025 or non-strict accuracy");return"\\"+e},CapturingGroup(e,t,n){const{body:r,name:o,number:s}=e,i={ignoreCase:t.currentFlags.ignoreCase},a=t.originMap.get(e);return a&&(i.hidden=!0,s>a.number&&(i.transferTo=a.number)),t.captureMap.set(s,i),`(${o?`?<${o}>`:""}${r.map(n).join("|")})`},Character({value:e},t){const n=xi(e),r=Aa(e,{escDigit:"Backreference"===t.lastNode.type,inCharClass:t.inCharClass,useFlagV:t.useFlagV});if(r!==n)return r;if(t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&Sa(n)){const e=Mi(n);return t.inCharClass?e.join(""):e.length>1?`[${e.join("")}]`:e[0]}return n},CharacterClass(e,t,n){const{kind:r,negate:o,parent:s}=e;let{body:i}=e;if("intersection"===r&&!t.useFlagV)throw new Error("Use of character class intersection requires min target ES2024");_i.bugFlagVLiteralHyphenIsRange&&t.useFlagV&&i.some(Pa)&&(i=[Ss(45),...i.filter(e=>!Pa(e))]);const a=()=>`[${o?"^":""}${i.map(n).join("intersection"===r?"&&":"")}]`;if(!t.inCharClass){if((!t.useFlagV||_i.bugNestedClassIgnoresNegation)&&!o){const t=i.filter(e=>"CharacterClass"===e.type&&"union"===e.kind&&e.negate);if(t.length){const r=Ns(),o=r.body[0];return r.parent=s,o.parent=r,i=i.filter(e=>!t.includes(e)),e.body=i,i.length?(e.parent=o,o.body.push(e)):r.body.pop(),t.forEach(e=>{const t=ks({body:[e]});e.parent=t,t.parent=r,r.body.push(t)}),n(r)}}t.inCharClass=!0;const r=a();return t.inCharClass=!1,r}const l=i[0];if("union"===r&&!o&&l&&((!t.useFlagV||!t.verbose)&&"union"===s.kind&&(!_i.bugFlagVLiteralHyphenIsRange||!t.useFlagV)||!t.verbose&&"intersection"===s.kind&&1===i.length&&"CharacterClassRange"!==l.type))return i.map(n).join("");if(!t.useFlagV&&"CharacterClass"===s.type)throw new Error("Uses nested character class in a way that requires min target ES2024");return a()},CharacterClassRange(e,t){const n=e.min.value,r=e.max.value,o={escDigit:!1,inCharClass:!0,useFlagV:t.useFlagV},s=Aa(n,o),i=Aa(r,o),a=new Set;return t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&Ea(_a(e)).forEach(e=>{a.add(Array.isArray(e)?`${Aa(e[0],o)}-${Aa(e[1],o)}`:Aa(e,o))}),`${s}-${i}${[...a].join("")}`},CharacterSet({kind:e,negate:t,value:n,key:r},o){if("dot"===e)return o.currentFlags.dotAll?o.appliedGlobalFlags.dotAll||o.useFlagMods?".":"[^]":Si`[^\n]`;if("digit"===e)return t?Si`\D`:Si`\d`;if("property"===e){if(o.useAppliedIgnoreCase&&o.currentFlags.ignoreCase&&qi.has(n))throw new Error(`Unicode property "${n}" can't be case-insensitive when other chars have specific case`);return`${t?Si`\P`:Si`\p`}{${r?`${r}=`:""}${n}}`}if("word"===e)return t?Si`\W`:Si`\w`;throw new Error(`Unexpected character set kind "${e}"`)},Flags:(e,t)=>(t.appliedGlobalFlags.ignoreCase?"i":"")+(e.dotAll?"s":"")+(e.sticky?"y":""),Group({atomic:e,body:t,flags:n,parent:r},o,s){const i=o.currentFlags;n&&(o.currentFlags=Ei(i,n));const a=t.map(s).join("|"),l=o.verbose||1!==t.length||"Quantifier"===r.type||e||o.useFlagMods&&n?`(?${La(e,n,o.useFlagMods)}${a})`:a;return o.currentFlags=i,l},LookaroundAssertion:({body:e,kind:t,negate:n},r,o)=>`(?${"lookahead"===t?"":"<"}${n?"!":"="}${e.map(o).join("|")})`,Quantifier:(e,t,n)=>n(e.body)+Ia(e),Subroutine({isRecursive:e,ref:t},n){if(!e)throw new Error("Unexpected non-recursive subroutine in transformed AST");const r=n.recursionLimit;return 0===t?`(?R=${r})`:Si`\g<${t}&R=${r}>`}},wa=new Set(["$","(",")","*","+",".","?","[","\\","]","^","{","|","}"]),ka=new Set(["-","\\","]","^","["]),Ca=new Set(["(",")","-","/","[","\\","]","^","{","|","}","!","#","$","%","&","*","+",",",".",":",";","<","=",">","?","@","`","~"]),va=new Map([[9,Si`\t`],[10,Si`\n`],[11,Si`\v`],[12,Si`\f`],[13,Si`\r`],[8232,Si`\u2028`],[8233,Si`\u2029`],[65279,Si`\uFEFF`]]),xa=/^\p{Cased}$/u;function Sa(e){return xa.test(e)}function _a(e,t){const n=!!t?.firstOnly,r=e.min.value,o=e.max.value,s=[];if(r<65&&(65535===o||o>=131071)||65536===r&&o>=131071)return s;for(let e=r;e<=o;e++){const t=xi(e);if(!Sa(t))continue;const i=Mi(t).filter(e=>{const t=e.codePointAt(0);return t<r||t>o});if(i.length&&(s.push(...i),n))break}return s}function Aa(e,{escDigit:t,inCharClass:n,useFlagV:r}){if(va.has(e))return va.get(e);if(e<32||e>126&&e<160||e>262143||t&&((o=e)>47&&o<58))return e>255?`\\u{${e.toString(16).toUpperCase()}}`:`\\x${e.toString(16).toUpperCase().padStart(2,"0")}`;var o;const s=n?r?Ca:ka:wa,i=xi(e);return(s.has(i)?"\\":"")+i}function Ea(e){const t=e.map(e=>e.codePointAt(0)).sort((e,t)=>e-t),n=[];let r=null;for(let e=0;e<t.length;e++)t[e+1]===t[e]+1?r??=t[e]:null===r?n.push(t[e]):(n.push([r,t[e]]),r=null);return n}function La(e,t,n){if(e)return">";let r="";if(t&&n){const{enable:e,disable:n}=t;r=(e?.ignoreCase?"i":"")+(e?.dotAll?"s":"")+(n?"-":"")+(n?.ignoreCase?"i":"")+(n?.dotAll?"s":"")}return`${r}:`}function Ia({kind:e,max:t,min:n}){let r;return r=n||1!==t?n||t!==1/0?1===n&&t===1/0?"+":n===t?`{${n}}`:`{${n},${t===1/0?"":t}}`:"*":"?",r+{greedy:"",lazy:"?",possessive:"+"}[e]}function Na({type:e}){return"CapturingGroup"===e||"Group"===e||"LookaroundAssertion"===e}function Pa({type:e,value:t}){return"Character"===e&&45===t}var Oa=(a=f("captureMap"),l=f("compiled"),c=f("pattern"),u=f("nameMap"),d=f("strategy"),h=f("execCore"),class e extends RegExp{get source(){return p(this,c)[c]||"(?:)"}constructor(t,n,r){const o=!!r?.lazyCompile;if(t instanceof RegExp){if(r)throw new Error("Cannot provide options when copying a regexp");const o=t;super(o,n),Object.defineProperty(this,h,{value:Ta}),Object.defineProperty(this,a,{writable:!0,value:new Map}),Object.defineProperty(this,l,{writable:!0,value:null}),Object.defineProperty(this,c,{writable:!0,value:void 0}),Object.defineProperty(this,u,{writable:!0,value:null}),Object.defineProperty(this,d,{writable:!0,value:null}),this.rawOptions={},p(this,c)[c]=o.source,o instanceof e&&(p(this,a)[a]=p(o,a)[a],p(this,u)[u]=p(o,u)[u],p(this,d)[d]=p(o,d)[d],this.rawOptions=o.rawOptions)}else{const e=Object.assign({hiddenCaptures:[],strategy:null,transfers:[]},r);super(o?"":t,n),Object.defineProperty(this,h,{value:Ta}),Object.defineProperty(this,a,{writable:!0,value:new Map}),Object.defineProperty(this,l,{writable:!0,value:null}),Object.defineProperty(this,c,{writable:!0,value:void 0}),Object.defineProperty(this,u,{writable:!0,value:null}),Object.defineProperty(this,d,{writable:!0,value:null}),this.rawOptions={},p(this,c)[c]=t,p(this,a)[a]=Ra(e.hiddenCaptures,e.transfers),p(this,d)[d]=e.strategy,this.rawOptions=r??{}}o||(p(this,l)[l]=this)}exec(t){if(!p(this,l)[l]){const t=this.rawOptions,n=g(t,y);p(this,l)[l]=new e(p(this,c)[c],this.flags,n)}const n=this.global||this.sticky,r=this.lastIndex;if("clip_search"===p(this,d)[d]&&n&&r){this.lastIndex=0;const e=p(this,h)[h](t.slice(r));return e&&($a(e,r,t,this.hasIndices),this.lastIndex+=r),e}return p(this,h)[h](t)}});function Ta(e){p(this,l)[l].lastIndex=this.lastIndex;const t=RegExp.prototype.exec.call(p(this,l)[l],e);if(this.lastIndex=p(this,l)[l].lastIndex,!t||!p(this,a)[a].size)return t;const n=[...t];let r;t.length=1,this.hasIndices&&(r=[...t.indices],t.indices.length=1);const o=[0];for(let e=1;e<n.length;e++){const{hidden:s,transferTo:i}=p(this,a)[a].get(e)??{};if(s?o.push(null):(o.push(t.length),t.push(n[e]),this.hasIndices&&t.indices.push(r[e])),i&&void 0!==n[e]){const s=o[i];if(!s)throw new Error(`Invalid capture transfer to "${s}"`);if(t[s]=n[e],this.hasIndices&&(t.indices[s]=r[e]),t.groups){p(this,u)[u]||(p(this,u)[u]=Ma(this.source));const o=p(this,u)[u].get(i);o&&(t.groups[o]=n[e],this.hasIndices&&(t.indices.groups[o]=r[e]))}}}return t}function $a(e,t,n,r){if(e.index+=t,e.input=n,r){const n=e.indices;for(let e=0;e<n.length;e++){const r=n[e];r&&(n[e]=[r[0]+t,r[1]+t])}const r=n.groups;r&&Object.keys(r).forEach(e=>{const n=r[e];n&&(r[e]=[n[0]+t,n[1]+t])})}}function Ra(e,t){const n=new Map;for(const t of e)n.set(t,{hidden:!0});for(const[e,r]of t)for(const t of r)Li(n,t,{}).transferTo=e;return n}function Ma(e){const t=/(?<capture>\((?:\?<(?![=!])(?<name>[^>]+)>|(?!\?)))|\\?./gsu,n=new Map;let r,o=0,s=0;for(;r=t.exec(e);){const{0:e,groups:{capture:t,name:i}}=r;"["===e?o++:o?"]"===e&&o--:t&&(s++,i&&n.set(s,i))}return n}function ja(e,t){const n=Da(e,t);return n.options?new Oa(n.pattern,n.flags,n.options):new RegExp(n.pattern,n.flags)}function Da(e,t){const n=Ti(t),r=Hi(us(e,{flags:n.flags,normalizeUnknownPropertyNames:!0,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline},skipBackrefValidation:n.rules.allowOrphanBackrefs,unicodePropertyMap:ji}),{accuracy:n.accuracy,asciiWordBoundaries:n.rules.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,bestEffortTarget:n.target}),o=ma(r,n),s=yi(o.pattern,{captureTransfers:o._captureTransfers,hiddenCaptures:o._hiddenCaptures,mode:"external"}),i=ai(ui(s.pattern).pattern,{captureTransfers:s.captureTransfers,hiddenCaptures:s.hiddenCaptures}),a={pattern:i.pattern,flags:`${n.hasIndices?"d":""}${n.global?"g":""}${o.flags}${o.options.disable.v?"u":"v"}`};if(n.avoidSubclass){if(n.lazyCompileLength!==1/0)throw new Error("Lazy compilation requires subclass")}else{const e=i.hiddenCaptures.sort((e,t)=>e-t),t=Array.from(i.captureTransfers),o=r._strategy,s=a.pattern.length>=n.lazyCompileLength;(e.length||t.length||o||s)&&(a.options=Object.assign({},e.length&&{hiddenCaptures:e},t.length&&{transfers:t},o&&{strategy:o},s&&{lazyCompile:s}))}return a}function Ba(e,t){return ja(e,Object.assign({global:!0,hasIndices:!0,lazyCompileLength:3e3,rules:{allowOrphanBackrefs:!0,asciiWordBoundaries:!0,captureGroup:!0,recursionLimit:5,singleline:!0}},t))}function Fa(e={}){const t=Object.assign({target:"auto",cache:new Map},e);return t.regexConstructor||=e=>Ba(e,{target:t.target}),{createScanner:e=>new mo(e,t),createString:e=>({content:e})}}var Ga=k({createOnigurumaEngine:()=>hl,getDefaultWasmLoader:()=>dl,loadWasm:()=>al,setDefaultWasmLoader:()=>ul}),Ua=class extends Error{constructor(e){super(e),this.name="ShikiError"}};function Wa(){return"undefined"!=typeof performance?performance.now():Date.now()}const za=(e,t)=>e+(t-e%t)%t;async function qa(e){let t,n;const r={};function o(e){n=e,r.HEAPU8=new Uint8Array(e),r.HEAPU32=new Uint32Array(e)}function s(e){try{return t.grow(e-n.byteLength+65535>>>16),o(t.buffer),1}catch{}}const i="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function a(e,t,n=1024){const r=t+n;let o=t;for(;e[o]&&!(o>=r);)++o;if(o-t>16&&e.buffer&&i)return i.decode(e.subarray(t,o));let s="";for(;t<o;){let n=e[t++];if(!(128&n)){s+=String.fromCharCode(n);continue}const r=63&e[t++];if(192==(224&n)){s+=String.fromCharCode((31&n)<<6|r);continue}const o=63&e[t++];if(n=224==(240&n)?(15&n)<<12|r<<6|o:(7&n)<<18|r<<12|o<<6|63&e[t++],n<65536)s+=String.fromCharCode(n);else{const e=n-65536;s+=String.fromCharCode(55296|e>>10,56320|1023&e)}}return s}function l(e,t){return e?a(r.HEAPU8,e,t):""}const c={emscripten_get_now:Wa,emscripten_memcpy_big:function(e,t,n){r.HEAPU8.copyWithin(e,t,t+n)},emscripten_resize_heap:function(e){const t=r.HEAPU8.length,n=2147483648;if((e>>>=0)>n)return!1;for(let r=1;r<=4;r*=2){let o=t*(1+.2/r);if(o=Math.min(o,e+100663296),s(Math.min(n,za(Math.max(e,o),65536))))return!0}return!1},fd_write:()=>0};return await(async function(){const n=await e({env:c,wasi_snapshot_preview1:c});t=n.memory,o(t.buffer),Object.assign(r,n),r.UTF8ToString=l})(),r}var Ha=Object.defineProperty,Va=(e,t,n)=>t in e?Ha(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Xa=(e,t,n)=>Va(e,"symbol"!=typeof t?t+"":t,n);let Ka=null;function Za(e){throw new Ua(e.UTF8ToString(e.getLastOnigError()))}var Ja=class e{constructor(t){Xa(this,"utf16Length"),Xa(this,"utf8Length"),Xa(this,"utf16Value"),Xa(this,"utf8Value"),Xa(this,"utf16OffsetToUtf8"),Xa(this,"utf8OffsetToUtf16");const n=t.length,r=e._utf8ByteLength(t),o=r!==n,s=o?new Uint32Array(n+1):null;o&&(s[n]=r);const i=o?new Uint32Array(r+1):null;o&&(i[r]=n);const a=new Uint8Array(r);let l=0;for(let e=0;e<n;e++){const r=t.charCodeAt(e);let c=r,u=!1;if(r>=55296&&r<=56319&&e+1<n){const n=t.charCodeAt(e+1);n>=56320&&n<=57343&&(c=65536+(r-55296<<10)|n-56320,u=!0)}o&&(s[e]=l,u&&(s[e+1]=l),c<=127?i[l+0]=e:c<=2047?(i[l+0]=e,i[l+1]=e):c<=65535?(i[l+0]=e,i[l+1]=e,i[l+2]=e):(i[l+0]=e,i[l+1]=e,i[l+2]=e,i[l+3]=e)),c<=127?a[l++]=c:c<=2047?(a[l++]=192|(1984&c)>>>6,a[l++]=128|(63&c)>>>0):c<=65535?(a[l++]=224|(61440&c)>>>12,a[l++]=128|(4032&c)>>>6,a[l++]=128|(63&c)>>>0):(a[l++]=240|(1835008&c)>>>18,a[l++]=128|(258048&c)>>>12,a[l++]=128|(4032&c)>>>6,a[l++]=128|(63&c)>>>0),u&&e++}this.utf16Length=n,this.utf8Length=r,this.utf16Value=t,this.utf8Value=a,this.utf16OffsetToUtf8=s,this.utf8OffsetToUtf16=i}static _utf8ByteLength(e){let t=0;for(let n=0,r=e.length;n<r;n++){const o=e.charCodeAt(n);let s=o,i=!1;if(o>=55296&&o<=56319&&n+1<r){const t=e.charCodeAt(n+1);t>=56320&&t<=57343&&(s=65536+(o-55296<<10)|t-56320,i=!0)}t+=s<=127?1:s<=2047?2:s<=65535?3:4,i&&n++}return t}createString(e){const t=e.omalloc(this.utf8Length);return e.HEAPU8.set(this.utf8Value,t),t}};const Qa=class e{constructor(t){if(Xa(this,"id",++e.LAST_ID),Xa(this,"_onigBinding"),Xa(this,"content"),Xa(this,"utf16Length"),Xa(this,"utf8Length"),Xa(this,"utf16OffsetToUtf8"),Xa(this,"utf8OffsetToUtf16"),Xa(this,"ptr"),!Ka)throw new Ua("Must invoke loadWasm first.");this._onigBinding=Ka,this.content=t;const n=new Ja(t);this.utf16Length=n.utf16Length,this.utf8Length=n.utf8Length,this.utf16OffsetToUtf8=n.utf16OffsetToUtf8,this.utf8OffsetToUtf16=n.utf8OffsetToUtf16,this.utf8Length<1e4&&!e._sharedPtrInUse?(e._sharedPtr||(e._sharedPtr=Ka.omalloc(1e4)),e._sharedPtrInUse=!0,Ka.HEAPU8.set(n.utf8Value,e._sharedPtr),this.ptr=e._sharedPtr):this.ptr=n.createString(Ka)}convertUtf8OffsetToUtf16(e){return this.utf8OffsetToUtf16?e<0?0:e>this.utf8Length?this.utf16Length:this.utf8OffsetToUtf16[e]:e}convertUtf16OffsetToUtf8(e){return this.utf16OffsetToUtf8?e<0?0:e>this.utf16Length?this.utf8Length:this.utf16OffsetToUtf8[e]:e}dispose(){this.ptr===e._sharedPtr?e._sharedPtrInUse=!1:this._onigBinding.ofree(this.ptr)}};Xa(Qa,"LAST_ID",0),Xa(Qa,"_sharedPtr",0),Xa(Qa,"_sharedPtrInUse",!1);let Ya=Qa;var el=class{constructor(e){if(Xa(this,"_onigBinding"),Xa(this,"_ptr"),!Ka)throw new Ua("Must invoke loadWasm first.");const t=[],n=[];for(let r=0,o=e.length;r<o;r++){const o=new Ja(e[r]);t[r]=o.createString(Ka),n[r]=o.utf8Length}const r=Ka.omalloc(4*e.length);Ka.HEAPU32.set(t,r/4);const o=Ka.omalloc(4*e.length);Ka.HEAPU32.set(n,o/4);const s=Ka.createOnigScanner(r,o,e.length);for(let n=0,r=e.length;n<r;n++)Ka.ofree(t[n]);Ka.ofree(o),Ka.ofree(r),0===s&&Za(Ka),this._onigBinding=Ka,this._ptr=s}dispose(){this._onigBinding.freeOnigScanner(this._ptr)}findNextMatchSync(e,t,n){let r=0;if("number"==typeof n&&(r=n),"string"==typeof e){e=new Ya(e);const n=this._findNextMatchSync(e,t,!1,r);return e.dispose(),n}return this._findNextMatchSync(e,t,!1,r)}_findNextMatchSync(e,t,n,r){const o=this._onigBinding,s=o.findNextOnigScannerMatch(this._ptr,e.id,e.ptr,e.utf8Length,e.convertUtf16OffsetToUtf8(t),r);if(0===s)return null;const i=o.HEAPU32;let a=s/4;const l=i[a++],c=i[a++],u=[];for(let t=0;t<c;t++){const n=e.convertUtf8OffsetToUtf16(i[a++]),r=e.convertUtf8OffsetToUtf16(i[a++]);u[t]={start:n,end:r,length:r-n}}return{index:l,captureIndices:u}}};function tl(e){return"function"==typeof e.default}function nl(e){return void 0!==e.data}function rl(e){return"undefined"!=typeof Response&&e instanceof Response}function ol(e){return"undefined"!=typeof ArrayBuffer&&(e instanceof ArrayBuffer||ArrayBuffer.isView(e))||"undefined"!=typeof Buffer&&Buffer.isBuffer?.(e)||"undefined"!=typeof SharedArrayBuffer&&e instanceof SharedArrayBuffer||"undefined"!=typeof Uint32Array&&e instanceof Uint32Array}let sl,il;function al(e){if(sl)return sl;return sl=(async function(){Ka=await qa(async t=>{let n=e;var r;return n=await n,"function"==typeof n&&(n=await n(t)),"function"==typeof n&&(n=await n(t)),"function"==typeof n.instantiator?n=await n.instantiator(t):tl(n)?n=await n.default(t):(nl(n)&&(n=n.data),rl(n)?n="function"==typeof WebAssembly.instantiateStreaming?await(r=n,e=>WebAssembly.instantiateStreaming(r,e))(t):await cl(n)(t):ol(n)||n instanceof WebAssembly.Module?n=await ll(n)(t):"default"in n&&n.default instanceof WebAssembly.Module&&(n=await ll(n.default)(t))),"instance"in n&&(n=n.instance),"exports"in n&&(n=n.exports),n})})(),sl}function ll(e){return t=>WebAssembly.instantiate(e,t)}function cl(e){return async t=>{const n=await e.arrayBuffer();return WebAssembly.instantiate(n,t)}}function ul(e){il=e}function dl(){return il}async function hl(e){return e&&await al(e),{createScanner:e=>new el(e.map(e=>"string"==typeof e?e:e.source)),createString:e=>new Ya(e)}}var pl,fl;A(_({}),pl=Ga,"default"),fl&&A(fl,pl,"default"),(()=>{try{return!1}catch{return!1}})();const gl={dark:"pierre-dark",light:"pierre-light"};Object.freeze({fromStart:0,fromEnd:0});const ml=new Map,yl=new Set;function bl(e,t){e=Array.isArray(e)?e:[e];for(const n of e){if(yl.has(n.name))continue;let e=ml.get(n.name);null==e&&(e=n,ml.set(n.name,e));const r=e.data.find(t=>t.name===e.name||!0===t.aliases?.includes(e.name));if(null==r)throw new Error(`attachResolvedLanguages: No returned grammar declares "${e.name}" as its name or an alias.`);t.loadLanguageSync(e.data);try{t.getLanguage(e.name)}catch{throw new Error(`attachResolvedLanguages: "${r.name}" is already loaded without alias "${e.name}". Load the alias first or give the grammar a unique name.`)}yl.add(e.name)}}const wl=new Set;var kl=class extends Error{constructor(e){super(`Theme "${e}" is already registered`),this.name="DuplicateThemeError"}},Cl=class extends Error{constructor(e){super(`No loader registered for theme "${e}"`),this.name="UnregisteredThemeError"}},vl=class extends Error{constructor(e){super(`Theme "${e}" has not been resolved`),this.name="UnresolvedThemeError"}};const xl=(function(){const e=new Map,t=new Map,n=new Map;let r=0;function o(o){const s=t.get(o);if(void 0!==s)return Promise.resolve(s);const i=n.get(o);if(void 0!==i)return i;const a=e.get(o);if(void 0===a)return Promise.reject(new Cl(o));const l=r,c=a().then(e=>{const s=null!==(i=e)&&"object"==typeof i&&"default"in i?i.default:i;var i;return l===r&&t.set(o,s),n.get(o)===c&&n.delete(o),s}).catch(e=>{throw n.get(o)===c&&n.delete(o),e});return n.set(o,c),c}function s(e,n){t.set(e,n)}return{clearResolvedThemes:function(){r++,t.clear(),n.clear()},getResolvedOrResolveTheme:function(e){const n=t.get(e);return void 0!==n?n:o(e)},getResolvedTheme:function(e){return t.get(e)},getResolvedThemes:function(e){const n=[];for(const r of e){const e=t.get(r);if(void 0===e)throw new vl(r);n.push(e)}return n},hasRegisteredTheme:function(t){return e.has(t)},hasResolvedTheme:function(e){return t.has(e)},hasResolvedThemes:function(e){for(const n of e)if(!t.has(n))return!1;return!0},registerTheme:function(t,n){if(e.has(t))throw new kl(t);e.set(t,n)},registerThemeIfAbsent:function(t,n){return!e.has(t)&&(e.set(t,n),!0)},resolveTheme:o,resolveThemes:function(e){return Promise.all(e.map(e=>o(e)))},seedResolvedTheme:s,seedResolvedThemes:function(e){for(const[t,n]of e)s(t,n)}}})();function Sl(e,t){e=Array.isArray(e)?e:[e];for(let n of e){let e;if("string"==typeof n){if(e=xl.getResolvedTheme(n),null==e)throw new Error(`loadResolvedThemes: ${n} is not resolved, you must resolve it before calling loadResolvedThemes`)}else e=n,n=n.name,null==xl.getResolvedTheme(n)&&xl.seedResolvedTheme(n,e);wl.has(n)||(wl.add(n),t.loadThemeSync(e))}}const _l=new Map;let Al=0;const El={"1c":"1c",abap:"abap",as:"actionscript-3",ada:"ada",adb:"ada",ads:"ada",adoc:"asciidoc",asciidoc:"asciidoc","component.html":"angular-html","component.ts":"angular-ts",conf:"nginx",htaccess:"apache",cls:"tex",trigger:"apex",apl:"apl",applescript:"applescript",scpt:"applescript",ara:"ara",asm:"asm",s:"riscv",astro:"astro",awk:"awk",bal:"ballerina",sh:"zsh",bash:"zsh",bat:"cmd",cmd:"cmd",be:"berry",beancount:"beancount",bib:"bibtex",bicep:"bicep","blade.php":"blade",bsl:"bsl",c:"c",h:"objective-cpp",cs:"csharp",cpp:"cpp",hpp:"cpp",cc:"cpp",cxx:"cpp",hh:"cpp",cdc:"cdc",cairo:"cairo",clar:"clarity",clj:"clojure",cljs:"clojure",cljc:"clojure",soy:"soy",cmake:"cmake","CMakeLists.txt":"cmake",cob:"cobol",cbl:"cobol",cobol:"cobol",CODEOWNERS:"codeowners",ql:"ql",coffee:"coffeescript",lisp:"lisp",cl:"lisp",lsp:"lisp",log:"log",v:"verilog",cql:"cql",cr:"crystal",css:"css",csv:"csv",cue:"cue",cypher:"cypher",cyp:"cypher",d:"d",dart:"dart",dax:"dax",desktop:"desktop",diff:"diff",patch:"diff",Dockerfile:"dockerfile",dockerfile:"dockerfile",env:"dotenv",dm:"dream-maker",edge:"edge",el:"emacs-lisp",ex:"elixir",exs:"elixir",elm:"elm",erb:"erb",erl:"erlang",hrl:"erlang",f:"fortran-fixed-form",for:"fortran-fixed-form",fs:"fsharp",fsi:"fsharp",fsx:"fsharp",f03:"f03",f08:"f08",f18:"f18",f77:"f77",f90:"fortran-free-form",f95:"fortran-free-form",fnl:"fennel",fish:"fish",ftl:"ftl",tres:"gdresource",res:"gdresource",gd:"gdscript",gdshader:"gdshader",gs:"genie",feature:"gherkin",COMMIT_EDITMSG:"git-commit","git-rebase-todo":"git-rebase",gjs:"glimmer-js",gleam:"gleam",gts:"glimmer-ts",glsl:"glsl",vert:"glsl",frag:"glsl",shader:"shaderlab",gp:"gnuplot",plt:"gnuplot",gnuplot:"gnuplot",go:"go",graphql:"graphql",gql:"graphql",groovy:"groovy",gvy:"groovy",hack:"hack",haml:"haml",hbs:"handlebars",handlebars:"handlebars",hs:"haskell",lhs:"haskell",hx:"haxe",hcl:"hcl",hjson:"hjson",hlsl:"hlsl",fx:"hlsl",html:"html",htm:"html",http:"http",rest:"http",hxml:"hxml",hy:"hy",imba:"imba",ini:"ini",cfg:"ini",jade:"pug",pug:"pug",java:"java",js:"javascript",mjs:"javascript",cjs:"javascript",jinja:"jinja",jinja2:"jinja",j2:"jinja",jison:"jison",jl:"julia",json:"json",json5:"json5",jsonc:"jsonc",jsonl:"jsonl",jsonnet:"jsonnet",libsonnet:"jsonnet",jssm:"jssm",jsx:"jsx",kt:"kotlin",kts:"kts",kql:"kusto",tex:"tex",ltx:"tex",lean:"lean4",less:"less",liquid:"liquid",lit:"lit",ll:"llvm",logo:"logo",lua:"lua",luau:"luau",Makefile:"makefile",mk:"makefile",makefile:"makefile",md:"markdown",markdown:"markdown",marko:"marko",m:"wolfram",mat:"matlab",mdc:"mdc",mdx:"mdx",wiki:"wikitext",mediawiki:"wikitext",mmd:"mermaid",mermaid:"mermaid",mips:"mipsasm",mojo:"mojo","\ud83d\udd25":"mojo",move:"move",nar:"narrat",nf:"nextflow",nim:"nim",nims:"nim",nimble:"nim",nix:"nix",nu:"nushell",mm:"objective-cpp",ml:"ocaml",mli:"ocaml",mll:"ocaml",mly:"ocaml",odin:"odin",pas:"pascal",p:"pascal",pl:"prolog",pm:"perl",t:"perl",raku:"raku",p6:"raku",pl6:"raku",php:"php",phtml:"php",pls:"plsql",sql:"sql",po:"po",polar:"polar",pcss:"postcss",pot:"pot",potx:"potx",pq:"powerquery",pqm:"powerquery",ps1:"powershell",psm1:"powershell",psd1:"powershell",prisma:"prisma",pro:"prolog",P:"prolog",properties:"properties",proto:"protobuf",pp:"puppet",purs:"purescript",py:"python",pyw:"python",pyi:"python",BUCK:"python",BUILD:"python",PACKAGE:"python",WORKSPACE:"python",Tiltfile:"python",bazel:"python",bxl:"python",bzl:"python",bzlmod:"python",star:"python",sky:"python",qml:"qml",qmldir:"qmldir",qss:"qss",r:"r",R:"r",rkt:"racket",rktl:"racket",razor:"razor",cshtml:"razor",rb:"ruby",rbw:"ruby",reg:"reg",regex:"regexp",rel:"rel",rs:"rust",rst:"rst",rake:"ruby",gemspec:"ruby",jbuilder:"ruby",builder:"ruby",rabl:"ruby",arb:"ruby",ru:"ruby",podspec:"ruby",Gemfile:"ruby",Rakefile:"ruby",Guardfile:"ruby",Capfile:"ruby",Berksfile:"ruby",Brewfile:"ruby",Vagrantfile:"ruby",Thorfile:"ruby",Appraisals:"ruby",Dangerfile:"ruby",sas:"sas",sass:"sass",scala:"scala",sc:"scala",scm:"scheme",ss:"scheme",sld:"scheme",scss:"scss",sdbl:"sdbl",shadergraph:"shader",st:"smalltalk",sol:"solidity",sparql:"sparql",rq:"sparql",spl:"splunk",config:"ssh-config",do:"stata",ado:"stata",dta:"stata",styl:"stylus",stylus:"stylus",svelte:"svelte",swift:"swift",sv:"system-verilog",svh:"system-verilog",service:"systemd",socket:"systemd",device:"systemd",timer:"systemd",talon:"talonscript",tasl:"tasl",tcl:"tcl",templ:"templ",tf:"tf",tfvars:"tfvars",toml:"toml",ts:"typescript",mts:"typescript",cts:"typescript",tsp:"typespec",tsv:"tsv",tsx:"tsx",ttl:"turtle",twig:"twig",typ:"typst",vv:"v",vala:"vala",vapi:"vala",vb:"vb",vbs:"vb",bas:"vb",vh:"verilog",vhd:"vhdl",vhdl:"vhdl",vim:"vimscript",vue:"vue","vine.ts":"vue-vine",vy:"vyper",wasm:"wasm",wat:"wasm",wy:"\u6587\u8a00",wgsl:"wgsl",wit:"wit",wl:"wolfram",nb:"wolfram",xml:"xml",xsl:"xsl",xslt:"xsl",yaml:"yaml",yml:"yml",zs:"zenscript",zig:"zig",zsh:"zsh",sty:"tex"};function Ll(e){const t=Il(e);if(null!=t)return t;const n=e.split(/[/\\]/).pop()??e;return n===e?"text":Il(n)??"text"}function Il(e){if(_l.has(e))return _l.get(e)??"text";if(Object.hasOwn(El,e))return El[e]??null;const t=e.match(/\.([^/\\]+\.[^/\\]+)$/);if(null!=t){if(_l.has(t[1]))return _l.get(t[1])??"text";if(Object.hasOwn(El,t[1]))return El[t[1]]??"text"}const n=e.match(/\.([^.]+)$/)?.[1]??"";return _l.has(n)?_l.get(n)??"text":Object.hasOwn(El,n)?El[n]??"text":null}function Nl(e,t){if(e<=Al)return!1;_l.clear();for(const e in t){const n=t[e];null!=n&&_l.set(e,n)}return Al=e,!0}var Pl=class{diff(e,t,n={}){let r;"function"==typeof n?(r=n,n={}):"callback"in n&&(r=n.callback);const o=this.castInput(e,n),s=this.castInput(t,n),i=this.removeEmpty(this.tokenize(o,n)),a=this.removeEmpty(this.tokenize(s,n));return this.diffWithOptionsObj(i,a,n,r)}diffWithOptionsObj(e,t,n,r){var o;const s=e=>(e=this.postProcess(e,n),r?void setTimeout(function(){r(e)},0):e),i=t.length,a=e.length;let l=1,c=i+a;null!=n.maxEditLength&&(c=Math.min(c,n.maxEditLength));const u=null!==(o=n.timeout)&&void 0!==o?o:1/0,d=Date.now()+u,h=[{oldPos:-1,lastComponent:void 0}];let p=this.extractCommon(h[0],t,e,0,n);if(h[0].oldPos+1>=a&&p+1>=i)return s(this.buildValues(h[0].lastComponent,t,e));let f=-1/0,g=1/0;const m=()=>{for(let r=Math.max(f,-l);r<=Math.min(g,l);r+=2){let o;const l=h[r-1],c=h[r+1];l&&(h[r-1]=void 0);let u=!1;if(c){const e=c.oldPos-r;u=c&&0<=e&&e<i}const d=l&&l.oldPos+1<a;if(u||d){if(o=!d||u&&l.oldPos<c.oldPos?this.addToPath(c,!0,!1,0,n):this.addToPath(l,!1,!0,1,n),p=this.extractCommon(o,t,e,r,n),o.oldPos+1>=a&&p+1>=i)return s(this.buildValues(o.lastComponent,t,e))||!0;h[r]=o,o.oldPos+1>=a&&(g=Math.min(g,r-1)),p+1>=i&&(f=Math.max(f,r+1))}else h[r]=void 0}l++};if(r)!(function e(){setTimeout(function(){if(l>c||Date.now()>d)return r(void 0);m()||e()},0)})();else for(;l<=c&&Date.now()<=d;){const e=m();if(e)return e}}addToPath(e,t,n,r,o){const s=e.lastComponent;return s&&!o.oneChangePerToken&&s.added===t&&s.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:s.count+1,added:t,removed:n,previousComponent:s.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:s}}}extractCommon(e,t,n,r,o){const s=t.length,i=n.length;let a=e.oldPos,l=a-r,c=0;for(;l+1<s&&a+1<i&&this.equals(n[a+1],t[l+1],o);)l++,a++,c++,o.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return c&&!o.oneChangePerToken&&(e.lastComponent={count:c,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=a,l}equals(e,t,n){return n.comparator?n.comparator(e,t):e===t||!!n.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){const t=[];for(let n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join("")}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,n){const r=[];let o;for(;e;)r.push(e),o=e.previousComponent,delete e.previousComponent,e=o;r.reverse();const s=r.length;let i=0,a=0,l=0;for(;i<s;i++){const e=r[i];if(e.removed)e.value=this.join(n.slice(l,l+e.count)),l+=e.count;else{if(!e.added&&this.useLongestToken){let r=t.slice(a,a+e.count);r=r.map(function(e,t){const r=n[l+t];return r.length>e.length?r:e}),e.value=this.join(r)}else e.value=this.join(t.slice(a,a+e.count));a+=e.count,e.added||(l+=e.count)}}return r}};const Ol=new class extends Pl{};function Tl(e,t){let n;for(n=0;n<e.length&&n<t.length;n++)if(e[n]!=t[n])return e.slice(0,n);return e.slice(0,n)}function $l(e,t){let n;if(!e||!t||e[e.length-1]!=t[t.length-1])return"";for(n=0;n<e.length&&n<t.length;n++)if(e[e.length-(n+1)]!=t[t.length-(n+1)])return e.slice(-n);return e.slice(-n)}function Rl(e,t,n){if(e.slice(0,t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't start with prefix ${JSON.stringify(t)}; this is a bug`);return n+e.slice(t.length)}function Ml(e,t,n){if(!t)return e+n;if(e.slice(-t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't end with suffix ${JSON.stringify(t)}; this is a bug`);return e.slice(0,-t.length)+n}function jl(e,t){return Rl(e,t,"")}function Dl(e,t){return Ml(e,t,"")}function Bl(e,t){return t.slice(0,Fl(e,t))}function Fl(e,t){let n=0;e.length>t.length&&(n=e.length-t.length);let r=t.length;e.length<t.length&&(r=e.length);const o=Array(r);let s=0;o[0]=0;for(let e=1;e<r;e++){for(t[e]==t[s]?o[e]=o[s]:o[e]=s;s>0&&t[e]!=t[s];)s=o[s];t[e]==t[s]&&s++}s=0;for(let r=n;r<e.length;r++){for(;s>0&&e[r]!=t[s];)s=o[s];e[r]==t[s]&&s++}return s}function Gl(e,t){const n=[];for(const r of Array.from(t.segment(e))){const e=r.segment;n.length&&/\s/.test(n[n.length-1])&&/\s/.test(e)?n[n.length-1]+=e:n.push(e)}return n}function Ul(e,t){if(t)return zl(e,t)[1];let n;for(n=e.length-1;n>=0&&e[n].match(/\s/);n--);return e.substring(n+1)}function Wl(e,t){if(t)return zl(e,t)[0];const n=e.match(/^\s*/);return n?n[0]:""}function zl(e,t){if(!t)return[Wl(e),Ul(e)];if("word"!=t.resolvedOptions().granularity)throw new Error("The segmenter passed must have a granularity of \"word\"");const n=Gl(e,t),r=n[0],o=n[n.length-1];return[/\s/.test(r)?r:"",/\s/.test(o)?o:""]}const ql="a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}",Hl=new RegExp(`[${ql}]+|\\s+|[^${ql}]`,"ug");function Vl(e,t,n,r,o){if(t&&n){const[s,i]=zl(t.value,o),[a,l]=zl(n.value,o);if(e){const r=Tl(s,a);e.value=Ml(e.value,a,r),t.value=jl(t.value,r),n.value=jl(n.value,r)}if(r){const e=$l(i,l);r.value=Rl(r.value,l,e),t.value=Dl(t.value,e),n.value=Dl(n.value,e)}}else if(n){if(e){const e=Wl(n.value,o);n.value=n.value.substring(e.length)}if(r){const e=Wl(r.value,o);r.value=r.value.substring(e.length)}}else if(e&&r){const n=Wl(r.value,o),[s,i]=zl(t.value,o),a=Tl(n,s);t.value=jl(t.value,a);const l=$l(jl(n,a),i);t.value=Dl(t.value,l),r.value=Rl(r.value,n,l),e.value=Ml(e.value,n,n.slice(0,n.length-l.length))}else if(r){const e=Wl(r.value,o),n=Bl(Ul(t.value,o),e);t.value=Dl(t.value,n)}else if(e){const n=Bl(Ul(e.value,o),Wl(t.value,o));t.value=jl(t.value,n)}}new class extends Pl{equals(e,t,n){return n.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e.trim()===t.trim()}tokenize(e,t={}){let n;if(t.intlSegmenter){const r=t.intlSegmenter;if("word"!=r.resolvedOptions().granularity)throw new Error("The segmenter passed must have a granularity of \"word\"");n=Gl(e,r)}else n=e.match(Hl)||[];const r=[];let o=null;return n.forEach(e=>{/\s/.test(e)?null==o?r.push(e):r.push(r.pop()+e):null!=o&&/\s/.test(o)?r[r.length-1]==o?r.push(r.pop()+e):r.push(o+e):r.push(e),o=e}),r}join(e){return e.map((e,t)=>0==t?e:e.replace(/^\s+/,"")).join("")}postProcess(e,t){if(!e||t.oneChangePerToken)return e;let n=null,r=null,o=null;return e.forEach(e=>{e.added?r=e:e.removed?o=e:((r||o)&&Vl(n,o,r,e,t.intlSegmenter),n=e,r=null,o=null)}),(r||o)&&Vl(n,o,r,null,t.intlSegmenter),e}};const Xl=new class extends Pl{tokenize(e){const t=new RegExp(`(\\r?\\n)|[${ql}]+|[^\\S\\n\\r]+|[^${ql}]`,"ug");return e.match(t)||[]}};function Kl(e,t,n){return Xl.diff(e,t,n)}function Zl(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,"\n"));const n=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let e=0;e<r.length;e++){const o=r[e];e%2&&!t.newlineIsToken?n[n.length-1]+=o:n.push(o)}return n}function Jl(e){return"."==e||"!"==e||"?"==e}new class extends Pl{constructor(){super(...arguments),this.tokenize=Zl}equals(e,t,n){return n.ignoreWhitespace?(n.newlineIsToken&&e.includes("\n")||(e=e.trim()),n.newlineIsToken&&t.includes("\n")||(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith("\n")&&(e=e.slice(0,-1)),t.endsWith("\n")&&(t=t.slice(0,-1))),super.equals(e,t,n)}};new class extends Pl{tokenize(e){var t;const n=[];let r=0;for(let o=0;o<e.length;o++){if(o==e.length-1){n.push(e.slice(r));break}if(Jl(e[o])&&e[o+1].match(/\s/)){for(n.push(e.slice(r,o+1)),o=r=o+1;null===(t=e[o+1])||void 0===t?void 0:t.match(/\s/);)o++;n.push(e.slice(r,o+1)),r=o+1}}return n}};new class extends Pl{tokenize(e){return e.split(/([{}:;,]|\s+)/)}};function Ql(e,t,n,r,o){let s,i;for(t=t||[],n=n||[],r&&(e=r(void 0===o?"":o,e)),s=0;s<t.length;s+=1)if(t[s]===e)return n[s];if("[object Array]"===Object.prototype.toString.call(e)){for(t.push(e),i=new Array(e.length),n.push(i),s=0;s<e.length;s+=1)i[s]=Ql(e[s],t,n,r,String(s));return t.pop(),n.pop(),i}if(e&&e.toJSON&&(e=e.toJSON()),"object"==typeof e&&null!==e){t.push(e),i={},n.push(i);const o=[];let a;for(a in e)Object.prototype.hasOwnProperty.call(e,a)&&o.push(a);for(o.sort(),s=0;s<o.length;s+=1)a=o[s],i[a]=Ql(e[a],t,n,r,a);t.pop(),n.pop()}else i=e;return i}new class extends Pl{constructor(){super(...arguments),this.tokenize=Zl}get useLongestToken(){return!0}castInput(e,t){const{undefinedReplacement:n,stringifyReplacer:r=(e,t)=>void 0===t?n:t}=t;return"string"==typeof e?e:JSON.stringify(Ql(e,null,null,r),null," ")}equals(e,t,n){return super.equals(e.replace(/,([\r\n])/g,"$1"),t.replace(/,([\r\n])/g,"$1"),n)}};function Yl(e,t){for(const n of t)e.push(n)}function ec(e){let t=e.length;return 10===e.charCodeAt(t-1)&&(t--,13===e.charCodeAt(t-1)&&t--),e.slice(0,t)}function tc(e,t=0){let n=3735928559^t,r=1103547991^t;for(let t,o=0;o<e.length;o++)t=e.charCodeAt(o),n=Math.imul(n^t,2654435761),r=Math.imul(r^t,1597334677);return n=Math.imul(n^n>>>16,2246822507),n^=Math.imul(r^r>>>13,3266489909),r=Math.imul(r^r>>>16,2246822507),r^=Math.imul(n^n>>>13,3266489909),(4294967296*(2097151&r)+(n>>>0)).toString(36).slice(0,6)}function nc({tagName:e,children:t=[],properties:n={}}){return{type:"element",tagName:e,properties:n,children:t}}function rc(e){let t=e.children[0];for(;null!=t;){if("element"===t.type&&"code"===t.tagName)return t;t="children"in t?t.children[0]:null}}function oc(e,t,n){const r="function"==typeof n.lineInfo?n.lineInfo(t):n.lineInfo[t-1];if(null==r){const r=`processLine: line ${t}, contains no state.lineInfo`;throw console.error(r,{node:e,line:t,state:n}),new Error(r)}return e.tagName="div",e.properties["data-line"]=r.lineNumber,e.properties["data-alt-line"]=r.altLineNumber,e.properties["data-line-type"]=r.type,e.properties["data-line-index"]=r.lineIndex,0===e.children.length&&e.children.push({type:"text",value:"\n"}),e}new class extends Pl{tokenize(e){return e.slice()}join(e){return e}removeEmpty(e){return e}};const sc=Symbol("no-token"),ic=Symbol("multiple-tokens");function ac(e){const t=lc(e);if(null!=t)return t;let n=sc;const r=[];let o,s=[];const i=()=>{if(0===s.length||null==o)return s=[],void(o=void 0);if(1===s.length){const t=s[0];if("element"===t?.type){e=o,t.properties["data-char"]=e;for(const e of t.children)cc(e)}else cc(t);return r.push(t),s=[],void(o=void 0)}var e;for(const e of s)cc(e);r.push(nc({tagName:"span",properties:{"data-char":o},children:s})),s=[],o=void 0},a=e=>{e!==sc&&(e!==ic?n!==sc?n!==e&&(n=ic):n=e:n=ic)};for(const t of e.children){const e="element"===t.type?ac(t):sc;a(e),"number"==typeof e?(null!=o&&o!==e&&i(),o??=e,s.push(t)):(i(),r.push(t))}return i(),e.children=r,n}function lc(e){const t=e.properties["data-char"];if("number"==typeof t)return t}function cc(e){if("element"===e.type){e.properties["data-char"]=void 0;for(const t of e.children)cc(t)}}function uc(e=!1,t=!1){const n={lineInfo:[]},r=[Object.assign({line:e=>(delete e.properties.class,e),pre(t){const r=rc(t),o=[];if(null!=r){let t=1;for(const s of r.children)"element"===s.type&&(e&&ac(s),o.push(oc(s,t,n)),t++);r.children=o}return t}},e?{tokens(e){for(const t of e){let e=0;for(const n of t){const t=n;t.__lineChar??=e,e+=n.content.length}}},preprocess(e,t){t.mergeWhitespaces="never"},span(e,t,n,r,o){if(null!=o?.offset&&null!=o.content){const t=o.__lineChar;return null!=t&&(e.properties["data-char"]=t),e}return e}}:null)];return t&&r.push(hc,dc),e&&r.push({line:e=>("element"===e.type&&0===e.children.length&&e.children.push({type:"element",tagName:"br",properties:{},children:[]}),e)}),{state:n,transformers:r,toClass:dc}}const dc=(function(e={}){const{classPrefix:t="__shiki_",classSuffix:n="",classReplacer:r=e=>e}=e,o=new Map;function s(e){return Object.entries(e).map(([e,t])=>`${e}:${t}`).join(";")}function i(e){const i="string"==typeof e?e:s(e);let a=t+tc(i)+n;return a=r(a),o.has(a)||o.set(a,"string"==typeof e?e:Object.assign({},e)),a}return{name:"@shikijs/transformers:style-to-class",pre(e){if(!e.properties.style)return;const t=i(e.properties.style);delete e.properties.style,this.addClassToHast(e,t)},tokens(e){for(const t of e)for(const e of t){if(!e.htmlStyle)continue;const t=i(e.htmlStyle);e.htmlStyle={},e.htmlAttrs||={},e.htmlAttrs.class?e.htmlAttrs.class+=` ${t}`:e.htmlAttrs.class=t}},getClassRegistry:()=>o,getCSS(){let e="";for(const[t,n]of o.entries())e+=`.${t}{${"string"==typeof n?n:s(n)}}`;return e},clearRegistry(){o.clear()}}})({classPrefix:"hl-"}),hc={name:"token-style-normalizer",tokens(e){for(const t of e)for(const e of t){if(null!=e.htmlStyle)continue;const t={};null!=e.color&&(t.color=e.color),null!=e.bgColor&&(t["background-color"]=e.bgColor),null!=e.fontStyle&&0!==e.fontStyle&&(1&e.fontStyle&&(t["font-style"]="italic"),2&e.fontStyle&&(t["font-weight"]="bold"),4&e.fontStyle&&(t["text-decoration"]="underline")),Object.keys(t).length>0&&(e.htmlStyle=t)}}};function pc(e){return`--${"token"===e?"diffs-token":"diffs"}-`}const fc=/^#(?:[0-9a-f]{3}0|[0-9a-f]{6}00)$/i,gc=/^0(?:\.0+)?%?$/;function mc(e){const t=e.indexOf("(");if(t<=0||!e.endsWith(")"))return;const n=e.slice(0,t).trim();if(!/^(?:rgb|rgba|hsl|hsla|hwb|lab|lch|oklab|oklch|color)$/i.test(n))return;const r=e.slice(t+1,-1).trim();if(0===r.length)return;const o=r.lastIndexOf("/");if(-1!==o)return r.slice(o+1).trim();if(/^(?:rgba|hsla)$/i.test(n)){const e=r.split(",");if(4===e.length)return e[3]?.trim()}}function yc(e){const t=/^#([0-9a-f]{3}|[0-9a-f]{6}|[0-9a-f]{8})\b/i.exec(e.trim());if(null==t)return null;const n=t[1];let r,o=1;return 3===n.length?r=n.split("").map(e=>e+e).join(""):6===n.length?r=n:(r=n.slice(0,6),o=parseInt(n.slice(6,8),16)/255),[parseInt(r.slice(0,2),16),parseInt(r.slice(2,4),16),parseInt(r.slice(4,6),16),o]}function bc(e){if(null==e)return null;const t=yc(e);if(null==t)return null;const n=t[0]/255,r=t[1]/255,o=t[2]/255,s=e=>e<=.03928?e/12.92:((e+.055)/1.055)**2.4;return.2126*s(n)+.7152*s(r)+.0722*s(o)}function wc(e){if(null==e)return!1;const t=e.trim().toLowerCase();if("transparent"===t)return!0;if(fc.test(t))return!0;const n=mc(t);return null!=n&&gc.test(n)}function kc(e,t,n){if(null==t||null==n)return!1;const r=bc(e),o=bc(t),s=bc(n);return null!=r&&null!=o&&null!=s&&Math.abs(r-s)<Math.abs(r-o)}const Cc=new WeakMap;function vc(e){const t=Cc.get(e);if(null!=t)return t;const n=e.colors??{},r=Object.assign({},n),o=n["editor.background"]??e.bg,s=n["editor.foreground"]??e.fg,i=n["sideBar.background"]??o,a=n["sideBar.foreground"]??s;xc(r,"editor.background",o),xc(r,"editor.foreground",s),xc(r,"sideBar.background",i),xc(r,"sideBar.foreground",a),xc(r,"input.background",n["input.background"]??i),xc(r,"sideBarSectionHeader.foreground",n["sideBarSectionHeader.foreground"]??a),xc(r,"list.activeSelectionForeground",n["list.activeSelectionForeground"]??a),xc(r,"gitDecoration.addedResourceForeground",Sc(n["gitDecoration.addedResourceForeground"],n["terminal.ansiGreen"],n["editorGutter.addedBackground"])),xc(r,"gitDecoration.modifiedResourceForeground",Sc(n["gitDecoration.modifiedResourceForeground"],n["terminal.ansiBlue"],n["editorGutter.modifiedBackground"])),xc(r,"gitDecoration.deletedResourceForeground",Sc(n["gitDecoration.deletedResourceForeground"],n["terminal.ansiRed"],n["editorGutter.deletedBackground"]));const l=(wc(n["list.focusOutline"])?void 0:n["list.focusOutline"])??(wc(n.focusBorder)?void 0:n.focusBorder);null!=l?r["list.focusOutline"]=l:delete r["list.focusOutline"];const c=n["list.hoverBackground"];var u,d;null!=c&&(u=c,null!=(d=i)&&u.toLowerCase()===d.toLowerCase()||kc(c,i,a))&&delete r["list.hoverBackground"];const h=Object.freeze(Object.assign({},e,{colors:Object.freeze(r)}));return Cc.set(e,h),h}function xc(e,t,n){null!=n&&""!==n&&(e[t]=n)}function Sc(...e){for(const t of e)if(null!=t&&""!==t)return t}function _c({theme:e=gl,highlighter:t,prefix:n}){let r="";if("string"==typeof e){const o=t.getTheme(e),s=vc(o);r+=`color:${s.fg};`,r+=`background-color:${s.bg};`,r+=`${pc("global")}fg:${s.fg};`,r+=`${pc("global")}bg:${s.bg};`,r+=Ac(o,n)}else{let n=t.getTheme(e.dark),o=vc(n);r+=`${pc("global")}dark:${o.fg};`,r+=`${pc("global")}dark-bg:${o.bg};`,r+=Ac(n,"dark"),n=t.getTheme(e.light),o=vc(n),r+=`${pc("global")}light:${o.fg};`,r+=`${pc("global")}light-bg:${o.bg};`,r+=Ac(n,"light")}return r}function Ac(e,t){t=null!=t?`${t}-`:"";let n="";const r=e.colors?.["gitDecoration.addedResourceForeground"]??e.colors?.["terminal.ansiGreen"];null!=r&&(n+=`${pc("global")}${t}addition-color:${r};`);const o=e.colors?.["gitDecoration.deletedResourceForeground"]??e.colors?.["terminal.ansiRed"];null!=o&&(n+=`${pc("global")}${t}deletion-color:${o};`);const s=e.colors?.["gitDecoration.modifiedResourceForeground"]??e.colors?.["terminal.ansiBlue"];return null!=s&&(n+=`${pc("global")}${t}modified-color:${s};`),n}function Ec(e){let t=e.children[0];for(;null!=t;){if("element"===t.type&&"code"===t.tagName)return t.children;t="children"in t?t.children[0]:null}throw console.error(e),new Error("getLineNodes: Unable to find children")}function Lc(e,t){return e-(0===t?0:1)}function Ic(e,t){return Lc(e,t)+t}function Nc({isPartial:e,rangeSize:t,expandedHunks:n,hunkIndex:r,collapsedContextThreshold:o}){const s=Math.max(t,0);if(0===s||e)return{fromStart:0,fromEnd:0,rangeSize:s,collapsedLines:s,renderAll:!1};if(!0===n||s<=o)return{fromStart:s,fromEnd:0,rangeSize:s,collapsedLines:0,renderAll:!0};const i=n?.get(r),a=Math.min(Math.max(i?.fromStart??0,0),s),l=Math.min(Math.max(i?.fromEnd??0,0),s),c=a+l,u=c>=s;return{fromStart:u?s:a,fromEnd:u?0:l,rangeSize:s,collapsedLines:Math.max(s-c,0),renderAll:u}}function Pc({fileDiff:e,errorPrefix:t}){const n=e.hunks[e.hunks.length-1];if(null==n||e.isPartial||0===e.additionLines.length||0===e.deletionLines.length)return 0;const r=e.additionLines.length-Ic(n.additionStart,n.additionCount),o=e.deletionLines.length-Ic(n.deletionStart,n.deletionCount);if(r<=0&&o<=0)return 0;if(r!==o)throw new Error(`${t}: trailing context mismatch (additions=${r}, deletions=${o}) for ${e.name}`);return Math.min(r,o)}function Oc({fileDiff:e,hunkIndex:t,expandedHunks:n,collapsedContextThreshold:r,errorPrefix:o}){if(t!==e.hunks.length-1)return;const s=Pc({fileDiff:e,errorPrefix:o});if(s<=0)return;if(!0===n||s<=r)return{fromStart:s,fromEnd:0,rangeSize:s,collapsedLines:0,renderAll:!0};const i=n?.get(e.hunks.length),a=Math.min(Math.max(i?.fromStart??0,0),s);return{fromStart:a,fromEnd:0,rangeSize:s,collapsedLines:s-a,renderAll:a>=s}}function Tc({diff:e,diffStyle:t,startingLine:n=0,totalLines:r=1/0,expandedHunks:o,collapsedContextThreshold:s=1,callback:i}){const a=$c({diff:e,diffStyle:t,startingLine:n,expandedHunks:o,collapsedContextThreshold:s}),l={viewportStart:n,viewportEnd:n+r,isWindowedHighlight:n>0||r<1/0,splitCount:a.splitCount,unifiedCount:a.unifiedCount,finalHunkIndex:e.hunks.length-1,shouldBreak(){if(!l.isWindowedHighlight)return!1;const e=l.unifiedCount>=n+r,o=l.splitCount>=n+r;return"unified"===t?e:("split"===t||e)&&o},shouldSkip(e,r){if(!l.isWindowedHighlight)return!1;const o=e>0&&l.unifiedCount+e<=n,s=r>0&&l.splitCount+r<=n;return"unified"===t?o:("split"===t||o)&&s},incrementCounts(e,n){"unified"!==t&&"both"!==t||(l.unifiedCount+=e),"split"!==t&&"both"!==t||(l.splitCount+=n)},isInWindow(e,n){if(!l.isWindowedHighlight)return!0;const r=l.isInUnifiedWindow(e),o=l.isInSplitWindow(n);return"unified"===t?r:"split"===t?o:r||o},isInUnifiedWindow:e=>!l.isWindowedHighlight||l.unifiedCount>=n-e&&l.unifiedCount<n+r,isInSplitWindow:e=>!l.isWindowedHighlight||l.splitCount>=n-e&&l.splitCount<n+r,emit:(e,n=!1)=>(n||("unified"===t?l.incrementCounts(1,0):"split"===t?l.incrementCounts(0,1):l.incrementCounts(1,1)),i(e)??!1)};e:for(let d=a.hunkIndex;d<e.hunks.length;d++){const h=e.hunks[d];if(null==h)throw new Error("iterateOverDiff: invalid hunk index");if(l.shouldBreak())break;const p=Lc(h.deletionStart,h.deletionCount),f=Lc(h.additionStart,h.additionCount),g=e.isPartial||0!==h.deletionCount?h.deletionLineIndex:p,m=e.isPartial||0!==h.additionCount?h.additionLineIndex:f,y=Nc({isPartial:e.isPartial,rangeSize:h.collapsedBefore,expandedHunks:o,hunkIndex:d,collapsedContextThreshold:s}),b=d===l.finalHunkIndex?Oc({fileDiff:e,hunkIndex:d,expandedHunks:o,collapsedContextThreshold:s,errorPrefix:"iterateOverDiff"}):void 0,w=y.fromStart+y.fromEnd;function c(e,n){return null==b||b.collapsedLines<=0||b.fromStart+b.fromEnd>0?0:"unified"===t?e===h.unifiedLineStart+h.unifiedLineCount-1?b.collapsedLines:0:n===h.splitLineStart+h.splitLineCount-1?b.collapsedLines:0}let k=0===y.collapsedLines;function u(){return k?0:(k=!0,y.collapsedLines)}if(l.shouldSkip(w,w))l.incrementCounts(w,w),u();else{let L=h.unifiedLineStart-y.rangeSize,I=h.splitLineStart-y.rangeSize,N=g-y.rangeSize,P=m-y.rangeSize,O=p+1-y.rangeSize,T=f+1-y.rangeSize;if(jc(l,y.fromStart,t,e=>l.emit({hunkIndex:d,hunk:h,collapsedBefore:0,collapsedAfter:0,type:"context-expanded",deletionLine:{lineNumber:O+e,lineIndex:N+e,noEOFCR:!1,unifiedLineIndex:L+e,splitLineIndex:I+e},additionLine:{unifiedLineIndex:L+e,splitLineIndex:I+e,lineIndex:P+e,lineNumber:T+e,noEOFCR:!1}})))break e;if(L=h.unifiedLineStart-y.fromEnd,I=h.splitLineStart-y.fromEnd,N=g-y.fromEnd,P=m-y.fromEnd,O=p+1-y.fromEnd,T=f+1-y.fromEnd,jc(l,y.fromEnd,t,e=>l.emit({hunkIndex:d,hunk:h,collapsedBefore:u(),collapsedAfter:0,type:"context-expanded",deletionLine:{lineNumber:O+e,lineIndex:N+e,noEOFCR:!1,unifiedLineIndex:L+e,splitLineIndex:I+e},additionLine:{unifiedLineIndex:L+e,splitLineIndex:I+e,lineIndex:P+e,lineNumber:T+e,noEOFCR:!1}}),()=>{u()}))break e}let C=h.unifiedLineStart,v=h.splitLineStart,x=g,S=m,_=p+1,A=f+1;const E=h.hunkContent.at(-1);for(const $ of h.hunkContent){if(l.shouldBreak())break e;const R=$===E;if("context"===$.type){if(l.shouldSkip($.lines,$.lines))l.incrementCounts($.lines,$.lines),u();else if(jc(l,$.lines,t,e=>{const t=R&&e===$.lines-1,n=C+e,r=v+e;return l.emit({hunkIndex:d,hunk:h,collapsedBefore:u(),collapsedAfter:c(n,r),type:"context",deletionLine:{lineNumber:_+e,lineIndex:x+e,noEOFCR:t&&h.noEOFCRDeletions,unifiedLineIndex:n,splitLineIndex:r},additionLine:{unifiedLineIndex:n,splitLineIndex:r,lineIndex:S+e,lineNumber:A+e,noEOFCR:t&&h.noEOFCRAdditions}})},()=>{u()}))break e;C+=$.lines,v+=$.lines,x+=$.lines,S+=$.lines,_+=$.lines,A+=$.lines}else{const M=Math.max($.deletions,$.additions),j=$.deletions+$.additions;if(!l.shouldSkip(j,M)){const D=Dc(l,$,t);(D[0]?.[0]??0)>0&&u();for(const[B,F]of D)for(let G=B;G<F;G++){const U=c(C+G,"unified"===t?v+(G<$.deletions?G:G-$.deletions):v+G);if(l.emit(Bc({hunkIndex:d,hunk:h,collapsedBefore:u(),collapsedAfter:U,diffStyle:t,index:G,unifiedLineIndex:C,splitLineIndex:v,additionLineIndex:S,deletionLineIndex:x,additionLineNumber:A,deletionLineNumber:_,content:$,isLastContent:R,unifiedCount:j,splitCount:M}),!0))break e}}u(),l.incrementCounts(j,M),C+=j,v+=M,x+=$.deletions,S+=$.additions,_+=$.deletions,A+=$.additions}}if(null!=b){const{collapsedLines:W,fromStart:z,fromEnd:q}=b,H=z+q;if(jc(l,H,t,t=>{const n=t===H-1;return l.emit({hunkIndex:e.hunks.length,hunk:void 0,collapsedBefore:0,collapsedAfter:n?W:0,type:"context-expanded",deletionLine:{lineNumber:_+t,lineIndex:x+t,noEOFCR:!1,unifiedLineIndex:C+t,splitLineIndex:v+t},additionLine:{unifiedLineIndex:C+t,splitLineIndex:v+t,lineIndex:S+t,lineNumber:A+t,noEOFCR:!1}})},void 0,()=>l.shouldBreak()))break e}}}function $c({diff:e,diffStyle:t,startingLine:n,expandedHunks:r,collapsedContextThreshold:o}){if(n<=0||"both"===t)return{hunkIndex:0,splitCount:0,unifiedCount:0};const s=Rc({diff:e,expandedHunks:r,collapsedContextThreshold:o});let i=0,a=e.hunks.length-1,l=e.hunks.length;for(;i<=a;){const e=i+a>>1,r=s[e+1];if(null==r)throw new Error("iterateOverDiff: invalid hunk prefix index");("unified"===t?r.unifiedCount:r.splitCount)>n?(l=e,a=e-1):i=e+1}if(l>=e.hunks.length){const t=s[e.hunks.length];if(null==t)throw new Error("iterateOverDiff: invalid terminal hunk prefix index");return{hunkIndex:e.hunks.length,splitCount:t.splitCount,unifiedCount:t.unifiedCount}}const c=s[l];if(null==c)throw new Error("iterateOverDiff: invalid selected hunk prefix index");return{hunkIndex:l,splitCount:c.splitCount,unifiedCount:c.unifiedCount}}function Rc({diff:e,expandedHunks:t,collapsedContextThreshold:n}){let r=0,o=0;const s=e.hunks.length-1,i=[{splitCount:0,unifiedCount:0}];for(let a=0;a<e.hunks.length;a++){const l=e.hunks[a];if(null==l)throw new Error("iterateOverDiff: invalid hunk summary index");const c=Nc({isPartial:e.isPartial,rangeSize:l.collapsedBefore,expandedHunks:t,hunkIndex:a,collapsedContextThreshold:n}),u=c.fromStart+c.fromEnd;r+=u+l.splitLineCount,o+=u+l.unifiedLineCount;const d=a===s?Oc({fileDiff:e,hunkIndex:a,expandedHunks:t,collapsedContextThreshold:n,errorPrefix:"iterateOverDiff"}):void 0;if(null!=d){const e=d.fromStart+d.fromEnd;r+=e,o+=e}i.push({splitCount:r,unifiedCount:o})}return i}function Mc(e,t,n){if(!e.isWindowedHighlight||t<=0)return[0,t];const r=[];function o(n){const o=Math.max(0,e.viewportStart-n),s=Math.min(t,e.viewportEnd-n);s>o&&r.push([o,s])}if("split"!==n&&o(e.unifiedCount),"unified"!==n&&o(e.splitCount),0===r.length)return[0,0];let s=r[0][0],i=r[0][1];for(let e=1;e<r.length;e++){const t=r[e];s=Math.min(s,t[0]),i=Math.max(i,t[1])}return[s,i]}function jc(e,t,n,r,o,s){const[i,a]=Mc(e,t,n);i>0&&(e.incrementCounts(i,i),o?.());let l=i;for(;l<t;){if(!0===s?.())return!0;if(l>=a){e.incrementCounts(t-l,t-l);break}if(e.isInWindow(0,0)){if(!0===r(l))return!0}else e.incrementCounts(1,1);l++}return!1}function Dc(e,t,n){if(!e.isWindowedHighlight)return[[0,"unified"===n?t.deletions+t.additions:Math.max(t.deletions,t.additions)]];const r="unified"!==n,o="unified"===n?"unified":"split",s=[];function i(t,n){if(t+n<=e.viewportStart||t>=e.viewportEnd)return;const r=Math.max(0,e.viewportStart-t),o=Math.min(n,e.viewportEnd-t);return o>r?[r,o]:void 0}function a(e,n){return"split"===o?e:"additions"===n?[e[0]+t.deletions,e[1]+t.deletions]:e}function l(e,t){if(null==e)return;const[n,r]=a(e,t);r>n&&s.push([n,r])}if("split"!==n&&(l(i(e.unifiedCount,t.deletions),"deletions"),l(i(e.unifiedCount+t.deletions,t.additions),"additions")),r&&(l(i(e.splitCount,t.deletions),"deletions"),l(i(e.splitCount,t.additions),"additions")),0===s.length)return s;s.sort((e,t)=>e[0]-t[0]);const c=[s[0]];for(const[e,t]of s.slice(1)){const n=c[c.length-1];e<=n[1]?n[1]=Math.max(n[1],t):c.push([e,t])}return c}function Bc({hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,diffStyle:o,index:s,unifiedLineIndex:i,splitLineIndex:a,additionLineIndex:l,deletionLineIndex:c,additionLineNumber:u,deletionLineNumber:d,content:h,isLastContent:p,unifiedCount:f,splitCount:g}){const m=s<h.deletions?i+s:void 0,y="unified"===o?s>=h.deletions?i+s:void 0:s<h.additions?i+h.deletions+s:void 0,b="unified"===o?a+(s<h.deletions?s:s-h.deletions):a+s,w=s<h.deletions?c+s:void 0,k=s<h.deletions?d+s:void 0,C="unified"===o?s>=h.deletions?l+(s-h.deletions):void 0:s<h.additions?l+s:void 0,v="unified"===o?s>=h.deletions?u+(s-h.deletions):void 0:s<h.additions?u+s:void 0,x="unified"===o?p&&s===h.deletions-1&&t.noEOFCRDeletions:p&&s===g-1&&t.noEOFCRDeletions,S="unified"===o?p&&s===f-1&&t.noEOFCRAdditions:p&&s===g-1&&t.noEOFCRAdditions,_=null!=w&&null!=k&&null!=m?{lineNumber:k,lineIndex:w,noEOFCR:x,unifiedLineIndex:m,splitLineIndex:b}:void 0,A=null!=C&&null!=v&&null!=y?{unifiedLineIndex:y,splitLineIndex:b,lineIndex:C,lineNumber:v,noEOFCR:S}:void 0;if(null==_&&null!=A)return{type:"change",hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:void 0,additionLine:A};if(null!=_&&null==A)return{type:"change",hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:_,additionLine:void 0};if(null==_||null==A)throw new Error("iterateOverDiff: missing change line data");return{type:"change",hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:_,additionLine:A}}function Fc({line:e,spanStart:t,spanLength:n}){return{start:{line:e,character:t},end:{line:e,character:t+n},properties:{"data-diff-span":""},alwaysWrap:!0}}function Gc({item:e,arr:t,enableJoin:n,isNeutral:r=!1,isLastItem:o=!1}){const s=t[t.length-1];if(null==s||o||!n)return void t.push([r?0:1,e.value]);const i=0===s[0];r===i||r&&1===e.value.length&&!i?s[1]+=e.value:t.push([r?0:1,e.value])}const Uc={forcePlainText:!1};function Wc(e,t,n,{forcePlainText:r,startingLine:o,totalLines:s,expandedHunks:i,collapsedContextThreshold:a=1}=Uc){r?(o??=0,s??=1/0):(o=0,s=1/0);const l=o>0||s<1/0,c="string"==typeof n.theme?t.getTheme(n.theme).type:void 0,u=_c({theme:n.theme,highlighter:t}),d=r&&!l&&(e.unifiedLineCount>1e3||e.splitLineCount>1e3)?"none":n.lineDiffType,h={deletionLines:[],additionLines:[]},{maxLineDiffLength:p}=n,f=!r&&!e.isPartial,g=r?i:void 0,m=new Map;function y(e){const t=f?0:e,n=m.get(t)??{deletionContent:{push(e){this.value+=e,this.length++},value:"",length:0},additionContent:{push(e){this.value+=e,this.length++},value:"",length:0},deletionInfo:[],additionInfo:[],deletionDecorations:[],additionDecorations:[],deletionSegments:[],additionSegments:[]};return m.set(t,n),n}function b(e,t,n,r){if(l){let e=n.at(-1);null!=e&&e.targetIndex+e.count===t||(e={targetIndex:t,originalOffset:r.length,count:0},n.push(e)),e.count++}r.push(e)}Tc({diff:e,diffStyle:"both",startingLine:o,totalLines:s,expandedHunks:!l||g,collapsedContextThreshold:a,callback:({hunkIndex:t,additionLine:n,deletionLine:r,type:o})=>{const s=y(t),i=null!=n?n.splitLineIndex:r.splitLineIndex;"change"===o&&null!=n&&null!=r&&qc({additionLine:e.additionLines[n.lineIndex],deletionLine:e.deletionLines[r.lineIndex],deletionLineIndex:s.deletionContent.length,additionLineIndex:s.additionContent.length,deletionDecorations:s.deletionDecorations,additionDecorations:s.additionDecorations,lineDiffType:d,maxLineDiffLength:p}),null!=r&&(b(e.deletionLines[r.lineIndex],r.lineIndex,s.deletionSegments,s.deletionContent),s.deletionInfo.push({type:"change"===o?"change-deletion":o,lineNumber:r.lineNumber,altLineNumber:"change"===o?void 0:n.lineNumber??void 0,lineIndex:`${r.unifiedLineIndex},${i}`})),null!=n&&(b(e.additionLines[n.lineIndex],n.lineIndex,s.additionSegments,s.additionContent),s.additionInfo.push({type:"change"===o?"change-addition":o,lineNumber:n.lineNumber,altLineNumber:"change"===o?void 0:r.lineNumber??void 0,lineIndex:`${n.unifiedLineIndex},${i}`}))}});for(const o of m.values()){if(0===o.deletionContent.length&&0===o.additionContent.length)continue;const s={name:e.prevName??e.name,contents:o.deletionContent.value},i={name:e.name,contents:o.additionContent.value},{deletionLines:a,additionLines:l}=Hc({deletionFile:s,deletionInfo:o.deletionInfo,deletionDecorations:o.deletionDecorations,additionFile:i,additionInfo:o.additionInfo,additionDecorations:o.additionDecorations,highlighter:t,options:n,languageOverride:r?"text":e.lang});if(f)h.deletionLines=a,h.additionLines=l;else{if(o.deletionSegments.length>0)for(const e of o.deletionSegments)for(let t=0;t<e.count;t++)h.deletionLines[e.targetIndex+t]=a[e.originalOffset+t];else Yl(h.deletionLines,a);if(o.additionSegments.length>0)for(const e of o.additionSegments)for(let t=0;t<e.count;t++)h.additionLines[e.targetIndex+t]=l[e.originalOffset+t];else Yl(h.additionLines,l)}}return{code:h,themeStyles:u,baseThemeType:c}}function zc(e,{deletionLineIndex:t,additionLineIndex:n,deletionDecorations:r,additionDecorations:o}){let s=0,i=0,a=-1,l=0,c=-1,u=0;for(const{value:t,added:n,removed:r}of e)r?(-1===a&&(a=s),s+=t.length,l=s):n?(-1===c&&(c=i),i+=t.length,u=i):(s+=t.length,i+=t.length);-1!==a&&r.push(Fc({line:t,spanStart:a,spanLength:l-a})),-1!==c&&o.push(Fc({line:n,spanStart:c,spanLength:u-c}))}function qc({deletionLine:e,additionLine:t,deletionLineIndex:n,additionLineIndex:r,deletionDecorations:o,additionDecorations:s,lineDiffType:i,maxLineDiffLength:a}){if(null==e||null==t||"none"===i)return;if(e=ec(e),t=ec(t),e.length>a||t.length>a)return;const l="char"===i?(c=e,u=t,Ol.diff(c,u,d)):Kl(e,t);var c,u,d;if("word-line"===i)return void zc(l,{deletionLineIndex:n,additionLineIndex:r,deletionDecorations:o,additionDecorations:s});const h=[],p=[],f="word-alt"===i,g=l.at(-1);for(const e of l){const t=e===g;e.added||e.removed?e.removed?Gc({item:e,arr:h,enableJoin:f,isLastItem:t}):Gc({item:e,arr:p,enableJoin:f,isLastItem:t}):(Gc({item:e,arr:h,enableJoin:f,isNeutral:!0,isLastItem:t}),Gc({item:e,arr:p,enableJoin:f,isNeutral:!0,isLastItem:t}))}let m=0;for(const e of h)1===e[0]&&o.push(Fc({line:n,spanStart:m,spanLength:e[1].length})),m+=e[1].length;m=0;for(const e of p)1===e[0]&&s.push(Fc({line:r,spanStart:m,spanLength:e[1].length})),m+=e[1].length}function Hc(e){let{deletionFile:t,additionFile:n,deletionInfo:r,additionInfo:o,highlighter:s,deletionDecorations:i,additionDecorations:a,languageOverride:l,options:{theme:c}}=e,u=g(e.options,b);const d=l??Ll(t.name),h=l??Ll(n.name),{state:p,transformers:f}=uc(u.useTokenTransformer),m="string"==typeof c?Object.assign({},u,{lang:"text",theme:c,transformers:f,decorations:void 0,defaultColor:!1,cssVariablePrefix:pc("token"),tokenizeTimeLimit:0}):Object.assign({},u,{lang:"text",themes:c,transformers:f,decorations:void 0,defaultColor:!1,cssVariablePrefix:pc("token"),tokenizeTimeLimit:0});return{deletionLines:""===t.contents?[]:(m.lang=d,p.lineInfo=r,m.decorations=i,Ec(s.codeToHast(ec(t.contents),m))),additionLines:""===n.contents?[]:(m.lang=h,m.decorations=a,p.lineInfo=o,Ec(s.codeToHast(ec(n.contents),m)))}}function Vc(e){const t=[0];let n=e.indexOf("\r"),r=e.indexOf("\n"),o=0,s=0;for(;-1!==n||-1!==r;){let i;if(-1!==n&&(-1===r||n<r)?r===n+1?(i=r+1,n=e.indexOf("\r",i),r=e.indexOf("\n",i)):(i=n+1,n=e.indexOf("\r",i)):(i=r+1,r=e.indexOf("\n",i)),t.push(i),4===++s){if(i-o<=40){for(let n=i;n<e.length;n++){const r=e.charCodeAt(n);10!==r&&13!==r||(13===r&&n+1<e.length&&10===e.charCodeAt(n+1)&&n++,t.push(n+1))}return t}o=i,s=0}}return t}function Xc(e){const t=Vc(e);return Array.from({length:t.length},(n,r)=>{const o=t[r],s=t[r+1]??e.length;return e.slice(o,s)})}const Kc={forcePlainText:!1};function Zc(e,t,{theme:n,tokenizeMaxLineLength:r,useTokenTransformer:o},{forcePlainText:s,startingLine:i,totalLines:a,lines:l}=Kc){s?(i??=0,a??=1/0):(i=0,a=1/0);const c=i>0||a<1/0,{state:u,transformers:d}=uc(o),h=s?"text":e.lang??Ll(e.name),p="string"==typeof n?t.getTheme(n).type:void 0,f=_c({theme:n,highlighter:t});u.lineInfo=e=>({type:"context",lineIndex:e-1+i,lineNumber:e+i});const g="string"==typeof n?{lang:h,theme:n,transformers:d,defaultColor:!1,cssVariablePrefix:pc("token"),tokenizeMaxLineLength:r,tokenizeTimeLimit:0}:{lang:h,themes:n,transformers:d,defaultColor:!1,cssVariablePrefix:pc("token"),tokenizeMaxLineLength:r,tokenizeTimeLimit:0},m=Ec(t.codeToHast((c?Jc(l??Xc(e.contents),i,a):e.contents).replace(/\r(?!\n)/g,"\n"),g));const y=c?new Array(i):m;return c&&Yl(y,m),{code:y,themeStyles:f,baseThemeType:p}}function Jc(e,t,n){if(0===e.length)return"";const r=Math.min(t+n,e.length);return e.slice(t,r).join("")}let Qc,Yc={theme:gl,useTokenTransformer:!1,tokenizeMaxLineLength:1e3,lineDiffType:"word-alt",maxLineDiffLength:1e3};const eu=/(?:)/;async function tu(e){try{switch(e.type){case"initialize":await nu(e);break;case"set-render-options":await ru(e);break;case"file":await ou(e);break;case"diff":await su(e);break;default:throw new Error(`Unknown request type: ${e.type}`)}}catch(t){console.error("Worker error:",t),uu(e.id,t)}finally{eu.exec("")}}async function nu({id:e,renderOptions:t,preferredHighlighter:n,resolvedThemes:r,resolvedLanguages:o,customExtensionsVersion:s,customExtensionMap:i}){let a=iu(n);"then"in a&&(a=await a),au({customExtensionsVersion:s,customExtensionMap:i}),Sl(r,a),null!=o&&bl(o,a),Yc=t,postMessage({type:"success",id:e,requestType:"initialize",sentAt:Date.now()})}async function ru({id:e,renderOptions:t,resolvedThemes:n}){let r=iu();"then"in r&&(r=await r),Sl(n,r),Yc=t,postMessage({type:"success",id:e,requestType:"set-render-options",sentAt:Date.now()})}async function ou({id:e,file:t,resolvedLanguages:n,customExtensionsVersion:r,customExtensionMap:o}){let s=iu();"then"in s&&(s=await s),au({customExtensionsVersion:r,customExtensionMap:o}),null!=n&&bl(n,s);const i={theme:Yc.theme,useTokenTransformer:Yc.useTokenTransformer,tokenizeMaxLineLength:Yc.tokenizeMaxLineLength};lu(e,Zc(t,s,i),i)}async function su({id:e,diff:t,resolvedLanguages:n,customExtensionsVersion:r,customExtensionMap:o}){let s=iu();"then"in s&&(s=await s),au({customExtensionsVersion:r,customExtensionMap:o}),null!=n&&bl(n,s),cu(e,Wc(t,s,Yc),Yc)}function iu(e="shiki-js"){return Qc??=fo({themes:[],langs:[],engine:"shiki-wasm"===e?hl(t(i[4])(i[3],i.paths)):Fa()}),Qc}function au({customExtensionsVersion:e,customExtensionMap:t}){if(null!=e||null!=t){if(null==e||null==t)throw new Error("Worker request must include both customExtensionsVersion and customExtensionMap");Nl(e,t)}}function lu(e,t,n){postMessage({type:"success",requestType:"file",id:e,result:t,options:n,sentAt:Date.now()})}function cu(e,t,n){postMessage({type:"success",requestType:"diff",id:e,result:t,options:n,sentAt:Date.now()})}function uu(e,t){const n={type:"error",id:e,error:t instanceof Error?t.message:String(t),stack:t instanceof Error?t.stack:void 0};postMessage(n)}self.addEventListener("error",e=>{console.error("[Shiki Worker] Unhandled error:",e.error)}),self.addEventListener("message",e=>{tu(e.data)})},1784,{"0":30,"1":31,"2":25,"3":1785,"4":982,"paths":{"1785":"/_expo/static/js/web/wasm-B9ZqxnKj-2becd88758f5fc2a4baf4892deedd634.js"}});
59
- __r(1765);
58
+ `.replace(/\s+/g,""),"gsu");function ui(e){if(!new RegExp(`${li}\\+`).test(e))return{pattern:e};const t=[];let n,r=null,o=null,s="",i=0;for(ci.lastIndex=0;n=ci.exec(e);){const{0:a,index:l,groups:{qBase:c,qMod:u,invalidQ:d}}=n;if("["===a)i||(o=l),i++;else if("]"===a)i?i--:o=null;else if(!i)if("+"===u&&s&&!s.startsWith("(")){if(d)throw new Error(`Invalid quantifier "${a}"`);let t=-1;if(/^\{\d+\}$/.test(c))e=Ys(e,l+c.length,u,"");else{if(")"===s||"]"===s){const t=")"===s?r:o;if(null===t)throw new Error(`Invalid unmatched "${s}"`);e=`${e.slice(0,t)}(?>${e.slice(t,l)}${c})${e.slice(l+a.length)}`}else e=`${e.slice(0,l-s.length)}(?>${s}${c})${e.slice(l+a.length)}`;t+=4}ci.lastIndex+=t}else"("===a[0]?t.push(l):")"===a&&(r=t.length?t.pop():null);s=a}return{pattern:e}}const di=String.raw,hi=di`\(\?R=(?<rDepth>[^\)]+)\)|${di`\\g<(?<gRNameOrNum>[^>&]+)&R=(?<gRDepth>[^>]+)>`}`,pi=di`\(\?<(?![=!])(?<captureName>[^>]+)>`,fi=di`${pi}|(?<unnamed>\()(?!\?)`,gi=new RegExp(di`${pi}|${hi}|\(\?|\\?.`,"gsu"),mi="Cannot use multiple overlapping recursions";function yi(e,t){const{hiddenCaptures:n,mode:r}=Object.assign({hiddenCaptures:[],mode:"plugin"},t);let o=t?.captureTransfers??new Map;if(!new RegExp(hi,"su").test(e))return{pattern:e,captureTransfers:o,hiddenCaptures:n};if("plugin"===r&&oi(e,di`\(\?\(DEFINE\)`,ei.DEFAULT))throw new Error("DEFINE groups cannot be used with recursion");const s=[],i=oi(e,di`\\[1-9]`,ei.DEFAULT),a=new Map,l=[];let c,u=!1,d=0,h=0;for(gi.lastIndex=0;c=gi.exec(e);){const{0:t,groups:{captureName:p,rDepth:f,gRNameOrNum:g,gRDepth:m}}=c;if("["===t)d++;else if(d)"]"===t&&d--;else{if(f){if(bi(f),u)throw new Error(mi);if(i)throw new Error(("external"===r?"Backrefs":"Numbered backrefs")+" cannot be used with global recursion");const t=e.slice(0,c.index),a=e.slice(gi.lastIndex);if(oi(a,hi,ei.DEFAULT))throw new Error(mi);const l=+f-1;e=wi(t,a,l,!1,n,s,h),o=vi(o,t,l,s.length,0,h);break}if(g){bi(m);let d=!1;for(const e of l)if(e.name===g||e.num===+g){if(d=!0,e.hasRecursedWithin)throw new Error(mi);break}if(!d)throw new Error(di`Recursive \g cannot be used outside the referenced group "${"external"===r?g:di`\g<${g}&R=${m}>`}"`);const p=a.get(g),f=si(e,p);if(i&&oi(f,di`${pi}|\((?!\?)`,ei.DEFAULT))throw new Error(("external"===r?"Backrefs":"Numbered backrefs")+" cannot be used with recursion of capturing groups");const y=e.slice(p,c.index),b=f.slice(y.length+t.length),w=s.length,k=+m-1,C=wi(y,b,k,!0,n,s,h);o=vi(o,y,k,s.length-w,w,h),e=`${e.slice(0,p)}${C}${e.slice(p+f.length)}`,gi.lastIndex+=C.length-t.length-y.length-b.length,l.forEach(e=>e.hasRecursedWithin=!0),u=!0}else if(p)h++,a.set(String(h),gi.lastIndex),a.set(p,gi.lastIndex),l.push({num:h,name:p});else if("("===t[0]){const e="("===t;e&&(h++,a.set(String(h),gi.lastIndex)),l.push(e?{num:h}:{})}else")"===t&&l.pop()}}return n.push(...s),{pattern:e,captureTransfers:o,hiddenCaptures:n}}function bi(e){const t=`Max depth must be integer between 2 and 100; used ${e}`;if(!/^[1-9]\d*$/.test(e))throw new Error(t);if((e=+e)<2||e>100)throw new Error(t)}function wi(e,t,n,r,o,s,i){const a=new Set;r&&ni(e+t,pi,({groups:{captureName:e}})=>{a.add(e)},ei.DEFAULT);const l=[n,r?a:null,o,s,i];return`${e}${ki(`(?:${e}`,"forward",...l)}(?:)${ki(`${t})`,"backward",...l)}${t}`}function ki(e,t,n,r,o,s,i){const a=e=>"forward"===t?e+2:n-e+2-1;let l="";for(let t=0;t<n;t++){const n=a(t);l+=ti(e,di`${fi}|\\k<(?<backref>[^>]+)>`,({0:e,groups:{captureName:t,unnamed:a,backref:l}})=>{if(l&&r&&!r.has(l))return e;const c=`_$${n}`;if(a||t){const n=i+s.length+1;return s.push(n),Ci(o,n),a?e:`(?<${t}${c}>`}return di`\k<${l}${c}>`},ei.DEFAULT)}return l}function Ci(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function vi(e,t,n,r,o,s){if(e.size&&r){let i=0;ni(t,fi,()=>i++,ei.DEFAULT);const a=s-i+o,l=new Map;return e.forEach((e,t)=>{const o=(r-i*n)/n,s=i*n,c=t>a+i?t+r:t,u=[];for(const t of e)if(t<=a)u.push(t);else if(t>a+i+o)u.push(t+r);else if(t<=a+i)for(let e=0;e<=n;e++)u.push(t+i*e);else for(let e=0;e<=n;e++)u.push(t+s+o*e);l.set(c,u)}),l}return e}var xi=String.fromCodePoint,Si=String.raw,_i={},Ai=globalThis.RegExp;function Ei(e,{enable:t,disable:n}){return{dotAll:!(n?.dotAll||!t?.dotAll&&!e.dotAll),ignoreCase:!(n?.ignoreCase||!t?.ignoreCase&&!e.ignoreCase)}}function Li(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}function Ii(e,t){return Pi[e]>=Pi[t]}function Ni(e,t){if(null==e)throw new Error(t??"Value expected");return e}_i.flagGroups=(()=>{try{new Ai("(?i:)")}catch{return!1}return!0})(),_i.unicodeSets=(()=>{try{new Ai("[[]]","v")}catch{return!1}return!0})(),_i.bugFlagVLiteralHyphenIsRange=!!_i.unicodeSets&&(()=>{try{new Ai(Si`[\d\-a]`,"v")}catch{return!0}return!1})(),_i.bugNestedClassIgnoresNegation=_i.unicodeSets&&new Ai("[[^a]]","v").test("a");var Pi={ES2025:2025,ES2024:2024,ES2018:2018},Oi={auto:"auto",ES2025:"ES2025",ES2024:"ES2024",ES2018:"ES2018"};function Ti(e={}){if("[object Object]"!=={}.toString.call(e))throw new Error("Unexpected options");if(void 0!==e.target&&!Oi[e.target])throw new Error(`Unexpected target "${e.target}"`);const t=Object.assign({accuracy:"default",avoidSubclass:!1,flags:"",global:!1,hasIndices:!1,lazyCompileLength:1/0,target:"auto",verbose:!1},e,{rules:Object.assign({allowOrphanBackrefs:!1,asciiWordBoundaries:!1,captureGroup:!1,recursionLimit:20,singleline:!1},e.rules)});return"auto"===t.target&&(t.target=_i.flagGroups?"ES2025":_i.unicodeSets?"ES2024":"ES2018"),t}var $i=new Set([xi(304),xi(305)]),Ri=Si`[\p{L}\p{M}\p{N}\p{Pc}]`;function Mi(e){if($i.has(e))return[e];const t=new Set,n=e.toLowerCase(),r=n.toUpperCase(),o=Fi.get(n),s=Di.get(n),i=Bi.get(n);return 1===[...r].length&&t.add(r),i&&t.add(i),o&&t.add(o),t.add(n),s&&t.add(s),[...t]}var ji=new Map("C Other\nCc Control cntrl\nCf Format\nCn Unassigned\nCo Private_Use\nCs Surrogate\nL Letter\nLC Cased_Letter\nLl Lowercase_Letter\nLm Modifier_Letter\nLo Other_Letter\nLt Titlecase_Letter\nLu Uppercase_Letter\nM Mark Combining_Mark\nMc Spacing_Mark\nMe Enclosing_Mark\nMn Nonspacing_Mark\nN Number\nNd Decimal_Number digit\nNl Letter_Number\nNo Other_Number\nP Punctuation punct\nPc Connector_Punctuation\nPd Dash_Punctuation\nPe Close_Punctuation\nPf Final_Punctuation\nPi Initial_Punctuation\nPo Other_Punctuation\nPs Open_Punctuation\nS Symbol\nSc Currency_Symbol\nSk Modifier_Symbol\nSm Math_Symbol\nSo Other_Symbol\nZ Separator\nZl Line_Separator\nZp Paragraph_Separator\nZs Space_Separator\nASCII\nASCII_Hex_Digit AHex\nAlphabetic Alpha\nAny\nAssigned\nBidi_Control Bidi_C\nBidi_Mirrored Bidi_M\nCase_Ignorable CI\nCased\nChanges_When_Casefolded CWCF\nChanges_When_Casemapped CWCM\nChanges_When_Lowercased CWL\nChanges_When_NFKC_Casefolded CWKCF\nChanges_When_Titlecased CWT\nChanges_When_Uppercased CWU\nDash\nDefault_Ignorable_Code_Point DI\nDeprecated Dep\nDiacritic Dia\nEmoji\nEmoji_Component EComp\nEmoji_Modifier EMod\nEmoji_Modifier_Base EBase\nEmoji_Presentation EPres\nExtended_Pictographic ExtPict\nExtender Ext\nGrapheme_Base Gr_Base\nGrapheme_Extend Gr_Ext\nHex_Digit Hex\nIDS_Binary_Operator IDSB\nIDS_Trinary_Operator IDST\nID_Continue IDC\nID_Start IDS\nIdeographic Ideo\nJoin_Control Join_C\nLogical_Order_Exception LOE\nLowercase Lower\nMath\nNoncharacter_Code_Point NChar\nPattern_Syntax Pat_Syn\nPattern_White_Space Pat_WS\nQuotation_Mark QMark\nRadical\nRegional_Indicator RI\nSentence_Terminal STerm\nSoft_Dotted SD\nTerminal_Punctuation Term\nUnified_Ideograph UIdeo\nUppercase Upper\nVariation_Selector VS\nWhite_Space space\nXID_Continue XIDC\nXID_Start XIDS".split(/\s/).map(e=>[qs(e),e])),Di=new Map([["s",xi(383)],[xi(383),"s"]]),Bi=new Map([[xi(223),xi(7838)],[xi(107),xi(8490)],[xi(229),xi(8491)],[xi(969),xi(8486)]]),Fi=new Map([Wi(453),Wi(456),Wi(459),Wi(498),...zi(8072,8079),...zi(8088,8095),...zi(8104,8111),Wi(8124),Wi(8140),Wi(8188)]),Gi=new Map([["alnum",Si`[\p{Alpha}\p{Nd}]`],["alpha",Si`\p{Alpha}`],["ascii",Si`\p{ASCII}`],["blank",Si`[\p{Zs}\t]`],["cntrl",Si`\p{Cc}`],["digit",Si`\p{Nd}`],["graph",Si`[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]`],["lower",Si`\p{Lower}`],["print",Si`[[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]\p{Zs}]`],["punct",Si`[\p{P}\p{S}]`],["space",Si`\p{space}`],["upper",Si`\p{Upper}`],["word",Si`[\p{Alpha}\p{M}\p{Nd}\p{Pc}]`],["xdigit",Si`\p{AHex}`]]);function Ui(e,t){const n=[];for(let r=e;r<=t;r++)n.push(r);return n}function Wi(e){const t=xi(e);return[t.toLowerCase(),t]}function zi(e,t){return Ui(e,t).map(e=>Wi(e))}var qi=new Set(["Lower","Lowercase","Upper","Uppercase","Ll","Lowercase_Letter","Lt","Titlecase_Letter","Lu","Uppercase_Letter"]);function Hi(e,t){const n=Object.assign({accuracy:"default",asciiWordBoundaries:!1,avoidSubclass:!1,bestEffortTarget:"ES2025"},t);Zi(e);const r={accuracy:n.accuracy,asciiWordBoundaries:n.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,flagDirectivesByAlt:new Map,jsGroupNameMap:new Map,minTargetEs2024:Ii(n.bestEffortTarget,"ES2024"),passedLookbehind:!1,strategy:null,subroutineRefMap:new Map,supportedGNodes:new Set,digitIsAscii:e.flags.digitIsAscii,spaceIsAscii:e.flags.spaceIsAscii,wordIsAscii:e.flags.wordIsAscii};Xs(e,Vi,r);const o={dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},s={currentFlags:o,prevFlags:null,globalFlags:o,groupOriginByCopy:new Map,groupsByName:new Map,multiplexCapturesToLeftByRef:new Map,openRefs:new Map,reffedNodesByReferencer:new Map,subroutineRefMap:r.subroutineRefMap};return Xs(e,Xi,s),Xs(e,Ki,{groupsByName:s.groupsByName,highestOrphanBackref:0,numCapturesToLeft:0,reffedNodesByReferencer:s.reffedNodesByReferencer}),e._originMap=s.groupOriginByCopy,e._strategy=r.strategy,e}var Vi={AbsenceFunction({node:e,parent:t,replaceWith:n}){const{body:r,kind:o}=e;if("repeater"!==o)throw new Error("Unsupported absence function \"(?~|\"");{const e=Ns();e.body[0].body.push(Ps({negate:!0,body:r}),js("Any"));const o=Ns();o.body[0].body.push($s("greedy",0,1/0,e)),n(ga(o,t),{traverse:!0})}},Alternative:{enter({node:e,parent:t,key:n},{flagDirectivesByAlt:r}){const o=e.body.filter(e=>"flags"===e.kind);for(let e=n+1;e<t.body.length;e++){Li(r,t.body[e],[]).push(...o)}},exit({node:e},{flagDirectivesByAlt:t}){if(t.get(e)?.length){const n=ra(t.get(e));if(n){const t=Ns({flags:n});t.body[0].body=e.body,e.body=[ga(t,e)]}}}},Assertion({node:e,parent:t,key:n,container:r,root:o,remove:s,replaceWith:i},a){const{kind:l,negate:c}=e,{asciiWordBoundaries:u,avoidSubclass:d,supportedGNodes:h,wordIsAscii:p}=a;if("text_segment_boundary"===l)throw new Error(`Unsupported text segment boundary "\\${c?"Y":"y"}"`);if("line_end"===l)i(ga(Ps({body:[ks({body:[Cs("string_end")]}),ks({body:[Ss(10)]})]}),t));else if("line_start"===l)i(ga(ha(Si`(?<=\A|\n(?!\z))`,{skipLookbehindValidation:!0}),t));else if("search_start"===l)if(h.has(e))o.flags.sticky=!0,s();else{const e=r[n-1];if(e&&ca(e))i(ga(Ps({negate:!0}),t));else{if(d)throw new Error(Si`Uses "\G" in a way that requires a subclass`);i(fa(Cs("string_start"),t)),a.strategy="clip_search"}}else if("string_end"===l||"string_start"===l);else if("string_end_newline"===l)i(ga(ha(Si`(?=\n?\z)`),t));else{if("word_boundary"!==l)throw new Error(`Unexpected assertion kind "${l}"`);if(!p&&!u){i(ga(ha(c?`(?:(?<=${Ri})(?=${Ri})|(?<!${Ri})(?!${Ri}))`:`(?:(?<=${Ri})(?!${Ri})|(?<!${Ri})(?=${Ri}))`),t))}}},Backreference({node:e},{jsGroupNameMap:t}){let{ref:n}=e;"string"!=typeof n||da(n)||(n=na(n,t),e.ref=n)},CapturingGroup({node:e},{jsGroupNameMap:t,subroutineRefMap:n}){let{name:r}=e;r&&!da(r)&&(r=na(r,t),e.name=r),n.set(e.number,e),r&&n.set(r,e)},CharacterClassRange({node:e,parent:t,replaceWith:n}){"intersection"===t.kind&&n(ga(_s({body:[e]}),t),{traverse:!0})},CharacterSet({node:e,parent:t,replaceWith:n},{accuracy:r,minTargetEs2024:o,digitIsAscii:s,spaceIsAscii:i,wordIsAscii:a}){const{kind:l,negate:c,value:u}=e;if(!s||"digit"!==l&&"digit"!==u)if(!i||"space"!==l&&"space"!==u)if(!a||"word"!==l&&"word"!==u)if("any"===l)n(fa(js("Any"),t));else if("digit"===l)n(fa(js("Nd",{negate:c}),t));else if("dot"===l);else if("text_segment"===l){if("strict"===r)throw new Error(Si`Use of "\X" requires non-strict accuracy`);const e="\\p{Emoji}(?:\\p{EMod}|\\uFE0F\\u20E3?|[\\x{E0020}-\\x{E007E}]+\\x{E007F})?",s=Si`\p{RI}{2}|${e}(?:\u200D${e})*`;n(ga(ha(Si`(?>\r\n|${o?Si`\p{RGI_Emoji}`:s}|\P{M}\p{M}*)`,{skipPropertyNameValidation:!0}),t))}else if("hex"===l)n(fa(js("AHex",{negate:c}),t));else if("newline"===l)n(ga(ha(c?"[^\n]":"(?>\r\n?|[\n\v\f\x85\u2028\u2029])"),t));else if("posix"===l)if(o||"graph"!==u&&"print"!==u)n(ga(pa(ha(Gi.get(u)),c),t));else{if("strict"===r)throw new Error(`POSIX class "${u}" requires min target ES2024 or non-strict accuracy`);let e={graph:"!-~",print:" -~"}[u];c&&(e=`\0-${xi(e.codePointAt(0)-1)}${xi(e.codePointAt(2)+1)}-\udbff\udfff`),n(ga(ha(`[${e}]`),t))}else if("property"===l)ji.has(qs(u))||(e.key="sc");else if("space"===l)n(fa(js("space",{negate:c}),t));else{if("word"!==l)throw new Error(`Unexpected character set kind "${l}"`);n(ga(pa(ha(Ri),c),t))}else n(fa(Es("word",{negate:c}),t));else n(ga(pa(ha("[\t-\r ]"),c),t));else n(fa(Es("digit",{negate:c}),t))},Directive({node:e,parent:t,root:n,remove:r,replaceWith:o,removeAllPrevSiblings:s,removeAllNextSiblings:i}){const{kind:a,flags:l}=e;if("flags"===a)if(l.enable||l.disable){const e=Ns({flags:l});e.body[0].body=i(),o(ga(e,t),{traverse:!0})}else r();else{if("keep"!==a)throw new Error(`Unexpected directive kind "${a}"`);{const e=n.body[0],r=1===n.body.length&&as(e,{type:"Group"})&&1===e.body[0].body.length?e.body[0]:n;if(t.parent!==r||r.body.length>1)throw new Error(Si`Uses "\K" in a way that's unsupported`);const i=Ps({behind:!0});i.body[0].body=s(),o(ga(i,t))}}},Flags({node:e,parent:t}){if(e.posixIsAscii)throw new Error("Unsupported flag \"P\"");if("word"===e.textSegmentMode)throw new Error("Unsupported flag \"y{w}\"");["digitIsAscii","extended","posixIsAscii","spaceIsAscii","wordIsAscii","textSegmentMode"].forEach(t=>delete e[t]),Object.assign(e,{global:!1,hasIndices:!1,multiline:!1,sticky:e.sticky??!1}),t.options={disable:{x:!0,n:!0},force:{v:!0}}},Group({node:e}){if(!e.flags)return;const{enable:t,disable:n}=e.flags;t?.extended&&delete t.extended,n?.extended&&delete n.extended,t?.dotAll&&n?.dotAll&&delete t.dotAll,t?.ignoreCase&&n?.ignoreCase&&delete t.ignoreCase,t&&!Object.keys(t).length&&delete e.flags.enable,n&&!Object.keys(n).length&&delete e.flags.disable,!e.flags.enable&&!e.flags.disable&&delete e.flags},LookaroundAssertion({node:e},t){const{kind:n}=e;"lookbehind"===n&&(t.passedLookbehind=!0)},NamedCallout({node:e,parent:t,replaceWith:n}){const{kind:r}=e;if("fail"!==r)throw new Error(`Unsupported named callout "(*${r.toUpperCase()}"`);n(ga(Ps({negate:!0}),t))},Quantifier({node:e}){if("Quantifier"===e.body.type){const t=Ns();t.body[0].body.push(e.body),e.body=ga(t,e)}},Regex:{enter({node:e},{supportedGNodes:t}){const n=[];let r=!1,o=!1;for(const t of e.body)if(1===t.body.length&&"search_start"===t.body[0].kind)t.body.pop();else{const e=ia(t.body);e?(r=!0,Array.isArray(e)?n.push(...e):n.push(e)):o=!0}r&&!o&&n.forEach(e=>t.add(e))},exit(e,{accuracy:t,passedLookbehind:n,strategy:r}){if("strict"===t&&n&&r)throw new Error(Si`Uses "\G" in a way that requires non-strict accuracy`)}},Subroutine({node:e},{jsGroupNameMap:t}){let{ref:n}=e;"string"!=typeof n||da(n)||(n=na(n,t),e.ref=n)}},Xi={Backreference({node:e},{multiplexCapturesToLeftByRef:t,reffedNodesByReferencer:n}){const{orphan:r,ref:o}=e;r||n.set(e,[...t.get(o).map(({node:e})=>e)])},CapturingGroup:{enter({node:e,parent:t,replaceWith:n,skip:r},{groupOriginByCopy:o,groupsByName:s,multiplexCapturesToLeftByRef:i,openRefs:a,reffedNodesByReferencer:l}){const c=o.get(e);if(c&&a.has(e.number)){const r=fa(ea(e.number),t);return l.set(r,a.get(e.number)),void n(r)}a.set(e.number,e),i.set(e.number,[]),e.name&&Li(i,e.name,[]);const u=i.get(e.name??e.number);for(let t=0;t<u.length;t++){const n=u[t];if(c===n.node||c&&c===n.origin||e===n.origin){u.splice(t,1);break}}if(i.get(e.number).push({node:e,origin:c}),e.name&&i.get(e.name).push({node:e,origin:c}),e.name){const t=Li(s,e.name,new Map);let n=!1;if(c)n=!0;else for(const e of t.values())if(!e.hasDuplicateNameToRemove){n=!0;break}s.get(e.name).set(e,{node:e,hasDuplicateNameToRemove:n})}},exit({node:e},{openRefs:t}){t.get(e.number)===e&&t.delete(e.number)}},Group:{enter({node:e},t){t.prevFlags=t.currentFlags,e.flags&&(t.currentFlags=Ei(t.currentFlags,e.flags))},exit(e,t){t.currentFlags=t.prevFlags}},Subroutine({node:e,parent:t,replaceWith:n},r){const{isRecursive:o,ref:s}=e;if(o){let n=t;for(;(n=n.parent)&&("CapturingGroup"!==n.type||n.name!==s&&n.number!==s););return void r.reffedNodesByReferencer.set(e,n)}const i=r.subroutineRefMap.get(s),a=0===s,l=a?ea(0):Yi(i,r.groupOriginByCopy,null);let c=l;if(!a){const e=ra(ta(i,e=>"Group"===e.type&&!!e.flags)),t=e?Ei(r.globalFlags,e):r.globalFlags;Ji(t,r.currentFlags)||(c=Ns({flags:oa(t)}),c.body[0].body.push(l))}n(ga(c,t),{traverse:!a})}},Ki={Backreference({node:e,parent:t,replaceWith:n},r){if(e.orphan)return void(r.highestOrphanBackref=Math.max(r.highestOrphanBackref,e.ref));const o=r.reffedNodesByReferencer.get(e).filter(t=>Qi(t,e));o.length?o.length>1?n(ga(Ns({atomic:!0,body:o.reverse().map(e=>ks({body:[vs(e.number)]}))}),t)):e.ref=o[0].number:n(ga(Ps({negate:!0}),t))},CapturingGroup({node:e},t){e.number=++t.numCapturesToLeft,e.name&&t.groupsByName.get(e.name).get(e).hasDuplicateNameToRemove&&delete e.name},Regex:{exit({node:e},t){const n=Math.max(t.highestOrphanBackref-t.numCapturesToLeft,0);for(let t=0;t<n;t++){const t=xs();e.body.at(-1).body.push(t)}}},Subroutine({node:e},t){e.isRecursive&&0!==e.ref&&(e.ref=t.reffedNodesByReferencer.get(e).number)}};function Zi(e){Xs(e,{"*"({node:e,parent:t}){e.parent=t}})}function Ji(e,t){return e.dotAll===t.dotAll&&e.ignoreCase===t.ignoreCase}function Qi(e,t){let n=t;do{if("Regex"===n.type)return!1;if("Alternative"===n.type)continue;if(n===e)return!1;const t=sa(n.parent);for(const r of t){if(r===n)break;if(r===e||aa(r,e))return!0}}while(n=n.parent);throw new Error("Unexpected path")}function Yi(e,t,n,r){const o=Array.isArray(e)?[]:{};for(const[s,i]of Object.entries(e))"parent"===s?o.parent=Array.isArray(n)?r:n:i&&"object"==typeof i?o[s]=Yi(i,t,o,n):("type"===s&&"CapturingGroup"===i&&t.set(o,t.get(e)??e),o[s]=i);return o}function ea(e){const t=Ms(e);return t.isRecursive=!0,t}function ta(e,t){const n=[];for(;e=e.parent;)t&&!t(e)||n.push(e);return n}function na(e,t){if(t.has(e))return t.get(e);const n=`$${t.size}_${e.replace(/^[^$_\p{IDS}]|[^$\u200C\u200D\p{IDC}]/gu,"_")}`;return t.set(e,n),n}function ra(e){const t=["dotAll","ignoreCase"],n={enable:{},disable:{}};return e.forEach(({flags:e})=>{t.forEach(t=>{e.enable?.[t]&&(delete n.disable[t],n.enable[t]=!0),e.disable?.[t]&&(n.disable[t]=!0)})}),Object.keys(n.enable).length||delete n.enable,Object.keys(n.disable).length||delete n.disable,n.enable||n.disable?n:null}function oa({dotAll:e,ignoreCase:t}){const n={};return(e||t)&&(n.enable={},e&&(n.enable.dotAll=!0),t&&(n.enable.ignoreCase=!0)),e&&t||(n.disable={},!e&&(n.disable.dotAll=!0),!t&&(n.disable.ignoreCase=!0)),n}function sa(e){if(!e)throw new Error("Node expected");const{body:t}=e;return Array.isArray(t)?t:t?[t]:null}function ia(e){const t=e.find(e=>"search_start"===e.kind||ua(e,{negate:!1})||!la(e));if(!t)return null;if("search_start"===t.kind)return t;if("LookaroundAssertion"===t.type)return t.body[0].body[0];if("CapturingGroup"===t.type||"Group"===t.type){const e=[];for(const n of t.body){const t=ia(n.body);if(!t)return null;Array.isArray(t)?e.push(...t):e.push(t)}return e}return null}function aa(e,t){const n=sa(e)??[];for(const e of n)if(e===t||aa(e,t))return!0;return!1}function la({type:e}){return"Assertion"===e||"Directive"===e||"LookaroundAssertion"===e}function ca(e){const t=["Character","CharacterClass","CharacterSet"];return t.includes(e.type)||"Quantifier"===e.type&&e.min&&t.includes(e.body.type)}function ua(e,t){const n=Object.assign({negate:null},t);return"LookaroundAssertion"===e.type&&(null===n.negate||e.negate===n.negate)&&1===e.body.length&&as(e.body[0],{type:"Assertion",kind:"search_start"})}function da(e){return/^[$_\p{IDS}][$\u200C\u200D\p{IDC}]*$/u.test(e)}function ha(e,t){const n=us(e,Object.assign({},t,{unicodePropertyMap:ji})).body;return n.length>1||n[0].body.length>1?Ns({body:n}):n[0].body[0]}function pa(e,t){return e.negate=t,e}function fa(e,t){return e.parent=t,e}function ga(e,t){return Zi(e),e.parent=t,e}function ma(e,t){const n=Ti(t),r=Ii(n.target,"ES2024"),o=Ii(n.target,"ES2025"),s=n.rules.recursionLimit;if(!Number.isInteger(s)||s<2||s>20)throw new Error("Invalid recursionLimit; use 2-20");let i=null,a=null;if(!o){const t=[e.flags.ignoreCase];Xs(e,ya,{getCurrentModI:()=>t.at(-1),popModI(){t.pop()},pushModI(e){t.push(e)},setHasCasedChar(){t.at(-1)?i=!0:a=!0}})}const l={dotAll:e.flags.dotAll,ignoreCase:!(!e.flags.ignoreCase&&!i||a)};let c=e;const u={accuracy:n.accuracy,appliedGlobalFlags:l,captureMap:new Map,currentFlags:{dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},inCharClass:!1,lastNode:c,originMap:e._originMap,recursionLimit:s,useAppliedIgnoreCase:!(o||!i||!a),useFlagMods:o,useFlagV:r,verbose:n.verbose};function d(e){return u.lastNode=c,c=e,Ni(ba[e.type],`Unexpected node type "${e.type}"`)(e,u,d)}const h={pattern:e.body.map(d).join("|"),flags:d(e.flags),options:Object.assign({},e.options)};return r||(delete h.options.force.v,h.options.disable.v=!0,h.options.unicodeSetsPlugin=null),h._captureTransfers=new Map,h._hiddenCaptures=[],u.captureMap.forEach((e,t)=>{e.hidden&&h._hiddenCaptures.push(t),e.transferTo&&Li(h._captureTransfers,e.transferTo,[]).push(t)}),h}var ya={"*":{enter({node:e},t){if(Na(e)){const n=t.getCurrentModI();t.pushModI(e.flags?Ei({ignoreCase:n},e.flags).ignoreCase:n)}},exit({node:e},t){Na(e)&&t.popModI()}},Backreference(e,t){t.setHasCasedChar()},Character({node:e},t){Sa(xi(e.value))&&t.setHasCasedChar()},CharacterClassRange({node:e,skip:t},n){t(),_a(e,{firstOnly:!0}).length&&n.setHasCasedChar()},CharacterSet({node:e},t){"property"===e.kind&&qi.has(e.value)&&t.setHasCasedChar()}},ba={Alternative:({body:e},t,n)=>e.map(n).join(""),Assertion({kind:e,negate:t}){if("string_end"===e)return"$";if("string_start"===e)return"^";if("word_boundary"===e)return t?Si`\B`:Si`\b`;throw new Error(`Unexpected assertion kind "${e}"`)},Backreference({ref:e},t){if("number"!=typeof e)throw new Error("Unexpected named backref in transformed AST");if(!t.useFlagMods&&"strict"===t.accuracy&&t.currentFlags.ignoreCase&&!t.captureMap.get(e).ignoreCase)throw new Error("Use of case-insensitive backref to case-sensitive group requires target ES2025 or non-strict accuracy");return"\\"+e},CapturingGroup(e,t,n){const{body:r,name:o,number:s}=e,i={ignoreCase:t.currentFlags.ignoreCase},a=t.originMap.get(e);return a&&(i.hidden=!0,s>a.number&&(i.transferTo=a.number)),t.captureMap.set(s,i),`(${o?`?<${o}>`:""}${r.map(n).join("|")})`},Character({value:e},t){const n=xi(e),r=Aa(e,{escDigit:"Backreference"===t.lastNode.type,inCharClass:t.inCharClass,useFlagV:t.useFlagV});if(r!==n)return r;if(t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&Sa(n)){const e=Mi(n);return t.inCharClass?e.join(""):e.length>1?`[${e.join("")}]`:e[0]}return n},CharacterClass(e,t,n){const{kind:r,negate:o,parent:s}=e;let{body:i}=e;if("intersection"===r&&!t.useFlagV)throw new Error("Use of character class intersection requires min target ES2024");_i.bugFlagVLiteralHyphenIsRange&&t.useFlagV&&i.some(Pa)&&(i=[Ss(45),...i.filter(e=>!Pa(e))]);const a=()=>`[${o?"^":""}${i.map(n).join("intersection"===r?"&&":"")}]`;if(!t.inCharClass){if((!t.useFlagV||_i.bugNestedClassIgnoresNegation)&&!o){const t=i.filter(e=>"CharacterClass"===e.type&&"union"===e.kind&&e.negate);if(t.length){const r=Ns(),o=r.body[0];return r.parent=s,o.parent=r,i=i.filter(e=>!t.includes(e)),e.body=i,i.length?(e.parent=o,o.body.push(e)):r.body.pop(),t.forEach(e=>{const t=ks({body:[e]});e.parent=t,t.parent=r,r.body.push(t)}),n(r)}}t.inCharClass=!0;const r=a();return t.inCharClass=!1,r}const l=i[0];if("union"===r&&!o&&l&&((!t.useFlagV||!t.verbose)&&"union"===s.kind&&(!_i.bugFlagVLiteralHyphenIsRange||!t.useFlagV)||!t.verbose&&"intersection"===s.kind&&1===i.length&&"CharacterClassRange"!==l.type))return i.map(n).join("");if(!t.useFlagV&&"CharacterClass"===s.type)throw new Error("Uses nested character class in a way that requires min target ES2024");return a()},CharacterClassRange(e,t){const n=e.min.value,r=e.max.value,o={escDigit:!1,inCharClass:!0,useFlagV:t.useFlagV},s=Aa(n,o),i=Aa(r,o),a=new Set;return t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&Ea(_a(e)).forEach(e=>{a.add(Array.isArray(e)?`${Aa(e[0],o)}-${Aa(e[1],o)}`:Aa(e,o))}),`${s}-${i}${[...a].join("")}`},CharacterSet({kind:e,negate:t,value:n,key:r},o){if("dot"===e)return o.currentFlags.dotAll?o.appliedGlobalFlags.dotAll||o.useFlagMods?".":"[^]":Si`[^\n]`;if("digit"===e)return t?Si`\D`:Si`\d`;if("property"===e){if(o.useAppliedIgnoreCase&&o.currentFlags.ignoreCase&&qi.has(n))throw new Error(`Unicode property "${n}" can't be case-insensitive when other chars have specific case`);return`${t?Si`\P`:Si`\p`}{${r?`${r}=`:""}${n}}`}if("word"===e)return t?Si`\W`:Si`\w`;throw new Error(`Unexpected character set kind "${e}"`)},Flags:(e,t)=>(t.appliedGlobalFlags.ignoreCase?"i":"")+(e.dotAll?"s":"")+(e.sticky?"y":""),Group({atomic:e,body:t,flags:n,parent:r},o,s){const i=o.currentFlags;n&&(o.currentFlags=Ei(i,n));const a=t.map(s).join("|"),l=o.verbose||1!==t.length||"Quantifier"===r.type||e||o.useFlagMods&&n?`(?${La(e,n,o.useFlagMods)}${a})`:a;return o.currentFlags=i,l},LookaroundAssertion:({body:e,kind:t,negate:n},r,o)=>`(?${"lookahead"===t?"":"<"}${n?"!":"="}${e.map(o).join("|")})`,Quantifier:(e,t,n)=>n(e.body)+Ia(e),Subroutine({isRecursive:e,ref:t},n){if(!e)throw new Error("Unexpected non-recursive subroutine in transformed AST");const r=n.recursionLimit;return 0===t?`(?R=${r})`:Si`\g<${t}&R=${r}>`}},wa=new Set(["$","(",")","*","+",".","?","[","\\","]","^","{","|","}"]),ka=new Set(["-","\\","]","^","["]),Ca=new Set(["(",")","-","/","[","\\","]","^","{","|","}","!","#","$","%","&","*","+",",",".",":",";","<","=",">","?","@","`","~"]),va=new Map([[9,Si`\t`],[10,Si`\n`],[11,Si`\v`],[12,Si`\f`],[13,Si`\r`],[8232,Si`\u2028`],[8233,Si`\u2029`],[65279,Si`\uFEFF`]]),xa=/^\p{Cased}$/u;function Sa(e){return xa.test(e)}function _a(e,t){const n=!!t?.firstOnly,r=e.min.value,o=e.max.value,s=[];if(r<65&&(65535===o||o>=131071)||65536===r&&o>=131071)return s;for(let e=r;e<=o;e++){const t=xi(e);if(!Sa(t))continue;const i=Mi(t).filter(e=>{const t=e.codePointAt(0);return t<r||t>o});if(i.length&&(s.push(...i),n))break}return s}function Aa(e,{escDigit:t,inCharClass:n,useFlagV:r}){if(va.has(e))return va.get(e);if(e<32||e>126&&e<160||e>262143||t&&((o=e)>47&&o<58))return e>255?`\\u{${e.toString(16).toUpperCase()}}`:`\\x${e.toString(16).toUpperCase().padStart(2,"0")}`;var o;const s=n?r?Ca:ka:wa,i=xi(e);return(s.has(i)?"\\":"")+i}function Ea(e){const t=e.map(e=>e.codePointAt(0)).sort((e,t)=>e-t),n=[];let r=null;for(let e=0;e<t.length;e++)t[e+1]===t[e]+1?r??=t[e]:null===r?n.push(t[e]):(n.push([r,t[e]]),r=null);return n}function La(e,t,n){if(e)return">";let r="";if(t&&n){const{enable:e,disable:n}=t;r=(e?.ignoreCase?"i":"")+(e?.dotAll?"s":"")+(n?"-":"")+(n?.ignoreCase?"i":"")+(n?.dotAll?"s":"")}return`${r}:`}function Ia({kind:e,max:t,min:n}){let r;return r=n||1!==t?n||t!==1/0?1===n&&t===1/0?"+":n===t?`{${n}}`:`{${n},${t===1/0?"":t}}`:"*":"?",r+{greedy:"",lazy:"?",possessive:"+"}[e]}function Na({type:e}){return"CapturingGroup"===e||"Group"===e||"LookaroundAssertion"===e}function Pa({type:e,value:t}){return"Character"===e&&45===t}var Oa=(a=f("captureMap"),l=f("compiled"),c=f("pattern"),u=f("nameMap"),d=f("strategy"),h=f("execCore"),class e extends RegExp{get source(){return p(this,c)[c]||"(?:)"}constructor(t,n,r){const o=!!r?.lazyCompile;if(t instanceof RegExp){if(r)throw new Error("Cannot provide options when copying a regexp");const o=t;super(o,n),Object.defineProperty(this,h,{value:Ta}),Object.defineProperty(this,a,{writable:!0,value:new Map}),Object.defineProperty(this,l,{writable:!0,value:null}),Object.defineProperty(this,c,{writable:!0,value:void 0}),Object.defineProperty(this,u,{writable:!0,value:null}),Object.defineProperty(this,d,{writable:!0,value:null}),this.rawOptions={},p(this,c)[c]=o.source,o instanceof e&&(p(this,a)[a]=p(o,a)[a],p(this,u)[u]=p(o,u)[u],p(this,d)[d]=p(o,d)[d],this.rawOptions=o.rawOptions)}else{const e=Object.assign({hiddenCaptures:[],strategy:null,transfers:[]},r);super(o?"":t,n),Object.defineProperty(this,h,{value:Ta}),Object.defineProperty(this,a,{writable:!0,value:new Map}),Object.defineProperty(this,l,{writable:!0,value:null}),Object.defineProperty(this,c,{writable:!0,value:void 0}),Object.defineProperty(this,u,{writable:!0,value:null}),Object.defineProperty(this,d,{writable:!0,value:null}),this.rawOptions={},p(this,c)[c]=t,p(this,a)[a]=Ra(e.hiddenCaptures,e.transfers),p(this,d)[d]=e.strategy,this.rawOptions=r??{}}o||(p(this,l)[l]=this)}exec(t){if(!p(this,l)[l]){const t=this.rawOptions,n=g(t,y);p(this,l)[l]=new e(p(this,c)[c],this.flags,n)}const n=this.global||this.sticky,r=this.lastIndex;if("clip_search"===p(this,d)[d]&&n&&r){this.lastIndex=0;const e=p(this,h)[h](t.slice(r));return e&&($a(e,r,t,this.hasIndices),this.lastIndex+=r),e}return p(this,h)[h](t)}});function Ta(e){p(this,l)[l].lastIndex=this.lastIndex;const t=RegExp.prototype.exec.call(p(this,l)[l],e);if(this.lastIndex=p(this,l)[l].lastIndex,!t||!p(this,a)[a].size)return t;const n=[...t];let r;t.length=1,this.hasIndices&&(r=[...t.indices],t.indices.length=1);const o=[0];for(let e=1;e<n.length;e++){const{hidden:s,transferTo:i}=p(this,a)[a].get(e)??{};if(s?o.push(null):(o.push(t.length),t.push(n[e]),this.hasIndices&&t.indices.push(r[e])),i&&void 0!==n[e]){const s=o[i];if(!s)throw new Error(`Invalid capture transfer to "${s}"`);if(t[s]=n[e],this.hasIndices&&(t.indices[s]=r[e]),t.groups){p(this,u)[u]||(p(this,u)[u]=Ma(this.source));const o=p(this,u)[u].get(i);o&&(t.groups[o]=n[e],this.hasIndices&&(t.indices.groups[o]=r[e]))}}}return t}function $a(e,t,n,r){if(e.index+=t,e.input=n,r){const n=e.indices;for(let e=0;e<n.length;e++){const r=n[e];r&&(n[e]=[r[0]+t,r[1]+t])}const r=n.groups;r&&Object.keys(r).forEach(e=>{const n=r[e];n&&(r[e]=[n[0]+t,n[1]+t])})}}function Ra(e,t){const n=new Map;for(const t of e)n.set(t,{hidden:!0});for(const[e,r]of t)for(const t of r)Li(n,t,{}).transferTo=e;return n}function Ma(e){const t=/(?<capture>\((?:\?<(?![=!])(?<name>[^>]+)>|(?!\?)))|\\?./gsu,n=new Map;let r,o=0,s=0;for(;r=t.exec(e);){const{0:e,groups:{capture:t,name:i}}=r;"["===e?o++:o?"]"===e&&o--:t&&(s++,i&&n.set(s,i))}return n}function ja(e,t){const n=Da(e,t);return n.options?new Oa(n.pattern,n.flags,n.options):new RegExp(n.pattern,n.flags)}function Da(e,t){const n=Ti(t),r=Hi(us(e,{flags:n.flags,normalizeUnknownPropertyNames:!0,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline},skipBackrefValidation:n.rules.allowOrphanBackrefs,unicodePropertyMap:ji}),{accuracy:n.accuracy,asciiWordBoundaries:n.rules.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,bestEffortTarget:n.target}),o=ma(r,n),s=yi(o.pattern,{captureTransfers:o._captureTransfers,hiddenCaptures:o._hiddenCaptures,mode:"external"}),i=ai(ui(s.pattern).pattern,{captureTransfers:s.captureTransfers,hiddenCaptures:s.hiddenCaptures}),a={pattern:i.pattern,flags:`${n.hasIndices?"d":""}${n.global?"g":""}${o.flags}${o.options.disable.v?"u":"v"}`};if(n.avoidSubclass){if(n.lazyCompileLength!==1/0)throw new Error("Lazy compilation requires subclass")}else{const e=i.hiddenCaptures.sort((e,t)=>e-t),t=Array.from(i.captureTransfers),o=r._strategy,s=a.pattern.length>=n.lazyCompileLength;(e.length||t.length||o||s)&&(a.options=Object.assign({},e.length&&{hiddenCaptures:e},t.length&&{transfers:t},o&&{strategy:o},s&&{lazyCompile:s}))}return a}function Ba(e,t){return ja(e,Object.assign({global:!0,hasIndices:!0,lazyCompileLength:3e3,rules:{allowOrphanBackrefs:!0,asciiWordBoundaries:!0,captureGroup:!0,recursionLimit:5,singleline:!0}},t))}function Fa(e={}){const t=Object.assign({target:"auto",cache:new Map},e);return t.regexConstructor||=e=>Ba(e,{target:t.target}),{createScanner:e=>new mo(e,t),createString:e=>({content:e})}}var Ga=k({createOnigurumaEngine:()=>hl,getDefaultWasmLoader:()=>dl,loadWasm:()=>al,setDefaultWasmLoader:()=>ul}),Ua=class extends Error{constructor(e){super(e),this.name="ShikiError"}};function Wa(){return"undefined"!=typeof performance?performance.now():Date.now()}const za=(e,t)=>e+(t-e%t)%t;async function qa(e){let t,n;const r={};function o(e){n=e,r.HEAPU8=new Uint8Array(e),r.HEAPU32=new Uint32Array(e)}function s(e){try{return t.grow(e-n.byteLength+65535>>>16),o(t.buffer),1}catch{}}const i="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function a(e,t,n=1024){const r=t+n;let o=t;for(;e[o]&&!(o>=r);)++o;if(o-t>16&&e.buffer&&i)return i.decode(e.subarray(t,o));let s="";for(;t<o;){let n=e[t++];if(!(128&n)){s+=String.fromCharCode(n);continue}const r=63&e[t++];if(192==(224&n)){s+=String.fromCharCode((31&n)<<6|r);continue}const o=63&e[t++];if(n=224==(240&n)?(15&n)<<12|r<<6|o:(7&n)<<18|r<<12|o<<6|63&e[t++],n<65536)s+=String.fromCharCode(n);else{const e=n-65536;s+=String.fromCharCode(55296|e>>10,56320|1023&e)}}return s}function l(e,t){return e?a(r.HEAPU8,e,t):""}const c={emscripten_get_now:Wa,emscripten_memcpy_big:function(e,t,n){r.HEAPU8.copyWithin(e,t,t+n)},emscripten_resize_heap:function(e){const t=r.HEAPU8.length,n=2147483648;if((e>>>=0)>n)return!1;for(let r=1;r<=4;r*=2){let o=t*(1+.2/r);if(o=Math.min(o,e+100663296),s(Math.min(n,za(Math.max(e,o),65536))))return!0}return!1},fd_write:()=>0};return await(async function(){const n=await e({env:c,wasi_snapshot_preview1:c});t=n.memory,o(t.buffer),Object.assign(r,n),r.UTF8ToString=l})(),r}var Ha=Object.defineProperty,Va=(e,t,n)=>t in e?Ha(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Xa=(e,t,n)=>Va(e,"symbol"!=typeof t?t+"":t,n);let Ka=null;function Za(e){throw new Ua(e.UTF8ToString(e.getLastOnigError()))}var Ja=class e{constructor(t){Xa(this,"utf16Length"),Xa(this,"utf8Length"),Xa(this,"utf16Value"),Xa(this,"utf8Value"),Xa(this,"utf16OffsetToUtf8"),Xa(this,"utf8OffsetToUtf16");const n=t.length,r=e._utf8ByteLength(t),o=r!==n,s=o?new Uint32Array(n+1):null;o&&(s[n]=r);const i=o?new Uint32Array(r+1):null;o&&(i[r]=n);const a=new Uint8Array(r);let l=0;for(let e=0;e<n;e++){const r=t.charCodeAt(e);let c=r,u=!1;if(r>=55296&&r<=56319&&e+1<n){const n=t.charCodeAt(e+1);n>=56320&&n<=57343&&(c=65536+(r-55296<<10)|n-56320,u=!0)}o&&(s[e]=l,u&&(s[e+1]=l),c<=127?i[l+0]=e:c<=2047?(i[l+0]=e,i[l+1]=e):c<=65535?(i[l+0]=e,i[l+1]=e,i[l+2]=e):(i[l+0]=e,i[l+1]=e,i[l+2]=e,i[l+3]=e)),c<=127?a[l++]=c:c<=2047?(a[l++]=192|(1984&c)>>>6,a[l++]=128|(63&c)>>>0):c<=65535?(a[l++]=224|(61440&c)>>>12,a[l++]=128|(4032&c)>>>6,a[l++]=128|(63&c)>>>0):(a[l++]=240|(1835008&c)>>>18,a[l++]=128|(258048&c)>>>12,a[l++]=128|(4032&c)>>>6,a[l++]=128|(63&c)>>>0),u&&e++}this.utf16Length=n,this.utf8Length=r,this.utf16Value=t,this.utf8Value=a,this.utf16OffsetToUtf8=s,this.utf8OffsetToUtf16=i}static _utf8ByteLength(e){let t=0;for(let n=0,r=e.length;n<r;n++){const o=e.charCodeAt(n);let s=o,i=!1;if(o>=55296&&o<=56319&&n+1<r){const t=e.charCodeAt(n+1);t>=56320&&t<=57343&&(s=65536+(o-55296<<10)|t-56320,i=!0)}t+=s<=127?1:s<=2047?2:s<=65535?3:4,i&&n++}return t}createString(e){const t=e.omalloc(this.utf8Length);return e.HEAPU8.set(this.utf8Value,t),t}};const Qa=class e{constructor(t){if(Xa(this,"id",++e.LAST_ID),Xa(this,"_onigBinding"),Xa(this,"content"),Xa(this,"utf16Length"),Xa(this,"utf8Length"),Xa(this,"utf16OffsetToUtf8"),Xa(this,"utf8OffsetToUtf16"),Xa(this,"ptr"),!Ka)throw new Ua("Must invoke loadWasm first.");this._onigBinding=Ka,this.content=t;const n=new Ja(t);this.utf16Length=n.utf16Length,this.utf8Length=n.utf8Length,this.utf16OffsetToUtf8=n.utf16OffsetToUtf8,this.utf8OffsetToUtf16=n.utf8OffsetToUtf16,this.utf8Length<1e4&&!e._sharedPtrInUse?(e._sharedPtr||(e._sharedPtr=Ka.omalloc(1e4)),e._sharedPtrInUse=!0,Ka.HEAPU8.set(n.utf8Value,e._sharedPtr),this.ptr=e._sharedPtr):this.ptr=n.createString(Ka)}convertUtf8OffsetToUtf16(e){return this.utf8OffsetToUtf16?e<0?0:e>this.utf8Length?this.utf16Length:this.utf8OffsetToUtf16[e]:e}convertUtf16OffsetToUtf8(e){return this.utf16OffsetToUtf8?e<0?0:e>this.utf16Length?this.utf8Length:this.utf16OffsetToUtf8[e]:e}dispose(){this.ptr===e._sharedPtr?e._sharedPtrInUse=!1:this._onigBinding.ofree(this.ptr)}};Xa(Qa,"LAST_ID",0),Xa(Qa,"_sharedPtr",0),Xa(Qa,"_sharedPtrInUse",!1);let Ya=Qa;var el=class{constructor(e){if(Xa(this,"_onigBinding"),Xa(this,"_ptr"),!Ka)throw new Ua("Must invoke loadWasm first.");const t=[],n=[];for(let r=0,o=e.length;r<o;r++){const o=new Ja(e[r]);t[r]=o.createString(Ka),n[r]=o.utf8Length}const r=Ka.omalloc(4*e.length);Ka.HEAPU32.set(t,r/4);const o=Ka.omalloc(4*e.length);Ka.HEAPU32.set(n,o/4);const s=Ka.createOnigScanner(r,o,e.length);for(let n=0,r=e.length;n<r;n++)Ka.ofree(t[n]);Ka.ofree(o),Ka.ofree(r),0===s&&Za(Ka),this._onigBinding=Ka,this._ptr=s}dispose(){this._onigBinding.freeOnigScanner(this._ptr)}findNextMatchSync(e,t,n){let r=0;if("number"==typeof n&&(r=n),"string"==typeof e){e=new Ya(e);const n=this._findNextMatchSync(e,t,!1,r);return e.dispose(),n}return this._findNextMatchSync(e,t,!1,r)}_findNextMatchSync(e,t,n,r){const o=this._onigBinding,s=o.findNextOnigScannerMatch(this._ptr,e.id,e.ptr,e.utf8Length,e.convertUtf16OffsetToUtf8(t),r);if(0===s)return null;const i=o.HEAPU32;let a=s/4;const l=i[a++],c=i[a++],u=[];for(let t=0;t<c;t++){const n=e.convertUtf8OffsetToUtf16(i[a++]),r=e.convertUtf8OffsetToUtf16(i[a++]);u[t]={start:n,end:r,length:r-n}}return{index:l,captureIndices:u}}};function tl(e){return"function"==typeof e.default}function nl(e){return void 0!==e.data}function rl(e){return"undefined"!=typeof Response&&e instanceof Response}function ol(e){return"undefined"!=typeof ArrayBuffer&&(e instanceof ArrayBuffer||ArrayBuffer.isView(e))||"undefined"!=typeof Buffer&&Buffer.isBuffer?.(e)||"undefined"!=typeof SharedArrayBuffer&&e instanceof SharedArrayBuffer||"undefined"!=typeof Uint32Array&&e instanceof Uint32Array}let sl,il;function al(e){if(sl)return sl;return sl=(async function(){Ka=await qa(async t=>{let n=e;var r;return n=await n,"function"==typeof n&&(n=await n(t)),"function"==typeof n&&(n=await n(t)),"function"==typeof n.instantiator?n=await n.instantiator(t):tl(n)?n=await n.default(t):(nl(n)&&(n=n.data),rl(n)?n="function"==typeof WebAssembly.instantiateStreaming?await(r=n,e=>WebAssembly.instantiateStreaming(r,e))(t):await cl(n)(t):ol(n)||n instanceof WebAssembly.Module?n=await ll(n)(t):"default"in n&&n.default instanceof WebAssembly.Module&&(n=await ll(n.default)(t))),"instance"in n&&(n=n.instance),"exports"in n&&(n=n.exports),n})})(),sl}function ll(e){return t=>WebAssembly.instantiate(e,t)}function cl(e){return async t=>{const n=await e.arrayBuffer();return WebAssembly.instantiate(n,t)}}function ul(e){il=e}function dl(){return il}async function hl(e){return e&&await al(e),{createScanner:e=>new el(e.map(e=>"string"==typeof e?e:e.source)),createString:e=>new Ya(e)}}var pl,fl;A(_({}),pl=Ga,"default"),fl&&A(fl,pl,"default"),(()=>{try{return!1}catch{return!1}})();const gl={dark:"pierre-dark",light:"pierre-light"};Object.freeze({fromStart:0,fromEnd:0});const ml=new Map,yl=new Set;function bl(e,t){e=Array.isArray(e)?e:[e];for(const n of e){if(yl.has(n.name))continue;let e=ml.get(n.name);null==e&&(e=n,ml.set(n.name,e));const r=e.data.find(t=>t.name===e.name||!0===t.aliases?.includes(e.name));if(null==r)throw new Error(`attachResolvedLanguages: No returned grammar declares "${e.name}" as its name or an alias.`);t.loadLanguageSync(e.data);try{t.getLanguage(e.name)}catch{throw new Error(`attachResolvedLanguages: "${r.name}" is already loaded without alias "${e.name}". Load the alias first or give the grammar a unique name.`)}yl.add(e.name)}}const wl=new Set;var kl=class extends Error{constructor(e){super(`Theme "${e}" is already registered`),this.name="DuplicateThemeError"}},Cl=class extends Error{constructor(e){super(`No loader registered for theme "${e}"`),this.name="UnregisteredThemeError"}},vl=class extends Error{constructor(e){super(`Theme "${e}" has not been resolved`),this.name="UnresolvedThemeError"}};const xl=(function(){const e=new Map,t=new Map,n=new Map;let r=0;function o(o){const s=t.get(o);if(void 0!==s)return Promise.resolve(s);const i=n.get(o);if(void 0!==i)return i;const a=e.get(o);if(void 0===a)return Promise.reject(new Cl(o));const l=r,c=a().then(e=>{const s=null!==(i=e)&&"object"==typeof i&&"default"in i?i.default:i;var i;return l===r&&t.set(o,s),n.get(o)===c&&n.delete(o),s}).catch(e=>{throw n.get(o)===c&&n.delete(o),e});return n.set(o,c),c}function s(e,n){t.set(e,n)}return{clearResolvedThemes:function(){r++,t.clear(),n.clear()},getResolvedOrResolveTheme:function(e){const n=t.get(e);return void 0!==n?n:o(e)},getResolvedTheme:function(e){return t.get(e)},getResolvedThemes:function(e){const n=[];for(const r of e){const e=t.get(r);if(void 0===e)throw new vl(r);n.push(e)}return n},hasRegisteredTheme:function(t){return e.has(t)},hasResolvedTheme:function(e){return t.has(e)},hasResolvedThemes:function(e){for(const n of e)if(!t.has(n))return!1;return!0},registerTheme:function(t,n){if(e.has(t))throw new kl(t);e.set(t,n)},registerThemeIfAbsent:function(t,n){return!e.has(t)&&(e.set(t,n),!0)},resolveTheme:o,resolveThemes:function(e){return Promise.all(e.map(e=>o(e)))},seedResolvedTheme:s,seedResolvedThemes:function(e){for(const[t,n]of e)s(t,n)}}})();function Sl(e,t){e=Array.isArray(e)?e:[e];for(let n of e){let e;if("string"==typeof n){if(e=xl.getResolvedTheme(n),null==e)throw new Error(`loadResolvedThemes: ${n} is not resolved, you must resolve it before calling loadResolvedThemes`)}else e=n,n=n.name,null==xl.getResolvedTheme(n)&&xl.seedResolvedTheme(n,e);wl.has(n)||(wl.add(n),t.loadThemeSync(e))}}const _l=new Map;let Al=0;const El={"1c":"1c",abap:"abap",as:"actionscript-3",ada:"ada",adb:"ada",ads:"ada",adoc:"asciidoc",asciidoc:"asciidoc","component.html":"angular-html","component.ts":"angular-ts",conf:"nginx",htaccess:"apache",cls:"tex",trigger:"apex",apl:"apl",applescript:"applescript",scpt:"applescript",ara:"ara",asm:"asm",s:"riscv",astro:"astro",awk:"awk",bal:"ballerina",sh:"zsh",bash:"zsh",bat:"cmd",cmd:"cmd",be:"berry",beancount:"beancount",bib:"bibtex",bicep:"bicep","blade.php":"blade",bsl:"bsl",c:"c",h:"objective-cpp",cs:"csharp",cpp:"cpp",hpp:"cpp",cc:"cpp",cxx:"cpp",hh:"cpp",cdc:"cdc",cairo:"cairo",clar:"clarity",clj:"clojure",cljs:"clojure",cljc:"clojure",soy:"soy",cmake:"cmake","CMakeLists.txt":"cmake",cob:"cobol",cbl:"cobol",cobol:"cobol",CODEOWNERS:"codeowners",ql:"ql",coffee:"coffeescript",lisp:"lisp",cl:"lisp",lsp:"lisp",log:"log",v:"verilog",cql:"cql",cr:"crystal",css:"css",csv:"csv",cue:"cue",cypher:"cypher",cyp:"cypher",d:"d",dart:"dart",dax:"dax",desktop:"desktop",diff:"diff",patch:"diff",Dockerfile:"dockerfile",dockerfile:"dockerfile",env:"dotenv",dm:"dream-maker",edge:"edge",el:"emacs-lisp",ex:"elixir",exs:"elixir",elm:"elm",erb:"erb",erl:"erlang",hrl:"erlang",f:"fortran-fixed-form",for:"fortran-fixed-form",fs:"fsharp",fsi:"fsharp",fsx:"fsharp",f03:"f03",f08:"f08",f18:"f18",f77:"f77",f90:"fortran-free-form",f95:"fortran-free-form",fnl:"fennel",fish:"fish",ftl:"ftl",tres:"gdresource",res:"gdresource",gd:"gdscript",gdshader:"gdshader",gs:"genie",feature:"gherkin",COMMIT_EDITMSG:"git-commit","git-rebase-todo":"git-rebase",gjs:"glimmer-js",gleam:"gleam",gts:"glimmer-ts",glsl:"glsl",vert:"glsl",frag:"glsl",shader:"shaderlab",gp:"gnuplot",plt:"gnuplot",gnuplot:"gnuplot",go:"go",graphql:"graphql",gql:"graphql",groovy:"groovy",gvy:"groovy",hack:"hack",haml:"haml",hbs:"handlebars",handlebars:"handlebars",hs:"haskell",lhs:"haskell",hx:"haxe",hcl:"hcl",hjson:"hjson",hlsl:"hlsl",fx:"hlsl",html:"html",htm:"html",http:"http",rest:"http",hxml:"hxml",hy:"hy",imba:"imba",ini:"ini",cfg:"ini",jade:"pug",pug:"pug",java:"java",js:"javascript",mjs:"javascript",cjs:"javascript",jinja:"jinja",jinja2:"jinja",j2:"jinja",jison:"jison",jl:"julia",json:"json",json5:"json5",jsonc:"jsonc",jsonl:"jsonl",jsonnet:"jsonnet",libsonnet:"jsonnet",jssm:"jssm",jsx:"jsx",kt:"kotlin",kts:"kts",kql:"kusto",tex:"tex",ltx:"tex",lean:"lean4",less:"less",liquid:"liquid",lit:"lit",ll:"llvm",logo:"logo",lua:"lua",luau:"luau",Makefile:"makefile",mk:"makefile",makefile:"makefile",md:"markdown",markdown:"markdown",marko:"marko",m:"wolfram",mat:"matlab",mdc:"mdc",mdx:"mdx",wiki:"wikitext",mediawiki:"wikitext",mmd:"mermaid",mermaid:"mermaid",mips:"mipsasm",mojo:"mojo","\ud83d\udd25":"mojo",move:"move",nar:"narrat",nf:"nextflow",nim:"nim",nims:"nim",nimble:"nim",nix:"nix",nu:"nushell",mm:"objective-cpp",ml:"ocaml",mli:"ocaml",mll:"ocaml",mly:"ocaml",odin:"odin",pas:"pascal",p:"pascal",pl:"prolog",pm:"perl",t:"perl",raku:"raku",p6:"raku",pl6:"raku",php:"php",phtml:"php",pls:"plsql",sql:"sql",po:"po",polar:"polar",pcss:"postcss",pot:"pot",potx:"potx",pq:"powerquery",pqm:"powerquery",ps1:"powershell",psm1:"powershell",psd1:"powershell",prisma:"prisma",pro:"prolog",P:"prolog",properties:"properties",proto:"protobuf",pp:"puppet",purs:"purescript",py:"python",pyw:"python",pyi:"python",BUCK:"python",BUILD:"python",PACKAGE:"python",WORKSPACE:"python",Tiltfile:"python",bazel:"python",bxl:"python",bzl:"python",bzlmod:"python",star:"python",sky:"python",qml:"qml",qmldir:"qmldir",qss:"qss",r:"r",R:"r",rkt:"racket",rktl:"racket",razor:"razor",cshtml:"razor",rb:"ruby",rbw:"ruby",reg:"reg",regex:"regexp",rel:"rel",rs:"rust",rst:"rst",rake:"ruby",gemspec:"ruby",jbuilder:"ruby",builder:"ruby",rabl:"ruby",arb:"ruby",ru:"ruby",podspec:"ruby",Gemfile:"ruby",Rakefile:"ruby",Guardfile:"ruby",Capfile:"ruby",Berksfile:"ruby",Brewfile:"ruby",Vagrantfile:"ruby",Thorfile:"ruby",Appraisals:"ruby",Dangerfile:"ruby",sas:"sas",sass:"sass",scala:"scala",sc:"scala",scm:"scheme",ss:"scheme",sld:"scheme",scss:"scss",sdbl:"sdbl",shadergraph:"shader",st:"smalltalk",sol:"solidity",sparql:"sparql",rq:"sparql",spl:"splunk",config:"ssh-config",do:"stata",ado:"stata",dta:"stata",styl:"stylus",stylus:"stylus",svelte:"svelte",swift:"swift",sv:"system-verilog",svh:"system-verilog",service:"systemd",socket:"systemd",device:"systemd",timer:"systemd",talon:"talonscript",tasl:"tasl",tcl:"tcl",templ:"templ",tf:"tf",tfvars:"tfvars",toml:"toml",ts:"typescript",mts:"typescript",cts:"typescript",tsp:"typespec",tsv:"tsv",tsx:"tsx",ttl:"turtle",twig:"twig",typ:"typst",vv:"v",vala:"vala",vapi:"vala",vb:"vb",vbs:"vb",bas:"vb",vh:"verilog",vhd:"vhdl",vhdl:"vhdl",vim:"vimscript",vue:"vue","vine.ts":"vue-vine",vy:"vyper",wasm:"wasm",wat:"wasm",wy:"\u6587\u8a00",wgsl:"wgsl",wit:"wit",wl:"wolfram",nb:"wolfram",xml:"xml",xsl:"xsl",xslt:"xsl",yaml:"yaml",yml:"yml",zs:"zenscript",zig:"zig",zsh:"zsh",sty:"tex"};function Ll(e){const t=Il(e);if(null!=t)return t;const n=e.split(/[/\\]/).pop()??e;return n===e?"text":Il(n)??"text"}function Il(e){if(_l.has(e))return _l.get(e)??"text";if(Object.hasOwn(El,e))return El[e]??null;const t=e.match(/\.([^/\\]+\.[^/\\]+)$/);if(null!=t){if(_l.has(t[1]))return _l.get(t[1])??"text";if(Object.hasOwn(El,t[1]))return El[t[1]]??"text"}const n=e.match(/\.([^.]+)$/)?.[1]??"";return _l.has(n)?_l.get(n)??"text":Object.hasOwn(El,n)?El[n]??"text":null}function Nl(e,t){if(e<=Al)return!1;_l.clear();for(const e in t){const n=t[e];null!=n&&_l.set(e,n)}return Al=e,!0}var Pl=class{diff(e,t,n={}){let r;"function"==typeof n?(r=n,n={}):"callback"in n&&(r=n.callback);const o=this.castInput(e,n),s=this.castInput(t,n),i=this.removeEmpty(this.tokenize(o,n)),a=this.removeEmpty(this.tokenize(s,n));return this.diffWithOptionsObj(i,a,n,r)}diffWithOptionsObj(e,t,n,r){var o;const s=e=>(e=this.postProcess(e,n),r?void setTimeout(function(){r(e)},0):e),i=t.length,a=e.length;let l=1,c=i+a;null!=n.maxEditLength&&(c=Math.min(c,n.maxEditLength));const u=null!==(o=n.timeout)&&void 0!==o?o:1/0,d=Date.now()+u,h=[{oldPos:-1,lastComponent:void 0}];let p=this.extractCommon(h[0],t,e,0,n);if(h[0].oldPos+1>=a&&p+1>=i)return s(this.buildValues(h[0].lastComponent,t,e));let f=-1/0,g=1/0;const m=()=>{for(let r=Math.max(f,-l);r<=Math.min(g,l);r+=2){let o;const l=h[r-1],c=h[r+1];l&&(h[r-1]=void 0);let u=!1;if(c){const e=c.oldPos-r;u=c&&0<=e&&e<i}const d=l&&l.oldPos+1<a;if(u||d){if(o=!d||u&&l.oldPos<c.oldPos?this.addToPath(c,!0,!1,0,n):this.addToPath(l,!1,!0,1,n),p=this.extractCommon(o,t,e,r,n),o.oldPos+1>=a&&p+1>=i)return s(this.buildValues(o.lastComponent,t,e))||!0;h[r]=o,o.oldPos+1>=a&&(g=Math.min(g,r-1)),p+1>=i&&(f=Math.max(f,r+1))}else h[r]=void 0}l++};if(r)!(function e(){setTimeout(function(){if(l>c||Date.now()>d)return r(void 0);m()||e()},0)})();else for(;l<=c&&Date.now()<=d;){const e=m();if(e)return e}}addToPath(e,t,n,r,o){const s=e.lastComponent;return s&&!o.oneChangePerToken&&s.added===t&&s.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:s.count+1,added:t,removed:n,previousComponent:s.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:s}}}extractCommon(e,t,n,r,o){const s=t.length,i=n.length;let a=e.oldPos,l=a-r,c=0;for(;l+1<s&&a+1<i&&this.equals(n[a+1],t[l+1],o);)l++,a++,c++,o.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return c&&!o.oneChangePerToken&&(e.lastComponent={count:c,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=a,l}equals(e,t,n){return n.comparator?n.comparator(e,t):e===t||!!n.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){const t=[];for(let n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join("")}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,n){const r=[];let o;for(;e;)r.push(e),o=e.previousComponent,delete e.previousComponent,e=o;r.reverse();const s=r.length;let i=0,a=0,l=0;for(;i<s;i++){const e=r[i];if(e.removed)e.value=this.join(n.slice(l,l+e.count)),l+=e.count;else{if(!e.added&&this.useLongestToken){let r=t.slice(a,a+e.count);r=r.map(function(e,t){const r=n[l+t];return r.length>e.length?r:e}),e.value=this.join(r)}else e.value=this.join(t.slice(a,a+e.count));a+=e.count,e.added||(l+=e.count)}}return r}};const Ol=new class extends Pl{};function Tl(e,t){let n;for(n=0;n<e.length&&n<t.length;n++)if(e[n]!=t[n])return e.slice(0,n);return e.slice(0,n)}function $l(e,t){let n;if(!e||!t||e[e.length-1]!=t[t.length-1])return"";for(n=0;n<e.length&&n<t.length;n++)if(e[e.length-(n+1)]!=t[t.length-(n+1)])return e.slice(-n);return e.slice(-n)}function Rl(e,t,n){if(e.slice(0,t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't start with prefix ${JSON.stringify(t)}; this is a bug`);return n+e.slice(t.length)}function Ml(e,t,n){if(!t)return e+n;if(e.slice(-t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't end with suffix ${JSON.stringify(t)}; this is a bug`);return e.slice(0,-t.length)+n}function jl(e,t){return Rl(e,t,"")}function Dl(e,t){return Ml(e,t,"")}function Bl(e,t){return t.slice(0,Fl(e,t))}function Fl(e,t){let n=0;e.length>t.length&&(n=e.length-t.length);let r=t.length;e.length<t.length&&(r=e.length);const o=Array(r);let s=0;o[0]=0;for(let e=1;e<r;e++){for(t[e]==t[s]?o[e]=o[s]:o[e]=s;s>0&&t[e]!=t[s];)s=o[s];t[e]==t[s]&&s++}s=0;for(let r=n;r<e.length;r++){for(;s>0&&e[r]!=t[s];)s=o[s];e[r]==t[s]&&s++}return s}function Gl(e,t){const n=[];for(const r of Array.from(t.segment(e))){const e=r.segment;n.length&&/\s/.test(n[n.length-1])&&/\s/.test(e)?n[n.length-1]+=e:n.push(e)}return n}function Ul(e,t){if(t)return zl(e,t)[1];let n;for(n=e.length-1;n>=0&&e[n].match(/\s/);n--);return e.substring(n+1)}function Wl(e,t){if(t)return zl(e,t)[0];const n=e.match(/^\s*/);return n?n[0]:""}function zl(e,t){if(!t)return[Wl(e),Ul(e)];if("word"!=t.resolvedOptions().granularity)throw new Error("The segmenter passed must have a granularity of \"word\"");const n=Gl(e,t),r=n[0],o=n[n.length-1];return[/\s/.test(r)?r:"",/\s/.test(o)?o:""]}const ql="a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}",Hl=new RegExp(`[${ql}]+|\\s+|[^${ql}]`,"ug");function Vl(e,t,n,r,o){if(t&&n){const[s,i]=zl(t.value,o),[a,l]=zl(n.value,o);if(e){const r=Tl(s,a);e.value=Ml(e.value,a,r),t.value=jl(t.value,r),n.value=jl(n.value,r)}if(r){const e=$l(i,l);r.value=Rl(r.value,l,e),t.value=Dl(t.value,e),n.value=Dl(n.value,e)}}else if(n){if(e){const e=Wl(n.value,o);n.value=n.value.substring(e.length)}if(r){const e=Wl(r.value,o);r.value=r.value.substring(e.length)}}else if(e&&r){const n=Wl(r.value,o),[s,i]=zl(t.value,o),a=Tl(n,s);t.value=jl(t.value,a);const l=$l(jl(n,a),i);t.value=Dl(t.value,l),r.value=Rl(r.value,n,l),e.value=Ml(e.value,n,n.slice(0,n.length-l.length))}else if(r){const e=Wl(r.value,o),n=Bl(Ul(t.value,o),e);t.value=Dl(t.value,n)}else if(e){const n=Bl(Ul(e.value,o),Wl(t.value,o));t.value=jl(t.value,n)}}new class extends Pl{equals(e,t,n){return n.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e.trim()===t.trim()}tokenize(e,t={}){let n;if(t.intlSegmenter){const r=t.intlSegmenter;if("word"!=r.resolvedOptions().granularity)throw new Error("The segmenter passed must have a granularity of \"word\"");n=Gl(e,r)}else n=e.match(Hl)||[];const r=[];let o=null;return n.forEach(e=>{/\s/.test(e)?null==o?r.push(e):r.push(r.pop()+e):null!=o&&/\s/.test(o)?r[r.length-1]==o?r.push(r.pop()+e):r.push(o+e):r.push(e),o=e}),r}join(e){return e.map((e,t)=>0==t?e:e.replace(/^\s+/,"")).join("")}postProcess(e,t){if(!e||t.oneChangePerToken)return e;let n=null,r=null,o=null;return e.forEach(e=>{e.added?r=e:e.removed?o=e:((r||o)&&Vl(n,o,r,e,t.intlSegmenter),n=e,r=null,o=null)}),(r||o)&&Vl(n,o,r,null,t.intlSegmenter),e}};const Xl=new class extends Pl{tokenize(e){const t=new RegExp(`(\\r?\\n)|[${ql}]+|[^\\S\\n\\r]+|[^${ql}]`,"ug");return e.match(t)||[]}};function Kl(e,t,n){return Xl.diff(e,t,n)}function Zl(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,"\n"));const n=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let e=0;e<r.length;e++){const o=r[e];e%2&&!t.newlineIsToken?n[n.length-1]+=o:n.push(o)}return n}function Jl(e){return"."==e||"!"==e||"?"==e}new class extends Pl{constructor(){super(...arguments),this.tokenize=Zl}equals(e,t,n){return n.ignoreWhitespace?(n.newlineIsToken&&e.includes("\n")||(e=e.trim()),n.newlineIsToken&&t.includes("\n")||(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith("\n")&&(e=e.slice(0,-1)),t.endsWith("\n")&&(t=t.slice(0,-1))),super.equals(e,t,n)}};new class extends Pl{tokenize(e){var t;const n=[];let r=0;for(let o=0;o<e.length;o++){if(o==e.length-1){n.push(e.slice(r));break}if(Jl(e[o])&&e[o+1].match(/\s/)){for(n.push(e.slice(r,o+1)),o=r=o+1;null===(t=e[o+1])||void 0===t?void 0:t.match(/\s/);)o++;n.push(e.slice(r,o+1)),r=o+1}}return n}};new class extends Pl{tokenize(e){return e.split(/([{}:;,]|\s+)/)}};function Ql(e,t,n,r,o){let s,i;for(t=t||[],n=n||[],r&&(e=r(void 0===o?"":o,e)),s=0;s<t.length;s+=1)if(t[s]===e)return n[s];if("[object Array]"===Object.prototype.toString.call(e)){for(t.push(e),i=new Array(e.length),n.push(i),s=0;s<e.length;s+=1)i[s]=Ql(e[s],t,n,r,String(s));return t.pop(),n.pop(),i}if(e&&e.toJSON&&(e=e.toJSON()),"object"==typeof e&&null!==e){t.push(e),i={},n.push(i);const o=[];let a;for(a in e)Object.prototype.hasOwnProperty.call(e,a)&&o.push(a);for(o.sort(),s=0;s<o.length;s+=1)a=o[s],i[a]=Ql(e[a],t,n,r,a);t.pop(),n.pop()}else i=e;return i}new class extends Pl{constructor(){super(...arguments),this.tokenize=Zl}get useLongestToken(){return!0}castInput(e,t){const{undefinedReplacement:n,stringifyReplacer:r=(e,t)=>void 0===t?n:t}=t;return"string"==typeof e?e:JSON.stringify(Ql(e,null,null,r),null," ")}equals(e,t,n){return super.equals(e.replace(/,([\r\n])/g,"$1"),t.replace(/,([\r\n])/g,"$1"),n)}};function Yl(e,t){for(const n of t)e.push(n)}function ec(e){let t=e.length;return 10===e.charCodeAt(t-1)&&(t--,13===e.charCodeAt(t-1)&&t--),e.slice(0,t)}function tc(e,t=0){let n=3735928559^t,r=1103547991^t;for(let t,o=0;o<e.length;o++)t=e.charCodeAt(o),n=Math.imul(n^t,2654435761),r=Math.imul(r^t,1597334677);return n=Math.imul(n^n>>>16,2246822507),n^=Math.imul(r^r>>>13,3266489909),r=Math.imul(r^r>>>16,2246822507),r^=Math.imul(n^n>>>13,3266489909),(4294967296*(2097151&r)+(n>>>0)).toString(36).slice(0,6)}function nc({tagName:e,children:t=[],properties:n={}}){return{type:"element",tagName:e,properties:n,children:t}}function rc(e){let t=e.children[0];for(;null!=t;){if("element"===t.type&&"code"===t.tagName)return t;t="children"in t?t.children[0]:null}}function oc(e,t,n){const r="function"==typeof n.lineInfo?n.lineInfo(t):n.lineInfo[t-1];if(null==r){const r=`processLine: line ${t}, contains no state.lineInfo`;throw console.error(r,{node:e,line:t,state:n}),new Error(r)}return e.tagName="div",e.properties["data-line"]=r.lineNumber,e.properties["data-alt-line"]=r.altLineNumber,e.properties["data-line-type"]=r.type,e.properties["data-line-index"]=r.lineIndex,0===e.children.length&&e.children.push({type:"text",value:"\n"}),e}new class extends Pl{tokenize(e){return e.slice()}join(e){return e}removeEmpty(e){return e}};const sc=Symbol("no-token"),ic=Symbol("multiple-tokens");function ac(e){const t=lc(e);if(null!=t)return t;let n=sc;const r=[];let o,s=[];const i=()=>{if(0===s.length||null==o)return s=[],void(o=void 0);if(1===s.length){const t=s[0];if("element"===t?.type){e=o,t.properties["data-char"]=e;for(const e of t.children)cc(e)}else cc(t);return r.push(t),s=[],void(o=void 0)}var e;for(const e of s)cc(e);r.push(nc({tagName:"span",properties:{"data-char":o},children:s})),s=[],o=void 0},a=e=>{e!==sc&&(e!==ic?n!==sc?n!==e&&(n=ic):n=e:n=ic)};for(const t of e.children){const e="element"===t.type?ac(t):sc;a(e),"number"==typeof e?(null!=o&&o!==e&&i(),o??=e,s.push(t)):(i(),r.push(t))}return i(),e.children=r,n}function lc(e){const t=e.properties["data-char"];if("number"==typeof t)return t}function cc(e){if("element"===e.type){e.properties["data-char"]=void 0;for(const t of e.children)cc(t)}}function uc(e=!1,t=!1){const n={lineInfo:[]},r=[Object.assign({line:e=>(delete e.properties.class,e),pre(t){const r=rc(t),o=[];if(null!=r){let t=1;for(const s of r.children)"element"===s.type&&(e&&ac(s),o.push(oc(s,t,n)),t++);r.children=o}return t}},e?{tokens(e){for(const t of e){let e=0;for(const n of t){const t=n;t.__lineChar??=e,e+=n.content.length}}},preprocess(e,t){t.mergeWhitespaces="never"},span(e,t,n,r,o){if(null!=o?.offset&&null!=o.content){const t=o.__lineChar;return null!=t&&(e.properties["data-char"]=t),e}return e}}:null)];return t&&r.push(hc,dc),e&&r.push({line:e=>("element"===e.type&&0===e.children.length&&e.children.push({type:"element",tagName:"br",properties:{},children:[]}),e)}),{state:n,transformers:r,toClass:dc}}const dc=(function(e={}){const{classPrefix:t="__shiki_",classSuffix:n="",classReplacer:r=e=>e}=e,o=new Map;function s(e){return Object.entries(e).map(([e,t])=>`${e}:${t}`).join(";")}function i(e){const i="string"==typeof e?e:s(e);let a=t+tc(i)+n;return a=r(a),o.has(a)||o.set(a,"string"==typeof e?e:Object.assign({},e)),a}return{name:"@shikijs/transformers:style-to-class",pre(e){if(!e.properties.style)return;const t=i(e.properties.style);delete e.properties.style,this.addClassToHast(e,t)},tokens(e){for(const t of e)for(const e of t){if(!e.htmlStyle)continue;const t=i(e.htmlStyle);e.htmlStyle={},e.htmlAttrs||={},e.htmlAttrs.class?e.htmlAttrs.class+=` ${t}`:e.htmlAttrs.class=t}},getClassRegistry:()=>o,getCSS(){let e="";for(const[t,n]of o.entries())e+=`.${t}{${"string"==typeof n?n:s(n)}}`;return e},clearRegistry(){o.clear()}}})({classPrefix:"hl-"}),hc={name:"token-style-normalizer",tokens(e){for(const t of e)for(const e of t){if(null!=e.htmlStyle)continue;const t={};null!=e.color&&(t.color=e.color),null!=e.bgColor&&(t["background-color"]=e.bgColor),null!=e.fontStyle&&0!==e.fontStyle&&(1&e.fontStyle&&(t["font-style"]="italic"),2&e.fontStyle&&(t["font-weight"]="bold"),4&e.fontStyle&&(t["text-decoration"]="underline")),Object.keys(t).length>0&&(e.htmlStyle=t)}}};function pc(e){return`--${"token"===e?"diffs-token":"diffs"}-`}const fc=/^#(?:[0-9a-f]{3}0|[0-9a-f]{6}00)$/i,gc=/^0(?:\.0+)?%?$/;function mc(e){const t=e.indexOf("(");if(t<=0||!e.endsWith(")"))return;const n=e.slice(0,t).trim();if(!/^(?:rgb|rgba|hsl|hsla|hwb|lab|lch|oklab|oklch|color)$/i.test(n))return;const r=e.slice(t+1,-1).trim();if(0===r.length)return;const o=r.lastIndexOf("/");if(-1!==o)return r.slice(o+1).trim();if(/^(?:rgba|hsla)$/i.test(n)){const e=r.split(",");if(4===e.length)return e[3]?.trim()}}function yc(e){const t=/^#([0-9a-f]{3}|[0-9a-f]{6}|[0-9a-f]{8})\b/i.exec(e.trim());if(null==t)return null;const n=t[1];let r,o=1;return 3===n.length?r=n.split("").map(e=>e+e).join(""):6===n.length?r=n:(r=n.slice(0,6),o=parseInt(n.slice(6,8),16)/255),[parseInt(r.slice(0,2),16),parseInt(r.slice(2,4),16),parseInt(r.slice(4,6),16),o]}function bc(e){if(null==e)return null;const t=yc(e);if(null==t)return null;const n=t[0]/255,r=t[1]/255,o=t[2]/255,s=e=>e<=.03928?e/12.92:((e+.055)/1.055)**2.4;return.2126*s(n)+.7152*s(r)+.0722*s(o)}function wc(e){if(null==e)return!1;const t=e.trim().toLowerCase();if("transparent"===t)return!0;if(fc.test(t))return!0;const n=mc(t);return null!=n&&gc.test(n)}function kc(e,t,n){if(null==t||null==n)return!1;const r=bc(e),o=bc(t),s=bc(n);return null!=r&&null!=o&&null!=s&&Math.abs(r-s)<Math.abs(r-o)}const Cc=new WeakMap;function vc(e){const t=Cc.get(e);if(null!=t)return t;const n=e.colors??{},r=Object.assign({},n),o=n["editor.background"]??e.bg,s=n["editor.foreground"]??e.fg,i=n["sideBar.background"]??o,a=n["sideBar.foreground"]??s;xc(r,"editor.background",o),xc(r,"editor.foreground",s),xc(r,"sideBar.background",i),xc(r,"sideBar.foreground",a),xc(r,"input.background",n["input.background"]??i),xc(r,"sideBarSectionHeader.foreground",n["sideBarSectionHeader.foreground"]??a),xc(r,"list.activeSelectionForeground",n["list.activeSelectionForeground"]??a),xc(r,"gitDecoration.addedResourceForeground",Sc(n["gitDecoration.addedResourceForeground"],n["terminal.ansiGreen"],n["editorGutter.addedBackground"])),xc(r,"gitDecoration.modifiedResourceForeground",Sc(n["gitDecoration.modifiedResourceForeground"],n["terminal.ansiBlue"],n["editorGutter.modifiedBackground"])),xc(r,"gitDecoration.deletedResourceForeground",Sc(n["gitDecoration.deletedResourceForeground"],n["terminal.ansiRed"],n["editorGutter.deletedBackground"]));const l=(wc(n["list.focusOutline"])?void 0:n["list.focusOutline"])??(wc(n.focusBorder)?void 0:n.focusBorder);null!=l?r["list.focusOutline"]=l:delete r["list.focusOutline"];const c=n["list.hoverBackground"];var u,d;null!=c&&(u=c,null!=(d=i)&&u.toLowerCase()===d.toLowerCase()||kc(c,i,a))&&delete r["list.hoverBackground"];const h=Object.freeze(Object.assign({},e,{colors:Object.freeze(r)}));return Cc.set(e,h),h}function xc(e,t,n){null!=n&&""!==n&&(e[t]=n)}function Sc(...e){for(const t of e)if(null!=t&&""!==t)return t}function _c({theme:e=gl,highlighter:t,prefix:n}){let r="";if("string"==typeof e){const o=t.getTheme(e),s=vc(o);r+=`color:${s.fg};`,r+=`background-color:${s.bg};`,r+=`${pc("global")}fg:${s.fg};`,r+=`${pc("global")}bg:${s.bg};`,r+=Ac(o,n)}else{let n=t.getTheme(e.dark),o=vc(n);r+=`${pc("global")}dark:${o.fg};`,r+=`${pc("global")}dark-bg:${o.bg};`,r+=Ac(n,"dark"),n=t.getTheme(e.light),o=vc(n),r+=`${pc("global")}light:${o.fg};`,r+=`${pc("global")}light-bg:${o.bg};`,r+=Ac(n,"light")}return r}function Ac(e,t){t=null!=t?`${t}-`:"";let n="";const r=e.colors?.["gitDecoration.addedResourceForeground"]??e.colors?.["terminal.ansiGreen"];null!=r&&(n+=`${pc("global")}${t}addition-color:${r};`);const o=e.colors?.["gitDecoration.deletedResourceForeground"]??e.colors?.["terminal.ansiRed"];null!=o&&(n+=`${pc("global")}${t}deletion-color:${o};`);const s=e.colors?.["gitDecoration.modifiedResourceForeground"]??e.colors?.["terminal.ansiBlue"];return null!=s&&(n+=`${pc("global")}${t}modified-color:${s};`),n}function Ec(e){let t=e.children[0];for(;null!=t;){if("element"===t.type&&"code"===t.tagName)return t.children;t="children"in t?t.children[0]:null}throw console.error(e),new Error("getLineNodes: Unable to find children")}function Lc(e,t){return e-(0===t?0:1)}function Ic(e,t){return Lc(e,t)+t}function Nc({isPartial:e,rangeSize:t,expandedHunks:n,hunkIndex:r,collapsedContextThreshold:o}){const s=Math.max(t,0);if(0===s||e)return{fromStart:0,fromEnd:0,rangeSize:s,collapsedLines:s,renderAll:!1};if(!0===n||s<=o)return{fromStart:s,fromEnd:0,rangeSize:s,collapsedLines:0,renderAll:!0};const i=n?.get(r),a=Math.min(Math.max(i?.fromStart??0,0),s),l=Math.min(Math.max(i?.fromEnd??0,0),s),c=a+l,u=c>=s;return{fromStart:u?s:a,fromEnd:u?0:l,rangeSize:s,collapsedLines:Math.max(s-c,0),renderAll:u}}function Pc({fileDiff:e,errorPrefix:t}){const n=e.hunks[e.hunks.length-1];if(null==n||e.isPartial||0===e.additionLines.length||0===e.deletionLines.length)return 0;const r=e.additionLines.length-Ic(n.additionStart,n.additionCount),o=e.deletionLines.length-Ic(n.deletionStart,n.deletionCount);if(r<=0&&o<=0)return 0;if(r!==o)throw new Error(`${t}: trailing context mismatch (additions=${r}, deletions=${o}) for ${e.name}`);return Math.min(r,o)}function Oc({fileDiff:e,hunkIndex:t,expandedHunks:n,collapsedContextThreshold:r,errorPrefix:o}){if(t!==e.hunks.length-1)return;const s=Pc({fileDiff:e,errorPrefix:o});if(s<=0)return;if(!0===n||s<=r)return{fromStart:s,fromEnd:0,rangeSize:s,collapsedLines:0,renderAll:!0};const i=n?.get(e.hunks.length),a=Math.min(Math.max(i?.fromStart??0,0),s);return{fromStart:a,fromEnd:0,rangeSize:s,collapsedLines:s-a,renderAll:a>=s}}function Tc({diff:e,diffStyle:t,startingLine:n=0,totalLines:r=1/0,expandedHunks:o,collapsedContextThreshold:s=1,callback:i}){const a=$c({diff:e,diffStyle:t,startingLine:n,expandedHunks:o,collapsedContextThreshold:s}),l={viewportStart:n,viewportEnd:n+r,isWindowedHighlight:n>0||r<1/0,splitCount:a.splitCount,unifiedCount:a.unifiedCount,finalHunkIndex:e.hunks.length-1,shouldBreak(){if(!l.isWindowedHighlight)return!1;const e=l.unifiedCount>=n+r,o=l.splitCount>=n+r;return"unified"===t?e:("split"===t||e)&&o},shouldSkip(e,r){if(!l.isWindowedHighlight)return!1;const o=e>0&&l.unifiedCount+e<=n,s=r>0&&l.splitCount+r<=n;return"unified"===t?o:("split"===t||o)&&s},incrementCounts(e,n){"unified"!==t&&"both"!==t||(l.unifiedCount+=e),"split"!==t&&"both"!==t||(l.splitCount+=n)},isInWindow(e,n){if(!l.isWindowedHighlight)return!0;const r=l.isInUnifiedWindow(e),o=l.isInSplitWindow(n);return"unified"===t?r:"split"===t?o:r||o},isInUnifiedWindow:e=>!l.isWindowedHighlight||l.unifiedCount>=n-e&&l.unifiedCount<n+r,isInSplitWindow:e=>!l.isWindowedHighlight||l.splitCount>=n-e&&l.splitCount<n+r,emit:(e,n=!1)=>(n||("unified"===t?l.incrementCounts(1,0):"split"===t?l.incrementCounts(0,1):l.incrementCounts(1,1)),i(e)??!1)};e:for(let d=a.hunkIndex;d<e.hunks.length;d++){const h=e.hunks[d];if(null==h)throw new Error("iterateOverDiff: invalid hunk index");if(l.shouldBreak())break;const p=Lc(h.deletionStart,h.deletionCount),f=Lc(h.additionStart,h.additionCount),g=e.isPartial||0!==h.deletionCount?h.deletionLineIndex:p,m=e.isPartial||0!==h.additionCount?h.additionLineIndex:f,y=Nc({isPartial:e.isPartial,rangeSize:h.collapsedBefore,expandedHunks:o,hunkIndex:d,collapsedContextThreshold:s}),b=d===l.finalHunkIndex?Oc({fileDiff:e,hunkIndex:d,expandedHunks:o,collapsedContextThreshold:s,errorPrefix:"iterateOverDiff"}):void 0,w=y.fromStart+y.fromEnd;function c(e,n){return null==b||b.collapsedLines<=0||b.fromStart+b.fromEnd>0?0:"unified"===t?e===h.unifiedLineStart+h.unifiedLineCount-1?b.collapsedLines:0:n===h.splitLineStart+h.splitLineCount-1?b.collapsedLines:0}let k=0===y.collapsedLines;function u(){return k?0:(k=!0,y.collapsedLines)}if(l.shouldSkip(w,w))l.incrementCounts(w,w),u();else{let L=h.unifiedLineStart-y.rangeSize,I=h.splitLineStart-y.rangeSize,N=g-y.rangeSize,P=m-y.rangeSize,O=p+1-y.rangeSize,T=f+1-y.rangeSize;if(jc(l,y.fromStart,t,e=>l.emit({hunkIndex:d,hunk:h,collapsedBefore:0,collapsedAfter:0,type:"context-expanded",deletionLine:{lineNumber:O+e,lineIndex:N+e,noEOFCR:!1,unifiedLineIndex:L+e,splitLineIndex:I+e},additionLine:{unifiedLineIndex:L+e,splitLineIndex:I+e,lineIndex:P+e,lineNumber:T+e,noEOFCR:!1}})))break e;if(L=h.unifiedLineStart-y.fromEnd,I=h.splitLineStart-y.fromEnd,N=g-y.fromEnd,P=m-y.fromEnd,O=p+1-y.fromEnd,T=f+1-y.fromEnd,jc(l,y.fromEnd,t,e=>l.emit({hunkIndex:d,hunk:h,collapsedBefore:u(),collapsedAfter:0,type:"context-expanded",deletionLine:{lineNumber:O+e,lineIndex:N+e,noEOFCR:!1,unifiedLineIndex:L+e,splitLineIndex:I+e},additionLine:{unifiedLineIndex:L+e,splitLineIndex:I+e,lineIndex:P+e,lineNumber:T+e,noEOFCR:!1}}),()=>{u()}))break e}let C=h.unifiedLineStart,v=h.splitLineStart,x=g,S=m,_=p+1,A=f+1;const E=h.hunkContent.at(-1);for(const $ of h.hunkContent){if(l.shouldBreak())break e;const R=$===E;if("context"===$.type){if(l.shouldSkip($.lines,$.lines))l.incrementCounts($.lines,$.lines),u();else if(jc(l,$.lines,t,e=>{const t=R&&e===$.lines-1,n=C+e,r=v+e;return l.emit({hunkIndex:d,hunk:h,collapsedBefore:u(),collapsedAfter:c(n,r),type:"context",deletionLine:{lineNumber:_+e,lineIndex:x+e,noEOFCR:t&&h.noEOFCRDeletions,unifiedLineIndex:n,splitLineIndex:r},additionLine:{unifiedLineIndex:n,splitLineIndex:r,lineIndex:S+e,lineNumber:A+e,noEOFCR:t&&h.noEOFCRAdditions}})},()=>{u()}))break e;C+=$.lines,v+=$.lines,x+=$.lines,S+=$.lines,_+=$.lines,A+=$.lines}else{const M=Math.max($.deletions,$.additions),j=$.deletions+$.additions;if(!l.shouldSkip(j,M)){const D=Dc(l,$,t);(D[0]?.[0]??0)>0&&u();for(const[B,F]of D)for(let G=B;G<F;G++){const U=c(C+G,"unified"===t?v+(G<$.deletions?G:G-$.deletions):v+G);if(l.emit(Bc({hunkIndex:d,hunk:h,collapsedBefore:u(),collapsedAfter:U,diffStyle:t,index:G,unifiedLineIndex:C,splitLineIndex:v,additionLineIndex:S,deletionLineIndex:x,additionLineNumber:A,deletionLineNumber:_,content:$,isLastContent:R,unifiedCount:j,splitCount:M}),!0))break e}}u(),l.incrementCounts(j,M),C+=j,v+=M,x+=$.deletions,S+=$.additions,_+=$.deletions,A+=$.additions}}if(null!=b){const{collapsedLines:W,fromStart:z,fromEnd:q}=b,H=z+q;if(jc(l,H,t,t=>{const n=t===H-1;return l.emit({hunkIndex:e.hunks.length,hunk:void 0,collapsedBefore:0,collapsedAfter:n?W:0,type:"context-expanded",deletionLine:{lineNumber:_+t,lineIndex:x+t,noEOFCR:!1,unifiedLineIndex:C+t,splitLineIndex:v+t},additionLine:{unifiedLineIndex:C+t,splitLineIndex:v+t,lineIndex:S+t,lineNumber:A+t,noEOFCR:!1}})},void 0,()=>l.shouldBreak()))break e}}}function $c({diff:e,diffStyle:t,startingLine:n,expandedHunks:r,collapsedContextThreshold:o}){if(n<=0||"both"===t)return{hunkIndex:0,splitCount:0,unifiedCount:0};const s=Rc({diff:e,expandedHunks:r,collapsedContextThreshold:o});let i=0,a=e.hunks.length-1,l=e.hunks.length;for(;i<=a;){const e=i+a>>1,r=s[e+1];if(null==r)throw new Error("iterateOverDiff: invalid hunk prefix index");("unified"===t?r.unifiedCount:r.splitCount)>n?(l=e,a=e-1):i=e+1}if(l>=e.hunks.length){const t=s[e.hunks.length];if(null==t)throw new Error("iterateOverDiff: invalid terminal hunk prefix index");return{hunkIndex:e.hunks.length,splitCount:t.splitCount,unifiedCount:t.unifiedCount}}const c=s[l];if(null==c)throw new Error("iterateOverDiff: invalid selected hunk prefix index");return{hunkIndex:l,splitCount:c.splitCount,unifiedCount:c.unifiedCount}}function Rc({diff:e,expandedHunks:t,collapsedContextThreshold:n}){let r=0,o=0;const s=e.hunks.length-1,i=[{splitCount:0,unifiedCount:0}];for(let a=0;a<e.hunks.length;a++){const l=e.hunks[a];if(null==l)throw new Error("iterateOverDiff: invalid hunk summary index");const c=Nc({isPartial:e.isPartial,rangeSize:l.collapsedBefore,expandedHunks:t,hunkIndex:a,collapsedContextThreshold:n}),u=c.fromStart+c.fromEnd;r+=u+l.splitLineCount,o+=u+l.unifiedLineCount;const d=a===s?Oc({fileDiff:e,hunkIndex:a,expandedHunks:t,collapsedContextThreshold:n,errorPrefix:"iterateOverDiff"}):void 0;if(null!=d){const e=d.fromStart+d.fromEnd;r+=e,o+=e}i.push({splitCount:r,unifiedCount:o})}return i}function Mc(e,t,n){if(!e.isWindowedHighlight||t<=0)return[0,t];const r=[];function o(n){const o=Math.max(0,e.viewportStart-n),s=Math.min(t,e.viewportEnd-n);s>o&&r.push([o,s])}if("split"!==n&&o(e.unifiedCount),"unified"!==n&&o(e.splitCount),0===r.length)return[0,0];let s=r[0][0],i=r[0][1];for(let e=1;e<r.length;e++){const t=r[e];s=Math.min(s,t[0]),i=Math.max(i,t[1])}return[s,i]}function jc(e,t,n,r,o,s){const[i,a]=Mc(e,t,n);i>0&&(e.incrementCounts(i,i),o?.());let l=i;for(;l<t;){if(!0===s?.())return!0;if(l>=a){e.incrementCounts(t-l,t-l);break}if(e.isInWindow(0,0)){if(!0===r(l))return!0}else e.incrementCounts(1,1);l++}return!1}function Dc(e,t,n){if(!e.isWindowedHighlight)return[[0,"unified"===n?t.deletions+t.additions:Math.max(t.deletions,t.additions)]];const r="unified"!==n,o="unified"===n?"unified":"split",s=[];function i(t,n){if(t+n<=e.viewportStart||t>=e.viewportEnd)return;const r=Math.max(0,e.viewportStart-t),o=Math.min(n,e.viewportEnd-t);return o>r?[r,o]:void 0}function a(e,n){return"split"===o?e:"additions"===n?[e[0]+t.deletions,e[1]+t.deletions]:e}function l(e,t){if(null==e)return;const[n,r]=a(e,t);r>n&&s.push([n,r])}if("split"!==n&&(l(i(e.unifiedCount,t.deletions),"deletions"),l(i(e.unifiedCount+t.deletions,t.additions),"additions")),r&&(l(i(e.splitCount,t.deletions),"deletions"),l(i(e.splitCount,t.additions),"additions")),0===s.length)return s;s.sort((e,t)=>e[0]-t[0]);const c=[s[0]];for(const[e,t]of s.slice(1)){const n=c[c.length-1];e<=n[1]?n[1]=Math.max(n[1],t):c.push([e,t])}return c}function Bc({hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,diffStyle:o,index:s,unifiedLineIndex:i,splitLineIndex:a,additionLineIndex:l,deletionLineIndex:c,additionLineNumber:u,deletionLineNumber:d,content:h,isLastContent:p,unifiedCount:f,splitCount:g}){const m=s<h.deletions?i+s:void 0,y="unified"===o?s>=h.deletions?i+s:void 0:s<h.additions?i+h.deletions+s:void 0,b="unified"===o?a+(s<h.deletions?s:s-h.deletions):a+s,w=s<h.deletions?c+s:void 0,k=s<h.deletions?d+s:void 0,C="unified"===o?s>=h.deletions?l+(s-h.deletions):void 0:s<h.additions?l+s:void 0,v="unified"===o?s>=h.deletions?u+(s-h.deletions):void 0:s<h.additions?u+s:void 0,x="unified"===o?p&&s===h.deletions-1&&t.noEOFCRDeletions:p&&s===g-1&&t.noEOFCRDeletions,S="unified"===o?p&&s===f-1&&t.noEOFCRAdditions:p&&s===g-1&&t.noEOFCRAdditions,_=null!=w&&null!=k&&null!=m?{lineNumber:k,lineIndex:w,noEOFCR:x,unifiedLineIndex:m,splitLineIndex:b}:void 0,A=null!=C&&null!=v&&null!=y?{unifiedLineIndex:y,splitLineIndex:b,lineIndex:C,lineNumber:v,noEOFCR:S}:void 0;if(null==_&&null!=A)return{type:"change",hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:void 0,additionLine:A};if(null!=_&&null==A)return{type:"change",hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:_,additionLine:void 0};if(null==_||null==A)throw new Error("iterateOverDiff: missing change line data");return{type:"change",hunkIndex:e,hunk:t,collapsedAfter:n,collapsedBefore:r,deletionLine:_,additionLine:A}}function Fc({line:e,spanStart:t,spanLength:n}){return{start:{line:e,character:t},end:{line:e,character:t+n},properties:{"data-diff-span":""},alwaysWrap:!0}}function Gc({item:e,arr:t,enableJoin:n,isNeutral:r=!1,isLastItem:o=!1}){const s=t[t.length-1];if(null==s||o||!n)return void t.push([r?0:1,e.value]);const i=0===s[0];r===i||r&&1===e.value.length&&!i?s[1]+=e.value:t.push([r?0:1,e.value])}const Uc={forcePlainText:!1};function Wc(e,t,n,{forcePlainText:r,startingLine:o,totalLines:s,expandedHunks:i,collapsedContextThreshold:a=1}=Uc){r?(o??=0,s??=1/0):(o=0,s=1/0);const l=o>0||s<1/0,c="string"==typeof n.theme?t.getTheme(n.theme).type:void 0,u=_c({theme:n.theme,highlighter:t}),d=r&&!l&&(e.unifiedLineCount>1e3||e.splitLineCount>1e3)?"none":n.lineDiffType,h={deletionLines:[],additionLines:[]},{maxLineDiffLength:p}=n,f=!r&&!e.isPartial,g=r?i:void 0,m=new Map;function y(e){const t=f?0:e,n=m.get(t)??{deletionContent:{push(e){this.value+=e,this.length++},value:"",length:0},additionContent:{push(e){this.value+=e,this.length++},value:"",length:0},deletionInfo:[],additionInfo:[],deletionDecorations:[],additionDecorations:[],deletionSegments:[],additionSegments:[]};return m.set(t,n),n}function b(e,t,n,r){if(l){let e=n.at(-1);null!=e&&e.targetIndex+e.count===t||(e={targetIndex:t,originalOffset:r.length,count:0},n.push(e)),e.count++}r.push(e)}Tc({diff:e,diffStyle:"both",startingLine:o,totalLines:s,expandedHunks:!l||g,collapsedContextThreshold:a,callback:({hunkIndex:t,additionLine:n,deletionLine:r,type:o})=>{const s=y(t),i=null!=n?n.splitLineIndex:r.splitLineIndex;"change"===o&&null!=n&&null!=r&&qc({additionLine:e.additionLines[n.lineIndex],deletionLine:e.deletionLines[r.lineIndex],deletionLineIndex:s.deletionContent.length,additionLineIndex:s.additionContent.length,deletionDecorations:s.deletionDecorations,additionDecorations:s.additionDecorations,lineDiffType:d,maxLineDiffLength:p}),null!=r&&(b(e.deletionLines[r.lineIndex],r.lineIndex,s.deletionSegments,s.deletionContent),s.deletionInfo.push({type:"change"===o?"change-deletion":o,lineNumber:r.lineNumber,altLineNumber:"change"===o?void 0:n.lineNumber??void 0,lineIndex:`${r.unifiedLineIndex},${i}`})),null!=n&&(b(e.additionLines[n.lineIndex],n.lineIndex,s.additionSegments,s.additionContent),s.additionInfo.push({type:"change"===o?"change-addition":o,lineNumber:n.lineNumber,altLineNumber:"change"===o?void 0:r.lineNumber??void 0,lineIndex:`${n.unifiedLineIndex},${i}`}))}});for(const o of m.values()){if(0===o.deletionContent.length&&0===o.additionContent.length)continue;const s={name:e.prevName??e.name,contents:o.deletionContent.value},i={name:e.name,contents:o.additionContent.value},{deletionLines:a,additionLines:l}=Hc({deletionFile:s,deletionInfo:o.deletionInfo,deletionDecorations:o.deletionDecorations,additionFile:i,additionInfo:o.additionInfo,additionDecorations:o.additionDecorations,highlighter:t,options:n,languageOverride:r?"text":e.lang});if(f)h.deletionLines=a,h.additionLines=l;else{if(o.deletionSegments.length>0)for(const e of o.deletionSegments)for(let t=0;t<e.count;t++)h.deletionLines[e.targetIndex+t]=a[e.originalOffset+t];else Yl(h.deletionLines,a);if(o.additionSegments.length>0)for(const e of o.additionSegments)for(let t=0;t<e.count;t++)h.additionLines[e.targetIndex+t]=l[e.originalOffset+t];else Yl(h.additionLines,l)}}return{code:h,themeStyles:u,baseThemeType:c}}function zc(e,{deletionLineIndex:t,additionLineIndex:n,deletionDecorations:r,additionDecorations:o}){let s=0,i=0,a=-1,l=0,c=-1,u=0;for(const{value:t,added:n,removed:r}of e)r?(-1===a&&(a=s),s+=t.length,l=s):n?(-1===c&&(c=i),i+=t.length,u=i):(s+=t.length,i+=t.length);-1!==a&&r.push(Fc({line:t,spanStart:a,spanLength:l-a})),-1!==c&&o.push(Fc({line:n,spanStart:c,spanLength:u-c}))}function qc({deletionLine:e,additionLine:t,deletionLineIndex:n,additionLineIndex:r,deletionDecorations:o,additionDecorations:s,lineDiffType:i,maxLineDiffLength:a}){if(null==e||null==t||"none"===i)return;if(e=ec(e),t=ec(t),e.length>a||t.length>a)return;const l="char"===i?(c=e,u=t,Ol.diff(c,u,d)):Kl(e,t);var c,u,d;if("word-line"===i)return void zc(l,{deletionLineIndex:n,additionLineIndex:r,deletionDecorations:o,additionDecorations:s});const h=[],p=[],f="word-alt"===i,g=l.at(-1);for(const e of l){const t=e===g;e.added||e.removed?e.removed?Gc({item:e,arr:h,enableJoin:f,isLastItem:t}):Gc({item:e,arr:p,enableJoin:f,isLastItem:t}):(Gc({item:e,arr:h,enableJoin:f,isNeutral:!0,isLastItem:t}),Gc({item:e,arr:p,enableJoin:f,isNeutral:!0,isLastItem:t}))}let m=0;for(const e of h)1===e[0]&&o.push(Fc({line:n,spanStart:m,spanLength:e[1].length})),m+=e[1].length;m=0;for(const e of p)1===e[0]&&s.push(Fc({line:r,spanStart:m,spanLength:e[1].length})),m+=e[1].length}function Hc(e){let{deletionFile:t,additionFile:n,deletionInfo:r,additionInfo:o,highlighter:s,deletionDecorations:i,additionDecorations:a,languageOverride:l,options:{theme:c}}=e,u=g(e.options,b);const d=l??Ll(t.name),h=l??Ll(n.name),{state:p,transformers:f}=uc(u.useTokenTransformer),m="string"==typeof c?Object.assign({},u,{lang:"text",theme:c,transformers:f,decorations:void 0,defaultColor:!1,cssVariablePrefix:pc("token"),tokenizeTimeLimit:0}):Object.assign({},u,{lang:"text",themes:c,transformers:f,decorations:void 0,defaultColor:!1,cssVariablePrefix:pc("token"),tokenizeTimeLimit:0});return{deletionLines:""===t.contents?[]:(m.lang=d,p.lineInfo=r,m.decorations=i,Ec(s.codeToHast(ec(t.contents),m))),additionLines:""===n.contents?[]:(m.lang=h,m.decorations=a,p.lineInfo=o,Ec(s.codeToHast(ec(n.contents),m)))}}function Vc(e){const t=[0];let n=e.indexOf("\r"),r=e.indexOf("\n"),o=0,s=0;for(;-1!==n||-1!==r;){let i;if(-1!==n&&(-1===r||n<r)?r===n+1?(i=r+1,n=e.indexOf("\r",i),r=e.indexOf("\n",i)):(i=n+1,n=e.indexOf("\r",i)):(i=r+1,r=e.indexOf("\n",i)),t.push(i),4===++s){if(i-o<=40){for(let n=i;n<e.length;n++){const r=e.charCodeAt(n);10!==r&&13!==r||(13===r&&n+1<e.length&&10===e.charCodeAt(n+1)&&n++,t.push(n+1))}return t}o=i,s=0}}return t}function Xc(e){const t=Vc(e);return Array.from({length:t.length},(n,r)=>{const o=t[r],s=t[r+1]??e.length;return e.slice(o,s)})}const Kc={forcePlainText:!1};function Zc(e,t,{theme:n,tokenizeMaxLineLength:r,useTokenTransformer:o},{forcePlainText:s,startingLine:i,totalLines:a,lines:l}=Kc){s?(i??=0,a??=1/0):(i=0,a=1/0);const c=i>0||a<1/0,{state:u,transformers:d}=uc(o),h=s?"text":e.lang??Ll(e.name),p="string"==typeof n?t.getTheme(n).type:void 0,f=_c({theme:n,highlighter:t});u.lineInfo=e=>({type:"context",lineIndex:e-1+i,lineNumber:e+i});const g="string"==typeof n?{lang:h,theme:n,transformers:d,defaultColor:!1,cssVariablePrefix:pc("token"),tokenizeMaxLineLength:r,tokenizeTimeLimit:0}:{lang:h,themes:n,transformers:d,defaultColor:!1,cssVariablePrefix:pc("token"),tokenizeMaxLineLength:r,tokenizeTimeLimit:0},m=Ec(t.codeToHast((c?Jc(l??Xc(e.contents),i,a):e.contents).replace(/\r(?!\n)/g,"\n"),g));const y=c?new Array(i):m;return c&&Yl(y,m),{code:y,themeStyles:f,baseThemeType:p}}function Jc(e,t,n){if(0===e.length)return"";const r=Math.min(t+n,e.length);return e.slice(t,r).join("")}let Qc,Yc={theme:gl,useTokenTransformer:!1,tokenizeMaxLineLength:1e3,lineDiffType:"word-alt",maxLineDiffLength:1e3};const eu=/(?:)/;async function tu(e){try{switch(e.type){case"initialize":await nu(e);break;case"set-render-options":await ru(e);break;case"file":await ou(e);break;case"diff":await su(e);break;default:throw new Error(`Unknown request type: ${e.type}`)}}catch(t){console.error("Worker error:",t),uu(e.id,t)}finally{eu.exec("")}}async function nu({id:e,renderOptions:t,preferredHighlighter:n,resolvedThemes:r,resolvedLanguages:o,customExtensionsVersion:s,customExtensionMap:i}){let a=iu(n);"then"in a&&(a=await a),au({customExtensionsVersion:s,customExtensionMap:i}),Sl(r,a),null!=o&&bl(o,a),Yc=t,postMessage({type:"success",id:e,requestType:"initialize",sentAt:Date.now()})}async function ru({id:e,renderOptions:t,resolvedThemes:n}){let r=iu();"then"in r&&(r=await r),Sl(n,r),Yc=t,postMessage({type:"success",id:e,requestType:"set-render-options",sentAt:Date.now()})}async function ou({id:e,file:t,resolvedLanguages:n,customExtensionsVersion:r,customExtensionMap:o}){let s=iu();"then"in s&&(s=await s),au({customExtensionsVersion:r,customExtensionMap:o}),null!=n&&bl(n,s);const i={theme:Yc.theme,useTokenTransformer:Yc.useTokenTransformer,tokenizeMaxLineLength:Yc.tokenizeMaxLineLength};lu(e,Zc(t,s,i),i)}async function su({id:e,diff:t,resolvedLanguages:n,customExtensionsVersion:r,customExtensionMap:o}){let s=iu();"then"in s&&(s=await s),au({customExtensionsVersion:r,customExtensionMap:o}),null!=n&&bl(n,s),cu(e,Wc(t,s,Yc),Yc)}function iu(e="shiki-js"){return Qc??=fo({themes:[],langs:[],engine:"shiki-wasm"===e?hl(t(i[4])(i[3],i.paths)):Fa()}),Qc}function au({customExtensionsVersion:e,customExtensionMap:t}){if(null!=e||null!=t){if(null==e||null==t)throw new Error("Worker request must include both customExtensionsVersion and customExtensionMap");Nl(e,t)}}function lu(e,t,n){postMessage({type:"success",requestType:"file",id:e,result:t,options:n,sentAt:Date.now()})}function cu(e,t,n){postMessage({type:"success",requestType:"diff",id:e,result:t,options:n,sentAt:Date.now()})}function uu(e,t){const n={type:"error",id:e,error:t instanceof Error?t.message:String(t),stack:t instanceof Error?t.stack:void 0};postMessage(n)}self.addEventListener("error",e=>{console.error("[Shiki Worker] Unhandled error:",e.error)}),self.addEventListener("message",e=>{tu(e.data)})},1785,{"0":30,"1":31,"2":25,"3":1786,"4":985,"paths":{"1786":"/_expo/static/js/web/wasm-B9ZqxnKj-fe539fe6cce1e3674f7b3773ad969f71.js"}});
59
+ __r(1766);