An agentic browser harness: an AI side panel & orb in your own logged-in Chrome, Edge, Arc, Brave or even Firefox run by the agent/subscription you already use (Claude Code, Codex, Antigravity). Free, open source, no API key. Also an MCP server.
TypeScript agentic-browseragentic-browsingagy-cliaiai-agentai-browser-extensionai-toolsbrave-extensionbrowser-agentbrowser-automationbrowser-extensionbrowser-usebrowserskillchrome-extensionclaude-codecodexfirefox-addonmcp-servernanobrowserweb-automation
feat(windows): a Windows app with the macOS app's screens and behaviour — the preflight that installs Node, the command and the extension in one press, the seven tabs, a tray icon for the menu-bar one, an updater, and a browsentic.exe launcher on the PATH — built with Tauri, sharing the extension's palette, guardrail rows and theme picker
Shahriar8528f9d98040
diff --git a/.gitignore b/.gitignoreindex 0856a6c..013be11 100644--- a/.gitignore+++ b/.gitignore@@ -24,6 +24,13 @@ coverage/# `dist/` rule above already covers.src/mac/.build/+# The Windows app's Cargo build tree, the payload it carries (staged from the extension and daemon+# builds by scripts/windows-payload.ts), and the schemas Tauri generates. Its UI builds to+# src/windows/dist/, which the `dist/` rule covers.+src/windows/target/+src/windows/src-tauri/resources/+src/windows/src-tauri/gen/+# WXT generated types + bundle stats.wxt/stats.htmldiff --git a/package.json b/package.jsonindex 84f1acb..b9dd7a3 100644--- a/package.json+++ b/package.json@@ -31,12 +31,20 @@"daemon:link": "cd src/daemon && npm link","daemon:unlink": "npm rm -g browsentic @browsentic/mcp","mac:app": "yarn build && yarn daemon:build && src/mac/Scripts/build-app.sh",- "mac:dmg": "yarn mac:app && src/mac/Scripts/make-dmg.sh"+ "mac:dmg": "yarn mac:app && src/mac/Scripts/make-dmg.sh",+ "win:ui": "vite build src/windows",+ "win:ui:dev": "vite src/windows",+ "win:preview": "vite src/windows --open",+ "win:dev": "tauri dev",+ "win:payload": "node scripts/windows-payload.ts",+ "win:app": "yarn build && yarn daemon:build && tauri build"},"dependencies": {"@radix-ui/react-scroll-area": "^1.2.16","@radix-ui/react-select": "^2.3.7","@radix-ui/react-slot": "^1.3.1",+ "@tauri-apps/api": "^2.12.0",+ "@tauri-apps/plugin-opener": "^2.5.5","class-variance-authority": "^0.7.1","clsx": "^2.1.1","lucide-react": "^1.26.0",@@ -47,14 +55,17 @@},"devDependencies": {"@tailwindcss/vite": "^4.3.3",+ "@tauri-apps/cli": "^2.11.5","@types/react": "^19.2.17","@types/react-dom": "^19.2.3",+ "@vitejs/plugin-react": "^6.1.1","@vitest/coverage-v8": "^5.0.1","@wxt-dev/module-react": "^1.2.2","happy-dom": "^20.14.5","tailwindcss": "^4.3.3","tw-animate-css": "^1.4.0","typescript": "^7.0.2",+ "vite": "^8.0.0","vitest": "^5.0.1","web-ext": "^10.6.0","wxt": "^0.20.27"diff --git a/scripts/windows-payload.ts b/scripts/windows-payload.tsnew file mode 100644index 0000000..4f8e000--- /dev/null+++ b/scripts/windows-payload.ts@@ -0,0 +1,56 @@+// Stages what the Windows app carries, the way src/mac/Scripts/build-app.sh stages the macOS one:+// the npm package's layout under resources/payload (cli.js resolves ../skills and ../extension+// from dist/), and the browsentic.exe launcher under resources/launcher. Tauri runs it before every+// build, with the target it is building for in TAURI_ENV_TARGET_TRIPLE.+//+// It builds nothing of the extension or the daemon: `yarn build && yarn daemon:build` come first,+// and a payload whose versions disagree is refused rather than shipped.++import { execFileSync } from 'node:child_process';+import { cpSync, existsSync, mkdirSync, readFileSync, rmSync } from 'node:fs';+import { join } from 'node:path';+import { fileURLToPath } from 'node:url';++const root = fileURLToPath(new URL('..', import.meta.url));+const daemon = join(root, 'src/daemon');+const extension = join(root, 'dist/chrome-mv3');+const workspace = join(root, 'src/windows');+const resources = join(workspace, 'src-tauri/resources');++function die(problem: string, fix: string): never {+ console.error(`windows-payload: ${problem}\n ${fix}`);+ process.exit(1);+}++const versionOf = (manifest: string) => JSON.parse(readFileSync(manifest, 'utf8')).version as string;++if (!existsSync(join(extension, 'manifest.json'))) die('no extension build at dist/chrome-mv3', 'Run `yarn build` at the repository root first.');+if (!existsSync(join(daemon, 'dist/cli.js'))) die('no daemon build at src/daemon/dist/cli.js', 'Run `yarn daemon:build` first.');++const version = versionOf(join(daemon, 'package.json'));+const built = versionOf(join(extension, 'manifest.json'));+if (built !== version) die(`the built extension is ${built} but the package is ${version}`, 'Rebuild it after bumping the version: `yarn build`.');+if (!readFileSync(join(daemon, 'dist/cli.js'), 'utf8').includes(`"${version}"`)) {+ die(`src/daemon/dist/cli.js was not built from ${version}`, 'Run `yarn daemon:build`.');+}++rmSync(resources, { recursive: true, force: true });+const payload = join(resources, 'payload');+mkdirSync(join(payload, 'dist'), { recursive: true });+for (const file of ['cli.js', 'daemon-main.js']) cpSync(join(daemon, 'dist', file), join(payload, 'dist', file));+cpSync(join(daemon, 'skills'), join(payload, 'skills'), { recursive: true });+cpSync(extension, join(payload, 'extension/chrome-mv3'), { recursive: true });+for (const file of ['package.json', 'LICENSE']) cpSync(join(daemon, file), join(payload, file));++const target = process.env.TAURI_ENV_TARGET_TRIPLE;+const forWindows = target ? target.includes('windows') : process.platform === 'win32';+const crossing = forWindows && process.platform !== 'win32';+const cargo = [...(crossing ? ['xwin'] : []), 'build', '--release', '--package', 'browsentic-launcher', ...(target ? ['--target', target] : [])];+execFileSync('cargo', cargo, { cwd: workspace, stdio: 'inherit', env: { ...process.env, XWIN_ACCEPT_LICENSE: process.env.XWIN_ACCEPT_LICENSE ?? '1' } });++const launcher = forWindows ? 'browsentic.exe' : 'browsentic';+const release = join(workspace, 'target', target ?? '', 'release', launcher);+mkdirSync(join(resources, 'launcher'), { recursive: true });+cpSync(release, join(resources, 'launcher', launcher));++console.log(`windows-payload: v${version} staged for ${target ?? 'this machine'}`);diff --git a/src/windows/Cargo.lock b/src/windows/Cargo.locknew file mode 100644index 0000000..427270a--- /dev/null+++ b/src/windows/Cargo.lock@@ -0,0 +1,5650 @@+# This file is automatically @generated by Cargo.+# It is not intended for manual editing.+version = 4++[[package]]+name = "adler2"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa"++[[package]]+name = "aho-corasick"+version = "1.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c982642fa9e8606056828ee9a8505737230110bb1099153c79efe865c59d12ba"+dependencies = [+ "memchr",+]++[[package]]+name = "alloc-no-stdlib"+version = "3.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c2fb6cfd47bf496ff64095c20eaba0c201404ee38714d4142fcfa1dc334fcc7a"++[[package]]+name = "alloc-stdlib"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0b5c1865780388bfa186411ab5f247819487fc4864c6e9c3106611fa347586e1"+dependencies = [+ "alloc-no-stdlib",+]++[[package]]+name = "android_system_properties"+version = "0.1.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ae221649c9976a6f6c56ae1facf410f3ddb33cc661c4b7b61020a912d4237fbc"+dependencies = [+ "libc",+]++[[package]]+name = "anyhow"+version = "1.0.104"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "330a5ed07fa54e4702c9d6c4174f74427fc0ef6e214bbd677ae50a5099946470"++[[package]]+name = "async-broadcast"+version = "0.7.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "435a87a52755b8f27fcf321ac4f04b2802e337c8c4872923137471ec39c37532"+dependencies = [+ "event-listener",+ "event-listener-strategy",+ "futures-core",+ "pin-project-lite",+]++[[package]]+name = "async-channel"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "924ed96dd52d1b75e9c1a3e6275715fd320f5f9439fb5a4a11fa51f4221158d2"+dependencies = [+ "concurrent-queue",+ "event-listener-strategy",+ "futures-core",+ "pin-project-lite",+]++[[package]]+name = "async-executor"+version = "1.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c96bf972d85afc50bf5ab8fe2d54d1586b4e0b46c97c50a0c9e71e2f7bcd812a"+dependencies = [+ "async-task",+ "concurrent-queue",+ "fastrand",+ "futures-lite",+ "pin-project-lite",+ "slab",+]++[[package]]+name = "async-io"+version = "2.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "456b8a8feb6f42d237746d4b3e9a178494627745c3c56c6ea55d92ba50d026fc"+dependencies = [+ "autocfg",+ "cfg-if",+ "concurrent-queue",+ "futures-io",+ "futures-lite",+ "parking",+ "polling",+ "rustix",+ "slab",+ "windows-sys 0.61.2",+]++[[package]]+name = "async-lock"+version = "3.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "290f7f2596bd5b78a9fec8088ccd89180d7f9f55b94b0576823bbbdc72ee8311"+dependencies = [+ "event-listener",+ "event-listener-strategy",+ "pin-project-lite",+]++[[package]]+name = "async-process"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc50921ec0055cdd8a16de48773bfeec5c972598674347252c0399676be7da75"+dependencies = [+ "async-channel",+ "async-io",+ "async-lock",+ "async-signal",+ "async-task",+ "blocking",+ "cfg-if",+ "event-listener",+ "futures-lite",+ "rustix",+]++[[package]]+name = "async-recursion"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "async-signal"+version = "0.2.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "52b5aaafa020cf5053a01f2a60e8ff5dccf550f0f77ec54a4e47285ac2bab485"+dependencies = [+ "async-io",+ "async-lock",+ "atomic-waker",+ "cfg-if",+ "futures-core",+ "futures-io",+ "rustix",+ "signal-hook-registry",+ "slab",+ "windows-sys 0.61.2",+]++[[package]]+name = "async-task"+version = "4.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8b75356056920673b02621b35afd0f7dda9306d03c79a30f5c56c44cf256e3de"++[[package]]+name = "async-trait"+version = "0.1.92"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "82f6aeea286b8eb4dd3431a1be1b59d290ace00f5bfd8e2a159bc2a05e2c1667"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "atk"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "241b621213072e993be4f6f3a9e4b45f65b7e6faad43001be957184b7bb1824b"+dependencies = [+ "atk-sys",+ "glib",+ "libc",+]++[[package]]+name = "atk-sys"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c5e48b684b0ca77d2bbadeef17424c2ea3c897d44d566a1617e7e8f30614d086"+dependencies = [+ "glib-sys",+ "gobject-sys",+ "libc",+ "system-deps",+]++[[package]]+name = "atomic-waker"+version = "1.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0"++[[package]]+name = "autocfg"+version = "1.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53"++[[package]]+name = "base64"+version = "0.21.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567"++[[package]]+name = "base64"+version = "0.22.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6"++[[package]]+name = "base64"+version = "0.23.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ac07cdecf99051d9a5238b80f35af32cdeba5b336e55d957b318b50137e18da5"++[[package]]+name = "bit-set"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "08807e080ed7f9d5433fa9b275196cfc35414f66a0c79d864dc51a0d825231a3"+dependencies = [+ "bit-vec",+]++[[package]]+name = "bit-vec"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7"++[[package]]+name = "bitflags"+version = "1.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a"++[[package]]+name = "bitflags"+version = "2.13.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3ded4057c258ba199e2d26386d3af3780957ecaee6c4ef4041c6b4b8b97c0b06"+dependencies = [+ "serde_core",+]++[[package]]+name = "block-buffer"+version = "0.10.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71"+dependencies = [+ "generic-array",+]++[[package]]+name = "block-buffer"+version = "0.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d2f6c7dbe95a6ed67ad9f18e57daf93a2f034c524b99fd2b76d18fdfeb6660aa"+dependencies = [+ "hybrid-array",+]++[[package]]+name = "block2"+version = "0.6.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cdeb9d870516001442e364c5220d3574d2da8dc765554b4a617230d33fa58ef5"+dependencies = [+ "objc2",+]++[[package]]+name = "blocking"+version = "1.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a70e4329df6cb94385eed412ec92375c3cdd8a6e502493d1229b6414e4036dfa"+dependencies = [+ "async-channel",+ "async-task",+ "futures-io",+ "futures-lite",+ "piper",+]++[[package]]+name = "brotli"+version = "9.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f8b851b75c23ca7873623d612fe49bd1989aeb03d08fb9432187eb253d3d4c6b"+dependencies = [+ "alloc-no-stdlib",+ "alloc-stdlib",+ "brotli-decompressor",+]++[[package]]+name = "brotli-decompressor"+version = "6.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "941cd9bd4ddab83cb46fa5a2d428f1c857b24ac78cb876cf7beb710840934bd7"+dependencies = [+ "alloc-no-stdlib",+ "alloc-stdlib",+]++[[package]]+name = "browsentic-desktop"+version = "0.0.0"+dependencies = [+ "futures-util",+ "reqwest 0.12.28",+ "serde",+ "serde_json",+ "sha2",+ "tauri",+ "tauri-build",+ "tauri-plugin-opener",+ "tauri-plugin-single-instance",+ "tauri-plugin-updater",+ "tempfile",+ "time",+ "tokio",+ "tokio-tungstenite",+ "windows-sys 0.61.2",+ "winreg 0.56.0",+ "zip",+]++[[package]]+name = "browsentic-launcher"+version = "0.0.0"+dependencies = [+ "serde_json",+ "windows-sys 0.61.2",+]++[[package]]+name = "bs58"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bf88ba1141d185c399bee5288d850d63b8369520c1eafc32a0430b5b6c287bf4"+dependencies = [+ "tinyvec",+]++[[package]]+name = "bumpalo"+version = "3.20.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649"++[[package]]+name = "bytemuck"+version = "1.25.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "95832e849adfb21180ccb6826a99da14e5d266ae5c2e668e1602cf234f153797"++[[package]]+name = "byteorder"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b"++[[package]]+name = "byteorder-lite"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8f1fe948ff07f4bd06c30984e69f5b4899c516a3ef74f34df92a2df2ab535495"++[[package]]+name = "bytes"+version = "1.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc652a48c352aef3ea3aed32080501cf3ef6ed5da78602a020c991775b0aff04"+dependencies = [+ "serde",+]++[[package]]+name = "cairo-rs"+version = "0.18.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ca26ef0159422fb77631dc9d17b102f253b876fe1586b03b803e63a309b4ee2"+dependencies = [+ "bitflags 2.13.2",+ "cairo-sys-rs",+ "glib",+ "libc",+ "once_cell",+ "thiserror 1.0.69",+]++[[package]]+name = "cairo-sys-rs"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "685c9fa8e590b8b3d678873528d83411db17242a73fccaed827770ea0fedda51"+dependencies = [+ "glib-sys",+ "libc",+ "system-deps",+]++[[package]]+name = "camino"+version = "1.2.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bbbad30e4b4c14a39e3cc8aed085a12a327257c316619c93581e017bc52be591"+dependencies = [+ "serde_core",+]++[[package]]+name = "cargo-platform"+version = "0.1.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e35af189006b9c0f00a064685c727031e3ed2d8020f7ba284d78cc2671bd36ea"+dependencies = [+ "serde",+]++[[package]]+name = "cargo_metadata"+version = "0.19.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dd5eb614ed4c27c5d706420e4320fbe3216ab31fa1c33cd8246ac36dae4479ba"+dependencies = [+ "camino",+ "cargo-platform",+ "semver",+ "serde",+ "serde_json",+ "thiserror 2.0.21",+]++[[package]]+name = "cargo_toml"+version = "1.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "82f4b26e751e711a5302649417f2da046dce6391b2ea30a4820f37462314f0b9"+dependencies = [+ "semver",+ "serde",+ "toml 1.1.6+spec-1.1.0",+]++[[package]]+name = "cc"+version = "1.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f360145194ee8e21db5ee7f3fcd4fe52210864c75c985dae33218202c8bbe040"+dependencies = [+ "find-msvc-tools",+ "shlex",+]++[[package]]+name = "cesu8"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c"++[[package]]+name = "cfb"+version = "0.7.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d38f2da7a0a2c4ccf0065be06397cc26a81f4e528be095826eee9d4adbb8c60f"+dependencies = [+ "byteorder",+ "fnv",+ "uuid",+]++[[package]]+name = "cfb"+version = "0.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a347dcabdae9c31b0825fd6a8bed285ec9c2acb89c47827126d52fa4f59cece3"+dependencies = [+ "fnv",+ "uuid",+ "web-time",+]++[[package]]+name = "cfg-expr"+version = "0.15.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d067ad48b8650848b989a59a86c6c36a995d02d2bf778d45c3c5d57bc2718f02"+dependencies = [+ "smallvec",+ "target-lexicon",+]++[[package]]+name = "cfg-if"+version = "1.0.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4e7648175b45a9a48536d676f68d918270699102aa8dab5496df06904c914600"++[[package]]+name = "chacha20"+version = "0.10.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "65c35e4b699c7e15ccbe7ee35c005e4fc0a278d22238a2857e6ce2dadeda1b06"+dependencies = [+ "cfg-if",+ "cpufeatures 0.3.1",+ "rand_core",+]++[[package]]+name = "chrono"+version = "0.4.45"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1aa79e62e7697b8e29b513a68abacf485adcd1fe8284a4316c5ae868e6633327"+dependencies = [+ "iana-time-zone",+ "num-traits",+ "serde",+ "windows-link 0.2.1",+]++[[package]]+name = "combine"+version = "4.6.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cfc320937d09e6de266b31b9afb480f197d7a861be86be7cb2ea7e5d1bfffc5e"+dependencies = [+ "bytes",+ "memchr",+]++[[package]]+name = "concurrent-queue"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973"+dependencies = [+ "crossbeam-utils",+]++[[package]]+name = "const-oid"+version = "0.10.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a6ef517f0926dd24a1582492c791b6a4818a4d94e789a334894aa15b0d12f55c"++[[package]]+name = "cookie"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1a373e3602691c3cdea496d2f0ee5935151e6168fe87739483c463db1b2f2f87"+dependencies = [+ "time",+ "version_check",+]++[[package]]+name = "core-foundation"+version = "0.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b2a6cd9ae233e7f62ba4e9353e81a88df7fc8a5987b8d445b4d90c879bd156f6"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "core-foundation-sys"+version = "0.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b"++[[package]]+name = "core-graphics"+version = "0.25.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "064badf302c3194842cf2c5d61f56cc88e54a759313879cdf03abdd27d0c3b97"+dependencies = [+ "bitflags 2.13.2",+ "core-foundation",+ "core-graphics-types",+ "foreign-types 0.5.0",+ "libc",+]++[[package]]+name = "core-graphics-types"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3d44a101f213f6c4cdc1853d4b78aef6db6bdfa3468798cc1d9912f4735013eb"+dependencies = [+ "bitflags 2.13.2",+ "core-foundation",+ "libc",+]++[[package]]+name = "cpufeatures"+version = "0.2.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280"+dependencies = [+ "libc",+]++[[package]]+name = "cpufeatures"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5ca28b0ae3115b884660db4118d803791fd6756b6e88f39c0f3f7859060d7566"+dependencies = [+ "libc",+]++[[package]]+name = "crc32fast"+version = "1.5.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "01a7799fd6b852db0e61728dde9a204c423b44d689dbd432522543614b490e78"+dependencies = [+ "cfg-if",+]++[[package]]+name = "crossbeam-channel"+version = "0.5.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "98b0cc327b5bc766e7fda9c9260cc0fa81b43a8e240440422dff70788e3f9ef1"+dependencies = [+ "crossbeam-utils",+]++[[package]]+name = "crossbeam-utils"+version = "0.8.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a31eee39dddec8330830986fcd7625edb5a24ec90ea038215273bbc3adb08ac6"++[[package]]+name = "crypto-common"+version = "0.1.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "78c8292055d1c1df0cce5d180393dc8cce0abec0a7102adb6c7b1eef6016d60a"+dependencies = [+ "generic-array",+ "typenum",+]++[[package]]+name = "crypto-common"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ce6e4c961d6cd6c9a86db418387425e8bdeaf05b3c8bc1411e6dca4c252f1453"+dependencies = [+ "hybrid-array",+]++[[package]]+name = "cssparser"+version = "0.37.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8c9cdaae01d5ed7882b04d795e7f752f46ff52d2fa3b50a20d28c464510bba98"+dependencies = [+ "cssparser-macros",+ "dtoa-short",+ "itoa",+ "phf",+ "smallvec",+]++[[package]]+name = "cssparser-macros"+version = "0.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d045de693cb712d0b22c6a64be5b953f67b3ce00ab5ad3dd5d8b441886ab8e1a"+dependencies = [+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "ctor"+version = "1.0.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "914a755b7c2d4af2bdcff7ce1739e2db9a1b81a9b07123d8015786ae03c0980d"++[[package]]+name = "darling"+version = "0.24.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed17f5901b6630b993ca003def43f2f8ef4014fc13b047b57aad617ff32bc2ec"+dependencies = [+ "darling_core",+ "darling_macro",+]++[[package]]+name = "darling_core"+version = "0.24.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6837e2cf7485aaae18f86181d2f0e9a7ed297a025e220aeabf63fdebd3a2ddff"+dependencies = [+ "ident_case",+ "proc-macro2",+ "quote",+ "strsim",+ "syn 3.0.6",+]++[[package]]+name = "darling_macro"+version = "0.24.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2ac7135c3ef02b2f7833bbeb1be5ba7f966dcde8a87c6b87f65a778d71a02785"+dependencies = [+ "darling_core",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "data-encoding"+version = "2.11.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4583a4551df46e2792f82ceeac45e850d2e2d5debba0b91f102385cda5b11f06"++[[package]]+name = "dbus"+version = "0.9.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3ab69f03cc8c4340c9c8e315114e1658e6775a9b16a04357973aa21cec22b32e"+dependencies = [+ "libc",+ "libdbus-sys",+ "windows-sys 0.61.2",+]++[[package]]+name = "defmt"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e2953bfe4f93bbd20cc71198842756f77d161884c99ebbabc41d80231ded88d1"+dependencies = [+ "bitflags 1.3.2",+ "defmt-macros",+]++[[package]]+name = "defmt-macros"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bad9c72e7ca2137e0dc3813245a0d282fd6daad32fd800af018306a9169b5fe8"+dependencies = [+ "defmt-parser",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "defmt-parser"+version = "1.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "10d60334b3b2e7c9d91ef8150abfb6fa4c1c39ebbcf4a81c2e346aad939fee3e"+dependencies = [+ "thiserror 2.0.21",+]++[[package]]+name = "deranged"+version = "0.5.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7cd812cc2bc1d69d4764bd80df88b4317eaef9e773c75226407d9bc0876b211c"+dependencies = [+ "serde_core",+]++[[package]]+name = "derive_more"+version = "2.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d751e9e49156b02b44f9c1815bcb94b984cdcc4396ecc32521c739452808b134"+dependencies = [+ "derive_more-impl",+]++[[package]]+name = "derive_more-impl"+version = "2.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "799a97264921d8623a957f6c3b9011f3b5492f557bbb7a5a19b7fa6d06ba8dcb"+dependencies = [+ "proc-macro2",+ "quote",+ "rustc_version",+ "syn 2.0.119",+]++[[package]]+name = "digest"+version = "0.10.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292"+dependencies = [+ "block-buffer 0.10.4",+ "crypto-common 0.1.7",+]++[[package]]+name = "digest"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f1dd6dbb5841937940781866fa1281a1ff7bd3bf827091440879f9994983d5c2"+dependencies = [+ "block-buffer 0.12.1",+ "const-oid",+ "crypto-common 0.2.2",+]++[[package]]+name = "dirs"+version = "6.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c3e8aa94d75141228480295a7d0e7feb620b1a5ad9f12bc40be62411e38cce4e"+dependencies = [+ "dirs-sys",+]++[[package]]+name = "dirs"+version = "7.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8d57d423b3c82e89b9a24ca3091fee61f456a26edbd28d26c65906f4bc1dcd8f"+dependencies = [+ "dirs-sys",+]++[[package]]+name = "dirs-sys"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e01a3366d27ee9890022452ee61b2b63a67e6f13f58900b651ff5665f0bb1fab"+dependencies = [+ "libc",+ "option-ext",+ "redox_users",+ "windows-sys 0.61.2",+]++[[package]]+name = "dispatch2"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e0e367e4e7da84520dedcac1901e4da967309406d1e51017ae1abfb97adbd38"+dependencies = [+ "bitflags 2.13.2",+ "block2",+ "libc",+ "objc2",+]++[[package]]+name = "displaydoc"+version = "0.2.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c6232dd377dcc64799954cbd3a9bb882e9cdc1308ccd87b1c098f1fb2eaf82a8"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "dlopen2"+version = "0.8.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5e2c5bd4158e66d1e215c49b837e11d62f3267b30c92f1d171c4d3105e3dc4d4"+dependencies = [+ "dlopen2_derive",+ "libc",+ "once_cell",+ "winapi",+]++[[package]]+name = "dlopen2_derive"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0fbbb781877580993a8707ec48672673ec7b81eeba04cfd2310bd28c08e47c8f"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "dom_query"+version = "0.28.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fac5fca71e65e94cc718a6e2af65d6e0f9c6027751c2aa562fbb5087fda639bc"+dependencies = [+ "bit-set",+ "cssparser",+ "foldhash",+ "html5ever",+ "precomputed-hash",+ "selectors",+ "tendril",+]++[[package]]+name = "dpi"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d8b14ccef22fc6f5a8f4d7d768562a182c04ce9a3b3157b91390b52ddfdf1a76"+dependencies = [+ "serde",+]++[[package]]+name = "dtoa"+version = "1.0.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4c3cf4824e2d5f025c7b531afcb2325364084a16806f6d47fbc1f5fbd9960590"++[[package]]+name = "dtoa-short"+version = "0.3.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cd1511a7b6a56299bd043a9c167a6d2bfb37bf84a6dfceaba651168adfb43c87"+dependencies = [+ "dtoa",+]++[[package]]+name = "dunce"+version = "1.0.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813"++[[package]]+name = "dyn-clone"+version = "1.0.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d0881ea181b1df73ff77ffaaf9c7544ecc11e82fba9b5f27b262a3c73a332555"++[[package]]+name = "embed-resource"+version = "3.0.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fbfdaacccebec3b28e4866b8973543c7647797db5ada1bdab552e48fe665fbbd"+dependencies = [+ "cc",+ "memchr",+ "rustc_version",+ "toml 1.1.6+spec-1.1.0",+ "vswhom",+ "winreg 0.55.0",+]++[[package]]+name = "embed_plist"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7"++[[package]]+name = "endi"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "66b7e2430c6dff6a955451e2cfc438f09cea1965a9d6f87f7e3b90decc014099"++[[package]]+name = "enumflags2"+version = "0.7.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1027f7680c853e056ebcec683615fb6fbbc07dbaa13b4d5d9442b146ded4ecef"+dependencies = [+ "enumflags2_derive",+ "serde",+]++[[package]]+name = "enumflags2_derive"+version = "0.7.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "67c78a4d8fdf9953a5c9d458f9efe940fd97a0cab0941c075a813ac594733827"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "equivalent"+version = "1.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f"++[[package]]+name = "erased-serde"+version = "0.4.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d2add8a07dd6a8d93ff627029c51de145e12686fbc36ecb298ac22e74cf02dec"+dependencies = [+ "serde",+ "serde_core",+ "typeid",+]++[[package]]+name = "errno"+version = "0.3.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb"+dependencies = [+ "libc",+ "windows-sys 0.61.2",+]++[[package]]+name = "event-listener"+version = "5.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5a23add41df1562121a9393cb065eab5146a1242410f23a644851e90cfd669d2"+dependencies = [+ "parking",+ "pin-project-lite",+]++[[package]]+name = "event-listener-strategy"+version = "0.5.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8be9f3dfaaffdae2972880079a491a1a8bb7cbed0b8dd7a347f668b4150a3b93"+dependencies = [+ "event-listener",+ "pin-project-lite",+]++[[package]]+name = "fastrand"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "da7c62ceae207dd37ea5b845da6a0696c799f85e97da1ab5b7910be3c1c80223"++[[package]]+name = "fdeflate"+version = "0.3.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e6853b52649d4ac5c0bd02320cddc5ba956bdb407c4b75a2c6b75bf51500f8c"+dependencies = [+ "simd-adler32",+]++[[package]]+name = "field-offset"+version = "0.3.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "38e2275cc4e4fc009b0669731a1e5ab7ebf11f469eaede2bab9309a5b4d6057f"+dependencies = [+ "memoffset",+ "rustc_version",+]++[[package]]+name = "filetime"+version = "0.2.29"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c287a33c7f0a620c38e641e7f60827713987b3c0f26e8ddc9462cc69cf75759"+dependencies = [+ "cfg-if",+ "libc",+]++[[package]]+name = "find-msvc-tools"+version = "0.1.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "aedcfb3409746eddb02b9e19ebda1c3394f759a152e48ee875a0844d1b955484"++[[package]]+name = "flate2"+version = "1.1.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6e634e2e0ebac1ee034020da1ca582e17ffe4e0f5e985823721e168928136dcb"+dependencies = [+ "crc32fast",+ "miniz_oxide 0.9.1",+ "zlib-rs",+]++[[package]]+name = "fnv"+version = "1.0.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"++[[package]]+name = "foldhash"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb"++[[package]]+name = "foreign-types"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1"+dependencies = [+ "foreign-types-shared 0.1.1",+]++[[package]]+name = "foreign-types"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d737d9aa519fb7b749cbc3b962edcf310a8dd1f4b67c91c4f83975dbdd17d965"+dependencies = [+ "foreign-types-macros",+ "foreign-types-shared 0.3.1",+]++[[package]]+name = "foreign-types-macros"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ea5190182e6915eb873ddbc16e23b711b6eb1f9c00a0d0a3a91b5f6228475225"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "foreign-types-shared"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b"++[[package]]+name = "foreign-types-shared"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b"++[[package]]+name = "form_urlencoded"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cb4cb245038516f5f85277875cdaa4f7d2c9a0fa0468de06ed190163b1581fcf"+dependencies = [+ "percent-encoding",+]++[[package]]+name = "futures-channel"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b1f9e3d69d39e4862ffed03ed071a76f9a13ba1d9109d355b0f0aa6b15e393c4"+dependencies = [+ "futures-core",+]++[[package]]+name = "futures-core"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "92d699e522242e69e3003b94ecc1f960f3a5e015aa7c5d7486e65ad01dd94f5e"++[[package]]+name = "futures-executor"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "031b47cf1a3c6cc8bc2fc76cd437f521619387907d469316e7c0bc278f1f5432"+dependencies = [+ "futures-core",+ "futures-task",+ "futures-util",+]++[[package]]+name = "futures-io"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "53c0fa8157de1303bfffdaa1cc2a673bfffb60102f76b0ef4441659124373fed"++[[package]]+name = "futures-lite"+version = "2.6.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f78e10609fe0e0b3f4157ffab1876319b5b0db102a2c60dc4626306dc46b44ad"+dependencies = [+ "fastrand",+ "futures-core",+ "futures-io",+ "parking",+ "pin-project-lite",+]++[[package]]+name = "futures-macro"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9fb9654ba8355388abeb8dcb4fc62f511300867002afc858860463bdd9fe0c44"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "futures-sink"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1944426bf7d03f1d14f708785e4b33efd750b36d48a157b836b3efc15ede8e1d"++[[package]]+name = "futures-task"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cd417de3d1d015fc3bfd2b1ea46dfc7bab72ef86f1cc7cc9c78e728b34a6d1fd"++[[package]]+name = "futures-util"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0d50a92467f8ba5dd6e3ee5d4bd04d73ab2e4e1c44474a0674821dfce14b79bc"+dependencies = [+ "futures-core",+ "futures-io",+ "futures-macro",+ "futures-sink",+ "futures-task",+ "memchr",+ "pin-project-lite",+ "slab",+]++[[package]]+name = "gdk"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d9f245958c627ac99d8e529166f9823fb3b838d1d41fd2b297af3075093c2691"+dependencies = [+ "cairo-rs",+ "gdk-pixbuf",+ "gdk-sys",+ "gio",+ "glib",+ "libc",+ "pango",+]++[[package]]+name = "gdk-pixbuf"+version = "0.18.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "50e1f5f1b0bfb830d6ccc8066d18db35c487b1b2b1e8589b5dfe9f07e8defaec"+dependencies = [+ "gdk-pixbuf-sys",+ "gio",+ "glib",+ "libc",+ "once_cell",+]++[[package]]+name = "gdk-pixbuf-sys"+version = "0.18.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3f9839ea644ed9c97a34d129ad56d38a25e6756f99f3a88e15cd39c20629caf7"+dependencies = [+ "gio-sys",+ "glib-sys",+ "gobject-sys",+ "libc",+ "system-deps",+]++[[package]]+name = "gdk-sys"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c2d13f38594ac1e66619e188c6d5a1adb98d11b2fcf7894fc416ad76aa2f3f7"+dependencies = [+ "cairo-sys-rs",+ "gdk-pixbuf-sys",+ "gio-sys",+ "glib-sys",+ "gobject-sys",+ "libc",+ "pango-sys",+ "pkg-config",+ "system-deps",+]++[[package]]+name = "gdkwayland-sys"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "140071d506d223f7572b9f09b5e155afbd77428cd5cc7af8f2694c41d98dfe69"+dependencies = [+ "gdk-sys",+ "glib-sys",+ "gobject-sys",+ "libc",+ "pkg-config",+ "system-deps",+]++[[package]]+name = "gdkx11"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3caa00e14351bebbc8183b3c36690327eb77c49abc2268dd4bd36b856db3fbfe"+dependencies = [+ "gdk",+ "gdkx11-sys",+ "gio",+ "glib",+ "libc",+ "x11",+]++[[package]]+name = "gdkx11-sys"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6e2e7445fe01ac26f11601db260dd8608fe172514eb63b3b5e261ea6b0f4428d"+dependencies = [+ "gdk-sys",+ "glib-sys",+ "libc",+ "system-deps",+ "x11",+]++[[package]]+name = "generic-array"+version = "0.14.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a"+dependencies = [+ "typenum",+ "version_check",+]++[[package]]+name = "getrandom"+version = "0.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd"+dependencies = [+ "cfg-if",+ "libc",+ "r-efi 5.3.0",+ "wasip2",+]++[[package]]+name = "getrandom"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099"+dependencies = [+ "cfg-if",+ "libc",+ "r-efi 6.0.0",+ "rand_core",+]++[[package]]+name = "gio"+version = "0.18.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d4fc8f532f87b79cbc51a79748f16a6828fb784be93145a322fa14d06d354c73"+dependencies = [+ "futures-channel",+ "futures-core",+ "futures-io",+ "futures-util",+ "gio-sys",+ "glib",+ "libc",+ "once_cell",+ "pin-project-lite",+ "smallvec",+ "thiserror 1.0.69",+]++[[package]]+name = "gio-sys"+version = "0.18.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "37566df850baf5e4cb0dfb78af2e4b9898d817ed9263d1090a2df958c64737d2"+dependencies = [+ "glib-sys",+ "gobject-sys",+ "libc",+ "system-deps",+ "winapi",+]++[[package]]+name = "glib"+version = "0.18.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "233daaf6e83ae6a12a52055f568f9d7cf4671dabb78ff9560ab6da230ce00ee5"+dependencies = [+ "bitflags 2.13.2",+ "futures-channel",+ "futures-core",+ "futures-executor",+ "futures-task",+ "futures-util",+ "gio-sys",+ "glib-macros",+ "glib-sys",+ "gobject-sys",+ "libc",+ "memchr",+ "once_cell",+ "smallvec",+ "thiserror 1.0.69",+]++[[package]]+name = "glib-macros"+version = "0.18.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0bb0228f477c0900c880fd78c8759b95c7636dbd7842707f49e132378aa2acdc"+dependencies = [+ "heck 0.4.1",+ "proc-macro-crate 2.0.2",+ "proc-macro-error",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "glib-sys"+version = "0.18.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "063ce2eb6a8d0ea93d2bf8ba1957e78dbab6be1c2220dd3daca57d5a9d869898"+dependencies = [+ "libc",+ "system-deps",+]++[[package]]+name = "glob"+version = "0.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e4eba85ea1d0a966a983acd07deee566e67395d2d96b6fb39e62b5a833f1eb0b"++[[package]]+name = "gobject-sys"+version = "0.18.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0850127b514d1c4a4654ead6dedadb18198999985908e6ffe4436f53c785ce44"+dependencies = [+ "glib-sys",+ "libc",+ "system-deps",+]++[[package]]+name = "gtk"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fd56fb197bfc42bd5d2751f4f017d44ff59fbb58140c6b49f9b3b2bdab08506a"+dependencies = [+ "atk",+ "cairo-rs",+ "field-offset",+ "futures-channel",+ "gdk",+ "gdk-pixbuf",+ "gio",+ "glib",+ "gtk-sys",+ "gtk3-macros",+ "libc",+ "pango",+ "pkg-config",+]++[[package]]+name = "gtk-sys"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8f29a1c21c59553eb7dd40e918be54dccd60c52b049b75119d5d96ce6b624414"+dependencies = [+ "atk-sys",+ "cairo-sys-rs",+ "gdk-pixbuf-sys",+ "gdk-sys",+ "gio-sys",+ "glib-sys",+ "gobject-sys",+ "libc",+ "pango-sys",+ "system-deps",+]++[[package]]+name = "gtk3-macros"+version = "0.18.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "52ff3c5b21f14f0736fed6dcfc0bfb4225ebf5725f3c0209edeec181e4d73e9d"+dependencies = [+ "proc-macro-crate 1.3.1",+ "proc-macro-error",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "hashbrown"+version = "0.12.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888"++[[package]]+name = "hashbrown"+version = "0.17.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a"++[[package]]+name = "heck"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8"++[[package]]+name = "heck"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea"++[[package]]+name = "hermit-abi"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e17592d60ebacc7d5e169f4663c5f84f9161cc90328abcfe8456f41e4dfcb284"++[[package]]+name = "hex"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70"++[[package]]+name = "html5ever"+version = "0.39.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "46a1761807faccc9a19e86944bbf40610014066306f96edcdedc2fb714bcb7b8"+dependencies = [+ "log",+ "markup5ever",+]++[[package]]+name = "http"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "918d3568bebf352712bc2ef3d46a8bcf1a75b373be6539de198e9105cbbf9ce0"+dependencies = [+ "bytes",+ "itoa",+]++[[package]]+name = "http-body"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ca2a8f2913ee65f60facd6a5905613afaa448497a0230cc41ce022d93290bc2c"+dependencies = [+ "bytes",+ "http",+]++[[package]]+name = "http-body-util"+version = "0.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23169fe34a5fbcdd3f3862e78fb9b6fccd5f02a6dc6f732547005d45631ce71c"+dependencies = [+ "bytes",+ "futures-core",+ "http",+ "http-body",+ "pin-project-lite",+]++[[package]]+name = "httparse"+version = "1.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87"++[[package]]+name = "hybrid-array"+version = "0.4.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "27f864f10dfb56725ce5ce5472bc52252c8f93a4ab86327122cebf62c5f59a17"+dependencies = [+ "typenum",+]++[[package]]+name = "hyper"+version = "1.11.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "27b501faa50e7a26c3d3560ca625132f4078a17771f4810baf70475ae48cbe43"+dependencies = [+ "atomic-waker",+ "bytes",+ "futures-channel",+ "futures-core",+ "http",+ "http-body",+ "httparse",+ "itoa",+ "pin-project-lite",+ "smallvec",+ "tokio",+ "want",+]++[[package]]+name = "hyper-tls"+version = "0.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0"+dependencies = [+ "bytes",+ "http-body-util",+ "hyper",+ "hyper-util",+ "native-tls",+ "tokio",+ "tokio-native-tls",+ "tower-service",+]++[[package]]+name = "hyper-util"+version = "0.1.21"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ddc03d96684f9226b8a787cdb71488417b53ab5ea8fdb1dac946cb9431cc8bff"+dependencies = [+ "base64 0.23.1",+ "bytes",+ "futures-channel",+ "futures-util",+ "http",+ "http-body",+ "httparse",+ "hyper",+ "ipnet",+ "libc",+ "percent-encoding",+ "pin-project-lite",+ "socket2",+ "tokio",+ "tower-service",+ "tracing",+]++[[package]]+name = "iana-time-zone"+version = "0.1.65"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e31bc9ad994ba00e440a8aa5c9ef0ec67d5cb5e5cb0cc7f8b744a35b389cc470"+dependencies = [+ "android_system_properties",+ "core-foundation-sys",+ "iana-time-zone-haiku",+ "js-sys",+ "log",+ "wasm-bindgen",+ "windows-core 0.62.2",+]++[[package]]+name = "iana-time-zone-haiku"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f"+dependencies = [+ "cc",+]++[[package]]+name = "ico"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3e795dff5605e0f04bff85ca41b51a96b83e80b281e96231bcaaf1ac35103371"+dependencies = [+ "byteorder",+ "png 0.17.16",+]++[[package]]+name = "icu_collections"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fa68d21081c4a05d5a901a1c62add574c77048b6a1c67be3b50ce0b60d4ca513"+dependencies = [+ "displaydoc",+ "potential_utf",+ "utf8_iter",+ "yoke",+ "zerofrom",+ "zerovec",+]++[[package]]+name = "icu_locale_core"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d56e28588da92eee5c3201a6eff33fabdd49b62269c8938d4ff050ce4d900deb"+dependencies = [+ "displaydoc",+ "litemap",+ "tinystr",+ "writeable",+ "zerovec",+]++[[package]]+name = "icu_normalizer"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "12f9cf5f235641ed274641dd81c3f28d870e276763d0797aeeab72317b1c646f"+dependencies = [+ "icu_collections",+ "icu_normalizer_data",+ "icu_properties",+ "icu_provider",+ "smallvec",+ "zerovec",+]++[[package]]+name = "icu_normalizer_data"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1563da1ed3e0b3bf3d74c9b85917ac9c56464d2f57242270c09c9e752f8021a0"++[[package]]+name = "icu_properties"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7e7ca276ad3145661a65914e6daf131ca5120cd3dcee8f8f3214b8875184a148"+dependencies = [+ "displaydoc",+ "icu_collections",+ "icu_locale_core",+ "icu_properties_data",+ "icu_provider",+ "zerotrie",+ "zerovec",+]++[[package]]+name = "icu_properties_data"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e590f038c1464a96894fd6d10127e90a8be4509f56ff7ecef851b15cee0b7caa"++[[package]]+name = "icu_provider"+version = "2.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d27bbb9d3abbefac45d55f647c9de1d44aafcd1186eb91879afef17c396c3e73"+dependencies = [+ "displaydoc",+ "icu_locale_core",+ "writeable",+ "yoke",+ "zerofrom",+ "zerotrie",+ "zerovec",+]++[[package]]+name = "ident_case"+version = "1.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39"++[[package]]+name = "idna"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de"+dependencies = [+ "idna_adapter",+ "smallvec",+ "utf8_iter",+]++[[package]]+name = "idna_adapter"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cb68373c0d6620ef8105e855e7745e18b0d00d3bdb07fb532e434244cdb9a714"+dependencies = [+ "icu_normalizer",+ "icu_properties",+]++[[package]]+name = "image"+version = "0.25.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85ab80394333c02fe689eaf900ab500fbd0c2213da414687ebf995a65d5a6104"+dependencies = [+ "bytemuck",+ "byteorder-lite",+ "moxcms",+ "num-traits",+ "png 0.18.1",+]++[[package]]+name = "indexmap"+version = "1.9.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99"+dependencies = [+ "autocfg",+ "hashbrown 0.12.3",+ "serde",+]++[[package]]+name = "indexmap"+version = "2.14.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cc4e190f5d26ca7051642629da2c52fc03bde85a03197c99408dcd291734c855"+dependencies = [+ "equivalent",+ "hashbrown 0.17.1",+ "serde",+ "serde_core",+]++[[package]]+name = "infer"+version = "0.19.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a588916bfdfd92e71cacef98a63d9b1f0d74d6599980d11894290e7ddefffcf7"+dependencies = [+ "cfb 0.7.3",+]++[[package]]+name = "infer"+version = "0.22.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f4200d433cbd5178df7797c9c2e75b348b728e39631cf14520d1e2fc424201f4"+dependencies = [+ "cfb 0.14.0",+]++[[package]]+name = "ipnet"+version = "2.12.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "791930b43c0d5973160d90a8f3894509f2b273430f5c5c73b668636d0287c5c0"++[[package]]+name = "is-docker"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "928bae27f42bc99b60d9ac7334e3a21d10ad8f1835a4e12ec3ec0464765ed1b3"+dependencies = [+ "once_cell",+]++[[package]]+name = "is-wsl"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "173609498df190136aa7dea1a91db051746d339e18476eed5ca40521f02d7aa5"+dependencies = [+ "is-docker",+ "once_cell",+]++[[package]]+name = "itoa"+version = "1.0.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682"++[[package]]+name = "javascriptcore-rs"+version = "1.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ca5671e9ffce8ffba57afc24070e906da7fc4b1ba66f2cabebf61bf2ea257fcc"+dependencies = [+ "bitflags 1.3.2",+ "glib",+ "javascriptcore-rs-sys",+]++[[package]]+name = "javascriptcore-rs-sys"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "af1be78d14ffa4b75b66df31840478fef72b51f8c2465d4ca7c194da9f7a5124"+dependencies = [+ "glib-sys",+ "gobject-sys",+ "libc",+ "system-deps",+]++[[package]]+name = "jiff"+version = "0.2.37"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ab1baf72f08796de0260609515130699b890ac25f30e610ad894bc5856cafdb"+dependencies = [+ "defmt",+ "jiff-core",+ "jiff-static",+ "jiff-tzdb-platform",+ "log",+ "portable-atomic",+ "portable-atomic-util",+ "serde_core",+ "windows-link 0.2.1",+]++[[package]]+name = "jiff-core"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5e52fe76043ccecc9005d2305ebaadf7d7fc0cc89ca6baa10a94d6bc68c7128c"+dependencies = [+ "defmt",+ "log",+]++[[package]]+name = "jiff-static"+version = "0.2.37"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "378268a1116ad67ae6228701118ac9f491d78fda38a40a1f1a9e1348de6f7212"+dependencies = [+ "jiff-core",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "jiff-tzdb"+version = "0.1.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "142bd39932ad231f10513df9ab62661fead8719872150b7ad02a2df79f4e141e"++[[package]]+name = "jiff-tzdb-platform"+version = "0.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "875a5a69ac2bab1a891711cf5eccbec1ce0341ea805560dcd90b7a2e925132e8"+dependencies = [+ "jiff-tzdb",+]++[[package]]+name = "jni"+version = "0.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1a87aa2bb7d2af34197c04845522473242e1aa17c12f4935d5856491a7fb8c97"+dependencies = [+ "cesu8",+ "cfg-if",+ "combine",+ "jni-sys 0.3.1",+ "log",+ "thiserror 1.0.69",+ "walkdir",+ "windows-sys 0.45.0",+]++[[package]]+name = "jni-sys"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "41a652e1f9b6e0275df1f15b32661cf0d4b78d4d87ddec5e0c3c20f097433258"+dependencies = [+ "jni-sys 0.4.1",+]++[[package]]+name = "jni-sys"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c6377a88cb3910bee9b0fa88d4f42e1d2da8e79915598f65fb0c7ee14c878af2"+dependencies = [+ "jni-sys-macros",+]++[[package]]+name = "jni-sys-macros"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "38c0b942f458fe50cdac086d2f946512305e5631e720728f2a61aabcd47a6264"+dependencies = [+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "js-sys"+version = "0.3.106"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7883d941dae510fb2d978fc3fe018c71c9e2892fd38854de3e8b92c2e5ad9cc5"+dependencies = [+ "cfg-if",+ "futures-util",+ "wasm-bindgen",+]++[[package]]+name = "json-patch"+version = "4.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7421438de105a0827e44fadd05377727847d717c80ce29a229f85fd04c427b72"+dependencies = [+ "jsonptr",+ "serde",+ "serde_json",+ "thiserror 2.0.21",+]++[[package]]+name = "jsonptr"+version = "0.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a5a3cc660ba5d72bce0b3bb295bf20847ccbb40fd423f3f05b61273672e561fe"+dependencies = [+ "serde",+ "serde_json",+]++[[package]]+name = "keyboard-types"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0fbe853b403ae61a04233030ae8a79d94975281ed9770a1f9e246732b534b28d"+dependencies = [+ "bitflags 2.13.2",+ "serde",+]++[[package]]+name = "libappindicator"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "03589b9607c868cc7ae54c0b2a22c8dc03dd41692d48f2d7df73615c6a95dc0a"+dependencies = [+ "glib",+ "gtk",+ "gtk-sys",+ "libappindicator-sys",+ "log",+]++[[package]]+name = "libappindicator-sys"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6e9ec52138abedcc58dc17a7c6c0c00a2bdb4f3427c7f63fa97fd0d859155caf"+dependencies = [+ "gtk-sys",+ "libloading",+ "once_cell",+]++[[package]]+name = "libc"+version = "0.2.189"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3eaf3ede3fee6db1a4c2ee091bf8a8b4dccdc6d17f656fb07896ee72867612f2"++[[package]]+name = "libdbus-sys"+version = "0.2.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "328c4789d42200f1eeec05bd86c9c13c7f091d2ba9a6ea35acdf51f31bc0f043"+dependencies = [+ "pkg-config",+]++[[package]]+name = "libloading"+version = "0.7.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b67380fd3b2fbe7527a606e18729d21c6f3951633d0500574c4dc22d2d638b9f"+dependencies = [+ "cfg-if",+ "winapi",+]++[[package]]+name = "libredox"+version = "0.1.25"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "61ff90caf6077a803a240f62fdbe88645a890bbca49ef8174c3cb0404362171d"+dependencies = [+ "libc",+]++[[package]]+name = "linux-raw-sys"+version = "0.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32a66949e030da00e8c7d4434b251670a91556f4144941d37452769c25d58a53"++[[package]]+name = "litemap"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "47d9d19d1d6efa0109d2f65ff4c85cddd50bd572e5a00127ab10987290bcefae"++[[package]]+name = "lock_api"+version = "0.4.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "224399e74b87b5f3557511d98dff8b14089b3dadafcab6bb93eab67d3aace965"+dependencies = [+ "scopeguard",+]++[[package]]+name = "log"+version = "0.4.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f9f8bd3e56ce4dfc153cf470fffbfa98c7620958b312ca5c3a4b8d5181fd13c6"++[[package]]+name = "markup5ever"+version = "0.39.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7122d987ec5f704ee56f6e5b41a7d93722e9aae27ae07cafa4036c4d3f9757de"+dependencies = [+ "log",+ "tendril",+ "web_atoms",+]++[[package]]+name = "memchr"+version = "2.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98"++[[package]]+name = "memoffset"+version = "0.9.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a"+dependencies = [+ "autocfg",+]++[[package]]+name = "mime"+version = "0.3.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a"++[[package]]+name = "minisign-verify"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "22f9645cb765ea72b8111f36c522475d2daa0d22c957a9826437e97534bc4e9e"++[[package]]+name = "miniz_oxide"+version = "0.8.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316"+dependencies = [+ "adler2",+ "simd-adler32",+]++[[package]]+name = "miniz_oxide"+version = "0.9.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b63fbc4a50860e98e7b2aa7804ded1db5cbc3aff9193adaff57a6931bf7c4b4c"+dependencies = [+ "adler2",+ "simd-adler32",+]++[[package]]+name = "mio"+version = "1.2.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4b18443e9c262bfe8fa82f51666e2642c53393f7e5c27b3e1aeab922cff5b9d8"+dependencies = [+ "libc",+ "wasi",+ "windows-sys 0.61.2",+]++[[package]]+name = "moxcms"+version = "0.8.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bb85c154ba489f01b25c0d36ae69a87e4a1c73a72631fc6c0eb6dde34a73e44b"+dependencies = [+ "num-traits",+ "pxfm",+]++[[package]]+name = "muda"+version = "0.20.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cca139e57da4383727f189e43e66e84fa372347027fc996f9f1a007ec0a37996"+dependencies = [+ "crossbeam-channel",+ "dpi",+ "gtk",+ "keyboard-types",+ "objc2",+ "objc2-app-kit",+ "objc2-core-foundation",+ "objc2-foundation",+ "once_cell",+ "png 0.18.1",+ "serde",+ "thiserror 2.0.21",+ "windows-sys 0.61.2",+]++[[package]]+name = "native-tls"+version = "0.2.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "465500e14ea162429d264d44189adc38b199b62b1c21eea9f69e4b73cb03bbf2"+dependencies = [+ "libc",+ "log",+ "openssl",+ "openssl-probe",+ "openssl-sys",+ "schannel",+ "security-framework",+ "security-framework-sys",+ "tempfile",+]++[[package]]+name = "ndk"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c3f42e7bbe13d351b6bead8286a43aac9534b82bd3cc43e47037f012ebfd62d4"+dependencies = [+ "bitflags 2.13.2",+ "jni-sys 0.3.1",+ "log",+ "ndk-sys",+ "num_enum",+ "raw-window-handle",+ "thiserror 1.0.69",+]++[[package]]+name = "ndk-context"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "27b02d87554356db9e9a873add8782d4ea6e3e58ea071a9adb9a2e8ddb884a8b"++[[package]]+name = "ndk-sys"+version = "0.6.0+11769913"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ee6cda3051665f1fb8d9e08fc35c96d5a244fb1be711a03b71118828afc9a873"+dependencies = [+ "jni-sys 0.3.1",+]++[[package]]+name = "new_debug_unreachable"+version = "1.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086"++[[package]]+name = "num-conv"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "521739c6d2bac4aa25192232afe6841231376b2b26d4d9fae5ecf8ca5772e441"++[[package]]+name = "num-traits"+version = "0.2.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841"+dependencies = [+ "autocfg",+]++[[package]]+name = "num_enum"+version = "0.7.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5d0bca838442ec211fa11de3a8b0e0e8f3a4522575b5c4c06ed722e005036f26"+dependencies = [+ "num_enum_derive",+ "rustversion",+]++[[package]]+name = "num_enum_derive"+version = "0.7.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "680998035259dcfcafe653688bf2aa6d3e2dc05e98be6ab46afb089dc84f1df8"+dependencies = [+ "proc-macro-crate 3.5.0",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "objc2"+version = "0.6.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3a12a8ed07aefc768292f076dc3ac8c48f3781c8f2d5851dd3d98950e8c5a89f"+dependencies = [+ "objc2-encode",+ "objc2-exception-helper",+]++[[package]]+name = "objc2-app-kit"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d49e936b501e5c5bf01fda3a9452ff86dc3ea98ad5f283e1455153142d97518c"+dependencies = [+ "bitflags 2.13.2",+ "block2",+ "objc2",+ "objc2-core-foundation",+ "objc2-foundation",+ "objc2-quartz-core",+]++[[package]]+name = "objc2-cloud-kit"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "73ad74d880bb43877038da939b7427bba67e9dd42004a18b809ba7d87cee241c"+dependencies = [+ "bitflags 2.13.2",+ "objc2",+ "objc2-foundation",+]++[[package]]+name = "objc2-core-data"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0b402a653efbb5e82ce4df10683b6b28027616a2715e90009947d50b8dd298fa"+dependencies = [+ "objc2",+ "objc2-foundation",+]++[[package]]+name = "objc2-core-foundation"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2a180dd8642fa45cdb7dd721cd4c11b1cadd4929ce112ebd8b9f5803cc79d536"+dependencies = [+ "bitflags 2.13.2",+ "dispatch2",+ "objc2",+]++[[package]]+name = "objc2-core-graphics"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e022c9d066895efa1345f8e33e584b9f958da2fd4cd116792e15e07e4720a807"+dependencies = [+ "bitflags 2.13.2",+ "dispatch2",+ "objc2",+ "objc2-core-foundation",+ "objc2-io-surface",+]++[[package]]+name = "objc2-core-image"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e5d563b38d2b97209f8e861173de434bd0214cf020e3423a52624cd1d989f006"+dependencies = [+ "objc2",+ "objc2-foundation",+]++[[package]]+name = "objc2-core-location"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ca347214e24bc973fc025fd0d36ebb179ff30536ed1f80252706db19ee452009"+dependencies = [+ "objc2",+ "objc2-foundation",+]++[[package]]+name = "objc2-core-text"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0cde0dfb48d25d2b4862161a4d5fcc0e3c24367869ad306b0c9ec0073bfed92d"+dependencies = [+ "bitflags 2.13.2",+ "objc2",+ "objc2-core-foundation",+ "objc2-core-graphics",+]++[[package]]+name = "objc2-encode"+version = "4.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ef25abbcd74fb2609453eb695bd2f860d389e457f67dc17cafc8b8cbc89d0c33"++[[package]]+name = "objc2-exception-helper"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c7a1c5fbb72d7735b076bb47b578523aedc40f3c439bea6dfd595c089d79d98a"+dependencies = [+ "cc",+]++[[package]]+name = "objc2-foundation"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e3e0adef53c21f888deb4fa59fc59f7eb17404926ee8a6f59f5df0fd7f9f3272"+dependencies = [+ "bitflags 2.13.2",+ "block2",+ "libc",+ "objc2",+ "objc2-core-foundation",+]++[[package]]+name = "objc2-io-surface"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "180788110936d59bab6bd83b6060ffdfffb3b922ba1396b312ae795e1de9d81d"+dependencies = [+ "bitflags 2.13.2",+ "objc2",+ "objc2-core-foundation",+]++[[package]]+name = "objc2-osa-kit"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f112d1746737b0da274ef79a23aac283376f335f4095a083a267a082f21db0c0"+dependencies = [+ "bitflags 2.13.2",+ "objc2",+ "objc2-app-kit",+ "objc2-foundation",+]++[[package]]+name = "objc2-quartz-core"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "96c1358452b371bf9f104e21ec536d37a650eb10f7ee379fff67d2e08d537f1f"+dependencies = [+ "bitflags 2.13.2",+ "objc2",+ "objc2-core-foundation",+ "objc2-foundation",+]++[[package]]+name = "objc2-ui-kit"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d87d638e33c06f577498cbcc50491496a3ed4246998a7fbba7ccb98b1e7eab22"+dependencies = [+ "bitflags 2.13.2",+ "block2",+ "objc2",+ "objc2-cloud-kit",+ "objc2-core-data",+ "objc2-core-foundation",+ "objc2-core-graphics",+ "objc2-core-image",+ "objc2-core-location",+ "objc2-core-text",+ "objc2-foundation",+ "objc2-quartz-core",+ "objc2-user-notifications",+]++[[package]]+name = "objc2-user-notifications"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9df9128cbbfef73cda168416ccf7f837b62737d748333bfe9ab71c245d76613e"+dependencies = [+ "objc2",+ "objc2-foundation",+]++[[package]]+name = "objc2-web-kit"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b2e5aaab980c433cf470df9d7af96a7b46a9d892d521a2cbbb2f8a4c16751e7f"+dependencies = [+ "bitflags 2.13.2",+ "block2",+ "objc2",+ "objc2-app-kit",+ "objc2-core-foundation",+ "objc2-foundation",+]++[[package]]+name = "once_cell"+version = "1.21.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50"++[[package]]+name = "open"+version = "5.4.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "aa576c76302b7b808eecc68061e67336c47833ef9d22caa74dda10fa9675eebc"+dependencies = [+ "dunce",+ "is-wsl",+ "libc",+]++[[package]]+name = "openssl"+version = "0.10.81"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "77823a27f0babb03091cb9ed9ef80af3b39dbc82f97e8fa530374b7dafd87a45"+dependencies = [+ "bitflags 2.13.2",+ "cfg-if",+ "foreign-types 0.3.2",+ "libc",+ "openssl-macros",+ "openssl-sys",+]++[[package]]+name = "openssl-macros"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "openssl-probe"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7c87def4c32ab89d880effc9e097653c8da5d6ef28e6b539d313baaacfbafcbe"++[[package]]+name = "openssl-sys"+version = "0.9.117"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b47e7e6bb2c38cd930d25a23b40fa52e068c10e85f3e03a7f5ba5aaca5713695"+dependencies = [+ "cc",+ "libc",+ "pkg-config",+ "vcpkg",+]++[[package]]+name = "option-ext"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d"++[[package]]+name = "ordered-stream"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9aa2b01e1d916879f73a53d01d1d6cee68adbb31d6d9177a8cfce093cced1d50"+dependencies = [+ "futures-core",+ "pin-project-lite",+]++[[package]]+name = "osakit"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "732c71caeaa72c065bb69d7ea08717bd3f4863a4f451402fc9513e29dbd5261b"+dependencies = [+ "objc2",+ "objc2-foundation",+ "objc2-osa-kit",+ "serde",+ "serde_json",+ "thiserror 2.0.21",+]++[[package]]+name = "pango"+version = "0.18.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7ca27ec1eb0457ab26f3036ea52229edbdb74dee1edd29063f5b9b010e7ebee4"+dependencies = [+ "gio",+ "glib",+ "libc",+ "once_cell",+ "pango-sys",+]++[[package]]+name = "pango-sys"+version = "0.18.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "436737e391a843e5933d6d9aa102cb126d501e815b83601365a948a518555dc5"+dependencies = [+ "glib-sys",+ "gobject-sys",+ "libc",+ "system-deps",+]++[[package]]+name = "parking"+version = "2.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba"++[[package]]+name = "parking_lot"+version = "0.12.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "93857453250e3077bd71ff98b6a65ea6621a19bb0f559a85248955ac12c45a1a"+dependencies = [+ "lock_api",+ "parking_lot_core",+]++[[package]]+name = "parking_lot_core"+version = "0.9.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2621685985a2ebf1c516881c026032ac7deafcda1a2c9b7850dc81e3dfcb64c1"+dependencies = [+ "cfg-if",+ "libc",+ "redox_syscall",+ "smallvec",+ "windows-link 0.2.1",+]++[[package]]+name = "percent-encoding"+version = "2.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220"++[[package]]+name = "phf"+version = "0.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c1562dc717473dbaa4c1f85a36410e03c047b2e7df7f45ee938fbef64ae7fadf"+dependencies = [+ "phf_macros",+ "phf_shared",+ "serde",+]++[[package]]+name = "phf_codegen"+version = "0.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "49aa7f9d80421bca176ca8dbfebe668cc7a2684708594ec9f3c0db0805d5d6e1"+dependencies = [+ "phf_generator",+ "phf_shared",+]++[[package]]+name = "phf_generator"+version = "0.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "135ace3a761e564ec88c03a77317a7c6b80bb7f7135ef2544dbe054243b89737"+dependencies = [+ "fastrand",+ "phf_shared",+]++[[package]]+name = "phf_macros"+version = "0.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "812f032b54b1e759ccd5f8b6677695d5268c588701effba24601f6932f8269ef"+dependencies = [+ "phf_generator",+ "phf_shared",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "phf_shared"+version = "0.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e57fef6bc5981e38c2ce2d63bfa546861309f875b8a75f092d1d54ae2d64f266"+dependencies = [+ "siphasher",+]++[[package]]+name = "pin-project-lite"+version = "0.2.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd"++[[package]]+name = "piper"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c835479a4443ded371d6c535cbfd8d31ad92c5d23ae9770a61bc155e4992a3c1"+dependencies = [+ "atomic-waker",+ "fastrand",+ "futures-io",+]++[[package]]+name = "pkg-config"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f6b464fbc74e149a392436b17d523f769e057cb6877f6a5c4618bc6f11800548"++[[package]]+name = "plist"+version = "1.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2896bade328c13f7042a297ea5ac5b0951f6cf989dea5f32c2fd98da398195cb"+dependencies = [+ "base64 0.23.1",+ "indexmap 2.14.2",+ "quick-xml",+ "serde",+ "time",+]++[[package]]+name = "png"+version = "0.17.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "82151a2fc869e011c153adc57cf2789ccb8d9906ce52c0b39a6b5697749d7526"+dependencies = [+ "bitflags 1.3.2",+ "crc32fast",+ "fdeflate",+ "flate2",+ "miniz_oxide 0.8.9",+]++[[package]]+name = "png"+version = "0.18.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61"+dependencies = [+ "bitflags 2.13.2",+ "crc32fast",+ "fdeflate",+ "flate2",+ "miniz_oxide 0.8.9",+]++[[package]]+name = "polling"+version = "3.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5d0e4f59085d47d8241c88ead0f274e8a0cb551f3625263c05eb8dd897c34218"+dependencies = [+ "cfg-if",+ "concurrent-queue",+ "hermit-abi",+ "pin-project-lite",+ "rustix",+ "windows-sys 0.61.2",+]++[[package]]+name = "portable-atomic"+version = "1.15.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "05c8b63e8d9609db387f0324918f81d68fe27748f084ef092fb35954d0539a85"++[[package]]+name = "portable-atomic-util"+version = "0.2.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "10ab3eb7f3becc3a1cbc4f2c6f20267996cfc1a6467a873763411b136a122715"+dependencies = [+ "portable-atomic",+]++[[package]]+name = "potential_utf"+version = "0.1.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d83eb9bc6d8e5cf568e7a1101d60ee05e81ed50ea106026f3d18deeb046d7661"+dependencies = [+ "zerovec",+]++[[package]]+name = "powerfmt"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391"++[[package]]+name = "precomputed-hash"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c"++[[package]]+name = "proc-macro-crate"+version = "1.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919"+dependencies = [+ "once_cell",+ "toml_edit 0.19.15",+]++[[package]]+name = "proc-macro-crate"+version = "2.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b00f26d3400549137f92511a46ac1cd8ce37cb5598a96d382381458b992a5d24"+dependencies = [+ "toml_datetime 0.6.3",+ "toml_edit 0.20.2",+]++[[package]]+name = "proc-macro-crate"+version = "3.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e67ba7e9b2b56446f1d419b1d807906278ffa1a658a8a5d8a39dcb1f5a78614f"+dependencies = [+ "toml_edit 0.25.15+spec-1.1.0",+]++[[package]]+name = "proc-macro-error"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c"+dependencies = [+ "proc-macro-error-attr",+ "proc-macro2",+ "quote",+ "syn 1.0.109",+ "version_check",+]++[[package]]+name = "proc-macro-error-attr"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869"+dependencies = [+ "proc-macro2",+ "quote",+ "version_check",+]++[[package]]+name = "proc-macro2"+version = "1.0.107"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "985e7ec9bb745e6ce6535b544d84d6cd6f7ad8bd711c398938ae983b91a766d9"+dependencies = [+ "unicode-ident",+]++[[package]]+name = "pxfm"+version = "0.1.30"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d55d956fa96f5ec02be2e13af0e20391a5aa83d6a074e3ad368959d0fab299ea"++[[package]]+name = "quick-xml"+version = "0.42.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "41b1177fdf999d2321d3fb46ff47159d9c1fb9ad66a4879f8c50a0b504615e9b"+dependencies = [+ "memchr",+]++[[package]]+name = "quote"+version = "1.0.47"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1fbf4db142a473a8d80c26bbf18454ed458bf8d26c8219c331daecfdbd079001"+dependencies = [+ "proc-macro2",+]++[[package]]+name = "r-efi"+version = "5.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f"++[[package]]+name = "r-efi"+version = "6.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf"++[[package]]+name = "rand"+version = "0.10.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "65c9fb96cbc91e3478eaae79a69fcd3f1ae4ad052e471fe6732fff548984b4af"+dependencies = [+ "chacha20",+ "getrandom 0.4.3",+ "rand_core",+]++[[package]]+name = "rand_core"+version = "0.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "63b8176103e19a2643978565ca18b50549f6101881c443590420e4dc998a3c69"++[[package]]+name = "raw-window-handle"+version = "0.6.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "20675572f6f24e9e76ef639bc5552774ed45f1c30e2951e1e99c59888861c539"++[[package]]+name = "redox_syscall"+version = "0.5.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d"+dependencies = [+ "bitflags 2.13.2",+]++[[package]]+name = "redox_users"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "60dc65c0ff1a7ae1294b0c67b9f14baf70b644404010370171787bfac1038fc0"+dependencies = [+ "libredox",+ "thiserror 2.0.21",+]++[[package]]+name = "ref-cast"+version = "1.0.27"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7e440fb4e4b4147295338efb76001ab9e4efc0e5839df2c47fc5ac2381d365c3"+dependencies = [+ "ref-cast-impl",+]++[[package]]+name = "ref-cast-impl"+version = "1.0.27"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "92ecd8964f8453721699a1ed72037b0db49ce2f5a5138486ee89bed6f67cdf3a"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "regex"+version = "1.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f020237b6c8eed93db2e2cb53c00c60a8e1bc73da7d073199a1180401450218d"+dependencies = [+ "aho-corasick",+ "memchr",+ "regex-automata",+ "regex-syntax",+]++[[package]]+name = "regex-automata"+version = "0.4.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ad8553b9b26413251cbf30e620595c7a41b3887f03da04579c0e6b0d6a06b4b2"+dependencies = [+ "aho-corasick",+ "memchr",+ "regex-syntax",+]++[[package]]+name = "regex-syntax"+version = "0.8.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4"++[[package]]+name = "reqwest"+version = "0.12.28"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "eddd3ca559203180a307f12d114c268abf583f59b03cb906fd0b3ff8646c1147"+dependencies = [+ "base64 0.22.1",+ "bytes",+ "futures-core",+ "http",+ "http-body",+ "http-body-util",+ "hyper",+ "hyper-tls",+ "hyper-util",+ "js-sys",+ "log",+ "native-tls",+ "percent-encoding",+ "pin-project-lite",+ "rustls-pki-types",+ "serde",+ "serde_json",+ "serde_urlencoded",+ "sync_wrapper",+ "tokio",+ "tokio-native-tls",+ "tower",+ "tower-http",+ "tower-service",+ "url",+ "wasm-bindgen",+ "wasm-bindgen-futures",+ "web-sys",+]++[[package]]+name = "reqwest"+version = "0.13.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "16a1cfa75cc186dd73d5818e510e042e40927bccc9c236b061cea97e1eb08029"+dependencies = [+ "base64 0.23.1",+ "bytes",+ "futures-core",+ "futures-util",+ "http",+ "http-body",+ "http-body-util",+ "hyper",+ "hyper-tls",+ "hyper-util",+ "js-sys",+ "log",+ "native-tls",+ "percent-encoding",+ "pin-project-lite",+ "rustls-pki-types",+ "serde",+ "serde_json",+ "sync_wrapper",+ "tokio",+ "tokio-native-tls",+ "tokio-util",+ "tower",+ "tower-http",+ "tower-service",+ "url",+ "wasm-bindgen",+ "wasm-bindgen-futures",+ "wasm-streams",+ "web-sys",+]++[[package]]+name = "rustc-hash"+version = "2.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d"++[[package]]+name = "rustc_version"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92"+dependencies = [+ "semver",+]++[[package]]+name = "rustix"+version = "1.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "891efababe418670775f199f0d233d84843c227a0949a883ce15b37c78d6629d"+dependencies = [+ "bitflags 2.13.2",+ "errno",+ "libc",+ "linux-raw-sys",+ "windows-sys 0.61.2",+]++[[package]]+name = "rustls-pki-types"+version = "1.15.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2f4925028c7eb5d1fcdaf196971378ed9d2c1c4efc7dc5d011256f76c99c0a96"+dependencies = [+ "zeroize",+]++[[package]]+name = "rustversion"+version = "1.0.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f"++[[package]]+name = "ryu"+version = "1.0.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9774ba4a74de5f7b1c1451ed6cd5285a32eddb5cccb8cc655a4e50009e06477f"++[[package]]+name = "same-file"+version = "1.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502"+dependencies = [+ "winapi-util",+]++[[package]]+name = "schannel"+version = "0.1.29"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "91c1b7e4904c873ef0710c1f407dde2e6287de2bebc1bbbf7d430bb7cbffd939"+dependencies = [+ "windows-sys 0.61.2",+]++[[package]]+name = "schemars"+version = "0.8.22"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3fbf2ae1b8bc8e02df939598064d22402220cd5bbcca1c76f7d6a310974d5615"+dependencies = [+ "dyn-clone",+ "indexmap 1.9.3",+ "schemars_derive",+ "serde",+ "serde_json",+ "url",+ "uuid",+]++[[package]]+name = "schemars"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4cd191f9397d57d581cddd31014772520aa448f65ef991055d7f61582c65165f"+dependencies = [+ "dyn-clone",+ "ref-cast",+ "serde",+ "serde_json",+]++[[package]]+name = "schemars"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "687274d293b6cdc6e73e0fee520bf2049650090d7164f87672d212a3c530cf4a"+dependencies = [+ "dyn-clone",+ "ref-cast",+ "serde",+ "serde_json",+]++[[package]]+name = "schemars_derive"+version = "0.8.22"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32e265784ad618884abaea0600a9adf15393368d840e0222d101a072f3f7534d"+dependencies = [+ "proc-macro2",+ "quote",+ "serde_derive_internals",+ "syn 2.0.119",+]++[[package]]+name = "scopeguard"+version = "1.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49"++[[package]]+name = "security-framework"+version = "3.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b7f4bc775c73d9a02cde8bf7b2ec4c9d12743edf609006c7facc23998404cd1d"+dependencies = [+ "bitflags 2.13.2",+ "core-foundation",+ "core-foundation-sys",+ "libc",+ "security-framework-sys",+]++[[package]]+name = "security-framework-sys"+version = "2.17.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ce2691df843ecc5d231c0b14ece2acc3efb62c0a398c7e1d875f3983ce020e3"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "selectors"+version = "0.38.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8adfa1c298912827b8a28b223b3b874357397ae706e6190acd9bf28cee99114d"+dependencies = [+ "bitflags 2.13.2",+ "cssparser",+ "derive_more",+ "log",+ "new_debug_unreachable",+ "phf",+ "phf_codegen",+ "precomputed-hash",+ "rustc-hash",+ "servo_arc",+ "smallvec",+]++[[package]]+name = "semver"+version = "1.0.28"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd"+dependencies = [+ "serde",+ "serde_core",+]++[[package]]+name = "serde"+version = "1.0.229"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4148590afebada386688f18773da617792bf2ef03ffc1e4cbd2b1d45b023e0ba"+dependencies = [+ "serde_core",+ "serde_derive",+]++[[package]]+name = "serde-untagged"+version = "0.1.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f9faf48a4a2d2693be24c6289dbe26552776eb7737074e6722891fadbe6c5058"+dependencies = [+ "erased-serde",+ "serde",+ "serde_core",+ "typeid",+]++[[package]]+name = "serde_core"+version = "1.0.229"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "67dca2c9c51e58a4791a4b1ed58308b39c64224d349a935ab5039aa360942a48"+dependencies = [+ "serde_derive",+]++[[package]]+name = "serde_derive"+version = "1.0.229"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e7a5d71263a5a7d47b41f6b3f06ba276f10cc18b0931f1799f710578e2309348"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "serde_derive_internals"+version = "0.29.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "18d26a20a969b9e3fdf2fc2d9f21eda6c40e2de84c9408bb5d3b05d499aae711"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "serde_json"+version = "1.0.151"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c841b55ecdae098c80dcae9cf767f6f8a0c2cdb3416bbef72181df4d0fe73f14"+dependencies = [+ "itoa",+ "memchr",+ "serde",+ "serde_core",+ "zmij",+]++[[package]]+name = "serde_repr"+version = "0.1.21"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8d3b1629de253c70a0508c3899572da79ca359fdab27c7920ff00406df418906"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "serde_spanned"+version = "0.6.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bf41e0cfaf7226dca15e8197172c295a782857fcb97fad1808a166870dee75a3"+dependencies = [+ "serde",+]++[[package]]+name = "serde_spanned"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6662b5879511e06e8999a8a235d848113e942c9124f211511b16466ee2995f26"+dependencies = [+ "serde_core",+]++[[package]]+name = "serde_urlencoded"+version = "0.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd"+dependencies = [+ "form_urlencoded",+ "itoa",+ "ryu",+ "serde",+]++[[package]]+name = "serde_with"+version = "3.24.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "df9adc193c780ef8f159aee8b61e2d5801aaa555e6eb0947fe45530ec506296f"+dependencies = [+ "base64 0.23.1",+ "bs58",+ "chrono",+ "hex",+ "indexmap 1.9.3",+ "indexmap 2.14.2",+ "jiff",+ "schemars 0.9.0",+ "schemars 1.2.2",+ "serde_core",+ "serde_json",+ "serde_with_macros",+ "time",+]++[[package]]+name = "serde_with_macros"+version = "3.24.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3e17bbc68e28663bbbb90df47e058aa7eda4fb445b89fe70457bb94fbccf6e49"+dependencies = [+ "darling",+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "serialize-to-javascript"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "04f3666a07a197cdb77cdf306c32be9b7f598d7060d50cfd4d5aa04bfd92f6c5"+dependencies = [+ "serde",+ "serde_json",+ "serialize-to-javascript-impl",+]++[[package]]+name = "serialize-to-javascript-impl"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "772ee033c0916d670af7860b6e1ef7d658a4629a6d0b4c8c3e67f09b3765b75d"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "servo_arc"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "170fb83ab34de17dc69aa7c67482b22218ddb85da56546f9bd6b929e32a05930"+dependencies = [+ "stable_deref_trait",+]++[[package]]+name = "sha1"+version = "0.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "aacc4cc499359472b4abe1bf11d0b12e688af9a805fa5e3016f9a386dc2d0214"+dependencies = [+ "cfg-if",+ "cpufeatures 0.3.1",+ "digest 0.11.3",+]++[[package]]+name = "sha2"+version = "0.10.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a7507d819769d01a365ab707794a4084392c824f54a7a6a7862f8c3d0892b283"+dependencies = [+ "cfg-if",+ "cpufeatures 0.2.17",+ "digest 0.10.7",+]++[[package]]+name = "shlex"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba"++[[package]]+name = "signal-hook-registry"+version = "1.4.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c4db69cba1110affc0e9f7bcd48bbf87b3f4fc7c61fc9155afd4c469eb3d6c1b"+dependencies = [+ "errno",+ "libc",+]++[[package]]+name = "simd-adler32"+version = "0.3.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3a219298ac11a56ea9a6d2120044824d6f01aeb034955e7af7bc16858527deea"++[[package]]+name = "siphasher"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "33f4fe9184a62d842c9ef383018f3306d8ba224fd9d836f56d7288308847c256"++[[package]]+name = "slab"+version = "0.4.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5"++[[package]]+name = "smallvec"+version = "1.16.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f9395f0f0eee849a9b707b2f06bb92a6a422090e2123bb2ef8e87a0e61892a8e"++[[package]]+name = "socket2"+version = "0.6.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c3d1e2c7f27f8d4cb10542a02c49005dbd6e93095799d6f3be745fae9f8fedd4"+dependencies = [+ "libc",+ "windows-sys 0.61.2",+]++[[package]]+name = "softbuffer"+version = "0.4.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "aac18da81ebbf05109ab275b157c22a653bb3c12cf884450179942f81bcbf6c3"+dependencies = [+ "bytemuck",+ "js-sys",+ "ndk",+ "objc2",+ "objc2-core-foundation",+ "objc2-core-graphics",+ "objc2-foundation",+ "objc2-quartz-core",+ "raw-window-handle",+ "redox_syscall",+ "tracing",+ "wasm-bindgen",+ "web-sys",+ "windows-sys 0.61.2",+]++[[package]]+name = "soup3"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "471f924a40f31251afc77450e781cb26d55c0b650842efafc9c6cbd2f7cc4f9f"+dependencies = [+ "futures-channel",+ "gio",+ "glib",+ "libc",+ "soup3-sys",+]++[[package]]+name = "soup3-sys"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7ebe8950a680a12f24f15ebe1bf70db7af98ad242d9db43596ad3108aab86c27"+dependencies = [+ "gio-sys",+ "glib-sys",+ "gobject-sys",+ "libc",+ "system-deps",+]++[[package]]+name = "stable_deref_trait"+version = "1.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596"++[[package]]+name = "string_cache"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a18596f8c785a729f2819c0f6a7eae6ebeebdfffbfe4214ae6b087f690e31901"+dependencies = [+ "new_debug_unreachable",+ "parking_lot",+ "phf_shared",+ "precomputed-hash",+]++[[package]]+name = "string_cache_codegen"+version = "0.6.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "585635e46db231059f76c5849798146164652513eb9e8ab2685939dd90f29b69"+dependencies = [+ "phf_generator",+ "phf_shared",+ "proc-macro2",+ "quote",+]++[[package]]+name = "strsim"+version = "0.11.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f"++[[package]]+name = "swift-rs"+version = "1.0.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e45c444e496845d3f2a351146bff59aae4975b2280238df1dfaa0c7d1846f38e"+dependencies = [+ "base64 0.21.7",+ "serde",+ "serde_json",+]++[[package]]+name = "syn"+version = "1.0.109"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237"+dependencies = [+ "proc-macro2",+ "unicode-ident",+]++[[package]]+name = "syn"+version = "2.0.119"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "872831b642d1a07999a962a351ed35b955ea2cfc8f3862091e2a240a84f17297"+dependencies = [+ "proc-macro2",+ "quote",+ "unicode-ident",+]++[[package]]+name = "syn"+version = "3.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8593e8e72159ed2257d083c7a454a85cbf854f37a0966d8d483aff8c8a3ebcee"+dependencies = [+ "proc-macro2",+ "quote",+ "unicode-ident",+]++[[package]]+name = "sync_wrapper"+version = "1.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0bf256ce5efdfa370213c1dabab5935a12e49f2c58d15e9eac2870d3b4f27263"+dependencies = [+ "futures-core",+]++[[package]]+name = "synstructure"+version = "0.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "901704edd0dfe137f1987838ee4f259e4e063c31371bdb423f7ae38ec6f77f02"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "system-deps"+version = "6.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a3e535eb8dded36d55ec13eddacd30dec501792ff23a0b1682c38601b8cf2349"+dependencies = [+ "cfg-expr",+ "heck 0.5.0",+ "pkg-config",+ "toml 0.8.2",+ "version-compare",+]++[[package]]+name = "tao"+version = "0.37.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f37f381f4e048e6cdf038b5705f8cf14ad108279d46eb968140a7b291aba9400"+dependencies = [+ "bitflags 2.13.2",+ "block2",+ "core-foundation",+ "core-graphics",+ "crossbeam-channel",+ "dbus",+ "dispatch2",+ "dlopen2",+ "dpi",+ "gdkwayland-sys",+ "gdkx11-sys",+ "gtk",+ "jni",+ "libc",+ "log",+ "ndk",+ "ndk-context",+ "ndk-sys",+ "objc2",+ "objc2-app-kit",+ "objc2-foundation",+ "objc2-ui-kit",+ "parking_lot",+ "percent-encoding",+ "raw-window-handle",+ "tao-macros",+ "unicode-segmentation",+ "url",+ "windows 0.62.2",+ "windows-core 0.62.2",+ "windows-version",+ "x11-dl",+]++[[package]]+name = "tao-macros"+version = "0.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5f7eeb6d99155545da6150a1795945f16ac9c178deb2a5f2e74d776107bd5849"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "tar"+version = "0.4.46"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3f6221d9a6003c78398e3b239969f352578258df48c8eb051caadae0015bc840"+dependencies = [+ "filetime",+ "libc",+ "xattr",+]++[[package]]+name = "target-lexicon"+version = "0.12.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1"++[[package]]+name = "tauri"+version = "2.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cb20ef8e6f97d6fe03039666cd82861f09a38b56291fa2f0f9fe140023f61c1a"+dependencies = [+ "anyhow",+ "bytes",+ "cookie",+ "dirs 7.0.0",+ "dunce",+ "embed_plist",+ "getrandom 0.3.4",+ "glob",+ "gtk",+ "heck 0.5.0",+ "http",+ "image",+ "jni",+ "libc",+ "log",+ "mime",+ "muda",+ "objc2",+ "objc2-app-kit",+ "objc2-foundation",+ "objc2-ui-kit",+ "objc2-web-kit",+ "percent-encoding",+ "plist",+ "raw-window-handle",+ "reqwest 0.13.5",+ "serde",+ "serde_json",+ "serde_repr",+ "serialize-to-javascript",+ "swift-rs",+ "tauri-build",+ "tauri-macros",+ "tauri-runtime",+ "tauri-runtime-wry",+ "tauri-utils",+ "thiserror 2.0.21",+ "tokio",+ "tray-icon",+ "url",+ "webkit2gtk",+ "webview2-com",+ "window-vibrancy",+ "windows 0.62.2",+]++[[package]]+name = "tauri-build"+version = "2.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5b5ae674f48836f5dd2eeaf9e221c095bd3e78a8d0439c77ca93b48740a1b644"+dependencies = [+ "anyhow",+ "cargo_toml",+ "dirs 7.0.0",+ "glob",+ "heck 0.5.0",+ "json-patch",+ "schemars 0.8.22",+ "semver",+ "serde",+ "serde_json",+ "tauri-utils",+ "tauri-winres",+ "walkdir",+]++[[package]]+name = "tauri-codegen"+version = "2.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3926b73ac01df7c14f19ff872cd56e67213a87acc0000ea37ddb300f3d11a3e3"+dependencies = [+ "base64 0.22.1",+ "brotli",+ "ico",+ "json-patch",+ "plist",+ "png 0.18.1",+ "proc-macro2",+ "quote",+ "semver",+ "serde",+ "serde_json",+ "sha2",+ "syn 2.0.119",+ "tauri-utils",+ "thiserror 2.0.21",+ "time",+ "url",+ "uuid",+ "walkdir",+]++[[package]]+name = "tauri-macros"+version = "2.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d21d0fa2c0529972ea6ecaf7404fcf40efac098eda0beb06ca682f41e33a6aa5"+dependencies = [+ "heck 0.5.0",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+ "tauri-codegen",+ "tauri-utils",+]++[[package]]+name = "tauri-plugin"+version = "2.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c9ff3ebb9fda56ceb93d46f6cbb126bae82951bf43498543a5163dde5def49a1"+dependencies = [+ "anyhow",+ "glob",+ "plist",+ "schemars 0.8.22",+ "serde",+ "serde_json",+ "tauri-utils",+ "walkdir",+]++[[package]]+name = "tauri-plugin-opener"+version = "2.5.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "60d60366174b745b4ef5824b8bbc1c457fd08f0ce101ff643c0a49181a9f4e91"+dependencies = [+ "dunce",+ "glob",+ "objc2-app-kit",+ "objc2-foundation",+ "open",+ "schemars 0.8.22",+ "serde",+ "serde_json",+ "tauri",+ "tauri-plugin",+ "thiserror 2.0.21",+ "url",+ "windows 0.61.3",+ "zbus",+]++[[package]]+name = "tauri-plugin-single-instance"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8bed24ed0f31939002fad4568e04ba87ba717cd22f85318b867fc427ab88e11b"+dependencies = [+ "serde",+ "serde_json",+ "tauri",+ "thiserror 2.0.21",+ "tokio",+ "tracing",+ "windows-sys 0.60.2",+ "zbus",+]++[[package]]+name = "tauri-plugin-updater"+version = "2.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7a5cad8ed5948d988e1018ecd31e27cacedbf72ce3fb972940c3e4bf51639e4b"+dependencies = [+ "base64 0.22.1",+ "dirs 6.0.0",+ "flate2",+ "futures-util",+ "http",+ "infer 0.19.0",+ "log",+ "minisign-verify",+ "osakit",+ "percent-encoding",+ "reqwest 0.13.5",+ "semver",+ "serde",+ "serde_json",+ "tar",+ "tauri",+ "tauri-plugin",+ "tempfile",+ "thiserror 2.0.21",+ "time",+ "tokio",+ "url",+ "windows-sys 0.60.2",+]++[[package]]+name = "tauri-runtime"+version = "2.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c9e6d5ef76985b32ff012a43b58df205d25a285e400ca878afcacddc5d5f3238"+dependencies = [+ "cookie",+ "dpi",+ "gtk",+ "http",+ "jni",+ "objc2",+ "objc2-ui-kit",+ "objc2-web-kit",+ "raw-window-handle",+ "serde",+ "serde_json",+ "tauri-utils",+ "thiserror 2.0.21",+ "url",+ "webkit2gtk",+ "webview2-com",+ "windows 0.62.2",+]++[[package]]+name = "tauri-runtime-wry"+version = "2.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fa829eb69860cf1fb0bedb21d2d5f1effce3527d054a68ca1cd7355c654400a3"+dependencies = [+ "gtk",+ "http",+ "jni",+ "log",+ "objc2",+ "objc2-app-kit",+ "once_cell",+ "percent-encoding",+ "raw-window-handle",+ "softbuffer",+ "tao",+ "tauri-runtime",+ "tauri-utils",+ "url",+ "webkit2gtk",+ "webview2-com",+ "windows 0.62.2",+ "wry",+]++[[package]]+name = "tauri-utils"+version = "2.10.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4dd257082deff79550de3409ed146104aeaf86fe38649615b04a304144939677"+dependencies = [+ "anyhow",+ "brotli",+ "cargo_metadata",+ "ctor",+ "dom_query",+ "dunce",+ "glob",+ "http",+ "infer 0.22.0",+ "json-patch",+ "log",+ "memchr",+ "phf",+ "plist",+ "proc-macro2",+ "quote",+ "regex",+ "schemars 0.8.22",+ "semver",+ "serde",+ "serde-untagged",+ "serde_json",+ "serde_with",+ "swift-rs",+ "thiserror 2.0.21",+ "toml 1.1.6+spec-1.1.0",+ "url",+ "urlpattern",+ "uuid",+ "walkdir",+]++[[package]]+name = "tauri-winres"+version = "0.3.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cc65d45c68858bfe420dd29e834b5d15dbecf8a07a8a16cf4d532c7b1f69d4b6"+dependencies = [+ "dunce",+ "embed-resource",+ "toml 1.1.6+spec-1.1.0",+]++[[package]]+name = "tempfile"+version = "3.27.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd"+dependencies = [+ "fastrand",+ "getrandom 0.4.3",+ "once_cell",+ "rustix",+ "windows-sys 0.61.2",+]++[[package]]+name = "tendril"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5fed54709c5b3a53d09bb1c113ea4f5ceafd1e772ddcb0030a82e1d56c087b08"+dependencies = [+ "new_debug_unreachable",+]++[[package]]+name = "thiserror"+version = "1.0.69"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52"+dependencies = [+ "thiserror-impl 1.0.69",+]++[[package]]+name = "thiserror"+version = "2.0.21"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "09e52cb86a36cede5cb101bf8908837b3e4c6e5e59fe7fd85c23fb56200d189e"+dependencies = [+ "thiserror-impl 2.0.21",+]++[[package]]+name = "thiserror-impl"+version = "1.0.69"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "thiserror-impl"+version = "2.0.21"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fe5197923287db20a58125f0bc85c062f7f2c892de97b18c356f9efb14b28524"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "time"+version = "0.3.55"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cdb87b95ec50ddfa440816d227a17b2ccbdda963a316a727fda0fc4334f7d134"+dependencies = [+ "deranged",+ "num-conv",+ "powerfmt",+ "serde_core",+ "time-core",+ "time-macros",+]++[[package]]+name = "time-core"+version = "0.1.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9e1c906769ad99c88eaa54e728060edef082f8e358ff32030cb7c7d315e81109"++[[package]]+name = "time-macros"+version = "0.2.32"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7e689342a48d2ea927c87ea50cabf8594854bf940e9310208848d680d668ed85"+dependencies = [+ "num-conv",+ "time-core",+]++[[package]]+name = "tinystr"+version = "0.8.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b1e27c91459209c2986af3dcf603a5a74a4368754ce37414f59acc971167f643"+dependencies = [+ "displaydoc",+ "zerovec",+]++[[package]]+name = "tinyvec"+version = "1.13.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fd3ca314f692efd6c868f8408f53fe444634a845f96c028b97d35f6a1f79f0ee"++[[package]]+name = "tokio"+version = "1.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "202caea871b69668250d242070849eb495be178ed697a3e98aebce5bc81a0bed"+dependencies = [+ "bytes",+ "libc",+ "mio",+ "pin-project-lite",+ "signal-hook-registry",+ "socket2",+ "tokio-macros",+ "windows-sys 0.61.2",+]++[[package]]+name = "tokio-macros"+version = "2.7.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "78773a2a397f451582ce068015985c33193cf6dea8b74d2a639fe457b2f07b0e"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "tokio-native-tls"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2"+dependencies = [+ "native-tls",+ "tokio",+]++[[package]]+name = "tokio-tungstenite"+version = "0.30.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "17a073bfed563fa236697a068031408a93cd9522e08abf9933ead3e73411bd71"+dependencies = [+ "futures-util",+ "log",+ "tokio",+ "tungstenite",+]++[[package]]+name = "tokio-util"+version = "0.7.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "494815d09bf52b5548659851081238f0ca39ff638363907596da739561c62c52"+dependencies = [+ "bytes",+ "futures-core",+ "futures-sink",+ "pin-project-lite",+ "tokio",+]++[[package]]+name = "toml"+version = "0.8.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "185d8ab0dfbb35cf1399a6344d8484209c088f75f8f68230da55d48d95d43e3d"+dependencies = [+ "serde",+ "serde_spanned 0.6.9",+ "toml_datetime 0.6.3",+ "toml_edit 0.20.2",+]++[[package]]+name = "toml"+version = "1.1.6+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "920602543f0911ab71da12c50d59701da54c196d1a2bf5cb4b75667f137a406a"+dependencies = [+ "indexmap 2.14.2",+ "serde_core",+ "serde_spanned 1.1.1",+ "toml_datetime 1.1.1+spec-1.1.0",+ "toml_parser",+ "toml_writer",+ "winnow 1.0.4",+]++[[package]]+name = "toml_datetime"+version = "0.6.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b"+dependencies = [+ "serde",+]++[[package]]+name = "toml_datetime"+version = "1.1.1+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3165f65f62e28e0115a00b2ebdd37eb6f3b641855f9d636d3cd4103767159ad7"+dependencies = [+ "serde_core",+]++[[package]]+name = "toml_edit"+version = "0.19.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421"+dependencies = [+ "indexmap 2.14.2",+ "toml_datetime 0.6.3",+ "winnow 0.5.40",+]++[[package]]+name = "toml_edit"+version = "0.20.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338"+dependencies = [+ "indexmap 2.14.2",+ "serde",+ "serde_spanned 0.6.9",+ "toml_datetime 0.6.3",+ "winnow 0.5.40",+]++[[package]]+name = "toml_edit"+version = "0.25.15+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1340ea94a5856333492c9064b02c778b191dd2c853778d9609debdcdfea3a614"+dependencies = [+ "indexmap 2.14.2",+ "toml_datetime 1.1.1+spec-1.1.0",+ "toml_parser",+ "winnow 1.0.4",+]++[[package]]+name = "toml_parser"+version = "1.1.3+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1d38ac1cf9b95face32296c0a3ede1fdc270627c9d9c02a7274dd6d960dc4d56"+dependencies = [+ "winnow 1.0.4",+]++[[package]]+name = "toml_writer"+version = "1.1.2+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7d56353a2a665ad0f41a421187180aab746c8c325620617ad883a99a1cbe66d2"++[[package]]+name = "tower"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ebe5ef63511595f1344e2d5cfa636d973292adc0eec1f0ad45fae9f0851ab1d4"+dependencies = [+ "futures-core",+ "futures-util",+ "pin-project-lite",+ "sync_wrapper",+ "tokio",+ "tower-layer",+ "tower-service",+]++[[package]]+name = "tower-http"+version = "0.6.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4cfcf7e2740e6fc6d4d688b4ef00650406bb94adf4731e43c096c3a19fe40840"+dependencies = [+ "bitflags 2.13.2",+ "bytes",+ "futures-util",+ "http",+ "http-body",+ "pin-project-lite",+ "tower",+ "tower-layer",+ "tower-service",+ "url",+]++[[package]]+name = "tower-layer"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e"++[[package]]+name = "tower-service"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3"++[[package]]+name = "tracing"+version = "0.1.44"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100"+dependencies = [+ "pin-project-lite",+ "tracing-attributes",+ "tracing-core",+]++[[package]]+name = "tracing-attributes"+version = "0.1.31"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7490cfa5ec963746568740651ac6781f701c9c5ea257c58e057f3ba8cf69e8da"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "tracing-core"+version = "0.1.36"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a"+dependencies = [+ "once_cell",+]++[[package]]+name = "tray-icon"+version = "0.25.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b2b9c52859a94554803ccd4a24b98f74148ebc73b90676d783f3490b1bff9d72"+dependencies = [+ "crossbeam-channel",+ "dirs 7.0.0",+ "libappindicator",+ "muda",+ "objc2",+ "objc2-app-kit",+ "objc2-core-foundation",+ "objc2-core-graphics",+ "objc2-foundation",+ "once_cell",+ "png 0.18.1",+ "serde",+ "thiserror 2.0.21",+ "windows-sys 0.61.2",+]++[[package]]+name = "try-lock"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b"++[[package]]+name = "tungstenite"+version = "0.30.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e48ac77174b19c110a50ab2128b24215ac9cb40e0e12e093fb602d175c569d22"+dependencies = [+ "bytes",+ "data-encoding",+ "http",+ "httparse",+ "log",+ "rand",+ "sha1",+ "thiserror 2.0.21",+]++[[package]]+name = "typed-path"+version = "0.12.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8e28f89b80c87b8fb0cf04ab448d5dd0dd0ade2f8891bae878de66a75a28600e"++[[package]]+name = "typeid"+version = "1.0.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bc7d623258602320d5c55d1bc22793b57daff0ec7efc270ea7d55ce1d5f5471c"++[[package]]+name = "typenum"+version = "1.20.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6f5e870be6c3b371b77fe0ee0bafb859fa4964b4404c27de1d380043c4dda20"++[[package]]+name = "uds_windows"+version = "1.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f2f6fb2847f6742cd76af783a2a2c49e9375d0a111c7bef6f71cd9e738c72d6e"+dependencies = [+ "memoffset",+ "tempfile",+ "windows-sys 0.61.2",+]++[[package]]+name = "unicode-ident"+version = "1.0.26"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d245f478577f809a851594d02313b640fb437e0bb33866753cff937863096954"++[[package]]+name = "unicode-segmentation"+version = "1.13.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8"++[[package]]+name = "url"+version = "2.5.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ff67a8a4397373c3ef660812acab3268222035010ab8680ec4215f38ba3d0eed"+dependencies = [+ "form_urlencoded",+ "idna",+ "percent-encoding",+ "serde",+ "serde_derive",+]++[[package]]+name = "urlpattern"+version = "0.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "df16f50ef4cc145211879a3867ba757076b25dfee812040dcb0658bd9ae7904b"+dependencies = [+ "icu_properties",+ "regex",+ "serde",+ "url",+]++[[package]]+name = "utf8_iter"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be"++[[package]]+name = "uuid"+version = "1.26.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2ef6dac1e96601b4fb3acccccff2139741fcb757cb9a36089bf5be91cfb285ce"+dependencies = [+ "getrandom 0.4.3",+ "js-sys",+ "serde_core",+ "wasm-bindgen",+]++[[package]]+name = "vcpkg"+version = "0.2.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426"++[[package]]+name = "version-compare"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "03c2856837ef78f57382f06b2b8563a2f512f7185d732608fd9176cb3b8edf0e"++[[package]]+name = "version_check"+version = "0.9.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a"++[[package]]+name = "vswhom"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "be979b7f07507105799e854203b470ff7c78a1639e330a58f183b5fea574608b"+dependencies = [+ "libc",+ "vswhom-sys",+]++[[package]]+name = "vswhom-sys"+version = "0.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fb067e4cbd1ff067d1df46c9194b5de0e98efd2810bbc95c5d5e5f25a3231150"+dependencies = [+ "cc",+ "libc",+]++[[package]]+name = "walkdir"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b"+dependencies = [+ "same-file",+ "winapi-util",+]++[[package]]+name = "want"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e"+dependencies = [+ "try-lock",+]++[[package]]+name = "wasi"+version = "0.11.1+wasi-snapshot-preview1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b"++[[package]]+name = "wasip2"+version = "1.0.4+wasi-0.2.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487"+dependencies = [+ "wit-bindgen",+]++[[package]]+name = "wasm-bindgen"+version = "0.2.129"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9bb54f33acc68fd454578d9820b0bde1a1a3d17aa17bb7b6595806d02886d409"+dependencies = [+ "cfg-if",+ "once_cell",+ "rustversion",+ "wasm-bindgen-macro",+ "wasm-bindgen-shared",+]++[[package]]+name = "wasm-bindgen-futures"+version = "0.4.79"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3cbab34de2d982e9b48e18d216d04c4a6f641066ff19ffb699980f591ee3610e"+dependencies = [+ "js-sys",+ "tokio",+ "wasm-bindgen",+]++[[package]]+name = "wasm-bindgen-macro"+version = "0.2.129"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2e29d0c35b16e224a7eeb5cd2d25e3e1968fbd65604117b44d3b789d00ee8535"+dependencies = [+ "quote",+ "wasm-bindgen-macro-support",+]++[[package]]+name = "wasm-bindgen-macro-support"+version = "0.2.129"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6f501a8bc3719dba86ef8ae4728879c08001bea749eb1333ac5b91e040e2a6b7"+dependencies = [+ "bumpalo",+ "proc-macro2",+ "quote",+ "syn 3.0.6",+ "wasm-bindgen-shared",+]++[[package]]+name = "wasm-bindgen-shared"+version = "0.2.129"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23f0c9c52aa7cd7d77769a4cfe2a9adb1b331f489a41d912ce14513d5ab995c6"+dependencies = [+ "unicode-ident",+]++[[package]]+name = "wasm-streams"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9d1ec4f6517c9e11ae630e200b2b65d193279042e28edd4a2cda233e46670bbb"+dependencies = [+ "futures-util",+ "js-sys",+ "wasm-bindgen",+ "wasm-bindgen-futures",+ "web-sys",+]++[[package]]+name = "web-sys"+version = "0.3.106"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "88261b9deccee56594c11a3460c462c41f58d148598fe70ad77070126a68aba4"+dependencies = [+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "web-time"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5a6580f308b1fad9207618087a65c04e7a10bc77e02c8e84e9b00dd4b12fa0bb"+dependencies = [+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "web_atoms"+version = "0.2.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ba8b815c1b593dc0baf78dd0f4fc8fdb2de53198fb1163738093e9a311c33fb3"+dependencies = [+ "phf",+ "phf_codegen",+ "string_cache",+ "string_cache_codegen",+]++[[package]]+name = "webkit2gtk"+version = "2.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a1027150013530fb2eaf806408df88461ae4815a45c541c8975e61d6f2fc4793"+dependencies = [+ "bitflags 1.3.2",+ "cairo-rs",+ "gdk",+ "gdk-sys",+ "gio",+ "gio-sys",+ "glib",+ "glib-sys",+ "gobject-sys",+ "gtk",+ "gtk-sys",+ "javascriptcore-rs",+ "libc",+ "once_cell",+ "soup3",+ "webkit2gtk-sys",+]++[[package]]+name = "webkit2gtk-sys"+version = "2.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "916a5f65c2ef0dfe12fff695960a2ec3d4565359fdbb2e9943c974e06c734ea5"+dependencies = [+ "bitflags 1.3.2",+ "cairo-sys-rs",+ "gdk-sys",+ "gio-sys",+ "glib-sys",+ "gobject-sys",+ "gtk-sys",+ "javascriptcore-rs-sys",+ "libc",+ "pkg-config",+ "soup3-sys",+ "system-deps",+]++[[package]]+name = "webview2-com"+version = "0.39.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3f89fca7a704cee10dcb3654c1dbb8941d1783132f1917358af75bec37a7d7e6"+dependencies = [+ "webview2-com-macros",+ "webview2-com-sys",+ "windows 0.62.2",+ "windows-core 0.62.2",+]++[[package]]+name = "webview2-com-macros"+version = "0.8.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "67a921c1b6914c367b2b823cd4cde6f96beec77d30a939c8199bb377cf9b9b54"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "webview2-com-sys"+version = "0.39.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b3a07132775117d6065853d9d1178157b8c90e228de47129d6bce2c7edebedfb"+dependencies = [+ "thiserror 2.0.21",+ "windows 0.62.2",+ "windows-core 0.62.2",+]++[[package]]+name = "winapi"+version = "0.3.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419"+dependencies = [+ "winapi-i686-pc-windows-gnu",+ "winapi-x86_64-pc-windows-gnu",+]++[[package]]+name = "winapi-i686-pc-windows-gnu"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6"++[[package]]+name = "winapi-util"+version = "0.1.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22"+dependencies = [+ "windows-sys 0.61.2",+]++[[package]]+name = "winapi-x86_64-pc-windows-gnu"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"++[[package]]+name = "window-vibrancy"+version = "0.8.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "111e51caca442cafd9bab396628ac4d814880eaea4e63dfd76a12e9f342b5580"+dependencies = [+ "objc2",+ "objc2-app-kit",+ "objc2-core-foundation",+ "objc2-foundation",+ "objc2-quartz-core",+ "raw-window-handle",+ "windows-sys 0.61.2",+ "windows-version",+]++[[package]]+name = "windows"+version = "0.61.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9babd3a767a4c1aef6900409f85f5d53ce2544ccdfaa86dad48c91782c6d6893"+dependencies = [+ "windows-collections 0.2.0",+ "windows-core 0.61.2",+ "windows-future 0.2.1",+ "windows-link 0.1.3",+ "windows-numerics 0.2.0",+]++[[package]]+name = "windows"+version = "0.62.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "527fadee13e0c05939a6a05d5bd6eec6cd2e3dbd648b9f8e447c6518133d8580"+dependencies = [+ "windows-collections 0.3.2",+ "windows-core 0.62.2",+ "windows-future 0.3.2",+ "windows-numerics 0.3.1",+]++[[package]]+name = "windows-collections"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3beeceb5e5cfd9eb1d76b381630e82c4241ccd0d27f1a39ed41b2760b255c5e8"+dependencies = [+ "windows-core 0.61.2",+]++[[package]]+name = "windows-collections"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23b2d95af1a8a14a3c7367e1ed4fc9c20e0a26e79551b1454d72583c97cc6610"+dependencies = [+ "windows-core 0.62.2",+]++[[package]]+name = "windows-core"+version = "0.61.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c0fdd3ddb90610c7638aa2b3a3ab2904fb9e5cdbecc643ddb3647212781c4ae3"+dependencies = [+ "windows-implement",+ "windows-interface",+ "windows-link 0.1.3",+ "windows-result 0.3.4",+ "windows-strings 0.4.2",+]++[[package]]+name = "windows-core"+version = "0.62.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb"+dependencies = [+ "windows-implement",+ "windows-interface",+ "windows-link 0.2.1",+ "windows-result 0.4.1",+ "windows-strings 0.5.1",+]++[[package]]+name = "windows-future"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc6a41e98427b19fe4b73c550f060b59fa592d7d686537eebf9385621bfbad8e"+dependencies = [+ "windows-core 0.61.2",+ "windows-link 0.1.3",+ "windows-threading 0.1.0",+]++[[package]]+name = "windows-future"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e1d6f90251fe18a279739e78025bd6ddc52a7e22f921070ccdc67dde84c605cb"+dependencies = [+ "windows-core 0.62.2",+ "windows-link 0.2.1",+ "windows-threading 0.2.1",+]++[[package]]+name = "windows-implement"+version = "0.60.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "windows-interface"+version = "0.59.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "windows-link"+version = "0.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5e6ad25900d524eaabdbbb96d20b4311e1e7ae1699af4fb28c17ae66c80d798a"++[[package]]+name = "windows-link"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5"++[[package]]+name = "windows-numerics"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9150af68066c4c5c07ddc0ce30421554771e528bde427614c61038bc2c92c2b1"+dependencies = [+ "windows-core 0.61.2",+ "windows-link 0.1.3",+]++[[package]]+name = "windows-numerics"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6e2e40844ac143cdb44aead537bbf727de9b044e107a0f1220392177d15b0f26"+dependencies = [+ "windows-core 0.62.2",+ "windows-link 0.2.1",+]++[[package]]+name = "windows-result"+version = "0.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "56f42bd332cc6c8eac5af113fc0c1fd6a8fd2aa08a0119358686e5160d0586c6"+dependencies = [+ "windows-link 0.1.3",+]++[[package]]+name = "windows-result"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5"+dependencies = [+ "windows-link 0.2.1",+]++[[package]]+name = "windows-strings"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "56e6c93f3a0c3b36176cb1327a4958a0353d5d166c2a35cb268ace15e91d3b57"+dependencies = [+ "windows-link 0.1.3",+]++[[package]]+name = "windows-strings"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091"+dependencies = [+ "windows-link 0.2.1",+]++[[package]]+name = "windows-sys"+version = "0.45.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0"+dependencies = [+ "windows-targets 0.42.2",+]++[[package]]+name = "windows-sys"+version = "0.59.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b"+dependencies = [+ "windows-targets 0.52.6",+]++[[package]]+name = "windows-sys"+version = "0.60.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb"+dependencies = [+ "windows-targets 0.53.5",+]++[[package]]+name = "windows-sys"+version = "0.61.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc"+dependencies = [+ "windows-link 0.2.1",+]++[[package]]+name = "windows-targets"+version = "0.42.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071"+dependencies = [+ "windows_aarch64_gnullvm 0.42.2",+ "windows_aarch64_msvc 0.42.2",+ "windows_i686_gnu 0.42.2",+ "windows_i686_msvc 0.42.2",+ "windows_x86_64_gnu 0.42.2",+ "windows_x86_64_gnullvm 0.42.2",+ "windows_x86_64_msvc 0.42.2",+]++[[package]]+name = "windows-targets"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973"+dependencies = [+ "windows_aarch64_gnullvm 0.52.6",+ "windows_aarch64_msvc 0.52.6",+ "windows_i686_gnu 0.52.6",+ "windows_i686_gnullvm 0.52.6",+ "windows_i686_msvc 0.52.6",+ "windows_x86_64_gnu 0.52.6",+ "windows_x86_64_gnullvm 0.52.6",+ "windows_x86_64_msvc 0.52.6",+]++[[package]]+name = "windows-targets"+version = "0.53.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3"+dependencies = [+ "windows-link 0.2.1",+ "windows_aarch64_gnullvm 0.53.1",+ "windows_aarch64_msvc 0.53.1",+ "windows_i686_gnu 0.53.1",+ "windows_i686_gnullvm 0.53.1",+ "windows_i686_msvc 0.53.1",+ "windows_x86_64_gnu 0.53.1",+ "windows_x86_64_gnullvm 0.53.1",+ "windows_x86_64_msvc 0.53.1",+]++[[package]]+name = "windows-threading"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b66463ad2e0ea3bbf808b7f1d371311c80e115c0b71d60efc142cafbcfb057a6"+dependencies = [+ "windows-link 0.1.3",+]++[[package]]+name = "windows-threading"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3949bd5b99cafdf1c7ca86b43ca564028dfe27d66958f2470940f73d86d75b37"+dependencies = [+ "windows-link 0.2.1",+]++[[package]]+name = "windows-version"+version = "0.1.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e4060a1da109b9d0326b7262c8e12c84df67cc0dbc9e33cf49e01ccc2eb63631"+dependencies = [+ "windows-link 0.2.1",+]++[[package]]+name = "windows_aarch64_gnullvm"+version = "0.42.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "597a5118570b68bc08d8d59125332c54f1ba9d9adeedeef5b99b02ba2b0698f8"++[[package]]+name = "windows_aarch64_gnullvm"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3"++[[package]]+name = "windows_aarch64_gnullvm"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53"++[[package]]+name = "windows_aarch64_msvc"+version = "0.42.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43"++[[package]]+name = "windows_aarch64_msvc"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469"++[[package]]+name = "windows_aarch64_msvc"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006"++[[package]]+name = "windows_i686_gnu"+version = "0.42.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c61d927d8da41da96a81f029489353e68739737d3beca43145c8afec9a31a84f"++[[package]]+name = "windows_i686_gnu"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b"++[[package]]+name = "windows_i686_gnu"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3"++[[package]]+name = "windows_i686_gnullvm"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66"++[[package]]+name = "windows_i686_gnullvm"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c"++[[package]]+name = "windows_i686_msvc"+version = "0.42.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060"++[[package]]+name = "windows_i686_msvc"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66"++[[package]]+name = "windows_i686_msvc"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2"++[[package]]+name = "windows_x86_64_gnu"+version = "0.42.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8de912b8b8feb55c064867cf047dda097f92d51efad5b491dfb98f6bbb70cb36"++[[package]]+name = "windows_x86_64_gnu"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78"++[[package]]+name = "windows_x86_64_gnu"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499"++[[package]]+name = "windows_x86_64_gnullvm"+version = "0.42.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3"++[[package]]+name = "windows_x86_64_gnullvm"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d"++[[package]]+name = "windows_x86_64_gnullvm"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1"++[[package]]+name = "windows_x86_64_msvc"+version = "0.42.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0"++[[package]]+name = "windows_x86_64_msvc"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"++[[package]]+name = "windows_x86_64_msvc"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650"++[[package]]+name = "winnow"+version = "0.5.40"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876"+dependencies = [+ "memchr",+]++[[package]]+name = "winnow"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23b97319f7b8343df12cc98938e5c3eb436064524c8d2b4e30a1d3a36eecdf81"+dependencies = [+ "memchr",+]++[[package]]+name = "winreg"+version = "0.55.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cb5a765337c50e9ec252c2069be9bf91c7df47afb103b642ba3a53bf8101be97"+dependencies = [+ "cfg-if",+ "windows-sys 0.59.0",+]++[[package]]+name = "winreg"+version = "0.56.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7d6f32a0ff4a9f6f01231eb2059cc85479330739333e0e58cadf03b6af2cca10"+dependencies = [+ "cfg-if",+ "windows-sys 0.61.2",+]++[[package]]+name = "wit-bindgen"+version = "0.57.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e"++[[package]]+name = "writeable"+version = "0.6.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3ad82d2a33cdc9674dc7465672f271e096168fcdbe0f799d9e6db8c5892679dc"++[[package]]+name = "wry"+version = "0.57.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a819957a01b3119af85e638a38d242af76dbc87d130dca67bfd0441072e21ff0"+dependencies = [+ "base64 0.22.1",+ "block2",+ "cookie",+ "crossbeam-channel",+ "dirs 7.0.0",+ "dom_query",+ "dpi",+ "dunce",+ "gdkx11",+ "gtk",+ "http",+ "javascriptcore-rs",+ "jni",+ "libc",+ "ndk",+ "objc2",+ "objc2-app-kit",+ "objc2-core-foundation",+ "objc2-foundation",+ "objc2-ui-kit",+ "objc2-web-kit",+ "once_cell",+ "percent-encoding",+ "raw-window-handle",+ "sha2",+ "soup3",+ "tao-macros",+ "thiserror 2.0.21",+ "url",+ "webkit2gtk",+ "webkit2gtk-sys",+ "webview2-com",+ "windows 0.62.2",+ "windows-core 0.62.2",+ "windows-version",+ "x11-dl",+]++[[package]]+name = "x11"+version = "2.21.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "502da5464ccd04011667b11c435cb992822c2c0dbde1770c988480d312a0db2e"+dependencies = [+ "libc",+ "pkg-config",+]++[[package]]+name = "x11-dl"+version = "2.21.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "38735924fedd5314a6e548792904ed8c6de6636285cb9fec04d5b1db85c1516f"+dependencies = [+ "libc",+ "once_cell",+ "pkg-config",+]++[[package]]+name = "xattr"+version = "1.6.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32e45ad4206f6d2479085147f02bc2ef834ac85886624a23575ae137c8aa8156"+dependencies = [+ "libc",+ "rustix",+]++[[package]]+name = "yoke"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "709fe23a0424b6a435d82152b1bd3fdfb0833487d5fa90d05d42762a9891fef5"+dependencies = [+ "stable_deref_trait",+ "yoke-derive",+ "zerofrom",+]++[[package]]+name = "yoke-derive"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "33811428bee40dbceb6d545e95754741d17a6aef9a4849f0fd62e2ba4f412a78"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+ "synstructure",+]++[[package]]+name = "zbus"+version = "5.19.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5db4be7c075cb421e4b7ee645541604239bd243ba7c357511f4ff3a74b555907"+dependencies = [+ "async-broadcast",+ "async-executor",+ "async-io",+ "async-lock",+ "async-process",+ "async-recursion",+ "async-task",+ "async-trait",+ "blocking",+ "enumflags2",+ "event-listener",+ "futures-core",+ "futures-lite",+ "hex",+ "libc",+ "ordered-stream",+ "rustix",+ "serde",+ "serde_repr",+ "tracing",+ "uds_windows",+ "uuid",+ "windows-sys 0.61.2",+ "winnow 1.0.4",+ "zbus_macros",+ "zbus_names",+ "zvariant",+]++[[package]]+name = "zbus_macros"+version = "5.19.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2990635d09ade6df1868f72f8cac69a876a90981e8bd3c40b1be413f8dc88f40"+dependencies = [+ "proc-macro-crate 3.5.0",+ "proc-macro2",+ "quote",+ "syn 3.0.6",+ "zbus_names",+ "zvariant",+ "zvariant_utils",+]++[[package]]+name = "zbus_names"+version = "4.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d8bf88b4a3ff53e883001e0e0115b297a9d53c31b9c1edd2bfdd853e3428624e"+dependencies = [+ "serde",+ "winnow 1.0.4",+ "zvariant",+]++[[package]]+name = "zcheapstr"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d1afec51604565183aeb5c54c20aeab286120d4e4460f7f76e3e8bb8c0d99473"+dependencies = [+ "serde",+]++[[package]]+name = "zerofrom"+version = "0.1.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ec05a11813ea801ff6d75110ad09cd0824ddba17dfe17128ea0d5f68e6c5272"+dependencies = [+ "zerofrom-derive",+]++[[package]]+name = "zerofrom-derive"+version = "0.1.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f75b4683f6c7f45248d4d64056a24298c6281e0993356d7d1b4a1a962ef10d4a"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+ "synstructure",+]++[[package]]+name = "zeroize"+version = "1.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e13c156562582aa81c60cb29407084cdb54c4164760106ab78e6c5b0858cf64e"++[[package]]+name = "zerotrie"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4ea269c3bd32f0a32c321907a2ae912ba6f4649bb0fc764a15627e99a7095a3f"+dependencies = [+ "displaydoc",+ "yoke",+ "zerofrom",+]++[[package]]+name = "zerovec"+version = "0.11.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bb0464e17806c1d976d5cba29399c7f08e516e279e2ba493f63123b5fca67dd8"+dependencies = [+ "yoke",+ "zerofrom",+ "zerovec-derive",+]++[[package]]+name = "zerovec-derive"+version = "0.11.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "34df6fc39dbd26ddc9c10e6a2984476e13acce22e64e4487636ef494369225da"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.6",+]++[[package]]+name = "zip"+version = "8.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2d04a6b5381502aa6087c94c669499eb1602eb9c5e8198e534de571f7154809b"+dependencies = [+ "crc32fast",+ "flate2",+ "indexmap 2.14.2",+ "memchr",+ "typed-path",+ "zopfli",+]++[[package]]+name = "zlib-rs"+version = "0.6.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b268e58e7c693d7c271f93ffc4ba3b380412554231c85bf61ca7af91042a4112"++[[package]]+name = "zmij"+version = "1.0.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b"++[[package]]+name = "zopfli"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f05cd8797d63865425ff89b5c4a48804f35ba0ce8d125800027ad6017d2b5249"+dependencies = [+ "bumpalo",+ "crc32fast",+ "log",+ "simd-adler32",+]++[[package]]+name = "zvariant"+version = "5.15.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c1d34c27cc6cdd1f458427519dd6b8612f7b7e3f7b9a0b2355d041dda9869147"+dependencies = [+ "endi",+ "enumflags2",+ "serde",+ "winnow 1.0.4",+ "zcheapstr",+ "zvariant_derive",+ "zvariant_utils",+]++[[package]]+name = "zvariant_derive"+version = "5.15.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "864155e69b4352db0c7f374917bf45d1e0c8d17659c8b3dbf9795f3673f8c497"+dependencies = [+ "proc-macro-crate 3.5.0",+ "proc-macro2",+ "quote",+ "syn 3.0.6",+ "zvariant_utils",+]++[[package]]+name = "zvariant_utils"+version = "4.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bad0294361a320b694a328460dc73add56c306150f5cb6bfafc44446120008a3"+dependencies = [+ "proc-macro2",+ "quote",+ "serde",+ "syn 3.0.6",+ "winnow 1.0.4",+]diff --git a/src/windows/Cargo.toml b/src/windows/Cargo.tomlnew file mode 100644index 0000000..0b7b7e3--- /dev/null+++ b/src/windows/Cargo.toml@@ -0,0 +1,10 @@+[workspace]+members = ["src-tauri", "launcher"]+resolver = "2"++[profile.release]+codegen-units = 1+lto = true+opt-level = "s"+panic = "abort"+strip = truediff --git a/src/windows/index.html b/src/windows/index.htmlnew file mode 100644index 0000000..eac7594--- /dev/null+++ b/src/windows/index.html@@ -0,0 +1,12 @@+<!doctype html>+<html lang="en" data-theme="ember">+ <head>+ <meta charset="UTF-8" />+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />+ <title>Browsentic</title>+ </head>+ <body>+ <div id="root"></div>+ <script type="module" src="/ui/main.tsx"></script>+ </body>+</html>diff --git a/src/windows/launcher/Cargo.toml b/src/windows/launcher/Cargo.tomlnew file mode 100644index 0000000..af6bea7--- /dev/null+++ b/src/windows/launcher/Cargo.toml@@ -0,0 +1,21 @@+[package]+name = "browsentic-launcher"+version = "0.0.0"+edition = "2021"+publish = false++[[bin]]+name = "browsentic"+path = "src/main.rs"++[dependencies]+serde_json = "1"++[target.'cfg(windows)'.dependencies]+windows-sys = { version = "0.61", features = [+ "Win32_Foundation",+ "Win32_Security",+ "Win32_System_Console",+ "Win32_System_JobObjects",+ "Win32_System_Threading",+] }diff --git a/src/windows/launcher/src/main.rs b/src/windows/launcher/src/main.rsnew file mode 100644index 0000000..c5c19d0--- /dev/null+++ b/src/windows/launcher/src/main.rs@@ -0,0 +1,100 @@+use std::env;+use std::ffi::OsString;+use std::fs;+use std::path::{Path, PathBuf};+use std::process::Command;++const NODE: &str = if cfg!(windows) { "node.exe" } else { "node" };+const MISSING_NODE: &str =+ "browsentic: Node.js 20 or newer is missing. Open the Browsentic app and it will install it.";++fn main() {+ let Some(state) = home().map(|home| home.join(".browsentic")) else {+ fail("browsentic: cannot find your home folder.")+ };+ let Some(node) = node(&state) else { fail(MISSING_NODE) };++ let mut args: Vec<OsString> = env::args_os().skip(1).collect();+ if args.is_empty() && invoked_as("browsentic-mcp") {+ args.push("mcp".into());+ }++ let mut child = Command::new(&node)+ .arg(state.join("cli").join("dist").join("cli.js"))+ .args(args)+ .spawn()+ .unwrap_or_else(|error| fail(&format!("browsentic: could not start {}: {error}", node.display())));+ platform::hand_over(&child);++ let status = child.wait().unwrap_or_else(|error| fail(&format!("browsentic: {error}")));+ std::process::exit(status.code().unwrap_or(1));+}++fn home() -> Option<PathBuf> {+ env::var_os(if cfg!(windows) { "USERPROFILE" } else { "HOME" }).map(PathBuf::from)+}++/// The Node the app recorded when it installed the CLI, then its private copy, then the user's own.+fn node(state: &Path) -> Option<PathBuf> {+ let recorded = fs::read_to_string(state.join("cli").join(".browsentic-app.json"))+ .ok()+ .and_then(|text| serde_json::from_str::<serde_json::Value>(&text).ok())+ .and_then(|marker| marker.get("node")?.as_str().map(PathBuf::from));+ let private = state.join("runtime").join("node").join(if cfg!(windows) { NODE } else { "bin/node" });+ [recorded, Some(private)]+ .into_iter()+ .flatten()+ .find(|path| path.is_file())+ .or_else(|| env::split_paths(&env::var_os("PATH")?).map(|dir| dir.join(NODE)).find(|path| path.is_file()))+}++fn invoked_as(name: &str) -> bool {+ env::args_os()+ .next()+ .map(PathBuf::from)+ .and_then(|path| path.file_stem().map(|stem| stem.to_string_lossy().eq_ignore_ascii_case(name)))+ .unwrap_or(false)+}++fn fail(message: &str) -> ! {+ eprintln!("{message}");+ std::process::exit(127)+}++#[cfg(windows)]+mod platform {+ use std::os::windows::io::AsRawHandle;+ use std::process::Child;+ use windows_sys::Win32::System::Console::SetConsoleCtrlHandler;+ use windows_sys::Win32::System::JobObjects::{+ AssignProcessToJobObject, CreateJobObjectW, JobObjectExtendedLimitInformation, SetInformationJobObject,+ JOBOBJECT_EXTENDED_LIMIT_INFORMATION, JOB_OBJECT_LIMIT_KILL_ON_JOB_CLOSE, JOB_OBJECT_LIMIT_SILENT_BREAKAWAY_OK,+ };++ /// Windows has no exec: Node stays this process's child. A job kills it with us, so a client+ /// that ends the launcher never leaves Node running, while everything Node starts (the daemon,+ /// an agent) breaks away and lives its own life. Ctrl+C is left to Node, which also receives it.+ pub fn hand_over(child: &Child) {+ unsafe {+ let job = CreateJobObjectW(std::ptr::null(), std::ptr::null());+ if !job.is_null() {+ let mut limits: JOBOBJECT_EXTENDED_LIMIT_INFORMATION = std::mem::zeroed();+ limits.BasicLimitInformation.LimitFlags =+ JOB_OBJECT_LIMIT_KILL_ON_JOB_CLOSE | JOB_OBJECT_LIMIT_SILENT_BREAKAWAY_OK;+ SetInformationJobObject(+ job,+ JobObjectExtendedLimitInformation,+ &limits as *const _ as *const _,+ std::mem::size_of::<JOBOBJECT_EXTENDED_LIMIT_INFORMATION>() as u32,+ );+ AssignProcessToJobObject(job, child.as_raw_handle() as _);+ }+ SetConsoleCtrlHandler(None, 1);+ }+ }+}++#[cfg(not(windows))]+mod platform {+ pub fn hand_over(_: &std::process::Child) {}+}diff --git a/src/windows/src-tauri/Cargo.toml b/src/windows/src-tauri/Cargo.tomlnew file mode 100644index 0000000..8a7dda1--- /dev/null+++ b/src/windows/src-tauri/Cargo.toml@@ -0,0 +1,34 @@+[package]+name = "browsentic-desktop"+version = "0.0.0"+edition = "2021"+publish = false++[[bin]]+name = "Browsentic"+path = "src/main.rs"++[build-dependencies]+tauri-build = { version = "2", features = [] }++[dependencies]+futures-util = { version = "0.3", default-features = false, features = ["sink", "std"] }+reqwest = { version = "0.12", default-features = false, features = ["json", "native-tls"] }+serde = { version = "1", features = ["derive"] }+serde_json = "1"+sha2 = "0.10"+tauri = { version = "~2.12", features = ["tray-icon", "image-png"] }+tauri-plugin-opener = "~2.5"+tauri-plugin-single-instance = "2"+tauri-plugin-updater = { version = "~2.12", default-features = false, features = ["native-tls"] }+time = { version = "0.3", features = ["formatting"] }+tokio = { version = "1", features = ["fs", "io-util", "macros", "net", "process", "rt", "sync", "time"] }+tokio-tungstenite = "0.30"+zip = { version = "8", default-features = false, features = ["deflate"] }++[target.'cfg(windows)'.dependencies]+windows-sys = { version = "0.61", features = ["Win32_Foundation", "Win32_System_Environment", "Win32_UI_WindowsAndMessaging"] }+winreg = "0.56"++[dev-dependencies]+tempfile = "3"diff --git a/src/windows/src-tauri/build.rs b/src/windows/src-tauri/build.rsnew file mode 100644index 0000000..d860e1e--- /dev/null+++ b/src/windows/src-tauri/build.rs@@ -0,0 +1,3 @@+fn main() {+ tauri_build::build()+}diff --git a/src/windows/src-tauri/capabilities/default.json b/src/windows/src-tauri/capabilities/default.jsonnew file mode 100644index 0000000..8be6c01--- /dev/null+++ b/src/windows/src-tauri/capabilities/default.json@@ -0,0 +1,12 @@+{+ "$schema": "../gen/schemas/desktop-schema.json",+ "identifier": "default",+ "description": "The Browsentic window: its own commands, events, and opening links and folders.",+ "windows": ["main"],+ "permissions": [+ "core:default",+ "core:window:allow-set-theme",+ "opener:allow-open-url",+ "opener:allow-reveal-item-in-dir"+ ]+}diff --git a/src/windows/src-tauri/icons/128x128.png b/src/windows/src-tauri/icons/128x128.pngnew file mode 100644index 0000000..295e747Binary files /dev/null and b/src/windows/src-tauri/icons/128x128.png differdiff --git a/src/windows/src-tauri/icons/[email protected] b/src/windows/src-tauri/icons/[email protected]new file mode 100644index 0000000..f35656aBinary files /dev/null and b/src/windows/src-tauri/icons/[email protected] differdiff --git a/src/windows/src-tauri/icons/32x32.png b/src/windows/src-tauri/icons/32x32.pngnew file mode 100644index 0000000..9fed29aBinary files /dev/null and b/src/windows/src-tauri/icons/32x32.png differdiff --git a/src/windows/src-tauri/icons/icon.icns b/src/windows/src-tauri/icons/icon.icnsnew file mode 100644index 0000000..8369b4aBinary files /dev/null and b/src/windows/src-tauri/icons/icon.icns differdiff --git a/src/windows/src-tauri/icons/icon.ico b/src/windows/src-tauri/icons/icon.iconew file mode 100644index 0000000..769be69Binary files /dev/null and b/src/windows/src-tauri/icons/icon.ico differdiff --git a/src/windows/src-tauri/icons/icon.png b/src/windows/src-tauri/icons/icon.pngnew file mode 100644index 0000000..83431d4Binary files /dev/null and b/src/windows/src-tauri/icons/icon.png differdiff --git a/src/windows/src-tauri/installer-hooks.nsh b/src/windows/src-tauri/installer-hooks.nshnew file mode 100644index 0000000..5eb9d6a--- /dev/null+++ b/src/windows/src-tauri/installer-hooks.nsh@@ -0,0 +1,8 @@+; An update runs the old uninstaller too, with /UPDATE; only a real uninstall stops the daemon and+; takes browsentic off the PATH. What the daemon keeps in ~/.browsentic stays, as it does when the+; macOS app goes to the Trash; the app's own Uninstall removes that.+!macro NSIS_HOOK_PREUNINSTALL+ ${If} $UpdateMode <> 1+ ExecWait '"$INSTDIR\${MAINBINARYNAME}.exe" --uninstall'+ ${EndIf}+!macroenddiff --git a/src/windows/src-tauri/src/control.rs b/src/windows/src-tauri/src/control.rsnew file mode 100644index 0000000..3a9b7f2--- /dev/null+++ b/src/windows/src-tauri/src/control.rs@@ -0,0 +1,185 @@+use futures_util::stream::{SplitSink, StreamExt};+use futures_util::SinkExt;+use serde::{Deserialize, Serialize};+use serde_json::Value;+use std::collections::HashMap;+use std::sync::atomic::{AtomicBool, AtomicU64, Ordering};+use std::sync::Arc;+use std::time::Duration;+use tokio::net::TcpStream;+use tokio::sync::{oneshot, Mutex};+use tokio_tungstenite::tungstenite::client::IntoClientRequest;+use tokio_tungstenite::tungstenite::http::HeaderValue;+use tokio_tungstenite::tungstenite::Message;+use tokio_tungstenite::{connect_async, MaybeTlsStream, WebSocketStream};++use crate::paths::Paths;++#[derive(Serialize, Deserialize, Clone, Debug, PartialEq)]+#[serde(rename_all = "camelCase")]+pub struct Lockfile {+ pub pid: u32,+ pub port: u16,+ pub token: String,+ pub daemon_version: Option<String>,+}++pub fn read_lock(paths: &Paths) -> Option<Lockfile> {+ serde_json::from_str(&std::fs::read_to_string(paths.lockfile()).ok()?).ok()+}++pub const OFFLINE: &str = "The daemon is not running. Turn it on from the Overview tab.";+pub const TIMEOUT: &str = "The daemon did not answer in time. Restart it from the Overview tab.";++type Sink = SplitSink<WebSocketStream<MaybeTlsStream<TcpStream>>, Message>;+type Pending = Arc<std::sync::Mutex<HashMap<String, oneshot::Sender<Value>>>>;++struct Connection {+ lock: Lockfile,+ sink: Sink,+ pending: Pending,+ open: Arc<AtomicBool>,+}++/// The daemon's `/control` socket, spoken natively: the same frames RemoteBridge sends, with the+/// bearer token from the lockfile, which a webview's own WebSocket has no way to send. Holding it+/// open is also what keeps the daemon from idling out.+#[derive(Default)]+pub struct Control {+ connection: Mutex<Option<Connection>>,+ next: AtomicU64,+}++impl Control {+ /// True when this opened a new socket, which has subscribed to nothing yet.+ pub async fn connect(&self, lock: Lockfile, on_event: impl Fn(String) + Send + 'static) -> Result<bool, String> {+ let mut slot = self.connection.lock().await;+ if slot.as_ref().is_some_and(|live| live.lock == lock && live.open.load(Ordering::SeqCst)) {+ return Ok(false);+ }+ *slot = None;++ let mut request = format!("ws://127.0.0.1:{}/control", lock.port).into_client_request().map_err(|error| error.to_string())?;+ let bearer = HeaderValue::from_str(&format!("Bearer {}", lock.token)).map_err(|error| error.to_string())?;+ request.headers_mut().insert("Authorization", bearer);+ let (stream, _) = tokio::time::timeout(Duration::from_secs(5), connect_async(request))+ .await+ .map_err(|_| OFFLINE.to_string())?+ .map_err(|_| OFFLINE.to_string())?;+ let (sink, mut source) = stream.split();++ let pending: Pending = Arc::default();+ let open = Arc::new(AtomicBool::new(true));+ let (reader_pending, reader_open) = (pending.clone(), open.clone());+ tokio::spawn(async move {+ while let Some(Ok(message)) = source.next().await {+ let Message::Text(text) = message else { continue };+ let Ok(frame) = serde_json::from_str::<Value>(text.as_str()) else { continue };+ if let Some(event) = frame.get("event").and_then(Value::as_str) {+ on_event(event.to_string());+ }+ if let Some(id) = frame.get("id").and_then(Value::as_str) {+ if let Some(waiting) = reader_pending.lock().unwrap().remove(id) {+ let _ = waiting.send(frame);+ }+ }+ }+ reader_open.store(false, Ordering::SeqCst);+ reader_pending.lock().unwrap().clear();+ });++ *slot = Some(Connection { lock, sink, pending, open });+ Ok(true)+ }++ /// Sends one frame and waits for the frame that answers it, which is returned whole.+ pub async fn request(&self, mut frame: Value, timeout: Duration) -> Result<Value, String> {+ let id = format!("app-{}", self.next.fetch_add(1, Ordering::SeqCst));+ frame.as_object_mut().ok_or("A control frame is a JSON object.")?.insert("id".into(), Value::String(id.clone()));+ let (sender, receiver) = oneshot::channel();+ {+ let mut slot = self.connection.lock().await;+ let live = slot.as_mut().filter(|live| live.open.load(Ordering::SeqCst)).ok_or(OFFLINE)?;+ live.pending.lock().unwrap().insert(id.clone(), sender);+ if live.sink.send(Message::text(frame.to_string())).await.is_err() {+ live.open.store(false, Ordering::SeqCst);+ return Err(OFFLINE.into());+ }+ }+ match tokio::time::timeout(timeout, receiver).await {+ Ok(Ok(reply)) => Ok(reply),+ Ok(Err(_)) => Err(OFFLINE.into()),+ Err(_) => {+ if let Some(live) = self.connection.lock().await.as_ref() {+ live.pending.lock().unwrap().remove(&id);+ }+ Err(TIMEOUT.into())+ }+ }+ }++ pub async fn close(&self) {+ if let Some(mut live) = self.connection.lock().await.take() {+ let _ = live.sink.close().await;+ }+ }+}++#[cfg(test)]+mod tests {+ use super::*;+ use tokio::net::TcpListener;+ use tokio_tungstenite::tungstenite::handshake::server::{Request, Response};++ /// A daemon stand-in that insists on the bearer token, answers `status`, and announces an event.+ async fn daemon(token: &'static str) -> u16 {+ let listener = TcpListener::bind("127.0.0.1:0").await.unwrap();+ let port = listener.local_addr().unwrap().port();+ tokio::spawn(async move {+ while let Ok((stream, _)) = listener.accept().await {+ let checked = |request: &Request, response: Response| {+ let authorized = request.headers().get("Authorization").and_then(|value| value.to_str().ok()) == Some(&format!("Bearer {token}"));+ if authorized { Ok(response) } else { Err(Response::builder().status(401).body(None).unwrap()) }+ };+ let Ok(socket) = tokio_tungstenite::accept_hdr_async(stream, checked).await else { continue };+ let (mut sink, mut source) = socket.split();+ tokio::spawn(async move {+ while let Some(Ok(Message::Text(text))) = source.next().await {+ let frame: Value = serde_json::from_str(text.as_str()).unwrap();+ let reply = serde_json::json!({ "id": frame["id"], "op": "status", "status": { "port": port } });+ sink.send(Message::text(serde_json::json!({ "event": "settings-changed" }).to_string())).await.unwrap();+ sink.send(Message::text(reply.to_string())).await.unwrap();+ }+ });+ }+ });+ port+ }++ fn lock(port: u16, token: &str) -> Lockfile {+ Lockfile { pid: 1, port, token: token.into(), daemon_version: None }+ }++ #[tokio::test]+ async fn asks_with_the_token_and_matches_the_answer_to_the_question() {+ let port = daemon("secret").await;+ let control = Control::default();+ let events = Arc::new(std::sync::Mutex::new(Vec::new()));+ let heard = events.clone();++ assert!(control.connect(lock(port, "secret"), move |event| heard.lock().unwrap().push(event)).await.unwrap());+ assert!(!control.connect(lock(port, "secret"), |_| {}).await.unwrap());+ let reply = control.request(serde_json::json!({ "op": "status" }), Duration::from_secs(2)).await.unwrap();++ assert_eq!(reply["status"]["port"], port);+ assert_eq!(events.lock().unwrap().as_slice(), ["settings-changed"]);+ }++ #[tokio::test]+ async fn a_wrong_token_is_offline_and_a_request_without_a_socket_says_so() {+ let port = daemon("secret").await;+ let control = Control::default();+ assert_eq!(control.connect(lock(port, "guess"), |_| {}).await, Err(OFFLINE.into()));+ assert_eq!(control.request(serde_json::json!({ "op": "status" }), Duration::from_secs(1)).await, Err(OFFLINE.into()));+ }+}diff --git a/src/windows/src-tauri/src/main.rs b/src/windows/src-tauri/src/main.rsnew file mode 100644index 0000000..21ea607--- /dev/null+++ b/src/windows/src-tauri/src/main.rs@@ -0,0 +1,257 @@+#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")]++mod control;+mod node;+mod path_env;+mod paths;+mod payload;+mod process;+mod system;+mod tray;+mod update;++use serde::Serialize;+use serde_json::Value;+use std::io::{Read, Seek, SeekFrom};+use std::path::PathBuf;+use std::time::Duration;+use tauri::{AppHandle, Emitter, Manager, State, WindowEvent};+use tokio::sync::Mutex;++use node::NodeInstall;++struct App {+ paths: paths::Paths,+ control: control::Control,+ node: Mutex<Option<NodeInstall>>,+}++type Result<T> = std::result::Result<T, String>;++const LOG_TAIL: u64 = 96_000;++fn bundle(app: &AppHandle) -> Option<payload::Bundle> {+ let resources = app.path().resource_dir().ok()?;+ let bundle = payload::Bundle {+ payload: resources.join("payload"),+ launcher: resources.join("launcher").join(format!("browsentic{}", std::env::consts::EXE_SUFFIX)),+ };+ bundle.payload.join("package.json").is_file().then_some(bundle)+}++async fn located(state: &App) -> Result<NodeInstall> {+ state.node.lock().await.clone().ok_or_else(|| "Node.js has to be installed first.".into())+}++#[derive(Serialize)]+#[serde(rename_all = "camelCase")]+struct AppInfo {+ version: String,+ system: system::System,+ paths: paths::PathsView,+ payload: payload::PayloadStatus,+}++#[tauri::command]+fn app_info(app: AppHandle, state: State<'_, App>) -> AppInfo {+ AppInfo {+ version: app.package_info().version.to_string(),+ system: system::describe(),+ paths: state.paths.view(),+ payload: payload::status(&state.paths, bundle(&app).as_ref()),+ }+}++#[tauri::command]+async fn locate_node(state: State<'_, App>) -> Result<Option<NodeInstall>> {+ let found = node::locate(&state.paths).await;+ *state.node.lock().await = found.clone();+ Ok(found)+}++#[tauri::command]+async fn install_node(app: AppHandle, state: State<'_, App>) -> Result<NodeInstall> {+ let installed = node::install_private(&state.paths, |fraction, label| {+ let _ = app.emit("node-progress", serde_json::json!({ "fraction": fraction, "label": label }));+ })+ .await?;+ *state.node.lock().await = Some(installed.clone());+ Ok(installed)+}++#[tauri::command]+async fn install_payload(app: AppHandle, state: State<'_, App>) -> Result<()> {+ let node = located(&state).await?;+ let bundle = bundle(&app).ok_or("This copy of Browsentic carries no CLI payload. Download a fresh one from browsentic.com.")?;+ let executable = std::env::current_exe().map_err(|error| error.to_string())?;+ let paths = state.paths.clone();+ tauri::async_runtime::spawn_blocking(move || payload::install(&paths, &bundle, &node, &executable)).await.map_err(|error| error.to_string())?+}++/// Everything the control socket does not carry goes through the installed command, so the app and+/// a terminal never disagree about what an operation does. It starts from the home folder, which the+/// daemon it may start inherits, so no install folder is ever held open.+#[tauri::command]+async fn cli(state: State<'_, App>, args: Vec<String>, timeout_secs: Option<u64>) -> Result<process::Output> {+ let node = located(&state).await?;+ let mut command = process::command(&node.path, &[node.dir()]);+ command.arg(state.paths.cli_entry()).args(&args).current_dir(&state.paths.home);+ process::run(&mut command, Duration::from_secs(timeout_secs.unwrap_or(90))).await+}++#[tauri::command]+async fn npm_install(state: State<'_, App>, package: String) -> Result<process::Output> {+ let node = located(&state).await?;+ let mut command = process::command(&node.path, &[node.dir()]);+ command.arg(node.npm_cli()).args(["install", "--global", &package]).current_dir(&state.paths.home);+ process::run(&mut command, Duration::from_secs(600)).await+}++#[tauri::command]+fn extension_stamp(state: State<'_, App>) -> Option<payload::InstallStamp> {+ payload::extension_stamp(&state.paths)+}++#[tauri::command]+fn browsers() -> Vec<system::Browser> {+ system::browsers()+}++#[tauri::command]+fn open_extensions_page(path: PathBuf) -> Result<()> {+ system::open_extensions_page(&path)+}++#[tauri::command]+async fn agents_on_path(state: State<'_, App>, bins: Vec<String>) -> Result<Vec<String>> {+ let extra: Vec<PathBuf> = state.node.lock().await.iter().map(NodeInstall::dir).collect();+ Ok(system::agents_on_path(&bins, &extra))+}++#[tauri::command]+fn read_lock(state: State<'_, App>) -> Option<control::Lockfile> {+ control::read_lock(&state.paths)+}++/// The end of the daemon's log, starting on a whole line.+#[tauri::command]+fn log_tail(state: State<'_, App>) -> String {+ let Ok(mut file) = std::fs::File::open(state.paths.log()) else { return String::new() };+ let size = file.metadata().map(|meta| meta.len()).unwrap_or(0);+ let from = size.saturating_sub(LOG_TAIL);+ let mut bytes = Vec::new();+ if file.seek(SeekFrom::Start(from)).and_then(|_| file.read_to_end(&mut bytes)).is_err() {+ return String::new();+ }+ let text = String::from_utf8_lossy(&bytes);+ match (from > 0).then(|| text.find('\n')).flatten() {+ Some(newline) => text[newline + 1..].to_string(),+ None => text.into_owned(),+ }+}++#[tauri::command]+fn command_link(state: State<'_, App>) -> path_env::CommandLink {+ path_env::command_link(&state.paths.bin())+}++#[tauri::command]+fn set_command_link(state: State<'_, App>, on: bool) -> Result<path_env::CommandLink> {+ let bin = state.paths.bin();+ if on { path_env::link(&bin)? } else { path_env::unlink(&bin)? }+ Ok(path_env::command_link(&bin))+}++#[tauri::command]+async fn control_connect(app: AppHandle, state: State<'_, App>) -> Result<bool> {+ let lock = control::read_lock(&state.paths).ok_or(control::OFFLINE)?;+ state.control.connect(lock, move |event| {+ let _ = app.emit("control-event", event);+ })+ .await+}++#[tauri::command]+async fn control_request(state: State<'_, App>, frame: Value, timeout_ms: Option<u64>) -> Result<Value> {+ state.control.request(frame, Duration::from_millis(timeout_ms.unwrap_or(10_000))).await+}++#[tauri::command]+async fn control_close(state: State<'_, App>) -> Result<()> {+ state.control.close().await;+ Ok(())+}++#[tauri::command]+fn tray_status(tray: State<'_, tray::Tray>, status: tray::Status) -> Result<()> {+ tray.apply(&status).map_err(|error| error.to_string())+}++#[tauri::command]+async fn check_update(app: AppHandle) -> Result<Option<update::Release>> {+ update::check(&app).await+}++#[tauri::command]+async fn install_update(app: AppHandle) -> Result<()> {+ update::install(&app).await+}++/// Run by the uninstaller before the app's files go: stop the daemon and take browsentic off the PATH.+fn prepare_uninstall() {+ let paths = paths::Paths::from_env();+ if paths.shim().is_file() {+ let mut stop = std::process::Command::new(paths.shim());+ stop.arg("stop").current_dir(&paths.home);+ #[cfg(windows)]+ std::os::windows::process::CommandExt::creation_flags(&mut stop, 0x0800_0000);+ let _ = stop.status();+ }+ let _ = path_env::unlink(&paths.bin());+}++fn main() {+ if std::env::args().any(|arg| arg == "--uninstall") {+ return prepare_uninstall();+ }+ tauri::Builder::default()+ .plugin(tauri_plugin_single_instance::init(|app, _, _| tray::show(app)))+ .plugin(tauri_plugin_opener::init())+ .plugin(tauri_plugin_updater::Builder::new().build())+ .manage(App { paths: paths::Paths::from_env(), control: control::Control::default(), node: Mutex::default() })+ .setup(|app| {+ let tray = tray::build(app.handle())?;+ app.manage(tray);+ Ok(())+ })+ .on_window_event(|window, event| {+ if let WindowEvent::CloseRequested { api, .. } = event {+ api.prevent_close();+ let _ = window.hide();+ }+ })+ .invoke_handler(tauri::generate_handler![+ agents_on_path,+ app_info,+ browsers,+ check_update,+ cli,+ command_link,+ control_close,+ control_connect,+ control_request,+ extension_stamp,+ install_node,+ install_payload,+ install_update,+ locate_node,+ log_tail,+ npm_install,+ open_extensions_page,+ read_lock,+ set_command_link,+ tray_status,+ ])+ .run(tauri::generate_context!())+ .expect("Browsentic could not start");+}diff --git a/src/windows/src-tauri/src/node.rs b/src/windows/src-tauri/src/node.rsnew file mode 100644index 0000000..588b38c--- /dev/null+++ b/src/windows/src-tauri/src/node.rs@@ -0,0 +1,202 @@+use serde::{Deserialize, Serialize};+use sha2::{Digest, Sha256};+use std::fs::File;+use std::path::{Path, PathBuf};+use std::time::Duration;+use tokio::io::AsyncWriteExt;++use crate::paths::Paths;+use crate::process;++pub const MINIMUM_MAJOR: u32 = 20;+const DIST: &str = "https://nodejs.org/dist";++#[derive(Serialize, Deserialize, Clone, Debug, PartialEq)]+#[serde(rename_all = "camelCase")]+pub struct NodeInstall {+ pub path: PathBuf,+ pub version: String,+ pub is_private: bool,+}++impl NodeInstall {+ pub fn dir(&self) -> PathBuf {+ self.path.parent().map(Path::to_path_buf).unwrap_or_default()+ }++ /// npm's own script, so installing an agent never starts npm.cmd.+ pub fn npm_cli(&self) -> PathBuf {+ let root = if cfg!(windows) { self.dir() } else { self.dir().join("..").join("lib") };+ root.join("node_modules").join("npm").join("bin").join("npm-cli.js")+ }+}++pub fn major(version: &str) -> u32 {+ version.trim().trim_start_matches('v').split('.').next().and_then(|major| major.parse().ok()).unwrap_or(0)+}++pub fn architecture() -> &'static str {+ if cfg!(target_arch = "aarch64") { "arm64" } else { "x64" }+}++/// The user's own Node when it is new enough, otherwise the private copy under ~/.browsentic/runtime.+pub async fn locate(paths: &Paths) -> Option<NodeInstall> {+ let candidates = [(process::which("node", &[]), false), (Some(paths.private_node()), true)];+ for (path, is_private) in candidates {+ let Some(path) = path.filter(|path| path.is_file()) else { continue };+ let Ok(output) = process::run(process::command(&path, &[]).arg("--version"), Duration::from_secs(8)).await else { continue };+ let version = output.stdout.trim().to_string();+ if output.ok && major(&version) >= MINIMUM_MAJOR {+ return Some(NodeInstall { path, version, is_private });+ }+ }+ None+}++#[derive(Deserialize)]+struct Release {+ version: String,+ files: Vec<String>,+ lts: serde_json::Value,+}++fn current_lts(releases: Vec<Release>, platform: &str) -> Option<String> {+ releases.into_iter().find(|release| release.lts.is_string() && release.files.iter().any(|file| file == platform)).map(|release| release.version)+}++fn checksum_for(sums: &str, name: &str) -> Option<String> {+ sums.lines().find_map(|line| line.strip_suffix(name)?.strip_suffix(" ").map(str::to_string))+}++/// Downloads the current LTS from nodejs.org into ~/.browsentic/runtime/node. No administrator,+/// no package manager, and nothing outside ~/.browsentic is touched.+pub async fn install_private(paths: &Paths, progress: impl Fn(f64, String)) -> Result<NodeInstall, String> {+ if !cfg!(windows) {+ return Err("The app installs its own Node.js on Windows only.".into());+ }+ let failed = |error: reqwest::Error| format!("nodejs.org could not be reached ({error}). Check the connection and try again.");+ let client = reqwest::Client::builder().user_agent("Browsentic").build().map_err(failed)?;++ progress(0.0, "Finding the current Node.js LTS".into());+ let platform = format!("win-{}-zip", architecture());+ let releases: Vec<Release> = client.get(format!("{DIST}/index.json")).send().await.and_then(|r| r.error_for_status()).map_err(failed)?.json().await.map_err(failed)?;+ let version = current_lts(releases, &platform).ok_or("nodejs.org did not list a release for this computer. Try again later.")?;+ let name = format!("node-{version}-win-{}.zip", architecture());+ let sums = client.get(format!("{DIST}/{version}/SHASUMS256.txt")).send().await.and_then(|r| r.error_for_status()).map_err(failed)?.text().await.map_err(failed)?;+ let expected = checksum_for(&sums, &name).ok_or("nodejs.org published no checksum for this download, so it was not installed.")?;++ let label = format!("Downloading Node.js {version}");+ progress(0.02, label.clone());+ tokio::fs::create_dir_all(paths.runtime()).await.map_err(|error| error.to_string())?;+ let archive = paths.runtime().join(format!("{name}.part"));+ let mut response = client.get(format!("{DIST}/{version}/{name}")).send().await.and_then(|r| r.error_for_status()).map_err(failed)?;+ let total = response.content_length().unwrap_or(0) as f64;+ let mut file = tokio::fs::File::create(&archive).await.map_err(|error| error.to_string())?;+ let mut digest = Sha256::new();+ let mut received = 0f64;+ while let Some(chunk) = response.chunk().await.map_err(failed)? {+ digest.update(&chunk);+ file.write_all(&chunk).await.map_err(|error| error.to_string())?;+ received += chunk.len() as f64;+ if total > 0.0 {+ progress(0.02 + received / total * 0.88, label.clone());+ }+ }+ file.flush().await.map_err(|error| error.to_string())?;+ drop(file);++ progress(0.92, "Verifying the download".into());+ let actual: String = digest.finalize().iter().map(|byte| format!("{byte:02x}")).collect();+ if actual != expected {+ let _ = std::fs::remove_file(&archive);+ return Err("The Node.js download did not match its published checksum, so it was discarded. Try again.".into());+ }++ progress(0.95, "Unpacking".into());+ let target = paths.runtime().join("node");+ let unpacked = {+ let (archive, target) = (archive.clone(), target.clone());+ tokio::task::spawn_blocking(move || unpack(&archive, &target)).await.map_err(|error| error.to_string())?+ };+ let _ = std::fs::remove_file(&archive);+ unpacked.map_err(|error| format!("Node.js downloaded but would not unpack: {error}"))?;++ progress(1.0, format!("Node.js {version} is ready"));+ Ok(NodeInstall { path: paths.private_node(), version, is_private: true })+}++/// Unpacks Node's zip without its top folder (node-v22.x-win-arm64/), then swaps it into place whole.+pub fn unpack(archive: &Path, target: &Path) -> Result<(), String> {+ let staging = target.with_file_name(format!("node.tmp-{}", std::process::id()));+ let _ = std::fs::remove_dir_all(&staging);+ let mut zip = zip::ZipArchive::new(File::open(archive).map_err(|error| error.to_string())?).map_err(|error| error.to_string())?;+ for index in 0..zip.len() {+ let mut entry = zip.by_index(index).map_err(|error| error.to_string())?;+ let Some(inner) = entry.enclosed_name().map(|name| name.components().skip(1).collect::<PathBuf>()) else { continue };+ if inner.as_os_str().is_empty() {+ continue;+ }+ let out = staging.join(inner);+ if entry.is_dir() {+ std::fs::create_dir_all(&out).map_err(|error| error.to_string())?;+ } else {+ if let Some(parent) = out.parent() {+ std::fs::create_dir_all(parent).map_err(|error| error.to_string())?;+ }+ std::io::copy(&mut entry, &mut File::create(&out).map_err(|error| error.to_string())?).map_err(|error| error.to_string())?;+ }+ }+ let _ = std::fs::remove_dir_all(target);+ std::fs::rename(&staging, target).map_err(|error| error.to_string())+}++#[cfg(test)]+mod tests {+ use super::*;+ use std::io::Write;++ #[test]+ fn reads_the_major_version_as_node_prints_it() {+ assert_eq!((major("v22.11.0\n"), major("20.0.0"), major("nonsense")), (22, 20, 0));+ }++ #[test]+ fn picks_the_newest_lts_that_ships_this_platform() {+ let releases: Vec<Release> = serde_json::from_str(+ r#"[{"version":"v25.0.0","files":["win-arm64-zip"],"lts":false},+ {"version":"v24.2.0","files":["win-x64-zip"],"lts":"Krypton"},+ {"version":"v24.1.0","files":["win-arm64-zip","win-x64-zip"],"lts":"Krypton"}]"#,+ )+ .unwrap();+ assert_eq!(current_lts(releases, "win-arm64-zip"), Some("v24.1.0".into()));+ }++ #[test]+ fn finds_the_published_checksum_for_exactly_this_file() {+ let sums = "aaa node-v24.1.0-win-x64.zip\nbbb node-v24.1.0-win-arm64.zip\nccc node-v24.1.0-win-arm64.zip.sig\n";+ assert_eq!(checksum_for(sums, "node-v24.1.0-win-arm64.zip"), Some("bbb".into()));+ assert_eq!(checksum_for(sums, "node-v24.1.0-win-x86.zip"), None);+ }++ #[test]+ fn unpacks_without_the_top_folder_and_replaces_what_was_there() {+ let dir = tempfile::tempdir().unwrap();+ let archive = dir.path().join("node.zip");+ let mut zip = zip::ZipWriter::new(File::create(&archive).unwrap());+ let stored = zip::write::SimpleFileOptions::default().compression_method(zip::CompressionMethod::Stored);+ zip.add_directory("node-v24.1.0-win-arm64/", stored).unwrap();+ zip.start_file("node-v24.1.0-win-arm64/node.exe", stored).unwrap();+ zip.write_all(b"node").unwrap();+ zip.start_file("node-v24.1.0-win-arm64/node_modules/npm/bin/npm-cli.js", stored).unwrap();+ zip.write_all(b"npm").unwrap();+ zip.finish().unwrap();++ let target = dir.path().join("runtime").join("node");+ std::fs::create_dir_all(target.join("stale")).unwrap();+ unpack(&archive, &target).unwrap();++ assert_eq!(std::fs::read(target.join("node.exe")).unwrap(), b"node");+ assert!(target.join("node_modules/npm/bin/npm-cli.js").is_file());+ assert!(!target.join("stale").exists());+ }+}diff --git a/src/windows/src-tauri/src/path_env.rs b/src/windows/src-tauri/src/path_env.rsnew file mode 100644index 0000000..6e4b962--- /dev/null+++ b/src/windows/src-tauri/src/path_env.rs@@ -0,0 +1,160 @@+use serde::Serialize;+use std::path::{Path, PathBuf};++use crate::paths::same_dir;++#[derive(Serialize, Debug, Default)]+#[serde(rename_all = "camelCase")]+pub struct CommandLink {+ /// The folder on the user's PATH that holds our `browsentic`, when there is one.+ pub linked_in: Option<PathBuf>,+ /// A `browsentic` that is on the PATH but is not ours: an npm global, or a checkout's link.+ pub foreign: Option<PathBuf>,+}++pub fn command_link(bin: &Path) -> CommandLink {+ let linked_in = user_path().into_iter().find(|dir| same_dir(dir, bin));+ let foreign = fresh_path()+ .into_iter()+ .filter(|dir| !same_dir(dir, bin))+ .flat_map(|dir| ["browsentic.exe", "browsentic.cmd", "browsentic.ps1", "browsentic"].map(|name| dir.join(name)))+ .find(|candidate| candidate.is_file());+ CommandLink { linked_in, foreign }+}++/// Splits a PATH value, keeping every entry exactly as written so a rewrite changes only ours.+pub fn entries(value: &str) -> Vec<&str> {+ value.split(';').filter(|entry| !entry.trim().is_empty()).collect()+}++pub fn with_dir(value: &str, dir: &Path) -> String {+ let mut kept: Vec<String> = without(value, dir);+ kept.push(dir.to_string_lossy().into_owned());+ kept.join(";")+}++pub fn without_dir(value: &str, dir: &Path) -> String {+ without(value, dir).join(";")+}++fn without(value: &str, dir: &Path) -> Vec<String> {+ entries(value).into_iter().filter(|entry| !same_dir(Path::new(entry), dir)).map(str::to_string).collect()+}++#[cfg(windows)]+mod registry {+ use winreg::enums::{HKEY_CURRENT_USER, HKEY_LOCAL_MACHINE, KEY_READ, KEY_WRITE, REG_EXPAND_SZ};+ use winreg::{RegKey, RegValue};++ const USER: &str = "Environment";+ const SYSTEM: &str = r"SYSTEM\CurrentControlSet\Control\Session Manager\Environment";++ fn read(hive: RegKey, key: &str) -> String {+ hive.open_subkey_with_flags(key, KEY_READ).and_then(|key| key.get_value::<String, _>("Path")).unwrap_or_default()+ }++ pub fn user_raw() -> String {+ read(RegKey::predef(HKEY_CURRENT_USER), USER)+ }++ pub fn system_raw() -> String {+ read(RegKey::predef(HKEY_LOCAL_MACHINE), SYSTEM)+ }++ /// REG_EXPAND_SZ, as Windows itself writes it, so entries like %USERPROFILE% keep expanding.+ pub fn write_user(value: &str) -> Result<(), String> {+ let key = RegKey::predef(HKEY_CURRENT_USER).open_subkey_with_flags(USER, KEY_READ | KEY_WRITE).map_err(|error| error.to_string())?;+ let bytes: Vec<u8> = value.encode_utf16().chain([0]).flat_map(u16::to_le_bytes).collect();+ key.set_raw_value("Path", &RegValue { bytes: bytes.into(), vtype: REG_EXPAND_SZ }).map_err(|error| error.to_string())?;+ announce();+ Ok(())+ }++ pub fn expand(value: &str) -> String {+ use windows_sys::Win32::System::Environment::ExpandEnvironmentStringsW;+ let wide: Vec<u16> = value.encode_utf16().chain([0]).collect();+ let needed = unsafe { ExpandEnvironmentStringsW(wide.as_ptr(), std::ptr::null_mut(), 0) };+ if needed == 0 {+ return value.to_string();+ }+ let mut buffer = vec![0u16; needed as usize];+ let written = unsafe { ExpandEnvironmentStringsW(wide.as_ptr(), buffer.as_mut_ptr(), needed) };+ String::from_utf16_lossy(&buffer[..written.saturating_sub(1) as usize])+ }++ /// Tells Explorer, and every terminal it opens from now on, that the environment changed.+ fn announce() {+ use windows_sys::Win32::UI::WindowsAndMessaging::{SendMessageTimeoutW, HWND_BROADCAST, SMTO_ABORTIFHUNG, WM_SETTINGCHANGE};+ let area: Vec<u16> = "Environment".encode_utf16().chain([0]).collect();+ unsafe {+ SendMessageTimeoutW(HWND_BROADCAST, WM_SETTINGCHANGE, 0, area.as_ptr() as isize, SMTO_ABORTIFHUNG, 3000, std::ptr::null_mut());+ }+ }+}++#[cfg(windows)]+pub fn user_path() -> Vec<PathBuf> {+ entries(®istry::user_raw()).into_iter().map(|entry| PathBuf::from(registry::expand(entry))).collect()+}++#[cfg(windows)]+pub fn fresh_path() -> Vec<PathBuf> {+ [registry::system_raw(), registry::user_raw()]+ .iter()+ .flat_map(|value| entries(value).into_iter().map(|entry| PathBuf::from(registry::expand(entry))).collect::<Vec<_>>())+ .collect()+}++#[cfg(windows)]+pub fn link(bin: &Path) -> Result<(), String> {+ registry::write_user(&with_dir(®istry::user_raw(), bin))+}++#[cfg(windows)]+pub fn unlink(bin: &Path) -> Result<(), String> {+ let current = registry::user_raw();+ let next = without_dir(¤t, bin);+ if next == current { Ok(()) } else { registry::write_user(&next) }+}++#[cfg(not(windows))]+pub fn user_path() -> Vec<PathBuf> {+ Vec::new()+}++#[cfg(not(windows))]+pub fn fresh_path() -> Vec<PathBuf> {+ Vec::new()+}++#[cfg(not(windows))]+pub fn link(_: &Path) -> Result<(), String> {+ Err("Putting browsentic on the PATH is done on Windows only.".into())+}++#[cfg(not(windows))]+pub fn unlink(_: &Path) -> Result<(), String> {+ Ok(())+}++#[cfg(test)]+mod tests {+ use super::*;++ #[test]+ fn adds_our_folder_once_and_leaves_every_other_entry_as_written() {+ let bin = Path::new(r"C:\Users\me\.browsentic\bin");+ let before = r"%USERPROFILE%\AppData\Local\Microsoft\WindowsApps;C:\tools;";+ let after = with_dir(before, bin);+ assert_eq!(after, r"%USERPROFILE%\AppData\Local\Microsoft\WindowsApps;C:\tools;C:\Users\me\.browsentic\bin");+ assert_eq!(with_dir(&after, bin), after);+ assert_eq!(entries(&with_dir(r"C:\USERS\ME\.BROWSENTIC\BIN", bin)), vec![r"C:\Users\me\.browsentic\bin"]);+ }++ #[test]+ fn removes_only_our_folder() {+ let bin = Path::new(r"C:\Users\me\.browsentic\bin");+ assert_eq!(without_dir(r"C:\tools;c:\users\me\.browsentic\bin\;D:\x", bin), r"C:\tools;D:\x");+ assert_eq!(without_dir(r"C:\tools", bin), r"C:\tools");+ }+}diff --git a/src/windows/src-tauri/src/paths.rs b/src/windows/src-tauri/src/paths.rsnew file mode 100644index 0000000..7bf601e--- /dev/null+++ b/src/windows/src-tauri/src/paths.rs@@ -0,0 +1,153 @@+use serde::Serialize;+use std::path::{Path, PathBuf};++const EXE: &str = std::env::consts::EXE_SUFFIX;++/// Where Browsentic keeps everything, laid out exactly as the macOS app and `npx browsentic setup` lay it out.+#[derive(Clone, Debug)]+pub struct Paths {+ pub home: PathBuf,+}++impl Paths {+ /// A debug build can be pointed at a scratch home, so working on the app never touches the real install.+ pub fn from_env() -> Self {+ let scratch = cfg!(debug_assertions).then(|| std::env::var_os("BROWSENTIC_APP_HOME")).flatten();+ let home = scratch+ .or_else(|| std::env::var_os(if cfg!(windows) { "USERPROFILE" } else { "HOME" }))+ .map(PathBuf::from)+ .unwrap_or_default();+ Self { home }+ }++ pub fn state(&self) -> PathBuf {+ self.home.join(".browsentic")+ }+ pub fn cli(&self) -> PathBuf {+ self.state().join("cli")+ }+ pub fn cli_entry(&self) -> PathBuf {+ self.cli().join("dist").join("cli.js")+ }+ pub fn cli_manifest(&self) -> PathBuf {+ self.cli().join("package.json")+ }+ pub fn app_marker(&self) -> PathBuf {+ self.cli().join(".browsentic-app.json")+ }+ pub fn bin(&self) -> PathBuf {+ self.state().join("bin")+ }+ pub fn shim(&self) -> PathBuf {+ self.bin().join(format!("browsentic{EXE}"))+ }+ pub fn mcp_shim(&self) -> PathBuf {+ self.bin().join(format!("browsentic-mcp{EXE}"))+ }+ pub fn runtime(&self) -> PathBuf {+ self.state().join("runtime")+ }+ pub fn private_node(&self) -> PathBuf {+ let node = self.runtime().join("node");+ if cfg!(windows) { node.join("node.exe") } else { node.join("bin").join("node") }+ }+ pub fn lockfile(&self) -> PathBuf {+ self.state().join("daemon.json")+ }+ pub fn log(&self) -> PathBuf {+ self.state().join("daemon.log")+ }+ pub fn config(&self) -> PathBuf {+ self.state().join("config.json")+ }+ pub fn default_extension(&self) -> PathBuf {+ self.home.join("browsentic").join("extension").join("chrome-mv3")+ }++ /// `extensionDir` in config.json when someone chose one, the default otherwise.+ pub fn extension_dir(&self) -> PathBuf {+ std::fs::read_to_string(self.config())+ .ok()+ .and_then(|text| serde_json::from_str::<serde_json::Value>(&text).ok())+ .and_then(|config| config.get("extensionDir")?.as_str().filter(|dir| !dir.is_empty()).map(|dir| self.expand(dir)))+ .unwrap_or_else(|| self.default_extension())+ }++ fn expand(&self, dir: &str) -> PathBuf {+ match dir.strip_prefix("~/").or_else(|| dir.strip_prefix("~\\")) {+ Some(rest) => self.home.join(rest),+ None => PathBuf::from(dir),+ }+ }++ pub fn view(&self) -> PathsView {+ PathsView {+ home: self.home.clone(),+ state: self.state(),+ extension_dir: self.extension_dir(),+ log: self.log(),+ shim: self.shim(),+ mcp_shim: self.mcp_shim(),+ bin: self.bin(),+ config: self.config(),+ separator: std::path::MAIN_SEPARATOR,+ }+ }+}++#[derive(Serialize)]+#[serde(rename_all = "camelCase")]+pub struct PathsView {+ pub home: PathBuf,+ pub state: PathBuf,+ pub extension_dir: PathBuf,+ pub log: PathBuf,+ pub shim: PathBuf,+ pub mcp_shim: PathBuf,+ pub bin: PathBuf,+ pub config: PathBuf,+ pub separator: char,+}++pub fn same_dir(a: &Path, b: &Path) -> bool {+ let normal = |path: &Path| path.to_string_lossy().trim_end_matches(['\\', '/']).to_lowercase();+ normal(a) == normal(b)+}++#[cfg(test)]+mod tests {+ use super::*;++ fn at(home: &Path) -> Paths {+ Paths { home: home.to_path_buf() }+ }++ #[test]+ fn keeps_the_layout_every_other_install_uses() {+ let paths = at(Path::new("/h"));+ assert_eq!(paths.cli_entry(), Path::new("/h/.browsentic/cli/dist/cli.js"));+ assert_eq!(paths.lockfile(), Path::new("/h/.browsentic/daemon.json"));+ assert_eq!(paths.default_extension(), Path::new("/h/browsentic/extension/chrome-mv3"));+ assert_eq!(paths.shim().file_stem().unwrap(), "browsentic");+ }++ #[test]+ fn follows_an_extension_folder_chosen_in_config() {+ let home = tempfile::tempdir().unwrap();+ let paths = at(home.path());+ std::fs::create_dir_all(paths.state()).unwrap();+ assert_eq!(paths.extension_dir(), paths.default_extension());++ std::fs::write(paths.config(), r#"{"extensionDir":"~/elsewhere/ext"}"#).unwrap();+ assert_eq!(paths.extension_dir(), home.path().join("elsewhere/ext"));++ std::fs::write(paths.config(), r#"{"extensionDir":""}"#).unwrap();+ assert_eq!(paths.extension_dir(), paths.default_extension());+ }++ #[test]+ fn compares_folders_the_way_windows_does() {+ assert!(same_dir(Path::new(r"C:\Users\Me\.browsentic\bin\"), Path::new(r"c:\users\me\.browsentic\bin")));+ assert!(!same_dir(Path::new(r"C:\a"), Path::new(r"C:\b")));+ }+}diff --git a/src/windows/src-tauri/src/payload.rs b/src/windows/src-tauri/src/payload.rsnew file mode 100644index 0000000..c4e5cb2--- /dev/null+++ b/src/windows/src-tauri/src/payload.rs@@ -0,0 +1,185 @@+use serde::Serialize;+use std::fs;+use std::io;+use std::path::{Path, PathBuf};++use crate::node::NodeInstall;+use crate::paths::Paths;++/// The CLI, the bundled skills and the extension build, carried inside the app in the npm+/// package's layout and laid down in ~/.browsentic/cli, beside the `browsentic` launchers.+pub struct Bundle {+ pub payload: PathBuf,+ pub launcher: PathBuf,+}++#[derive(Serialize, Debug, PartialEq)]+#[serde(rename_all = "camelCase")]+pub struct PayloadStatus {+ pub bundled: Option<String>,+ pub installed: Option<String>,+ pub current: bool,+}++#[derive(Serialize, serde::Deserialize, Debug, PartialEq)]+#[serde(rename_all = "camelCase")]+pub struct InstallStamp {+ pub version: String,+ pub installed_at: String,+}++pub fn version_at(manifest: &Path) -> Option<String> {+ let text = fs::read_to_string(manifest).ok()?;+ serde_json::from_str::<serde_json::Value>(&text).ok()?.get("version")?.as_str().map(str::to_string)+}++impl Bundle {+ pub fn version(&self) -> Option<String> {+ version_at(&self.payload.join("package.json"))+ }+}++/// The marker's version alone is not enough: the macOS app learned that a same-version dev build+/// installed over a release would otherwise be taken for current.+pub fn status(paths: &Paths, bundle: Option<&Bundle>) -> PayloadStatus {+ let bundled = bundle.and_then(Bundle::version);+ let installed = paths.cli_entry().is_file().then(|| version_at(&paths.cli_manifest())).flatten();+ let current = bundled.is_some() && bundled == installed && paths.app_marker().is_file();+ PayloadStatus { bundled, installed, current }+}++pub fn extension_stamp(paths: &Paths) -> Option<InstallStamp> {+ let text = fs::read_to_string(paths.extension_dir().join(".browsentic-install.json")).ok()?;+ serde_json::from_str(&text).ok()+}++/// A directory swap: the daemon has been stopped by the caller, and nothing derives an identity+/// from this path (the extension's folder is another matter, and is never moved).+pub fn install(paths: &Paths, bundle: &Bundle, node: &NodeInstall, app: &Path) -> Result<(), String> {+ let version = bundle.version().ok_or("This copy of Browsentic carries no CLI payload. Download a fresh one from browsentic.com.")?;+ let fail = |error: io::Error| error.to_string();+ fs::create_dir_all(paths.state()).map_err(fail)?;++ let pid = std::process::id();+ let staging = paths.state().join(format!("cli.tmp-{pid}"));+ let _ = fs::remove_dir_all(&staging);+ copy_dir(&bundle.payload, &staging).map_err(fail)?;+ let marker = serde_json::json!({+ "app": app,+ "installedAt": time::OffsetDateTime::now_utc().format(&time::format_description::well_known::Rfc3339).unwrap_or_default(),+ "node": node.path,+ "version": version,+ });+ fs::write(staging.join(".browsentic-app.json"), serde_json::to_string_pretty(&marker).unwrap_or_default()).map_err(fail)?;++ let retired = paths.state().join(format!("cli.old-{pid}"));+ if paths.cli().exists() {+ fs::rename(paths.cli(), &retired).map_err(fail)?;+ }+ fs::rename(&staging, paths.cli()).map_err(fail)?;+ let _ = fs::remove_dir_all(&retired);+ sweep(&paths.state(), "cli.old-");++ fs::create_dir_all(paths.bin()).map_err(fail)?;+ for shim in [paths.shim(), paths.mcp_shim()] {+ place(&bundle.launcher, &shim).map_err(fail)?;+ }+ sweep(&paths.bin(), ".old-");+ Ok(())+}++/// Windows will not overwrite a running program, but it will rename one, so an MCP client holding+/// the old launcher open never blocks an update. The renamed copy is swept once it has exited.+fn place(source: &Path, target: &Path) -> io::Result<()> {+ if target.exists() {+ let name = target.file_name().map(|name| name.to_string_lossy().into_owned()).unwrap_or_default();+ fs::rename(target, target.with_file_name(format!("{name}.old-{}", std::process::id())))?;+ }+ fs::copy(source, target).map(drop)+}++fn sweep(dir: &Path, marker: &str) {+ let Ok(entries) = fs::read_dir(dir) else { return };+ for entry in entries.flatten().filter(|entry| entry.file_name().to_string_lossy().contains(marker)) {+ let path = entry.path();+ let _ = if path.is_dir() { fs::remove_dir_all(&path) } else { fs::remove_file(&path) };+ }+}++fn copy_dir(from: &Path, to: &Path) -> io::Result<()> {+ fs::create_dir_all(to)?;+ for entry in fs::read_dir(from)? {+ let entry = entry?;+ let target = to.join(entry.file_name());+ if entry.file_type()?.is_dir() {+ copy_dir(&entry.path(), &target)?;+ } else {+ fs::copy(entry.path(), target)?;+ }+ }+ Ok(())+}++#[cfg(test)]+mod tests {+ use super::*;++ fn bundle(root: &Path, version: &str) -> Bundle {+ let payload = root.join("payload");+ fs::create_dir_all(payload.join("dist")).unwrap();+ fs::create_dir_all(payload.join("extension").join("chrome-mv3")).unwrap();+ fs::write(payload.join("package.json"), format!(r#"{{"name":"browsentic","version":"{version}"}}"#)).unwrap();+ fs::write(payload.join("dist").join("cli.js"), "cli").unwrap();+ let launcher = root.join("browsentic-launcher");+ fs::write(&launcher, format!("launcher {version}")).unwrap();+ Bundle { payload, launcher }+ }++ fn node() -> NodeInstall {+ NodeInstall { path: PathBuf::from("/opt/node/node"), version: "v24.1.0".into(), is_private: true }+ }++ #[test]+ fn a_fresh_install_is_current_and_marked_as_the_app_s() {+ let root = tempfile::tempdir().unwrap();+ let paths = Paths { home: root.path().join("home") };+ let bundle = bundle(root.path(), "0.8.0");+ assert_eq!(status(&paths, Some(&bundle)), PayloadStatus { bundled: Some("0.8.0".into()), installed: None, current: false });++ install(&paths, &bundle, &node(), Path::new("/Apps/Browsentic.exe")).unwrap();++ assert!(status(&paths, Some(&bundle)).current);+ let marker: serde_json::Value = serde_json::from_str(&fs::read_to_string(paths.app_marker()).unwrap()).unwrap();+ assert_eq!((marker["version"].as_str(), marker["node"].as_str()), (Some("0.8.0"), Some("/opt/node/node")));+ assert_eq!(fs::read_to_string(paths.mcp_shim()).unwrap(), "launcher 0.8.0");+ }++ #[test]+ fn the_same_version_without_the_marker_is_not_current() {+ let root = tempfile::tempdir().unwrap();+ let paths = Paths { home: root.path().join("home") };+ let bundle = bundle(root.path(), "0.8.0");+ install(&paths, &bundle, &node(), Path::new("/Apps/Browsentic.exe")).unwrap();+ fs::remove_file(paths.app_marker()).unwrap();+ assert!(!status(&paths, Some(&bundle)).current);+ }++ #[test]+ fn an_update_replaces_the_cli_and_the_launchers_and_leaves_nothing_behind() {+ let root = tempfile::tempdir().unwrap();+ let paths = Paths { home: root.path().join("home") };+ install(&paths, &bundle(&root.path().join("old"), "0.7.6"), &node(), Path::new("/a")).unwrap();+ fs::write(paths.cli().join("left-over.js"), "stale").unwrap();++ install(&paths, &bundle(&root.path().join("new"), "0.8.0"), &node(), Path::new("/a")).unwrap();++ assert_eq!(version_at(&paths.cli_manifest()), Some("0.8.0".into()));+ assert!(!paths.cli().join("left-over.js").exists());+ assert_eq!(fs::read_to_string(paths.shim()).unwrap(), "launcher 0.8.0");+ let leftovers: Vec<_> = fs::read_dir(paths.state()).unwrap().chain(fs::read_dir(paths.bin()).unwrap()).flatten()+ .map(|entry| entry.file_name().to_string_lossy().into_owned())+ .filter(|name| name.contains(".old-") || name.contains("cli.old-") || name.contains("cli.tmp-"))+ .collect();+ assert!(leftovers.is_empty(), "{leftovers:?}");+ }+}diff --git a/src/windows/src-tauri/src/process.rs b/src/windows/src-tauri/src/process.rsnew file mode 100644index 0000000..d15b4b6--- /dev/null+++ b/src/windows/src-tauri/src/process.rs@@ -0,0 +1,114 @@+use serde::Serialize;+use std::ffi::OsStr;+use std::path::{Path, PathBuf};+use std::process::Stdio;+use std::time::Duration;+use tokio::process::Command;++use crate::path_env;++#[derive(Serialize, Debug)]+#[serde(rename_all = "camelCase")]+pub struct Output {+ pub ok: bool,+ pub code: Option<i32>,+ pub stdout: String,+ pub stderr: String,+}++/// The folders a terminal opened right now would search: the registry's, not the ones this process+/// started with, so an agent installed while the app was open is found without restarting it.+pub fn search_path(extra: &[PathBuf]) -> Vec<PathBuf> {+ let inherited: Vec<PathBuf> = std::env::var_os("PATH").map(|path| std::env::split_paths(&path).collect()).unwrap_or_default();+ extra.iter().cloned().chain(path_env::fresh_path()).chain(inherited).collect()+}++/// A child that never opens a console window and dies with its future.+pub fn command(program: impl AsRef<OsStr>, extra_path: &[PathBuf]) -> Command {+ let mut command = Command::new(program);+ command.stdin(Stdio::null()).stdout(Stdio::piped()).stderr(Stdio::piped()).kill_on_drop(true);+ if let Ok(path) = std::env::join_paths(search_path(extra_path)) {+ command.env("PATH", path);+ }+ #[cfg(windows)]+ command.creation_flags(CREATE_NO_WINDOW);+ command+}++#[cfg(windows)]+const CREATE_NO_WINDOW: u32 = 0x0800_0000;++pub async fn run(command: &mut Command, timeout: Duration) -> Result<Output, String> {+ let child = command.spawn().map_err(|error| error.to_string())?;+ match tokio::time::timeout(timeout, child.wait_with_output()).await {+ Ok(Ok(output)) => Ok(Output {+ ok: output.status.success(),+ code: output.status.code(),+ stdout: String::from_utf8_lossy(&output.stdout).into_owned(),+ stderr: String::from_utf8_lossy(&output.stderr).into_owned(),+ }),+ Ok(Err(error)) => Err(error.to_string()),+ Err(_) => Err(format!("It did not finish within {} seconds, so it was stopped.", timeout.as_secs())),+ }+}++/// `name` as a terminal would resolve it, trying each PATHEXT extension on Windows.+pub fn which(name: &str, extra: &[PathBuf]) -> Option<PathBuf> {+ let extensions: Vec<String> = if cfg!(windows) {+ std::env::var("PATHEXT")+ .unwrap_or_else(|_| ".COM;.EXE;.BAT;.CMD".into())+ .split(';')+ .filter(|extension| !extension.is_empty())+ .map(str::to_lowercase)+ .collect()+ } else {+ vec![String::new()]+ };+ search_path(extra)+ .into_iter()+ .flat_map(|dir| extensions.iter().map(move |extension| dir.join(format!("{name}{extension}"))))+ .find(|candidate| is_program(candidate))+}++fn is_program(path: &Path) -> bool {+ #[cfg(unix)]+ {+ use std::os::unix::fs::PermissionsExt;+ path.metadata().map(|meta| meta.is_file() && meta.permissions().mode() & 0o111 != 0).unwrap_or(false)+ }+ #[cfg(not(unix))]+ path.is_file()+}++#[cfg(test)]+mod tests {+ use super::*;++ #[cfg(unix)]+ #[tokio::test]+ async fn reports_what_a_program_printed_and_how_it_ended() {+ let output = run(command("sh", &[]).args(["-c", "echo out; echo err >&2; exit 3"]), Duration::from_secs(5))+ .await+ .unwrap();+ assert_eq!((output.ok, output.code, output.stdout.trim(), output.stderr.trim()), (false, Some(3), "out", "err"));+ }++ #[cfg(unix)]+ #[tokio::test]+ async fn stops_a_program_that_outlives_its_timeout() {+ let error = run(command("sh", &[]).args(["-c", "sleep 5"]), Duration::from_millis(200)).await.unwrap_err();+ assert!(error.contains("did not finish"));+ }++ #[test]+ fn finds_a_program_in_an_extra_folder_first() {+ let dir = tempfile::tempdir().unwrap();+ let program = dir.path().join(if cfg!(windows) { "browsentic-probe.cmd" } else { "browsentic-probe" });+ std::fs::write(&program, "").unwrap();+ #[cfg(unix)]+ std::fs::set_permissions(&program, std::os::unix::fs::PermissionsExt::from_mode(0o755)).unwrap();+ let extra = [dir.path().to_path_buf()];+ assert_eq!(which("browsentic-probe", &extra).map(|found| found.to_string_lossy().to_lowercase()), Some(program.to_string_lossy().to_lowercase()));+ assert_eq!(which("browsentic-probe-missing", &extra), None);+ }+}diff --git a/src/windows/src-tauri/src/system.rs b/src/windows/src-tauri/src/system.rsnew file mode 100644index 0000000..4dd2874--- /dev/null+++ b/src/windows/src-tauri/src/system.rs@@ -0,0 +1,117 @@+use serde::Serialize;+use std::path::PathBuf;++use crate::process;++#[derive(Serialize, Clone, Debug)]+#[serde(rename_all = "camelCase")]+pub struct Browser {+ pub name: String,+ pub path: PathBuf,+}++/// Chromium browsers on Windows: the name shown, the program App Paths registers, and where each+/// installs itself when it does not register one, under Program Files or the user's AppData.+const BROWSERS: [(&str, &str, &str); 6] = [+ ("Google Chrome", "chrome.exe", r"Google\Chrome\Application\chrome.exe"),+ ("Microsoft Edge", "msedge.exe", r"Microsoft\Edge\Application\msedge.exe"),+ ("Brave", "brave.exe", r"BraveSoftware\Brave-Browser\Application\brave.exe"),+ ("Vivaldi", "vivaldi.exe", r"Vivaldi\Application\vivaldi.exe"),+ ("Opera", "opera.exe", r"Programs\Opera\opera.exe"),+ ("Chromium", "chromium.exe", r"Chromium\Application\chrome.exe"),+];++pub fn browsers() -> Vec<Browser> {+ BROWSERS+ .iter()+ .filter_map(|(name, program, relative)| {+ platform::registered(program)+ .into_iter()+ .chain(install_roots().into_iter().map(|root| root.join(relative)))+ .find(|path| path.is_file())+ .map(|path| Browser { name: name.to_string(), path })+ })+ .collect()+}++fn install_roots() -> Vec<PathBuf> {+ ["ProgramFiles", "ProgramFiles(x86)", "LOCALAPPDATA"].iter().filter_map(std::env::var_os).map(PathBuf::from).collect()+}++/// Chromium browsers take chrome:// from their command line on Windows, Edge and Brave included.+pub fn open_extensions_page(browser: &std::path::Path) -> Result<(), String> {+ let mut command = std::process::Command::new(browser);+ command.arg("chrome://extensions");+ command.spawn().map(drop).map_err(|error| error.to_string())+}++/// Which of these agent CLIs a terminal would find, the app's private Node folder included.+pub fn agents_on_path(bins: &[String], extra: &[PathBuf]) -> Vec<String> {+ bins.iter().filter(|bin| process::which(bin, extra).is_some()).cloned().collect()+}++#[derive(Serialize, Debug)]+#[serde(rename_all = "camelCase")]+pub struct System {+ pub name: String,+ pub architecture: &'static str,+}++pub fn describe() -> System {+ System { name: platform::name(), architecture: if cfg!(target_arch = "aarch64") { "ARM64" } else { "x64" } }+}++/// Windows 11 still calls itself Windows 10 in ProductName; build 22000 is where 11 begins.+pub fn windows_name(product: &str, display: &str, build: u32) -> String {+ let product = if build >= 22000 { product.replacen("Windows 10", "Windows 11", 1) } else { product.to_string() };+ [product.as_str(), display].iter().filter(|part| !part.is_empty()).cloned().collect::<Vec<_>>().join(" ")+}++#[cfg(windows)]+mod platform {+ use std::path::PathBuf;+ use winreg::enums::{HKEY_CURRENT_USER, HKEY_LOCAL_MACHINE, KEY_READ};+ use winreg::RegKey;++ pub fn registered(program: &str) -> Vec<PathBuf> {+ let key = format!(r"SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\{program}");+ [HKEY_CURRENT_USER, HKEY_LOCAL_MACHINE]+ .into_iter()+ .filter_map(|hive| RegKey::predef(hive).open_subkey_with_flags(&key, KEY_READ).ok()?.get_value::<String, _>("").ok())+ .map(|path| PathBuf::from(path.trim_matches('"')))+ .collect()+ }++ pub fn name() -> String {+ let Ok(key) = RegKey::predef(HKEY_LOCAL_MACHINE).open_subkey_with_flags(r"SOFTWARE\Microsoft\Windows NT\CurrentVersion", KEY_READ) else {+ return "Windows".into();+ };+ let read = |name: &str| key.get_value::<String, _>(name).unwrap_or_default();+ super::windows_name(&read("ProductName"), &read("DisplayVersion"), read("CurrentBuildNumber").parse().unwrap_or(0))+ }+}++#[cfg(not(windows))]+mod platform {+ use std::path::PathBuf;++ pub fn registered(_: &str) -> Vec<PathBuf> {+ Vec::new()+ }++ pub fn name() -> String {+ format!("{} (development)", std::env::consts::OS)+ }+}++#[cfg(test)]+mod tests {+ use super::*;++ #[test]+ fn calls_windows_11_by_its_name() {+ assert_eq!(windows_name("Windows 10 Pro", "24H2", 26100), "Windows 11 Pro 24H2");+ assert_eq!(windows_name("Windows 10 Home", "22H2", 19045), "Windows 10 Home 22H2");+ assert_eq!(windows_name("Windows 10 Pro", "", 22631), "Windows 11 Pro");+ }+}diff --git a/src/windows/src-tauri/src/tray.rs b/src/windows/src-tauri/src/tray.rsnew file mode 100644index 0000000..28b5079--- /dev/null+++ b/src/windows/src-tauri/src/tray.rs@@ -0,0 +1,77 @@+use serde::Deserialize;+use tauri::menu::{Menu, MenuItem, PredefinedMenuItem};+use tauri::tray::{MouseButton, MouseButtonState, TrayIconBuilder, TrayIconEvent};+use tauri::{AppHandle, Emitter, Manager, Wry};++/// The menu-bar extra of the macOS app, as a notification-area icon: the daemon's state, turning it+/// on or off, restarting it, and the window. Closing the window leaves this running.+pub struct Tray {+ status: MenuItem<Wry>,+ toggle: MenuItem<Wry>,+ restart: MenuItem<Wry>,+}++#[derive(Deserialize)]+#[serde(rename_all = "camelCase")]+pub struct Status {+ pub summary: String,+ pub toggle: String,+ pub can_toggle: bool,+ pub can_restart: bool,+}++pub fn build(app: &AppHandle) -> tauri::Result<Tray> {+ let item = |id: &str, text: &str, enabled: bool| MenuItem::with_id(app, id, text, enabled, None::<&str>);+ let status = item("status", "Daemon: Off", false)?;+ let toggle = item("toggle", "Turn On", false)?;+ let restart = item("restart", "Restart", false)?;+ let menu = Menu::with_items(+ app,+ &[+ &status,+ &PredefinedMenuItem::separator(app)?,+ &toggle,+ &restart,+ &PredefinedMenuItem::separator(app)?,+ &item("open", "Open Browsentic", true)?,+ &item("quit", "Quit", true)?,+ ],+ )?;++ let mut tray = TrayIconBuilder::with_id("browsentic").tooltip("Browsentic").menu(&menu).show_menu_on_left_click(false);+ if let Some(icon) = app.default_window_icon() {+ tray = tray.icon(icon.clone());+ }+ tray.on_menu_event(|app, event| match event.id().as_ref() {+ "open" => show(app),+ "quit" => app.exit(0),+ action => {+ let _ = app.emit("tray", action);+ }+ })+ .on_tray_icon_event(|tray, event| {+ if let TrayIconEvent::Click { button: MouseButton::Left, button_state: MouseButtonState::Up, .. } = event {+ show(tray.app_handle());+ }+ })+ .build(app)?;++ Ok(Tray { status, toggle, restart })+}++impl Tray {+ pub fn apply(&self, status: &Status) -> tauri::Result<()> {+ self.status.set_text(&status.summary)?;+ self.toggle.set_text(&status.toggle)?;+ self.toggle.set_enabled(status.can_toggle)?;+ self.restart.set_enabled(status.can_restart)+ }+}++pub fn show(app: &AppHandle) {+ if let Some(window) = app.get_webview_window("main") {+ let _ = window.unminimize();+ let _ = window.show();+ let _ = window.set_focus();+ }+}diff --git a/src/windows/src-tauri/src/update.rs b/src/windows/src-tauri/src/update.rsnew file mode 100644index 0000000..0be1863--- /dev/null+++ b/src/windows/src-tauri/src/update.rs@@ -0,0 +1,54 @@+use serde::Serialize;+use tauri::{AppHandle, Emitter, Url};+use tauri_plugin_updater::{Updater, UpdaterExt};++#[derive(Serialize)]+#[serde(rename_all = "camelCase")]+pub struct Release {+ pub version: String,+ pub notes: Option<String>,+}++/// The release feed from tauri.conf.json, or another one for a test build; either way the download+/// must carry a signature from the key built into this app, or it is not installed.+fn updater(app: &AppHandle) -> Result<Updater, String> {+ let mut builder = app.updater_builder();+ if let Some(feed) = std::env::var("BROWSENTIC_UPDATE_URL").ok().and_then(|url| Url::parse(&url).ok()) {+ builder = builder.endpoints(vec![feed]).map_err(|error| error.to_string())?;+ }+ builder.build().map_err(|error| error.to_string())+}++fn explain(error: tauri_plugin_updater::Error) -> String {+ match error {+ tauri_plugin_updater::Error::Reqwest(_) | tauri_plugin_updater::Error::Network(_) => {+ "GitHub could not be reached. Check the connection and try again.".into()+ }+ tauri_plugin_updater::Error::Minisign(_) | tauri_plugin_updater::Error::SignatureUtf8(_) => {+ "The download's signature does not match this app's key, so it was not installed.".into()+ }+ other => other.to_string(),+ }+}++pub async fn check(app: &AppHandle) -> Result<Option<Release>, String> {+ let found = updater(app)?.check().await.map_err(explain)?;+ Ok(found.map(|update| Release { version: update.version.clone(), notes: update.body.clone() }))+}++/// Downloads and runs the new installer, which closes this app, replaces it, and opens it again.+pub async fn install(app: &AppHandle) -> Result<(), String> {+ let update = updater(app)?.check().await.map_err(explain)?.ok_or("There is no newer release to install.")?;+ let progress = app.clone();+ let mut received = 0u64;+ update+ .download_and_install(+ move |chunk, total| {+ received += chunk as u64;+ let _ = progress.emit("update-progress", serde_json::json!({ "received": received, "total": total }));+ },+ || {},+ )+ .await+ .map_err(explain)+}diff --git a/src/windows/src-tauri/tauri.conf.json b/src/windows/src-tauri/tauri.conf.jsonnew file mode 100644index 0000000..61c8c2c--- /dev/null+++ b/src/windows/src-tauri/tauri.conf.json@@ -0,0 +1,60 @@+{+ "$schema": "https://schema.tauri.app/config/2",+ "productName": "Browsentic",+ "mainBinaryName": "Browsentic",+ "version": "../../daemon/package.json",+ "identifier": "com.imshaikot.browsentic",+ "build": {+ "frontendDist": "../dist",+ "devUrl": "http://localhost:1420",+ "beforeDevCommand": "yarn win:payload && yarn win:ui:dev",+ "beforeBuildCommand": "yarn win:payload && yarn win:ui"+ },+ "app": {+ "windows": [+ {+ "label": "main",+ "title": "Browsentic",+ "width": 1040,+ "height": 760,+ "minWidth": 940,+ "minHeight": 680,+ "center": true,+ "backgroundColor": "#110A06"+ }+ ],+ "security": {+ "csp": "default-src 'self'; img-src 'self' data:; style-src 'self' 'unsafe-inline'; connect-src ipc: http://ipc.localhost"+ }+ },+ "bundle": {+ "active": true,+ "targets": ["nsis"],+ "publisher": "Browsentic",+ "homepage": "https://browsentic.com",+ "copyright": "MIT License",+ "category": "DeveloperTool",+ "shortDescription": "Your browser, driven by the AI agent you already run",+ "createUpdaterArtifacts": true,+ "icon": ["icons/32x32.png", "icons/128x128.png", "icons/[email protected]", "icons/icon.icns", "icons/icon.ico"],+ "resources": {+ "resources/payload/": "payload/",+ "resources/launcher/": "launcher/"+ },+ "windows": {+ "webviewInstallMode": { "type": "downloadBootstrapper" },+ "nsis": {+ "installMode": "currentUser",+ "installerHooks": "./installer-hooks.nsh",+ "installerIcon": "icons/icon.ico"+ }+ }+ },+ "plugins": {+ "updater": {+ "pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDM0MDRFRkQ2RjcyMUUzNzEKUldSeDR5SDMxdThFTkkxZXVFa0Y1OVhpTTVaTGdIQmdXV0RpMXliclZnRi81QVJFVEl6dDkwSzUK",+ "endpoints": ["https://github.com/imshaikot/browsentic/releases/latest/download/latest.json"],+ "windows": { "installMode": "passive" }+ }+ }+}diff --git a/src/windows/ui/app.css b/src/windows/ui/app.cssnew file mode 100644index 0000000..6086a67--- /dev/null+++ b/src/windows/ui/app.css@@ -0,0 +1,113 @@+@import "../../extension/assets/globals.css";++@source "../../extension/components";++html,+body,+#root {+ height: 100%;+ overflow: hidden;+}++body {+ user-select: none;+}++.select-text {+ user-select: text;+}++.backdrop-wash {+ position: absolute;+ border-radius: 9999px;+ animation: drift 11s ease-in-out infinite alternate;+}++.backdrop-wash-brand {+ width: 900px;+ height: 900px;+ left: calc(50% - 450px - 300px);+ top: calc(50% - 450px - 270px);+ background: radial-gradient(closest-side, color-mix(in oklch, var(--brand) 20%, transparent), transparent);+ --drift-x: 80px;+ --drift-y: -60px;+}++.backdrop-wash-ember {+ width: 860px;+ height: 860px;+ left: calc(50% - 430px + 340px);+ top: calc(50% - 430px + 295px);+ background: radial-gradient(closest-side, color-mix(in oklch, var(--ember) 16%, transparent), transparent);+ --drift-x: -80px;+ --drift-y: 70px;+}++[data-theme="daylight"] .backdrop-wash-brand {+ background: radial-gradient(closest-side, color-mix(in oklch, var(--brand) 12%, transparent), transparent);+}++[data-theme="daylight"] .backdrop-wash-ember {+ background: radial-gradient(closest-side, color-mix(in oklch, var(--ember) 9%, transparent), transparent);+}++@keyframes drift {+ to {+ transform: translate(var(--drift-x), var(--drift-y));+ }+}++/* A ring drawn with a conic gradient and cut out by a radial mask: the orb's and the beacon's arcs. */+.ring {+ position: absolute;+ border-radius: 9999px;+ mask: radial-gradient(farthest-side, transparent calc(100% - var(--ring-width, 3px)), #000 calc(100% - var(--ring-width, 3px)));+}++.spin {+ animation: turn var(--spin, 6s) linear infinite;+}++.spin-reverse {+ animation: turn var(--spin, 6s) linear infinite reverse;+}++.breathe {+ animation: breathe 2.2s ease-in-out infinite alternate;+}++@keyframes turn {+ to {+ transform: rotate(360deg);+ }+}++@keyframes breathe {+ from {+ transform: scale(0.94);+ }+ to {+ transform: scale(1.1);+ }+}++.enter {+ animation: enter 0.28s ease-out both;+}++@keyframes enter {+ from {+ opacity: 0;+ transform: translateY(8px);+ }+}++@media (prefers-reduced-motion: reduce) {+ .backdrop-wash,+ .spin,+ .spin-reverse,+ .breathe,+ .enter {+ animation: none;+ }+}diff --git a/src/windows/ui/app.tsx b/src/windows/ui/app.tsxnew file mode 100644index 0000000..d55244c--- /dev/null+++ b/src/windows/ui/app.tsx@@ -0,0 +1,77 @@+import { useEffect, useSyncExternalStore } from 'react';++import { Backdrop, NoticeBanner } from './components';+import { TABS, useModelState, type Appearance, type Model } from './model';+import type { Backend } from './backend';+import { MainView } from './views/main';+import { PreflightView } from './views/preflight';++const darkQuery = () => window.matchMedia('(prefers-color-scheme: dark)');++function useSystemDark() {+ return useSyncExternalStore(+ (listener) => {+ const query = darkQuery();+ query.addEventListener('change', listener);+ return () => query.removeEventListener('change', listener);+ },+ () => darkQuery().matches,+ );+}++/** Ember when dark and Daylight when light, as the macOS window does; the browsers keep their own theme. */+function useAppearance(appearance: Appearance, backend: Backend) {+ const systemDark = useSystemDark();+ const dark = appearance === 'dark' || (appearance === 'system' && systemDark);+ useEffect(() => {+ document.documentElement.dataset.theme = dark ? 'ember' : 'daylight';+ void backend.setWindowTheme(appearance === 'system' ? null : appearance).catch(() => undefined);+ }, [dark, appearance, backend]);+}++function useShortcuts(model: Model) {+ useEffect(() => {+ const onKey = (event: KeyboardEvent) => {+ if (!event.ctrlKey || event.altKey || event.metaKey) return;+ const state = model.snapshot();+ const digit = Number(event.key);+ if (!event.shiftKey && digit >= 1 && digit <= TABS.length) {+ event.preventDefault();+ model.setTab(TABS[digit - 1]);+ return;+ }+ if (!event.shiftKey || state.phase !== 'main') return;+ const key = event.key.toLowerCase();+ if (key === 'd' && (state.daemon === 'on' || state.daemon === 'off')) void model.setDaemon(state.daemon === 'off');+ else if (key === 'r' && state.daemon === 'on') void model.restartDaemon();+ else if (key === 'p' && state.daemon === 'on') {+ model.setTab('browsers');+ void model.newPairingCode();+ } else return;+ event.preventDefault();+ };+ window.addEventListener('keydown', onKey);+ return () => window.removeEventListener('keydown', onKey);+ }, [model]);+}++export function App({ model, backend }: { model: Model; backend: Backend }) {+ const state = useModelState(model);+ useAppearance(state.appearance, backend);+ useShortcuts(model);+ useEffect(() => model.start(), [model]);++ return (+ <div className="relative h-full text-ink">+ <Backdrop />+ <div className="relative h-full">+ {state.phase === 'preflight' ? <PreflightView model={model} state={state} /> : <MainView model={model} state={state} />}+ </div>+ {state.notice && (+ <div key={state.notice.id} className="enter pointer-events-auto fixed inset-x-0 bottom-5.5 flex justify-center px-6">+ <NoticeBanner text={state.notice.text} isError={state.notice.isError} />+ </div>+ )}+ </div>+ );+}diff --git a/src/windows/ui/backend.ts b/src/windows/ui/backend.tsnew file mode 100644index 0000000..7cabc7b--- /dev/null+++ b/src/windows/ui/backend.ts@@ -0,0 +1,211 @@+import type { BridgeStatus, SessionSummary } from '@/daemon/control';+import type { AgentDescriptor, AgentState } from '@/lib/agents/catalog';+import type { Preferences } from '@/lib/settings/preferences';++export type { BridgeStatus, SessionSummary };++export interface NodeInstall {+ path: string;+ version: string;+ isPrivate: boolean;+}++export interface PathsView {+ home: string;+ state: string;+ extensionDir: string;+ log: string;+ shim: string;+ mcpShim: string;+ bin: string;+ config: string;+ separator: string;+}++export interface AppInfo {+ version: string;+ system: { name: string; architecture: string };+ paths: PathsView;+ payload: { bundled: string | null; installed: string | null; current: boolean };+}++export interface CliOutput {+ ok: boolean;+ code: number | null;+ stdout: string;+ stderr: string;+}++export interface Lockfile {+ pid: number;+ port: number;+ token: string;+ daemonVersion?: string;+}++export interface Browser {+ name: string;+ path: string;+}++export interface InstallStamp {+ version: string;+ installedAt: string;+}++export interface CommandLink {+ linkedIn: string | null;+ foreign: string | null;+}++export interface Release {+ version: string;+ notes: string | null;+}++export interface TrayStatus {+ summary: string;+ toggle: string;+ canToggle: boolean;+ canRestart: boolean;+}++export interface Progress {+ fraction: number;+ label: string;+}++export interface Skill {+ name: string;+ description: string;+ triggers: string[];+ isDefault: boolean;+ category: string;+ domains: string[];+ source: string;+ provenance: string;+ path?: string;+}++export interface SkillListing {+ skills: Skill[];+ dirs: string[];+ agent: string;+ agentSkills: { name: string; description?: string }[];+}++export interface Grant {+ action: string;+ host: string;+ at: string;+}++export interface DownloadRecord {+ id: string;+ name: string;+ mime: string;+ size: number;+ url: string;+ host?: string;+ notes: string;+ savedTo: string;+ capturedAt: string;+}++export interface DownloadListing {+ dir: string;+ downloads: DownloadRecord[];+}++export type AgentListing = AgentState & { catalog?: AgentDescriptor[] };++export interface PairingCode {+ code: string;+ expiresAt: number;+}++export type { Preferences };++/** Everything the window asks of the machine, so the same views run on Tauri or on a stand-in. */+export interface Backend {+ appInfo(): Promise<AppInfo>;+ locateNode(): Promise<NodeInstall | null>;+ installNode(onProgress: (progress: Progress) => void): Promise<NodeInstall>;+ installPayload(): Promise<void>;+ cli(args: string[], timeoutSecs?: number): Promise<CliOutput>;+ npmInstall(pkg: string): Promise<CliOutput>;+ extensionStamp(): Promise<InstallStamp | null>;+ browsers(): Promise<Browser[]>;+ openExtensionsPage(browser: Browser): Promise<void>;+ agentsOnPath(bins: string[]): Promise<string[]>;+ readLock(): Promise<Lockfile | null>;+ logTail(): Promise<string>;+ commandLink(): Promise<CommandLink>;+ setCommandLink(on: boolean): Promise<CommandLink>;+ controlConnect(): Promise<boolean>;+ controlRequest(frame: Record<string, unknown>, timeoutMs?: number): Promise<Record<string, unknown>>;+ controlClose(): Promise<void>;+ trayStatus(status: TrayStatus): Promise<void>;+ checkUpdate(): Promise<Release | null>;+ installUpdate(onProgress: (fraction: number) => void): Promise<void>;+ onControlEvent(listener: (event: string) => void): () => void;+ onTray(listener: (action: string) => void): () => void;+ openUrl(url: string): Promise<void>;+ reveal(path: string): Promise<void>;+ setWindowTheme(theme: 'light' | 'dark' | null): Promise<void>;+}++const unlisten = (pending: Promise<() => void>) => () => void pending.then((stop) => stop());++export async function tauriBackend(): Promise<Backend> {+ const { invoke } = await import('@tauri-apps/api/core');+ const { listen } = await import('@tauri-apps/api/event');+ const { getCurrentWindow } = await import('@tauri-apps/api/window');+ const opener = await import('@tauri-apps/plugin-opener');++ return {+ appInfo: () => invoke('app_info'),+ locateNode: () => invoke('locate_node'),+ installNode: async (onProgress) => {+ const stop = await listen<Progress>('node-progress', (event) => onProgress(event.payload));+ try {+ return await invoke<NodeInstall>('install_node');+ } finally {+ stop();+ }+ },+ installPayload: () => invoke('install_payload'),+ cli: (args, timeoutSecs) => invoke('cli', { args, timeoutSecs }),+ npmInstall: (pkg) => invoke('npm_install', { package: pkg }),+ extensionStamp: () => invoke('extension_stamp'),+ browsers: () => invoke('browsers'),+ openExtensionsPage: (browser) => invoke('open_extensions_page', { path: browser.path }),+ agentsOnPath: (bins) => invoke('agents_on_path', { bins }),+ readLock: () => invoke('read_lock'),+ logTail: () => invoke('log_tail'),+ commandLink: () => invoke('command_link'),+ setCommandLink: (on) => invoke('set_command_link', { on }),+ controlConnect: () => invoke('control_connect'),+ controlRequest: (frame, timeoutMs) => invoke('control_request', { frame, timeoutMs }),+ controlClose: () => invoke('control_close'),+ trayStatus: (status) => invoke('tray_status', { status }),+ checkUpdate: () => invoke('check_update'),+ installUpdate: async (onProgress) => {+ const stop = await listen<{ received: number; total: number | null }>('update-progress', ({ payload }) =>+ onProgress(payload.total ? payload.received / payload.total : 0),+ );+ try {+ await invoke('install_update');+ } finally {+ stop();+ }+ },+ onControlEvent: (listener) => unlisten(listen<string>('control-event', (event) => listener(event.payload))),+ onTray: (listener) => unlisten(listen<string>('tray', (event) => listener(event.payload))),+ openUrl: (url) => opener.openUrl(url),+ reveal: (path) => opener.revealItemInDir(path),+ setWindowTheme: (theme) => getCurrentWindow().setTheme(theme),+ };+}++export const isTauri = () => typeof window !== 'undefined' && '__TAURI_INTERNALS__' in window;diff --git a/src/windows/ui/components.tsx b/src/windows/ui/components.tsxnew file mode 100644index 0000000..157298b--- /dev/null+++ b/src/windows/ui/components.tsx@@ -0,0 +1,273 @@+import { useState, type ButtonHTMLAttributes, type ReactNode } from 'react';+import { Check, CircleAlert, CircleCheck, Copy, Folder, Loader2, Power, type LucideIcon } from 'lucide-react';++import { cn } from '@/lib/utils';+import { copy, short, type Model } from './model';+import type { AppInfo } from './backend';++export type Tint = 'brand' | 'lime' | 'amber' | 'danger' | 'ember' | 'magenta' | 'dim' | 'faint';++/** Whole class names, so Tailwind sees every one of them. */+const TEXT: Record<Tint, string> = {+ brand: 'text-brand',+ lime: 'text-lime',+ amber: 'text-amber',+ danger: 'text-destructive',+ ember: 'text-ember',+ magenta: 'text-magenta',+ dim: 'text-ink-dim',+ faint: 'text-ink-faint',+};++const WASH: Record<Tint, string> = {+ brand: 'bg-brand/13',+ lime: 'bg-lime/13',+ amber: 'bg-amber/13',+ danger: 'bg-destructive/13',+ ember: 'bg-ember/13',+ magenta: 'bg-magenta/13',+ dim: 'bg-ink-dim/13',+ faint: 'bg-ink-faint/13',+};++const DOT: Record<Tint, string> = {+ brand: 'bg-brand text-brand',+ lime: 'bg-lime text-lime',+ amber: 'bg-amber text-amber',+ danger: 'bg-destructive text-destructive',+ ember: 'bg-ember text-ember',+ magenta: 'bg-magenta text-magenta',+ dim: 'bg-ink-dim text-ink-dim',+ faint: 'bg-ink-faint text-ink-faint',+};++export function Card({ children, className, padded = true }: { children: ReactNode; className?: string; padded?: boolean }) {+ return (+ <section className={cn('w-full rounded-2xl border border-line bg-surface/72 backdrop-blur-sm', padded && 'p-5', className)}>+ {children}+ </section>+ );+}++export function SectionTitle({ title, subtitle }: { title: string; subtitle?: ReactNode }) {+ return (+ <div className="min-w-0 space-y-1">+ <h2 className="font-display text-[15px] font-semibold text-ink">{title}</h2>+ {subtitle && <p className="text-xs leading-relaxed text-ink-dim">{subtitle}</p>}+ </div>+ );+}++export function Pill({ text, tint = 'dim', icon: Icon }: { text: string; tint?: Tint; icon?: LucideIcon }) {+ return (+ <span className={cn('inline-flex shrink-0 items-center gap-1.25 rounded-full px-2.25 py-1 text-[11px] font-medium', TEXT[tint], WASH[tint])}>+ {Icon && <Icon className="size-2.5" strokeWidth={3} />}+ {text}+ </span>+ );+}++export function GlowDot({ tint, pulsing = false }: { tint: Tint; pulsing?: boolean }) {+ return <span className={cn('glow-dot inline-block size-2 shrink-0 rounded-full', DOT[tint], pulsing && 'animate-pulse')} />;+}++export function Spinner({ className }: { className?: string }) {+ return <Loader2 className={cn('size-4 animate-spin text-ink-faint', className)} />;+}++type ButtonProps = ButtonHTMLAttributes<HTMLButtonElement> & { icon?: LucideIcon; tint?: Tint };++export function PrimaryButton({ icon: Icon, tint = 'brand', className, children, ...props }: ButtonProps) {+ return (+ <button+ type="button"+ {...props}+ className={cn(+ 'inline-flex shrink-0 items-center gap-2 rounded-full px-4 py-2.25 text-[13px] font-semibold transition active:scale-[0.97] disabled:opacity-40',+ tint === 'danger' ? 'glow-destructive bg-destructive text-ink' : 'glow-brand bg-brand text-ground',+ className,+ )}+ >+ {Icon && <Icon className="size-4" />}+ {children}+ </button>+ );+}++export function QuietButton({ icon: Icon, tint, className, children, ...props }: ButtonProps) {+ return (+ <button+ type="button"+ {...props}+ className={cn(+ 'inline-flex shrink-0 items-center gap-1.5 rounded-full border border-line bg-surface-2/70 px-3 py-1.75 text-xs font-medium transition hover:bg-surface-2 active:scale-[0.97] disabled:opacity-40',+ tint ? TEXT[tint] : 'text-ink',+ className,+ )}+ >+ {Icon && <Icon className="size-3.5" />}+ {children}+ </button>+ );+}++export function CopyButton({ value, label = 'Copy' }: { value: string; label?: string }) {+ const [copied, setCopied] = useState(false);+ const press = async () => {+ try {+ await copy(value);+ setCopied(true);+ setTimeout(() => setCopied(false), 1400);+ } catch {+ setCopied(false);+ }+ };+ return (+ <QuietButton icon={copied ? Check : Copy} tint={copied ? 'lime' : undefined} onClick={() => void press()}>+ {copied ? 'Copied' : label}+ </QuietButton>+ );+}++export function PathRow({ path, model, info }: { path: string; model: Model; info?: AppInfo }) {+ return (+ <div className="flex items-center gap-2 rounded-[10px] border border-line bg-ground-2 py-1.5 pr-1.5 pl-3">+ <span className="min-w-0 flex-1 truncate font-mono text-xs text-ink select-text" title={path}>+ {short(path, info)}+ </span>+ <CopyButton value={path} />+ <QuietButton icon={Folder} onClick={() => void model.reveal(path)}>+ Show+ </QuietButton>+ </div>+ );+}++export function EmptyState({ icon: Icon, title, detail }: { icon: LucideIcon; title: string; detail: string }) {+ return (+ <div className="flex flex-col items-center gap-2.5 py-11 text-center">+ <Icon className="size-7 text-ink-faint" strokeWidth={1.25} />+ <p className="font-display text-[15px] font-semibold text-ink">{title}</p>+ <p className="max-w-[380px] text-xs text-ink-dim">{detail}</p>+ </div>+ );+}++export function NoticeBanner({ text, isError }: { text: string; isError: boolean }) {+ const Icon = isError ? CircleAlert : CircleCheck;+ return (+ <div+ role="status"+ className={cn(+ 'flex max-w-[620px] items-center gap-2.5 rounded-[14px] border bg-surface/90 px-4 py-2.75 shadow-2xl backdrop-blur-md',+ isError ? 'border-destructive/40' : 'border-lime/40',+ )}+ >+ <Icon className={cn('size-4 shrink-0', isError ? 'text-destructive' : 'text-lime')} />+ <p className="text-[12.5px] text-ink select-text">{text}</p>+ </div>+ );+}++export function OfflineHint({ what, model, daemonOff }: { what: string; model: Model; daemonOff: boolean }) {+ return (+ <Card>+ <div className="flex items-center gap-3.5">+ <Power className="size-5 shrink-0 text-amber" strokeWidth={2.5} />+ <div className="min-w-0 flex-1 space-y-0.75">+ <p className="font-display text-sm font-semibold text-ink">The daemon is off</p>+ <p className="text-xs text-ink-dim">{what} come from the running daemon.</p>+ </div>+ <PrimaryButton disabled={!daemonOff} onClick={() => void model.setDaemon(true)}>+ Turn it on+ </PrimaryButton>+ </div>+ </Card>+ );+}++/** The ground every screen sits on: the ember black, a dot grid, and two slow washes of colour. */+export function Backdrop() {+ return (+ <div aria-hidden className="pointer-events-none fixed inset-0 overflow-hidden bg-ground">+ <div className="dot-grid absolute inset-0 [mask-image:radial-gradient(ellipse_at_top,#000,transparent_70%)]" />+ <div className="backdrop-wash backdrop-wash-brand" />+ <div className="backdrop-wash backdrop-wash-ember" />+ </div>+ );+}++export function Step({ number, children }: { number: number; children: ReactNode }) {+ return (+ <div className="flex items-baseline gap-2.5">+ <span className="flex size-4.5 shrink-0 items-center justify-center rounded-full bg-brand/14 font-mono text-[10px] font-bold text-brand">+ {number}+ </span>+ <p className="text-[12.5px] text-ink-dim">{children}</p>+ </div>+ );+}++export function Segmented<T extends string>({+ options,+ value,+ onSelect,+ disabled,+}: {+ options: { value: T; label: string }[];+ value: T;+ onSelect: (next: T) => void;+ disabled?: boolean;+}) {+ return (+ <div className="inline-flex gap-0.5 rounded-lg border border-line bg-ground-2 p-0.5">+ {options.map((option) => (+ <button+ key={option.value}+ type="button"+ disabled={disabled}+ aria-pressed={option.value === value}+ onClick={() => onSelect(option.value)}+ className={cn(+ 'rounded-md px-3 py-1 text-xs font-medium transition-colors disabled:opacity-40',+ option.value === value ? 'bg-brand/20 text-brand' : 'text-ink-faint hover:text-ink-dim',+ )}+ >+ {option.label}+ </button>+ ))}+ </div>+ );+}++export function ConfirmDialog({+ title,+ message,+ action,+ onConfirm,+ onCancel,+ children,+}: {+ title: string;+ message: string;+ action: string;+ onConfirm: () => void;+ onCancel: () => void;+ children?: ReactNode;+}) {+ return (+ <div role="dialog" aria-modal aria-label={title} className="fixed inset-0 z-50 flex items-center justify-center bg-ground/60 backdrop-blur-sm" onClick={onCancel}>+ <div className="enter w-[440px] space-y-3.5 rounded-2xl border border-line-strong bg-ground p-6 shadow-2xl" onClick={(event) => event.stopPropagation()}>+ <h2 className="font-display text-lg font-semibold text-ink">{title}</h2>+ <p className="text-[12.5px] leading-relaxed whitespace-pre-line text-ink-dim">{message}</p>+ {children}+ <div className="flex justify-end gap-2 pt-1">+ <QuietButton onClick={onCancel}>Cancel</QuietButton>+ <PrimaryButton tint="danger" onClick={onConfirm}>+ {action}+ </PrimaryButton>+ </div>+ </div>+ </div>+ );+}diff --git a/src/windows/ui/main.tsx b/src/windows/ui/main.tsxnew file mode 100644index 0000000..610552a--- /dev/null+++ b/src/windows/ui/main.tsx@@ -0,0 +1,25 @@+import { StrictMode } from 'react';+import { createRoot } from 'react-dom/client';++import './app.css';+import { App } from './app';+import { isTauri, tauriBackend } from './backend';+import { Model, type Tab } from './model';++const backend = isTauri() ? await tauriBackend() : await import('./mock-backend').then(({ mockBackend }) => mockBackend());+const model = new Model(backend);++const previewTab = !isTauri() && (new URLSearchParams(location.search).get('tab') as Tab | null);+if (previewTab) {+ const stop = model.subscribe(() => {+ if (model.snapshot().phase !== 'main') return;+ stop();+ model.setTab(previewTab);+ });+}++createRoot(document.getElementById('root')!).render(+ <StrictMode>+ <App model={model} backend={backend} />+ </StrictMode>,+);diff --git a/src/windows/ui/mock-backend.ts b/src/windows/ui/mock-backend.tsnew file mode 100644index 0000000..f49277d--- /dev/null+++ b/src/windows/ui/mock-backend.ts@@ -0,0 +1,197 @@+import { AGENT_LIST, AGENTS, type AgentKind } from '@/lib/agents/catalog';+import type { GuardrailSettings } from '@/lib/settings/guardrails';+import type { PreferenceChange } from '@/lib/settings/preferences';+import type { AgentListing, Backend, CliOutput, InstallStamp, Lockfile, NodeInstall, Preferences } from './backend';++/**+ * A stand-in machine for working on the window in a plain browser: `yarn win:preview`. Everything+ * is installed and the daemon is running, unless the address ends in #fresh, which starts from a+ * computer that has nothing yet.+ */+export function mockBackend({ instant = false, fresh = location.hash === '#fresh' } = {}): Backend {+ const home = 'C:\\Users\\you';+ const version = '0.8.0';+ let node: NodeInstall | null = fresh ? null : { path: `${home}\\.browsentic\\runtime\\node\\node.exe`, version: 'v24.11.1', isPrivate: true };+ let installed = fresh ? null : version;+ let stamp: InstallStamp | null = fresh ? null : { version, installedAt: new Date().toISOString() };+ let running = !fresh;+ let linked = !fresh;+ let socket = false;+ let active: AgentKind = 'claude';+ const models: Partial<Record<AgentKind, string>> = {};+ const listeners = new Set<(event: string) => void>();+ let preferences: Preferences = { theme: null, guardrails: guardrails(`${home}\\.browsentic\\config.json`) };++ const ok = (stdout: string): CliOutput => ({ ok: true, code: 0, stdout, stderr: '' });+ const later = <T>(value: T, ms = 350) => new Promise<T>((resolve) => setTimeout(() => resolve(value), instant ? 0 : ms));+ const lock = (): Lockfile | null => (running ? { pid: 18115, port: 8765, token: 'mock-token', daemonVersion: version } : null);+ const agents = (): AgentListing => ({+ active,+ runners: AGENT_LIST.map(({ kind, bin }, index) =>+ index < 3+ ? { kind, bin, ready: true, version: `${bin} 2.1.${280 + index}`, model: models[kind] }+ : { kind, bin, ready: false, problem: { code: 'AGENT_MISSING' as const, message: `${AGENTS[kind].label} is not installed.`, fix: AGENTS[kind].install } },+ ),+ catalog: AGENT_LIST,+ });++ const replies: Record<string, (frame: Record<string, unknown>) => Record<string, unknown>> = {+ status: () => ({+ status: { connected: true, daemonVersion: version, protocolVersion: 21, port: 8765, manifestInSync: true, extensionVersion: version, connectedBrowsers: 1, pairedBrowsers: 1, pairingPending: false },+ }),+ sessions: () => ({+ sessions: [+ { id: 's1', browser: 'Google Chrome', origin: 'chrome-extension://pplbfkdfiimmogofmehpibbmldcefgpc/', extensionVersion: version, pairedAt: ago(3 * 86400), lastSeenAt: ago(4), connected: true },+ { id: 's2', browser: 'Microsoft Edge', origin: 'chrome-extension://jmhkmekhafbfbkmpoheoinnbicpbnlpa/', extensionVersion: '0.7.6', pairedAt: ago(9 * 86400), lastSeenAt: ago(2 * 3600), connected: false },+ ],+ }),+ pair: () => ({ code: 'K7Q2M9', expiresAt: Date.now() + 10 * 60 * 1000 }),+ revoke: () => ({ revoked: 1 }),+ preferences: () => ({ result: { ok: true, data: preferences } }),+ setPreference: ({ change }) => {+ const next = change as PreferenceChange;+ preferences = next.kind === 'theme' ? { ...preferences, theme: next.theme } : { ...preferences, guardrails: applyGuardrail(preferences.guardrails, next.setting, next.value) };+ listeners.forEach((listener) => listener('settings-changed'));+ return { result: { ok: true, data: preferences } };+ },+ agent: ({ set }) => {+ if (typeof set === 'string') active = set as AgentKind;+ return { state: agents() };+ },+ };++ const commands: Record<string, (args: string[]) => CliOutput> = {+ start: () => ((running = true), ok('started')),+ stop: () => ((running = false), ok('stopped')),+ restart: () => ok('restarted'),+ setup: () => ((stamp = { version, installedAt: new Date().toISOString() }), ok(JSON.stringify({ version, extensionDir: `${home}\\browsentic\\extension\\chrome-mv3`, daemon: { port: 8765, pid: 18115 }, alreadyPaired: true, pairingCode: null }))),+ agent: (args) => {+ if (args[1] === 'model') models[args[2] as AgentKind] = args[3];+ return ok(JSON.stringify(agents()));+ },+ skills: () => ok(JSON.stringify(skills(home))),+ approvals: () => ok(JSON.stringify({ grants: [{ action: 'page.submitForm', host: 'github.com', at: ago(2 * 86400) }, { action: 'page.captureDownload', host: 'github.com', at: ago(86400) }, { action: 'page.submitForm', host: 'news.ycombinator.com', at: ago(3600) }] })),+ downloads: () => ok(JSON.stringify({ dir: `${home}\\browsentic\\downloads`, downloads: [{ id: 'd1', name: 'invoice-2026-09.pdf', mime: 'application/pdf', size: 48213, url: 'https://example.com/invoice.pdf', host: 'example.com', notes: 'PDF, 47 KB, from example.com', savedTo: `${home}\\browsentic\\downloads\\invoice-2026-09.pdf`, capturedAt: ago(5400) }] })),+ uninstall: () => ((installed = null), (stamp = null), (running = false), ok('removed')),+ };++ return {+ appInfo: () =>+ later({+ version,+ system: { name: 'Windows 11 Pro 24H2', architecture: 'ARM64' },+ paths: {+ home,+ state: `${home}\\.browsentic`,+ extensionDir: `${home}\\browsentic\\extension\\chrome-mv3`,+ log: `${home}\\.browsentic\\daemon.log`,+ shim: `${home}\\.browsentic\\bin\\browsentic.exe`,+ mcpShim: `${home}\\.browsentic\\bin\\browsentic-mcp.exe`,+ bin: `${home}\\.browsentic\\bin`,+ config: `${home}\\.browsentic\\config.json`,+ separator: '\\',+ },+ payload: { bundled: version, installed, current: installed === version },+ }),+ locateNode: () => later(node),+ installNode: async (onProgress) => {+ for (let step = 0; step <= 10; step++) {+ onProgress({ fraction: step / 10, label: step < 9 ? 'Downloading Node.js v24.11.1' : 'Unpacking' });+ await later(null, 160);+ }+ node = { path: `${home}\\.browsentic\\runtime\\node\\node.exe`, version: 'v24.11.1', isPrivate: true };+ return node;+ },+ installPayload: async () => void (installed = await later(version, 700)),+ cli: async (args) => later((commands[args[0]] ?? (() => ok('')))(args)),+ npmInstall: (pkg) => later(ok(`added 1 package: ${pkg}`), 1200),+ extensionStamp: () => later(stamp, 120),+ browsers: () => later([{ name: 'Google Chrome', path: 'C:\\Program Files\\Google\\Chrome\\Application\\chrome.exe' }, { name: 'Microsoft Edge', path: 'C:\\Program Files (x86)\\Microsoft\\Edge\\Application\\msedge.exe' }]),+ openExtensionsPage: () => later(undefined),+ agentsOnPath: (bins) => later(fresh ? [] : bins.slice(0, 3)),+ readLock: () => later(lock(), 60),+ logTail: () => later(log(), 60),+ commandLink: () => later({ linkedIn: linked ? `${home}\\.browsentic\\bin` : null, foreign: null }),+ setCommandLink: (on) => later({ linkedIn: (linked = on) ? `${home}\\.browsentic\\bin` : null, foreign: null }),+ controlConnect: () => (running ? later(!socket && (socket = true), 40) : Promise.reject(new Error('The daemon is not running. Turn it on from the Overview tab.'))),+ controlRequest: (frame) => later((replies[String(frame.op)] ?? (() => ({})))(frame), 60),+ controlClose: () => later(void (socket = false), 20),+ trayStatus: () => later(undefined, 0),+ checkUpdate: () => later(null),+ installUpdate: () => later(undefined),+ onControlEvent: (listener) => (listeners.add(listener), () => listeners.delete(listener)),+ onTray: () => () => undefined,+ openUrl: async (url) => void window.open(url, '_blank'),+ reveal: async () => undefined,+ setWindowTheme: async () => undefined,+ };+}++const ago = (seconds: number) => new Date(Date.now() - seconds * 1000).toISOString();++function guardrails(configPath: string): GuardrailSettings {+ return {+ rules: [+ { id: 'form-submission', title: 'Submits a form', reason: 'Submitting a form can send, buy or post something on your behalf.', fallback: 'confirm' },+ { id: 'site-tool-call', title: 'Calls a tool the site provides', reason: 'A site’s own tools can act on your account there.', fallback: 'confirm' },+ { id: 'file-upload', title: 'Uploads one of the user’s files', reason: 'A file leaves your computer.', fallback: 'confirm', override: 'allow' },+ { id: 'file-download', title: 'Saves a file from the page to disk', reason: 'A file from the web lands on your disk.', fallback: 'allow' },+ { id: 'off-scope-navigation', title: 'Leaves the sites this run is about', reason: 'A run stays on the sites it was asked about.', fallback: 'confirm' },+ { id: 'code-injection', title: 'Runs code it wrote in the page', reason: 'Code the agent wrote runs with the page’s access.', fallback: 'deny', locked: true },+ { id: 'non-http-navigation', title: 'Non-http navigation', reason: 'file:, javascript: and data: addresses are not the web.', fallback: 'deny', locked: true },+ ],+ fence: { enabled: true, overridden: false },+ unattended: { effect: 'deny', overridden: false },+ hosts: ['github.com', 'localhost'],+ configPath,+ };+}++function applyGuardrail(settings: GuardrailSettings, setting: string, value: unknown): GuardrailSettings {+ if (setting === 'fence') return { ...settings, fence: { enabled: value === null ? true : Boolean(value), overridden: value !== null } };+ if (setting === 'unattended') return { ...settings, unattended: { effect: value === 'allow' ? 'allow' : 'deny', overridden: value !== null } };+ return {+ ...settings,+ rules: settings.rules.map((rule) => (rule.id === setting ? { ...rule, override: value === null ? undefined : (value as typeof rule.fallback) } : rule)),+ };+}++function skills(home: string) {+ const skill = (name: string, description: string, source: string, domains: string[] = [], isDefault = false, provenance = 'authored') => ({+ name,+ description,+ triggers: [],+ isDefault,+ category: 'browsing',+ domains,+ source,+ provenance,+ path: `${home}\\browsentic\\skills\\${name}\\SKILL.md`,+ });+ return {+ dirs: ['~\\.browsentic\\cli\\skills', '~\\browsentic\\skills'],+ agent: 'claude',+ agentSkills: [{ name: 'review', description: 'Reviews the current diff for correctness bugs.' }],+ skills: [+ skill('browser-control', 'Drives the page: finds elements by what they say, fills forms, and checks each step landed.', 'bundled', [], true),+ skill('browse-navigation', 'Moves between pages and tabs without losing the thread of a task.', 'bundled', [], true),+ skill('a-eye', 'Reads a picture the user points at, or a chart the page drew.', 'bundled'),+ skill('github-issues', 'Triages issues: labels, duplicates and the first reply.', 'user', ['github.com']),+ skill('hn-front-page', 'A site map of Hacker News: where the threads, the comments and the flags are.', 'user', ['news.ycombinator.com'], false, 'generated'),+ ],+ };+}++function log() {+ const stamp = (seconds: number) => new Date(Date.now() - seconds * 1000).toISOString();+ return [+ `${stamp(310)} daemon listening on 127.0.0.1:8765`,+ `${stamp(300)} native host registered for Chrome, Edge`,+ `${stamp(240)} browser connected: Google Chrome (extension 0.8.0)`,+ `${stamp(200)} paired chrome-extension://pplbfkdfiimmogofmehpibbmldcefgpc`,+ `${stamp(120)} run 7f3a started: claude, 1 tab`,+ `${stamp(90)} page.submitForm on github.com: confirm → allowed`,+ `${stamp(60)} run 7f3a finished in 41s`,+ `${stamp(30)} agent codex: version probe failed: exited 1`,+ ].join('\n');+}diff --git a/src/windows/ui/model.test.ts b/src/windows/ui/model.test.tsnew file mode 100644index 0000000..0d2468a--- /dev/null+++ b/src/windows/ui/model.test.ts@@ -0,0 +1,162 @@+import { afterEach, describe, expect, it } from 'vitest';++import type { Backend } from './backend';+import { mockBackend } from './mock-backend';+import { Model, outcome, parseJson, short, type State } from './model';+import { splitLine } from './views/logs';++const instantly = () => Promise.resolve();+const models: Model[] = [];++function start(backend: Backend) {+ const model = new Model(backend, instantly);+ models.push(model);+ return model;+}++async function until(model: Model, done: (state: State) => boolean, limit = 3000) {+ const started = Date.now();+ while (!done(model.snapshot())) {+ if (Date.now() - started > limit) throw new Error(`gave up waiting; state was ${JSON.stringify({ phase: model.snapshot().phase, daemon: model.snapshot().daemon, checks: model.snapshot().checks })}`);+ await new Promise((resolve) => setTimeout(resolve, 5));+ }+}++afterEach(() => {+ models.splice(0).forEach((model) => model.dispose());+ localStorage.clear();+});++describe('reading what the CLI and the daemon say', () => {+ it('parses --json output that a warning was printed before', () => {+ const output = { ok: true, code: 0, stdout: '! browsentic 0.9.0 is published\n{"grants":[]}', stderr: '' };+ expect(parseJson(output, 'approvals')).toEqual({ grants: [] });+ });++ it('turns a failed command into its own last words, and unreadable output into advice', () => {+ expect(() => parseJson({ ok: false, code: 1, stdout: '', stderr: 'AGENT_MISSING: codex is not installed' }, 'agent')).toThrow('AGENT_MISSING');+ expect(() => parseJson({ ok: true, code: 0, stdout: 'not json', stderr: '' }, 'skills')).toThrow('Update the app');+ });++ it('throws the daemon’s own message for a refused change', () => {+ expect(() => outcome({ ok: false, error: { code: 'BLOCKED', message: 'An agent run cannot change the settings it runs under.' } })).toThrow(+ 'An agent run cannot change the settings it runs under.',+ );+ expect(outcome({ ok: true, data: { theme: 'ember' } })).toEqual({ theme: 'ember' });+ });++ it('writes a Windows path under %USERPROFILE% and leaves others whole', async () => {+ const info = await mockBackend({ instant: true }).appInfo();+ expect(short('C:\\Users\\you\\.browsentic\\cli', info)).toBe('%USERPROFILE%\\.browsentic\\cli');+ expect(short('D:\\elsewhere', info)).toBe('D:\\elsewhere');+ });++ it('reads the clock time off a log line', () => {+ expect(splitLine('2026-09-27T17:10:15.381Z daemon listening on 127.0.0.1:8765')).toEqual({ time: '17:10:15', message: 'daemon listening on 127.0.0.1:8765' });+ expect(splitLine('no stamp here')).toEqual({ time: 'no', message: 'stamp here' });+ });+});++describe('the preflight', () => {+ it('finds a computer with nothing installed, and does not open the app', async () => {+ const model = start(mockBackend({ instant: true, fresh: true }));+ await model.runPreflight();+ const { checks, phase } = model.snapshot();+ expect([checks.node.kind, checks.command.kind, checks.extensionFiles.kind, checks.browser.kind, checks.agent.kind]).toEqual([+ 'missing',+ 'missing',+ 'missing',+ 'passed',+ 'advisory',+ ]);+ expect(phase).toBe('preflight');+ expect(model.needsSetup).toBe(true);+ });++ it('sets everything up in one press, then opens and turns the daemon on', async () => {+ const model = start(mockBackend({ instant: true, fresh: true }));+ await model.runPreflight();+ await model.setUpEverything();+ await until(model, (state) => state.daemon === 'on');+ const { checks, phase, status } = model.snapshot();+ expect([checks.node.kind, checks.command.kind, checks.extensionFiles.kind]).toEqual(['passed', 'passed', 'passed']);+ expect(phase).toBe('main');+ expect(status?.port).toBe(8765);+ });++ it('opens by itself when everything is in place, and reads the shared settings once the socket is new', async () => {+ const model = start(mockBackend({ instant: true }));+ await model.runPreflight();+ await until(model, (state) => state.phase === 'main' && !!state.preferences && state.sessions.length > 0);+ expect(model.snapshot().preferences?.guardrails.rules.length).toBeGreaterThan(0);+ });++ it('finishes an update by itself when the new app carries a newer command', async () => {+ const base = mockBackend({ instant: true });+ let installed = '0.7.6';+ const backend: Backend = {+ ...base,+ appInfo: async () => {+ const info = await base.appInfo();+ return { ...info, payload: { bundled: '0.8.0', installed, current: installed === '0.8.0' } };+ },+ installPayload: async () => void (installed = '0.8.0'),+ };+ localStorage.setItem('browsentic/finishUpdateOnLaunch', 'true');+ const model = start(backend);+ await model.runPreflight();+ await until(model, (state) => state.phase === 'main');+ expect(model.snapshot().checks.command.kind).toBe('passed');+ expect(localStorage.getItem('browsentic/finishUpdateOnLaunch')).toBeNull();+ });+});++describe('the running app', () => {+ async function running() {+ const model = start(mockBackend({ instant: true }));+ await model.runPreflight();+ await until(model, (state) => state.daemon === 'on' && !!state.preferences);+ return model;+ }++ it('hands out a pairing code and unpairs a browser, saying how many', async () => {+ const model = await running();+ await model.newPairingCode();+ expect(model.snapshot().pairing?.code).toBe('K7Q2M9');+ await model.revoke(model.snapshot().sessions[0]);+ expect(model.snapshot().notice?.text).toBe('Unpaired 1 browser.');+ });++ it('writes a guardrail and a browser theme through the daemon', async () => {+ const model = await running();+ await model.setGuardrail('form-submission', 'allow');+ await model.setBrowserTheme('midnight');+ const { preferences } = model.snapshot();+ expect(preferences?.theme).toBe('midnight');+ expect(preferences?.guardrails.rules.find((rule) => rule.id === 'form-submission')?.override).toBe('allow');+ });++ it('switches the agent and keeps the catalog it already had', async () => {+ const model = await running();+ await until(model, (state) => !!state.agents?.catalog);+ await model.selectAgent('codex');+ expect(model.snapshot().agents?.active).toBe('codex');+ expect(model.snapshot().agents?.catalog?.length).toBeGreaterThan(0);+ });++ it('turns the daemon off and back on', async () => {+ const model = await running();+ await model.setDaemon(false);+ expect(model.snapshot().daemon).toBe('off');+ await model.setDaemon(true);+ expect(model.snapshot().daemon).toBe('on');+ });++ it('remembers the window’s appearance and whether the daemon starts with the app', () => {+ const model = start(mockBackend({ instant: true }));+ model.setAppearance('dark');+ model.setStartDaemonOnLaunch(false);+ const again = start(mockBackend({ instant: true }));+ expect([again.snapshot().appearance, again.snapshot().startDaemonOnLaunch]).toEqual(['dark', false]);+ });+});diff --git a/src/windows/ui/model.ts b/src/windows/ui/model.tsnew file mode 100644index 0000000..3d1c24d--- /dev/null+++ b/src/windows/ui/model.ts@@ -0,0 +1,790 @@+import { useSyncExternalStore } from 'react';++import { AGENT_LIST, type AgentDescriptor, type AgentKind } from '@/lib/agents/catalog';+import type { GuardrailValue } from '@/lib/settings/guardrails';+import type { PreferenceChange } from '@/lib/settings/preferences';+import type { ThemeId } from '@/lib/settings/theme';+import type {+ AgentListing,+ AppInfo,+ Backend,+ Browser,+ BridgeStatus,+ CliOutput,+ CommandLink,+ DownloadListing,+ Grant,+ InstallStamp,+ Lockfile,+ NodeInstall,+ PairingCode,+ Preferences,+ Release,+ SessionSummary,+ SkillListing,+} from './backend';++export type Phase = 'preflight' | 'main';+export type DaemonPhase = 'off' | 'starting' | 'on' | 'stopping';+export type Tab = 'overview' | 'browsers' | 'agents' | 'skills' | 'activity' | 'logs' | 'settings';+export const TABS: Tab[] = ['overview', 'browsers', 'agents', 'skills', 'activity', 'logs', 'settings'];++export type CheckId = 'system' | 'node' | 'command' | 'extensionFiles' | 'browser' | 'agent';+export const CHECKS: CheckId[] = ['system', 'node', 'command', 'extensionFiles', 'browser', 'agent'];+/** What "Set up everything" installs on its own. A browser and an agent are the user's pick. */+export const INSTALLS_AUTOMATICALLY: CheckId[] = ['node', 'command', 'extensionFiles'];++export type CheckState =+ | { kind: 'waiting' }+ | { kind: 'checking' }+ | { kind: 'passed' | 'missing' | 'advisory' | 'failed'; text: string }+ | { kind: 'working'; fraction?: number; text: string };++export type UpdatePhase =+ | { kind: 'idle' }+ | { kind: 'checking' }+ | { kind: 'downloading'; fraction: number }+ | { kind: 'relaunching' }+ | { kind: 'failed'; reason: string };++export type Appearance = 'system' | 'light' | 'dark';++export interface Notice {+ id: number;+ text: string;+ isError: boolean;+}++export interface State {+ phase: Phase;+ tab: Tab;+ checks: Record<CheckId, CheckState>;+ preflightBusy: boolean;+ fixing: boolean;+ info?: AppInfo;+ node?: NodeInstall | null;+ daemon: DaemonPhase;+ lock?: Lockfile;+ status?: BridgeStatus;+ sessions: SessionSummary[];+ pairing?: PairingCode;+ agents?: AgentListing;+ preferences?: Preferences;+ /** The running daemon never answered for its settings: it predates this app and needs a restart. */+ preferencesUnsupported: boolean;+ skills?: SkillListing;+ grants: Grant[];+ downloads?: DownloadListing;+ stamp?: InstallStamp | null;+ browsers: Browser[];+ logText: string;+ commandLink?: CommandLink;+ update?: Release;+ updatePhase: UpdatePhase;+ lastUpdateCheck?: number;+ busy: string[];+ notice?: Notice;+ appearance: Appearance;+ startDaemonOnLaunch: boolean;+}++const MINIMUM_NODE = 20;+const FINISH_UPDATE = 'browsentic/finishUpdateOnLaunch';+const APPEARANCE = 'browsentic/appearance';+const START_ON_LAUNCH = 'browsentic/startDaemonOnLaunch';+const CLAUDE_CODE = '@anthropic-ai/claude-code';++const pause = (ms: number) => new Promise((resolve) => setTimeout(resolve, ms));++const stored = (key: string): string | null => {+ try {+ return localStorage.getItem(key);+ } catch {+ return null;+ }+};++const store = (key: string, value: string | null) => {+ try {+ if (value === null) localStorage.removeItem(key);+ else localStorage.setItem(key, value);+ } catch {+ /* A window with no storage keeps its choices for this session only. */+ }+};++export const isPassed = (state: CheckState | undefined) => state?.kind === 'passed';+export const needsAttention = (state: CheckState | undefined) => state?.kind === 'missing' || state?.kind === 'failed';+export const isInstalling = (phase: UpdatePhase) => phase.kind === 'downloading' || phase.kind === 'relaunching';++export function failureOf(output: CliOutput): string {+ const text = (output.stderr.trim() || output.stdout.trim()).slice(-400);+ return text || 'The browsentic command exited with an error. See the Logs tab.';+}++/** The CLI's --json output, from its first bracket: a warning printed before it is not part of it. */+export function parseJson<T>(output: CliOutput, command: string): T {+ if (!output.ok) throw new Error(failureOf(output));+ const start = output.stdout.search(/[[{]/);+ try {+ return JSON.parse(output.stdout.slice(start)) as T;+ } catch {+ throw new Error(`“browsentic ${command}” printed something this app cannot read. Update the app.`);+ }+}++/** A path as a Windows user reads one in prose: under %USERPROFILE%, never with a tilde. */+export function short(path: string, info: AppInfo | undefined): string {+ if (!info || !path.toLowerCase().startsWith(info.paths.home.toLowerCase())) return path;+ const rest = path.slice(info.paths.home.length);+ return info.paths.separator === '\\' ? `%USERPROFILE%${rest}` : `~${rest}`;+}++export const initialState = (): State => ({+ phase: 'preflight',+ tab: 'overview',+ checks: Object.fromEntries(CHECKS.map((id) => [id, { kind: 'waiting' }])) as Record<CheckId, CheckState>,+ preflightBusy: true,+ fixing: false,+ daemon: 'off',+ sessions: [],+ preferencesUnsupported: false,+ grants: [],+ browsers: [],+ logText: '',+ updatePhase: { kind: 'idle' },+ busy: [],+ appearance: (stored(APPEARANCE) as Appearance | null) ?? 'system',+ startDaemonOnLaunch: stored(START_ON_LAUNCH) !== 'false',+});++export class Model {+ private state: State = initialState();+ private listeners = new Set<() => void>();+ private poller?: ReturnType<typeof setInterval>;+ private updateWatcher?: ReturnType<typeof setInterval>;+ private stopEvents?: () => void;+ private noticeTimer?: ReturnType<typeof setTimeout>;+ private noticeCount = 0;+ private started = false;++ constructor(+ private readonly backend: Backend,+ private readonly pace: (ms: number) => Promise<unknown> = pause,+ ) {+ backend.onTray((action) => {+ if (action === 'toggle') void this.setDaemon(this.state.daemon === 'off');+ if (action === 'restart') void this.restartDaemon();+ });+ }++ subscribe = (listener: () => void) => {+ this.listeners.add(listener);+ return () => this.listeners.delete(listener);+ };++ snapshot = () => this.state;++ private set(patch: Partial<State> | ((state: State) => Partial<State>)) {+ const next = typeof patch === 'function' ? patch(this.state) : patch;+ const before = this.state;+ this.state = { ...this.state, ...next };+ this.listeners.forEach((listener) => listener());+ if (before.daemon !== this.state.daemon || before.status !== this.state.status || before.phase !== this.state.phase) {+ void this.syncTray();+ }+ }++ private check(id: CheckId, state: CheckState) {+ this.set((current) => ({ checks: { ...current.checks, [id]: state } }));+ }++ get canEnter() {+ return INSTALLS_AUTOMATICALLY.every((id) => isPassed(this.state.checks[id]));+ }++ get needsSetup() {+ return INSTALLS_AUTOMATICALLY.some((id) => !isPassed(this.state.checks[id]));+ }++ get extensionNeedsReload() {+ const { stamp, status } = this.state;+ return !!stamp && !!status?.connected && !!status.extensionVersion && status.extensionVersion !== stamp.version;+ }++ // Preflight++ start() {+ if (this.started) return;+ this.started = true;+ void this.runPreflight();+ }++ async runPreflight() {+ this.set({ preflightBusy: true, checks: initialState().checks });+ for (const id of CHECKS) {+ this.check(id, { kind: 'checking' });+ const [state] = await Promise.all([this.evaluate(id), this.pace(420)]);+ this.check(id, state);+ }+ this.set({ preflightBusy: false });+ if (this.finishingUpdate()) {+ await this.setUpEverything();+ if (this.state.phase === 'main') this.say(`Browsentic ${this.state.info?.version} is installed.`);+ return;+ }+ if (this.canEnter && !CHECKS.some((id) => needsAttention(this.state.checks[id]))) {+ await this.pace(900);+ this.enter();+ }+ }++ private async evaluate(id: CheckId): Promise<CheckState> {+ try {+ switch (id) {+ case 'system': {+ const info = await this.backend.appInfo();+ this.set({ info });+ return { kind: 'passed', text: `${info.system.name} · ${info.system.architecture}` };+ }+ case 'node': {+ const node = await this.backend.locateNode();+ this.set({ node });+ if (!node) {+ return { kind: 'missing', text: `Version ${MINIMUM_NODE} or newer runs the daemon. A private copy goes in ${this.short(`${this.state.info?.paths.state}${this.sep}runtime`)}.` };+ }+ return { kind: 'passed', text: `${node.version} · ${node.isPrivate ? 'private copy' : this.short(node.path)}` };+ }+ case 'command': {+ const info = await this.backend.appInfo();+ this.set({ info });+ const { bundled, installed, current } = info.payload;+ const cli = this.short(`${info.paths.state}${this.sep}cli`);+ if (!bundled) return { kind: 'failed', text: 'This copy of Browsentic carries no CLI payload. Download a fresh one from browsentic.com.' };+ if (current) return { kind: 'passed', text: `v${bundled} in ${cli}` };+ if (installed && installed !== bundled) return { kind: 'missing', text: `v${installed} is installed; this app carries v${bundled}.` };+ return { kind: 'missing', text: `Installs the CLI and daemon into ${cli}.` };+ }+ case 'extensionFiles': {+ const stamp = await this.backend.extensionStamp();+ this.set({ stamp });+ const bundled = this.state.info?.payload.bundled;+ const dir = this.short(this.state.info?.paths.extensionDir ?? '');+ if (!bundled) return { kind: 'failed', text: 'This copy of Browsentic carries no CLI payload. Download a fresh one from browsentic.com.' };+ if (!stamp) return { kind: 'missing', text: `Unpacks to ${dir}, where the browser loads it from.` };+ if (stamp.version !== bundled) return { kind: 'missing', text: `v${stamp.version} is unpacked; this app carries v${bundled}.` };+ return { kind: 'passed', text: `v${stamp.version} in ${dir}` };+ }+ case 'browser': {+ const browsers = await this.backend.browsers();+ this.set({ browsers });+ return browsers.length+ ? { kind: 'passed', text: browsers.map((browser) => browser.name).join(', ') }+ : { kind: 'advisory', text: 'None found. Chrome, Edge, Brave, Vivaldi or Opera all work.' };+ }+ case 'agent': {+ const found = await this.backend.agentsOnPath(AGENT_LIST.map((agent) => agent.bin));+ const labels = AGENT_LIST.filter((agent) => found.includes(agent.bin)).map((agent) => agent.label);+ return labels.length+ ? { kind: 'passed', text: labels.join(', ') }+ : { kind: 'advisory', text: 'None on your PATH. The side panel needs one, such as Claude Code or Codex.' };+ }+ }+ } catch (error) {+ return { kind: 'failed', text: messageOf(error) };+ }+ }++ /** After an update the new app carries a newer command and extension, and the person already asked for them. */+ private finishingUpdate() {+ const asked = stored(FINISH_UPDATE) === 'true';+ store(FINISH_UPDATE, null);+ return asked && (!isPassed(this.state.checks.command) || !isPassed(this.state.checks.extensionFiles)) && isPassed(this.state.checks.node);+ }++ async setUpEverything() {+ this.set({ fixing: true });+ try {+ for (const id of INSTALLS_AUTOMATICALLY) {+ if (!isPassed(this.state.checks[id]) && !(await this.fix(id))) return;+ }+ if (this.canEnter) {+ await this.pace(700);+ this.enter();+ }+ } finally {+ this.set({ fixing: false });+ }+ }++ async fix(id: CheckId): Promise<boolean> {+ try {+ switch (id) {+ case 'node': {+ this.check(id, { kind: 'working', fraction: 0, text: 'Starting' });+ const node = await this.backend.installNode(({ fraction, label }) => this.check('node', { kind: 'working', fraction, text: label }));+ this.set({ node });+ break;+ }+ case 'command': {+ this.requireNode();+ this.check(id, { kind: 'working', text: `Copying the CLI into ${this.short(`${this.state.info?.paths.state}${this.sep}cli`)}` });+ const wasRunning = !!(await this.backend.readLock()) && !!this.state.info?.payload.installed;+ if (wasRunning) await this.backend.cli(['stop']);+ await this.backend.installPayload();+ if (wasRunning) {+ this.check(id, { kind: 'working', text: 'Restarting the daemon on the new build' });+ await this.run(['start']);+ }+ break;+ }+ case 'extensionFiles':+ this.requireNode();+ this.check(id, { kind: 'working', text: 'Unpacking the extension' });+ parseJson(await this.backend.cli(['setup', '--no-pair', '--no-self-update', '--json'], 120), 'setup');+ break;+ case 'agent': {+ this.requireNode();+ this.check(id, { kind: 'working', text: `npm install --global ${CLAUDE_CODE}` });+ const output = await this.backend.npmInstall(CLAUDE_CODE);+ if (!output.ok) throw new Error(failureOf(output));+ break;+ }+ case 'browser':+ await this.backend.openUrl('https://www.google.com/chrome/');+ return true;+ case 'system':+ return true;+ }+ const state = await this.evaluate(id);+ this.check(id, state);+ return state.kind === 'passed';+ } catch (error) {+ this.check(id, { kind: 'failed', text: messageOf(error) });+ return false;+ }+ }++ enter() {+ this.set({ phase: 'main' });+ this.startPolling();+ void this.refreshCommandLink();+ if (this.state.startDaemonOnLaunch && this.state.daemon === 'off') void this.setDaemon(true);+ this.watchForUpdates();+ }++ showPreflight() {+ this.set({ phase: 'preflight' });+ void this.runPreflight();+ }++ setTab(tab: Tab) {+ if (this.state.phase === 'main') this.set({ tab });+ }++ // Daemon++ private startPolling() {+ this.stopEvents?.();+ this.stopEvents = this.backend.onControlEvent((event) => {+ if (event !== 'settings-changed') return;+ void this.loadPreferences();+ void this.loadAgents();+ });+ clearInterval(this.poller);+ void this.refresh();+ this.poller = setInterval(() => void this.refresh(), 2000);+ }++ dispose() {+ this.stopPolling();+ clearTimeout(this.noticeTimer);+ }++ private stopPolling() {+ clearInterval(this.poller);+ clearInterval(this.updateWatcher);+ this.stopEvents?.();+ }++ async refresh() {+ const lock = await this.backend.readLock().catch(() => null);+ if (!lock) return this.markOff();+ try {+ if (await this.backend.controlConnect()) void this.loadPreferences(true);+ const status = (await this.control({ op: 'status' })).status as BridgeStatus;+ const sessions = (await this.control({ op: 'sessions' })).sessions as SessionSummary[];+ const stamp = await this.backend.extensionStamp();+ this.set((state) => ({+ lock,+ status,+ sessions,+ stamp,+ daemon: state.daemon === 'stopping' ? 'stopping' : 'on',+ pairing: state.pairing && status.pairingPending && state.pairing.expiresAt > Date.now() ? state.pairing : undefined,+ }));+ if (!this.state.agents) await this.loadAgents();+ } catch {+ await this.backend.controlClose();+ this.markOff();+ }+ }++ private markOff() {+ if (this.state.daemon === 'starting') return;+ this.set({ daemon: 'off', lock: undefined, status: undefined, sessions: [], pairing: undefined, preferences: undefined });+ }++ async setDaemon(on: boolean) {+ if (!this.state.node || this.state.daemon !== (on ? 'off' : 'on')) return;+ this.set({ daemon: on ? 'starting' : 'stopping' });+ try {+ if (on) await this.run(['start']);+ else {+ await this.backend.controlClose();+ await this.run(['stop']);+ }+ } catch (error) {+ this.report(error);+ }+ this.set({ daemon: on ? 'starting' : 'off' });+ if (!on) this.markOff();+ await this.refresh();+ if (on && this.snapshot().daemon === 'starting') this.set({ daemon: 'off' });+ }++ async restartDaemon() {+ await this.perform('restart', async () => {+ this.set({ daemon: 'starting' });+ await this.backend.controlClose();+ await this.run(['restart']);+ this.set({ agents: undefined });+ });+ await this.refresh();+ if (this.snapshot().daemon === 'starting') this.set({ daemon: 'off' });+ }++ // Operations++ newPairingCode() {+ return this.perform('pair', async () => {+ const reply = await this.control({ op: 'pair' });+ this.set({ pairing: { code: String(reply.code), expiresAt: Number(reply.expiresAt) } });+ });+ }++ async revoke(session?: SessionSummary) {+ await this.perform('revoke', async () => {+ const reply = await this.control(session ? { op: 'revoke', origin: session.origin, session: session.id } : { op: 'revoke' });+ const count = Number(reply.revoked);+ this.say(count === 0 ? 'Nothing to unpair.' : `Unpaired ${count} browser${count === 1 ? '' : 's'}.`);+ });+ await this.refresh();+ }++ async loadAgents() {+ if (!this.state.node) return;+ try {+ this.set({ agents: parseJson<AgentListing>(await this.backend.cli(['agent', '--json']), 'agent') });+ } catch {+ /* The Agents tab shows its own offline hint; a failed background read says nothing. */+ }+ }++ async loadPreferences(watch = false) {+ try {+ const reply = await this.control({ op: 'preferences', watch });+ this.set({ preferences: outcome<Preferences>(reply.result), preferencesUnsupported: false });+ } catch (error) {+ if (messageOf(error).includes('did not answer in time')) this.set({ preferencesUnsupported: true });+ }+ }++ setBrowserTheme(theme: ThemeId) {+ return this.setPreference('theme', { kind: 'theme', theme });+ }++ setGuardrail(setting: string, value: GuardrailValue) {+ return this.setPreference(`guardrail:${setting}`, { kind: 'guardrail', setting, value });+ }++ private setPreference(key: string, change: PreferenceChange) {+ return this.perform(key, async () => {+ const reply = await this.control({ op: 'setPreference', change });+ this.set({ preferences: outcome<Preferences>(reply.result) });+ });+ }++ selectAgent(kind: AgentKind) {+ return this.agentChange(kind, { op: 'agent', set: kind });+ }++ repairAgent(kind: AgentKind) {+ return this.agentChange(kind, { op: 'agent', grant: kind });+ }++ private agentChange(kind: AgentKind, frame: Record<string, unknown>) {+ return this.perform(`agent:${kind}`, async () => {+ const reply = await this.control(frame, 60_000);+ this.set((state) => ({ agents: { ...(reply.state as AgentListing), catalog: state.agents?.catalog } }));+ });+ }++ setModel(model: string | null, kind: AgentKind) {+ return this.perform(`agent:${kind}`, async () => {+ await this.run(['agent', 'model', kind, ...(model ? [model] : [])]);+ this.set({ agents: parseJson<AgentListing>(await this.backend.cli(['agent', '--json']), 'agent') });+ });+ }++ async installAgent(descriptor: AgentDescriptor) {+ if (!descriptor.install.startsWith('npm ') || !this.state.node) {+ await this.backend.openUrl(descriptor.docs);+ return;+ }+ const pkg = descriptor.install.split(' ').at(-1) ?? '';+ await this.perform(`agent:${descriptor.kind}`, async () => {+ const output = await this.backend.npmInstall(pkg);+ if (!output.ok) throw new Error(failureOf(output));+ this.set({ agents: parseJson<AgentListing>(await this.backend.cli(['agent', '--json']), 'agent') });+ this.say(`${descriptor.label} is installed. Run “${descriptor.bin}” in a terminal once to sign in.`);+ });+ }++ loadSkills() {+ return this.perform('skills', async () => this.set({ skills: parseJson<SkillListing>(await this.backend.cli(['skills', '--json']), 'skills') }), true);+ }++ loadActivity() {+ return this.perform(+ 'activity',+ async () => {+ const grants = parseJson<{ grants: Grant[] }>(await this.backend.cli(['approvals', '--json']), 'approvals').grants;+ const downloads = parseJson<DownloadListing>(await this.backend.cli(['downloads', '--json']), 'downloads');+ this.set({ grants, downloads });+ },+ true,+ );+ }++ clearApprovals(host?: string) {+ return this.perform('approvals', async () => {+ await this.run(['approvals', 'clear', ...(host ? [host] : [])]);+ this.set({ grants: parseJson<{ grants: Grant[] }>(await this.backend.cli(['approvals', '--json']), 'approvals').grants });+ });+ }++ clearDownloads() {+ return this.perform('downloads', async () => {+ await this.run(['downloads', 'clear']);+ this.set({ downloads: parseJson<DownloadListing>(await this.backend.cli(['downloads', '--json']), 'downloads') });+ });+ }++ reinstallExtension() {+ return this.perform('extension', async () => {+ const result = parseJson<{ version: string }>(await this.backend.cli(['setup', '--no-pair', '--no-self-update', '--force', '--json'], 120), 'setup');+ this.set({ stamp: await this.backend.extensionStamp() });+ this.say(`Extension v${result.version} written. Press ↻ on its card at chrome://extensions.`);+ });+ }++ async openExtensionsPage(browser: Browser) {+ await copy(this.state.info?.paths.extensionDir ?? '');+ try {+ await this.backend.openExtensionsPage(browser);+ this.say('The extension’s folder is on your clipboard. In the folder picker, paste it into the address bar.');+ } catch (error) {+ this.report(error);+ }+ }++ async loadLog() {+ const logText = await this.backend.logTail().catch(() => '');+ if (logText !== this.state.logText) this.set({ logText });+ }++ async refreshCommandLink() {+ this.set({ commandLink: await this.backend.commandLink().catch(() => undefined) });+ }++ async setCommandLink(on: boolean) {+ try {+ const commandLink = await this.backend.setCommandLink(on);+ this.set({ commandLink });+ if (on) this.say('“browsentic” now runs from any new terminal.');+ } catch (error) {+ this.report(error);+ }+ }++ async uninstall(keepSkills: boolean) {+ await this.perform('uninstall', async () => {+ await this.backend.controlClose();+ await this.backend.setCommandLink(false).catch(() => undefined);+ await this.run(['uninstall', '--yes', ...(keepSkills ? ['--keep-skills'] : [])], 60);+ this.stopPolling();+ this.markOff();+ this.set({ phase: 'preflight' });+ });+ await this.runPreflight();+ }++ setAppearance(appearance: Appearance) {+ store(APPEARANCE, appearance);+ this.set({ appearance });+ }++ setStartDaemonOnLaunch(on: boolean) {+ store(START_ON_LAUNCH, String(on));+ this.set({ startDaemonOnLaunch: on });+ }++ // Updates++ private watchForUpdates() {+ clearInterval(this.updateWatcher);+ void this.checkForUpdate();+ this.updateWatcher = setInterval(() => void this.checkForUpdate(), 6 * 3600 * 1000);+ }++ async checkForUpdate(announce = false) {+ if (this.state.updatePhase.kind !== 'idle') return;+ this.set({ updatePhase: { kind: 'checking' } });+ try {+ const found = await this.backend.checkUpdate();+ if (found && found.version !== this.state.update?.version) {+ this.say(`Browsentic ${found.version} is out. You have ${this.state.info?.version}. Update from the Overview tab.`);+ } else if (announce && !found) {+ this.say(`Browsentic ${this.state.info?.version} is the latest.`);+ }+ this.set({ update: found ?? undefined, lastUpdateCheck: Date.now() });+ } catch (error) {+ if (announce) this.report(error);+ } finally {+ if (this.snapshot().updatePhase.kind === 'checking') this.set({ updatePhase: { kind: 'idle' } });+ }+ }++ async installUpdate() {+ if (!this.state.update || isInstalling(this.state.updatePhase)) return;+ this.set({ updatePhase: { kind: 'downloading', fraction: 0 } });+ store(FINISH_UPDATE, 'true');+ try {+ await this.backend.installUpdate((fraction) => this.set({ updatePhase: { kind: 'downloading', fraction } }));+ this.set({ updatePhase: { kind: 'relaunching' } });+ } catch (error) {+ store(FINISH_UPDATE, null);+ this.set({ updatePhase: { kind: 'failed', reason: messageOf(error) } });+ }+ }++ dismissUpdateFailure() {+ if (this.state.updatePhase.kind === 'failed') this.set({ updatePhase: { kind: 'idle' } });+ }++ // Plumbing++ private get sep() {+ return this.state.info?.paths.separator ?? '\\';+ }++ private short(path: string) {+ return short(path, this.state.info);+ }++ private requireNode() {+ if (!this.state.node) throw new Error('Node.js has to be installed first.');+ }++ private async run(args: string[], timeoutSecs?: number) {+ const output = await this.backend.cli(args, timeoutSecs);+ if (!output.ok) throw new Error(failureOf(output));+ return output;+ }++ private async control(frame: Record<string, unknown>, timeoutMs?: number) {+ const reply = await this.backend.controlRequest(frame, timeoutMs);+ if (typeof reply.error === 'object' && reply.error) throw new Error(String((reply.error as { message?: unknown }).message ?? 'The daemon refused that.'));+ return reply;+ }++ private async perform(key: string, work: () => Promise<unknown>, quiet = false) {+ if (!this.state.node || this.state.busy.includes(key)) return;+ this.set((state) => ({ busy: [...state.busy, key] }));+ try {+ await work();+ } catch (error) {+ if (!quiet) this.report(error);+ } finally {+ this.set((state) => ({ busy: state.busy.filter((held) => held !== key) }));+ }+ }++ reveal(path: string) {+ return this.backend.reveal(path).catch((error) => this.report(error));+ }++ openUrl(url: string) {+ return this.backend.openUrl(url).catch((error) => this.report(error));+ }++ isBusy(key: string) {+ return this.state.busy.includes(key);+ }++ say(text: string) {+ this.show(text, false);+ }++ report(error: unknown) {+ this.show(messageOf(error), true);+ }++ private show(text: string, isError: boolean) {+ const notice = { id: ++this.noticeCount, text, isError };+ this.set({ notice });+ clearTimeout(this.noticeTimer);+ this.noticeTimer = setTimeout(() => {+ if (this.state.notice?.id === notice.id) this.set({ notice: undefined });+ }, isError ? 7000 : 4500);+ }++ private async syncTray() {+ const { daemon, status, phase } = this.state;+ const label = { off: 'Off', starting: 'Starting', on: 'Running', stopping: 'Stopping' }[daemon];+ const link = status ? ` · extension ${status.connected ? 'connected' : 'not connected'}` : '';+ await this.backend+ .trayStatus({+ summary: `Daemon: ${label}${status ? ` · 127.0.0.1:${status.port}` : ''}${link}`,+ toggle: daemon === 'on' ? 'Turn Off' : 'Turn On',+ canToggle: phase === 'main' && (daemon === 'on' || daemon === 'off'),+ canRestart: daemon === 'on',+ })+ .catch(() => undefined);+ }+}++export function outcome<T>(result: unknown): T {+ const answer = result as { ok?: boolean; data?: T; error?: { message?: string } } | undefined;+ if (answer?.ok && answer.data !== undefined) return answer.data;+ throw new Error(answer?.error?.message ?? 'The daemon answered with something this app cannot read. Update the app.');+}++export function messageOf(error: unknown): string {+ if (error instanceof Error) return error.message;+ return typeof error === 'string' ? error : 'Something went wrong.';+}++export async function copy(text: string) {+ try {+ await navigator.clipboard.writeText(text);+ } catch {+ /* Nothing to fall back on: the button says Copied only when this succeeds. */+ throw new Error('The clipboard refused the copy.');+ }+}++export function useModelState(model: Model): State {+ return useSyncExternalStore(model.subscribe, model.snapshot);+}diff --git a/src/windows/ui/views/activity.tsx b/src/windows/ui/views/activity.tsxnew file mode 100644index 0000000..7d83a57--- /dev/null+++ b/src/windows/ui/views/activity.tsx@@ -0,0 +1,113 @@+import { useEffect, useState } from 'react';+import { FileDown, FileText, Folder, ShieldCheck } from 'lucide-react';++import { formatWhen } from '@/lib/format-when';+import { Card, ConfirmDialog, EmptyState, PathRow, Pill, QuietButton, SectionTitle } from '../components';+import type { Model, State } from '../model';++const ago = (iso: string) => formatWhen(Date.parse(iso));++export function ActivityView({ model, state }: { model: Model; state: State }) {+ const [confirming, setConfirming] = useState<'approvals' | 'downloads' | null>(null);+ useEffect(() => void model.loadActivity(), [model]);++ const hosts = Object.entries(Object.groupBy(state.grants, (grant) => grant.host)).sort(([a], [b]) => a.localeCompare(b));+ const downloads = state.downloads?.downloads ?? [];++ return (+ <div className="space-y-4.5">+ <Card>+ <div className="space-y-3">+ <div className="flex items-start gap-3">+ <div className="min-w-0 flex-1">+ <SectionTitle title="Standing approvals" subtitle="Every “always on this site” you have granted. These actions no longer ask on these sites." />+ </div>+ {state.grants.length > 0 && (+ <QuietButton tint="danger" onClick={() => setConfirming('approvals')}>+ Forget all+ </QuietButton>+ )}+ </div>+ {hosts.length === 0 ? (+ <EmptyState icon={ShieldCheck} title="Nothing is pre-approved" detail="Every gated action still asks before it runs." />+ ) : (+ hosts.map(([host, grants = []]) => (+ <div key={host} className="flex items-start gap-3 rounded-xl bg-ground-2 p-3">+ <div className="min-w-0 flex-1 space-y-1.5">+ <p className="text-[13px] font-semibold text-ink">{host}</p>+ <div className="flex flex-wrap gap-1.25">+ {grants.map((grant) => (+ <Pill key={grant.action} text={`${grant.action.replace('page.', '')} · ${ago(grant.at)}`} />+ ))}+ </div>+ </div>+ <QuietButton disabled={state.busy.includes('approvals')} onClick={() => void model.clearApprovals(host)}>+ Forget+ </QuietButton>+ </div>+ ))+ )}+ </div>+ </Card>++ <Card>+ <div className="space-y-3">+ <div className="flex items-start gap-3">+ <div className="min-w-0 flex-1">+ <SectionTitle title="Captured downloads" subtitle="Files an agent pulled off a page. The daemon sweeps them after two weeks." />+ </div>+ {downloads.length > 0 && (+ <QuietButton tint="danger" onClick={() => setConfirming('downloads')}>+ Delete all+ </QuietButton>+ )}+ </div>+ {state.downloads && <PathRow path={state.downloads.dir} model={model} info={state.info} />}+ {downloads.length === 0 ? (+ <EmptyState icon={FileDown} title="Nothing captured" detail="Files land here when an agent uses page.captureDownload." />+ ) : (+ downloads.map((download) => (+ <div key={download.id} className="flex items-center gap-3 rounded-xl bg-ground-2 p-3">+ <FileText className="size-4 shrink-0 text-brand" />+ <div className="min-w-0 flex-1 space-y-0.5">+ <p className="truncate text-[12.5px] font-medium text-ink">{download.name}</p>+ <p className="truncate text-[11.5px] text-ink-dim">+ {download.notes} · {ago(download.capturedAt)}+ </p>+ </div>+ <QuietButton icon={Folder} onClick={() => void model.reveal(download.savedTo)}>+ Show+ </QuietButton>+ </div>+ ))+ )}+ </div>+ </Card>++ {confirming === 'approvals' && (+ <ConfirmDialog+ title="Forget every standing approval?"+ message="Gated actions will ask again on every site."+ action="Forget all"+ onCancel={() => setConfirming(null)}+ onConfirm={() => {+ setConfirming(null);+ void model.clearApprovals();+ }}+ />+ )}+ {confirming === 'downloads' && (+ <ConfirmDialog+ title="Delete every captured download?"+ message="The files are removed from disk."+ action="Delete all"+ onCancel={() => setConfirming(null)}+ onConfirm={() => {+ setConfirming(null);+ void model.clearDownloads();+ }}+ />+ )}+ </div>+ );+}diff --git a/src/windows/ui/views/agents.tsx b/src/windows/ui/views/agents.tsxnew file mode 100644index 0000000..a7f81b2--- /dev/null+++ b/src/windows/ui/views/agents.tsx@@ -0,0 +1,141 @@+import { Check, Circle, CircleArrowDown, CircleDot, WandSparkles } from 'lucide-react';++import { AgentMark } from '@/extension/components/agent-marks';+import { ModelFilter } from '@/extension/components/model-filter';+import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from '@/extension/components/ui/select';+import { AGENTS, type AgentDescriptor, type RunnerStatus } from '@/lib/agents/catalog';+import { describeList, offered } from '@/lib/agents/model-list';+import { cn } from '@/lib/utils';+import { Card, OfflineHint, Pill, PrimaryButton, QuietButton, SectionTitle, Spinner } from '../components';+import type { Model, State } from '../model';++const CLI_DEFAULT = '__default__';+const LONG_LIST = 20;++export function AgentsView({ model, state }: { model: Model; state: State }) {+ if (state.daemon !== 'on') return <OfflineHint what="Agent readiness checks" model={model} daemonOff={state.daemon === 'off'} />;+ if (!state.agents) {+ return (+ <div className="flex justify-center p-15">+ <Spinner />+ </div>+ );+ }+ const { agents } = state;+ return (+ <div className="space-y-4.5">+ <Card>+ <SectionTitle+ title="Which agent runs the side panel"+ subtitle="Browsentic ships no model and needs no API key. It drives the agent CLI you are already signed in to."+ />+ </Card>+ {agents.runners.map((runner) => (+ <AgentCard+ key={runner.kind}+ runner={runner}+ descriptor={agents.catalog?.find((entry) => entry.kind === runner.kind) ?? AGENTS[runner.kind]}+ active={agents.active === runner.kind}+ working={state.busy.includes(`agent:${runner.kind}`)}+ model={model}+ />+ ))}+ </div>+ );+}++function AgentCard({ runner, descriptor, active, working, model }: { runner: RunnerStatus; descriptor: AgentDescriptor; active: boolean; working: boolean; model: Model }) {+ const problem = runner.problem;+ const npm = descriptor.install.startsWith('npm ');+ return (+ <Card className={cn(active && 'border-brand/50')}>+ <div className="space-y-3">+ <div className="flex items-center gap-3">+ {active ? <CircleDot className="size-4.5 shrink-0 text-brand" /> : <Circle className="size-4.5 shrink-0 text-ink-faint" />}+ <AgentMark kind={runner.kind} className="size-5 shrink-0" />+ <div className="min-w-0 flex-1 space-y-0.5">+ <div className="flex items-baseline gap-2">+ <span className="font-display text-base font-semibold text-ink">{descriptor.label}</span>+ <span className="text-[11.5px] text-ink-faint">{descriptor.vendor}</span>+ {descriptor.beta && <Pill text="beta" tint="faint" />}+ </div>+ <p className={cn('font-mono text-[11.5px]', runner.ready ? 'text-ink-dim' : 'text-amber')}>+ {runner.ready ? (runner.version ?? 'Ready') : 'Unavailable'}+ </p>+ </div>+ {working && <Spinner />}+ {active ? (+ <Pill text="In use" tint="brand" icon={Check} />+ ) : (+ runner.ready && (+ <QuietButton disabled={working} onClick={() => void model.selectAgent(runner.kind)}>+ Use this agent+ </QuietButton>+ )+ )}+ </div>++ {problem ? (+ <div className="space-y-2 pl-[62px]">+ <p className="text-[12.5px] text-ink-dim">{problem.message}</p>+ {problem.fix && <p className="rounded-lg bg-ground-2 px-2.5 py-1.5 font-mono text-[11.5px] break-all text-ink select-text">{problem.fix}</p>}+ <div className="flex gap-2">+ {problem.code === 'AGENT_MISSING' && (+ <PrimaryButton icon={CircleArrowDown} disabled={working} onClick={() => void model.installAgent(descriptor)}>+ {npm ? `Install ${descriptor.label}` : 'Open the install guide'}+ </PrimaryButton>+ )}+ {problem.grantable && (+ <PrimaryButton icon={WandSparkles} disabled={working} onClick={() => void model.repairAgent(runner.kind)}>+ Fix it for me+ </PrimaryButton>+ )}+ <QuietButton onClick={() => void model.openUrl(descriptor.docs)}>Docs</QuietButton>+ </div>+ </div>+ ) : (+ <ModelRow runner={runner} active={active} working={working} model={model} />+ )}+ </div>+ </Card>+ );+}++function ModelRow({ runner, active, working, model }: { runner: RunnerStatus; active: boolean; working: boolean; model: Model }) {+ const list = offered(runner);+ const pinned = runner.model && !list.ids.includes(runner.model) ? runner.model : null;+ const choose = (next: string | null) => void model.setModel(next, runner.kind);+ return (+ <div className="flex flex-wrap items-center gap-x-2.5 gap-y-1 pl-[62px]">+ <span className="text-xs text-ink-dim">Model</span>+ <div className="w-[260px]">+ {list.ids.length > LONG_LIST ? (+ <ModelFilter+ value={runner.model ?? null}+ ids={list.ids}+ suggested={AGENTS[runner.kind].models.filter((id) => list.ids.includes(id))}+ pinned={pinned}+ disabled={working}+ onModel={choose}+ />+ ) : (+ <Select value={runner.model ?? CLI_DEFAULT} onValueChange={(value) => choose(value === CLI_DEFAULT ? null : value)} disabled={working}>+ <SelectTrigger className="h-8 font-mono text-xs">+ <SelectValue />+ </SelectTrigger>+ <SelectContent className="font-mono text-xs">+ <SelectItem value={CLI_DEFAULT}>The CLI’s own default</SelectItem>+ {pinned && <SelectItem value={pinned}>{pinned} · not listed</SelectItem>}+ {list.ids.map((id) => (+ <SelectItem key={id} value={id}>+ {id}+ </SelectItem>+ ))}+ </SelectContent>+ </Select>+ )}+ </div>+ {active && <span className="basis-full font-mono text-[10px] text-ink-faint">{describeList(runner.kind, list)}</span>}+ </div>+ );+}diff --git a/src/windows/ui/views/browsers.tsx b/src/windows/ui/views/browsers.tsxnew file mode 100644index 0000000..4c7f686--- /dev/null+++ b/src/windows/ui/views/browsers.tsx@@ -0,0 +1,74 @@+import { useState } from 'react';+import { Globe } from 'lucide-react';++import { formatWhen } from '@/lib/format-when';+import { Card, ConfirmDialog, EmptyState, GlowDot, OfflineHint, Pill, QuietButton, SectionTitle } from '../components';+import type { Model, State } from '../model';+import type { SessionSummary } from '../backend';+import { ConnectCard } from './overview';++const extensionId = (origin: string) => origin.replace(/^[a-z-]+-extension:\/\//, '').replace(/\/$/, '');+const ago = (iso: string) => formatWhen(Date.parse(iso));++export function BrowsersView({ model, state }: { model: Model; state: State }) {+ const [confirming, setConfirming] = useState(false);+ if (state.daemon !== 'on') return <OfflineHint what="Paired browsers" model={model} daemonOff={state.daemon === 'off'} />;++ return (+ <div className="space-y-4.5">+ <ConnectCard model={model} state={state} />+ <Card>+ <div className="space-y-3.5">+ <div className="flex items-start gap-3">+ <div className="min-w-0 flex-1">+ <SectionTitle title="Paired browsers" subtitle="Each one holds a key of its own. Unpairing drops the key and disconnects it at once." />+ </div>+ {state.sessions.length > 1 && (+ <QuietButton tint="danger" onClick={() => setConfirming(true)}>+ Unpair all+ </QuietButton>+ )}+ </div>+ {state.sessions.length === 0 ? (+ <EmptyState icon={Globe} title="No browser is paired" detail="Get a pairing code above and paste it into the Browsentic popup." />+ ) : (+ state.sessions.map((session) => <SessionRow key={session.id} session={session} model={model} busy={state.busy.includes('revoke')} />)+ )}+ </div>+ </Card>+ {confirming && (+ <ConfirmDialog+ title="Unpair every browser?"+ message="Each one will need a new pairing code to connect again."+ action="Unpair all"+ onCancel={() => setConfirming(false)}+ onConfirm={() => {+ setConfirming(false);+ void model.revoke();+ }}+ />+ )}+ </div>+ );+}++function SessionRow({ session, model, busy }: { session: SessionSummary; model: Model; busy: boolean }) {+ return (+ <div className="flex items-center gap-3 rounded-xl bg-ground-2 p-3">+ <GlowDot tint={session.connected ? 'lime' : 'faint'} pulsing={session.connected} />+ <div className="min-w-0 flex-1 space-y-0.75">+ {session.browser && <p className="text-[13px] font-medium text-ink">{session.browser}</p>}+ <p className={session.browser ? 'truncate font-mono text-xs text-ink-dim select-text' : 'truncate font-mono text-xs text-ink select-text'}>+ {extensionId(session.origin)}+ </p>+ <p className="text-[11.5px] text-ink-dim">+ Extension v{session.extensionVersion} · paired {ago(session.pairedAt)} · seen {ago(session.lastSeenAt)}+ </p>+ </div>+ <Pill text={session.connected ? 'Connected' : 'Away'} tint={session.connected ? 'lime' : 'dim'} />+ <QuietButton tint="danger" disabled={busy} onClick={() => void model.revoke(session)}>+ Unpair+ </QuietButton>+ </div>+ );+}diff --git a/src/windows/ui/views/logs.tsx b/src/windows/ui/views/logs.tsxnew file mode 100644index 0000000..48ac3f7--- /dev/null+++ b/src/windows/ui/views/logs.tsx@@ -0,0 +1,70 @@+import { useEffect, useRef, useState } from 'react';+import { Folder } from 'lucide-react';++import { Switch } from '@/extension/components/ui/switch';+import { Card, CopyButton, QuietButton, SectionTitle } from '../components';+import { short, type Model, type State } from '../model';++const tone = (message: string) => {+ const lowered = message.toLowerCase();+ if (['rejected', 'error', 'failed'].some((word) => lowered.includes(word))) return 'text-destructive';+ if (['drifted', 'revoked'].some((word) => lowered.includes(word))) return 'text-amber';+ if (['connected', 'paired', 'listening'].some((word) => lowered.includes(word))) return 'text-lime';+ return 'text-ink-dim';+};++/** A log line opens with an ISO stamp; the clock time is all the view needs of it. */+export function splitLine(text: string): { time: string; message: string } {+ const space = text.indexOf(' ');+ const stamp = space < 0 ? '' : text.slice(0, space);+ const message = space < 0 ? text : text.slice(space + 1);+ return { time: stamp.length >= 19 && stamp.includes('T') ? stamp.slice(11, 19) : stamp, message };+}++export function LogsView({ model, state }: { model: Model; state: State }) {+ const [following, setFollowing] = useState(true);+ const end = useRef<HTMLDivElement>(null);++ useEffect(() => {+ void model.loadLog();+ const tick = setInterval(() => void model.loadLog(), 1500);+ return () => clearInterval(tick);+ }, [model]);++ useEffect(() => {+ if (following) end.current?.scrollIntoView({ block: 'end' });+ }, [state.logText, following]);++ const log = state.info?.paths.log ?? '';+ const lines = state.logText.split(/\r?\n/).filter(Boolean);++ return (+ <Card padded={false}>+ <div className="flex items-center gap-2 p-4">+ <div className="min-w-0 flex-1">+ <SectionTitle title="Daemon log" subtitle={short(log, state.info)} />+ </div>+ <label className="flex items-center gap-2 text-xs text-ink-dim">+ Follow+ <Switch checked={following} label="Follow the log" onChange={setFollowing} />+ </label>+ <CopyButton value={state.logText} label="Copy all" />+ <QuietButton icon={Folder} onClick={() => void model.reveal(log)}>+ Show+ </QuietButton>+ </div>+ <div className="h-[470px] overflow-y-auto border-t border-line bg-ground-2/60 p-3.5 font-mono text-[11px] select-text">+ {lines.map((line, index) => {+ const { time, message } = splitLine(line);+ return (+ <div key={index} className="flex gap-2.5 leading-[1.45]">+ <span className="shrink-0 text-ink-faint">{time}</span>+ <span className={tone(message)}>{message}</span>+ </div>+ );+ })}+ <div ref={end} />+ </div>+ </Card>+ );+}diff --git a/src/windows/ui/views/main.tsx b/src/windows/ui/views/main.tsxnew file mode 100644index 0000000..ae7e3f1--- /dev/null+++ b/src/windows/ui/views/main.tsx@@ -0,0 +1,64 @@+import { AlignLeft, BookOpen, Globe, Power, Settings, ShieldCheck, Sparkles, type LucideIcon } from 'lucide-react';++import { cn } from '@/lib/utils';+import { TABS, type Model, type State, type Tab } from '../model';+import { ActivityView } from './activity';+import { AgentsView } from './agents';+import { BrowsersView } from './browsers';+import { LogsView } from './logs';+import { OverviewView } from './overview';+import { SettingsView } from './settings';+import { SkillsView } from './skills';++const TAB: Record<Tab, { label: string; icon: LucideIcon; view: typeof OverviewView }> = {+ overview: { label: 'Overview', icon: Power, view: OverviewView },+ browsers: { label: 'Browsers', icon: Globe, view: BrowsersView },+ agents: { label: 'Agents', icon: Sparkles, view: AgentsView },+ skills: { label: 'Skills', icon: BookOpen, view: SkillsView },+ activity: { label: 'Activity', icon: ShieldCheck, view: ActivityView },+ logs: { label: 'Logs', icon: AlignLeft, view: LogsView },+ settings: { label: 'Settings', icon: Settings, view: SettingsView },+};++export function MainView({ model, state }: { model: Model; state: State }) {+ const View = TAB[state.tab].view;+ return (+ <div className="relative h-full">+ <div className="h-full overflow-y-auto [scrollbar-width:none]">+ <div key={state.tab} className="enter mx-auto max-w-[880px] px-7 pt-16 pb-9">+ <View model={model} state={state} />+ </div>+ </div>+ <TabCapsule model={model} state={state} />+ </div>+ );+}++/** The view switcher floats at the top centre, Ctrl+1…Ctrl+7. */+function TabCapsule({ model, state }: { model: Model; state: State }) {+ return (+ <nav className="absolute top-1.5 left-1/2 flex -translate-x-1/2 gap-0.5 rounded-full border border-line bg-surface/80 p-1 shadow-[0_6px_18px_rgb(0_0_0/0.25)] backdrop-blur-md">+ {TABS.map((tab, index) => {+ const { label, icon: Icon } = TAB[tab];+ const selected = state.tab === tab;+ return (+ <button+ key={tab}+ type="button"+ title={`${label} (Ctrl+${index + 1})`}+ aria-current={selected ? 'page' : undefined}+ onClick={() => model.setTab(tab)}+ className={cn(+ 'flex items-center gap-1.5 rounded-full px-3 py-1.75 text-xs font-medium transition-colors',+ selected ? 'bg-brand text-ground' : 'text-ink-dim hover:text-ink',+ )}+ >+ <Icon className="size-3" strokeWidth={2.5} />+ {label}+ {tab === 'overview' && state.update && <span className={cn('size-1.5 rounded-full', selected ? 'bg-ground' : 'bg-brand')} />}+ </button>+ );+ })}+ </nav>+ );+}diff --git a/src/windows/ui/views/overview.tsx b/src/windows/ui/views/overview.tsxnew file mode 100644index 0000000..2625a70--- /dev/null+++ b/src/windows/ui/views/overview.tsx@@ -0,0 +1,239 @@+import { useEffect, useState } from 'react';+import { Cpu, FileDown, KeyRound, Network, Power, Puzzle, RefreshCw, SquareArrowOutUpRight, Wrench, type LucideIcon } from 'lucide-react';++import { cn } from '@/lib/utils';+import { Card, CopyButton, GlowDot, PathRow, Pill, PrimaryButton, QuietButton, SectionTitle, Step, type Tint } from '../components';+import type { DaemonPhase, Model, State } from '../model';+import type { PairingCode } from '../backend';+import { UpdateCard } from './update-card';++const TINT: Record<DaemonPhase, Tint> = { on: 'lime', off: 'faint', starting: 'amber', stopping: 'amber' };+const LABEL: Record<DaemonPhase, string> = { off: 'Off', starting: 'Starting', on: 'Running', stopping: 'Stopping' };++export function OverviewView({ model, state }: { model: Model; state: State }) {+ const { daemon, status, lock } = state;+ const connected = status?.connected === true;+ const title = {+ on: connected ? 'Your browser is in the loop' : 'Waiting for your browser',+ off: 'Browsentic is off',+ starting: 'Bringing the daemon up',+ stopping: 'Shutting down',+ }[daemon];+ const subtitle = {+ on: connected+ ? 'Open the side panel in your browser and say what you want. This window can close: the daemon keeps running.'+ : 'The daemon is listening. Load the extension and pair it, and the side panel comes alive.',+ off: 'Turn it on and the side panel in your browser can reach the agent you already run.',+ starting: 'One moment.',+ stopping: 'One moment.',+ }[daemon];++ return (+ <div className="space-y-4.5">+ {state.update && <UpdateCard model={model} state={state} />}++ <Card className="p-6.5">+ <div className="flex items-center gap-7">+ <PowerOrb phase={daemon} onToggle={() => void model.setDaemon(daemon === 'off')} />+ <div className="min-w-0 flex-1 space-y-2">+ <div className="flex items-center gap-2">+ <GlowDot tint={TINT[daemon]} pulsing={daemon === 'on'} />+ <span className={cn('text-[11px] font-bold tracking-[0.11em] uppercase', TEXT_TINT[TINT[daemon]])}>{LABEL[daemon]}</span>+ </div>+ <h1 className="font-display text-2xl font-bold text-ink">{title}</h1>+ <p className="text-[13px] text-ink-dim">{subtitle}</p>+ {daemon === 'on' && (+ <QuietButton icon={RefreshCw} className="mt-1" disabled={state.busy.includes('restart')} onClick={() => void model.restartDaemon()}>+ Restart+ </QuietButton>+ )}+ </div>+ </div>+ </Card>++ {status && lock && (+ <div className="grid grid-cols-4 gap-3">+ <Stat label="Address" value={`127.0.0.1:${status.port}`} icon={Network} />+ <Stat label="Daemon" value={`v${status.daemonVersion}`} detail={`pid ${lock.pid}`} icon={Cpu} />+ <Stat+ label="Extension"+ value={connected ? 'Connected' : 'Not connected'}+ detail={status.extensionVersion && `v${status.extensionVersion}`}+ icon={Puzzle}+ tint={connected ? 'lime' : 'amber'}+ />+ <Stat+ label="Tools"+ value={status.manifestInSync ? 'In sync' : 'Drifted'}+ detail={status.manifestInSync ? undefined : 'reload the extension'}+ icon={Wrench}+ tint={status.manifestInSync ? 'lime' : 'amber'}+ />+ </div>+ )}++ {daemon === 'on' && (status?.pairedBrowsers === 0 || state.pairing) && <ConnectCard model={model} state={state} />}+ <ExtensionCard model={model} state={state} />+ {!state.update && <UpdateCard model={model} state={state} />}+ </div>+ );+}++const TEXT_TINT: Record<Tint, string> = {+ brand: 'text-brand',+ lime: 'text-lime',+ amber: 'text-amber',+ danger: 'text-destructive',+ ember: 'text-ember',+ magenta: 'text-magenta',+ dim: 'text-ink-dim',+ faint: 'text-ink-faint',+};++function PowerOrb({ phase, onToggle }: { phase: DaemonPhase; onToggle: () => void }) {+ const on = phase === 'on';+ const moving = phase === 'starting' || phase === 'stopping';+ return (+ <button+ type="button"+ onClick={onToggle}+ disabled={moving}+ title={on ? 'Turn the daemon off' : 'Turn the daemon on'}+ aria-label={on ? 'Turn the daemon off' : 'Turn the daemon on'}+ className="relative size-[148px] shrink-0 rounded-full transition-transform duration-300 hover:scale-103"+ >+ {on && <span className="breathe absolute inset-0 rounded-full bg-[radial-gradient(closest-side,color-mix(in_oklch,var(--brand)_calc(var(--glow)*0.55),transparent)_45%,transparent)]" />}+ <span+ className={cn('ring inset-3.5', (on || moving) && 'spin')}+ style={{+ background: moving+ ? 'conic-gradient(var(--brand) 0 35%, transparent 35%)'+ : on+ ? 'conic-gradient(var(--brand), var(--ember), var(--magenta), var(--brand))'+ : 'var(--line-strong)',+ }}+ />+ <span className="absolute inset-6.5 rounded-full border border-line-strong bg-gradient-to-b from-surface-2 to-ground-2 shadow-[0_6px_10px_rgb(0_0_0/0.35)]" />+ <Power+ className={cn('absolute top-1/2 left-1/2 size-8 -translate-x-1/2 -translate-y-1/2', on ? 'neon-text text-brand' : 'text-ink-faint')}+ strokeWidth={3}+ />+ </button>+ );+}++function Stat({ label, value, detail, icon: Icon, tint = 'brand' }: { label: string; value: string; detail?: string; icon: LucideIcon; tint?: Tint }) {+ return (+ <div className="space-y-1.5 rounded-[14px] border border-line bg-surface/72 p-3.5">+ <div className="flex items-center gap-1.5">+ <Icon className={cn('size-2.5', TEXT_TINT[tint])} strokeWidth={3} />+ <span className="text-[10px] font-semibold tracking-[0.08em] text-ink-faint uppercase">{label}</span>+ </div>+ <p className="truncate font-display text-[15px] font-semibold text-ink">{value}</p>+ <p className="font-mono text-[10.5px] text-ink-dim">{detail ?? ' '}</p>+ </div>+ );+}++export function ConnectCard({ model, state }: { model: Model; state: State }) {+ return (+ <Card>+ <div className="space-y-4">+ <SectionTitle+ title="Pair a browser"+ subtitle="Open the Browsentic popup in your browser, paste the code, and press Connect. It works once and expires in ten minutes."+ />+ {state.pairing ? (+ <PairingCodeView pairing={state.pairing} model={model} />+ ) : (+ <PrimaryButton icon={KeyRound} disabled={state.busy.includes('pair')} onClick={() => void model.newPairingCode()}>+ Get a pairing code+ </PrimaryButton>+ )}+ </div>+ </Card>+ );+}++function PairingCodeView({ pairing, model }: { pairing: PairingCode; model: Model }) {+ const [now, setNow] = useState(Date.now());+ useEffect(() => {+ const tick = setInterval(() => setNow(Date.now()), 1000);+ return () => clearInterval(tick);+ }, []);+ const left = Math.max(0, Math.floor((pairing.expiresAt - now) / 1000));+ const grouped = pairing.code.length > 4 ? `${pairing.code.slice(0, 4)}-${pairing.code.slice(4)}` : pairing.code;++ return (+ <div className="flex items-center gap-4.5">+ <div className="flex gap-1.5">+ {[...grouped].map((character, index) =>+ character === '-' ? (+ <span key={index} className="self-center font-mono text-[22px] text-ink-faint">+ –+ </span>+ ) : (+ <span+ key={index}+ className="flex h-11 w-8.5 items-center justify-center rounded-[9px] border border-brand/30 bg-ground-2 font-mono text-2xl font-bold text-brand select-text"+ >+ {character}+ </span>+ ),+ )}+ </div>+ <div className="space-y-1.5">+ <p className={cn('font-mono text-xs', left < 60 ? 'text-amber' : 'text-ink-dim')}>+ {left > 0 ? `Expires in ${Math.floor(left / 60)}:${String(left % 60).padStart(2, '0')}` : 'Expired'}+ </p>+ <div className="flex gap-2">+ <CopyButton value={grouped} label="Copy code" />+ <QuietButton onClick={() => void model.newPairingCode()}>New code</QuietButton>+ </div>+ </div>+ </div>+ );+}++function ExtensionCard({ model, state }: { model: Model; state: State }) {+ const connected = state.status?.connected === true;+ const reload = model.extensionNeedsReload;+ const subtitle = reload+ ? 'A newer build is unpacked than the one your browser has loaded. Press ↻ on the Browsentic card at chrome://extensions.'+ : connected+ ? 'Loaded and talking to the daemon. The folder below has to stay where it is: the browser’s pairing is tied to the path.'+ : 'Browsers only load an unpacked extension by hand, so these three steps are yours.';++ return (+ <Card>+ <div className="space-y-3.5">+ <div className="flex items-start gap-3">+ <div className="min-w-0 flex-1">+ <SectionTitle title="The extension" subtitle={subtitle} />+ </div>+ {state.stamp && <Pill text={`v${state.stamp.version} unpacked`} tint="brand" />}+ {reload && <Pill text="Reload needed" tint="amber" icon={RefreshCw} />}+ </div>+ {state.info && <PathRow path={state.info.paths.extensionDir} model={model} info={state.info} />}+ {!connected && (+ <div className="space-y-2">+ <Step number={1}>Open chrome://extensions and turn on Developer mode.</Step>+ <Step number={2}>Press “Load unpacked”, then paste the folder above into the picker’s address bar.</Step>+ <Step number={3}>Open the Browsentic popup and paste a pairing code.</Step>+ </div>+ )}+ <div className="flex flex-wrap items-center gap-2">+ {state.browsers.slice(0, 3).map((browser) => (+ <QuietButton key={browser.path} icon={SquareArrowOutUpRight} onClick={() => void model.openExtensionsPage(browser)}>+ Extensions in {browser.name}+ </QuietButton>+ ))}+ <div className="flex-1" />+ <QuietButton icon={FileDown} disabled={state.busy.includes('extension')} onClick={() => void model.reinstallExtension()}>+ Write it again+ </QuietButton>+ </div>+ </div>+ </Card>+ );+}diff --git a/src/windows/ui/views/preflight.tsx b/src/windows/ui/views/preflight.tsxnew file mode 100644index 0000000..5a1ec97--- /dev/null+++ b/src/windows/ui/views/preflight.tsx@@ -0,0 +1,171 @@+import {+ ArrowRight,+ CircleAlert,+ CircleArrowDown,+ CircleCheck,+ Globe,+ Hexagon,+ Monitor,+ OctagonX,+ Puzzle,+ RefreshCw,+ Sparkles,+ SquareTerminal,+ WandSparkles,+ type LucideIcon,+} from 'lucide-react';++import { Logo } from '@/extension/components/brand';+import { cn } from '@/lib/utils';+import { PrimaryButton, QuietButton, Spinner } from '../components';+import { CHECKS, INSTALLS_AUTOMATICALLY, needsAttention, type CheckId, type CheckState, type Model, type State } from '../model';++const CHECK: Record<CheckId, { title: string; icon: LucideIcon }> = {+ system: { title: 'This computer', icon: Monitor },+ node: { title: 'Node.js runtime', icon: Hexagon },+ command: { title: 'Browsentic command', icon: SquareTerminal },+ extensionFiles: { title: 'Browser extension', icon: Puzzle },+ browser: { title: 'A Chromium browser', icon: Globe },+ agent: { title: 'An AI agent', icon: Sparkles },+};++export function PreflightView({ model, state }: { model: Model; state: State }) {+ const headline = state.fixing+ ? 'Installing what is missing'+ : state.preflightBusy+ ? 'Checking what this computer already has'+ : model.needsSetup+ ? 'A few things are missing. One click installs them'+ : 'Everything is in place';++ return (+ <div className="enter flex h-full flex-col items-center overflow-y-auto px-6">+ <div className="min-h-4 flex-1" />+ <Beacon active={state.preflightBusy || state.fixing} settled={model.canEnter && !state.preflightBusy} />+ <h1 className="mt-3 font-display text-[30px] font-bold text-ink">Browsentic</h1>+ <p className="mt-1 text-[13px] text-ink-dim">{headline}</p>++ <div className="mt-5 w-[600px] max-w-full space-y-1.5">+ {CHECKS.map((id) => (+ <CheckRow key={id} id={id} state={state.checks[id]} model={model} busy={state.fixing || state.preflightBusy} hasNode={!!state.node} />+ ))}+ </div>++ <div className="mt-4 flex h-10 shrink-0 items-center gap-2.5">+ {!state.preflightBusy &&+ (model.needsSetup ? (+ <PrimaryButton icon={WandSparkles} disabled={state.fixing} onClick={() => void model.setUpEverything()}>+ {state.fixing ? 'Setting up…' : 'Set up everything'}+ </PrimaryButton>+ ) : (+ <PrimaryButton icon={ArrowRight} onClick={() => model.enter()}>+ Open Browsentic+ </PrimaryButton>+ ))}+ {!state.preflightBusy && (+ <QuietButton icon={RefreshCw} disabled={state.fixing} onClick={() => void model.runPreflight()}>+ Check again+ </QuietButton>+ )}+ </div>++ <div className="min-h-4 flex-1" />+ <p className="pb-4 text-[11px] text-ink-faint">+ Everything Browsentic installs stays in %USERPROFILE%\.browsentic and %USERPROFILE%\browsentic. No administrator, no account.+ </p>+ </div>+ );+}++/** The loading mark: the brand glyph inside two counter-rotating arcs and a breathing halo. */+function Beacon({ active, settled }: { active: boolean; settled: boolean }) {+ return (+ <div className="relative size-[148px] shrink-0">+ <div className="breathe absolute inset-0 rounded-full bg-[radial-gradient(closest-side,color-mix(in_oklch,var(--brand)_35%,transparent),transparent)]" />+ <div+ className="ring spin inset-1.5"+ style={{+ ['--spin' as string]: '2.6s',+ ['--ring-width' as string]: '2.5px',+ background: active+ ? 'conic-gradient(from 0deg, transparent 0 38%, var(--brand) 70%, var(--ember) 100%)'+ : 'conic-gradient(var(--brand), var(--ember), var(--brand))',+ }}+ />+ {active && (+ <div+ className="ring spin-reverse inset-4"+ style={{ ['--spin' as string]: '2.6s', ['--ring-width' as string]: '1.5px', background: 'conic-gradient(color-mix(in oklch, var(--magenta) 80%, transparent) 0 30%, transparent 30%)' }}+ />+ )}+ <div+ className={cn(+ 'absolute top-1/2 left-1/2 flex size-[92px] -translate-x-1/2 -translate-y-1/2 items-center justify-center rounded-[22px] border border-line-strong bg-gradient-to-b from-surface to-ground transition-transform duration-700',+ settled ? 'scale-104 shadow-[0_0_26px_color-mix(in_oklch,var(--lime)_calc(var(--glow)*0.7),transparent)]' : 'shadow-[0_0_26px_color-mix(in_oklch,var(--brand)_calc(var(--glow)*0.7),transparent)]',+ )}+ >+ <Logo className="size-[68px] text-brand" />+ </div>+ </div>+ );+}++function CheckRow({ id, state, model, busy, hasNode }: { id: CheckId; state: CheckState; model: Model; busy: boolean; hasNode: boolean }) {+ const { title, icon: Icon } = CHECK[id];+ const detail =+ state.kind === 'waiting' ? 'Waiting' : state.kind === 'checking' ? 'Checking…' : state.text;+ const action = busy+ ? null+ : id === 'browser' && state.kind === 'advisory'+ ? { label: 'Get Chrome', fix: () => model.fix('browser') }+ : id === 'agent' && state.kind === 'advisory' && hasNode+ ? { label: 'Install Claude Code', fix: () => model.fix('agent') }+ : needsAttention(state) && INSTALLS_AUTOMATICALLY.includes(id)+ ? { label: 'Install', fix: () => model.fix(id) }+ : null;++ return (+ <div+ className={cn(+ 'flex shrink-0 items-center gap-3 rounded-[14px] border bg-surface/72 px-3.5 py-2 transition-opacity',+ needsAttention(state) ? 'border-amber/45' : 'border-line',+ state.kind === 'waiting' && 'opacity-45',+ )}+ >+ <span className="flex size-7.5 shrink-0 items-center justify-center rounded-[9px] bg-ground-2">+ <Icon className={cn('size-3.5', state.kind === 'waiting' ? 'text-ink-faint' : 'text-brand')} />+ </span>+ <div className="min-w-0 flex-1">+ <p className="text-[13px] font-semibold text-ink">{title}</p>+ <p className={cn('line-clamp-2 text-[11.5px]', state.kind === 'failed' ? 'text-destructive' : 'text-ink-dim')}>{detail}</p>+ {state.kind === 'working' && state.fraction !== undefined && (+ <div className="mt-1.5 h-1 overflow-hidden rounded-full bg-ground-2">+ <div className="h-full rounded-full bg-brand transition-[width]" style={{ width: `${Math.round(state.fraction * 100)}%` }} />+ </div>+ )}+ </div>+ {action && <QuietButton onClick={() => void action.fix()}>{action.label}</QuietButton>}+ <span className="flex w-5.5 justify-center">+ <Indicator state={state} />+ </span>+ </div>+ );+}++function Indicator({ state }: { state: CheckState }) {+ switch (state.kind) {+ case 'waiting':+ return <span className="size-4 rounded-full border-[1.5px] border-line-strong" />;+ case 'checking':+ case 'working':+ return <Spinner />;+ case 'passed':+ return <CircleCheck className="size-4.5 text-lime" />;+ case 'missing':+ return <CircleArrowDown className="size-4.5 text-amber" />;+ case 'advisory':+ return <CircleAlert className="size-4.5 text-amber" />;+ case 'failed':+ return <OctagonX className="size-4.5 text-destructive" />;+ }+}diff --git a/src/windows/ui/views/settings.tsx b/src/windows/ui/views/settings.tsxnew file mode 100644index 0000000..68bd391--- /dev/null+++ b/src/windows/ui/views/settings.tsx@@ -0,0 +1,198 @@+import { useState } from 'react';+import { RefreshCw, TriangleAlert } from 'lucide-react';++import { GuardrailPolicy } from '@/extension/components/guardrail-policy';+import { ThemePicker } from '@/extension/components/theme-picker';+import { Switch } from '@/extension/components/ui/switch';+import { DEFAULT_THEME } from '@/lib/settings/theme';+import { Card, ConfirmDialog, CopyButton, OfflineHint, PathRow, PrimaryButton, QuietButton, SectionTitle, Segmented, Spinner } from '../components';+import { short, type Appearance, type Model, type State } from '../model';+import { UpdateCard } from './update-card';++export function SettingsView({ model, state }: { model: Model; state: State }) {+ const [confirming, setConfirming] = useState(false);+ const [keepSkills, setKeepSkills] = useState(true);+ const info = state.info;+ const mcpCommand = `claude mcp add browsentic -- ${info?.paths.mcpShim ?? 'browsentic-mcp'}`;+ const link = state.commandLink;++ return (+ <div className="space-y-4.5">+ <UpdateCard model={model} state={state} />++ <Card>+ <div className="space-y-3.5">+ <SectionTitle title="Appearance" />+ <Segmented<Appearance>+ options={[+ { value: 'system', label: 'System' },+ { value: 'light', label: 'Light' },+ { value: 'dark', label: 'Dark' },+ ]}+ value={state.appearance}+ onSelect={(appearance) => model.setAppearance(appearance)}+ />+ <div className="border-t border-line" />+ <SwitchRow+ title="Turn the daemon on when the app opens"+ subtitle="It keeps running after the window closes, so the side panel and MCP clients still work."+ checked={state.startDaemonOnLaunch}+ onChange={(on) => model.setStartDaemonOnLaunch(on)}+ />+ </div>+ </Card>++ <BrowserSettings model={model} state={state} />++ <Card>+ <div className="space-y-3">+ <SwitchRow+ title="“browsentic” in your terminal"+ subtitle={+ link?.linkedIn+ ? `On your PATH, in ${short(link.linkedIn, info)}. Everything this window does, the command does too. Terminals opened from now on have it.`+ : 'Adds its folder to your user PATH. No administrator, and only terminals opened afterwards see it.'+ }+ checked={!!link?.linkedIn}+ onChange={(on) => void model.setCommandLink(on)}+ />+ {link?.foreign && (+ <p className="flex gap-1.5 text-[11.5px] text-amber">+ <TriangleAlert className="mt-px size-3.5 shrink-0" />+ Another browsentic is already on your PATH at {link.foreign}. Remove it with “npm rm -g browsentic” so the two cannot disagree.+ </p>+ )}+ {info && <PathRow path={info.paths.shim} model={model} info={info} />}+ </div>+ </Card>++ <Card>+ <div className="space-y-3">+ <SectionTitle+ title="Optional: use it from an MCP client"+ subtitle="The same browser tools, handed to Claude Code or any other MCP client. The side panel does not need this."+ />+ <div className="flex items-center gap-2 rounded-[10px] border border-line bg-ground-2 py-1.5 pr-1.5 pl-3">+ <span className="min-w-0 flex-1 truncate font-mono text-[11.5px] text-ink select-text">{mcpCommand}</span>+ <CopyButton value={mcpCommand} />+ </div>+ {state.lock && (+ <div className="flex items-center gap-2">+ <span className="text-xs text-ink-dim">Control token</span>+ <span className="font-mono text-[11px] text-ink-faint">{'•'.repeat(24)}</span>+ <div className="flex-1" />+ <CopyButton value={state.lock.token} label="Copy token" />+ </div>+ )}+ </div>+ </Card>++ <Card>+ <div className="space-y-3">+ <SectionTitle title="About" subtitle={`Browsentic ${info?.version ?? ''} · free and open source, MIT.`} />+ <div className="flex flex-wrap items-center gap-2">+ <QuietButton onClick={() => void model.openUrl('https://browsentic.com')}>browsentic.com</QuietButton>+ <QuietButton onClick={() => void model.openUrl('https://github.com/imshaikot/browsentic')}>Source</QuietButton>+ <QuietButton onClick={() => model.showPreflight()}>Run the checks again</QuietButton>+ <div className="flex-1" />+ <QuietButton tint="danger" onClick={() => setConfirming(true)}>+ Uninstall…+ </QuietButton>+ </div>+ </div>+ </Card>++ {confirming && (+ <ConfirmDialog+ title="Uninstall Browsentic?"+ message={+ 'This stops the daemon, unpairs every browser, and removes %USERPROFILE%\\.browsentic and %USERPROFILE%\\browsentic: the command, the unpacked extension, keys, approvals and logs.\n\nRemove the Browsentic card at chrome://extensions first. Afterwards, uninstall the app itself in Settings › Apps › Installed apps.'+ }+ action="Uninstall"+ onCancel={() => setConfirming(false)}+ onConfirm={() => {+ setConfirming(false);+ void model.uninstall(keepSkills);+ }}+ >+ <label className="flex items-center gap-2 text-[12.5px] text-ink">+ <input type="checkbox" checked={keepSkills} onChange={(event) => setKeepSkills(event.target.checked)} className="accent-[var(--brand)]" />+ Keep my skills and site maps+ </label>+ </ConfirmDialog>+ )}+ </div>+ );+}++function SwitchRow({ title, subtitle, checked, onChange }: { title: string; subtitle: string; checked: boolean; onChange: (on: boolean) => void }) {+ return (+ <div className="flex items-center gap-4">+ <div className="min-w-0 flex-1">+ <SectionTitle title={title} subtitle={subtitle} />+ </div>+ <Switch checked={checked} label={title} onChange={onChange} />+ </div>+ );+}++/** The settings every paired browser shares, kept by the daemon in config.json. The extension's own settings page edits the same values. */+function BrowserSettings({ model, state }: { model: Model; state: State }) {+ if (state.daemon !== 'on') return <OfflineHint what="The browser theme and the guardrails" model={model} daemonOff={state.daemon === 'off'} />;+ if (state.preferencesUnsupported) {+ return (+ <Card>+ <div className="flex items-center gap-3.5">+ <RefreshCw className="size-5 shrink-0 text-amber" strokeWidth={2.5} />+ <div className="min-w-0 flex-1">+ <SectionTitle+ title="The daemon predates this app"+ subtitle="It is still running from before the last update, so it cannot share the browser theme or the guardrails yet."+ />+ </div>+ <PrimaryButton onClick={() => void model.restartDaemon()}>Restart it</PrimaryButton>+ </div>+ </Card>+ );+ }+ const preferences = state.preferences;+ if (!preferences) {+ return (+ <Card>+ <div className="flex justify-center">+ <Spinner />+ </div>+ </Card>+ );+ }+ const guardrailBusy = state.busy.find((key) => key.startsWith('guardrail:'))?.slice('guardrail:'.length) ?? null;++ return (+ <>+ <Card>+ <div className="space-y-3.5">+ <SectionTitle+ title="Browser theme"+ subtitle="How the side panel, the popup and the extension’s settings page look in every paired browser. This window keeps its own appearance."+ />+ <ThemePicker theme={preferences.theme ?? DEFAULT_THEME} onSelect={(theme) => void model.setBrowserTheme(theme)} />+ </div>+ </Card>+ <Card>+ <div className="space-y-4">+ <SectionTitle+ title="Guardrails"+ subtitle="What the agent may do without asking you first. A run takes its policy when it starts, and every paired browser follows the same rules."+ />+ <GuardrailPolicy+ settings={preferences.guardrails}+ busy={guardrailBusy}+ error={null}+ onWrite={(setting, value) => void model.setGuardrail(setting, value)}+ onReload={() => void model.loadPreferences()}+ />+ </div>+ </Card>+ </>+ );+}diff --git a/src/windows/ui/views/skills.tsx b/src/windows/ui/views/skills.tsxnew file mode 100644index 0000000..0fce153--- /dev/null+++ b/src/windows/ui/views/skills.tsx@@ -0,0 +1,99 @@+import { useEffect, useState } from 'react';+import { BookOpen, Folder, Globe, RefreshCw } from 'lucide-react';++import { Card, EmptyState, PathRow, Pill, QuietButton, SectionTitle, Spinner, type Tint } from '../components';+import type { Model, State } from '../model';+import type { Skill } from '../backend';++const SOURCE: Record<string, Tint> = { bundled: 'brand', user: 'ember' };++export function SkillsView({ model, state }: { model: Model; state: State }) {+ const [query, setQuery] = useState('');+ useEffect(() => void model.loadSkills(), [model]);++ const skills = state.skills?.skills ?? [];+ const needle = query.trim().toLowerCase();+ const shown = needle ? skills.filter((skill) => `${skill.name} ${skill.description} ${skill.domains.join(' ')}`.toLowerCase().includes(needle)) : skills;+ const own = state.skills?.agentSkills ?? [];++ return (+ <div className="space-y-4.5">+ <Card>+ <div className="space-y-3">+ <div className="flex items-start gap-3">+ <div className="min-w-0 flex-1">+ <SectionTitle+ title="Skills the agent can route to"+ subtitle="Read in order: a later folder shadows an earlier one by name. Drop a folder with a SKILL.md into yours to add one."+ />+ </div>+ <QuietButton icon={RefreshCw} onClick={() => void model.loadSkills()}>+ Refresh+ </QuietButton>+ </div>+ {state.skills?.dirs.map((dir) => <PathRow key={dir} path={expand(dir, state)} model={model} info={state.info} />)}+ <input+ value={query}+ onChange={(event) => setQuery(event.target.value)}+ placeholder="Filter by name, description or site"+ className="w-full rounded-[10px] border border-line bg-ground-2 px-3 py-2 text-[13px] text-ink outline-none placeholder:text-ink-faint focus:border-brand/50"+ />+ </div>+ </Card>++ {!state.skills ? (+ <div className="flex justify-center p-10">+ <Spinner />+ </div>+ ) : shown.length === 0 ? (+ <EmptyState icon={BookOpen} title="No skill matches" detail="Clear the filter to see all of them." />+ ) : (+ <div className="grid grid-cols-2 gap-3">+ {shown.map((skill) => (+ <SkillTile key={`${skill.source}/${skill.name}`} skill={skill} model={model} />+ ))}+ </div>+ )}++ {own.length > 0 && (+ <Card>+ <div className="space-y-2.5">+ <SectionTitle title="The agent’s own skills" subtitle="Attachable from the side panel’s / picker." />+ {own.map((skill) => (+ <div key={skill.name} className="space-y-0.5">+ <p className="font-mono text-xs font-semibold text-ink">{skill.name}</p>+ {skill.description && <p className="line-clamp-2 text-[11.5px] text-ink-dim">{skill.description}</p>}+ </div>+ ))}+ </div>+ </Card>+ )}+ </div>+ );+}++const expand = (dir: string, state: State) => (dir.startsWith('~') && state.info ? `${state.info.paths.home}${dir.slice(1)}` : dir);++function SkillTile({ skill, model }: { skill: Skill; model: Model }) {+ return (+ <div className="space-y-2 rounded-[14px] border border-line bg-surface/72 p-3.5">+ <div className="flex items-center gap-1.5">+ <span className="min-w-0 flex-1 truncate font-mono text-[12.5px] font-semibold text-ink">{skill.name}</span>+ {skill.isDefault && <Pill text="default" tint="lime" />}+ <Pill text={skill.provenance === 'generated' ? 'mapped' : skill.source} tint={SOURCE[skill.source] ?? 'magenta'} />+ </div>+ <p className="line-clamp-3 min-h-11 text-xs text-ink-dim">{skill.description || 'No description.'}</p>+ <div className="flex items-center gap-1.5">+ {skill.domains.slice(0, 2).map((domain) => (+ <Pill key={domain} text={domain} icon={Globe} />+ ))}+ <div className="flex-1" />+ {skill.path && (+ <button type="button" title="Show in File Explorer" className="text-ink-dim hover:text-ink" onClick={() => void model.reveal(skill.path!)}>+ <Folder className="size-4" />+ </button>+ )}+ </div>+ </div>+ );+}diff --git a/src/windows/ui/views/update-card.tsx b/src/windows/ui/views/update-card.tsxnew file mode 100644index 0000000..aa4fb17--- /dev/null+++ b/src/windows/ui/views/update-card.tsx@@ -0,0 +1,87 @@+import { BadgeCheck, CircleArrowDown, RefreshCw, TriangleAlert } from 'lucide-react';++import { cn } from '@/lib/utils';+import { formatWhen } from '@/lib/format-when';+import { Card, CopyButton, PrimaryButton, QuietButton, SectionTitle, Spinner } from '../components';+import type { Model, State } from '../model';++export const INSTALL_LINE = 'irm https://browsentic.com/install.ps1 | iex';+const RELEASES = 'https://github.com/imshaikot/browsentic/releases/tag/v';++export function UpdateCard({ model, state }: { model: Model; state: State }) {+ const { update, updatePhase: phase, info } = state;+ const current = info?.version ?? '';+ const failed = phase.kind === 'failed';+ const Icon = failed ? TriangleAlert : update ? CircleArrowDown : BadgeCheck;+ const tint = failed ? 'text-amber' : update ? 'text-brand' : 'text-lime';++ const title =+ phase.kind === 'downloading'+ ? `Downloading Browsentic ${update?.version ?? ''} · ${Math.round(phase.fraction * 100)}%`+ : phase.kind === 'relaunching'+ ? 'Reopening on the new version'+ : failed+ ? 'The update did not install'+ : update+ ? `Browsentic ${update.version} is out`+ : `Browsentic ${current} is up to date`;++ const subtitle =+ phase.kind === 'downloading'+ ? 'The daemon keeps running while this happens.'+ : phase.kind === 'relaunching'+ ? 'The app closes for a moment, then replaces the command, the daemon and the extension.'+ : failed+ ? `${phase.reason} Nothing was changed. The PowerShell line installs the same release.`+ : update+ ? `You have ${current}. One press replaces the app, then the command, the daemon and the extension, and reopens it.`+ : state.lastUpdateCheck+ ? `Checked GitHub ${formatWhen(state.lastUpdateCheck)}.`+ : 'Checks GitHub when it opens and every few hours after.';++ const checking = phase.kind === 'checking';+ const check = (label: string) => (+ <QuietButton icon={RefreshCw} disabled={checking} onClick={() => void model.checkForUpdate(true)}>+ {checking ? 'Checking…' : label}+ </QuietButton>+ );++ return (+ <Card className={cn(update && 'border-brand/45')}>+ <div className="space-y-3">+ <div className="flex items-center gap-3.5">+ <Icon className={cn('size-5.5 shrink-0', tint)} />+ <div className="min-w-0 flex-1">+ <SectionTitle title={title} subtitle={subtitle} />+ </div>+ <div className="flex shrink-0 items-center gap-2">+ {phase.kind === 'downloading' || phase.kind === 'relaunching' ? (+ <Spinner />+ ) : failed ? (+ <>+ <CopyButton value={INSTALL_LINE} label="Copy the PowerShell line" />+ <PrimaryButton icon={RefreshCw} onClick={() => void model.installUpdate()}>+ Try again+ </PrimaryButton>+ </>+ ) : update ? (+ <>+ <QuietButton onClick={() => void model.openUrl(`${RELEASES}${update.version}`)}>What’s new</QuietButton>+ <PrimaryButton icon={CircleArrowDown} onClick={() => void model.installUpdate()}>+ Update now+ </PrimaryButton>+ </>+ ) : (+ check('Check for updates')+ )}+ </div>+ </div>+ {phase.kind === 'downloading' && (+ <div className="h-1 overflow-hidden rounded-full bg-ground-2">+ <div className="h-full rounded-full bg-brand transition-[width]" style={{ width: `${Math.round(phase.fraction * 100)}%` }} />+ </div>+ )}+ </div>+ </Card>+ );+}diff --git a/src/windows/vite.config.ts b/src/windows/vite.config.tsnew file mode 100644index 0000000..00e1ce8--- /dev/null+++ b/src/windows/vite.config.ts@@ -0,0 +1,13 @@+import { fileURLToPath } from 'node:url';+import tailwindcss from '@tailwindcss/vite';+import react from '@vitejs/plugin-react';+import { defineConfig } from 'vite';++export default defineConfig({+ root: fileURLToPath(new URL('.', import.meta.url)),+ plugins: [react(), tailwindcss()],+ resolve: { alias: { '@': fileURLToPath(new URL('..', import.meta.url)) } },+ clearScreen: false,+ server: { port: 1420, strictPort: true },+ build: { outDir: 'dist', emptyOutDir: true, target: 'es2022' },+});diff --git a/vitest.config.ts b/vitest.config.tsindex 152a81a..7508bbf 100644--- a/vitest.config.ts+++ b/vitest.config.ts@@ -34,6 +34,14 @@ export default defineConfig({include: ['src/lib/actions/page/**/*.test.ts', 'src/lib/handsfree/host.test.ts'],},},+ {+ resolve: { alias: [{ find: /^@\//, replacement: `${at('./src')}/` }] },+ test: {+ name: 'windows',+ environment: 'happy-dom',+ include: ['src/windows/ui/**/*.test.ts'],+ },+ },{resolve: daemonResolve,test: {diff --git a/yarn.lock b/yarn.lockindex 40798c6..25853c2 100644--- a/yarn.lock+++ b/yarn.lock@@ -1450,6 +1450,143 @@ __metadata:languageName: nodelinkType: hard+"@tauri-apps/api@npm:^2.11.0, @tauri-apps/api@npm:^2.12.0":+ version: 2.12.0+ resolution: "@tauri-apps/api@npm:2.12.0"+ checksum: 10c0/3bcf726e74a96b1dfc7f04bac9dc4c30808ff8fc68bc501e9b2a92ee15674b89276637b69bc42d5f61f1aaa2c98aa9b6134d7bdabbf9b320d3a6504e1216b2ef+ languageName: node+ linkType: hard++"@tauri-apps/cli-darwin-arm64@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-darwin-arm64@npm:2.11.5"+ conditions: os=darwin & cpu=arm64+ languageName: node+ linkType: hard++"@tauri-apps/cli-darwin-x64@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-darwin-x64@npm:2.11.5"+ conditions: os=darwin & cpu=x64+ languageName: node+ linkType: hard++"@tauri-apps/cli-linux-arm-gnueabihf@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-linux-arm-gnueabihf@npm:2.11.5"+ conditions: os=linux & cpu=arm+ languageName: node+ linkType: hard++"@tauri-apps/cli-linux-arm64-gnu@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-linux-arm64-gnu@npm:2.11.5"+ conditions: os=linux & cpu=arm64 & libc=glibc+ languageName: node+ linkType: hard++"@tauri-apps/cli-linux-arm64-musl@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-linux-arm64-musl@npm:2.11.5"+ conditions: os=linux & cpu=arm64 & libc=musl+ languageName: node+ linkType: hard++"@tauri-apps/cli-linux-riscv64-gnu@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-linux-riscv64-gnu@npm:2.11.5"+ conditions: os=linux & cpu=riscv64 & libc=glibc+ languageName: node+ linkType: hard++"@tauri-apps/cli-linux-x64-gnu@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-linux-x64-gnu@npm:2.11.5"+ conditions: os=linux & cpu=x64 & libc=glibc+ languageName: node+ linkType: hard++"@tauri-apps/cli-linux-x64-musl@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-linux-x64-musl@npm:2.11.5"+ conditions: os=linux & cpu=x64 & libc=musl+ languageName: node+ linkType: hard++"@tauri-apps/cli-win32-arm64-msvc@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-win32-arm64-msvc@npm:2.11.5"+ conditions: os=win32 & cpu=arm64+ languageName: node+ linkType: hard++"@tauri-apps/cli-win32-ia32-msvc@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-win32-ia32-msvc@npm:2.11.5"+ conditions: os=win32 & cpu=ia32+ languageName: node+ linkType: hard++"@tauri-apps/cli-win32-x64-msvc@npm:2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli-win32-x64-msvc@npm:2.11.5"+ conditions: os=win32 & cpu=x64+ languageName: node+ linkType: hard++"@tauri-apps/cli@npm:^2.11.5":+ version: 2.11.5+ resolution: "@tauri-apps/cli@npm:2.11.5"+ dependencies:+ "@tauri-apps/cli-darwin-arm64": "npm:2.11.5"+ "@tauri-apps/cli-darwin-x64": "npm:2.11.5"+ "@tauri-apps/cli-linux-arm-gnueabihf": "npm:2.11.5"+ "@tauri-apps/cli-linux-arm64-gnu": "npm:2.11.5"+ "@tauri-apps/cli-linux-arm64-musl": "npm:2.11.5"+ "@tauri-apps/cli-linux-riscv64-gnu": "npm:2.11.5"+ "@tauri-apps/cli-linux-x64-gnu": "npm:2.11.5"+ "@tauri-apps/cli-linux-x64-musl": "npm:2.11.5"+ "@tauri-apps/cli-win32-arm64-msvc": "npm:2.11.5"+ "@tauri-apps/cli-win32-ia32-msvc": "npm:2.11.5"+ "@tauri-apps/cli-win32-x64-msvc": "npm:2.11.5"+ dependenciesMeta:+ "@tauri-apps/cli-darwin-arm64":+ optional: true+ "@tauri-apps/cli-darwin-x64":+ optional: true+ "@tauri-apps/cli-linux-arm-gnueabihf":+ optional: true+ "@tauri-apps/cli-linux-arm64-gnu":+ optional: true+ "@tauri-apps/cli-linux-arm64-musl":+ optional: true+ "@tauri-apps/cli-linux-riscv64-gnu":+ optional: true+ "@tauri-apps/cli-linux-x64-gnu":+ optional: true+ "@tauri-apps/cli-linux-x64-musl":+ optional: true+ "@tauri-apps/cli-win32-arm64-msvc":+ optional: true+ "@tauri-apps/cli-win32-ia32-msvc":+ optional: true+ "@tauri-apps/cli-win32-x64-msvc":+ optional: true+ bin:+ tauri: tauri.js+ checksum: 10c0/cea6cb7abaf8f5c79d87677941cebcc9ffba3c4d446e396ce1424353fdf8b5a8e2b8b5f4eca37524eb44d62aff0043de54822c6882da0d14b07a685a675a8a31+ languageName: node+ linkType: hard++"@tauri-apps/plugin-opener@npm:^2.5.5":+ version: 2.5.5+ resolution: "@tauri-apps/plugin-opener@npm:2.5.5"+ dependencies:+ "@tauri-apps/api": "npm:^2.11.0"+ checksum: 10c0/2ad09fc3831758785b4c3d291e3c04a9b7949694bce9867e0e2e7f14f6b7d8d04efc4152369b08845f115bbe33c34a85e2bb5a28e0206314ad92130e431c1e95+ languageName: node+ linkType: hard+"@tybys/wasm-util@npm:^0.10.2, @tybys/wasm-util@npm:^0.10.3":version: 0.10.3resolution: "@tybys/wasm-util@npm:0.10.3"@@ -1737,6 +1874,27 @@ __metadata:languageName: nodelinkType: hard+"@vitejs/plugin-react@npm:^6.1.1":+ version: 6.1.1+ resolution: "@vitejs/plugin-react@npm:6.1.1"+ dependencies:+ "@rolldown/pluginutils": "npm:^1.0.1"+ peerDependencies:+ "@rolldown/plugin-babel": ^0.1.7 || ^0.2.0+ babel-plugin-react-compiler: ^1.0.0+ oxc-transform-react: ^0.145.0+ vite: ^8.0.0+ peerDependenciesMeta:+ "@rolldown/plugin-babel":+ optional: true+ babel-plugin-react-compiler:+ optional: true+ oxc-transform-react:+ optional: true+ checksum: 10c0/4599b37ee19ebee289782b177642e3002afa9b74cb57a2c0e2a601053c7ebb47f9ef178ab605ff1217de1d23069948a8d366447bfac0d9fb2f17afee5368acd0+ languageName: node+ linkType: hard+"@vitest/coverage-v8@npm:^5.0.1":version: 5.0.1resolution: "@vitest/coverage-v8@npm:5.0.1"@@ -2205,8 +2363,12 @@ __metadata:"@radix-ui/react-select": "npm:^2.3.7""@radix-ui/react-slot": "npm:^1.3.1""@tailwindcss/vite": "npm:^4.3.3"+ "@tauri-apps/api": "npm:^2.12.0"+ "@tauri-apps/cli": "npm:^2.11.5"+ "@tauri-apps/plugin-opener": "npm:^2.5.5""@types/react": "npm:^19.2.17""@types/react-dom": "npm:^19.2.3"+ "@vitejs/plugin-react": "npm:^6.1.1""@vitest/coverage-v8": "npm:^5.0.1""@wxt-dev/module-react": "npm:^1.2.2"class-variance-authority: "npm:^0.7.1"@@ -2219,6 +2381,7 @@ __metadata:tailwindcss: "npm:^4.3.3"tw-animate-css: "npm:^1.4.0"typescript: "npm:^7.0.2"+ vite: "npm:^8.0.0"vitest: "npm:^5.0.1"web-ext: "npm:^10.6.0"wxt: "npm:^0.20.27"