diff --git a/README.md b/README.md
index c6bbd398..dd1d6c4d 100644
--- a/README.md
+++ b/README.md
@@ -2,7 +2,7 @@
-
+
@@ -34,7 +34,7 @@ Technical foundation derived from the upstream [GCWing/BitFun](https://github.co
-
+
---
diff --git a/README.zh-CN.md b/README.zh-CN.md
index 32484596..fd85ad58 100644
--- a/README.zh-CN.md
+++ b/README.zh-CN.md
@@ -2,7 +2,7 @@
-
+
@@ -35,7 +35,7 @@
-
+
---
diff --git a/assets/brand/README.md b/assets/brand/README.md
new file mode 100644
index 00000000..f2cff6c7
--- /dev/null
+++ b/assets/brand/README.md
@@ -0,0 +1,66 @@
+# Sparo OS brand assets
+
+This directory is the single source of truth for Sparo OS brand artwork.
+
+## Roles
+
+- The default product logo is the circular material mark derived from `source/sparo-mark-master.png`.
+- Launch, dock, taskbar, installer, home-screen, favicon, application-list, and system-tray surfaces use the circular material Logo at every size.
+- The `Sparo OS` wordmark is extracted from `reference/sparo-identity-board.png`; it is not recreated with a font or redrawn path.
+- Tray artwork uses the complete circular material Logo with its red core. Active states add only a compact semantic badge. The app's compact top-left home control keeps a separate source-derived red-core asset.
+
+## Canonical inputs
+
+- `source/sparo-mark-master.png` — user-supplied high-resolution transparent mark master.
+- `source/sparo-core-master.png` — user-supplied high-resolution transparent red-core master.
+- `reference/sparo-identity-board.png` — approved identity board and wordmark reference.
+
+The generator removes low-alpha speckles, normalizes the visible mark to a true circular field, tightly crops application and tray icons to the visible circular bounds, preserves material lighting, and creates every product asset deterministically. Brand artwork is PNG-only: do not trace the mark or wordmark into SVG, and do not hand-edit generated copies.
+
+## Generated outputs
+
+- `exports/mark/` — responsive circular marks from 16 to 512 px.
+- `exports/app-icon/` — edge-fitted circular application icons from 16 to 1024 px, each exported without added transparent padding and with alpha-safe target-size reduction.
+- `exports/core/` — target-specific red-core PNGs reserved for compact in-product controls.
+- `exports/wordmark/` — globally consistent optically bold primary, reversed, and monochrome wordmarks.
+- `exports/lockup/` — horizontal mark-and-wordmark lockups.
+- `exports/tray/` — target-specific 16, 20, 24, 32, and 48 px full-Logo tray PNGs, plus light, dark, and semantic state variants.
+- `exports/web/` — favicons, Apple touch icon, and Web app icons.
+- `qa/` — large-format, small-size, and tray-state review matrices.
+- `manifest.json` — source provenance and deterministic product-output hashes.
+- `adoption-manifest.json` — hashes of synchronized product copies and platform icon files.
+
+QA preview boards are review artifacts rather than product inputs. Their labels
+use the host font renderer, so checks require the committed PNGs to exist with
+the expected dimensions but intentionally omit their byte hashes from the
+cross-platform deterministic manifest.
+
+## Color reference
+
+- Core Red: `#E53935`
+- Warm White: `#F5F2EE`
+- Soft Ivory: `#ECE7E1`
+- Sand Gray: `#D8D3CC`
+- Deep Charcoal: `#1A1A1A`
+
+The master contains photographic/material variation around these reference colors. Do not flatten its red core or replace its shadows with generic CSS effects.
+
+## Usage rules
+
+- Use the circular material Logo for general in-product identity, operating-system application icons, and tray states. Use the red core only for the compact app-chrome home control.
+- Use the dedicated 16–64px edge-fitted app-icon exports for taskbars, window icons, favicons, and other compact surfaces instead of relying on operating-system downscaling.
+- Use the same canonical primary or reversed wordmark on every product surface, including the boot splash and About dialog. Its neutral strokes are expanded deterministically in the source export while the approved letterforms and red core remain unchanged; do not simulate boldness with CSS or create surface-specific copies.
+- Select the nearest generated raster size; never upscale a small copy. Application and tray icons use target-specific alpha-safe reduction with the circular container fitted to all four canvas edges instead of operating-system downscaling of the padded master.
+- Use the material mark at 64 px and above. At 16–48 px, use the dedicated target-size PNG.
+- Preserve a clear space of at least one red-core radius around standalone marks and lockups.
+- Never crop the red core, recolor the material master, add an extra drop shadow, or redraw the geometry.
+
+## Commands
+
+```text
+pnpm run brand:generate
+pnpm run brand:sync
+pnpm run brand:check
+```
+
+`brand:generate` rebuilds the deterministic PNG package. `brand:sync` also copies declared consumers, regenerates desktop/installer platform icons, removes retired vector assets, and records adoption hashes. `brand:check` fails on stale, missing, unmanaged, or legacy brand resources.
diff --git a/assets/brand/adoption-manifest.json b/assets/brand/adoption-manifest.json
new file mode 100644
index 00000000..6999e723
--- /dev/null
+++ b/assets/brand/adoption-manifest.json
@@ -0,0 +1,773 @@
+{
+ "schemaVersion": 1,
+ "generatedBy": "pnpm run brand:sync",
+ "sourceManifestSha256": "d6295853926cce0400be22fc41f7f6caa93d02d616359bed19fe6f3a990b94be",
+ "configSha256": "b968b24d3485dece1100b13168b83e52e93d47b41c30c6239132e08908fe1f42",
+ "files": [
+ {
+ "path": "installer/src-tauri/icons/128x128.png",
+ "bytes": 22999,
+ "sha256": "76e85fe60cf8d3ebcd1a089771b627806b8281deffb8c697dc47d52ac639432e"
+ },
+ {
+ "path": "installer/src-tauri/icons/128x128@2x.png",
+ "bytes": 75057,
+ "sha256": "a18d68acdf055c735735f58d15a95e59bf8464146028861c8aed2123ae6e5241"
+ },
+ {
+ "path": "installer/src-tauri/icons/32x32.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "installer/src-tauri/icons/64x64.png",
+ "bytes": 7228,
+ "sha256": "d2c4c5ca72928ee29f3b6ede38b87af9d519581b0065b7d44e9249c6448848d1"
+ },
+ {
+ "path": "installer/src-tauri/icons/Square107x107Logo.png",
+ "bytes": 16914,
+ "sha256": "b8ea0dc5276770fb2d7665436dd6ffdf3bc1f3df2da0622f3b3258fd2297bf61"
+ },
+ {
+ "path": "installer/src-tauri/icons/Square142x142Logo.png",
+ "bytes": 26888,
+ "sha256": "f63ae5c093caccf98ade422291a3c1f425b6d64260ed3ab38fca8ec426ea5681"
+ },
+ {
+ "path": "installer/src-tauri/icons/Square150x150Logo.png",
+ "bytes": 29368,
+ "sha256": "31f5f5f505afc75891da0b01441e44c2056989034459b99154203094e8874ca8"
+ },
+ {
+ "path": "installer/src-tauri/icons/Square284x284Logo.png",
+ "bytes": 87937,
+ "sha256": "79c8fc7c0fc1907c6e61f35c2e680212bd368c7c77a2da1eae8fe3202e8939c2"
+ },
+ {
+ "path": "installer/src-tauri/icons/Square30x30Logo.png",
+ "bytes": 2327,
+ "sha256": "04aa27294dcae70b5a466befb6991b85a560e85d93439b91c6fbf0187853f05f"
+ },
+ {
+ "path": "installer/src-tauri/icons/Square310x310Logo.png",
+ "bytes": 103579,
+ "sha256": "7ace27c517cbf0a20f03550281d36db3fe0f38423cca9ffad2208b3ab1ffa110"
+ },
+ {
+ "path": "installer/src-tauri/icons/Square44x44Logo.png",
+ "bytes": 4361,
+ "sha256": "ceb53f67fe5a42ad93d80de1525e0422214af302e7049075a64cbc38b2646372"
+ },
+ {
+ "path": "installer/src-tauri/icons/Square71x71Logo.png",
+ "bytes": 8661,
+ "sha256": "2589792c6b966f193c2dee8d9dd59bded04c4cdb98f6177ff54fada83ac928a3"
+ },
+ {
+ "path": "installer/src-tauri/icons/Square89x89Logo.png",
+ "bytes": 12476,
+ "sha256": "2b055cb5c3c3c07b5f98e65116edcf9bd060d094769f1a5dbd0cdd17b1ba1910"
+ },
+ {
+ "path": "installer/src-tauri/icons/StoreLogo.png",
+ "bytes": 5188,
+ "sha256": "e2c2d3335326a8b7ea97af2cd08360bcff2914d6cf0864c506fb56461d9bb817"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-anydpi-v26/ic_launcher.xml",
+ "bytes": 261,
+ "sha256": "760d4b8a06bf7163dd010c33ad2cac9e4a75fa0177afaba042f83e311eef0c3e"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher.png",
+ "bytes": 4128,
+ "sha256": "f7a47ad0933472e6218e1d203c54dfe1c0cb0d8ba030bceb5d9ab6a774e89199"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_foreground.png",
+ "bytes": 26742,
+ "sha256": "e44f601d55c965b868272422d07cde0dc67237329369cb60e252100b58c1e2c3"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_round.png",
+ "bytes": 4128,
+ "sha256": "f7a47ad0933472e6218e1d203c54dfe1c0cb0d8ba030bceb5d9ab6a774e89199"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher.png",
+ "bytes": 3855,
+ "sha256": "3d1dff05ffdd4337b8982b4bfce7aef53c4a205227f5e7a73974aab81e422783"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_foreground.png",
+ "bytes": 13226,
+ "sha256": "05a4b7bccae17fba2e9f10f02e572e04a4081b3eed5fa47d4d9bae73fe8d07e7"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_round.png",
+ "bytes": 3855,
+ "sha256": "3d1dff05ffdd4337b8982b4bfce7aef53c4a205227f5e7a73974aab81e422783"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher.png",
+ "bytes": 10916,
+ "sha256": "ab3db37b6e5aede879bf927ea6304294e233b481fb202f78fec9db02aaaa59ad"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_foreground.png",
+ "bytes": 44333,
+ "sha256": "406e7bd86457207167a07bd2568e2915114665df701d65cfa2e43ebe3970d77f"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_round.png",
+ "bytes": 10916,
+ "sha256": "ab3db37b6e5aede879bf927ea6304294e233b481fb202f78fec9db02aaaa59ad"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher.png",
+ "bytes": 21787,
+ "sha256": "023174b84c84a7d12dacd805a113d030960ec77614980271d365ad365e083a7c"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png",
+ "bytes": 92756,
+ "sha256": "a6920b81ba4e3c64c7dc4aaba3b7b51ba3159cc46851a3feab653503eb931245"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_round.png",
+ "bytes": 21787,
+ "sha256": "023174b84c84a7d12dacd805a113d030960ec77614980271d365ad365e083a7c"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher.png",
+ "bytes": 36148,
+ "sha256": "0bc97a240d00b1f4e0b623c3d33eb00edea683e7192f2f48fc50a25ab8c31093"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png",
+ "bytes": 167030,
+ "sha256": "f3a42f7b7205cc667ff890ee3ce4b2380d817751c0a7b77efa78df85a284715f"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_round.png",
+ "bytes": 36148,
+ "sha256": "0bc97a240d00b1f4e0b623c3d33eb00edea683e7192f2f48fc50a25ab8c31093"
+ },
+ {
+ "path": "installer/src-tauri/icons/android/values/ic_launcher_background.xml",
+ "bytes": 118,
+ "sha256": "cfd1fe5d927768c1684791c0acb0fa62cab2156d009268446f5532756294aa20"
+ },
+ {
+ "path": "installer/src-tauri/icons/icon.icns",
+ "bytes": 1418891,
+ "sha256": "efd1d8bf22a5d2e1a92bf93f4e315022c42d6828dcf045e063ccfece2f2a31d1"
+ },
+ {
+ "path": "installer/src-tauri/icons/icon.ico",
+ "bytes": 114681,
+ "sha256": "b54f4e48202d083a4d4c101418e999fdbf9bc17ab2d789a494841e7a125d7482"
+ },
+ {
+ "path": "installer/src-tauri/icons/icon.png",
+ "bytes": 286843,
+ "sha256": "ee957c7ef29958df5a47290c50e4cc71161d7dcd228c04cf4beb221a271edca2"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-20x20@1x.png",
+ "bytes": 1008,
+ "sha256": "a2a39dc0772ffc5e8aa5bdc8181b8ac86e8d8a5ab3d0c5e8f806824014f8244d"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-20x20@2x-1.png",
+ "bytes": 3051,
+ "sha256": "d6cbfe05c02f477d00737f152a4bbe03df94146ef227b885bc7e16f23a4adcfa"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-20x20@2x.png",
+ "bytes": 3051,
+ "sha256": "d6cbfe05c02f477d00737f152a4bbe03df94146ef227b885bc7e16f23a4adcfa"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-20x20@3x.png",
+ "bytes": 5936,
+ "sha256": "d0726369fdd5fc4a337006ce14e918b92d0494ea9c29344dffa8526c8b71ed23"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-29x29@1x.png",
+ "bytes": 1789,
+ "sha256": "f0d5ec605ec54483c5869bc1a2b6eaf6bd284e1013acd0af9f55406b4ae8c351"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-29x29@2x-1.png",
+ "bytes": 5608,
+ "sha256": "af280c5c0ac4ef04bf2ff249a4939feb03b51ec574f1c84782e4750fa7c1090e"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-29x29@2x.png",
+ "bytes": 5608,
+ "sha256": "af280c5c0ac4ef04bf2ff249a4939feb03b51ec574f1c84782e4750fa7c1090e"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-29x29@3x.png",
+ "bytes": 9345,
+ "sha256": "f0d560f35d035bc22adf7e877df9dcb7f696c1ef25bc6ab13bb03a5275da4537"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-40x40@1x.png",
+ "bytes": 3051,
+ "sha256": "d6cbfe05c02f477d00737f152a4bbe03df94146ef227b885bc7e16f23a4adcfa"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-40x40@2x-1.png",
+ "bytes": 8057,
+ "sha256": "92e72d0655bbef95409fe120d2f0de29ae129628da9006551891a1cd6619af67"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-40x40@2x.png",
+ "bytes": 8057,
+ "sha256": "92e72d0655bbef95409fe120d2f0de29ae129628da9006551891a1cd6619af67"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-40x40@3x.png",
+ "bytes": 15964,
+ "sha256": "fa89bd4d1d57d98a01aa27681a102bd31a610e3e8ec2779953685b74c64c2349"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-512@2x.png",
+ "bytes": 868655,
+ "sha256": "9e56dc0ac53ee8fde77647e57fe322673fbc5e76205632bd7b3c6aa87343f24d"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-60x60@2x.png",
+ "bytes": 15964,
+ "sha256": "fa89bd4d1d57d98a01aa27681a102bd31a610e3e8ec2779953685b74c64c2349"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-60x60@3x.png",
+ "bytes": 31778,
+ "sha256": "9f569deeab77490d2df63ee2a20965bf7b31bd70504a980ee8676c6dbb4548b3"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-76x76@1x.png",
+ "bytes": 7348,
+ "sha256": "0105d01b2ba4f091d0039385506acd8ade2b31702759ce84abf2fac8daa2a351"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-76x76@2x.png",
+ "bytes": 23983,
+ "sha256": "0ed26e0918b9e18a36ceffdc55f329610ab1ae029c518964a27b6bad7f6137fb"
+ },
+ {
+ "path": "installer/src-tauri/icons/ios/AppIcon-83.5x83.5@2x.png",
+ "bytes": 28253,
+ "sha256": "0fa0fcaf13711cad20686a8112af1600db69db8184b966efdaa916090cf7da56"
+ },
+ {
+ "path": "installer/src/assets/brand/sparo-mark-16.png",
+ "bytes": 793,
+ "sha256": "17a69d0395848de0a3c5506ea1b7df986949b0596d8652fb607c0a49582ef074"
+ },
+ {
+ "path": "installer/src/assets/brand/sparo-mark-24.png",
+ "bytes": 1429,
+ "sha256": "9be58d8aabb5a18baac37ea92b66f61bd0e530eb345e646068b94aec16b72dbc"
+ },
+ {
+ "path": "installer/src/assets/brand/sparo-mark-32.png",
+ "bytes": 2220,
+ "sha256": "03d12b7f4bd2fe97296c1a28f33d20648ef4a41e1f51eee65c8ef0c0cea4f236"
+ },
+ {
+ "path": "installer/src/assets/brand/sparo-mark-48.png",
+ "bytes": 4254,
+ "sha256": "6bc33619b7b8fc5f359496177d1fe32c29e39f145fd2ef297474350ea16ec81b"
+ },
+ {
+ "path": "installer/src/assets/brand/sparo-mark-full.png",
+ "bytes": 237905,
+ "sha256": "290b3b68a69e4e61f239d88a965f95b1ba55bc52d9704b1b430d178b24bfccdd"
+ },
+ {
+ "path": "src/apps/desktop/icons/128x128.png",
+ "bytes": 22999,
+ "sha256": "76e85fe60cf8d3ebcd1a089771b627806b8281deffb8c697dc47d52ac639432e"
+ },
+ {
+ "path": "src/apps/desktop/icons/128x128@2x.png",
+ "bytes": 75057,
+ "sha256": "a18d68acdf055c735735f58d15a95e59bf8464146028861c8aed2123ae6e5241"
+ },
+ {
+ "path": "src/apps/desktop/icons/32x32.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "src/apps/desktop/icons/64x64.png",
+ "bytes": 7228,
+ "sha256": "d2c4c5ca72928ee29f3b6ede38b87af9d519581b0065b7d44e9249c6448848d1"
+ },
+ {
+ "path": "src/apps/desktop/icons/Square107x107Logo.png",
+ "bytes": 16914,
+ "sha256": "b8ea0dc5276770fb2d7665436dd6ffdf3bc1f3df2da0622f3b3258fd2297bf61"
+ },
+ {
+ "path": "src/apps/desktop/icons/Square142x142Logo.png",
+ "bytes": 26888,
+ "sha256": "f63ae5c093caccf98ade422291a3c1f425b6d64260ed3ab38fca8ec426ea5681"
+ },
+ {
+ "path": "src/apps/desktop/icons/Square150x150Logo.png",
+ "bytes": 29368,
+ "sha256": "31f5f5f505afc75891da0b01441e44c2056989034459b99154203094e8874ca8"
+ },
+ {
+ "path": "src/apps/desktop/icons/Square284x284Logo.png",
+ "bytes": 87937,
+ "sha256": "79c8fc7c0fc1907c6e61f35c2e680212bd368c7c77a2da1eae8fe3202e8939c2"
+ },
+ {
+ "path": "src/apps/desktop/icons/Square30x30Logo.png",
+ "bytes": 2327,
+ "sha256": "04aa27294dcae70b5a466befb6991b85a560e85d93439b91c6fbf0187853f05f"
+ },
+ {
+ "path": "src/apps/desktop/icons/Square310x310Logo.png",
+ "bytes": 103579,
+ "sha256": "7ace27c517cbf0a20f03550281d36db3fe0f38423cca9ffad2208b3ab1ffa110"
+ },
+ {
+ "path": "src/apps/desktop/icons/Square44x44Logo.png",
+ "bytes": 4361,
+ "sha256": "ceb53f67fe5a42ad93d80de1525e0422214af302e7049075a64cbc38b2646372"
+ },
+ {
+ "path": "src/apps/desktop/icons/Square71x71Logo.png",
+ "bytes": 8661,
+ "sha256": "2589792c6b966f193c2dee8d9dd59bded04c4cdb98f6177ff54fada83ac928a3"
+ },
+ {
+ "path": "src/apps/desktop/icons/Square89x89Logo.png",
+ "bytes": 12476,
+ "sha256": "2b055cb5c3c3c07b5f98e65116edcf9bd060d094769f1a5dbd0cdd17b1ba1910"
+ },
+ {
+ "path": "src/apps/desktop/icons/StoreLogo.png",
+ "bytes": 5188,
+ "sha256": "e2c2d3335326a8b7ea97af2cd08360bcff2914d6cf0864c506fb56461d9bb817"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-anydpi-v26/ic_launcher.xml",
+ "bytes": 261,
+ "sha256": "760d4b8a06bf7163dd010c33ad2cac9e4a75fa0177afaba042f83e311eef0c3e"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher.png",
+ "bytes": 4128,
+ "sha256": "f7a47ad0933472e6218e1d203c54dfe1c0cb0d8ba030bceb5d9ab6a774e89199"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_foreground.png",
+ "bytes": 26742,
+ "sha256": "e44f601d55c965b868272422d07cde0dc67237329369cb60e252100b58c1e2c3"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_round.png",
+ "bytes": 4128,
+ "sha256": "f7a47ad0933472e6218e1d203c54dfe1c0cb0d8ba030bceb5d9ab6a774e89199"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher.png",
+ "bytes": 3855,
+ "sha256": "3d1dff05ffdd4337b8982b4bfce7aef53c4a205227f5e7a73974aab81e422783"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_foreground.png",
+ "bytes": 13226,
+ "sha256": "05a4b7bccae17fba2e9f10f02e572e04a4081b3eed5fa47d4d9bae73fe8d07e7"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_round.png",
+ "bytes": 3855,
+ "sha256": "3d1dff05ffdd4337b8982b4bfce7aef53c4a205227f5e7a73974aab81e422783"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher.png",
+ "bytes": 10916,
+ "sha256": "ab3db37b6e5aede879bf927ea6304294e233b481fb202f78fec9db02aaaa59ad"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_foreground.png",
+ "bytes": 44333,
+ "sha256": "406e7bd86457207167a07bd2568e2915114665df701d65cfa2e43ebe3970d77f"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_round.png",
+ "bytes": 10916,
+ "sha256": "ab3db37b6e5aede879bf927ea6304294e233b481fb202f78fec9db02aaaa59ad"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher.png",
+ "bytes": 21787,
+ "sha256": "023174b84c84a7d12dacd805a113d030960ec77614980271d365ad365e083a7c"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png",
+ "bytes": 92756,
+ "sha256": "a6920b81ba4e3c64c7dc4aaba3b7b51ba3159cc46851a3feab653503eb931245"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_round.png",
+ "bytes": 21787,
+ "sha256": "023174b84c84a7d12dacd805a113d030960ec77614980271d365ad365e083a7c"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher.png",
+ "bytes": 36148,
+ "sha256": "0bc97a240d00b1f4e0b623c3d33eb00edea683e7192f2f48fc50a25ab8c31093"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png",
+ "bytes": 167030,
+ "sha256": "f3a42f7b7205cc667ff890ee3ce4b2380d817751c0a7b77efa78df85a284715f"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_round.png",
+ "bytes": 36148,
+ "sha256": "0bc97a240d00b1f4e0b623c3d33eb00edea683e7192f2f48fc50a25ab8c31093"
+ },
+ {
+ "path": "src/apps/desktop/icons/android/values/ic_launcher_background.xml",
+ "bytes": 118,
+ "sha256": "cfd1fe5d927768c1684791c0acb0fa62cab2156d009268446f5532756294aa20"
+ },
+ {
+ "path": "src/apps/desktop/icons/hicolor/128x128/apps/sparo-os.png",
+ "bytes": 22999,
+ "sha256": "76e85fe60cf8d3ebcd1a089771b627806b8281deffb8c697dc47d52ac639432e"
+ },
+ {
+ "path": "src/apps/desktop/icons/hicolor/16x16/apps/sparo-os.png",
+ "bytes": 813,
+ "sha256": "81321112286d69c31a13b99a10ba3e3248cc305774cf6f4e4858263851bef83f"
+ },
+ {
+ "path": "src/apps/desktop/icons/hicolor/256x256/apps/sparo-os.png",
+ "bytes": 75057,
+ "sha256": "a18d68acdf055c735735f58d15a95e59bf8464146028861c8aed2123ae6e5241"
+ },
+ {
+ "path": "src/apps/desktop/icons/hicolor/32x32/apps/sparo-os.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "src/apps/desktop/icons/hicolor/48x48/apps/sparo-os.png",
+ "bytes": 4554,
+ "sha256": "b57e8dc54b97d931844d6d4b358f9d2963c427fac9b36a5c8a875e335d90426d"
+ },
+ {
+ "path": "src/apps/desktop/icons/hicolor/512x512/apps/sparo-os.png",
+ "bytes": 286843,
+ "sha256": "ee957c7ef29958df5a47290c50e4cc71161d7dcd228c04cf4beb221a271edca2"
+ },
+ {
+ "path": "src/apps/desktop/icons/hicolor/64x64/apps/sparo-os.png",
+ "bytes": 7228,
+ "sha256": "d2c4c5ca72928ee29f3b6ede38b87af9d519581b0065b7d44e9249c6448848d1"
+ },
+ {
+ "path": "src/apps/desktop/icons/hicolor/96x96/apps/sparo-os.png",
+ "bytes": 14197,
+ "sha256": "8b5594005c89ed50a14e663f0b7e1aca41160db7f510bdaec940c8cfc0489a1a"
+ },
+ {
+ "path": "src/apps/desktop/icons/icon.icns",
+ "bytes": 1418891,
+ "sha256": "dcd23153b7157f2db0d7f4aa8c002be5269fe047f8cd2b774b753adc680bc14b"
+ },
+ {
+ "path": "src/apps/desktop/icons/icon.ico",
+ "bytes": 114681,
+ "sha256": "b54f4e48202d083a4d4c101418e999fdbf9bc17ab2d789a494841e7a125d7482"
+ },
+ {
+ "path": "src/apps/desktop/icons/icon.png",
+ "bytes": 286843,
+ "sha256": "ee957c7ef29958df5a47290c50e4cc71161d7dcd228c04cf4beb221a271edca2"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-20x20@1x.png",
+ "bytes": 1008,
+ "sha256": "a2a39dc0772ffc5e8aa5bdc8181b8ac86e8d8a5ab3d0c5e8f806824014f8244d"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-20x20@2x-1.png",
+ "bytes": 3051,
+ "sha256": "d6cbfe05c02f477d00737f152a4bbe03df94146ef227b885bc7e16f23a4adcfa"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-20x20@2x.png",
+ "bytes": 3051,
+ "sha256": "d6cbfe05c02f477d00737f152a4bbe03df94146ef227b885bc7e16f23a4adcfa"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-20x20@3x.png",
+ "bytes": 5936,
+ "sha256": "d0726369fdd5fc4a337006ce14e918b92d0494ea9c29344dffa8526c8b71ed23"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-29x29@1x.png",
+ "bytes": 1789,
+ "sha256": "f0d5ec605ec54483c5869bc1a2b6eaf6bd284e1013acd0af9f55406b4ae8c351"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-29x29@2x-1.png",
+ "bytes": 5608,
+ "sha256": "af280c5c0ac4ef04bf2ff249a4939feb03b51ec574f1c84782e4750fa7c1090e"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-29x29@2x.png",
+ "bytes": 5608,
+ "sha256": "af280c5c0ac4ef04bf2ff249a4939feb03b51ec574f1c84782e4750fa7c1090e"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-29x29@3x.png",
+ "bytes": 9345,
+ "sha256": "f0d560f35d035bc22adf7e877df9dcb7f696c1ef25bc6ab13bb03a5275da4537"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-40x40@1x.png",
+ "bytes": 3051,
+ "sha256": "d6cbfe05c02f477d00737f152a4bbe03df94146ef227b885bc7e16f23a4adcfa"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-40x40@2x-1.png",
+ "bytes": 8057,
+ "sha256": "92e72d0655bbef95409fe120d2f0de29ae129628da9006551891a1cd6619af67"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-40x40@2x.png",
+ "bytes": 8057,
+ "sha256": "92e72d0655bbef95409fe120d2f0de29ae129628da9006551891a1cd6619af67"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-40x40@3x.png",
+ "bytes": 15964,
+ "sha256": "fa89bd4d1d57d98a01aa27681a102bd31a610e3e8ec2779953685b74c64c2349"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-512@2x.png",
+ "bytes": 868655,
+ "sha256": "9e56dc0ac53ee8fde77647e57fe322673fbc5e76205632bd7b3c6aa87343f24d"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-60x60@2x.png",
+ "bytes": 15964,
+ "sha256": "fa89bd4d1d57d98a01aa27681a102bd31a610e3e8ec2779953685b74c64c2349"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-60x60@3x.png",
+ "bytes": 31778,
+ "sha256": "9f569deeab77490d2df63ee2a20965bf7b31bd70504a980ee8676c6dbb4548b3"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-76x76@1x.png",
+ "bytes": 7348,
+ "sha256": "0105d01b2ba4f091d0039385506acd8ade2b31702759ce84abf2fac8daa2a351"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-76x76@2x.png",
+ "bytes": 23983,
+ "sha256": "0ed26e0918b9e18a36ceffdc55f329610ab1ae029c518964a27b6bad7f6137fb"
+ },
+ {
+ "path": "src/apps/desktop/icons/ios/AppIcon-83.5x83.5@2x.png",
+ "bytes": 28253,
+ "sha256": "0fa0fcaf13711cad20686a8112af1600db69db8184b966efdaa916090cf7da56"
+ },
+ {
+ "path": "src/apps/desktop/icons/tray/tray-error.png",
+ "bytes": 2359,
+ "sha256": "f8262c27dbd553f84a4648aaf037f208598926d349993a1e9670d517f1dcbc26"
+ },
+ {
+ "path": "src/apps/desktop/icons/tray/tray-idle.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "src/apps/desktop/icons/tray/tray-running.png",
+ "bytes": 2360,
+ "sha256": "8d6c230705373932a75184280d07152dedca28c215c0810e3f710a93f2b899b5"
+ },
+ {
+ "path": "src/apps/desktop/icons/tray/tray-waiting.png",
+ "bytes": 2357,
+ "sha256": "793bf22cf7d1dde92affdbfba7a9deeea6278564c450cc5d63edd38da5e9d2ad"
+ },
+ {
+ "path": "src/apps/relay-server/static/brand/app-icon-180.png",
+ "bytes": 39902,
+ "sha256": "9d5507571b8b6ffb547842f7e75d19aa36abe5e278870c596cd7430359ccfa46"
+ },
+ {
+ "path": "src/apps/relay-server/static/brand/favicon-32.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "src/apps/relay-server/static/brand/sparo-mark-16.png",
+ "bytes": 793,
+ "sha256": "17a69d0395848de0a3c5506ea1b7df986949b0596d8652fb607c0a49582ef074"
+ },
+ {
+ "path": "src/apps/relay-server/static/brand/sparo-mark-24.png",
+ "bytes": 1429,
+ "sha256": "9be58d8aabb5a18baac37ea92b66f61bd0e530eb345e646068b94aec16b72dbc"
+ },
+ {
+ "path": "src/apps/relay-server/static/brand/sparo-mark-32.png",
+ "bytes": 2220,
+ "sha256": "03d12b7f4bd2fe97296c1a28f33d20648ef4a41e1f51eee65c8ef0c0cea4f236"
+ },
+ {
+ "path": "src/apps/relay-server/static/brand/sparo-mark-48.png",
+ "bytes": 4254,
+ "sha256": "6bc33619b7b8fc5f359496177d1fe32c29e39f145fd2ef297474350ea16ec81b"
+ },
+ {
+ "path": "src/apps/relay-server/static/brand/sparo-mark-full.png",
+ "bytes": 237905,
+ "sha256": "290b3b68a69e4e61f239d88a965f95b1ba55bc52d9704b1b430d178b24bfccdd"
+ },
+ {
+ "path": "src/mobile-web/public/brand/app-icon-180.png",
+ "bytes": 39902,
+ "sha256": "9d5507571b8b6ffb547842f7e75d19aa36abe5e278870c596cd7430359ccfa46"
+ },
+ {
+ "path": "src/mobile-web/public/brand/favicon-32.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "src/mobile-web/public/brand/sparo-mark-16.png",
+ "bytes": 793,
+ "sha256": "17a69d0395848de0a3c5506ea1b7df986949b0596d8652fb607c0a49582ef074"
+ },
+ {
+ "path": "src/mobile-web/public/brand/sparo-mark-24.png",
+ "bytes": 1429,
+ "sha256": "9be58d8aabb5a18baac37ea92b66f61bd0e530eb345e646068b94aec16b72dbc"
+ },
+ {
+ "path": "src/mobile-web/public/brand/sparo-mark-32.png",
+ "bytes": 2220,
+ "sha256": "03d12b7f4bd2fe97296c1a28f33d20648ef4a41e1f51eee65c8ef0c0cea4f236"
+ },
+ {
+ "path": "src/mobile-web/public/brand/sparo-mark-48.png",
+ "bytes": 4254,
+ "sha256": "6bc33619b7b8fc5f359496177d1fe32c29e39f145fd2ef297474350ea16ec81b"
+ },
+ {
+ "path": "src/mobile-web/public/brand/sparo-mark-full.png",
+ "bytes": 237905,
+ "sha256": "290b3b68a69e4e61f239d88a965f95b1ba55bc52d9704b1b430d178b24bfccdd"
+ },
+ {
+ "path": "src/web-ui/public/brand/app-icon-512.png",
+ "bytes": 286830,
+ "sha256": "f453249bbc010d885cac92f94c9f236cd8cf63b1057d90a175afb142bd11500d"
+ },
+ {
+ "path": "src/web-ui/public/brand/favicon-32.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "src/web-ui/public/brand/sparo-mark-256.png",
+ "bytes": 66587,
+ "sha256": "f1869e6ae634eaf53dc49e44d96b6fd838c8648892687b25e490fff33a371835"
+ },
+ {
+ "path": "src/web-ui/public/brand/sparo-mark-full.png",
+ "bytes": 237905,
+ "sha256": "290b3b68a69e4e61f239d88a965f95b1ba55bc52d9704b1b430d178b24bfccdd"
+ },
+ {
+ "path": "src/web-ui/public/brand/sparo-wordmark-primary.png",
+ "bytes": 34510,
+ "sha256": "ac61b6608967a896889ef42eed5fcb838c258fbce0bee984a7746d149db5c4c3"
+ },
+ {
+ "path": "src/web-ui/public/brand/sparo-wordmark-reversed.png",
+ "bytes": 34511,
+ "sha256": "772b0f73821ba015ae6b3f37cfbbdb897fd4db07b504d5fdf70062cf5c207348"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-app-icon-32.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-core-16.png",
+ "bytes": 583,
+ "sha256": "d8c56ce81f3e842aa9dded49b862b052d82ce3fb3f40d9364c0dae4aae4de9ac"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-core-20.png",
+ "bytes": 817,
+ "sha256": "0a8dcd51fd7be98662cb0a61557ded28dda83a3b5169909978a1ec1f021df3c7"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-core-24.png",
+ "bytes": 1010,
+ "sha256": "ed51d728c8b6dfad5353b57bbea5ef1e04f6a97d7f8f3417ded98c323f375236"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-core-32.png",
+ "bytes": 1490,
+ "sha256": "d5b8e8716df53caac81df865cfbb9262dd525b52923090e233cf1470ec6ee3bc"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-core-48.png",
+ "bytes": 2721,
+ "sha256": "cc42a80faeb9e22ca8fea8971bc350caac29ea0c673a420a3c176e4f8c8f5367"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-mark-16.png",
+ "bytes": 793,
+ "sha256": "17a69d0395848de0a3c5506ea1b7df986949b0596d8652fb607c0a49582ef074"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-mark-24.png",
+ "bytes": 1429,
+ "sha256": "9be58d8aabb5a18baac37ea92b66f61bd0e530eb345e646068b94aec16b72dbc"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-mark-256.png",
+ "bytes": 66587,
+ "sha256": "f1869e6ae634eaf53dc49e44d96b6fd838c8648892687b25e490fff33a371835"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-mark-32.png",
+ "bytes": 2220,
+ "sha256": "03d12b7f4bd2fe97296c1a28f33d20648ef4a41e1f51eee65c8ef0c0cea4f236"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-mark-48.png",
+ "bytes": 4254,
+ "sha256": "6bc33619b7b8fc5f359496177d1fe32c29e39f145fd2ef297474350ea16ec81b"
+ },
+ {
+ "path": "src/web-ui/src/design-system/foundation/brand/sparo-mark-full.png",
+ "bytes": 237905,
+ "sha256": "290b3b68a69e4e61f239d88a965f95b1ba55bc52d9704b1b430d178b24bfccdd"
+ }
+ ]
+}
diff --git a/assets/brand/exports/app-icon/sparo-app-icon-1024.png b/assets/brand/exports/app-icon/sparo-app-icon-1024.png
new file mode 100644
index 00000000..20c674d3
Binary files /dev/null and b/assets/brand/exports/app-icon/sparo-app-icon-1024.png differ
diff --git a/assets/brand/exports/app-icon/sparo-app-icon-128.png b/assets/brand/exports/app-icon/sparo-app-icon-128.png
new file mode 100644
index 00000000..7895d648
Binary files /dev/null and b/assets/brand/exports/app-icon/sparo-app-icon-128.png differ
diff --git a/assets/brand/exports/app-icon/sparo-app-icon-16.png b/assets/brand/exports/app-icon/sparo-app-icon-16.png
new file mode 100644
index 00000000..0e7ccb52
Binary files /dev/null and b/assets/brand/exports/app-icon/sparo-app-icon-16.png differ
diff --git a/assets/brand/exports/app-icon/sparo-app-icon-24.png b/assets/brand/exports/app-icon/sparo-app-icon-24.png
new file mode 100644
index 00000000..15c2fb89
Binary files /dev/null and b/assets/brand/exports/app-icon/sparo-app-icon-24.png differ
diff --git a/assets/brand/exports/app-icon/sparo-app-icon-256.png b/assets/brand/exports/app-icon/sparo-app-icon-256.png
new file mode 100644
index 00000000..5a0c0e81
Binary files /dev/null and b/assets/brand/exports/app-icon/sparo-app-icon-256.png differ
diff --git a/assets/brand/exports/app-icon/sparo-app-icon-32.png b/assets/brand/exports/app-icon/sparo-app-icon-32.png
new file mode 100644
index 00000000..2f5e44f9
Binary files /dev/null and b/assets/brand/exports/app-icon/sparo-app-icon-32.png differ
diff --git a/assets/brand/exports/app-icon/sparo-app-icon-48.png b/assets/brand/exports/app-icon/sparo-app-icon-48.png
new file mode 100644
index 00000000..3a8be1f4
Binary files /dev/null and b/assets/brand/exports/app-icon/sparo-app-icon-48.png differ
diff --git a/assets/brand/exports/app-icon/sparo-app-icon-512.png b/assets/brand/exports/app-icon/sparo-app-icon-512.png
new file mode 100644
index 00000000..c9cd4a69
Binary files /dev/null and b/assets/brand/exports/app-icon/sparo-app-icon-512.png differ
diff --git a/assets/brand/exports/app-icon/sparo-app-icon-64.png b/assets/brand/exports/app-icon/sparo-app-icon-64.png
new file mode 100644
index 00000000..5b7a72cc
Binary files /dev/null and b/assets/brand/exports/app-icon/sparo-app-icon-64.png differ
diff --git a/assets/brand/exports/core/sparo-core-16.png b/assets/brand/exports/core/sparo-core-16.png
new file mode 100644
index 00000000..b9f45ded
Binary files /dev/null and b/assets/brand/exports/core/sparo-core-16.png differ
diff --git a/assets/brand/exports/core/sparo-core-20.png b/assets/brand/exports/core/sparo-core-20.png
new file mode 100644
index 00000000..6337d009
Binary files /dev/null and b/assets/brand/exports/core/sparo-core-20.png differ
diff --git a/assets/brand/exports/core/sparo-core-24.png b/assets/brand/exports/core/sparo-core-24.png
new file mode 100644
index 00000000..27852d0d
Binary files /dev/null and b/assets/brand/exports/core/sparo-core-24.png differ
diff --git a/assets/brand/exports/core/sparo-core-32.png b/assets/brand/exports/core/sparo-core-32.png
new file mode 100644
index 00000000..f5eb3acd
Binary files /dev/null and b/assets/brand/exports/core/sparo-core-32.png differ
diff --git a/assets/brand/exports/core/sparo-core-48.png b/assets/brand/exports/core/sparo-core-48.png
new file mode 100644
index 00000000..5301c09b
Binary files /dev/null and b/assets/brand/exports/core/sparo-core-48.png differ
diff --git a/assets/brand/exports/lockup/sparo-lockup-horizontal-mono.png b/assets/brand/exports/lockup/sparo-lockup-horizontal-mono.png
new file mode 100644
index 00000000..75f6ead3
Binary files /dev/null and b/assets/brand/exports/lockup/sparo-lockup-horizontal-mono.png differ
diff --git a/assets/brand/exports/lockup/sparo-lockup-horizontal-primary.png b/assets/brand/exports/lockup/sparo-lockup-horizontal-primary.png
new file mode 100644
index 00000000..4521468c
Binary files /dev/null and b/assets/brand/exports/lockup/sparo-lockup-horizontal-primary.png differ
diff --git a/assets/brand/exports/lockup/sparo-lockup-horizontal-reversed.png b/assets/brand/exports/lockup/sparo-lockup-horizontal-reversed.png
new file mode 100644
index 00000000..d45f8675
Binary files /dev/null and b/assets/brand/exports/lockup/sparo-lockup-horizontal-reversed.png differ
diff --git a/assets/brand/exports/mark/sparo-mark-128.png b/assets/brand/exports/mark/sparo-mark-128.png
new file mode 100644
index 00000000..f456853c
Binary files /dev/null and b/assets/brand/exports/mark/sparo-mark-128.png differ
diff --git a/assets/brand/exports/mark/sparo-mark-16.png b/assets/brand/exports/mark/sparo-mark-16.png
new file mode 100644
index 00000000..436e8c9f
Binary files /dev/null and b/assets/brand/exports/mark/sparo-mark-16.png differ
diff --git a/assets/brand/exports/mark/sparo-mark-24.png b/assets/brand/exports/mark/sparo-mark-24.png
new file mode 100644
index 00000000..b3e6726f
Binary files /dev/null and b/assets/brand/exports/mark/sparo-mark-24.png differ
diff --git a/assets/brand/exports/mark/sparo-mark-256.png b/assets/brand/exports/mark/sparo-mark-256.png
new file mode 100644
index 00000000..aee2c85c
Binary files /dev/null and b/assets/brand/exports/mark/sparo-mark-256.png differ
diff --git a/assets/brand/exports/mark/sparo-mark-32.png b/assets/brand/exports/mark/sparo-mark-32.png
new file mode 100644
index 00000000..4078a327
Binary files /dev/null and b/assets/brand/exports/mark/sparo-mark-32.png differ
diff --git a/assets/brand/exports/mark/sparo-mark-48.png b/assets/brand/exports/mark/sparo-mark-48.png
new file mode 100644
index 00000000..5ae20c02
Binary files /dev/null and b/assets/brand/exports/mark/sparo-mark-48.png differ
diff --git a/assets/brand/exports/mark/sparo-mark-512.png b/assets/brand/exports/mark/sparo-mark-512.png
new file mode 100644
index 00000000..275ec993
Binary files /dev/null and b/assets/brand/exports/mark/sparo-mark-512.png differ
diff --git a/assets/brand/exports/mark/sparo-mark-64.png b/assets/brand/exports/mark/sparo-mark-64.png
new file mode 100644
index 00000000..17158d09
Binary files /dev/null and b/assets/brand/exports/mark/sparo-mark-64.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-16-dark.png b/assets/brand/exports/tray/sparo-tray-16-dark.png
new file mode 100644
index 00000000..0e7ccb52
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-16-dark.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-16-light.png b/assets/brand/exports/tray/sparo-tray-16-light.png
new file mode 100644
index 00000000..0e7ccb52
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-16-light.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-20-dark.png b/assets/brand/exports/tray/sparo-tray-20-dark.png
new file mode 100644
index 00000000..fe2e7c57
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-20-dark.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-20-light.png b/assets/brand/exports/tray/sparo-tray-20-light.png
new file mode 100644
index 00000000..fe2e7c57
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-20-light.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-24-dark.png b/assets/brand/exports/tray/sparo-tray-24-dark.png
new file mode 100644
index 00000000..15c2fb89
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-24-dark.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-24-light.png b/assets/brand/exports/tray/sparo-tray-24-light.png
new file mode 100644
index 00000000..15c2fb89
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-24-light.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-32-dark.png b/assets/brand/exports/tray/sparo-tray-32-dark.png
new file mode 100644
index 00000000..2f5e44f9
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-32-dark.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-32-light.png b/assets/brand/exports/tray/sparo-tray-32-light.png
new file mode 100644
index 00000000..2f5e44f9
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-32-light.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-48-dark.png b/assets/brand/exports/tray/sparo-tray-48-dark.png
new file mode 100644
index 00000000..3a8be1f4
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-48-dark.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-48-light.png b/assets/brand/exports/tray/sparo-tray-48-light.png
new file mode 100644
index 00000000..3a8be1f4
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-48-light.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-error.png b/assets/brand/exports/tray/sparo-tray-error.png
new file mode 100644
index 00000000..38183031
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-error.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-idle-16.png b/assets/brand/exports/tray/sparo-tray-idle-16.png
new file mode 100644
index 00000000..0e7ccb52
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-idle-16.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-idle-20.png b/assets/brand/exports/tray/sparo-tray-idle-20.png
new file mode 100644
index 00000000..fe2e7c57
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-idle-20.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-idle-24.png b/assets/brand/exports/tray/sparo-tray-idle-24.png
new file mode 100644
index 00000000..15c2fb89
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-idle-24.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-idle-32.png b/assets/brand/exports/tray/sparo-tray-idle-32.png
new file mode 100644
index 00000000..2f5e44f9
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-idle-32.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-idle-48.png b/assets/brand/exports/tray/sparo-tray-idle-48.png
new file mode 100644
index 00000000..3a8be1f4
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-idle-48.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-idle.png b/assets/brand/exports/tray/sparo-tray-idle.png
new file mode 100644
index 00000000..2f5e44f9
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-idle.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-running.png b/assets/brand/exports/tray/sparo-tray-running.png
new file mode 100644
index 00000000..c7751275
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-running.png differ
diff --git a/assets/brand/exports/tray/sparo-tray-waiting.png b/assets/brand/exports/tray/sparo-tray-waiting.png
new file mode 100644
index 00000000..8860bfe9
Binary files /dev/null and b/assets/brand/exports/tray/sparo-tray-waiting.png differ
diff --git a/assets/brand/exports/web/apple-touch-icon-180.png b/assets/brand/exports/web/apple-touch-icon-180.png
new file mode 100644
index 00000000..3bce3cf1
Binary files /dev/null and b/assets/brand/exports/web/apple-touch-icon-180.png differ
diff --git a/assets/brand/exports/web/favicon-16.png b/assets/brand/exports/web/favicon-16.png
new file mode 100644
index 00000000..0e7ccb52
Binary files /dev/null and b/assets/brand/exports/web/favicon-16.png differ
diff --git a/assets/brand/exports/web/favicon-32.png b/assets/brand/exports/web/favicon-32.png
new file mode 100644
index 00000000..2f5e44f9
Binary files /dev/null and b/assets/brand/exports/web/favicon-32.png differ
diff --git a/assets/brand/exports/web/favicon-48.png b/assets/brand/exports/web/favicon-48.png
new file mode 100644
index 00000000..3a8be1f4
Binary files /dev/null and b/assets/brand/exports/web/favicon-48.png differ
diff --git a/assets/brand/exports/web/web-app-icon-192.png b/assets/brand/exports/web/web-app-icon-192.png
new file mode 100644
index 00000000..1e9c7f91
Binary files /dev/null and b/assets/brand/exports/web/web-app-icon-192.png differ
diff --git a/assets/brand/exports/web/web-app-icon-512.png b/assets/brand/exports/web/web-app-icon-512.png
new file mode 100644
index 00000000..2fe045bc
Binary files /dev/null and b/assets/brand/exports/web/web-app-icon-512.png differ
diff --git a/assets/brand/exports/wordmark/sparo-wordmark-mono.png b/assets/brand/exports/wordmark/sparo-wordmark-mono.png
new file mode 100644
index 00000000..9d59a309
Binary files /dev/null and b/assets/brand/exports/wordmark/sparo-wordmark-mono.png differ
diff --git a/assets/brand/exports/wordmark/sparo-wordmark-primary.png b/assets/brand/exports/wordmark/sparo-wordmark-primary.png
new file mode 100644
index 00000000..73f058cd
Binary files /dev/null and b/assets/brand/exports/wordmark/sparo-wordmark-primary.png differ
diff --git a/assets/brand/exports/wordmark/sparo-wordmark-reversed.png b/assets/brand/exports/wordmark/sparo-wordmark-reversed.png
new file mode 100644
index 00000000..3e6aeb4d
Binary files /dev/null and b/assets/brand/exports/wordmark/sparo-wordmark-reversed.png differ
diff --git a/assets/brand/manifest.json b/assets/brand/manifest.json
new file mode 100644
index 00000000..6b5be9f6
--- /dev/null
+++ b/assets/brand/manifest.json
@@ -0,0 +1,393 @@
+{
+ "schemaVersion": 5,
+ "brandVersion": "2026.08-tight-circular-system-icons",
+ "status": "current",
+ "generatedBy": "pnpm run brand:generate",
+ "provenance": {
+ "mark": {
+ "path": "source/sparo-mark-master.png",
+ "pixels": [
+ 1536,
+ 1024
+ ],
+ "sha256": "10c9328ae0f8543b1713ffb68d752a4d4e8d26a76dae283c597826c92cc5e14d",
+ "treatment": "Low-alpha speckles removed, visible bounds normalized to a true circle, supplied material detail preserved."
+ },
+ "core": {
+ "path": "source/sparo-core-master.png",
+ "pixels": [
+ 1536,
+ 1024
+ ],
+ "sha256": "9bdbc6ebd4d750fb534a7aa166bafaf2313232567acec12c7a0a1c9444c5b3ce",
+ "treatment": "Source silhouette and material preserved for compact in-product core exports; target sizes use alpha-safe reduction and lossless PNG compression."
+ },
+ "reference": {
+ "path": "reference/sparo-identity-board.png",
+ "pixels": [
+ 1448,
+ 1086
+ ],
+ "sha256": "0b2d0032de23174be0381976f8edc90094e7fa380a37dfb7147f873e9e388e4f"
+ },
+ "appIcon": "Transparent margins are removed on all four sides of the normalized circular material Logo before platform-size reduction; source proportions and material are preserved.",
+ "wordmark": "Deterministic transparent raster extraction from the approved identity board with a global 3px optical stroke expansion; the approved letter geometry and red core are preserved without redrawn paths."
+ },
+ "roles": {
+ "defaultLogo": "circular",
+ "applicationIcon": "circular at every size, including taskbar and window icons",
+ "trayIcon": "edge-fitted circular material Logo with the red core; active states add a compact status badge",
+ "wordmark": "Globally optically bold Sparo OS wordmark with a red core inside the lowercase a"
+ },
+ "formatPolicy": "Brand artwork is PNG-only. Product code must not redraw or embed brand geometry as SVG.",
+ "qaPolicy": "QA preview boards are validated for presence, PNG format, and dimensions but excluded from cross-platform byte hashes because their labels use host font rasterization.",
+ "colors": {
+ "coreRed": "#E53935",
+ "warmWhite": "#F5F2EE",
+ "softIvory": "#ECE7E1",
+ "sandGray": "#D8D3CC",
+ "deepCharcoal": "#1A1A1A"
+ },
+ "sourceProcessing": {
+ "alphaThreshold": 8,
+ "detectedVisibleBounds": {
+ "left": 337,
+ "top": 53,
+ "width": 858,
+ "height": 872
+ },
+ "detectedCoreBounds": {
+ "left": 392,
+ "top": 67,
+ "width": 752,
+ "height": 882
+ },
+ "normalizedCanvas": [
+ 1024,
+ 1024
+ ],
+ "wordmark": {
+ "neutralStrokeExpansionPx": 3,
+ "primaryAndReversedPreserveRedCore": true,
+ "redrawnGeometry": false
+ }
+ },
+ "sizePolicy": {
+ "canonicalMinimumPx": 64,
+ "responsiveMinimumPx": 16,
+ "rule": "Use the normalized raster master at 64px and above and target-specific raster reductions at 16-48px.",
+ "smallSizes": [
+ 16,
+ 24,
+ 32,
+ 48
+ ]
+ },
+ "appIcon": {
+ "master": "exports/app-icon/sparo-app-icon-1024.png",
+ "geometry": "circular",
+ "transparentOutsideCircle": true,
+ "edgeFit": "Visible bounds fill all four sides of the square canvas; only the circular corners remain transparent.",
+ "smallSizeProcessing": "Premultiplied-alpha Lanczos reduction from the normalized circular mark.",
+ "iosOpaqueBackground": "#F5F2EE"
+ },
+ "tray": {
+ "geometry": "Direct target-size raster derivatives of the edge-fitted circular material Logo with its red core.",
+ "stateBadges": {
+ "idle": null,
+ "running": "#168A5B",
+ "waiting": "#C77B12",
+ "error": "#8B3AA8"
+ },
+ "sizes": [
+ 16,
+ 20,
+ 24,
+ 32,
+ 48
+ ],
+ "contentLimit": "Visible circular Logo fills all four sides of the target canvas without added transparent padding.",
+ "compression": "Lossless PNG, level 9, adaptive filtering."
+ },
+ "sources": {
+ "source/sparo-mark-master.png": {
+ "bytes": 983141,
+ "sha256": "10c9328ae0f8543b1713ffb68d752a4d4e8d26a76dae283c597826c92cc5e14d"
+ },
+ "source/sparo-core-master.png": {
+ "bytes": 904102,
+ "sha256": "9bdbc6ebd4d750fb534a7aa166bafaf2313232567acec12c7a0a1c9444c5b3ce"
+ },
+ "reference/sparo-identity-board.png": {
+ "bytes": 1506523,
+ "sha256": "0b2d0032de23174be0381976f8edc90094e7fa380a37dfb7147f873e9e388e4f"
+ }
+ },
+ "files": [
+ {
+ "path": "exports/app-icon/sparo-app-icon-1024.png",
+ "bytes": 1021655,
+ "sha256": "c65833124c839750b6b6b82bb89ef8748caa5f21264ffd77213a781cb641534c"
+ },
+ {
+ "path": "exports/app-icon/sparo-app-icon-128.png",
+ "bytes": 22827,
+ "sha256": "0da0e354ae77f215b79f0ea298d4d6046dac332cefb6fca47514e5c9dace7d91"
+ },
+ {
+ "path": "exports/app-icon/sparo-app-icon-16.png",
+ "bytes": 813,
+ "sha256": "81321112286d69c31a13b99a10ba3e3248cc305774cf6f4e4858263851bef83f"
+ },
+ {
+ "path": "exports/app-icon/sparo-app-icon-24.png",
+ "bytes": 1517,
+ "sha256": "2b9475092c8c0de07d30f49ee78c1e93a9bd6e0aeff740911d1ec0d982696804"
+ },
+ {
+ "path": "exports/app-icon/sparo-app-icon-256.png",
+ "bytes": 75322,
+ "sha256": "70a88b176dd76df6336b65d0f67aabe146e4ca9c977c320c90e9e16b6ccc0f69"
+ },
+ {
+ "path": "exports/app-icon/sparo-app-icon-32.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "exports/app-icon/sparo-app-icon-48.png",
+ "bytes": 4554,
+ "sha256": "b57e8dc54b97d931844d6d4b358f9d2963c427fac9b36a5c8a875e335d90426d"
+ },
+ {
+ "path": "exports/app-icon/sparo-app-icon-512.png",
+ "bytes": 286830,
+ "sha256": "f453249bbc010d885cac92f94c9f236cd8cf63b1057d90a175afb142bd11500d"
+ },
+ {
+ "path": "exports/app-icon/sparo-app-icon-64.png",
+ "bytes": 7228,
+ "sha256": "d2c4c5ca72928ee29f3b6ede38b87af9d519581b0065b7d44e9249c6448848d1"
+ },
+ {
+ "path": "exports/core/sparo-core-16.png",
+ "bytes": 583,
+ "sha256": "d8c56ce81f3e842aa9dded49b862b052d82ce3fb3f40d9364c0dae4aae4de9ac"
+ },
+ {
+ "path": "exports/core/sparo-core-20.png",
+ "bytes": 817,
+ "sha256": "0a8dcd51fd7be98662cb0a61557ded28dda83a3b5169909978a1ec1f021df3c7"
+ },
+ {
+ "path": "exports/core/sparo-core-24.png",
+ "bytes": 1010,
+ "sha256": "ed51d728c8b6dfad5353b57bbea5ef1e04f6a97d7f8f3417ded98c323f375236"
+ },
+ {
+ "path": "exports/core/sparo-core-32.png",
+ "bytes": 1490,
+ "sha256": "d5b8e8716df53caac81df865cfbb9262dd525b52923090e233cf1470ec6ee3bc"
+ },
+ {
+ "path": "exports/core/sparo-core-48.png",
+ "bytes": 2721,
+ "sha256": "cc42a80faeb9e22ca8fea8971bc350caac29ea0c673a420a3c176e4f8c8f5367"
+ },
+ {
+ "path": "exports/lockup/sparo-lockup-horizontal-mono.png",
+ "bytes": 52446,
+ "sha256": "5be09ea9fb2b54d350efa40b0d910ce0038d45a38975ae6ba6be81608dd275de"
+ },
+ {
+ "path": "exports/lockup/sparo-lockup-horizontal-primary.png",
+ "bytes": 113890,
+ "sha256": "d2a230460323355ad34bb1ac2b92f32319819279a1a8ac066e981c96751878ce"
+ },
+ {
+ "path": "exports/lockup/sparo-lockup-horizontal-reversed.png",
+ "bytes": 114771,
+ "sha256": "3e32ebde378d5111256dc30b6041d8ec3521590cb769d33f8785454ef2855ed7"
+ },
+ {
+ "path": "exports/mark/sparo-mark-128.png",
+ "bytes": 21235,
+ "sha256": "22aeeda3f6881a4be6292a1de7758ca9fc58dbc7b7da61ff707b404c7e28cbb7"
+ },
+ {
+ "path": "exports/mark/sparo-mark-16.png",
+ "bytes": 793,
+ "sha256": "17a69d0395848de0a3c5506ea1b7df986949b0596d8652fb607c0a49582ef074"
+ },
+ {
+ "path": "exports/mark/sparo-mark-24.png",
+ "bytes": 1429,
+ "sha256": "9be58d8aabb5a18baac37ea92b66f61bd0e530eb345e646068b94aec16b72dbc"
+ },
+ {
+ "path": "exports/mark/sparo-mark-256.png",
+ "bytes": 66587,
+ "sha256": "f1869e6ae634eaf53dc49e44d96b6fd838c8648892687b25e490fff33a371835"
+ },
+ {
+ "path": "exports/mark/sparo-mark-32.png",
+ "bytes": 2220,
+ "sha256": "03d12b7f4bd2fe97296c1a28f33d20648ef4a41e1f51eee65c8ef0c0cea4f236"
+ },
+ {
+ "path": "exports/mark/sparo-mark-48.png",
+ "bytes": 4254,
+ "sha256": "6bc33619b7b8fc5f359496177d1fe32c29e39f145fd2ef297474350ea16ec81b"
+ },
+ {
+ "path": "exports/mark/sparo-mark-512.png",
+ "bytes": 237905,
+ "sha256": "290b3b68a69e4e61f239d88a965f95b1ba55bc52d9704b1b430d178b24bfccdd"
+ },
+ {
+ "path": "exports/mark/sparo-mark-64.png",
+ "bytes": 6634,
+ "sha256": "bf938438a21f593cfa68471ac79a729586ef8816a0fabe736fc847d8c830377c"
+ },
+ {
+ "path": "exports/tray/sparo-tray-16-dark.png",
+ "bytes": 813,
+ "sha256": "81321112286d69c31a13b99a10ba3e3248cc305774cf6f4e4858263851bef83f"
+ },
+ {
+ "path": "exports/tray/sparo-tray-16-light.png",
+ "bytes": 813,
+ "sha256": "81321112286d69c31a13b99a10ba3e3248cc305774cf6f4e4858263851bef83f"
+ },
+ {
+ "path": "exports/tray/sparo-tray-20-dark.png",
+ "bytes": 1157,
+ "sha256": "eb6b0eca83a5d63585db9a51add1e5f3e3d708f98bcf6f02e3a78d858fe21191"
+ },
+ {
+ "path": "exports/tray/sparo-tray-20-light.png",
+ "bytes": 1157,
+ "sha256": "eb6b0eca83a5d63585db9a51add1e5f3e3d708f98bcf6f02e3a78d858fe21191"
+ },
+ {
+ "path": "exports/tray/sparo-tray-24-dark.png",
+ "bytes": 1517,
+ "sha256": "2b9475092c8c0de07d30f49ee78c1e93a9bd6e0aeff740911d1ec0d982696804"
+ },
+ {
+ "path": "exports/tray/sparo-tray-24-light.png",
+ "bytes": 1517,
+ "sha256": "2b9475092c8c0de07d30f49ee78c1e93a9bd6e0aeff740911d1ec0d982696804"
+ },
+ {
+ "path": "exports/tray/sparo-tray-32-dark.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "exports/tray/sparo-tray-32-light.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "exports/tray/sparo-tray-48-dark.png",
+ "bytes": 4554,
+ "sha256": "b57e8dc54b97d931844d6d4b358f9d2963c427fac9b36a5c8a875e335d90426d"
+ },
+ {
+ "path": "exports/tray/sparo-tray-48-light.png",
+ "bytes": 4554,
+ "sha256": "b57e8dc54b97d931844d6d4b358f9d2963c427fac9b36a5c8a875e335d90426d"
+ },
+ {
+ "path": "exports/tray/sparo-tray-error.png",
+ "bytes": 2359,
+ "sha256": "f8262c27dbd553f84a4648aaf037f208598926d349993a1e9670d517f1dcbc26"
+ },
+ {
+ "path": "exports/tray/sparo-tray-idle-16.png",
+ "bytes": 813,
+ "sha256": "81321112286d69c31a13b99a10ba3e3248cc305774cf6f4e4858263851bef83f"
+ },
+ {
+ "path": "exports/tray/sparo-tray-idle-20.png",
+ "bytes": 1157,
+ "sha256": "eb6b0eca83a5d63585db9a51add1e5f3e3d708f98bcf6f02e3a78d858fe21191"
+ },
+ {
+ "path": "exports/tray/sparo-tray-idle-24.png",
+ "bytes": 1517,
+ "sha256": "2b9475092c8c0de07d30f49ee78c1e93a9bd6e0aeff740911d1ec0d982696804"
+ },
+ {
+ "path": "exports/tray/sparo-tray-idle-32.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "exports/tray/sparo-tray-idle-48.png",
+ "bytes": 4554,
+ "sha256": "b57e8dc54b97d931844d6d4b358f9d2963c427fac9b36a5c8a875e335d90426d"
+ },
+ {
+ "path": "exports/tray/sparo-tray-idle.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "exports/tray/sparo-tray-running.png",
+ "bytes": 2360,
+ "sha256": "8d6c230705373932a75184280d07152dedca28c215c0810e3f710a93f2b899b5"
+ },
+ {
+ "path": "exports/tray/sparo-tray-waiting.png",
+ "bytes": 2357,
+ "sha256": "793bf22cf7d1dde92affdbfba7a9deeea6278564c450cc5d63edd38da5e9d2ad"
+ },
+ {
+ "path": "exports/web/apple-touch-icon-180.png",
+ "bytes": 39902,
+ "sha256": "9d5507571b8b6ffb547842f7e75d19aa36abe5e278870c596cd7430359ccfa46"
+ },
+ {
+ "path": "exports/web/favicon-16.png",
+ "bytes": 813,
+ "sha256": "81321112286d69c31a13b99a10ba3e3248cc305774cf6f4e4858263851bef83f"
+ },
+ {
+ "path": "exports/web/favicon-32.png",
+ "bytes": 2395,
+ "sha256": "f1f2566dfeba2e8593676da2f79587696ac70838dc9391dce676348768bcc808"
+ },
+ {
+ "path": "exports/web/favicon-48.png",
+ "bytes": 4554,
+ "sha256": "b57e8dc54b97d931844d6d4b358f9d2963c427fac9b36a5c8a875e335d90426d"
+ },
+ {
+ "path": "exports/web/web-app-icon-192.png",
+ "bytes": 45123,
+ "sha256": "3f81f7bf0ed8ef06962be12e4ec22d9ebfb1ce1ff2e98d312b77e97c9d0984a7"
+ },
+ {
+ "path": "exports/web/web-app-icon-512.png",
+ "bytes": 286843,
+ "sha256": "ee957c7ef29958df5a47290c50e4cc71161d7dcd228c04cf4beb221a271edca2"
+ },
+ {
+ "path": "exports/wordmark/sparo-wordmark-mono.png",
+ "bytes": 34145,
+ "sha256": "9b42f1aac05dfeb3161e202235ec3cbf443a190fe528975f464d63550eae63b2"
+ },
+ {
+ "path": "exports/wordmark/sparo-wordmark-primary.png",
+ "bytes": 34510,
+ "sha256": "ac61b6608967a896889ef42eed5fcb838c258fbce0bee984a7746d149db5c4c3"
+ },
+ {
+ "path": "exports/wordmark/sparo-wordmark-reversed.png",
+ "bytes": 34511,
+ "sha256": "772b0f73821ba015ae6b3f37cfbbdb897fd4db07b504d5fdf70062cf5c207348"
+ }
+ ]
+}
diff --git a/assets/brand/qa/sparo-app-icon-size-matrix.png b/assets/brand/qa/sparo-app-icon-size-matrix.png
new file mode 100644
index 00000000..6309fdc9
Binary files /dev/null and b/assets/brand/qa/sparo-app-icon-size-matrix.png differ
diff --git a/assets/brand/qa/sparo-brand-asset-matrix.png b/assets/brand/qa/sparo-brand-asset-matrix.png
new file mode 100644
index 00000000..b755c18f
Binary files /dev/null and b/assets/brand/qa/sparo-brand-asset-matrix.png differ
diff --git a/assets/brand/qa/sparo-small-mark-matrix.png b/assets/brand/qa/sparo-small-mark-matrix.png
new file mode 100644
index 00000000..f641fb35
Binary files /dev/null and b/assets/brand/qa/sparo-small-mark-matrix.png differ
diff --git a/assets/brand/qa/sparo-startup-brand-preview.png b/assets/brand/qa/sparo-startup-brand-preview.png
new file mode 100644
index 00000000..d24b30da
Binary files /dev/null and b/assets/brand/qa/sparo-startup-brand-preview.png differ
diff --git a/assets/brand/qa/sparo-tray-state-matrix.png b/assets/brand/qa/sparo-tray-state-matrix.png
new file mode 100644
index 00000000..900472ab
Binary files /dev/null and b/assets/brand/qa/sparo-tray-state-matrix.png differ
diff --git a/assets/brand/reference/sparo-identity-board.png b/assets/brand/reference/sparo-identity-board.png
new file mode 100644
index 00000000..578165a3
Binary files /dev/null and b/assets/brand/reference/sparo-identity-board.png differ
diff --git a/assets/brand/source/sparo-core-master.png b/assets/brand/source/sparo-core-master.png
new file mode 100644
index 00000000..cfb0bcc5
Binary files /dev/null and b/assets/brand/source/sparo-core-master.png differ
diff --git a/assets/brand/source/sparo-mark-master.png b/assets/brand/source/sparo-mark-master.png
new file mode 100644
index 00000000..acb39986
Binary files /dev/null and b/assets/brand/source/sparo-mark-master.png differ
diff --git a/docs/sparo-vi-design.md b/docs/sparo-vi-design.md
index 345be28c..618e927f 100644
--- a/docs/sparo-vi-design.md
+++ b/docs/sparo-vi-design.md
@@ -1,5 +1,7 @@
# Sparo VI Design System
+> **Historical reference:** the logo geometry, color, application-icon, wordmark, and export guidance in this document has been superseded by [`assets/brand/README.md`](../assets/brand/README.md). The current default logo is the circular warm-field mark with a red core; application launch surfaces use the rounded-rectangle icon. Product copies are managed only through `pnpm run brand:sync`.
+
> Source image: `png/VI.png`
> This document extracts the visible design information from the VI board. A few very small labels are summarized where exact text is not fully legible.
@@ -59,7 +61,7 @@ The Sparo logo is built from four symbolic elements:
| Symbol | Standalone mark for compact brand recognition |
| Horizontal | Symbol plus `Sparo` wordmark |
| Stacked | Symbol above `Sparo`, for centered layouts |
-| App Icon | Symbol placed on dark rounded-square background |
+| App Icon | Soft inner form and red core on a warm rounded-rectangle field |
### Wordmark
@@ -70,8 +72,8 @@ The Sparo logo is built from four symbolic elements:
### App Icon
-- Background: Sparo Ink
-- Foreground: white logo stroke plus Sparo Print Red / Echo Red accent
+- Background: Warm White rounded rectangle
+- Foreground: Soft Ivory inner form and Core Red center
- Corner radius: moderate rounded square
- Use for desktop/app launch surfaces, dock/taskbar icon, and compact product identity.
@@ -446,4 +448,4 @@ When porting these patterns into the desktop Web UI (`src/web-ui`), the followin
| Built-in Apps strip | Apps Scene category strips, integration listings |
-Implementations of the above already exist in the website repo and should be treated as the source of truth for both the marketing surface and the product UI.
\ No newline at end of file
+Implementations of the above already exist in the website repo and should be treated as the source of truth for both the marketing surface and the product UI.
diff --git a/image/Sparo_title.png b/image/Sparo_title.png
deleted file mode 100644
index 4535936d..00000000
Binary files a/image/Sparo_title.png and /dev/null differ
diff --git a/image/readme_hero.png b/image/readme_hero.png
deleted file mode 100644
index 24b53425..00000000
Binary files a/image/readme_hero.png and /dev/null differ
diff --git a/image/readme_hero.webp b/image/readme_hero.webp
new file mode 100644
index 00000000..195cb95f
Binary files /dev/null and b/image/readme_hero.webp differ
diff --git a/image/readme_hero_CN.png b/image/readme_hero_CN.png
deleted file mode 100644
index 5a3fd99a..00000000
Binary files a/image/readme_hero_CN.png and /dev/null differ
diff --git a/image/readme_hero_CN.webp b/image/readme_hero_CN.webp
new file mode 100644
index 00000000..d71b954c
Binary files /dev/null and b/image/readme_hero_CN.webp differ
diff --git a/image/sparo-app-icon-rounded.png b/image/sparo-app-icon-rounded.png
deleted file mode 100644
index 491cfba4..00000000
Binary files a/image/sparo-app-icon-rounded.png and /dev/null differ
diff --git a/image/sparo-logo-mark.png b/image/sparo-logo-mark.png
deleted file mode 100644
index 8c783315..00000000
Binary files a/image/sparo-logo-mark.png and /dev/null differ
diff --git a/image/sparo-readme-wordmark.png b/image/sparo-readme-wordmark.png
new file mode 100644
index 00000000..d4b4ad77
Binary files /dev/null and b/image/sparo-readme-wordmark.png differ
diff --git a/image/sparo-tray-icons-preview.png b/image/sparo-tray-icons-preview.png
deleted file mode 100644
index 6a796188..00000000
Binary files a/image/sparo-tray-icons-preview.png and /dev/null differ
diff --git a/installer/src-tauri/icons/128x128.png b/installer/src-tauri/icons/128x128.png
index fb0343a7..1c7b4e23 100644
Binary files a/installer/src-tauri/icons/128x128.png and b/installer/src-tauri/icons/128x128.png differ
diff --git a/installer/src-tauri/icons/128x128@2x.png b/installer/src-tauri/icons/128x128@2x.png
index b1394ad1..74f18439 100644
Binary files a/installer/src-tauri/icons/128x128@2x.png and b/installer/src-tauri/icons/128x128@2x.png differ
diff --git a/installer/src-tauri/icons/32x32.png b/installer/src-tauri/icons/32x32.png
index 1665dd04..2f5e44f9 100644
Binary files a/installer/src-tauri/icons/32x32.png and b/installer/src-tauri/icons/32x32.png differ
diff --git a/installer/src-tauri/icons/64x64.png b/installer/src-tauri/icons/64x64.png
index 95b475af..5b7a72cc 100644
Binary files a/installer/src-tauri/icons/64x64.png and b/installer/src-tauri/icons/64x64.png differ
diff --git a/installer/src-tauri/icons/Square107x107Logo.png b/installer/src-tauri/icons/Square107x107Logo.png
index ad37c787..d5b248a1 100644
Binary files a/installer/src-tauri/icons/Square107x107Logo.png and b/installer/src-tauri/icons/Square107x107Logo.png differ
diff --git a/installer/src-tauri/icons/Square142x142Logo.png b/installer/src-tauri/icons/Square142x142Logo.png
index 5f5e5cb0..e44ff7af 100644
Binary files a/installer/src-tauri/icons/Square142x142Logo.png and b/installer/src-tauri/icons/Square142x142Logo.png differ
diff --git a/installer/src-tauri/icons/Square150x150Logo.png b/installer/src-tauri/icons/Square150x150Logo.png
index ec2d29db..e607c495 100644
Binary files a/installer/src-tauri/icons/Square150x150Logo.png and b/installer/src-tauri/icons/Square150x150Logo.png differ
diff --git a/installer/src-tauri/icons/Square284x284Logo.png b/installer/src-tauri/icons/Square284x284Logo.png
index ecfd6298..d98e7c79 100644
Binary files a/installer/src-tauri/icons/Square284x284Logo.png and b/installer/src-tauri/icons/Square284x284Logo.png differ
diff --git a/installer/src-tauri/icons/Square30x30Logo.png b/installer/src-tauri/icons/Square30x30Logo.png
index 226af42f..03a76719 100644
Binary files a/installer/src-tauri/icons/Square30x30Logo.png and b/installer/src-tauri/icons/Square30x30Logo.png differ
diff --git a/installer/src-tauri/icons/Square310x310Logo.png b/installer/src-tauri/icons/Square310x310Logo.png
index 199ac81d..f4cff6a5 100644
Binary files a/installer/src-tauri/icons/Square310x310Logo.png and b/installer/src-tauri/icons/Square310x310Logo.png differ
diff --git a/installer/src-tauri/icons/Square44x44Logo.png b/installer/src-tauri/icons/Square44x44Logo.png
index 50bb0055..b669621c 100644
Binary files a/installer/src-tauri/icons/Square44x44Logo.png and b/installer/src-tauri/icons/Square44x44Logo.png differ
diff --git a/installer/src-tauri/icons/Square71x71Logo.png b/installer/src-tauri/icons/Square71x71Logo.png
index 9b5e393a..8c2261fe 100644
Binary files a/installer/src-tauri/icons/Square71x71Logo.png and b/installer/src-tauri/icons/Square71x71Logo.png differ
diff --git a/installer/src-tauri/icons/Square89x89Logo.png b/installer/src-tauri/icons/Square89x89Logo.png
index 0bd1c700..daec8d29 100644
Binary files a/installer/src-tauri/icons/Square89x89Logo.png and b/installer/src-tauri/icons/Square89x89Logo.png differ
diff --git a/installer/src-tauri/icons/StoreLogo.png b/installer/src-tauri/icons/StoreLogo.png
index 799563ac..407dc94f 100644
Binary files a/installer/src-tauri/icons/StoreLogo.png and b/installer/src-tauri/icons/StoreLogo.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher.png b/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher.png
index 22f27bb8..c7dd6f14 100644
Binary files a/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher.png and b/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_foreground.png b/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_foreground.png
index 22f27bb8..a177ef41 100644
Binary files a/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_foreground.png and b/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_foreground.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_round.png b/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_round.png
index 22f27bb8..c7dd6f14 100644
Binary files a/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_round.png and b/installer/src-tauri/icons/android/mipmap-hdpi/ic_launcher_round.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher.png b/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher.png
index 78b0bbd9..d6ef9ea9 100644
Binary files a/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher.png and b/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_foreground.png b/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_foreground.png
index 78b0bbd9..2a1429ff 100644
Binary files a/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_foreground.png and b/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_foreground.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_round.png b/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_round.png
index 78b0bbd9..d6ef9ea9 100644
Binary files a/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_round.png and b/installer/src-tauri/icons/android/mipmap-mdpi/ic_launcher_round.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher.png b/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher.png
index 90c76da3..e66ae720 100644
Binary files a/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher.png and b/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_foreground.png b/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_foreground.png
index 90c76da3..58f6a024 100644
Binary files a/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_foreground.png and b/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_foreground.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_round.png b/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_round.png
index 90c76da3..e66ae720 100644
Binary files a/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_round.png and b/installer/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_round.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher.png b/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher.png
index 6fb315dd..a8ff2ace 100644
Binary files a/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher.png and b/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png b/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png
index 6fb315dd..73ab55a0 100644
Binary files a/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png and b/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_round.png b/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_round.png
index 6fb315dd..a8ff2ace 100644
Binary files a/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_round.png and b/installer/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_round.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher.png b/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher.png
index d6dd6a98..63a0eaa7 100644
Binary files a/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher.png and b/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png b/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png
index d6dd6a98..8d688951 100644
Binary files a/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png and b/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png differ
diff --git a/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_round.png b/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_round.png
index d6dd6a98..63a0eaa7 100644
Binary files a/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_round.png and b/installer/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_round.png differ
diff --git a/installer/src-tauri/icons/android/values/ic_launcher_background.xml b/installer/src-tauri/icons/android/values/ic_launcher_background.xml
index ea9c223a..7938c64e 100644
--- a/installer/src-tauri/icons/android/values/ic_launcher_background.xml
+++ b/installer/src-tauri/icons/android/values/ic_launcher_background.xml
@@ -1,4 +1,4 @@
- #fff
+ #F5F2EE
\ No newline at end of file
diff --git a/installer/src-tauri/icons/app-icon-rounded-source.png b/installer/src-tauri/icons/app-icon-rounded-source.png
deleted file mode 100644
index d5e59ffc..00000000
Binary files a/installer/src-tauri/icons/app-icon-rounded-source.png and /dev/null differ
diff --git a/installer/src-tauri/icons/icon.icns b/installer/src-tauri/icons/icon.icns
index b7ba91f1..9f213f9b 100644
Binary files a/installer/src-tauri/icons/icon.icns and b/installer/src-tauri/icons/icon.icns differ
diff --git a/installer/src-tauri/icons/icon.ico b/installer/src-tauri/icons/icon.ico
index feb7c28c..0506188b 100644
Binary files a/installer/src-tauri/icons/icon.ico and b/installer/src-tauri/icons/icon.ico differ
diff --git a/installer/src-tauri/icons/icon.png b/installer/src-tauri/icons/icon.png
index 9e8086ab..2fe045bc 100644
Binary files a/installer/src-tauri/icons/icon.png and b/installer/src-tauri/icons/icon.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-20x20@1x.png b/installer/src-tauri/icons/ios/AppIcon-20x20@1x.png
index 63cb8266..624494b0 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-20x20@1x.png and b/installer/src-tauri/icons/ios/AppIcon-20x20@1x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-20x20@2x-1.png b/installer/src-tauri/icons/ios/AppIcon-20x20@2x-1.png
index d1763dde..0cfd832a 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-20x20@2x-1.png and b/installer/src-tauri/icons/ios/AppIcon-20x20@2x-1.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-20x20@2x.png b/installer/src-tauri/icons/ios/AppIcon-20x20@2x.png
index d1763dde..0cfd832a 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-20x20@2x.png and b/installer/src-tauri/icons/ios/AppIcon-20x20@2x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-20x20@3x.png b/installer/src-tauri/icons/ios/AppIcon-20x20@3x.png
index 8e2019b1..77532256 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-20x20@3x.png and b/installer/src-tauri/icons/ios/AppIcon-20x20@3x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-29x29@1x.png b/installer/src-tauri/icons/ios/AppIcon-29x29@1x.png
index 7ba86c84..46d013c3 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-29x29@1x.png and b/installer/src-tauri/icons/ios/AppIcon-29x29@1x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-29x29@2x-1.png b/installer/src-tauri/icons/ios/AppIcon-29x29@2x-1.png
index f9d95fae..ad6d68a6 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-29x29@2x-1.png and b/installer/src-tauri/icons/ios/AppIcon-29x29@2x-1.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-29x29@2x.png b/installer/src-tauri/icons/ios/AppIcon-29x29@2x.png
index f9d95fae..ad6d68a6 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-29x29@2x.png and b/installer/src-tauri/icons/ios/AppIcon-29x29@2x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-29x29@3x.png b/installer/src-tauri/icons/ios/AppIcon-29x29@3x.png
index 4238e73b..77908fd0 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-29x29@3x.png and b/installer/src-tauri/icons/ios/AppIcon-29x29@3x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-40x40@1x.png b/installer/src-tauri/icons/ios/AppIcon-40x40@1x.png
index d1763dde..0cfd832a 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-40x40@1x.png and b/installer/src-tauri/icons/ios/AppIcon-40x40@1x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-40x40@2x-1.png b/installer/src-tauri/icons/ios/AppIcon-40x40@2x-1.png
index bb9a016b..d1c893ff 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-40x40@2x-1.png and b/installer/src-tauri/icons/ios/AppIcon-40x40@2x-1.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-40x40@2x.png b/installer/src-tauri/icons/ios/AppIcon-40x40@2x.png
index bb9a016b..d1c893ff 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-40x40@2x.png and b/installer/src-tauri/icons/ios/AppIcon-40x40@2x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-40x40@3x.png b/installer/src-tauri/icons/ios/AppIcon-40x40@3x.png
index 9db4f379..694cee05 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-40x40@3x.png and b/installer/src-tauri/icons/ios/AppIcon-40x40@3x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-512@2x.png b/installer/src-tauri/icons/ios/AppIcon-512@2x.png
index deaabc02..91169e65 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-512@2x.png and b/installer/src-tauri/icons/ios/AppIcon-512@2x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-60x60@2x.png b/installer/src-tauri/icons/ios/AppIcon-60x60@2x.png
index 9db4f379..694cee05 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-60x60@2x.png and b/installer/src-tauri/icons/ios/AppIcon-60x60@2x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-60x60@3x.png b/installer/src-tauri/icons/ios/AppIcon-60x60@3x.png
index 5b8b8c70..303b4768 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-60x60@3x.png and b/installer/src-tauri/icons/ios/AppIcon-60x60@3x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-76x76@1x.png b/installer/src-tauri/icons/ios/AppIcon-76x76@1x.png
index 0d8099eb..caed8331 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-76x76@1x.png and b/installer/src-tauri/icons/ios/AppIcon-76x76@1x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-76x76@2x.png b/installer/src-tauri/icons/ios/AppIcon-76x76@2x.png
index e06acefb..3b241b54 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-76x76@2x.png and b/installer/src-tauri/icons/ios/AppIcon-76x76@2x.png differ
diff --git a/installer/src-tauri/icons/ios/AppIcon-83.5x83.5@2x.png b/installer/src-tauri/icons/ios/AppIcon-83.5x83.5@2x.png
index ae45e080..7bb7efe5 100644
Binary files a/installer/src-tauri/icons/ios/AppIcon-83.5x83.5@2x.png and b/installer/src-tauri/icons/ios/AppIcon-83.5x83.5@2x.png differ
diff --git a/installer/src/assets/brand/sparo-mark-16.png b/installer/src/assets/brand/sparo-mark-16.png
new file mode 100644
index 00000000..436e8c9f
Binary files /dev/null and b/installer/src/assets/brand/sparo-mark-16.png differ
diff --git a/installer/src/assets/brand/sparo-mark-24.png b/installer/src/assets/brand/sparo-mark-24.png
new file mode 100644
index 00000000..b3e6726f
Binary files /dev/null and b/installer/src/assets/brand/sparo-mark-24.png differ
diff --git a/installer/src/assets/brand/sparo-mark-32.png b/installer/src/assets/brand/sparo-mark-32.png
new file mode 100644
index 00000000..4078a327
Binary files /dev/null and b/installer/src/assets/brand/sparo-mark-32.png differ
diff --git a/installer/src/assets/brand/sparo-mark-48.png b/installer/src/assets/brand/sparo-mark-48.png
new file mode 100644
index 00000000..5ae20c02
Binary files /dev/null and b/installer/src/assets/brand/sparo-mark-48.png differ
diff --git a/installer/src/assets/brand/sparo-mark-full.png b/installer/src/assets/brand/sparo-mark-full.png
new file mode 100644
index 00000000..275ec993
Binary files /dev/null and b/installer/src/assets/brand/sparo-mark-full.png differ
diff --git a/installer/src/assets/sparo-logo-mark.png b/installer/src/assets/sparo-logo-mark.png
deleted file mode 100644
index 8c783315..00000000
Binary files a/installer/src/assets/sparo-logo-mark.png and /dev/null differ
diff --git a/installer/src/components/brand/SparoMark.tsx b/installer/src/components/brand/SparoMark.tsx
index 0bdb7112..2c5c8b75 100644
--- a/installer/src/components/brand/SparoMark.tsx
+++ b/installer/src/components/brand/SparoMark.tsx
@@ -1,22 +1,31 @@
-import logoMark from '../../assets/sparo-logo-mark.png';
+import mark16 from '../../assets/brand/sparo-mark-16.png';
+import mark24 from '../../assets/brand/sparo-mark-24.png';
+import mark32 from '../../assets/brand/sparo-mark-32.png';
+import mark48 from '../../assets/brand/sparo-mark-48.png';
+import markFull from '../../assets/brand/sparo-mark-full.png';
interface SparoMarkProps {
size?: number;
}
-/**
- * Sparo brand mark using the theme-neutral logo asset.
- */
+function sourceForSize(size: number) {
+ if (size <= 20) return mark16;
+ if (size <= 28) return mark24;
+ if (size <= 40) return mark32;
+ if (size < 64) return mark48;
+ return markFull;
+}
+
+/** Uses the declared responsive brand source for the requested display size. */
export function SparoMark({ size = 56 }: SparoMarkProps) {
return (
-
-

-
+
);
}
diff --git a/package.json b/package.json
index a0d2b820..5ec1da19 100644
--- a/package.json
+++ b/package.json
@@ -8,10 +8,13 @@
},
"scripts": {
"copy-monaco": "copyfiles -u 5 \"src/web-ui/node_modules/monaco-editor/min/vs/**/*\" src/web-ui/public/monaco-editor",
- "copy-icons": "copyfiles -f \"src/apps/desktop/icons/sparo-app-icon.png\" \"src/web-ui/public/\"",
+ "copy-icons": "node scripts/sync-brand-assets.mjs --target web",
"copy-assets": "pnpm run copy-monaco && pnpm run copy-icons",
"generate-version": "node scripts/generate-version.cjs",
"generate-all": "pnpm run generate-version",
+ "brand:generate": "node scripts/generate-brand-assets.mjs",
+ "brand:sync": "node scripts/sync-brand-assets.mjs",
+ "brand:check": "node scripts/check-brand-assets.mjs",
"postinstall": "pnpm run copy-assets",
"dev": "node scripts/dev.cjs web",
"dev:web": "pnpm --dir src/web-ui dev",
@@ -31,7 +34,7 @@
"build:web:unchecked": "pnpm --dir src/web-ui build && pnpm run verify:monaco-assets",
"build:web": "pnpm run check:web && pnpm run build:web:unchecked",
"build:mobile-web": "pnpm --dir src/mobile-web build",
- "sync:mobile-web-brand": "node scripts/generate-mobile-web-icons.mjs",
+ "sync:mobile-web-brand": "node scripts/sync-brand-assets.mjs --target mobile",
"prepare:mobile-web": "node scripts/mobile-web-build.cjs",
"preview": "pnpm --dir src/web-ui preview",
"bundle:ppt-live-export": "node scripts/bundle-ppt-live-export.mjs",
diff --git a/scripts/brand-assets.config.mjs b/scripts/brand-assets.config.mjs
new file mode 100644
index 00000000..fa31e397
--- /dev/null
+++ b/scripts/brand-assets.config.mjs
@@ -0,0 +1,125 @@
+export const brandAssetCopies = Object.freeze([
+ // Web UI public assets: stable PNG URLs for boot HTML and exported images.
+ { group: 'web', source: 'exports/app-icon/sparo-app-icon-512.png', target: 'src/web-ui/public/brand/app-icon-512.png' },
+ { group: 'web', source: 'exports/web/favicon-32.png', target: 'src/web-ui/public/brand/favicon-32.png' },
+ { group: 'web', source: 'exports/mark/sparo-mark-256.png', target: 'src/web-ui/public/brand/sparo-mark-256.png' },
+ { group: 'web', source: 'exports/mark/sparo-mark-512.png', target: 'src/web-ui/public/brand/sparo-mark-full.png' },
+ { group: 'web', source: 'exports/wordmark/sparo-wordmark-primary.png', target: 'src/web-ui/public/brand/sparo-wordmark-primary.png' },
+ { group: 'web', source: 'exports/wordmark/sparo-wordmark-reversed.png', target: 'src/web-ui/public/brand/sparo-wordmark-reversed.png' },
+
+ // Design-system-owned copies keep the reusable logo component self-contained.
+ { group: 'web', source: 'exports/mark/sparo-mark-16.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-mark-16.png' },
+ { group: 'web', source: 'exports/mark/sparo-mark-24.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-mark-24.png' },
+ { group: 'web', source: 'exports/mark/sparo-mark-32.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-mark-32.png' },
+ { group: 'web', source: 'exports/mark/sparo-mark-48.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-mark-48.png' },
+ { group: 'web', source: 'exports/mark/sparo-mark-256.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-mark-256.png' },
+ { group: 'web', source: 'exports/mark/sparo-mark-512.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-mark-full.png' },
+ { group: 'web', source: 'exports/app-icon/sparo-app-icon-32.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-app-icon-32.png' },
+
+ // Compact app chrome keeps its dedicated source-derived red core.
+ { group: 'web', source: 'exports/core/sparo-core-16.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-core-16.png' },
+ { group: 'web', source: 'exports/core/sparo-core-20.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-core-20.png' },
+ { group: 'web', source: 'exports/core/sparo-core-24.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-core-24.png' },
+ { group: 'web', source: 'exports/core/sparo-core-32.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-core-32.png' },
+ { group: 'web', source: 'exports/core/sparo-core-48.png', target: 'src/web-ui/src/design-system/foundation/brand/sparo-core-48.png' },
+
+ // Mobile Web uses stable public URLs so a later logo swap does not change JS hashes.
+ { group: 'mobile', source: 'exports/web/favicon-32.png', target: 'src/mobile-web/public/brand/favicon-32.png' },
+ { group: 'mobile', source: 'exports/web/apple-touch-icon-180.png', target: 'src/mobile-web/public/brand/app-icon-180.png' },
+ { group: 'mobile', source: 'exports/mark/sparo-mark-16.png', target: 'src/mobile-web/public/brand/sparo-mark-16.png' },
+ { group: 'mobile', source: 'exports/mark/sparo-mark-24.png', target: 'src/mobile-web/public/brand/sparo-mark-24.png' },
+ { group: 'mobile', source: 'exports/mark/sparo-mark-32.png', target: 'src/mobile-web/public/brand/sparo-mark-32.png' },
+ { group: 'mobile', source: 'exports/mark/sparo-mark-48.png', target: 'src/mobile-web/public/brand/sparo-mark-48.png' },
+ { group: 'mobile', source: 'exports/mark/sparo-mark-512.png', target: 'src/mobile-web/public/brand/sparo-mark-full.png' },
+
+ // The relay fallback mirrors the same stable mobile assets without rebuilding JS.
+ { group: 'relay', source: 'exports/web/favicon-32.png', target: 'src/apps/relay-server/static/brand/favicon-32.png' },
+ { group: 'relay', source: 'exports/web/apple-touch-icon-180.png', target: 'src/apps/relay-server/static/brand/app-icon-180.png' },
+ { group: 'relay', source: 'exports/mark/sparo-mark-16.png', target: 'src/apps/relay-server/static/brand/sparo-mark-16.png' },
+ { group: 'relay', source: 'exports/mark/sparo-mark-24.png', target: 'src/apps/relay-server/static/brand/sparo-mark-24.png' },
+ { group: 'relay', source: 'exports/mark/sparo-mark-32.png', target: 'src/apps/relay-server/static/brand/sparo-mark-32.png' },
+ { group: 'relay', source: 'exports/mark/sparo-mark-48.png', target: 'src/apps/relay-server/static/brand/sparo-mark-48.png' },
+ { group: 'relay', source: 'exports/mark/sparo-mark-512.png', target: 'src/apps/relay-server/static/brand/sparo-mark-full.png' },
+
+ // Installer source assets are package-local because it is an independently built app.
+ { group: 'installer', source: 'exports/mark/sparo-mark-16.png', target: 'installer/src/assets/brand/sparo-mark-16.png' },
+ { group: 'installer', source: 'exports/mark/sparo-mark-24.png', target: 'installer/src/assets/brand/sparo-mark-24.png' },
+ { group: 'installer', source: 'exports/mark/sparo-mark-32.png', target: 'installer/src/assets/brand/sparo-mark-32.png' },
+ { group: 'installer', source: 'exports/mark/sparo-mark-48.png', target: 'installer/src/assets/brand/sparo-mark-48.png' },
+ { group: 'installer', source: 'exports/mark/sparo-mark-512.png', target: 'installer/src/assets/brand/sparo-mark-full.png' },
+
+ // Desktop tray states use the complete circular Logo; active states add a compact status badge.
+ { group: 'desktop', source: 'exports/tray/sparo-tray-idle.png', target: 'src/apps/desktop/icons/tray/tray-idle.png' },
+ { group: 'desktop', source: 'exports/tray/sparo-tray-running.png', target: 'src/apps/desktop/icons/tray/tray-running.png' },
+ { group: 'desktop', source: 'exports/tray/sparo-tray-waiting.png', target: 'src/apps/desktop/icons/tray/tray-waiting.png' },
+ { group: 'desktop', source: 'exports/tray/sparo-tray-error.png', target: 'src/apps/desktop/icons/tray/tray-error.png' },
+]);
+
+export const platformIconTargets = Object.freeze([
+ 'src/apps/desktop/icons',
+ 'installer/src-tauri/icons',
+]);
+
+export const linuxHicolorSizes = Object.freeze([16, 32, 48, 64, 96, 128, 256, 512]);
+
+// These paths belong to the retired hand-drawn vector and one-off raster pipelines.
+export const legacyBrandAssets = Object.freeze([
+ 'assets/brand/source/sparo-mark-full.svg',
+ 'assets/brand/source/sparo-app-icon.svg',
+ 'assets/brand/source/sparo-wordmark.svg',
+ 'assets/brand/source/sparo-lockup-horizontal.svg',
+ 'src/web-ui/public/brand/favicon.svg',
+ 'src/web-ui/public/brand/sparo-mark-full.svg',
+ 'src/web-ui/public/brand/sparo-wordmark-primary.svg',
+ 'src/web-ui/public/brand/sparo-wordmark-reversed.svg',
+ 'src/web-ui/public/brand/sparo-wordmark-startup-primary.png',
+ 'src/web-ui/public/brand/sparo-wordmark-startup-reversed.png',
+ 'src/web-ui/src/design-system/foundation/brand/sparo-mark-16.svg',
+ 'src/web-ui/src/design-system/foundation/brand/sparo-mark-24.svg',
+ 'src/web-ui/src/design-system/foundation/brand/sparo-mark-32.svg',
+ 'src/web-ui/src/design-system/foundation/brand/sparo-mark-48.svg',
+ 'src/web-ui/src/design-system/foundation/brand/sparo-mark-full.svg',
+ 'src/web-ui/src/design-system/foundation/brand/sparo-app-icon-32.svg',
+ 'src/mobile-web/public/brand/sparo-mark-16.svg',
+ 'src/mobile-web/public/brand/sparo-mark-24.svg',
+ 'src/mobile-web/public/brand/sparo-mark-32.svg',
+ 'src/mobile-web/public/brand/sparo-mark-48.svg',
+ 'src/mobile-web/public/brand/sparo-mark-full.svg',
+ 'src/apps/relay-server/static/brand/sparo-mark-16.svg',
+ 'src/apps/relay-server/static/brand/sparo-mark-24.svg',
+ 'src/apps/relay-server/static/brand/sparo-mark-32.svg',
+ 'src/apps/relay-server/static/brand/sparo-mark-48.svg',
+ 'src/apps/relay-server/static/brand/sparo-mark-full.svg',
+ 'installer/src/assets/brand/sparo-mark-16.svg',
+ 'installer/src/assets/brand/sparo-mark-24.svg',
+ 'installer/src/assets/brand/sparo-mark-32.svg',
+ 'installer/src/assets/brand/sparo-mark-48.svg',
+ 'installer/src/assets/brand/sparo-mark-full.svg',
+ 'image/sparo-logo-mark.png',
+ 'image/sparo-app-icon-rounded.png',
+ 'image/wordmark/README.md',
+ 'image/wordmark/manifest.json',
+ 'image/wordmark/sparo-os-wordmark.svg',
+ 'image/wordmark/sparo-os-wordmark-reversed.svg',
+ 'image/wordmark/sparo-os-wordmark-monochrome.svg',
+ 'src/web-ui/public/sparo-logo-mark.png',
+ 'src/web-ui/public/sparo-app-icon.png',
+ 'src/mobile-web/public/favicon.png',
+ 'src/mobile-web/public/apple-touch-icon.png',
+ 'src/mobile-web/src/assets/sparo-logo-mark.png',
+ 'installer/src/assets/sparo-logo-mark.png',
+ 'src/apps/desktop/icons/sparo-app-icon.png',
+ 'src/apps/desktop/icons/app-icon-rounded-source.png',
+ 'installer/src-tauri/icons/app-icon-rounded-source.png',
+ 'src/apps/relay-server/static/favicon.png',
+ 'src/apps/relay-server/static/apple-touch-icon.png',
+ 'src/apps/relay-server/static/assets/sparo-logo-mark-BchWKRwx.png',
+ 'scripts/generate-icons.mjs',
+ 'scripts/generate-rounded-app-icon.mjs',
+ 'scripts/generate-mobile-web-icons.mjs',
+]);
+
+export const legacyBrandDirectories = Object.freeze([
+ 'assets/brand/source/small',
+ 'image/wordmark',
+]);
diff --git a/scripts/check-brand-assets.mjs b/scripts/check-brand-assets.mjs
new file mode 100644
index 00000000..0b8b760d
--- /dev/null
+++ b/scripts/check-brand-assets.mjs
@@ -0,0 +1,6 @@
+import { checkProductBrandAssets } from './sync-brand-assets.mjs';
+
+checkProductBrandAssets().catch((error) => {
+ console.error(error instanceof Error ? error.message : error);
+ process.exitCode = 1;
+});
diff --git a/scripts/generate-brand-assets.mjs b/scripts/generate-brand-assets.mjs
new file mode 100644
index 00000000..10e5033a
--- /dev/null
+++ b/scripts/generate-brand-assets.mjs
@@ -0,0 +1,967 @@
+import { createHash } from 'node:crypto';
+import { existsSync } from 'node:fs';
+import { mkdir, readFile, readdir, rm, writeFile } from 'node:fs/promises';
+import path from 'node:path';
+import { fileURLToPath } from 'node:url';
+
+import sharp from 'sharp';
+
+const REPO_ROOT = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
+const BRAND_ROOT = path.join(REPO_ROOT, 'assets', 'brand');
+const MARK_SOURCE = 'source/sparo-mark-master.png';
+const CORE_SOURCE = 'source/sparo-core-master.png';
+const REFERENCE_SOURCE = 'reference/sparo-identity-board.png';
+
+const MASTER_SIZE = 1024;
+const MARK_SIZES = Object.freeze([16, 24, 32, 48, 64, 128, 256, 512]);
+const APP_ICON_SIZES = Object.freeze([16, 24, 32, 48, 64, 128, 256, 512, 1024]);
+const SMALL_SIZES = Object.freeze([16, 24, 32, 48]);
+const TRAY_SIZES = Object.freeze([16, 20, 24, 32, 48]);
+const WORDMARK_STROKE_RADIUS = 3;
+
+const COLORS = Object.freeze({
+ coreRed: '#E53935',
+ warmWhite: '#F5F2EE',
+ softIvory: '#ECE7E1',
+ sandGray: '#D8D3CC',
+ deepCharcoal: '#1A1A1A',
+ reversed: '#FFFDFC',
+});
+
+const TRAY_STATE_BADGES = Object.freeze({
+ idle: null,
+ running: '#168A5B',
+ waiting: '#C77B12',
+ error: '#8B3AA8',
+});
+
+function isQaArtifact(relativePath) {
+ return relativePath.startsWith('qa/');
+}
+
+function sha256(value) {
+ return createHash('sha256').update(value).digest('hex');
+}
+
+function hexChannels(value) {
+ const normalized = value.replace('#', '');
+ return [0, 2, 4].map((offset) => Number.parseInt(normalized.slice(offset, offset + 2), 16));
+}
+
+function clamp(value, minimum = 0, maximum = 1) {
+ return Math.min(maximum, Math.max(minimum, value));
+}
+
+function escapeXml(value) {
+ return value
+ .replaceAll('&', '&')
+ .replaceAll('<', '<')
+ .replaceAll('>', '>')
+ .replaceAll('"', '"');
+}
+
+function labelSvg(width, height, value, size = 24, color = COLORS.deepCharcoal, anchor = 'start') {
+ const x = anchor === 'middle' ? width / 2 : anchor === 'end' ? width : 0;
+ return Buffer.from([
+ '',
+ ].join(''));
+}
+
+function circleCoverage(x, y, centerX, centerY, radius) {
+ return clamp(radius + 0.5 - Math.hypot(x + 0.5 - centerX, y + 0.5 - centerY));
+}
+
+function roundedRectangleCoverage(x, y, left, top, width, height, radius) {
+ const centerX = left + width / 2;
+ const centerY = top + height / 2;
+ const qx = Math.abs(x + 0.5 - centerX) - (width / 2 - radius);
+ const qy = Math.abs(y + 0.5 - centerY) - (height / 2 - radius);
+ const distance = Math.hypot(Math.max(qx, 0), Math.max(qy, 0)) + Math.min(Math.max(qx, qy), 0) - radius;
+ return clamp(0.5 - distance);
+}
+
+async function rawRgba(input) {
+ return sharp(input).ensureAlpha().raw().toBuffer({ resolveWithObject: true });
+}
+
+async function pngFromRaw(data, width, height) {
+ return sharp(data, { raw: { width, height, channels: 4 } })
+ .png({ compressionLevel: 9, adaptiveFiltering: false })
+ .toBuffer();
+}
+
+async function resizePng(input, width, height = width, { sharpen = false } = {}) {
+ let pipeline = sharp(input).resize(width, height, { fit: 'fill', kernel: sharp.kernel.lanczos3 });
+ if (sharpen) pipeline = pipeline.sharpen({ sigma: 0.55, m1: 0.8, m2: 1.5 });
+ return pipeline.png({ compressionLevel: 9, adaptiveFiltering: false }).toBuffer();
+}
+
+async function resizePremultipliedRgba(input, width, height) {
+ const source = await rawRgba(input);
+ const premultiplied = Buffer.alloc(source.data.length);
+ for (let offset = 0; offset < source.data.length; offset += 4) {
+ const alpha = source.data[offset + 3];
+ premultiplied[offset] = Math.round(source.data[offset] * alpha / 255);
+ premultiplied[offset + 1] = Math.round(source.data[offset + 1] * alpha / 255);
+ premultiplied[offset + 2] = Math.round(source.data[offset + 2] * alpha / 255);
+ premultiplied[offset + 3] = alpha;
+ }
+
+ const resized = await sharp(premultiplied, {
+ raw: { width: source.info.width, height: source.info.height, channels: 4 },
+ }).resize(width, height, {
+ fit: 'fill',
+ kernel: sharp.kernel.lanczos3,
+ }).raw().toBuffer({ resolveWithObject: true });
+
+ for (let offset = 0; offset < resized.data.length; offset += 4) {
+ const alpha = resized.data[offset + 3];
+ if (alpha === 0) {
+ resized.data[offset] = 0;
+ resized.data[offset + 1] = 0;
+ resized.data[offset + 2] = 0;
+ continue;
+ }
+ resized.data[offset] = Math.min(255, Math.round(resized.data[offset] * 255 / alpha));
+ resized.data[offset + 1] = Math.min(255, Math.round(resized.data[offset + 1] * 255 / alpha));
+ resized.data[offset + 2] = Math.min(255, Math.round(resized.data[offset + 2] * 255 / alpha));
+ }
+
+ return pngFromRaw(resized.data, width, height);
+}
+
+async function cropTransparentMargins(input, outputSize) {
+ const source = await rawRgba(input);
+ const bounds = alphaBounds(source.data, source.info.width, source.info.height, 8);
+ if (Math.abs(bounds.width - bounds.height) > 1) {
+ throw new Error('Expected circular artwork to have square visible bounds');
+ }
+ const cropSize = Math.max(bounds.width, bounds.height);
+ const centerX = bounds.left + bounds.width / 2;
+ const centerY = bounds.top + bounds.height / 2;
+ const left = Math.max(0, Math.min(
+ source.info.width - cropSize,
+ Math.round(centerX - cropSize / 2),
+ ));
+ const top = Math.max(0, Math.min(
+ source.info.height - cropSize,
+ Math.round(centerY - cropSize / 2),
+ ));
+ const cropped = await sharp(input)
+ .extract({ left, top, width: cropSize, height: cropSize })
+ .png({ compressionLevel: 9, adaptiveFiltering: false })
+ .toBuffer();
+ const result = await resizePremultipliedRgba(cropped, outputSize, outputSize);
+ const output = await rawRgba(result);
+ const outputBounds = alphaBounds(output.data, output.info.width, output.info.height, 8);
+ if (
+ outputBounds.left !== 0 ||
+ outputBounds.top !== 0 ||
+ outputBounds.width !== outputSize ||
+ outputBounds.height !== outputSize
+ ) {
+ throw new Error('Edge-fitted circular artwork must fill all four canvas edges');
+ }
+ return result;
+}
+
+async function coloredBlurredAlpha(alphaMask, width, height, color, sigma) {
+ const blurred = await sharp(alphaMask, {
+ raw: { width, height, channels: 1 },
+ }).blur(sigma).raw().toBuffer({ resolveWithObject: true });
+ const rgb = hexChannels(color);
+ const output = Buffer.alloc(width * height * 4);
+ for (let index = 0; index < alphaMask.length; index += 1) {
+ const offset = index * 4;
+ output[offset] = rgb[0];
+ output[offset + 1] = rgb[1];
+ output[offset + 2] = rgb[2];
+ output[offset + 3] = blurred.data[index * blurred.info.channels];
+ }
+ return pngFromRaw(output, width, height);
+}
+
+function alphaBounds(data, width, height, threshold) {
+ let left = width;
+ let top = height;
+ let right = -1;
+ let bottom = -1;
+ for (let y = 0; y < height; y += 1) {
+ for (let x = 0; x < width; x += 1) {
+ if (data[(y * width + x) * 4 + 3] < threshold) continue;
+ left = Math.min(left, x);
+ top = Math.min(top, y);
+ right = Math.max(right, x);
+ bottom = Math.max(bottom, y);
+ }
+ }
+ if (right < left || bottom < top) throw new Error('Raster source has no visible pixels');
+ return { left, top, width: right - left + 1, height: bottom - top + 1 };
+}
+
+async function normalizeMarkMaster(sourceBuffer) {
+ const source = await rawRgba(sourceBuffer);
+ const bounds = alphaBounds(source.data, source.info.width, source.info.height, 8);
+ const crop = Buffer.alloc(bounds.width * bounds.height * 4);
+ for (let y = 0; y < bounds.height; y += 1) {
+ for (let x = 0; x < bounds.width; x += 1) {
+ const from = ((bounds.top + y) * source.info.width + bounds.left + x) * 4;
+ const to = (y * bounds.width + x) * 4;
+ crop[to] = source.data[from];
+ crop[to + 1] = source.data[from + 1];
+ crop[to + 2] = source.data[from + 2];
+ crop[to + 3] = source.data[from + 3] < 8 ? 0 : source.data[from + 3];
+ }
+ }
+
+ const fieldSize = 896;
+ const resized = await sharp(crop, {
+ raw: { width: bounds.width, height: bounds.height, channels: 4 },
+ }).resize(fieldSize, fieldSize, { fit: 'fill', kernel: sharp.kernel.lanczos3 })
+ .raw()
+ .toBuffer();
+
+ const clipped = Buffer.from(resized);
+ const radius = 444;
+ for (let y = 0; y < fieldSize; y += 1) {
+ for (let x = 0; x < fieldSize; x += 1) {
+ const offset = (y * fieldSize + x) * 4;
+ const mask = circleCoverage(x, y, fieldSize / 2, fieldSize / 2, radius);
+ clipped[offset + 3] = Math.round(clipped[offset + 3] * mask);
+ }
+ }
+
+ const surface = await sharp({
+ create: { width: MASTER_SIZE, height: MASTER_SIZE, channels: 4, background: '#00000000' },
+ }).composite([{ input: await pngFromRaw(clipped, fieldSize, fieldSize), left: 64, top: 64 }])
+ .png({ compressionLevel: 9, adaptiveFiltering: false })
+ .toBuffer();
+
+ const shadowMask = Buffer.alloc(MASTER_SIZE * MASTER_SIZE);
+ for (let y = 0; y < MASTER_SIZE; y += 1) {
+ for (let x = 0; x < MASTER_SIZE; x += 1) {
+ shadowMask[y * MASTER_SIZE + x] = Math.round(
+ circleCoverage(x, y, 512, 528, radius) * 48,
+ );
+ }
+ }
+ const shadow = await coloredBlurredAlpha(
+ shadowMask,
+ MASTER_SIZE,
+ MASTER_SIZE,
+ '#695B50',
+ 22,
+ );
+
+ const mark = await sharp({
+ create: { width: MASTER_SIZE, height: MASTER_SIZE, channels: 4, background: '#00000000' },
+ }).composite([{ input: shadow }, { input: surface }])
+ .png({ compressionLevel: 9, adaptiveFiltering: false })
+ .toBuffer();
+
+ return { mark, surface, sourceBounds: bounds };
+}
+
+async function prepareCoreMaster(sourceBuffer) {
+ const source = await rawRgba(sourceBuffer);
+ const bounds = alphaBounds(source.data, source.info.width, source.info.height, 8);
+ const crop = Buffer.alloc(bounds.width * bounds.height * 4);
+ for (let y = 0; y < bounds.height; y += 1) {
+ for (let x = 0; x < bounds.width; x += 1) {
+ const from = ((bounds.top + y) * source.info.width + bounds.left + x) * 4;
+ const to = (y * bounds.width + x) * 4;
+ const alpha = source.data[from + 3] < 8 ? 0 : source.data[from + 3];
+ crop[to] = alpha === 0 ? 0 : source.data[from];
+ crop[to + 1] = alpha === 0 ? 0 : source.data[from + 1];
+ crop[to + 2] = alpha === 0 ? 0 : source.data[from + 2];
+ crop[to + 3] = alpha;
+ }
+ }
+ return {
+ artwork: await pngFromRaw(crop, bounds.width, bounds.height),
+ bounds,
+ };
+}
+
+async function extractWordmark(referenceBuffer) {
+ // The approved board contains layout dividers on both sides of the wordmark
+ // panel. Keep the extraction window strictly inside those rules.
+ const region = { left: 875, top: 575, width: 490, height: 110 };
+ const source = await sharp(referenceBuffer).extract(region).removeAlpha().raw().toBuffer({ resolveWithObject: true });
+ const raw = Buffer.alloc(source.info.width * source.info.height * 4);
+ const charcoal = hexChannels(COLORS.deepCharcoal);
+ const red = hexChannels(COLORS.coreRed);
+ for (let y = 0; y < source.info.height; y += 1) {
+ for (let x = 0; x < source.info.width; x += 1) {
+ const from = (y * source.info.width + x) * 3;
+ const to = (y * source.info.width + x) * 4;
+ const r = source.data[from];
+ const g = source.data[from + 1];
+ const b = source.data[from + 2];
+ const isRed = r > 120 && r - g > 45 && r - b > 40;
+ const luminance = r * 0.2126 + g * 0.7152 + b * 0.0722;
+ let alpha;
+ let color;
+ if (isRed) {
+ alpha = Math.max((255 - g) / (255 - red[1]), (255 - b) / (255 - red[2]));
+ color = red;
+ } else {
+ alpha = (250 - luminance) / (250 - 26);
+ color = charcoal;
+ }
+ alpha = alpha < 0.035 ? 0 : clamp(alpha);
+ raw[to] = color[0];
+ raw[to + 1] = color[1];
+ raw[to + 2] = color[2];
+ raw[to + 3] = Math.round(alpha * 255);
+ }
+ }
+ const bounds = alphaBounds(raw, source.info.width, source.info.height, 8);
+ const padding = 4;
+ const left = Math.max(0, bounds.left - padding);
+ const top = Math.max(0, bounds.top - padding);
+ const width = Math.min(source.info.width - left, bounds.width + padding * 2);
+ const height = Math.min(source.info.height - top, bounds.height + padding * 2);
+ const cropped = await sharp(raw, {
+ raw: { width: source.info.width, height: source.info.height, channels: 4 },
+ }).extract({ left, top, width, height }).png({ compressionLevel: 9, adaptiveFiltering: false }).toBuffer();
+
+ return sharp({
+ create: { width: 950, height: 192, channels: 4, background: '#00000000' },
+ }).composite([{
+ input: await sharp(cropped).resize(918, 176, {
+ fit: 'contain',
+ kernel: sharp.kernel.lanczos3,
+ background: '#00000000',
+ }).toBuffer(),
+ left: 16,
+ top: 8,
+ }]).png({ compressionLevel: 9, adaptiveFiltering: false }).toBuffer();
+}
+
+async function recolorWordmark(wordmark, foreground, { preserveRed = true } = {}) {
+ const source = await rawRgba(wordmark);
+ const color = hexChannels(foreground);
+ for (let offset = 0; offset < source.data.length; offset += 4) {
+ const isRed = source.data[offset] > source.data[offset + 1] + 80;
+ if (preserveRed && isRed) continue;
+ source.data[offset] = color[0];
+ source.data[offset + 1] = color[1];
+ source.data[offset + 2] = color[2];
+ }
+ return pngFromRaw(source.data, source.info.width, source.info.height);
+}
+
+function dilateAlphaMask(mask, width, height, radius) {
+ const result = Buffer.alloc(mask.length);
+ const offsets = [];
+ for (let y = -radius; y <= radius; y += 1) {
+ for (let x = -radius; x <= radius; x += 1) {
+ if (x * x + y * y <= radius * radius) offsets.push([x, y]);
+ }
+ }
+ for (let y = 0; y < height; y += 1) {
+ for (let x = 0; x < width; x += 1) {
+ let alpha = 0;
+ for (const [offsetX, offsetY] of offsets) {
+ const sampleX = x + offsetX;
+ const sampleY = y + offsetY;
+ if (sampleX < 0 || sampleX >= width || sampleY < 0 || sampleY >= height) continue;
+ alpha = Math.max(alpha, mask[sampleY * width + sampleX]);
+ }
+ result[y * width + x] = alpha;
+ }
+ }
+ return result;
+}
+
+async function buildOpticallyBoldWordmark(
+ wordmark,
+ foreground,
+ { radius = WORDMARK_STROKE_RADIUS, preserveRed = true } = {},
+) {
+ const source = await rawRgba(wordmark);
+ const neutralAlpha = Buffer.alloc(source.info.width * source.info.height);
+ const redAlpha = Buffer.alloc(source.info.width * source.info.height);
+ for (let index = 0; index < neutralAlpha.length; index += 1) {
+ const offset = index * 4;
+ const isRed = source.data[offset] > source.data[offset + 1] + 80;
+ if (isRed && preserveRed) {
+ redAlpha[index] = source.data[offset + 3];
+ } else {
+ neutralAlpha[index] = source.data[offset + 3];
+ }
+ }
+
+ const expandedNeutral = dilateAlphaMask(
+ neutralAlpha,
+ source.info.width,
+ source.info.height,
+ radius,
+ );
+ const foregroundRgb = hexChannels(foreground);
+ const redRgb = hexChannels(COLORS.coreRed);
+ const output = Buffer.alloc(source.data.length);
+ for (let index = 0; index < expandedNeutral.length; index += 1) {
+ const offset = index * 4;
+ const foregroundAlpha = expandedNeutral[index] / 255;
+ const accentAlpha = redAlpha[index] / 255;
+ const alpha = accentAlpha + foregroundAlpha * (1 - accentAlpha);
+ if (alpha === 0) continue;
+ const foregroundContribution = foregroundAlpha * (1 - accentAlpha);
+ output[offset] = Math.round(
+ (redRgb[0] * accentAlpha + foregroundRgb[0] * foregroundContribution) / alpha,
+ );
+ output[offset + 1] = Math.round(
+ (redRgb[1] * accentAlpha + foregroundRgb[1] * foregroundContribution) / alpha,
+ );
+ output[offset + 2] = Math.round(
+ (redRgb[2] * accentAlpha + foregroundRgb[2] * foregroundContribution) / alpha,
+ );
+ output[offset + 3] = Math.round(alpha * 255);
+ }
+ return pngFromRaw(output, source.info.width, source.info.height);
+}
+
+async function buildLockup(mark, wordmark, dividerColor) {
+ const divider = await sharp({
+ create: { width: 4, height: 176, channels: 4, background: dividerColor },
+ }).png({ compressionLevel: 9, adaptiveFiltering: false }).toBuffer();
+ return sharp({
+ create: { width: 1340, height: 256, channels: 4, background: '#00000000' },
+ }).composite([
+ { input: await resizePng(mark, 256), left: 0, top: 0 },
+ { input: divider, left: 302, top: 40 },
+ { input: wordmark, left: 352, top: 32 },
+ ]).png({ compressionLevel: 9, adaptiveFiltering: false }).toBuffer();
+}
+
+async function buildCompactCore(coreArtwork, size) {
+ const metadata = await sharp(coreArtwork).metadata();
+ if (!metadata.width || !metadata.height) throw new Error('Core master has invalid dimensions');
+
+ // Keep a target-specific transparent safe zone. Directly assigning the
+ // 1536x1024 master to a 32px tray slot causes dark alpha fringes and lets
+ // platform scaling choose inconsistent optical sizes.
+ const contentLimit = Math.max(1, Math.round(size * 0.875));
+ const scale = Math.min(contentLimit / metadata.width, contentLimit / metadata.height);
+ const width = Math.max(1, Math.round(metadata.width * scale));
+ const height = Math.max(1, Math.round(metadata.height * scale));
+ const core = await resizePremultipliedRgba(coreArtwork, width, height);
+
+ return sharp({
+ create: { width: size, height: size, channels: 4, background: '#00000000' },
+ }).composite([{
+ input: core,
+ left: Math.floor((size - width) / 2),
+ top: Math.floor((size - height) / 2),
+ }]).png({ compressionLevel: 9, adaptiveFiltering: true }).toBuffer();
+}
+
+async function buildTrayLogo(appIcon, size) {
+ return resizePremultipliedRgba(appIcon, size, size);
+}
+
+async function buildTrayState(appIcon, size, badgeColor) {
+ const logo = await buildTrayLogo(appIcon, size);
+ if (!badgeColor) return logo;
+
+ const badge = Buffer.alloc(size * size * 4);
+ const rgb = hexChannels(badgeColor);
+ const radius = Math.max(2, size * 0.125);
+ const borderWidth = Math.max(0.75, size / 32);
+ const center = size - radius - Math.max(0.5, size * 0.035);
+ for (let y = 0; y < size; y += 1) {
+ for (let x = 0; x < size; x += 1) {
+ const offset = (y * size + x) * 4;
+ const outer = circleCoverage(x, y, center, center, radius + borderWidth);
+ const inner = circleCoverage(x, y, center, center, radius);
+ const border = Math.max(0, outer - inner);
+ const alpha = Math.max(inner, border);
+ if (alpha === 0) continue;
+ const useBorder = border > inner;
+ badge[offset] = useBorder ? 255 : rgb[0];
+ badge[offset + 1] = useBorder ? 253 : rgb[1];
+ badge[offset + 2] = useBorder ? 252 : rgb[2];
+ badge[offset + 3] = Math.round(alpha * 255);
+ }
+ }
+
+ return sharp(logo).composite([{ input: await pngFromRaw(badge, size, size) }])
+ .png({ compressionLevel: 9, adaptiveFiltering: true })
+ .toBuffer();
+}
+
+async function roundedSwatch(color) {
+ const size = 104;
+ const raw = Buffer.alloc(size * size * 4);
+ const rgb = hexChannels(color);
+ for (let y = 0; y < size; y += 1) {
+ for (let x = 0; x < size; x += 1) {
+ const offset = (y * size + x) * 4;
+ const alpha = roundedRectangleCoverage(x, y, 0, 0, size, size, 20);
+ raw[offset] = rgb[0];
+ raw[offset + 1] = rgb[1];
+ raw[offset + 2] = rgb[2];
+ raw[offset + 3] = Math.round(alpha * 255);
+ }
+ }
+ return pngFromRaw(raw, size, size);
+}
+
+async function buildBrandPreview(variants) {
+ const composites = [
+ { input: labelSvg(1450, 54, 'Sparo OS raster brand asset matrix', 36), left: 72, top: 50 },
+ { input: labelSvg(560, 38, 'Circular default logo', 22), left: 84, top: 126 },
+ { input: await resizePng(variants.mark, 510), left: 84, top: 176 },
+ { input: labelSvg(390, 38, 'Circular application icon', 22), left: 710, top: 126 },
+ { input: await resizePng(variants.appIcon, 330), left: 748, top: 184 },
+ { input: labelSvg(440, 38, 'Reference-derived wordmark', 22), left: 710, top: 560 },
+ { input: await sharp(variants.wordmarkPrimary).resize({ width: 760, fit: 'contain' }).toBuffer(), left: 710, top: 614 },
+ { input: labelSvg(440, 38, 'Horizontal lockup', 22), left: 710, top: 800 },
+ { input: await sharp(variants.lockupPrimary).resize({ width: 800, fit: 'contain' }).toBuffer(), left: 710, top: 848 },
+ ];
+ const palette = [
+ ['CORE RED', COLORS.coreRed],
+ ['WARM WHITE', COLORS.warmWhite],
+ ['SOFT IVORY', COLORS.softIvory],
+ ['SAND GRAY', COLORS.sandGray],
+ ['DEEP CHARCOAL', COLORS.deepCharcoal],
+ ];
+ for (const [index, [name, color]] of palette.entries()) {
+ const left = 76 + index * 124;
+ composites.push({ input: await roundedSwatch(color), left, top: 792 });
+ composites.push({ input: labelSvg(112, 24, name, 12), left: left - 2, top: 910 });
+ composites.push({ input: labelSvg(112, 22, color, 12), left: left - 2, top: 936 });
+ }
+ return sharp({ create: { width: 1600, height: 1040, channels: 4, background: '#FFFFFF' } })
+ .composite(composites)
+ .png({ compressionLevel: 9, adaptiveFiltering: false })
+ .toBuffer();
+}
+
+async function buildSmallPreview(smallMarks, smallAppIcons) {
+ const composites = [
+ { input: labelSvg(1080, 52, 'Sparo small-size raster QA', 34), left: 60, top: 42 },
+ { input: labelSvg(480, 34, 'Default circular logo', 21), left: 72, top: 124 },
+ { input: labelSvg(480, 34, 'Application icon', 21), left: 620, top: 124 },
+ ];
+ for (const [index, size] of SMALL_SIZES.entries()) {
+ const top = 184 + index * 110;
+ composites.push({ input: await resizePng(smallMarks[size], 84), left: 76, top });
+ composites.push({ input: await resizePng(smallAppIcons[size], 84), left: 624, top });
+ composites.push({ input: smallMarks[size], left: 206, top: top + 22 });
+ composites.push({ input: smallAppIcons[size], left: 754, top: top + 22 });
+ composites.push({ input: labelSvg(250, 30, size + ' px raster / native', 18), left: 292, top: top + 28 });
+ composites.push({ input: labelSvg(250, 30, size + ' px raster / native', 18), left: 840, top: top + 28 });
+ }
+ return sharp({ create: { width: 1160, height: 670, channels: 4, background: '#FFFFFF' } })
+ .composite(composites)
+ .png({ compressionLevel: 9, adaptiveFiltering: false })
+ .toBuffer();
+}
+
+async function buildStartupBrandPreview(mark, wordmarkPrimary, wordmarkReversed) {
+ const lightPanel = await sharp({
+ create: { width: 500, height: 500, channels: 4, background: COLORS.warmWhite },
+ }).png().toBuffer();
+ const darkPanel = await sharp({
+ create: { width: 500, height: 500, channels: 4, background: COLORS.deepCharcoal },
+ }).png().toBuffer();
+ const mark128 = await resizePng(mark, 128);
+ const primary220 = await sharp(wordmarkPrimary).resize({ width: 220, fit: 'contain' }).png().toBuffer();
+ const reversed220 = await sharp(wordmarkReversed).resize({ width: 220, fit: 'contain' }).png().toBuffer();
+ return sharp({ create: { width: 1100, height: 620, channels: 4, background: '#FFFFFF' } })
+ .composite([
+ { input: labelSvg(1000, 52, 'Sparo startup brand lockup / actual CSS pixel scale', 32), left: 50, top: 38 },
+ { input: lightPanel, left: 40, top: 100 },
+ { input: darkPanel, left: 560, top: 100 },
+ { input: labelSvg(440, 32, 'LIGHT', 17, COLORS.deepCharcoal, 'middle'), left: 70, top: 126 },
+ { input: labelSvg(440, 32, 'DARK', 17, COLORS.reversed, 'middle'), left: 590, top: 126 },
+ { input: mark128, left: 226, top: 190 },
+ { input: mark128, left: 746, top: 190 },
+ { input: primary220, left: 180, top: 336 },
+ { input: reversed220, left: 700, top: 336 },
+ ])
+ .png({ compressionLevel: 9, adaptiveFiltering: false })
+ .toBuffer();
+}
+
+async function buildAppIconSizePreview(appIcons) {
+ const sizes = [16, 24, 32, 48, 64, 128];
+ const composites = [
+ { input: labelSvg(1080, 52, 'Sparo application icon size policy', 34), left: 56, top: 42 },
+ { input: labelSvg(980, 32, 'Circular material logo at every size / target-specific alpha-safe raster reduction', 18), left: 58, top: 92 },
+ ];
+ for (const [index, size] of sizes.entries()) {
+ const icon = appIcons[size];
+ const left = 58 + index * 182;
+ const enlarged = size < 128
+ ? await sharp(icon).resize(128, 128, { kernel: sharp.kernel.nearest }).png().toBuffer()
+ : icon;
+ composites.push({ input: enlarged, left, top: 156 });
+ composites.push({ input: icon, left: left + Math.floor((128 - size) / 2), top: 304 });
+ composites.push({ input: labelSvg(154, 28, size + ' px', 17, COLORS.deepCharcoal, 'middle'), left: left - 12, top: 448 });
+ composites.push({
+ input: labelSvg(
+ 154,
+ 26,
+ 'CIRCULAR',
+ 14,
+ COLORS.coreRed,
+ 'middle',
+ ),
+ left: left - 12,
+ top: 482,
+ });
+ }
+ return sharp({ create: { width: 1160, height: 550, channels: 4, background: '#FFFFFF' } })
+ .composite(composites)
+ .png({ compressionLevel: 9, adaptiveFiltering: false })
+ .toBuffer();
+}
+
+async function buildTrayPreview(trayStates, traySizes) {
+ const composites = [
+ { input: labelSvg(920, 52, 'Sparo full-logo tray assets', 34), left: 54, top: 42 },
+ { input: labelSvg(820, 32, 'Edge-fitted circular Logo; active states add a compact badge.', 17), left: 56, top: 92 },
+ ];
+ for (const [index, [state, icon]] of Object.entries(trayStates).entries()) {
+ const left = 64 + index * 218;
+ composites.push({
+ input: await sharp(icon).resize(128, 128, { kernel: sharp.kernel.nearest }).png().toBuffer(),
+ left,
+ top: 142,
+ });
+ composites.push({ input: icon, left: left + 160, top: 190 });
+ composites.push({ input: labelSvg(192, 30, state.toUpperCase(), 18, COLORS.deepCharcoal, 'middle'), left, top: 294 });
+ }
+ for (const [index, [size, icon]] of Object.entries(traySizes).entries()) {
+ const left = 72 + index * 170;
+ composites.push({
+ input: await sharp(icon).resize(96, 96, { kernel: sharp.kernel.nearest }).png().toBuffer(),
+ left,
+ top: 388,
+ });
+ composites.push({ input: icon, left: left + 112, top: 420 });
+ composites.push({ input: labelSvg(142, 28, size + ' px', 17, COLORS.deepCharcoal, 'middle'), left: left - 12, top: 500 });
+ }
+ return sharp({ create: { width: 940, height: 570, channels: 4, background: '#FFFFFF' } })
+ .composite(composites)
+ .png({ compressionLevel: 9, adaptiveFiltering: false })
+ .toBuffer();
+}
+
+function manifestFor(assets, sources, metadata, sourceBounds, coreBounds) {
+ const files = [...assets.entries()]
+ // QA boards contain host-rendered labels. Their pixels can differ with the
+ // system font stack even when every product asset is byte-identical.
+ .filter(([filePath]) => !isQaArtifact(filePath))
+ .sort(([left], [right]) => left.localeCompare(right))
+ .map(([filePath, value]) => ({ path: filePath, bytes: value.length, sha256: sha256(value) }));
+ return {
+ schemaVersion: 5,
+ brandVersion: '2026.08-tight-circular-system-icons',
+ status: 'current',
+ generatedBy: 'pnpm run brand:generate',
+ provenance: {
+ mark: {
+ path: MARK_SOURCE,
+ pixels: [metadata.mark.width, metadata.mark.height],
+ sha256: sha256(sources[MARK_SOURCE]),
+ treatment: 'Low-alpha speckles removed, visible bounds normalized to a true circle, supplied material detail preserved.',
+ },
+ core: {
+ path: CORE_SOURCE,
+ pixels: [metadata.core.width, metadata.core.height],
+ sha256: sha256(sources[CORE_SOURCE]),
+ treatment: 'Source silhouette and material preserved for compact in-product core exports; target sizes use alpha-safe reduction and lossless PNG compression.',
+ },
+ reference: {
+ path: REFERENCE_SOURCE,
+ pixels: [metadata.reference.width, metadata.reference.height],
+ sha256: sha256(sources[REFERENCE_SOURCE]),
+ },
+ appIcon: 'Transparent margins are removed on all four sides of the normalized circular material Logo before platform-size reduction; source proportions and material are preserved.',
+ wordmark: 'Deterministic transparent raster extraction from the approved identity board with a global 3px optical stroke expansion; the approved letter geometry and red core are preserved without redrawn paths.',
+ },
+ roles: {
+ defaultLogo: 'circular',
+ applicationIcon: 'circular at every size, including taskbar and window icons',
+ trayIcon: 'edge-fitted circular material Logo with the red core; active states add a compact status badge',
+ wordmark: 'Globally optically bold Sparo OS wordmark with a red core inside the lowercase a',
+ },
+ formatPolicy: 'Brand artwork is PNG-only. Product code must not redraw or embed brand geometry as SVG.',
+ qaPolicy: 'QA preview boards are validated for presence, PNG format, and dimensions but excluded from cross-platform byte hashes because their labels use host font rasterization.',
+ colors: {
+ coreRed: COLORS.coreRed,
+ warmWhite: COLORS.warmWhite,
+ softIvory: COLORS.softIvory,
+ sandGray: COLORS.sandGray,
+ deepCharcoal: COLORS.deepCharcoal,
+ },
+ sourceProcessing: {
+ alphaThreshold: 8,
+ detectedVisibleBounds: sourceBounds,
+ detectedCoreBounds: coreBounds,
+ normalizedCanvas: [MASTER_SIZE, MASTER_SIZE],
+ wordmark: {
+ neutralStrokeExpansionPx: WORDMARK_STROKE_RADIUS,
+ primaryAndReversedPreserveRedCore: true,
+ redrawnGeometry: false,
+ },
+ },
+ sizePolicy: {
+ canonicalMinimumPx: 64,
+ responsiveMinimumPx: 16,
+ rule: 'Use the normalized raster master at 64px and above and target-specific raster reductions at 16-48px.',
+ smallSizes: SMALL_SIZES,
+ },
+ appIcon: {
+ master: 'exports/app-icon/sparo-app-icon-1024.png',
+ geometry: 'circular',
+ transparentOutsideCircle: true,
+ edgeFit: 'Visible bounds fill all four sides of the square canvas; only the circular corners remain transparent.',
+ smallSizeProcessing: 'Premultiplied-alpha Lanczos reduction from the normalized circular mark.',
+ iosOpaqueBackground: COLORS.warmWhite,
+ },
+ tray: {
+ geometry: 'Direct target-size raster derivatives of the edge-fitted circular material Logo with its red core.',
+ stateBadges: TRAY_STATE_BADGES,
+ sizes: TRAY_SIZES,
+ contentLimit: 'Visible circular Logo fills all four sides of the target canvas without added transparent padding.',
+ compression: 'Lossless PNG, level 9, adaptive filtering.',
+ },
+ sources: Object.fromEntries(
+ Object.entries(sources).map(([filePath, value]) => [filePath, { bytes: value.length, sha256: sha256(value) }]),
+ ),
+ files,
+ };
+}
+
+async function buildBrandAssets() {
+ const [markSource, coreSource, referenceSource] = await Promise.all([
+ readFile(path.join(BRAND_ROOT, MARK_SOURCE)),
+ readFile(path.join(BRAND_ROOT, CORE_SOURCE)),
+ readFile(path.join(BRAND_ROOT, REFERENCE_SOURCE)),
+ ]);
+ const [markMetadata, coreMetadata, referenceMetadata] = await Promise.all([
+ sharp(markSource).metadata(),
+ sharp(coreSource).metadata(),
+ sharp(referenceSource).metadata(),
+ ]);
+ if (!markMetadata.hasAlpha || !markMetadata.width || !markMetadata.height) {
+ throw new Error(MARK_SOURCE + ' must be a transparent PNG');
+ }
+ if (!coreMetadata.hasAlpha || !coreMetadata.width || !coreMetadata.height) {
+ throw new Error(CORE_SOURCE + ' must be a transparent PNG');
+ }
+ if (referenceMetadata.width !== 1448 || referenceMetadata.height !== 1086) {
+ throw new Error(REFERENCE_SOURCE + ' must retain the approved 1448x1086 board');
+ }
+
+ const normalized = await normalizeMarkMaster(markSource);
+ const core = await prepareCoreMaster(coreSource);
+ const appIcon = await cropTransparentMargins(normalized.surface, MASTER_SIZE);
+ const wordmarkSource = await extractWordmark(referenceSource);
+ const wordmarkPrimary = await buildOpticallyBoldWordmark(wordmarkSource, COLORS.deepCharcoal);
+ const wordmarkReversed = await buildOpticallyBoldWordmark(wordmarkSource, COLORS.reversed);
+ const wordmarkMono = await buildOpticallyBoldWordmark(
+ wordmarkSource,
+ COLORS.deepCharcoal,
+ { preserveRed: false },
+ );
+ const lockupPrimary = await buildLockup(normalized.mark, wordmarkPrimary, COLORS.sandGray);
+ const lockupReversed = await buildLockup(normalized.mark, wordmarkReversed, '#8A8580');
+ const lockupMono = await buildLockup(
+ await recolorWordmark(normalized.mark, COLORS.deepCharcoal, { preserveRed: false }),
+ wordmarkMono,
+ COLORS.deepCharcoal,
+ );
+ const variants = {
+ mark: normalized.mark,
+ appIcon,
+ wordmarkPrimary,
+ wordmarkReversed,
+ wordmarkMono,
+ lockupPrimary,
+ lockupReversed,
+ lockupMono,
+ };
+
+ const assets = new Map();
+ for (const size of MARK_SIZES) {
+ assets.set('exports/mark/sparo-mark-' + size + '.png', await resizePng(normalized.mark, size));
+ }
+ for (const size of APP_ICON_SIZES) {
+ assets.set(
+ 'exports/app-icon/sparo-app-icon-' + size + '.png',
+ await resizePremultipliedRgba(appIcon, size, size),
+ );
+ }
+ assets.set('exports/wordmark/sparo-wordmark-primary.png', wordmarkPrimary);
+ assets.set('exports/wordmark/sparo-wordmark-reversed.png', wordmarkReversed);
+ assets.set('exports/wordmark/sparo-wordmark-mono.png', wordmarkMono);
+ assets.set('exports/lockup/sparo-lockup-horizontal-primary.png', lockupPrimary);
+ assets.set('exports/lockup/sparo-lockup-horizontal-reversed.png', lockupReversed);
+ assets.set('exports/lockup/sparo-lockup-horizontal-mono.png', lockupMono);
+
+ const smallMarks = {};
+ const smallAppIcons = {};
+ for (const size of SMALL_SIZES) {
+ smallMarks[size] = assets.get('exports/mark/sparo-mark-' + size + '.png');
+ smallAppIcons[size] = assets.get('exports/app-icon/sparo-app-icon-' + size + '.png');
+ }
+
+ const traySizes = {};
+ for (const size of TRAY_SIZES) {
+ assets.set('exports/core/sparo-core-' + size + '.png', await buildCompactCore(core.artwork, size));
+ traySizes[size] = await buildTrayLogo(appIcon, size);
+ assets.set('exports/tray/sparo-tray-idle-' + size + '.png', traySizes[size]);
+ assets.set('exports/tray/sparo-tray-' + size + '-dark.png', traySizes[size]);
+ assets.set('exports/tray/sparo-tray-' + size + '-light.png', traySizes[size]);
+ }
+ const trayStates = {};
+ for (const [state, badgeColor] of Object.entries(TRAY_STATE_BADGES)) {
+ trayStates[state] = await buildTrayState(appIcon, 32, badgeColor);
+ assets.set('exports/tray/sparo-tray-' + state + '.png', trayStates[state]);
+ }
+
+ for (const size of [16, 32, 48]) {
+ assets.set('exports/web/favicon-' + size + '.png', smallAppIcons[size]);
+ }
+ assets.set('exports/web/apple-touch-icon-180.png', await resizePng(appIcon, 180));
+ assets.set('exports/web/web-app-icon-192.png', await resizePng(appIcon, 192));
+ assets.set('exports/web/web-app-icon-512.png', await resizePng(appIcon, 512));
+ const appIconPreviewSizes = Object.fromEntries(
+ [16, 24, 32, 48, 64, 128].map((size) => [
+ size,
+ assets.get('exports/app-icon/sparo-app-icon-' + size + '.png'),
+ ]),
+ );
+ assets.set('qa/sparo-brand-asset-matrix.png', await buildBrandPreview(variants));
+ assets.set('qa/sparo-app-icon-size-matrix.png', await buildAppIconSizePreview(appIconPreviewSizes));
+ assets.set('qa/sparo-small-mark-matrix.png', await buildSmallPreview(smallMarks, smallAppIcons));
+ assets.set('qa/sparo-startup-brand-preview.png', await buildStartupBrandPreview(
+ normalized.mark,
+ wordmarkPrimary,
+ wordmarkReversed,
+ ));
+ assets.set('qa/sparo-tray-state-matrix.png', await buildTrayPreview(trayStates, traySizes));
+
+ const sources = {
+ [MARK_SOURCE]: markSource,
+ [CORE_SOURCE]: coreSource,
+ [REFERENCE_SOURCE]: referenceSource,
+ };
+ assets.set('manifest.json', Buffer.from(JSON.stringify(manifestFor(
+ assets,
+ sources,
+ {
+ mark: markMetadata,
+ core: coreMetadata,
+ reference: referenceMetadata,
+ },
+ normalized.sourceBounds,
+ core.bounds,
+ ), null, 2) + '\n'));
+ return assets;
+}
+
+async function walkFiles(directory) {
+ if (!existsSync(directory)) return [];
+ const result = [];
+ for (const entry of await readdir(directory, { withFileTypes: true })) {
+ const fullPath = path.join(directory, entry.name);
+ if (entry.isDirectory()) result.push(...await walkFiles(fullPath));
+ if (entry.isFile()) result.push(fullPath);
+ }
+ return result;
+}
+
+async function clearGeneratedAssets() {
+ for (const relativePath of ['exports', 'qa']) {
+ await rm(path.join(BRAND_ROOT, relativePath), { force: true, recursive: true });
+ }
+ await rm(path.join(BRAND_ROOT, 'manifest.json'), { force: true });
+}
+
+export async function generateBrandAssets() {
+ const assets = await buildBrandAssets();
+ await clearGeneratedAssets();
+ for (const [relativePath, value] of assets) {
+ const destination = path.join(BRAND_ROOT, relativePath);
+ await mkdir(path.dirname(destination), { recursive: true });
+ await writeFile(destination, value);
+ }
+ const qaCount = [...assets.keys()].filter(isQaArtifact).length;
+ const deterministicCount = assets.size - qaCount;
+ console.log(
+ 'Generated ' + deterministicCount + ' deterministic Sparo brand files and ' +
+ qaCount + ' host-rendered QA previews.',
+ );
+}
+
+export async function checkBrandAssets() {
+ const expected = await buildBrandAssets();
+ const failures = [];
+ for (const [relativePath, value] of expected) {
+ try {
+ const actual = await readFile(path.join(BRAND_ROOT, relativePath));
+ if (isQaArtifact(relativePath)) {
+ const [actualMetadata, expectedMetadata] = await Promise.all([
+ sharp(actual).metadata(),
+ sharp(value).metadata(),
+ ]);
+ if (
+ actualMetadata.format !== 'png' ||
+ actualMetadata.width !== expectedMetadata.width ||
+ actualMetadata.height !== expectedMetadata.height
+ ) {
+ failures.push(relativePath + ' has an invalid format or dimensions');
+ }
+ } else if (!actual.equals(value)) {
+ failures.push(relativePath + ' is stale');
+ }
+ } catch {
+ failures.push(relativePath + ' is missing');
+ }
+ }
+ const expectedPaths = new Set(expected.keys());
+ for (const directory of ['exports', 'qa']) {
+ for (const filePath of await walkFiles(path.join(BRAND_ROOT, directory))) {
+ const relativePath = path.relative(BRAND_ROOT, filePath).replaceAll('\\', '/');
+ if (!expectedPaths.has(relativePath)) failures.push(relativePath + ' is unmanaged');
+ if (path.extname(relativePath).toLowerCase() === '.svg') failures.push(relativePath + ' violates the PNG-only policy');
+ }
+ }
+ for (const legacyPath of [
+ 'source/sparo-mark-full.svg',
+ 'source/sparo-app-icon.svg',
+ 'source/sparo-wordmark.svg',
+ 'source/sparo-lockup-horizontal.svg',
+ 'source/small',
+ ]) {
+ if (existsSync(path.join(BRAND_ROOT, legacyPath))) failures.push(legacyPath + ' is a legacy vector source');
+ }
+ if (failures.length > 0) {
+ throw new Error('Brand assets are not current:\n- ' + failures.join('\n- ') + '\nRun pnpm run brand:generate.');
+ }
+ const qaCount = [...expected.keys()].filter(isQaArtifact).length;
+ const deterministicCount = expected.size - qaCount;
+ console.log(
+ 'Verified ' + deterministicCount + ' deterministic Sparo brand files and ' +
+ qaCount + ' host-rendered QA previews.',
+ );
+}
+
+const isMain = process.argv[1] && path.resolve(process.argv[1]) === fileURLToPath(import.meta.url);
+if (isMain) {
+ const shouldCheck = process.argv.includes('--check');
+ (shouldCheck ? checkBrandAssets() : generateBrandAssets()).catch((error) => {
+ console.error(error instanceof Error ? error.message : error);
+ process.exitCode = 1;
+ });
+}
diff --git a/scripts/generate-icons.mjs b/scripts/generate-icons.mjs
deleted file mode 100644
index 52056606..00000000
--- a/scripts/generate-icons.mjs
+++ /dev/null
@@ -1,267 +0,0 @@
-/**
- * Generate rounded-rect Tauri desktop icons from the new logo.
- *
- * Strategy: start from sparo-logo-mark.png (logo mark on transparent bg,
- * trimmed tight). Composite it onto a rounded-rect filled with the brand dark
- * surface. Padding is pixel-controlled so small sizes stay crisp and legible.
- *
- * Run AFTER `pnpm tauri icon` so rounded versions overwrite the plain ones.
- * Handles both the main desktop app and the installer.
- */
-
-import { createRequire } from 'module';
-import { fileURLToPath } from 'url';
-import path from 'path';
-import fs from 'fs';
-
-const require = createRequire(import.meta.url);
-const sharp = require('sharp');
-
-const __dirname = path.dirname(fileURLToPath(import.meta.url));
-const root = path.resolve(__dirname, '..');
-
-// Source = trimmed logo mark (transparent background).
-const markSrc = path.join(root, 'image', 'sparo-logo-mark.png');
-// Brand app icon background.
-const BG = { r: 26, g: 26, b: 26 };
-
-// Padding ratio (fraction of icon size used as inner padding on each side).
-// Smaller padding → mark fills more of the icon. Adaptive: tiny icons need
-// minimal padding so the mark doesn't shrink to an unreadable blob.
-function paddingRatioFor(size) {
- if (size <= 20) return 0.02;
- if (size <= 32) return 0.035;
- if (size <= 48) return 0.05;
- if (size <= 128) return 0.07;
- return 0.085;
-}
-
-// Rounded-rect corner radius (ratio of size).
-function radiusRatioFor(size) {
- if (size <= 20) return 0.20;
- if (size <= 48) return 0.22;
- return 0.225;
-}
-
-// Sharpen strength by size.
-function sharpenFor(size) {
- if (size <= 24) return { sigma: 0.7, m1: 1.4, m2: 2.8 };
- if (size <= 48) return { sigma: 0.8, m1: 1.0, m2: 2.0 };
- if (size <= 128) return { sigma: 0.5, m1: 1.0, m2: 1.5 };
- return { sigma: 0.3, m1: 1.0, m2: 1.0 };
-}
-
-function roundedBackgroundSvg(size) {
- const r = Math.round(size * radiusRatioFor(size));
- const hex = `rgb(${BG.r},${BG.g},${BG.b})`;
- return Buffer.from(
- ``
- );
-}
-
-function roundedMaskSvg(size) {
- const r = Math.round(size * radiusRatioFor(size));
- return Buffer.from(
- ``
- );
-}
-
-/**
- * Build a rounded icon:
- * 1. Render the rounded-rect background from SVG (crisp vector edges).
- * 2. Resize the transparent mark to (size - 2*padding) with high-quality filter.
- * 3. Composite mark at centre.
- * 4. Sharpen gently for small sizes.
- * 5. Apply rounded-rect mask to guarantee clean corners (alpha-cut).
- */
-async function makeRoundedIcon(markBuffer, size) {
- const pad = Math.round(size * paddingRatioFor(size));
- const inner = Math.max(1, size - pad * 2);
-
- const markResized = await sharp(markBuffer)
- .ensureAlpha()
- .resize(inner, inner, {
- fit: 'contain',
- background: { r: 0, g: 0, b: 0, alpha: 0 },
- kernel: sharp.kernel.lanczos3,
- })
- .toBuffer();
-
- const bg = await sharp(roundedBackgroundSvg(size), { density: 384 })
- .resize(size, size)
- .png()
- .toBuffer();
-
- const composited = await sharp(bg)
- .composite([{ input: markResized, top: pad, left: pad }])
- .toBuffer();
-
- const sh = sharpenFor(size);
- return sharp(composited)
- .sharpen({ sigma: sh.sigma, m1: sh.m1, m2: sh.m2 })
- .composite([{ input: roundedMaskSvg(size), blend: 'dest-in' }])
- .png({ compressionLevel: 9 })
- .toBuffer();
-}
-
-// Multi-size ICO writer with PNG frames (PNG-in-ICO, Vista+).
-//
-// Frame order matters a lot on Tauri 2 (up to at least 2.11):
-// tauri-codegen's `new_ico()` only reads `entries()[0]` and uses that single
-// RGBA for the runtime window icon AND the taskbar HICON — every other frame
-// in the ICO is ignored at runtime. So we must put the HIGHEST resolution
-// first; Windows will downsample from 256 to taskbar size (32 / 40 / 48 / 64
-// depending on DPI) using its high-quality filter, which looks far crisper
-// than a pre-baked 32x32 bitmap.
-// bitCount=32 (RGBA) matches stock Tauri output; bitCount=0 makes some
-// Windows icon selection paths treat the frame as low-quality.
-async function writeIco(markBuf, outPath) {
- const icoSizes = [256, 128];
- const pngFrames = await Promise.all(icoSizes.map((s) => makeRoundedIcon(markBuf, s)));
-
- const count = icoSizes.length;
- let dataOffset = 6 + count * 16;
- const header = Buffer.alloc(6);
- header.writeUInt16LE(0, 0);
- header.writeUInt16LE(1, 2);
- header.writeUInt16LE(count, 4);
-
- const entries = icoSizes.map((s, i) => {
- const entry = Buffer.alloc(16);
- entry.writeUInt8(s >= 256 ? 0 : s, 0);
- entry.writeUInt8(s >= 256 ? 0 : s, 1);
- entry.writeUInt8(0, 2);
- entry.writeUInt8(0, 3);
- entry.writeUInt16LE(1, 4); // planes
- entry.writeUInt16LE(32, 6); // bitCount = 32 (RGBA) — matches stock Tauri output
- entry.writeUInt32LE(pngFrames[i].length, 8);
- entry.writeUInt32LE(dataOffset, 12);
- dataOffset += pngFrames[i].length;
- return entry;
- });
-
- fs.writeFileSync(outPath, Buffer.concat([header, ...entries, ...pngFrames]));
-}
-
-async function writeFile(filePath, buf) {
- try {
- fs.writeFileSync(filePath, buf);
- console.log(` ${path.basename(filePath)}`);
- } catch {
- console.warn(` ${path.basename(filePath)} (skipped - file locked)`);
- }
-}
-
-async function generateForDir(iconDir) {
- const markBuf = fs.readFileSync(markSrc);
-
- try {
- await writeIco(markBuf, path.join(iconDir, 'icon.ico'));
- console.log(` icon.ico (rounded, 128-256px)`);
- } catch {
- console.warn(` icon.ico (skipped - file locked)`);
- }
-
- await writeFile(path.join(iconDir, 'icon.png'), await makeRoundedIcon(markBuf, 512));
-
- for (const [name, size] of [
- ['32x32.png', 32],
- ['64x64.png', 64],
- ['128x128.png', 128],
- ['128x128@2x.png', 256],
- ]) {
- await writeFile(path.join(iconDir, name), await makeRoundedIcon(markBuf, size));
- }
-
- for (const [name, size] of [
- ['Square30x30Logo.png', 30],
- ['Square44x44Logo.png', 44],
- ['Square71x71Logo.png', 71],
- ['Square89x89Logo.png', 89],
- ['Square107x107Logo.png', 107],
- ['Square142x142Logo.png', 142],
- ['Square150x150Logo.png', 150],
- ['Square284x284Logo.png', 284],
- ['Square310x310Logo.png', 310],
- ['StoreLogo.png', 50],
- ]) {
- await writeFile(path.join(iconDir, name), await makeRoundedIcon(markBuf, size));
- }
-
- await writeFile(
- path.join(iconDir, 'app-icon-rounded-source.png'),
- await makeRoundedIcon(markBuf, 1024),
- );
-
- const appIconPath = path.join(iconDir, 'sparo-app-icon.png');
- if (fs.existsSync(appIconPath)) {
- await writeFile(appIconPath, await makeRoundedIcon(markBuf, 512));
- }
-
- const iosDir = path.join(iconDir, 'ios');
- if (fs.existsSync(iosDir)) {
- for (const f of fs.readdirSync(iosDir)) {
- if (!f.endsWith('.png')) continue;
- const m = f.match(/(\d+)x\1@(\d+)x/);
- if (m) {
- const size = parseInt(m[1]) * parseInt(m[2]);
- try {
- fs.writeFileSync(path.join(iosDir, f), await makeRoundedIcon(markBuf, size));
- console.log(` ios/${f}`);
- } catch {
- console.warn(` ios/${f} (skipped - file locked)`);
- }
- }
- }
- }
-
- const androidDir = path.join(iconDir, 'android');
- if (fs.existsSync(androidDir)) {
- const sizeMap = { 'mipmap-mdpi': 48, 'mipmap-hdpi': 72, 'mipmap-xhdpi': 96, 'mipmap-xxhdpi': 144, 'mipmap-xxxhdpi': 192 };
- for (const [folder, size] of Object.entries(sizeMap)) {
- const dir = path.join(androidDir, folder);
- if (!fs.existsSync(dir)) continue;
- for (const f of fs.readdirSync(dir)) {
- if (!f.endsWith('.png')) continue;
- await writeFile(path.join(dir, f), await makeRoundedIcon(markBuf, size));
- }
- }
- }
-
- const hicolorDir = path.join(iconDir, 'hicolor');
- if (fs.existsSync(hicolorDir)) {
- for (const sizeFolder of fs.readdirSync(hicolorDir)) {
- const appsDir = path.join(hicolorDir, sizeFolder, 'apps');
- if (!fs.existsSync(appsDir)) continue;
- const size = parseInt(sizeFolder);
- if (!size) continue;
- const oldFile = path.join(appsDir, 'sparo-desktop.png');
- const newFile = path.join(appsDir, 'sparo-os.png');
- if (fs.existsSync(oldFile) && !fs.existsSync(newFile)) {
- fs.renameSync(oldFile, newFile);
- }
- for (const f of fs.readdirSync(appsDir)) {
- if (!f.endsWith('.png')) continue;
- await writeFile(path.join(appsDir, f), await makeRoundedIcon(markBuf, size));
- }
- }
- }
-}
-
-async function run() {
- const targets = [
- path.join(root, 'src', 'apps', 'desktop', 'icons'),
- path.join(root, 'installer', 'src-tauri', 'icons'),
- ];
- for (const dir of targets) {
- console.log(`\n[${dir}]`);
- await generateForDir(dir);
- }
- console.log('\nAll rounded icons generated successfully.');
-}
-
-run().catch((err) => { console.error(err); process.exit(1); });
diff --git a/scripts/generate-mobile-web-icons.mjs b/scripts/generate-mobile-web-icons.mjs
deleted file mode 100644
index 4cc81678..00000000
--- a/scripts/generate-mobile-web-icons.mjs
+++ /dev/null
@@ -1,61 +0,0 @@
-/**
- * Sync mobile-remote Web branding from repository `image/` sources:
- * - Rounded favicons from image/sparo-app-icon-rounded.png (home-screen / tab icon)
- * - Logo mark from image/sparo-logo-mark.png → bundled assets
- */
-import { createRequire } from 'module';
-import { fileURLToPath } from 'url';
-import path from 'path';
-import fs from 'fs';
-
-const require = createRequire(import.meta.url);
-const sharp = require('sharp');
-
-const __dirname = path.dirname(fileURLToPath(import.meta.url));
-const root = path.resolve(__dirname, '..');
-const imageDir = path.join(root, 'image');
-const srcMark = fs.readFileSync(path.join(imageDir, 'sparo-app-icon-rounded.png'));
-const logoMark = 'sparo-logo-mark.png';
-const publicDir = path.join(root, 'src', 'mobile-web', 'public');
-const assetsDir = path.join(root, 'src', 'mobile-web', 'src', 'assets');
-
-function roundedMask(size, ratio = 0.225) {
- const r = Math.round(size * ratio);
- return Buffer.from(
- ``
- );
-}
-
-async function makeRounded(size) {
- const resized = await sharp(srcMark).resize(size, size, { fit: 'cover', position: 'centre' }).toBuffer();
- return sharp(resized).composite([{ input: roundedMask(size), blend: 'dest-in' }]).png().toBuffer();
-}
-
-function copyLogoMark() {
- if (!fs.existsSync(assetsDir)) {
- fs.mkdirSync(assetsDir, { recursive: true });
- }
- const from = path.join(imageDir, logoMark);
- if (!fs.existsSync(from)) {
- console.warn(`skip missing logo mark: ${from}`);
- return;
- }
- fs.copyFileSync(from, path.join(assetsDir, logoMark));
- console.log(`copied ${logoMark} → mobile-web src/assets`);
-}
-
-async function run() {
- fs.writeFileSync(path.join(publicDir, 'favicon.png'), await makeRounded(32));
- console.log('wrote favicon.png (32x32 rounded)');
-
- fs.writeFileSync(path.join(publicDir, 'apple-touch-icon.png'), await makeRounded(180));
- console.log('wrote apple-touch-icon.png (180x180 rounded)');
-
- copyLogoMark();
-
- console.log('Done.');
-}
-
-run().catch((e) => { console.error(e); process.exit(1); });
diff --git a/scripts/generate-rounded-app-icon.mjs b/scripts/generate-rounded-app-icon.mjs
deleted file mode 100644
index 462018a6..00000000
--- a/scripts/generate-rounded-app-icon.mjs
+++ /dev/null
@@ -1,31 +0,0 @@
-import sharp from "sharp";
-
-const input = process.argv[2] ?? "png/logo-dark.png";
-const output = process.argv[3] ?? "src/apps/desktop/icons/app-icon-rounded-source.png";
-const logoOutput = process.argv[4] ?? "src/apps/desktop/icons/sparo-app-icon.png";
-const hicolorRoot = "src/apps/desktop/icons/hicolor";
-
-const size = 1024;
-const radius = Math.round(size * 0.22);
-const roundedRect = Buffer.from(
- ``,
-);
-
-const roundedIcon = await sharp(input)
- .resize(size, size, { fit: "cover", position: "center" })
- .ensureAlpha()
- .composite([{ input: roundedRect, blend: "dest-in" }])
- .png()
- .toBuffer();
-
-await sharp(roundedIcon).toFile(output);
-await sharp(roundedIcon).resize(512, 512).png().toFile(logoOutput);
-
-for (const iconSize of [16, 32, 48, 64, 96, 128, 256, 512]) {
- await sharp(roundedIcon)
- .resize(iconSize, iconSize)
- .png()
- .toFile(`${hicolorRoot}/${iconSize}x${iconSize}/apps/sparo-os.png`);
-}
diff --git a/scripts/mobile-web-build.cjs b/scripts/mobile-web-build.cjs
index 20aa5d3d..552670be 100644
--- a/scripts/mobile-web-build.cjs
+++ b/scripts/mobile-web-build.cjs
@@ -105,9 +105,9 @@ function buildMobileWeb(options = {}) {
cleanStaleMobileWebResources(logInfo);
- const brandSync = runSilent('node scripts/generate-mobile-web-icons.mjs', ROOT_DIR);
+ const brandSync = runSilent('node scripts/sync-brand-assets.mjs --target mobile', ROOT_DIR);
if (!brandSync.ok) {
- logError('mobile-web brand sync failed (scripts/generate-mobile-web-icons.mjs)');
+ logError('mobile-web brand sync failed (scripts/sync-brand-assets.mjs)');
const output = tailOutput(brandSync.stderr || brandSync.stdout);
if (output) logError(output);
return { ok: false };
diff --git a/scripts/sync-brand-assets.mjs b/scripts/sync-brand-assets.mjs
new file mode 100644
index 00000000..92eca99c
--- /dev/null
+++ b/scripts/sync-brand-assets.mjs
@@ -0,0 +1,397 @@
+import { spawnSync } from 'node:child_process';
+import { createHash } from 'node:crypto';
+import { existsSync } from 'node:fs';
+import {
+ copyFile,
+ mkdir,
+ mkdtemp,
+ readFile,
+ readdir,
+ rm,
+ rmdir,
+ stat,
+ writeFile,
+} from 'node:fs/promises';
+import path from 'node:path';
+import { fileURLToPath } from 'node:url';
+
+import sharp from 'sharp';
+
+import {
+ brandAssetCopies,
+ legacyBrandAssets,
+ legacyBrandDirectories,
+ linuxHicolorSizes,
+ platformIconTargets,
+} from './brand-assets.config.mjs';
+import { checkBrandAssets, generateBrandAssets } from './generate-brand-assets.mjs';
+
+const REPO_ROOT = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
+const BRAND_ROOT = path.join(REPO_ROOT, 'assets', 'brand');
+const ADOPTION_MANIFEST = path.join(BRAND_ROOT, 'adoption-manifest.json');
+const CONFIG_PATH = path.join(REPO_ROOT, 'scripts', 'brand-assets.config.mjs');
+const APP_ICON_SOURCE = path.join(BRAND_ROOT, 'exports', 'app-icon', 'sparo-app-icon-1024.png');
+const APP_ICON_OPAQUE_BACKGROUND = '#F5F2EE';
+const TAURI_CLI = path.join(REPO_ROOT, 'node_modules', '@tauri-apps', 'cli', 'tauri.js');
+
+function repoPath(relativePath) {
+ return path.join(REPO_ROOT, relativePath);
+}
+
+function brandPath(relativePath) {
+ return path.join(BRAND_ROOT, relativePath);
+}
+
+function normalized(relativePath) {
+ return relativePath.replace(/\\/g, '/');
+}
+
+function sha256(value) {
+ return createHash('sha256').update(value).digest('hex');
+}
+
+function sourceForAppIconSize(size) {
+ if (size <= 20) return brandPath('exports/app-icon/sparo-app-icon-16.png');
+ if (size <= 28) return brandPath('exports/app-icon/sparo-app-icon-24.png');
+ if (size <= 40) return brandPath('exports/app-icon/sparo-app-icon-32.png');
+ if (size < 64) return brandPath('exports/app-icon/sparo-app-icon-48.png');
+ if (size === 64) return brandPath('exports/app-icon/sparo-app-icon-64.png');
+ return APP_ICON_SOURCE;
+}
+
+async function renderAppIcon(size, { opaque = false } = {}) {
+ let pipeline = sharp(await readFile(sourceForAppIconSize(size)))
+ .resize(size, size, { fit: 'contain' });
+ if (opaque) pipeline = pipeline.flatten({ background: APP_ICON_OPAQUE_BACKGROUND });
+ return pipeline.png({ compressionLevel: 9, adaptiveFiltering: false }).toBuffer();
+}
+
+async function writeFileWithRetry(destination, value) {
+ const maximumAttempts = process.platform === 'win32' ? 5 : 1;
+ for (let attempt = 1; attempt <= maximumAttempts; attempt += 1) {
+ try {
+ await writeFile(destination, value);
+ return;
+ } catch (error) {
+ if (attempt === maximumAttempts) throw error;
+ await new Promise((resolve) => setTimeout(resolve, attempt * 100));
+ }
+ }
+}
+
+async function writeRasterIcon(destination, size, options) {
+ await mkdir(path.dirname(destination), { recursive: true });
+ await writeFileWithRetry(destination, await renderAppIcon(size, options));
+}
+
+async function walkFiles(directory) {
+ if (!existsSync(directory)) return [];
+ const result = [];
+ for (const entry of await readdir(directory, { withFileTypes: true })) {
+ const entryPath = path.join(directory, entry.name);
+ if (entry.isDirectory()) {
+ result.push(...await walkFiles(entryPath));
+ } else if (entry.isFile()) {
+ result.push(entryPath);
+ }
+ }
+ return result;
+}
+
+async function writeResponsiveIco(destination) {
+ // Tauri 2 uses the first ICO frame for its runtime window icon. A 64 px
+ // compact-master frame is the best compromise for common 32-64 px taskbar
+ // sizes; the remaining frames let Explorer choose an exact representation.
+ const sizes = [64, 256, 128, 48, 32, 24, 16];
+ const frames = await Promise.all(sizes.map((size) => renderAppIcon(size)));
+ const header = Buffer.alloc(6);
+ header.writeUInt16LE(0, 0);
+ header.writeUInt16LE(1, 2);
+ header.writeUInt16LE(sizes.length, 4);
+
+ let dataOffset = 6 + sizes.length * 16;
+ const entries = frames.map((frame, index) => {
+ const size = sizes[index];
+ const entry = Buffer.alloc(16);
+ entry.writeUInt8(size >= 256 ? 0 : size, 0);
+ entry.writeUInt8(size >= 256 ? 0 : size, 1);
+ entry.writeUInt8(0, 2);
+ entry.writeUInt8(0, 3);
+ entry.writeUInt16LE(1, 4);
+ entry.writeUInt16LE(32, 6);
+ entry.writeUInt32LE(frame.length, 8);
+ entry.writeUInt32LE(dataOffset, 12);
+ dataOffset += frame.length;
+ return entry;
+ });
+
+ await writeFileWithRetry(destination, Buffer.concat([header, ...entries, ...frames]));
+}
+
+async function overwriteTauriRasterSet(iconDirectory) {
+ const rootRasterSizes = new Map([
+ ['32x32.png', 32],
+ ['64x64.png', 64],
+ ['128x128.png', 128],
+ ['128x128@2x.png', 256],
+ ['icon.png', 512],
+ ['Square30x30Logo.png', 30],
+ ['Square44x44Logo.png', 44],
+ ['Square71x71Logo.png', 71],
+ ['Square89x89Logo.png', 89],
+ ['Square107x107Logo.png', 107],
+ ['Square142x142Logo.png', 142],
+ ['Square150x150Logo.png', 150],
+ ['Square284x284Logo.png', 284],
+ ['Square310x310Logo.png', 310],
+ ['StoreLogo.png', 50],
+ ]);
+
+ for (const [fileName, size] of rootRasterSizes) {
+ await writeRasterIcon(path.join(iconDirectory, fileName), size);
+ }
+
+ for (const platform of ['android', 'ios']) {
+ const platformDirectory = path.join(iconDirectory, platform);
+ for (const filePath of await walkFiles(platformDirectory)) {
+ if (path.extname(filePath).toLowerCase() !== '.png') continue;
+ const metadata = await sharp(filePath).metadata();
+ if (!metadata.width || metadata.width !== metadata.height) {
+ throw new Error('Expected a square platform icon: ' + filePath);
+ }
+ await writeRasterIcon(filePath, metadata.width, { opaque: true });
+ }
+ }
+
+ await writeResponsiveIco(path.join(iconDirectory, 'icon.ico'));
+}
+
+function runTauriIcon(outputDirectory) {
+ const maximumAttempts = process.platform === 'win32' ? 3 : 1;
+ for (let attempt = 1; attempt <= maximumAttempts; attempt += 1) {
+ const result = spawnSync(
+ process.execPath,
+ [TAURI_CLI, 'icon', APP_ICON_SOURCE, '--output', outputDirectory, '--ios-color', APP_ICON_OPAQUE_BACKGROUND],
+ { cwd: REPO_ROOT, stdio: 'inherit' },
+ );
+ if (result.status === 0) return;
+ if (attempt < maximumAttempts) {
+ console.warn(
+ 'Tauri platform icon generation failed; retrying (' +
+ attempt +
+ '/' +
+ maximumAttempts +
+ '): ' +
+ outputDirectory,
+ );
+ }
+ }
+ throw new Error('Tauri platform icon generation failed for ' + outputDirectory);
+}
+
+async function generatePlatformIcons() {
+ if (!existsSync(TAURI_CLI)) {
+ throw new Error('Tauri CLI is unavailable. Run pnpm install before pnpm run brand:sync.');
+ }
+
+ for (const relativeTarget of platformIconTargets) {
+ const target = repoPath(relativeTarget);
+ await mkdir(target, { recursive: true });
+ const temporaryOutput = await mkdtemp(path.join(BRAND_ROOT, '.platform-icons-'));
+ try {
+ // Generate into a fresh directory so Windows file mappings on an
+ // installed/current icon cannot interrupt the Tauri CLI halfway through.
+ runTauriIcon(temporaryOutput);
+ for (const generatedFile of await walkFiles(temporaryOutput)) {
+ const relativeFile = path.relative(temporaryOutput, generatedFile);
+ const destination = path.join(target, relativeFile);
+ await mkdir(path.dirname(destination), { recursive: true });
+ await writeFileWithRetry(destination, await readFile(generatedFile));
+ }
+ await overwriteTauriRasterSet(target);
+ } finally {
+ await rm(temporaryOutput, { force: true, recursive: true });
+ }
+ }
+
+ const hicolorRoot = repoPath('src/apps/desktop/icons/hicolor');
+ for (const size of linuxHicolorSizes) {
+ await writeRasterIcon(
+ path.join(hicolorRoot, `${size}x${size}`, 'apps', 'sparo-os.png'),
+ size,
+ );
+ }
+}
+
+async function syncCopies(groups) {
+ const selected = groups.size === 0
+ ? brandAssetCopies
+ : brandAssetCopies.filter((entry) => groups.has(entry.group));
+
+ if (groups.size > 0 && selected.length === 0) {
+ throw new Error('Unknown brand sync target: ' + [...groups].join(', '));
+ }
+
+ for (const entry of selected) {
+ const source = brandPath(entry.source);
+ const target = repoPath(entry.target);
+ await mkdir(path.dirname(target), { recursive: true });
+ await copyFile(source, target);
+ }
+
+ return selected.length;
+}
+
+async function removeLegacyAssets() {
+ for (const relativePath of legacyBrandAssets) {
+ await rm(repoPath(relativePath), { force: true });
+ }
+ for (const relativePath of legacyBrandDirectories) {
+ try {
+ await rmdir(repoPath(relativePath));
+ } catch (error) {
+ if (error?.code !== 'ENOENT' && error?.code !== 'ENOTEMPTY') throw error;
+ }
+ }
+}
+
+async function managedPlatformFiles() {
+ const files = [];
+ for (const relativeTarget of platformIconTargets) {
+ const target = repoPath(relativeTarget);
+ for (const filePath of await walkFiles(target)) {
+ const relative = normalized(path.relative(REPO_ROOT, filePath));
+ if (relative.includes('/tray/')) continue;
+ files.push(relative);
+ }
+ }
+ return files.sort();
+}
+
+async function manifestEntry(relativePath) {
+ const value = await readFile(repoPath(relativePath));
+ return { path: normalized(relativePath), bytes: value.length, sha256: sha256(value) };
+}
+
+async function writeAdoptionManifest() {
+ const sourceManifest = await readFile(brandPath('manifest.json'));
+ const config = await readFile(CONFIG_PATH);
+ const managedPaths = new Set([
+ ...brandAssetCopies.map((entry) => normalized(entry.target)),
+ ...await managedPlatformFiles(),
+ ]);
+ const files = [];
+ for (const relativePath of [...managedPaths].sort()) {
+ files.push(await manifestEntry(relativePath));
+ }
+
+ const manifest = {
+ schemaVersion: 1,
+ generatedBy: 'pnpm run brand:sync',
+ sourceManifestSha256: sha256(sourceManifest),
+ configSha256: sha256(config),
+ files,
+ };
+ await writeFile(ADOPTION_MANIFEST, JSON.stringify(manifest, null, 2) + '\n');
+}
+
+export async function checkProductBrandAssets() {
+ await checkBrandAssets();
+ const failures = [];
+
+ for (const entry of brandAssetCopies) {
+ try {
+ const [source, target] = await Promise.all([
+ readFile(brandPath(entry.source)),
+ readFile(repoPath(entry.target)),
+ ]);
+ if (!source.equals(target)) failures.push(entry.target + ' is stale');
+ } catch {
+ failures.push(entry.target + ' is missing');
+ }
+ }
+
+ for (const relativePath of legacyBrandAssets) {
+ if (existsSync(repoPath(relativePath))) failures.push(relativePath + ' is a legacy asset');
+ }
+
+ try {
+ const [manifestText, sourceManifest, config] = await Promise.all([
+ readFile(ADOPTION_MANIFEST, 'utf8'),
+ readFile(brandPath('manifest.json')),
+ readFile(CONFIG_PATH),
+ ]);
+ const manifest = JSON.parse(manifestText);
+ if (manifest.sourceManifestSha256 !== sha256(sourceManifest)) {
+ failures.push('assets/brand/adoption-manifest.json has a stale source manifest');
+ }
+ if (manifest.configSha256 !== sha256(config)) {
+ failures.push('assets/brand/adoption-manifest.json has a stale target configuration');
+ }
+ for (const entry of manifest.files ?? []) {
+ try {
+ const value = await readFile(repoPath(entry.path));
+ if (value.length !== entry.bytes || sha256(value) !== entry.sha256) {
+ failures.push(entry.path + ' differs from the adoption manifest');
+ }
+ } catch {
+ failures.push(entry.path + ' is missing');
+ }
+ }
+ } catch (error) {
+ failures.push(
+ 'assets/brand/adoption-manifest.json is missing or invalid: ' +
+ (error instanceof Error ? error.message : String(error)),
+ );
+ }
+
+ if (failures.length > 0) {
+ throw new Error(
+ 'Product brand assets are out of sync:\n- ' +
+ failures.join('\n- ') +
+ '\nRun pnpm run brand:sync.',
+ );
+ }
+
+ console.log('Verified ' + brandAssetCopies.length + ' declared brand copies and platform icons.');
+}
+
+export async function syncBrandAssets({ groups = new Set(), full = groups.size === 0 } = {}) {
+ if (full) {
+ await generateBrandAssets();
+ } else {
+ await checkBrandAssets();
+ }
+
+ const copyCount = await syncCopies(groups);
+ if (!full) {
+ console.log('Synchronized ' + copyCount + ' brand assets for ' + [...groups].join(', ') + '.');
+ return;
+ }
+
+ await generatePlatformIcons();
+ await removeLegacyAssets();
+ await writeAdoptionManifest();
+ await checkProductBrandAssets();
+ console.log('Synchronized the current Sparo brand across all declared product targets.');
+}
+
+function selectedGroups(argv) {
+ const groups = new Set();
+ for (let index = 0; index < argv.length; index += 1) {
+ if (argv[index] === '--target' && argv[index + 1]) {
+ groups.add(argv[index + 1]);
+ index += 1;
+ }
+ }
+ return groups;
+}
+
+const isMain = process.argv[1] && path.resolve(process.argv[1]) === fileURLToPath(import.meta.url);
+if (isMain) {
+ const groups = selectedGroups(process.argv.slice(2));
+ syncBrandAssets({ groups }).catch((error) => {
+ console.error(error instanceof Error ? error.message : error);
+ process.exitCode = 1;
+ });
+}
diff --git a/src/apps/desktop/icons/128x128.png b/src/apps/desktop/icons/128x128.png
index fb0343a7..1c7b4e23 100644
Binary files a/src/apps/desktop/icons/128x128.png and b/src/apps/desktop/icons/128x128.png differ
diff --git a/src/apps/desktop/icons/128x128@2x.png b/src/apps/desktop/icons/128x128@2x.png
index b1394ad1..74f18439 100644
Binary files a/src/apps/desktop/icons/128x128@2x.png and b/src/apps/desktop/icons/128x128@2x.png differ
diff --git a/src/apps/desktop/icons/32x32.png b/src/apps/desktop/icons/32x32.png
index 1665dd04..2f5e44f9 100644
Binary files a/src/apps/desktop/icons/32x32.png and b/src/apps/desktop/icons/32x32.png differ
diff --git a/src/apps/desktop/icons/64x64.png b/src/apps/desktop/icons/64x64.png
index 95b475af..5b7a72cc 100644
Binary files a/src/apps/desktop/icons/64x64.png and b/src/apps/desktop/icons/64x64.png differ
diff --git a/src/apps/desktop/icons/Square107x107Logo.png b/src/apps/desktop/icons/Square107x107Logo.png
index 74ea32ee..d5b248a1 100644
Binary files a/src/apps/desktop/icons/Square107x107Logo.png and b/src/apps/desktop/icons/Square107x107Logo.png differ
diff --git a/src/apps/desktop/icons/Square142x142Logo.png b/src/apps/desktop/icons/Square142x142Logo.png
index e4e81f52..e44ff7af 100644
Binary files a/src/apps/desktop/icons/Square142x142Logo.png and b/src/apps/desktop/icons/Square142x142Logo.png differ
diff --git a/src/apps/desktop/icons/Square150x150Logo.png b/src/apps/desktop/icons/Square150x150Logo.png
index 1cb61237..e607c495 100644
Binary files a/src/apps/desktop/icons/Square150x150Logo.png and b/src/apps/desktop/icons/Square150x150Logo.png differ
diff --git a/src/apps/desktop/icons/Square284x284Logo.png b/src/apps/desktop/icons/Square284x284Logo.png
index 1ed1e2b6..d98e7c79 100644
Binary files a/src/apps/desktop/icons/Square284x284Logo.png and b/src/apps/desktop/icons/Square284x284Logo.png differ
diff --git a/src/apps/desktop/icons/Square30x30Logo.png b/src/apps/desktop/icons/Square30x30Logo.png
index dbab0b41..03a76719 100644
Binary files a/src/apps/desktop/icons/Square30x30Logo.png and b/src/apps/desktop/icons/Square30x30Logo.png differ
diff --git a/src/apps/desktop/icons/Square310x310Logo.png b/src/apps/desktop/icons/Square310x310Logo.png
index 7e5b6c42..f4cff6a5 100644
Binary files a/src/apps/desktop/icons/Square310x310Logo.png and b/src/apps/desktop/icons/Square310x310Logo.png differ
diff --git a/src/apps/desktop/icons/Square44x44Logo.png b/src/apps/desktop/icons/Square44x44Logo.png
index f7502bb3..b669621c 100644
Binary files a/src/apps/desktop/icons/Square44x44Logo.png and b/src/apps/desktop/icons/Square44x44Logo.png differ
diff --git a/src/apps/desktop/icons/Square71x71Logo.png b/src/apps/desktop/icons/Square71x71Logo.png
index 97abcb31..8c2261fe 100644
Binary files a/src/apps/desktop/icons/Square71x71Logo.png and b/src/apps/desktop/icons/Square71x71Logo.png differ
diff --git a/src/apps/desktop/icons/Square89x89Logo.png b/src/apps/desktop/icons/Square89x89Logo.png
index e0deaedd..daec8d29 100644
Binary files a/src/apps/desktop/icons/Square89x89Logo.png and b/src/apps/desktop/icons/Square89x89Logo.png differ
diff --git a/src/apps/desktop/icons/StoreLogo.png b/src/apps/desktop/icons/StoreLogo.png
index 749c4216..407dc94f 100644
Binary files a/src/apps/desktop/icons/StoreLogo.png and b/src/apps/desktop/icons/StoreLogo.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher.png b/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher.png
index 458fb127..c7dd6f14 100644
Binary files a/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher.png and b/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_foreground.png b/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_foreground.png
index 458fb127..a177ef41 100644
Binary files a/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_foreground.png and b/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_foreground.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_round.png b/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_round.png
index 458fb127..c7dd6f14 100644
Binary files a/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_round.png and b/src/apps/desktop/icons/android/mipmap-hdpi/ic_launcher_round.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher.png b/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher.png
index b675894d..d6ef9ea9 100644
Binary files a/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher.png and b/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_foreground.png b/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_foreground.png
index b675894d..2a1429ff 100644
Binary files a/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_foreground.png and b/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_foreground.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_round.png b/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_round.png
index b675894d..d6ef9ea9 100644
Binary files a/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_round.png and b/src/apps/desktop/icons/android/mipmap-mdpi/ic_launcher_round.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher.png b/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher.png
index 051bd062..e66ae720 100644
Binary files a/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher.png and b/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_foreground.png b/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_foreground.png
index 051bd062..58f6a024 100644
Binary files a/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_foreground.png and b/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_foreground.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_round.png b/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_round.png
index 051bd062..e66ae720 100644
Binary files a/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_round.png and b/src/apps/desktop/icons/android/mipmap-xhdpi/ic_launcher_round.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher.png b/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher.png
index db6199a8..a8ff2ace 100644
Binary files a/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher.png and b/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png b/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png
index db6199a8..73ab55a0 100644
Binary files a/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png and b/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_round.png b/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_round.png
index db6199a8..a8ff2ace 100644
Binary files a/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_round.png and b/src/apps/desktop/icons/android/mipmap-xxhdpi/ic_launcher_round.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher.png b/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher.png
index df0ac0ff..63a0eaa7 100644
Binary files a/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher.png and b/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png b/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png
index df0ac0ff..8d688951 100644
Binary files a/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png and b/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png differ
diff --git a/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_round.png b/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_round.png
index df0ac0ff..63a0eaa7 100644
Binary files a/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_round.png and b/src/apps/desktop/icons/android/mipmap-xxxhdpi/ic_launcher_round.png differ
diff --git a/src/apps/desktop/icons/android/values/ic_launcher_background.xml b/src/apps/desktop/icons/android/values/ic_launcher_background.xml
index ea9c223a..7938c64e 100644
--- a/src/apps/desktop/icons/android/values/ic_launcher_background.xml
+++ b/src/apps/desktop/icons/android/values/ic_launcher_background.xml
@@ -1,4 +1,4 @@
- #fff
+ #F5F2EE
\ No newline at end of file
diff --git a/src/apps/desktop/icons/app-icon-rounded-source.png b/src/apps/desktop/icons/app-icon-rounded-source.png
deleted file mode 100644
index d5e59ffc..00000000
Binary files a/src/apps/desktop/icons/app-icon-rounded-source.png and /dev/null differ
diff --git a/src/apps/desktop/icons/hicolor/128x128/apps/sparo-os.png b/src/apps/desktop/icons/hicolor/128x128/apps/sparo-os.png
index fb0343a7..1c7b4e23 100644
Binary files a/src/apps/desktop/icons/hicolor/128x128/apps/sparo-os.png and b/src/apps/desktop/icons/hicolor/128x128/apps/sparo-os.png differ
diff --git a/src/apps/desktop/icons/hicolor/16x16/apps/sparo-os.png b/src/apps/desktop/icons/hicolor/16x16/apps/sparo-os.png
index 624879ba..0e7ccb52 100644
Binary files a/src/apps/desktop/icons/hicolor/16x16/apps/sparo-os.png and b/src/apps/desktop/icons/hicolor/16x16/apps/sparo-os.png differ
diff --git a/src/apps/desktop/icons/hicolor/256x256/apps/sparo-os.png b/src/apps/desktop/icons/hicolor/256x256/apps/sparo-os.png
index b1394ad1..74f18439 100644
Binary files a/src/apps/desktop/icons/hicolor/256x256/apps/sparo-os.png and b/src/apps/desktop/icons/hicolor/256x256/apps/sparo-os.png differ
diff --git a/src/apps/desktop/icons/hicolor/32x32/apps/sparo-os.png b/src/apps/desktop/icons/hicolor/32x32/apps/sparo-os.png
index 1665dd04..2f5e44f9 100644
Binary files a/src/apps/desktop/icons/hicolor/32x32/apps/sparo-os.png and b/src/apps/desktop/icons/hicolor/32x32/apps/sparo-os.png differ
diff --git a/src/apps/desktop/icons/hicolor/48x48/apps/sparo-os.png b/src/apps/desktop/icons/hicolor/48x48/apps/sparo-os.png
index 663e6036..3a8be1f4 100644
Binary files a/src/apps/desktop/icons/hicolor/48x48/apps/sparo-os.png and b/src/apps/desktop/icons/hicolor/48x48/apps/sparo-os.png differ
diff --git a/src/apps/desktop/icons/hicolor/512x512/apps/sparo-os.png b/src/apps/desktop/icons/hicolor/512x512/apps/sparo-os.png
index 9e8086ab..2fe045bc 100644
Binary files a/src/apps/desktop/icons/hicolor/512x512/apps/sparo-os.png and b/src/apps/desktop/icons/hicolor/512x512/apps/sparo-os.png differ
diff --git a/src/apps/desktop/icons/hicolor/64x64/apps/sparo-os.png b/src/apps/desktop/icons/hicolor/64x64/apps/sparo-os.png
index 95b475af..5b7a72cc 100644
Binary files a/src/apps/desktop/icons/hicolor/64x64/apps/sparo-os.png and b/src/apps/desktop/icons/hicolor/64x64/apps/sparo-os.png differ
diff --git a/src/apps/desktop/icons/hicolor/96x96/apps/sparo-os.png b/src/apps/desktop/icons/hicolor/96x96/apps/sparo-os.png
index 718bbe4e..2637c320 100644
Binary files a/src/apps/desktop/icons/hicolor/96x96/apps/sparo-os.png and b/src/apps/desktop/icons/hicolor/96x96/apps/sparo-os.png differ
diff --git a/src/apps/desktop/icons/icon.icns b/src/apps/desktop/icons/icon.icns
index f27982aa..8ab3b1ab 100644
Binary files a/src/apps/desktop/icons/icon.icns and b/src/apps/desktop/icons/icon.icns differ
diff --git a/src/apps/desktop/icons/icon.ico b/src/apps/desktop/icons/icon.ico
index feb7c28c..0506188b 100644
Binary files a/src/apps/desktop/icons/icon.ico and b/src/apps/desktop/icons/icon.ico differ
diff --git a/src/apps/desktop/icons/icon.png b/src/apps/desktop/icons/icon.png
index 9e8086ab..2fe045bc 100644
Binary files a/src/apps/desktop/icons/icon.png and b/src/apps/desktop/icons/icon.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-20x20@1x.png b/src/apps/desktop/icons/ios/AppIcon-20x20@1x.png
index 40e733ab..624494b0 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-20x20@1x.png and b/src/apps/desktop/icons/ios/AppIcon-20x20@1x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-20x20@2x-1.png b/src/apps/desktop/icons/ios/AppIcon-20x20@2x-1.png
index bb17d84f..0cfd832a 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-20x20@2x-1.png and b/src/apps/desktop/icons/ios/AppIcon-20x20@2x-1.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-20x20@2x.png b/src/apps/desktop/icons/ios/AppIcon-20x20@2x.png
index bb17d84f..0cfd832a 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-20x20@2x.png and b/src/apps/desktop/icons/ios/AppIcon-20x20@2x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-20x20@3x.png b/src/apps/desktop/icons/ios/AppIcon-20x20@3x.png
index d5816836..77532256 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-20x20@3x.png and b/src/apps/desktop/icons/ios/AppIcon-20x20@3x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-29x29@1x.png b/src/apps/desktop/icons/ios/AppIcon-29x29@1x.png
index 564fbd58..46d013c3 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-29x29@1x.png and b/src/apps/desktop/icons/ios/AppIcon-29x29@1x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-29x29@2x-1.png b/src/apps/desktop/icons/ios/AppIcon-29x29@2x-1.png
index 4f785120..ad6d68a6 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-29x29@2x-1.png and b/src/apps/desktop/icons/ios/AppIcon-29x29@2x-1.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-29x29@2x.png b/src/apps/desktop/icons/ios/AppIcon-29x29@2x.png
index 4f785120..ad6d68a6 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-29x29@2x.png and b/src/apps/desktop/icons/ios/AppIcon-29x29@2x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-29x29@3x.png b/src/apps/desktop/icons/ios/AppIcon-29x29@3x.png
index 5f20be25..77908fd0 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-29x29@3x.png and b/src/apps/desktop/icons/ios/AppIcon-29x29@3x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-40x40@1x.png b/src/apps/desktop/icons/ios/AppIcon-40x40@1x.png
index bb17d84f..0cfd832a 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-40x40@1x.png and b/src/apps/desktop/icons/ios/AppIcon-40x40@1x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-40x40@2x-1.png b/src/apps/desktop/icons/ios/AppIcon-40x40@2x-1.png
index 3a03d8af..d1c893ff 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-40x40@2x-1.png and b/src/apps/desktop/icons/ios/AppIcon-40x40@2x-1.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-40x40@2x.png b/src/apps/desktop/icons/ios/AppIcon-40x40@2x.png
index 3a03d8af..d1c893ff 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-40x40@2x.png and b/src/apps/desktop/icons/ios/AppIcon-40x40@2x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-40x40@3x.png b/src/apps/desktop/icons/ios/AppIcon-40x40@3x.png
index fd414ce0..694cee05 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-40x40@3x.png and b/src/apps/desktop/icons/ios/AppIcon-40x40@3x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-512@2x.png b/src/apps/desktop/icons/ios/AppIcon-512@2x.png
index 39bfb11d..91169e65 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-512@2x.png and b/src/apps/desktop/icons/ios/AppIcon-512@2x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-60x60@2x.png b/src/apps/desktop/icons/ios/AppIcon-60x60@2x.png
index fd414ce0..694cee05 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-60x60@2x.png and b/src/apps/desktop/icons/ios/AppIcon-60x60@2x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-60x60@3x.png b/src/apps/desktop/icons/ios/AppIcon-60x60@3x.png
index 94c2fcad..303b4768 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-60x60@3x.png and b/src/apps/desktop/icons/ios/AppIcon-60x60@3x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-76x76@1x.png b/src/apps/desktop/icons/ios/AppIcon-76x76@1x.png
index ed316487..caed8331 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-76x76@1x.png and b/src/apps/desktop/icons/ios/AppIcon-76x76@1x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-76x76@2x.png b/src/apps/desktop/icons/ios/AppIcon-76x76@2x.png
index 2673175d..3b241b54 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-76x76@2x.png and b/src/apps/desktop/icons/ios/AppIcon-76x76@2x.png differ
diff --git a/src/apps/desktop/icons/ios/AppIcon-83.5x83.5@2x.png b/src/apps/desktop/icons/ios/AppIcon-83.5x83.5@2x.png
index d69b34de..7bb7efe5 100644
Binary files a/src/apps/desktop/icons/ios/AppIcon-83.5x83.5@2x.png and b/src/apps/desktop/icons/ios/AppIcon-83.5x83.5@2x.png differ
diff --git a/src/apps/desktop/icons/sparo-app-icon.png b/src/apps/desktop/icons/sparo-app-icon.png
deleted file mode 100644
index 9e8086ab..00000000
Binary files a/src/apps/desktop/icons/sparo-app-icon.png and /dev/null differ
diff --git a/src/apps/desktop/icons/tray/tray-error.png b/src/apps/desktop/icons/tray/tray-error.png
index 20fefb19..38183031 100644
Binary files a/src/apps/desktop/icons/tray/tray-error.png and b/src/apps/desktop/icons/tray/tray-error.png differ
diff --git a/src/apps/desktop/icons/tray/tray-idle.png b/src/apps/desktop/icons/tray/tray-idle.png
index 4f2d3fb8..2f5e44f9 100644
Binary files a/src/apps/desktop/icons/tray/tray-idle.png and b/src/apps/desktop/icons/tray/tray-idle.png differ
diff --git a/src/apps/desktop/icons/tray/tray-running.png b/src/apps/desktop/icons/tray/tray-running.png
index 3684381d..c7751275 100644
Binary files a/src/apps/desktop/icons/tray/tray-running.png and b/src/apps/desktop/icons/tray/tray-running.png differ
diff --git a/src/apps/desktop/icons/tray/tray-waiting.png b/src/apps/desktop/icons/tray/tray-waiting.png
index df6b872d..8860bfe9 100644
Binary files a/src/apps/desktop/icons/tray/tray-waiting.png and b/src/apps/desktop/icons/tray/tray-waiting.png differ
diff --git a/src/apps/desktop/src/tray/mod.rs b/src/apps/desktop/src/tray/mod.rs
index 60d9a1a4..f9ccbf93 100644
--- a/src/apps/desktop/src/tray/mod.rs
+++ b/src/apps/desktop/src/tray/mod.rs
@@ -162,7 +162,8 @@ pub fn init_tray(app: &AppHandle) -> Result<(), Box> {
TrayIconBuilder::with_id("sparo-main")
.icon(icon)
- .icon_as_template(cfg!(target_os = "macos"))
+ // Runtime state is encoded by the mark's single solid color on every OS.
+ .icon_as_template(false)
.tooltip("Sparo OS")
.show_menu_on_left_click(false)
.menu(&initial_menu)
diff --git a/src/apps/relay-server/static/apple-touch-icon.png b/src/apps/relay-server/static/apple-touch-icon.png
deleted file mode 100644
index 18ab438b..00000000
Binary files a/src/apps/relay-server/static/apple-touch-icon.png and /dev/null differ
diff --git a/src/apps/relay-server/static/assets/index-BnwLOzZ9.js b/src/apps/relay-server/static/assets/index-CSpvm6tT.js
similarity index 85%
rename from src/apps/relay-server/static/assets/index-BnwLOzZ9.js
rename to src/apps/relay-server/static/assets/index-CSpvm6tT.js
index b209e0f5..d42c0566 100644
--- a/src/apps/relay-server/static/assets/index-BnwLOzZ9.js
+++ b/src/apps/relay-server/static/assets/index-CSpvm6tT.js
@@ -6,43 +6,43 @@
`).replace(EN,"")}function Ji(r,a,s){if(a=yb(a),yb(r)!==a&&s)throw Error(n(425))}function eo(){}var Xs=null,Qs=null;function Js(r,a){return r==="textarea"||r==="noscript"||typeof a.children=="string"||typeof a.children=="number"||typeof a.dangerouslySetInnerHTML=="object"&&a.dangerouslySetInnerHTML!==null&&a.dangerouslySetInnerHTML.__html!=null}var el=typeof setTimeout=="function"?setTimeout:void 0,SN=typeof clearTimeout=="function"?clearTimeout:void 0,Eb=typeof Promise=="function"?Promise:void 0,vN=typeof queueMicrotask=="function"?queueMicrotask:typeof Eb<"u"?function(r){return Eb.resolve(null).then(r).catch(kN)}:el;function kN(r){setTimeout(function(){throw r})}function tl(r,a){var s=a,d=0;do{var b=s.nextSibling;if(r.removeChild(s),b&&b.nodeType===8)if(s=b.data,s==="/$"){if(d===0){r.removeChild(b),Ba(a);return}d--}else s!=="$"&&s!=="$?"&&s!=="$!"||d++;s=b}while(s);Ba(a)}function dr(r){for(;r!=null;r=r.nextSibling){var a=r.nodeType;if(a===1||a===3)break;if(a===8){if(a=r.data,a==="$"||a==="$!"||a==="$?")break;if(a==="/$")return null}}return r}function Sb(r){r=r.previousSibling;for(var a=0;r;){if(r.nodeType===8){var s=r.data;if(s==="$"||s==="$!"||s==="$?"){if(a===0)return r;a--}else s==="/$"&&a++}r=r.previousSibling}return null}var ra=Math.random().toString(36).slice(2),Dn="__reactFiber$"+ra,Za="__reactProps$"+ra,qn="__reactContainer$"+ra,nl="__reactEvents$"+ra,_N="__reactListeners$"+ra,wN="__reactHandles$"+ra;function Nr(r){var a=r[Dn];if(a)return a;for(var s=r.parentNode;s;){if(a=s[qn]||s[Dn]){if(s=a.alternate,a.child!==null||s!==null&&s.child!==null)for(r=Sb(r);r!==null;){if(s=r[Dn])return s;r=Sb(r)}return a}r=s,s=r.parentNode}return null}function Xa(r){return r=r[Dn]||r[qn],!r||r.tag!==5&&r.tag!==6&&r.tag!==13&&r.tag!==3?null:r}function aa(r){if(r.tag===5||r.tag===6)return r.stateNode;throw Error(n(33))}function to(r){return r[Za]||null}var rl=[],ia=-1;function pr(r){return{current:r}}function Xe(r){0>ia||(r.current=rl[ia],rl[ia]=null,ia--)}function Ve(r,a){ia++,rl[ia]=r.current,r.current=a}var fr={},Pt=pr(fr),Kt=pr(!1),Cr=fr;function oa(r,a){var s=r.type.contextTypes;if(!s)return fr;var d=r.stateNode;if(d&&d.__reactInternalMemoizedUnmaskedChildContext===a)return d.__reactInternalMemoizedMaskedChildContext;var b={},y;for(y in s)b[y]=a[y];return d&&(r=r.stateNode,r.__reactInternalMemoizedUnmaskedChildContext=a,r.__reactInternalMemoizedMaskedChildContext=b),b}function Zt(r){return r=r.childContextTypes,r!=null}function no(){Xe(Kt),Xe(Pt)}function vb(r,a,s){if(Pt.current!==fr)throw Error(n(168));Ve(Pt,a),Ve(Kt,s)}function kb(r,a,s){var d=r.stateNode;if(a=a.childContextTypes,typeof d.getChildContext!="function")return s;d=d.getChildContext();for(var b in d)if(!(b in a))throw Error(n(108,Se(r)||"Unknown",b));return x({},s,d)}function ro(r){return r=(r=r.stateNode)&&r.__reactInternalMemoizedMergedChildContext||fr,Cr=Pt.current,Ve(Pt,r),Ve(Kt,Kt.current),!0}function _b(r,a,s){var d=r.stateNode;if(!d)throw Error(n(169));s?(r=kb(r,a,Cr),d.__reactInternalMemoizedMergedChildContext=r,Xe(Kt),Xe(Pt),Ve(Pt,r)):Xe(Kt),Ve(Kt,s)}var Gn=null,ao=!1,al=!1;function wb(r){Gn===null?Gn=[r]:Gn.push(r)}function TN(r){ao=!0,wb(r)}function gr(){if(!al&&Gn!==null){al=!0;var r=0,a=qe;try{var s=Gn;for(qe=1;r>=_,b-=_,Hn=1<<32-wn(a)+b|s<Ae?(Nt=Te,Te=null):Nt=Te.sibling;var je=re(z,Te,G[Ae],ce);if(je===null){Te===null&&(Te=Nt);break}r&&Te&&je.alternate===null&&a(z,Te),U=y(je,U,Ae),we===null?ve=je:we.sibling=je,we=je,Te=Nt}if(Ae===G.length)return s(z,Te),et&&Or(z,Ae),ve;if(Te===null){for(;AeAe?(Nt=Te,Te=null):Nt=Te.sibling;var _r=re(z,Te,je.value,ce);if(_r===null){Te===null&&(Te=Nt);break}r&&Te&&_r.alternate===null&&a(z,Te),U=y(_r,U,Ae),we===null?ve=_r:we.sibling=_r,we=_r,Te=Nt}if(je.done)return s(z,Te),et&&Or(z,Ae),ve;if(Te===null){for(;!je.done;Ae++,je=G.next())je=oe(z,je.value,ce),je!==null&&(U=y(je,U,Ae),we===null?ve=je:we.sibling=je,we=je);return et&&Or(z,Ae),ve}for(Te=d(z,Te);!je.done;Ae++,je=G.next())je=me(Te,z,Ae,je.value,ce),je!==null&&(r&&je.alternate!==null&&Te.delete(je.key===null?Ae:je.key),U=y(je,U,Ae),we===null?ve=je:we.sibling=je,we=je);return r&&Te.forEach(function(iC){return a(z,iC)}),et&&Or(z,Ae),ve}function ht(z,U,G,ce){if(typeof G=="object"&&G!==null&&G.type===B&&G.key===null&&(G=G.props.children),typeof G=="object"&&G!==null){switch(G.$$typeof){case L:e:{for(var ve=G.key,we=U;we!==null;){if(we.key===ve){if(ve=G.type,ve===B){if(we.tag===7){s(z,we.sibling),U=b(we,G.props.children),U.return=z,z=U;break e}}else if(we.elementType===ve||typeof ve=="object"&&ve!==null&&ve.$$typeof===te&&Cb(ve)===we.type){s(z,we.sibling),U=b(we,G.props),U.ref=Qa(z,we,G),U.return=z,z=U;break e}s(z,we);break}else a(z,we);we=we.sibling}G.type===B?(U=jr(G.props.children,z.mode,ce,G.key),U.return=z,z=U):(ce=Lo(G.type,G.key,G.props,null,z.mode,ce),ce.ref=Qa(z,U,G),ce.return=z,z=ce)}return _(z);case w:e:{for(we=G.key;U!==null;){if(U.key===we)if(U.tag===4&&U.stateNode.containerInfo===G.containerInfo&&U.stateNode.implementation===G.implementation){s(z,U.sibling),U=b(U,G.children||[]),U.return=z,z=U;break e}else{s(z,U);break}else a(z,U);U=U.sibling}U=tu(G,z.mode,ce),U.return=z,z=U}return _(z);case te:return we=G._init,ht(z,U,we(G._payload),ce)}if(kt(G))return ye(z,U,G,ce);if(Q(G))return Ee(z,U,G,ce);lo(z,G)}return typeof G=="string"&&G!==""||typeof G=="number"?(G=""+G,U!==null&&U.tag===6?(s(z,U.sibling),U=b(U,G),U.return=z,z=U):(s(z,U),U=eu(G,z.mode,ce),U.return=z,z=U),_(z)):s(z,U)}return ht}var ca=Ib(!0),Ob=Ib(!1),uo=pr(null),co=null,da=null,cl=null;function dl(){cl=da=co=null}function pl(r){var a=uo.current;Xe(uo),r._currentValue=a}function fl(r,a,s){for(;r!==null;){var d=r.alternate;if((r.childLanes&a)!==a?(r.childLanes|=a,d!==null&&(d.childLanes|=a)):d!==null&&(d.childLanes&a)!==a&&(d.childLanes|=a),r===s)break;r=r.return}}function pa(r,a){co=r,cl=da=null,r=r.dependencies,r!==null&&r.firstContext!==null&&((r.lanes&a)!==0&&(Xt=!0),r.firstContext=null)}function gn(r){var a=r._currentValue;if(cl!==r)if(r={context:r,memoizedValue:a,next:null},da===null){if(co===null)throw Error(n(308));da=r,co.dependencies={lanes:0,firstContext:r}}else da=da.next=r;return a}var Lr=null;function gl(r){Lr===null?Lr=[r]:Lr.push(r)}function Lb(r,a,s,d){var b=a.interleaved;return b===null?(s.next=s,gl(a)):(s.next=b.next,b.next=s),a.interleaved=s,Vn(r,d)}function Vn(r,a){r.lanes|=a;var s=r.alternate;for(s!==null&&(s.lanes|=a),s=r,r=r.return;r!==null;)r.childLanes|=a,s=r.alternate,s!==null&&(s.childLanes|=a),s=r,r=r.return;return s.tag===3?s.stateNode:null}var mr=!1;function ml(r){r.updateQueue={baseState:r.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Db(r,a){r=r.updateQueue,a.updateQueue===r&&(a.updateQueue={baseState:r.baseState,firstBaseUpdate:r.firstBaseUpdate,lastBaseUpdate:r.lastBaseUpdate,shared:r.shared,effects:r.effects})}function Yn(r,a){return{eventTime:r,lane:a,tag:0,payload:null,callback:null,next:null}}function hr(r,a,s){var d=r.updateQueue;if(d===null)return null;if(d=d.shared,(Ue&2)!==0){var b=d.pending;return b===null?a.next=a:(a.next=b.next,b.next=a),d.pending=a,Vn(r,s)}return b=d.interleaved,b===null?(a.next=a,gl(d)):(a.next=b.next,b.next=a),d.interleaved=a,Vn(r,s)}function po(r,a,s){if(a=a.updateQueue,a!==null&&(a=a.shared,(s&4194240)!==0)){var d=a.lanes;d&=r.pendingLanes,s|=d,a.lanes=s,Ns(r,s)}}function Mb(r,a){var s=r.updateQueue,d=r.alternate;if(d!==null&&(d=d.updateQueue,s===d)){var b=null,y=null;if(s=s.firstBaseUpdate,s!==null){do{var _={eventTime:s.eventTime,lane:s.lane,tag:s.tag,payload:s.payload,callback:s.callback,next:null};y===null?b=y=_:y=y.next=_,s=s.next}while(s!==null);y===null?b=y=a:y=y.next=a}else b=y=a;s={baseState:d.baseState,firstBaseUpdate:b,lastBaseUpdate:y,shared:d.shared,effects:d.effects},r.updateQueue=s;return}r=s.lastBaseUpdate,r===null?s.firstBaseUpdate=a:r.next=a,s.lastBaseUpdate=a}function fo(r,a,s,d){var b=r.updateQueue;mr=!1;var y=b.firstBaseUpdate,_=b.lastBaseUpdate,I=b.shared.pending;if(I!==null){b.shared.pending=null;var F=I,V=F.next;F.next=null,_===null?y=V:_.next=V,_=F;var ie=r.alternate;ie!==null&&(ie=ie.updateQueue,I=ie.lastBaseUpdate,I!==_&&(I===null?ie.firstBaseUpdate=V:I.next=V,ie.lastBaseUpdate=F))}if(y!==null){var oe=b.baseState;_=0,ie=V=F=null,I=y;do{var re=I.lane,me=I.eventTime;if((d&re)===re){ie!==null&&(ie=ie.next={eventTime:me,lane:0,tag:I.tag,payload:I.payload,callback:I.callback,next:null});e:{var ye=r,Ee=I;switch(re=a,me=s,Ee.tag){case 1:if(ye=Ee.payload,typeof ye=="function"){oe=ye.call(me,oe,re);break e}oe=ye;break e;case 3:ye.flags=ye.flags&-65537|128;case 0:if(ye=Ee.payload,re=typeof ye=="function"?ye.call(me,oe,re):ye,re==null)break e;oe=x({},oe,re);break e;case 2:mr=!0}}I.callback!==null&&I.lane!==0&&(r.flags|=64,re=b.effects,re===null?b.effects=[I]:re.push(I))}else me={eventTime:me,lane:re,tag:I.tag,payload:I.payload,callback:I.callback,next:null},ie===null?(V=ie=me,F=oe):ie=ie.next=me,_|=re;if(I=I.next,I===null){if(I=b.shared.pending,I===null)break;re=I,I=re.next,re.next=null,b.lastBaseUpdate=re,b.shared.pending=null}}while(!0);if(ie===null&&(F=oe),b.baseState=F,b.firstBaseUpdate=V,b.lastBaseUpdate=ie,a=b.shared.interleaved,a!==null){b=a;do _|=b.lane,b=b.next;while(b!==a)}else y===null&&(b.shared.lanes=0);Fr|=_,r.lanes=_,r.memoizedState=oe}}function Fb(r,a,s){if(r=a.effects,a.effects=null,r!==null)for(a=0;as?s:4,r(!0);var d=Sl.transition;Sl.transition={};try{r(!1),a()}finally{qe=s,Sl.transition=d}}function ty(){return mn().memoizedState}function NN(r,a,s){var d=Sr(r);if(s={lane:d,action:s,hasEagerState:!1,eagerState:null,next:null},ny(r))ry(a,s);else if(s=Lb(r,a,s,d),s!==null){var b=Gt();Cn(s,r,d,b),ay(s,a,d)}}function CN(r,a,s){var d=Sr(r),b={lane:d,action:s,hasEagerState:!1,eagerState:null,next:null};if(ny(r))ry(a,b);else{var y=r.alternate;if(r.lanes===0&&(y===null||y.lanes===0)&&(y=a.lastRenderedReducer,y!==null))try{var _=a.lastRenderedState,I=y(_,s);if(b.hasEagerState=!0,b.eagerState=I,Tn(I,_)){var F=a.interleaved;F===null?(b.next=b,gl(a)):(b.next=F.next,F.next=b),a.interleaved=b;return}}catch{}s=Lb(r,a,b,d),s!==null&&(b=Gt(),Cn(s,r,d,b),ay(s,a,d))}}function ny(r){var a=r.alternate;return r===ot||a!==null&&a===ot}function ry(r,a){ni=ho=!0;var s=r.pending;s===null?a.next=a:(a.next=s.next,s.next=a),r.pending=a}function ay(r,a,s){if((s&4194240)!==0){var d=a.lanes;d&=r.pendingLanes,s|=d,a.lanes=s,Ns(r,s)}}var Eo={readContext:gn,useCallback:Ut,useContext:Ut,useEffect:Ut,useImperativeHandle:Ut,useInsertionEffect:Ut,useLayoutEffect:Ut,useMemo:Ut,useReducer:Ut,useRef:Ut,useState:Ut,useDebugValue:Ut,useDeferredValue:Ut,useTransition:Ut,useMutableSource:Ut,useSyncExternalStore:Ut,useId:Ut,unstable_isNewReconciler:!1},IN={readContext:gn,useCallback:function(r,a){return Fn().memoizedState=[r,a===void 0?null:a],r},useContext:gn,useEffect:Vb,useImperativeHandle:function(r,a,s){return s=s!=null?s.concat([r]):null,bo(4194308,4,Zb.bind(null,a,r),s)},useLayoutEffect:function(r,a){return bo(4194308,4,r,a)},useInsertionEffect:function(r,a){return bo(4,2,r,a)},useMemo:function(r,a){var s=Fn();return a=a===void 0?null:a,r=r(),s.memoizedState=[r,a],r},useReducer:function(r,a,s){var d=Fn();return a=s!==void 0?s(a):a,d.memoizedState=d.baseState=a,r={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:r,lastRenderedState:a},d.queue=r,r=r.dispatch=NN.bind(null,ot,r),[d.memoizedState,r]},useRef:function(r){var a=Fn();return r={current:r},a.memoizedState=r},useState:Hb,useDebugValue:Al,useDeferredValue:function(r){return Fn().memoizedState=r},useTransition:function(){var r=Hb(!1),a=r[0];return r=RN.bind(null,r[1]),Fn().memoizedState=r,[a,r]},useMutableSource:function(){},useSyncExternalStore:function(r,a,s){var d=ot,b=Fn();if(et){if(s===void 0)throw Error(n(407));s=s()}else{if(s=a(),Rt===null)throw Error(n(349));(Mr&30)!==0||jb(d,a,s)}b.memoizedState=s;var y={value:s,getSnapshot:a};return b.queue=y,Vb($b.bind(null,d,y,r),[r]),d.flags|=2048,ii(9,zb.bind(null,d,y,s,a),void 0,null),s},useId:function(){var r=Fn(),a=Rt.identifierPrefix;if(et){var s=Wn,d=Hn;s=(d&~(1<<32-wn(d)-1)).toString(32)+s,a=":"+a+"R"+s,s=ri++,0<\/script>",r=r.removeChild(r.firstChild)):typeof d.is=="string"?r=_.createElement(s,{is:d.is}):(r=_.createElement(s),s==="select"&&(_=r,d.multiple?_.multiple=!0:d.size&&(_.size=d.size))):r=_.createElementNS(r,s),r[Dn]=a,r[Za]=d,wy(r,a,!1,!1),a.stateNode=r;e:{switch(_=gt(s,d),s){case"dialog":Ze("cancel",r),Ze("close",r),b=d;break;case"iframe":case"object":case"embed":Ze("load",r),b=d;break;case"video":case"audio":for(b=0;bba&&(a.flags|=128,d=!0,oi(y,!1),a.lanes=4194304)}else{if(!d)if(r=go(_),r!==null){if(a.flags|=128,d=!0,s=r.updateQueue,s!==null&&(a.updateQueue=s,a.flags|=4),oi(y,!0),y.tail===null&&y.tailMode==="hidden"&&!_.alternate&&!et)return Bt(a),null}else 2*mt()-y.renderingStartTime>ba&&s!==1073741824&&(a.flags|=128,d=!0,oi(y,!1),a.lanes=4194304);y.isBackwards?(_.sibling=a.child,a.child=_):(s=y.last,s!==null?s.sibling=_:a.child=_,y.last=_)}return y.tail!==null?(a=y.tail,y.rendering=a,y.tail=a.sibling,y.renderingStartTime=mt(),a.sibling=null,s=it.current,Ve(it,d?s&1|2:s&1),a):(Bt(a),null);case 22:case 23:return Xl(),d=a.memoizedState!==null,r!==null&&r.memoizedState!==null!==d&&(a.flags|=8192),d&&(a.mode&1)!==0?(un&1073741824)!==0&&(Bt(a),a.subtreeFlags&6&&(a.flags|=8192)):Bt(a),null;case 24:return null;case 25:return null}throw Error(n(156,a.tag))}function BN(r,a){switch(ol(a),a.tag){case 1:return Zt(a.type)&&no(),r=a.flags,r&65536?(a.flags=r&-65537|128,a):null;case 3:return fa(),Xe(Kt),Xe(Pt),El(),r=a.flags,(r&65536)!==0&&(r&128)===0?(a.flags=r&-65537|128,a):null;case 5:return bl(a),null;case 13:if(Xe(it),r=a.memoizedState,r!==null&&r.dehydrated!==null){if(a.alternate===null)throw Error(n(340));ua()}return r=a.flags,r&65536?(a.flags=r&-65537|128,a):null;case 19:return Xe(it),null;case 4:return fa(),null;case 10:return pl(a.type._context),null;case 22:case 23:return Xl(),null;case 24:return null;default:return null}}var _o=!1,jt=!1,jN=typeof WeakSet=="function"?WeakSet:Set,be=null;function ma(r,a){var s=r.ref;if(s!==null)if(typeof s=="function")try{s(null)}catch(d){ut(r,a,d)}else s.current=null}function Bl(r,a,s){try{s()}catch(d){ut(r,a,d)}}var Ay=!1;function zN(r,a){if(Xs=$i,r=ib(),qs(r)){if("selectionStart"in r)var s={start:r.selectionStart,end:r.selectionEnd};else e:{s=(s=r.ownerDocument)&&s.defaultView||window;var d=s.getSelection&&s.getSelection();if(d&&d.rangeCount!==0){s=d.anchorNode;var b=d.anchorOffset,y=d.focusNode;d=d.focusOffset;try{s.nodeType,y.nodeType}catch{s=null;break e}var _=0,I=-1,F=-1,V=0,ie=0,oe=r,re=null;t:for(;;){for(var me;oe!==s||b!==0&&oe.nodeType!==3||(I=_+b),oe!==y||d!==0&&oe.nodeType!==3||(F=_+d),oe.nodeType===3&&(_+=oe.nodeValue.length),(me=oe.firstChild)!==null;)re=oe,oe=me;for(;;){if(oe===r)break t;if(re===s&&++V===b&&(I=_),re===y&&++ie===d&&(F=_),(me=oe.nextSibling)!==null)break;oe=re,re=oe.parentNode}oe=me}s=I===-1||F===-1?null:{start:I,end:F}}else s=null}s=s||{start:0,end:0}}else s=null;for(Qs={focusedElem:r,selectionRange:s},$i=!1,be=a;be!==null;)if(a=be,r=a.child,(a.subtreeFlags&1028)!==0&&r!==null)r.return=a,be=r;else for(;be!==null;){a=be;try{var ye=a.alternate;if((a.flags&1024)!==0)switch(a.tag){case 0:case 11:case 15:break;case 1:if(ye!==null){var Ee=ye.memoizedProps,ht=ye.memoizedState,z=a.stateNode,U=z.getSnapshotBeforeUpdate(a.elementType===a.type?Ee:An(a.type,Ee),ht);z.__reactInternalSnapshotBeforeUpdate=U}break;case 3:var G=a.stateNode.containerInfo;G.nodeType===1?G.textContent="":G.nodeType===9&&G.documentElement&&G.removeChild(G.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(ce){ut(a,a.return,ce)}if(r=a.sibling,r!==null){r.return=a.return,be=r;break}be=a.return}return ye=Ay,Ay=!1,ye}function si(r,a,s){var d=a.updateQueue;if(d=d!==null?d.lastEffect:null,d!==null){var b=d=d.next;do{if((b.tag&r)===r){var y=b.destroy;b.destroy=void 0,y!==void 0&&Bl(a,s,y)}b=b.next}while(b!==d)}}function wo(r,a){if(a=a.updateQueue,a=a!==null?a.lastEffect:null,a!==null){var s=a=a.next;do{if((s.tag&r)===r){var d=s.create;s.destroy=d()}s=s.next}while(s!==a)}}function jl(r){var a=r.ref;if(a!==null){var s=r.stateNode;r.tag,r=s,typeof a=="function"?a(r):a.current=r}}function Ry(r){var a=r.alternate;a!==null&&(r.alternate=null,Ry(a)),r.child=null,r.deletions=null,r.sibling=null,r.tag===5&&(a=r.stateNode,a!==null&&(delete a[Dn],delete a[Za],delete a[nl],delete a[_N],delete a[wN])),r.stateNode=null,r.return=null,r.dependencies=null,r.memoizedProps=null,r.memoizedState=null,r.pendingProps=null,r.stateNode=null,r.updateQueue=null}function Ny(r){return r.tag===5||r.tag===3||r.tag===4}function Cy(r){e:for(;;){for(;r.sibling===null;){if(r.return===null||Ny(r.return))return null;r=r.return}for(r.sibling.return=r.return,r=r.sibling;r.tag!==5&&r.tag!==6&&r.tag!==18;){if(r.flags&2||r.child===null||r.tag===4)continue e;r.child.return=r,r=r.child}if(!(r.flags&2))return r.stateNode}}function zl(r,a,s){var d=r.tag;if(d===5||d===6)r=r.stateNode,a?s.nodeType===8?s.parentNode.insertBefore(r,a):s.insertBefore(r,a):(s.nodeType===8?(a=s.parentNode,a.insertBefore(r,s)):(a=s,a.appendChild(r)),s=s._reactRootContainer,s!=null||a.onclick!==null||(a.onclick=eo));else if(d!==4&&(r=r.child,r!==null))for(zl(r,a,s),r=r.sibling;r!==null;)zl(r,a,s),r=r.sibling}function $l(r,a,s){var d=r.tag;if(d===5||d===6)r=r.stateNode,a?s.insertBefore(r,a):s.appendChild(r);else if(d!==4&&(r=r.child,r!==null))for($l(r,a,s),r=r.sibling;r!==null;)$l(r,a,s),r=r.sibling}var Ot=null,Rn=!1;function br(r,a,s){for(s=s.child;s!==null;)Iy(r,a,s),s=s.sibling}function Iy(r,a,s){if(Ln&&typeof Ln.onCommitFiberUnmount=="function")try{Ln.onCommitFiberUnmount(Fi,s)}catch{}switch(s.tag){case 5:jt||ma(s,a);case 6:var d=Ot,b=Rn;Ot=null,br(r,a,s),Ot=d,Rn=b,Ot!==null&&(Rn?(r=Ot,s=s.stateNode,r.nodeType===8?r.parentNode.removeChild(s):r.removeChild(s)):Ot.removeChild(s.stateNode));break;case 18:Ot!==null&&(Rn?(r=Ot,s=s.stateNode,r.nodeType===8?tl(r.parentNode,s):r.nodeType===1&&tl(r,s),Ba(r)):tl(Ot,s.stateNode));break;case 4:d=Ot,b=Rn,Ot=s.stateNode.containerInfo,Rn=!0,br(r,a,s),Ot=d,Rn=b;break;case 0:case 11:case 14:case 15:if(!jt&&(d=s.updateQueue,d!==null&&(d=d.lastEffect,d!==null))){b=d=d.next;do{var y=b,_=y.destroy;y=y.tag,_!==void 0&&((y&2)!==0||(y&4)!==0)&&Bl(s,a,_),b=b.next}while(b!==d)}br(r,a,s);break;case 1:if(!jt&&(ma(s,a),d=s.stateNode,typeof d.componentWillUnmount=="function"))try{d.props=s.memoizedProps,d.state=s.memoizedState,d.componentWillUnmount()}catch(I){ut(s,a,I)}br(r,a,s);break;case 21:br(r,a,s);break;case 22:s.mode&1?(jt=(d=jt)||s.memoizedState!==null,br(r,a,s),jt=d):br(r,a,s);break;default:br(r,a,s)}}function Oy(r){var a=r.updateQueue;if(a!==null){r.updateQueue=null;var s=r.stateNode;s===null&&(s=r.stateNode=new jN),a.forEach(function(d){var b=ZN.bind(null,r,d);s.has(d)||(s.add(d),d.then(b,b))})}}function Nn(r,a){var s=a.deletions;if(s!==null)for(var d=0;db&&(b=_),d&=~y}if(d=b,d=mt()-d,d=(120>d?120:480>d?480:1080>d?1080:1920>d?1920:3e3>d?3e3:4320>d?4320:1960*qN(d/1960))-d,10r?16:r,Er===null)var d=!1;else{if(r=Er,Er=null,No=0,(Ue&6)!==0)throw Error(n(331));var b=Ue;for(Ue|=4,be=r.current;be!==null;){var y=be,_=y.child;if((be.flags&16)!==0){var I=y.deletions;if(I!==null){for(var F=0;Fmt()-Hl?Ur(r,0):Gl|=s),Jt(r,a)}function Hy(r,a){a===0&&((r.mode&1)===0?a=1:(a=Ui,Ui<<=1,(Ui&130023424)===0&&(Ui=4194304)));var s=Gt();r=Vn(r,a),r!==null&&(Da(r,a,s),Jt(r,s))}function KN(r){var a=r.memoizedState,s=0;a!==null&&(s=a.retryLane),Hy(r,s)}function ZN(r,a){var s=0;switch(r.tag){case 13:var d=r.stateNode,b=r.memoizedState;b!==null&&(s=b.retryLane);break;case 19:d=r.stateNode;break;default:throw Error(n(314))}d!==null&&d.delete(a),Hy(r,s)}var Wy;Wy=function(r,a,s){if(r!==null)if(r.memoizedProps!==a.pendingProps||Kt.current)Xt=!0;else{if((r.lanes&s)===0&&(a.flags&128)===0)return Xt=!1,PN(r,a,s);Xt=(r.flags&131072)!==0}else Xt=!1,et&&(a.flags&1048576)!==0&&Tb(a,oo,a.index);switch(a.lanes=0,a.tag){case 2:var d=a.type;ko(r,a),r=a.pendingProps;var b=oa(a,Pt.current);pa(a,s),b=kl(null,a,d,r,b,s);var y=_l();return a.flags|=1,typeof b=="object"&&b!==null&&typeof b.render=="function"&&b.$$typeof===void 0?(a.tag=1,a.memoizedState=null,a.updateQueue=null,Zt(d)?(y=!0,ro(a)):y=!1,a.memoizedState=b.state!==null&&b.state!==void 0?b.state:null,ml(a),b.updater=So,a.stateNode=b,b._reactInternals=a,Nl(a,d,r,s),a=Ll(null,a,d,!0,y,s)):(a.tag=0,et&&y&&il(a),qt(null,a,b,s),a=a.child),a;case 16:d=a.elementType;e:{switch(ko(r,a),r=a.pendingProps,b=d._init,d=b(d._payload),a.type=d,b=a.tag=QN(d),r=An(d,r),b){case 0:a=Ol(null,a,d,r,s);break e;case 1:a=yy(null,a,d,r,s);break e;case 11:a=fy(null,a,d,r,s);break e;case 14:a=gy(null,a,d,An(d.type,r),s);break e}throw Error(n(306,d,""))}return a;case 0:return d=a.type,b=a.pendingProps,b=a.elementType===d?b:An(d,b),Ol(r,a,d,b,s);case 1:return d=a.type,b=a.pendingProps,b=a.elementType===d?b:An(d,b),yy(r,a,d,b,s);case 3:e:{if(Ey(a),r===null)throw Error(n(387));d=a.pendingProps,y=a.memoizedState,b=y.element,Db(r,a),fo(a,d,null,s);var _=a.memoizedState;if(d=_.element,y.isDehydrated)if(y={element:d,isDehydrated:!1,cache:_.cache,pendingSuspenseBoundaries:_.pendingSuspenseBoundaries,transitions:_.transitions},a.updateQueue.baseState=y,a.memoizedState=y,a.flags&256){b=ga(Error(n(423)),a),a=Sy(r,a,d,s,b);break e}else if(d!==b){b=ga(Error(n(424)),a),a=Sy(r,a,d,s,b);break e}else for(ln=dr(a.stateNode.containerInfo.firstChild),sn=a,et=!0,xn=null,s=Ob(a,null,d,s),a.child=s;s;)s.flags=s.flags&-3|4096,s=s.sibling;else{if(ua(),d===b){a=Kn(r,a,s);break e}qt(r,a,d,s)}a=a.child}return a;case 5:return Pb(a),r===null&&ll(a),d=a.type,b=a.pendingProps,y=r!==null?r.memoizedProps:null,_=b.children,Js(d,b)?_=null:y!==null&&Js(d,y)&&(a.flags|=32),by(r,a),qt(r,a,_,s),a.child;case 6:return r===null&&ll(a),null;case 13:return vy(r,a,s);case 4:return hl(a,a.stateNode.containerInfo),d=a.pendingProps,r===null?a.child=ca(a,null,d,s):qt(r,a,d,s),a.child;case 11:return d=a.type,b=a.pendingProps,b=a.elementType===d?b:An(d,b),fy(r,a,d,b,s);case 7:return qt(r,a,a.pendingProps,s),a.child;case 8:return qt(r,a,a.pendingProps.children,s),a.child;case 12:return qt(r,a,a.pendingProps.children,s),a.child;case 10:e:{if(d=a.type._context,b=a.pendingProps,y=a.memoizedProps,_=b.value,Ve(uo,d._currentValue),d._currentValue=_,y!==null)if(Tn(y.value,_)){if(y.children===b.children&&!Kt.current){a=Kn(r,a,s);break e}}else for(y=a.child,y!==null&&(y.return=a);y!==null;){var I=y.dependencies;if(I!==null){_=y.child;for(var F=I.firstContext;F!==null;){if(F.context===d){if(y.tag===1){F=Yn(-1,s&-s),F.tag=2;var V=y.updateQueue;if(V!==null){V=V.shared;var ie=V.pending;ie===null?F.next=F:(F.next=ie.next,ie.next=F),V.pending=F}}y.lanes|=s,F=y.alternate,F!==null&&(F.lanes|=s),fl(y.return,s,a),I.lanes|=s;break}F=F.next}}else if(y.tag===10)_=y.type===a.type?null:y.child;else if(y.tag===18){if(_=y.return,_===null)throw Error(n(341));_.lanes|=s,I=_.alternate,I!==null&&(I.lanes|=s),fl(_,s,a),_=y.sibling}else _=y.child;if(_!==null)_.return=y;else for(_=y;_!==null;){if(_===a){_=null;break}if(y=_.sibling,y!==null){y.return=_.return,_=y;break}_=_.return}y=_}qt(r,a,b.children,s),a=a.child}return a;case 9:return b=a.type,d=a.pendingProps.children,pa(a,s),b=gn(b),d=d(b),a.flags|=1,qt(r,a,d,s),a.child;case 14:return d=a.type,b=An(d,a.pendingProps),b=An(d.type,b),gy(r,a,d,b,s);case 15:return my(r,a,a.type,a.pendingProps,s);case 17:return d=a.type,b=a.pendingProps,b=a.elementType===d?b:An(d,b),ko(r,a),a.tag=1,Zt(d)?(r=!0,ro(a)):r=!1,pa(a,s),oy(a,d,b),Nl(a,d,b,s),Ll(null,a,d,!0,r,s);case 19:return _y(r,a,s);case 22:return hy(r,a,s)}throw Error(n(156,a.tag))};function Vy(r,a){return xh(r,a)}function XN(r,a,s,d){this.tag=r,this.key=s,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=d,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function bn(r,a,s,d){return new XN(r,a,s,d)}function Jl(r){return r=r.prototype,!(!r||!r.isReactComponent)}function QN(r){if(typeof r=="function")return Jl(r)?1:0;if(r!=null){if(r=r.$$typeof,r===J)return 11;if(r===H)return 14}return 2}function kr(r,a){var s=r.alternate;return s===null?(s=bn(r.tag,a,r.key,r.mode),s.elementType=r.elementType,s.type=r.type,s.stateNode=r.stateNode,s.alternate=r,r.alternate=s):(s.pendingProps=a,s.type=r.type,s.flags=0,s.subtreeFlags=0,s.deletions=null),s.flags=r.flags&14680064,s.childLanes=r.childLanes,s.lanes=r.lanes,s.child=r.child,s.memoizedProps=r.memoizedProps,s.memoizedState=r.memoizedState,s.updateQueue=r.updateQueue,a=r.dependencies,s.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext},s.sibling=r.sibling,s.index=r.index,s.ref=r.ref,s}function Lo(r,a,s,d,b,y){var _=2;if(d=r,typeof r=="function")Jl(r)&&(_=1);else if(typeof r=="string")_=5;else e:switch(r){case B:return jr(s.children,b,y,a);case W:_=8,b|=8;break;case j:return r=bn(12,s,a,b|2),r.elementType=j,r.lanes=y,r;case de:return r=bn(13,s,a,b),r.elementType=de,r.lanes=y,r;case Z:return r=bn(19,s,a,b),r.elementType=Z,r.lanes=y,r;case ue:return Do(s,b,y,a);default:if(typeof r=="object"&&r!==null)switch(r.$$typeof){case M:_=10;break e;case Y:_=9;break e;case J:_=11;break e;case H:_=14;break e;case te:_=16,d=null;break e}throw Error(n(130,r==null?r:typeof r,""))}return a=bn(_,s,a,b),a.elementType=r,a.type=d,a.lanes=y,a}function jr(r,a,s,d){return r=bn(7,r,d,a),r.lanes=s,r}function Do(r,a,s,d){return r=bn(22,r,d,a),r.elementType=ue,r.lanes=s,r.stateNode={isHidden:!1},r}function eu(r,a,s){return r=bn(6,r,null,a),r.lanes=s,r}function tu(r,a,s){return a=bn(4,r.children!==null?r.children:[],r.key,a),a.lanes=s,a.stateNode={containerInfo:r.containerInfo,pendingChildren:null,implementation:r.implementation},a}function JN(r,a,s,d,b){this.tag=a,this.containerInfo=r,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Rs(0),this.expirationTimes=Rs(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Rs(0),this.identifierPrefix=d,this.onRecoverableError=b,this.mutableSourceEagerHydrationData=null}function nu(r,a,s,d,b,y,_,I,F){return r=new JN(r,a,s,I,F),a===1?(a=1,y===!0&&(a|=8)):a=0,y=bn(3,null,null,a),r.current=y,y.stateNode=r,y.memoizedState={element:d,isDehydrated:s,cache:null,transitions:null,pendingSuspenseBoundaries:null},ml(y),r}function eC(r,a,s){var d=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),lu.exports=dC(),lu.exports}var sE;function fC(){if(sE)return zo;sE=1;var e=pC();return zo.createRoot=e.createRoot,zo.hydrateRoot=e.hydrateRoot,zo}var gC=fC();const mC=Ni(gC),qm="en-US",lE={"en-US":{common:{appName:"Sparo OS",slogan:"Ignite AI for Everyone",back:"Back",continue:"Continue",cancel:"Cancel",switch:"Switch",workspace:"Workspace",userId:"User ID",loading:"Loading...",language:"Language",switchLanguage:"Switch language",toggleTheme:"Toggle theme",attachImage:"Attach image",stop:"Stop",submit:"Submit",submitting:"Submitting...",submitted:"Submitted",other:"Other",customTextInput:"Custom text input",typeYourAnswer:"Type your answer...",itemCount:"{count} items",justNow:"just now",minutesAgo:"{count}m ago",hoursAgo:"{count}h ago",daysAgo:"{count}d ago"},pairing:{enterUserIdToContinue:"Enter your user ID to continue",connectingAndPairing:"Connecting and pairing...",pairedLoadingSessions:"Paired! Loading sessions...",connectionError:"Connection error",invalidQrCode:"Invalid QR code: missing room or public key",userIdRequired:"User ID is required",tooManyAttempts:"Too many failed attempts. Try again in {seconds}s.",pairingFailed:"Pairing failed",fieldLabel:"User ID",placeholder:"Enter a user ID",note:"The first successful connection binds this URL to your user ID for the current remote session.",connecting:"Connecting...",retryIn:"Retry in {seconds}s",continue:"Continue"},sessions:{remoteCockpit:"Remote cockpit",workspace:"Workspace",switchWorkspace:"Switch workspace",selectWorkspace:"Select Workspace",noWorkspaces:"No workspaces found",noWorkspaceSelected:"No workspace selected",launch:"Launch",startRemoteFlow:"Start a new remote flow",codeSession:"Code Session",codeSessionDesc:"For coding anywhere, anytime.",coworkSession:"Cowork Session",coworkSessionDesc:"For assisting with everyday work.",recent:"Recent",sessionHistory:"Session history",loadingSessions:"Loading sessions...",noSessions:"No sessions yet. Create one to get started.",untitledSession:"Untitled Session",loadingMore:"Loading more...",remoteCodeSession:"Remote Code Session",remoteCoworkSession:"Remote Cowork Session",agentBitFunCoder:"BitFun Coder",agentCowork:"Cowork",agentDesign:"Design",agentDeepResearch:"Deep Research",appBuilder:"App Builder",agentAgenticOs:"Sparo OS",agentDefault:"Default",agentBitFunCoderDesc:"AI coding and engineering tasks",agentCoworkDesc:"Collaborative assistant for daily work",agentDesignDesc:"Visual design with AI-powered canvas",agentDeepResearchDesc:"In-depth research and analysis",appBuilderDesc:"Build and preview Product Apps",pullToRefresh:"Pull to refresh",agentView:"Agent",manualView:"Manual",active:"Active",history:"History",newSession:"New Session",deleteSession:"Delete",renameSession:"Rename",confirmDelete:"Delete this session?",confirmDeleteDesc:"This action cannot be undone.",agenticOsSession:"Sparo OS"},tasks:{title:"Tasks",noActiveSessions:"No active sessions.",noRecentSessions:"No recent sessions."},apps:{title:"Apps",skills:"Skills",skillsDesc:"Manage and run built-in skills",memory:"Memory",memoryDesc:"View and manage agent memory",shell:"Shell",shellDesc:"View agent terminal sessions",settings:"Settings",settingsDesc:"Appearance, language, and account",comingSoon:"Coming soon",manageOnDesktop:"Manage on desktop",manageOnDesktopDesc:"This feature is available in the desktop app."},me:{title:"Me",workspace:"Workspace",switchWorkspace:"Switch Workspace",copyPath:"Copy Path",preferences:"Preferences",appearance:"Appearance",language:"Language",debugLogs:"Debug Logs",account:"Account",userId:"User ID",deviceId:"Device",signOut:"Sign Out",signOutConfirm:"Sign out from this remote session?",signOutDesc:"You will need to scan the QR code again to reconnect.",followSystem:"Follow System",light:"Light",dark:"Dark"},search:{title:"Search",placeholder:"Search sessions, workspaces...",sessions:"Sessions",workspaces:"Workspaces",noResults:"No results found."},topbar:{openMenu:"Open menu",tasks:"Tasks",apps:"Apps",backToOS:"Back to Sparo OS"},workspace:{title:"Workspace",loadingInfo:"Loading workspace info...",selectedWorkspace:"Selected Workspace",unknownProject:"Unknown Project",noWorkspaceOpen:"No workspace is currently open on the desktop.",noWorkspaceHint:"Select a recent workspace below, or open one on the desktop first.",selectWorkspace:"Select Workspace",recentWorkspaces:"Recent Workspaces",noRecentWorkspaces:"No recent workspaces found. Please open a workspace on the desktop first.",failedToSetWorkspace:"Failed to set workspace",openingWorkspace:"Opening workspace..."},chat:{session:"Session",loadingOlderMessages:"Loading older messages...",showResponse:"Show response",hideResponse:"Hide response",analyzingImage:"Analyzing image with image understanding model...",inputPlaceholder:"How can I help you...",collapsedInputPlaceholder:"Ask Sparo OS...",workingPlaceholder:"Sparo OS is working...",streamingTapToQueue:"Assistant is replying — tap to type a follow-up (queued)",collapsedStreamingPlaceholder:"Replying...",messageQueued:"Message queued; it will run after the current step",imageAnalyzingPlaceholder:"Analyzing image...",imageAttachmentFallback:"(see attached images)",modelSelection:"Select model",modelPrimary:"Primary Model",modelFast:"Fast Model",modelNotConfigured:"Model not configured",askQuestionCount:"{count} question{suffix}",waiting:"Waiting",modeBitFunCoder:"BitFun Coder",modePlan:"Plan",modeDebug:"Debug",modeTeam:"Team",thinking:"Thinking...",allTasksCompleted:"All tasks completed",task:"Task",toolCalls:"{count} tool call{suffix}",done:"{count} done",running:"{count} running",thoughtCharacters:"Thought {count} characters",textCharacters:"Text {count} characters",readToolsDone:"{summary}",readToolsRunning:"{summary} ({doneCount} done)",fileLoading:"Loading...",fileUnavailable:"File unavailable",fileDownloading:"Downloading...",fileDownloaded:"Downloaded",clickToDownload:"Click to download"},tools:{explore:"Explore",read:"Read",write:"Write",ls:"LS",shell:"Shell",glob:"Glob",grep:"Grep",delete:"Delete",task:"Task",search:"Search",edit:"Edit",web:"Web",todo:"Todo"}},"zh-CN":{common:{appName:"Sparo OS",slogan:"点亮每个人的 AI 火种",back:"返回",continue:"继续",cancel:"取消",switch:"切换",workspace:"工作区",userId:"用户 ID",loading:"加载中...",language:"语言",switchLanguage:"切换语言",toggleTheme:"切换主题",attachImage:"添加图片",stop:"停止",submit:"提交",submitting:"提交中...",submitted:"已提交",other:"其他",customTextInput:"自定义输入",typeYourAnswer:"请输入你的回答...",itemCount:"{count} 项",justNow:"刚刚",minutesAgo:"{count} 分钟前",hoursAgo:"{count} 小时前",daysAgo:"{count} 天前"},pairing:{enterUserIdToContinue:"请输入你的用户 ID 继续",connectingAndPairing:"正在连接并配对...",pairedLoadingSessions:"配对成功,正在加载会话...",connectionError:"连接异常",invalidQrCode:"二维码无效:缺少 room 或 public key",userIdRequired:"用户 ID 不能为空",tooManyAttempts:"失败次数过多,请在 {seconds} 秒后重试。",pairingFailed:"配对失败",fieldLabel:"用户 ID",placeholder:"请输入用户 ID",note:"首次成功连接后,本次远程会话会把该 URL 绑定到你的用户 ID。",connecting:"连接中...",retryIn:"{seconds} 秒后重试",continue:"继续"},sessions:{remoteCockpit:"Remote cockpit",workspace:"工作区",switchWorkspace:"切换工作区",selectWorkspace:"选择工作区",noWorkspaces:"暂无工作区",noWorkspaceSelected:"未选择工作区",launch:"启动",startRemoteFlow:"开始一个新的远程流程",codeSession:"代码会话",codeSessionDesc:"随时随地进行编码。",coworkSession:"协作会话",coworkSessionDesc:"处理日常协作与办公任务。",recent:"最近",sessionHistory:"会话历史",loadingSessions:"正在加载会话...",noSessions:"还没有会话,先创建一个开始吧。",untitledSession:"未命名会话",loadingMore:"正在加载更多...",remoteCodeSession:"远程代码会话",remoteCoworkSession:"远程协作会话",agentBitFunCoder:"BitFun Coder",agentCowork:"Cowork",agentDesign:"设计",agentDeepResearch:"深度研究",appBuilder:"App Builder",agentAgenticOs:"Sparo OS",agentDefault:"默认",agentBitFunCoderDesc:"AI 编码和工程任务",agentCoworkDesc:"日常工作协作助理",agentDesignDesc:"AI 视觉设计画布",agentDeepResearchDesc:"深度研究与分析",appBuilderDesc:"构建并预览 Product App",pullToRefresh:"下拉刷新",agentView:"Agent",manualView:"手动",active:"进行中",history:"历史",newSession:"新会话",deleteSession:"删除",renameSession:"重命名",confirmDelete:"删除此会话?",confirmDeleteDesc:"此操作不可撤销。",agenticOsSession:"Sparo OS"},tasks:{title:"任务",noActiveSessions:"暂无进行中的会话。",noRecentSessions:"暂无历史会话。"},apps:{title:"应用",skills:"技能库",skillsDesc:"管理和运行内置技能",memory:"记忆",memoryDesc:"查看和管理 agent 记忆",shell:"终端",shellDesc:"查看 agent 终端会话",settings:"设置",settingsDesc:"外观、语言与账户",comingSoon:"即将开放",manageOnDesktop:"请在桌面端管理",manageOnDesktopDesc:"此功能在桌面应用中可用。"},me:{title:"我",workspace:"工作区",switchWorkspace:"切换工作区",copyPath:"复制路径",preferences:"偏好设置",appearance:"外观",language:"语言",debugLogs:"调试日志",account:"账户",userId:"用户 ID",deviceId:"设备",signOut:"退出登录",signOutConfirm:"退出此远程会话?",signOutDesc:"退出后需要重新扫码才能重新连接。",followSystem:"跟随系统",light:"浅色",dark:"深色"},search:{title:"搜索",placeholder:"搜索会话、工作区...",sessions:"会话",workspaces:"工作区",noResults:"没有找到相关结果。"},topbar:{openMenu:"打开菜单",tasks:"任务",apps:"应用",backToOS:"返回 Sparo OS"},workspace:{title:"工作区",loadingInfo:"正在加载工作区信息...",selectedWorkspace:"所选工作区",unknownProject:"未知项目",noWorkspaceOpen:"桌面端当前没有打开工作区。",noWorkspaceHint:"你可以在下方选择最近工作区,或先在桌面端打开一个工作区。",selectWorkspace:"选择工作区",recentWorkspaces:"最近工作区",noRecentWorkspaces:"没有找到最近工作区,请先在桌面端打开一个工作区。",failedToSetWorkspace:"设置工作区失败",openingWorkspace:"正在打开工作区..."},chat:{session:"会话",loadingOlderMessages:"正在加载更早的消息...",showResponse:"Show response",hideResponse:"Hide response",analyzingImage:"正在使用图像理解模型分析图片...",inputPlaceholder:"有什么可以帮您...",collapsedInputPlaceholder:"发消息...",workingPlaceholder:"Sparo OS 正在处理中...",streamingTapToQueue:"助手正在回复 — 点击输入后续消息(将排队)",collapsedStreamingPlaceholder:"正在回复...",messageQueued:"已加入队列,将在当前步骤结束后处理",imageAnalyzingPlaceholder:"正在分析图片...",imageAttachmentFallback:"(见附带图片)",modelSelection:"选择模型",modelPrimary:"Primary 模型",modelFast:"Fast 模型",modelNotConfigured:"模型未配置",askQuestionCount:"{count} 个问题",waiting:"等待中",modeBitFunCoder:"BitFun Coder",modePlan:"Plan",modeDebug:"Debug",modeTeam:"Team",thinking:"思考中...",allTasksCompleted:"所有任务已完成",task:"任务",toolCalls:"{count} 次工具调用",done:"已完成 {count}",running:"运行中 {count}",thoughtCharacters:"思考 {count} 个字符",textCharacters:"文本 {count} 个字符",readToolsDone:"{summary}",readToolsRunning:"{summary}(已完成 {doneCount})",fileLoading:"加载中...",fileUnavailable:"文件不可用",fileDownloading:"下载中...",fileDownloaded:"已下载",clickToDownload:"点击下载"},tools:{explore:"探索",read:"读取",write:"写入",ls:"列表",shell:"Shell",glob:"Glob",grep:"Grep",delete:"删除",task:"任务",search:"搜索",edit:"编辑",web:"网络",todo:"待办"}}},mx="sparo-mobile-language";function hx(e){return e==="zh-CN"||e==="en-US"}function uE(e,t){const n=t.split(".");let i=e;for(const o of n){if(!i||typeof i!="object"||!(o in i))return null;i=i[o]}return typeof i=="string"?i:null}function hC(e,t){return t?e.replace(/\{(\w+)\}/g,(n,i)=>{const o=t[i];return o==null?"":String(o)}):e}function bC(e,t,n){const i=uE(lE[e],t)??uE(lE[qm],t)??t;return hC(i,n)}function yC(){try{const n=localStorage.getItem(mx);if(hx(n))return n}catch{}const e=EC();return e||((navigator.language?.toLowerCase()||"").startsWith("zh")?"zh-CN":qm)}function EC(){const e=[];try{e.push(new URLSearchParams(window.location.search).get("lang"))}catch{}const t=window.location.hash||"",n=t.indexOf("?");if(n>=0)try{const i=t.slice(n+1);e.push(new URLSearchParams(i).get("lang"))}catch{}for(const i of e)if(hx(i))return i;return null}const bx=P.createContext({language:qm,setLanguage:()=>{},toggleLanguage:()=>{},t:e=>e}),SC=({children:e})=>{const[t,n]=P.useState(yC);P.useLayoutEffect(()=>{document.documentElement.lang=t;try{localStorage.setItem(mx,t)}catch{}},[t]);const i=P.useCallback(u=>{n(u)},[]),o=P.useCallback(()=>{n(u=>u==="zh-CN"?"en-US":"zh-CN")},[]),l=P.useMemo(()=>({language:t,setLanguage:i,toggleLanguage:o,t:(u,c)=>bC(t,u,c)}),[t,i,o]);return g.jsx(bx.Provider,{value:l,children:e})};function dt(){return P.useContext(bx)}const yx={"--ink":"#0F172A","--graphite":"#253044","--slate":"#5B6B8C","--print":"#B7372F","--echo":"#E06B5F","--cloud":"#F8FAFC","--surface":"#FFFFFF","--hairline":"rgba(255, 255, 255, 0.12)","--hairline-soft":"rgba(255, 255, 255, 0.08)","--color-bg-primary":"#0F172A","--color-bg-secondary":"#151E2F","--color-bg-tertiary":"#0F172A","--color-bg-quaternary":"#1C2840","--color-bg-elevated":"#1A2436","--color-bg-workbench":"#0F172A","--color-bg-scene":"#151E2F","--color-bg-flowchat":"#151E2F","--color-bg-tooltip":"rgba(26, 36, 54, 0.96)","--color-text-primary":"rgba(248, 250, 252, 0.92)","--color-text-secondary":"rgba(248, 250, 252, 0.70)","--color-text-muted":"rgba(248, 250, 252, 0.45)","--color-text-disabled":"rgba(248, 250, 252, 0.28)","--element-bg-subtle":"rgba(255, 255, 255, 0.04)","--element-bg-soft":"rgba(255, 255, 255, 0.07)","--element-bg-base":"rgba(255, 255, 255, 0.10)","--element-bg-medium":"rgba(255, 255, 255, 0.14)","--element-bg-strong":"rgba(255, 255, 255, 0.20)","--element-bg-elevated":"rgba(255, 255, 255, 0.08)","--color-accent-50":"rgba(183, 55, 47, 0.06)","--color-accent-100":"rgba(183, 55, 47, 0.12)","--color-accent-200":"rgba(183, 55, 47, 0.20)","--color-accent-300":"rgba(183, 55, 47, 0.32)","--color-accent-400":"rgba(183, 55, 47, 0.50)","--color-accent-500":"#E06B5F","--color-accent-600":"#B7372F","--color-accent-700":"rgba(224, 107, 95, 0.8)","--color-accent-800":"rgba(224, 107, 95, 0.9)","--color-purple-50":"rgba(139, 92, 246, 0.04)","--color-purple-100":"rgba(139, 92, 246, 0.08)","--color-purple-200":"rgba(139, 92, 246, 0.15)","--color-purple-300":"rgba(139, 92, 246, 0.25)","--color-purple-400":"rgba(139, 92, 246, 0.4)","--color-purple-500":"#8b5cf6","--color-purple-600":"#7c3aed","--color-purple-700":"rgba(124, 58, 237, 0.8)","--color-purple-800":"rgba(124, 58, 237, 0.9)","--color-pink-50":"rgba(236, 72, 153, 0.04)","--color-pink-100":"rgba(236, 72, 153, 0.08)","--color-pink-200":"rgba(236, 72, 153, 0.15)","--color-pink-300":"rgba(236, 72, 153, 0.25)","--color-pink-400":"rgba(236, 72, 153, 0.4)","--color-pink-500":"#ec4899","--color-pink-600":"#db2777","--color-pink-700":"rgba(219, 39, 119, 0.8)","--color-pink-800":"rgba(219, 39, 119, 0.9)","--color-orange-50":"rgba(249, 115, 22, 0.04)","--color-orange-100":"rgba(249, 115, 22, 0.08)","--color-orange-200":"rgba(249, 115, 22, 0.15)","--color-orange-300":"rgba(249, 115, 22, 0.25)","--color-orange-400":"rgba(249, 115, 22, 0.4)","--color-orange-500":"#f97316","--color-orange-600":"#ea580c","--color-orange-700":"rgba(234, 88, 12, 0.8)","--color-orange-800":"rgba(234, 88, 12, 0.9)","--color-success":"#4ADE80","--color-success-bg":"rgba(74, 222, 128, 0.10)","--color-success-border":"rgba(74, 222, 128, 0.30)","--color-warning":"#FBBF24","--color-warning-bg":"rgba(251, 191, 36, 0.10)","--color-warning-border":"rgba(251, 191, 36, 0.30)","--color-error":"#E06B5F","--color-error-bg":"rgba(224, 107, 95, 0.12)","--color-error-border":"rgba(224, 107, 95, 0.35)","--color-info":"#60A5FA","--color-info-bg":"rgba(96, 165, 250, 0.10)","--color-info-border":"rgba(96, 165, 250, 0.30)","--color-highlight":"#E06B5F","--color-highlight-bg":"rgba(224, 107, 95, 0.15)","--color-overlay":"rgba(0, 0, 0, 0.55)","--border-subtle":"rgba(255, 255, 255, 0.08)","--border-base":"rgba(255, 255, 255, 0.12)","--border-medium":"rgba(255, 255, 255, 0.20)","--border-strong":"rgba(255, 255, 255, 0.30)","--border-prominent":"rgba(224, 107, 95, 0.50)","--glow-blue":"0 12px 32px rgba(224, 107, 95, 0.20), 0 6px 16px rgba(224, 107, 95, 0.14)","--glow-purple":"0 12px 32px rgba(139, 92, 246, 0.20), 0 6px 16px rgba(124, 58, 237, 0.14)","--glow-orange":"0 12px 32px rgba(249, 115, 22, 0.20), 0 6px 16px rgba(234, 88, 12, 0.14)","--glow-mixed":"0 12px 32px rgba(224, 107, 95, 0.16), 0 6px 16px rgba(139, 92, 246, 0.12)","--shadow-xs":"0 1px 2px rgba(0, 0, 0, 0.5)","--shadow-sm":"0 2px 4px rgba(0, 0, 0, 0.45)","--shadow-base":"0 4px 8px rgba(0, 0, 0, 0.40)","--shadow-lg":"0 8px 16px rgba(0, 0, 0, 0.35)","--shadow-xl":"0 12px 24px rgba(0, 0, 0, 0.30)","--shadow-2xl":"0 16px 32px rgba(0, 0, 0, 0.25)","--blur-subtle":"blur(4px) saturate(1.05)","--blur-base":"blur(8px) saturate(1.1)","--blur-medium":"blur(12px) saturate(1.2)","--blur-strong":"blur(16px) saturate(1.3) brightness(1.1)","--blur-intense":"blur(20px) saturate(1.4) brightness(1.15)","--size-radius-sm":"6px","--size-radius-base":"8px","--size-radius-lg":"12px","--size-radius-xl":"16px","--size-radius-2xl":"20px","--size-radius-full":"9999px","--size-gap-1":"4px","--size-gap-2":"8px","--size-gap-3":"12px","--size-gap-4":"16px","--size-gap-5":"20px","--size-gap-6":"24px","--size-gap-8":"32px","--size-gap-10":"40px","--size-gap-12":"48px","--size-gap-16":"64px","--motion-instant":"0.1s","--motion-fast":"0.15s","--motion-base":"0.24s","--motion-slow":"0.6s","--motion-lazy":"1s","--easing-standard":"cubic-bezier(0.4, 0, 0.2, 1)","--easing-decelerate":"cubic-bezier(0, 0, 0.2, 1)","--easing-accelerate":"cubic-bezier(0.4, 0, 1, 1)","--easing-bounce":"cubic-bezier(0.68, -0.55, 0.265, 1.55)","--easing-smooth":"cubic-bezier(0.4, 0, 0.2, 1)","--font-family-sans":"'Inter', 'Geist', 'Noto Sans SC', 'HarmonyOS Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif","--font-family-mono":"'Menlo', 'SF Mono', 'Cascadia Code', 'Consolas', 'Liberation Mono', 'Courier New', 'Noto Sans Mono CJK SC', 'Noto Sans Mono', monospace","--font-weight-normal":"400","--font-weight-medium":"500","--font-weight-semibold":"600","--font-weight-bold":"700","--font-size-xs":"12px","--font-size-sm":"14px","--font-size-base":"15px","--font-size-lg":"16px","--font-size-xl":"18px","--font-size-2xl":"20px","--font-size-3xl":"24px","--line-height-tight":"1.2","--line-height-base":"1.5","--line-height-relaxed":"1.75","--opacity-disabled":"0.6","--opacity-hover":"0.8","--opacity-focus":"0.9","--opacity-overlay":"0.4","--scrollbar-thumb":"rgba(255, 255, 255, 0.15)","--scrollbar-thumb-hover":"rgba(255, 255, 255, 0.28)","--btn-default-bg":"rgba(255, 255, 255, 0.08)","--btn-default-color":"rgba(248, 250, 252, 0.70)","--btn-hover-bg":"rgba(255, 255, 255, 0.14)","--btn-hover-color":"rgba(248, 250, 252, 0.92)","--btn-primary-bg":"#F8FAFC","--btn-primary-color":"#0F172A","--btn-primary-hover-bg":"rgba(248, 250, 252, 0.90)","--btn-ghost-bg":"transparent","--btn-ghost-color":"rgba(248, 250, 252, 0.70)","--btn-ghost-hover-bg":"rgba(255, 255, 255, 0.08)"},Ex={"--ink":"#0F172A","--graphite":"#253044","--slate":"#5B6B8C","--print":"#B7372F","--echo":"#E06B5F","--cloud":"#F8FAFC","--surface":"#FFFFFF","--hairline":"rgba(15, 23, 42, 0.12)","--hairline-soft":"rgba(15, 23, 42, 0.08)","--color-bg-primary":"#F8FAFC","--color-bg-secondary":"#FFFFFF","--color-bg-tertiary":"#F8FAFC","--color-bg-quaternary":"#EEF1F5","--color-bg-elevated":"#FFFFFF","--color-bg-workbench":"#F8FAFC","--color-bg-scene":"#FFFFFF","--color-bg-flowchat":"#FFFFFF","--color-bg-tooltip":"rgba(255, 255, 255, 0.98)","--color-text-primary":"#0F172A","--color-text-secondary":"#253044","--color-text-muted":"#5B6B8C","--color-text-disabled":"#A0AEBE","--element-bg-subtle":"rgba(15, 23, 42, 0.03)","--element-bg-soft":"rgba(15, 23, 42, 0.05)","--element-bg-base":"rgba(15, 23, 42, 0.07)","--element-bg-medium":"rgba(15, 23, 42, 0.10)","--element-bg-strong":"rgba(15, 23, 42, 0.15)","--element-bg-elevated":"rgba(255, 255, 255, 0.94)","--color-accent-50":"rgba(183, 55, 47, 0.04)","--color-accent-100":"rgba(183, 55, 47, 0.08)","--color-accent-200":"rgba(183, 55, 47, 0.14)","--color-accent-300":"rgba(183, 55, 47, 0.22)","--color-accent-400":"rgba(183, 55, 47, 0.36)","--color-accent-500":"#B7372F","--color-accent-600":"#9B2E27","--color-accent-700":"rgba(155, 46, 39, 0.8)","--color-accent-800":"rgba(155, 46, 39, 0.9)","--color-purple-50":"rgba(175, 82, 222, 0.04)","--color-purple-100":"rgba(175, 82, 222, 0.08)","--color-purple-200":"rgba(175, 82, 222, 0.14)","--color-purple-300":"rgba(175, 82, 222, 0.22)","--color-purple-400":"rgba(175, 82, 222, 0.36)","--color-purple-500":"#AF52DE","--color-purple-600":"#9536CC","--color-purple-700":"rgba(149, 54, 204, 0.8)","--color-purple-800":"rgba(149, 54, 204, 0.9)","--color-pink-50":"rgba(236, 72, 153, 0.04)","--color-pink-100":"rgba(236, 72, 153, 0.08)","--color-pink-200":"rgba(236, 72, 153, 0.14)","--color-pink-300":"rgba(236, 72, 153, 0.22)","--color-pink-400":"rgba(236, 72, 153, 0.36)","--color-pink-500":"#EC4899","--color-pink-600":"#DB2777","--color-pink-700":"rgba(219, 39, 119, 0.8)","--color-pink-800":"rgba(219, 39, 119, 0.9)","--color-orange-50":"rgba(255, 149, 0, 0.04)","--color-orange-100":"rgba(255, 149, 0, 0.08)","--color-orange-200":"rgba(255, 149, 0, 0.14)","--color-orange-300":"rgba(255, 149, 0, 0.22)","--color-orange-400":"rgba(255, 149, 0, 0.36)","--color-orange-500":"#FF9500","--color-orange-600":"#CC7A00","--color-orange-700":"rgba(204, 122, 0, 0.8)","--color-orange-800":"rgba(204, 122, 0, 0.9)","--color-success":"#16A34A","--color-success-bg":"rgba(22, 163, 74, 0.08)","--color-success-border":"rgba(22, 163, 74, 0.25)","--color-warning":"#D97706","--color-warning-bg":"rgba(217, 119, 6, 0.08)","--color-warning-border":"rgba(217, 119, 6, 0.25)","--color-error":"#B7372F","--color-error-bg":"rgba(183, 55, 47, 0.08)","--color-error-border":"rgba(183, 55, 47, 0.25)","--color-info":"#0369A1","--color-info-bg":"rgba(3, 105, 161, 0.08)","--color-info-border":"rgba(3, 105, 161, 0.25)","--color-highlight":"#B7372F","--color-highlight-bg":"rgba(183, 55, 47, 0.10)","--color-overlay":"rgba(15, 23, 42, 0.35)","--border-subtle":"rgba(15, 23, 42, 0.08)","--border-base":"rgba(15, 23, 42, 0.12)","--border-medium":"rgba(15, 23, 42, 0.20)","--border-strong":"rgba(15, 23, 42, 0.30)","--border-prominent":"rgba(15, 23, 42, 0.40)","--glow-blue":"0 2px 8px rgba(183, 55, 47, 0.08)","--glow-purple":"0 2px 8px rgba(175, 82, 222, 0.08)","--glow-orange":"0 2px 8px rgba(255, 149, 0, 0.08)","--glow-mixed":"0 2px 8px rgba(183, 55, 47, 0.06), 0 2px 8px rgba(175, 82, 222, 0.04)","--shadow-xs":"0 1px 2px rgba(15, 23, 42, 0.04)","--shadow-sm":"0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04)","--shadow-base":"0 2px 8px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.04)","--shadow-lg":"0 4px 16px rgba(15, 23, 42, 0.08), 0 2px 6px rgba(15, 23, 42, 0.04)","--shadow-xl":"0 8px 24px rgba(15, 23, 42, 0.10), 0 4px 8px rgba(15, 23, 42, 0.04)","--shadow-2xl":"0 12px 32px rgba(15, 23, 42, 0.12), 0 4px 12px rgba(15, 23, 42, 0.06)","--blur-subtle":"blur(4px) saturate(1.2)","--blur-base":"blur(8px) saturate(1.4)","--blur-medium":"blur(12px) saturate(1.6)","--blur-strong":"blur(16px) saturate(1.8)","--blur-intense":"blur(20px) saturate(2.0)","--size-radius-sm":"6px","--size-radius-base":"8px","--size-radius-lg":"12px","--size-radius-xl":"16px","--size-radius-2xl":"20px","--size-radius-full":"9999px","--size-gap-1":"4px","--size-gap-2":"8px","--size-gap-3":"12px","--size-gap-4":"16px","--size-gap-5":"20px","--size-gap-6":"24px","--size-gap-8":"32px","--size-gap-10":"40px","--size-gap-12":"48px","--size-gap-16":"64px","--motion-instant":"0.1s","--motion-fast":"0.15s","--motion-base":"0.24s","--motion-slow":"0.6s","--motion-lazy":"1s","--easing-standard":"cubic-bezier(0.4, 0, 0.2, 1)","--easing-decelerate":"cubic-bezier(0, 0, 0.2, 1)","--easing-accelerate":"cubic-bezier(0.4, 0, 1, 1)","--easing-bounce":"cubic-bezier(0.68, -0.55, 0.265, 1.55)","--easing-smooth":"cubic-bezier(0.4, 0, 0.2, 1)","--font-family-sans":"'Inter', 'Geist', 'Noto Sans SC', 'HarmonyOS Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif","--font-family-mono":"'Menlo', 'SF Mono', 'Cascadia Code', 'Consolas', 'Liberation Mono', 'Courier New', 'Noto Sans Mono CJK SC', 'Noto Sans Mono', monospace","--font-weight-normal":"400","--font-weight-medium":"500","--font-weight-semibold":"600","--font-weight-bold":"700","--font-size-xs":"12px","--font-size-sm":"14px","--font-size-base":"15px","--font-size-lg":"16px","--font-size-xl":"18px","--font-size-2xl":"20px","--font-size-3xl":"24px","--line-height-tight":"1.2","--line-height-base":"1.5","--line-height-relaxed":"1.75","--opacity-disabled":"0.55","--opacity-hover":"0.75","--opacity-focus":"0.9","--opacity-overlay":"0.35","--scrollbar-thumb":"rgba(15, 23, 42, 0.15)","--scrollbar-thumb-hover":"rgba(15, 23, 42, 0.25)","--btn-default-bg":"rgba(15, 23, 42, 0.06)","--btn-default-color":"#253044","--btn-hover-bg":"rgba(15, 23, 42, 0.10)","--btn-hover-color":"#0F172A","--btn-primary-bg":"#0F172A","--btn-primary-color":"#ffffff","--btn-primary-hover-bg":"#253044","--btn-ghost-bg":"transparent","--btn-ghost-color":"#253044","--btn-ghost-hover-bg":"rgba(15, 23, 42, 0.06)"},Sx="sparo-mobile-theme",cE="data-sparo-theme",vC={dark:yx,light:Ex},ym={dark:"#121214",light:"#f2f2f7"},vx={dark:"#e8e8e8",light:"#1c1c1e"};function dE(e,t){const n=ym[e],i=vx[e],o=[":root {"];for(const[l,u]of Object.entries(t))o.push(` ${l}: ${u};`);return o.push(` color-scheme: ${e};`),o.push("}"),o.push(`html, body { background-color: ${n}; color: ${i}; color-scheme: ${e}; }`),o.join(`
-`)}const kC={dark:dE("dark",yx),light:dE("light",Ex)};function _C(e){const t=document.documentElement,n=document.body,i=vC[e],o=document.createElement("style");o.setAttribute(cE,e),o.textContent=kC[e],document.head.appendChild(o),document.head.querySelectorAll(`style[${cE}]`).forEach(u=>{u!==o&&u.remove()});for(const u of Object.keys(i))t.style.setProperty(u,i[u]);t.style.setProperty("color-scheme",e),t.setAttribute("data-theme",e),t.setAttribute("data-theme-type",e),n.setAttribute("data-theme",e),n.style.backgroundColor=ym[e],n.style.color=vx[e];const l=document.querySelector('meta[name="theme-color"]');l&&(l.setAttribute("content",ym[e]),l.removeAttribute("media"))}function wC(){try{const e=localStorage.getItem(Sx);if(e==="dark"||e==="light")return e}catch{}return window.matchMedia?.("(prefers-color-scheme: light)").matches?"light":"dark"}const kx=P.createContext({themeId:"dark",isDark:!0,setTheme:()=>{},toggleTheme:()=>{}}),TC=280;let pE;const xC=({children:e})=>{const[t,n]=P.useState(wC);P.useLayoutEffect(()=>{const l=document.documentElement,u=l.getAttribute("data-theme"),c=u&&u!==t;c&&(clearTimeout(pE),l.classList.add("theme-switching"),l.offsetHeight),_C(t),c&&(pE=setTimeout(()=>{l.classList.remove("theme-switching")},TC+40));try{localStorage.setItem(Sx,t)}catch{}},[t]);const i=P.useCallback(l=>n(l),[]),o=P.useCallback(()=>n(l=>l==="dark"?"light":"dark"),[]);return g.jsx(kx.Provider,{value:{themeId:t,isDark:t==="dark",setTheme:i,toggleTheme:o},children:e})};function Ca(){return P.useContext(kx)}const AC=({className:e})=>{const{language:t,toggleLanguage:n,t:i}=dt();return g.jsx("button",{type:"button",className:e||"mobile-lang-btn",onClick:n,"aria-label":i("common.switchLanguage"),title:i("common.switchLanguage"),children:t==="zh-CN"?"中":"EN"})};function RC(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"}function _x(e,t=""){if(!Number.isSafeInteger(e)||e<0){const n=t&&`"${t}" `;throw new Error(`${n}expected integer >= 0, got ${e}`)}}function Ei(e,t,n=""){const i=RC(e),o=e?.length,l=t!==void 0;if(!i||l&&o!==t){const u=n&&`"${n}" `,c=l?` of length ${t}`:"",p=i?`length=${o}`:`type=${typeof e}`;throw new Error(u+"expected Uint8Array"+c+", got "+p)}return e}const wx=typeof Uint8Array.from([]).toHex=="function"&&typeof Uint8Array.fromHex=="function",NC=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function CC(e){if(Ei(e),wx)return e.toHex();let t="";for(let n=0;n=Xn._0&&e<=Xn._9)return e-Xn._0;if(e>=Xn.A&&e<=Xn.F)return e-(Xn.A-10);if(e>=Xn.a&&e<=Xn.f)return e-(Xn.a-10)}function IC(e){if(typeof e!="string")throw new Error("hex string expected, got "+typeof e);if(wx)return Uint8Array.fromHex(e);const t=e.length,n=t/2;if(t%2)throw new Error("hex string expected, got unpadded hex of length "+t);const i=new Uint8Array(n);for(let o=0,l=0;otypeof e=="bigint"&&Tx<=e;function PC(e,t,n){return ts(e)&&ts(t)&&ts(n)&&t<=e&&eObject.entries(l).forEach(([c,p])=>i(c,p,u));o(t,!1),o(n,!0)}const xx=BigInt(0);function Ax(e,t){const n=e%t;return n>=xx?n:t+n}function In(e,t,n){let i=e;for(;t-- >xx;)i*=i,i%=n;return i}function BC(e,t){return function(i){const o=e(i);return{secretKey:o,publicKey:t(o)}}}const fi=BigInt(0),Ea=BigInt(1),$o=BigInt(2);function jC(e){return UC(e,{adjustScalarBytes:"function",powPminus2:"function"}),Object.freeze({...e})}function zC(e){const t=jC(e),{P:n,type:i,adjustScalarBytes:o,powPminus2:l,randomBytes:u}=t,c=i==="x25519";if(!c&&i!=="x448")throw new Error("invalid type");const p=u||OC,f=c?255:448,m=c?32:56,h=BigInt(c?9:5),S=BigInt(c?121665:39081),E=c?$o**BigInt(254):$o**BigInt(447),v=c?BigInt(8)*$o**BigInt(251)-Ea:BigInt(4)*$o**BigInt(445)-Ea,k=E+v+Ea,T=Z=>Ax(Z,n),N=R(h);function R(Z){return FC(T(Z),m)}function A(Z){const H=Em(Ei(Z,m,"uCoordinate"));return c&&(H[31]&=127),T(gE(H))}function O(Z){return gE(o(Em(Ei(Z,m,"scalar"))))}function L(Z,H){const te=M(A(H),O(Z));if(te===fi)throw new Error("invalid private or public key received");return R(te)}function w(Z){return L(Z,N)}const B=w,W=L;function j(Z,H,te){const ue=T(Z*(H-te));return H=T(H-ue),te=T(te+ue),{x_2:H,x_3:te}}function M(Z,H){mE("u",Z,fi,n),mE("scalar",H,E,k);const te=H,ue=Z;let q=Ea,Q=fi,x=Z,D=Ea,$=fi;for(let ae=BigInt(f-1);ae>=fi;ae--){const pe=te>>ae&Ea;$^=pe,{x_2:q,x_3:x}=j($,q,x),{x_2:Q,x_3:D}=j($,Q,D),$=pe;const fe=q+Q,Se=T(fe*fe),ke=q-Q,X=T(ke*ke),he=Se-X,Ie=x+D,Qe=x-D,Ce=T(Qe*fe),$e=T(Ie*ke),pt=Ce+$e,tt=Ce-$e;x=T(pt*pt),D=T(ue*T(tt*tt)),q=T(Se*X),Q=T(he*(Se+T(S*he)))}({x_2:q,x_3:x}=j($,q,x)),{x_2:Q,x_3:D}=j($,Q,D);const C=l(Q);return T(q*C)}const Y={secretKey:m,publicKey:m,seed:m},J=(Z=p(m))=>(Ei(Z,Y.seed,"seed"),Z),de={randomSecretKey:J};return Object.freeze({keygen:BC(J,B),getSharedSecret:W,getPublicKey:B,scalarMult:L,scalarMultBase:w,utils:de,GuBytes:N.slice(),lengths:Y})}const $C=BigInt(1),hE=BigInt(2),qC=BigInt(3),GC=BigInt(5);BigInt(8);const Rx=BigInt("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed");function HC(e){const t=BigInt(10),n=BigInt(20),i=BigInt(40),o=BigInt(80),l=Rx,c=e*e%l*e%l,p=In(c,hE,l)*c%l,f=In(p,$C,l)*e%l,m=In(f,GC,l)*f%l,h=In(m,t,l)*m%l,S=In(h,n,l)*h%l,E=In(S,i,l)*S%l,v=In(E,o,l)*E%l,k=In(v,o,l)*E%l,T=In(k,t,l)*m%l;return{pow_p_5_8:In(T,hE,l)*e%l,b2:c}}function WC(e){return e[0]&=248,e[31]&=127,e[31]|=64,e}const Nx=(()=>{const e=Rx;return zC({P:e,type:"x25519",powPminus2:t=>{const{pow_p_5_8:n,b2:i}=HC(t);return Ax(In(n,qC,e)*i,e)},adjustScalarBytes:WC})})();function VC(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"}function nn(e,t,n=""){const i=VC(e),o=e?.length,l=t!==void 0;if(!i||l&&o!==t){const u=n&&`"${n}" `,c=l?` of length ${t}`:"",p=i?`length=${o}`:`type=${typeof e}`;throw new Error(u+"expected Uint8Array"+c+", got "+p)}return e}function os(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")}function Cx(e,t){nn(e,void 0,"output");const n=t.outputLen;if(e.length{function n(i,...o){if(nn(i,void 0,"key"),!KC)throw new Error("Non little-endian hardware is not yet supported");if(e.nonceLength!==void 0){const m=o[0];nn(m,e.varSizeNonce?void 0:e.nonceLength,"nonce")}const l=e.tagLength;l&&o[1]!==void 0&&nn(o[1],void 0,"AAD");const u=t(i,...o),c=(m,h)=>{if(h!==void 0){if(m!==2)throw new Error("cipher output not supported");nn(h,void 0,"output")}};let p=!1;return{encrypt(m,h){if(p)throw new Error("cannot encrypt() twice with same key + nonce");return p=!0,nn(m),c(u.encrypt.length,h),u.encrypt(m,h)},decrypt(m,h){if(nn(m),l&&m.length{const o=i&1;return{s3:n<<31|i>>>1,s2:t<<31|n>>>1,s1:e<<31|t>>>1,s0:e>>>1^eI<<24&-(o&1)}},En=e=>(e>>>0&255)<<24|(e>>>8&255)<<16|(e>>>16&255)<<8|e>>>24&255|0;function nI(e){e.reverse();const t=e[15]&1;let n=0;for(let i=0;i>>1|n,n=(o&1)<<7}return e[0]^=-t&225,e}const rI=e=>e>64*1024?8:e>1024?4:2;class Ix{blockLen=Jn;outputLen=Jn;s0=0;s1=0;s2=0;s3=0;finished=!1;t;W;windowSize;constructor(t,n){nn(t,16,"key"),t=Hr(t);const i=hs(t);let o=i.getUint32(0,!1),l=i.getUint32(4,!1),u=i.getUint32(8,!1),c=i.getUint32(12,!1);const p=[];for(let v=0;v<128;v++)p.push({s0:En(o),s1:En(l),s2:En(u),s3:En(c)}),{s0:o,s1:l,s2:u,s3:c}=tI(o,l,u,c);const f=rI(n||1024);if(![1,2,4,8].includes(f))throw new Error("ghash: invalid window size, expected 2, 4 or 8");this.W=f;const h=128/f,S=this.windowSize=2**f,E=[];for(let v=0;v>>f-O-1&1))continue;const{s0:w,s1:B,s2:W,s3:j}=p[f*v+O];T^=w,N^=B,R^=W,A^=j}E.push({s0:T,s1:N,s2:R,s3:A})}this.t=E}_updateBlock(t,n,i,o){t^=this.s0,n^=this.s1,i^=this.s2,o^=this.s3;const{W:l,t:u,windowSize:c}=this;let p=0,f=0,m=0,h=0;const S=(1<>>8*k&255;for(let N=8/l-1;N>=0;N--){const R=T>>>l*N&S,{s0:A,s1:O,s2:L,s3:w}=u[E*c+R];p^=A,f^=O,m^=L,h^=w,E+=1}}this.s0=p,this.s1=f,this.s2=m,this.s3=h}update(t){os(this),nn(t),t=Hr(t);const n=er(t),i=Math.floor(t.length/Jn),o=t.length%Jn;for(let l=0;le(o,i.length).update(i).digest(),n=e(new Uint8Array(16),0);return t.outputLen=n.outputLen,t.blockLen=n.blockLen,t.create=(i,o)=>e(i,o),t}const bE=Ox((e,t)=>new Ix(e,t));Ox((e,t)=>new aI(e,t));const Sm=16,iI=4,qo=new Uint8Array(Sm),oI=283;function sI(e){if(![16,24,32].includes(e.length))throw new Error('"aes key" expected Uint8Array of length 16/24/32, got length='+e.length)}function Hm(e){return e<<1^oI&-(e>>7)}function yE(e,t){let n=0;for(;t>0;t>>=1)n^=e&-(t&1),e=Hm(e);return n}const lI=(()=>{const e=new Uint8Array(256);for(let n=0,i=1;n<256;n++,i^=Hm(i))e[n]=i;const t=new Uint8Array(256);t[0]=99;for(let n=0;n<255;n++){let i=e[255-n];i|=i<<8,t[e[n]]=(i^i>>4^i>>5^i>>6^i>>7^99)&255}return tr(e),t})(),uI=e=>e<<24|e>>>8,du=e=>e<<8|e>>>24;function cI(e,t){if(e.length!==256)throw new Error("Wrong sbox length");const n=new Uint32Array(256).map((f,m)=>t(e[m])),i=n.map(du),o=i.map(du),l=o.map(du),u=new Uint32Array(256*256),c=new Uint32Array(256*256),p=new Uint16Array(256*256);for(let f=0;f<256;f++)for(let m=0;m<256;m++){const h=f*256+m;u[h]=n[f]^i[m],c[h]=o[f]^l[m],p[h]=e[f]<<8|e[m]}return{sbox:e,sbox2:p,T0:n,T1:i,T2:o,T3:l,T01:u,T23:c}}const Lx=cI(lI,e=>yE(e,3)<<24|e<<16|e<<8|yE(e,2)),dI=(()=>{const e=new Uint8Array(16);for(let t=0,n=1;t<16;t++,n=Hm(n))e[t]=n;return e})();function pI(e){nn(e);const t=e.length;sI(e);const{sbox2:n}=Lx,i=[];ss(e)||i.push(e=Hr(e));const o=er(e),l=o.length,u=p=>yi(n,p,p,p,p),c=new Uint32Array(t+28);c.set(o);for(let p=l;p6&&p%l===4&&(f=u(f)),c[p]=c[p-l]^f}return tr(...i),c}function Go(e,t,n,i,o,l){return e[n<<8&65280|i>>>8&255]^t[o>>>8&65280|l>>>24&255]}function yi(e,t,n,i,o){return e[t&255|n&65280]|e[i>>>16&255|o>>>16&65280]<<16}function EE(e,t,n,i,o){const{sbox2:l,T01:u,T23:c}=Lx;let p=0;t^=e[p++],n^=e[p++],i^=e[p++],o^=e[p++];const f=e.length/4-2;for(let v=0;v>>0,c.setUint32(m,S,t),{s0:E,s1:v,s2:k,s3:T}=EE(e,u[0],u[1],u[2],u[3]);const N=Sm*Math.floor(p.length/iI);if(Nt+=String.fromCharCode(n)),btoa(t)}function km(e){const t=atob(e),n=new Uint8Array(t.length);for(let i=0;io.agent_type==="OSAgent");return i?i.session_id:this.createSession("OSAgent","Sparo OS",t)}async getSessionMessages(t,n,i){const o=await this.request({cmd:"get_session_messages",session_id:t,limit:n,before_message_id:i});return{messages:o.messages||[],has_more:o.has_more||!1}}async getModelCatalog(t){return(await this.request({cmd:"get_model_catalog",session_id:t??void 0})).catalog}async setSessionModel(t,n){return(await this.request({cmd:"set_session_model",session_id:t,model_id:n})).model_id}async sendMessage(t,n,i,o){return(await this.request({cmd:"send_message",session_id:t,content:n,agent_type:i||void 0,image_contexts:o&&o.length>0?o:void 0})).turn_id}async cancelTask(t,n){await this.request({cmd:"cancel_task",session_id:t,turn_id:n??void 0})}async cancelTool(t,n){await this.request({cmd:"cancel_tool",tool_id:t,reason:n??void 0})}async deleteSession(t){await this.request({cmd:"delete_session",session_id:t})}async answerQuestion(t,n){await this.request({cmd:"answer_question",tool_id:t,answers:n})}async pollSession(t,n,i,o=0){return this.request({cmd:"poll_session",session_id:t,since_version:n,known_msg_count:i,known_model_catalog_version:o})}async ping(){await this.request({cmd:"ping"})}async getFileInfo(t,n){const i=await this.request({cmd:"get_file_info",path:t,session_id:n??void 0});return{name:i.name,size:i.size,mimeType:i.mime_type}}async readFile(t,n,i){let l=0;const u=[];let c="",p="",f=0;for(;;){const m=await this.request({cmd:"read_file_chunk",path:t,session_id:n??void 0,offset:l,limit:3145728});if(u.push(m.chunk_base64),c=m.name,p=m.mime_type,f=m.total_size,l+=m.chunk_size,i?.(Math.min(l,f),f),l>=f||m.chunk_size===0)break}return{name:c,contentBase64:u.join(""),mimeType:p,size:f}}}class EI{intervalId=null;sinceVersion=0;knownMsgCount=0;sessionId;sessionMgr;onUpdate;polling=!1;stopped=!1;hasActiveTurn=!1;knownModelCatalogVersion=0;turnJustEndedAt=null;TURN_JUST_ENDED_GRACE_PERIOD_MS=5e3;constructor(t,n,i,o=0){this.sessionMgr=t,this.sessionId=n,this.onUpdate=i,this.knownModelCatalogVersion=o}start(t=0){this.stopped=!1,this.knownMsgCount=t,this.tick(),document.addEventListener("visibilitychange",this.onVisibilityChange)}stop(){this.stopped=!0,this.intervalId!==null&&(clearTimeout(this.intervalId),this.intervalId=null),document.removeEventListener("visibilitychange",this.onVisibilityChange)}resetCursors(){this.sinceVersion=0,this.knownMsgCount=0}setKnownModelCatalogVersion(t){this.knownModelCatalogVersion=t}nudge(){this.hasActiveTurn=!0,this.intervalId!==null&&clearTimeout(this.intervalId),this.tick()}getInterval(){if(document.visibilityState!=="visible")return 5e3;const t=Date.now();return this.turnJustEndedAt!=null&&t-this.turnJustEndedAtthis.tick(),this.getInterval()))}onVisibilityChange=()=>{this.stopped||(document.visibilityState==="visible"?(this.intervalId!==null&&clearTimeout(this.intervalId),this.tick()):this.scheduleNext())};async tick(){if(this.stopped||this.polling){this.scheduleNext();return}this.polling=!0;try{const t=await this.sessionMgr.pollSession(this.sessionId,this.sinceVersion,this.knownMsgCount,this.knownModelCatalogVersion);if(t.changed){const n=this.hasActiveTurn,i=t.active_turn!=null&&t.active_turn.status==="active";this.hasActiveTurn=i,n&&!i&&(this.turnJustEndedAt=Date.now()),t.new_messages&&t.new_messages.length>0&&(this.turnJustEndedAt=null),this.sinceVersion=t.version,t.total_msg_count!=null&&(this.knownMsgCount=t.total_msg_count),t.model_catalog?.version!=null&&(this.knownModelCatalogVersion=t.model_catalog.version),this.onUpdate(t)}}catch(t){console.error("[Poller] poll error",t)}finally{this.polling=!1,this.scheduleNext()}}}const vE=e=>{let t;const n=new Set,i=(f,m)=>{const h=typeof f=="function"?f(t):f;if(!Object.is(h,t)){const S=t;t=m??(typeof h!="object"||h===null)?h:Object.assign({},t,h),n.forEach(E=>E(t,S))}},o=()=>t,c={setState:i,getState:o,getInitialState:()=>p,subscribe:f=>(n.add(f),()=>n.delete(f))},p=t=e(i,o,c);return c},SI=(e=>e?vE(e):vE),vI=e=>e;function kI(e,t=vI){const n=ct.useSyncExternalStore(e.subscribe,ct.useCallback(()=>t(e.getState()),[e,t]),ct.useCallback(()=>t(e.getInitialState()),[e,t]));return ct.useDebugValue(n),n}const kE=e=>{const t=SI(e),n=i=>kI(t,i);return Object.assign(n,t),n},Fx=(e=>e?kE(e):kE),vn=Fx((e,t)=>({connectionStatus:"idle",setConnectionStatus:n=>e({connectionStatus:n}),selectedWorkspace:null,setSelectedWorkspace:n=>e({selectedWorkspace:n}),authenticatedUserId:null,setAuthenticatedUserId:n=>e({authenticatedUserId:n}),sessions:[],setSessions:n=>e({sessions:n}),appendSessions:n=>e(i=>({sessions:[...i.sessions,...n]})),updateSessionName:(n,i)=>e(o=>({sessions:o.sessions.map(l=>l.session_id===n?{...l,name:i}:l)})),activeSessionId:null,setActiveSessionId:n=>e({activeSessionId:n}),messagesBySession:{},getMessages:n=>t().messagesBySession[n]||[],setMessages:(n,i)=>e(o=>({messagesBySession:{...o.messagesBySession,[n]:i}})),appendNewMessages:(n,i)=>e(o=>{if(i.length===0)return o;const l=o.messagesBySession[n]||[],u=new Set(l.map(p=>p.id)),c=i.filter(p=>!u.has(p.id));return c.length===0?o:{messagesBySession:{...o.messagesBySession,[n]:[...l,...c]}}}),activeTurn:null,setActiveTurn:n=>e({activeTurn:n}),error:null,setError:n=>e({error:n})})),Px=""+new URL("sparo-logo-mark-BchWKRwx.png",import.meta.url).href,_E="sparo.mobile.install_id",wE="sparo.mobile.user_id",zr="sparo.mobile.user_id_lock_until",Sa="sparo.mobile.user_id_failure_count",_I=3,TE=6e4;function wI(e){return e.includes("This remote URL is already protected")||e.includes("This mobile device must continue using the previously confirmed user ID")}function TI(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?crypto.randomUUID():`mobile-${Date.now().toString(36)}-${Math.random().toString(36).slice(2,10)}`}function xE(){const e=localStorage.getItem(_E)?.trim();if(e)return e;const t=TI();return localStorage.setItem(_E,t),t}function xI(){const e=window.location.hash,t=new URLSearchParams(e.replace(/^#\/pair\?/,"")),n=t.get("room"),i=t.get("pk"),o=t.get("relay");if(o)return{room:n,pk:i,httpBaseUrl:o.replace(/^wss:\/\//,"https://").replace(/^ws:\/\//,"http://").replace(/\/ws\/?$/,"").replace(/\/$/,"")};const l=window.location.origin,u=window.location.pathname.replace(/\/[^/]*$/,"").replace(/\/r\/[^/]*$/,"");return{room:n,pk:i,httpBaseUrl:l+u}}const AI=({onPaired:e})=>{const{t}=dt(),{connectionStatus:n,setConnectionStatus:i,setError:o,error:l,setAuthenticatedUserId:u}=vn(),[c,p]=P.useState(""),[f,m]=P.useState(""),[h,S]=P.useState(!1),[E,v]=P.useState(0),[k,T]=P.useState(null),[N,R]=P.useState(()=>Date.now()),A=P.useRef(!1),O=P.useRef(0),L=P.useRef(null),w=P.useMemo(()=>xI(),[]),B=!!k&&k>N,W=B?Math.max(1,Math.ceil((k-N)/1e3)):0,j=P.useCallback(async(Z,H)=>{const te=Z.trim(),ue=H?.autoReconnect===!0,q=H?.installId||f||xE(),Q=L.current,x=!!Q&&Q>Date.now(),D=x?Math.max(1,Math.ceil((Q-Date.now())/1e3)):0;if(!w.room||!w.pk){o(t("pairing.invalidQrCode")),i("error");return}if(!te){o(t("pairing.userIdRequired")),i("error");return}if(!ue&&x){o(t("pairing.tooManyAttempts",{seconds:D})),i("error");return}m(q),S(!0);const $=new bI(w.httpBaseUrl,w.room);try{o(null),i("pairing");const C=await $.pair(w.pk,{userId:te,mobileInstallId:q});i("paired"),localStorage.setItem(wE,te),localStorage.removeItem(Sa),localStorage.removeItem(zr),v(0),T(null),u(C.authenticated_user_id??te);const ae=new yI($),pe=vn.getState();C.has_workspace&&pe.setSelectedWorkspace({has_workspace:!0,path:C.path,project_name:C.project_name,git_branch:C.git_branch,workspace_kind:C.workspace_kind}),C.sessions&&pe.setSessions(C.sessions),e($,ae)}catch(C){const ae=C?.message||t("pairing.pairingFailed");if(!ue&&wI(ae)){const pe=O.current+1,fe=pe>=_I,Se=fe?Date.now()+TE:null;localStorage.setItem(Sa,String(pe)),Se?localStorage.setItem(zr,String(Se)):localStorage.removeItem(zr),v(pe),T(Se),o(fe?t("pairing.tooManyAttempts",{seconds:Math.ceil(TE/1e3)}):ae)}else o(ae);i("error")}finally{S(!1)}},[f,w.httpBaseUrl,w.pk,w.room,u,i,o,t]);P.useEffect(()=>{const Z=localStorage.getItem(wE)?.trim()??"",H=xE(),te=Number(localStorage.getItem(Sa)||"0"),ue=Number(localStorage.getItem(zr)||"0"),q=ue>Date.now()?ue:null;ue&&!q&&(localStorage.removeItem(zr),localStorage.removeItem(Sa));const Q=!!Z&&!!H&&!!w.room&&!!w.pk;p(Z),m(H),v(q?te:0),T(q),i(Q?"pairing":"idle"),o(null),Q&&!A.current&&(A.current=!0,j(Z,{autoReconnect:!0,installId:H}))},[j,w.pk,w.room,i,o]),P.useEffect(()=>{O.current=E,L.current=k},[E,k]),P.useEffect(()=>{if(!k)return;if(k<=Date.now()){T(null),v(0),localStorage.removeItem(zr),localStorage.removeItem(Sa);return}const Z=window.setInterval(()=>{const H=Date.now();R(H),k<=H&&(T(null),v(0),localStorage.removeItem(zr),localStorage.removeItem(Sa))},1e3);return()=>window.clearInterval(Z)},[k]);const M=async()=>{A.current=!0,await j(c,{autoReconnect:!1})},Y={idle:t("pairing.enterUserIdToContinue"),pairing:t("pairing.connectingAndPairing"),paired:t("pairing.pairedLoadingSessions"),error:t("pairing.connectionError")},J=n==="pairing",de=n==="idle"||n==="error";return g.jsxs("div",{className:"pairing-page",children:[g.jsx("div",{className:"pairing-page__actions",children:g.jsx(AC,{})}),g.jsx("div",{className:"pairing-page__mark",children:g.jsx("img",{src:Px,alt:"Sparo OS",className:"pairing-page__logo-img"})}),g.jsx("div",{className:"pairing-page__brand",children:g.jsxs("div",{className:"pairing-page__brand-slogan",children:[g.jsx("span",{className:"pairing-page__slogan-dot","aria-hidden":"true"}),t("common.slogan")]})}),g.jsx("div",{className:"pairing-page__spinner-wrap",children:J&&g.jsx("div",{className:"pairing-page__orbit-spinner"})}),g.jsx("div",{className:"pairing-page__state",children:Y[n]||n}),l&&g.jsxs("div",{className:"pairing-page__error",children:[g.jsx("span",{className:"pairing-page__error-dot","aria-hidden":"true"}),l]}),de&&g.jsxs("div",{className:"pairing-page__form",children:[g.jsxs("label",{className:"pairing-page__field",children:[g.jsx("span",{className:"pairing-page__field-label",children:t("pairing.fieldLabel")}),g.jsx("input",{className:"pairing-page__input",type:"text",value:c,onChange:Z=>p(Z.target.value),onKeyDown:Z=>{Z.key==="Enter"&&M()},placeholder:t("pairing.placeholder"),autoCapitalize:"off",autoCorrect:"off",autoComplete:"username",disabled:h||B})]}),g.jsx("p",{className:"pairing-page__note",children:t("pairing.note")}),g.jsxs("button",{className:"pairing-page__submit",onClick:()=>{M()},disabled:h||B,children:[g.jsx("span",{className:"pairing-page__submit-dot","aria-hidden":"true"}),h?t("pairing.connecting"):B?t("pairing.retryIn",{seconds:W}):t("pairing.continue")]})]})]})},RI=["app:skills","app:memory","app:shell","app:settings","me","search"];function fu(e){return RI.includes(e)}const Bn=Fx((e,t)=>({activeScene:"home",pageStack:["home"],sessionContext:null,push(n){e(i=>({activeScene:n,pageStack:[...i.pageStack,n]})),history.pushState({scene:n},"")},pop(){const{pageStack:n}=t();if(n.length<=1)return;const i=n[n.length-2];e(o=>({activeScene:i,pageStack:o.pageStack.slice(0,-1)})),history.back()},closeOverlay(){const{activeScene:n,pageStack:i}=t();if(!fu(n))return;const o=i.slice().reverse().find(u=>!fu(u))??"home",l=i.filter(u=>!fu(u));e({activeScene:o,pageStack:l.length?l:["home"]}),history.back()},openAgenticOs(){e({activeScene:"home",pageStack:["home"],sessionContext:null}),history.pushState({scene:"home"},"")},setSessionContext(n){e({sessionContext:n})},openChat(n){e(i=>({activeScene:"chat",pageStack:[...i.pageStack,"chat"],sessionContext:n})),history.pushState({scene:"chat"},"")}})),NI="modulepreload",CI=function(e,t){return new URL(e,t).href},AE={},II=function(t,n,i){let o=Promise.resolve();if(n&&n.length>0){let f=function(m){return Promise.all(m.map(h=>Promise.resolve(h).then(S=>({status:"fulfilled",value:S}),S=>({status:"rejected",reason:S}))))};const u=document.getElementsByTagName("link"),c=document.querySelector("meta[property=csp-nonce]"),p=c?.nonce||c?.getAttribute("nonce");o=f(n.map(m=>{if(m=CI(m,i),m in AE)return;AE[m]=!0;const h=m.endsWith(".css"),S=h?'[rel="stylesheet"]':"";if(i)for(let v=u.length-1;v>=0;v--){const k=u[v];if(k.href===m&&(!h||k.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${m}"]${S}`))return;const E=document.createElement("link");if(E.rel=h?"stylesheet":NI,h||(E.as="script"),E.crossOrigin="",E.href=m,p&&E.setAttribute("nonce",p),document.head.appendChild(E),h)return new Promise((v,k)=>{E.addEventListener("load",v),E.addEventListener("error",()=>k(new Error(`Unable to preload CSS for ${m}`)))})}))}function l(u){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=u,window.dispatchEvent(c),!c.defaultPrevented)throw u}return o.then(u=>{for(const c of u||[])c.status==="rejected"&&l(c.reason);return t().catch(l)})};function OI(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const LI=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,DI=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,MI={};function RE(e,t){return(MI.jsx?DI:LI).test(e)}const FI=/[ \t\n\f\r]/g;function PI(e){return typeof e=="object"?e.type==="text"?NE(e.value):!1:NE(e)}function NE(e){return e.replace(FI,"")===""}class Ci{constructor(t,n,i){this.normal=n,this.property=t,i&&(this.space=i)}}Ci.prototype.normal={};Ci.prototype.property={};Ci.prototype.space=void 0;function Ux(e,t){const n={},i={};for(const o of e)Object.assign(n,o.property),Object.assign(i,o.normal);return new Ci(n,i,t)}function _m(e){return e.toLowerCase()}class rn{constructor(t,n){this.attribute=n,this.property=t}}rn.prototype.attribute="";rn.prototype.booleanish=!1;rn.prototype.boolean=!1;rn.prototype.commaOrSpaceSeparated=!1;rn.prototype.commaSeparated=!1;rn.prototype.defined=!1;rn.prototype.mustUseProperty=!1;rn.prototype.number=!1;rn.prototype.overloadedBoolean=!1;rn.prototype.property="";rn.prototype.spaceSeparated=!1;rn.prototype.space=void 0;let UI=0;const Re=Vr(),vt=Vr(),wm=Vr(),le=Vr(),Ye=Vr(),Ta=Vr(),cn=Vr();function Vr(){return 2**++UI}const Tm=Object.freeze(Object.defineProperty({__proto__:null,boolean:Re,booleanish:vt,commaOrSpaceSeparated:cn,commaSeparated:Ta,number:le,overloadedBoolean:wm,spaceSeparated:Ye},Symbol.toStringTag,{value:"Module"})),gu=Object.keys(Tm);class Wm extends rn{constructor(t,n,i,o){let l=-1;if(super(t,n),CE(this,"space",o),typeof i=="number")for(;++l4&&n.slice(0,4)==="data"&&qI.test(t)){if(t.charAt(4)==="-"){const l=t.slice(5).replace(IE,WI);i="data"+l.charAt(0).toUpperCase()+l.slice(1)}else{const l=t.slice(4);if(!IE.test(l)){let u=l.replace($I,HI);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=Wm}return new o(i,t)}function HI(e){return"-"+e.toLowerCase()}function WI(e){return e.charAt(1).toUpperCase()}const VI=Ux([Bx,BI,$x,qx,Gx],"html"),Vm=Ux([Bx,jI,$x,qx,Gx],"svg");function YI(e){return e.join(" ").trim()}var va={},mu,OE;function KI(){if(OE)return mu;OE=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,i=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,l=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,u=/^[;\s]*/,c=/^\s+|\s+$/g,p=`
-`,f="/",m="*",h="",S="comment",E="declaration";function v(T,N){if(typeof T!="string")throw new TypeError("First argument must be a string");if(!T)return[];N=N||{};var R=1,A=1;function O(Z){var H=Z.match(t);H&&(R+=H.length);var te=Z.lastIndexOf(p);A=~te?Z.length-te:A+Z.length}function L(){var Z={line:R,column:A};return function(H){return H.position=new w(Z),j(),H}}function w(Z){this.start=Z,this.end={line:R,column:A},this.source=N.source}w.prototype.content=T;function B(Z){var H=new Error(N.source+":"+R+":"+A+": "+Z);if(H.reason=Z,H.filename=N.source,H.line=R,H.column=A,H.source=T,!N.silent)throw H}function W(Z){var H=Z.exec(T);if(H){var te=H[0];return O(te),T=T.slice(te.length),H}}function j(){W(n)}function M(Z){var H;for(Z=Z||[];H=Y();)H!==!1&&Z.push(H);return Z}function Y(){var Z=L();if(!(f!=T.charAt(0)||m!=T.charAt(1))){for(var H=2;h!=T.charAt(H)&&(m!=T.charAt(H)||f!=T.charAt(H+1));)++H;if(H+=2,h===T.charAt(H-1))return B("End of comment missing");var te=T.slice(2,H-2);return A+=2,O(te),T=T.slice(H),A+=2,Z({type:S,comment:te})}}function J(){var Z=L(),H=W(i);if(H){if(Y(),!W(o))return B("property missing ':'");var te=W(l),ue=Z({type:E,property:k(H[0].replace(e,h)),value:te?k(te[0].replace(e,h)):h});return W(u),ue}}function de(){var Z=[];M(Z);for(var H;H=J();)H!==!1&&(Z.push(H),M(Z));return Z}return j(),de()}function k(T){return T?T.replace(c,h):h}return mu=v,mu}var LE;function ZI(){if(LE)return va;LE=1;var e=va&&va.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(va,"__esModule",{value:!0}),va.default=n;const t=e(KI());function n(i,o){let l=null;if(!i||typeof i!="string")return l;const u=(0,t.default)(i),c=typeof o=="function";return u.forEach(p=>{if(p.type!=="declaration")return;const{property:f,value:m}=p;c?o(f,m,p):m&&(l=l||{},l[f]=m)}),l}return va}var gi={},DE;function XI(){if(DE)return gi;DE=1,Object.defineProperty(gi,"__esModule",{value:!0}),gi.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,i=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,l=function(f){return!f||n.test(f)||e.test(f)},u=function(f,m){return m.toUpperCase()},c=function(f,m){return"".concat(m,"-")},p=function(f,m){return m===void 0&&(m={}),l(f)?f:(f=f.toLowerCase(),m.reactCompat?f=f.replace(o,c):f=f.replace(i,c),f.replace(t,u))};return gi.camelCase=p,gi}var mi,ME;function QI(){if(ME)return mi;ME=1;var e=mi&&mi.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(ZI()),n=XI();function i(o,l){var u={};return!o||typeof o!="string"||(0,t.default)(o,function(c,p){c&&p&&(u[(0,n.camelCase)(c,l)]=p)}),u}return i.default=i,mi=i,mi}var JI=QI();const e1=Ni(JI),Hx=Wx("end"),Ym=Wx("start");function Wx(e){return t;function t(n){const i=n&&n.position&&n.position[e]||{};if(typeof i.line=="number"&&i.line>0&&typeof i.column=="number"&&i.column>0)return{line:i.line,column:i.column,offset:typeof i.offset=="number"&&i.offset>-1?i.offset:void 0}}}function t1(e){const t=Ym(e),n=Hx(e);if(t&&n)return{start:t,end:n}}function Si(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?FE(e.position):"start"in e||"end"in e?FE(e):"line"in e||"column"in e?xm(e):""}function xm(e){return PE(e&&e.line)+":"+PE(e&&e.column)}function FE(e){return xm(e&&e.start)+"-"+xm(e&&e.end)}function PE(e){return e&&typeof e=="number"?e:1}class $t extends Error{constructor(t,n,i){super(),typeof n=="string"&&(i=n,n=void 0);let o="",l={},u=!1;if(n&&("line"in n&&"column"in n?l={place:n}:"start"in n&&"end"in n?l={place:n}:"type"in n?l={ancestors:[n],place:n.position}:l={...n}),typeof t=="string"?o=t:!l.cause&&t&&(u=!0,o=t.message,l.cause=t),!l.ruleId&&!l.source&&typeof i=="string"){const p=i.indexOf(":");p===-1?l.ruleId=i:(l.source=i.slice(0,p),l.ruleId=i.slice(p+1))}if(!l.place&&l.ancestors&&l.ancestors){const p=l.ancestors[l.ancestors.length-1];p&&(l.place=p.position)}const c=l.place&&"start"in l.place?l.place.start:l.place;this.ancestors=l.ancestors||void 0,this.cause=l.cause||void 0,this.column=c?c.column:void 0,this.fatal=void 0,this.file="",this.message=o,this.line=c?c.line:void 0,this.name=Si(l.place)||"1:1",this.place=l.place||void 0,this.reason=this.message,this.ruleId=l.ruleId||void 0,this.source=l.source||void 0,this.stack=u&&l.cause&&typeof l.cause.stack=="string"?l.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}$t.prototype.file="";$t.prototype.name="";$t.prototype.reason="";$t.prototype.message="";$t.prototype.stack="";$t.prototype.column=void 0;$t.prototype.line=void 0;$t.prototype.ancestors=void 0;$t.prototype.cause=void 0;$t.prototype.fatal=void 0;$t.prototype.place=void 0;$t.prototype.ruleId=void 0;$t.prototype.source=void 0;const Km={}.hasOwnProperty,n1=new Map,r1=/[A-Z]/g,a1=new Set(["table","tbody","thead","tfoot","tr"]),i1=new Set(["td","th"]),Vx="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function o1(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let i;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");i=g1(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");i=f1(n,t.jsx,t.jsxs)}const o={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:i,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?Vm:VI,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},l=Yx(o,e,void 0);return l&&typeof l!="string"?l:o.create(e,o.Fragment,{children:l||void 0},void 0)}function Yx(e,t,n){if(t.type==="element")return s1(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return l1(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return c1(e,t,n);if(t.type==="mdxjsEsm")return u1(e,t);if(t.type==="root")return d1(e,t,n);if(t.type==="text")return p1(e,t)}function s1(e,t,n){const i=e.schema;let o=i;t.tagName.toLowerCase()==="svg"&&i.space==="html"&&(o=Vm,e.schema=o),e.ancestors.push(t);const l=Zx(e,t.tagName,!1),u=m1(e,t);let c=Xm(e,t);return a1.has(t.tagName)&&(c=c.filter(function(p){return typeof p=="string"?!PI(p):!0})),Kx(e,u,l,t),Zm(u,c),e.ancestors.pop(),e.schema=i,e.create(t,l,u,n)}function l1(e,t){if(t.data&&t.data.estree&&e.evaluater){const i=t.data.estree.body[0];return i.type,e.evaluater.evaluateExpression(i.expression)}Ti(e,t.position)}function u1(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Ti(e,t.position)}function c1(e,t,n){const i=e.schema;let o=i;t.name==="svg"&&i.space==="html"&&(o=Vm,e.schema=o),e.ancestors.push(t);const l=t.name===null?e.Fragment:Zx(e,t.name,!0),u=h1(e,t),c=Xm(e,t);return Kx(e,u,l,t),Zm(u,c),e.ancestors.pop(),e.schema=i,e.create(t,l,u,n)}function d1(e,t,n){const i={};return Zm(i,Xm(e,t)),e.create(t,e.Fragment,i,n)}function p1(e,t){return t.value}function Kx(e,t,n,i){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=i)}function Zm(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function f1(e,t,n){return i;function i(o,l,u,c){const f=Array.isArray(u.children)?n:t;return c?f(l,u,c):f(l,u)}}function g1(e,t){return n;function n(i,o,l,u){const c=Array.isArray(l.children),p=Ym(i);return t(o,l,u,c,{columnNumber:p?p.column-1:void 0,fileName:e,lineNumber:p?p.line:void 0},void 0)}}function m1(e,t){const n={};let i,o;for(o in t.properties)if(o!=="children"&&Km.call(t.properties,o)){const l=b1(e,o,t.properties[o]);if(l){const[u,c]=l;e.tableCellAlignToStyle&&u==="align"&&typeof c=="string"&&i1.has(t.tagName)?i=c:n[u]=c}}if(i){const l=n.style||(n.style={});l[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=i}return n}function h1(e,t){const n={};for(const i of t.attributes)if(i.type==="mdxJsxExpressionAttribute")if(i.data&&i.data.estree&&e.evaluater){const l=i.data.estree.body[0];l.type;const u=l.expression;u.type;const c=u.properties[0];c.type,Object.assign(n,e.evaluater.evaluateExpression(c.argument))}else Ti(e,t.position);else{const o=i.name;let l;if(i.value&&typeof i.value=="object")if(i.value.data&&i.value.data.estree&&e.evaluater){const c=i.value.data.estree.body[0];c.type,l=e.evaluater.evaluateExpression(c.expression)}else Ti(e,t.position);else l=i.value===null?!0:i.value;n[o]=l}return n}function Xm(e,t){const n=[];let i=-1;const o=e.passKeys?new Map:n1;for(;++io?0:o+t:t=t>o?o:t,n=n>0?n:0,i.length<1e4)u=Array.from(i),u.unshift(t,n),e.splice(...u);else for(n&&e.splice(t,n);l0?(dn(e,e.length,0,t),e):t}const jE={}.hasOwnProperty;function Qx(e){const t={};let n=-1;for(;++n13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}function On(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Ht=xr(/[A-Za-z]/),zt=xr(/[\dA-Za-z]/),x1=xr(/[#-'*+\--9=?A-Z^-~]/);function ls(e){return e!==null&&(e<32||e===127)}const Am=xr(/\d/),A1=xr(/[\dA-Fa-f]/),R1=xr(/[!-/:-@[-`{-~]/);function xe(e){return e!==null&&e<-2}function He(e){return e!==null&&(e<0||e===32)}function Fe(e){return e===-2||e===-1||e===32}const bs=xr(new RegExp("\\p{P}|\\p{S}","u")),Wr=xr(/\s/);function xr(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Oa(e){const t=[];let n=-1,i=0,o=0;for(;++n55295&&l<57344){const c=e.charCodeAt(n+1);l<56320&&c>56319&&c<57344?(u=String.fromCharCode(l,c),o=1):u="�"}else u=String.fromCharCode(l);u&&(t.push(e.slice(i,n),encodeURIComponent(u)),i=n+o+1,u=""),o&&(n+=o,o=0)}return t.join("")+e.slice(i)}function Pe(e,t,n,i){const o=i?i-1:Number.POSITIVE_INFINITY;let l=0;return u;function u(p){return Fe(p)?(e.enter(n),c(p)):t(p)}function c(p){return Fe(p)&&l++u))return;const B=t.events.length;let W=B,j,M;for(;W--;)if(t.events[W][0]==="exit"&&t.events[W][1].type==="chunkFlow"){if(j){M=t.events[W][1].end;break}j=!0}for(N(i),w=B;wA;){const L=n[O];t.containerState=L[1],L[0].exit.call(t,e)}n.length=A}function R(){o.write([null]),l=void 0,o=void 0,t.containerState._closeFlow=void 0}}function L1(e,t,n){return Pe(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Ra(e){if(e===null||He(e)||Wr(e))return 1;if(bs(e))return 2}function ys(e,t,n){const i=[];let o=-1;for(;++o1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const h={...e[i][1].end},S={...e[n][1].start};$E(h,-p),$E(S,p),u={type:p>1?"strongSequence":"emphasisSequence",start:h,end:{...e[i][1].end}},c={type:p>1?"strongSequence":"emphasisSequence",start:{...e[n][1].start},end:S},l={type:p>1?"strongText":"emphasisText",start:{...e[i][1].end},end:{...e[n][1].start}},o={type:p>1?"strong":"emphasis",start:{...u.start},end:{...c.end}},e[i][1].end={...u.start},e[n][1].start={...c.end},f=[],e[i][1].end.offset-e[i][1].start.offset&&(f=Sn(f,[["enter",e[i][1],t],["exit",e[i][1],t]])),f=Sn(f,[["enter",o,t],["enter",u,t],["exit",u,t],["enter",l,t]]),f=Sn(f,ys(t.parser.constructs.insideSpan.null,e.slice(i+1,n),t)),f=Sn(f,[["exit",l,t],["enter",c,t],["exit",c,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(m=2,f=Sn(f,[["enter",e[n][1],t],["exit",e[n][1],t]])):m=0,dn(e,i-1,n-i+3,f),n=i+f.length-m-2;break}}for(n=-1;++n0&&Fe(w)?Pe(e,R,"linePrefix",l+1)(w):R(w)}function R(w){return w===null||xe(w)?e.check(qE,k,O)(w):(e.enter("codeFlowValue"),A(w))}function A(w){return w===null||xe(w)?(e.exit("codeFlowValue"),R(w)):(e.consume(w),A)}function O(w){return e.exit("codeFenced"),t(w)}function L(w,B,W){let j=0;return M;function M(H){return w.enter("lineEnding"),w.consume(H),w.exit("lineEnding"),Y}function Y(H){return w.enter("codeFencedFence"),Fe(H)?Pe(w,J,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(H):J(H)}function J(H){return H===c?(w.enter("codeFencedFenceSequence"),de(H)):W(H)}function de(H){return H===c?(j++,w.consume(H),de):j>=u?(w.exit("codeFencedFenceSequence"),Fe(H)?Pe(w,Z,"whitespace")(H):Z(H)):W(H)}function Z(H){return H===null||xe(H)?(w.exit("codeFencedFence"),B(H)):W(H)}}}function H1(e,t,n){const i=this;return o;function o(u){return u===null?n(u):(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),l)}function l(u){return i.parser.lazy[i.now().line]?n(u):t(u)}}const bu={name:"codeIndented",tokenize:V1},W1={partial:!0,tokenize:Y1};function V1(e,t,n){const i=this;return o;function o(f){return e.enter("codeIndented"),Pe(e,l,"linePrefix",5)(f)}function l(f){const m=i.events[i.events.length-1];return m&&m[1].type==="linePrefix"&&m[2].sliceSerialize(m[1],!0).length>=4?u(f):n(f)}function u(f){return f===null?p(f):xe(f)?e.attempt(W1,u,p)(f):(e.enter("codeFlowValue"),c(f))}function c(f){return f===null||xe(f)?(e.exit("codeFlowValue"),u(f)):(e.consume(f),c)}function p(f){return e.exit("codeIndented"),t(f)}}function Y1(e,t,n){const i=this;return o;function o(u){return i.parser.lazy[i.now().line]?n(u):xe(u)?(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),o):Pe(e,l,"linePrefix",5)(u)}function l(u){const c=i.events[i.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?t(u):xe(u)?o(u):n(u)}}const K1={name:"codeText",previous:X1,resolve:Z1,tokenize:Q1};function Z1(e){let t=e.length-4,n=3,i,o;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(i=n;++i=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return tthis.left.length?this.right.slice(this.right.length-i+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-i+this.left.length).reverse())}splice(t,n,i){const o=n||0;this.setCursor(Math.trunc(t));const l=this.right.splice(this.right.length-o,Number.POSITIVE_INFINITY);return i&&hi(this.left,i),l.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),hi(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),hi(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t=4?t(u):e.interrupt(i.parser.constructs.flow,n,t)(u)}}function aA(e,t,n,i,o,l,u,c,p){const f=p||Number.POSITIVE_INFINITY;let m=0;return h;function h(N){return N===60?(e.enter(i),e.enter(o),e.enter(l),e.consume(N),e.exit(l),S):N===null||N===32||N===41||ls(N)?n(N):(e.enter(i),e.enter(u),e.enter(c),e.enter("chunkString",{contentType:"string"}),k(N))}function S(N){return N===62?(e.enter(l),e.consume(N),e.exit(l),e.exit(o),e.exit(i),t):(e.enter(c),e.enter("chunkString",{contentType:"string"}),E(N))}function E(N){return N===62?(e.exit("chunkString"),e.exit(c),S(N)):N===null||N===60||xe(N)?n(N):(e.consume(N),N===92?v:E)}function v(N){return N===60||N===62||N===92?(e.consume(N),E):E(N)}function k(N){return!m&&(N===null||N===41||He(N))?(e.exit("chunkString"),e.exit(c),e.exit(u),e.exit(i),t(N)):m999||E===null||E===91||E===93&&!p||E===94&&!c&&"_hiddenFootnoteSupport"in u.parser.constructs?n(E):E===93?(e.exit(l),e.enter(o),e.consume(E),e.exit(o),e.exit(i),t):xe(E)?(e.enter("lineEnding"),e.consume(E),e.exit("lineEnding"),m):(e.enter("chunkString",{contentType:"string"}),h(E))}function h(E){return E===null||E===91||E===93||xe(E)||c++>999?(e.exit("chunkString"),m(E)):(e.consume(E),p||(p=!Fe(E)),E===92?S:h)}function S(E){return E===91||E===92||E===93?(e.consume(E),c++,h):h(E)}}function oA(e,t,n,i,o,l){let u;return c;function c(S){return S===34||S===39||S===40?(e.enter(i),e.enter(o),e.consume(S),e.exit(o),u=S===40?41:S,p):n(S)}function p(S){return S===u?(e.enter(o),e.consume(S),e.exit(o),e.exit(i),t):(e.enter(l),f(S))}function f(S){return S===u?(e.exit(l),p(u)):S===null?n(S):xe(S)?(e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),Pe(e,f,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),m(S))}function m(S){return S===u||S===null||xe(S)?(e.exit("chunkString"),f(S)):(e.consume(S),S===92?h:m)}function h(S){return S===u||S===92?(e.consume(S),m):m(S)}}function vi(e,t){let n;return i;function i(o){return xe(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,i):Fe(o)?Pe(e,i,n?"linePrefix":"lineSuffix")(o):t(o)}}const o0={name:"definition",tokenize:l0},s0={partial:!0,tokenize:u0};function l0(e,t,n){const i=this;let o;return l;function l(E){return e.enter("definition"),u(E)}function u(E){return iA.call(i,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(E)}function c(E){return o=On(i.sliceSerialize(i.events[i.events.length-1][1]).slice(1,-1)),E===58?(e.enter("definitionMarker"),e.consume(E),e.exit("definitionMarker"),p):n(E)}function p(E){return He(E)?vi(e,f)(E):f(E)}function f(E){return aA(e,m,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(E)}function m(E){return e.attempt(s0,h,h)(E)}function h(E){return Fe(E)?Pe(e,S,"whitespace")(E):S(E)}function S(E){return E===null||xe(E)?(e.exit("definition"),i.parser.defined.push(o),t(E)):n(E)}}function u0(e,t,n){return i;function i(c){return He(c)?vi(e,o)(c):n(c)}function o(c){return oA(e,l,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(c)}function l(c){return Fe(c)?Pe(e,u,"whitespace")(c):u(c)}function u(c){return c===null||xe(c)?t(c):n(c)}}const c0={name:"hardBreakEscape",tokenize:d0};function d0(e,t,n){return i;function i(l){return e.enter("hardBreakEscape"),e.consume(l),o}function o(l){return xe(l)?(e.exit("hardBreakEscape"),t(l)):n(l)}}const p0={name:"headingAtx",resolve:f0,tokenize:g0};function f0(e,t){let n=e.length-2,i=3,o,l;return e[i][1].type==="whitespace"&&(i+=2),n-2>i&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(i===n-1||n-4>i&&e[n-2][1].type==="whitespace")&&(n-=i+1===n?2:4),n>i&&(o={type:"atxHeadingText",start:e[i][1].start,end:e[n][1].end},l={type:"chunkText",start:e[i][1].start,end:e[n][1].end,contentType:"text"},dn(e,i,n-i+1,[["enter",o,t],["enter",l,t],["exit",l,t],["exit",o,t]])),e}function g0(e,t,n){let i=0;return o;function o(m){return e.enter("atxHeading"),l(m)}function l(m){return e.enter("atxHeadingSequence"),u(m)}function u(m){return m===35&&i++<6?(e.consume(m),u):m===null||He(m)?(e.exit("atxHeadingSequence"),c(m)):n(m)}function c(m){return m===35?(e.enter("atxHeadingSequence"),p(m)):m===null||xe(m)?(e.exit("atxHeading"),t(m)):Fe(m)?Pe(e,c,"whitespace")(m):(e.enter("atxHeadingText"),f(m))}function p(m){return m===35?(e.consume(m),p):(e.exit("atxHeadingSequence"),c(m))}function f(m){return m===null||m===35||He(m)?(e.exit("atxHeadingText"),c(m)):(e.consume(m),f)}}const m0=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],HE=["pre","script","style","textarea"],h0={concrete:!0,name:"htmlFlow",resolveTo:E0,tokenize:S0},b0={partial:!0,tokenize:k0},y0={partial:!0,tokenize:v0};function E0(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function S0(e,t,n){const i=this;let o,l,u,c,p;return f;function f(C){return m(C)}function m(C){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(C),h}function h(C){return C===33?(e.consume(C),S):C===47?(e.consume(C),l=!0,k):C===63?(e.consume(C),o=3,i.interrupt?t:x):Ht(C)?(e.consume(C),u=String.fromCharCode(C),T):n(C)}function S(C){return C===45?(e.consume(C),o=2,E):C===91?(e.consume(C),o=5,c=0,v):Ht(C)?(e.consume(C),o=4,i.interrupt?t:x):n(C)}function E(C){return C===45?(e.consume(C),i.interrupt?t:x):n(C)}function v(C){const ae="CDATA[";return C===ae.charCodeAt(c++)?(e.consume(C),c===ae.length?i.interrupt?t:J:v):n(C)}function k(C){return Ht(C)?(e.consume(C),u=String.fromCharCode(C),T):n(C)}function T(C){if(C===null||C===47||C===62||He(C)){const ae=C===47,pe=u.toLowerCase();return!ae&&!l&&HE.includes(pe)?(o=1,i.interrupt?t(C):J(C)):m0.includes(u.toLowerCase())?(o=6,ae?(e.consume(C),N):i.interrupt?t(C):J(C)):(o=7,i.interrupt&&!i.parser.lazy[i.now().line]?n(C):l?R(C):A(C))}return C===45||zt(C)?(e.consume(C),u+=String.fromCharCode(C),T):n(C)}function N(C){return C===62?(e.consume(C),i.interrupt?t:J):n(C)}function R(C){return Fe(C)?(e.consume(C),R):M(C)}function A(C){return C===47?(e.consume(C),M):C===58||C===95||Ht(C)?(e.consume(C),O):Fe(C)?(e.consume(C),A):M(C)}function O(C){return C===45||C===46||C===58||C===95||zt(C)?(e.consume(C),O):L(C)}function L(C){return C===61?(e.consume(C),w):Fe(C)?(e.consume(C),L):A(C)}function w(C){return C===null||C===60||C===61||C===62||C===96?n(C):C===34||C===39?(e.consume(C),p=C,B):Fe(C)?(e.consume(C),w):W(C)}function B(C){return C===p?(e.consume(C),p=null,j):C===null||xe(C)?n(C):(e.consume(C),B)}function W(C){return C===null||C===34||C===39||C===47||C===60||C===61||C===62||C===96||He(C)?L(C):(e.consume(C),W)}function j(C){return C===47||C===62||Fe(C)?A(C):n(C)}function M(C){return C===62?(e.consume(C),Y):n(C)}function Y(C){return C===null||xe(C)?J(C):Fe(C)?(e.consume(C),Y):n(C)}function J(C){return C===45&&o===2?(e.consume(C),te):C===60&&o===1?(e.consume(C),ue):C===62&&o===4?(e.consume(C),D):C===63&&o===3?(e.consume(C),x):C===93&&o===5?(e.consume(C),Q):xe(C)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(b0,$,de)(C)):C===null||xe(C)?(e.exit("htmlFlowData"),de(C)):(e.consume(C),J)}function de(C){return e.check(y0,Z,$)(C)}function Z(C){return e.enter("lineEnding"),e.consume(C),e.exit("lineEnding"),H}function H(C){return C===null||xe(C)?de(C):(e.enter("htmlFlowData"),J(C))}function te(C){return C===45?(e.consume(C),x):J(C)}function ue(C){return C===47?(e.consume(C),u="",q):J(C)}function q(C){if(C===62){const ae=u.toLowerCase();return HE.includes(ae)?(e.consume(C),D):J(C)}return Ht(C)&&u.length<8?(e.consume(C),u+=String.fromCharCode(C),q):J(C)}function Q(C){return C===93?(e.consume(C),x):J(C)}function x(C){return C===62?(e.consume(C),D):C===45&&o===2?(e.consume(C),x):J(C)}function D(C){return C===null||xe(C)?(e.exit("htmlFlowData"),$(C)):(e.consume(C),D)}function $(C){return e.exit("htmlFlow"),t(C)}}function v0(e,t,n){const i=this;return o;function o(u){return xe(u)?(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),l):n(u)}function l(u){return i.parser.lazy[i.now().line]?n(u):t(u)}}function k0(e,t,n){return i;function i(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Ii,t,n)}}const _0={name:"htmlText",tokenize:w0};function w0(e,t,n){const i=this;let o,l,u;return c;function c(x){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(x),p}function p(x){return x===33?(e.consume(x),f):x===47?(e.consume(x),L):x===63?(e.consume(x),A):Ht(x)?(e.consume(x),W):n(x)}function f(x){return x===45?(e.consume(x),m):x===91?(e.consume(x),l=0,v):Ht(x)?(e.consume(x),R):n(x)}function m(x){return x===45?(e.consume(x),E):n(x)}function h(x){return x===null?n(x):x===45?(e.consume(x),S):xe(x)?(u=h,ue(x)):(e.consume(x),h)}function S(x){return x===45?(e.consume(x),E):h(x)}function E(x){return x===62?te(x):x===45?S(x):h(x)}function v(x){const D="CDATA[";return x===D.charCodeAt(l++)?(e.consume(x),l===D.length?k:v):n(x)}function k(x){return x===null?n(x):x===93?(e.consume(x),T):xe(x)?(u=k,ue(x)):(e.consume(x),k)}function T(x){return x===93?(e.consume(x),N):k(x)}function N(x){return x===62?te(x):x===93?(e.consume(x),N):k(x)}function R(x){return x===null||x===62?te(x):xe(x)?(u=R,ue(x)):(e.consume(x),R)}function A(x){return x===null?n(x):x===63?(e.consume(x),O):xe(x)?(u=A,ue(x)):(e.consume(x),A)}function O(x){return x===62?te(x):A(x)}function L(x){return Ht(x)?(e.consume(x),w):n(x)}function w(x){return x===45||zt(x)?(e.consume(x),w):B(x)}function B(x){return xe(x)?(u=B,ue(x)):Fe(x)?(e.consume(x),B):te(x)}function W(x){return x===45||zt(x)?(e.consume(x),W):x===47||x===62||He(x)?j(x):n(x)}function j(x){return x===47?(e.consume(x),te):x===58||x===95||Ht(x)?(e.consume(x),M):xe(x)?(u=j,ue(x)):Fe(x)?(e.consume(x),j):te(x)}function M(x){return x===45||x===46||x===58||x===95||zt(x)?(e.consume(x),M):Y(x)}function Y(x){return x===61?(e.consume(x),J):xe(x)?(u=Y,ue(x)):Fe(x)?(e.consume(x),Y):j(x)}function J(x){return x===null||x===60||x===61||x===62||x===96?n(x):x===34||x===39?(e.consume(x),o=x,de):xe(x)?(u=J,ue(x)):Fe(x)?(e.consume(x),J):(e.consume(x),Z)}function de(x){return x===o?(e.consume(x),o=void 0,H):x===null?n(x):xe(x)?(u=de,ue(x)):(e.consume(x),de)}function Z(x){return x===null||x===34||x===39||x===60||x===61||x===96?n(x):x===47||x===62||He(x)?j(x):(e.consume(x),Z)}function H(x){return x===47||x===62||He(x)?j(x):n(x)}function te(x){return x===62?(e.consume(x),e.exit("htmlTextData"),e.exit("htmlText"),t):n(x)}function ue(x){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),q}function q(x){return Fe(x)?Pe(e,Q,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(x):Q(x)}function Q(x){return e.enter("htmlTextData"),u(x)}}const eh={name:"labelEnd",resolveAll:R0,resolveTo:N0,tokenize:C0},T0={tokenize:I0},x0={tokenize:O0},A0={tokenize:L0};function R0(e){let t=-1;const n=[];for(;++t=3&&(f===null||xe(f))?(e.exit("thematicBreak"),t(f)):n(f)}function p(f){return f===o?(e.consume(f),i++,p):(e.exit("thematicBreakSequence"),Fe(f)?Pe(e,c,"whitespace")(f):c(f))}}const tn={continuation:{tokenize:q0},exit:H0,name:"list",tokenize:$0},j0={partial:!0,tokenize:W0},z0={partial:!0,tokenize:G0};function $0(e,t,n){const i=this,o=i.events[i.events.length-1];let l=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,u=0;return c;function c(E){const v=i.containerState.type||(E===42||E===43||E===45?"listUnordered":"listOrdered");if(v==="listUnordered"?!i.containerState.marker||E===i.containerState.marker:Am(E)){if(i.containerState.type||(i.containerState.type=v,e.enter(v,{_container:!0})),v==="listUnordered")return e.enter("listItemPrefix"),E===42||E===45?e.check(ns,n,f)(E):f(E);if(!i.interrupt||E===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),p(E)}return n(E)}function p(E){return Am(E)&&++u<10?(e.consume(E),p):(!i.interrupt||u<2)&&(i.containerState.marker?E===i.containerState.marker:E===41||E===46)?(e.exit("listItemValue"),f(E)):n(E)}function f(E){return e.enter("listItemMarker"),e.consume(E),e.exit("listItemMarker"),i.containerState.marker=i.containerState.marker||E,e.check(Ii,i.interrupt?n:m,e.attempt(j0,S,h))}function m(E){return i.containerState.initialBlankLine=!0,l++,S(E)}function h(E){return Fe(E)?(e.enter("listItemPrefixWhitespace"),e.consume(E),e.exit("listItemPrefixWhitespace"),S):n(E)}function S(E){return i.containerState.size=l+i.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(E)}}function q0(e,t,n){const i=this;return i.containerState._closeFlow=void 0,e.check(Ii,o,l);function o(c){return i.containerState.furtherBlankLines=i.containerState.furtherBlankLines||i.containerState.initialBlankLine,Pe(e,t,"listItemIndent",i.containerState.size+1)(c)}function l(c){return i.containerState.furtherBlankLines||!Fe(c)?(i.containerState.furtherBlankLines=void 0,i.containerState.initialBlankLine=void 0,u(c)):(i.containerState.furtherBlankLines=void 0,i.containerState.initialBlankLine=void 0,e.attempt(z0,t,u)(c))}function u(c){return i.containerState._closeFlow=!0,i.interrupt=void 0,Pe(e,e.attempt(tn,t,n),"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c)}}function G0(e,t,n){const i=this;return Pe(e,o,"listItemIndent",i.containerState.size+1);function o(l){const u=i.events[i.events.length-1];return u&&u[1].type==="listItemIndent"&&u[2].sliceSerialize(u[1],!0).length===i.containerState.size?t(l):n(l)}}function H0(e){e.exit(this.containerState.type)}function W0(e,t,n){const i=this;return Pe(e,o,"listItemPrefixWhitespace",i.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function o(l){const u=i.events[i.events.length-1];return!Fe(l)&&u&&u[1].type==="listItemPrefixWhitespace"?t(l):n(l)}}const WE={name:"setextUnderline",resolveTo:V0,tokenize:Y0};function V0(e,t){let n=e.length,i,o,l;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){i=n;break}e[n][1].type==="paragraph"&&(o=n)}else e[n][1].type==="content"&&e.splice(n,1),!l&&e[n][1].type==="definition"&&(l=n);const u={type:"setextHeading",start:{...e[i][1].start},end:{...e[e.length-1][1].end}};return e[o][1].type="setextHeadingText",l?(e.splice(o,0,["enter",u,t]),e.splice(l+1,0,["exit",e[i][1],t]),e[i][1].end={...e[l][1].end}):e[i][1]=u,e.push(["exit",u,t]),e}function Y0(e,t,n){const i=this;let o;return l;function l(f){let m=i.events.length,h;for(;m--;)if(i.events[m][1].type!=="lineEnding"&&i.events[m][1].type!=="linePrefix"&&i.events[m][1].type!=="content"){h=i.events[m][1].type==="paragraph";break}return!i.parser.lazy[i.now().line]&&(i.interrupt||h)?(e.enter("setextHeadingLine"),o=f,u(f)):n(f)}function u(f){return e.enter("setextHeadingLineSequence"),c(f)}function c(f){return f===o?(e.consume(f),c):(e.exit("setextHeadingLineSequence"),Fe(f)?Pe(e,p,"lineSuffix")(f):p(f))}function p(f){return f===null||xe(f)?(e.exit("setextHeadingLine"),t(f)):n(f)}}const K0={tokenize:Z0};function Z0(e){const t=this,n=e.attempt(Ii,i,e.attempt(this.parser.constructs.flowInitial,o,Pe(e,e.attempt(this.parser.constructs.flow,o,e.attempt(t0,o)),"linePrefix")));return n;function i(l){if(l===null){e.consume(l);return}return e.enter("lineEndingBlank"),e.consume(l),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(l){if(l===null){e.consume(l);return}return e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const X0={resolveAll:lA()},Q0=sA("string"),J0=sA("text");function sA(e){return{resolveAll:lA(e==="text"?eO:void 0),tokenize:t};function t(n){const i=this,o=this.parser.constructs[e],l=n.attempt(o,u,c);return u;function u(m){return f(m)?l(m):c(m)}function c(m){if(m===null){n.consume(m);return}return n.enter("data"),n.consume(m),p}function p(m){return f(m)?(n.exit("data"),l(m)):(n.consume(m),p)}function f(m){if(m===null)return!0;const h=o[m];let S=-1;if(h)for(;++S-1){const c=u[0];typeof c=="string"?u[0]=c.slice(i):u.shift()}l>0&&u.push(e[o].slice(0,l))}return u}function fO(e,t){let n=-1;const i=[];let o;for(;++n{u!==o&&u.remove()});for(const u of Object.keys(i))t.style.setProperty(u,i[u]);t.style.setProperty("color-scheme",e),t.setAttribute("data-theme",e),t.setAttribute("data-theme-type",e),n.setAttribute("data-theme",e),n.style.backgroundColor=ym[e],n.style.color=vx[e];const l=document.querySelector('meta[name="theme-color"]');l&&(l.setAttribute("content",ym[e]),l.removeAttribute("media"))}function wC(){try{const e=localStorage.getItem(Sx);if(e==="dark"||e==="light")return e}catch{}return window.matchMedia?.("(prefers-color-scheme: light)").matches?"light":"dark"}const kx=P.createContext({themeId:"dark",isDark:!0,setTheme:()=>{},toggleTheme:()=>{}}),TC=280;let pE;const xC=({children:e})=>{const[t,n]=P.useState(wC);P.useLayoutEffect(()=>{const l=document.documentElement,u=l.getAttribute("data-theme"),c=u&&u!==t;c&&(clearTimeout(pE),l.classList.add("theme-switching"),l.offsetHeight),_C(t),c&&(pE=setTimeout(()=>{l.classList.remove("theme-switching")},TC+40));try{localStorage.setItem(Sx,t)}catch{}},[t]);const i=P.useCallback(l=>n(l),[]),o=P.useCallback(()=>n(l=>l==="dark"?"light":"dark"),[]);return g.jsx(kx.Provider,{value:{themeId:t,isDark:t==="dark",setTheme:i,toggleTheme:o},children:e})};function Ca(){return P.useContext(kx)}const AC=({className:e})=>{const{language:t,toggleLanguage:n,t:i}=dt();return g.jsx("button",{type:"button",className:e||"mobile-lang-btn",onClick:n,"aria-label":i("common.switchLanguage"),title:i("common.switchLanguage"),children:t==="zh-CN"?"中":"EN"})};function RC(e){return e<=20?"sparo-mark-16.png":e<=28?"sparo-mark-24.png":e<=40?"sparo-mark-32.png":e<64?"sparo-mark-48.png":"sparo-mark-full.png"}function _x({size:e,alt:t="",draggable:n=!1,...i}){return g.jsx("img",{src:`./brand/${RC(e)}`,width:e,height:e,alt:t,draggable:n,...i})}function NC(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"}function wx(e,t=""){if(!Number.isSafeInteger(e)||e<0){const n=t&&`"${t}" `;throw new Error(`${n}expected integer >= 0, got ${e}`)}}function Ei(e,t,n=""){const i=NC(e),o=e?.length,l=t!==void 0;if(!i||l&&o!==t){const u=n&&`"${n}" `,c=l?` of length ${t}`:"",p=i?`length=${o}`:`type=${typeof e}`;throw new Error(u+"expected Uint8Array"+c+", got "+p)}return e}const Tx=typeof Uint8Array.from([]).toHex=="function"&&typeof Uint8Array.fromHex=="function",CC=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function IC(e){if(Ei(e),Tx)return e.toHex();let t="";for(let n=0;n=Xn._0&&e<=Xn._9)return e-Xn._0;if(e>=Xn.A&&e<=Xn.F)return e-(Xn.A-10);if(e>=Xn.a&&e<=Xn.f)return e-(Xn.a-10)}function OC(e){if(typeof e!="string")throw new Error("hex string expected, got "+typeof e);if(Tx)return Uint8Array.fromHex(e);const t=e.length,n=t/2;if(t%2)throw new Error("hex string expected, got unpadded hex of length "+t);const i=new Uint8Array(n);for(let o=0,l=0;otypeof e=="bigint"&&xx<=e;function UC(e,t,n){return ts(e)&&ts(t)&&ts(n)&&t<=e&&eObject.entries(l).forEach(([c,p])=>i(c,p,u));o(t,!1),o(n,!0)}const Ax=BigInt(0);function Rx(e,t){const n=e%t;return n>=Ax?n:t+n}function In(e,t,n){let i=e;for(;t-- >Ax;)i*=i,i%=n;return i}function jC(e,t){return function(i){const o=e(i);return{secretKey:o,publicKey:t(o)}}}const fi=BigInt(0),Ea=BigInt(1),$o=BigInt(2);function zC(e){return BC(e,{adjustScalarBytes:"function",powPminus2:"function"}),Object.freeze({...e})}function $C(e){const t=zC(e),{P:n,type:i,adjustScalarBytes:o,powPminus2:l,randomBytes:u}=t,c=i==="x25519";if(!c&&i!=="x448")throw new Error("invalid type");const p=u||LC,f=c?255:448,m=c?32:56,h=BigInt(c?9:5),S=BigInt(c?121665:39081),E=c?$o**BigInt(254):$o**BigInt(447),v=c?BigInt(8)*$o**BigInt(251)-Ea:BigInt(4)*$o**BigInt(445)-Ea,k=E+v+Ea,T=Z=>Rx(Z,n),N=R(h);function R(Z){return PC(T(Z),m)}function A(Z){const H=Em(Ei(Z,m,"uCoordinate"));return c&&(H[31]&=127),T(gE(H))}function O(Z){return gE(o(Em(Ei(Z,m,"scalar"))))}function L(Z,H){const te=M(A(H),O(Z));if(te===fi)throw new Error("invalid private or public key received");return R(te)}function w(Z){return L(Z,N)}const B=w,W=L;function j(Z,H,te){const ue=T(Z*(H-te));return H=T(H-ue),te=T(te+ue),{x_2:H,x_3:te}}function M(Z,H){mE("u",Z,fi,n),mE("scalar",H,E,k);const te=H,ue=Z;let q=Ea,Q=fi,x=Z,D=Ea,$=fi;for(let ae=BigInt(f-1);ae>=fi;ae--){const pe=te>>ae&Ea;$^=pe,{x_2:q,x_3:x}=j($,q,x),{x_2:Q,x_3:D}=j($,Q,D),$=pe;const fe=q+Q,Se=T(fe*fe),ke=q-Q,X=T(ke*ke),he=Se-X,Ie=x+D,Qe=x-D,Ce=T(Qe*fe),$e=T(Ie*ke),pt=Ce+$e,tt=Ce-$e;x=T(pt*pt),D=T(ue*T(tt*tt)),q=T(Se*X),Q=T(he*(Se+T(S*he)))}({x_2:q,x_3:x}=j($,q,x)),{x_2:Q,x_3:D}=j($,Q,D);const C=l(Q);return T(q*C)}const Y={secretKey:m,publicKey:m,seed:m},J=(Z=p(m))=>(Ei(Z,Y.seed,"seed"),Z),de={randomSecretKey:J};return Object.freeze({keygen:jC(J,B),getSharedSecret:W,getPublicKey:B,scalarMult:L,scalarMultBase:w,utils:de,GuBytes:N.slice(),lengths:Y})}const qC=BigInt(1),hE=BigInt(2),GC=BigInt(3),HC=BigInt(5);BigInt(8);const Nx=BigInt("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed");function WC(e){const t=BigInt(10),n=BigInt(20),i=BigInt(40),o=BigInt(80),l=Nx,c=e*e%l*e%l,p=In(c,hE,l)*c%l,f=In(p,qC,l)*e%l,m=In(f,HC,l)*f%l,h=In(m,t,l)*m%l,S=In(h,n,l)*h%l,E=In(S,i,l)*S%l,v=In(E,o,l)*E%l,k=In(v,o,l)*E%l,T=In(k,t,l)*m%l;return{pow_p_5_8:In(T,hE,l)*e%l,b2:c}}function VC(e){return e[0]&=248,e[31]&=127,e[31]|=64,e}const Cx=(()=>{const e=Nx;return $C({P:e,type:"x25519",powPminus2:t=>{const{pow_p_5_8:n,b2:i}=WC(t);return Rx(In(n,GC,e)*i,e)},adjustScalarBytes:VC})})();function YC(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"}function nn(e,t,n=""){const i=YC(e),o=e?.length,l=t!==void 0;if(!i||l&&o!==t){const u=n&&`"${n}" `,c=l?` of length ${t}`:"",p=i?`length=${o}`:`type=${typeof e}`;throw new Error(u+"expected Uint8Array"+c+", got "+p)}return e}function os(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")}function Ix(e,t){nn(e,void 0,"output");const n=t.outputLen;if(e.length{function n(i,...o){if(nn(i,void 0,"key"),!ZC)throw new Error("Non little-endian hardware is not yet supported");if(e.nonceLength!==void 0){const m=o[0];nn(m,e.varSizeNonce?void 0:e.nonceLength,"nonce")}const l=e.tagLength;l&&o[1]!==void 0&&nn(o[1],void 0,"AAD");const u=t(i,...o),c=(m,h)=>{if(h!==void 0){if(m!==2)throw new Error("cipher output not supported");nn(h,void 0,"output")}};let p=!1;return{encrypt(m,h){if(p)throw new Error("cannot encrypt() twice with same key + nonce");return p=!0,nn(m),c(u.encrypt.length,h),u.encrypt(m,h)},decrypt(m,h){if(nn(m),l&&m.length{const o=i&1;return{s3:n<<31|i>>>1,s2:t<<31|n>>>1,s1:e<<31|t>>>1,s0:e>>>1^tI<<24&-(o&1)}},En=e=>(e>>>0&255)<<24|(e>>>8&255)<<16|(e>>>16&255)<<8|e>>>24&255|0;function rI(e){e.reverse();const t=e[15]&1;let n=0;for(let i=0;i>>1|n,n=(o&1)<<7}return e[0]^=-t&225,e}const aI=e=>e>64*1024?8:e>1024?4:2;class Ox{blockLen=Jn;outputLen=Jn;s0=0;s1=0;s2=0;s3=0;finished=!1;t;W;windowSize;constructor(t,n){nn(t,16,"key"),t=Hr(t);const i=hs(t);let o=i.getUint32(0,!1),l=i.getUint32(4,!1),u=i.getUint32(8,!1),c=i.getUint32(12,!1);const p=[];for(let v=0;v<128;v++)p.push({s0:En(o),s1:En(l),s2:En(u),s3:En(c)}),{s0:o,s1:l,s2:u,s3:c}=nI(o,l,u,c);const f=aI(n||1024);if(![1,2,4,8].includes(f))throw new Error("ghash: invalid window size, expected 2, 4 or 8");this.W=f;const h=128/f,S=this.windowSize=2**f,E=[];for(let v=0;v>>f-O-1&1))continue;const{s0:w,s1:B,s2:W,s3:j}=p[f*v+O];T^=w,N^=B,R^=W,A^=j}E.push({s0:T,s1:N,s2:R,s3:A})}this.t=E}_updateBlock(t,n,i,o){t^=this.s0,n^=this.s1,i^=this.s2,o^=this.s3;const{W:l,t:u,windowSize:c}=this;let p=0,f=0,m=0,h=0;const S=(1<>>8*k&255;for(let N=8/l-1;N>=0;N--){const R=T>>>l*N&S,{s0:A,s1:O,s2:L,s3:w}=u[E*c+R];p^=A,f^=O,m^=L,h^=w,E+=1}}this.s0=p,this.s1=f,this.s2=m,this.s3=h}update(t){os(this),nn(t),t=Hr(t);const n=er(t),i=Math.floor(t.length/Jn),o=t.length%Jn;for(let l=0;le(o,i.length).update(i).digest(),n=e(new Uint8Array(16),0);return t.outputLen=n.outputLen,t.blockLen=n.blockLen,t.create=(i,o)=>e(i,o),t}const bE=Lx((e,t)=>new Ox(e,t));Lx((e,t)=>new iI(e,t));const Sm=16,oI=4,qo=new Uint8Array(Sm),sI=283;function lI(e){if(![16,24,32].includes(e.length))throw new Error('"aes key" expected Uint8Array of length 16/24/32, got length='+e.length)}function Hm(e){return e<<1^sI&-(e>>7)}function yE(e,t){let n=0;for(;t>0;t>>=1)n^=e&-(t&1),e=Hm(e);return n}const uI=(()=>{const e=new Uint8Array(256);for(let n=0,i=1;n<256;n++,i^=Hm(i))e[n]=i;const t=new Uint8Array(256);t[0]=99;for(let n=0;n<255;n++){let i=e[255-n];i|=i<<8,t[e[n]]=(i^i>>4^i>>5^i>>6^i>>7^99)&255}return tr(e),t})(),cI=e=>e<<24|e>>>8,du=e=>e<<8|e>>>24;function dI(e,t){if(e.length!==256)throw new Error("Wrong sbox length");const n=new Uint32Array(256).map((f,m)=>t(e[m])),i=n.map(du),o=i.map(du),l=o.map(du),u=new Uint32Array(256*256),c=new Uint32Array(256*256),p=new Uint16Array(256*256);for(let f=0;f<256;f++)for(let m=0;m<256;m++){const h=f*256+m;u[h]=n[f]^i[m],c[h]=o[f]^l[m],p[h]=e[f]<<8|e[m]}return{sbox:e,sbox2:p,T0:n,T1:i,T2:o,T3:l,T01:u,T23:c}}const Dx=dI(uI,e=>yE(e,3)<<24|e<<16|e<<8|yE(e,2)),pI=(()=>{const e=new Uint8Array(16);for(let t=0,n=1;t<16;t++,n=Hm(n))e[t]=n;return e})();function fI(e){nn(e);const t=e.length;lI(e);const{sbox2:n}=Dx,i=[];ss(e)||i.push(e=Hr(e));const o=er(e),l=o.length,u=p=>yi(n,p,p,p,p),c=new Uint32Array(t+28);c.set(o);for(let p=l;p6&&p%l===4&&(f=u(f)),c[p]=c[p-l]^f}return tr(...i),c}function Go(e,t,n,i,o,l){return e[n<<8&65280|i>>>8&255]^t[o>>>8&65280|l>>>24&255]}function yi(e,t,n,i,o){return e[t&255|n&65280]|e[i>>>16&255|o>>>16&65280]<<16}function EE(e,t,n,i,o){const{sbox2:l,T01:u,T23:c}=Dx;let p=0;t^=e[p++],n^=e[p++],i^=e[p++],o^=e[p++];const f=e.length/4-2;for(let v=0;v>>0,c.setUint32(m,S,t),{s0:E,s1:v,s2:k,s3:T}=EE(e,u[0],u[1],u[2],u[3]);const N=Sm*Math.floor(p.length/oI);if(Nt+=String.fromCharCode(n)),btoa(t)}function km(e){const t=atob(e),n=new Uint8Array(t.length);for(let i=0;io.agent_type==="OSAgent");return i?i.session_id:this.createSession("OSAgent","Sparo OS",t)}async getSessionMessages(t,n,i){const o=await this.request({cmd:"get_session_messages",session_id:t,limit:n,before_message_id:i});return{messages:o.messages||[],has_more:o.has_more||!1}}async getModelCatalog(t){return(await this.request({cmd:"get_model_catalog",session_id:t??void 0})).catalog}async setSessionModel(t,n){return(await this.request({cmd:"set_session_model",session_id:t,model_id:n})).model_id}async sendMessage(t,n,i,o){return(await this.request({cmd:"send_message",session_id:t,content:n,agent_type:i||void 0,image_contexts:o&&o.length>0?o:void 0})).turn_id}async cancelTask(t,n){await this.request({cmd:"cancel_task",session_id:t,turn_id:n??void 0})}async cancelTool(t,n){await this.request({cmd:"cancel_tool",tool_id:t,reason:n??void 0})}async deleteSession(t){await this.request({cmd:"delete_session",session_id:t})}async answerQuestion(t,n){await this.request({cmd:"answer_question",tool_id:t,answers:n})}async pollSession(t,n,i,o=0){return this.request({cmd:"poll_session",session_id:t,since_version:n,known_msg_count:i,known_model_catalog_version:o})}async ping(){await this.request({cmd:"ping"})}async getFileInfo(t,n){const i=await this.request({cmd:"get_file_info",path:t,session_id:n??void 0});return{name:i.name,size:i.size,mimeType:i.mime_type}}async readFile(t,n,i){let l=0;const u=[];let c="",p="",f=0;for(;;){const m=await this.request({cmd:"read_file_chunk",path:t,session_id:n??void 0,offset:l,limit:3145728});if(u.push(m.chunk_base64),c=m.name,p=m.mime_type,f=m.total_size,l+=m.chunk_size,i?.(Math.min(l,f),f),l>=f||m.chunk_size===0)break}return{name:c,contentBase64:u.join(""),mimeType:p,size:f}}}class SI{intervalId=null;sinceVersion=0;knownMsgCount=0;sessionId;sessionMgr;onUpdate;polling=!1;stopped=!1;hasActiveTurn=!1;knownModelCatalogVersion=0;turnJustEndedAt=null;TURN_JUST_ENDED_GRACE_PERIOD_MS=5e3;constructor(t,n,i,o=0){this.sessionMgr=t,this.sessionId=n,this.onUpdate=i,this.knownModelCatalogVersion=o}start(t=0){this.stopped=!1,this.knownMsgCount=t,this.tick(),document.addEventListener("visibilitychange",this.onVisibilityChange)}stop(){this.stopped=!0,this.intervalId!==null&&(clearTimeout(this.intervalId),this.intervalId=null),document.removeEventListener("visibilitychange",this.onVisibilityChange)}resetCursors(){this.sinceVersion=0,this.knownMsgCount=0}setKnownModelCatalogVersion(t){this.knownModelCatalogVersion=t}nudge(){this.hasActiveTurn=!0,this.intervalId!==null&&clearTimeout(this.intervalId),this.tick()}getInterval(){if(document.visibilityState!=="visible")return 5e3;const t=Date.now();return this.turnJustEndedAt!=null&&t-this.turnJustEndedAtthis.tick(),this.getInterval()))}onVisibilityChange=()=>{this.stopped||(document.visibilityState==="visible"?(this.intervalId!==null&&clearTimeout(this.intervalId),this.tick()):this.scheduleNext())};async tick(){if(this.stopped||this.polling){this.scheduleNext();return}this.polling=!0;try{const t=await this.sessionMgr.pollSession(this.sessionId,this.sinceVersion,this.knownMsgCount,this.knownModelCatalogVersion);if(t.changed){const n=this.hasActiveTurn,i=t.active_turn!=null&&t.active_turn.status==="active";this.hasActiveTurn=i,n&&!i&&(this.turnJustEndedAt=Date.now()),t.new_messages&&t.new_messages.length>0&&(this.turnJustEndedAt=null),this.sinceVersion=t.version,t.total_msg_count!=null&&(this.knownMsgCount=t.total_msg_count),t.model_catalog?.version!=null&&(this.knownModelCatalogVersion=t.model_catalog.version),this.onUpdate(t)}}catch(t){console.error("[Poller] poll error",t)}finally{this.polling=!1,this.scheduleNext()}}}const vE=e=>{let t;const n=new Set,i=(f,m)=>{const h=typeof f=="function"?f(t):f;if(!Object.is(h,t)){const S=t;t=m??(typeof h!="object"||h===null)?h:Object.assign({},t,h),n.forEach(E=>E(t,S))}},o=()=>t,c={setState:i,getState:o,getInitialState:()=>p,subscribe:f=>(n.add(f),()=>n.delete(f))},p=t=e(i,o,c);return c},vI=(e=>e?vE(e):vE),kI=e=>e;function _I(e,t=kI){const n=ct.useSyncExternalStore(e.subscribe,ct.useCallback(()=>t(e.getState()),[e,t]),ct.useCallback(()=>t(e.getInitialState()),[e,t]));return ct.useDebugValue(n),n}const kE=e=>{const t=vI(e),n=i=>_I(t,i);return Object.assign(n,t),n},Px=(e=>e?kE(e):kE),vn=Px((e,t)=>({connectionStatus:"idle",setConnectionStatus:n=>e({connectionStatus:n}),selectedWorkspace:null,setSelectedWorkspace:n=>e({selectedWorkspace:n}),authenticatedUserId:null,setAuthenticatedUserId:n=>e({authenticatedUserId:n}),sessions:[],setSessions:n=>e({sessions:n}),appendSessions:n=>e(i=>({sessions:[...i.sessions,...n]})),updateSessionName:(n,i)=>e(o=>({sessions:o.sessions.map(l=>l.session_id===n?{...l,name:i}:l)})),activeSessionId:null,setActiveSessionId:n=>e({activeSessionId:n}),messagesBySession:{},getMessages:n=>t().messagesBySession[n]||[],setMessages:(n,i)=>e(o=>({messagesBySession:{...o.messagesBySession,[n]:i}})),appendNewMessages:(n,i)=>e(o=>{if(i.length===0)return o;const l=o.messagesBySession[n]||[],u=new Set(l.map(p=>p.id)),c=i.filter(p=>!u.has(p.id));return c.length===0?o:{messagesBySession:{...o.messagesBySession,[n]:[...l,...c]}}}),activeTurn:null,setActiveTurn:n=>e({activeTurn:n}),error:null,setError:n=>e({error:n})})),_E="sparo.mobile.install_id",wE="sparo.mobile.user_id",zr="sparo.mobile.user_id_lock_until",Sa="sparo.mobile.user_id_failure_count",wI=3,TE=6e4;function TI(e){return e.includes("This remote URL is already protected")||e.includes("This mobile device must continue using the previously confirmed user ID")}function xI(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?crypto.randomUUID():`mobile-${Date.now().toString(36)}-${Math.random().toString(36).slice(2,10)}`}function xE(){const e=localStorage.getItem(_E)?.trim();if(e)return e;const t=xI();return localStorage.setItem(_E,t),t}function AI(){const e=window.location.hash,t=new URLSearchParams(e.replace(/^#\/pair\?/,"")),n=t.get("room"),i=t.get("pk"),o=t.get("relay");if(o)return{room:n,pk:i,httpBaseUrl:o.replace(/^wss:\/\//,"https://").replace(/^ws:\/\//,"http://").replace(/\/ws\/?$/,"").replace(/\/$/,"")};const l=window.location.origin,u=window.location.pathname.replace(/\/[^/]*$/,"").replace(/\/r\/[^/]*$/,"");return{room:n,pk:i,httpBaseUrl:l+u}}const RI=({onPaired:e})=>{const{t}=dt(),{connectionStatus:n,setConnectionStatus:i,setError:o,error:l,setAuthenticatedUserId:u}=vn(),[c,p]=P.useState(""),[f,m]=P.useState(""),[h,S]=P.useState(!1),[E,v]=P.useState(0),[k,T]=P.useState(null),[N,R]=P.useState(()=>Date.now()),A=P.useRef(!1),O=P.useRef(0),L=P.useRef(null),w=P.useMemo(()=>AI(),[]),B=!!k&&k>N,W=B?Math.max(1,Math.ceil((k-N)/1e3)):0,j=P.useCallback(async(Z,H)=>{const te=Z.trim(),ue=H?.autoReconnect===!0,q=H?.installId||f||xE(),Q=L.current,x=!!Q&&Q>Date.now(),D=x?Math.max(1,Math.ceil((Q-Date.now())/1e3)):0;if(!w.room||!w.pk){o(t("pairing.invalidQrCode")),i("error");return}if(!te){o(t("pairing.userIdRequired")),i("error");return}if(!ue&&x){o(t("pairing.tooManyAttempts",{seconds:D})),i("error");return}m(q),S(!0);const $=new yI(w.httpBaseUrl,w.room);try{o(null),i("pairing");const C=await $.pair(w.pk,{userId:te,mobileInstallId:q});i("paired"),localStorage.setItem(wE,te),localStorage.removeItem(Sa),localStorage.removeItem(zr),v(0),T(null),u(C.authenticated_user_id??te);const ae=new EI($),pe=vn.getState();C.has_workspace&&pe.setSelectedWorkspace({has_workspace:!0,path:C.path,project_name:C.project_name,git_branch:C.git_branch,workspace_kind:C.workspace_kind}),C.sessions&&pe.setSessions(C.sessions),e($,ae)}catch(C){const ae=C?.message||t("pairing.pairingFailed");if(!ue&&TI(ae)){const pe=O.current+1,fe=pe>=wI,Se=fe?Date.now()+TE:null;localStorage.setItem(Sa,String(pe)),Se?localStorage.setItem(zr,String(Se)):localStorage.removeItem(zr),v(pe),T(Se),o(fe?t("pairing.tooManyAttempts",{seconds:Math.ceil(TE/1e3)}):ae)}else o(ae);i("error")}finally{S(!1)}},[f,w.httpBaseUrl,w.pk,w.room,u,i,o,t]);P.useEffect(()=>{const Z=localStorage.getItem(wE)?.trim()??"",H=xE(),te=Number(localStorage.getItem(Sa)||"0"),ue=Number(localStorage.getItem(zr)||"0"),q=ue>Date.now()?ue:null;ue&&!q&&(localStorage.removeItem(zr),localStorage.removeItem(Sa));const Q=!!Z&&!!H&&!!w.room&&!!w.pk;p(Z),m(H),v(q?te:0),T(q),i(Q?"pairing":"idle"),o(null),Q&&!A.current&&(A.current=!0,j(Z,{autoReconnect:!0,installId:H}))},[j,w.pk,w.room,i,o]),P.useEffect(()=>{O.current=E,L.current=k},[E,k]),P.useEffect(()=>{if(!k)return;if(k<=Date.now()){T(null),v(0),localStorage.removeItem(zr),localStorage.removeItem(Sa);return}const Z=window.setInterval(()=>{const H=Date.now();R(H),k<=H&&(T(null),v(0),localStorage.removeItem(zr),localStorage.removeItem(Sa))},1e3);return()=>window.clearInterval(Z)},[k]);const M=async()=>{A.current=!0,await j(c,{autoReconnect:!1})},Y={idle:t("pairing.enterUserIdToContinue"),pairing:t("pairing.connectingAndPairing"),paired:t("pairing.pairedLoadingSessions"),error:t("pairing.connectionError")},J=n==="pairing",de=n==="idle"||n==="error";return g.jsxs("div",{className:"pairing-page",children:[g.jsx("div",{className:"pairing-page__actions",children:g.jsx(AC,{})}),g.jsx("div",{className:"pairing-page__mark",children:g.jsx(_x,{size:72,alt:"Sparo OS",className:"pairing-page__logo-img"})}),g.jsx("div",{className:"pairing-page__brand",children:g.jsxs("div",{className:"pairing-page__brand-slogan",children:[g.jsx("span",{className:"pairing-page__slogan-dot","aria-hidden":"true"}),t("common.slogan")]})}),g.jsx("div",{className:"pairing-page__spinner-wrap",children:J&&g.jsx("div",{className:"pairing-page__orbit-spinner"})}),g.jsx("div",{className:"pairing-page__state",children:Y[n]||n}),l&&g.jsxs("div",{className:"pairing-page__error",children:[g.jsx("span",{className:"pairing-page__error-dot","aria-hidden":"true"}),l]}),de&&g.jsxs("div",{className:"pairing-page__form",children:[g.jsxs("label",{className:"pairing-page__field",children:[g.jsx("span",{className:"pairing-page__field-label",children:t("pairing.fieldLabel")}),g.jsx("input",{className:"pairing-page__input",type:"text",value:c,onChange:Z=>p(Z.target.value),onKeyDown:Z=>{Z.key==="Enter"&&M()},placeholder:t("pairing.placeholder"),autoCapitalize:"off",autoCorrect:"off",autoComplete:"username",disabled:h||B})]}),g.jsx("p",{className:"pairing-page__note",children:t("pairing.note")}),g.jsxs("button",{className:"pairing-page__submit",onClick:()=>{M()},disabled:h||B,children:[g.jsx("span",{className:"pairing-page__submit-dot","aria-hidden":"true"}),h?t("pairing.connecting"):B?t("pairing.retryIn",{seconds:W}):t("pairing.continue")]})]})]})},NI=["app:skills","app:memory","app:shell","app:settings","me","search"];function fu(e){return NI.includes(e)}const Bn=Px((e,t)=>({activeScene:"home",pageStack:["home"],sessionContext:null,push(n){e(i=>({activeScene:n,pageStack:[...i.pageStack,n]})),history.pushState({scene:n},"")},pop(){const{pageStack:n}=t();if(n.length<=1)return;const i=n[n.length-2];e(o=>({activeScene:i,pageStack:o.pageStack.slice(0,-1)})),history.back()},closeOverlay(){const{activeScene:n,pageStack:i}=t();if(!fu(n))return;const o=i.slice().reverse().find(u=>!fu(u))??"home",l=i.filter(u=>!fu(u));e({activeScene:o,pageStack:l.length?l:["home"]}),history.back()},openAgenticOs(){e({activeScene:"home",pageStack:["home"],sessionContext:null}),history.pushState({scene:"home"},"")},setSessionContext(n){e({sessionContext:n})},openChat(n){e(i=>({activeScene:"chat",pageStack:[...i.pageStack,"chat"],sessionContext:n})),history.pushState({scene:"chat"},"")}})),CI="modulepreload",II=function(e,t){return new URL(e,t).href},AE={},OI=function(t,n,i){let o=Promise.resolve();if(n&&n.length>0){let f=function(m){return Promise.all(m.map(h=>Promise.resolve(h).then(S=>({status:"fulfilled",value:S}),S=>({status:"rejected",reason:S}))))};const u=document.getElementsByTagName("link"),c=document.querySelector("meta[property=csp-nonce]"),p=c?.nonce||c?.getAttribute("nonce");o=f(n.map(m=>{if(m=II(m,i),m in AE)return;AE[m]=!0;const h=m.endsWith(".css"),S=h?'[rel="stylesheet"]':"";if(i)for(let v=u.length-1;v>=0;v--){const k=u[v];if(k.href===m&&(!h||k.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${m}"]${S}`))return;const E=document.createElement("link");if(E.rel=h?"stylesheet":CI,h||(E.as="script"),E.crossOrigin="",E.href=m,p&&E.setAttribute("nonce",p),document.head.appendChild(E),h)return new Promise((v,k)=>{E.addEventListener("load",v),E.addEventListener("error",()=>k(new Error(`Unable to preload CSS for ${m}`)))})}))}function l(u){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=u,window.dispatchEvent(c),!c.defaultPrevented)throw u}return o.then(u=>{for(const c of u||[])c.status==="rejected"&&l(c.reason);return t().catch(l)})};function LI(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const DI=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,MI=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,FI={};function RE(e,t){return(FI.jsx?MI:DI).test(e)}const PI=/[ \t\n\f\r]/g;function UI(e){return typeof e=="object"?e.type==="text"?NE(e.value):!1:NE(e)}function NE(e){return e.replace(PI,"")===""}class Ci{constructor(t,n,i){this.normal=n,this.property=t,i&&(this.space=i)}}Ci.prototype.normal={};Ci.prototype.property={};Ci.prototype.space=void 0;function Ux(e,t){const n={},i={};for(const o of e)Object.assign(n,o.property),Object.assign(i,o.normal);return new Ci(n,i,t)}function _m(e){return e.toLowerCase()}class rn{constructor(t,n){this.attribute=n,this.property=t}}rn.prototype.attribute="";rn.prototype.booleanish=!1;rn.prototype.boolean=!1;rn.prototype.commaOrSpaceSeparated=!1;rn.prototype.commaSeparated=!1;rn.prototype.defined=!1;rn.prototype.mustUseProperty=!1;rn.prototype.number=!1;rn.prototype.overloadedBoolean=!1;rn.prototype.property="";rn.prototype.spaceSeparated=!1;rn.prototype.space=void 0;let BI=0;const Re=Vr(),vt=Vr(),wm=Vr(),le=Vr(),Ye=Vr(),Ta=Vr(),cn=Vr();function Vr(){return 2**++BI}const Tm=Object.freeze(Object.defineProperty({__proto__:null,boolean:Re,booleanish:vt,commaOrSpaceSeparated:cn,commaSeparated:Ta,number:le,overloadedBoolean:wm,spaceSeparated:Ye},Symbol.toStringTag,{value:"Module"})),gu=Object.keys(Tm);class Wm extends rn{constructor(t,n,i,o){let l=-1;if(super(t,n),CE(this,"space",o),typeof i=="number")for(;++l4&&n.slice(0,4)==="data"&&GI.test(t)){if(t.charAt(4)==="-"){const l=t.slice(5).replace(IE,VI);i="data"+l.charAt(0).toUpperCase()+l.slice(1)}else{const l=t.slice(4);if(!IE.test(l)){let u=l.replace(qI,WI);u.charAt(0)!=="-"&&(u="-"+u),t="data"+u}}o=Wm}return new o(i,t)}function WI(e){return"-"+e.toLowerCase()}function VI(e){return e.charAt(1).toUpperCase()}const YI=Ux([Bx,jI,$x,qx,Gx],"html"),Vm=Ux([Bx,zI,$x,qx,Gx],"svg");function KI(e){return e.join(" ").trim()}var va={},mu,OE;function ZI(){if(OE)return mu;OE=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,i=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,l=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,u=/^[;\s]*/,c=/^\s+|\s+$/g,p=`
+`,f="/",m="*",h="",S="comment",E="declaration";function v(T,N){if(typeof T!="string")throw new TypeError("First argument must be a string");if(!T)return[];N=N||{};var R=1,A=1;function O(Z){var H=Z.match(t);H&&(R+=H.length);var te=Z.lastIndexOf(p);A=~te?Z.length-te:A+Z.length}function L(){var Z={line:R,column:A};return function(H){return H.position=new w(Z),j(),H}}function w(Z){this.start=Z,this.end={line:R,column:A},this.source=N.source}w.prototype.content=T;function B(Z){var H=new Error(N.source+":"+R+":"+A+": "+Z);if(H.reason=Z,H.filename=N.source,H.line=R,H.column=A,H.source=T,!N.silent)throw H}function W(Z){var H=Z.exec(T);if(H){var te=H[0];return O(te),T=T.slice(te.length),H}}function j(){W(n)}function M(Z){var H;for(Z=Z||[];H=Y();)H!==!1&&Z.push(H);return Z}function Y(){var Z=L();if(!(f!=T.charAt(0)||m!=T.charAt(1))){for(var H=2;h!=T.charAt(H)&&(m!=T.charAt(H)||f!=T.charAt(H+1));)++H;if(H+=2,h===T.charAt(H-1))return B("End of comment missing");var te=T.slice(2,H-2);return A+=2,O(te),T=T.slice(H),A+=2,Z({type:S,comment:te})}}function J(){var Z=L(),H=W(i);if(H){if(Y(),!W(o))return B("property missing ':'");var te=W(l),ue=Z({type:E,property:k(H[0].replace(e,h)),value:te?k(te[0].replace(e,h)):h});return W(u),ue}}function de(){var Z=[];M(Z);for(var H;H=J();)H!==!1&&(Z.push(H),M(Z));return Z}return j(),de()}function k(T){return T?T.replace(c,h):h}return mu=v,mu}var LE;function XI(){if(LE)return va;LE=1;var e=va&&va.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(va,"__esModule",{value:!0}),va.default=n;const t=e(ZI());function n(i,o){let l=null;if(!i||typeof i!="string")return l;const u=(0,t.default)(i),c=typeof o=="function";return u.forEach(p=>{if(p.type!=="declaration")return;const{property:f,value:m}=p;c?o(f,m,p):m&&(l=l||{},l[f]=m)}),l}return va}var gi={},DE;function QI(){if(DE)return gi;DE=1,Object.defineProperty(gi,"__esModule",{value:!0}),gi.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,i=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,l=function(f){return!f||n.test(f)||e.test(f)},u=function(f,m){return m.toUpperCase()},c=function(f,m){return"".concat(m,"-")},p=function(f,m){return m===void 0&&(m={}),l(f)?f:(f=f.toLowerCase(),m.reactCompat?f=f.replace(o,c):f=f.replace(i,c),f.replace(t,u))};return gi.camelCase=p,gi}var mi,ME;function JI(){if(ME)return mi;ME=1;var e=mi&&mi.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},t=e(XI()),n=QI();function i(o,l){var u={};return!o||typeof o!="string"||(0,t.default)(o,function(c,p){c&&p&&(u[(0,n.camelCase)(c,l)]=p)}),u}return i.default=i,mi=i,mi}var e1=JI();const t1=Ni(e1),Hx=Wx("end"),Ym=Wx("start");function Wx(e){return t;function t(n){const i=n&&n.position&&n.position[e]||{};if(typeof i.line=="number"&&i.line>0&&typeof i.column=="number"&&i.column>0)return{line:i.line,column:i.column,offset:typeof i.offset=="number"&&i.offset>-1?i.offset:void 0}}}function n1(e){const t=Ym(e),n=Hx(e);if(t&&n)return{start:t,end:n}}function Si(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?FE(e.position):"start"in e||"end"in e?FE(e):"line"in e||"column"in e?xm(e):""}function xm(e){return PE(e&&e.line)+":"+PE(e&&e.column)}function FE(e){return xm(e&&e.start)+"-"+xm(e&&e.end)}function PE(e){return e&&typeof e=="number"?e:1}class $t extends Error{constructor(t,n,i){super(),typeof n=="string"&&(i=n,n=void 0);let o="",l={},u=!1;if(n&&("line"in n&&"column"in n?l={place:n}:"start"in n&&"end"in n?l={place:n}:"type"in n?l={ancestors:[n],place:n.position}:l={...n}),typeof t=="string"?o=t:!l.cause&&t&&(u=!0,o=t.message,l.cause=t),!l.ruleId&&!l.source&&typeof i=="string"){const p=i.indexOf(":");p===-1?l.ruleId=i:(l.source=i.slice(0,p),l.ruleId=i.slice(p+1))}if(!l.place&&l.ancestors&&l.ancestors){const p=l.ancestors[l.ancestors.length-1];p&&(l.place=p.position)}const c=l.place&&"start"in l.place?l.place.start:l.place;this.ancestors=l.ancestors||void 0,this.cause=l.cause||void 0,this.column=c?c.column:void 0,this.fatal=void 0,this.file="",this.message=o,this.line=c?c.line:void 0,this.name=Si(l.place)||"1:1",this.place=l.place||void 0,this.reason=this.message,this.ruleId=l.ruleId||void 0,this.source=l.source||void 0,this.stack=u&&l.cause&&typeof l.cause.stack=="string"?l.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}$t.prototype.file="";$t.prototype.name="";$t.prototype.reason="";$t.prototype.message="";$t.prototype.stack="";$t.prototype.column=void 0;$t.prototype.line=void 0;$t.prototype.ancestors=void 0;$t.prototype.cause=void 0;$t.prototype.fatal=void 0;$t.prototype.place=void 0;$t.prototype.ruleId=void 0;$t.prototype.source=void 0;const Km={}.hasOwnProperty,r1=new Map,a1=/[A-Z]/g,i1=new Set(["table","tbody","thead","tfoot","tr"]),o1=new Set(["td","th"]),Vx="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function s1(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let i;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");i=m1(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");i=g1(n,t.jsx,t.jsxs)}const o={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:i,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?Vm:YI,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},l=Yx(o,e,void 0);return l&&typeof l!="string"?l:o.create(e,o.Fragment,{children:l||void 0},void 0)}function Yx(e,t,n){if(t.type==="element")return l1(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return u1(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return d1(e,t,n);if(t.type==="mdxjsEsm")return c1(e,t);if(t.type==="root")return p1(e,t,n);if(t.type==="text")return f1(e,t)}function l1(e,t,n){const i=e.schema;let o=i;t.tagName.toLowerCase()==="svg"&&i.space==="html"&&(o=Vm,e.schema=o),e.ancestors.push(t);const l=Zx(e,t.tagName,!1),u=h1(e,t);let c=Xm(e,t);return i1.has(t.tagName)&&(c=c.filter(function(p){return typeof p=="string"?!UI(p):!0})),Kx(e,u,l,t),Zm(u,c),e.ancestors.pop(),e.schema=i,e.create(t,l,u,n)}function u1(e,t){if(t.data&&t.data.estree&&e.evaluater){const i=t.data.estree.body[0];return i.type,e.evaluater.evaluateExpression(i.expression)}Ti(e,t.position)}function c1(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);Ti(e,t.position)}function d1(e,t,n){const i=e.schema;let o=i;t.name==="svg"&&i.space==="html"&&(o=Vm,e.schema=o),e.ancestors.push(t);const l=t.name===null?e.Fragment:Zx(e,t.name,!0),u=b1(e,t),c=Xm(e,t);return Kx(e,u,l,t),Zm(u,c),e.ancestors.pop(),e.schema=i,e.create(t,l,u,n)}function p1(e,t,n){const i={};return Zm(i,Xm(e,t)),e.create(t,e.Fragment,i,n)}function f1(e,t){return t.value}function Kx(e,t,n,i){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=i)}function Zm(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function g1(e,t,n){return i;function i(o,l,u,c){const f=Array.isArray(u.children)?n:t;return c?f(l,u,c):f(l,u)}}function m1(e,t){return n;function n(i,o,l,u){const c=Array.isArray(l.children),p=Ym(i);return t(o,l,u,c,{columnNumber:p?p.column-1:void 0,fileName:e,lineNumber:p?p.line:void 0},void 0)}}function h1(e,t){const n={};let i,o;for(o in t.properties)if(o!=="children"&&Km.call(t.properties,o)){const l=y1(e,o,t.properties[o]);if(l){const[u,c]=l;e.tableCellAlignToStyle&&u==="align"&&typeof c=="string"&&o1.has(t.tagName)?i=c:n[u]=c}}if(i){const l=n.style||(n.style={});l[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=i}return n}function b1(e,t){const n={};for(const i of t.attributes)if(i.type==="mdxJsxExpressionAttribute")if(i.data&&i.data.estree&&e.evaluater){const l=i.data.estree.body[0];l.type;const u=l.expression;u.type;const c=u.properties[0];c.type,Object.assign(n,e.evaluater.evaluateExpression(c.argument))}else Ti(e,t.position);else{const o=i.name;let l;if(i.value&&typeof i.value=="object")if(i.value.data&&i.value.data.estree&&e.evaluater){const c=i.value.data.estree.body[0];c.type,l=e.evaluater.evaluateExpression(c.expression)}else Ti(e,t.position);else l=i.value===null?!0:i.value;n[o]=l}return n}function Xm(e,t){const n=[];let i=-1;const o=e.passKeys?new Map:r1;for(;++io?0:o+t:t=t>o?o:t,n=n>0?n:0,i.length<1e4)u=Array.from(i),u.unshift(t,n),e.splice(...u);else for(n&&e.splice(t,n);l0?(dn(e,e.length,0,t),e):t}const jE={}.hasOwnProperty;function Qx(e){const t={};let n=-1;for(;++n13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}function On(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Ht=xr(/[A-Za-z]/),zt=xr(/[\dA-Za-z]/),A1=xr(/[#-'*+\--9=?A-Z^-~]/);function ls(e){return e!==null&&(e<32||e===127)}const Am=xr(/\d/),R1=xr(/[\dA-Fa-f]/),N1=xr(/[!-/:-@[-`{-~]/);function xe(e){return e!==null&&e<-2}function He(e){return e!==null&&(e<0||e===32)}function Fe(e){return e===-2||e===-1||e===32}const bs=xr(new RegExp("\\p{P}|\\p{S}","u")),Wr=xr(/\s/);function xr(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Oa(e){const t=[];let n=-1,i=0,o=0;for(;++n55295&&l<57344){const c=e.charCodeAt(n+1);l<56320&&c>56319&&c<57344?(u=String.fromCharCode(l,c),o=1):u="�"}else u=String.fromCharCode(l);u&&(t.push(e.slice(i,n),encodeURIComponent(u)),i=n+o+1,u=""),o&&(n+=o,o=0)}return t.join("")+e.slice(i)}function Pe(e,t,n,i){const o=i?i-1:Number.POSITIVE_INFINITY;let l=0;return u;function u(p){return Fe(p)?(e.enter(n),c(p)):t(p)}function c(p){return Fe(p)&&l++u))return;const B=t.events.length;let W=B,j,M;for(;W--;)if(t.events[W][0]==="exit"&&t.events[W][1].type==="chunkFlow"){if(j){M=t.events[W][1].end;break}j=!0}for(N(i),w=B;wA;){const L=n[O];t.containerState=L[1],L[0].exit.call(t,e)}n.length=A}function R(){o.write([null]),l=void 0,o=void 0,t.containerState._closeFlow=void 0}}function D1(e,t,n){return Pe(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Ra(e){if(e===null||He(e)||Wr(e))return 1;if(bs(e))return 2}function ys(e,t,n){const i=[];let o=-1;for(;++o1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const h={...e[i][1].end},S={...e[n][1].start};$E(h,-p),$E(S,p),u={type:p>1?"strongSequence":"emphasisSequence",start:h,end:{...e[i][1].end}},c={type:p>1?"strongSequence":"emphasisSequence",start:{...e[n][1].start},end:S},l={type:p>1?"strongText":"emphasisText",start:{...e[i][1].end},end:{...e[n][1].start}},o={type:p>1?"strong":"emphasis",start:{...u.start},end:{...c.end}},e[i][1].end={...u.start},e[n][1].start={...c.end},f=[],e[i][1].end.offset-e[i][1].start.offset&&(f=Sn(f,[["enter",e[i][1],t],["exit",e[i][1],t]])),f=Sn(f,[["enter",o,t],["enter",u,t],["exit",u,t],["enter",l,t]]),f=Sn(f,ys(t.parser.constructs.insideSpan.null,e.slice(i+1,n),t)),f=Sn(f,[["exit",l,t],["enter",c,t],["exit",c,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(m=2,f=Sn(f,[["enter",e[n][1],t],["exit",e[n][1],t]])):m=0,dn(e,i-1,n-i+3,f),n=i+f.length-m-2;break}}for(n=-1;++n0&&Fe(w)?Pe(e,R,"linePrefix",l+1)(w):R(w)}function R(w){return w===null||xe(w)?e.check(qE,k,O)(w):(e.enter("codeFlowValue"),A(w))}function A(w){return w===null||xe(w)?(e.exit("codeFlowValue"),R(w)):(e.consume(w),A)}function O(w){return e.exit("codeFenced"),t(w)}function L(w,B,W){let j=0;return M;function M(H){return w.enter("lineEnding"),w.consume(H),w.exit("lineEnding"),Y}function Y(H){return w.enter("codeFencedFence"),Fe(H)?Pe(w,J,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(H):J(H)}function J(H){return H===c?(w.enter("codeFencedFenceSequence"),de(H)):W(H)}function de(H){return H===c?(j++,w.consume(H),de):j>=u?(w.exit("codeFencedFenceSequence"),Fe(H)?Pe(w,Z,"whitespace")(H):Z(H)):W(H)}function Z(H){return H===null||xe(H)?(w.exit("codeFencedFence"),B(H)):W(H)}}}function W1(e,t,n){const i=this;return o;function o(u){return u===null?n(u):(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),l)}function l(u){return i.parser.lazy[i.now().line]?n(u):t(u)}}const bu={name:"codeIndented",tokenize:Y1},V1={partial:!0,tokenize:K1};function Y1(e,t,n){const i=this;return o;function o(f){return e.enter("codeIndented"),Pe(e,l,"linePrefix",5)(f)}function l(f){const m=i.events[i.events.length-1];return m&&m[1].type==="linePrefix"&&m[2].sliceSerialize(m[1],!0).length>=4?u(f):n(f)}function u(f){return f===null?p(f):xe(f)?e.attempt(V1,u,p)(f):(e.enter("codeFlowValue"),c(f))}function c(f){return f===null||xe(f)?(e.exit("codeFlowValue"),u(f)):(e.consume(f),c)}function p(f){return e.exit("codeIndented"),t(f)}}function K1(e,t,n){const i=this;return o;function o(u){return i.parser.lazy[i.now().line]?n(u):xe(u)?(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),o):Pe(e,l,"linePrefix",5)(u)}function l(u){const c=i.events[i.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?t(u):xe(u)?o(u):n(u)}}const Z1={name:"codeText",previous:Q1,resolve:X1,tokenize:J1};function X1(e){let t=e.length-4,n=3,i,o;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(i=n;++i=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return tthis.left.length?this.right.slice(this.right.length-i+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-i+this.left.length).reverse())}splice(t,n,i){const o=n||0;this.setCursor(Math.trunc(t));const l=this.right.splice(this.right.length-o,Number.POSITIVE_INFINITY);return i&&hi(this.left,i),l.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),hi(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),hi(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t=4?t(u):e.interrupt(i.parser.constructs.flow,n,t)(u)}}function aA(e,t,n,i,o,l,u,c,p){const f=p||Number.POSITIVE_INFINITY;let m=0;return h;function h(N){return N===60?(e.enter(i),e.enter(o),e.enter(l),e.consume(N),e.exit(l),S):N===null||N===32||N===41||ls(N)?n(N):(e.enter(i),e.enter(u),e.enter(c),e.enter("chunkString",{contentType:"string"}),k(N))}function S(N){return N===62?(e.enter(l),e.consume(N),e.exit(l),e.exit(o),e.exit(i),t):(e.enter(c),e.enter("chunkString",{contentType:"string"}),E(N))}function E(N){return N===62?(e.exit("chunkString"),e.exit(c),S(N)):N===null||N===60||xe(N)?n(N):(e.consume(N),N===92?v:E)}function v(N){return N===60||N===62||N===92?(e.consume(N),E):E(N)}function k(N){return!m&&(N===null||N===41||He(N))?(e.exit("chunkString"),e.exit(c),e.exit(u),e.exit(i),t(N)):m999||E===null||E===91||E===93&&!p||E===94&&!c&&"_hiddenFootnoteSupport"in u.parser.constructs?n(E):E===93?(e.exit(l),e.enter(o),e.consume(E),e.exit(o),e.exit(i),t):xe(E)?(e.enter("lineEnding"),e.consume(E),e.exit("lineEnding"),m):(e.enter("chunkString",{contentType:"string"}),h(E))}function h(E){return E===null||E===91||E===93||xe(E)||c++>999?(e.exit("chunkString"),m(E)):(e.consume(E),p||(p=!Fe(E)),E===92?S:h)}function S(E){return E===91||E===92||E===93?(e.consume(E),c++,h):h(E)}}function oA(e,t,n,i,o,l){let u;return c;function c(S){return S===34||S===39||S===40?(e.enter(i),e.enter(o),e.consume(S),e.exit(o),u=S===40?41:S,p):n(S)}function p(S){return S===u?(e.enter(o),e.consume(S),e.exit(o),e.exit(i),t):(e.enter(l),f(S))}function f(S){return S===u?(e.exit(l),p(u)):S===null?n(S):xe(S)?(e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),Pe(e,f,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),m(S))}function m(S){return S===u||S===null||xe(S)?(e.exit("chunkString"),f(S)):(e.consume(S),S===92?h:m)}function h(S){return S===u||S===92?(e.consume(S),m):m(S)}}function vi(e,t){let n;return i;function i(o){return xe(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,i):Fe(o)?Pe(e,i,n?"linePrefix":"lineSuffix")(o):t(o)}}const s0={name:"definition",tokenize:u0},l0={partial:!0,tokenize:c0};function u0(e,t,n){const i=this;let o;return l;function l(E){return e.enter("definition"),u(E)}function u(E){return iA.call(i,e,c,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(E)}function c(E){return o=On(i.sliceSerialize(i.events[i.events.length-1][1]).slice(1,-1)),E===58?(e.enter("definitionMarker"),e.consume(E),e.exit("definitionMarker"),p):n(E)}function p(E){return He(E)?vi(e,f)(E):f(E)}function f(E){return aA(e,m,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(E)}function m(E){return e.attempt(l0,h,h)(E)}function h(E){return Fe(E)?Pe(e,S,"whitespace")(E):S(E)}function S(E){return E===null||xe(E)?(e.exit("definition"),i.parser.defined.push(o),t(E)):n(E)}}function c0(e,t,n){return i;function i(c){return He(c)?vi(e,o)(c):n(c)}function o(c){return oA(e,l,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(c)}function l(c){return Fe(c)?Pe(e,u,"whitespace")(c):u(c)}function u(c){return c===null||xe(c)?t(c):n(c)}}const d0={name:"hardBreakEscape",tokenize:p0};function p0(e,t,n){return i;function i(l){return e.enter("hardBreakEscape"),e.consume(l),o}function o(l){return xe(l)?(e.exit("hardBreakEscape"),t(l)):n(l)}}const f0={name:"headingAtx",resolve:g0,tokenize:m0};function g0(e,t){let n=e.length-2,i=3,o,l;return e[i][1].type==="whitespace"&&(i+=2),n-2>i&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(i===n-1||n-4>i&&e[n-2][1].type==="whitespace")&&(n-=i+1===n?2:4),n>i&&(o={type:"atxHeadingText",start:e[i][1].start,end:e[n][1].end},l={type:"chunkText",start:e[i][1].start,end:e[n][1].end,contentType:"text"},dn(e,i,n-i+1,[["enter",o,t],["enter",l,t],["exit",l,t],["exit",o,t]])),e}function m0(e,t,n){let i=0;return o;function o(m){return e.enter("atxHeading"),l(m)}function l(m){return e.enter("atxHeadingSequence"),u(m)}function u(m){return m===35&&i++<6?(e.consume(m),u):m===null||He(m)?(e.exit("atxHeadingSequence"),c(m)):n(m)}function c(m){return m===35?(e.enter("atxHeadingSequence"),p(m)):m===null||xe(m)?(e.exit("atxHeading"),t(m)):Fe(m)?Pe(e,c,"whitespace")(m):(e.enter("atxHeadingText"),f(m))}function p(m){return m===35?(e.consume(m),p):(e.exit("atxHeadingSequence"),c(m))}function f(m){return m===null||m===35||He(m)?(e.exit("atxHeadingText"),c(m)):(e.consume(m),f)}}const h0=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],HE=["pre","script","style","textarea"],b0={concrete:!0,name:"htmlFlow",resolveTo:S0,tokenize:v0},y0={partial:!0,tokenize:_0},E0={partial:!0,tokenize:k0};function S0(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function v0(e,t,n){const i=this;let o,l,u,c,p;return f;function f(C){return m(C)}function m(C){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(C),h}function h(C){return C===33?(e.consume(C),S):C===47?(e.consume(C),l=!0,k):C===63?(e.consume(C),o=3,i.interrupt?t:x):Ht(C)?(e.consume(C),u=String.fromCharCode(C),T):n(C)}function S(C){return C===45?(e.consume(C),o=2,E):C===91?(e.consume(C),o=5,c=0,v):Ht(C)?(e.consume(C),o=4,i.interrupt?t:x):n(C)}function E(C){return C===45?(e.consume(C),i.interrupt?t:x):n(C)}function v(C){const ae="CDATA[";return C===ae.charCodeAt(c++)?(e.consume(C),c===ae.length?i.interrupt?t:J:v):n(C)}function k(C){return Ht(C)?(e.consume(C),u=String.fromCharCode(C),T):n(C)}function T(C){if(C===null||C===47||C===62||He(C)){const ae=C===47,pe=u.toLowerCase();return!ae&&!l&&HE.includes(pe)?(o=1,i.interrupt?t(C):J(C)):h0.includes(u.toLowerCase())?(o=6,ae?(e.consume(C),N):i.interrupt?t(C):J(C)):(o=7,i.interrupt&&!i.parser.lazy[i.now().line]?n(C):l?R(C):A(C))}return C===45||zt(C)?(e.consume(C),u+=String.fromCharCode(C),T):n(C)}function N(C){return C===62?(e.consume(C),i.interrupt?t:J):n(C)}function R(C){return Fe(C)?(e.consume(C),R):M(C)}function A(C){return C===47?(e.consume(C),M):C===58||C===95||Ht(C)?(e.consume(C),O):Fe(C)?(e.consume(C),A):M(C)}function O(C){return C===45||C===46||C===58||C===95||zt(C)?(e.consume(C),O):L(C)}function L(C){return C===61?(e.consume(C),w):Fe(C)?(e.consume(C),L):A(C)}function w(C){return C===null||C===60||C===61||C===62||C===96?n(C):C===34||C===39?(e.consume(C),p=C,B):Fe(C)?(e.consume(C),w):W(C)}function B(C){return C===p?(e.consume(C),p=null,j):C===null||xe(C)?n(C):(e.consume(C),B)}function W(C){return C===null||C===34||C===39||C===47||C===60||C===61||C===62||C===96||He(C)?L(C):(e.consume(C),W)}function j(C){return C===47||C===62||Fe(C)?A(C):n(C)}function M(C){return C===62?(e.consume(C),Y):n(C)}function Y(C){return C===null||xe(C)?J(C):Fe(C)?(e.consume(C),Y):n(C)}function J(C){return C===45&&o===2?(e.consume(C),te):C===60&&o===1?(e.consume(C),ue):C===62&&o===4?(e.consume(C),D):C===63&&o===3?(e.consume(C),x):C===93&&o===5?(e.consume(C),Q):xe(C)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(y0,$,de)(C)):C===null||xe(C)?(e.exit("htmlFlowData"),de(C)):(e.consume(C),J)}function de(C){return e.check(E0,Z,$)(C)}function Z(C){return e.enter("lineEnding"),e.consume(C),e.exit("lineEnding"),H}function H(C){return C===null||xe(C)?de(C):(e.enter("htmlFlowData"),J(C))}function te(C){return C===45?(e.consume(C),x):J(C)}function ue(C){return C===47?(e.consume(C),u="",q):J(C)}function q(C){if(C===62){const ae=u.toLowerCase();return HE.includes(ae)?(e.consume(C),D):J(C)}return Ht(C)&&u.length<8?(e.consume(C),u+=String.fromCharCode(C),q):J(C)}function Q(C){return C===93?(e.consume(C),x):J(C)}function x(C){return C===62?(e.consume(C),D):C===45&&o===2?(e.consume(C),x):J(C)}function D(C){return C===null||xe(C)?(e.exit("htmlFlowData"),$(C)):(e.consume(C),D)}function $(C){return e.exit("htmlFlow"),t(C)}}function k0(e,t,n){const i=this;return o;function o(u){return xe(u)?(e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),l):n(u)}function l(u){return i.parser.lazy[i.now().line]?n(u):t(u)}}function _0(e,t,n){return i;function i(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Ii,t,n)}}const w0={name:"htmlText",tokenize:T0};function T0(e,t,n){const i=this;let o,l,u;return c;function c(x){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(x),p}function p(x){return x===33?(e.consume(x),f):x===47?(e.consume(x),L):x===63?(e.consume(x),A):Ht(x)?(e.consume(x),W):n(x)}function f(x){return x===45?(e.consume(x),m):x===91?(e.consume(x),l=0,v):Ht(x)?(e.consume(x),R):n(x)}function m(x){return x===45?(e.consume(x),E):n(x)}function h(x){return x===null?n(x):x===45?(e.consume(x),S):xe(x)?(u=h,ue(x)):(e.consume(x),h)}function S(x){return x===45?(e.consume(x),E):h(x)}function E(x){return x===62?te(x):x===45?S(x):h(x)}function v(x){const D="CDATA[";return x===D.charCodeAt(l++)?(e.consume(x),l===D.length?k:v):n(x)}function k(x){return x===null?n(x):x===93?(e.consume(x),T):xe(x)?(u=k,ue(x)):(e.consume(x),k)}function T(x){return x===93?(e.consume(x),N):k(x)}function N(x){return x===62?te(x):x===93?(e.consume(x),N):k(x)}function R(x){return x===null||x===62?te(x):xe(x)?(u=R,ue(x)):(e.consume(x),R)}function A(x){return x===null?n(x):x===63?(e.consume(x),O):xe(x)?(u=A,ue(x)):(e.consume(x),A)}function O(x){return x===62?te(x):A(x)}function L(x){return Ht(x)?(e.consume(x),w):n(x)}function w(x){return x===45||zt(x)?(e.consume(x),w):B(x)}function B(x){return xe(x)?(u=B,ue(x)):Fe(x)?(e.consume(x),B):te(x)}function W(x){return x===45||zt(x)?(e.consume(x),W):x===47||x===62||He(x)?j(x):n(x)}function j(x){return x===47?(e.consume(x),te):x===58||x===95||Ht(x)?(e.consume(x),M):xe(x)?(u=j,ue(x)):Fe(x)?(e.consume(x),j):te(x)}function M(x){return x===45||x===46||x===58||x===95||zt(x)?(e.consume(x),M):Y(x)}function Y(x){return x===61?(e.consume(x),J):xe(x)?(u=Y,ue(x)):Fe(x)?(e.consume(x),Y):j(x)}function J(x){return x===null||x===60||x===61||x===62||x===96?n(x):x===34||x===39?(e.consume(x),o=x,de):xe(x)?(u=J,ue(x)):Fe(x)?(e.consume(x),J):(e.consume(x),Z)}function de(x){return x===o?(e.consume(x),o=void 0,H):x===null?n(x):xe(x)?(u=de,ue(x)):(e.consume(x),de)}function Z(x){return x===null||x===34||x===39||x===60||x===61||x===96?n(x):x===47||x===62||He(x)?j(x):(e.consume(x),Z)}function H(x){return x===47||x===62||He(x)?j(x):n(x)}function te(x){return x===62?(e.consume(x),e.exit("htmlTextData"),e.exit("htmlText"),t):n(x)}function ue(x){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),q}function q(x){return Fe(x)?Pe(e,Q,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(x):Q(x)}function Q(x){return e.enter("htmlTextData"),u(x)}}const eh={name:"labelEnd",resolveAll:N0,resolveTo:C0,tokenize:I0},x0={tokenize:O0},A0={tokenize:L0},R0={tokenize:D0};function N0(e){let t=-1;const n=[];for(;++t=3&&(f===null||xe(f))?(e.exit("thematicBreak"),t(f)):n(f)}function p(f){return f===o?(e.consume(f),i++,p):(e.exit("thematicBreakSequence"),Fe(f)?Pe(e,c,"whitespace")(f):c(f))}}const tn={continuation:{tokenize:G0},exit:W0,name:"list",tokenize:q0},z0={partial:!0,tokenize:V0},$0={partial:!0,tokenize:H0};function q0(e,t,n){const i=this,o=i.events[i.events.length-1];let l=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,u=0;return c;function c(E){const v=i.containerState.type||(E===42||E===43||E===45?"listUnordered":"listOrdered");if(v==="listUnordered"?!i.containerState.marker||E===i.containerState.marker:Am(E)){if(i.containerState.type||(i.containerState.type=v,e.enter(v,{_container:!0})),v==="listUnordered")return e.enter("listItemPrefix"),E===42||E===45?e.check(ns,n,f)(E):f(E);if(!i.interrupt||E===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),p(E)}return n(E)}function p(E){return Am(E)&&++u<10?(e.consume(E),p):(!i.interrupt||u<2)&&(i.containerState.marker?E===i.containerState.marker:E===41||E===46)?(e.exit("listItemValue"),f(E)):n(E)}function f(E){return e.enter("listItemMarker"),e.consume(E),e.exit("listItemMarker"),i.containerState.marker=i.containerState.marker||E,e.check(Ii,i.interrupt?n:m,e.attempt(z0,S,h))}function m(E){return i.containerState.initialBlankLine=!0,l++,S(E)}function h(E){return Fe(E)?(e.enter("listItemPrefixWhitespace"),e.consume(E),e.exit("listItemPrefixWhitespace"),S):n(E)}function S(E){return i.containerState.size=l+i.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(E)}}function G0(e,t,n){const i=this;return i.containerState._closeFlow=void 0,e.check(Ii,o,l);function o(c){return i.containerState.furtherBlankLines=i.containerState.furtherBlankLines||i.containerState.initialBlankLine,Pe(e,t,"listItemIndent",i.containerState.size+1)(c)}function l(c){return i.containerState.furtherBlankLines||!Fe(c)?(i.containerState.furtherBlankLines=void 0,i.containerState.initialBlankLine=void 0,u(c)):(i.containerState.furtherBlankLines=void 0,i.containerState.initialBlankLine=void 0,e.attempt($0,t,u)(c))}function u(c){return i.containerState._closeFlow=!0,i.interrupt=void 0,Pe(e,e.attempt(tn,t,n),"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c)}}function H0(e,t,n){const i=this;return Pe(e,o,"listItemIndent",i.containerState.size+1);function o(l){const u=i.events[i.events.length-1];return u&&u[1].type==="listItemIndent"&&u[2].sliceSerialize(u[1],!0).length===i.containerState.size?t(l):n(l)}}function W0(e){e.exit(this.containerState.type)}function V0(e,t,n){const i=this;return Pe(e,o,"listItemPrefixWhitespace",i.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function o(l){const u=i.events[i.events.length-1];return!Fe(l)&&u&&u[1].type==="listItemPrefixWhitespace"?t(l):n(l)}}const WE={name:"setextUnderline",resolveTo:Y0,tokenize:K0};function Y0(e,t){let n=e.length,i,o,l;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){i=n;break}e[n][1].type==="paragraph"&&(o=n)}else e[n][1].type==="content"&&e.splice(n,1),!l&&e[n][1].type==="definition"&&(l=n);const u={type:"setextHeading",start:{...e[i][1].start},end:{...e[e.length-1][1].end}};return e[o][1].type="setextHeadingText",l?(e.splice(o,0,["enter",u,t]),e.splice(l+1,0,["exit",e[i][1],t]),e[i][1].end={...e[l][1].end}):e[i][1]=u,e.push(["exit",u,t]),e}function K0(e,t,n){const i=this;let o;return l;function l(f){let m=i.events.length,h;for(;m--;)if(i.events[m][1].type!=="lineEnding"&&i.events[m][1].type!=="linePrefix"&&i.events[m][1].type!=="content"){h=i.events[m][1].type==="paragraph";break}return!i.parser.lazy[i.now().line]&&(i.interrupt||h)?(e.enter("setextHeadingLine"),o=f,u(f)):n(f)}function u(f){return e.enter("setextHeadingLineSequence"),c(f)}function c(f){return f===o?(e.consume(f),c):(e.exit("setextHeadingLineSequence"),Fe(f)?Pe(e,p,"lineSuffix")(f):p(f))}function p(f){return f===null||xe(f)?(e.exit("setextHeadingLine"),t(f)):n(f)}}const Z0={tokenize:X0};function X0(e){const t=this,n=e.attempt(Ii,i,e.attempt(this.parser.constructs.flowInitial,o,Pe(e,e.attempt(this.parser.constructs.flow,o,e.attempt(n0,o)),"linePrefix")));return n;function i(l){if(l===null){e.consume(l);return}return e.enter("lineEndingBlank"),e.consume(l),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(l){if(l===null){e.consume(l);return}return e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const Q0={resolveAll:lA()},J0=sA("string"),eO=sA("text");function sA(e){return{resolveAll:lA(e==="text"?tO:void 0),tokenize:t};function t(n){const i=this,o=this.parser.constructs[e],l=n.attempt(o,u,c);return u;function u(m){return f(m)?l(m):c(m)}function c(m){if(m===null){n.consume(m);return}return n.enter("data"),n.consume(m),p}function p(m){return f(m)?(n.exit("data"),l(m)):(n.consume(m),p)}function f(m){if(m===null)return!0;const h=o[m];let S=-1;if(h)for(;++S-1){const c=u[0];typeof c=="string"?u[0]=c.slice(i):u.shift()}l>0&&u.push(e[o].slice(0,l))}return u}function gO(e,t){let n=-1;const i=[];let o;for(;++n0){const We=ge.tokenStack[ge.tokenStack.length-1];(We[1]||YE).call(ge,void 0,We[0])}for(ee.position={start:wr(K.length>0?K[0][1].start:{line:1,column:1,offset:0}),end:wr(K.length>0?K[K.length-2][1].end:{line:1,column:1,offset:0})},Ne=-1;++Ne0&&(i.className=["language-"+o[0]]);let l={type:"element",tagName:"code",properties:i,children:[{type:"text",value:n}]};return t.meta&&(l.data={meta:t.meta}),e.patch(t,l),l=e.applyData(t,l),l={type:"element",tagName:"pre",properties:{},children:[l]},e.patch(t,l),l}function AO(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function RO(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function NO(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",i=String(t.identifier).toUpperCase(),o=Oa(i.toLowerCase()),l=e.footnoteOrder.indexOf(i);let u,c=e.footnoteCounts.get(i);c===void 0?(c=0,e.footnoteOrder.push(i),u=e.footnoteOrder.length):u=l+1,c+=1,e.footnoteCounts.set(i,c);const p={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+o,id:n+"fnref-"+o+(c>1?"-"+c:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(u)}]};e.patch(t,p);const f={type:"element",tagName:"sup",properties:{},children:[p]};return e.patch(t,f),e.applyData(t,f)}function CO(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function IO(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function dA(e,t){const n=t.referenceType;let i="]";if(n==="collapsed"?i+="[]":n==="full"&&(i+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return[{type:"text",value:"!["+t.alt+i}];const o=e.all(t),l=o[0];l&&l.type==="text"?l.value="["+l.value:o.unshift({type:"text",value:"["});const u=o[o.length-1];return u&&u.type==="text"?u.value+=i:o.push({type:"text",value:i}),o}function OO(e,t){const n=String(t.identifier).toUpperCase(),i=e.definitionById.get(n);if(!i)return dA(e,t);const o={src:Oa(i.url||""),alt:t.alt};i.title!==null&&i.title!==void 0&&(o.title=i.title);const l={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,l),e.applyData(t,l)}function LO(e,t){const n={src:Oa(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const i={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,i),e.applyData(t,i)}function DO(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const i={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,i),e.applyData(t,i)}function MO(e,t){const n=String(t.identifier).toUpperCase(),i=e.definitionById.get(n);if(!i)return dA(e,t);const o={href:Oa(i.url||"")};i.title!==null&&i.title!==void 0&&(o.title=i.title);const l={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,l),e.applyData(t,l)}function FO(e,t){const n={href:Oa(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const i={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,i),e.applyData(t,i)}function PO(e,t,n){const i=e.all(t),o=n?UO(n):pA(t),l={},u=[];if(typeof t.checked=="boolean"){const m=i[0];let h;m&&m.type==="element"&&m.tagName==="p"?h=m:(h={type:"element",tagName:"p",properties:{},children:[]},i.unshift(h)),h.children.length>0&&h.children.unshift({type:"text",value:" "}),h.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),l.className=["task-list-item"]}let c=-1;for(;++c0){const We=ge.tokenStack[ge.tokenStack.length-1];(We[1]||YE).call(ge,void 0,We[0])}for(ee.position={start:wr(K.length>0?K[0][1].start:{line:1,column:1,offset:0}),end:wr(K.length>0?K[K.length-2][1].end:{line:1,column:1,offset:0})},Ne=-1;++Ne0&&(i.className=["language-"+o[0]]);let l={type:"element",tagName:"code",properties:i,children:[{type:"text",value:n}]};return t.meta&&(l.data={meta:t.meta}),e.patch(t,l),l=e.applyData(t,l),l={type:"element",tagName:"pre",properties:{},children:[l]},e.patch(t,l),l}function RO(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function NO(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function CO(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",i=String(t.identifier).toUpperCase(),o=Oa(i.toLowerCase()),l=e.footnoteOrder.indexOf(i);let u,c=e.footnoteCounts.get(i);c===void 0?(c=0,e.footnoteOrder.push(i),u=e.footnoteOrder.length):u=l+1,c+=1,e.footnoteCounts.set(i,c);const p={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+o,id:n+"fnref-"+o+(c>1?"-"+c:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(u)}]};e.patch(t,p);const f={type:"element",tagName:"sup",properties:{},children:[p]};return e.patch(t,f),e.applyData(t,f)}function IO(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function OO(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function dA(e,t){const n=t.referenceType;let i="]";if(n==="collapsed"?i+="[]":n==="full"&&(i+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return[{type:"text",value:"!["+t.alt+i}];const o=e.all(t),l=o[0];l&&l.type==="text"?l.value="["+l.value:o.unshift({type:"text",value:"["});const u=o[o.length-1];return u&&u.type==="text"?u.value+=i:o.push({type:"text",value:i}),o}function LO(e,t){const n=String(t.identifier).toUpperCase(),i=e.definitionById.get(n);if(!i)return dA(e,t);const o={src:Oa(i.url||""),alt:t.alt};i.title!==null&&i.title!==void 0&&(o.title=i.title);const l={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,l),e.applyData(t,l)}function DO(e,t){const n={src:Oa(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const i={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,i),e.applyData(t,i)}function MO(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const i={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,i),e.applyData(t,i)}function FO(e,t){const n=String(t.identifier).toUpperCase(),i=e.definitionById.get(n);if(!i)return dA(e,t);const o={href:Oa(i.url||"")};i.title!==null&&i.title!==void 0&&(o.title=i.title);const l={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,l),e.applyData(t,l)}function PO(e,t){const n={href:Oa(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const i={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,i),e.applyData(t,i)}function UO(e,t,n){const i=e.all(t),o=n?BO(n):pA(t),l={},u=[];if(typeof t.checked=="boolean"){const m=i[0];let h;m&&m.type==="element"&&m.tagName==="p"?h=m:(h={type:"element",tagName:"p",properties:{},children:[]},i.unshift(h)),h.children.length>0&&h.children.unshift({type:"text",value:" "}),h.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),l.className=["task-list-item"]}let c=-1;for(;++c1}function BO(e,t){const n={},i=e.all(t);let o=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++o0){const u={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},c=Ym(t.children[1]),p=Hx(t.children[t.children.length-1]);c&&p&&(u.position={start:c,end:p}),o.push(u)}const l={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,l),e.applyData(t,l)}function GO(e,t,n){const i=n?n.children:void 0,l=(i?i.indexOf(t):1)===0?"th":"td",u=n&&n.type==="table"?n.align:void 0,c=u?u.length:t.children.length;let p=-1;const f=[];for(;++p0,!0),i[0]),o=i.index+i[0].length,i=n.exec(t);return l.push(XE(t.slice(o),o>0,!1)),l.join("")}function XE(e,t,n){let i=0,o=e.length;if(t){let l=e.codePointAt(i);for(;l===KE||l===ZE;)i++,l=e.codePointAt(i)}if(n){let l=e.codePointAt(o-1);for(;l===KE||l===ZE;)o--,l=e.codePointAt(o-1)}return o>i?e.slice(i,o):""}function VO(e,t){const n={type:"text",value:WO(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function YO(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const KO={blockquote:wO,break:TO,code:xO,delete:AO,emphasis:RO,footnoteReference:NO,heading:CO,html:IO,imageReference:OO,image:LO,inlineCode:DO,linkReference:MO,link:FO,listItem:PO,list:BO,paragraph:jO,root:zO,strong:$O,table:qO,tableCell:HO,tableRow:GO,text:VO,thematicBreak:YO,toml:Wo,yaml:Wo,definition:Wo,footnoteDefinition:Wo};function Wo(){}const fA=-1,Es=0,ki=1,us=2,th=3,nh=4,rh=5,ah=6,gA=7,mA=8,QE=typeof self=="object"?self:globalThis,ZO=(e,t)=>{const n=(o,l)=>(e.set(l,o),o),i=o=>{if(e.has(o))return e.get(o);const[l,u]=t[o];switch(l){case Es:case fA:return n(u,o);case ki:{const c=n([],o);for(const p of u)c.push(i(p));return c}case us:{const c=n({},o);for(const[p,f]of u)c[i(p)]=i(f);return c}case th:return n(new Date(u),o);case nh:{const{source:c,flags:p}=u;return n(new RegExp(c,p),o)}case rh:{const c=n(new Map,o);for(const[p,f]of u)c.set(i(p),i(f));return c}case ah:{const c=n(new Set,o);for(const p of u)c.add(i(p));return c}case gA:{const{name:c,message:p}=u;return n(new QE[c](p),o)}case mA:return n(BigInt(u),o);case"BigInt":return n(Object(BigInt(u)),o);case"ArrayBuffer":return n(new Uint8Array(u).buffer,u);case"DataView":{const{buffer:c}=new Uint8Array(u);return n(new DataView(c),u)}}return n(new QE[l](u),o)};return i},JE=e=>ZO(new Map,e)(0),ka="",{toString:XO}={},{keys:QO}=Object,bi=e=>{const t=typeof e;if(t!=="object"||!e)return[Es,t];const n=XO.call(e).slice(8,-1);switch(n){case"Array":return[ki,ka];case"Object":return[us,ka];case"Date":return[th,ka];case"RegExp":return[nh,ka];case"Map":return[rh,ka];case"Set":return[ah,ka];case"DataView":return[ki,n]}return n.includes("Array")?[ki,n]:n.includes("Error")?[gA,n]:[us,n]},Vo=([e,t])=>e===Es&&(t==="function"||t==="symbol"),JO=(e,t,n,i)=>{const o=(u,c)=>{const p=i.push(u)-1;return n.set(c,p),p},l=u=>{if(n.has(u))return n.get(u);let[c,p]=bi(u);switch(c){case Es:{let m=u;switch(p){case"bigint":c=mA,m=u.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+p);m=null;break;case"undefined":return o([fA],u)}return o([c,m],u)}case ki:{if(p){let S=u;return p==="DataView"?S=new Uint8Array(u.buffer):p==="ArrayBuffer"&&(S=new Uint8Array(u)),o([p,[...S]],u)}const m=[],h=o([c,m],u);for(const S of u)m.push(l(S));return h}case us:{if(p)switch(p){case"BigInt":return o([p,u.toString()],u);case"Boolean":case"Number":case"String":return o([p,u.valueOf()],u)}if(t&&"toJSON"in u)return l(u.toJSON());const m=[],h=o([c,m],u);for(const S of QO(u))(e||!Vo(bi(u[S])))&&m.push([l(S),l(u[S])]);return h}case th:return o([c,u.toISOString()],u);case nh:{const{source:m,flags:h}=u;return o([c,{source:m,flags:h}],u)}case rh:{const m=[],h=o([c,m],u);for(const[S,E]of u)(e||!(Vo(bi(S))||Vo(bi(E))))&&m.push([l(S),l(E)]);return h}case ah:{const m=[],h=o([c,m],u);for(const S of u)(e||!Vo(bi(S)))&&m.push(l(S));return h}}const{message:f}=u;return o([c,{name:p,message:f}],u)};return l},eS=(e,{json:t,lossy:n}={})=>{const i=[];return JO(!(t||n),!!t,new Map,i)(e),i},cs=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?JE(eS(e,t)):structuredClone(e):(e,t)=>JE(eS(e,t));function eL(e,t){const n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function tL(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function nL(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||eL,i=e.options.footnoteBackLabel||tL,o=e.options.footnoteLabel||"Footnotes",l=e.options.footnoteLabelTagName||"h2",u=e.options.footnoteLabelProperties||{className:["sr-only"]},c=[];let p=-1;for(;++p0&&v.push({type:"text",value:" "});let R=typeof n=="string"?n:n(p,E);typeof R=="string"&&(R={type:"text",value:R}),v.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+S+(E>1?"-"+E:""),dataFootnoteBackref:"",ariaLabel:typeof i=="string"?i:i(p,E),className:["data-footnote-backref"]},children:Array.isArray(R)?R:[R]})}const T=m[m.length-1];if(T&&T.type==="element"&&T.tagName==="p"){const R=T.children[T.children.length-1];R&&R.type==="text"?R.value+=" ":T.children.push({type:"text",value:" "}),T.children.push(...v)}else m.push(...v);const N={type:"element",tagName:"li",properties:{id:t+"fn-"+S},children:e.wrap(m,!0)};e.patch(f,N),c.push(N)}if(c.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:l,properties:{...cs(u),id:"footnote-label"},children:[{type:"text",value:o}]},{type:"text",value:`
+`});const f={type:"element",tagName:"li",properties:l,children:u};return e.patch(t,f),e.applyData(t,f)}function BO(e){let t=!1;if(e.type==="list"){t=e.spread||!1;const n=e.children;let i=-1;for(;!t&&++i1}function jO(e,t){const n={},i=e.all(t);let o=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++o0){const u={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},c=Ym(t.children[1]),p=Hx(t.children[t.children.length-1]);c&&p&&(u.position={start:c,end:p}),o.push(u)}const l={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,l),e.applyData(t,l)}function HO(e,t,n){const i=n?n.children:void 0,l=(i?i.indexOf(t):1)===0?"th":"td",u=n&&n.type==="table"?n.align:void 0,c=u?u.length:t.children.length;let p=-1;const f=[];for(;++p0,!0),i[0]),o=i.index+i[0].length,i=n.exec(t);return l.push(XE(t.slice(o),o>0,!1)),l.join("")}function XE(e,t,n){let i=0,o=e.length;if(t){let l=e.codePointAt(i);for(;l===KE||l===ZE;)i++,l=e.codePointAt(i)}if(n){let l=e.codePointAt(o-1);for(;l===KE||l===ZE;)o--,l=e.codePointAt(o-1)}return o>i?e.slice(i,o):""}function YO(e,t){const n={type:"text",value:VO(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function KO(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const ZO={blockquote:TO,break:xO,code:AO,delete:RO,emphasis:NO,footnoteReference:CO,heading:IO,html:OO,imageReference:LO,image:DO,inlineCode:MO,linkReference:FO,link:PO,listItem:UO,list:jO,paragraph:zO,root:$O,strong:qO,table:GO,tableCell:WO,tableRow:HO,text:YO,thematicBreak:KO,toml:Wo,yaml:Wo,definition:Wo,footnoteDefinition:Wo};function Wo(){}const fA=-1,Es=0,ki=1,us=2,th=3,nh=4,rh=5,ah=6,gA=7,mA=8,QE=typeof self=="object"?self:globalThis,XO=(e,t)=>{const n=(o,l)=>(e.set(l,o),o),i=o=>{if(e.has(o))return e.get(o);const[l,u]=t[o];switch(l){case Es:case fA:return n(u,o);case ki:{const c=n([],o);for(const p of u)c.push(i(p));return c}case us:{const c=n({},o);for(const[p,f]of u)c[i(p)]=i(f);return c}case th:return n(new Date(u),o);case nh:{const{source:c,flags:p}=u;return n(new RegExp(c,p),o)}case rh:{const c=n(new Map,o);for(const[p,f]of u)c.set(i(p),i(f));return c}case ah:{const c=n(new Set,o);for(const p of u)c.add(i(p));return c}case gA:{const{name:c,message:p}=u;return n(new QE[c](p),o)}case mA:return n(BigInt(u),o);case"BigInt":return n(Object(BigInt(u)),o);case"ArrayBuffer":return n(new Uint8Array(u).buffer,u);case"DataView":{const{buffer:c}=new Uint8Array(u);return n(new DataView(c),u)}}return n(new QE[l](u),o)};return i},JE=e=>XO(new Map,e)(0),ka="",{toString:QO}={},{keys:JO}=Object,bi=e=>{const t=typeof e;if(t!=="object"||!e)return[Es,t];const n=QO.call(e).slice(8,-1);switch(n){case"Array":return[ki,ka];case"Object":return[us,ka];case"Date":return[th,ka];case"RegExp":return[nh,ka];case"Map":return[rh,ka];case"Set":return[ah,ka];case"DataView":return[ki,n]}return n.includes("Array")?[ki,n]:n.includes("Error")?[gA,n]:[us,n]},Vo=([e,t])=>e===Es&&(t==="function"||t==="symbol"),eL=(e,t,n,i)=>{const o=(u,c)=>{const p=i.push(u)-1;return n.set(c,p),p},l=u=>{if(n.has(u))return n.get(u);let[c,p]=bi(u);switch(c){case Es:{let m=u;switch(p){case"bigint":c=mA,m=u.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+p);m=null;break;case"undefined":return o([fA],u)}return o([c,m],u)}case ki:{if(p){let S=u;return p==="DataView"?S=new Uint8Array(u.buffer):p==="ArrayBuffer"&&(S=new Uint8Array(u)),o([p,[...S]],u)}const m=[],h=o([c,m],u);for(const S of u)m.push(l(S));return h}case us:{if(p)switch(p){case"BigInt":return o([p,u.toString()],u);case"Boolean":case"Number":case"String":return o([p,u.valueOf()],u)}if(t&&"toJSON"in u)return l(u.toJSON());const m=[],h=o([c,m],u);for(const S of JO(u))(e||!Vo(bi(u[S])))&&m.push([l(S),l(u[S])]);return h}case th:return o([c,u.toISOString()],u);case nh:{const{source:m,flags:h}=u;return o([c,{source:m,flags:h}],u)}case rh:{const m=[],h=o([c,m],u);for(const[S,E]of u)(e||!(Vo(bi(S))||Vo(bi(E))))&&m.push([l(S),l(E)]);return h}case ah:{const m=[],h=o([c,m],u);for(const S of u)(e||!Vo(bi(S)))&&m.push(l(S));return h}}const{message:f}=u;return o([c,{name:p,message:f}],u)};return l},eS=(e,{json:t,lossy:n}={})=>{const i=[];return eL(!(t||n),!!t,new Map,i)(e),i},cs=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?JE(eS(e,t)):structuredClone(e):(e,t)=>JE(eS(e,t));function tL(e,t){const n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function nL(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function rL(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||tL,i=e.options.footnoteBackLabel||nL,o=e.options.footnoteLabel||"Footnotes",l=e.options.footnoteLabelTagName||"h2",u=e.options.footnoteLabelProperties||{className:["sr-only"]},c=[];let p=-1;for(;++p0&&v.push({type:"text",value:" "});let R=typeof n=="string"?n:n(p,E);typeof R=="string"&&(R={type:"text",value:R}),v.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+S+(E>1?"-"+E:""),dataFootnoteBackref:"",ariaLabel:typeof i=="string"?i:i(p,E),className:["data-footnote-backref"]},children:Array.isArray(R)?R:[R]})}const T=m[m.length-1];if(T&&T.type==="element"&&T.tagName==="p"){const R=T.children[T.children.length-1];R&&R.type==="text"?R.value+=" ":T.children.push({type:"text",value:" "}),T.children.push(...v)}else m.push(...v);const N={type:"element",tagName:"li",properties:{id:t+"fn-"+S},children:e.wrap(m,!0)};e.patch(f,N),c.push(N)}if(c.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:l,properties:{...cs(u),id:"footnote-label"},children:[{type:"text",value:o}]},{type:"text",value:`
`},{type:"element",tagName:"ol",properties:{},children:e.wrap(c,!0)},{type:"text",value:`
-`}]}}const Ss=(function(e){if(e==null)return oL;if(typeof e=="function")return vs(e);if(typeof e=="object")return Array.isArray(e)?rL(e):aL(e);if(typeof e=="string")return iL(e);throw new Error("Expected function, string, or object as test")});function rL(e){const t=[];let n=-1;for(;++n":""))+")"})}return S;function S(){let E=hA,v,k,T;if((!t||l(p,f,m[m.length-1]||void 0))&&(E=cL(n(p,m)),E[0]===Nm))return E;if("children"in p&&p.children){const N=p;if(N.children&&E[0]!==uL)for(k=(i?N.children.length:-1)+u,T=m.concat(N);k>-1&&k":""))+")"})}return S;function S(){let E=hA,v,k,T;if((!t||l(p,f,m[m.length-1]||void 0))&&(E=dL(n(p,m)),E[0]===Nm))return E;if("children"in p&&p.children){const N=p;if(N.children&&E[0]!==cL)for(k=(i?N.children.length:-1)+u,T=m.concat(N);k>-1&&k0&&n.push({type:"text",value:`
-`}),n}function tS(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function nS(e,t){const n=pL(e,t),i=n.one(e,void 0),o=nL(n),l=Array.isArray(i)?{type:"root",children:i}:i||{type:"root",children:[]};return o&&l.children.push({type:"text",value:`
-`},o),l}function bL(e,t){return e&&"run"in e?async function(n,i){const o=nS(n,{file:i,...t});await e.run(o,i)}:function(n,i){return nS(n,{file:i,...e||t})}}function rS(e){if(e)throw e}var Eu,aS;function yL(){if(aS)return Eu;aS=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,i=Object.getOwnPropertyDescriptor,o=function(f){return typeof Array.isArray=="function"?Array.isArray(f):t.call(f)==="[object Array]"},l=function(f){if(!f||t.call(f)!=="[object Object]")return!1;var m=e.call(f,"constructor"),h=f.constructor&&f.constructor.prototype&&e.call(f.constructor.prototype,"isPrototypeOf");if(f.constructor&&!m&&!h)return!1;var S;for(S in f);return typeof S>"u"||e.call(f,S)},u=function(f,m){n&&m.name==="__proto__"?n(f,m.name,{enumerable:!0,configurable:!0,value:m.newValue,writable:!0}):f[m.name]=m.newValue},c=function(f,m){if(m==="__proto__")if(e.call(f,m)){if(i)return i(f,m).value}else return;return f[m]};return Eu=function p(){var f,m,h,S,E,v,k=arguments[0],T=1,N=arguments.length,R=!1;for(typeof k=="boolean"&&(R=k,k=arguments[1]||{},T=2),(k==null||typeof k!="object"&&typeof k!="function")&&(k={});Tu.length;let p;c&&u.push(o);try{p=e.apply(this,u)}catch(f){const m=f;if(c&&n)throw m;return o(m)}c||(p&&p.then&&typeof p.then=="function"?p.then(l,o):p instanceof Error?o(p):l(p))}function o(u,...c){n||(n=!0,t(u,...c))}function l(u){o(null,u)}}const Un={basename:kL,dirname:_L,extname:wL,join:TL,sep:"/"};function kL(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Oi(e);let n=0,i=-1,o=e.length,l;if(t===void 0||t.length===0||t.length>e.length){for(;o--;)if(e.codePointAt(o)===47){if(l){n=o+1;break}}else i<0&&(l=!0,i=o+1);return i<0?"":e.slice(n,i)}if(t===e)return"";let u=-1,c=t.length-1;for(;o--;)if(e.codePointAt(o)===47){if(l){n=o+1;break}}else u<0&&(l=!0,u=o+1),c>-1&&(e.codePointAt(o)===t.codePointAt(c--)?c<0&&(i=o):(c=-1,i=u));return n===i?i=u:i<0&&(i=e.length),e.slice(n,i)}function _L(e){if(Oi(e),e.length===0)return".";let t=-1,n=e.length,i;for(;--n;)if(e.codePointAt(n)===47){if(i){t=n;break}}else i||(i=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function wL(e){Oi(e);let t=e.length,n=-1,i=0,o=-1,l=0,u;for(;t--;){const c=e.codePointAt(t);if(c===47){if(u){i=t+1;break}continue}n<0&&(u=!0,n=t+1),c===46?o<0?o=t:l!==1&&(l=1):o>-1&&(l=-1)}return o<0||n<0||l===0||l===1&&o===n-1&&o===i+1?"":e.slice(o,n)}function TL(...e){let t=-1,n;for(;++t0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function AL(e,t){let n="",i=0,o=-1,l=0,u=-1,c,p;for(;++u<=e.length;){if(u2){if(p=n.lastIndexOf("/"),p!==n.length-1){p<0?(n="",i=0):(n=n.slice(0,p),i=n.length-1-n.lastIndexOf("/")),o=u,l=0;continue}}else if(n.length>0){n="",i=0,o=u,l=0;continue}}t&&(n=n.length>0?n+"/..":"..",i=2)}else n.length>0?n+="/"+e.slice(o+1,u):n=e.slice(o+1,u),i=u-o-1;o=u,l=0}else c===46&&l>-1?l++:l=-1}return n}function Oi(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const RL={cwd:NL};function NL(){return"/"}function Om(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function CL(e){if(typeof e=="string")e=new URL(e);else if(!Om(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return IL(e)}function IL(e){if(e.hostname!==""){const i=new TypeError('File URL host must be "localhost" or empty on darwin');throw i.code="ERR_INVALID_FILE_URL_HOST",i}const t=e.pathname;let n=-1;for(;++n0){let[E,...v]=m;const k=i[S][1];Im(k)&&Im(E)&&(E=Su(!0,k,E)),i[S]=[f,E,...v]}}}}const ML=new oh().freeze();function wu(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Tu(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function xu(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function oS(e){if(!Im(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function sS(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Yo(e){return FL(e)?e:new yA(e)}function FL(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function PL(e){return typeof e=="string"||UL(e)}function UL(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const BL="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",lS=[],uS={allowDangerousHtml:!0},jL=/^(https?|ircs?|mailto|xmpp)$/i,zL=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"className",id:"remove-classname"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function $L(e){const t=qL(e),n=GL(e);return HL(t.runSync(t.parse(n),n),e)}function qL(e){const t=e.rehypePlugins||lS,n=e.remarkPlugins||lS,i=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...uS}:uS;return ML().use(_O).use(n).use(bL,i).use(t)}function GL(e){const t=e.children||"",n=new yA;return typeof t=="string"&&(n.value=t),n}function HL(e,t){const n=t.allowedElements,i=t.allowElement,o=t.components,l=t.disallowedElements,u=t.skipHtml,c=t.unwrapDisallowed,p=t.urlTransform||WL;for(const m of zL)Object.hasOwn(t,m.from)&&(""+m.from+(m.to?"use `"+m.to+"` instead":"remove it")+BL+m.id,void 0);return ih(e,f),o1(e,{Fragment:g.Fragment,components:o,ignoreInvalidStyle:!0,jsx:g.jsx,jsxs:g.jsxs,passKeys:!0,passNode:!0});function f(m,h,S){if(m.type==="raw"&&S&&typeof h=="number")return u?S.children.splice(h,1):S.children[h]={type:"text",value:m.value},h;if(m.type==="element"){let E;for(E in hu)if(Object.hasOwn(hu,E)&&Object.hasOwn(m.properties,E)){const v=m.properties[E],k=hu[E];(k===null||k.includes(m.tagName))&&(m.properties[E]=p(String(v||""),E,m))}}if(m.type==="element"){let E=n?!n.includes(m.tagName):l?l.includes(m.tagName):!1;if(!E&&i&&typeof h=="number"&&(E=!i(m,h,S)),E&&S&&typeof h=="number")return c&&m.children?S.children.splice(h,1,...m.children):S.children.splice(h,1),h}}}function WL(e){const t=e.indexOf(":"),n=e.indexOf("?"),i=e.indexOf("#"),o=e.indexOf("/");return t===-1||o!==-1&&t>o||n!==-1&&t>n||i!==-1&&t>i||jL.test(e.slice(0,t))?e:""}function cS(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let i=0,o=n.indexOf(t);for(;o!==-1;)i++,o=n.indexOf(t,o+t.length);return i}function VL(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function YL(e,t,n){const o=Ss((n||{}).ignore||[]),l=KL(t);let u=-1;for(;++u0?{type:"text",value:w}:void 0),w===!1?S.lastIndex=O+1:(v!==O&&R.push({type:"text",value:f.value.slice(v,O)}),Array.isArray(w)?R.push(...w):w&&R.push(w),v=O+A[0].length,N=!0),!S.global)break;A=S.exec(f.value)}return N?(v?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],i=n.indexOf(")");const o=cS(e,"(");let l=cS(e,")");for(;i!==-1&&o>l;)e+=n.slice(0,i+1),n=n.slice(i+1),i=n.indexOf(")"),l++;return[e,n]}function EA(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Wr(n)||bs(n))&&(!t||n!==47)}SA.peek=yD;function cD(){this.buffer()}function dD(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function pD(){this.buffer()}function fD(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function gD(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=On(this.sliceSerialize(e)).toLowerCase(),n.label=t}function mD(e){this.exit(e)}function hD(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=On(this.sliceSerialize(e)).toLowerCase(),n.label=t}function bD(e){this.exit(e)}function yD(){return"["}function SA(e,t,n,i){const o=n.createTracker(i);let l=o.move("[^");const u=n.enter("footnoteReference"),c=n.enter("reference");return l+=o.move(n.safe(n.associationId(e),{after:"]",before:l})),c(),u(),l+=o.move("]"),l}function ED(){return{enter:{gfmFootnoteCallString:cD,gfmFootnoteCall:dD,gfmFootnoteDefinitionLabelString:pD,gfmFootnoteDefinition:fD},exit:{gfmFootnoteCallString:gD,gfmFootnoteCall:mD,gfmFootnoteDefinitionLabelString:hD,gfmFootnoteDefinition:bD}}}function SD(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:SA},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(i,o,l,u){const c=l.createTracker(u);let p=c.move("[^");const f=l.enter("footnoteDefinition"),m=l.enter("label");return p+=c.move(l.safe(l.associationId(i),{before:p,after:"]"})),m(),p+=c.move("]:"),i.children&&i.children.length>0&&(c.shift(4),p+=c.move((t?`
-`:" ")+l.indentLines(l.containerFlow(i,c.current()),t?vA:vD))),f(),p}}function vD(e,t,n){return t===0?e:vA(e,t,n)}function vA(e,t,n){return(n?"":" ")+e}const kD=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];kA.peek=AD;function _D(){return{canContainEols:["delete"],enter:{strikethrough:TD},exit:{strikethrough:xD}}}function wD(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:kD}],handlers:{delete:kA}}}function TD(e){this.enter({type:"delete",children:[]},e)}function xD(e){this.exit(e)}function kA(e,t,n,i){const o=n.createTracker(i),l=n.enter("strikethrough");let u=o.move("~~");return u+=n.containerPhrasing(e,{...o.current(),before:u,after:"~"}),u+=o.move("~~"),l(),u}function AD(){return"~"}function RD(e){return e.length}function ND(e,t){const n=t||{},i=(n.align||[]).concat(),o=n.stringLength||RD,l=[],u=[],c=[],p=[];let f=0,m=-1;for(;++mf&&(f=e[m].length);++Np[N])&&(p[N]=A)}k.push(R)}u[m]=k,c[m]=T}let h=-1;if(typeof i=="object"&&"length"in i)for(;++hp[h]&&(p[h]=R),E[h]=R),S[h]=A}u.splice(1,0,S),c.splice(1,0,E),m=-1;const v=[];for(;++m "),l.shift(2);const u=n.indentLines(n.containerFlow(e,l.current()),OD);return o(),u}function OD(e,t,n){return">"+(n?"":" ")+e}function LD(e,t){return pS(e,t.inConstruct,!0)&&!pS(e,t.notInConstruct,!1)}function pS(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let i=-1;for(;++iu&&(u=l):l=1,o=i+t.length,i=n.indexOf(t,o);return u}function MD(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function FD(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function PD(e,t,n,i){const o=FD(n),l=e.value||"",u=o==="`"?"GraveAccent":"Tilde";if(MD(e,n)){const h=n.enter("codeIndented"),S=n.indentLines(l,UD);return h(),S}const c=n.createTracker(i),p=o.repeat(Math.max(DD(l,o)+1,3)),f=n.enter("codeFenced");let m=c.move(p);if(e.lang){const h=n.enter(`codeFencedLang${u}`);m+=c.move(n.safe(e.lang,{before:m,after:" ",encode:["`"],...c.current()})),h()}if(e.lang&&e.meta){const h=n.enter(`codeFencedMeta${u}`);m+=c.move(" "),m+=c.move(n.safe(e.meta,{before:m,after:`
+`}),n}function tS(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function nS(e,t){const n=fL(e,t),i=n.one(e,void 0),o=rL(n),l=Array.isArray(i)?{type:"root",children:i}:i||{type:"root",children:[]};return o&&l.children.push({type:"text",value:`
+`},o),l}function yL(e,t){return e&&"run"in e?async function(n,i){const o=nS(n,{file:i,...t});await e.run(o,i)}:function(n,i){return nS(n,{file:i,...e||t})}}function rS(e){if(e)throw e}var Eu,aS;function EL(){if(aS)return Eu;aS=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,i=Object.getOwnPropertyDescriptor,o=function(f){return typeof Array.isArray=="function"?Array.isArray(f):t.call(f)==="[object Array]"},l=function(f){if(!f||t.call(f)!=="[object Object]")return!1;var m=e.call(f,"constructor"),h=f.constructor&&f.constructor.prototype&&e.call(f.constructor.prototype,"isPrototypeOf");if(f.constructor&&!m&&!h)return!1;var S;for(S in f);return typeof S>"u"||e.call(f,S)},u=function(f,m){n&&m.name==="__proto__"?n(f,m.name,{enumerable:!0,configurable:!0,value:m.newValue,writable:!0}):f[m.name]=m.newValue},c=function(f,m){if(m==="__proto__")if(e.call(f,m)){if(i)return i(f,m).value}else return;return f[m]};return Eu=function p(){var f,m,h,S,E,v,k=arguments[0],T=1,N=arguments.length,R=!1;for(typeof k=="boolean"&&(R=k,k=arguments[1]||{},T=2),(k==null||typeof k!="object"&&typeof k!="function")&&(k={});Tu.length;let p;c&&u.push(o);try{p=e.apply(this,u)}catch(f){const m=f;if(c&&n)throw m;return o(m)}c||(p&&p.then&&typeof p.then=="function"?p.then(l,o):p instanceof Error?o(p):l(p))}function o(u,...c){n||(n=!0,t(u,...c))}function l(u){o(null,u)}}const Un={basename:_L,dirname:wL,extname:TL,join:xL,sep:"/"};function _L(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Oi(e);let n=0,i=-1,o=e.length,l;if(t===void 0||t.length===0||t.length>e.length){for(;o--;)if(e.codePointAt(o)===47){if(l){n=o+1;break}}else i<0&&(l=!0,i=o+1);return i<0?"":e.slice(n,i)}if(t===e)return"";let u=-1,c=t.length-1;for(;o--;)if(e.codePointAt(o)===47){if(l){n=o+1;break}}else u<0&&(l=!0,u=o+1),c>-1&&(e.codePointAt(o)===t.codePointAt(c--)?c<0&&(i=o):(c=-1,i=u));return n===i?i=u:i<0&&(i=e.length),e.slice(n,i)}function wL(e){if(Oi(e),e.length===0)return".";let t=-1,n=e.length,i;for(;--n;)if(e.codePointAt(n)===47){if(i){t=n;break}}else i||(i=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function TL(e){Oi(e);let t=e.length,n=-1,i=0,o=-1,l=0,u;for(;t--;){const c=e.codePointAt(t);if(c===47){if(u){i=t+1;break}continue}n<0&&(u=!0,n=t+1),c===46?o<0?o=t:l!==1&&(l=1):o>-1&&(l=-1)}return o<0||n<0||l===0||l===1&&o===n-1&&o===i+1?"":e.slice(o,n)}function xL(...e){let t=-1,n;for(;++t0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function RL(e,t){let n="",i=0,o=-1,l=0,u=-1,c,p;for(;++u<=e.length;){if(u2){if(p=n.lastIndexOf("/"),p!==n.length-1){p<0?(n="",i=0):(n=n.slice(0,p),i=n.length-1-n.lastIndexOf("/")),o=u,l=0;continue}}else if(n.length>0){n="",i=0,o=u,l=0;continue}}t&&(n=n.length>0?n+"/..":"..",i=2)}else n.length>0?n+="/"+e.slice(o+1,u):n=e.slice(o+1,u),i=u-o-1;o=u,l=0}else c===46&&l>-1?l++:l=-1}return n}function Oi(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const NL={cwd:CL};function CL(){return"/"}function Om(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function IL(e){if(typeof e=="string")e=new URL(e);else if(!Om(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return OL(e)}function OL(e){if(e.hostname!==""){const i=new TypeError('File URL host must be "localhost" or empty on darwin');throw i.code="ERR_INVALID_FILE_URL_HOST",i}const t=e.pathname;let n=-1;for(;++n0){let[E,...v]=m;const k=i[S][1];Im(k)&&Im(E)&&(E=Su(!0,k,E)),i[S]=[f,E,...v]}}}}const FL=new oh().freeze();function wu(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Tu(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function xu(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function oS(e){if(!Im(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function sS(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Yo(e){return PL(e)?e:new yA(e)}function PL(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function UL(e){return typeof e=="string"||BL(e)}function BL(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const jL="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",lS=[],uS={allowDangerousHtml:!0},zL=/^(https?|ircs?|mailto|xmpp)$/i,$L=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"className",id:"remove-classname"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function qL(e){const t=GL(e),n=HL(e);return WL(t.runSync(t.parse(n),n),e)}function GL(e){const t=e.rehypePlugins||lS,n=e.remarkPlugins||lS,i=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...uS}:uS;return FL().use(wO).use(n).use(yL,i).use(t)}function HL(e){const t=e.children||"",n=new yA;return typeof t=="string"&&(n.value=t),n}function WL(e,t){const n=t.allowedElements,i=t.allowElement,o=t.components,l=t.disallowedElements,u=t.skipHtml,c=t.unwrapDisallowed,p=t.urlTransform||VL;for(const m of $L)Object.hasOwn(t,m.from)&&(""+m.from+(m.to?"use `"+m.to+"` instead":"remove it")+jL+m.id,void 0);return ih(e,f),s1(e,{Fragment:g.Fragment,components:o,ignoreInvalidStyle:!0,jsx:g.jsx,jsxs:g.jsxs,passKeys:!0,passNode:!0});function f(m,h,S){if(m.type==="raw"&&S&&typeof h=="number")return u?S.children.splice(h,1):S.children[h]={type:"text",value:m.value},h;if(m.type==="element"){let E;for(E in hu)if(Object.hasOwn(hu,E)&&Object.hasOwn(m.properties,E)){const v=m.properties[E],k=hu[E];(k===null||k.includes(m.tagName))&&(m.properties[E]=p(String(v||""),E,m))}}if(m.type==="element"){let E=n?!n.includes(m.tagName):l?l.includes(m.tagName):!1;if(!E&&i&&typeof h=="number"&&(E=!i(m,h,S)),E&&S&&typeof h=="number")return c&&m.children?S.children.splice(h,1,...m.children):S.children.splice(h,1),h}}}function VL(e){const t=e.indexOf(":"),n=e.indexOf("?"),i=e.indexOf("#"),o=e.indexOf("/");return t===-1||o!==-1&&t>o||n!==-1&&t>n||i!==-1&&t>i||zL.test(e.slice(0,t))?e:""}function cS(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let i=0,o=n.indexOf(t);for(;o!==-1;)i++,o=n.indexOf(t,o+t.length);return i}function YL(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function KL(e,t,n){const o=Ss((n||{}).ignore||[]),l=ZL(t);let u=-1;for(;++u0?{type:"text",value:w}:void 0),w===!1?S.lastIndex=O+1:(v!==O&&R.push({type:"text",value:f.value.slice(v,O)}),Array.isArray(w)?R.push(...w):w&&R.push(w),v=O+A[0].length,N=!0),!S.global)break;A=S.exec(f.value)}return N?(v?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],i=n.indexOf(")");const o=cS(e,"(");let l=cS(e,")");for(;i!==-1&&o>l;)e+=n.slice(0,i+1),n=n.slice(i+1),i=n.indexOf(")"),l++;return[e,n]}function EA(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Wr(n)||bs(n))&&(!t||n!==47)}SA.peek=ED;function dD(){this.buffer()}function pD(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function fD(){this.buffer()}function gD(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function mD(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=On(this.sliceSerialize(e)).toLowerCase(),n.label=t}function hD(e){this.exit(e)}function bD(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=On(this.sliceSerialize(e)).toLowerCase(),n.label=t}function yD(e){this.exit(e)}function ED(){return"["}function SA(e,t,n,i){const o=n.createTracker(i);let l=o.move("[^");const u=n.enter("footnoteReference"),c=n.enter("reference");return l+=o.move(n.safe(n.associationId(e),{after:"]",before:l})),c(),u(),l+=o.move("]"),l}function SD(){return{enter:{gfmFootnoteCallString:dD,gfmFootnoteCall:pD,gfmFootnoteDefinitionLabelString:fD,gfmFootnoteDefinition:gD},exit:{gfmFootnoteCallString:mD,gfmFootnoteCall:hD,gfmFootnoteDefinitionLabelString:bD,gfmFootnoteDefinition:yD}}}function vD(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:SA},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(i,o,l,u){const c=l.createTracker(u);let p=c.move("[^");const f=l.enter("footnoteDefinition"),m=l.enter("label");return p+=c.move(l.safe(l.associationId(i),{before:p,after:"]"})),m(),p+=c.move("]:"),i.children&&i.children.length>0&&(c.shift(4),p+=c.move((t?`
+`:" ")+l.indentLines(l.containerFlow(i,c.current()),t?vA:kD))),f(),p}}function kD(e,t,n){return t===0?e:vA(e,t,n)}function vA(e,t,n){return(n?"":" ")+e}const _D=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];kA.peek=RD;function wD(){return{canContainEols:["delete"],enter:{strikethrough:xD},exit:{strikethrough:AD}}}function TD(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:_D}],handlers:{delete:kA}}}function xD(e){this.enter({type:"delete",children:[]},e)}function AD(e){this.exit(e)}function kA(e,t,n,i){const o=n.createTracker(i),l=n.enter("strikethrough");let u=o.move("~~");return u+=n.containerPhrasing(e,{...o.current(),before:u,after:"~"}),u+=o.move("~~"),l(),u}function RD(){return"~"}function ND(e){return e.length}function CD(e,t){const n=t||{},i=(n.align||[]).concat(),o=n.stringLength||ND,l=[],u=[],c=[],p=[];let f=0,m=-1;for(;++mf&&(f=e[m].length);++Np[N])&&(p[N]=A)}k.push(R)}u[m]=k,c[m]=T}let h=-1;if(typeof i=="object"&&"length"in i)for(;++hp[h]&&(p[h]=R),E[h]=R),S[h]=A}u.splice(1,0,S),c.splice(1,0,E),m=-1;const v=[];for(;++m "),l.shift(2);const u=n.indentLines(n.containerFlow(e,l.current()),LD);return o(),u}function LD(e,t,n){return">"+(n?"":" ")+e}function DD(e,t){return pS(e,t.inConstruct,!0)&&!pS(e,t.notInConstruct,!1)}function pS(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let i=-1;for(;++iu&&(u=l):l=1,o=i+t.length,i=n.indexOf(t,o);return u}function FD(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function PD(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function UD(e,t,n,i){const o=PD(n),l=e.value||"",u=o==="`"?"GraveAccent":"Tilde";if(FD(e,n)){const h=n.enter("codeIndented"),S=n.indentLines(l,BD);return h(),S}const c=n.createTracker(i),p=o.repeat(Math.max(MD(l,o)+1,3)),f=n.enter("codeFenced");let m=c.move(p);if(e.lang){const h=n.enter(`codeFencedLang${u}`);m+=c.move(n.safe(e.lang,{before:m,after:" ",encode:["`"],...c.current()})),h()}if(e.lang&&e.meta){const h=n.enter(`codeFencedMeta${u}`);m+=c.move(" "),m+=c.move(n.safe(e.meta,{before:m,after:`
`,encode:["`"],...c.current()})),h()}return m+=c.move(`
`),l&&(m+=c.move(l+`
-`)),m+=c.move(p),f(),m}function UD(e,t,n){return(n?"":" ")+e}function sh(e){const t=e.options.quote||'"';if(t!=='"'&&t!=="'")throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function BD(e,t,n,i){const o=sh(n),l=o==='"'?"Quote":"Apostrophe",u=n.enter("definition");let c=n.enter("label");const p=n.createTracker(i);let f=p.move("[");return f+=p.move(n.safe(n.associationId(e),{before:f,after:"]",...p.current()})),f+=p.move("]: "),c(),!e.url||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),f+=p.move("<"),f+=p.move(n.safe(e.url,{before:f,after:">",...p.current()})),f+=p.move(">")):(c=n.enter("destinationRaw"),f+=p.move(n.safe(e.url,{before:f,after:e.title?" ":`
-`,...p.current()}))),c(),e.title&&(c=n.enter(`title${l}`),f+=p.move(" "+o),f+=p.move(n.safe(e.title,{before:f,after:o,...p.current()})),f+=p.move(o),c()),u(),f}function jD(e){const t=e.options.emphasis||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function xi(e){return""+e.toString(16).toUpperCase()+";"}function ds(e,t,n){const i=Ra(e),o=Ra(t);return i===void 0?o===void 0?n==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:i===1?o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}_A.peek=zD;function _A(e,t,n,i){const o=jD(n),l=n.enter("emphasis"),u=n.createTracker(i),c=u.move(o);let p=u.move(n.containerPhrasing(e,{after:o,before:c,...u.current()}));const f=p.charCodeAt(0),m=ds(i.before.charCodeAt(i.before.length-1),f,o);m.inside&&(p=xi(f)+p.slice(1));const h=p.charCodeAt(p.length-1),S=ds(i.after.charCodeAt(0),h,o);S.inside&&(p=p.slice(0,-1)+xi(h));const E=u.move(o);return l(),n.attentionEncodeSurroundingInfo={after:S.outside,before:m.outside},c+p+E}function zD(e,t,n){return n.options.emphasis||"*"}function $D(e,t){let n=!1;return ih(e,function(i){if("value"in i&&/\r?\n|\r/.test(i.value)||i.type==="break")return n=!0,Nm}),!!((!e.depth||e.depth<3)&&Qm(e)&&(t.options.setext||n))}function qD(e,t,n,i){const o=Math.max(Math.min(6,e.depth||1),1),l=n.createTracker(i);if($D(e,n)){const m=n.enter("headingSetext"),h=n.enter("phrasing"),S=n.containerPhrasing(e,{...l.current(),before:`
+`)),m+=c.move(p),f(),m}function BD(e,t,n){return(n?"":" ")+e}function sh(e){const t=e.options.quote||'"';if(t!=='"'&&t!=="'")throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function jD(e,t,n,i){const o=sh(n),l=o==='"'?"Quote":"Apostrophe",u=n.enter("definition");let c=n.enter("label");const p=n.createTracker(i);let f=p.move("[");return f+=p.move(n.safe(n.associationId(e),{before:f,after:"]",...p.current()})),f+=p.move("]: "),c(),!e.url||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),f+=p.move("<"),f+=p.move(n.safe(e.url,{before:f,after:">",...p.current()})),f+=p.move(">")):(c=n.enter("destinationRaw"),f+=p.move(n.safe(e.url,{before:f,after:e.title?" ":`
+`,...p.current()}))),c(),e.title&&(c=n.enter(`title${l}`),f+=p.move(" "+o),f+=p.move(n.safe(e.title,{before:f,after:o,...p.current()})),f+=p.move(o),c()),u(),f}function zD(e){const t=e.options.emphasis||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function xi(e){return""+e.toString(16).toUpperCase()+";"}function ds(e,t,n){const i=Ra(e),o=Ra(t);return i===void 0?o===void 0?n==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:i===1?o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}_A.peek=$D;function _A(e,t,n,i){const o=zD(n),l=n.enter("emphasis"),u=n.createTracker(i),c=u.move(o);let p=u.move(n.containerPhrasing(e,{after:o,before:c,...u.current()}));const f=p.charCodeAt(0),m=ds(i.before.charCodeAt(i.before.length-1),f,o);m.inside&&(p=xi(f)+p.slice(1));const h=p.charCodeAt(p.length-1),S=ds(i.after.charCodeAt(0),h,o);S.inside&&(p=p.slice(0,-1)+xi(h));const E=u.move(o);return l(),n.attentionEncodeSurroundingInfo={after:S.outside,before:m.outside},c+p+E}function $D(e,t,n){return n.options.emphasis||"*"}function qD(e,t){let n=!1;return ih(e,function(i){if("value"in i&&/\r?\n|\r/.test(i.value)||i.type==="break")return n=!0,Nm}),!!((!e.depth||e.depth<3)&&Qm(e)&&(t.options.setext||n))}function GD(e,t,n,i){const o=Math.max(Math.min(6,e.depth||1),1),l=n.createTracker(i);if(qD(e,n)){const m=n.enter("headingSetext"),h=n.enter("phrasing"),S=n.containerPhrasing(e,{...l.current(),before:`
`,after:`
`});return h(),m(),S+`
`+(o===1?"=":"-").repeat(S.length-(Math.max(S.lastIndexOf("\r"),S.lastIndexOf(`
`))+1))}const u="#".repeat(o),c=n.enter("headingAtx"),p=n.enter("phrasing");l.move(u+" ");let f=n.containerPhrasing(e,{before:"# ",after:`
-`,...l.current()});return/^[\t ]/.test(f)&&(f=xi(f.charCodeAt(0))+f.slice(1)),f=f?u+" "+f:u,n.options.closeAtx&&(f+=" "+u),p(),c(),f}wA.peek=GD;function wA(e){return e.value||""}function GD(){return"<"}TA.peek=HD;function TA(e,t,n,i){const o=sh(n),l=o==='"'?"Quote":"Apostrophe",u=n.enter("image");let c=n.enter("label");const p=n.createTracker(i);let f=p.move("![");return f+=p.move(n.safe(e.alt,{before:f,after:"]",...p.current()})),f+=p.move("]("),c(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),f+=p.move("<"),f+=p.move(n.safe(e.url,{before:f,after:">",...p.current()})),f+=p.move(">")):(c=n.enter("destinationRaw"),f+=p.move(n.safe(e.url,{before:f,after:e.title?" ":")",...p.current()}))),c(),e.title&&(c=n.enter(`title${l}`),f+=p.move(" "+o),f+=p.move(n.safe(e.title,{before:f,after:o,...p.current()})),f+=p.move(o),c()),f+=p.move(")"),u(),f}function HD(){return"!"}xA.peek=WD;function xA(e,t,n,i){const o=e.referenceType,l=n.enter("imageReference");let u=n.enter("label");const c=n.createTracker(i);let p=c.move("![");const f=n.safe(e.alt,{before:p,after:"]",...c.current()});p+=c.move(f+"]["),u();const m=n.stack;n.stack=[],u=n.enter("reference");const h=n.safe(n.associationId(e),{before:p,after:"]",...c.current()});return u(),n.stack=m,l(),o==="full"||!f||f!==h?p+=c.move(h+"]"):o==="shortcut"?p=p.slice(0,-1):p+=c.move("]"),p}function WD(){return"!"}AA.peek=VD;function AA(e,t,n){let i=e.value||"",o="`",l=-1;for(;new RegExp("(^|[^`])"+o+"([^`]|$)").test(i);)o+="`";for(/[^ \r\n]/.test(i)&&(/^[ \r\n]/.test(i)&&/[ \r\n]$/.test(i)||/^`|`$/.test(i))&&(i=" "+i+" ");++l\u007F]/.test(e.url))}NA.peek=YD;function NA(e,t,n,i){const o=sh(n),l=o==='"'?"Quote":"Apostrophe",u=n.createTracker(i);let c,p;if(RA(e,n)){const m=n.stack;n.stack=[],c=n.enter("autolink");let h=u.move("<");return h+=u.move(n.containerPhrasing(e,{before:h,after:">",...u.current()})),h+=u.move(">"),c(),n.stack=m,h}c=n.enter("link"),p=n.enter("label");let f=u.move("[");return f+=u.move(n.containerPhrasing(e,{before:f,after:"](",...u.current()})),f+=u.move("]("),p(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(p=n.enter("destinationLiteral"),f+=u.move("<"),f+=u.move(n.safe(e.url,{before:f,after:">",...u.current()})),f+=u.move(">")):(p=n.enter("destinationRaw"),f+=u.move(n.safe(e.url,{before:f,after:e.title?" ":")",...u.current()}))),p(),e.title&&(p=n.enter(`title${l}`),f+=u.move(" "+o),f+=u.move(n.safe(e.title,{before:f,after:o,...u.current()})),f+=u.move(o),p()),f+=u.move(")"),c(),f}function YD(e,t,n){return RA(e,n)?"<":"["}CA.peek=KD;function CA(e,t,n,i){const o=e.referenceType,l=n.enter("linkReference");let u=n.enter("label");const c=n.createTracker(i);let p=c.move("[");const f=n.containerPhrasing(e,{before:p,after:"]",...c.current()});p+=c.move(f+"]["),u();const m=n.stack;n.stack=[],u=n.enter("reference");const h=n.safe(n.associationId(e),{before:p,after:"]",...c.current()});return u(),n.stack=m,l(),o==="full"||!f||f!==h?p+=c.move(h+"]"):o==="shortcut"?p=p.slice(0,-1):p+=c.move("]"),p}function KD(){return"["}function lh(e){const t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function ZD(e){const t=lh(e),n=e.options.bulletOther;if(!n)return t==="*"?"-":"*";if(n!=="*"&&n!=="+"&&n!=="-")throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function XD(e){const t=e.options.bulletOrdered||".";if(t!=="."&&t!==")")throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function IA(e){const t=e.options.rule||"*";if(t!=="*"&&t!=="-"&&t!=="_")throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function QD(e,t,n,i){const o=n.enter("list"),l=n.bulletCurrent;let u=e.ordered?XD(n):lh(n);const c=e.ordered?u==="."?")":".":ZD(n);let p=t&&n.bulletLastUsed?u===n.bulletLastUsed:!1;if(!e.ordered){const m=e.children?e.children[0]:void 0;if((u==="*"||u==="-")&&m&&(!m.children||!m.children[0])&&n.stack[n.stack.length-1]==="list"&&n.stack[n.stack.length-2]==="listItem"&&n.stack[n.stack.length-3]==="list"&&n.stack[n.stack.length-4]==="listItem"&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(p=!0),IA(n)===u&&m){let h=-1;for(;++h-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+l);let u=l.length+1;(o==="tab"||o==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(u=Math.ceil(u/4)*4);const c=n.createTracker(i);c.move(l+" ".repeat(u-l.length)),c.shift(u);const p=n.enter("listItem"),f=n.indentLines(n.containerFlow(e,c.current()),m);return p(),f;function m(h,S,E){return S?(E?"":" ".repeat(u))+h:(E?l:l+" ".repeat(u-l.length))+h}}function t2(e,t,n,i){const o=n.enter("paragraph"),l=n.enter("phrasing"),u=n.containerPhrasing(e,i);return l(),o(),u}const n2=Ss(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function r2(e,t,n,i){return(e.children.some(function(u){return n2(u)})?n.containerPhrasing:n.containerFlow).call(n,e,i)}function a2(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}OA.peek=i2;function OA(e,t,n,i){const o=a2(n),l=n.enter("strong"),u=n.createTracker(i),c=u.move(o+o);let p=u.move(n.containerPhrasing(e,{after:o,before:c,...u.current()}));const f=p.charCodeAt(0),m=ds(i.before.charCodeAt(i.before.length-1),f,o);m.inside&&(p=xi(f)+p.slice(1));const h=p.charCodeAt(p.length-1),S=ds(i.after.charCodeAt(0),h,o);S.inside&&(p=p.slice(0,-1)+xi(h));const E=u.move(o+o);return l(),n.attentionEncodeSurroundingInfo={after:S.outside,before:m.outside},c+p+E}function i2(e,t,n){return n.options.strong||"*"}function o2(e,t,n,i){return n.safe(e.value,i)}function s2(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function l2(e,t,n){const i=(IA(n)+(n.options.ruleSpaces?" ":"")).repeat(s2(n));return n.options.ruleSpaces?i.slice(0,-1):i}const LA={blockquote:ID,break:fS,code:PD,definition:BD,emphasis:_A,hardBreak:fS,heading:qD,html:wA,image:TA,imageReference:xA,inlineCode:AA,link:NA,linkReference:CA,list:QD,listItem:e2,paragraph:t2,root:r2,strong:OA,text:o2,thematicBreak:l2};function u2(){return{enter:{table:c2,tableData:gS,tableHeader:gS,tableRow:p2},exit:{codeText:f2,table:d2,tableData:Cu,tableHeader:Cu,tableRow:Cu}}}function c2(e){const t=e._align;this.enter({type:"table",align:t.map(function(n){return n==="none"?null:n}),children:[]},e),this.data.inTable=!0}function d2(e){this.exit(e),this.data.inTable=void 0}function p2(e){this.enter({type:"tableRow",children:[]},e)}function Cu(e){this.exit(e)}function gS(e){this.enter({type:"tableCell",children:[]},e)}function f2(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,g2));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function g2(e,t){return t==="|"?t:e}function m2(e){const t=e||{},n=t.tableCellPadding,i=t.tablePipeAlign,o=t.stringLength,l=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
+`,...l.current()});return/^[\t ]/.test(f)&&(f=xi(f.charCodeAt(0))+f.slice(1)),f=f?u+" "+f:u,n.options.closeAtx&&(f+=" "+u),p(),c(),f}wA.peek=HD;function wA(e){return e.value||""}function HD(){return"<"}TA.peek=WD;function TA(e,t,n,i){const o=sh(n),l=o==='"'?"Quote":"Apostrophe",u=n.enter("image");let c=n.enter("label");const p=n.createTracker(i);let f=p.move("![");return f+=p.move(n.safe(e.alt,{before:f,after:"]",...p.current()})),f+=p.move("]("),c(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(c=n.enter("destinationLiteral"),f+=p.move("<"),f+=p.move(n.safe(e.url,{before:f,after:">",...p.current()})),f+=p.move(">")):(c=n.enter("destinationRaw"),f+=p.move(n.safe(e.url,{before:f,after:e.title?" ":")",...p.current()}))),c(),e.title&&(c=n.enter(`title${l}`),f+=p.move(" "+o),f+=p.move(n.safe(e.title,{before:f,after:o,...p.current()})),f+=p.move(o),c()),f+=p.move(")"),u(),f}function WD(){return"!"}xA.peek=VD;function xA(e,t,n,i){const o=e.referenceType,l=n.enter("imageReference");let u=n.enter("label");const c=n.createTracker(i);let p=c.move("![");const f=n.safe(e.alt,{before:p,after:"]",...c.current()});p+=c.move(f+"]["),u();const m=n.stack;n.stack=[],u=n.enter("reference");const h=n.safe(n.associationId(e),{before:p,after:"]",...c.current()});return u(),n.stack=m,l(),o==="full"||!f||f!==h?p+=c.move(h+"]"):o==="shortcut"?p=p.slice(0,-1):p+=c.move("]"),p}function VD(){return"!"}AA.peek=YD;function AA(e,t,n){let i=e.value||"",o="`",l=-1;for(;new RegExp("(^|[^`])"+o+"([^`]|$)").test(i);)o+="`";for(/[^ \r\n]/.test(i)&&(/^[ \r\n]/.test(i)&&/[ \r\n]$/.test(i)||/^`|`$/.test(i))&&(i=" "+i+" ");++l\u007F]/.test(e.url))}NA.peek=KD;function NA(e,t,n,i){const o=sh(n),l=o==='"'?"Quote":"Apostrophe",u=n.createTracker(i);let c,p;if(RA(e,n)){const m=n.stack;n.stack=[],c=n.enter("autolink");let h=u.move("<");return h+=u.move(n.containerPhrasing(e,{before:h,after:">",...u.current()})),h+=u.move(">"),c(),n.stack=m,h}c=n.enter("link"),p=n.enter("label");let f=u.move("[");return f+=u.move(n.containerPhrasing(e,{before:f,after:"](",...u.current()})),f+=u.move("]("),p(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(p=n.enter("destinationLiteral"),f+=u.move("<"),f+=u.move(n.safe(e.url,{before:f,after:">",...u.current()})),f+=u.move(">")):(p=n.enter("destinationRaw"),f+=u.move(n.safe(e.url,{before:f,after:e.title?" ":")",...u.current()}))),p(),e.title&&(p=n.enter(`title${l}`),f+=u.move(" "+o),f+=u.move(n.safe(e.title,{before:f,after:o,...u.current()})),f+=u.move(o),p()),f+=u.move(")"),c(),f}function KD(e,t,n){return RA(e,n)?"<":"["}CA.peek=ZD;function CA(e,t,n,i){const o=e.referenceType,l=n.enter("linkReference");let u=n.enter("label");const c=n.createTracker(i);let p=c.move("[");const f=n.containerPhrasing(e,{before:p,after:"]",...c.current()});p+=c.move(f+"]["),u();const m=n.stack;n.stack=[],u=n.enter("reference");const h=n.safe(n.associationId(e),{before:p,after:"]",...c.current()});return u(),n.stack=m,l(),o==="full"||!f||f!==h?p+=c.move(h+"]"):o==="shortcut"?p=p.slice(0,-1):p+=c.move("]"),p}function ZD(){return"["}function lh(e){const t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function XD(e){const t=lh(e),n=e.options.bulletOther;if(!n)return t==="*"?"-":"*";if(n!=="*"&&n!=="+"&&n!=="-")throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function QD(e){const t=e.options.bulletOrdered||".";if(t!=="."&&t!==")")throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function IA(e){const t=e.options.rule||"*";if(t!=="*"&&t!=="-"&&t!=="_")throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function JD(e,t,n,i){const o=n.enter("list"),l=n.bulletCurrent;let u=e.ordered?QD(n):lh(n);const c=e.ordered?u==="."?")":".":XD(n);let p=t&&n.bulletLastUsed?u===n.bulletLastUsed:!1;if(!e.ordered){const m=e.children?e.children[0]:void 0;if((u==="*"||u==="-")&&m&&(!m.children||!m.children[0])&&n.stack[n.stack.length-1]==="list"&&n.stack[n.stack.length-2]==="listItem"&&n.stack[n.stack.length-3]==="list"&&n.stack[n.stack.length-4]==="listItem"&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(p=!0),IA(n)===u&&m){let h=-1;for(;++h-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+l);let u=l.length+1;(o==="tab"||o==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(u=Math.ceil(u/4)*4);const c=n.createTracker(i);c.move(l+" ".repeat(u-l.length)),c.shift(u);const p=n.enter("listItem"),f=n.indentLines(n.containerFlow(e,c.current()),m);return p(),f;function m(h,S,E){return S?(E?"":" ".repeat(u))+h:(E?l:l+" ".repeat(u-l.length))+h}}function n2(e,t,n,i){const o=n.enter("paragraph"),l=n.enter("phrasing"),u=n.containerPhrasing(e,i);return l(),o(),u}const r2=Ss(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function a2(e,t,n,i){return(e.children.some(function(u){return r2(u)})?n.containerPhrasing:n.containerFlow).call(n,e,i)}function i2(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}OA.peek=o2;function OA(e,t,n,i){const o=i2(n),l=n.enter("strong"),u=n.createTracker(i),c=u.move(o+o);let p=u.move(n.containerPhrasing(e,{after:o,before:c,...u.current()}));const f=p.charCodeAt(0),m=ds(i.before.charCodeAt(i.before.length-1),f,o);m.inside&&(p=xi(f)+p.slice(1));const h=p.charCodeAt(p.length-1),S=ds(i.after.charCodeAt(0),h,o);S.inside&&(p=p.slice(0,-1)+xi(h));const E=u.move(o+o);return l(),n.attentionEncodeSurroundingInfo={after:S.outside,before:m.outside},c+p+E}function o2(e,t,n){return n.options.strong||"*"}function s2(e,t,n,i){return n.safe(e.value,i)}function l2(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function u2(e,t,n){const i=(IA(n)+(n.options.ruleSpaces?" ":"")).repeat(l2(n));return n.options.ruleSpaces?i.slice(0,-1):i}const LA={blockquote:OD,break:fS,code:UD,definition:jD,emphasis:_A,hardBreak:fS,heading:GD,html:wA,image:TA,imageReference:xA,inlineCode:AA,link:NA,linkReference:CA,list:JD,listItem:t2,paragraph:n2,root:a2,strong:OA,text:s2,thematicBreak:u2};function c2(){return{enter:{table:d2,tableData:gS,tableHeader:gS,tableRow:f2},exit:{codeText:g2,table:p2,tableData:Cu,tableHeader:Cu,tableRow:Cu}}}function d2(e){const t=e._align;this.enter({type:"table",align:t.map(function(n){return n==="none"?null:n}),children:[]},e),this.data.inTable=!0}function p2(e){this.exit(e),this.data.inTable=void 0}function f2(e){this.enter({type:"tableRow",children:[]},e)}function Cu(e){this.exit(e)}function gS(e){this.enter({type:"tableCell",children:[]},e)}function g2(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,m2));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function m2(e,t){return t==="|"?t:e}function h2(e){const t=e||{},n=t.tableCellPadding,i=t.tablePipeAlign,o=t.stringLength,l=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:S,table:u,tableCell:p,tableRow:c}};function u(E,v,k,T){return f(m(E,k,T),E.align)}function c(E,v,k,T){const N=h(E,k,T),R=f([N]);return R.slice(0,R.indexOf(`
-`))}function p(E,v,k,T){const N=k.enter("tableCell"),R=k.enter("phrasing"),A=k.containerPhrasing(E,{...T,before:l,after:l});return R(),N(),A}function f(E,v){return ND(E,{align:v,alignDelimiters:i,padding:n,stringLength:o})}function m(E,v,k){const T=E.children;let N=-1;const R=[],A=v.enter("table");for(;++N0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const L2={tokenize:z2,partial:!0};function D2(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:U2,continuation:{tokenize:B2},exit:j2}},text:{91:{name:"gfmFootnoteCall",tokenize:P2},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:M2,resolveTo:F2}}}}function M2(e,t,n){const i=this;let o=i.events.length;const l=i.parser.gfmFootnotes||(i.parser.gfmFootnotes=[]);let u;for(;o--;){const p=i.events[o][1];if(p.type==="labelImage"){u=p;break}if(p.type==="gfmFootnoteCall"||p.type==="labelLink"||p.type==="label"||p.type==="image"||p.type==="link")break}return c;function c(p){if(!u||!u._balanced)return n(p);const f=On(i.sliceSerialize({start:u.end,end:i.now()}));return f.codePointAt(0)!==94||!l.includes(f.slice(1))?n(p):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(p),e.exit("gfmFootnoteCallLabelMarker"),t(p))}}function F2(e,t){let n=e.length;for(;n--;)if(e[n][1].type==="labelImage"&&e[n][0]==="enter"){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const i={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},o={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};o.end.column++,o.end.offset++,o.end._bufferIndex++;const l={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},u={type:"chunkString",contentType:"string",start:Object.assign({},l.start),end:Object.assign({},l.end)},c=[e[n+1],e[n+2],["enter",i,t],e[n+3],e[n+4],["enter",o,t],["exit",o,t],["enter",l,t],["enter",u,t],["exit",u,t],["exit",l,t],e[e.length-2],e[e.length-1],["exit",i,t]];return e.splice(n,e.length-n+1,...c),e}function P2(e,t,n){const i=this,o=i.parser.gfmFootnotes||(i.parser.gfmFootnotes=[]);let l=0,u;return c;function c(h){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(h),e.exit("gfmFootnoteCallLabelMarker"),p}function p(h){return h!==94?n(h):(e.enter("gfmFootnoteCallMarker"),e.consume(h),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",f)}function f(h){if(l>999||h===93&&!u||h===null||h===91||He(h))return n(h);if(h===93){e.exit("chunkString");const S=e.exit("gfmFootnoteCallString");return o.includes(On(i.sliceSerialize(S)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(h),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(h)}return He(h)||(u=!0),l++,e.consume(h),h===92?m:f}function m(h){return h===91||h===92||h===93?(e.consume(h),l++,f):f(h)}}function U2(e,t,n){const i=this,o=i.parser.gfmFootnotes||(i.parser.gfmFootnotes=[]);let l,u=0,c;return p;function p(v){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(v),e.exit("gfmFootnoteDefinitionLabelMarker"),f}function f(v){return v===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(v),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",m):n(v)}function m(v){if(u>999||v===93&&!c||v===null||v===91||He(v))return n(v);if(v===93){e.exit("chunkString");const k=e.exit("gfmFootnoteDefinitionLabelString");return l=On(i.sliceSerialize(k)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(v),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),S}return He(v)||(c=!0),u++,e.consume(v),v===92?h:m}function h(v){return v===91||v===92||v===93?(e.consume(v),u++,m):m(v)}function S(v){return v===58?(e.enter("definitionMarker"),e.consume(v),e.exit("definitionMarker"),o.includes(l)||o.push(l),Pe(e,E,"gfmFootnoteDefinitionWhitespace")):n(v)}function E(v){return t(v)}}function B2(e,t,n){return e.check(Ii,t,e.attempt(L2,t,n))}function j2(e){e.exit("gfmFootnoteDefinition")}function z2(e,t,n){const i=this;return Pe(e,o,"gfmFootnoteDefinitionIndent",5);function o(l){const u=i.events[i.events.length-1];return u&&u[1].type==="gfmFootnoteDefinitionIndent"&&u[2].sliceSerialize(u[1],!0).length===4?t(l):n(l)}}function $2(e){let n=(e||{}).singleTilde;const i={name:"strikethrough",tokenize:l,resolveAll:o};return n==null&&(n=!0),{text:{126:i},insideSpan:{null:[i]},attentionMarkers:{null:[126]}};function o(u,c){let p=-1;for(;++p1?p(v):(u.consume(v),h++,E);if(h<2&&!n)return p(v);const T=u.exit("strikethroughSequenceTemporary"),N=Ra(v);return T._open=!N||N===2&&!!k,T._close=!k||k===2&&!!N,c(v)}}}class q2{constructor(){this.map=[]}add(t,n,i){G2(this,t,n,i)}consume(t){if(this.map.sort(function(l,u){return l[0]-u[0]}),this.map.length===0)return;let n=this.map.length;const i=[];for(;n>0;)n-=1,i.push(t.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),t.length=this.map[n][0];i.push(t.slice()),t.length=0;let o=i.pop();for(;o;){for(const l of o)t.push(l);o=i.pop()}this.map.length=0}}function G2(e,t,n,i){let o=0;if(!(n===0&&i.length===0)){for(;o-1;){const Z=i.events[Y][1].type;if(Z==="lineEnding"||Z==="linePrefix")Y--;else break}const J=Y>-1?i.events[Y][1].type:null,de=J==="tableHead"||J==="tableRow"?w:p;return de===w&&i.parser.lazy[i.now().line]?n(M):de(M)}function p(M){return e.enter("tableHead"),e.enter("tableRow"),f(M)}function f(M){return M===124||(u=!0,l+=1),m(M)}function m(M){return M===null?n(M):xe(M)?l>1?(l=0,i.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(M),e.exit("lineEnding"),E):n(M):Fe(M)?Pe(e,m,"whitespace")(M):(l+=1,u&&(u=!1,o+=1),M===124?(e.enter("tableCellDivider"),e.consume(M),e.exit("tableCellDivider"),u=!0,m):(e.enter("data"),h(M)))}function h(M){return M===null||M===124||He(M)?(e.exit("data"),m(M)):(e.consume(M),M===92?S:h)}function S(M){return M===92||M===124?(e.consume(M),h):h(M)}function E(M){return i.interrupt=!1,i.parser.lazy[i.now().line]?n(M):(e.enter("tableDelimiterRow"),u=!1,Fe(M)?Pe(e,v,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(M):v(M))}function v(M){return M===45||M===58?T(M):M===124?(u=!0,e.enter("tableCellDivider"),e.consume(M),e.exit("tableCellDivider"),k):L(M)}function k(M){return Fe(M)?Pe(e,T,"whitespace")(M):T(M)}function T(M){return M===58?(l+=1,u=!0,e.enter("tableDelimiterMarker"),e.consume(M),e.exit("tableDelimiterMarker"),N):M===45?(l+=1,N(M)):M===null||xe(M)?O(M):L(M)}function N(M){return M===45?(e.enter("tableDelimiterFiller"),R(M)):L(M)}function R(M){return M===45?(e.consume(M),R):M===58?(u=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(M),e.exit("tableDelimiterMarker"),A):(e.exit("tableDelimiterFiller"),A(M))}function A(M){return Fe(M)?Pe(e,O,"whitespace")(M):O(M)}function O(M){return M===124?v(M):M===null||xe(M)?!u||o!==l?L(M):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(M)):L(M)}function L(M){return n(M)}function w(M){return e.enter("tableRow"),B(M)}function B(M){return M===124?(e.enter("tableCellDivider"),e.consume(M),e.exit("tableCellDivider"),B):M===null||xe(M)?(e.exit("tableRow"),t(M)):Fe(M)?Pe(e,B,"whitespace")(M):(e.enter("data"),W(M))}function W(M){return M===null||M===124||He(M)?(e.exit("data"),B(M)):(e.consume(M),M===92?j:W)}function j(M){return M===92||M===124?(e.consume(M),W):W(M)}}function Y2(e,t){let n=-1,i=!0,o=0,l=[0,0,0,0],u=[0,0,0,0],c=!1,p=0,f,m,h;const S=new q2;for(;++nn[2]+1){const v=n[2]+1,k=n[3]-n[2]-1;e.add(v,k,[])}}e.add(n[3]+1,0,[["exit",h,t]])}return o!==void 0&&(l.end=Object.assign({},_a(t.events,o)),e.add(o,0,[["exit",l,t]]),l=void 0),l}function hS(e,t,n,i,o){const l=[],u=_a(t.events,n);o&&(o.end=Object.assign({},u),l.push(["exit",o,t])),i.end=Object.assign({},u),l.push(["exit",i,t]),e.add(n+1,0,l)}function _a(e,t){const n=e[t],i=n[0]==="enter"?"start":"end";return n[1][i]}const K2={name:"tasklistCheck",tokenize:X2};function Z2(){return{text:{91:K2}}}function X2(e,t,n){const i=this;return o;function o(p){return i.previous!==null||!i._gfmTasklistFirstContentOfListItem?n(p):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(p),e.exit("taskListCheckMarker"),l)}function l(p){return He(p)?(e.enter("taskListCheckValueUnchecked"),e.consume(p),e.exit("taskListCheckValueUnchecked"),u):p===88||p===120?(e.enter("taskListCheckValueChecked"),e.consume(p),e.exit("taskListCheckValueChecked"),u):n(p)}function u(p){return p===93?(e.enter("taskListCheckMarker"),e.consume(p),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),c):n(p)}function c(p){return xe(p)?t(p):Fe(p)?e.check({tokenize:Q2},t,n)(p):n(p)}}function Q2(e,t,n){return Pe(e,i,"whitespace");function i(o){return o===null?n(o):t(o)}}function J2(e){return Qx([w2(),D2(),$2(e),W2(),Z2()])}const eM={};function tM(e){const t=this,n=e||eM,i=t.data(),o=i.micromarkExtensions||(i.micromarkExtensions=[]),l=i.fromMarkdownExtensions||(i.fromMarkdownExtensions=[]),u=i.toMarkdownExtensions||(i.toMarkdownExtensions=[]);o.push(J2(n)),l.push(S2()),u.push(v2(n))}function nM(e,t){if(e==null)return{};var n={};for(var i in e)if({}.hasOwnProperty.call(e,i)){if(t.indexOf(i)!==-1)continue;n[i]=e[i]}return n}function rM(e,t){if(e==null)return{};var n,i,o=nM(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(i=0;ie.length)&&(t=e.length);for(var n=0,i=Array(t);n=4)return[e[0],e[1],e[2],e[3],"".concat(e[0],".").concat(e[1]),"".concat(e[0],".").concat(e[2]),"".concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[0]),"".concat(e[1],".").concat(e[2]),"".concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[1]),"".concat(e[2],".").concat(e[3]),"".concat(e[3],".").concat(e[0]),"".concat(e[3],".").concat(e[1]),"".concat(e[3],".").concat(e[2]),"".concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[1],".").concat(e[3]),"".concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[2],".").concat(e[3]),"".concat(e[0],".").concat(e[3],".").concat(e[1]),"".concat(e[0],".").concat(e[3],".").concat(e[2]),"".concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[1],".").concat(e[2],".").concat(e[3]),"".concat(e[1],".").concat(e[3],".").concat(e[0]),"".concat(e[1],".").concat(e[3],".").concat(e[2]),"".concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[0],".").concat(e[3]),"".concat(e[2],".").concat(e[1],".").concat(e[0]),"".concat(e[2],".").concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[3],".").concat(e[0]),"".concat(e[2],".").concat(e[3],".").concat(e[1]),"".concat(e[3],".").concat(e[0],".").concat(e[1]),"".concat(e[3],".").concat(e[0],".").concat(e[2]),"".concat(e[3],".").concat(e[1],".").concat(e[0]),"".concat(e[3],".").concat(e[1],".").concat(e[2]),"".concat(e[3],".").concat(e[2],".").concat(e[0]),"".concat(e[3],".").concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[1],".").concat(e[2],".").concat(e[3]),"".concat(e[0],".").concat(e[1],".").concat(e[3],".").concat(e[2]),"".concat(e[0],".").concat(e[2],".").concat(e[1],".").concat(e[3]),"".concat(e[0],".").concat(e[2],".").concat(e[3],".").concat(e[1]),"".concat(e[0],".").concat(e[3],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[3],".").concat(e[2],".").concat(e[1]),"".concat(e[1],".").concat(e[0],".").concat(e[2],".").concat(e[3]),"".concat(e[1],".").concat(e[0],".").concat(e[3],".").concat(e[2]),"".concat(e[1],".").concat(e[2],".").concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[2],".").concat(e[3],".").concat(e[0]),"".concat(e[1],".").concat(e[3],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[3],".").concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[0],".").concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[0],".").concat(e[3],".").concat(e[1]),"".concat(e[2],".").concat(e[1],".").concat(e[0],".").concat(e[3]),"".concat(e[2],".").concat(e[1],".").concat(e[3],".").concat(e[0]),"".concat(e[2],".").concat(e[3],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[3],".").concat(e[1],".").concat(e[0]),"".concat(e[3],".").concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[3],".").concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[3],".").concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[3],".").concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[3],".").concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[3],".").concat(e[2],".").concat(e[1],".").concat(e[0])]}var Iu={};function dM(e){if(e.length===0||e.length===1)return e;var t=e.join(".");return Iu[t]||(Iu[t]=cM(e)),Iu[t]}function pM(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,i=e.filter(function(l){return l!=="token"}),o=dM(i);return o.reduce(function(l,u){return wa(wa({},l),n[u])},t)}function yS(e){return e.join(" ")}function fM(e,t){var n=0;return function(i){return n+=1,i.map(function(o,l){return qA({node:o,stylesheet:e,useInlineStyles:t,key:"code-segment-".concat(n,"-").concat(l)})})}}function qA(e){var t=e.node,n=e.stylesheet,i=e.style,o=i===void 0?{}:i,l=e.useInlineStyles,u=e.key,c=t.properties,p=t.type,f=t.tagName,m=t.value;if(p==="text")return m;if(f){var h=fM(n,l),S;if(!l)S=wa(wa({},c),{},{className:yS(c.className)});else{var E=Object.keys(n).reduce(function(N,R){return R.split(".").forEach(function(A){N.includes(A)||N.push(A)}),N},[]),v=c.className&&c.className.includes("token")?["token"]:[],k=c.className&&v.concat(c.className.filter(function(N){return!E.includes(N)}));S=wa(wa({},c),{},{className:yS(k)||void 0,style:pM(c.className,Object.assign({},c.style,o),n)})}var T=h(t.children);return ct.createElement(f,Fm({key:u},S),T)}}const gM=(function(e,t){var n=e.listLanguages();return n.indexOf(t)!==-1});var mM=["language","children","style","customStyle","codeTagProps","useInlineStyles","showLineNumbers","showInlineLineNumbers","startingLineNumber","lineNumberContainerStyle","lineNumberStyle","wrapLines","wrapLongLines","lineProps","renderer","PreTag","CodeTag","code","astGenerator"];function ES(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,i)}return n}function Tr(e){for(var t=1;t1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],i=0;i2&&arguments[2]!==void 0?arguments[2]:[];return rs({children:L,lineNumber:w,lineNumberStyle:c,largestLineNumber:u,showInlineLineNumbers:o,lineProps:n,className:B,showLineNumbers:i,wrapLongLines:p,wrapLines:t})}function k(L,w){if(i&&w&&o){var B=HA(c,w,u);L.unshift(GA(w,B))}return L}function T(L,w){var B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];return t||B.length>0?v(L,w,B):k(L,w)}for(var N=function(){var w=m[E],B=w.children[0].value,W=bM(B);if(W){var j=B.split(`
+`))}function p(E,v,k,T){const N=k.enter("tableCell"),R=k.enter("phrasing"),A=k.containerPhrasing(E,{...T,before:l,after:l});return R(),N(),A}function f(E,v){return CD(E,{align:v,alignDelimiters:i,padding:n,stringLength:o})}function m(E,v,k){const T=E.children;let N=-1;const R=[],A=v.enter("table");for(;++N0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const D2={tokenize:$2,partial:!0};function M2(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:B2,continuation:{tokenize:j2},exit:z2}},text:{91:{name:"gfmFootnoteCall",tokenize:U2},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:F2,resolveTo:P2}}}}function F2(e,t,n){const i=this;let o=i.events.length;const l=i.parser.gfmFootnotes||(i.parser.gfmFootnotes=[]);let u;for(;o--;){const p=i.events[o][1];if(p.type==="labelImage"){u=p;break}if(p.type==="gfmFootnoteCall"||p.type==="labelLink"||p.type==="label"||p.type==="image"||p.type==="link")break}return c;function c(p){if(!u||!u._balanced)return n(p);const f=On(i.sliceSerialize({start:u.end,end:i.now()}));return f.codePointAt(0)!==94||!l.includes(f.slice(1))?n(p):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(p),e.exit("gfmFootnoteCallLabelMarker"),t(p))}}function P2(e,t){let n=e.length;for(;n--;)if(e[n][1].type==="labelImage"&&e[n][0]==="enter"){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const i={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},o={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};o.end.column++,o.end.offset++,o.end._bufferIndex++;const l={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},u={type:"chunkString",contentType:"string",start:Object.assign({},l.start),end:Object.assign({},l.end)},c=[e[n+1],e[n+2],["enter",i,t],e[n+3],e[n+4],["enter",o,t],["exit",o,t],["enter",l,t],["enter",u,t],["exit",u,t],["exit",l,t],e[e.length-2],e[e.length-1],["exit",i,t]];return e.splice(n,e.length-n+1,...c),e}function U2(e,t,n){const i=this,o=i.parser.gfmFootnotes||(i.parser.gfmFootnotes=[]);let l=0,u;return c;function c(h){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(h),e.exit("gfmFootnoteCallLabelMarker"),p}function p(h){return h!==94?n(h):(e.enter("gfmFootnoteCallMarker"),e.consume(h),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",f)}function f(h){if(l>999||h===93&&!u||h===null||h===91||He(h))return n(h);if(h===93){e.exit("chunkString");const S=e.exit("gfmFootnoteCallString");return o.includes(On(i.sliceSerialize(S)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(h),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(h)}return He(h)||(u=!0),l++,e.consume(h),h===92?m:f}function m(h){return h===91||h===92||h===93?(e.consume(h),l++,f):f(h)}}function B2(e,t,n){const i=this,o=i.parser.gfmFootnotes||(i.parser.gfmFootnotes=[]);let l,u=0,c;return p;function p(v){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(v),e.exit("gfmFootnoteDefinitionLabelMarker"),f}function f(v){return v===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(v),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",m):n(v)}function m(v){if(u>999||v===93&&!c||v===null||v===91||He(v))return n(v);if(v===93){e.exit("chunkString");const k=e.exit("gfmFootnoteDefinitionLabelString");return l=On(i.sliceSerialize(k)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(v),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),S}return He(v)||(c=!0),u++,e.consume(v),v===92?h:m}function h(v){return v===91||v===92||v===93?(e.consume(v),u++,m):m(v)}function S(v){return v===58?(e.enter("definitionMarker"),e.consume(v),e.exit("definitionMarker"),o.includes(l)||o.push(l),Pe(e,E,"gfmFootnoteDefinitionWhitespace")):n(v)}function E(v){return t(v)}}function j2(e,t,n){return e.check(Ii,t,e.attempt(D2,t,n))}function z2(e){e.exit("gfmFootnoteDefinition")}function $2(e,t,n){const i=this;return Pe(e,o,"gfmFootnoteDefinitionIndent",5);function o(l){const u=i.events[i.events.length-1];return u&&u[1].type==="gfmFootnoteDefinitionIndent"&&u[2].sliceSerialize(u[1],!0).length===4?t(l):n(l)}}function q2(e){let n=(e||{}).singleTilde;const i={name:"strikethrough",tokenize:l,resolveAll:o};return n==null&&(n=!0),{text:{126:i},insideSpan:{null:[i]},attentionMarkers:{null:[126]}};function o(u,c){let p=-1;for(;++p1?p(v):(u.consume(v),h++,E);if(h<2&&!n)return p(v);const T=u.exit("strikethroughSequenceTemporary"),N=Ra(v);return T._open=!N||N===2&&!!k,T._close=!k||k===2&&!!N,c(v)}}}class G2{constructor(){this.map=[]}add(t,n,i){H2(this,t,n,i)}consume(t){if(this.map.sort(function(l,u){return l[0]-u[0]}),this.map.length===0)return;let n=this.map.length;const i=[];for(;n>0;)n-=1,i.push(t.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),t.length=this.map[n][0];i.push(t.slice()),t.length=0;let o=i.pop();for(;o;){for(const l of o)t.push(l);o=i.pop()}this.map.length=0}}function H2(e,t,n,i){let o=0;if(!(n===0&&i.length===0)){for(;o-1;){const Z=i.events[Y][1].type;if(Z==="lineEnding"||Z==="linePrefix")Y--;else break}const J=Y>-1?i.events[Y][1].type:null,de=J==="tableHead"||J==="tableRow"?w:p;return de===w&&i.parser.lazy[i.now().line]?n(M):de(M)}function p(M){return e.enter("tableHead"),e.enter("tableRow"),f(M)}function f(M){return M===124||(u=!0,l+=1),m(M)}function m(M){return M===null?n(M):xe(M)?l>1?(l=0,i.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(M),e.exit("lineEnding"),E):n(M):Fe(M)?Pe(e,m,"whitespace")(M):(l+=1,u&&(u=!1,o+=1),M===124?(e.enter("tableCellDivider"),e.consume(M),e.exit("tableCellDivider"),u=!0,m):(e.enter("data"),h(M)))}function h(M){return M===null||M===124||He(M)?(e.exit("data"),m(M)):(e.consume(M),M===92?S:h)}function S(M){return M===92||M===124?(e.consume(M),h):h(M)}function E(M){return i.interrupt=!1,i.parser.lazy[i.now().line]?n(M):(e.enter("tableDelimiterRow"),u=!1,Fe(M)?Pe(e,v,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(M):v(M))}function v(M){return M===45||M===58?T(M):M===124?(u=!0,e.enter("tableCellDivider"),e.consume(M),e.exit("tableCellDivider"),k):L(M)}function k(M){return Fe(M)?Pe(e,T,"whitespace")(M):T(M)}function T(M){return M===58?(l+=1,u=!0,e.enter("tableDelimiterMarker"),e.consume(M),e.exit("tableDelimiterMarker"),N):M===45?(l+=1,N(M)):M===null||xe(M)?O(M):L(M)}function N(M){return M===45?(e.enter("tableDelimiterFiller"),R(M)):L(M)}function R(M){return M===45?(e.consume(M),R):M===58?(u=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(M),e.exit("tableDelimiterMarker"),A):(e.exit("tableDelimiterFiller"),A(M))}function A(M){return Fe(M)?Pe(e,O,"whitespace")(M):O(M)}function O(M){return M===124?v(M):M===null||xe(M)?!u||o!==l?L(M):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(M)):L(M)}function L(M){return n(M)}function w(M){return e.enter("tableRow"),B(M)}function B(M){return M===124?(e.enter("tableCellDivider"),e.consume(M),e.exit("tableCellDivider"),B):M===null||xe(M)?(e.exit("tableRow"),t(M)):Fe(M)?Pe(e,B,"whitespace")(M):(e.enter("data"),W(M))}function W(M){return M===null||M===124||He(M)?(e.exit("data"),B(M)):(e.consume(M),M===92?j:W)}function j(M){return M===92||M===124?(e.consume(M),W):W(M)}}function K2(e,t){let n=-1,i=!0,o=0,l=[0,0,0,0],u=[0,0,0,0],c=!1,p=0,f,m,h;const S=new G2;for(;++nn[2]+1){const v=n[2]+1,k=n[3]-n[2]-1;e.add(v,k,[])}}e.add(n[3]+1,0,[["exit",h,t]])}return o!==void 0&&(l.end=Object.assign({},_a(t.events,o)),e.add(o,0,[["exit",l,t]]),l=void 0),l}function hS(e,t,n,i,o){const l=[],u=_a(t.events,n);o&&(o.end=Object.assign({},u),l.push(["exit",o,t])),i.end=Object.assign({},u),l.push(["exit",i,t]),e.add(n+1,0,l)}function _a(e,t){const n=e[t],i=n[0]==="enter"?"start":"end";return n[1][i]}const Z2={name:"tasklistCheck",tokenize:Q2};function X2(){return{text:{91:Z2}}}function Q2(e,t,n){const i=this;return o;function o(p){return i.previous!==null||!i._gfmTasklistFirstContentOfListItem?n(p):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(p),e.exit("taskListCheckMarker"),l)}function l(p){return He(p)?(e.enter("taskListCheckValueUnchecked"),e.consume(p),e.exit("taskListCheckValueUnchecked"),u):p===88||p===120?(e.enter("taskListCheckValueChecked"),e.consume(p),e.exit("taskListCheckValueChecked"),u):n(p)}function u(p){return p===93?(e.enter("taskListCheckMarker"),e.consume(p),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),c):n(p)}function c(p){return xe(p)?t(p):Fe(p)?e.check({tokenize:J2},t,n)(p):n(p)}}function J2(e,t,n){return Pe(e,i,"whitespace");function i(o){return o===null?n(o):t(o)}}function eM(e){return Qx([T2(),M2(),q2(e),V2(),X2()])}const tM={};function nM(e){const t=this,n=e||tM,i=t.data(),o=i.micromarkExtensions||(i.micromarkExtensions=[]),l=i.fromMarkdownExtensions||(i.fromMarkdownExtensions=[]),u=i.toMarkdownExtensions||(i.toMarkdownExtensions=[]);o.push(eM(n)),l.push(v2()),u.push(k2(n))}function rM(e,t){if(e==null)return{};var n={};for(var i in e)if({}.hasOwnProperty.call(e,i)){if(t.indexOf(i)!==-1)continue;n[i]=e[i]}return n}function aM(e,t){if(e==null)return{};var n,i,o=rM(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(i=0;ie.length)&&(t=e.length);for(var n=0,i=Array(t);n=4)return[e[0],e[1],e[2],e[3],"".concat(e[0],".").concat(e[1]),"".concat(e[0],".").concat(e[2]),"".concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[0]),"".concat(e[1],".").concat(e[2]),"".concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[1]),"".concat(e[2],".").concat(e[3]),"".concat(e[3],".").concat(e[0]),"".concat(e[3],".").concat(e[1]),"".concat(e[3],".").concat(e[2]),"".concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[1],".").concat(e[3]),"".concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[2],".").concat(e[3]),"".concat(e[0],".").concat(e[3],".").concat(e[1]),"".concat(e[0],".").concat(e[3],".").concat(e[2]),"".concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[1],".").concat(e[2],".").concat(e[3]),"".concat(e[1],".").concat(e[3],".").concat(e[0]),"".concat(e[1],".").concat(e[3],".").concat(e[2]),"".concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[0],".").concat(e[3]),"".concat(e[2],".").concat(e[1],".").concat(e[0]),"".concat(e[2],".").concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[3],".").concat(e[0]),"".concat(e[2],".").concat(e[3],".").concat(e[1]),"".concat(e[3],".").concat(e[0],".").concat(e[1]),"".concat(e[3],".").concat(e[0],".").concat(e[2]),"".concat(e[3],".").concat(e[1],".").concat(e[0]),"".concat(e[3],".").concat(e[1],".").concat(e[2]),"".concat(e[3],".").concat(e[2],".").concat(e[0]),"".concat(e[3],".").concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[1],".").concat(e[2],".").concat(e[3]),"".concat(e[0],".").concat(e[1],".").concat(e[3],".").concat(e[2]),"".concat(e[0],".").concat(e[2],".").concat(e[1],".").concat(e[3]),"".concat(e[0],".").concat(e[2],".").concat(e[3],".").concat(e[1]),"".concat(e[0],".").concat(e[3],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[3],".").concat(e[2],".").concat(e[1]),"".concat(e[1],".").concat(e[0],".").concat(e[2],".").concat(e[3]),"".concat(e[1],".").concat(e[0],".").concat(e[3],".").concat(e[2]),"".concat(e[1],".").concat(e[2],".").concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[2],".").concat(e[3],".").concat(e[0]),"".concat(e[1],".").concat(e[3],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[3],".").concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[0],".").concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[0],".").concat(e[3],".").concat(e[1]),"".concat(e[2],".").concat(e[1],".").concat(e[0],".").concat(e[3]),"".concat(e[2],".").concat(e[1],".").concat(e[3],".").concat(e[0]),"".concat(e[2],".").concat(e[3],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[3],".").concat(e[1],".").concat(e[0]),"".concat(e[3],".").concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[3],".").concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[3],".").concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[3],".").concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[3],".").concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[3],".").concat(e[2],".").concat(e[1],".").concat(e[0])]}var Iu={};function pM(e){if(e.length===0||e.length===1)return e;var t=e.join(".");return Iu[t]||(Iu[t]=dM(e)),Iu[t]}function fM(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,i=e.filter(function(l){return l!=="token"}),o=pM(i);return o.reduce(function(l,u){return wa(wa({},l),n[u])},t)}function yS(e){return e.join(" ")}function gM(e,t){var n=0;return function(i){return n+=1,i.map(function(o,l){return qA({node:o,stylesheet:e,useInlineStyles:t,key:"code-segment-".concat(n,"-").concat(l)})})}}function qA(e){var t=e.node,n=e.stylesheet,i=e.style,o=i===void 0?{}:i,l=e.useInlineStyles,u=e.key,c=t.properties,p=t.type,f=t.tagName,m=t.value;if(p==="text")return m;if(f){var h=gM(n,l),S;if(!l)S=wa(wa({},c),{},{className:yS(c.className)});else{var E=Object.keys(n).reduce(function(N,R){return R.split(".").forEach(function(A){N.includes(A)||N.push(A)}),N},[]),v=c.className&&c.className.includes("token")?["token"]:[],k=c.className&&v.concat(c.className.filter(function(N){return!E.includes(N)}));S=wa(wa({},c),{},{className:yS(k)||void 0,style:fM(c.className,Object.assign({},c.style,o),n)})}var T=h(t.children);return ct.createElement(f,Fm({key:u},S),T)}}const mM=(function(e,t){var n=e.listLanguages();return n.indexOf(t)!==-1});var hM=["language","children","style","customStyle","codeTagProps","useInlineStyles","showLineNumbers","showInlineLineNumbers","startingLineNumber","lineNumberContainerStyle","lineNumberStyle","wrapLines","wrapLongLines","lineProps","renderer","PreTag","CodeTag","code","astGenerator"];function ES(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,i)}return n}function Tr(e){for(var t=1;t1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],i=0;i2&&arguments[2]!==void 0?arguments[2]:[];return rs({children:L,lineNumber:w,lineNumberStyle:c,largestLineNumber:u,showInlineLineNumbers:o,lineProps:n,className:B,showLineNumbers:i,wrapLongLines:p,wrapLines:t})}function k(L,w){if(i&&w&&o){var B=HA(c,w,u);L.unshift(GA(w,B))}return L}function T(L,w){var B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];return t||B.length>0?v(L,w,B):k(L,w)}for(var N=function(){var w=m[E],B=w.children[0].value,W=yM(B);if(W){var j=B.split(`
`);j.forEach(function(M,Y){var J=i&&h.length+l,de={type:"text",value:"".concat(M,`
-`)};if(Y===0){var Z=m.slice(S+1,E).concat(rs({children:[de],className:w.properties.className})),H=T(Z,J);h.push(H)}else if(Y===j.length-1){var te=m[E+1]&&m[E+1].children&&m[E+1].children[0],ue={type:"text",value:"".concat(M)};if(te){var q=rs({children:[ue],className:w.properties.className});m.splice(E+1,0,q)}else{var Q=[ue],x=T(Q,J,w.properties.className);h.push(x)}}else{var D=[de],$=T(D,J,w.properties.className);h.push($)}}),S=E}E++};E4&&v.slice(0,4)===i&&o.test(E)&&(E.charAt(4)==="-"?k=p(E):E=f(E),T=t),new T(k,E))}function p(S){var E=S.slice(5).replace(l,h);return i+E.charAt(0).toUpperCase()+E.slice(1)}function f(S){var E=S.slice(4);return l.test(E)?S:(E=E.replace(u,m),E.charAt(0)!=="-"&&(E="-"+E),i+E)}function m(S){return"-"+S.toLowerCase()}function h(S){return S.charAt(1).toUpperCase()}return Vu}var Yu,PS;function FM(){if(PS)return Yu;PS=1,Yu=t;var e=/[#.]/g;function t(n,i){for(var o=n||"",l=i||"div",u={},c=0,p,f,m;c",aF="Í",iF="Î",oF="Ì",sF="Ï",lF="<",uF="Ñ",cF="Ó",dF="Ô",pF="Ò",fF="Ø",gF="Õ",mF="Ö",hF='"',bF="®",yF="Þ",EF="Ú",SF="Û",vF="Ù",kF="Ü",_F="Ý",wF="á",TF="â",xF="´",AF="æ",RF="à",NF="&",CF="å",IF="ã",OF="ä",LF="¦",DF="ç",MF="¸",FF="¢",PF="©",UF="¤",BF="°",jF="÷",zF="é",$F="ê",qF="è",GF="ð",HF="ë",WF="½",VF="¼",YF="¾",KF=">",ZF="í",XF="î",QF="¡",JF="ì",eP="¿",tP="ï",nP="«",rP="<",aP="¯",iP="µ",oP="·",sP=" ",lP="¬",uP="ñ",cP="ó",dP="ô",pP="ò",fP="ª",gP="º",mP="ø",hP="õ",bP="ö",yP="¶",EP="±",SP="£",vP='"',kP="»",_P="®",wP="§",TP="",xP="¹",AP="²",RP="³",NP="ß",CP="þ",IP="×",OP="ú",LP="û",DP="ù",MP="¨",FP="ü",PP="ý",UP="¥",BP="ÿ",jP={AElig:$M,AMP:qM,Aacute:GM,Acirc:HM,Agrave:WM,Aring:VM,Atilde:YM,Auml:KM,COPY:ZM,Ccedil:XM,ETH:QM,Eacute:JM,Ecirc:eF,Egrave:tF,Euml:nF,GT:rF,Iacute:aF,Icirc:iF,Igrave:oF,Iuml:sF,LT:lF,Ntilde:uF,Oacute:cF,Ocirc:dF,Ograve:pF,Oslash:fF,Otilde:gF,Ouml:mF,QUOT:hF,REG:bF,THORN:yF,Uacute:EF,Ucirc:SF,Ugrave:vF,Uuml:kF,Yacute:_F,aacute:wF,acirc:TF,acute:xF,aelig:AF,agrave:RF,amp:NF,aring:CF,atilde:IF,auml:OF,brvbar:LF,ccedil:DF,cedil:MF,cent:FF,copy:PF,curren:UF,deg:BF,divide:jF,eacute:zF,ecirc:$F,egrave:qF,eth:GF,euml:HF,frac12:WF,frac14:VF,frac34:YF,gt:KF,iacute:ZF,icirc:XF,iexcl:QF,igrave:JF,iquest:eP,iuml:tP,laquo:nP,lt:rP,macr:aP,micro:iP,middot:oP,nbsp:sP,not:lP,ntilde:uP,oacute:cP,ocirc:dP,ograve:pP,ordf:fP,ordm:gP,oslash:mP,otilde:hP,ouml:bP,para:yP,plusmn:EP,pound:SP,quot:vP,raquo:kP,reg:_P,sect:wP,shy:TP,sup1:xP,sup2:AP,sup3:RP,szlig:NP,thorn:CP,times:IP,uacute:OP,ucirc:LP,ugrave:DP,uml:MP,uuml:FP,yacute:PP,yen:UP,yuml:BP},zP={0:"�",128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"};var Qu,qS;function QA(){if(qS)return Qu;qS=1,Qu=e;function e(t){var n=typeof t=="string"?t.charCodeAt(0):t;return n>=48&&n<=57}return Qu}var Ju,GS;function $P(){if(GS)return Ju;GS=1,Ju=e;function e(t){var n=typeof t=="string"?t.charCodeAt(0):t;return n>=97&&n<=102||n>=65&&n<=70||n>=48&&n<=57}return Ju}var ec,HS;function qP(){if(HS)return ec;HS=1,ec=e;function e(t){var n=typeof t=="string"?t.charCodeAt(0):t;return n>=97&&n<=122||n>=65&&n<=90}return ec}var tc,WS;function GP(){if(WS)return tc;WS=1;var e=qP(),t=QA();tc=n;function n(i){return e(i)||t(i)}return tc}var nc,VS;function HP(){if(VS)return nc;VS=1;var e,t=59;nc=n;function n(i){var o="&"+i+";",l;return e=e||document.createElement("i"),e.innerHTML=o,l=e.textContent,l.charCodeAt(l.length-1)===t&&i!=="semi"||l===o?!1:l}return nc}var rc,YS;function WP(){if(YS)return rc;YS=1;var e=jP,t=zP,n=QA(),i=$P(),o=GP(),l=HP();rc=Q;var u={}.hasOwnProperty,c=String.fromCharCode,p=Function.prototype,f={warning:null,reference:null,text:null,warningContext:null,referenceContext:null,textContext:null,position:{},additional:null,attribute:!1,nonTerminated:!0},m=9,h=10,S=12,E=32,v=38,k=59,T=60,N=61,R=35,A=88,O=120,L=65533,w="named",B="hexadecimal",W="decimal",j={};j[B]=16,j[W]=10;var M={};M[w]=o,M[W]=n,M[B]=i;var Y=1,J=2,de=3,Z=4,H=5,te=6,ue=7,q={};q[Y]="Named character references must be terminated by a semicolon",q[J]="Numeric character references must be terminated by a semicolon",q[de]="Named character references cannot be empty",q[Z]="Numeric character references cannot be empty",q[H]="Named character references must be known",q[te]="Numeric character references cannot be disallowed",q[ue]="Numeric character references cannot be outside the permissible Unicode range";function Q(C,ae){var pe={},fe,Se;ae||(ae={});for(Se in f)fe=ae[Se],pe[Se]=fe??f[Se];return(pe.position.indent||pe.position.start)&&(pe.indent=pe.position.indent||[],pe.position=pe.position.start),x(C,pe)}function x(C,ae){var pe=ae.additional,fe=ae.nonTerminated,Se=ae.text,ke=ae.reference,X=ae.warning,he=ae.textContext,Ie=ae.referenceContext,Qe=ae.warningContext,Ce=ae.position,$e=ae.indent||[],pt=C.length,tt=0,Wt=-1,Ct=Ce.column||1,kn=Ce.line||1,kt="",It=[],Mt,ft,_t,bt,K,ee,ge,_e,Ne,We,nt,yt,xt,rt,Ke,gt,st,Ft,Je;for(typeof pe=="string"&&(pe=pe.charCodeAt(0)),gt=Vt(),_e=X?_n:p,tt--,pt++;++tt65535&&(ee-=65536,We+=c(ee>>>10|55296),ee=56320|ee&1023),ee=We+c(ee))):rt!==w&&_e(Z,Ft)),ee?($n(),gt=Vt(),tt=Je-1,Ct+=Je-xt+1,It.push(ee),st=Vt(),st.offset++,ke&&ke.call(Ie,ee,{start:gt,end:st},C.slice(xt-1,Je)),gt=st):(bt=C.slice(xt-1,Je),kt+=bt,Ct+=bt.length,tt=Je-1)}else K===10&&(kn++,Wt++,Ct=0),K===K?(kt+=c(K),Ct++):$n();return It.join("");function Vt(){return{line:kn,column:Ct,offset:tt+(Ce.offset||0)}}function _n(Ar,Rr){var rr=Vt();rr.column+=Rr,rr.offset+=Rr,X.call(Qe,q[Ar],rr,Ar)}function $n(){kt&&(It.push(kt),Se&&Se.call(he,kt,{start:gt,end:Vt()}),kt="")}}function D(C){return C>=55296&&C<=57343||C>1114111}function $(C){return C>=1&&C<=8||C===11||C>=13&&C<=31||C>=127&&C<=159||C>=64976&&C<=65007||(C&65535)===65535||(C&65535)===65534}return rc}var ac={exports:{}},KS;function VP(){return KS||(KS=1,(function(e){var t=typeof window<"u"?window:typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope?self:{};var n=(function(i){var o=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,l=0,u={},c={manual:i.Prism&&i.Prism.manual,disableWorkerMessageHandler:i.Prism&&i.Prism.disableWorkerMessageHandler,util:{encode:function R(A){return A instanceof p?new p(A.type,R(A.content),A.alias):Array.isArray(A)?A.map(R):A.replace(/&/g,"&").replace(/"u")return null;if("currentScript"in document)return document.currentScript;try{throw new Error}catch(L){var R=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(L.stack)||[])[1];if(R){var A=document.getElementsByTagName("script");for(var O in A)if(A[O].src==R)return A[O]}return null}},isActive:function(R,A,O){for(var L="no-"+A;R;){var w=R.classList;if(w.contains(A))return!0;if(w.contains(L))return!1;R=R.parentElement}return!!O}},languages:{plain:u,plaintext:u,text:u,txt:u,extend:function(R,A){var O=c.util.clone(c.languages[R]);for(var L in A)O[L]=A[L];return O},insertBefore:function(R,A,O,L){L=L||c.languages;var w=L[R],B={};for(var W in w)if(w.hasOwnProperty(W)){if(W==A)for(var j in O)O.hasOwnProperty(j)&&(B[j]=O[j]);O.hasOwnProperty(W)||(B[W]=w[W])}var M=L[R];return L[R]=B,c.languages.DFS(c.languages,function(Y,J){J===M&&Y!=R&&(this[Y]=B)}),B},DFS:function R(A,O,L,w){w=w||{};var B=c.util.objId;for(var W in A)if(A.hasOwnProperty(W)){O.call(A,W,A[W],L||W);var j=A[W],M=c.util.type(j);M==="Object"&&!w[B(j)]?(w[B(j)]=!0,R(j,O,null,w)):M==="Array"&&!w[B(j)]&&(w[B(j)]=!0,R(j,O,W,w))}}},plugins:{},highlightAll:function(R,A){c.highlightAllUnder(document,R,A)},highlightAllUnder:function(R,A,O){var L={callback:O,container:R,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};c.hooks.run("before-highlightall",L),L.elements=Array.prototype.slice.apply(L.container.querySelectorAll(L.selector)),c.hooks.run("before-all-elements-highlight",L);for(var w=0,B;B=L.elements[w++];)c.highlightElement(B,A===!0,L.callback)},highlightElement:function(R,A,O){var L=c.util.getLanguage(R),w=c.languages[L];c.util.setLanguage(R,L);var B=R.parentElement;B&&B.nodeName.toLowerCase()==="pre"&&c.util.setLanguage(B,L);var W=R.textContent,j={element:R,language:L,grammar:w,code:W};function M(J){j.highlightedCode=J,c.hooks.run("before-insert",j),j.element.innerHTML=j.highlightedCode,c.hooks.run("after-highlight",j),c.hooks.run("complete",j),O&&O.call(j.element)}if(c.hooks.run("before-sanity-check",j),B=j.element.parentElement,B&&B.nodeName.toLowerCase()==="pre"&&!B.hasAttribute("tabindex")&&B.setAttribute("tabindex","0"),!j.code){c.hooks.run("complete",j),O&&O.call(j.element);return}if(c.hooks.run("before-highlight",j),!j.grammar){M(c.util.encode(j.code));return}if(A&&i.Worker){var Y=new Worker(c.filename);Y.onmessage=function(J){M(J.data)},Y.postMessage(JSON.stringify({language:j.language,code:j.code,immediateClose:!0}))}else M(c.highlight(j.code,j.grammar,j.language))},highlight:function(R,A,O){var L={code:R,grammar:A,language:O};if(c.hooks.run("before-tokenize",L),!L.grammar)throw new Error('The language "'+L.language+'" has no grammar.');return L.tokens=c.tokenize(L.code,L.grammar),c.hooks.run("after-tokenize",L),p.stringify(c.util.encode(L.tokens),L.language)},tokenize:function(R,A){var O=A.rest;if(O){for(var L in O)A[L]=O[L];delete A.rest}var w=new h;return S(w,w.head,R),m(R,w,A,w.head,0),v(w)},hooks:{all:{},add:function(R,A){var O=c.hooks.all;O[R]=O[R]||[],O[R].push(A)},run:function(R,A){var O=c.hooks.all[R];if(!(!O||!O.length))for(var L=0,w;w=O[L++];)w(A)}},Token:p};i.Prism=c;function p(R,A,O,L){this.type=R,this.content=A,this.alias=O,this.length=(L||"").length|0}p.stringify=function R(A,O){if(typeof A=="string")return A;if(Array.isArray(A)){var L="";return A.forEach(function(M){L+=R(M,O)}),L}var w={type:A.type,content:R(A.content,O),tag:"span",classes:["token",A.type],attributes:{},language:O},B=A.alias;B&&(Array.isArray(B)?Array.prototype.push.apply(w.classes,B):w.classes.push(B)),c.hooks.run("wrap",w);var W="";for(var j in w.attributes)W+=" "+j+'="'+(w.attributes[j]||"").replace(/"/g,""")+'"';return"<"+w.tag+' class="'+w.classes.join(" ")+'"'+W+">"+w.content+""+w.tag+">"};function f(R,A,O,L){R.lastIndex=A;var w=R.exec(O);if(w&&L&&w[1]){var B=w[1].length;w.index+=B,w[0]=w[0].slice(B)}return w}function m(R,A,O,L,w,B){for(var W in O)if(!(!O.hasOwnProperty(W)||!O[W])){var j=O[W];j=Array.isArray(j)?j:[j];for(var M=0;M=B.reach);Q+=q.value.length,q=q.next){var x=q.value;if(A.length>R.length)return;if(!(x instanceof p)){var D=1,$;if(Z){if($=f(ue,Q,R,de),!$||$.index>=R.length)break;var fe=$.index,C=$.index+$[0].length,ae=Q;for(ae+=q.value.length;fe>=ae;)q=q.next,ae+=q.value.length;if(ae-=q.value.length,Q=ae,q.value instanceof p)continue;for(var pe=q;pe!==A.tail&&(aeB.reach&&(B.reach=he);var Ie=q.prev;ke&&(Ie=S(A,Ie,ke),Q+=ke.length),E(A,Ie,D);var Qe=new p(W,J?c.tokenize(Se,J):Se,H,Se);if(q=S(A,Ie,Qe),X&&S(A,q,X),D>1){var Ce={cause:W+","+M,reach:he};m(R,A,O,q.prev,Q,Ce),B&&Ce.reach>B.reach&&(B.reach=Ce.reach)}}}}}}function h(){var R={value:null,prev:null,next:null},A={value:null,prev:R,next:null};R.next=A,this.head=R,this.tail=A,this.length=0}function S(R,A,O){var L=A.next,w={value:O,prev:A,next:L};return A.next=w,L.prev=w,R.length++,w}function E(R,A,O){for(var L=A.next,w=0;w/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern://i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/?[\da-f]{1,8};/i]},t.languages.markup.tag.inside["attr-value"].inside.entity=t.languages.markup.entity,t.languages.markup.doctype.inside["internal-subset"].inside=t.languages.markup,t.hooks.add("wrap",function(n){n.type==="entity"&&(n.attributes.title=n.content.value.replace(/&/,"&"))}),Object.defineProperty(t.languages.markup.tag,"addInlined",{value:function(i,o){var l={};l["language-"+o]={pattern:/(^$)/i,lookbehind:!0,inside:t.languages[o]},l.cdata=/^$/i;var u={"included-cdata":{pattern://i,inside:l}};u["language-"+o]={pattern:/[\s\S]+/,inside:t.languages[o]};var c={};c[i]={pattern:RegExp(/(<__[^>]*>)(?:))*\]\]>|(?!)/.source.replace(/__/g,function(){return i}),"i"),lookbehind:!0,greedy:!0,inside:u},t.languages.insertBefore("markup","cdata",c)}}),Object.defineProperty(t.languages.markup.tag,"addAttribute",{value:function(n,i){t.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+n+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[i,"language-"+i],inside:t.languages[i]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),t.languages.html=t.languages.markup,t.languages.mathml=t.languages.markup,t.languages.svg=t.languages.markup,t.languages.xml=t.languages.extend("markup",{}),t.languages.ssml=t.languages.xml,t.languages.atom=t.languages.xml,t.languages.rss=t.languages.xml}return ic}var oc,XS;function KP(){if(XS)return oc;XS=1,oc=e,e.displayName="css",e.aliases=[];function e(t){(function(n){var i=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;n.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:/@[\w-](?:[^;{\s]|\s+(?![\s{]))*(?:;|(?=\s*\{))/,inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+i.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+i.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+i.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:i,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},n.languages.css.atrule.inside.rest=n.languages.css;var o=n.languages.markup;o&&(o.tag.addInlined("style","css"),o.tag.addAttribute("style","css"))})(t)}return oc}var sc,QS;function ZP(){if(QS)return sc;QS=1,sc=e,e.displayName="clike",e.aliases=[];function e(t){t.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/}}return sc}var lc,JS;function XP(){if(JS)return lc;JS=1,lc=e,e.displayName="javascript",e.aliases=["js"];function e(t){t.languages.javascript=t.languages.extend("clike",{"class-name":[t.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),t.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,t.languages.insertBefore("javascript","keyword",{regex:{pattern:/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)\/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/,lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:t.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:t.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:t.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:t.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:t.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),t.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:t.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),t.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),t.languages.markup&&(t.languages.markup.tag.addInlined("script","javascript"),t.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),t.languages.js=t.languages.javascript}return lc}var uc,ev;function QP(){if(ev)return uc;ev=1;var e=typeof globalThis=="object"?globalThis:typeof self=="object"?self:typeof window=="object"?window:typeof is=="object"?is:{},t=L();e.Prism={manual:!0,disableWorkerMessageHandler:!0};var n=zM(),i=WP(),o=VP(),l=YP(),u=KP(),c=ZP(),p=XP();t();var f={}.hasOwnProperty;function m(){}m.prototype=o;var h=new m;uc=h,h.highlight=v,h.register=S,h.alias=E,h.registered=k,h.listLanguages=T,S(l),S(u),S(c),S(p),h.util.encode=A,h.Token.stringify=N;function S(w){if(typeof w!="function"||!w.displayName)throw new Error("Expected `function` for `grammar`, got `"+w+"`");h.languages[w.displayName]===void 0&&w(h)}function E(w,B){var W=h.languages,j=w,M,Y,J,de;B&&(j={},j[w]=B);for(M in j)for(Y=j[M],Y=typeof Y=="string"?[Y]:Y,J=Y.length,de=-1;++de code[class*="language-"]':{background:"#f5f2f0",padding:".1em",borderRadius:".3em",whiteSpace:"normal"},comment:{color:"slategray"},prolog:{color:"slategray"},doctype:{color:"slategray"},cdata:{color:"slategray"},punctuation:{color:"#999"},namespace:{Opacity:".7"},property:{color:"#905"},tag:{color:"#905"},boolean:{color:"#905"},number:{color:"#905"},constant:{color:"#905"},symbol:{color:"#905"},deleted:{color:"#905"},selector:{color:"#690"},"attr-name":{color:"#690"},string:{color:"#690"},char:{color:"#690"},builtin:{color:"#690"},inserted:{color:"#690"},operator:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},entity:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)",cursor:"help"},url:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},".language-css .token.string":{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},".style .token.string":{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},atrule:{color:"#07a"},"attr-value":{color:"#07a"},keyword:{color:"#07a"},function:{color:"#DD4A68"},"class-name":{color:"#DD4A68"},regex:{color:"#e90"},important:{color:"#e90",fontWeight:"bold"},variable:{color:"#e90"},bold:{fontWeight:"bold"},italic:{fontStyle:"italic"}};var cc,tv;function eU(){if(tv)return cc;tv=1,cc=e,e.displayName="abap",e.aliases=[];function e(t){t.languages.abap={comment:/^\*.*/m,string:/(`|')(?:\\.|(?!\1)[^\\\r\n])*\1/,"string-template":{pattern:/([|}])(?:\\.|[^\\|{\r\n])*(?=[|{])/,lookbehind:!0,alias:"string"},"eol-comment":{pattern:/(^|\s)".*/m,lookbehind:!0,alias:"comment"},keyword:{pattern:/(\s|\.|^)(?:SCIENTIFIC_WITH_LEADING_ZERO|SCALE_PRESERVING_SCIENTIFIC|RMC_COMMUNICATION_FAILURE|END-ENHANCEMENT-SECTION|MULTIPLY-CORRESPONDING|SUBTRACT-CORRESPONDING|VERIFICATION-MESSAGE|DIVIDE-CORRESPONDING|ENHANCEMENT-SECTION|CURRENCY_CONVERSION|RMC_SYSTEM_FAILURE|START-OF-SELECTION|MOVE-CORRESPONDING|RMC_INVALID_STATUS|CUSTOMER-FUNCTION|END-OF-DEFINITION|ENHANCEMENT-POINT|SYSTEM-EXCEPTIONS|ADD-CORRESPONDING|SCALE_PRESERVING|SELECTION-SCREEN|CURSOR-SELECTION|END-OF-SELECTION|LOAD-OF-PROGRAM|SCROLL-BOUNDARY|SELECTION-TABLE|EXCEPTION-TABLE|IMPLEMENTATIONS|PARAMETER-TABLE|RIGHT-JUSTIFIED|UNIT_CONVERSION|AUTHORITY-CHECK|LIST-PROCESSING|SIGN_AS_POSTFIX|COL_BACKGROUND|IMPLEMENTATION|INTERFACE-POOL|TRANSFORMATION|IDENTIFICATION|ENDENHANCEMENT|LINE-SELECTION|INITIALIZATION|LEFT-JUSTIFIED|SELECT-OPTIONS|SELECTION-SETS|COMMUNICATION|CORRESPONDING|DECIMAL_SHIFT|PRINT-CONTROL|VALUE-REQUEST|CHAIN-REQUEST|FUNCTION-POOL|FIELD-SYMBOLS|FUNCTIONALITY|INVERTED-DATE|SELECTION-SET|CLASS-METHODS|OUTPUT-LENGTH|CLASS-CODING|COL_NEGATIVE|ERRORMESSAGE|FIELD-GROUPS|HELP-REQUEST|NO-EXTENSION|NO-TOPOFPAGE|REDEFINITION|DISPLAY-MODE|ENDINTERFACE|EXIT-COMMAND|FIELD-SYMBOL|NO-SCROLLING|SHORTDUMP-ID|ACCESSPOLICY|CLASS-EVENTS|COL_POSITIVE|DECLARATIONS|ENHANCEMENTS|FILTER-TABLE|SWITCHSTATES|SYNTAX-CHECK|TRANSPORTING|ASYNCHRONOUS|SYNTAX-TRACE|TOKENIZATION|USER-COMMAND|WITH-HEADING|ABAP-SOURCE|BREAK-POINT|CHAIN-INPUT|COMPRESSION|FIXED-POINT|NEW-SECTION|NON-UNICODE|OCCURRENCES|RESPONSIBLE|SYSTEM-CALL|TRACE-TABLE|ABBREVIATED|CHAR-TO-HEX|END-OF-FILE|ENDFUNCTION|ENVIRONMENT|ASSOCIATION|COL_HEADING|EDITOR-CALL|END-OF-PAGE|ENGINEERING|IMPLEMENTED|INTENSIFIED|RADIOBUTTON|SYSTEM-EXIT|TOP-OF-PAGE|TRANSACTION|APPLICATION|CONCATENATE|DESTINATION|ENHANCEMENT|IMMEDIATELY|NO-GROUPING|PRECOMPILED|REPLACEMENT|TITLE-LINES|ACTIVATION|BYTE-ORDER|CLASS-POOL|CONNECTION|CONVERSION|DEFINITION|DEPARTMENT|EXPIRATION|INHERITING|MESSAGE-ID|NO-HEADING|PERFORMING|QUEUE-ONLY|RIGHTSPACE|SCIENTIFIC|STATUSINFO|STRUCTURES|SYNCPOINTS|WITH-TITLE|ATTRIBUTES|BOUNDARIES|CLASS-DATA|COL_NORMAL|DD\/MM\/YYYY|DESCENDING|INTERFACES|LINE-COUNT|MM\/DD\/YYYY|NON-UNIQUE|PRESERVING|SELECTIONS|STATEMENTS|SUBROUTINE|TRUNCATION|TYPE-POOLS|ARITHMETIC|BACKGROUND|ENDPROVIDE|EXCEPTIONS|IDENTIFIER|INDEX-LINE|OBLIGATORY|PARAMETERS|PERCENTAGE|PUSHBUTTON|RESOLUTION|COMPONENTS|DEALLOCATE|DISCONNECT|DUPLICATES|FIRST-LINE|HEAD-LINES|NO-DISPLAY|OCCURRENCE|RESPECTING|RETURNCODE|SUBMATCHES|TRACE-FILE|ASCENDING|BYPASSING|ENDMODULE|EXCEPTION|EXCLUDING|EXPORTING|INCREMENT|MATCHCODE|PARAMETER|PARTIALLY|PREFERRED|REFERENCE|REPLACING|RETURNING|SELECTION|SEPARATED|SPECIFIED|STATEMENT|TIMESTAMP|TYPE-POOL|ACCEPTING|APPENDAGE|ASSIGNING|COL_GROUP|COMPARING|CONSTANTS|DANGEROUS|IMPORTING|INSTANCES|LEFTSPACE|LOG-POINT|QUICKINFO|READ-ONLY|SCROLLING|SQLSCRIPT|STEP-LOOP|TOP-LINES|TRANSLATE|APPENDING|AUTHORITY|CHARACTER|COMPONENT|CONDITION|DIRECTORY|DUPLICATE|MESSAGING|RECEIVING|SUBSCREEN|ACCORDING|COL_TOTAL|END-LINES|ENDMETHOD|ENDSELECT|EXPANDING|EXTENSION|INCLUDING|INFOTYPES|INTERFACE|INTERVALS|LINE-SIZE|PF-STATUS|PROCEDURE|PROTECTED|REQUESTED|RESUMABLE|RIGHTPLUS|SAP-SPOOL|SECONDARY|STRUCTURE|SUBSTRING|TABLEVIEW|NUMOFCHAR|ADJACENT|ANALYSIS|ASSIGNED|BACKWARD|CHANNELS|CHECKBOX|CONTINUE|CRITICAL|DATAINFO|DD\/MM\/YY|DURATION|ENCODING|ENDCLASS|FUNCTION|LEFTPLUS|LINEFEED|MM\/DD\/YY|OVERFLOW|RECEIVED|SKIPPING|SORTABLE|STANDARD|SUBTRACT|SUPPRESS|TABSTRIP|TITLEBAR|TRUNCATE|UNASSIGN|WHENEVER|ANALYZER|COALESCE|COMMENTS|CONDENSE|DECIMALS|DEFERRED|ENDWHILE|EXPLICIT|KEYWORDS|MESSAGES|POSITION|PRIORITY|RECEIVER|RENAMING|TIMEZONE|TRAILING|ALLOCATE|CENTERED|CIRCULAR|CONTROLS|CURRENCY|DELETING|DESCRIBE|DISTANCE|ENDCATCH|EXPONENT|EXTENDED|GENERATE|IGNORING|INCLUDES|INTERNAL|MAJOR-ID|MODIFIER|NEW-LINE|OPTIONAL|PROPERTY|ROLLBACK|STARTING|SUPPLIED|ABSTRACT|CHANGING|CONTEXTS|CREATING|CUSTOMER|DATABASE|DAYLIGHT|DEFINING|DISTINCT|DIVISION|ENABLING|ENDCHAIN|ESCAPING|HARMLESS|IMPLICIT|INACTIVE|LANGUAGE|MINOR-ID|MULTIPLY|NEW-PAGE|NO-TITLE|POS_HIGH|SEPARATE|TEXTPOOL|TRANSFER|SELECTOR|DBMAXLEN|ITERATOR|ARCHIVE|BIT-XOR|BYTE-CO|COLLECT|COMMENT|CURRENT|DEFAULT|DISPLAY|ENDFORM|EXTRACT|LEADING|LISTBOX|LOCATOR|MEMBERS|METHODS|NESTING|POS_LOW|PROCESS|PROVIDE|RAISING|RESERVE|SECONDS|SUMMARY|VISIBLE|BETWEEN|BIT-AND|BYTE-CS|CLEANUP|COMPUTE|CONTROL|CONVERT|DATASET|ENDCASE|FORWARD|HEADERS|HOTSPOT|INCLUDE|INVERSE|KEEPING|NO-ZERO|OBJECTS|OVERLAY|PADDING|PATTERN|PROGRAM|REFRESH|SECTION|SUMMING|TESTING|VERSION|WINDOWS|WITHOUT|BIT-NOT|BYTE-CA|BYTE-NA|CASTING|CONTEXT|COUNTRY|DYNAMIC|ENABLED|ENDLOOP|EXECUTE|FRIENDS|HANDLER|HEADING|INITIAL|\*-INPUT|LOGFILE|MAXIMUM|MINIMUM|NO-GAPS|NO-SIGN|PRAGMAS|PRIMARY|PRIVATE|REDUCED|REPLACE|REQUEST|RESULTS|UNICODE|WARNING|ALIASES|BYTE-CN|BYTE-NS|CALLING|COL_KEY|COLUMNS|CONNECT|ENDEXEC|ENTRIES|EXCLUDE|FILTERS|FURTHER|HELP-ID|LOGICAL|MAPPING|MESSAGE|NAMETAB|OPTIONS|PACKAGE|PERFORM|RECEIVE|STATICS|VARYING|BINDING|CHARLEN|GREATER|XSTRLEN|ACCEPT|APPEND|DETAIL|ELSEIF|ENDING|ENDTRY|FORMAT|FRAMES|GIVING|HASHED|HEADER|IMPORT|INSERT|MARGIN|MODULE|NATIVE|OBJECT|OFFSET|REMOTE|RESUME|SAVING|SIMPLE|SUBMIT|TABBED|TOKENS|UNIQUE|UNPACK|UPDATE|WINDOW|YELLOW|ACTUAL|ASPECT|CENTER|CURSOR|DELETE|DIALOG|DIVIDE|DURING|ERRORS|EVENTS|EXTEND|FILTER|HANDLE|HAVING|IGNORE|LITTLE|MEMORY|NO-GAP|OCCURS|OPTION|PERSON|PLACES|PUBLIC|REDUCE|REPORT|RESULT|SINGLE|SORTED|SWITCH|SYNTAX|TARGET|VALUES|WRITER|ASSERT|BLOCKS|BOUNDS|BUFFER|CHANGE|COLUMN|COMMIT|CONCAT|COPIES|CREATE|DDMMYY|DEFINE|ENDIAN|ESCAPE|EXPAND|KERNEL|LAYOUT|LEGACY|LEVELS|MMDDYY|NUMBER|OUTPUT|RANGES|READER|RETURN|SCREEN|SEARCH|SELECT|SHARED|SOURCE|STABLE|STATIC|SUBKEY|SUFFIX|TABLES|UNWIND|YYMMDD|ASSIGN|BACKUP|BEFORE|BINARY|BIT-OR|BLANKS|CLIENT|CODING|COMMON|DEMAND|DYNPRO|EXCEPT|EXISTS|EXPORT|FIELDS|GLOBAL|GROUPS|LENGTH|LOCALE|MEDIUM|METHOD|MODIFY|NESTED|OTHERS|REJECT|SCROLL|SUPPLY|SYMBOL|ENDFOR|STRLEN|ALIGN|BEGIN|BOUND|ENDAT|ENTRY|EVENT|FINAL|FLUSH|GRANT|INNER|SHORT|USING|WRITE|AFTER|BLACK|BLOCK|CLOCK|COLOR|COUNT|DUMMY|EMPTY|ENDDO|ENDON|GREEN|INDEX|INOUT|LEAVE|LEVEL|LINES|MODIF|ORDER|OUTER|RANGE|RESET|RETRY|RIGHT|SMART|SPLIT|STYLE|TABLE|THROW|UNDER|UNTIL|UPPER|UTF-8|WHERE|ALIAS|BLANK|CLEAR|CLOSE|EXACT|FETCH|FIRST|FOUND|GROUP|LLANG|LOCAL|OTHER|REGEX|SPOOL|TITLE|TYPES|VALID|WHILE|ALPHA|BOXED|CATCH|CHAIN|CHECK|CLASS|COVER|ENDIF|EQUIV|FIELD|FLOOR|FRAME|INPUT|LOWER|MATCH|NODES|PAGES|PRINT|RAISE|ROUND|SHIFT|SPACE|SPOTS|STAMP|STATE|TASKS|TIMES|TRMAC|ULINE|UNION|VALUE|WIDTH|EQUAL|LOG10|TRUNC|BLOB|CASE|CEIL|CLOB|COND|EXIT|FILE|GAPS|HOLD|INCL|INTO|KEEP|KEYS|LAST|LINE|LONG|LPAD|MAIL|MODE|OPEN|PINK|READ|ROWS|TEST|THEN|ZERO|AREA|BACK|BADI|BYTE|CAST|EDIT|EXEC|FAIL|FIND|FKEQ|FONT|FREE|GKEQ|HIDE|INIT|ITNO|LATE|LOOP|MAIN|MARK|MOVE|NEXT|NULL|RISK|ROLE|UNIT|WAIT|ZONE|BASE|CALL|CODE|DATA|DATE|FKGE|GKGE|HIGH|KIND|LEFT|LIST|MASK|MESH|NAME|NODE|PACK|PAGE|POOL|SEND|SIGN|SIZE|SOME|STOP|TASK|TEXT|TIME|USER|VARY|WITH|WORD|BLUE|CONV|COPY|DEEP|ELSE|FORM|FROM|HINT|ICON|JOIN|LIKE|LOAD|ONLY|PART|SCAN|SKIP|SORT|TYPE|UNIX|VIEW|WHEN|WORK|ACOS|ASIN|ATAN|COSH|EACH|FRAC|LESS|RTTI|SINH|SQRT|TANH|AVG|BIT|DIV|ISO|LET|OUT|PAD|SQL|ALL|CI_|CPI|END|LOB|LPI|MAX|MIN|NEW|OLE|RUN|SET|\?TO|YES|ABS|ADD|AND|BIG|FOR|HDB|JOB|LOW|NOT|SAP|TRY|VIA|XML|ANY|GET|IDS|KEY|MOD|OFF|PUT|RAW|RED|REF|SUM|TAB|XSD|CNT|COS|EXP|LOG|SIN|TAN|XOR|AT|CO|CP|DO|GT|ID|IF|NS|OR|BT|CA|CS|GE|NA|NB|EQ|IN|LT|NE|NO|OF|ON|PF|TO|AS|BY|CN|IS|LE|NP|UP|E|I|M|O|Z|C|X)\b/i,lookbehind:!0},number:/\b\d+\b/,operator:{pattern:/(\s)(?:\*\*?|<[=>]?|>=?|\?=|[-+\/=])(?=\s)/,lookbehind:!0},"string-operator":{pattern:/(\s)&&?(?=\s)/,lookbehind:!0,alias:"keyword"},"token-operator":[{pattern:/(\w)(?:->?|=>|[~|{}])(?=\w)/,lookbehind:!0,alias:"punctuation"},{pattern:/[|{}]/,alias:"punctuation"}],punctuation:/[,.:()]/}}return cc}var dc,nv;function tU(){if(nv)return dc;nv=1,dc=e,e.displayName="abnf",e.aliases=[];function e(t){(function(n){var i="(?:ALPHA|BIT|CHAR|CR|CRLF|CTL|DIGIT|DQUOTE|HEXDIG|HTAB|LF|LWSP|OCTET|SP|VCHAR|WSP)";n.languages.abnf={comment:/;.*/,string:{pattern:/(?:%[is])?"[^"\n\r]*"/,greedy:!0,inside:{punctuation:/^%[is]/}},range:{pattern:/%(?:b[01]+-[01]+|d\d+-\d+|x[A-F\d]+-[A-F\d]+)/i,alias:"number"},terminal:{pattern:/%(?:b[01]+(?:\.[01]+)*|d\d+(?:\.\d+)*|x[A-F\d]+(?:\.[A-F\d]+)*)/i,alias:"number"},repetition:{pattern:/(^|[^\w-])(?:\d*\*\d*|\d+)/,lookbehind:!0,alias:"operator"},definition:{pattern:/(^[ \t]*)(?:[a-z][\w-]*|<[^<>\r\n]*>)(?=\s*=)/m,lookbehind:!0,alias:"keyword",inside:{punctuation:/<|>/}},"core-rule":{pattern:RegExp("(?:(^|[^<\\w-])"+i+"|<"+i+">)(?![\\w-])","i"),lookbehind:!0,alias:["rule","constant"],inside:{punctuation:/<|>/}},rule:{pattern:/(^|[^<\w-])[a-z][\w-]*|<[^<>\r\n]*>/i,lookbehind:!0,inside:{punctuation:/<|>/}},operator:/=\/?|\//,punctuation:/[()\[\]]/}})(t)}return dc}var pc,rv;function nU(){if(rv)return pc;rv=1,pc=e,e.displayName="actionscript",e.aliases=[];function e(t){t.languages.actionscript=t.languages.extend("javascript",{keyword:/\b(?:as|break|case|catch|class|const|default|delete|do|dynamic|each|else|extends|final|finally|for|function|get|if|implements|import|in|include|instanceof|interface|internal|is|namespace|native|new|null|override|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|use|var|void|while|with)\b/,operator:/\+\+|--|(?:[+\-*\/%^]|&&?|\|\|?|<|>>?>?|[!=]=?)=?|[~?@]/}),t.languages.actionscript["class-name"].alias="function",delete t.languages.actionscript.parameter,delete t.languages.actionscript["literal-property"],t.languages.markup&&t.languages.insertBefore("actionscript","string",{xml:{pattern:/(^|[^.])<\/?\w+(?:\s+[^\s>\/=]+=("|')(?:\\[\s\S]|(?!\2)[^\\])*\2)*\s*\/?>/,lookbehind:!0,inside:t.languages.markup}})}return pc}var fc,av;function rU(){if(av)return fc;av=1,fc=e,e.displayName="ada",e.aliases=[];function e(t){t.languages.ada={comment:/--.*/,string:/"(?:""|[^"\r\f\n])*"/,number:[{pattern:/\b\d(?:_?\d)*#[\dA-F](?:_?[\dA-F])*(?:\.[\dA-F](?:_?[\dA-F])*)?#(?:E[+-]?\d(?:_?\d)*)?/i},{pattern:/\b\d(?:_?\d)*(?:\.\d(?:_?\d)*)?(?:E[+-]?\d(?:_?\d)*)?\b/i}],"attr-name":/\b'\w+/,keyword:/\b(?:abort|abs|abstract|accept|access|aliased|all|and|array|at|begin|body|case|constant|declare|delay|delta|digits|do|else|elsif|end|entry|exception|exit|for|function|generic|goto|if|in|interface|is|limited|loop|mod|new|not|null|of|others|out|overriding|package|pragma|private|procedure|protected|raise|range|record|rem|renames|requeue|return|reverse|select|separate|some|subtype|synchronized|tagged|task|terminate|then|type|until|use|when|while|with|xor)\b/i,boolean:/\b(?:false|true)\b/i,operator:/<[=>]?|>=?|=>?|:=|\/=?|\*\*?|[&+-]/,punctuation:/\.\.?|[,;():]/,char:/'.'/,variable:/\b[a-z](?:\w)*\b/i}}return fc}var gc,iv;function aU(){if(iv)return gc;iv=1,gc=e,e.displayName="agda",e.aliases=[];function e(t){(function(n){n.languages.agda={comment:/\{-[\s\S]*?(?:-\}|$)|--.*/,string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^\\\r\n"])*"/,greedy:!0},punctuation:/[(){}⦃⦄.;@]/,"class-name":{pattern:/((?:data|record) +)\S+/,lookbehind:!0},function:{pattern:/(^[ \t]*)(?!\s)[^:\r\n]+(?=:)/m,lookbehind:!0},operator:{pattern:/(^\s*|\s)(?:[=|:∀→λ\\?_]|->)(?=\s)/,lookbehind:!0},keyword:/\b(?:Set|abstract|constructor|data|eta-equality|field|forall|hiding|import|in|inductive|infix|infixl|infixr|instance|let|macro|module|mutual|no-eta-equality|open|overlap|pattern|postulate|primitive|private|public|quote|quoteContext|quoteGoal|quoteTerm|record|renaming|rewrite|syntax|tactic|unquote|unquoteDecl|unquoteDef|using|variable|where|with)\b/}})(t)}return gc}var mc,ov;function iU(){if(ov)return mc;ov=1,mc=e,e.displayName="al",e.aliases=[];function e(t){t.languages.al={comment:/\/\/.*|\/\*[\s\S]*?\*\//,string:{pattern:/'(?:''|[^'\r\n])*'(?!')|"(?:""|[^"\r\n])*"(?!")/,greedy:!0},function:{pattern:/(\b(?:event|procedure|trigger)\s+|(?:^|[^.])\.\s*)[a-z_]\w*(?=\s*\()/i,lookbehind:!0},keyword:[/\b(?:array|asserterror|begin|break|case|do|downto|else|end|event|exit|for|foreach|function|if|implements|in|indataset|interface|internal|local|of|procedure|program|protected|repeat|runonclient|securityfiltering|suppressdispose|temporary|then|to|trigger|until|var|while|with|withevents)\b/i,/\b(?:action|actions|addafter|addbefore|addfirst|addlast|area|assembly|chartpart|codeunit|column|controladdin|cuegroup|customizes|dataitem|dataset|dotnet|elements|enum|enumextension|extends|field|fieldattribute|fieldelement|fieldgroup|fieldgroups|fields|filter|fixed|grid|group|key|keys|label|labels|layout|modify|moveafter|movebefore|movefirst|movelast|page|pagecustomization|pageextension|part|profile|query|repeater|report|requestpage|schema|separator|systempart|table|tableelement|tableextension|textattribute|textelement|type|usercontrol|value|xmlport)\b/i],number:/\b(?:0x[\da-f]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?)(?:F|LL?|U(?:LL?)?)?\b/i,boolean:/\b(?:false|true)\b/i,variable:/\b(?:Curr(?:FieldNo|Page|Report)|x?Rec|RequestOptionsPage)\b/,"class-name":/\b(?:automation|biginteger|bigtext|blob|boolean|byte|char|clienttype|code|completiontriggererrorlevel|connectiontype|database|dataclassification|datascope|date|dateformula|datetime|decimal|defaultlayout|dialog|dictionary|dotnetassembly|dotnettypedeclaration|duration|errorinfo|errortype|executioncontext|executionmode|fieldclass|fieldref|fieldtype|file|filterpagebuilder|guid|httpclient|httpcontent|httpheaders|httprequestmessage|httpresponsemessage|instream|integer|joker|jsonarray|jsonobject|jsontoken|jsonvalue|keyref|list|moduledependencyinfo|moduleinfo|none|notification|notificationscope|objecttype|option|outstream|pageresult|record|recordid|recordref|reportformat|securityfilter|sessionsettings|tableconnectiontype|tablefilter|testaction|testfield|testfilterfield|testpage|testpermissions|testrequestpage|text|textbuilder|textconst|textencoding|time|transactionmodel|transactiontype|variant|verbosity|version|view|views|webserviceactioncontext|webserviceactionresultcode|xmlattribute|xmlattributecollection|xmlcdata|xmlcomment|xmldeclaration|xmldocument|xmldocumenttype|xmlelement|xmlnamespacemanager|xmlnametable|xmlnode|xmlnodelist|xmlprocessinginstruction|xmlreadoptions|xmltext|xmlwriteoptions)\b/i,operator:/\.\.|:[=:]|[-+*/]=?|<>|[<>]=?|=|\b(?:and|div|mod|not|or|xor)\b/i,punctuation:/[()\[\]{}:.;,]/}}return mc}var hc,sv;function oU(){if(sv)return hc;sv=1,hc=e,e.displayName="antlr4",e.aliases=["g4"];function e(t){t.languages.antlr4={comment:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,string:{pattern:/'(?:\\.|[^\\'\r\n])*'/,greedy:!0},"character-class":{pattern:/\[(?:\\.|[^\\\]\r\n])*\]/,greedy:!0,alias:"regex",inside:{range:{pattern:/([^[]|(?:^|[^\\])(?:\\\\)*\\\[)-(?!\])/,lookbehind:!0,alias:"punctuation"},escape:/\\(?:u(?:[a-fA-F\d]{4}|\{[a-fA-F\d]+\})|[pP]\{[=\w-]+\}|[^\r\nupP])/,punctuation:/[\[\]]/}},action:{pattern:/\{(?:[^{}]|\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})*\})*\}/,greedy:!0,inside:{content:{pattern:/(\{)[\s\S]+(?=\})/,lookbehind:!0},punctuation:/[{}]/}},command:{pattern:/(->\s*(?!\s))(?:\s*(?:,\s*)?\b[a-z]\w*(?:\s*\([^()\r\n]*\))?)+(?=\s*;)/i,lookbehind:!0,inside:{function:/\b\w+(?=\s*(?:[,(]|$))/,punctuation:/[,()]/}},annotation:{pattern:/@\w+(?:::\w+)*/,alias:"keyword"},label:{pattern:/#[ \t]*\w+/,alias:"punctuation"},keyword:/\b(?:catch|channels|finally|fragment|grammar|import|lexer|locals|mode|options|parser|returns|throws|tokens)\b/,definition:[{pattern:/\b[a-z]\w*(?=\s*:)/,alias:["rule","class-name"]},{pattern:/\b[A-Z]\w*(?=\s*:)/,alias:["token","constant"]}],constant:/\b[A-Z][A-Z_]*\b/,operator:/\.\.|->|[|~]|[*+?]\??/,punctuation:/[;:()=]/},t.languages.g4=t.languages.antlr4}return hc}var bc,lv;function sU(){if(lv)return bc;lv=1,bc=e,e.displayName="apacheconf",e.aliases=[];function e(t){t.languages.apacheconf={comment:/#.*/,"directive-inline":{pattern:/(^[\t ]*)\b(?:AcceptFilter|AcceptPathInfo|AccessFileName|Action|Add(?:Alt|AltByEncoding|AltByType|Charset|DefaultCharset|Description|Encoding|Handler|Icon|IconByEncoding|IconByType|InputFilter|Language|ModuleInfo|OutputFilter|OutputFilterByType|Type)|Alias|AliasMatch|Allow(?:CONNECT|EncodedSlashes|Methods|Override|OverrideList)?|Anonymous(?:_LogEmail|_MustGiveEmail|_NoUserID|_VerifyEmail)?|AsyncRequestWorkerFactor|Auth(?:BasicAuthoritative|BasicFake|BasicProvider|BasicUseDigestAlgorithm|DBDUserPWQuery|DBDUserRealmQuery|DBMGroupFile|DBMType|DBMUserFile|Digest(?:Algorithm|Domain|NonceLifetime|Provider|Qop|ShmemSize)|Form(?:Authoritative|Body|DisableNoStore|FakeBasicAuth|Location|LoginRequiredLocation|LoginSuccessLocation|LogoutLocation|Method|Mimetype|Password|Provider|SitePassphrase|Size|Username)|GroupFile|LDAP(?:AuthorizePrefix|BindAuthoritative|BindDN|BindPassword|CharsetConfig|CompareAsUser|CompareDNOnServer|DereferenceAliases|GroupAttribute|GroupAttributeIsDN|InitialBindAsUser|InitialBindPattern|MaxSubGroupDepth|RemoteUserAttribute|RemoteUserIsDN|SearchAsUser|SubGroupAttribute|SubGroupClass|Url)|Merging|Name|nCache(?:Context|Enable|ProvideFor|SOCache|Timeout)|nzFcgiCheckAuthnProvider|nzFcgiDefineProvider|Type|UserFile|zDBDLoginToReferer|zDBDQuery|zDBDRedirectQuery|zDBMType|zSendForbiddenOnFailure)|BalancerGrowth|BalancerInherit|BalancerMember|BalancerPersist|BrowserMatch|BrowserMatchNoCase|BufferedLogs|BufferSize|Cache(?:DefaultExpire|DetailHeader|DirLength|DirLevels|Disable|Enable|File|Header|IgnoreCacheControl|IgnoreHeaders|IgnoreNoLastMod|IgnoreQueryString|IgnoreURLSessionIdentifiers|KeyBaseURL|LastModifiedFactor|Lock|LockMaxAge|LockPath|MaxExpire|MaxFileSize|MinExpire|MinFileSize|NegotiatedDocs|QuickHandler|ReadSize|ReadTime|Root|Socache(?:MaxSize|MaxTime|MinTime|ReadSize|ReadTime)?|StaleOnError|StoreExpired|StoreNoStore|StorePrivate)|CGIDScriptTimeout|CGIMapExtension|CharsetDefault|CharsetOptions|CharsetSourceEnc|CheckCaseOnly|CheckSpelling|ChrootDir|ContentDigest|CookieDomain|CookieExpires|CookieName|CookieStyle|CookieTracking|CoreDumpDirectory|CustomLog|Dav|DavDepthInfinity|DavGenericLockDB|DavLockDB|DavMinTimeout|DBDExptime|DBDInitSQL|DBDKeep|DBDMax|DBDMin|DBDParams|DBDPersist|DBDPrepareSQL|DBDriver|DefaultIcon|DefaultLanguage|DefaultRuntimeDir|DefaultType|Define|Deflate(?:BufferSize|CompressionLevel|FilterNote|InflateLimitRequestBody|InflateRatio(?:Burst|Limit)|MemLevel|WindowSize)|Deny|DirectoryCheckHandler|DirectoryIndex|DirectoryIndexRedirect|DirectorySlash|DocumentRoot|DTracePrivileges|DumpIOInput|DumpIOOutput|EnableExceptionHook|EnableMMAP|EnableSendfile|Error|ErrorDocument|ErrorLog|ErrorLogFormat|Example|ExpiresActive|ExpiresByType|ExpiresDefault|ExtendedStatus|ExtFilterDefine|ExtFilterOptions|FallbackResource|FileETag|FilterChain|FilterDeclare|FilterProtocol|FilterProvider|FilterTrace|ForceLanguagePriority|ForceType|ForensicLog|GprofDir|GracefulShutdownTimeout|Group|Header|HeaderName|Heartbeat(?:Address|Listen|MaxServers|Storage)|HostnameLookups|IdentityCheck|IdentityCheckTimeout|ImapBase|ImapDefault|ImapMenu|Include|IncludeOptional|Index(?:HeadInsert|Ignore|IgnoreReset|Options|OrderDefault|StyleSheet)|InputSed|ISAPI(?:AppendLogToErrors|AppendLogToQuery|CacheFile|FakeAsync|LogNotSupported|ReadAheadBuffer)|KeepAlive|KeepAliveTimeout|KeptBodySize|LanguagePriority|LDAP(?:CacheEntries|CacheTTL|ConnectionPoolTTL|ConnectionTimeout|LibraryDebug|OpCacheEntries|OpCacheTTL|ReferralHopLimit|Referrals|Retries|RetryDelay|SharedCacheFile|SharedCacheSize|Timeout|TrustedClientCert|TrustedGlobalCert|TrustedMode|VerifyServerCert)|Limit(?:InternalRecursion|Request(?:Body|Fields|FieldSize|Line)|XMLRequestBody)|Listen|ListenBackLog|LoadFile|LoadModule|LogFormat|LogLevel|LogMessage|LuaAuthzProvider|LuaCodeCache|Lua(?:Hook(?:AccessChecker|AuthChecker|CheckUserID|Fixups|InsertFilter|Log|MapToStorage|TranslateName|TypeChecker)|Inherit|InputFilter|MapHandler|OutputFilter|PackageCPath|PackagePath|QuickHandler|Root|Scope)|Max(?:ConnectionsPerChild|KeepAliveRequests|MemFree|RangeOverlaps|RangeReversals|Ranges|RequestWorkers|SpareServers|SpareThreads|Threads)|MergeTrailers|MetaDir|MetaFiles|MetaSuffix|MimeMagicFile|MinSpareServers|MinSpareThreads|MMapFile|ModemStandard|ModMimeUsePathInfo|MultiviewsMatch|Mutex|NameVirtualHost|NoProxy|NWSSLTrustedCerts|NWSSLUpgradeable|Options|Order|OutputSed|PassEnv|PidFile|PrivilegesMode|Protocol|ProtocolEcho|Proxy(?:AddHeaders|BadHeader|Block|Domain|ErrorOverride|ExpressDBMFile|ExpressDBMType|ExpressEnable|FtpDirCharset|FtpEscapeWildcards|FtpListOnWildcard|HTML(?:BufSize|CharsetOut|DocType|Enable|Events|Extended|Fixups|Interp|Links|Meta|StripComments|URLMap)|IOBufferSize|MaxForwards|Pass(?:Inherit|InterpolateEnv|Match|Reverse|ReverseCookieDomain|ReverseCookiePath)?|PreserveHost|ReceiveBufferSize|Remote|RemoteMatch|Requests|SCGIInternalRedirect|SCGISendfile|Set|SourceAddress|Status|Timeout|Via)|ReadmeName|ReceiveBufferSize|Redirect|RedirectMatch|RedirectPermanent|RedirectTemp|ReflectorHeader|RemoteIP(?:Header|InternalProxy|InternalProxyList|ProxiesHeader|TrustedProxy|TrustedProxyList)|RemoveCharset|RemoveEncoding|RemoveHandler|RemoveInputFilter|RemoveLanguage|RemoveOutputFilter|RemoveType|RequestHeader|RequestReadTimeout|Require|Rewrite(?:Base|Cond|Engine|Map|Options|Rule)|RLimitCPU|RLimitMEM|RLimitNPROC|Satisfy|ScoreBoardFile|Script(?:Alias|AliasMatch|InterpreterSource|Log|LogBuffer|LogLength|Sock)?|SecureListen|SeeRequestTail|SendBufferSize|Server(?:Admin|Alias|Limit|Name|Path|Root|Signature|Tokens)|Session(?:Cookie(?:Name|Name2|Remove)|Crypto(?:Cipher|Driver|Passphrase|PassphraseFile)|DBD(?:CookieName|CookieName2|CookieRemove|DeleteLabel|InsertLabel|PerUser|SelectLabel|UpdateLabel)|Env|Exclude|Header|Include|MaxAge)?|SetEnv|SetEnvIf|SetEnvIfExpr|SetEnvIfNoCase|SetHandler|SetInputFilter|SetOutputFilter|SSIEndTag|SSIErrorMsg|SSIETag|SSILastModified|SSILegacyExprParser|SSIStartTag|SSITimeFormat|SSIUndefinedEcho|SSL(?:CACertificateFile|CACertificatePath|CADNRequestFile|CADNRequestPath|CARevocationCheck|CARevocationFile|CARevocationPath|CertificateChainFile|CertificateFile|CertificateKeyFile|CipherSuite|Compression|CryptoDevice|Engine|FIPS|HonorCipherOrder|InsecureRenegotiation|OCSP(?:DefaultResponder|Enable|OverrideResponder|ResponderTimeout|ResponseMaxAge|ResponseTimeSkew|UseRequestNonce)|OpenSSLConfCmd|Options|PassPhraseDialog|Protocol|Proxy(?:CACertificateFile|CACertificatePath|CARevocation(?:Check|File|Path)|CheckPeer(?:CN|Expire|Name)|CipherSuite|Engine|MachineCertificate(?:ChainFile|File|Path)|Protocol|Verify|VerifyDepth)|RandomSeed|RenegBufferSize|Require|RequireSSL|Session(?:Cache|CacheTimeout|TicketKeyFile|Tickets)|SRPUnknownUserSeed|SRPVerifierFile|Stapling(?:Cache|ErrorCacheTimeout|FakeTryLater|ForceURL|ResponderTimeout|ResponseMaxAge|ResponseTimeSkew|ReturnResponderErrors|StandardCacheTimeout)|StrictSNIVHostCheck|UserName|UseStapling|VerifyClient|VerifyDepth)|StartServers|StartThreads|Substitute|Suexec|SuexecUserGroup|ThreadLimit|ThreadsPerChild|ThreadStackSize|TimeOut|TraceEnable|TransferLog|TypesConfig|UnDefine|UndefMacro|UnsetEnv|Use|UseCanonicalName|UseCanonicalPhysicalPort|User|UserDir|VHostCGIMode|VHostCGIPrivs|VHostGroup|VHostPrivs|VHostSecure|VHostUser|Virtual(?:DocumentRoot|ScriptAlias)(?:IP)?|WatchdogInterval|XBitHack|xml2EncAlias|xml2EncDefault|xml2StartParse)\b/im,lookbehind:!0,alias:"property"},"directive-block":{pattern:/<\/?\b(?:Auth[nz]ProviderAlias|Directory|DirectoryMatch|Else|ElseIf|Files|FilesMatch|If|IfDefine|IfModule|IfVersion|Limit|LimitExcept|Location|LocationMatch|Macro|Proxy|Require(?:All|Any|None)|VirtualHost)\b.*>/i,inside:{"directive-block":{pattern:/^<\/?\w+/,inside:{punctuation:/^<\/?/},alias:"tag"},"directive-block-parameter":{pattern:/.*[^>]/,inside:{punctuation:/:/,string:{pattern:/("|').*\1/,inside:{variable:/[$%]\{?(?:\w\.?[-+:]?)+\}?/}}},alias:"attr-value"},punctuation:/>/},alias:"tag"},"directive-flags":{pattern:/\[(?:[\w=],?)+\]/,alias:"keyword"},string:{pattern:/("|').*\1/,inside:{variable:/[$%]\{?(?:\w\.?[-+:]?)+\}?/}},variable:/[$%]\{?(?:\w\.?[-+:]?)+\}?/,regex:/\^?.*\$|\^.*\$?/}}return bc}var yc,uv;function ph(){if(uv)return yc;uv=1,yc=e,e.displayName="sql",e.aliases=[];function e(t){t.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/}}return yc}var Ec,cv;function lU(){if(cv)return Ec;cv=1;var e=ph();Ec=t,t.displayName="apex",t.aliases=[];function t(n){n.register(e),(function(i){var o=/\b(?:(?:after|before)(?=\s+[a-z])|abstract|activate|and|any|array|as|asc|autonomous|begin|bigdecimal|blob|boolean|break|bulk|by|byte|case|cast|catch|char|class|collect|commit|const|continue|currency|date|datetime|decimal|default|delete|desc|do|double|else|end|enum|exception|exit|export|extends|final|finally|float|for|from|get(?=\s*[{};])|global|goto|group|having|hint|if|implements|import|in|inner|insert|instanceof|int|integer|interface|into|join|like|limit|list|long|loop|map|merge|new|not|null|nulls|number|object|of|on|or|outer|override|package|parallel|pragma|private|protected|public|retrieve|return|rollback|select|set|short|sObject|sort|static|string|super|switch|synchronized|system|testmethod|then|this|throw|time|transaction|transient|trigger|try|undelete|update|upsert|using|virtual|void|webservice|when|where|while|(?:inherited|with|without)\s+sharing)\b/i,l=/\b(?:(?=[a-z_]\w*\s*[<\[])|(?!))[A-Z_]\w*(?:\s*\.\s*[A-Z_]\w*)*\b(?:\s*(?:\[\s*\]|<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>))*/.source.replace(//g,function(){return o.source});function u(p){return RegExp(p.replace(//g,function(){return l}),"i")}var c={keyword:o,punctuation:/[()\[\]{};,:.<>]/};i.languages.apex={comment:i.languages.clike.comment,string:i.languages.clike.string,sql:{pattern:/((?:[=,({:]|\breturn)\s*)\[[^\[\]]*\]/i,lookbehind:!0,greedy:!0,alias:"language-sql",inside:i.languages.sql},annotation:{pattern:/@\w+\b/,alias:"punctuation"},"class-name":[{pattern:u(/(\b(?:class|enum|extends|implements|instanceof|interface|new|trigger\s+\w+\s+on)\s+)/.source),lookbehind:!0,inside:c},{pattern:u(/(\(\s*)(?=\s*\)\s*[\w(])/.source),lookbehind:!0,inside:c},{pattern:u(/(?=\s*\w+\s*[;=,(){:])/.source),inside:c}],trigger:{pattern:/(\btrigger\s+)\w+\b/i,lookbehind:!0,alias:"class-name"},keyword:o,function:/\b[a-z_]\w*(?=\s*\()/i,boolean:/\b(?:false|true)\b/i,number:/(?:\B\.\d+|\b\d+(?:\.\d+|L)?)\b/i,operator:/[!=](?:==?)?|\?\.?|&&|\|\||--|\+\+|[-+*/^&|]=?|:|<=?|>{1,3}=?/,punctuation:/[()\[\]{};,.]/}})(n)}return Ec}var Sc,dv;function uU(){if(dv)return Sc;dv=1,Sc=e,e.displayName="apl",e.aliases=[];function e(t){t.languages.apl={comment:/(?:⍝|#[! ]).*$/m,string:{pattern:/'(?:[^'\r\n]|'')*'/,greedy:!0},number:/¯?(?:\d*\.?\b\d+(?:e[+¯]?\d+)?|¯|∞)(?:j¯?(?:(?:\d+(?:\.\d+)?|\.\d+)(?:e[+¯]?\d+)?|¯|∞))?/i,statement:/:[A-Z][a-z][A-Za-z]*\b/,"system-function":{pattern:/⎕[A-Z]+/i,alias:"function"},constant:/[⍬⌾#⎕⍞]/,function:/[-+×÷⌈⌊∣|⍳⍸?*⍟○!⌹<≤=>≥≠≡≢∊⍷∪∩~∨∧⍱⍲⍴,⍪⌽⊖⍉↑↓⊂⊃⊆⊇⌷⍋⍒⊤⊥⍕⍎⊣⊢⍁⍂≈⍯↗¤→]/,"monadic-operator":{pattern:/[\\\/⌿⍀¨⍨⌶&∥]/,alias:"operator"},"dyadic-operator":{pattern:/[.⍣⍠⍤∘⌸@⌺⍥]/,alias:"operator"},assignment:{pattern:/←/,alias:"keyword"},punctuation:/[\[;\]()◇⋄]/,dfn:{pattern:/[{}⍺⍵⍶⍹∇⍫:]/,alias:"builtin"}}}return Sc}var vc,pv;function cU(){if(pv)return vc;pv=1,vc=e,e.displayName="applescript",e.aliases=[];function e(t){t.languages.applescript={comment:[/\(\*(?:\(\*(?:[^*]|\*(?!\)))*\*\)|(?!\(\*)[\s\S])*?\*\)/,/--.+/,/#.+/],string:/"(?:\\.|[^"\\\r\n])*"/,number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e-?\d+)?\b/i,operator:[/[&=≠≤≥*+\-\/÷^]|[<>]=?/,/\b(?:(?:begin|end|start)s? with|(?:contains?|(?:does not|doesn't) contain)|(?:is|isn't|is not) (?:contained by|in)|(?:(?:is|isn't|is not) )?(?:greater|less) than(?: or equal)?(?: to)?|(?:comes|(?:does not|doesn't) come) (?:after|before)|(?:is|isn't|is not) equal(?: to)?|(?:(?:does not|doesn't) equal|equal to|equals|is not|isn't)|(?:a )?(?:ref(?: to)?|reference to)|(?:and|as|div|mod|not|or))\b/],keyword:/\b(?:about|above|after|against|apart from|around|aside from|at|back|before|beginning|behind|below|beneath|beside|between|but|by|considering|continue|copy|does|eighth|else|end|equal|error|every|exit|false|fifth|first|for|fourth|from|front|get|given|global|if|ignoring|in|instead of|into|is|it|its|last|local|me|middle|my|ninth|of|on|onto|out of|over|prop|property|put|repeat|return|returning|second|set|seventh|since|sixth|some|tell|tenth|that|the|then|third|through|thru|timeout|times|to|transaction|true|try|until|where|while|whose|with|without)\b/,"class-name":/\b(?:POSIX file|RGB color|alias|application|boolean|centimeters|centimetres|class|constant|cubic centimeters|cubic centimetres|cubic feet|cubic inches|cubic meters|cubic metres|cubic yards|date|degrees Celsius|degrees Fahrenheit|degrees Kelvin|feet|file|gallons|grams|inches|integer|kilograms|kilometers|kilometres|list|liters|litres|meters|metres|miles|number|ounces|pounds|quarts|real|record|reference|script|square feet|square kilometers|square kilometres|square meters|square metres|square miles|square yards|text|yards)\b/,punctuation:/[{}():,¬«»《》]/}}return vc}var kc,fv;function dU(){if(fv)return kc;fv=1,kc=e,e.displayName="aql",e.aliases=[];function e(t){t.languages.aql={comment:/\/\/.*|\/\*[\s\S]*?\*\//,property:{pattern:/([{,]\s*)(?:(?!\d)\w+|(["'´`])(?:(?!\2)[^\\\r\n]|\\.)*\2)(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(["'])(?:(?!\1)[^\\\r\n]|\\.)*\1/,greedy:!0},identifier:{pattern:/([´`])(?:(?!\1)[^\\\r\n]|\\.)*\1/,greedy:!0},variable:/@@?\w+/,keyword:[{pattern:/(\bWITH\s+)COUNT(?=\s+INTO\b)/i,lookbehind:!0},/\b(?:AGGREGATE|ALL|AND|ANY|ASC|COLLECT|DESC|DISTINCT|FILTER|FOR|GRAPH|IN|INBOUND|INSERT|INTO|K_PATHS|K_SHORTEST_PATHS|LET|LIKE|LIMIT|NONE|NOT|NULL|OR|OUTBOUND|REMOVE|REPLACE|RETURN|SHORTEST_PATH|SORT|UPDATE|UPSERT|WINDOW|WITH)\b/i,{pattern:/(^|[^\w.[])(?:KEEP|PRUNE|SEARCH|TO)\b/i,lookbehind:!0},{pattern:/(^|[^\w.[])(?:CURRENT|NEW|OLD)\b/,lookbehind:!0},{pattern:/\bOPTIONS(?=\s*\{)/i}],function:/\b(?!\d)\w+(?=\s*\()/,boolean:/\b(?:false|true)\b/i,range:{pattern:/\.\./,alias:"operator"},number:[/\b0b[01]+/i,/\b0x[0-9a-f]+/i,/(?:\B\.\d+|\b(?:0|[1-9]\d*)(?:\.\d+)?)(?:e[+-]?\d+)?/i],operator:/\*{2,}|[=!]~|[!=<>]=?|&&|\|\||[-+*/%]/,punctuation:/::|[?.:,;()[\]{}]/}}return kc}var _c,gv;function Yr(){if(gv)return _c;gv=1,_c=e,e.displayName="c",e.aliases=[];function e(t){t.languages.c=t.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),t.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),t.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},t.languages.c.string],char:t.languages.c.char,comment:t.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:t.languages.c}}}}),t.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete t.languages.c.boolean}return _c}var wc,mv;function fh(){if(mv)return wc;mv=1;var e=Yr();wc=t,t.displayName="cpp",t.aliases=[];function t(n){n.register(e),(function(i){var o=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,l=/\b(?!)\w+(?:\s*\.\s*\w+)*\b/.source.replace(//g,function(){return o.source});i.languages.cpp=i.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!)\w+/.source.replace(//g,function(){return o.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:o,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),i.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/(?:\s*:\s*)?|:\s*/.source.replace(//g,function(){return l})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),i.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:i.languages.cpp}}}}),i.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),i.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:i.languages.extend("cpp",{})}}),i.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},i.languages.cpp["base-clause"])})(n)}return wc}var Tc,hv;function pU(){if(hv)return Tc;hv=1;var e=fh();Tc=t,t.displayName="arduino",t.aliases=["ino"];function t(n){n.register(e),n.languages.arduino=n.languages.extend("cpp",{keyword:/\b(?:String|array|bool|boolean|break|byte|case|catch|continue|default|do|double|else|finally|for|function|goto|if|in|instanceof|int|integer|long|loop|new|null|return|setup|string|switch|throw|try|void|while|word)\b/,constant:/\b(?:ANALOG_MESSAGE|DEFAULT|DIGITAL_MESSAGE|EXTERNAL|FIRMATA_STRING|HIGH|INPUT|INPUT_PULLUP|INTERNAL|INTERNAL1V1|INTERNAL2V56|LED_BUILTIN|LOW|OUTPUT|REPORT_ANALOG|REPORT_DIGITAL|SET_PIN_MODE|SYSEX_START|SYSTEM_RESET)\b/,builtin:/\b(?:Audio|BSSID|Bridge|Client|Console|EEPROM|Esplora|EsploraTFT|Ethernet|EthernetClient|EthernetServer|EthernetUDP|File|FileIO|FileSystem|Firmata|GPRS|GSM|GSMBand|GSMClient|GSMModem|GSMPIN|GSMScanner|GSMServer|GSMVoiceCall|GSM_SMS|HttpClient|IPAddress|IRread|Keyboard|KeyboardController|LiquidCrystal|LiquidCrystal_I2C|Mailbox|Mouse|MouseController|PImage|Process|RSSI|RobotControl|RobotMotor|SD|SPI|SSID|Scheduler|Serial|Server|Servo|SoftwareSerial|Stepper|Stream|TFT|Task|USBHost|WiFi|WiFiClient|WiFiServer|WiFiUDP|Wire|YunClient|YunServer|abs|addParameter|analogRead|analogReadResolution|analogReference|analogWrite|analogWriteResolution|answerCall|attach|attachGPRS|attachInterrupt|attached|autoscroll|available|background|beep|begin|beginPacket|beginSD|beginSMS|beginSpeaker|beginTFT|beginTransmission|beginWrite|bit|bitClear|bitRead|bitSet|bitWrite|blink|blinkVersion|buffer|changePIN|checkPIN|checkPUK|checkReg|circle|cityNameRead|cityNameWrite|clear|clearScreen|click|close|compassRead|config|connect|connected|constrain|cos|countryNameRead|countryNameWrite|createChar|cursor|debugPrint|delay|delayMicroseconds|detach|detachInterrupt|digitalRead|digitalWrite|disconnect|display|displayLogos|drawBMP|drawCompass|encryptionType|end|endPacket|endSMS|endTransmission|endWrite|exists|exitValue|fill|find|findUntil|flush|gatewayIP|get|getAsynchronously|getBand|getButton|getCurrentCarrier|getIMEI|getKey|getModifiers|getOemKey|getPINUsed|getResult|getSignalStrength|getSocket|getVoiceCallStatus|getXChange|getYChange|hangCall|height|highByte|home|image|interrupts|isActionDone|isDirectory|isListening|isPIN|isPressed|isValid|keyPressed|keyReleased|keyboardRead|knobRead|leftToRight|line|lineFollowConfig|listen|listenOnLocalhost|loadImage|localIP|lowByte|macAddress|maintain|map|max|messageAvailable|micros|millis|min|mkdir|motorsStop|motorsWrite|mouseDragged|mouseMoved|mousePressed|mouseReleased|move|noAutoscroll|noBlink|noBuffer|noCursor|noDisplay|noFill|noInterrupts|noListenOnLocalhost|noStroke|noTone|onReceive|onRequest|open|openNextFile|overflow|parseCommand|parseFloat|parseInt|parsePacket|pauseMode|peek|pinMode|playFile|playMelody|point|pointTo|position|pow|prepare|press|print|printFirmwareVersion|printVersion|println|process|processInput|pulseIn|put|random|randomSeed|read|readAccelerometer|readBlue|readButton|readBytes|readBytesUntil|readGreen|readJoystickButton|readJoystickSwitch|readJoystickX|readJoystickY|readLightSensor|readMessage|readMicrophone|readNetworks|readRed|readSlider|readString|readStringUntil|readTemperature|ready|rect|release|releaseAll|remoteIP|remoteNumber|remotePort|remove|requestFrom|retrieveCallingNumber|rewindDirectory|rightToLeft|rmdir|robotNameRead|robotNameWrite|run|runAsynchronously|runShellCommand|runShellCommandAsynchronously|running|scanNetworks|scrollDisplayLeft|scrollDisplayRight|seek|sendAnalog|sendDigitalPortPair|sendDigitalPorts|sendString|sendSysex|serialEvent|setBand|setBitOrder|setClockDivider|setCursor|setDNS|setDataMode|setFirmwareVersion|setMode|setPINUsed|setSpeed|setTextSize|setTimeout|shiftIn|shiftOut|shutdown|sin|size|sqrt|startLoop|step|stop|stroke|subnetMask|switchPIN|tan|tempoWrite|text|tone|transfer|tuneWrite|turn|updateIR|userNameRead|userNameWrite|voiceCall|waitContinue|width|write|writeBlue|writeGreen|writeJSON|writeMessage|writeMicroseconds|writeRGB|writeRed|yield)\b/}),n.languages.ino=n.languages.arduino}return Tc}var xc,bv;function fU(){if(bv)return xc;bv=1,xc=e,e.displayName="arff",e.aliases=[];function e(t){t.languages.arff={comment:/%.*/,string:{pattern:/(["'])(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},keyword:/@(?:attribute|data|end|relation)\b/i,number:/\b\d+(?:\.\d+)?\b/,punctuation:/[{},]/}}return xc}var Ac,yv;function gU(){if(yv)return Ac;yv=1,Ac=e,e.displayName="asciidoc",e.aliases=["adoc"];function e(t){(function(n){var i={pattern:/(^[ \t]*)\[(?!\[)(?:(["'$`])(?:(?!\2)[^\\]|\\.)*\2|\[(?:[^\[\]\\]|\\.)*\]|[^\[\]\\"'$`]|\\.)*\]/m,lookbehind:!0,inside:{quoted:{pattern:/([$`])(?:(?!\1)[^\\]|\\.)*\1/,inside:{punctuation:/^[$`]|[$`]$/}},interpreted:{pattern:/'(?:[^'\\]|\\.)*'/,inside:{punctuation:/^'|'$/}},string:/"(?:[^"\\]|\\.)*"/,variable:/\w+(?==)/,punctuation:/^\[|\]$|,/,operator:/=/,"attr-value":/(?!^\s+$).+/}},o=n.languages.asciidoc={"comment-block":{pattern:/^(\/{4,})(?:\r?\n|\r)(?:[\s\S]*(?:\r?\n|\r))??\1/m,alias:"comment"},table:{pattern:/^\|={3,}(?:(?:\r?\n|\r(?!\n)).*)*?(?:\r?\n|\r)\|={3,}$/m,inside:{specifiers:{pattern:/(?:(?:(?:\d+(?:\.\d+)?|\.\d+)[+*](?:[<^>](?:\.[<^>])?|\.[<^>])?|[<^>](?:\.[<^>])?|\.[<^>])[a-z]*|[a-z]+)(?=\|)/,alias:"attr-value"},punctuation:{pattern:/(^|[^\\])[|!]=*/,lookbehind:!0}}},"passthrough-block":{pattern:/^(\+{4,})(?:\r?\n|\r)(?:[\s\S]*(?:\r?\n|\r))??\1$/m,inside:{punctuation:/^\++|\++$/}},"literal-block":{pattern:/^(-{4,}|\.{4,})(?:\r?\n|\r)(?:[\s\S]*(?:\r?\n|\r))??\1$/m,inside:{punctuation:/^(?:-+|\.+)|(?:-+|\.+)$/}},"other-block":{pattern:/^(--|\*{4,}|_{4,}|={4,})(?:\r?\n|\r)(?:[\s\S]*(?:\r?\n|\r))??\1$/m,inside:{punctuation:/^(?:-+|\*+|_+|=+)|(?:-+|\*+|_+|=+)$/}},"list-punctuation":{pattern:/(^[ \t]*)(?:-|\*{1,5}|\.{1,5}|(?:[a-z]|\d+)\.|[xvi]+\))(?= )/im,lookbehind:!0,alias:"punctuation"},"list-label":{pattern:/(^[ \t]*)[a-z\d].+(?::{2,4}|;;)(?=\s)/im,lookbehind:!0,alias:"symbol"},"indented-block":{pattern:/((\r?\n|\r)\2)([ \t]+)\S.*(?:(?:\r?\n|\r)\3.+)*(?=\2{2}|$)/,lookbehind:!0},comment:/^\/\/.*/m,title:{pattern:/^.+(?:\r?\n|\r)(?:={3,}|-{3,}|~{3,}|\^{3,}|\+{3,})$|^={1,5} .+|^\.(?![\s.]).*/m,alias:"important",inside:{punctuation:/^(?:\.|=+)|(?:=+|-+|~+|\^+|\++)$/}},"attribute-entry":{pattern:/^:[^:\r\n]+:(?: .*?(?: \+(?:\r?\n|\r).*?)*)?$/m,alias:"tag"},attributes:i,hr:{pattern:/^'{3,}$/m,alias:"punctuation"},"page-break":{pattern:/^<{3,}$/m,alias:"punctuation"},admonition:{pattern:/^(?:CAUTION|IMPORTANT|NOTE|TIP|WARNING):/m,alias:"keyword"},callout:[{pattern:/(^[ \t]*)\d*>/m,lookbehind:!0,alias:"symbol"},{pattern:/<\d+>/,alias:"symbol"}],macro:{pattern:/\b[a-z\d][a-z\d-]*::?(?:[^\s\[\]]*\[(?:[^\]\\"']|(["'])(?:(?!\1)[^\\]|\\.)*\1|\\.)*\])/,inside:{function:/^[a-z\d-]+(?=:)/,punctuation:/^::?/,attributes:{pattern:/(?:\[(?:[^\]\\"']|(["'])(?:(?!\1)[^\\]|\\.)*\1|\\.)*\])/,inside:i.inside}}},inline:{pattern:/(^|[^\\])(?:(?:\B\[(?:[^\]\\"']|(["'])(?:(?!\2)[^\\]|\\.)*\2|\\.)*\])?(?:\b_(?!\s)(?: _|[^_\\\r\n]|\\.)+(?:(?:\r?\n|\r)(?: _|[^_\\\r\n]|\\.)+)*_\b|\B``(?!\s).+?(?:(?:\r?\n|\r).+?)*''\B|\B`(?!\s)(?:[^`'\s]|\s+\S)+['`]\B|\B(['*+#])(?!\s)(?: \3|(?!\3)[^\\\r\n]|\\.)+(?:(?:\r?\n|\r)(?: \3|(?!\3)[^\\\r\n]|\\.)+)*\3\B)|(?:\[(?:[^\]\\"']|(["'])(?:(?!\4)[^\\]|\\.)*\4|\\.)*\])?(?:(__|\*\*|\+\+\+?|##|\$\$|[~^]).+?(?:(?:\r?\n|\r).+?)*\5|\{[^}\r\n]+\}|\[\[\[?.+?(?:(?:\r?\n|\r).+?)*\]?\]\]|<<.+?(?:(?:\r?\n|\r).+?)*>>|\(\(\(?.+?(?:(?:\r?\n|\r).+?)*\)?\)\)))/m,lookbehind:!0,inside:{attributes:i,url:{pattern:/^(?:\[\[\[?.+?\]?\]\]|<<.+?>>)$/,inside:{punctuation:/^(?:\[\[\[?|<<)|(?:\]\]\]?|>>)$/}},"attribute-ref":{pattern:/^\{.+\}$/,inside:{variable:{pattern:/(^\{)[a-z\d,+_-]+/,lookbehind:!0},operator:/^[=?!#%@$]|!(?=[:}])/,punctuation:/^\{|\}$|::?/}},italic:{pattern:/^(['_])[\s\S]+\1$/,inside:{punctuation:/^(?:''?|__?)|(?:''?|__?)$/}},bold:{pattern:/^\*[\s\S]+\*$/,inside:{punctuation:/^\*\*?|\*\*?$/}},punctuation:/^(?:``?|\+{1,3}|##?|\$\$|[~^]|\(\(\(?)|(?:''?|\+{1,3}|##?|\$\$|[~^`]|\)?\)\))$/}},replacement:{pattern:/\((?:C|R|TM)\)/,alias:"builtin"},entity:/?[\da-z]{1,8};/i,"line-continuation":{pattern:/(^| )\+$/m,lookbehind:!0,alias:"punctuation"}};function l(u){u=u.split(" ");for(var c={},p=0,f=u.length;p>=?|<<=?|&&?|\|\|?|[-+*/%&|^!=<>?]=?/,punctuation:/[(),:]/}}return Nc}var Cc,vv;function ks(){if(vv)return Cc;vv=1,Cc=e,e.displayName="csharp",e.aliases=["dotnet","cs"];function e(t){(function(n){function i(D,$){return D.replace(/<<(\d+)>>/g,function(C,ae){return"(?:"+$[+ae]+")"})}function o(D,$,C){return RegExp(i(D,$),"")}function l(D,$){for(var C=0;C<$;C++)D=D.replace(/<>/g,function(){return"(?:"+D+")"});return D.replace(/<>/g,"[^\\s\\S]")}var u={type:"bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void",typeDeclaration:"class enum interface record struct",contextual:"add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)",other:"abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield"};function c(D){return"\\b(?:"+D.trim().replace(/ /g,"|")+")\\b"}var p=c(u.typeDeclaration),f=RegExp(c(u.type+" "+u.typeDeclaration+" "+u.contextual+" "+u.other)),m=c(u.typeDeclaration+" "+u.contextual+" "+u.other),h=c(u.type+" "+u.typeDeclaration+" "+u.other),S=l(/<(?:[^<>;=+\-*/%&|^]|<>)*>/.source,2),E=l(/\((?:[^()]|<>)*\)/.source,2),v=/@?\b[A-Za-z_]\w*\b/.source,k=i(/<<0>>(?:\s*<<1>>)?/.source,[v,S]),T=i(/(?!<<0>>)<<1>>(?:\s*\.\s*<<1>>)*/.source,[m,k]),N=/\[\s*(?:,\s*)*\]/.source,R=i(/<<0>>(?:\s*(?:\?\s*)?<<1>>)*(?:\s*\?)?/.source,[T,N]),A=i(/[^,()<>[\];=+\-*/%&|^]|<<0>>|<<1>>|<<2>>/.source,[S,E,N]),O=i(/\(<<0>>+(?:,<<0>>+)+\)/.source,[A]),L=i(/(?:<<0>>|<<1>>)(?:\s*(?:\?\s*)?<<2>>)*(?:\s*\?)?/.source,[O,T,N]),w={keyword:f,punctuation:/[<>()?,.:[\]]/},B=/'(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'/.source,W=/"(?:\\.|[^\\"\r\n])*"/.source,j=/@"(?:""|\\[\s\S]|[^\\"])*"(?!")/.source;n.languages.csharp=n.languages.extend("clike",{string:[{pattern:o(/(^|[^$\\])<<0>>/.source,[j]),lookbehind:!0,greedy:!0},{pattern:o(/(^|[^@$\\])<<0>>/.source,[W]),lookbehind:!0,greedy:!0}],"class-name":[{pattern:o(/(\busing\s+static\s+)<<0>>(?=\s*;)/.source,[T]),lookbehind:!0,inside:w},{pattern:o(/(\busing\s+<<0>>\s*=\s*)<<1>>(?=\s*;)/.source,[v,L]),lookbehind:!0,inside:w},{pattern:o(/(\busing\s+)<<0>>(?=\s*=)/.source,[v]),lookbehind:!0},{pattern:o(/(\b<<0>>\s+)<<1>>/.source,[p,k]),lookbehind:!0,inside:w},{pattern:o(/(\bcatch\s*\(\s*)<<0>>/.source,[T]),lookbehind:!0,inside:w},{pattern:o(/(\bwhere\s+)<<0>>/.source,[v]),lookbehind:!0},{pattern:o(/(\b(?:is(?:\s+not)?|as)\s+)<<0>>/.source,[R]),lookbehind:!0,inside:w},{pattern:o(/\b<<0>>(?=\s+(?!<<1>>|with\s*\{)<<2>>(?:\s*[=,;:{)\]]|\s+(?:in|when)\b))/.source,[L,h,v]),inside:w}],keyword:f,number:/(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,operator:/>>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,punctuation:/\?\.?|::|[{}[\];(),.:]/}),n.languages.insertBefore("csharp","number",{range:{pattern:/\.\./,alias:"operator"}}),n.languages.insertBefore("csharp","punctuation",{"named-parameter":{pattern:o(/([(,]\s*)<<0>>(?=\s*:)/.source,[v]),lookbehind:!0,alias:"punctuation"}}),n.languages.insertBefore("csharp","class-name",{namespace:{pattern:o(/(\b(?:namespace|using)\s+)<<0>>(?:\s*\.\s*<<0>>)*(?=\s*[;{])/.source,[v]),lookbehind:!0,inside:{punctuation:/\./}},"type-expression":{pattern:o(/(\b(?:default|sizeof|typeof)\s*\(\s*(?!\s))(?:[^()\s]|\s(?!\s)|<<0>>)*(?=\s*\))/.source,[E]),lookbehind:!0,alias:"class-name",inside:w},"return-type":{pattern:o(/<<0>>(?=\s+(?:<<1>>\s*(?:=>|[({]|\.\s*this\s*\[)|this\s*\[))/.source,[L,T]),inside:w,alias:"class-name"},"constructor-invocation":{pattern:o(/(\bnew\s+)<<0>>(?=\s*[[({])/.source,[L]),lookbehind:!0,inside:w,alias:"class-name"},"generic-method":{pattern:o(/<<0>>\s*<<1>>(?=\s*\()/.source,[v,S]),inside:{function:o(/^<<0>>/.source,[v]),generic:{pattern:RegExp(S),alias:"class-name",inside:w}}},"type-list":{pattern:o(/\b((?:<<0>>\s+<<1>>|record\s+<<1>>\s*<<5>>|where\s+<<2>>)\s*:\s*)(?:<<3>>|<<4>>|<<1>>\s*<<5>>|<<6>>)(?:\s*,\s*(?:<<3>>|<<4>>|<<6>>))*(?=\s*(?:where|[{;]|=>|$))/.source,[p,k,v,L,f.source,E,/\bnew\s*\(\s*\)/.source]),lookbehind:!0,inside:{"record-arguments":{pattern:o(/(^(?!new\s*\()<<0>>\s*)<<1>>/.source,[k,E]),lookbehind:!0,greedy:!0,inside:n.languages.csharp},keyword:f,"class-name":{pattern:RegExp(L),greedy:!0,inside:w},punctuation:/[,()]/}},preprocessor:{pattern:/(^[\t ]*)#.*/m,lookbehind:!0,alias:"property",inside:{directive:{pattern:/(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,lookbehind:!0,alias:"keyword"}}}});var M=W+"|"+B,Y=i(/\/(?![*/])|\/\/[^\r\n]*[\r\n]|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>/.source,[M]),J=l(i(/[^"'/()]|<<0>>|\(<>*\)/.source,[Y]),2),de=/\b(?:assembly|event|field|method|module|param|property|return|type)\b/.source,Z=i(/<<0>>(?:\s*\(<<1>>*\))?/.source,[T,J]);n.languages.insertBefore("csharp","class-name",{attribute:{pattern:o(/((?:^|[^\s\w>)?])\s*\[\s*)(?:<<0>>\s*:\s*)?<<1>>(?:\s*,\s*<<1>>)*(?=\s*\])/.source,[de,Z]),lookbehind:!0,greedy:!0,inside:{target:{pattern:o(/^<<0>>(?=\s*:)/.source,[de]),alias:"keyword"},"attribute-arguments":{pattern:o(/\(<<0>>*\)/.source,[J]),inside:n.languages.csharp},"class-name":{pattern:RegExp(T),inside:{punctuation:/\./}},punctuation:/[:,]/}}});var H=/:[^}\r\n]+/.source,te=l(i(/[^"'/()]|<<0>>|\(<>*\)/.source,[Y]),2),ue=i(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[te,H]),q=l(i(/[^"'/()]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>|\(<>*\)/.source,[M]),2),Q=i(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[q,H]);function x(D,$){return{interpolation:{pattern:o(/((?:^|[^{])(?:\{\{)*)<<0>>/.source,[D]),lookbehind:!0,inside:{"format-string":{pattern:o(/(^\{(?:(?![}:])<<0>>)*)<<1>>(?=\}$)/.source,[$,H]),lookbehind:!0,inside:{punctuation:/^:/}},punctuation:/^\{|\}$/,expression:{pattern:/[\s\S]+/,alias:"language-csharp",inside:n.languages.csharp}}},string:/[\s\S]+/}}n.languages.insertBefore("csharp","string",{"interpolation-string":[{pattern:o(/(^|[^\\])(?:\$@|@\$)"(?:""|\\[\s\S]|\{\{|<<0>>|[^\\{"])*"/.source,[ue]),lookbehind:!0,greedy:!0,inside:x(ue,te)},{pattern:o(/(^|[^@\\])\$"(?:\\.|\{\{|<<0>>|[^\\"{])*"/.source,[Q]),lookbehind:!0,greedy:!0,inside:x(Q,q)}],char:{pattern:RegExp(B),greedy:!0}}),n.languages.dotnet=n.languages.cs=n.languages.csharp})(t)}return Cc}var Ic,kv;function bU(){if(kv)return Ic;kv=1;var e=ks();Ic=t,t.displayName="aspnet",t.aliases=[];function t(n){n.register(e),n.languages.aspnet=n.languages.extend("markup",{"page-directive":{pattern:/<%\s*@.*%>/,alias:"tag",inside:{"page-directive":{pattern:/<%\s*@\s*(?:Assembly|Control|Implements|Import|Master(?:Type)?|OutputCache|Page|PreviousPageType|Reference|Register)?|%>/i,alias:"tag"},rest:n.languages.markup.tag.inside}},directive:{pattern:/<%.*%>/,alias:"tag",inside:{directive:{pattern:/<%\s*?[$=%#:]{0,2}|%>/,alias:"tag"},rest:n.languages.csharp}}}),n.languages.aspnet.tag.pattern=/<(?!%)\/?[^\s>\/]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|[^\s'">=]+))?)*\s*\/?>/,n.languages.insertBefore("inside","punctuation",{directive:n.languages.aspnet.directive},n.languages.aspnet.tag.inside["attr-value"]),n.languages.insertBefore("aspnet","comment",{"asp-comment":{pattern:/<%--[\s\S]*?--%>/,alias:["asp","comment"]}}),n.languages.insertBefore("aspnet",n.languages.javascript?"script":"tag",{"asp-script":{pattern:/(
+
diff --git a/src/mobile-web/index.html b/src/mobile-web/index.html
index 4501cddb..e7dfcb0f 100644
--- a/src/mobile-web/index.html
+++ b/src/mobile-web/index.html
@@ -9,8 +9,8 @@
-
-
+
+
Sparo OS
+