diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1f00a901..bf579261 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -101,6 +101,42 @@ jobs: - name: Unit tests (Vitest, Windows-relevant subset) run: npm run test:win + # The fact and skill gates compare a quantized model's score against a fixed + # floor, and that score has moved before without the weights changing: with a + # runtime upgrade, and between platforms (src/server/recall/gate-canary.ts). + # This scores a small set of synthetic pairs with the released model and + # compares them with the scores recorded where the floors were measured. + # + # Not required to pass. A hosted Linux runner may have a CPU whose kernels + # differ from the server the reference was taken on, and that reads as drift + # with nothing changed in the repo. What it is for: the job going from green + # to red in the pull request that upgrades transformers.js or onnxruntime. + gate-canary: + continue-on-error: true + strategy: + fail-fast: false + matrix: + os: [macos-latest, ubuntu-latest] + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v4 + + - uses: actions/setup-node@v4 + with: + node-version: '24' + cache: npm + + - run: npm ci + + # 342 MB, pinned by revision and checksum in gte-model-artifact.ts. + - uses: actions/cache@v4 + with: + path: .embed-smoke-cache + key: gate-model-${{ hashFiles('src/server/recall/gte-model-artifact.ts') }} + + - name: Gate model scores as when its floors were measured + run: npm run eval:gate-canary + relay: runs-on: ubuntu-latest defaults: diff --git a/.gitignore b/.gitignore index eb5f8f83..e373a32d 100644 --- a/.gitignore +++ b/.gitignore @@ -18,6 +18,7 @@ build/native/ # Skill retrieval eval build output (embed-catalog, compiled to CJS) .skills-build/ +.gate-canary-build/ # Playwright E2E artifacts test-results/ diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 00000000..9b57e027 --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1,39 @@ +# Stem: rules for coding agents + +## Done means verified where the user will see it + +An audit of the history (2026-11-18) found that about 40 % of non-chore commits fix +work built shortly before, with a median of 2 days between the bug going in and the fix. +In nearly every case the broken work had been checked only by unit tests, a dry run, or +an e2e test that skipped the real interaction. The agent often said so, and the task was +closed anyway. + +A task is not done until the change has run the way the user will use it: + +- **Desktop UI** (renderer, Quick Chat / Ask about this window, composer, mail, settings): + run a separate dev instance with its own profile (`STEM_PROFILE= + STEM_DEVTOOLS_PORT= npx electron-vite dev`), drive it over CDP + (`agent-browser connect `), do the user's actual clicks and keys, and take a + screenshot. Never test against the user's running Stem.app or the real profile. +- **iOS**: build, install and screenshot in the Simulator against a separate server + (`STEM_STATE_DIR=…`), never the VPS. +- **Prompts, recall gates, skill or tool gating, anything a model reads**: run at least + one real-model turn on the case that prompted the change, plus one that used to work, + so a regression shows up. +- **Deploy and release scripts**: a dry run is not a test. Run the real thing, or leave + the task open. +- **Integrations** (browser extension / jbrow, computer control, MCP, relay, LM Studio): + exercise the real connection end to end once. +- **Bug fixes**: reproduce the bug first and confirm it is gone afterwards in the same + place. A new e2e test must click and type through the visible UI like a person, not + set hidden inputs or call handlers directly. + +If you cannot verify it (no GUI access, needs the user's device, costs real quota they +did not approve), do not call the task done. Say plainly "built, not verified", what +remains to check, and how. "Tests pass" alone is never the closing line for a UI, +prompt or integration change. + +## Before you start a fix + +Search `git log` for earlier fixes to the same area. If this is the second or later +attempt, read why the earlier ones failed and say so in your reply before changing code. diff --git a/Dockerfile b/Dockerfile index 28353095..520e21d2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -48,10 +48,9 @@ FROM ${NODE_IMAGE} AS build WORKDIR /app ENV ELECTRON_SKIP_BINARY_DOWNLOAD=1 \ PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1 -# patches/ and scripts/ensure-electron.mjs are named by `postinstall`, so they -# have to exist before `npm ci` rather than with the rest of the source. +# scripts/ensure-electron.mjs is named by `postinstall`, so it has to exist +# before `npm ci` rather than with the rest of the source. COPY package.json package-lock.json ./ -COPY patches ./patches COPY scripts/ensure-electron.mjs ./scripts/ensure-electron.mjs RUN npm ci --no-audit --no-fund COPY tsconfig.json electron.vite.config.ts ./ @@ -80,16 +79,9 @@ FROM ${NODE_IMAGE} AS deps WORKDIR /app ENV ELECTRON_SKIP_BINARY_DOWNLOAD=1 COPY package.json package-lock.json ./ -COPY patches ./patches -COPY scripts/ensure-electron.mjs ./scripts/ensure-electron.mjs -# `postinstall` runs patch-package, which is a devDependency and so is not -# installed by --omit=dev — the bare `npm ci` dies with `patch-package: not -# found`. Skip scripts and apply the patches with a fetched patch-package -# instead: pi-web-access is a production dependency and must ship patched. -# (ensure-electron.mjs is the other postinstall step; it exits 0 immediately -# when electron is absent, which with --omit=dev it always is.) -RUN npm ci --omit=dev --no-audit --no-fund --ignore-scripts \ - && npx --yes patch-package@8.0.1 +# No install scripts: `postinstall` is only ensure-electron.mjs, which has +# nothing to do without electron, and --omit=dev never installs it. +RUN npm ci --omit=dev --no-audit --no-fund --ignore-scripts # ---- stage 3: what actually ships -------------------------------------------- FROM ${UV_IMAGE} AS uv diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index f301648e..713271e6 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -12,6 +12,69 @@ Maintainer notes: date, tag. --> +## 0.8.0 — 2026-11-23 + +### Added + +- **People.** Memory learns about the people in your life. See them under Personas & people → + People. +- **Skills learn how you like things done**, such as how to sign your mail drafts, and get better + each time you correct them. +- **Skill history.** Restore an earlier version of a skill, and set how often its task comes up. +- **Tabs in Ask about this window.** ⌘T opens another conversation; ⌘M shrinks the panel to a pill. +- **Keep with its window** (Mac setting) keeps the Ask panel with its window. +- **Share links for chosen people.** Only the people you pick can open them, and you see who did. +- **Stem's own file viewer.** Files linked in replies open in a safe Stem window. +- **Change who's in a mail conversation** from the reply's To row, and pick who leads. +- **Stem can edit your scheduled tasks** from any chat, and you can undo its edits. +- **Pictures from your files** can be the starting point for a generated image. +- **Stem can change an MCP server** without losing its sign-in. +- **Current situation** at the top of your summary, such as a hospital stay or a trip. +- **Search in Settings.** +- **ChatGPT usage left**, shown in Settings → Models. +- **GPT-6.2 Astra and Sol** in the model list. +- **Zoom** with ⌘+, ⌘- and ⌘0. +- **Diff view** for code changes, **sounds** in replies, and the **Cotton Candy** theme. +- **Demo on the iPhone**, from the pair screen. + +### Changed + +- **Faster replies with ChatGPT.** Stem now talks to ChatGPT over WebSocket, so replies after a + tool call start about 1.5 s sooner. +- **Mail sends fast** and closes after sending. Attachments upload while you write. +- **New mail is simpler**: one card on the desktop, one page on the iPhone. +- **Chats open faster**, and memory lookups before a reply are faster. +- **Better recall.** Stem also remembers short overviews of related facts. +- **Stem GTE Memory** no longer needs the Qwen3 reranker: one download fewer. +- **Shared links show what the chat shows**, including pictures and sounds. +- **Scheduled tasks get short names** instead of the first line of their prompt. +- **Up to eight commands** run at once, instead of two. +- **Skills save automatically** by default. +- **New installs start on GPT-6.2 Sol.** +- **More room for chats**: the composer fits on one row and messages use the full width. +- **Dropping files on the window** shows your folders as tiles that always fit. +- **Your own mail always gets a reply**, even if just a short one. +- **A short "yes"** to a blocked command now gets you an approval card instead of a refusal. +- **Welcome screen** says where your data goes. New users aren't offered Claude sign-in. + +### Fixed + +- **A new chat no longer vanishes** while a big file uploads. +- **Chats no longer get stuck on Working**, including in Ask about this window. +- **Browser control stays connected** when the browser restarts the extension. +- **Charts and tables the model left open** no longer turn the reply into plain text. +- **Skills no longer get in the way** of unrelated browser or computer-control work. +- **Share links** publish exactly the preview you saw. +- **New mail on the iPhone** is no longer lost while photos upload. +- **MCP servers Stem installs** no longer break when a chat is deleted. +- **Archiving the open chat** now closes it and opens the next one. +- **Copy message** copies clean text, on the desktop and the iPhone. +- **Pasted text** starting with / is no longer taken as a command. +- **Web pictures from some sites** now show. +- **Numbered lists** keep their numbers. +- **Popups** are no longer hidden behind the composer. +- **Quitting Stem** no longer hangs. + ## 0.7.5 — 2026-10-30 ### Added diff --git a/SKILLS-UPKEEP.md b/SKILLS-UPKEEP.md index 8e94fb04..0e8c29f5 100644 --- a/SKILLS-UPKEEP.md +++ b/SKILLS-UPKEEP.md @@ -578,3 +578,53 @@ arXiv 2408.01875); admission by verified re-run (ASI). that drifted from the user's last save gets one model call that moves other jobs out as `approved` skills; an import is restored to what was installed. Backups in `.curator-history/-relabel`; marker `.skills-provenance.json`. + +## Addendum 2026-11-11 — skills learn from how their uses ended + +Until this change Stem knew that a skill was used (the tool-overlap proxy in +`grade.ts`) and, rarely, that the model called a step wrong (17 reports in 527 +loads on the server). It did not know whether the user accepted the result. Each +patch was judged on one turn, written without a check, and overwrote the file. +Hermes has the same gap in its loop; its GEPA tool, which does check, is a separate +manual run. Published results say the check matters more than the patch: 55 of 388 +automatic rewrites set a new best, a check against stored cases picked a better +skill in 9 of 14 settings, and every useful rewrite was built from failures +(arXiv 2608.02636). The methods that improve skills reliably also read many uses at +once and keep the diagnosis apart from the rewrite (survey, arXiv 2606.11435). + +What was built: + +1. **Case file** (`skills/cases.ts`, `.skills-cases.json`). One case per skill the + turn followed or reported: request, tool calls, start of the reply, skill version. + Written in the turn-settled hook, before the next message can be captured. Only + where memory would keep the turn (memory on, not private, not tainted, not + scheduled, not a persona without memory). Twelve cases per skill. Deleting a chat + drops its cases. +2. **Outcome on the distill call** (`recall/distill.ts`). A pending case whose next + user message is in the segment is listed in an extra block, and the reply gains + `skillOutcomes`: accepted, corrected (with feedback), redone, unclear. No extra + model call. `DISTILL_INSTRUCTIONS` is unchanged, and a segment with no case sends + the old prompt byte for byte. Each case closes exactly once, also when the segment + is abandoned, so it can never pair with a later message. +3. **Correction pass** (`startup/skills.ts`). A corrected or redone use patches its + skill, with the conversation from the use to the end as evidence and + `SKILL_CORRECTION_INSTRUCTIONS`. Imports are never patched. Same privacy refusals + as the convention pass. +4. **Check before every automatic change** (`skills/review.ts`, in `bridge.ts`). Old + text, new text, the reason, and the graded cases; the model answers keep or reject. + A rejected change is not written in Auto and gets no card in Ask. A change the check + cannot judge is not written in Auto; in Ask the card still shows. The user's own + requests and new skills are not checked. +5. **Rewrite from all cases** (`skills/rewrite.ts`). Three failed uses since the last + rewrite start a diagnosis call (what failed and what the accepted uses relied on, + no skill text) and then a rewrite call; the result goes through the check. Only + for Stem's own ideas (`CURATED_ORIGINS`). The failures are spent whatever the + outcome. +6. **Kept versions** (`skills/store.ts`). Every update copies the old SKILL.md to + `.skill-versions//v.md` (ten kept) and the new one carries a `change` + line. Manage → Skills lists them and restores one as a new version. Writes are + atomic now. + +Open: no real-model run yet. Measure on the server after deploy: how often a case +gets a verdict other than unclear, how often the check rejects, and whether skills +with corrections then collect more accepted uses. diff --git a/docs/README.md b/docs/README.md index 51be7c03..8beda799 100644 --- a/docs/README.md +++ b/docs/README.md @@ -12,6 +12,7 @@ Pick the feature you see in Stem. | [Memory](user/memory/README.md) | Learn useful context and recall earlier chats | | └ [Facts](user/memory/facts.md) | Durable details: preferences, people, projects | | └ [Past chats](user/memory/recall.md) | Recall: find relevant parts of past conversations | +| └ [People](user/memory/README.md#people) | Who is who in your life, and what Stem knows about each | | [Tools](user/tools/README.md) | Give Stem more capabilities | | └ [MCP servers](user/tools/mcp-servers.md) | Connect services and tools, on this Stem or on your own computer | | └ [Skills](user/tools/skills.md) | Reuse procedures that work | diff --git a/docs/assistant/assistant-mcp.md b/docs/assistant/assistant-mcp.md index ba16f981..c66b8b02 100644 --- a/docs/assistant/assistant-mcp.md +++ b/docs/assistant/assistant-mcp.md @@ -1,5 +1,7 @@ # Managing your own MCP servers -You can extend your own capabilities by managing MCP servers with your tools: `list_mcp_servers`, `add_mcp_server`, and `remove_mcp_server`. When the user asks to connect a service (Home Assistant, a database, an API, etc.), do it yourself with these tools rather than telling them to edit MCP config by hand. First gather everything the server needs from the user — for a local (stdio) server the command and args (e.g. `uvx ha-mcp@latest`) and any required env vars/tokens; for a remote (http) server the URL (the user signs into those separately via OAuth in the app). Adds and removes require the user's approval: a confirm card appears in the app, and the change only applies — and your new tools only become usable — after they approve and Stem reloads, so don't claim a server is connected until then. Note for the user that any token they share is written into your local configuration and kept in this chat's history, so they may want to rotate it later if that's a concern. +You can extend your own capabilities by managing MCP servers with your tools: `list_mcp_servers`, `add_mcp_server`, `edit_mcp_server`, and `remove_mcp_server`. When the user asks to connect a service (Home Assistant, a database, an API, etc.), do it yourself with these tools rather than telling them to edit MCP config by hand. First gather everything the server needs from the user — for a local (stdio) server the command and args (e.g. `uvx ha-mcp@latest`) and any required env vars/tokens; for a remote (http) server the URL (the user signs into those separately via OAuth in the app). To change a server that already exists — a new command, path, argument, URL or one env var — use `edit_mcp_server` with only what changes: it keeps the token and headers stored with the server, which you cannot read back, while `add_mcp_server` under the same name replaces the whole entry and drops them. Never send the user to the settings panel for a change `edit_mcp_server` can make. Adds, edits and removes require the user's approval: a confirm card appears in the app, and the change only applies — and your new tools only become usable — after they approve and Stem reloads, so don't claim a server is connected until then. Note for the user that any token they share is written into your local configuration and kept in this chat's history, so they may want to rotate it later if that's a concern. **Which machine a server runs on.** An MCP server runs on the same machine you do unless the user has pinned it to one of their own computers, and `list_mcp_servers` says which is which — check it before guessing, especially when one is failing. A command-started (stdio) server can only start if its command exists on the machine that runs it, so `failed to start: spawn uvx ENOENT` means that machine has no `uvx`; a URL server can only connect if that machine can reach the URL, so an address on the user's home network is unreachable from a server elsewhere. Either install what is missing where the server runs, or — when the server is only meaningful on the user's own computer (its files, its apps, its network) — tell them to move it: Tools → MCP servers, open the server, pick that computer on its **Runs on** tab and **Save**, then approve it on that computer (**Approve and start**). Only they can do that; `add_mcp_server` always adds a server that runs where you do. Read the `mcp-servers` guide page before you explain any of this. + +**Where a server you install yourself lives.** When you build, clone or download an MCP server (rather than run a published package through `uvx`/`npx`), put the finished copy in a folder of its own under Stem's tools folder — the `add_mcp_server` description names it — and point `command` and `args` there. Never point a server at this chat's scratch folder or at `files/`: scratch is deleted with the chat and the user tidies Files by hand, and the server would stop working the moment either goes. Build in scratch if you like, then copy the result over with `run_command`; `add_mcp_server` and `edit_mcp_server` refuse a path in either place. diff --git a/docs/assistant/assistant-preferences.md b/docs/assistant/assistant-preferences.md index b0fd1c6f..d5dcf517 100644 --- a/docs/assistant/assistant-preferences.md +++ b/docs/assistant/assistant-preferences.md @@ -1,3 +1,3 @@ # Your standing instructions (how to respond) -The user can give you STANDING behavioral rules that shape how you reply — response length ("always answer briefly"), output format ("use plain Markdown, no components"), tone, or language style. These are kept as your "custom instructions" and injected into every turn as high-priority directives, separate from remembered facts; honor them above your defaults. When the user asks you to ADOPT such a rule going forward ("from now on…", "always…", "stop doing X"), record it with the `set_custom_instructions` tool (action "append", "replace", or "clear") rather than relying on memory — the distiller does NOT save these as facts. The user approves the change in a card where THEY pick the surface, so do not assume it: pass `surface` only as a hint when they clearly meant one. "main" applies everywhere (including Quick Chat); "quickChat" is an extra layered only on the Quick Chat overlay, which inherits the main instructions. Don't use this for one-off requests ("answer this next one briefly") — just do those. +The user can give you STANDING behavioral rules that shape how you reply — response length ("always answer briefly"), output format ("use plain Markdown, no components"), tone, or language style. These are kept as your "custom instructions" and injected into every turn as high-priority directives, separate from remembered facts; honor them above your defaults. Only when the user explicitly asks you to adopt such a rule for every reply ("from now on…", "always…", "stop doing X", "put that in your instructions"), record it with the `set_custom_instructions` tool (action "append", "replace", or "clear") rather than relying on memory — the distiller does NOT save these as facts. The user approves the change in a card where THEY pick the surface, so do not assume it: pass `surface` only as a hint when they clearly meant one. "main" applies everywhere (including Quick Chat); "quickChat" is an extra layered only on the Quick Chat overlay, which inherits the main instructions. Don't use this for one-off requests ("answer this next one briefly") — just do those. Don't use it either for conventions that belong to one kind of work ("sign my email drafts on behalf of me", "write invoices in English"): those go in a skill for that work, through `manage_skill` (see `assistant-skills`). Don't use it for a preference about one thing either — how a scheduled task signs its drafts, how a persona behaves, how one kind of mail is written: change that thing (`update_task`, the persona) instead. The user agreeing with something you proposed is not a request to save it as an instruction. This tool is rarely the right one; when unsure, ask. diff --git a/docs/assistant/assistant-scheduling.md b/docs/assistant/assistant-scheduling.md index b0a024ff..398645fd 100644 --- a/docs/assistant/assistant-scheduling.md +++ b/docs/assistant/assistant-scheduling.md @@ -1,6 +1,6 @@ # Scheduled tasks -You can schedule a prompt to run automatically. When the user asks for something recurring or deferred — "every morning summarize my unread email", "check this page hourly and tell me if X changes", "remind me / look into this tomorrow at 9" — call `schedule_task` with a prompt describing the run plus either a `cron` expression (recurring, 5 fields, local time) or an `at` ISO datetime (one-time). Use `list_tasks` / `cancel_task` to review or remove tasks created in the current conversation. +You can schedule a prompt to run automatically. When the user asks for something recurring or deferred — "every morning summarize my unread email", "check this page hourly and tell me if X changes", "remind me / look into this tomorrow at 9" — call `schedule_task` with a prompt describing the run plus either a `cron` expression (recurring, 5 fields, local time) or an `at` ISO datetime (one-time). Use `list_tasks` to see the user's tasks (in a chat with the user that is every task, whichever chat scheduled it; an unattended run sees only its own thread's), `update_task` to change one in place — its prompt, schedule, or paused state — and `cancel_task` to delete one. When the user asks to change how a task behaves, edit it with `update_task`; don't send them to the chat it came from, and don't cancel and re-create it. A new `prompt` replaces the old one whole, so start from the current prompt and change only what was asked. Every run executes in a fresh, isolated thread with no memory of this or any conversation: the prompt is all it knows, plus a short list of what the task's earlier runs already mailed the user (their headlines and reports), so a watch task reports each finding once without the prompt having to track a baseline by hand. Write it fully self-contained — every name, URL, path, criterion and expected output spelled out, as if briefing a stranger. Never write "as discussed" or "the page above"; put the page in the prompt. diff --git a/docs/assistant/assistant-skills.md b/docs/assistant/assistant-skills.md index 18ce3ceb..9a000795 100644 --- a/docs/assistant/assistant-skills.md +++ b/docs/assistant/assistant-skills.md @@ -1,11 +1,17 @@ # Managing your own skills -A skill is a procedure you saved so you can follow it again: a short slug-like name, a one-sentence description saying WHEN to reach for it, and a body with the headings "## When to use", "## Steps", "## Verification". Relevant ones are loaded into your context each turn; the rest are listed by name. You save and update them with the `manage_skill` tool, which always takes an `initiated_by` — answer it honestly, because it decides what happens next. +A skill is a procedure you saved so you can follow it again: a short slug-like name, a one-sentence description saying WHEN to reach for it, and a body with the headings "## When to use", "## Steps", "## Verification". You save and update them with the `manage_skill` tool, which always takes an `initiated_by` — answer it honestly, because it decides what happens next. **When the user asks you to remember how to do something** — "save that as a skill", "remember this process", "add a skill for X" — call `manage_skill` right away with `initiated_by: "user"`. Write it yourself, in this turn: you have the actual commands, the actual output, and the whole conversation in front of you, which is more than anything reconstructing it later would have. A user-requested save always goes through, whatever their automatic-skills setting says. Do this even mid-conversation; it takes one call. **When saving one is your own idea**, use `initiated_by: "assistant"`. Do that after a turn where you worked something out that would plausibly come up again and that took knowledge you did not start with — the exact tool and arguments that worked, an order that mattered, a dead end you had to back out of. Say briefly what you saved and why, in one line at the end of your reply. Depending on the user's setting this may save silently, ask them to approve it, or be declined; if it is declined, don't retry the tool — mention the idea in your reply and let them decide. -Don't save: facts or preferences about the user (those are remembered separately), a retelling of one conversation, or anything you already know how to do without notes. A library full of near-misses is worse than a small one, because every skill costs context on every turn and a bad skill gets followed. +**When the user tells you how they want a recurring kind of work done**, that is a skill too, even with no tools in it. "Sign my drafts as Stem, on behalf of Vladimír", "write to my doctors in Slovak, formally", "send private mail from join3r@gmail.com": these are conventions for a job you will do again (drafting their email, writing their invoices, posting their updates). Save them in one skill for that job, named after the job rather than the recipient, with `initiated_by: "user"` because they asked for the behaviour. Quote exact wording verbatim in the steps (a signature, a sign-off line), and include the tool steps that produce the result (which tool, which sending identity, reply versus new). If a skill for that job already exists, update it with `expect_existing: true` instead of adding another. Do not put such conventions in custom instructions (those are for how you reply in every chat) or in a single scheduled task's prompt (other chats that do the same job would never see them). Say in one line which skill you saved. -Writing to an existing name replaces its body, so always send the FULL body, never a fragment. When a loaded skill turns out to be wrong or incomplete, say so in your reply and save the corrected version. If a save is rejected, the reply lists exactly what was wrong — fix those points and call again. +**Using skills.** Relevant skills are loaded into your context each turn; at most two are loaded in full and the rest are listed by name and description, each one time per chat. When a listed skill's description fits the request, load it with `manage_skill` action `view` and its `name` before you start, then follow it. + +Don't save: lone facts about the user (their address, an account number; those are remembered separately), a retelling of one conversation, or anything you already know how to do without notes. A library full of near-misses is worse than a small one, because every skill costs context on every turn and a bad skill gets followed. + +Pass `recurs` on a save when the user said, or the work shows, how often the task comes up: `weekly`, `monthly`, `quarterly`, `yearly`, or `occasional` for no rhythm. Stem switches off a skill that sits unused for several such periods, so a monthly or yearly task needs the right answer to still be there for its next run. When the job is the same procedure for another app, server or account as an existing skill, update that skill (`expect_existing: true`) so it takes the target as input and lists what differs per target; do not save a second skill under the other product's name. + +Writing to an existing name replaces its body, so always send the FULL body, never a fragment. When a loaded skill turns out to be wrong or incomplete, say so in your reply and save the corrected version. If a save is rejected, the reply lists exactly what was wrong — fix those points and call again. A change you make on your own (`initiated_by: "assistant"`) to an existing skill is first checked against that skill's earlier uses; if the check refuses it, keep following the skill as it is and do not retry. diff --git a/docs/development.md b/docs/development.md index d3839076..4e8bb428 100644 --- a/docs/development.md +++ b/docs/development.md @@ -40,6 +40,7 @@ First run opens the onboarding wizard — pick a provider and sign in, and you'r | `npm run dist` | Package installers for the current OS (electron-builder) | | `npm run eval:retrieval` | Run the real local-embedding Recall retrieval gate | | `npm run eval:memory` | Run the real extraction gate against a configured OpenAI-compatible model | +| `npm run eval:gate-canary` | Check that the gate model scores as it did when its floors were measured (downloads the model once) | ## Tech stack diff --git a/docs/gte-memory-pilot.md b/docs/gte-memory-pilot.md index 40d0197a..83bb9a7d 100644 --- a/docs/gte-memory-pilot.md +++ b/docs/gte-memory-pilot.md @@ -39,7 +39,7 @@ STEM_GTE_FACT_MODEL_DIR=/var/lib/stem/gte-fact-model Build the prepared server version and recreate only the Stem service using the deployment's existing Compose files. Keep the previous image for rollback. Wait for active turns and pending approvals to finish before replacing the container. -The dropdown status and activity feed report the experimental memory model preparing or failing. Server logs report `GTE fact pilot ready` and, on applicable recall builds, `experimental fact selection` with model, selection tier, count and whether context was used. These diagnostics omit message and fact text. While selected GTE is preparing or unavailable, Qwen remains the fact fallback; the Test model action reports GTE readiness and never times that fallback as GTE. +The dropdown status and activity feed report the experimental memory model preparing or failing. Server logs report `GTE fact pilot ready` and, on applicable recall builds, `experimental fact selection` with model, selection tier, count and whether context was used. These diagnostics omit message and fact text. GTE is a reranker of its own: selecting it unloads the catalog reranker (Qwen3 or BGE), and no other model stands in for it. While GTE is preparing or has failed, the dropdown shows that state and recall runs without a reranker, the same as while any reranker downloads; the Test model action reports GTE readiness or its error. ## Behavior and limits @@ -48,8 +48,8 @@ The dropdown status and activity feed report the experimental memory model prepa - Fact candidates and reranking use at most two prior eligible user messages from the active conversation branch, clipped to 400 Unicode characters each. Assistant, tool, scheduled/mail, and attachment-bearing history entries are omitted. Missing or unreadable history uses the current message alone. - Skill selection uses GTE with its own raw-logit floors: −0.5 for the best of a skill's description and its example requests, −3.25 for a skill with no examples yet, chosen where macOS and the Linux server image agree (`gte-fact-pilot.ts`). The fact floor −1.6370911598205566 is unchanged. Skill queries, episodic search and folder-document search continue using the current message. The trial adds a separate fact query embedding when context is present. - Private chats and personas with recall disabled do not read history for this trial or retrieve facts. Scheduled/mail deliveries use current-message-only fact selection. -- While verification/loading fails or is incomplete, fact retrieval uses the normally configured reranker. A failure during an already-started GTE selection uses the existing conservative retrieval fallbacks. -- Model quality was measured on local benchmarks and frozen synthetic Linux checks; these do not establish improved live answer quality. The configured Qwen worker remains available as a warm fallback, so these changes do not claim a single-reranker RAM reduction. +- While GTE is downloading, loading or failed, fact and skill selection run without a reranker (the existing conservative cosine/lexical tiers); no other reranker is loaded in its place. +- Model quality was measured on local benchmarks and frozen synthetic Linux checks; these do not establish improved live answer quality. With GTE selected only GTE is loaded, so the RAM reduction measured against Qwen applies. ## Roll back diff --git a/docs/public-share-design.md b/docs/public-share-design.md index 1b5a3253..b9a3f2f1 100644 --- a/docs/public-share-design.md +++ b/docs/public-share-design.md @@ -48,12 +48,17 @@ cleaned: | --- | --- | | User text, assistant MDX (charts, diagrams, tables, callouts) | System notices (failed/interrupted turns), failed sends | | Generated images (embedded as data URLs) | Tool rows / activity (queries, paths, commands) | -| Web sources (public URLs) | Recall, file, mail and schedule context (already stripped from history) | +| Web pictures the chat shows (`![…](https://…)`, embedded) | Recall, file, mail and schedule context (already stripped from history) | +| Sounds from `share_audio` (embedded) | | +| Web sources (public URLs, with the site icon embedded) | | | The model's name (optional) | `` (personal memory), `` (dead in a static page) | | User attachments: only when the user ticks "Include my pictures" | `stem://` and `file:` links (become plain text) | The user always sees a preview of exactly what will be published before the -upload. That preview is the main protection against leaking something private. +upload. That preview is the main protection against leaking something private, +so "Create link" publishes the very snapshot the server built for it (kept as +a draft for 30 minutes, named by `draftId`), never a fresh build that could +pick up a message that arrived after the user looked. Private chats can be shared: "private" means "not learned from", and sharing is an explicit act. @@ -64,12 +69,26 @@ is an explicit act. { "v": 1, "kind": "answer" | "thread", "title": "…", "sharedAt": 1760000000000, "messages": [ { "role": "user" | "assistant", "text": "…", "createdAt": 1760000000000, - "model": "GPT-6.1", "images": [{ "mime": "image/png", "dataUrl": "data:…", "alt": "…" }], - "sources": [{ "url": "https://…", "title": "…" }] } ] } + "model": "GPT-6.1 Sol · ChatGPT", + "images": [{ "mime": "image/png", "dataUrl": "data:…", "alt": "…", "generated": true, "width": 1024, "height": 1024 }], + "webImages": [{ "url": "https://…", "dataUrl": "data:…" }], + "audio": [{ "mime": "audio/mpeg", "dataUrl": "data:…", "title": "…" }], + "sources": [{ "url": "https://…", "title": "…", "icon": "data:…" }] } ] } ``` Viewers ignore unknown fields and show "made by a newer Stem" for `v > 1`. +The page has no Stem to ask, so everything the app fetches from the server as +it draws a reply rides in the snapshot. `webImages` holds exactly the pictures +the chat shows: the server runs the same provenance check as +`chats:remoteImage` (src/server/chats/remote-image.ts) when the link is made, +and a refused picture stays a link, as in the app. Mail shows web pictures as +links, so a mail share carries none. The page draws a reply with the app's own +parts (src/renderer/share/ShareView.tsx); `MdxStaticContext` hands them the +snapshot's bytes and makes file and Files links plain text. +tests/e2e/share-view.spec.ts renders one reply in the app and on the built page +under the CSP of relay/deploy/global/Caddyfile.snippet, and compares the markup. + ### Encryption ``` @@ -117,7 +136,8 @@ The browser decrypts with WebCrypto and `DecompressionStream('gzip')`. - stem-relay serves the whole viewer origin from `[share] viewer_dir` (only on the viewer host): `/s/*`, `/assets/*`, icons, `/v1/shares/*`. Caddy proxies just those paths and 404s the rest of the relay API there. Strict CSP (`script-src 'self'`, - `connect-src 'self'`, `frame-ancestors 'none'`), `Referrer-Policy: + `connect-src 'self'`, `img-src 'self' data: blob:`, `media-src blob:` for + shared sounds, `frame-ancestors 'none'`), `Referrer-Policy: no-referrer`, `X-Robots-Tag: noindex`. - Footer: "Made with Stem · heystem.app" and "Report". - `/s/` is the built `index.html` with its `` block @@ -136,7 +156,9 @@ The browser decrypts with WebCrypto and `DecompressionStream('gzip')`. - IPC: `share:preview(source, opts)`, `share:create(source, opts)`, `share:list()`, `share:revoke(id)`; `source = {kind:'chat', threadId} | {kind:'mail', conversationId}`, `opts = {scope: 'thread'|'pair'|'answer', - anchorId, includeAttachments?, includeModel?, ttlDays?}`. + anchorId, includeAttachments?, includeModel?, ttlDays?, draftId?}`. The + preview answers with a `draftId`; `share:create` publishes that draft and + refuses a call without one (an older client is told to update). ## Desktop UI @@ -148,7 +170,40 @@ The browser decrypts with WebCrypto and `DecompressionStream('gzip')`. preview card (editable title and description, drawn like an unfurl, with a note that it is not encrypted), Create link. Then: the link with Copy, its end date, and Revoke. Without a verified address, the dialog explains and links to Settings → Your email address. -- Settings → Your email address → "Shared links": list, copy, revoke. +- Settings → Features → Shared links: one row with the count. It opens a + searchable list (newest first, a clock on links that stop within 3 days); + each link opens its own page with Copy and Revoke, and for a locked link + the recipients and who opened it. + +## Locked to chosen people (2026-11-09) + +A link can name the people who may open it ("Only people I choose" in the +dialog). Decided with Vlado: + +- **The sharer sends the link.** The relay never mails the link itself, so it + cannot become a spam channel for arbitrary addresses. +- **Link + inbox.** The key stays in the fragment. The relay hands out the + blob only to a browser that entered a code it mailed to one of the + recipients. A forwarded link shows nothing; the relay still cannot read + the page. +- **A verified browser stays in for 7 days** (an HttpOnly cookie scoped to + that one share). +- **Stem says when someone opens it.** The server asks the relay every 10 + minutes (and when the Settings list opens) who opened its locked links, + stores it in shares.json, and posts a private mail ("martin@… opened the + link you shared") for each recipient's first opening. Who was told is + stored apart from the openings (`notified`), so a notice that failed goes + out on the next check. +- The visitor picks a masked address (`m•••@gmail.com`) by index, so the page + never shows full addresses. The relay keeps the recipients in the clear + while the share lives; revoking deletes them with the blob. +- The link-preview card starts off for a locked link (it is not encrypted). +- An old relay ignores `to` and would make the link public. The upload answer + echoes the recipients; when it does not, Stem deletes the share and says + nothing was shared. +- iOS still makes public links only. + +Protocol: relay/PROTOCOL.md, "Locked to recipients". ## Phase 2: iOS @@ -158,6 +213,6 @@ phone at first, so the sheet shows what is included (counts, pictures off). ## Not doing -- Live links, comments, view counts. +- Live links, comments, view counts for public links. - Server-side moderation of content (we can't read it). -- Per-recipient shares: that's inter-Stem mail. +- Mailing the link from the relay (the sharer sends it; see above). diff --git a/docs/user/browser-control.md b/docs/user/browser-control.md index 76071282..2d746f8e 100644 --- a/docs/user/browser-control.md +++ b/docs/user/browser-control.md @@ -75,6 +75,11 @@ The same two places as computer control, and a conversation gets it from exactly that bar ends the run. - There are no approvals per action. Leave the switch off if this Stem server is not yours alone. +- Stem never types passwords, one-time codes, PINs or card details; it tells you and + waits. A bank account number (IBAN) is not a secret: it fills one in when you ask. + On a form it picks the details that fit, private email and phone for a private + matter and work ones for work, and asks when it can't tell. Computer control + follows the same rules for passwords, codes, card details and IBANs. Web pages can contain text written to mislead an assistant. Stem is told never to follow instructions found on a page and to act only on what you asked, but a page is diff --git a/docs/user/chats.md b/docs/user/chats.md index c7d7c6e7..6c39e17c 100644 --- a/docs/user/chats.md +++ b/docs/user/chats.md @@ -15,7 +15,11 @@ there: ## Ask - Drop a file on **This chat** for one message. Drop it on **Files** to copy it into - Stem for reuse across chats. + Stem for reuse across chats: **Top level**, or one of your Files subfolders shown as + tiles. When there are more subfolders than fit, the recent ones show, and the last + tile ("12 more…") lets you pick any folder after the drop. +- Click a picture you attached to open it full-window. **Esc**, a click beside it or + **✕** closes it. This works for pictures in mail too. - Choose model, effort, and speed. - Each chat is **MDX** or plain **Markdown**. In an MDX chat, answers can include charts, tables, side-by-side comparisons, KPI tiles, diagrams, step lists, tabs, @@ -39,13 +43,32 @@ there: - Web answers include cited sources: the sites' icons show under the answer; open them for a card per source. - Places in an answer (an address, a shop, a venue) are links that open Maps. -- The context meter shows how full the conversation is. +- The context meter shows how full the conversation is. In a narrow window the + controls under the message box stay on one row by giving things up: the context + meter goes first, then the button labels, then **Note** and **Record** (both stay + in the `/` menu), then the model name. The arrow beside it still opens the model + picker. +- File paths in an answer are links. A click opens a document, a picture, a sound, + a video or a web page in Stem's own viewer window, or in its usual app; anything + else (a folder, a program, a script) is only shown in Finder (Explorer on Windows). + Right-click for **Open**, **Show in Finder** and **Copy Path**. Links to files in + your Files or in the chat's scratch folder work the same when Stem runs on a + server: Stem fetches the file first, and **Show in Finder** saves a copy to + Downloads. +- A change shown as a diff gets a diff view: removed and added lines tinted, line + numbers, and the changed words marked. Switch between **One column** and **Side by + side** in its header, or **Copy diff**. +- When Stem shares a sound (a recording it cut, a clip it made), it appears under the + answer as a player: play and pause, a waveform you can click or drag to seek, and + **Save to Downloads**. - Ask for a picture and Stem draws it with your ChatGPT subscription (see [Settings → Image generation](settings.md#image-generation)). Click it to enlarge. Under each picture, or on right-click: **Save to Downloads** (straight into your Downloads folder, no dialog) and **Copy**. On the phone, tap the picture and use **Share**, which has Save Image. To change a picture, just say what to change; - to edit a photo, attach it and say what to change. Stem can also save a picture + to edit a photo, attach it and say what to change, or name a picture that is + already in your Files or a connected folder ("use the logo in my project's art + folder"). Stem can also save a picture for you: "put it in my project's art folder" writes it to Files or to a folder you connected read & write, on its own computer when it lives on one (that computer must accept commands). @@ -63,7 +86,9 @@ there: **Archive instead**. Tasks scheduled from the chat stay: they run on their own and report by mail. - **Archive** (`⌘⇧A`, `Ctrl+Shift+A`) moves a chat out of the list into the folded - **Archived** section at its foot. Nothing is lost: an archived chat still opens and + **Archived** section at its foot. Archiving the open chat opens the next one in the + list (the one above when it was the last), so you can work through a run of chats + one after another. Nothing is lost: an archived chat still opens and shows up in search, with an archive badge. Right-click it and choose **Move out of archive** to bring it back, or just continue it: a new message brings it back on its own. @@ -92,7 +117,8 @@ model as chat subjects (**Settings → Models → Quick tasks**). The app's menu bar lists every action that has a shortcut, with its keys beside it, so it is a good place to learn them. **File** has new chat, new mail, Quick Chat and **Attach Files…**. **View** opens the side panel's tabs (**Chats**, **Memory**, -**Tools**, **Personas**, **Sources**, **Scheduled Tasks**). **Chat** has Stop, +**Tools**, **Personas & People**, **Sources**, **Scheduled Tasks**) and has **Actual +Size**, **Zoom In** and **Zoom Out** for the main window. **Chat** has Stop, effort, Fast, **Archive**, **Snooze…**, read or unread, and **Delete Chat…**. **Window** lists the first nine chats under ⌘1–9 (Ctrl+1–9). **Settings** and **Check for Updates…** are under **Stem** on a Mac and under **File** on Windows and @@ -130,7 +156,8 @@ Type `/` at the start of a message to see the commands the box understands: condenses a long chat's history so it takes less room, and says by how much ("142k → 31k tokens"). Add a focus to say what the condensed version must keep: `/compact keep the deployment steps`. It cannot run while an answer is still -being written. +being written. Only what you type starts a command: text you paste at the start of +the box is sent as it is, even when it begins with `/` or `//`. Each chat keeps its selected model and effort. Changing them in one chat does not rewrite earlier answers. diff --git a/docs/user/connected-folders.md b/docs/user/connected-folders.md index 199aa6eb..61f3e9be 100644 --- a/docs/user/connected-folders.md +++ b/docs/user/connected-folders.md @@ -93,6 +93,16 @@ cloud model receives the excerpts it processes and may add provider usage cost. **Full history** shows an estimate before it starts, and the button reads **Save and start**. A document's "I" or a name in a file is not taken to be you. +A fact learned from a file starts **unconfirmed**. Stem finds it when it searches its +memory for an answer, but does not bring it up on its own. To change that for one fact, +confirm or pin it in [Memory → Facts](memory/facts.md) (the **Unconfirmed** filter lists +them). + +The **Claude Code** folder has two choices, **Off** and **On use**. With **On use** Stem +reads Claude Code's memory notes as they are added or changed. A session transcript +teaches Stem only when an excerpt of it comes up in a chat; the transcripts are never +sent through the learning model in bulk. + Learned facts remain if their source file is deleted. On disconnect, Stem asks whether to forget facts learned from that folder; pinned facts are kept. diff --git a/docs/user/mail.md b/docs/user/mail.md index 7537fcc1..cfa7c4b6 100644 --- a/docs/user/mail.md +++ b/docs/user/mail.md @@ -25,7 +25,9 @@ control) are not built in. You make them in the Personas tab. ## The Personas tab -The list groups personas by what they run as: **Assistants**, **Coding agents** and +Open **Personas & people** in the side panel and choose **Personas** at the top +(**People** is the list of real people in your life; see +[Memory](memory/README.md#people)). The list groups personas by what they run as: **Assistants**, **Coding agents** and **Computer control**. **New** starts one of each kind. Click a persona to edit it; its header has buttons to duplicate it and, for your own personas, **Delete persona**. Nothing changes until you press **Save**. Three tabs: @@ -66,14 +68,27 @@ To let Normal use one of them, add it to the conversation yourself. ## Write and read mail -**New mail** (`⌘⇧N`) starts addressed to whoever your last mail went to. In +**New mail** (`⌘⇧N`) opens as one letter: **To** and **Subject** lines on top, your +message below, and the attach, dictation, discard and Send buttons underneath. It +starts addressed to whoever your last mail went to. In **To**, type a persona's name to add it. The first one leads: it gets your mail and answers you. Click the crown on another to make it lead. The subject is optional; Stem names the conversation after the first reply. **Private** in the header makes the whole conversation private: nothing in it is saved to memory or read from it, and the personas keep no notes of it. It is fixed once sent. Send -names the lead ("Send to Normal"). Closing the pane keeps an unsent draft, which -waits as a **Draft** row at the top of the Inbox; **Discard** asks first. +names the lead ("Send to Normal"); `⌘↵` (Ctrl+Enter) sends too. Closing the pane +keeps an unsent draft, which waits as a **Draft** row at the top of the Inbox; the +trash button (**Discard this draft**) asks first. + +Attachments start uploading the moment you add them, so Send does not wait for +them. A file still uploading shows a spinner; one that failed shows a warning and +is tried again when you send. + +Sending works like email: the mail closes and the conversation goes to **Sent**. +It comes back to the Inbox when the reply arrives. A reply you send closes its +conversation the same way. If a send fails, the mail stays open with your text and +the error. Every mail you write gets a reply, even one that asks nothing; then the +reply is a short line that shows it was read. A conversation reads newest first. The reply box sits on top, under the header, and says who gets your reply. Each conversation keeps its own reply draft. While @@ -88,13 +103,15 @@ other mail just waits for the run to end. A reply the server refused stays in th with Retry, Edit and Delete, so its text is never lost. **Forward** sends a mail on to other personas with a note of your own. -The Inbox lists **Waiting on you** first, then **Working** (conversations you -sent that personas are still on), then **Requests** (first mail from people on -other Stems you haven't accepted yet), then the folded **Snoozed**, **Archived** and -**Sent** sections. A run that needs your approval for a command waits in its -mail with **Allow once** and **Deny**. You can also answer in words in the reply -box instead. Once you answer, the conversation moves out of **Waiting on you** to -**Working**. The reply and compose boxes have the dictation mic too. +The Inbox lists the mail waiting on you first (unread in bold), then **Requests** +(first mail from people on other Stems you haven't accepted yet), then the folded +**Snoozed**, **Archived** and **Sent** sections. Conversations the personas are +still working on wait under **Sent** until their reply lands. A run that needs your +approval for a command waits in its mail with **Allow once** and **Deny**. You can +also answer in words in the reply box instead. Once you +answer, the run carries on. The reply and compose boxes have the dictation mic too. + +Click a picture attached to a mail to open it full-window. ## Agents diff --git a/docs/user/memory/README.md b/docs/user/memory/README.md index 48ef82ad..c4daafde 100644 --- a/docs/user/memory/README.md +++ b/docs/user/memory/README.md @@ -34,7 +34,14 @@ with every chat that can see your memory. It is at the top of **Memory → Facts later rewrites keep your corrections. **Rewrite** starts over and drops them, after asking. - It leaves out sensitive details (health, money, addresses) and facts learned - from connected folders. + from connected folders. Facts from the **Claude Code** folder are the exception: + they come from your own sessions there, so they count like facts from your chats. +- The one exception is **Current situation**, the first section: where you are + and what you are in the middle of right now, such as a hospital stay, recovery + after an operation, or a trip, with its dates. It names the circumstance, not + your medical details, so that an answer never ignores it. It is rewritten as + soon as Stem learns that the situation changed, and it is left out of mail + with other people. Edit the summary to remove or correct it. - It describes you; it never overrides your custom instructions. - Private chats and personas without memory access never get it. The switch on the card turns it off everywhere. @@ -43,6 +50,32 @@ Connected folders can also teach Stem facts. **Remember what it reads** allows r **Learn facts** chooses when learning happens. See [Connected folders](../connected-folders.md). +## People + +Memory also learns about the people in your life, not only about you: "Peter uses +Linux", "Jana is my accountant". Contact details, payment details and how far to +trust someone are kept only when you said them yourself, never from someone else's +words. + +**Personas & people → People** in the side panel lists who is who. Each person has +a card with **Who they are to you**, **Also called** (nicknames and other spellings), +**Stem address**, **Email**, **Other ways to reach them** and **Notes**, and a +**Facts** tab with every fact that names them. **+** (**New person**) adds someone; +nothing is saved until you press **Save**. + +When a chat or mail names a person on the list, Stem gets their card, your notes +and the facts about them with that message, even when the message reads nothing +like those facts ("write Peter how to install the VPN" brings "Peter uses Linux"). +A fact belongs to a person when it names them, so add the names you use for them +under **Also called**. Sensitive facts about a person still need a close match to be +sent. Private chats and personas without memory access get none of this. + +Stem also suggests people your memory already names. Suggestions wait under +**Suggested** and are not used until you accept one with the check button (**Add +to People**); the +sparkle button in the header (**Suggest people from memory**) asks for suggestions +right away. No card is ever made from what someone on another Stem wrote to you. + ## Models, and machines that cannot reach the internet Searching memory by meaning needs language models that run inside Stem — nothing diff --git a/docs/user/memory/facts.md b/docs/user/memory/facts.md index 3d7c71a8..6edbabf6 100644 --- a/docs/user/memory/facts.md +++ b/docs/user/memory/facts.md @@ -33,6 +33,8 @@ answer** when two facts disagree, then the facts themselves. **History** and itself is only ever shown to you, in the fact's details; the assistant sees the text. The source appears on each fact. One-off completed task details are normally skipped. +Facts can be about the people in your life as well as about you; see +[People](README.md#people). ## Review stored facts @@ -89,8 +91,23 @@ it as uncertain rather than forgetting both. Selected facts go to the model used for that chat—local or cloud. +Next to the facts, Stem can send a few **broader memories**. In the background it +files related facts into groups ("knee surgery and recovery", "the Northwind +contract") and writes each group a short summary from its facts. When a group is +close to your message, its summary goes along with the facts, so the answer sees +the wider picture and not one detail alone. A summary is sent only while it still +matches its facts: forgetting a fact clears the summaries of its groups, and +erasing facts erases them all. A group built from a sensitive fact needs a much +stronger match. + +Each chat that can see your memory is also told which topics your memory holds, +one short label per group, so the assistant knows when searching its memory will +find something and searches before asking you. A topic that holds a sensitive fact +shows only as its category ("Private: health"), and the list is left out of mail +with other people. + Use **Preview draft** (the eye button above the list) to see which facts the current -message would use. +message would use, and which broader memories would go with them. ## When two facts disagree diff --git a/docs/user/quick-chat.md b/docs/user/quick-chat.md index c883d849..7ab1d8e1 100644 --- a/docs/user/quick-chat.md +++ b/docs/user/quick-chat.md @@ -69,6 +69,18 @@ not on top of it, with a chip showing which window it captured. She asks - Pressing it in a window whose panel is open puts you back in that panel; pressing it while typing in a panel closes that one. Pressing it again in a window you asked about earlier continues that window's conversation. +- **+** in the panel's header (**New tab about this window**, `⌘T`) starts another + conversation about the same window, as a tab, with a fresh picture of it. A + window holds up to five tabs. Each tab is named after its first question; a dot + marks one that is answering or has a new answer. `⌘W` closes the tab you are in + (stopping its answer), and `⌘⇧[` / `⌘⇧]` go to the tab before or after. On + Windows and Linux, use Ctrl. +- **Shrink** in the header, or `⌘M`, shrinks the panel to a small pill beside its + window and gives the keyboard back to that window. Clicking back into the window + while an answer runs does the same. The pill shows the answer's progress; click it + to open the panel again, with your draft and the conversation as you left them. +- On a Mac, a window that floats above the others, such as an app's hotkey + window, counts as the window in front. - On a Mac it needs **Screen Recording** for the picture and **Accessibility** for the text. If one is off, the chip says which and opens the right System Settings pane. On Windows it needs no setup. On Linux it needs the GNOME @@ -79,5 +91,10 @@ off until you record one. On GNOME (Wayland) apps can't set global shortcuts: copy the command shown there and add it as a custom shortcut in GNOME's Keyboard settings. +On a Mac, **Keep with its window** below the shortcut makes a panel behave like +part of its window instead of floating over everything: other windows can cover +it, it comes forward with its window, and it hides while that window is minimized, +hidden or on another Space, then comes back with it. It is off by default. + Quick Chat has its own thread. Set its defaults in [**Settings → Quick Chat**](settings.md). diff --git a/docs/user/scheduled-tasks.md b/docs/user/scheduled-tasks.md index 0fc6024b..e6b46df4 100644 --- a/docs/user/scheduled-tasks.md +++ b/docs/user/scheduled-tasks.md @@ -95,6 +95,9 @@ Deleting a task keeps its mail in the Inbox; the hidden threads its runs left be are removed. A failure's reason is also in the log (`stem.log` in Stem’s state folder), which is where to look if the task is gone. -To replace the instruction or timing, edit the task here, or ask Stem in the chat -that created it to cancel the task and create a new one. Deleting that chat leaves -the task in place. +To change the instruction or timing, edit the task here, or ask Stem in any chat +("sign the Monday report as Stem", "move the backup check to 7:00", "pause the +weekly film search"). Stem sees all your tasks from any chat, whichever chat +scheduled them, except the tasks of private chats and private mail. It changes the +task in place; the **Prompt** tab then says *Edited by Stem in a chat* with **Revert +to the original**. Deleting the chat a task came from leaves the task in place. diff --git a/docs/user/settings.md b/docs/user/settings.md index e53c898c..235db5ed 100644 --- a/docs/user/settings.md +++ b/docs/user/settings.md @@ -19,6 +19,16 @@ address, shared links, image generation, commands, coding agents, computer contr browser control), **Server** (where Stem runs, your devices, moving or backing up) and **Models** (providers, which model does which job, memory recall, web search). +## Search settings + +**Search settings**, the field above the four tabs, finds a setting by its name, the +line under it, or the text of its ⓘ explanation, across all four tabs. When you open +Settings yourself (⌘, or Ctrl+,, the menu, or the side-panel button), the cursor is +already in it. Matches found only in an explanation are listed under **In +explanations**. Click a result, or pick one with the arrow keys and Enter: Stem +switches to its tab, opens the groups it sits in and scrolls to it. **Esc** clears +the field; a second **Esc** leaves it. + ## Providers and models Add a provider with: @@ -41,6 +51,12 @@ is red when the last check got no answer, and the page says why. A server that stops answering keeps the models it listed last, so a chat already on one of them does not lose its model. +With a ChatGPT sign-in, the **ChatGPT** tile shows how much of your plan's usage is +left ("5h 62% · week 80% left"). Its page has a bar for each limit, **5-hour limit** +and **Weekly limit**, with the percentage left and when it resets. The bar changes +colour as a warning at 25% left and again at 10%. If Stem cannot read the figures, +**Plan usage** on the page says why. + ### A model server on your Mac, with Stem on a server When Stem runs on a server and LM Studio or Ollama runs on your Mac, set **Runs @@ -106,7 +122,8 @@ runs on now, and a role left unset follows its group: the Deep check), **Skills** (writes skills, `/learn`, skill tidy-up) and the **Command safety check**'s review. Unset, they follow the model you chat with. - **Quick tasks** — small jobs a fast model does well: chat subjects, filing chats into - folders, and the safety check's quick first pass. + folders, picking which of your skills a message needs, and the safety check's quick + first pass. **Memory recall**, below the roles, sets how many facts go with each message and the models that pick them (see [Memory](memory/README.md#models-and-machines-that-cannot-reach-the-internet)). @@ -155,7 +172,7 @@ to you; it wins over everything else), and **About my setup** (which machines, f and services are yours and how much they matter). A command may run for up to an hour; longer jobs are started in the background and -checked on. +checked on. Up to eight commands run at the same time; further ones wait their turn. On an approval card, **Always allow** saves a command prefix for future turns. Keep prefixes narrow; `git status` grants less access than `git`. Approval cards @@ -338,7 +355,8 @@ image used as a starting point, go to OpenAI, even in a private chat. Under **Settings → App → Appearance**, set per computer: - **Theme** — **System** follows the OS; the others include Catppuccin, Gruvbox, - Solarized, Nord, Rosé Pine, One, Everforest, Kanagawa and Dracula. For a theme with + Solarized, Nord, Rosé Pine, One, Everforest, Kanagawa, Dracula, TokyoNight Storm and + Cotton Candy (pink, light and dark). For a theme with both palettes, **Light or dark** picks **Follow the OS**, **Always light** or **Always dark**. **Themes folder** opens the folder where you can add your own; copy `_example.json` to start one. @@ -347,6 +365,10 @@ Under **Settings → App → Appearance**, set per computer: - **Translucent sidebar** (macOS) — lets the desktop show through the toolbar and side panel. +To make everything in the main window bigger or smaller, press ⌘+ (or ⌘=), ⌘- and +⌘0 for actual size; on Windows and Linux, Ctrl with the same keys. The same items are +in the **View** menu. Stem remembers the zoom. Quick Chat keeps its own size. + ## Dictation The mic button in the composer turns speech into text on your own computer; the @@ -400,6 +422,10 @@ are added on top of the standing instructions. **Show on all displays** lets the overlay follow Spaces and displays. **Show progress on other Spaces** can also show progress for the main Stem window. +**Keep with its window** (Mac, under **Ask about this window**; off by default) keeps +an [Ask about this window](quick-chat.md#ask-about-this-window) panel with the window +it is about instead of floating over everything (see that page). + **Skip the Inbox** sends quick chats straight to **Archived** once answered, so a throwaway question never waits in the Inbox. **Open in Stem** brings the conversation back to the Inbox, as does continuing it from the main window. diff --git a/docs/user/share-links.md b/docs/user/share-links.md index 690bdecf..36c01599 100644 --- a/docs/user/share-links.md +++ b/docs/user/share-links.md @@ -42,14 +42,40 @@ the link can read what you see there. Then: Press **Create link**. Stem copies the link to the clipboard and shows it with **Copy link**, **Open in the browser** and **Revoke**. +## Only people you choose + +**Who can open it** in the dialog is **Anyone with the link** by default. Pick +**Only people I choose** and type their email addresses, separated by commas (up +to 20). Then: + +- You send the link yourself. Stem does not mail it to anyone. +- To open the page, a person picks their address (shown partly hidden, like + `m•••@gmail.com`) and presses **Send a code to …**. The share server mails them a + six-digit code that works for 15 minutes; they type it and press **Open**. That + browser then stays unlocked for that link for 7 days. +- A forwarded link shows nothing to anyone else, and the page is still encrypted, + so the share server cannot read it. +- Stem tells you when each person opens it for the first time, with a private mail + ("Shared link opened: …"), and the link's page in Settings lists who opened it + and when. +- The preview card starts switched off, since it is not encrypted. You can switch it + on. + +Links for chosen people are made on the computer. The iPhone app makes public links +only. + ## What is left out Tool steps, memory cards and in-app links are left out. Links to places inside Stem keep their words as plain text. Suggested replies, notices about failed turns and messages that failed to send stay out too. In mail, only the mails between you and your personas are shared: the personas' mail to each other and -approval cards stay out. Pictures Stem made are included, and so are web -sources. +approval cards stay out. + +The page shows an answer as the chat shows it. Pictures Stem made, web pictures +the answer shows, sounds it shared and its web sources are all included. The +page has no Stem behind it, so Stem copies them into the link when you make it. +A link to a file on your computer shows as its text. A private chat can be shared. Private only means Stem doesn't learn from it. @@ -79,11 +105,18 @@ The link is published under your verified address. ## Take a link down -Settings → Features → **Shared links** → **Public links you made** lists your -working links with what they share and their end date. The section appears once -you have made a link. Each row has **Copy link** and a revoke button (**Revoke — -the link stops opening**). A revoked link opens as *This link was turned off*. -Anyone who already saved the page keeps their copy. +Settings → Features → **Shared links** → **Links you shared** opens the list of your +working links, newest first, with what each shares and when it stops. The section +appears once you have made a link. **Find a link or a person** searches by title or +by an address a link was shared with. A clock marks a link that stops within three +days; an eye marks one that people you chose have opened. + +Click a link to open its page: what it shows, where it came from, when it was +shared, **Works until**, and the link itself. For a link shared with chosen people, +**Who can open it** lists each address with when they first opened it, or *Not +opened yet*. The header has **Copy link** and **Revoke link**, which asks first. A +revoked link opens as *This link was turned off*. Anyone who already saved the page +keeps their copy. Each shared page also has a **Report** button for readers. A link taken down after a report opens as *This link was removed*. diff --git a/docs/user/shortcuts.md b/docs/user/shortcuts.md index d4e78b84..172f4a3b 100644 --- a/docs/user/shortcuts.md +++ b/docs/user/shortcuts.md @@ -45,4 +45,12 @@ Everything Stem binds to a key, and a few composer tricks that no keycap adverti range, then mark, move or delete them together. **Esc** clears the selection. - Drop a file on **This chat** to use it for one message. Drop it on **Files** to copy it into Stem and reuse it across chats. -- **Enter** sends. **Shift+Enter** starts a new line. +- **Enter** sends. **Shift+Enter** starts a new line. In mail, **Enter** starts a new + line and **⌘↵** (**Ctrl+Enter**) sends. +- **⌘+** (or **⌘=**), **⌘-** and **⌘0** zoom the main window in, out and back to actual + size; on Windows and Linux use **Ctrl**. Stem remembers the zoom. Quick Chat keeps its + own size. +- In an **Ask about this window** panel: **⌘T** opens another tab about the same + window, **⌘W** closes the tab you are in, **⌘⇧[** and **⌘⇧]** switch tabs, and + **⌘M** shrinks the panel to a pill beside its window. Use **Ctrl** on Windows and + Linux. diff --git a/docs/user/tools/mcp-servers.md b/docs/user/tools/mcp-servers.md index 5ad6c620..84046734 100644 --- a/docs/user/tools/mcp-servers.md +++ b/docs/user/tools/mcp-servers.md @@ -129,6 +129,18 @@ works. A URL server that runs on your Stem server signs in as it always has. - When Stem proposes a server, verify the URL or command in the approval card. Reject anything unexpected. +Stem can also change a server you already have, when you ask it to fix or update one. +The card, **Change MCP server**, shows only what changes, old next to new: the +command, the URL, environment variables and headers set or removed. Values of +secrets stay hidden. Everything not listed, stored tokens and sign-ins included, +stays as it is. When the change points the server at a new URL or command, **Goes +along** names the stored secrets the new one will get; approve only if you trust it +with them. + +A server Stem builds or downloads for you is kept in a folder of its own inside +Stem's tools folder, never in a chat's scratch folder or in your Files, so deleting a +chat or tidying your Files cannot break it. + The switch in a server's header stops connecting but keeps the configuration and sign-in. **Remove server** removes both. diff --git a/docs/user/tools/skills.md b/docs/user/tools/skills.md index 1d79df1f..c8db96d6 100644 --- a/docs/user/tools/skills.md +++ b/docs/user/tools/skills.md @@ -15,6 +15,16 @@ Skills are reusable procedures: when to use a workflow, its steps, and how to ve the result. Not memories. They provide no accounts, tools, or permissions by themselves. +A skill can also hold how you want a recurring job done for you. Tell Stem "sign my +email drafts as Stem, on behalf of me" or "write to my doctors formally, from my Gmail +address", and it saves that in a skill for drafting your mail rather than in your +custom instructions. Every chat and scheduled task that drafts mail then follows it, +and later corrections update the same skill. Stem also proposes one on its own after +it drafts a message for you, under the **Saving skills** setting. When Memory learns +how you want a kind of work done ("always put the invoice number in the subject"), +Stem folds that into the skill for that work too; a mere taste or a one-off stays a +fact. + Open **Tools → Skills**. @@ -25,12 +35,29 @@ Open **Tools → Skills**. - Click a skill to select it, then the trash button under the list deletes it for good — it asks first. This works on skills you wrote yourself too: on a server install the skills folder is on the server, so this is the only way to reach it. +- The history button under the list shows the earlier versions of the selected + skill, each with the reason it changed. Pick one and press **Restore** to put it + back. The current text is kept as an earlier version, so a restore can be undone. + Stem keeps the last ten versions of each skill. +- **Needed** appears under the list for a selected skill that Stem wrote. It says + how often the task comes up: every week, every month, a few times a year, once + a year, or now and then. Stem estimates it when it writes the skill, and you can + change it. Stem switches a skill off by itself only after several of those + periods without use (60 days for a weekly task, 150 for a monthly one, 400 for + a few times a year, 800 for a yearly one, 90 for one with no rhythm), so a + yearly task is still there the next year. A skill switched off this way stays + on disk and can be switched back on. - **Tidy up** keeps one skill per job: it splits a skill that grew to cover several - unrelated jobs, merges two write-ups of the same job, and archives ones untouched - for 90 days. Archiving is the same reversible switch as above, so an archived - skill can be switched back on. Anything it rewrites is backed up first. -- **Saving skills** decides how much Stem may save on its own. Asking it to save - one always works, whichever you pick. + unrelated jobs, merges two write-ups of the same job, and merges skills that are + one procedure written once per app, server or account into a single skill that + lists what differs for each. It also switches off skills unused for longer than + their **Needed** answer allows. Archiving is the same reversible switch as + above, so an archived skill can be switched back on. Anything it rewrites is + backed up first. Stem runs the same pass by itself once a day. +- **Saving skills** decides how much Stem may save on its own: **Only when I ask**, + **Ask first** (each proposal comes as a card you approve) or **Save automatically** + (Stem saves what it learns and the Skills list shows it), which is the default. + Asking it to save one always works, whichever you pick. - **Skills model** does the model-driven skills work: writing, `/learn`, tidy-up. It is also under **Settings → Models → Judgment work**. @@ -38,17 +65,42 @@ An **auto** label marks a skill Stem created. Usage details show whether it is s useful. Stem reshapes only skills that were its own idea, including ones you accepted from a proposal card; it may change or split those without asking. Skills you asked it to save, skills you imported or added yourself, `/learn` skills and recorded skills are -never rewritten by tidy-up, and Stem changes them only when you ask. +never rewritten by tidy-up or by the rewrite below. Stem changes them only when you ask, +or when you correct a result that followed one. Imported skills never change that way. A cloud curator receives relevant chat excerpts during collection and auto-skill text during upkeep. It may use provider quota. Keep skills narrow and verifiable. Disable an auto skill to stop Stem using it. +## How skills improve + +Each time a skill is used, Stem keeps a short record of that use: your request, what +Stem did, and how you took the result in your next message. It reads that from your +next message in the background, with the memory pass that already reads it, so this +costs no extra model call per message. + +- When you correct a result ("no, sign it as Stem"), Stem changes the skill that + produced it, with your correction as a step. +- When three uses of a skill went wrong, Stem looks at all of its records at once, + works out which steps caused the trouble, and rewrites the skill. This applies only + to skills that were Stem's own idea. +- Before Stem saves any change it made on its own, a separate check compares the new + text with the old one and with the records. A change that would break what worked + before, or that only fits one case, is not saved. + +The Skills list shows the result as "5 accepted · 1 needed a fix". The **Saving +skills** setting applies to all of this: **Only when I ask** stops it, and **Ask +first** shows each change as a card. + +The records need Memory on. Private chats, scheduled runs and personas without memory +leave no record, and deleting a chat deletes its records. + ## Recording a skill Recording is in **Alpha**. On the Mac app, press **Record** under the message box -(or type `/record`, or ⌃⌥R) and do the task in your own apps as usual; press **Stop** when done. Stem +(or type `/record`, or ⌃⌥R; in a narrow window the button gives way and only these +remain) and do the task in your own apps as usual; press **Stop** when done. Stem notes what you click, type and switch to, plus the settings of any dialog you confirm, and writes a draft skill card in the chat. It may ask up to three questions in the card; answer in a sentence. **Save skill** adds it to your library. @@ -80,6 +132,13 @@ is not. A skill already used earlier in the same chat is not loaded again. The **used N×** figure on the Skills list is a different, stricter count: it credits a skill only when the turn ran something the skill's steps name. +A skill can also belong to a tool, such as your mail-drafting skill to the tool that +writes drafts. Then Stem reads it just before it uses that tool, however your request +was worded, so how you want that action done is followed even when the message +looked unrelated. The Skills list shows this under the skill's name: *Read before +fastmail · draft_email*, or *Read before any busycal tool*. A skill that does not fit +the job at hand is ignored. + ## Skills and the machine they run on A skill is followed later, possibly somewhere else: your library travels with Stem when you diff --git a/electron.vite.config.ts b/electron.vite.config.ts index 8c5540fe..c3ce2445 100644 --- a/electron.vite.config.ts +++ b/electron.vite.config.ts @@ -13,6 +13,7 @@ const systemVersion = JSON.stringify(computeSystemVersion(rootDir)); const mainAssets = [ ['src/server/pi/stem-mcp-extension.mjs', 'dist/main/pi/stem-mcp-extension.mjs'], ['src/server/pi/mcp-discovery.mjs', 'dist/main/pi/mcp-discovery.mjs'], + ['src/server/pi/mcp-install-paths.mjs', 'dist/main/pi/mcp-install-paths.mjs'], ['src/server/pi/image-gen.mjs', 'dist/main/pi/image-gen.mjs'], ['src/server/pi/pi-node-shim.mjs', 'dist/main/pi/pi-node-shim.mjs'] ] as const; @@ -37,11 +38,41 @@ function copyMainRuntimeAssets() { }; } +/** + * electron-vite 6 appends a "CommonJS Shims" block to every ES chunk that + * mentions require/__dirname/__filename, declaring them with `const`. Rolldown + * (Vite 8) does not rename bundled top-level bindings around that block the way + * Rollup did, so a bundled dependency's own `var require = createRequire(...)` + * (acpx → @openclaw/fs-safe) became "Identifier 'require' has already been + * declared" and stem-server would not start. Turning the shim's `const` into + * `var` makes both declarations legal; they bind the same thing. + */ +function relaxCjsShim() { + return { + name: 'stem:relax-cjs-shim', + apply: 'build' as const, + enforce: 'post' as const, + renderChunk(code: string): { code: string; map: null } | null { + const start = code.indexOf('// -- CommonJS Shims --'); + if (start < 0) return null; + const end = code.indexOf('createRequire(import.meta.url);', start); + if (end < 0) return null; + const block = code.slice(start, end).replace(/\bconst (__filename|__dirname|require) =/g, 'var $1 ='); + return { code: code.slice(0, start) + block + code.slice(end), map: null }; + } + }; +} + export default defineConfig({ main: { - plugins: [copyMainRuntimeAssets()], + plugins: [copyMainRuntimeAssets(), relaxCjsShim()], define: { __STEM_SYS_VERSION__: systemVersion }, build: { + // electron-vite 5+ externalizes every package.json dependency by default; + // Stem bundles them (only the `external` list below stays out), as + // electron-vite 4 did. The server image and server-boot run dist/main + // without those packages beside it. + externalizeDeps: false, outDir: 'dist/main', rollupOptions: { // index is the Electron main process: src/desktop, which starts the @@ -117,6 +148,7 @@ export default defineConfig({ }, preload: { build: { + externalizeDeps: false, outDir: 'dist/preload', rollupOptions: { input: 'src/preload/index.ts', @@ -135,8 +167,11 @@ export default defineConfig({ // main / Quick Chat / HUD. There was a second (mobile.html, the phone's // web client, served over the transport); both it and the static route // that served it are gone. + // Absolute: Vite 8's dev dependency scan resolves a relative input + // against the renderer root (src/renderer), not the project, fails, and + // skips pre-bundling, which left the first dev window blank. input: { - index: 'src/renderer/index.html' + index: join(rootDir, 'src/renderer/index.html') } } } diff --git a/eslint.config.js b/eslint.config.js index 037c0290..b8b89a26 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -6,6 +6,15 @@ import reactHooks from 'eslint-plugin-react-hooks'; export default [ { ignores: ['dist/**', 'release/**', 'node_modules/**', 'scripts/**', '.recall-build/**', '.skills-build/**'] }, js.configs.recommended, + { + rules: { + // New in ESLint 10's recommended set. Every hit here was the + // `let x = fallback; try { x = ... } catch { return }` shape, never a lost + // value; rewriting them only trades the initializer for TS + // definite-assignment friction. + 'no-useless-assignment': 'off' + } + }, { files: ['**/*.{ts,tsx}'], languageOptions: { @@ -18,7 +27,11 @@ export default [ }, rules: { ...tseslint.configs.recommended.rules, - ...reactHooks.configs.recommended.rules, + // react-hooks 7's recommended set adds the React Compiler rules (refs, + // set-state-in-effect, purity, ...). Stem does not run the compiler, so + // only the two classic hook rules apply, as under react-hooks 5. + 'react-hooks/rules-of-hooks': 'error', + 'react-hooks/exhaustive-deps': 'warn', // TypeScript already checks for undefined identifiers; no-undef is noisy // and wrong for type-only globals (HTMLDivElement, etc.). 'no-undef': 'off', diff --git a/ios/README.md b/ios/README.md index 44d18fd0..d474ba1c 100644 --- a/ios/README.md +++ b/ios/README.md @@ -41,6 +41,12 @@ phone that is already paired it asks before switching servers, naming the host. Links inside replies and mail only open if they are web, mail or phone links; phone numbers in replies are linked automatically. The code is spent once and expires in ten minutes. +**Try the demo** on the pair screen opens the same tabs over sample chats and mail +(`Stem/Transport/DemoServer.swift`), for App Review and anyone without a Stem yet. Every +call goes to that in-memory stand-in instead of the network: approving a request or +sending mail plays back a prepared reply, nothing is stored, and Settings → Leave the +demo returns to pairing. + Release builds refuse plain `http://` to anything but loopback; use the `https://` address of the proxy in front of the server ([Tailscale Serve](../docs/running-on-tailscale.md) or your own). diff --git a/ios/Stem/App/StemApp.swift b/ios/Stem/App/StemApp.swift index ecc1f889..3ca7efb4 100644 --- a/ios/Stem/App/StemApp.swift +++ b/ios/Stem/App/StemApp.swift @@ -116,12 +116,22 @@ struct SettingsView: View { var body: some View { NavigationStack { Form { - Section("Server") { - LabeledContent("Address", value: session.client.creds.serverUrl) - LabeledContent("Status") { - HStack(spacing: 6) { - ConnectionDot() - Text(statusText) + if session.isDemo { + Section { + Label("You're trying the demo", systemImage: "play.circle").font(.headline) + Text("Chats, mail and requests here are sample data, forgotten when you leave the demo. Nothing connects to a server, and approving a request or sending mail doesn't do anything outside the app.") + .font(.footnote) + .foregroundStyle(.secondary) + Button("Leave the demo") { app.unpair() } + } + } else { + Section("Server") { + LabeledContent("Address", value: session.client.creds.serverUrl) + LabeledContent("Status") { + HStack(spacing: 6) { + ConnectionDot() + Text(statusText) + } } } } @@ -130,8 +140,10 @@ struct SettingsView: View { Toggle("Web search", isOn: Binding(get: { session.webSearch }, set: { session.setWebSearch($0) })) } if PhoneDictation.supported { DictationSettingsSection() } - Section { - Button("Unpair this phone", role: .destructive) { confirmUnpair = true } + if !session.isDemo { + Section { + Button("Unpair this phone", role: .destructive) { confirmUnpair = true } + } } Section { LabeledContent("Version", value: Bundle.main.infoDictionary?["CFBundleShortVersionString"] as? String ?? "") diff --git a/ios/Stem/Markdown/MdxCopy.swift b/ios/Stem/Markdown/MdxCopy.swift new file mode 100644 index 00000000..22b1392d --- /dev/null +++ b/ios/Stem/Markdown/MdxCopy.swift @@ -0,0 +1,238 @@ +import Foundation + +// What "Copy" puts on the pasteboard for a reply: plain Markdown with every +// MDX component turned into the Markdown a person would have written for it +// (a Callout a quote, Steps a numbered list, a Chart a table of its numbers). +// A port of src/renderer/mdx/copy.ts; both are checked against the *.copy.md +// files beside the shared fixtures in tests/fixtures/mdx. + +enum MdxCopy { + private static let calloutLabels = ["info": "Note", "warn": "Warning", "success": "Done", "danger": "Caution"] + + /// The reply as Markdown with no component tags left in it. + static func markdown(_ text: String) -> String { + tidy(blocks(MdxTreeParser.parse(text).blocks)) + } + + private static func blocks(_ list: [MdxBlock]) -> String { + list.map(block).filter { !$0.trimmingCharacters(in: .whitespacesAndNewlines).isEmpty }.joined(separator: "\n\n") + } + + private static func block(_ b: MdxBlock) -> String { + guard case .component(let c) = b else { + if case .md(let text) = b { return stripTags(text) } + return "" + } + let a = c.attrs + switch c.name { + case "Callout": + let label = calloutLabels[a["type"] ?? ""] ?? "Note" + let body = blocks(c.children) + let opensWithProse = !matches(#"^(\s*([-*+]|\d+[.)])\s|#|>|```|~~~|\|)"#, body) + let text = !body.isEmpty && opensWithProse ? "**\(label):** \(body)" : "**\(label)**\n\n\(body)" + return quote(text.trimmingCharacters(in: .whitespacesAndNewlines)) + case "Steps": + return numbered(c.children.compactMap { named($0, "Step") }.map { blocks($0.children) }) + case "Collapsible", "Tab": + return titled(a["title"] ?? a["label"], blocks(c.children)) + case "Tabs": + return blocks(c.children) + case "DataTable": + return titled(a["caption"], MdxDataParse.table(c.data?.value).map(table) ?? "") + case "Chart": + var title = a["title"] + if let t = title, !t.isEmpty, let unit = a["unit"], !unit.isEmpty { title = "\(t) (\(unit))" } + return titled(title, MdxDataParse.table(c.data?.value).map(table) ?? "") + case "Stats": + return stats(c.data?.value) + case "Compare": + return compare(c.data?.value, recommend: a["recommend"]) + case "Diagram": + let source = c.data?.value.trimmingCharacters(in: .whitespacesAndNewlines) ?? "" + let lang = (c.data?.lang).flatMap { $0.isEmpty ? nil : $0 } ?? "mermaid" + return titled(a["title"], source.isEmpty ? "" : "```\(lang)\n\(source)\n```") + case "Quiz": + return titled(a["topic"], numbered(c.children.compactMap { named($0, "Question") }.map(question))) + case "Question": + return question(c) + case "Form": + return titled(a["prompt"], c.children.compactMap { named($0, "Field") }.map(field).joined(separator: "\n")) + case "Field": + return field(c) + case "FactChange": + let custom = a["label"].flatMap { $0.hasSuffix("?") ? nil : $0 } + let label = custom ?? (a["kind"] == "save" ? "Saved" : "Retired") + var line = "- **\(label):** \(a["text"] ?? "")" + while line.last?.isWhitespace == true { line.removeLast() } + if let reason = a["reason"], !reason.isEmpty { line += " (\(reason))" } + return line + case "Replies", "Reply": + return "" + default: + // Step, Choice, Option and unknown tags: their content, without the tag. + return blocks(c.children) + } + } + + private static func named(_ b: MdxBlock, _ name: String) -> MdxComponent? { + if case .component(let c) = b, c.name == name { return c } + return nil + } + + private static func question(_ q: MdxComponent) -> String { + var lines = [q.attrs["prompt"] ?? ""] + lines += q.children.compactMap { named($0, "Choice") }.map { "- " + blocks($0.children) } + if let answer = q.attrs["answer"], !answer.isEmpty { lines += ["", "Answer: \(answer)"] } + return lines.enumerated().filter { !$0.element.isEmpty || $0.offset > 0 }.map(\.element).joined(separator: "\n") + } + + private static func field(_ f: MdxComponent) -> String { + let label = f.attrs["label"] ?? f.attrs["name"] ?? "" + let options = f.children.compactMap { named($0, "Option") }.map { " - " + blocks($0.children) } + return (["- \(label)"] + options).joined(separator: "\n") + } + + private static func stats(_ raw: String?) -> String { + guard let t = MdxDataParse.table(raw) else { return "" } + return t.rows.map { r -> String in + let unit = r["unit"]?.string + let value: String + if case .number(let n)? = r["value"] { value = MdxFormat.compact(n, unit) } else { value = cell(r["value"]) } + let delta = present(r["delta"]).map { cell($0).trimmingCharacters(in: .whitespacesAndNewlines) } ?? "" + let change: String + if !delta.isEmpty { change = " (\(delta))" } + else if let previous = MdxDataParse.number(r["previous"]) { change = " (was \(MdxFormat.compact(previous, unit)))" } + else { change = "" } + return "- **\(cell(r["label"])):** \(value)\(change)" + }.joined(separator: "\n") + } + + private static func compare(_ raw: String?, recommend: String?) -> String { + guard let t = MdxDataParse.table(raw) else { return "" } + let pick = recommend?.trimmingCharacters(in: .whitespacesAndNewlines).lowercased() + func list(_ v: OJSON?) -> [String] { + switch v { + case .array(let items)?: return items.map { cell($0) }.filter { !$0.isEmpty } + case .string(let s)? where !s.isEmpty: return [s] + default: return [] + } + } + return t.rows.prefix(4).map { r -> String in + let name = cell(present(r["name"]) ?? r["option"]) + let summary = cell(present(r["summary"]) ?? present(r["bestFor"]) ?? r["best_for"]) + let picked = pick.map { !$0.isEmpty && name.trimmingCharacters(in: .whitespacesAndNewlines).lowercased() == $0 } ?? false + let head = "**\(name)**\(picked ? " (recommended)" : "")\(summary.isEmpty ? "" : ": \(summary)")" + let items = list(r["pros"]).map { "- Pro: \($0)" } + list(r["cons"]).map { "- Con: \($0)" } + return ([head] + items).joined(separator: "\n") + }.joined(separator: "\n\n") + } + + /// JS `??`: a missing key and a JSON null both fall through. + private static func present(_ v: OJSON?) -> OJSON? { + if case .null? = v { return nil } + return v + } + + private static func cell(_ v: OJSON?) -> String { + switch v { + case nil, .null?: return "" + case .array(let items)?: return items.map { cell($0) }.joined(separator: ", ") + case let v?: return v.text + } + } + + private static func table(_ t: MdxTable) -> String { + guard !t.columns.isEmpty else { return "" } + func esc(_ s: String) -> String { + s.replacingOccurrences(of: "|", with: "\\|").replacingOccurrences(of: "\n", with: " ") + } + func line(_ cells: [String]) -> String { "| " + cells.map(esc).joined(separator: " | ") + " |" } + let rows = t.rows.map { r in line(t.columns.map { cell(r[$0]) }) } + return ([line(t.columns), line(t.columns.map { _ in "---" })] + rows).joined(separator: "\n") + } + + private static func titled(_ title: String?, _ body: String) -> String { + let t = title?.trimmingCharacters(in: .whitespacesAndNewlines) ?? "" + return [t.isEmpty ? "" : "**\(t)**", body].filter { !$0.isEmpty }.joined(separator: "\n\n") + } + + private static func numbered(_ items: [String]) -> String { + items.filter { !$0.trimmingCharacters(in: .whitespacesAndNewlines).isEmpty }.enumerated().map { i, s in + let marker = "\(i + 1). " + let pad = String(repeating: " ", count: marker.count) + let lines = s.components(separatedBy: "\n").enumerated().map { j, l in j > 0 && !l.isEmpty ? pad + l : l } + return marker + lines.joined(separator: "\n") + }.joined(separator: "\n") + } + + private static func quote(_ body: String) -> String { + body.components(separatedBy: "\n").map { $0.isEmpty ? ">" : "> \($0)" }.joined(separator: "\n") + } + + private static let fenceRegex = try! NSRegularExpression(pattern: #"^\s{0,3}(`{3,}|~{3,})"#) + private static let lonelyTag = try! NSRegularExpression(pattern: #"^\s*]*)?/?>\s*$"#) + private static let codeSpan = try! NSRegularExpression(pattern: #"`+[^`]*`+"#) + private static let inlineTag = try! NSRegularExpression( + pattern: #""']|"[^"]*"|'[^']*')*)?/?>"#) + + /// Component tags left in a Markdown run (an inline , a reply that is + /// not valid MDX): the tags go, their words stay. Code is left as written. + private static func stripTags(_ md: String) -> String { + var out: [String] = [] + var fence: String? + for line in md.components(separatedBy: "\n") { + let marker = firstGroup(fenceRegex, line) + if let f = fence { + if let m = marker, m.first == f.first, m.count >= f.count, + line.trimmingCharacters(in: .whitespaces).dropFirst(m.count).trimmingCharacters(in: .whitespaces).isEmpty { + fence = nil + } + out.append(line) + continue + } + if let m = marker { + fence = m + out.append(line) + continue + } + if matches(lonelyTag, line) { continue } + out.append(stripInline(line)) + } + return out.joined(separator: "\n") + } + + /// Tags removed outside `code spans`. + private static func stripInline(_ line: String) -> String { + let ns = line as NSString + var result = "" + var at = 0 + func strip(_ s: String) -> String { + inlineTag.stringByReplacingMatches(in: s, range: NSRange(location: 0, length: (s as NSString).length), withTemplate: "") + } + for m in codeSpan.matches(in: line, range: NSRange(location: 0, length: ns.length)) { + result += strip(ns.substring(with: NSRange(location: at, length: m.range.location - at))) + result += ns.substring(with: m.range) + at = m.range.location + m.range.length + } + return result + strip(ns.substring(from: at)) + } + + private static func firstGroup(_ re: NSRegularExpression, _ s: String) -> String? { + let ns = s as NSString + guard let m = re.firstMatch(in: s, range: NSRange(location: 0, length: ns.length)) else { return nil } + return ns.substring(with: m.range(at: 1)) + } + + private static func matches(_ re: NSRegularExpression, _ s: String) -> Bool { + re.firstMatch(in: s, range: NSRange(location: 0, length: (s as NSString).length)) != nil + } + + private static func matches(_ pattern: String, _ s: String) -> Bool { + s.range(of: pattern, options: .regularExpression) != nil + } + + private static func tidy(_ md: String) -> String { + md.replacingOccurrences(of: #"\n{3,}"#, with: "\n\n", options: .regularExpression) + .trimmingCharacters(in: .whitespacesAndNewlines) + } +} diff --git a/ios/Stem/Markdown/MdxTree.swift b/ios/Stem/Markdown/MdxTree.swift index 154cd6ab..1449e87d 100644 --- a/ios/Stem/Markdown/MdxTree.swift +++ b/ios/Stem/Markdown/MdxTree.swift @@ -100,6 +100,11 @@ enum MdxTreeParser { var fence: (char: Character, count: Int)? var dataLines: [String]? var dataLang = "" + // A data component whose fence just ended: its closing tag is due. + // Models sometimes skip it and carry on with prose (see desktop's + // closeDataComponents), so any other non-blank line closes it here. A + // later stray closer matches nothing on the stack and is skipped. + var closerDue = false func close(_ frame: Frame, closed: Bool) -> MdxBlock { frame.flush() @@ -108,6 +113,18 @@ enum MdxTreeParser { } for line in text.components(separatedBy: "\n") { + if closerDue, fence == nil { + let trimmed = line.trimmingCharacters(in: .whitespaces) + let name = stack[stack.count - 1].name + if trimmed.isEmpty { continue } + closerDue = false + if !"".hasPrefix(trimmed), !trimmed.hasPrefix(" [MailConversation] { - mail.conversations - .filter { c in - c.status == "working" - && !c.waitingOnUser - && Inbox.placement(id: c.id, updatedAt: c.userUpdatedAt, state: mail.inbox, now: now) == .inbox - } - .sorted { ($0.userSentAt ?? 0) > ($1.userSentAt ?? 0) } - } -} diff --git a/ios/Stem/Models/Share.swift b/ios/Stem/Models/Share.swift index c4deaba3..92c94897 100644 --- a/ios/Stem/Models/Share.swift +++ b/ios/Stem/Models/Share.swift @@ -30,12 +30,16 @@ enum ShareScope: String, CaseIterable, Identifiable { struct ShareImage: Decodable, Hashable { var mime: String; var dataUrl: String; var alt: String? } +/// A sound the answer shared; the link carries it playable, so the preview shows it. +struct ShareAudio: Decodable, Hashable { var title: String?; var mime: String; var dataUrl: String } + struct ShareMessage: Decodable, Hashable { var role: String var author: String? var text: String var model: String? var images: [ShareImage]? + var audio: [ShareAudio]? } struct ShareSnapshot: Decodable, Hashable { @@ -52,6 +56,8 @@ struct ShareDraftPreview: Decodable, Hashable { var omittedAttachments: Int /// Absent from servers before link previews. var card: ShareCard? + /// The snapshot "Create link" publishes; absent from older servers. + var draftId: String? } struct SharedLink: Decodable, Hashable, Identifiable { diff --git a/ios/Stem/Models/Types.swift b/ios/Stem/Models/Types.swift index 7eb8d98d..88f772f3 100644 --- a/ios/Stem/Models/Types.swift +++ b/ios/Stem/Models/Types.swift @@ -53,7 +53,7 @@ struct InboxState: Codable, Hashable { var entries: [String: InboxEntry] = [:] } -struct ChatHistory: Decodable { +struct ChatHistory: Codable { var threadId: String var title: String var messages: [ChatMessage] @@ -159,7 +159,7 @@ struct StartTurnResult: Decodable { var assistantMessage: String? } -struct LiveTurnInfo: Decodable { +struct LiveTurnInfo: Codable { var threadId: String var turnId: String? } @@ -176,9 +176,9 @@ struct SkillLearnResult: Decodable { // MARK: Models + settings -struct ModelServiceTier: Decodable, Hashable { var id: String; var name: String } +struct ModelServiceTier: Codable, Hashable { var id: String; var name: String } -struct ModelSummary: Decodable, Hashable, Identifiable { +struct ModelSummary: Codable, Hashable, Identifiable { var id: String var displayName: String var description: String @@ -194,15 +194,15 @@ struct ModelSummary: Decodable, Hashable, Identifiable { } /// The slice of server settings the phone reads. -struct ServerSettings: Decodable { - struct WebSearch: Decodable { var main: Bool } - struct Defaults: Decodable { var model: String? } - struct Instructions: Decodable { var main: String; var quickChat: String } +struct ServerSettings: Codable { + struct WebSearch: Codable { var main: Bool } + struct Defaults: Codable { var model: String? } + struct Instructions: Codable { var main: String; var quickChat: String } var webSearch: WebSearch var defaults: Defaults? var customInstructions: Instructions? - struct ChatFeatures: Decodable { - struct Allow: Decodable { var allow: Bool } + struct ChatFeatures: Codable { + struct Allow: Codable { var allow: Bool } var voice: Allow? } /// Absent on an older server, which has no voice chat. @@ -211,7 +211,7 @@ struct ServerSettings: Decodable { // MARK: Personas -struct Persona: Decodable, Hashable, Identifiable { +struct Persona: Codable, Hashable, Identifiable { var id: String var name: String var clients: Bool? @@ -220,13 +220,13 @@ struct Persona: Decodable, Hashable, Identifiable { // MARK: Mail -struct MailListResult: Decodable { +struct MailListResult: Codable { var conversations: [MailConversation] var items: [MailItem] var inbox: InboxState } -struct MailConversation: Decodable, Hashable, Identifiable { +struct MailConversation: Codable, Hashable, Identifiable { var id: String var subject: String var participants: [String] @@ -249,7 +249,7 @@ struct MailConversation: Decodable, Hashable, Identifiable { var waitingOnUser: Bool { userUpdatedAt > max(userSentAt ?? 0, userAnsweredAt ?? 0) } } -struct MailItem: Decodable, Hashable, Identifiable { +struct MailItem: Codable, Hashable, Identifiable { var id: String var conversationId: String var from: String @@ -273,7 +273,7 @@ struct MailItem: Decodable, Hashable, Identifiable { var external: MailItemExternal? } -struct MailCollab: Decodable, Hashable { +struct MailCollab: Codable, Hashable { var goal: String var agreed: [String] var open: [String] @@ -281,14 +281,14 @@ struct MailCollab: Decodable, Hashable { } /// The other side of a conversation with another person. -struct MailExternalThread: Decodable, Hashable { +struct MailExternalThread: Codable, Hashable { var address: String var thread: String var `self`: String } /// Port of MailExternal (src/shared/types.ts). -struct MailItemExternal: Decodable, Hashable { +struct MailItemExternal: Codable, Hashable { var held: Bool? var keyChanged: Bool? /// queued | sent | delivered | expired | failed | unreachable | key-changed | waiting | joined @@ -348,7 +348,7 @@ struct InterStemReach: Decodable, Equatable { var reason: String? } -struct MailApproval: Decodable, Hashable { +struct MailApproval: Codable, Hashable { var id: String /// exec | harness | send (a persona's draft to another person, waiting for the user to send it) var kind: String @@ -378,7 +378,7 @@ struct MailComposeInput: Encodable { // MARK: Approvals -struct ExecApprovalRequest: Decodable, Hashable { +struct ExecApprovalRequest: Codable, Hashable { var id: String var threadId: String var command: String diff --git a/ios/Stem/Stores/AppModel.swift b/ios/Stem/Stores/AppModel.swift index cfa3090a..e5cb8bf5 100644 --- a/ios/Stem/Stores/AppModel.swift +++ b/ios/Stem/Stores/AppModel.swift @@ -51,8 +51,27 @@ final class AppModel { registerPush() } + /// "Try the demo" on the pair screen: the same app over sample data, held + /// in memory by a stand-in server. Nothing is stored, nothing is paired. + func startDemo() { + session?.close() + chatPath = [] + mailPath = [] + tab = .chats + session = Session(client: StemClient(demo: DemoServer())) + } + func unpair() { guard let s = session else { return } + if s.isDemo { + // Leaving the demo: forget it, but there's no pairing to revoke or clear. + s.close() + session = nil + DraftStore.clearAll() + chatPath = [] + mailPath = [] + return + } let client = s.client let id = s.client.creds.deviceId Task { try? await client.run("devices:revoke", [.string(id)]) } @@ -66,7 +85,7 @@ final class AppModel { } func registerPush() { - guard let token = pushToken, let client = session?.client else { return } + guard let token = pushToken, let client = session?.client, client.demo == nil else { return } Task { try? await client.run("devices:registerPush", [.string(token), "ios"]) } } @@ -97,7 +116,7 @@ final class AppModel { do { let creds = try await StemClient.pair(serverUrl: link.serverUrl, code: link.code) let oldClient = old.client - Task { try? await oldClient.run("devices:revoke", [.string(oldClient.creds.deviceId)]) } + if !old.isDemo { Task { try? await oldClient.run("devices:revoke", [.string(oldClient.creds.deviceId)]) } } DraftStore.clearAll() chatPath = [] mailPath = [] @@ -131,8 +150,10 @@ final class Session { @ObservationIgnored var visibleThreadId: String? @ObservationIgnored private var sub: UUID? - init(creds: Credentials) { - client = StemClient(creds: creds) + convenience init(creds: Credentials) { self.init(client: StemClient(creds: creds)) } + + init(client: StemClient) { + self.client = client connection = Connection(client: client) chats = ChatListStore(client: client) mail = MailStore(client: client) @@ -150,6 +171,9 @@ final class Session { connection.stop() } + /// Running "Try the demo": sample data, no server behind it. + var isDemo: Bool { client.demo != nil } + /// Personas a phone may start a chat as (the server refuses the others). var chatPersonas: [Persona] { personas.filter { $0.clients == true } } var mailPersonas: [Persona] { personas } diff --git a/ios/Stem/Stores/ChatListStore.swift b/ios/Stem/Stores/ChatListStore.swift index 1717b3a5..acf8ff26 100644 --- a/ios/Stem/Stores/ChatListStore.swift +++ b/ios/Stem/Stores/ChatListStore.swift @@ -17,7 +17,7 @@ final class ChatListStore { self.client = client // The last list this pairing saw, so a cold start shows chats at once // instead of a spinner while a few hundred KB come over a phone link. - if let data = try? Data(contentsOf: Self.cacheURL(client.creds.deviceId)), + if client.demo == nil, let data = try? Data(contentsOf: Self.cacheURL(client.creds.deviceId)), let cached = try? JSONDecoder().decode(ChatListResult.self, from: data) { apply(cached) loaded = true @@ -37,6 +37,7 @@ final class ChatListStore { static func clearCache() { try? FileManager.default.removeItem(at: cacheDir) } private func save(_ r: ChatListResult) { + guard client.demo == nil else { return } let url = Self.cacheURL(client.creds.deviceId) Task.detached(priority: .utility) { guard let data = try? JSONEncoder().encode(r) else { return } diff --git a/ios/Stem/Transport/Connection.swift b/ios/Stem/Transport/Connection.swift index b3278ab5..b8b2009a 100644 --- a/ios/Stem/Transport/Connection.swift +++ b/ios/Stem/Transport/Connection.swift @@ -38,6 +38,14 @@ final class Connection { func unsubscribe(_ id: UUID) { listeners[id] = nil } func start() { + if let demo = client.demo { + demo.connection = self + let snap = demo.snapshot() + status = .live + liveTurns = Dictionary(snap.live.map { ($0.threadId, $0.turnId ?? "") }, uniquingKeysWith: { $1 }) + emit(.snapshot(liveTurns: snap.live, execApprovals: snap.exec)) + return + } guard task == nil else { return } task = Task { [weak self] in await self?.loop() } } @@ -175,6 +183,12 @@ final class Connection { if let id = block.id { lastEventId = id } } + /// A frame from the demo's sample server, delivered like one off the stream. + func receivePush(channel: String, payload: JSONValue) { + if channel == "backend:event" { trackLiveTurn(payload) } + emit(.push(channel: channel, payload: payload)) + } + private func trackLiveTurn(_ env: JSONValue) { guard let method = env["method"]?.stringValue else { return } let params = env["params"] diff --git a/ios/Stem/Transport/DemoServer.swift b/ios/Stem/Transport/DemoServer.swift new file mode 100644 index 00000000..342172ec --- /dev/null +++ b/ios/Stem/Transport/DemoServer.swift @@ -0,0 +1,555 @@ +import Foundation + +/// "Try the demo" on the pair screen: a stand-in for the server that keeps +/// sample chats and mail in memory, answers every channel the app calls, and +/// plays replies back as stream events. `StemClient` and `Connection` hand +/// everything to it instead of the network, so the demo never opens a +/// connection: it can't reach anyone's Stem and nothing it "does" (approved +/// commands, sent mail) happens anywhere. Built for App Review, who have no +/// server to pair with. Nothing is saved; leaving the demo forgets it all. +@MainActor +final class DemoServer { + static let modelId = "demo" + static let credentials = Credentials(serverUrl: "Demo (no server)", deviceId: "demo", token: "") + + weak var connection: Connection? + + private var chats: [ChatSummary] = [] + private var folders: [ChatFolder] = [] + private var chatInbox = InboxState() + private var histories: [String: [ChatMessage]] = [:] + private var conversations: [MailConversation] = [] + private var items: [MailItem] = [] + private var mailInbox = InboxState() + private var execApprovals: [ExecApprovalRequest] = [] + /// turnId → the chat it runs in and the task playing it. + private var turns: [String: (threadId: String, task: Task)] = [:] + private var mailTasks: [String: Task] = [:] + private var webSearch = false + private var seq = 0 + + init() { seed() } + + // MARK: Stream + + func snapshot() -> (live: [LiveTurnInfo], exec: [ExecApprovalRequest]) { + (turns.map { LiveTurnInfo(threadId: $0.value.threadId, turnId: $0.key) }, execApprovals) + } + + private func push(_ channel: String, _ payload: JSONValue = .null) { + connection?.receivePush(channel: channel, payload: payload) + } + + private func event(_ method: String, _ params: [String: JSONValue]) { + push("backend:event", ["method": .string(method), "params": .object(params)]) + } + + // MARK: RPC + + func handle(_ channel: String, _ args: [JSONValue]) async throws -> JSONValue { + func arg(_ i: Int) -> JSONValue { i < args.count ? args[i] : .null } + func str(_ i: Int) -> String { arg(i).stringValue ?? "" } + func strings(_ i: Int) -> [String] { + if case .array(let a) = arg(i) { return a.compactMap(\.stringValue) } + return [] + } + func bool(_ i: Int) -> Bool { if case .bool(let b) = arg(i) { return b }; return false } + + switch channel { + // Shared lists + case "personas:list": + return .from([ + Persona(id: "assistant", name: "Assistant", clients: true, builtin: true), + Persona(id: "researcher", name: "Researcher", clients: true, builtin: false), + ]) + case "backend:listModels": + return .from([ModelSummary( + id: Self.modelId, displayName: "Demo model", description: "Prepared replies for the demo", + provider: "demo", providerName: "Demo", supportedEfforts: ["low", "medium", "high"], + defaultEffort: "medium", serviceTiers: [], isDefault: true)]) + case "settings:get": + return settings() + case "settings:updateWebSearch": + if case .bool(let on)? = arg(0)["main"] { webSearch = on } + return settings() + case "settings:updateDefaults", "devices:registerPush", "devices:revoke", "chats:setFormat": + return .null + + // Chats + case "chats:list": + return chatList() + case "chats:open", "chats:history": + let id = str(0) + guard let chat = chats.first(where: { $0.threadId == id }) else { throw StemError(message: "That chat is gone.") } + return .from(ChatHistory(threadId: id, title: chat.title, messages: histories[id] ?? [])) + case "inbox:setRead": + for id in strings(0) { setRead(&chatInbox, id, bool(1)) } + return chatList() + case "inbox:setArchived": + for id in strings(0) { setArchived(&chatInbox, id, bool(1)) } + return chatList() + case "chats:setFolder": + let folder = arg(1).stringValue + if let i = chats.firstIndex(where: { $0.threadId == str(0) }) { chats[i].folderId = folder } + return chatList() + case "folders:create": + seq += 1 + folders.append(ChatFolder(id: "demo-folder-\(seq)", name: str(0), parentId: arg(1).stringValue, + order: Double(folders.count))) + return chatList() + case "folders:rename": + if let i = folders.firstIndex(where: { $0.id == str(0) }) { folders[i].name = str(1) } + return chatList() + case "folders:delete": + let id = str(0) + let parent = folders.first { $0.id == id }?.parentId + folders.removeAll { $0.id == id } + for i in folders.indices where folders[i].parentId == id { folders[i].parentId = parent } + for i in chats.indices where chats[i].folderId == id { chats[i].folderId = parent } + return chatList() + case "chats:delete": + let id = str(0) + for (turn, t) in turns where t.threadId == id { t.task.cancel(); turns[turn] = nil } + chats.removeAll { $0.threadId == id } + histories[id] = nil + execApprovals.removeAll { $0.threadId == id } + push("chats:changed") + return .null + case "chats:rollbackToTurn": + let id = str(0), turn = str(1) + if let all = histories[id], let i = all.firstIndex(where: { $0.turnId == turn }) { + histories[id] = Array(all[.. JSONValue { + [ + "webSearch": ["main": .bool(webSearch)], + "defaults": ["model": .string(Self.modelId)], + "customInstructions": ["main": "", "quickChat": ""], + "chatFeatures": ["voice": ["allow": false]], + ] + } + + private func chatList() -> JSONValue { + .from(ChatListResult(chats: chats, folders: folders, inbox: chatInbox)) + } + + private func touchChat(_ id: String, preview: String) { + guard let i = chats.firstIndex(where: { $0.threadId == id }) else { return } + chats[i].updatedAt = Self.nowS + chats[i].preview = Self.plain(preview) + } + + private func startTurn(_ input: JSONValue) -> JSONValue { + let text = input["input"]?.stringValue ?? "" + let turn = input["turnId"]?.stringValue ?? UUID().uuidString.lowercased() + var names: [String] = [] + if case .array(let files)? = input["attachments"] { names = files.compactMap { $0["name"]?.stringValue } } + let threadId: String + if let id = input["threadId"]?.stringValue, chats.contains(where: { $0.threadId == id }) { + threadId = id + } else { + seq += 1 + threadId = "demo-chat-\(seq)" + let firstLine = text.split(separator: "\n").first.map(String.init) ?? "New chat" + let title = firstLine.count > 40 ? String(firstLine.prefix(40)) + "…" : firstLine + chats.append(ChatSummary( + threadId: threadId, title: title, private: input["private"] == .bool(true) ? true : nil, + format: input["format"]?.stringValue == "md" ? "md" : nil, createdAt: Self.nowS, updatedAt: Self.nowS)) + } + histories[threadId, default: []].append(ChatMessage( + id: "user-\(turn)", role: "user", content: text, + attachments: names.isEmpty ? nil : names.map { MessageAttachment(kind: "file", name: $0) }, + turnId: turn, runtimeTurnId: turn, createdAt: Self.iso(Date()))) + touchChat(threadId, preview: text) + push("chats:changed") + play(threadId: threadId, turn: turn, reply: Self.reply(to: text, files: names)) + return ["threadId": .string(threadId), "turnId": .string(turn)] + } + + /// Streams a prepared reply like a model would: a moment of thinking, + /// optionally a tool row, then the text in small pieces. + private func play(threadId: String, turn: String, reply: String, tool: (type: String, detail: String)? = nil) { + let base: [String: JSONValue] = ["threadId": .string(threadId), "turnId": .string(turn)] + let task = Task { [weak self] in + func pause(_ ms: Int) async -> Bool { + try? await Task.sleep(for: .milliseconds(ms)) + return !Task.isCancelled && self != nil + } + guard await pause(300) else { return } + self?.event("item/started", base.merging(["item": ["type": "reasoning", "id": .string("reasoning-\(turn)")]]) { $1 }) + guard await pause(800) else { return } + if let tool { + let item: JSONValue = ["type": .string(tool.type), "id": .string("tool-\(turn)"), "detail": .string(tool.detail)] + self?.event("item/started", base.merging(["item": item]) { $1 }) + guard await pause(1200) else { return } + var done = item + if case .object(var o) = done { o["status"] = "ok"; done = .object(o) } + self?.event("item/completed", base.merging(["item": done]) { $1 }) + } + var offset = 0 + for piece in Self.pieces(reply) { + self?.event("item/agentMessage/delta", base.merging([ + "delta": .string(piece), "offset": .number(Double(offset)), + ]) { $1 }) + offset += piece.utf16.count + guard await pause(35) else { return } + } + self?.finish(threadId: threadId, turn: turn, reply: reply) + } + turns[turn] = (threadId, task) + } + + private func finish(threadId: String, turn: String, reply: String) { + guard turns.removeValue(forKey: turn) != nil else { return } + let base: [String: JSONValue] = ["threadId": .string(threadId), "turnId": .string(turn)] + histories[threadId, default: []].append(ChatMessage( + id: "assistant-\(turn)", role: "assistant", content: reply, meta: MessageMeta(model: "Demo model"), + turnId: turn, runtimeTurnId: turn, createdAt: Self.iso(Date()))) + touchChat(threadId, preview: reply) + event("item/completed", base.merging(["item": ["type": "agentMessage", "id": .string("assistant-\(turn)"), "text": .string(reply)]]) { $1 }) + event("turn/completed", base) + push("chats:changed") + } + + private func interrupt(_ turn: String) { + guard let t = turns.removeValue(forKey: turn) else { return } + t.task.cancel() + event("turn/aborted", ["threadId": .string(t.threadId), "turnId": .string(turn)]) + push("chats:changed") + } + + private func resolveExec(_ id: String, _ decision: String) -> Bool { + guard let i = execApprovals.firstIndex(where: { $0.id == id }) else { return false } + let r = execApprovals.remove(at: i) + push("exec:approvalResolved", ["id": .string(id)]) + let turn = UUID().uuidString.lowercased() + if decision == "deny" { + play(threadId: r.threadId, turn: turn, reply: "Okay, I left everything where it is. The installers are still in Downloads; ask again whenever you want them gone.") + } else { + play(threadId: r.threadId, turn: turn, + reply: "Done. I moved **12 installers** older than 30 days to the Trash, which frees **3.4 GB**. Nothing else in Downloads changed, and you can put them back from the Trash.\n\n_This is the demo: no command ran and no files moved._", + tool: ("commandExecution", "find ~/Downloads -name '*.dmg' -mtime +30")) + } + return true + } + + // MARK: Mail + + private func mailList() -> JSONValue { + .from(MailListResult(conversations: conversations, items: items, inbox: mailInbox)) + } + + private func updateConversation(_ id: String, _ change: (inout MailConversation) -> Void) { + if let i = conversations.firstIndex(where: { $0.id == id }) { change(&conversations[i]) } + } + + private func addItem(_ conversationId: String, from: String, to: [String], body: String, + attachments: [MessageAttachment]? = nil, approval: MailApproval? = nil) { + seq += 1 + let now = Self.nowMs + items.append(MailItem(id: "demo-mail-\(seq)", conversationId: conversationId, from: from, to: to, body: body, + at: now, attachments: attachments, approval: approval)) + updateConversation(conversationId) { c in + c.updatedAt = now + if from == "user" { c.userSentAt = now } + if to.contains("user") { c.userUpdatedAt = now } + } + } + + private func reply(_ id: String, body: String, attachments: JSONValue) throws { + guard let c = conversations.first(where: { $0.id == id }) else { throw StemError(message: "That conversation is gone.") } + var files: [MessageAttachment]? + if case .array(let a) = attachments { + files = a.compactMap { $0["name"]?.stringValue }.map { MessageAttachment(kind: "file", name: $0) } + } + let persona = c.participants.first { !$0.hasPrefix("task:") } ?? "assistant" + addItem(id, from: "user", to: [persona], body: body, attachments: files) + updateConversation(id) { $0.status = "working" } + push("mail:changed") + answerLater(id, from: persona, body: Self.mailReply(conversation: id, to: body)) + } + + private func compose(_ input: JSONValue) { + var to: [String] = [] + if case .array(let a)? = input["to"] { to = a.compactMap(\.stringValue) } + if to.isEmpty { to = ["assistant"] } + let body = input["body"]?.stringValue ?? "" + let subject = input["subject"]?.stringValue.flatMap { $0.isEmpty ? nil : $0 } + ?? String(body.split(separator: "\n").first ?? "New mail").prefix(60).description + seq += 1 + let id = "demo-conv-\(seq)" + let now = Self.nowMs + conversations.append(MailConversation( + id: id, subject: subject, participants: to, + private: input["private"] == .bool(true) ? true : nil, status: "working", + updatedAt: now, userUpdatedAt: now, createdAt: now)) + addItem(id, from: "user", to: to, body: body) + push("mail:changed") + answerLater(id, from: to[0], body: Self.mailReply(conversation: id, to: body)) + } + + private func answerLater(_ id: String, from persona: String, body: String, delay: Int = 2500) { + mailTasks[id]?.cancel() + mailTasks[id] = Task { [weak self] in + try? await Task.sleep(for: .milliseconds(delay)) + guard !Task.isCancelled, let self else { return } + self.addItem(id, from: persona, to: ["user"], body: body) + self.updateConversation(id) { $0.status = "idle" } + self.mailTasks[id] = nil + self.push("mail:changed") + } + } + + private func resolveMailApproval(_ itemId: String, allow: Bool) -> JSONValue { + guard let i = items.firstIndex(where: { $0.id == itemId }), items[i].approval?.status == "pending" else { + return ["ok": false, "error": "That request was already answered."] + } + items[i].approval?.status = allow ? "allowed" : "denied" + let id = items[i].conversationId + let persona = items[i].from + updateConversation(id) { c in + c.userAnsweredAt = Self.nowMs + c.status = "working" + } + push("mail:changed") + answerLater(id, from: persona, body: allow + ? "Added. Your calendar now has:\n\n- **Fri 07:42** train to Vienna (platform 3)\n- **Sat 10:00** Albertina tickets\n- **Sun 18:10** train home\n\n_This is the demo: your calendar was not changed._" + : "Okay, I didn't add anything to your calendar. Ask again whenever you want the events in.", + delay: 1800) + return ["ok": true] + } + + // MARK: Inbox + + private func setRead(_ inbox: inout InboxState, _ id: String, _ read: Bool) { + var e = inbox.entries[id] ?? InboxEntry() + if read { e.readAt = Self.nowMs; e.forcedUnread = nil } else { e.readAt = nil; e.forcedUnread = true } + inbox.entries[id] = e + } + + private func setArchived(_ inbox: inout InboxState, _ id: String, _ archived: Bool) { + var e = inbox.entries[id] ?? InboxEntry() + e.archivedAt = archived ? Self.nowMs : nil + inbox.entries[id] = e + } + + // MARK: Helpers + + static var nowS: Double { Date().timeIntervalSince1970 } + static var nowMs: Double { Date().timeIntervalSince1970 * 1000 } + + /// A row preview: the reply's text without Markdown marks. + static func plain(_ text: String) -> String { + let stripped = text.replacingOccurrences(of: #"[*_#>|`]+"#, with: "", options: .regularExpression) + .replacingOccurrences(of: #"\s+"#, with: " ", options: .regularExpression) + .trimmingCharacters(in: .whitespaces) + return String(stripped.prefix(140)) + } + + static func iso(_ d: Date) -> String { ISO8601DateFormatter().string(from: d) } + + /// A reply in word-sized pieces, the way a model's deltas arrive. + static func pieces(_ text: String) -> [String] { + var out: [String] = [] + var cur = "" + for ch in text { + cur.append(ch) + if (ch == " " || ch == "\n") && cur.count >= 6 { out.append(cur); cur = "" } + } + if !cur.isEmpty { out.append(cur) } + return out + } + + static func reply(to text: String, files: [String]) -> String { + let t = text.lowercased() + let note = "\n\n_This is the demo, so the reply was prepared in advance. In your own Stem, the model you choose writes it, with your memory and the tools you allow._" + if !files.isEmpty { + return "Thanks, I have **\(files.joined(separator: ", "))**. In your own Stem I would read \(files.count == 1 ? "it" : "them") and answer about the contents." + note + } + if ["hello", "hi ", "hey", "ahoj", "čau"].contains(where: { t.hasPrefix($0) || t == $0.trimmingCharacters(in: .whitespaces) }) { + return "Hi! I'm Stem, your assistant. Things to try in this demo:\n\n- Ask me to plan something, like a trip or a week of dinners\n- Answer the request waiting in **Clean up my Downloads folder**\n- Open **Mail** and reply to a conversation" + note + } + if t.contains("dinner") || t.contains("recipe") || t.contains("cook") || t.contains("meal") { + return "Here's a simple plan for the week:\n\n| Day | Dinner | Time |\n| --- | --- | --- |\n| Mon | Lemon chicken with rice | 30 min |\n| Tue | Lentil soup | 40 min |\n| Wed | Pasta with spinach and feta | 20 min |\n| Thu | Fish tacos | 25 min |\n| Fri | Homemade pizza | 45 min |\n\nWant a shopping list for it?" + note + } + if t.contains("trip") || t.contains("travel") || t.contains("vienna") || t.contains("weekend") || t.contains("plan") { + return "Here's a first plan:\n\n1. **Morning** — an early train, so you arrive before the crowds\n2. **Midday** — one museum or a walk through the old town, then lunch somewhere small\n3. **Evening** — a concert or a long dinner\n\nTell me your dates and budget and I'll fill in times and tickets." + note + } + if t.contains("email") || t.contains("mail") || t.contains("write") || t.contains("draft") { + return "Here's a short draft:\n\n> Hi,\n>\n> Thanks for getting back to me. Friday works well for me — shall we say 10:00?\n>\n> Best regards\n\nShall I make it more formal, or shorter?" + note + } + let quoted = text.count > 120 ? String(text.prefix(120)) + "…" : text + return "You asked: “\(quoted)”\n\nIn your own Stem, I'd answer this with the model you pick, and could search the web, read your folders, or run a command on your Mac once you approve it.\n\nIn the demo, try:\n\n- Asking me to **plan a trip** or **a week of dinners**\n- Answering the request in **Clean up my Downloads folder**\n- Replying to a mail in **Mail**" + note + } + + static func mailReply(conversation: String, to body: String) -> String { + if conversation == "demo-landlord" { + return "Updated. I kept your wording and added a clear deadline:\n\n> Dear Mr. Novák,\n>\n> The heating in our flat has not worked since Monday. Please arrange a repair by **Friday**. If that isn't possible, let me know when a technician can come.\n>\n> Kind regards\n\nSend it from your own mail when you're happy with it.\n\n_This is the demo: nothing was sent to anyone._" + } + return "Thanks, got it. In your own Stem, I would work on this and reply here when it's done, asking first before anything that changes your files, calendar or accounts.\n\n_This is the demo, so this reply was prepared in advance and nothing was sent._" + } + + // MARK: Sample data + + private func seed() { + let now = Self.nowS + let h = 3600.0 + folders = [ + ChatFolder(id: "demo-folder-home", name: "Home", order: 0), + ChatFolder(id: "demo-folder-work", name: "Work", order: 1), + ] + + func chat(_ id: String, _ title: String, folder: String? = nil, ago: Double, _ turns: [(String, String)]) { + var msgs: [ChatMessage] = [] + for (n, t) in turns.enumerated() { + let turn = "\(id)-t\(n)" + let at = Self.iso(Date(timeIntervalSince1970: now - ago - Double(turns.count - n) * 60)) + msgs.append(ChatMessage(id: "user-\(turn)", role: "user", content: t.0, turnId: turn, runtimeTurnId: turn, createdAt: at)) + msgs.append(ChatMessage(id: "assistant-\(turn)", role: "assistant", content: t.1, meta: MessageMeta(model: "Demo model"), + turnId: turn, runtimeTurnId: turn, createdAt: at)) + } + histories[id] = msgs + chats.append(ChatSummary(threadId: id, title: title, preview: Self.plain(turns.last?.1 ?? ""), + folderId: folder, createdAt: now - ago - 600, updatedAt: now - ago)) + } + + chat("demo-downloads", "Clean up my Downloads folder", ago: 0.05 * h, [( + "My Mac is almost out of space. Can you clear the old installers out of Downloads?", + "I found **12 disk images** (.dmg) in Downloads that are older than 30 days, **3.4 GB** in all. The newest is from October, so none of them look like something you're still installing.\n\nI'd move them to the Trash, where you can still get them back. Moving files needs your OK — the request is below." + )]) + chat("demo-vienna", "Weekend in Vienna", ago: 3 * h, [( + "Plan a relaxed weekend in Vienna for two, going by train from Bratislava.", + "Here's a calm plan with plenty of breaks:\n\n### Friday\n- **07:42** train from Bratislava hl. st. (1 h 6 min)\n- Coffee and breakfast at a café near Stephansplatz\n- Afternoon walk through the old town\n\n### Saturday\n- **10:00** Albertina (book tickets online)\n- Lunch at the Naschmarkt\n- Evening: a concert at the Musikverein, if tickets are left\n\n### Sunday\n- Slow morning, then the Prater or Schönbrunn gardens\n- **18:10** train home\n\nWant me to put it in your calendar? I've already started on that in Mail." + )]) + chat("demo-budget", "Q4 team budget", folder: "demo-folder-work", ago: 26 * h, [( + "Sum up the Q4 team budget: travel 4 200, software 2 750, training 1 900, events 3 100.", + "| Item | Amount (€) | Share |\n| --- | ---: | ---: |\n| Travel | 4 200 | 35 % |\n| Events | 3 100 | 26 % |\n| Software | 2 750 | 23 % |\n| Training | 1 900 | 16 % |\n| **Total** | **11 950** | 100 % |\n\nTravel is the biggest line. Moving one trip to a video call would save about €800." + )]) + chat("demo-plants", "Watering the balcony plants", folder: "demo-folder-home", ago: 50 * h, [( + "How often should I water basil and rosemary on a sunny balcony in summer?", + "- **Basil** likes steady moisture: water when the top 2 cm of soil is dry, usually every day in a heatwave.\n- **Rosemary** prefers to dry out between waterings: about twice a week is plenty.\n\nWater in the morning, at the soil rather than the leaves." + )]) + // Opened already, except the chat with the request waiting. + for id in ["demo-vienna", "demo-budget", "demo-plants"] { setRead(&chatInbox, id, true) } + + execApprovals = [ExecApprovalRequest( + id: "demo-exec-downloads", threadId: "demo-downloads", + command: "find ~/Downloads -name '*.dmg' -mtime +30 -exec mv {} ~/.Trash/ \\;", + cwd: "~", prefixes: ["find"], judgeVerdict: "ask", + judgeReason: "Moves files to the Trash", deviceLabel: "MacBook Pro")] + + let ms = Self.nowMs + let mh = 3600_000.0 + func conv(_ id: String, _ subject: String, _ participants: [String], status: String = "idle", ago: Double) { + let at = ms - ago * mh + conversations.append(MailConversation(id: id, subject: subject, participants: participants, status: status, + updatedAt: at, userUpdatedAt: at, createdAt: at - mh)) + } + func mail(_ conv: String, _ from: String, _ to: [String], ago: Double, _ body: String, approval: MailApproval? = nil) { + seq += 1 + items.append(MailItem(id: "demo-mail-\(seq)", conversationId: conv, from: from, to: to, body: body, + at: ms - ago * mh, approval: approval)) + } + + conv("demo-calendar", "Add the Vienna trip to my calendar", ["assistant"], status: "awaiting-user", ago: 0.2) + mail("demo-calendar", "user", ["assistant"], ago: 0.4, + "Put the Vienna weekend in my calendar, with the train times.") + mail("demo-calendar", "assistant", ["user"], ago: 0.2, + "I made three events from the plan: both trains and the Albertina visit. Adding them changes your calendar, so I need your OK first.", + approval: MailApproval(id: "demo-approval-calendar", kind: "exec", + command: "stem-calendar add --file vienna-weekend.ics # 3 events, Fri–Sun", + cwd: "~", deviceLabel: "MacBook Pro", reason: "Adds events to your calendar", status: "pending")) + updateConversation("demo-calendar") { c in c.userSentAt = ms - 0.4 * mh } + + conv("demo-landlord", "Heating repair — email to the landlord", ["assistant", "researcher"], ago: 1.5) + mail("demo-landlord", "user", ["assistant"], ago: 2, + "Our heating has been broken since Monday. Can you draft a polite but firm email to the landlord asking for a repair this week?") + mail("demo-landlord", "assistant", ["researcher"], ago: 1.9, + "What repair deadline is reasonable to ask for when a flat has no heating?") + mail("demo-landlord", "researcher", ["assistant"], ago: 1.7, + "Tenancy guidance treats a heating failure in winter as urgent. Asking for a repair within 3–5 working days is reasonable, and it helps to say when you first reported it.") + mail("demo-landlord", "assistant", ["user"], ago: 1.5, + "Here's a draft:\n\n> Dear Mr. Novák,\n>\n> The heating in our flat has not worked since Monday. Could you please arrange a repair this week? I'm happy to be at home for a technician any afternoon.\n>\n> Kind regards\n\nResearcher says asking for a repair within 3–5 working days is reasonable. Shall I add a firm date?") + updateConversation("demo-landlord") { c in c.userSentAt = ms - 2 * mh } + + conv("demo-briefing", "Morning briefing", ["task:demo-morning"], ago: 8) + mail("demo-briefing", "task:demo-morning", ["user"], ago: 8, + "Good morning! Here's your day:\n\n- **Weather:** sunny, 14 °C, light wind\n- **10:30** dentist (bring the insurance card)\n- **Today:** the library books are due\n\nNothing urgent in your inbox.") + setRead(&mailInbox, "demo-briefing", true) + } +} diff --git a/ios/Stem/Transport/StemClient.swift b/ios/Stem/Transport/StemClient.swift index 57623389..a7ec52ab 100644 --- a/ios/Stem/Transport/StemClient.swift +++ b/ios/Stem/Transport/StemClient.swift @@ -11,6 +11,17 @@ struct StemError: LocalizedError { /// HTTP side of the server transport: `/rpc`, `/upload`, `/pair`. struct StemClient: Sendable { let creds: Credentials + /// Set for "Try the demo": every call goes to the in-app sample server and + /// nothing touches the network. + var demo: DemoServer? = nil + + /// The demo's client: no address, no token. + init(demo: DemoServer) { + creds = DemoServer.credentials + self.demo = demo + } + + init(creds: Credentials) { self.creds = creds } var baseURL: URL { URL(string: creds.serverUrl)! } @@ -33,6 +44,13 @@ struct StemClient: Sendable { } private func call(_ channel: String, _ args: [JSONValue], as: T.Type, discardResult: Bool) async throws -> T { + if let demo { + let value = try await demo.handle(channel, args) + if T.self == Empty.self { return Empty() as! T } + if T.self == JSONValue.self { return value as! T } + do { return try value.decode(T.self) } + catch { throw StemError(message: "\(channel): unexpected answer (\(error))") } + } var req = URLRequest(url: baseURL.appendingPathComponent("rpc")) req.httpMethod = "POST" // The server leaves the answer out (older servers send it anyway). @@ -67,6 +85,7 @@ struct StemClient: Sendable { /// Stages raw bytes on the server; the handle stands in for a file path /// on `startTurn` / `mail:*` attachments. func upload(_ data: Data, name: String, mime: String) async throws -> TurnAttachment { + if demo != nil { return TurnAttachment(name: name, path: "demo-upload:\(UUID().uuidString)", dataBase64: nil, mime: mime) } var comps = URLComponents(url: baseURL.appendingPathComponent("upload"), resolvingAgainstBaseURL: false)! comps.queryItems = [URLQueryItem(name: "name", value: name)] var req = URLRequest(url: comps.url!) @@ -85,6 +104,7 @@ struct StemClient: Sendable { /// One file from GET /files/, saved under a temporary folder with its name. func download(_ rel: String, name: String) async throws -> URL { + if demo != nil { throw StemError(message: "Files aren't available in the demo.") } let encoded = rel.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? rel guard let url = URL(string: creds.serverUrl + "/files/" + encoded) else { throw StemError(message: "Bad file address") } var req = URLRequest(url: url) diff --git a/ios/Stem/Views/Composer.swift b/ios/Stem/Views/Composer.swift index acd0c75e..acef978e 100644 --- a/ios/Stem/Views/Composer.swift +++ b/ios/Stem/Views/Composer.swift @@ -35,6 +35,11 @@ struct Composer: View { var focusRequest = 0 /// The chat's voice call and how to start or end it. Nil where voice chat isn't offered. var voice: (call: PhoneVoice, toggle: () -> Void)? + /// Page layout (New mail): this header and a full-width editor scroll as + /// one sheet of paper; attach, dictate and Send sit in a bar under it. + var page: AnyView? + /// Send's label in the page layout ("Send to Normal"). + var sendTitle: String? @Environment(Session.self) private var session @State private var noteMode = false @@ -57,6 +62,95 @@ struct Composer: View { } var body: some View { + Group { + if let page { pageBody(page) } else { barBody } + } + .onChange(of: draft) { _, d in DraftStore.save(draftKey, d) } + .task(id: focusRequest) { + guard focusRequest > 0 else { return } + // In a sheet the field can't take focus until the sheet has settled. + try? await Task.sleep(for: .milliseconds(450)) + focused = true + } + .photosPicker(isPresented: $showPhotos, selection: $photoItems, maxSelectionCount: 10, matching: .images) + .onChange(of: photoItems) { _, items in Task { await addPhotos(items) } } + .fileImporter(isPresented: $showFiles, allowedContentTypes: [.item], allowsMultipleSelection: true) { r in + if case .success(let urls) = r { addFiles(urls) } + } + .fullScreenCover(isPresented: $showCamera) { + CameraPicker { image in + if let jpg = image.jpegData(compressionQuality: 0.85), + let a = DraftAttachment.make(data: jpg, name: "photo-\(Int(Date().timeIntervalSince1970)).jpg", mime: "image/jpeg") { + draft.attachments.append(a) + } + } + .ignoresSafeArea() + } + .sheet(isPresented: $showModels) { ModelSheet().environment(session) } + .sheet(isPresented: $showDictationIntro, onDismiss: { dictationIntroSeen = true }) { + DictationIntroSheet(dictation: dictation) { + dictation.toggle(current: draft.text) { draft.text = $0 } + } + } + } + + /// A hand edit ends dictation (the next update would undo it), and `/note ` + /// switches to note mode. + private func textEdited(_ new: String) { + if dictation.active, new != dictation.lastWritten { dictation.freeze() } + applyNotePrefix(new) + } + + private func pageBody(_ header: AnyView) -> some View { + VStack(spacing: 0) { + ScrollView { + VStack(alignment: .leading, spacing: 0) { + header + TextField(placeholder, text: $draft.text, axis: .vertical) + .lineLimit(10...) + .focused($focused) + .onChange(of: draft.text) { _, new in textEdited(new) } + .padding(.horizontal, 16) + .padding(.vertical, 14) + .frame(maxWidth: .infinity, alignment: .topLeading) + if !draft.attachments.isEmpty { + attachmentChips.padding(.horizontal, 16).padding(.bottom, 12) + } + } + } + .scrollDismissesKeyboard(.interactively) + .interactiveDismissDisabled(sending) + VStack(alignment: .leading, spacing: 6) { + if let flash { + Text(flash).font(.footnote).foregroundStyle(.secondary).transition(.opacity) + } + HStack(spacing: 20) { + attachMenu + if PhoneDictation.supported { micButton } + Spacer() + Button { Task { await submit() } } label: { + HStack(spacing: 6) { + if sending { ProgressView().controlSize(.small).tint(.white) } + else { Image(systemName: "paperplane.fill") } + Text(sendTitle ?? "Send").lineLimit(1) + } + .font(.body.weight(.semibold)) + .padding(.horizontal, 4) + } + .buttonStyle(.borderedProminent) + .buttonBorderShape(.capsule) + .disabled(!canSend) + .accessibilityLabel(sendTitle ?? "Send") + } + } + .padding(.horizontal, 16) + .padding(.vertical, 10) + .background(.bar) + .overlay(alignment: .top) { Divider() } + } + } + + private var barBody: some View { VStack(alignment: .leading, spacing: 6) { if let flash { Text(flash) @@ -82,11 +176,7 @@ struct Composer: View { TextField(noteMode ? "Note to memory" : placeholder, text: $draft.text, axis: .vertical) .lineLimit(1...8) .focused($focused) - .onChange(of: draft.text) { _, new in - // A hand edit ends dictation; the next update would undo it. - if dictation.active, new != dictation.lastWritten { dictation.freeze() } - applyNotePrefix(new) - } + .onChange(of: draft.text) { _, new in textEdited(new) } if PhoneDictation.supported { micButton } if let voice { voiceButton(voice.call, toggle: voice.toggle) } } @@ -101,33 +191,6 @@ struct Composer: View { .padding(.horizontal, 12) .padding(.vertical, 8) .background(.bar) - .onChange(of: draft) { _, d in DraftStore.save(draftKey, d) } - .task(id: focusRequest) { - guard focusRequest > 0 else { return } - // In a sheet the field can't take focus until the sheet has settled. - try? await Task.sleep(for: .milliseconds(450)) - focused = true - } - .photosPicker(isPresented: $showPhotos, selection: $photoItems, maxSelectionCount: 10, matching: .images) - .onChange(of: photoItems) { _, items in Task { await addPhotos(items) } } - .fileImporter(isPresented: $showFiles, allowedContentTypes: [.item], allowsMultipleSelection: true) { r in - if case .success(let urls) = r { addFiles(urls) } - } - .fullScreenCover(isPresented: $showCamera) { - CameraPicker { image in - if let jpg = image.jpegData(compressionQuality: 0.85), - let a = DraftAttachment.make(data: jpg, name: "photo-\(Int(Date().timeIntervalSince1970)).jpg", mime: "image/jpeg") { - draft.attachments.append(a) - } - } - .ignoresSafeArea() - } - .sheet(isPresented: $showModels) { ModelSheet().environment(session) } - .sheet(isPresented: $showDictationIntro, onDismiss: { dictationIntroSeen = true }) { - DictationIntroSheet(dictation: dictation) { - dictation.toggle(current: draft.text) { draft.text = $0 } - } - } } // MARK: Slash commands @@ -197,11 +260,20 @@ struct Composer: View { } } } label: { - Image(systemName: "plus") - .font(.system(size: 17, weight: .semibold)) - .frame(width: 36, height: 36) - .background(Color(.secondarySystemBackground), in: Circle()) + if page != nil { + Image(systemName: "paperclip") + .font(.system(size: 18)) + .foregroundStyle(.secondary) + .frame(width: 28, height: 28) + .contentShape(Rectangle()) + } else { + Image(systemName: "plus") + .font(.system(size: 17, weight: .semibold)) + .frame(width: 36, height: 36) + .background(Color(.secondarySystemBackground), in: Circle()) + } } + .tint(page != nil ? .secondary : nil) .accessibilityLabel("Attach") } @@ -393,23 +465,33 @@ struct Composer: View { return } - // The field empties at once; the message waits in the transcript while - // its attachments upload, and comes back here if the send fails. + // In a chat the field empties at once; the message waits in the transcript + // while its attachments upload, and comes back here if the send fails. + // A page (new mail) has no transcript: the text stays put — and saved — + // until the send lands, so closing the sheet or losing the app mid-upload + // never loses it. let sent = draft - draft.text = "" - draft.attachments = [] + if page == nil { + draft.text = "" + draft.attachments = [] + } if await onSend(text, files) { files.forEach { $0.delete() } var fresh = Draft() fresh.personaId = draft.personaId fresh.isPrivate = draft.isPrivate fresh.to = draft.to - fresh.text = draft.text - fresh.attachments = draft.attachments + if page == nil { + // Whatever was typed while it sent stays for the next message. + fresh.text = draft.text + fresh.attachments = draft.attachments + } draft = fresh - } else { + } else if page == nil { draft.text = draft.text.isEmpty ? sent.text : sent.text + "\n" + draft.text draft.attachments = sent.attachments + draft.attachments + } else { + show("Not sent — your mail is still here.", seconds: 6) } } diff --git a/ios/Stem/Views/MailViews.swift b/ios/Stem/Views/MailViews.swift index 3b80e303..126da677 100644 --- a/ios/Stem/Views/MailViews.swift +++ b/ios/Stem/Views/MailViews.swift @@ -46,22 +46,14 @@ struct MailListView: View { } } } - } header: { - if folder == .inbox, !working.isEmpty, !rows.isEmpty { Text("Waiting on you") } - } - if folder == .inbox, !working.isEmpty { - // Sent and still being worked: visible here, never unread or "waiting on you". - Section("Working") { - ForEach(working) { c in - NavigationLink(value: Route.mail(c.id)) { MailRow(conversation: c) } - } - } } + // Mail the personas are still working on waits under Sent, like + // email, and comes back up when their answer lands. } .listStyle(.plain) .overlay { if !session.mail.loaded { ProgressView() } - else if rows.isEmpty && (folder != .inbox || working.isEmpty) { + else if rows.isEmpty { ContentUnavailableView("No mail in \(folder.rawValue)", systemImage: "tray") } } @@ -84,8 +76,8 @@ struct MailListView: View { } } .sheet(isPresented: $composing) { - MailComposeView { id in app.mailPath = [.mail(id)] } - .environment(session) + // Sending closes the sheet and stays on the list: nothing working shows. + MailComposeView().environment(session) } .task { if !session.mail.loaded { await session.mail.reload() } } } @@ -97,7 +89,6 @@ struct MailListView: View { private var requests: [MailConversation] { folder == .inbox ? (session.mail.sections[.inbox] ?? []).filter { session.interStem.isRequest($0) } : [] } - private var working: [MailConversation] { MailSections.working(session.mail.mail) } } struct MailRow: View { @@ -435,6 +426,7 @@ struct ReplyRequest: Identifiable { /// answering quoted beneath it. Cancel keeps the draft. struct MailReplySheet: View { @Environment(Session.self) private var session + @Environment(AppModel.self) private var app @Environment(\.dismiss) private var dismiss let conversationId: String /// Above zero: the caret goes into the reply at once (a form's Ask). @@ -510,6 +502,8 @@ struct MailReplySheet: View { let uploads = try await Uploads.upload(files, client: session.client) try await session.mail.reply(conversationId, body: text, attachments: uploads) dismiss() + // Sent: back to the list, like email — the answer brings it up again. + if app.mailPath.last == .mail(conversationId) { app.mailPath.removeLast() } return true } catch { // The sheet stays open with the text kept, so nothing is lost. @@ -582,7 +576,7 @@ struct MailItemCard: View { .background(mine ? Color.accentColor.opacity(0.10) : Color(.secondarySystemBackground).opacity(0.7), in: RoundedRectangle(cornerRadius: 14)) .contextMenu { - Button("Copy") { UIPasteboard.general.string = item.body } + Button("Copy") { UIPasteboard.general.string = MdxCopy.markdown(item.body) } if let onShare { Button("Share as Link…", systemImage: "square.and.arrow.up") { onShare() } } } } @@ -943,7 +937,6 @@ struct MailApprovalView: View { struct MailComposeView: View { @Environment(Session.self) private var session @Environment(\.dismiss) private var dismiss - var onSent: (String) -> Void @State private var draft = DraftStore.load("mail:new") @State private var error: String? @State private var reach: InterStemReach? @@ -955,56 +948,30 @@ struct MailComposeView: View { private var outLooksValid: Bool { outAddress.wholeMatch(of: /[^\s@]+@[^\s@]+\.[^\s@]+/) != nil } private var outSendable: Bool { outLooksValid && (reach == nil || reach?.state == "reachable" || reach?.state == "unreachable") } + private var leadName: String? { + draft.to.first.flatMap { id in session.mailPersonas.first { $0.id == id }?.name } + } + var body: some View { NavigationStack { - VStack(spacing: 0) { - Form { - if session.interStem.canWriteOut { - Section { - Toggle(isOn: Binding(get: { writingOut }, set: { draft.outTo = $0 ? (draft.outTo ?? "") : nil })) { - Label("To a person", systemImage: "at") - } - } footer: { - if writingOut { Text("To someone on their own Stem, by email address. End-to-end encrypted; only you send.") } - } - } - if writingOut { - personSection - } else { - Section { - VStack(alignment: .leading, spacing: 6) { - Text("To — the first one leads").font(.caption).foregroundStyle(.secondary) - ScrollView(.horizontal, showsIndicators: false) { - HStack(spacing: 6) { - ForEach(session.mailPersonas) { p in - let idx = draft.to.firstIndex(of: p.id) - Button { - if let idx { draft.to.remove(at: idx) } else { draft.to.append(p.id) } - } label: { - HStack(spacing: 4) { - if let idx { Text("\(idx + 1)").font(.caption2.bold()) } - Text(p.name) - } - } - .chipStyle(on: idx != nil) - } - } - .font(.subheadline) - } + Composer(kind: .mail, draftKey: "mail:new", draft: $draft, busy: writingOut ? !outSendable : draft.to.isEmpty, + placeholder: writingOut ? "Write your mail" : "Write the task — the reply lands in your Inbox", + onSend: send, page: AnyView(header), + sendTitle: writingOut ? "Send" : leadName.map { "Send to \($0)" }) + .navigationTitle("New mail") + .navigationBarTitleDisplayMode(.inline) + .toolbar { + ToolbarItem(placement: .cancellationAction) { Button("Close") { dismiss() } } + if !writingOut { + ToolbarItem(placement: .primaryAction) { + Button { draft.isPrivate.toggle() } label: { + Image(systemName: draft.isPrivate ? "lock.fill" : "lock") } - TextField("Subject", text: $draft.subject) - Toggle(isOn: $draft.isPrivate) { Label("Private", systemImage: "eye.slash") } - } + .tint(draft.isPrivate ? Color.accentColor : .secondary) + .accessibilityLabel(draft.isPrivate ? "Private on" : "Private off") } - if let error { Section { Text(error).foregroundStyle(.red).font(.footnote) } } } - .scrollDismissesKeyboard(.interactively) - Composer(kind: .mail, draftKey: "mail:new", draft: $draft, busy: writingOut && !outSendable, - placeholder: "Write your mail", onSend: send) } - .navigationTitle("New mail") - .navigationBarTitleDisplayMode(.inline) - .toolbar { ToolbarItem(placement: .cancellationAction) { Button("Close") { dismiss() } } } .onChange(of: draft) { _, d in DraftStore.save("mail:new", d) } .onAppear { if draft.to.isEmpty, session.mailPersonas.contains(where: { $0.id == "normal" }) { draft.to = ["normal"] } } .task(id: outAddress) { @@ -1018,33 +985,127 @@ struct MailComposeView: View { } } - @ViewBuilder private var personSection: some View { - Section { - if session.interStem.verifiedAddresses.count > 1 { - Picker("From", selection: Binding(get: { from ?? session.interStem.verifiedAddresses[0] }, set: { from = $0 })) { - ForEach(session.interStem.verifiedAddresses, id: \.self) { Text($0).tag($0) } + /// To, Subject and the notes above the body, as lines on one page. + @ViewBuilder private var header: some View { + VStack(alignment: .leading, spacing: 0) { + if session.interStem.canWriteOut { + Picker("Write to", selection: Binding(get: { writingOut }, set: { draft.outTo = $0 ? (draft.outTo ?? "") : nil })) { + Text("Personas").tag(false) + Text("A person").tag(true) + } + .pickerStyle(.segmented) + .padding(.horizontal, 16) + .padding(.top, 10) + .padding(.bottom, writingOut ? 4 : 10) + if writingOut { + Text("To someone on their own Stem, by email address. End-to-end encrypted; only you send.") + .font(.caption).foregroundStyle(.secondary) + .padding(.horizontal, 16).padding(.bottom, 10) } } - TextField("their@email.com", text: Binding(get: { draft.outTo ?? "" }, set: { draft.outTo = $0 })) - .keyboardType(.emailAddress) - .textInputAutocapitalization(.never) - .autocorrectionDisabled() - let matches = (session.interStem.status?.contacts ?? []).filter { - $0.state != "blocked" && $0.address != outAddress && (outAddress.isEmpty || $0.address.contains(outAddress) - || ($0.name ?? "").lowercased().contains(outAddress)) - }.prefix(5) - if !matches.isEmpty { + if writingOut { personLines } else { personaLines } + if let error { + Text(error).font(.footnote).foregroundStyle(.red) + .padding(.horizontal, 16).padding(.top, 10) + } + } + } + + /// One header line: a muted label, then its field. `labelTop` lines the + /// label up with a taller first row (the persona chips). + private func line(_ label: String, labelTop: CGFloat = 0, @ViewBuilder _ content: () -> Content) -> some View { + VStack(spacing: 0) { + HStack(alignment: .top, spacing: 10) { + Text(label).foregroundStyle(.secondary).frame(width: 62, alignment: .leading).padding(.top, labelTop) + content().frame(maxWidth: .infinity, alignment: .leading) + } + .padding(.horizontal, 16) + .padding(.vertical, 11) + Divider().padding(.leading, 16) + } + } + + @ViewBuilder private var personaLines: some View { + line("To", labelTop: 5) { + VStack(alignment: .leading, spacing: 6) { ScrollView(.horizontal, showsIndicators: false) { HStack(spacing: 6) { - ForEach(Array(matches)) { c in - Button(c.name ?? c.address) { draft.outTo = c.address }.chipStyle(on: false) + ForEach(session.mailPersonas) { p in + let idx = draft.to.firstIndex(of: p.id) + Button { + if let idx { draft.to.remove(at: idx) } else { draft.to.append(p.id) } + } label: { + HStack(spacing: 4) { + if let idx, draft.to.count > 1 { Text("\(idx + 1)").font(.caption2.bold()) } + Text(p.name) + } + } + .chipStyle(on: idx != nil) } } .font(.subheadline) } + Text(toHint).font(.caption).foregroundStyle(.secondary) + } + } + line("Subject") { + TextField("Optional", text: $draft.subject).fontWeight(.semibold) + } + if draft.isPrivate { + VStack(spacing: 0) { + Label("Private: nothing here is saved to memory or read from it. Fixed once sent.", systemImage: "lock.fill") + .font(.footnote) + .frame(maxWidth: .infinity, alignment: .leading) + .padding(.horizontal, 16) + .padding(.vertical, 9) + .background(Color.accentColor.opacity(0.12)) + Divider() + } + } + } + + private var toHint: String { + guard let lead = leadName else { return "Pick at least one persona — the first one leads." } + let others = draft.to.dropFirst().compactMap { id in session.mailPersonas.first { $0.id == id }?.name } + if others.isEmpty { return "\(lead) gets your mail and answers you." } + return "\(lead) gets your mail and answers you. \(others.joined(separator: ", ")) \(others.count == 1 ? "joins" : "join") when \(lead) asks." + } + + @ViewBuilder private var personLines: some View { + if session.interStem.verifiedAddresses.count > 1 { + line("From") { + Picker("From", selection: Binding(get: { from ?? session.interStem.verifiedAddresses[0] }, set: { from = $0 })) { + ForEach(session.interStem.verifiedAddresses, id: \.self) { Text($0).tag($0) } + } + .labelsHidden() + .pickerStyle(.menu) + } + } + line("To") { + VStack(alignment: .leading, spacing: 8) { + TextField("their@email.com", text: Binding(get: { draft.outTo ?? "" }, set: { draft.outTo = $0 })) + .keyboardType(.emailAddress) + .textInputAutocapitalization(.never) + .autocorrectionDisabled() + let matches = (session.interStem.status?.contacts ?? []).filter { + $0.state != "blocked" && $0.address != outAddress && (outAddress.isEmpty || $0.address.contains(outAddress) + || ($0.name ?? "").lowercased().contains(outAddress)) + }.prefix(5) + if !matches.isEmpty { + ScrollView(.horizontal, showsIndicators: false) { + HStack(spacing: 6) { + ForEach(Array(matches)) { c in + Button(c.name ?? c.address) { draft.outTo = c.address }.chipStyle(on: false) + } + } + .font(.subheadline) + } + } + if let reach, outLooksValid { reachRow(reach) } } - if let reach, outLooksValid { reachRow(reach) } - TextField("Subject (optional)", text: $draft.subject) + } + line("Subject") { + TextField("Optional", text: $draft.subject).fontWeight(.semibold) } } @@ -1070,20 +1131,21 @@ struct MailComposeView: View { } private func send(_ text: String, _ files: [DraftAttachment]) async -> Bool { + // Photo uploads take a while on mobile data; locking the phone or + // switching apps must not cut the upload off halfway. + let background = UIApplication.shared.beginBackgroundTask(withName: "mail:compose") + defer { if background != .invalid { UIApplication.shared.endBackgroundTask(background) } } if writingOut { return await sendToPerson(text, files) } do { let uploads = try await Uploads.upload(files, client: session.client) let input = MailComposeInput( to: draft.to, subject: draft.subject.isEmpty ? nil : draft.subject, body: text, attachments: uploads.isEmpty ? nil : uploads, private: draft.isPrivate ? true : nil) - let before = Set(session.mail.mail.conversations.map(\.id)) - let r = try await session.mail.compose(input) - let created = r.conversations.filter { !before.contains($0.id) }.max { $0.createdAt < $1.createdAt } + _ = try await session.mail.compose(input) draft.subject = "" draft.isPrivate = false DraftStore.clear("mail:new", draft) dismiss() - if let created { onSent(created.id) } return true } catch { self.error = error.localizedDescription @@ -1094,16 +1156,13 @@ struct MailComposeView: View { private func sendToPerson(_ text: String, _ files: [DraftAttachment]) async -> Bool { guard outSendable else { return false } do { - let before = Set(session.mail.mail.conversations.map(\.id)) let uploads = try await Uploads.upload(files, client: session.client) try await session.interStem.compose(to: outAddress, from: from, subject: draft.subject, body: text, attachments: uploads) await session.mail.reload() - let created = session.mail.mail.conversations.filter { !before.contains($0.id) }.max { $0.createdAt < $1.createdAt } draft.subject = "" draft.outTo = nil DraftStore.clear("mail:new", draft) dismiss() - if let created { onSent(created.id) } return true } catch { self.error = error.localizedDescription diff --git a/ios/Stem/Views/PairView.swift b/ios/Stem/Views/PairView.swift index 09ea1498..8b695402 100644 --- a/ios/Stem/Views/PairView.swift +++ b/ios/Stem/Views/PairView.swift @@ -49,6 +49,14 @@ struct PairView: View { } .disabled(busy || serverUrl.isEmpty || PairLink.normalizeCode(code).count != 8) } + Section { + Button { app.startDemo() } label: { + Label("Try the demo", systemImage: "play.circle") + } + .disabled(busy) + } footer: { + Text("No Stem yet? Look around with sample chats and mail. The demo doesn't connect to any server, and nothing you do in it leaves this phone.") + } } .navigationTitle("Pair") .sheet(isPresented: $scanning) { diff --git a/ios/Stem/Views/ShareSheet.swift b/ios/Stem/Views/ShareSheet.swift index 7a84b716..5541741b 100644 --- a/ios/Stem/Views/ShareSheet.swift +++ b/ios/Stem/Views/ShareSheet.swift @@ -1,3 +1,4 @@ +import AVFoundation import SwiftUI /// Publish an answer, the question and answer, or the whole chat / mail thread @@ -80,6 +81,9 @@ struct ShareLinkSheet: View { if let n = m.images?.count, n > 0 { Text(n == 1 ? "1 picture" : "\(n) pictures").font(.caption).foregroundStyle(.secondary) } + ForEach(Array((m.audio ?? []).enumerated()), id: \.offset) { _, a in + ShareAudioRow(audio: a) + } } } } else if error == nil { @@ -145,6 +149,8 @@ struct ShareLinkSheet: View { "ttlDays": .number(Double(ttlDays)) ] o["card"] = cardOn ? .object(["title": .string(title), "description": .string(desc)]) : .null + // Publish the snapshot on screen, not a fresh build. + if let draftId = preview?.draftId { o["draftId"] = .string(draftId) } return .object(o) } @@ -188,3 +194,34 @@ struct ShareLinkSheet: View { } } } + +/// A recording the link will carry, playable here so the user hears what they publish. +private struct ShareAudioRow: View { + let audio: ShareAudio + @State private var player: AVAudioPlayer? + @State private var playing = false + + var body: some View { + Button { + toggle() + } label: { + Label(audio.title?.isEmpty == false ? audio.title! : "Recording", + systemImage: playing ? "stop.circle" : "play.circle") + } + .buttonStyle(.borderless) + .font(.callout) + .onDisappear { player?.stop() } + } + + private func toggle() { + if playing { player?.stop(); playing = false; return } + if player == nil, + let comma = audio.dataUrl.firstIndex(of: ","), + let data = Data(base64Encoded: String(audio.dataUrl[audio.dataUrl.index(after: comma)...])) { + try? AVAudioSession.sharedInstance().setCategory(.playback) + player = try? AVAudioPlayer(data: data) + } + player?.currentTime = 0 + playing = player?.play() ?? false + } +} diff --git a/ios/Stem/Views/ThreadView.swift b/ios/Stem/Views/ThreadView.swift index ef2d6e0e..6f6e57ec 100644 --- a/ios/Stem/Views/ThreadView.swift +++ b/ios/Stem/Views/ThreadView.swift @@ -349,7 +349,8 @@ struct MessageRow: View { if let sources = message.sources, !sources.isEmpty { SourcesList(sources: sources) } } .contextMenu { - Button("Copy") { UIPasteboard.general.string = message.content } + // The reply as clean Markdown, without its component tags. + Button("Copy") { UIPasteboard.general.string = MdxCopy.markdown(message.content) } if let onShare, let turn = message.turnId, !message.content.isEmpty, !store.busy || !isLatest { Button("Share as Link…", systemImage: "square.and.arrow.up") { onShare(turn) } } diff --git a/ios/StemTests/MdxCopyTests.swift b/ios/StemTests/MdxCopyTests.swift new file mode 100644 index 00000000..2a1b2645 --- /dev/null +++ b/ios/StemTests/MdxCopyTests.swift @@ -0,0 +1,24 @@ +import XCTest +@testable import Stem + +/// "Copy" on a reply against the *.copy.md files in tests/fixtures/mdx, which +/// tests/unit/mdx-copy.test.ts checks against the desktop's converter. +final class MdxCopyTests: XCTestCase { + func testEveryFixtureCopiesLikeTheDesktop() throws { + let dir = try XCTUnwrap(Bundle(for: MdxCopyTests.self).url(forResource: "mdx", withExtension: nil)) + let names = try FileManager.default.contentsOfDirectory(atPath: dir.path) + .filter { $0.hasSuffix(".mdx") } + .map { String($0.dropLast(4)) } + .sorted() + XCTAssertGreaterThanOrEqual(names.count, 12) + for name in names { + let mdx = try String(contentsOf: dir.appendingPathComponent("\(name).mdx"), encoding: .utf8) + let expected = try String(contentsOf: dir.appendingPathComponent("\(name).copy.md"), encoding: .utf8) + XCTAssertEqual(MdxCopy.markdown(mdx) + "\n", expected, name) + } + } + + func testCodeKeepsItsTags() { + XCTAssertEqual(MdxCopy.markdown("Use `` like this."), "Use `` like this.") + } +} diff --git a/ios/StemTests/MdxTreeTests.swift b/ios/StemTests/MdxTreeTests.swift index b265283e..86f1c8b8 100644 --- a/ios/StemTests/MdxTreeTests.swift +++ b/ios/StemTests/MdxTreeTests.swift @@ -40,6 +40,25 @@ final class MdxTreeTests: XCTestCase { XCTAssertEqual(c.data?.value, "[{\"a\":") } + func testDataComponentLeftOpenClosesAfterItsFence() { + let src = "\n```json\n[{\"a\":\"1\"}]\n```\nProse after.\n\n\nCareful.\n\n\n" + let tree = MdxTreeParser.parse(src) + guard tree.blocks.count == 3, case .component(let table) = tree.blocks[0], + case .md(let prose) = tree.blocks[1], case .component(let callout) = tree.blocks[2] + else { return XCTFail("unexpected tree: \(tree.blocks)") } + XCTAssertEqual(table.name, "DataTable") + XCTAssertTrue(table.closed) + XCTAssertEqual(table.data?.value, "[{\"a\":\"1\"}]") + XCTAssertEqual(prose, "Prose after.") + XCTAssertEqual(callout.name, "Callout") + } + + func testDataComponentWaitsForAClosingTagStillStreaming() { + let tree = MdxTreeParser.parse("\n```json\n[]\n```\n\n```bash\nls\n```\n") guard case .component(let c) = tree.blocks.first else { return XCTFail("no component") } diff --git a/native/mac/stem-computer/WindowPeek.swift b/native/mac/stem-computer/WindowPeek.swift index 2c79ea67..19f648b2 100644 --- a/native/mac/stem-computer/WindowPeek.swift +++ b/native/mac/stem-computer/WindowPeek.swift @@ -13,18 +13,25 @@ enum WindowPeek { /// The window the person was looking at: the front window of the frontmost /// app, else (Stem itself was in front) the topmost ordinary window that is /// not Stem's. Nil when no other app has a window on screen. + /// + /// The frontmost app's window can float, and its app can have no Dock icon: + /// jbrow's hotkey window is both. Only the fallback keeps to ordinary + /// windows, so a floating window of an app in the back never wins. static func frontWindow() -> WindowInfo? { guard let raw = CGWindowListCopyWindowInfo([.optionOnScreenOnly, .excludeDesktopElements], kCGNullWindowID) as? [[String: Any]] else { return nil } // On-screen listing comes front to back; `Windows.list` has already dropped - // Stem's own windows, helpers and other non-Dock apps. - let known = Dictionary(Windows.list(minimized: false).map { ($0.id, $0) }, uniquingKeysWith: { a, _ in a }) + // Stem's own windows and helpers. + let all = Windows.list(minimized: false, floating: true) + let known = Dictionary(all.map { ($0.id, $0) }, uniquingKeysWith: { a, _ in a }) let ordered = raw.compactMap { ($0[kCGWindowNumber as String] as? Int).flatMap { known[CGWindowID($0)] } } - return ordered.first(where: { $0.frontmost }) ?? ordered.first + if let front = ordered.first(where: { $0.frontmost }) { return front } + let ordinary = Set(Windows.list(minimized: false).map(\.id)) + return ordered.first(where: { ordinary.contains($0.id) }) } /// A window asked about before, again (the panel's New re-captures it); nil once it is gone. static func window(id: CGWindowID) -> WindowInfo? { - Windows.list(minimized: false).first(where: { $0.id == id }) + Windows.list(minimized: false, floating: true).first(where: { $0.id == id }) } static func describe(_ w: WindowInfo) -> [String: Any] { @@ -46,7 +53,7 @@ enum WindowPeek { /// The window's readable text, top to bottom, or nil when its app exposes none. static func text(windowId: CGWindowID, maxChars: Int) -> String? { - guard let w = Windows.list(minimized: false).first(where: { $0.id == windowId }) else { return nil } + guard let w = Windows.list(minimized: false, floating: true).first(where: { $0.id == windowId }) else { return nil } let ax = AX(pid: w.pid, windowID: w.id) defer { ax.release() } return ax.readableText(windowBounds: w.bounds, maxChars: maxChars) diff --git a/native/mac/stem-computer/Windows.swift b/native/mac/stem-computer/Windows.swift index 123559ab..4649afc7 100644 --- a/native/mac/stem-computer/Windows.swift +++ b/native/mac/stem-computer/Windows.swift @@ -60,11 +60,33 @@ enum Windows { return pid } } - if Thread.isMainThread { RunLoop.current.run(until: Date()) } + // A short spin, not run(until: now): that can return before the pending + // activation notifications are handled, and then the answer is stale. + if Thread.isMainThread { RunLoop.current.run(mode: .default, before: Date(timeIntervalSinceNow: 0.01)) } return NSWorkspace.shared.frontmostApplication?.processIdentifier } - static func list(minimized wantMinimized: Bool = true) -> [WindowInfo] { + /// Make the app that owns `id` the active one, so that it gets the keyboard + /// back (a window panel that shrinks to its pill leaves no key window). + /// Accessibility first: it works from a background process. False when the + /// window is gone. + static func focusApp(of id: CGWindowID) -> Bool { + guard let pidNum = record(of: id)?[kCGWindowOwnerPID as String] as? Int else { return false } + let pid = pid_t(pidNum) + if AXIsProcessTrusted() { + let app = AXUIElementCreateApplication(pid) + AXUIElementSetMessagingTimeout(app, 0.3) + if AXUIElementSetAttributeValue(app, kAXFrontmostAttribute as CFString, kCFBooleanTrue) == .success { return true } + } + return NSRunningApplication(processIdentifier: pid)?.activate() ?? false + } + + /// `floating: true` also keeps the windows that float above ordinary ones + /// (up to the status bar level) and the windows of apps without a Dock icon: + /// a hotkey browser or a launcher shows such a panel, and it can be the + /// window the person is in. Only "ask about this window" wants them. + static func list(minimized wantMinimized: Bool = true, floating: Bool = false) -> [WindowInfo] { + let topLayer = floating ? Int(CGWindowLevelForKey(.statusWindow)) : 1 guard let raw = CGWindowListCopyWindowInfo([.optionAll], kCGNullWindowID) as? [[String: Any]] else { return [] } trace("window list: \(raw.count) entries") let front = frontmostPid() @@ -76,7 +98,7 @@ enum Windows { let axTrusted = AXIsProcessTrusted() var out: [WindowInfo] = [] for w in raw { - guard let layer = w[kCGWindowLayer as String] as? Int, layer == 0, + guard let layer = w[kCGWindowLayer as String] as? Int, layer >= 0, layer < topLayer, let idNum = w[kCGWindowNumber as String] as? Int, let pidNum = w[kCGWindowOwnerPID as String] as? Int, let boundsDict = w[kCGWindowBounds as String] as? NSDictionary, @@ -94,7 +116,7 @@ enum Windows { app = NSRunningApplication(processIdentifier: pid) apps[pid] = app } - guard let app, app.activationPolicy == .regular else { continue } + guard let app, app.activationPolicy == .regular || (floating && app.activationPolicy == .accessory) else { continue } let name = app.localizedName ?? (w[kCGWindowOwnerName as String] as? String) ?? "pid \(pid)" let onScreen = (w[kCGWindowIsOnscreen as String] as? Bool) ?? false let title = (w[kCGWindowName as String] as? String) ?? "" diff --git a/native/mac/stem-computer/main.swift b/native/mac/stem-computer/main.swift index dd1529b8..d63385d0 100644 --- a/native/mac/stem-computer/main.swift +++ b/native/mac/stem-computer/main.swift @@ -359,7 +359,20 @@ while let line = readLine(strippingNewline: true) { emit(["id": id, "ok": true, "text": WindowPeek.text(windowId: windowId, maxChars: maxChars) ?? NSNull()]) case "window-bounds": let windowId = CGWindowID(Int(number(obj["windowId"]) ?? 0)) - emit(["id": id, "ok": true, "bounds": WindowPeek.bounds(windowId: windowId) ?? NSNull()]) + // onScreen is false while the window is minimised, its app hidden, or it + // sits on another Space: the docked panel steps aside with it. + // frontmost: the window's app is the one in front. A docked panel sinks + // behind other apps' windows while it is not (see orderOverlayWithWindow). + let owner = (Windows.record(of: windowId)?[kCGWindowOwnerPID as String] as? Int).map { pid_t($0) } + let front = owner == nil ? nil : Windows.frontmostPid() + emit([ + "id": id, "ok": true, "bounds": WindowPeek.bounds(windowId: windowId) ?? NSNull(), + "onScreen": Windows.isOnScreen(windowId), + "frontmost": front.map { $0 == owner! } ?? NSNull() + ]) + case "focus-app": + let windowId = CGWindowID(Int(number(obj["windowId"]) ?? 0)) + emit(["id": id, "ok": true, "focused": Windows.focusApp(of: windowId)]) case "watch": let on = obj["on"] as? Bool ?? true if on { diff --git a/package-lock.json b/package-lock.json index 4bdd747e..1ffbed6e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,64 +1,63 @@ { "name": "stem", - "version": "0.7.5", + "version": "0.8.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "stem", - "version": "0.7.5", + "version": "0.8.0", "hasInstallScript": true, "dependencies": { - "@earendil-works/pi-coding-agent": "1.1.0", - "@huggingface/transformers": "^4.3.1", - "acpx": "0.13.1", - "electron-updater": "^6.8.9", - "ignore": "^7.0.12", - "pdfjs-dist": "^6.1.200", - "pele": "^1.6.0", - "pi-web-access": "0.18.0", + "@earendil-works/pi-coding-agent": "1.6.0", + "@huggingface/transformers": "^4.3.2", + "acpx": "0.22.0", + "electron-updater": "^6.8.12", + "ignore": "^7.0.16", + "pdfjs-dist": "^6.5.438", + "pele": "^1.13.0", + "pi-web-access": "0.48.0", "remark-gfm": "^4.0.0", "remark-mdx": "^3.1.0", "remark-parse": "^11.0.0", "unified": "^11.0.5", "word-extractor": "^1.0.4", - "yaml": "^2.6.1" + "yaml": "^2.9.1" }, "devDependencies": { "@electron-toolkit/preload": "^3.0.2", - "@eslint/js": "^9.39.4", - "@playwright/test": "^1.61.0", - "@types/node": "^22.18.6", - "@types/react": "^19.1.13", - "@types/react-dom": "^19.1.9", + "@eslint/js": "^10.0.1", + "@playwright/test": "^1.65.1", + "@types/node": "^24.19.2", + "@types/react": "^19.3.0", + "@types/react-dom": "^19.3.0", "@types/word-extractor": "^1.0.6", - "@typescript-eslint/eslint-plugin": "^8.44.0", - "@typescript-eslint/parser": "^8.44.0", - "@vitejs/plugin-react": "^5.0.4", - "dompurify": "^3.4.16", - "electron": "^42.4.1", - "electron-builder": "^26.15.3", - "electron-vite": "^4.0.0", - "eslint": "^9.36.0", - "eslint-plugin-react-hooks": "^5.2.0", + "@typescript-eslint/eslint-plugin": "^8.73.0", + "@typescript-eslint/parser": "^8.73.0", + "@vitejs/plugin-react": "^6.3.0", + "dompurify": "^3.4.18", + "electron": "^45.4.1", + "electron-builder": "^26.18.1", + "electron-vite": "^6.0.0", + "eslint": "^10.15.0", + "eslint-plugin-react-hooks": "^7.1.1", "lowlight": "^3.3.0", - "lucide-react": "^0.468.0", - "patch-package": "^8.0.1", - "playwright": "^1.61.0", - "react": "^19.1.1", - "react-dom": "^19.1.1", - "typescript": "^5.9.2", - "vite": "^7.1.7", - "vitest": "^4.1.9" + "lucide-react": "^1.77.0", + "playwright": "^1.65.1", + "react": "^19.3.1", + "react-dom": "^19.3.1", + "typescript": "^6.0.3", + "vite": "^8.3.8", + "vitest": "^5.1.1" }, "engines": { "node": ">=24" } }, "node_modules/@agentclientprotocol/sdk": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/@agentclientprotocol/sdk/-/sdk-1.4.0.tgz", - "integrity": "sha512-/eufudw+aFY1LKLolT6yFE6UMmYRl7fMJ/DEONSIyR6wI3slHWITBsANRGqXEY8FRzqUxwh7QEaGiZHcJPVThg==", + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/@agentclientprotocol/sdk/-/sdk-1.9.0.tgz", + "integrity": "sha512-saCOTPYBK1iqWqJFAYHXbg3+zCoFXyZZFoqQAwdTWkbrZZPpAETr80QOnYr2l+dzPwL0jpNhn3eDY8MoEIDbUA==", "license": "Apache-2.0", "peerDependencies": { "zod": "^3.25.0 || ^4.0.0" @@ -109,17 +108,17 @@ } }, "node_modules/@aws-sdk/core": { - "version": "3.978.2", - "resolved": "https://registry.npmjs.org/@aws-sdk/core/-/core-3.978.2.tgz", - "integrity": "sha512-ViOBLuGSSyPAmkKGJ6KJXtVN7MOEp3rnI7uH+kWxnHccvo8C9cvunEAnN5/oaZH1laQfsTBw7IOnmNkWlFZl2A==", + "version": "3.981.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/core/-/core-3.981.0.tgz", + "integrity": "sha512-Mnu7gaDrC5UCdyH8uLxLfB2eWbjE/HbjKX1U1J2VQxG3TTATUDObW2wU3I8iH3e9YH5NN2CY6w1mlAIe2XJ3jg==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "^3.974.6", - "@aws-sdk/xml-builder": "^3.972.41", + "@aws-sdk/types": "^3.975.1", + "@aws-sdk/xml-builder": "^3.972.43", "@aws/lambda-invoke-store": "^0.3.0", - "@smithy/core": "^3.35.2", - "@smithy/signature-v4": "^5.7.4", - "@smithy/types": "^4.19.0", + "@smithy/core": "^3.40.0", + "@smithy/signature-v4": "^5.7.5", + "@smithy/types": "^4.20.0", "bowser": "^2.11.0", "tslib": "^2.6.2" }, @@ -128,15 +127,15 @@ } }, "node_modules/@aws-sdk/credential-provider-env": { - "version": "3.972.73", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-env/-/credential-provider-env-3.972.73.tgz", - "integrity": "sha512-PxlFZiF5IPUsPnuVSqjM9jlmRwZhL0xx40ccWfZiLQS8TRnHQpegpK1uAidatWuEqbJtbbY97A2Sezikz2AMUw==", + "version": "3.972.84", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-env/-/credential-provider-env-3.972.84.tgz", + "integrity": "sha512-akZJetiMVeLRHsKzYh3LamDCo74ZUCeo0XoyRKMEMZT5qP7ReM6LhpioBCyuqKP5Vav5gEOeCmaQV0VVQr1Meg==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/types": "^4.19.0", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -144,41 +143,55 @@ } }, "node_modules/@aws-sdk/credential-provider-http": { - "version": "3.972.75", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-http/-/credential-provider-http-3.972.75.tgz", - "integrity": "sha512-Q/uIDy8eAVN7JgSKDg16F/f+hmNJj/ZyLJN8AkW2ofVdDgJVh8fO/A26iZ7YsvM2/k76hsf/u2lLAtyXsK8Ziw==", + "version": "3.972.86", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-http/-/credential-provider-http-3.972.86.tgz", + "integrity": "sha512-U4mHaDRPWAn63yhl7FXIzbppNmW1F+4dSLeuiUpej2v3Xb6rGwvayEJ8SdlrdMV+/mZtd+GStTEP2HqurEzXtw==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/fetch-http-handler": "^5.8.0", - "@smithy/node-http-handler": "^4.12.1", - "@smithy/types": "^4.19.0", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/fetch-http-handler": "^5.8.1", + "@smithy/node-http-handler": "^4.14.2", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { "node": ">=20.0.0" } }, + "node_modules/@aws-sdk/credential-provider-http/node_modules/@smithy/node-http-handler": { + "version": "4.14.2", + "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-4.14.2.tgz", + "integrity": "sha512-i1uORV1v3qBqP43ayRKzIdm1q5x14tf8N4Dd06/QUX1Szm6VxHMrTsu20X5E63UFsaNZCRjI4SXG0jDmqYa+3w==", + "license": "Apache-2.0", + "dependencies": { + "@smithy/core": "^3.39.0", + "@smithy/types": "^4.20.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18.0.0" + } + }, "node_modules/@aws-sdk/credential-provider-ini": { - "version": "3.973.18", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-ini/-/credential-provider-ini-3.973.18.tgz", - "integrity": "sha512-KoyjZ9vdjuxEQ8obAH06xKP8H0WKqGhwUZLMqAOiS7G0xgUAht4X8f0ASLC/vhNLCWGblZOD3VQHWyTROGJHLg==", + "version": "3.973.30", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-ini/-/credential-provider-ini-3.973.30.tgz", + "integrity": "sha512-r6r6499GWoGN943NA5YEhBEQ6TEOGTf7tTOBhHd/zw0UbNvSzd1/zPCNcDkPmRarA+e24X7KgxutqxjoWcskBg==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/credential-provider-env": "^3.972.73", - "@aws-sdk/credential-provider-http": "^3.972.75", - "@aws-sdk/credential-provider-login": "^3.972.80", - "@aws-sdk/credential-provider-process": "^3.972.73", - "@aws-sdk/credential-provider-sso": "^3.973.17", - "@aws-sdk/credential-provider-web-identity": "^3.972.79", - "@aws-sdk/nested-clients": "^3.997.47", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/credential-provider-env": "^3.972.84", + "@aws-sdk/credential-provider-http": "^3.972.86", + "@aws-sdk/credential-provider-login": "^3.972.92", + "@aws-sdk/credential-provider-process": "^3.972.84", + "@aws-sdk/credential-provider-sso": "^3.973.28", + "@aws-sdk/credential-provider-web-identity": "^3.972.90", + "@aws-sdk/nested-clients": "^3.998.3", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", "@smithy/credential-provider-imds": "^4.5.2", - "@smithy/types": "^4.19.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -186,16 +199,16 @@ } }, "node_modules/@aws-sdk/credential-provider-login": { - "version": "3.972.80", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-login/-/credential-provider-login-3.972.80.tgz", - "integrity": "sha512-xF9A0gaO7k+1dYPFoo69OQatA9Ov0QuDZfqE8H0FLyIoOph+mlEC+I1Qo9UULupGuDfSYh+kVpfcDSxSYf/2fg==", + "version": "3.972.92", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-login/-/credential-provider-login-3.972.92.tgz", + "integrity": "sha512-96bcp9Pe/Xd60OEwncZ+kAQTQSu+fJnpUGz1qE6ghF5jnETmrk8XMU86mIP3lolvnCgR61XbZ+Ht6hdBjiQOmQ==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/nested-clients": "^3.997.47", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/types": "^4.19.0", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/nested-clients": "^3.998.3", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -203,21 +216,21 @@ } }, "node_modules/@aws-sdk/credential-provider-node": { - "version": "3.972.85", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-node/-/credential-provider-node-3.972.85.tgz", - "integrity": "sha512-CrFcML/xImiSlquH4W3V6Npz3aSkPXHDVciAU1JOBN0vqjmkcz9H9up2sCHQqN76J/WrT+TJ580L8h2joksQrg==", + "version": "3.972.97", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-node/-/credential-provider-node-3.972.97.tgz", + "integrity": "sha512-E4a0IXXJVsIdo/K9roX4JAEfI0JJr7KTPymkbKgETRDqEcLygE4ZlLTe24+7Qkh8Dl5YpnPd+Tt0DOPJDFXIwA==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/credential-provider-env": "^3.972.73", - "@aws-sdk/credential-provider-http": "^3.972.75", - "@aws-sdk/credential-provider-ini": "^3.973.18", - "@aws-sdk/credential-provider-process": "^3.972.73", - "@aws-sdk/credential-provider-sso": "^3.973.17", - "@aws-sdk/credential-provider-web-identity": "^3.972.79", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", + "@aws-sdk/credential-provider-env": "^3.972.84", + "@aws-sdk/credential-provider-http": "^3.972.86", + "@aws-sdk/credential-provider-ini": "^3.973.30", + "@aws-sdk/credential-provider-process": "^3.972.84", + "@aws-sdk/credential-provider-sso": "^3.973.28", + "@aws-sdk/credential-provider-web-identity": "^3.972.90", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", "@smithy/credential-provider-imds": "^4.5.2", - "@smithy/types": "^4.19.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -225,15 +238,15 @@ } }, "node_modules/@aws-sdk/credential-provider-process": { - "version": "3.972.73", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-process/-/credential-provider-process-3.972.73.tgz", - "integrity": "sha512-tyNnT4aVuOEXmKKKZPExBi828vRd9heshobBsKF0bov5EORHSJc1AGsHOMRP57sDt+dIuVASUOywaixiX26t4g==", + "version": "3.972.84", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-process/-/credential-provider-process-3.972.84.tgz", + "integrity": "sha512-199C6OpNejd0nq9GFAkEFIKids1FL0R6LJtL9c1OTiDOXki7S1OduuPxW4+hE0LwndcYJ7YHOuYTlqScfpCocA==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/types": "^4.19.0", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -241,17 +254,17 @@ } }, "node_modules/@aws-sdk/credential-provider-sso": { - "version": "3.973.17", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-sso/-/credential-provider-sso-3.973.17.tgz", - "integrity": "sha512-gxKTWaUk2gSbBOH4m3NPRfEKcGXeDAOgHr7nNG5JktR1xZLo0R+DpMjbcleoHbB0uJREOG7hjIRE635IuBWsRQ==", + "version": "3.973.28", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-sso/-/credential-provider-sso-3.973.28.tgz", + "integrity": "sha512-bGg7wH8wVDJQIcJggO9lg1ZYbG7l+PbLwHuM3Bi/e1TlCZhU712JS1W3tdRpyptdJD1UGyhBNGO/YrhrQCHKbg==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/nested-clients": "^3.997.47", - "@aws-sdk/token-providers": "3.1149.0", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/types": "^4.19.0", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/nested-clients": "^3.998.3", + "@aws-sdk/token-providers": "3.1166.0", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -259,16 +272,16 @@ } }, "node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers": { - "version": "3.1149.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/token-providers/-/token-providers-3.1149.0.tgz", - "integrity": "sha512-CAwYyA8eVk1w6h8YgLvkjIOakWPwURaUFrP7BRVgkxTFUM+O87thyKsGKJ6rVPbP8eoEV10cBWQ5YfaYl3qSVQ==", + "version": "3.1166.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/token-providers/-/token-providers-3.1166.0.tgz", + "integrity": "sha512-ngJ8mxXqtQ9mnp7QV6TWKJCxkpjVfPWxKQSc2FYhCyCfOVFIGdFv7P+/RqVffFrJAorwBPpktnv32gNlcEgF4g==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/nested-clients": "^3.997.47", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/types": "^4.19.0", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/nested-clients": "^3.998.3", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -276,16 +289,16 @@ } }, "node_modules/@aws-sdk/credential-provider-web-identity": { - "version": "3.972.79", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-web-identity/-/credential-provider-web-identity-3.972.79.tgz", - "integrity": "sha512-/jn0Gs/qm6fs6nTIA5yncHayybz42SATZ3rNxCEBYPJ9v69PLrDRgk07E9xTT2gpRcNmDXXbi27ZbuU06N0Z6Q==", + "version": "3.972.90", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-web-identity/-/credential-provider-web-identity-3.972.90.tgz", + "integrity": "sha512-duLeE3xlf0viHeH+1RM4z5duR3b32BCZTWVMu+MbxFPjQBxy7hmIGEqt5hekuFPRuXoyhMovjNl+PNNsb5oiGQ==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/nested-clients": "^3.997.47", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/types": "^4.19.0", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/nested-clients": "^3.998.3", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -293,14 +306,14 @@ } }, "node_modules/@aws-sdk/eventstream-handler-node": { - "version": "3.972.36", - "resolved": "https://registry.npmjs.org/@aws-sdk/eventstream-handler-node/-/eventstream-handler-node-3.972.36.tgz", - "integrity": "sha512-HFaKXA6ugPVvpR7W/3UT3hylWIPndqGMwduwNVrmGsRT5+OESHN8/ven4eeofraQF5Kxp8A8QgGVrv7iQsTRKQ==", + "version": "3.972.42", + "resolved": "https://registry.npmjs.org/@aws-sdk/eventstream-handler-node/-/eventstream-handler-node-3.972.42.tgz", + "integrity": "sha512-YVB1wrpE1WF8NvMpaRyhwm9XBYl3HTbPNEIgybi0b0XpmBrJ7Y3Y/drbxh9qAVMbR+0hcwM63GPWzhOVRuerfg==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/types": "^4.19.0", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -308,14 +321,14 @@ } }, "node_modules/@aws-sdk/middleware-eventstream": { - "version": "3.972.31", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-eventstream/-/middleware-eventstream-3.972.31.tgz", - "integrity": "sha512-4yvdTVwPGKCnrwuwlYEmwLqQXKwk0unx3f/FvBi4FA9ruK/WGoPJyqfK7hOYurheIyQL44FR0ovgOHqvkfdpAQ==", + "version": "3.972.38", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-eventstream/-/middleware-eventstream-3.972.38.tgz", + "integrity": "sha512-4K6FDz2BxH3rve8Hw/8uApWXKCuKKMeYKzY23PoiGqUBWaA23eAy+GzW9aoG3Cm7HqgYzqkljl3ECJRJCxGs7g==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/types": "^4.19.0", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -323,17 +336,17 @@ } }, "node_modules/@aws-sdk/middleware-websocket": { - "version": "3.972.55", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-websocket/-/middleware-websocket-3.972.55.tgz", - "integrity": "sha512-dHlEl3sCn1Cu+qddPoz5RxjgGCXEzs/pbrh/rDRaOeb/Tz//FF59hacDvy7kvUn19mkm2nQRjhpzBnX+Ye37Qw==", + "version": "3.972.66", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-websocket/-/middleware-websocket-3.972.66.tgz", + "integrity": "sha512-feGNDB15ZgqX4DTsUykkgj7d8hzfzx03v80EIyRA1FTbsbAJQKxYB50kRbrrpE5WeFaWhgk+p5YHlsoyXrI2/g==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/fetch-http-handler": "^5.8.0", - "@smithy/signature-v4": "^5.7.4", - "@smithy/types": "^4.19.0", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/fetch-http-handler": "^5.8.1", + "@smithy/signature-v4": "^5.7.5", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -341,33 +354,47 @@ } }, "node_modules/@aws-sdk/nested-clients": { - "version": "3.997.47", - "resolved": "https://registry.npmjs.org/@aws-sdk/nested-clients/-/nested-clients-3.997.47.tgz", - "integrity": "sha512-bovCKvDsLocNTzaj6VrrMVJ2BGROqO0JlwcGseO67a+I9Bo+08nUJhSQfZUIx4+A4a7I4101GEJd/AYm7dQ68w==", + "version": "3.998.3", + "resolved": "https://registry.npmjs.org/@aws-sdk/nested-clients/-/nested-clients-3.998.3.tgz", + "integrity": "sha512-acHTTzMB13CU6dU4sxABYExMI3PQM2zStWH2MiUwJp/7QKTrLg2f7mbzSXoegW2kYOk2tdqQYagsZrWB8Xv7eA==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/core": "^3.978.2", - "@aws-sdk/signature-v4-multi-region": "^3.996.48", - "@aws-sdk/types": "^3.974.6", - "@smithy/core": "^3.35.2", - "@smithy/fetch-http-handler": "^5.8.0", - "@smithy/node-http-handler": "^4.12.1", - "@smithy/types": "^4.19.0", + "@aws-sdk/core": "^3.981.0", + "@aws-sdk/signature-v4-multi-region": "^3.996.52", + "@aws-sdk/types": "^3.975.1", + "@smithy/core": "^3.40.0", + "@smithy/fetch-http-handler": "^5.8.1", + "@smithy/node-http-handler": "^4.14.2", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { "node": ">=20.0.0" } }, + "node_modules/@aws-sdk/nested-clients/node_modules/@smithy/node-http-handler": { + "version": "4.14.2", + "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-4.14.2.tgz", + "integrity": "sha512-i1uORV1v3qBqP43ayRKzIdm1q5x14tf8N4Dd06/QUX1Szm6VxHMrTsu20X5E63UFsaNZCRjI4SXG0jDmqYa+3w==", + "license": "Apache-2.0", + "dependencies": { + "@smithy/core": "^3.39.0", + "@smithy/types": "^4.20.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=18.0.0" + } + }, "node_modules/@aws-sdk/signature-v4-multi-region": { - "version": "3.996.48", - "resolved": "https://registry.npmjs.org/@aws-sdk/signature-v4-multi-region/-/signature-v4-multi-region-3.996.48.tgz", - "integrity": "sha512-cFDXfEbXaGwbnpvR/DyqfxfjxpjXVRVthQLgkwvcfDS5u3+8G9WSj1X1Ag/pTRg/QOeOno1Tq3ycEdrKsCUcOA==", + "version": "3.996.52", + "resolved": "https://registry.npmjs.org/@aws-sdk/signature-v4-multi-region/-/signature-v4-multi-region-3.996.52.tgz", + "integrity": "sha512-6W6SjGc8OXUhMzNxU1X922ghD+PP1XvzmCk5Scui0jaYsLezycMYR1RaLp5xTIOUrhTXyb4DnAbPr3fBgmdnzg==", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/types": "^3.974.6", - "@smithy/signature-v4": "^5.7.4", - "@smithy/types": "^4.19.0", + "@aws-sdk/types": "^3.975.1", + "@smithy/signature-v4": "^5.7.5", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -392,12 +419,12 @@ } }, "node_modules/@aws-sdk/types": { - "version": "3.974.6", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.974.6.tgz", - "integrity": "sha512-v/clNZzZnDxGyvpHMOGpJKVXFAExJzUNAAjaWGdcx8QAcXLGwTaOkw33p5SHAi0YAioK32xB3hWwOekRVfmfKg==", + "version": "3.975.1", + "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.975.1.tgz", + "integrity": "sha512-7rGxUkCB2QPoQOeJmonmAICTN2zrH+fpmi1p4Iwu72lnxNaMhOgqcbpyddifnM1DBb19TWQ1u6z/XjkaFNEDWw==", "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^4.19.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -405,12 +432,12 @@ } }, "node_modules/@aws-sdk/xml-builder": { - "version": "3.972.41", - "resolved": "https://registry.npmjs.org/@aws-sdk/xml-builder/-/xml-builder-3.972.41.tgz", - "integrity": "sha512-ctjVSyCMegrWfXlx6VqzSBFI6UqmQ5ZlnfMhdLIiWmhoH8UAQxSCP5N3OpG7X3k4LnS7ou74C4mt20+bfTW2aQ==", + "version": "3.972.43", + "resolved": "https://registry.npmjs.org/@aws-sdk/xml-builder/-/xml-builder-3.972.43.tgz", + "integrity": "sha512-rG8QVx4DOrJWptsogu1Aq+CDsnPKaBrAlJpKLxrJrIDXAq1ElnW0yQjjBnlWSXll0cDakCG6UDvaqwz0A9d9Og==", "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^4.19.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -452,21 +479,21 @@ } }, "node_modules/@babel/core": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.29.7.tgz", - "integrity": "sha512-RgHBCvtjbOK2gXSNBNIkNoEc9qoVEtau3hj8gEqKQuL3HZAibKarWFEI3Lfm6EYKkLalOh8eSrj9b+ch9H/VBA==", + "version": "7.29.13", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.29.13.tgz", + "integrity": "sha512-j1nvOQCZYSgp7HLmisnCXFTpVvFODiijQ9QHkORfGKWH6YDtskTEeCJS7eV545GZ9UBzrq0e2xsOd5QQ5PjIqw==", "dev": true, "license": "MIT", "dependencies": { "@babel/code-frame": "^7.29.7", - "@babel/generator": "^7.29.7", - "@babel/helper-compilation-targets": "^7.29.7", - "@babel/helper-module-transforms": "^7.29.7", - "@babel/helpers": "^7.29.7", - "@babel/parser": "^7.29.7", + "@babel/generator": "^7.29.13", + "@babel/helper-compilation-targets": "^7.29.13", + "@babel/helper-module-transforms": "^7.29.13", + "@babel/helpers": "^7.29.13", + "@babel/parser": "^7.29.13", "@babel/template": "^7.29.7", - "@babel/traverse": "^7.29.7", - "@babel/types": "^7.29.7", + "@babel/traverse": "^7.29.13", + "@babel/types": "^7.29.11", "@jridgewell/remapping": "^2.3.5", "convert-source-map": "^2.0.0", "debug": "^4.1.0", @@ -483,9 +510,9 @@ } }, "node_modules/@babel/core/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "version": "6.3.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.2.tgz", + "integrity": "sha512-GYrCADwpu6yV5OAvchkQ27Z5wwMxWAEMg5NNWjyHh/5DboFFqbdbvYNIvZouQpxXyeMPoTOh0vdPYKlf0ZswdQ==", "dev": true, "license": "ISC", "bin": { @@ -493,14 +520,14 @@ } }, "node_modules/@babel/generator": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.29.7.tgz", - "integrity": "sha512-DkXD5OJQaAQIdZ1bt3UZdEnHAn9Imd3IVBdX03UFe+ony9Ojw5pzr9YVKGDY1jt+Gcn/FnGkNf8r+Vj5NOJWtQ==", + "version": "7.29.15", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.29.15.tgz", + "integrity": "sha512-gNWJUX0FlevflramOkaInywOMhU1lkln38gAC7TFZv2tsWbLYbN/2WZFGcq8zbX0Z55e4vGa27IB/NaeZoauWQ==", "dev": true, "license": "MIT", "dependencies": { - "@babel/parser": "^7.29.7", - "@babel/types": "^7.29.7", + "@babel/parser": "^7.29.15", + "@babel/types": "^7.29.15", "@jridgewell/gen-mapping": "^0.3.12", "@jridgewell/trace-mapping": "^0.3.28", "jsesc": "^3.0.2" @@ -510,9 +537,9 @@ } }, "node_modules/@babel/helper-compilation-targets": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.29.7.tgz", - "integrity": "sha512-wem6WaBj4NaVYVdNhLPPVacES6ZJ+KBBfSkTMD3YZxbP3rm3Di85tJU5ljaUNhaOynt+Aj0xruhYuzQBt8n71g==", + "version": "7.29.13", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.29.13.tgz", + "integrity": "sha512-8WxJ4/Vmes3ghacj8VOJy3NW8eyHiFY/4thU/LSBuBE470+igjR/j1ZTNn8fV5VdNrLx6iXUwig526UdOvfP0w==", "dev": true, "license": "MIT", "dependencies": { @@ -527,9 +554,9 @@ } }, "node_modules/@babel/helper-compilation-targets/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "version": "6.3.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.2.tgz", + "integrity": "sha512-GYrCADwpu6yV5OAvchkQ27Z5wwMxWAEMg5NNWjyHh/5DboFFqbdbvYNIvZouQpxXyeMPoTOh0vdPYKlf0ZswdQ==", "dev": true, "license": "ISC", "bin": { @@ -561,15 +588,15 @@ } }, "node_modules/@babel/helper-module-transforms": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.29.7.tgz", - "integrity": "sha512-UPUVSyXbOh627KiCIGQSgwWzGeBKLkaJ9PJEdrngIwMSzxLR4jS4+f1f1jb7VzBbg8nFLaYotvVPFCTqdrmTAg==", + "version": "7.29.14", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.29.14.tgz", + "integrity": "sha512-2XDvQVd9JESaOgGc4jT2/jquTAO7ppA5noTZQqH+MmZ89yjCzScLwtCPbWtkPZylL+TLWR49IwWmk+QkRR4GsA==", "dev": true, "license": "MIT", "dependencies": { "@babel/helper-module-imports": "^7.29.7", "@babel/helper-validator-identifier": "^7.29.7", - "@babel/traverse": "^7.29.7" + "@babel/traverse": "^7.29.14" }, "engines": { "node": ">=6.9.0" @@ -589,9 +616,9 @@ } }, "node_modules/@babel/helper-string-parser": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.29.7.tgz", - "integrity": "sha512-Pb5ijPrZ89GDH8223L4UP8i6QApWxs04RbPQJTeWDV0/keR2E36MeKnyr6LYmUUvqRRI+Iv87SuF1W6ErINzYw==", + "version": "7.29.15", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.29.15.tgz", + "integrity": "sha512-C2FuapQ2Kh1OnVHAoLi5rD3GBJ8COb9Q609T6HEpLqaBAo560PDP5OxBE5dCI/h951MBO/+bCUYU5SZ+8ZlV+w==", "dev": true, "license": "MIT", "engines": { @@ -619,27 +646,27 @@ } }, "node_modules/@babel/helpers": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.29.7.tgz", - "integrity": "sha512-1k2lAGRMfHTcwuNYcCNUmaUffmQv8KWMfh2iJUUeRlwlwH4FdNG7mfPI10NPfLHJFThE4Tyr4mv7kTNZOiPuBg==", + "version": "7.29.15", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.29.15.tgz", + "integrity": "sha512-l+ezV2czw3t2d2ELq+3CwPL4WLKK5O8IywBXb9/gpmbCOVZFmRYJPmHVqSCv2k+8iKbE30Zf54siOoIZ52XOxA==", "dev": true, "license": "MIT", "dependencies": { "@babel/template": "^7.29.7", - "@babel/types": "^7.29.7" + "@babel/types": "^7.29.15" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/parser": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.29.7.tgz", - "integrity": "sha512-hnORnjP/1P/zFEndoeX+n+t1RwWRJiJpM/jO7FW32Kn9r5+sJB2JWOdYo4L6k78j15eCwY3Gm/7364B1EMwtNg==", + "version": "7.29.15", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.29.15.tgz", + "integrity": "sha512-RpKWyisHoP81twtSCgmE02iU0RnPcq1DN5bBEbpUePrjA9Q3wXhufnCJrrayPpoZieqFh3zyZQqwtSK0gGccRA==", "dev": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.29.7" + "@babel/types": "^7.29.15" }, "bin": { "parser": "bin/babel-parser.js" @@ -664,42 +691,10 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/plugin-transform-react-jsx-self": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.29.7.tgz", - "integrity": "sha512-TL0hMc9xzy86VD31nUiwzd5otRAcyEPcsegCxolO0PvcXuH1v0kECe/UIznYFihpkvU5wg/jk4v0TTEFfm53fw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@babel/helper-plugin-utils": "^7.29.7" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, - "node_modules/@babel/plugin-transform-react-jsx-source": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.29.7.tgz", - "integrity": "sha512-06IyK09H3wi4cGbhDBwp5gUGo0IKtnYa8tyTiephirPCK6fbobVGiXMMI5zLQ4aKEYP3wZ3ArU44o+8KMrSG/Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "@babel/helper-plugin-utils": "^7.29.7" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, "node_modules/@babel/runtime": { - "version": "7.29.10", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.29.10.tgz", - "integrity": "sha512-NpugTzbKgGrNe45Ui32cN8vCFFMxVtP/9rtfwv0nP5FRDAjvYBxJcLVpYA9mr1jxP6cnIT7x9LUzuDTbWYYNRA==", + "version": "7.29.15", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.29.15.tgz", + "integrity": "sha512-304gsbbGVmQc+cNGHzwHBlqepYdWLKj3VXCQBGt/EGcV7PUPfKI7kAUNW1FZEOCwlQiLvQjg1JEaAlRQ616h+Q==", "license": "MIT", "engines": { "node": ">=6.9.0" @@ -721,18 +716,18 @@ } }, "node_modules/@babel/traverse": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.29.7.tgz", - "integrity": "sha512-EhlfNQtZ+NK22w5BM61ciuiq1m58ed33Wr1Xan//ZRTy6hgjnwyCffRYwzsGXdASJSUJ1guZILsErh1eQcl+zw==", + "version": "7.29.15", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.29.15.tgz", + "integrity": "sha512-ZfawBo2i8vvt+BTt37dWDKBPjUfm/H+bw+ltwsCRhW7gPtyNVwUXuNo54eO2Xo+P4VXpalPFfFISbBTRKC8SOQ==", "dev": true, "license": "MIT", "dependencies": { "@babel/code-frame": "^7.29.7", - "@babel/generator": "^7.29.7", + "@babel/generator": "^7.29.15", "@babel/helper-globals": "^7.29.7", - "@babel/parser": "^7.29.7", + "@babel/parser": "^7.29.15", "@babel/template": "^7.29.7", - "@babel/types": "^7.29.7", + "@babel/types": "^7.29.15", "debug": "^4.3.1" }, "engines": { @@ -740,1960 +735,1552 @@ } }, "node_modules/@babel/types": { - "version": "7.29.7", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.29.7.tgz", - "integrity": "sha512-4zBIxpPzowiZpusoFkyGVwakdRJUyuH5PxQ/PrqghfdFWWasvnCdPfQXHrenDai+gyLARulZjZowCOj6fjT4pA==", + "version": "7.29.15", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.29.15.tgz", + "integrity": "sha512-/XKpKDakL//LZ66bq1XsZOswuqeI5MZqPLDu18o3XdkU1fNJ7bdPtzgnc4ZNS+bBGHV0FJG8jjb8SwcC3nNVQQ==", "dev": true, "license": "MIT", "dependencies": { - "@babel/helper-string-parser": "^7.29.7", + "@babel/helper-string-parser": "^7.29.15", "@babel/helper-validator-identifier": "^7.29.7" }, "engines": { "node": ">=6.9.0" } }, + "node_modules/@cacheable/memory": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@cacheable/memory/-/memory-2.2.0.tgz", + "integrity": "sha512-CTLKqLItRCEixEAewD3/j9DB3/o96gpTPD4eJ1v+DGOlxZRZncRQkGYqqnAGCscYd6RNeXfGeiuCphsPtqyIfQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@cacheable/utils": "^2.5.0", + "@keyv/bigmap": "^1.3.1", + "hookified": "^1.15.1", + "keyv": "^5.6.0" + } + }, + "node_modules/@cacheable/memory/node_modules/@keyv/bigmap": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@keyv/bigmap/-/bigmap-1.3.1.tgz", + "integrity": "sha512-WbzE9sdmQtKy8vrNPa9BRnwZh5UF4s1KTmSK0KUVLo3eff5BlQNNWDnFOouNpKfPKDnms9xynJjsMYjMaT/aFQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "hashery": "^1.4.0", + "hookified": "^1.15.0" + }, + "engines": { + "node": ">= 18" + }, + "peerDependencies": { + "keyv": "^5.6.0" + } + }, + "node_modules/@cacheable/memory/node_modules/keyv": { + "version": "5.6.0", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.6.0.tgz", + "integrity": "sha512-CYDD3SOtsHtyXeEORYRx2qBtpDJFjRTGXUtmNEMGyzYOKj1TE3tycdlho7kA1Ufx9OYWZzg52QFBGALTirzDSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@keyv/serialize": "^1.1.1" + } + }, + "node_modules/@cacheable/utils": { + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/@cacheable/utils/-/utils-2.5.0.tgz", + "integrity": "sha512-buipgOVDkkPXNR5+xBpDw7Zk2n1EvU7qBJCNUcL7rhQ//kfpOXPAvQ511Os0vpLYJ1pZnvudNytkQt2hst3wqA==", + "dev": true, + "license": "MIT", + "dependencies": { + "hashery": "^1.5.1", + "keyv": "^5.6.0" + } + }, + "node_modules/@cacheable/utils/node_modules/keyv": { + "version": "5.6.0", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.6.0.tgz", + "integrity": "sha512-CYDD3SOtsHtyXeEORYRx2qBtpDJFjRTGXUtmNEMGyzYOKj1TE3tycdlho7kA1Ufx9OYWZzg52QFBGALTirzDSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@keyv/serialize": "^1.1.1" + } + }, "node_modules/@clack/core": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/@clack/core/-/core-1.4.3.tgz", - "integrity": "sha512-/kr3UWNtdJfxZtPgDqUOmG2pvwlmcLGheex5yiZKdwbzZJxhV+HMNR9QNmyY5cGwTNV6LrR7Jtp+KjhUAP1qBQ==", + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@clack/core/-/core-1.6.0.tgz", + "integrity": "sha512-4GZynIB2IIe431odxesswvWTCP6orvqd6e2b07b3VFWBQRqUqIHc/EPIZwFoKS692QBp+ooPuXKaJV8g4kXuYA==", "license": "MIT", "dependencies": { + "fast-string-width": "^3.0.2", "fast-wrap-ansi": "^0.2.0", - "sisteransi": "^1.0.5" + "sisteransi": "^2.0.0" }, "engines": { "node": ">= 20.12.0" } }, "node_modules/@clack/prompts": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/@clack/prompts/-/prompts-1.7.0.tgz", - "integrity": "sha512-y7/yvZ2TPAnR9+jnc00klvNNLkJiXFFrQA/hlLCcxA9a2A4zQIOimyFQ9XfwYKiGD1fb5GY8vbKIIgO8d5Tb2A==", + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/@clack/prompts/-/prompts-1.9.0.tgz", + "integrity": "sha512-tEj8X2No2A1c9NDnZECxiiJ8TP3vmFlN9tLlLeSaMqVW4tUmVG2R4qpv/eP4zymWxnymYLkLcIYVV0VcWj3RCQ==", "license": "MIT", "dependencies": { - "@clack/core": "1.4.3", + "@clack/core": "1.6.0", "fast-string-width": "^3.0.2", "fast-wrap-ansi": "^0.2.0", - "sisteransi": "^1.0.5" + "sisteransi": "^2.0.0" }, "engines": { "node": ">= 20.12.0" } }, - "node_modules/@earendil-works/chord": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@earendil-works/chord/-/chord-1.1.0.tgz", - "integrity": "sha512-gsHzKfyQ3t0ZIQ3cLBjJ5Vqy1TYnFyruHIV3g3BwmulCDYe5BW4yT9vaJk9QzN6YANILIO75uzuq+Gdxtzz1og==", + "node_modules/@earendil-works/pi-agent-core": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@earendil-works/pi-agent-core/-/pi-agent-core-1.6.0.tgz", + "integrity": "sha512-IU/x+2XtE4KIdIkEndZssdLPbIUR38Btj+Q7vjIIXIK7GSamLtDH5jOw/dzBWAvWFAgZ2dslF5sPc6GcGOnS+w==", "license": "MIT", "dependencies": { - "esbuild": "0.28.2" + "@earendil-works/pi-ai": "1.6.0", + "@earendil-works/pi-schema": "1.6.0" }, "engines": { "node": ">=22.19.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/aix-ppc64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.28.2.tgz", - "integrity": "sha512-XExcO+dvLKvVtNTibSTBej1NCAbaGhWn9Ww1ZPx80qsahhPFe/8jgWP0IchNe0F3HwkU7n8ejhH8bjonqht8mQ==", - "cpu": [ - "ppc64" - ], + "node_modules/@earendil-works/pi-ai": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@earendil-works/pi-ai/-/pi-ai-1.6.0.tgz", + "integrity": "sha512-9hL+eygFDEiFp//cydeUfmFsKmEqpmvsNPb10Y1W8+m5K9O+sx1hMStfu6nukrBD5sl6mP4RykCYBBNEgsVLfw==", "license": "MIT", - "optional": true, - "os": [ - "aix" - ], + "dependencies": { + "@anthropic-ai/sdk": "0.129.0", + "@aws-sdk/client-bedrock-runtime": "3.1127.0", + "@earendil-works/pi-schema": "1.6.0", + "@earendil-works/pi-telemetry": "1.6.0", + "@google/genai": "2.32.0", + "@smithy/node-http-handler": "4.12.1", + "http-proxy-agent": "9.1.0", + "https-proxy-agent": "9.1.0", + "openai": "7.59.0", + "partial-json": "0.1.7" + }, + "bin": { + "pi-ai": "dist/cli.js" + }, "engines": { - "node": ">=18" + "node": ">=22.19.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/android-arm": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.28.2.tgz", - "integrity": "sha512-kXXoiPVVGQcnIYGOeaovwOURpniDBpSq4A03qkQ+BMQqtGG6HYap3xne9C1O1yo4TR3qxlCX5IqqmX6fFo2Lqg==", - "cpu": [ - "arm" - ], + "node_modules/@earendil-works/pi-codemode": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@earendil-works/pi-codemode/-/pi-codemode-1.6.0.tgz", + "integrity": "sha512-GAgAy7iJCVbeiuqq2dTIuNj3aXTMUeTF8Nu8LZs72e8ueGGDU5L3/D8VxzTHALIpQ1/q8u1tfmB3iYS2Nopchw==", "license": "MIT", - "optional": true, - "os": [ - "android" - ], + "dependencies": { + "quickjs-wasi": "3.6.2" + }, "engines": { - "node": ">=18" + "node": ">=22.19.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/android-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.28.2.tgz", - "integrity": "sha512-5YfKeeI8qWfBZIX+u2xZC3Zlb3Os/gLS2sbEKM+I4ZOcsWmHS2WLysCcQZDAFRslDUU5Oiq44gf6PYN1vGwG5A==", - "cpu": [ - "arm64" - ], + "node_modules/@earendil-works/pi-coding-agent": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@earendil-works/pi-coding-agent/-/pi-coding-agent-1.6.0.tgz", + "integrity": "sha512-zX1BVEsshx7A2MRuQ6jfr3RJGWw4Wn+vLq5ZfmlvS1RskhRmByaSZVXH/zcwRrWHO7qPgs98pNCbPOEti/t0fQ==", "license": "MIT", - "optional": true, - "os": [ - "android" - ], + "dependencies": { + "@earendil-works/pi-agent-core": "1.6.0", + "@earendil-works/pi-ai": "1.6.0", + "@earendil-works/pi-codemode": "1.6.0", + "@earendil-works/pi-mcp": "1.6.0", + "@earendil-works/pi-tui": "1.6.0", + "@silvia-odwyer/photon-node": "0.3.4", + "brace-expansion": "5.0.12", + "chalk": "6.0.0", + "cross-spawn": "7.0.6", + "diff": "8.0.4", + "highlight.js": "10.7.3", + "hosted-git-info": "9.0.3", + "ignore": "7.0.8", + "jiti": "2.7.0", + "lovely-mermaid": "0.3.3", + "minimatch": "11.0.3", + "proper-lockfile": "4.1.2", + "quickjs-wasi": "3.6.2", + "semver": "7.8.5", + "typebox": "1.3.27", + "undici": "8.12.4", + "yaml": "2.9.0" + }, + "bin": { + "pi": "dist/bundle/cli.js" + }, "engines": { - "node": ">=18" + "node": ">=22.19.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/android-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.28.2.tgz", - "integrity": "sha512-O387ite7SzUyCcy3JQX4P4bLtEA7bLLkx+esve5JHnyYfNTxcVpXZo9jhdB0lTKN44gztELTdU7nS8Nr16Fs1Q==", - "cpu": [ - "x64" - ], + "node_modules/@earendil-works/pi-coding-agent/node_modules/ignore": { + "version": "7.0.8", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.8.tgz", + "integrity": "sha512-YYNsSlXBjMk92SKnkwvB5LOVSa6OznlFUGcsvrFgNJbJCd0M1XKeFVRc8ZByeCqz32FivYNHJVooLmdqrmvp/Q==", "license": "MIT", - "optional": true, - "os": [ - "android" - ], "engines": { - "node": ">=18" + "node": ">= 4" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/darwin-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.28.2.tgz", - "integrity": "sha512-n4KqkOQrraxHJcgjM1RvwbigfQKIKJVpM7xp+KsxiyUSrRdIXnt73VhrPAx0fV44hgfmIVKjxMN9J1t5jySVkw==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], + "node_modules/@earendil-works/pi-coding-agent/node_modules/minimatch": { + "version": "11.0.3", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-11.0.3.tgz", + "integrity": "sha512-iny/40PEGkNJQ5/Pv6z3nm6FbRAby32GeZRjCUJk2WnNDbgPSTcdI+DDvLqsgBdD4cD5sMtMheqPPnehCCa8Nw==", + "license": "BlueOak-1.0.0", + "dependencies": { + "@isaacs/nonrecursive-glob-match": "^1.0.3", + "brace-expansion": "^5.0.12" + }, "engines": { - "node": ">=18" + "node": "18 || 20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/darwin-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.28.2.tgz", - "integrity": "sha512-uq6suIWYP37qzGddBKPw5QEQPi6HiLGsO7UmkpfyaYNQ3D+rN6w6WfwH+nuqcGXWvawGwxOEroO4YGnFh95azw==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], + "node_modules/@earendil-works/pi-coding-agent/node_modules/typebox": { + "version": "1.3.27", + "resolved": "https://registry.npmjs.org/typebox/-/typebox-1.3.27.tgz", + "integrity": "sha512-zu+jc1pcy4UiNThxikUr36f0Rybk9PEeCg/NE6adeWr/SKsdNO4EzZHYRDlv2YCVAfj3Odq3dESSo/jNyoBXzA==", + "license": "MIT" + }, + "node_modules/@earendil-works/pi-coding-agent/node_modules/yaml": { + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.9.0.tgz", + "integrity": "sha512-2AvhNX3mb8zd6Zy7INTtSpl1F15HW6Wnqj0srWlkKLcpYl/gMIMJiyuGq2KeI2YFxUPjdlB+3Lc10seMLtL4cA==", + "license": "ISC", + "bin": { + "yaml": "bin.mjs" + }, "engines": { - "node": ">=18" + "node": ">= 14.6" + }, + "funding": { + "url": "https://github.com/sponsors/eemeli" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/freebsd-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.28.2.tgz", - "integrity": "sha512-n+I0BTSRIoy+d6RPKnEVwql5UwBJolytvY4mAOIEJorKlqgPII8ix6slVVrfZ5Tnj7glIZvloylbB/EJPMWEXw==", - "cpu": [ - "arm64" - ], + "node_modules/@earendil-works/pi-mcp": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@earendil-works/pi-mcp/-/pi-mcp-1.6.0.tgz", + "integrity": "sha512-dhqAR6MP8Fp3b8LEcBFOyxMZpGSozUAdzF0Dbl7OvojsjZrQsDV3ZKn85WRbwjHb4WjQUCVBsIZXwoyQxXeunw==", "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], + "dependencies": { + "cross-spawn": "7.0.6" + }, "engines": { - "node": ">=18" + "node": ">=22.19.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/freebsd-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.28.2.tgz", - "integrity": "sha512-78XJTJkvPs0kz2w61301PJjXl4g7q3JqiYMZ/M/yVI73EHBrCRTgkhu9oqG7vPqq+a/yadEW8aD+agKlk5xrmg==", - "cpu": [ - "x64" - ], + "node_modules/@earendil-works/pi-schema": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@earendil-works/pi-schema/-/pi-schema-1.6.0.tgz", + "integrity": "sha512-jD0VRCUcFzWQ5zN82pOuoHNN42/3pu4E5krtpiKknvPq4g2m+fuO38lj+xnZhuVpYcd2G0qlmr8lE6ZMzkad7Q==", "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], "engines": { - "node": ">=18" + "node": ">=22.19.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/linux-arm": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.28.2.tgz", - "integrity": "sha512-XlDnu2q5yoqems+xay6wSAcg9DDD7K9RLKZEBOMZm3ckNpJBvOX20tSfby8KfrrhINDyv9V2YVZKY/SpoGJI8w==", - "cpu": [ - "arm" - ], + "node_modules/@earendil-works/pi-telemetry": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@earendil-works/pi-telemetry/-/pi-telemetry-1.6.0.tgz", + "integrity": "sha512-MNL0TvtpgoSfX7mBLSVgzxTW6yvT8VLEpHvbWnZsIp92FtqVvx+4q9DxWZdX8KvcQqBs0GseAgVnLdVFinjN9Q==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], "engines": { - "node": ">=18" + "node": ">=22.19.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/linux-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.28.2.tgz", - "integrity": "sha512-pW4AC0P3it8c7do9MVM4p51FzHzdM/TZrerurgRcHJ2WTa1VQ1CIq18xncfpBJw4ojkiZZrKW2yIBWBP92j6Ug==", - "cpu": [ - "arm64" - ], + "node_modules/@earendil-works/pi-tui": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@earendil-works/pi-tui/-/pi-tui-1.6.0.tgz", + "integrity": "sha512-nVtWZ4rYr3KHDla3skGAWG5XoITEUJCoEx1AsWv1yKxV7+v86ulD2hxVn/P+COI6jsoeQmj3orqHbCHZwAUsUg==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "get-east-asian-width": "1.6.0", + "marked": "18.0.11", + "marked-cjk-friendly": "0.1.2" + }, "engines": { - "node": ">=18" + "node": ">=22.19.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/linux-ia32": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.28.2.tgz", - "integrity": "sha512-CYbnj78HsIeA+DhgUKgFCfvNsTHFhMMrinUrMZpDXJXKN8T3XViTZ/+wtHeVxEWY8ewSzTFN+nRmSwO2tZaLUQ==", - "cpu": [ - "ia32" - ], + "node_modules/@electron-internal/extract-zip": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/@electron-internal/extract-zip/-/extract-zip-1.0.8.tgz", + "integrity": "sha512-8iajeLFbzNwM0m3AsQZSZgYREWglAImyGvvFSWU34FgMW8sHlzdwj9QKvv9dgN7jMP591EFUF/sLOC3Jl9YIjQ==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "linux" - ], "engines": { - "node": ">=18" + "node": ">=22.12.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/linux-loong64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.28.2.tgz", - "integrity": "sha512-buwkd8nsph4R+ajRvw0qM5Hja/TXQow3ptzWO2EbG/cqcIkHloRrdlBtQlshyYGTNFvfkfJ5tpPLVkY4DtsPfQ==", - "cpu": [ - "loong64" - ], + "node_modules/@electron-toolkit/preload": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/@electron-toolkit/preload/-/preload-3.0.2.tgz", + "integrity": "sha512-TWWPToXd8qPRfSXwzf5KVhpXMfONaUuRAZJHsKthKgZR/+LqX1dZVSSClQ8OTAEduvLGdecljCsoT2jSshfoUg==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" + "peerDependencies": { + "electron": ">=13.0.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/linux-mips64el": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.28.2.tgz", - "integrity": "sha512-ZVykbDyk7519VwiNb9Lcj9m8XM6v5V9uKPvrEMkkEedVewf+0itkhahp4HDpgERXhwLRpWFypsGbG/J8s0QjJA==", - "cpu": [ - "mips64el" - ], + "node_modules/@electron/asar": { + "version": "3.4.1", + "resolved": "https://registry.npmjs.org/@electron/asar/-/asar-3.4.1.tgz", + "integrity": "sha512-i4/rNPRS84t0vSRa2HorerGRXWyF4vThfHesw0dmcWHp+cspK743UanA0suA5Q5y8kzY2y6YKrvbIUn69BCAiA==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "commander": "^5.0.0", + "glob": "^7.1.6", + "minimatch": "^3.0.4" + }, + "bin": { + "asar": "bin/asar.js" + }, "engines": { - "node": ">=18" + "node": ">=10.12.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/linux-ppc64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.28.2.tgz", - "integrity": "sha512-CAXl+Dtd9UUuJd8pKKdwh6MLm3MUMiqMPmhZ3tTSXPqfyQ3vDl6R5hZdZ/kYojK4ofXtdfSv1tFq8XzWx3heNQ==", - "cpu": [ - "ppc64" - ], + "node_modules/@electron/asar/node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@electron/asar/node_modules/brace-expansion": { + "version": "1.1.22", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.22.tgz", + "integrity": "sha512-CKLDTuSsN0+r1ThM0WkzzBI7dnPI6xEGfa/JnVYIK9JNBA1N1NyPwXVHor//NKD/y3sDxp764sZdLhFK7pH8XQ==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/linux-riscv64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.28.2.tgz", - "integrity": "sha512-GeXCej4IQtU1B+QlDV8W/RRvbzI3O/Stss+/bCXv4lZls5WGRtu2a+3JkA3i4qIUlMXpcHebWpF8AkJhATowuA==", - "cpu": [ - "riscv64" - ], + "node_modules/@electron/asar/node_modules/commander": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-5.1.0.tgz", + "integrity": "sha512-P0CysNDQ7rtVw4QIQtm+MRxV66vKFSvlsQvGYXZWR3qFU0jlMKHZZZgw8e+8DSah4UDKMqnknRDQz+xuQXQ/Zg==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "linux" - ], "engines": { - "node": ">=18" + "node": ">= 6" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/linux-s390x": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.28.2.tgz", - "integrity": "sha512-3H1weTYZPxt/WOhByszQZybS9w5lKzUn1FDMsgEChbHWQwHYQQRfBxgCcZvPhjHfKyJjIievvMmEUawJrdY9Dg==", - "cpu": [ - "s390x" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "node_modules/@electron/asar/node_modules/minimatch": { + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.5.tgz", + "integrity": "sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, "engines": { - "node": ">=18" + "node": "*" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/linux-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.28.2.tgz", - "integrity": "sha512-4xTZr1FUmSoQW4XIWmit3tzQrUTZM+N3P0XV8xROKYF50XfI7xeO90+1bZvNwxIufQ9hDQVRJH5YhgPVF8A/HQ==", - "cpu": [ - "x64" - ], + "node_modules/@electron/fuses": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@electron/fuses/-/fuses-1.8.0.tgz", + "integrity": "sha512-zx0EIq78WlY/lBb1uXlziZmDZI4ubcCXIMJ4uGjXzZW0nS19TjSPeXPAjzzTmKQlJUZm0SbmZhPKP7tuQ1SsEw==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" + "dependencies": { + "chalk": "^4.1.1", + "fs-extra": "^9.0.1", + "minimist": "^1.2.5" + }, + "bin": { + "electron-fuses": "dist/bin.js" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/netbsd-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.28.2.tgz", - "integrity": "sha512-sSATRjPeDBg3pdgHoQfoYBob11Kk1FGa9lui5RIHZCoCkJa9QKlvl3/vKz2usCmYYjs7ymJR/2Nnsqe+Hjt5nw==", - "cpu": [ - "arm64" - ], + "node_modules/@electron/fuses/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, "engines": { - "node": ">=18" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/netbsd-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.28.2.tgz", - "integrity": "sha512-lqnzCV+mM0gIADaKihiCg6ifgfU2L3h5E33rNQBN1Y4MaVGnzryzmvvf7UHxprpQdE8hpqLolJ9Rl+SkIRDpyw==", - "cpu": [ - "x64" - ], + "node_modules/@electron/fuses/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, "engines": { - "node": ">=18" + "node": ">=10" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/openbsd-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.28.2.tgz", - "integrity": "sha512-AL2qJILH7lNjrDmCQDvdxMfAUIv8KMNZOvrwAQ8i8//ntL9FflhOyMJ8OZSMBb8/AWXe3/5v5S20y3zCoZWKoQ==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/openbsd-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.28.2.tgz", - "integrity": "sha512-QtiuPytchRyC4rwUKhexJdQKvDuZ6hWloi3igqPQNUJCS1/v9EiO3UTOXR6A3FoMo4fnAKbWJdqaIwhOzh8qEw==", - "cpu": [ - "x64" - ], + "node_modules/@electron/get": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@electron/get/-/get-5.1.0.tgz", + "integrity": "sha512-3kSBtG8ObcTVfXanm5vVJ6UnBLEVmVsRk1M+vGqCuMBV+XLCbJYuWQful+yIy0GQDsSlK0kHEriEHn7SPk4EnA==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], + "dependencies": { + "debug": "^4.1.1", + "env-paths": "^3.0.0", + "graceful-fs": "^4.2.11", + "progress": "^2.0.3", + "semver": "^7.6.3", + "sumchecker": "^3.0.1" + }, "engines": { - "node": ">=18" + "node": ">=22.12.0" + }, + "optionalDependencies": { + "undici": "^7.24.4" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/openharmony-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.28.2.tgz", - "integrity": "sha512-WkhYDmpTjLvGlScA1rwjRUmhl4k8oXR3cIbtqWmELgU/dFeHHlEllxDvdWcNJV9rbzCexB5vz8gtNewWLgCT7Q==", - "cpu": [ - "arm64" - ], + "node_modules/@electron/get/node_modules/undici": { + "version": "7.30.2", + "resolved": "https://registry.npmjs.org/undici/-/undici-7.30.2.tgz", + "integrity": "sha512-mLyPQnHwUxaM/rideoK/+KL8DaAJLRl4aBCfmX444aCSLnIaomqPLtNRe2jdCYcsk5wZzXrDIQC8ZeYNRAYyIA==", + "dev": true, "license": "MIT", "optional": true, - "os": [ - "openharmony" - ], "engines": { - "node": ">=18" + "node": ">=20.18.1" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/sunos-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.28.2.tgz", - "integrity": "sha512-GPMSkTOtMnv2U2F8gxe4Io6qmVs+YKyp832Etqqxr0hFngmXQ3rzwytelm3GIn7T4VviRUlf3sOgBOiTdvaf7g==", - "cpu": [ - "x64" - ], + "node_modules/@electron/notarize": { + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/@electron/notarize/-/notarize-2.5.0.tgz", + "integrity": "sha512-jNT8nwH1f9X5GEITXaQ8IF/KdskvIkOFfB2CvwumsveVidzpSc+mvhhTMdAGSYF3O+Nq49lJ7y+ssODRXu06+A==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "sunos" - ], + "dependencies": { + "debug": "^4.1.1", + "fs-extra": "^9.0.1", + "promise-retry": "^2.0.1" + }, "engines": { - "node": ">=18" + "node": ">= 10.0.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/win32-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.28.2.tgz", - "integrity": "sha512-PIhhEkE9uPBleRBrQEJpUn7MBnibZzbGzYWPmY3x+YoVg/95zbjB4CxPPOQ8l5tYYM4mMaCthF8/1DIfBQQyWQ==", - "cpu": [ - "arm64" - ], + "node_modules/@electron/notarize/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "win32" - ], + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, "engines": { - "node": ">=18" + "node": ">=10" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/win32-ia32": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.28.2.tgz", - "integrity": "sha512-YmJbfTlvU7Sdn9BB+4PRES4oB6pxgS37MAONj+hBr/cpXS1aBPKXxNnDbu+QCWPj0o9dgyxeq79g6c5P8KeuYA==", - "cpu": [ - "ia32" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], + "node_modules/@electron/osx-sign": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/@electron/osx-sign/-/osx-sign-1.3.3.tgz", + "integrity": "sha512-KZ8mhXvWv2rIEgMbWZ4y33bDHyUKMXnx4M0sTyPNK/vcB81ImdeY9Ggdqy0SWbMDgmbqyQ+phgejh6V3R2QuSg==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "compare-version": "^0.1.2", + "debug": "^4.3.4", + "fs-extra": "^10.0.0", + "isbinaryfile": "^4.0.8", + "minimist": "^1.2.6", + "plist": "^3.0.5" + }, + "bin": { + "electron-osx-flat": "bin/electron-osx-flat.js", + "electron-osx-sign": "bin/electron-osx-sign.js" + }, "engines": { - "node": ">=18" + "node": ">=12.0.0" } }, - "node_modules/@earendil-works/chord/node_modules/@esbuild/win32-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.28.2.tgz", - "integrity": "sha512-5ebpxr3nWMzrL/rnUI755Jkuee0bHL/Gq0WTF9lvcpv73wAp5eu8MfBUgWK9bhWvZjj7yX8etf/8tI8Ney695g==", - "cpu": [ - "x64" - ], + "node_modules/@electron/osx-sign/node_modules/isbinaryfile": { + "version": "4.0.10", + "resolved": "https://registry.npmjs.org/isbinaryfile/-/isbinaryfile-4.0.10.tgz", + "integrity": "sha512-iHrqe5shvBUcFbmZq9zOQHBoeOhZJu6RQGrDpBgenUm/Am+F3JM2MgQj+rK3Z601fzrL5gLZWtAPH2OBaSVcyw==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "win32" - ], "engines": { - "node": ">=18" + "node": ">= 8.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/gjtorikian/" } }, - "node_modules/@earendil-works/chord/node_modules/esbuild": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.28.2.tgz", - "integrity": "sha512-HKVLS8dvII+xoKW9kmqxbRKrnWEXfJJr/FZhhJmiqIB0e053QNYFqOBouTMO/k5sID4MvCiUCvv8b9M4h32wIA==", - "hasInstallScript": true, + "node_modules/@electron/rebuild": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/@electron/rebuild/-/rebuild-4.2.1.tgz", + "integrity": "sha512-IS4pG3BysRrCLJ8xTAfvg+IQDbiUoAzdJy2SfjcYKnLDy5DpCdjnPdhS5Zf5UMfrkB24xu0KC+TqcOxg+eG+6w==", + "dev": true, "license": "MIT", + "dependencies": { + "@malept/cross-spawn-promise": "^2.0.0", + "debug": "^4.1.1", + "node-abi": "^4.2.0", + "node-api-version": "^0.2.1", + "node-gyp": "^12.2.0", + "read-binary-file-arch": "^1.0.6" + }, "bin": { - "esbuild": "bin/esbuild" + "electron-rebuild": "lib/cli.js" }, "engines": { - "node": ">=18" - }, - "optionalDependencies": { - "@esbuild/aix-ppc64": "0.28.2", - "@esbuild/android-arm": "0.28.2", - "@esbuild/android-arm64": "0.28.2", - "@esbuild/android-x64": "0.28.2", - "@esbuild/darwin-arm64": "0.28.2", - "@esbuild/darwin-x64": "0.28.2", - "@esbuild/freebsd-arm64": "0.28.2", - "@esbuild/freebsd-x64": "0.28.2", - "@esbuild/linux-arm": "0.28.2", - "@esbuild/linux-arm64": "0.28.2", - "@esbuild/linux-ia32": "0.28.2", - "@esbuild/linux-loong64": "0.28.2", - "@esbuild/linux-mips64el": "0.28.2", - "@esbuild/linux-ppc64": "0.28.2", - "@esbuild/linux-riscv64": "0.28.2", - "@esbuild/linux-s390x": "0.28.2", - "@esbuild/linux-x64": "0.28.2", - "@esbuild/netbsd-arm64": "0.28.2", - "@esbuild/netbsd-x64": "0.28.2", - "@esbuild/openbsd-arm64": "0.28.2", - "@esbuild/openbsd-x64": "0.28.2", - "@esbuild/openharmony-arm64": "0.28.2", - "@esbuild/sunos-x64": "0.28.2", - "@esbuild/win32-arm64": "0.28.2", - "@esbuild/win32-ia32": "0.28.2", - "@esbuild/win32-x64": "0.28.2" + "node": ">=22.12.0" } }, - "node_modules/@earendil-works/pi-agent-core": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@earendil-works/pi-agent-core/-/pi-agent-core-1.1.0.tgz", - "integrity": "sha512-aX1KZomNCPmwYnXa3OivF3VYLJ+WPUkIJlEIZTgwdOZdY/+oToWTQ334WYpQeOz9POpiYFNMJLPwIhXQ4e48kg==", + "node_modules/@electron/universal": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@electron/universal/-/universal-2.0.3.tgz", + "integrity": "sha512-Wn9sPYIVFRFl5HmwMJkARCCf7rqK/EurkfQ/rJZ14mHP3iYTjZSIOSVonEAnhWeAXwtw7zOekGRlc6yTtZ0t+g==", + "dev": true, "license": "MIT", "dependencies": { - "@earendil-works/pi-ai": "^1.1.0", - "typebox": "1.3.27" + "@electron/asar": "^3.3.1", + "@malept/cross-spawn-promise": "^2.0.0", + "debug": "^4.3.1", + "dir-compare": "^4.2.0", + "fs-extra": "^11.1.1", + "minimatch": "^9.0.3", + "plist": "^3.1.0" }, "engines": { - "node": ">=22.19.0" + "node": ">=16.4" } }, - "node_modules/@earendil-works/pi-ai": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@earendil-works/pi-ai/-/pi-ai-1.1.0.tgz", - "integrity": "sha512-1T7LAkc/5Bvc0v6w4vAGVdCrli0o/E0pEmYKTnixu95vSFArBjvbhS/G4ZwI0RUePgf0Imcu0VyqlM4EcXxqfw==", + "node_modules/@electron/universal/node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@electron/universal/node_modules/brace-expansion": { + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.8.tgz", + "integrity": "sha512-BnlDzDYQoplTsZSvPi86CNzmbcb07X8ufR8fk1zivaiEJlXJkiq1MQyDCVmlWcsWbj6aWXqHnrwwevbrm/Saig==", + "dev": true, "license": "MIT", "dependencies": { - "@anthropic-ai/sdk": "0.129.0", - "@aws-sdk/client-bedrock-runtime": "3.1127.0", - "@earendil-works/pi-telemetry": "^1.1.0", - "@google/genai": "2.21.0", - "@smithy/node-http-handler": "4.12.1", - "http-proxy-agent": "9.1.0", - "https-proxy-agent": "9.1.0", - "openai": "7.19.0", - "partial-json": "0.1.7", - "typebox": "1.3.27" - }, - "bin": { - "pi-ai": "dist/cli.js" - }, - "engines": { - "node": ">=22.19.0" + "balanced-match": "^1.0.0" } }, - "node_modules/@earendil-works/pi-ai/node_modules/agent-base": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-9.0.0.tgz", - "integrity": "sha512-TQf59BsZnytt8GdJKLPfUZ54g/iaUL2OWDSFCCvMOhsHduDQxO8xC4PNeyIkVcA5KwL2phPSv0douC0fgWzmnA==", + "node_modules/@electron/universal/node_modules/fs-extra": { + "version": "11.4.1", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.4.1.tgz", + "integrity": "sha512-KYAb4c9BJQI6QqGKthV68OHe0badztdXJWKo0WtBA9IuCFPTKvE5ZdUBglP833aMjhaSPNO4A5j/EkzZtGlKjA==", + "dev": true, "license": "MIT", + "dependencies": { + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, "engines": { - "node": ">= 20" + "node": ">=14.14" } }, - "node_modules/@earendil-works/pi-ai/node_modules/http-proxy-agent": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-9.1.0.tgz", - "integrity": "sha512-2NxoveTT58mjYT4n3RPTEfCZGLMbidoO8XEieXfpSYxu+PQJ1qpx4ypwH6N+uF9twBPIvRRgvkvW5HUTYWENig==", - "license": "MIT", + "node_modules/@electron/universal/node_modules/minimatch": { + "version": "9.0.9", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.9.tgz", + "integrity": "sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg==", + "dev": true, + "license": "ISC", "dependencies": { - "agent-base": "9.0.0", - "debug": "^4.3.4", - "proxy-agent-negotiate": "1.1.0" + "brace-expansion": "^2.0.2" }, "engines": { - "node": ">= 20" - } + "node": ">=16 || 14 >=14.17" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } }, - "node_modules/@earendil-works/pi-ai/node_modules/https-proxy-agent": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-9.1.0.tgz", - "integrity": "sha512-ag87y7cJJ9/3+GxFr8Oy4O5faDsGRGnBGsJj/YjOSsSx/5eadKLYTMPlzuR6obgoCDDm0abAAZitXXQkMOPSpA==", - "license": "MIT", + "node_modules/@electron/windows-sign": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/@electron/windows-sign/-/windows-sign-1.2.2.tgz", + "integrity": "sha512-dfZeox66AvdPtb2lD8OsIIQh12Tp0GNCRUDfBHIKGpbmopZto2/A8nSpYYLoedPIHpqkeblZ/k8OV0Gy7PYuyQ==", + "dev": true, + "license": "BSD-2-Clause", + "optional": true, + "peer": true, "dependencies": { - "agent-base": "9.0.0", + "cross-dirname": "^0.1.0", "debug": "^4.3.4", - "proxy-agent-negotiate": "1.1.0" + "fs-extra": "^11.1.1", + "minimist": "^1.2.8", + "postject": "^1.0.0-alpha.6" + }, + "bin": { + "electron-windows-sign": "bin/electron-windows-sign.js" }, "engines": { - "node": ">= 20" + "node": ">=14.14" } }, - "node_modules/@earendil-works/pi-codemode": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@earendil-works/pi-codemode/-/pi-codemode-1.1.0.tgz", - "integrity": "sha512-8Asc2AzhoNaXS1snmRFa96OhcWIlFM5k1Kuiz6p2DvIYgi5QHQccRAmDVY9oO92TzWrizpvQpconZGQ7JhlI7Q==", + "node_modules/@electron/windows-sign/node_modules/fs-extra": { + "version": "11.4.1", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.4.1.tgz", + "integrity": "sha512-KYAb4c9BJQI6QqGKthV68OHe0badztdXJWKo0WtBA9IuCFPTKvE5ZdUBglP833aMjhaSPNO4A5j/EkzZtGlKjA==", + "dev": true, "license": "MIT", + "optional": true, + "peer": true, "dependencies": { - "quickjs-wasi": "3.6.2" + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" }, "engines": { - "node": ">=22.19.0" + "node": ">=14.14" } }, - "node_modules/@earendil-works/pi-coding-agent": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@earendil-works/pi-coding-agent/-/pi-coding-agent-1.1.0.tgz", - "integrity": "sha512-SeEi/4hdcHNgA9UWlefZl7ZZpm3dzi2OoxNjDHsBJ9o298LNOtbL4DGKgitlEj6uCTccvtw6f2hlCkTPVJ2RXg==", + "node_modules/@emnapi/core": { + "version": "2.0.0-beta.2", + "resolved": "https://registry.npmjs.org/@emnapi/core/-/core-2.0.0-beta.2.tgz", + "integrity": "sha512-MzCVoWtcg4Pm2B3je5mMvYMvj3MmBKw+fU7vbsJc9/iT8ip6/eYIHo/Dsm/mr+wsHB6SEyJDuxB09Yy6r/8+4A==", + "dev": true, "license": "MIT", + "optional": true, "dependencies": { - "@earendil-works/chord": "^1.1.0", - "@earendil-works/pi-agent-core": "^1.1.0", - "@earendil-works/pi-ai": "^1.1.0", - "@earendil-works/pi-codemode": "^1.1.0", - "@earendil-works/pi-mcp": "^1.1.0", - "@earendil-works/pi-tui": "^1.1.0", - "@silvia-odwyer/photon-node": "0.3.4", - "brace-expansion": "5.0.12", - "chalk": "6.0.0", - "cross-spawn": "7.0.6", - "diff": "8.0.4", - "grok-mermaid": "0.2.3", - "highlight.js": "10.7.3", - "hosted-git-info": "9.0.3", - "ignore": "7.0.8", - "jiti": "2.7.0", - "minimatch": "10.2.6", - "proper-lockfile": "4.1.2", - "quickjs-wasi": "3.6.2", - "semver": "7.8.5", - "typebox": "1.3.27", - "undici": "8.10.2", - "yaml": "2.9.0" - }, - "bin": { - "pi": "dist/bundle/cli.js" - }, - "engines": { - "node": ">=22.19.0" + "@emnapi/wasi-threads": "2.2.0", + "tslib": "^2.4.0" } }, - "node_modules/@earendil-works/pi-coding-agent/node_modules/@silvia-odwyer/photon-node": { - "version": "0.3.4", - "resolved": "https://registry.npmjs.org/@silvia-odwyer/photon-node/-/photon-node-0.3.4.tgz", - "integrity": "sha512-bnly4BKB3KDTFxrUIcgCLbaeVVS8lrAkri1pEzskpmxu9MdfGQTy8b8EgcD83ywD3RPMsIulY8xJH5Awa+t9fA==", - "license": "Apache-2.0" - }, - "node_modules/@earendil-works/pi-coding-agent/node_modules/chalk": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-6.0.0.tgz", - "integrity": "sha512-2uNTXIuTTxk7ciZgAU1BQcgnchcG0xXnrs6jzkQfj9SsRa9M2s5zE8WT96hS6KmG4MzWHSrvH43DF1m4XRkrFg==", + "node_modules/@emnapi/runtime": { + "version": "1.11.3", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.11.3.tgz", + "integrity": "sha512-Xz4Tpyki7XyrpbUK1jR1AhdAdaXyhhY4lZ3neLodmhpuWfy2PAQN5B46sAiU4liOXGLkHypn/qU+jvfWSCYYLA==", "license": "MIT", - "engines": { - "node": ">=22" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "optional": true, + "dependencies": { + "tslib": "^2.4.0" } }, - "node_modules/@earendil-works/pi-coding-agent/node_modules/grok-mermaid": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/grok-mermaid/-/grok-mermaid-0.2.3.tgz", - "integrity": "sha512-/4KopAbsjvuRP9MdPtlDjOHUmUVEohOX73JNcsWpzAtFxh+bq5+Dhb6gzvRieLDwIPQIR3/vy8V1NNTuz4Zsmg==", - "license": "Apache-2.0", - "engines": { - "node": ">=18" + "node_modules/@emnapi/wasi-threads": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@emnapi/wasi-threads/-/wasi-threads-2.2.0.tgz", + "integrity": "sha512-JP7OYH38Q7+pyTAe14raZHLQIK7BDKbdwji+Xi3pcd/6QkJYQH3SX4wu6EplGrGJWRepoNzedfm0G3B9Z4e9Rw==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "tslib": "^2.4.0" } }, - "node_modules/@earendil-works/pi-coding-agent/node_modules/highlight.js": { - "version": "10.7.3", - "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-10.7.3.tgz", - "integrity": "sha512-tzcUFauisWKNHaRkN4Wjl/ZA07gENAjFl3J/c480dprkGTg5EQstgaNFqBfUqCq54kZRIEcreTsAgF/m2quD7A==", - "license": "BSD-3-Clause", + "node_modules/@esbuild/aix-ppc64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.28.2.tgz", + "integrity": "sha512-XExcO+dvLKvVtNTibSTBej1NCAbaGhWn9Ww1ZPx80qsahhPFe/8jgWP0IchNe0F3HwkU7n8ejhH8bjonqht8mQ==", + "cpu": [ + "ppc64" + ], + "license": "MIT", + "optional": true, + "os": [ + "aix" + ], "engines": { - "node": "*" + "node": ">=18" } }, - "node_modules/@earendil-works/pi-coding-agent/node_modules/hosted-git-info": { - "version": "9.0.3", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-9.0.3.tgz", - "integrity": "sha512-Hc+ghLoSt6QaYZUv0WBiIvmMDZuZZ7oaDvdH8MbfOO4lOsxdXLEvuC6ePoGs9H1X9oCLyq6+NVN0MKqD+ydxyg==", - "license": "ISC", - "dependencies": { - "lru-cache": "^11.1.0" - }, + "node_modules/@esbuild/android-arm": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.28.2.tgz", + "integrity": "sha512-kXXoiPVVGQcnIYGOeaovwOURpniDBpSq4A03qkQ+BMQqtGG6HYap3xne9C1O1yo4TR3qxlCX5IqqmX6fFo2Lqg==", + "cpu": [ + "arm" + ], + "license": "MIT", + "optional": true, + "os": [ + "android" + ], "engines": { - "node": "^20.17.0 || >=22.9.0" + "node": ">=18" } }, - "node_modules/@earendil-works/pi-coding-agent/node_modules/ignore": { - "version": "7.0.8", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.8.tgz", - "integrity": "sha512-YYNsSlXBjMk92SKnkwvB5LOVSa6OznlFUGcsvrFgNJbJCd0M1XKeFVRc8ZByeCqz32FivYNHJVooLmdqrmvp/Q==", + "node_modules/@esbuild/android-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.28.2.tgz", + "integrity": "sha512-5YfKeeI8qWfBZIX+u2xZC3Zlb3Os/gLS2sbEKM+I4ZOcsWmHS2WLysCcQZDAFRslDUU5Oiq44gf6PYN1vGwG5A==", + "cpu": [ + "arm64" + ], "license": "MIT", + "optional": true, + "os": [ + "android" + ], "engines": { - "node": ">= 4" + "node": ">=18" } }, - "node_modules/@earendil-works/pi-coding-agent/node_modules/lru-cache": { - "version": "11.4.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-11.4.0.tgz", - "integrity": "sha512-W+R+kFL4HgVxONq2bhXPi3bGpzGe/yEhVOp233qw9wCRtgncJ15P3bC+e4zZMu4Cq7d+WAJjXGW0uUkifhcatA==", - "license": "BlueOak-1.0.0", + "node_modules/@esbuild/android-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.28.2.tgz", + "integrity": "sha512-O387ite7SzUyCcy3JQX4P4bLtEA7bLLkx+esve5JHnyYfNTxcVpXZo9jhdB0lTKN44gztELTdU7nS8Nr16Fs1Q==", + "cpu": [ + "x64" + ], + "license": "MIT", + "optional": true, + "os": [ + "android" + ], "engines": { - "node": "20 || >=22" + "node": ">=18" } }, - "node_modules/@earendil-works/pi-coding-agent/node_modules/minimatch": { - "version": "10.2.6", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.6.tgz", - "integrity": "sha512-vpLQEs+VLCr1nU0BXS07maYoFwlDAH0gngQuuttxIwutDFEMHq2blX+8vpgxDdK3J1PwjCJiep77OitTZ4Ll1A==", - "license": "BlueOak-1.0.0", - "dependencies": { - "brace-expansion": "^5.0.8" - }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.28.2.tgz", + "integrity": "sha512-n4KqkOQrraxHJcgjM1RvwbigfQKIKJVpM7xp+KsxiyUSrRdIXnt73VhrPAx0fV44hgfmIVKjxMN9J1t5jySVkw==", + "cpu": [ + "arm64" + ], + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], "engines": { - "node": "18 || 20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" + "node": ">=18" } }, - "node_modules/@earendil-works/pi-coding-agent/node_modules/undici": { - "version": "8.10.2", - "resolved": "https://registry.npmjs.org/undici/-/undici-8.10.2.tgz", - "integrity": "sha512-/y4/bH9YNU5hi9NIrpOuvGXFcxrj3CMrV+/AYpowAYTpHn8gX/XPFjNy766FPoYY0miQhdW977JFWKGNhBdwyQ==", + "node_modules/@esbuild/darwin-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.28.2.tgz", + "integrity": "sha512-uq6suIWYP37qzGddBKPw5QEQPi6HiLGsO7UmkpfyaYNQ3D+rN6w6WfwH+nuqcGXWvawGwxOEroO4YGnFh95azw==", + "cpu": [ + "x64" + ], "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], "engines": { - "node": ">=22.19.0" + "node": ">=18" } }, - "node_modules/@earendil-works/pi-mcp": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@earendil-works/pi-mcp/-/pi-mcp-1.1.0.tgz", - "integrity": "sha512-xGKwvu3SvVTeoIx8Z7UGoJprB4VK20wKORMhufcWGx61fIauhu3J+UqfB5eeoF1oE/geYBA598K6nh1SdABQkg==", + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.28.2.tgz", + "integrity": "sha512-n+I0BTSRIoy+d6RPKnEVwql5UwBJolytvY4mAOIEJorKlqgPII8ix6slVVrfZ5Tnj7glIZvloylbB/EJPMWEXw==", + "cpu": [ + "arm64" + ], "license": "MIT", - "dependencies": { - "cross-spawn": "7.0.6" - }, + "optional": true, + "os": [ + "freebsd" + ], "engines": { - "node": ">=22.19.0" + "node": ">=18" } }, - "node_modules/@earendil-works/pi-telemetry": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@earendil-works/pi-telemetry/-/pi-telemetry-1.1.0.tgz", - "integrity": "sha512-8gAK05/2pPozZZz6hCLOi8x2vsqzvsmO9gG92kbvuvTPm0qMHaFlaXX98ndXsrOi5pmzha7vNLguuG4+0Rgxjw==", + "node_modules/@esbuild/freebsd-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.28.2.tgz", + "integrity": "sha512-78XJTJkvPs0kz2w61301PJjXl4g7q3JqiYMZ/M/yVI73EHBrCRTgkhu9oqG7vPqq+a/yadEW8aD+agKlk5xrmg==", + "cpu": [ + "x64" + ], "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], "engines": { - "node": ">=22.19.0" + "node": ">=18" } }, - "node_modules/@earendil-works/pi-tui": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@earendil-works/pi-tui/-/pi-tui-1.1.0.tgz", - "integrity": "sha512-v7wkS0y2ErZvZkSfemqd9RrBZJ5x6p8Ujsv7NdJj01IXJyFM0kNL6rMdcKcvTe7EVTd6ugvDB9VPZSoaBF9QxQ==", + "node_modules/@esbuild/linux-arm": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.28.2.tgz", + "integrity": "sha512-XlDnu2q5yoqems+xay6wSAcg9DDD7K9RLKZEBOMZm3ckNpJBvOX20tSfby8KfrrhINDyv9V2YVZKY/SpoGJI8w==", + "cpu": [ + "arm" + ], "license": "MIT", - "dependencies": { - "get-east-asian-width": "1.6.0", - "marked": "18.0.11" - }, + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=22.19.0" + "node": ">=18" } }, - "node_modules/@electron-internal/extract-zip": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@electron-internal/extract-zip/-/extract-zip-1.0.3.tgz", - "integrity": "sha512-OjKpjB7gohtEjZiq6nDx1egqjZJhGPN1iFOIED+NFhB/MMkXw/XRcHjh1DGXKT5z2W9eW7Jy2UKU3gpjvusFTQ==", - "dev": true, - "license": "BSD-2-Clause", + "node_modules/@esbuild/linux-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.28.2.tgz", + "integrity": "sha512-pW4AC0P3it8c7do9MVM4p51FzHzdM/TZrerurgRcHJ2WTa1VQ1CIq18xncfpBJw4ojkiZZrKW2yIBWBP92j6Ug==", + "cpu": [ + "arm64" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=22.12.0" + "node": ">=18" } }, - "node_modules/@electron-toolkit/preload": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/@electron-toolkit/preload/-/preload-3.0.2.tgz", - "integrity": "sha512-TWWPToXd8qPRfSXwzf5KVhpXMfONaUuRAZJHsKthKgZR/+LqX1dZVSSClQ8OTAEduvLGdecljCsoT2jSshfoUg==", - "dev": true, + "node_modules/@esbuild/linux-ia32": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.28.2.tgz", + "integrity": "sha512-CYbnj78HsIeA+DhgUKgFCfvNsTHFhMMrinUrMZpDXJXKN8T3XViTZ/+wtHeVxEWY8ewSzTFN+nRmSwO2tZaLUQ==", + "cpu": [ + "ia32" + ], "license": "MIT", - "peerDependencies": { - "electron": ">=13.0.0" + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" } }, - "node_modules/@electron/asar": { - "version": "3.4.1", - "resolved": "https://registry.npmjs.org/@electron/asar/-/asar-3.4.1.tgz", - "integrity": "sha512-i4/rNPRS84t0vSRa2HorerGRXWyF4vThfHesw0dmcWHp+cspK743UanA0suA5Q5y8kzY2y6YKrvbIUn69BCAiA==", - "dev": true, + "node_modules/@esbuild/linux-loong64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.28.2.tgz", + "integrity": "sha512-buwkd8nsph4R+ajRvw0qM5Hja/TXQow3ptzWO2EbG/cqcIkHloRrdlBtQlshyYGTNFvfkfJ5tpPLVkY4DtsPfQ==", + "cpu": [ + "loong64" + ], "license": "MIT", - "dependencies": { - "commander": "^5.0.0", - "glob": "^7.1.6", - "minimatch": "^3.0.4" - }, - "bin": { - "asar": "bin/asar.js" - }, + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=10.12.0" + "node": ">=18" } }, - "node_modules/@electron/asar/node_modules/balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@electron/asar/node_modules/brace-expansion": { - "version": "1.1.16", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.16.tgz", - "integrity": "sha512-IDw48K2/2kRkg9LdJxurvq3lV3aBgq0REY89duEqFRthjlPdXHKMj7EnQOXVckxzgisinf3nHfrcE2FufFLXMw==", - "dev": true, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.28.2.tgz", + "integrity": "sha512-ZVykbDyk7519VwiNb9Lcj9m8XM6v5V9uKPvrEMkkEedVewf+0itkhahp4HDpgERXhwLRpWFypsGbG/J8s0QjJA==", + "cpu": [ + "mips64el" + ], "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/@electron/asar/node_modules/minimatch": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.5.tgz", - "integrity": "sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" - }, + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": "*" + "node": ">=18" } }, - "node_modules/@electron/fuses": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/@electron/fuses/-/fuses-1.8.0.tgz", - "integrity": "sha512-zx0EIq78WlY/lBb1uXlziZmDZI4ubcCXIMJ4uGjXzZW0nS19TjSPeXPAjzzTmKQlJUZm0SbmZhPKP7tuQ1SsEw==", - "dev": true, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.28.2.tgz", + "integrity": "sha512-CAXl+Dtd9UUuJd8pKKdwh6MLm3MUMiqMPmhZ3tTSXPqfyQ3vDl6R5hZdZ/kYojK4ofXtdfSv1tFq8XzWx3heNQ==", + "cpu": [ + "ppc64" + ], "license": "MIT", - "dependencies": { - "chalk": "^4.1.1", - "fs-extra": "^9.0.1", - "minimist": "^1.2.5" - }, - "bin": { - "electron-fuses": "dist/bin.js" + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" } }, - "node_modules/@electron/fuses/node_modules/fs-extra": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", - "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", - "dev": true, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.28.2.tgz", + "integrity": "sha512-GeXCej4IQtU1B+QlDV8W/RRvbzI3O/Stss+/bCXv4lZls5WGRtu2a+3JkA3i4qIUlMXpcHebWpF8AkJhATowuA==", + "cpu": [ + "riscv64" + ], "license": "MIT", - "dependencies": { - "at-least-node": "^1.0.0", - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=10" + "node": ">=18" } }, - "node_modules/@electron/get": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/@electron/get/-/get-5.0.0.tgz", - "integrity": "sha512-pjoBpru1KdEtcExBnuHAP1cAc/5faoedw0hzJkL3o4/IJp7HNF1+fbrdxT3gMYRX2oJfvnA/WXeCTVQpYYxyJA==", - "dev": true, + "node_modules/@esbuild/linux-s390x": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.28.2.tgz", + "integrity": "sha512-3H1weTYZPxt/WOhByszQZybS9w5lKzUn1FDMsgEChbHWQwHYQQRfBxgCcZvPhjHfKyJjIievvMmEUawJrdY9Dg==", + "cpu": [ + "s390x" + ], "license": "MIT", - "dependencies": { - "debug": "^4.1.1", - "env-paths": "^3.0.0", - "graceful-fs": "^4.2.11", - "progress": "^2.0.3", - "semver": "^7.6.3", - "sumchecker": "^3.0.1" - }, + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=22.12.0" - }, - "optionalDependencies": { - "undici": "^7.24.4" + "node": ">=18" } }, - "node_modules/@electron/notarize": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/@electron/notarize/-/notarize-2.5.0.tgz", - "integrity": "sha512-jNT8nwH1f9X5GEITXaQ8IF/KdskvIkOFfB2CvwumsveVidzpSc+mvhhTMdAGSYF3O+Nq49lJ7y+ssODRXu06+A==", - "dev": true, + "node_modules/@esbuild/linux-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.28.2.tgz", + "integrity": "sha512-4xTZr1FUmSoQW4XIWmit3tzQrUTZM+N3P0XV8xROKYF50XfI7xeO90+1bZvNwxIufQ9hDQVRJH5YhgPVF8A/HQ==", + "cpu": [ + "x64" + ], "license": "MIT", - "dependencies": { - "debug": "^4.1.1", - "fs-extra": "^9.0.1", - "promise-retry": "^2.0.1" - }, + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">= 10.0.0" + "node": ">=18" } }, - "node_modules/@electron/notarize/node_modules/fs-extra": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", - "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", - "dev": true, + "node_modules/@esbuild/netbsd-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.28.2.tgz", + "integrity": "sha512-sSATRjPeDBg3pdgHoQfoYBob11Kk1FGa9lui5RIHZCoCkJa9QKlvl3/vKz2usCmYYjs7ymJR/2Nnsqe+Hjt5nw==", + "cpu": [ + "arm64" + ], "license": "MIT", - "dependencies": { - "at-least-node": "^1.0.0", - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, + "optional": true, + "os": [ + "netbsd" + ], "engines": { - "node": ">=10" + "node": ">=18" } }, - "node_modules/@electron/osx-sign": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/@electron/osx-sign/-/osx-sign-1.3.3.tgz", - "integrity": "sha512-KZ8mhXvWv2rIEgMbWZ4y33bDHyUKMXnx4M0sTyPNK/vcB81ImdeY9Ggdqy0SWbMDgmbqyQ+phgejh6V3R2QuSg==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "compare-version": "^0.1.2", - "debug": "^4.3.4", - "fs-extra": "^10.0.0", - "isbinaryfile": "^4.0.8", - "minimist": "^1.2.6", - "plist": "^3.0.5" - }, - "bin": { - "electron-osx-flat": "bin/electron-osx-flat.js", - "electron-osx-sign": "bin/electron-osx-sign.js" - }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.28.2.tgz", + "integrity": "sha512-lqnzCV+mM0gIADaKihiCg6ifgfU2L3h5E33rNQBN1Y4MaVGnzryzmvvf7UHxprpQdE8hpqLolJ9Rl+SkIRDpyw==", + "cpu": [ + "x64" + ], + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], "engines": { - "node": ">=12.0.0" + "node": ">=18" } }, - "node_modules/@electron/osx-sign/node_modules/isbinaryfile": { - "version": "4.0.10", - "resolved": "https://registry.npmjs.org/isbinaryfile/-/isbinaryfile-4.0.10.tgz", - "integrity": "sha512-iHrqe5shvBUcFbmZq9zOQHBoeOhZJu6RQGrDpBgenUm/Am+F3JM2MgQj+rK3Z601fzrL5gLZWtAPH2OBaSVcyw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 8.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/gjtorikian/" - } - }, - "node_modules/@electron/rebuild": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@electron/rebuild/-/rebuild-4.2.0.tgz", - "integrity": "sha512-RKL/O+jGoXJMxrx/5771y1n0xTKmFuOYGO3gMmwypBM6rsH0kou0mswwdXA2JrhIkE4xyC7v9vGk0n6NPzgOxQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@malept/cross-spawn-promise": "^2.0.0", - "debug": "^4.1.1", - "node-abi": "^4.2.0", - "node-api-version": "^0.2.1", - "node-gyp": "^12.2.0", - "read-binary-file-arch": "^1.0.6" - }, - "bin": { - "electron-rebuild": "lib/cli.js" - }, - "engines": { - "node": ">=22.12.0" - } - }, - "node_modules/@electron/universal": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@electron/universal/-/universal-2.0.3.tgz", - "integrity": "sha512-Wn9sPYIVFRFl5HmwMJkARCCf7rqK/EurkfQ/rJZ14mHP3iYTjZSIOSVonEAnhWeAXwtw7zOekGRlc6yTtZ0t+g==", - "dev": true, - "license": "MIT", - "dependencies": { - "@electron/asar": "^3.3.1", - "@malept/cross-spawn-promise": "^2.0.0", - "debug": "^4.3.1", - "dir-compare": "^4.2.0", - "fs-extra": "^11.1.1", - "minimatch": "^9.0.3", - "plist": "^3.1.0" - }, - "engines": { - "node": ">=16.4" - } - }, - "node_modules/@electron/universal/node_modules/balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@electron/universal/node_modules/brace-expansion": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.2.tgz", - "integrity": "sha512-w5JZcKgdhDOgOwm8H+KgbosopHMuGcl6qbulwjtz3SM7I7P3yW1eAjzMPLrIE+NQ9vjgANKHWeMHnrT0OXW1oA==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/@electron/universal/node_modules/fs-extra": { - "version": "11.3.6", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.3.6.tgz", - "integrity": "sha512-w8ZNZr2mKIc7qeNaQ9AVPT1+iFaI+Avd4xudVOvdDJ8VytREi1Ft5Ih7hd9jjehod8vAM5GMsfQ/TpPf4EyoEA==", - "dev": true, - "license": "MIT", - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, - "engines": { - "node": ">=14.14" - } - }, - "node_modules/@electron/universal/node_modules/minimatch": { - "version": "9.0.9", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.9.tgz", - "integrity": "sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.2" - }, - "engines": { - "node": ">=16 || 14 >=14.17" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/@electron/windows-sign": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/@electron/windows-sign/-/windows-sign-1.2.2.tgz", - "integrity": "sha512-dfZeox66AvdPtb2lD8OsIIQh12Tp0GNCRUDfBHIKGpbmopZto2/A8nSpYYLoedPIHpqkeblZ/k8OV0Gy7PYuyQ==", - "dev": true, - "license": "BSD-2-Clause", - "optional": true, - "peer": true, - "dependencies": { - "cross-dirname": "^0.1.0", - "debug": "^4.3.4", - "fs-extra": "^11.1.1", - "minimist": "^1.2.8", - "postject": "^1.0.0-alpha.6" - }, - "bin": { - "electron-windows-sign": "bin/electron-windows-sign.js" - }, - "engines": { - "node": ">=14.14" - } - }, - "node_modules/@electron/windows-sign/node_modules/fs-extra": { - "version": "11.3.6", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.3.6.tgz", - "integrity": "sha512-w8ZNZr2mKIc7qeNaQ9AVPT1+iFaI+Avd4xudVOvdDJ8VytREi1Ft5Ih7hd9jjehod8vAM5GMsfQ/TpPf4EyoEA==", - "dev": true, - "license": "MIT", - "optional": true, - "peer": true, - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, - "engines": { - "node": ">=14.14" - } - }, - "node_modules/@emnapi/runtime": { - "version": "1.11.3", - "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.11.3.tgz", - "integrity": "sha512-Xz4Tpyki7XyrpbUK1jR1AhdAdaXyhhY4lZ3neLodmhpuWfy2PAQN5B46sAiU4liOXGLkHypn/qU+jvfWSCYYLA==", - "license": "MIT", - "optional": true, - "dependencies": { - "tslib": "^2.4.0" - } - }, - "node_modules/@esbuild/aix-ppc64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.12.tgz", - "integrity": "sha512-Hhmwd6CInZ3dwpuGTF8fJG6yoWmsToE+vYgD4nytZVxcu1ulHpUQRAB1UJ8+N1Am3Mz4+xOByoQoSZf4D+CpkA==", + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.28.2.tgz", + "integrity": "sha512-AL2qJILH7lNjrDmCQDvdxMfAUIv8KMNZOvrwAQ8i8//ntL9FflhOyMJ8OZSMBb8/AWXe3/5v5S20y3zCoZWKoQ==", "cpu": [ - "ppc64" + "arm64" ], - "dev": true, "license": "MIT", "optional": true, "os": [ - "aix" + "openbsd" ], "engines": { "node": ">=18" } }, - "node_modules/@esbuild/android-arm": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.12.tgz", - "integrity": "sha512-VJ+sKvNA/GE7Ccacc9Cha7bpS8nyzVv0jdVgwNDaR4gDMC/2TTRc33Ip8qrNYUcpkOHUT5OZ0bUcNNVZQ9RLlg==", + "node_modules/@esbuild/openbsd-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.28.2.tgz", + "integrity": "sha512-QtiuPytchRyC4rwUKhexJdQKvDuZ6hWloi3igqPQNUJCS1/v9EiO3UTOXR6A3FoMo4fnAKbWJdqaIwhOzh8qEw==", "cpu": [ - "arm" + "x64" ], - "dev": true, "license": "MIT", "optional": true, "os": [ - "android" + "openbsd" ], "engines": { "node": ">=18" } }, - "node_modules/@esbuild/android-arm64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.12.tgz", - "integrity": "sha512-6AAmLG7zwD1Z159jCKPvAxZd4y/VTO0VkprYy+3N2FtJ8+BQWFXU+OxARIwA46c5tdD9SsKGZ/1ocqBS/gAKHg==", + "node_modules/@esbuild/openharmony-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.28.2.tgz", + "integrity": "sha512-WkhYDmpTjLvGlScA1rwjRUmhl4k8oXR3cIbtqWmELgU/dFeHHlEllxDvdWcNJV9rbzCexB5vz8gtNewWLgCT7Q==", "cpu": [ "arm64" ], - "dev": true, "license": "MIT", "optional": true, "os": [ - "android" + "openharmony" ], "engines": { "node": ">=18" } }, - "node_modules/@esbuild/android-x64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.12.tgz", - "integrity": "sha512-5jbb+2hhDHx5phYR2By8GTWEzn6I9UqR11Kwf22iKbNpYrsmRB18aX/9ivc5cabcUiAT/wM+YIZ6SG9QO6a8kg==", + "node_modules/@esbuild/sunos-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.28.2.tgz", + "integrity": "sha512-GPMSkTOtMnv2U2F8gxe4Io6qmVs+YKyp832Etqqxr0hFngmXQ3rzwytelm3GIn7T4VviRUlf3sOgBOiTdvaf7g==", "cpu": [ "x64" ], - "dev": true, "license": "MIT", "optional": true, "os": [ - "android" + "sunos" ], "engines": { "node": ">=18" } }, - "node_modules/@esbuild/darwin-arm64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.12.tgz", - "integrity": "sha512-N3zl+lxHCifgIlcMUP5016ESkeQjLj/959RxxNYIthIg+CQHInujFuXeWbWMgnTo4cp5XVHqFPmpyu9J65C1Yg==", + "node_modules/@esbuild/win32-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.28.2.tgz", + "integrity": "sha512-PIhhEkE9uPBleRBrQEJpUn7MBnibZzbGzYWPmY3x+YoVg/95zbjB4CxPPOQ8l5tYYM4mMaCthF8/1DIfBQQyWQ==", "cpu": [ "arm64" ], - "dev": true, "license": "MIT", "optional": true, "os": [ - "darwin" + "win32" ], "engines": { "node": ">=18" } }, - "node_modules/@esbuild/darwin-x64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.12.tgz", - "integrity": "sha512-HQ9ka4Kx21qHXwtlTUVbKJOAnmG1ipXhdWTmNXiPzPfWKpXqASVcWdnf2bnL73wgjNrFXAa3yYvBSd9pzfEIpA==", + "node_modules/@esbuild/win32-ia32": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.28.2.tgz", + "integrity": "sha512-YmJbfTlvU7Sdn9BB+4PRES4oB6pxgS37MAONj+hBr/cpXS1aBPKXxNnDbu+QCWPj0o9dgyxeq79g6c5P8KeuYA==", "cpu": [ - "x64" + "ia32" ], - "dev": true, "license": "MIT", "optional": true, "os": [ - "darwin" + "win32" ], "engines": { "node": ">=18" } }, - "node_modules/@esbuild/freebsd-arm64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.12.tgz", - "integrity": "sha512-gA0Bx759+7Jve03K1S0vkOu5Lg/85dou3EseOGUes8flVOGxbhDDh/iZaoek11Y8mtyKPGF3vP8XhnkDEAmzeg==", + "node_modules/@esbuild/win32-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.28.2.tgz", + "integrity": "sha512-5ebpxr3nWMzrL/rnUI755Jkuee0bHL/Gq0WTF9lvcpv73wAp5eu8MfBUgWK9bhWvZjj7yX8etf/8tI8Ney695g==", "cpu": [ - "arm64" + "x64" ], - "dev": true, "license": "MIT", "optional": true, "os": [ - "freebsd" + "win32" ], "engines": { "node": ">=18" } }, - "node_modules/@esbuild/freebsd-x64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.12.tgz", - "integrity": "sha512-TGbO26Yw2xsHzxtbVFGEXBFH0FRAP7gtcPE7P5yP7wGy7cXK2oO7RyOhL5NLiqTlBh47XhmIUXuGciXEqYFfBQ==", - "cpu": [ - "x64" - ], + "node_modules/@eslint-community/eslint-utils": { + "version": "4.10.1", + "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.10.1.tgz", + "integrity": "sha512-cuadcxVFE8sDK6iWJbs8Sn0av2Nrh2QSGQhVlBW9AaAHqHwjWsZHT8LJ4hFGPh7ASBV2deFdM7H/DPjulmh8rg==", "dev": true, "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], + "dependencies": { + "eslint-visitor-keys": "^3.4.3" + }, "engines": { - "node": ">=18" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + }, + "peerDependencies": { + "eslint": "^6.0.0 || ^7.0.0 || >=8.0.0" } }, - "node_modules/@esbuild/linux-arm": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.12.tgz", - "integrity": "sha512-lPDGyC1JPDou8kGcywY0YILzWlhhnRjdof3UlcoqYmS9El818LLfJJc3PXXgZHrHCAKs/Z2SeZtDJr5MrkxtOw==", - "cpu": [ - "arm" - ], + "node_modules/@eslint-community/regexpp": { + "version": "4.12.3", + "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.12.3.tgz", + "integrity": "sha512-R76UKbvsqI68DJJVTVyqFKqU98CN4+B+acxNfEA2IFarSzP0SjtKf/3+fFiXzTyv5Fj3PxLkGHe2wnVWWMxobQ==", "dev": true, "license": "MIT", - "optional": true, - "os": [ - "linux" - ], "engines": { - "node": ">=18" + "node": "^12.0.0 || ^14.0.0 || >=16.0.0" } }, - "node_modules/@esbuild/linux-arm64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.12.tgz", - "integrity": "sha512-8bwX7a8FghIgrupcxb4aUmYDLp8pX06rGh5HqDT7bB+8Rdells6mHvrFHHW2JAOPZUbnjUpKTLg6ECyzvas2AQ==", - "cpu": [ - "arm64" - ], + "node_modules/@eslint/config-array": { + "version": "0.23.6", + "resolved": "https://registry.npmjs.org/@eslint/config-array/-/config-array-0.23.6.tgz", + "integrity": "sha512-WrTH7nioI9QPY4NZGnsywmecswJdgeq4BCM76qok9VgjTO29ZgUzUvcuJLVPYVQM4uDbaPBU0M33R9DIxI8X3w==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "license": "Apache-2.0", + "dependencies": { + "@eslint/object-schema": "^3.0.5", + "debug": "^4.3.1", + "minimatch": "^11.0.5" + }, "engines": { - "node": ">=18" + "node": "^20.19.0 || ^22.13.0 || >=24" } }, - "node_modules/@esbuild/linux-ia32": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.12.tgz", - "integrity": "sha512-0y9KrdVnbMM2/vG8KfU0byhUN+EFCny9+8g202gYqSSVMonbsCfLjUO+rCci7pM0WBEtz+oK/PIwHkzxkyharA==", - "cpu": [ - "ia32" - ], + "node_modules/@eslint/config-array/node_modules/minimatch": { + "version": "11.0.9", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-11.0.9.tgz", + "integrity": "sha512-KCFkfyjqerNlSstjlhIGNXIKZGA/6O4V4RlhZ+Dsr621SPPw0mzlypE9D9ZOoPiVefHID+j7/XuMMlqfD/F60Q==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "license": "BlueOak-1.0.0", + "dependencies": { + "@isaacs/nonrecursive-glob-match": "^1.1.0", + "brace-expansion": "^5.0.12" + }, "engines": { - "node": ">=18" + "node": "20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/@esbuild/linux-loong64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.12.tgz", - "integrity": "sha512-h///Lr5a9rib/v1GGqXVGzjL4TMvVTv+s1DPoxQdz7l/AYv6LDSxdIwzxkrPW438oUXiDtwM10o9PmwS/6Z0Ng==", - "cpu": [ - "loong64" - ], + "node_modules/@eslint/config-helpers": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/@eslint/config-helpers/-/config-helpers-0.7.0.tgz", + "integrity": "sha512-DObd/KKUsU+FaFv4PLxSRenpXfQWmPXXP3pPZ6/K1PCrMu2vQpMDMuQe/BqYeoLcz8ro0bVDF1RxOJgfVEdhUw==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "license": "Apache-2.0", + "dependencies": { + "@eslint/core": "^1.2.1" + }, "engines": { - "node": ">=18" + "node": "^20.19.0 || ^22.13.0 || >=24" } }, - "node_modules/@esbuild/linux-mips64el": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.12.tgz", - "integrity": "sha512-iyRrM1Pzy9GFMDLsXn1iHUm18nhKnNMWscjmp4+hpafcZjrr2WbT//d20xaGljXDBYHqRcl8HnxbX6uaA/eGVw==", - "cpu": [ - "mips64el" - ], + "node_modules/@eslint/core": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@eslint/core/-/core-1.2.1.tgz", + "integrity": "sha512-MwcE1P+AZ4C6DWlpin/OmOA54mmIZ/+xZuJiQd4SyB29oAJjN30UW9wkKNptW2ctp4cEsvhlLY/CsQ1uoHDloQ==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "license": "Apache-2.0", + "dependencies": { + "@types/json-schema": "^7.0.15" + }, "engines": { - "node": ">=18" + "node": "^20.19.0 || ^22.13.0 || >=24" } }, - "node_modules/@esbuild/linux-ppc64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.12.tgz", - "integrity": "sha512-9meM/lRXxMi5PSUqEXRCtVjEZBGwB7P/D4yT8UG/mwIdze2aV4Vo6U5gD3+RsoHXKkHCfSxZKzmDssVlRj1QQA==", - "cpu": [ - "ppc64" - ], + "node_modules/@eslint/js": { + "version": "10.0.1", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-10.0.1.tgz", + "integrity": "sha512-zeR9k5pd4gxjZ0abRoIaxdc7I3nDktoXZk2qOv9gCNWx3mVwEn32VRhyLaRsDiJjTs0xq/T8mfPtyuXu7GWBcA==", "dev": true, "license": "MIT", - "optional": true, - "os": [ - "linux" - ], "engines": { - "node": ">=18" + "node": "^20.19.0 || ^22.13.0 || >=24" + }, + "funding": { + "url": "https://eslint.org/donate" + }, + "peerDependencies": { + "eslint": "^10.0.0" + }, + "peerDependenciesMeta": { + "eslint": { + "optional": true + } } }, - "node_modules/@esbuild/linux-riscv64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.12.tgz", - "integrity": "sha512-Zr7KR4hgKUpWAwb1f3o5ygT04MzqVrGEGXGLnj15YQDJErYu/BGg+wmFlIDOdJp0PmB0lLvxFIOXZgFRrdjR0w==", - "cpu": [ - "riscv64" - ], + "node_modules/@eslint/object-schema": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@eslint/object-schema/-/object-schema-3.0.5.tgz", + "integrity": "sha512-vqTaUEgxzm+YDSdElad6PiRoX4t8VGDjCtt05zn4nU810UIx/uNEV7/lZJ6KwFThKZOzOxzXy48da+No7HZaMw==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "license": "Apache-2.0", "engines": { - "node": ">=18" + "node": "^20.19.0 || ^22.13.0 || >=24" } }, - "node_modules/@esbuild/linux-s390x": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.12.tgz", - "integrity": "sha512-MsKncOcgTNvdtiISc/jZs/Zf8d0cl/t3gYWX8J9ubBnVOwlk65UIEEvgBORTiljloIWnBzLs4qhzPkJcitIzIg==", - "cpu": [ - "s390x" - ], + "node_modules/@eslint/plugin-kit": { + "version": "0.7.3", + "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.7.3.tgz", + "integrity": "sha512-IkO+/KEUvwbVpiURZg+P7zF74z5Jxe0UgJxVni+RtoHQ6IZieXaO02kmadomap/q+l6bc/jdPGGqTjhuZnuz1Q==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "license": "Apache-2.0", + "dependencies": { + "@eslint/core": "^1.2.1", + "levn": "^0.4.1" + }, "engines": { - "node": ">=18" + "node": "^20.19.0 || ^22.13.0 || >=24" } }, - "node_modules/@esbuild/linux-x64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.12.tgz", - "integrity": "sha512-uqZMTLr/zR/ed4jIGnwSLkaHmPjOjJvnm6TVVitAa08SLS9Z0VM8wIRx7gWbJB5/J54YuIMInDquWyYvQLZkgw==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "node_modules/@google/genai": { + "version": "2.32.0", + "resolved": "https://registry.npmjs.org/@google/genai/-/genai-2.32.0.tgz", + "integrity": "sha512-60c79uXpR0a47bmGqDxbXEBuQUalNmwo5mx5kqb91jIW4FoqpsLSt86DeVhRhtH5+s/16Wqxt3sXzFQn2U1OHQ==", + "hasInstallScript": true, + "license": "Apache-2.0", + "dependencies": { + "google-auth-library": "^10.3.0", + "p-retry": "^4.6.2", + "protobufjs": "^7.5.4", + "ws": "^8.18.0" + }, "engines": { - "node": ">=18" + "node": ">=20.0.0" + }, + "peerDependencies": { + "@modelcontextprotocol/sdk": "^1.25.2" + }, + "peerDependenciesMeta": { + "@modelcontextprotocol/sdk": { + "optional": true + } } }, - "node_modules/@esbuild/netbsd-arm64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.12.tgz", - "integrity": "sha512-xXwcTq4GhRM7J9A8Gv5boanHhRa/Q9KLVmcyXHCTaM4wKfIpWkdXiMog/KsnxzJ0A1+nD+zoecuzqPmCRyBGjg==", - "cpu": [ - "arm64" - ], - "dev": true, + "node_modules/@hono/node-server": { + "version": "2.1.11", + "resolved": "https://registry.npmjs.org/@hono/node-server/-/node-server-2.1.11.tgz", + "integrity": "sha512-KzKz9vl4vvr1vgLHamj+g5uonbrj5NwAdO3yzOS6cd2HjALVeOgTgeZOyAzNxejbkfOOPIcvuf/Tg8l1pEFLog==", "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], "engines": { - "node": ">=18" + "node": ">=20" + }, + "peerDependencies": { + "hono": "^4 || ^5.0.0-0" } }, - "node_modules/@esbuild/netbsd-x64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.12.tgz", - "integrity": "sha512-Ld5pTlzPy3YwGec4OuHh1aCVCRvOXdH8DgRjfDy/oumVovmuSzWfnSJg+VtakB9Cm0gxNO9BzWkj6mtO1FMXkQ==", - "cpu": [ - "x64" - ], - "dev": true, + "node_modules/@huggingface/jinja": { + "version": "0.5.13", + "resolved": "https://registry.npmjs.org/@huggingface/jinja/-/jinja-0.5.13.tgz", + "integrity": "sha512-jM17MqFily1iyT/1LD3r5w8/CZiyapVB0+7vOw48PfVtzyKsXStmHE4jVTyDAD05Tqv3un1xrS9ILUU1ugQAYQ==", "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], "engines": { "node": ">=18" } }, - "node_modules/@esbuild/openbsd-arm64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.12.tgz", - "integrity": "sha512-fF96T6KsBo/pkQI950FARU9apGNTSlZGsv1jZBAlcLL1MLjLNIWPBkj5NlSz8aAzYKg+eNqknrUJ24QBybeR5A==", - "cpu": [ - "arm64" - ], + "node_modules/@huggingface/tokenizers": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@huggingface/tokenizers/-/tokenizers-0.2.0.tgz", + "integrity": "sha512-LidMHe1FpcSYH4vcSjXooda34pC0M8m1gmDOv7SQi6Iv+ib1zX7J3sHBCC9/3FPCkn2k1b55FneVqMRxrr99pg==", + "license": "Apache-2.0" + }, + "node_modules/@huggingface/transformers": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/@huggingface/transformers/-/transformers-4.3.2.tgz", + "integrity": "sha512-V3+dqf3iWlRYJ9I9GreM3zGQd0lAXnnoPeddmkOQYWAEE4l/+Fi6p7tx/qVUJlKQgLXGim2W76rTOzz+eC0i7g==", + "license": "Apache-2.0", + "dependencies": { + "@huggingface/jinja": "^0.5.10", + "@huggingface/tokenizers": "^0.2.0", + "onnxruntime-node": "1.30.0", + "onnxruntime-web": "1.31.0-dev.20260914-8d85527a0", + "sharp": "^0.35.4" + } + }, + "node_modules/@humanfs/core": { + "version": "0.19.2", + "resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.2.tgz", + "integrity": "sha512-UhXNm+CFMWcbChXywFwkmhqjs3PRCmcSa/hfBgLIb7oQ5HNb1wS0icWsGtSAUNgefHeI+eBrA8I1fxmbHsGdvA==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], + "license": "Apache-2.0", + "dependencies": { + "@humanfs/types": "^0.15.0" + }, "engines": { - "node": ">=18" + "node": ">=18.18.0" } }, - "node_modules/@esbuild/openbsd-x64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.12.tgz", - "integrity": "sha512-MZyXUkZHjQxUvzK7rN8DJ3SRmrVrke8ZyRusHlP+kuwqTcfWLyqMOE3sScPPyeIXN/mDJIfGXvcMqCgYKekoQw==", - "cpu": [ - "x64" - ], + "node_modules/@humanfs/node": { + "version": "0.16.8", + "resolved": "https://registry.npmjs.org/@humanfs/node/-/node-0.16.8.tgz", + "integrity": "sha512-gE1eQNZ3R++kTzFUpdGlpmy8kDZD/MLyHqDwqjkVQI0JMdI1D51sy1H958PNXYkM2rAac7e5/CnIKZrHtPh3BQ==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], + "license": "Apache-2.0", + "dependencies": { + "@humanfs/core": "^0.19.2", + "@humanfs/types": "^0.15.0", + "@humanwhocodes/retry": "^0.4.0" + }, "engines": { - "node": ">=18" + "node": ">=18.18.0" } }, - "node_modules/@esbuild/openharmony-arm64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.25.12.tgz", - "integrity": "sha512-rm0YWsqUSRrjncSXGA7Zv78Nbnw4XL6/dzr20cyrQf7ZmRcsovpcRBdhD43Nuk3y7XIoW2OxMVvwuRvk9XdASg==", - "cpu": [ - "arm64" - ], + "node_modules/@humanfs/types": { + "version": "0.15.0", + "resolved": "https://registry.npmjs.org/@humanfs/types/-/types-0.15.0.tgz", + "integrity": "sha512-ZZ1w0aoQkwuUuC7Yf+7sdeaNfqQiiLcSRbfI08oAxqLtpXQr9AIVX7Ay7HLDuiLYAaFPu8oBYNq/QIi9URHJ3Q==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openharmony" - ], + "license": "Apache-2.0", "engines": { - "node": ">=18" + "node": ">=18.18.0" } }, - "node_modules/@esbuild/sunos-x64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.12.tgz", - "integrity": "sha512-3wGSCDyuTHQUzt0nV7bocDy72r2lI33QL3gkDNGkod22EsYl04sMf0qLb8luNKTOmgF/eDEDP5BFNwoBKH441w==", - "cpu": [ - "x64" - ], + "node_modules/@humanwhocodes/module-importer": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", + "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "sunos" - ], + "license": "Apache-2.0", "engines": { - "node": ">=18" + "node": ">=12.22" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/nzakas" } }, - "node_modules/@esbuild/win32-arm64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.12.tgz", - "integrity": "sha512-rMmLrur64A7+DKlnSuwqUdRKyd3UE7oPJZmnljqEptesKM8wx9J8gx5u0+9Pq0fQQW8vqeKebwNXdfOyP+8Bsg==", - "cpu": [ - "arm64" - ], + "node_modules/@humanwhocodes/retry": { + "version": "0.4.3", + "resolved": "https://registry.npmjs.org/@humanwhocodes/retry/-/retry-0.4.3.tgz", + "integrity": "sha512-bV0Tgo9K4hfPCek+aMAn81RppFKv2ySDQeMoSZuvTASywNTnVJCArCZE2FWqpvIatKu7VMRLWlR1EazvVhDyhQ==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], + "license": "Apache-2.0", "engines": { - "node": ">=18" + "node": ">=18.18" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/nzakas" } }, - "node_modules/@esbuild/win32-ia32": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.12.tgz", - "integrity": "sha512-HkqnmmBoCbCwxUKKNPBixiWDGCpQGVsrQfJoVGYLPT41XWF8lHuE5N6WhVia2n4o5QK5M4tYr21827fNhi4byQ==", - "cpu": [ - "ia32" - ], - "dev": true, + "node_modules/@img/colour": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@img/colour/-/colour-1.1.0.tgz", + "integrity": "sha512-Td76q7j57o/tLVdgS746cYARfSyxk8iEfRxewL9h4OMzYhbW4TAcppl0mT4eyqXddh6L/jwoM75mo7ixa/pCeQ==", "license": "MIT", - "optional": true, - "os": [ - "win32" - ], "engines": { "node": ">=18" } }, - "node_modules/@esbuild/win32-x64": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.12.tgz", - "integrity": "sha512-alJC0uCZpTFrSL0CCDjcgleBXPnCrEAhTBILpeAp7M/OFgoqtAetfBzX0xM00MUsVVPpVjlPuMbREqnZCXaTnA==", + "node_modules/@img/sharp-darwin-arm64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.35.5.tgz", + "integrity": "sha512-QRUlFQ0WxvdWyqqG/WtI3iupfD5rBzmCHXSdPsY91sAtVtTo7Q4cb6zOccZ3gqEqkr0f1As1ehLqmEpDsRf+lg==", "cpu": [ - "x64" + "arm64" ], - "dev": true, - "license": "MIT", + "license": "Apache-2.0", "optional": true, "os": [ - "win32" + "darwin" ], "engines": { - "node": ">=18" - } - }, - "node_modules/@eslint-community/eslint-utils": { - "version": "4.9.1", - "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.9.1.tgz", - "integrity": "sha512-phrYmNiYppR7znFEdqgfWHXR6NCkZEK7hwWDHZUjit/2/U0r6XvkDl0SYnoM51Hq7FhCGdLDT6zxCCOY1hexsQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "eslint-visitor-keys": "^3.4.3" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": ">=20.9.0" }, "funding": { - "url": "https://opencollective.com/eslint" + "url": "https://opencollective.com/libvips" }, - "peerDependencies": { - "eslint": "^6.0.0 || ^7.0.0 || >=8.0.0" - } - }, - "node_modules/@eslint-community/regexpp": { - "version": "4.12.2", - "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.12.2.tgz", - "integrity": "sha512-EriSTlt5OC9/7SXkRSCAhfSxxoSUgBm33OH+IkwbdpgoqsSsUg7y3uh+IICI/Qg4BBWr3U2i39RpmycbxMq4ew==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.0.0 || ^14.0.0 || >=16.0.0" + "optionalDependencies": { + "@img/sharp-libvips-darwin-arm64": "1.3.4" } }, - "node_modules/@eslint/config-array": { - "version": "0.21.2", - "resolved": "https://registry.npmjs.org/@eslint/config-array/-/config-array-0.21.2.tgz", - "integrity": "sha512-nJl2KGTlrf9GjLimgIru+V/mzgSK0ABCDQRvxw5BjURL7WfH5uoWmizbH7QB6MmnMBd8cIC9uceWnezL1VZWWw==", - "dev": true, + "node_modules/@img/sharp-darwin-x64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.35.5.tgz", + "integrity": "sha512-+BR255RhDlpygUpOc/Jdt1nT6DQ3XG/ERo5wbcdOf5Q320dKtPCKPLR1LJs9VGXRaMa8l1uUa0tkCNOXiAxZUw==", + "cpu": [ + "x64" + ], "license": "Apache-2.0", - "dependencies": { - "@eslint/object-schema": "^2.1.7", - "debug": "^4.3.1", - "minimatch": "^3.1.5" - }, + "optional": true, + "os": [ + "darwin" + ], "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/config-array/node_modules/balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@eslint/config-array/node_modules/brace-expansion": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.15.tgz", - "integrity": "sha512-EwOCDEex4quD37XhqM3omwtMoJjr//isUZz1JopUNWms+4Z2ViyM/k1YIRePpoVNnQhENnxtFjLaxNHrT7xIUg==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/@eslint/config-array/node_modules/minimatch": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.5.tgz", - "integrity": "sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" + "node": ">=20.9.0" }, - "engines": { - "node": "*" - } - }, - "node_modules/@eslint/config-helpers": { - "version": "0.4.2", - "resolved": "https://registry.npmjs.org/@eslint/config-helpers/-/config-helpers-0.4.2.tgz", - "integrity": "sha512-gBrxN88gOIf3R7ja5K9slwNayVcZgK6SOUORm2uBzTeIEfeVaIhOpCtTox3P6R7o2jLFwLFTLnC7kU/RGcYEgw==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@eslint/core": "^0.17.0" + "funding": { + "url": "https://opencollective.com/libvips" }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "optionalDependencies": { + "@img/sharp-libvips-darwin-x64": "1.3.4" } }, - "node_modules/@eslint/core": { - "version": "0.17.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.17.0.tgz", - "integrity": "sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==", - "dev": true, + "node_modules/@img/sharp-freebsd-wasm32": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-freebsd-wasm32/-/sharp-freebsd-wasm32-0.35.5.tgz", + "integrity": "sha512-Y/z91nEZ4uIBX5X3nfTovjU9lHNKFYbL2lpHCLVNmXQK03VIZvXBBt0KxbPGp2SdGSF+2mQU4e+hQaWOt86iAw==", "license": "Apache-2.0", + "optional": true, + "os": [ + "freebsd" + ], "dependencies": { - "@types/json-schema": "^7.0.15" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@eslint/eslintrc": { - "version": "3.3.5", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-3.3.5.tgz", - "integrity": "sha512-4IlJx0X0qftVsN5E+/vGujTRIFtwuLbNsVUe7TO6zYPDR1O6nFwvwhIKEKSrl6dZchmYBITazxKoUYOjdtjlRg==", - "dev": true, - "license": "MIT", - "dependencies": { - "ajv": "^6.14.0", - "debug": "^4.3.2", - "espree": "^10.0.1", - "globals": "^14.0.0", - "ignore": "^5.2.0", - "import-fresh": "^3.2.1", - "js-yaml": "^4.1.1", - "minimatch": "^3.1.5", - "strip-json-comments": "^3.1.1" + "@img/sharp-wasm32": "0.35.5" }, "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node": ">=20.9.0" }, "funding": { - "url": "https://opencollective.com/eslint" + "url": "https://opencollective.com/libvips" } }, - "node_modules/@eslint/eslintrc/node_modules/balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@eslint/eslintrc/node_modules/brace-expansion": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.15.tgz", - "integrity": "sha512-EwOCDEex4quD37XhqM3omwtMoJjr//isUZz1JopUNWms+4Z2ViyM/k1YIRePpoVNnQhENnxtFjLaxNHrT7xIUg==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" + "node_modules/@img/sharp-libvips-darwin-arm64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.3.4.tgz", + "integrity": "sha512-5R89nBYiRdUlSWJxPhO+GVtaXzXSxKnRu/xqMn3KTA3L9EB9Oy/P+Nn2f2vlhPuUdy/Zusb2DarbyTpGCfEDuw==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" } }, - "node_modules/@eslint/eslintrc/node_modules/ignore": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", - "integrity": "sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 4" + "node_modules/@img/sharp-libvips-darwin-x64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.3.4.tgz", + "integrity": "sha512-iR2OKH80yi0U+dUplyh3/xdpFvps6YkCwsXenIJxqxR1v9o+xtKTGbS9H7cps+2Vxjc8B1j96p75NmTGjIhtpQ==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" } }, - "node_modules/@eslint/eslintrc/node_modules/minimatch": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.5.tgz", - "integrity": "sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" + "node_modules/@img/sharp-libvips-linux-arm": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.3.4.tgz", + "integrity": "sha512-LmRtTsOHuvM2+wlO2Db37dx5MiZhB0FvSunciw48YjdOkZz9KAiRbm8ujeMOA1INqmei5NapFxYEK1D1ZSidmw==", + "cpu": [ + "arm" + ], + "libc": [ + "glibc" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" } }, - "node_modules/@eslint/js": { - "version": "9.39.4", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.39.4.tgz", - "integrity": "sha512-nE7DEIchvtiFTwBw4Lfbu59PG+kCofhjsKaCWzxTpt4lfRjRMqG6uMBzKXuEcyXhOHoUp9riAm7/aWYGhXZ9cw==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, + "node_modules/@img/sharp-libvips-linux-arm64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.3.4.tgz", + "integrity": "sha512-Y3dgX/6lE2QhQb+Gxy0WZxfg9MEm/JBjamZpS2IklP7xIQoKN4hzAm7KcMVGtaVDt3neE9OKBC7vAfonA/Lr1A==", + "cpu": [ + "arm64" + ], + "libc": [ + "glibc" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], "funding": { - "url": "https://eslint.org/donate" + "url": "https://opencollective.com/libvips" } }, - "node_modules/@eslint/object-schema": { - "version": "2.1.7", - "resolved": "https://registry.npmjs.org/@eslint/object-schema/-/object-schema-2.1.7.tgz", - "integrity": "sha512-VtAOaymWVfZcmZbp6E2mympDIHvyjXs/12LqWYjVw6qjrfF+VK+fyG33kChz3nnK+SU5/NeHOqrTEHS8sXO3OA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node_modules/@img/sharp-libvips-linux-ppc64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-ppc64/-/sharp-libvips-linux-ppc64-1.3.4.tgz", + "integrity": "sha512-Le6boB8Tai0Nis+gIxIpKx68UDVVIqdR8Tin5Yf1z2LJJQLDJvCDRqRu+jC2qCoD+eIomonmOwB4smBRxfVpYQ==", + "cpu": [ + "ppc64" + ], + "libc": [ + "glibc" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" } }, - "node_modules/@eslint/plugin-kit": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.1.tgz", - "integrity": "sha512-43/qtrDUokr7LJqoF2c3+RInu/t4zfrpYdoSDfYyhg52rwLV6TnOvdG4fXm7IkSB3wErkcmJS9iEhjVtOSEjjA==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@eslint/core": "^0.17.0", - "levn": "^0.4.1" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, - "node_modules/@google/genai": { - "version": "2.21.0", - "resolved": "https://registry.npmjs.org/@google/genai/-/genai-2.21.0.tgz", - "integrity": "sha512-+PDtco2/Z0ONdzCGekCoCT+O1VJS9xJQNN4XzQpXG/t3El/SWWMkCWlFRO1KmivOHPa4Q0VjUYu1HBKCZ/v33Q==", - "hasInstallScript": true, - "license": "Apache-2.0", - "dependencies": { - "google-auth-library": "^10.3.0", - "p-retry": "^4.6.2", - "protobufjs": "^7.5.4", - "ws": "^8.18.0" - }, - "engines": { - "node": ">=20.0.0" - }, - "peerDependencies": { - "@modelcontextprotocol/sdk": "^1.25.2" - }, - "peerDependenciesMeta": { - "@modelcontextprotocol/sdk": { - "optional": true - } - } - }, - "node_modules/@huggingface/jinja": { - "version": "0.5.10", - "resolved": "https://registry.npmjs.org/@huggingface/jinja/-/jinja-0.5.10.tgz", - "integrity": "sha512-SgS1D1bglQ94ceD4ZCL6eayUDy9uV1xuyk61OjgSxU5GJh7upqZCKII0JoTYMc6wWsg3JUgaPRX0ElQzXPk3Cw==", - "license": "MIT", - "engines": { - "node": ">=18" - } - }, - "node_modules/@huggingface/tokenizers": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/@huggingface/tokenizers/-/tokenizers-0.2.0.tgz", - "integrity": "sha512-LidMHe1FpcSYH4vcSjXooda34pC0M8m1gmDOv7SQi6Iv+ib1zX7J3sHBCC9/3FPCkn2k1b55FneVqMRxrr99pg==", - "license": "Apache-2.0" - }, - "node_modules/@huggingface/transformers": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/@huggingface/transformers/-/transformers-4.3.1.tgz", - "integrity": "sha512-5+voSeUCFK6PCKlY15dPhNOKq3/zOTxDN7oC+Wy9dFb1QZ0TSQomZRRy7URRK8YRuUoE9fGMQTTPC5d/pWBJhA==", - "license": "Apache-2.0", - "dependencies": { - "@huggingface/jinja": "^0.5.10", - "@huggingface/tokenizers": "^0.2.0", - "onnxruntime-node": "1.30.0", - "onnxruntime-web": "1.31.0-dev.20260914-8d85527a0", - "sharp": "^0.35.4" - } - }, - "node_modules/@humanfs/core": { - "version": "0.19.2", - "resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.2.tgz", - "integrity": "sha512-UhXNm+CFMWcbChXywFwkmhqjs3PRCmcSa/hfBgLIb7oQ5HNb1wS0icWsGtSAUNgefHeI+eBrA8I1fxmbHsGdvA==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@humanfs/types": "^0.15.0" - }, - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanfs/node": { - "version": "0.16.8", - "resolved": "https://registry.npmjs.org/@humanfs/node/-/node-0.16.8.tgz", - "integrity": "sha512-gE1eQNZ3R++kTzFUpdGlpmy8kDZD/MLyHqDwqjkVQI0JMdI1D51sy1H958PNXYkM2rAac7e5/CnIKZrHtPh3BQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@humanfs/core": "^0.19.2", - "@humanfs/types": "^0.15.0", - "@humanwhocodes/retry": "^0.4.0" - }, - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanfs/types": { - "version": "0.15.0", - "resolved": "https://registry.npmjs.org/@humanfs/types/-/types-0.15.0.tgz", - "integrity": "sha512-ZZ1w0aoQkwuUuC7Yf+7sdeaNfqQiiLcSRbfI08oAxqLtpXQr9AIVX7Ay7HLDuiLYAaFPu8oBYNq/QIi9URHJ3Q==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanwhocodes/module-importer": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", - "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=12.22" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" - } - }, - "node_modules/@humanwhocodes/retry": { - "version": "0.4.3", - "resolved": "https://registry.npmjs.org/@humanwhocodes/retry/-/retry-0.4.3.tgz", - "integrity": "sha512-bV0Tgo9K4hfPCek+aMAn81RppFKv2ySDQeMoSZuvTASywNTnVJCArCZE2FWqpvIatKu7VMRLWlR1EazvVhDyhQ==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" - } - }, - "node_modules/@img/colour": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@img/colour/-/colour-1.1.0.tgz", - "integrity": "sha512-Td76q7j57o/tLVdgS746cYARfSyxk8iEfRxewL9h4OMzYhbW4TAcppl0mT4eyqXddh6L/jwoM75mo7ixa/pCeQ==", - "license": "MIT", - "engines": { - "node": ">=18" - } - }, - "node_modules/@img/sharp-darwin-arm64": { - "version": "0.35.5", - "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.35.5.tgz", - "integrity": "sha512-QRUlFQ0WxvdWyqqG/WtI3iupfD5rBzmCHXSdPsY91sAtVtTo7Q4cb6zOccZ3gqEqkr0f1As1ehLqmEpDsRf+lg==", - "cpu": [ - "arm64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">=20.9.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-darwin-arm64": "1.3.4" - } - }, - "node_modules/@img/sharp-darwin-x64": { - "version": "0.35.5", - "resolved": "https://registry.npmjs.org/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.35.5.tgz", - "integrity": "sha512-+BR255RhDlpygUpOc/Jdt1nT6DQ3XG/ERo5wbcdOf5Q320dKtPCKPLR1LJs9VGXRaMa8l1uUa0tkCNOXiAxZUw==", - "cpu": [ - "x64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": ">=20.9.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - }, - "optionalDependencies": { - "@img/sharp-libvips-darwin-x64": "1.3.4" - } - }, - "node_modules/@img/sharp-freebsd-wasm32": { - "version": "0.35.5", - "resolved": "https://registry.npmjs.org/@img/sharp-freebsd-wasm32/-/sharp-freebsd-wasm32-0.35.5.tgz", - "integrity": "sha512-Y/z91nEZ4uIBX5X3nfTovjU9lHNKFYbL2lpHCLVNmXQK03VIZvXBBt0KxbPGp2SdGSF+2mQU4e+hQaWOt86iAw==", - "license": "Apache-2.0", - "optional": true, - "os": [ - "freebsd" - ], - "dependencies": { - "@img/sharp-wasm32": "0.35.5" - }, - "engines": { - "node": ">=20.9.0" - }, - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-darwin-arm64": { + "node_modules/@img/sharp-libvips-linux-riscv64": { "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.3.4.tgz", - "integrity": "sha512-5R89nBYiRdUlSWJxPhO+GVtaXzXSxKnRu/xqMn3KTA3L9EB9Oy/P+Nn2f2vlhPuUdy/Zusb2DarbyTpGCfEDuw==", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-riscv64/-/sharp-libvips-linux-riscv64-1.3.4.tgz", + "integrity": "sha512-aHkkIEHPRdQEegJN20MLmGtxYD9R2wQr3Cwpddnu5+YKMt6Uzax7S9h5gpZTo8wyrGuZSlfQ63OevL5mTyOC7Q==", "cpu": [ - "arm64" + "riscv64" + ], + "libc": [ + "glibc" ], "license": "LGPL-3.0-or-later", "optional": true, "os": [ - "darwin" + "linux" ], "funding": { "url": "https://opencollective.com/libvips" } }, - "node_modules/@img/sharp-libvips-darwin-x64": { + "node_modules/@img/sharp-libvips-linux-s390x": { "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.3.4.tgz", - "integrity": "sha512-iR2OKH80yi0U+dUplyh3/xdpFvps6YkCwsXenIJxqxR1v9o+xtKTGbS9H7cps+2Vxjc8B1j96p75NmTGjIhtpQ==", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.3.4.tgz", + "integrity": "sha512-ra/mB6MikESDUO7Yg+Mi95bFBb9GsObURuhnOv3OqknjGe9sZrG8tCe9q0xSIGrtLgvgw0gKnFWcK4blSgQOuQ==", "cpu": [ - "x64" + "s390x" + ], + "libc": [ + "glibc" ], "license": "LGPL-3.0-or-later", "optional": true, "os": [ - "darwin" + "linux" ], "funding": { "url": "https://opencollective.com/libvips" } }, - "node_modules/@img/sharp-libvips-linux-arm": { + "node_modules/@img/sharp-libvips-linux-x64": { "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.3.4.tgz", - "integrity": "sha512-LmRtTsOHuvM2+wlO2Db37dx5MiZhB0FvSunciw48YjdOkZz9KAiRbm8ujeMOA1INqmei5NapFxYEK1D1ZSidmw==", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.3.4.tgz", + "integrity": "sha512-GJ//SSXbnwSDes02umB3nDJLFcQzw8a18V8fyhqr6tV515tOEMdImjjxj1AoafMRz56F3PHgftnj1QEKSU1zkw==", "cpu": [ - "arm" + "x64" ], "libc": [ "glibc" @@ -2707,15 +2294,15 @@ "url": "https://opencollective.com/libvips" } }, - "node_modules/@img/sharp-libvips-linux-arm64": { + "node_modules/@img/sharp-libvips-linuxmusl-arm64": { "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.3.4.tgz", - "integrity": "sha512-Y3dgX/6lE2QhQb+Gxy0WZxfg9MEm/JBjamZpS2IklP7xIQoKN4hzAm7KcMVGtaVDt3neE9OKBC7vAfonA/Lr1A==", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.3.4.tgz", + "integrity": "sha512-hvulFwtjUcagsis6BBxHwGFwWoNZjgYmULGVrZcyfNbjA8hKILbRxGg15/7w5HDyXHXUos/j6baAWqnCyQ2DWA==", "cpu": [ "arm64" ], "libc": [ - "glibc" + "musl" ], "license": "LGPL-3.0-or-later", "optional": true, @@ -2726,15 +2313,15 @@ "url": "https://opencollective.com/libvips" } }, - "node_modules/@img/sharp-libvips-linux-ppc64": { + "node_modules/@img/sharp-libvips-linuxmusl-x64": { "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-ppc64/-/sharp-libvips-linux-ppc64-1.3.4.tgz", - "integrity": "sha512-Le6boB8Tai0Nis+gIxIpKx68UDVVIqdR8Tin5Yf1z2LJJQLDJvCDRqRu+jC2qCoD+eIomonmOwB4smBRxfVpYQ==", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.3.4.tgz", + "integrity": "sha512-6zXKeE/p39I1AmA3cJG35eyBGNqNddLnUXjhwBnsGjFPWqf5VKkDBEqaEkPDoTEtkxwi2vv8Tcr2mDyP4So7Fg==", "cpu": [ - "ppc64" + "x64" ], "libc": [ - "glibc" + "musl" ], "license": "LGPL-3.0-or-later", "optional": true, @@ -2745,119 +2332,24 @@ "url": "https://opencollective.com/libvips" } }, - "node_modules/@img/sharp-libvips-linux-riscv64": { - "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-riscv64/-/sharp-libvips-linux-riscv64-1.3.4.tgz", - "integrity": "sha512-aHkkIEHPRdQEegJN20MLmGtxYD9R2wQr3Cwpddnu5+YKMt6Uzax7S9h5gpZTo8wyrGuZSlfQ63OevL5mTyOC7Q==", + "node_modules/@img/sharp-linux-arm": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm/-/sharp-linux-arm-0.35.5.tgz", + "integrity": "sha512-LEaXK2WdXVK5ykcw0buWyPMsmLLL2vpHLD6yrNSW+JGEL3BZPA4tpKN6iaMc4AxTTAoaX/sU1rOL51lcIz48ZQ==", "cpu": [ - "riscv64" + "arm" ], "libc": [ "glibc" ], - "license": "LGPL-3.0-or-later", + "license": "Apache-2.0", "optional": true, "os": [ "linux" ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linux-s390x": { - "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.3.4.tgz", - "integrity": "sha512-ra/mB6MikESDUO7Yg+Mi95bFBb9GsObURuhnOv3OqknjGe9sZrG8tCe9q0xSIGrtLgvgw0gKnFWcK4blSgQOuQ==", - "cpu": [ - "s390x" - ], - "libc": [ - "glibc" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linux-x64": { - "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.3.4.tgz", - "integrity": "sha512-GJ//SSXbnwSDes02umB3nDJLFcQzw8a18V8fyhqr6tV515tOEMdImjjxj1AoafMRz56F3PHgftnj1QEKSU1zkw==", - "cpu": [ - "x64" - ], - "libc": [ - "glibc" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linuxmusl-arm64": { - "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.3.4.tgz", - "integrity": "sha512-hvulFwtjUcagsis6BBxHwGFwWoNZjgYmULGVrZcyfNbjA8hKILbRxGg15/7w5HDyXHXUos/j6baAWqnCyQ2DWA==", - "cpu": [ - "arm64" - ], - "libc": [ - "musl" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-libvips-linuxmusl-x64": { - "version": "1.3.4", - "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.3.4.tgz", - "integrity": "sha512-6zXKeE/p39I1AmA3cJG35eyBGNqNddLnUXjhwBnsGjFPWqf5VKkDBEqaEkPDoTEtkxwi2vv8Tcr2mDyP4So7Fg==", - "cpu": [ - "x64" - ], - "libc": [ - "musl" - ], - "license": "LGPL-3.0-or-later", - "optional": true, - "os": [ - "linux" - ], - "funding": { - "url": "https://opencollective.com/libvips" - } - }, - "node_modules/@img/sharp-linux-arm": { - "version": "0.35.5", - "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm/-/sharp-linux-arm-0.35.5.tgz", - "integrity": "sha512-LEaXK2WdXVK5ykcw0buWyPMsmLLL2vpHLD6yrNSW+JGEL3BZPA4tpKN6iaMc4AxTTAoaX/sU1rOL51lcIz48ZQ==", - "cpu": [ - "arm" - ], - "libc": [ - "glibc" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=20.9.0" - }, + "engines": { + "node": ">=20.9.0" + }, "funding": { "url": "https://opencollective.com/libvips" }, @@ -3145,6 +2637,12 @@ "node": ">=18.0.0" } }, + "node_modules/@isaacs/nonrecursive-glob-match": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@isaacs/nonrecursive-glob-match/-/nonrecursive-glob-match-1.1.0.tgz", + "integrity": "sha512-GPm/Dbvk5RLmhRnxXIa7nTpK0xtl4E0wj0MslsuNiJ1FIROU+2+9lgUC/dgF7Ey4QCWhfEsgxilMRMCdHPfDfw==", + "license": "BlueOak-1.0.0" + }, "node_modules/@jridgewell/gen-mapping": { "version": "0.3.13", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz", @@ -3168,9 +2666,9 @@ } }, "node_modules/@jridgewell/resolve-uri": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", - "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.3.tgz", + "integrity": "sha512-lhTtjtoEArWBjismtfS761S9Hlyn+nIZqOZVYoZ1Xn82PMNMVnk+jj/NhC4fAXGTs7ydONcJiR5vyQBTMDu27g==", "dev": true, "license": "MIT", "engines": { @@ -3178,9 +2676,9 @@ } }, "node_modules/@jridgewell/sourcemap-codec": { - "version": "1.5.5", - "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", - "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.6.0.tgz", + "integrity": "sha512-T7jf+5zgsZHwNJ4lvQ7/aezbyk0nNX+zJVWpmHA7VYsEx7a7qr5Rg5IbtJFqkgze5Y2sruq1RUY8Q837Od7iFw==", "dev": true, "license": "MIT" }, @@ -3195,6 +2693,13 @@ "@jridgewell/sourcemap-codec": "^1.4.14" } }, + "node_modules/@keyv/serialize": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@keyv/serialize/-/serialize-1.1.1.tgz", + "integrity": "sha512-dXn3FZhPv0US+7dtJsIi2R+c7qWYiReoEh5zUntWCf4oSpMNib8FDhSoed6m3QyZdx5hK7iLFkYk3rNxwt8vTA==", + "dev": true, + "license": "MIT" + }, "node_modules/@malept/cross-spawn-promise": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/@malept/cross-spawn-promise/-/cross-spawn-promise-2.0.0.tgz", @@ -3256,6 +2761,46 @@ "integrity": "sha512-Y28PR25bHXUg88kCV7nivXrP2Nj2RueZ3/l/jdx6J9f8J4nsEGcgX0Qe6lt7Pa+J79+kPiJU3LguR6O/6zrLOw==", "license": "BSD-2-Clause" }, + "node_modules/@modelcontextprotocol/sdk": { + "version": "1.32.1", + "resolved": "https://registry.npmjs.org/@modelcontextprotocol/sdk/-/sdk-1.32.1.tgz", + "integrity": "sha512-2DdE+SJDtzLEEWzY1ZjY7Q+VcPhcV1KisD3zI4u0XZyktsjHum1mwbMI+JaulUBi2OZk+KJAi2uPXzxichPkdw==", + "license": "MIT", + "dependencies": { + "@hono/node-server": "^1.19.9 || ^2.0.5", + "ajv": "^8.17.1", + "ajv-formats": "^3.0.1", + "content-type": "^1.0.5", + "cors": "^2.8.5", + "cross-spawn": "^7.0.5", + "eventsource": "^3.0.2", + "eventsource-parser": "^3.0.0", + "express": "^5.2.1", + "express-rate-limit": "^8.2.1", + "hono": "^4.11.4", + "jose": "^6.1.3", + "json-schema-typed": "^8.0.2", + "pkce-challenge": "^5.0.0", + "raw-body": "^3.0.0", + "zod": "^3.25 || ^4.0", + "zod-to-json-schema": "^3.25.1" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@cfworker/json-schema": "^4.1.1", + "zod": "^3.25 || ^4.0" + }, + "peerDependenciesMeta": { + "@cfworker/json-schema": { + "optional": true + }, + "zod": { + "optional": false + } + } + }, "node_modules/@mozilla/readability": { "version": "0.6.0", "resolved": "https://registry.npmjs.org/@mozilla/readability/-/readability-0.6.0.tgz", @@ -3266,9 +2811,9 @@ } }, "node_modules/@napi-rs/canvas": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas/-/canvas-1.0.2.tgz", - "integrity": "sha512-EYEqlMYaCbpZDz+IgDH5xp9MTd3ui4dmGqbQYryhMLnSRxrhHKq5KQWHHKxFUcEP4Hp8/BWgvqXocX4j7iSbOQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas/-/canvas-1.1.1.tgz", + "integrity": "sha512-UyNspnx0rXclATMOBXiWgy1xtWUSUDm4UOO6+YO8xzyVKaZRpvK+SlJSCtRoSI9J/mEqklJiPYtroN1B+hgLXg==", "license": "MIT", "optional": true, "workspaces": [ @@ -3282,23 +2827,23 @@ "url": "https://github.com/sponsors/Brooooooklyn" }, "optionalDependencies": { - "@napi-rs/canvas-android-arm64": "1.0.2", - "@napi-rs/canvas-darwin-arm64": "1.0.2", - "@napi-rs/canvas-darwin-x64": "1.0.2", - "@napi-rs/canvas-linux-arm-gnueabihf": "1.0.2", - "@napi-rs/canvas-linux-arm64-gnu": "1.0.2", - "@napi-rs/canvas-linux-arm64-musl": "1.0.2", - "@napi-rs/canvas-linux-riscv64-gnu": "1.0.2", - "@napi-rs/canvas-linux-x64-gnu": "1.0.2", - "@napi-rs/canvas-linux-x64-musl": "1.0.2", - "@napi-rs/canvas-win32-arm64-msvc": "1.0.2", - "@napi-rs/canvas-win32-x64-msvc": "1.0.2" + "@napi-rs/canvas-android-arm64": "1.1.1", + "@napi-rs/canvas-darwin-arm64": "1.1.1", + "@napi-rs/canvas-darwin-x64": "1.1.1", + "@napi-rs/canvas-linux-arm-gnueabihf": "1.1.1", + "@napi-rs/canvas-linux-arm64-gnu": "1.1.1", + "@napi-rs/canvas-linux-arm64-musl": "1.1.1", + "@napi-rs/canvas-linux-riscv64-gnu": "1.1.1", + "@napi-rs/canvas-linux-x64-gnu": "1.1.1", + "@napi-rs/canvas-linux-x64-musl": "1.1.1", + "@napi-rs/canvas-win32-arm64-msvc": "1.1.1", + "@napi-rs/canvas-win32-x64-msvc": "1.1.1" } }, "node_modules/@napi-rs/canvas-android-arm64": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-android-arm64/-/canvas-android-arm64-1.0.2.tgz", - "integrity": "sha512-IMXKVQod0ol4vt3gmClUfXz4JAgHYESGPCUqmH3lQxBoL0K/2greJaQE1HVBVxWWFKfLc4OLZVdxg7kXVyXv+g==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-android-arm64/-/canvas-android-arm64-1.1.1.tgz", + "integrity": "sha512-rSEp3y+/YXw6TxSx4/NHSAFxumZrkMoXy2WiVqpKGT8oF5GHOUDzTKj45e5cvzophX4iFaxwKs3+/gNkJ7FmzQ==", "cpu": [ "arm64" ], @@ -3316,9 +2861,9 @@ } }, "node_modules/@napi-rs/canvas-darwin-arm64": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-darwin-arm64/-/canvas-darwin-arm64-1.0.2.tgz", - "integrity": "sha512-Sc8tPi6cF+5lqOzCCKFALJHhDiRwyMzTPYm3bbhdXsOunU0lQO5f05ucyOzN2r55I23Hg5bsjH63uSCvWp3EgQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-darwin-arm64/-/canvas-darwin-arm64-1.1.1.tgz", + "integrity": "sha512-NrPTZWpu0ywOGdp9JBDi46gABUzDJK6IzlP7cOEwaAuVVFM8KRakUWk12RK3YQ/Ea5FrNVTWUFTmkXVk4RfHqg==", "cpu": [ "arm64" ], @@ -3336,9 +2881,9 @@ } }, "node_modules/@napi-rs/canvas-darwin-x64": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-darwin-x64/-/canvas-darwin-x64-1.0.2.tgz", - "integrity": "sha512-niDXZ9LhKB1zLrUdYB64RHQFDGz9rr0eGx061qtJJU3U20EMMIx28ADF5fVYbhtOgkWQrBjFicfaye1yM0U62A==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-darwin-x64/-/canvas-darwin-x64-1.1.1.tgz", + "integrity": "sha512-p3DOT8VBfu8cR3SVBUs6cEzJmzwOUQkNfo1S4nKLgeKDsSlvn2oZsRaa9m0lfMccn1WbwtgKCEpJXmHhp++Zrg==", "cpu": [ "x64" ], @@ -3356,9 +2901,9 @@ } }, "node_modules/@napi-rs/canvas-linux-arm-gnueabihf": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-arm-gnueabihf/-/canvas-linux-arm-gnueabihf-1.0.2.tgz", - "integrity": "sha512-sgatQL9JxGRH/Amzcvu0P3t8Am3duou74CisfuJ41Dwt8cWy723z/9KZ8LlgmxfypEwEZxSTNFJtU8d281lmhQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-arm-gnueabihf/-/canvas-linux-arm-gnueabihf-1.1.1.tgz", + "integrity": "sha512-YWGJfMa8TtEhsHd/kDiyBFwT/dAbRQiXwsm0tDev4H5cJiyOk08CC83JihrwnUsePGjIvxC8/8g/zqKKuqjpQA==", "cpu": [ "arm" ], @@ -3376,12 +2921,15 @@ } }, "node_modules/@napi-rs/canvas-linux-arm64-gnu": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-arm64-gnu/-/canvas-linux-arm64-gnu-1.0.2.tgz", - "integrity": "sha512-dgKuX0peF3xwY6ZF5QxGS4wbfDqpoFAJYXiLSp+guZKARQUKMkRqZSDrXKj7nfrec3UCMzC0PFCPte0ES98AiA==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-arm64-gnu/-/canvas-linux-arm64-gnu-1.1.1.tgz", + "integrity": "sha512-q1HBkNmB9mc6SF6uSz2492qSgsB46MqS+n3bPbPCE0kUXmWAPkH9vDADeawbhepQYn8RhlV2V/P5u6nykFXbuQ==", "cpu": [ "arm64" ], + "libc": [ + "glibc" + ], "license": "MIT", "optional": true, "os": [ @@ -3396,12 +2944,15 @@ } }, "node_modules/@napi-rs/canvas-linux-arm64-musl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-arm64-musl/-/canvas-linux-arm64-musl-1.0.2.tgz", - "integrity": "sha512-qwROoDIC9upfvDoRLuPn2aNg9CGW1x0Ygr4k2Or+8paA9d0qBLwk87U+g8KQpoOviKoPoiwl97kvBYuYD7qZoA==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-arm64-musl/-/canvas-linux-arm64-musl-1.1.1.tgz", + "integrity": "sha512-aF4RkTp2T45fERFPCIqbxeKVhvhHuXeyyk5/jdJ+N0tGLZy4NvMkIrBWt6GOCmAQ7H0G3M/O03hAsc4Li52q4A==", "cpu": [ "arm64" ], + "libc": [ + "musl" + ], "license": "MIT", "optional": true, "os": [ @@ -3416,12 +2967,15 @@ } }, "node_modules/@napi-rs/canvas-linux-riscv64-gnu": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-riscv64-gnu/-/canvas-linux-riscv64-gnu-1.0.2.tgz", - "integrity": "sha512-fXRjnPihdnbO6qy1QQOgxAonb68A0TCEG7rj1x7v7rxNElsE8EVIKIEUTvyDtU+sthYSbX+8e7g3oZiLGnOmxw==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-riscv64-gnu/-/canvas-linux-riscv64-gnu-1.1.1.tgz", + "integrity": "sha512-rCU4Xo5h0AQFEaa9dNr7Kxbk4gke9Uyi/I6ZXuBGYPSNWxYmWRS6DkrxaSKUJyCgA7c8l6lZBYfx/FtbJo3fMA==", "cpu": [ "riscv64" ], + "libc": [ + "glibc" + ], "license": "MIT", "optional": true, "os": [ @@ -3436,12 +2990,15 @@ } }, "node_modules/@napi-rs/canvas-linux-x64-gnu": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-x64-gnu/-/canvas-linux-x64-gnu-1.0.2.tgz", - "integrity": "sha512-nPR97DXhbWIAy7yazF3jc06kEPMqYMLmPzFOVNlwKPfIoSChnI+x7dc0hTLaihz3jxrjL6j4BbA7earxfx4X3g==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-x64-gnu/-/canvas-linux-x64-gnu-1.1.1.tgz", + "integrity": "sha512-7bZfDI9lxKqj9wJRHiSQBimCRanxDGHYE7TugnOmFJ9ScpgFSsLHFQtOH9wvmbQvBwv5nBuDBGJlG0+7iGkN+w==", "cpu": [ "x64" ], + "libc": [ + "glibc" + ], "license": "MIT", "optional": true, "os": [ @@ -3456,12 +3013,15 @@ } }, "node_modules/@napi-rs/canvas-linux-x64-musl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-x64-musl/-/canvas-linux-x64-musl-1.0.2.tgz", - "integrity": "sha512-l7zZY5+jL5qnBZtDz7CoBtY6p7EkHu422g/0zWwrOrzIwWyWxZFRfZZORY1UG7YApymPLx+UbOkN206xXn/c1Q==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-linux-x64-musl/-/canvas-linux-x64-musl-1.1.1.tgz", + "integrity": "sha512-xaFof2p0aO7C7ziMCLeueve09PVEKYCebljLTL3nyxoaRsYpEnBrUBP1aVpfD1Nk464dc7/wPV23fkHdOBie2g==", "cpu": [ "x64" ], + "libc": [ + "musl" + ], "license": "MIT", "optional": true, "os": [ @@ -3476,9 +3036,9 @@ } }, "node_modules/@napi-rs/canvas-win32-arm64-msvc": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-win32-arm64-msvc/-/canvas-win32-arm64-msvc-1.0.2.tgz", - "integrity": "sha512-yE0koHCFF4PIbMc2o2SEALhnipz7WBISh5glLvQiomtIoCcW0np3H4Lw93ceJAfJttTTeIIWFbwH84F7EVzjMQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-win32-arm64-msvc/-/canvas-win32-arm64-msvc-1.1.1.tgz", + "integrity": "sha512-wOLX/WRwWr0xGj2hnDf/t3tZfPlzzL9rGPsO1UnYSuNbRzwas/hC8JXnuhaEs8eCw+J+W4zxOJiVF4RxkvcMfw==", "cpu": [ "arm64" ], @@ -3496,9 +3056,9 @@ } }, "node_modules/@napi-rs/canvas-win32-x64-msvc": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/@napi-rs/canvas-win32-x64-msvc/-/canvas-win32-x64-msvc-1.0.2.tgz", - "integrity": "sha512-okU8/t2foV6C31n0GtvEMbfD5rOFc70+/6xUNME9Guld29sgSOIGUEDScAWFlcP3k5TYQRl9TNkwJEEjh15w8A==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@napi-rs/canvas-win32-x64-msvc/-/canvas-win32-x64-msvc-1.1.1.tgz", + "integrity": "sha512-6Ge1AF1SVO+Ypjaw9IPcApm95krR3GQ32HgVqlIckbN/WqUlWYS0hnb8ZIdu3e0IbutbJgd8D2qSeb2/Cdpbdw==", "cpu": [ "x64" ], @@ -3515,85 +3075,314 @@ "url": "https://github.com/sponsors/Brooooooklyn" } }, - "node_modules/@noble/hashes": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-2.2.0.tgz", - "integrity": "sha512-IYqDGiTXab6FniAgnSdZwgWbomxpy9FtYvLKs7wCUs2a8RkITG+DFGO1DM9cr+E3/RgADRpFjrKVaJ1z6sjtEg==", + "node_modules/@napi-rs/wasm-runtime": { + "version": "1.2.6", + "resolved": "https://registry.npmjs.org/@napi-rs/wasm-runtime/-/wasm-runtime-1.2.6.tgz", + "integrity": "sha512-mRyDmEw9/fCDXCGfL1sbgIw/GUK0PVxRW4YwgPN61F3LQ+fSyoBFarJVzgGyhF6kRzEQZ0FejDqm4WLXSeqQmw==", "dev": true, "license": "MIT", + "optional": true, + "dependencies": { + "@tybys/wasm-util": "^0.10.3" + }, "engines": { - "node": ">= 20.19.0" + "node": "^20.19.0 || ^22.13.0 || >=23.5.0" }, "funding": { - "url": "https://paulmillr.com/funding/" + "type": "github", + "url": "https://github.com/sponsors/Brooooooklyn" + }, + "peerDependencies": { + "@emnapi/core": "^1.7.1 || 2.0.0-beta.2", + "@emnapi/runtime": "^1.7.1 || 2.0.0-beta.2" } }, - "node_modules/@peculiar/asn1-schema": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/@peculiar/asn1-schema/-/asn1-schema-2.8.0.tgz", - "integrity": "sha512-7YT0U/ze0tF2QOBbE15gKZwy5tvgGyLRiRHLzhlbOpf7BT032oBSd0haZqXn5W6l26WLlu3dyxzjM+2638/z2Q==", + "node_modules/@noble/hashes": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.8.0.tgz", + "integrity": "sha512-jCs9ldd7NwzpgXDIf6P3+NrHh9/sD6CQdxHyjQI+h/6rDNo88ypBxxz45UDuZHz9r3tNz7N/VInSVoVdtXEI4A==", "dev": true, "license": "MIT", - "dependencies": { - "@peculiar/utils": "^2.0.2", - "asn1js": "^3.0.10", - "tslib": "^2.8.1" + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" } }, - "node_modules/@peculiar/json-schema": { - "version": "1.1.12", - "resolved": "https://registry.npmjs.org/@peculiar/json-schema/-/json-schema-1.1.12.tgz", - "integrity": "sha512-coUfuoMeIB7B8/NMekxaDzLhaYmp0HZNPEjYRm9goRou8UZIC3z21s0sL9AWoCw4EG876QyO3kYrc61WNF9B/w==", - "dev": true, + "node_modules/@openclaw/fs-safe": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe/-/fs-safe-0.27.2.tgz", + "integrity": "sha512-OvehJrbjd8TpUsyaL7BCu25KcqLCccBtEkLk47YvlXyH87k6NrkmY1VJiC6/thJS2e914AWu266JeOQBbsMebw==", "license": "MIT", - "dependencies": { - "tslib": "^2.0.0" + "engines": { + "node": ">=22" }, + "optionalDependencies": { + "@openclaw/fs-safe-darwin-arm64": "0.27.2", + "@openclaw/fs-safe-darwin-x64": "0.27.2", + "@openclaw/fs-safe-freebsd-arm64": "0.27.2", + "@openclaw/fs-safe-freebsd-x64": "0.27.2", + "@openclaw/fs-safe-linux-arm64-gnu": "0.27.2", + "@openclaw/fs-safe-linux-arm64-musl": "0.27.2", + "@openclaw/fs-safe-linux-x64-gnu": "0.27.2", + "@openclaw/fs-safe-linux-x64-musl": "0.27.2", + "@openclaw/fs-safe-win32-arm64-msvc": "0.27.2", + "@openclaw/fs-safe-win32-x64-msvc": "0.27.2", + "jszip": "^3.10.2" + } + }, + "node_modules/@openclaw/fs-safe-darwin-arm64": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-darwin-arm64/-/fs-safe-darwin-arm64-0.27.2.tgz", + "integrity": "sha512-df4XfjnN+tY94EZmo5K3G2nx1K97oJ3dW2lyQPVoFcuYk+Ik/9wtIVQ73tjx3tQRp12yPWzi4bscsZ2XwFgVeQ==", + "cpu": [ + "arm64" + ], + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], "engines": { - "node": ">=8.0.0" + "node": ">=22" } }, - "node_modules/@peculiar/utils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@peculiar/utils/-/utils-2.0.3.tgz", - "integrity": "sha512-+oL3HPFRIZ1St2K50lWCXiioIgSoxzz7R1J3uF6neO2yl1sgmpgY6XXJH4BdpoDkMWznQTeYF6oWNDZLCdQ4eQ==", - "dev": true, + "node_modules/@openclaw/fs-safe-darwin-x64": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-darwin-x64/-/fs-safe-darwin-x64-0.27.2.tgz", + "integrity": "sha512-+lSL9O6DvJEizUlMfNKTW10FXgb3FCn+M0ijiVNE12TcikxUVkv2FFk8fZigTyC5K8h+hxH6rzyazby8TcX8zQ==", + "cpu": [ + "x64" + ], "license": "MIT", - "dependencies": { - "tslib": "^2.8.1" + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=22" } }, - "node_modules/@peculiar/webcrypto": { - "version": "1.7.1", - "resolved": "https://registry.npmjs.org/@peculiar/webcrypto/-/webcrypto-1.7.1.tgz", - "integrity": "sha512-ODOov0sGMJMf3jPonOkgGqPknTsu+DdQ7kD++gz8aI+aFMOMHFbWAA2taqXXVTdP+OTOQR/znGvSpmkeI0WTYQ==", - "dev": true, + "node_modules/@openclaw/fs-safe-freebsd-arm64": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-freebsd-arm64/-/fs-safe-freebsd-arm64-0.27.2.tgz", + "integrity": "sha512-UorPeKoUORvY9NHma2a3ow5zJ8N4/JmSecljlECjOuCwpKkP/qsahoWpaUfzzsSBb4XT++txaV7AUd7jOgg8Dg==", + "cpu": [ + "arm64" + ], "license": "MIT", - "dependencies": { - "@peculiar/asn1-schema": "^2.7.0", - "@peculiar/json-schema": "^1.1.12", - "@peculiar/utils": "^2.0.2", - "tslib": "^2.8.1", - "webcrypto-core": "^1.9.2" - }, + "optional": true, + "os": [ + "freebsd" + ], "engines": { - "node": ">=14.18.0" + "node": ">=22" } }, - "node_modules/@playwright/test": { - "version": "1.61.0", - "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.61.0.tgz", - "integrity": "sha512-cKA5B6lpFEMyMGjxF54QihfYpB4FkEGH+qZhtArDEG+wezQAJY8Pq6C7T1SjWz+FFzt3TbyoXBQYk/0292TdJA==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "playwright": "1.61.0" - }, - "bin": { - "playwright": "cli.js" - }, + "node_modules/@openclaw/fs-safe-freebsd-x64": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-freebsd-x64/-/fs-safe-freebsd-x64-0.27.2.tgz", + "integrity": "sha512-jNeVh7lSpCvTuoGsV+iC0xETXzZEp6dTf77QSojohPOXCP5nxNmVydV6RkiBW/Ua6xvD9PvxDaBMtoYeFWPCJA==", + "cpu": [ + "x64" + ], + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], "engines": { - "node": ">=18" + "node": ">=22" + } + }, + "node_modules/@openclaw/fs-safe-linux-arm64-gnu": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-linux-arm64-gnu/-/fs-safe-linux-arm64-gnu-0.27.2.tgz", + "integrity": "sha512-R2utdxmPxan42+n0FjRc+1P3LHgwei25DUOJHBqcXr1ch0nNKkpSnmV7aYeLEER9Q0eBseEIwB9YgTGtKawG4A==", + "cpu": [ + "arm64" + ], + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=22" + } + }, + "node_modules/@openclaw/fs-safe-linux-arm64-musl": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-linux-arm64-musl/-/fs-safe-linux-arm64-musl-0.27.2.tgz", + "integrity": "sha512-6NEl+0nzqRfdyKQgggAh74CdxJRGZlchKzk8/OQxHKXuVyHpSPzeCXmAHQq8HwgZNvvSfLenhoGcCPCqrd+90A==", + "cpu": [ + "arm64" + ], + "libc": [ + "musl" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=22" + } + }, + "node_modules/@openclaw/fs-safe-linux-x64-gnu": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-linux-x64-gnu/-/fs-safe-linux-x64-gnu-0.27.2.tgz", + "integrity": "sha512-2OiwBdpzSqNbCFHWEZnqWirfcasEL1q6oGulrBKB/abPjXqyRAHgRgnVgTkTa5QEzoydAK+bCGLamLfHzKVAHw==", + "cpu": [ + "x64" + ], + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=22" + } + }, + "node_modules/@openclaw/fs-safe-linux-x64-musl": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-linux-x64-musl/-/fs-safe-linux-x64-musl-0.27.2.tgz", + "integrity": "sha512-8phQ3/CpKx1BrWFUu7zaDLvkR3pcKpdfhWzfJUOgsqZ3RfTuMgSOoT0bSUqnaZve+lx8ulRuXZ+aPikWN/K3FQ==", + "cpu": [ + "x64" + ], + "libc": [ + "musl" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=22" + } + }, + "node_modules/@openclaw/fs-safe-win32-arm64-msvc": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-win32-arm64-msvc/-/fs-safe-win32-arm64-msvc-0.27.2.tgz", + "integrity": "sha512-xg7FBlFK5LIKbze/YrCQ89KWPtTazKQktTyAl/eC40iXsYB8D1DcakE3FCdYd4O6UA79OfBS0PJvxlrE9jyx8w==", + "cpu": [ + "arm64" + ], + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=22" + } + }, + "node_modules/@openclaw/fs-safe-win32-x64-msvc": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/@openclaw/fs-safe-win32-x64-msvc/-/fs-safe-win32-x64-msvc-0.27.2.tgz", + "integrity": "sha512-vtwG04UXzIAZg2t+ykZMae4yWy+5P/MI1rekN4jtk8hRck+115mfqKzls1eNzc3YnT0TMo2s6KFjHe3a6wlDtg==", + "cpu": [ + "x64" + ], + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=22" + } + }, + "node_modules/@oxc-project/types": { + "version": "0.156.0", + "resolved": "https://registry.npmjs.org/@oxc-project/types/-/types-0.156.0.tgz", + "integrity": "sha512-1Duyg48TdJNdyhEB8Xn1L36bT9Pv6GUtlKjHxOys8xkaF/rQq3XJE+bAurSK/AgIz5mGFsb77cn9Pb20+WCScw==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/oxc-project" + } + }, + "node_modules/@peculiar/asn1-schema": { + "version": "2.11.1", + "resolved": "https://registry.npmjs.org/@peculiar/asn1-schema/-/asn1-schema-2.11.1.tgz", + "integrity": "sha512-jaU9OaCcbZUdyXx9hMETZB9xoNmxTGjOGFqd3cOwKFkpKnyKd9WxF3uqj4PvX4cyOMP9bSdHg5YyML2qtx/d/g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@peculiar/utils": "^2.0.2", + "asn1js": "^3.0.10", + "tslib": "^2.8.1" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@peculiar/json-schema": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/@peculiar/json-schema/-/json-schema-1.1.12.tgz", + "integrity": "sha512-coUfuoMeIB7B8/NMekxaDzLhaYmp0HZNPEjYRm9goRou8UZIC3z21s0sL9AWoCw4EG876QyO3kYrc61WNF9B/w==", + "dev": true, + "license": "MIT", + "dependencies": { + "tslib": "^2.0.0" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/@peculiar/utils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@peculiar/utils/-/utils-2.0.3.tgz", + "integrity": "sha512-+oL3HPFRIZ1St2K50lWCXiioIgSoxzz7R1J3uF6neO2yl1sgmpgY6XXJH4BdpoDkMWznQTeYF6oWNDZLCdQ4eQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "tslib": "^2.8.1" + } + }, + "node_modules/@peculiar/webcrypto": { + "version": "1.7.2", + "resolved": "https://registry.npmjs.org/@peculiar/webcrypto/-/webcrypto-1.7.2.tgz", + "integrity": "sha512-ktTSACRJ5WdpfjHjFT2EWJQQPacGv1cPCDfEbdmpAHOxdFiYqPe4lfnXGA3D8Dg9/0kHPYSvyRlgujIOVlTdvQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@peculiar/asn1-schema": "^2.7.0", + "@peculiar/json-schema": "^1.1.12", + "@peculiar/utils": "^2.0.2", + "tslib": "^2.8.1", + "webcrypto-core": "^1.9.2" + }, + "engines": { + "node": ">=14.18.0" + } + }, + "node_modules/@playwright/test": { + "version": "1.65.1", + "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.65.1.tgz", + "integrity": "sha512-y+NCIRm2LvY4slUVWvGh1nujJ8RF/hEisIsq2mtUPgdQC4L701bq5hZGMhrpeXjACvwvO9tj5dJqhvM6TP9lbw==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "playwright": "1.65.1" + }, + "bin": { + "playwright": "cli.js" + }, + "engines": { + "node": ">=20" } }, "node_modules/@protobufjs/aspromise": { @@ -3648,22 +3437,15 @@ "license": "BSD-3-Clause" }, "node_modules/@protobufjs/utf8": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@protobufjs/utf8/-/utf8-1.1.1.tgz", - "integrity": "sha512-oOAWABowe8EAbMyWKM0tYDKi8Yaox52D+HWZhAIJqQXbqe0xI/GV7FhLWqlEKreMkfDjshR5FKgi3mnle0h6Eg==", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@protobufjs/utf8/-/utf8-1.1.2.tgz", + "integrity": "sha512-b1UQwcEZ4yCnMCD8DAL1VlbvBJE9/IX4FTIp7BG1xYpf29SLazLSrqUkj4w7Y5y7cCVP6E5tcqqcI0xemPkHug==", "license": "BSD-3-Clause" }, - "node_modules/@rolldown/pluginutils": { - "version": "1.0.0-rc.3", - "resolved": "https://registry.npmjs.org/@rolldown/pluginutils/-/pluginutils-1.0.0-rc.3.tgz", - "integrity": "sha512-eybk3TjzzzV97Dlj5c+XrBFW57eTNhzod66y9HrBlzJ6NsCrWCp/2kaPS3K9wJmurBC0Tdw4yPjXKZqlznim3Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.62.0.tgz", - "integrity": "sha512-IPIQ55ythEHkfEd9jMEi32OQ7SxURsGA43JI22lj01OLZNt2NUbJX8YUHxkVWyQ6daHPNn0truF5nSj3DQp6YQ==", + "node_modules/@rolldown/binding-android-arm-eabi": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-android-arm-eabi/-/binding-android-arm-eabi-1.2.19.tgz", + "integrity": "sha512-e+Ebe0WT+9tbXmNKPIiC8YrWAHYwug3m6i4p3rZGGulfZri1jtI4HslT+OZnFf/OIHowWF71DTlHwXBP2SiA7A==", "cpu": [ "arm" ], @@ -3672,12 +3454,15 @@ "optional": true, "os": [ "android" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-android-arm64": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.62.0.tgz", - "integrity": "sha512-M6s9cr10MibETyo8JsOkq+Lo1+lU6hcvb1MApnUql5qte/5hMEgzlN8/ReIKNfRV8rrqX50W1BX9zoUhC192RA==", + "node_modules/@rolldown/binding-android-arm64": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-android-arm64/-/binding-android-arm64-1.2.19.tgz", + "integrity": "sha512-hOombrTJ+szt2ciEzS7oCA78lMPBgF5UMQWCJIyNfnrI7GLl8HYoFqCnpL2gcPOaXMqryGCU5ExdQKyDDcC+yA==", "cpu": [ "arm64" ], @@ -3686,12 +3471,15 @@ "optional": true, "os": [ "android" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.62.0.tgz", - "integrity": "sha512-BqCoMoIbn0keKys+dEAdBa70EtOwV1bEsQCUgU9FdiZmmMge/Zk7LlkYGqbrdHR+Frnt0E1FOanly+rlwvvQzw==", + "node_modules/@rolldown/binding-darwin-arm64": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-darwin-arm64/-/binding-darwin-arm64-1.2.19.tgz", + "integrity": "sha512-XoMA2pwCKGTQzUjPgtRwkedH4WmXhdIPKT6l6oOxd1PUbNodGI6DcBekgN7EC//+x3pfBYX/qL1gNmZAqivw5g==", "cpu": [ "arm64" ], @@ -3700,12 +3488,15 @@ "optional": true, "os": [ "darwin" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.62.0.tgz", - "integrity": "sha512-SIMzST3VFNXDAbeIWDWiFCNM5qncUBDWaEV7NfE7oZbDt2mgfW4MvbKdbYiGOLoM32gbTv608UMd0XktEYSD7w==", + "node_modules/@rolldown/binding-darwin-x64": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-darwin-x64/-/binding-darwin-x64-1.2.19.tgz", + "integrity": "sha512-zo8EsSSwMZCY/e+fRnGaX02YGgvJD0yvhNi/9hpGPA2MJ9ZF8dPCw75UGfpI6OpQ/myR/dIYmogRvqiZD0TrXg==", "cpu": [ "x64" ], @@ -3714,26 +3505,15 @@ "optional": true, "os": [ "darwin" - ] - }, - "node_modules/@rollup/rollup-freebsd-arm64": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.62.0.tgz", - "integrity": "sha512-ezjfSQMP7ArdUsbBwbQIfwAlhE84I2iVnzQNCFSveqV42q+BmKlzVpf7mxv5EchLcoWU4y6/heFzVg1F+hodUQ==", - "cpu": [ - "arm64" ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ] + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-freebsd-x64": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.62.0.tgz", - "integrity": "sha512-9+qTWGW9AZRhnUgwtTwzNwcPlL87ngkeN0LA+q1bADvmY9aNvWaF2TFW8BZgnQPYxpDI7+rMVLivcd4V737TAQ==", + "node_modules/@rolldown/binding-freebsd-x64": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-freebsd-x64/-/binding-freebsd-x64-1.2.19.tgz", + "integrity": "sha512-O8ISAOfI1nj7AuBPd30FSF47z7f7lzlk5poQVGgiikvQuGEBFYvW8ki+UEnT+YJPnNGjQzn304klt4O9FUE7mA==", "cpu": [ "x64" ], @@ -3742,26 +3522,15 @@ "optional": true, "os": [ "freebsd" - ] - }, - "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.62.0.tgz", - "integrity": "sha512-T1dMEQhXA/jkJ/jyMIw9IovK8bSUq7A8kLIlvZTb/6YIVsp2zLavr4F3oyllHWo7eIVJRyE5n3tUjQJEbE1IuQ==", - "cpu": [ - "arm" ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.62.0.tgz", - "integrity": "sha512-2as0LgT7qQpyceQq6VUJYnumUMUrgGQCWIiDIN9DE0/tglsk6o66uCB4f3djRawAltvfCNLyZZrsqbPA6inCsA==", + "node_modules/@rolldown/binding-linux-arm-gnueabihf": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-arm-gnueabihf/-/binding-linux-arm-gnueabihf-1.2.19.tgz", + "integrity": "sha512-/lYCba5NO0yq4S0jGMH8QTBtkvQxoXjoQWzF5BcWp9MjB9jxVRD1GQDNofkVjcOj30DWyhLIN/4Oe60JKzaONw==", "cpu": [ "arm" ], @@ -3770,194 +3539,182 @@ "optional": true, "os": [ "linux" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.62.0.tgz", - "integrity": "sha512-bVURMg+6eNN9C/yc0aVjooZcwTTtYF4YW3xta5pP0//r3o1V8gXEHXWCndj47w/HhwsFroZrFhR+6uQP5T0n0g==", + "node_modules/@rolldown/binding-linux-arm64-gnu": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-arm64-gnu/-/binding-linux-arm64-gnu-1.2.19.tgz", + "integrity": "sha512-pm/apFMBnSbFb3O6nG5pHO1iqHhZrjGDFEjSm+ot9J17XXPvH9L90y5h+jgfHCE+Qdlsvy8qKEcU4VKxgjD+vA==", "cpu": [ "arm64" ], "dev": true, + "libc": [ + "glibc" + ], "license": "MIT", "optional": true, "os": [ "linux" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.62.0.tgz", - "integrity": "sha512-Ful8pM/2yYI83PViWdFdpZhdI8HJ5qsXANe5atypbHDf+KIBBDsZsbyy8hbXnULVvW9NsTh5DHwbcBftyLTfiw==", + "node_modules/@rolldown/binding-linux-arm64-musl": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-arm64-musl/-/binding-linux-arm64-musl-1.2.19.tgz", + "integrity": "sha512-K1SmQp3FFichn8oqrNIwvFoZ5wcvjC7goBzpaMNvLf9FZc+QB/QvLmnpJZgAAGHiD980tP8FZZnXk2K94rvlxg==", "cpu": [ "arm64" ], "dev": true, + "libc": [ + "musl" + ], "license": "MIT", "optional": true, "os": [ "linux" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-linux-loong64-gnu": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-gnu/-/rollup-linux-loong64-gnu-4.62.0.tgz", - "integrity": "sha512-9Gp/DgrkzfUBmNPVTyPTvay+4xEP7M/clXpj3efXBcm6uTIVIgDg4rqUpqKXvLEuFRVuEpSAOkhgNeecvaZ4Cg==", + "node_modules/@rolldown/binding-linux-ppc64-gnu": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-ppc64-gnu/-/binding-linux-ppc64-gnu-1.2.19.tgz", + "integrity": "sha512-I0xwD57jP/3A7+5UPZin2w8Y7XHEmEM5zqpYZOcQ45MlNW6tUJUziymV3yRr7rL4vwyfEcRsRksC4a7Kc08p5Q==", "cpu": [ - "loong64" + "ppc64" ], "dev": true, + "libc": [ + "glibc" + ], "license": "MIT", "optional": true, "os": [ "linux" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-linux-loong64-musl": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-musl/-/rollup-linux-loong64-musl-4.62.0.tgz", - "integrity": "sha512-m9tsJz54LUXkSYM8+8PG81B9IKK5r+2T0clMq4QrS16xFosufU7firBDAZEsDheDs7wTlP7h3++S7lMsU955HA==", + "node_modules/@rolldown/binding-linux-s390x-gnu": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-s390x-gnu/-/binding-linux-s390x-gnu-1.2.19.tgz", + "integrity": "sha512-BrtEHT24SNXj9HiXqy+s/kXiSiQGt6EKCPUlRirAoIioVxKGnbXBUEkbZASAei7iZJB0/Ynm+0JP00Ipx7AnSw==", "cpu": [ - "loong64" + "s390x" ], "dev": true, + "libc": [ + "glibc" + ], "license": "MIT", "optional": true, "os": [ "linux" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-linux-ppc64-gnu": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.62.0.tgz", - "integrity": "sha512-3UvJ5PNVU16aJf6M3tFI24pWzAl2/ynfbyRN3ICyQajK1lSkrnVYNnLz3v04J32qKa0FczJc22zeToc0lr2A3w==", + "node_modules/@rolldown/binding-linux-x64-gnu": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-x64-gnu/-/binding-linux-x64-gnu-1.2.19.tgz", + "integrity": "sha512-rm75/9DkHKeU2WnA8w4X94WGYgLlDCFCfkQC+4bguVJmC/jvDRv2B+2wLOYhyE0fVuv7//Ckk39OoOufyCu76Q==", "cpu": [ - "ppc64" + "x64" ], "dev": true, + "libc": [ + "glibc" + ], "license": "MIT", "optional": true, "os": [ "linux" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-linux-ppc64-musl": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-musl/-/rollup-linux-ppc64-musl-4.62.0.tgz", - "integrity": "sha512-vRWUAbYLGHBZS6Q8Msb2sfnf1fvJf+47t8l/TwOerM2qArzy+IeNMTHrYLHXh95h8MoatPHI5hhSZNs+mGXKPg==", + "node_modules/@rolldown/binding-linux-x64-musl": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-x64-musl/-/binding-linux-x64-musl-1.2.19.tgz", + "integrity": "sha512-irh/4+iYFM4GAzpluDErgjz89bj6NDtqqMAG/6O1LG38Ed3NpyebzCpcVNkFW8uhy+/3/BocUvnXDR33CXWe9A==", "cpu": [ - "ppc64" + "x64" ], "dev": true, + "libc": [ + "musl" + ], "license": "MIT", "optional": true, "os": [ "linux" - ] + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.62.0.tgz", - "integrity": "sha512-c00T5SYENHAt86cfW47URaP3Us5vLC/4QO7GYud1G5VNRffCwwCuBspwqYrriuJB+5m0WFzClCn9wed0FBjKvg==", + "node_modules/@rolldown/binding-openharmony-arm64": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-openharmony-arm64/-/binding-openharmony-arm64-1.2.19.tgz", + "integrity": "sha512-+KWTWNoPt+CfSq94CiceWu3yPE+QzkaG+phPyz9G60tmZLwfQkcA4AeksafzvJAw4pvg1mcd5a1TkUqVv0s4JA==", "cpu": [ - "riscv64" + "arm64" ], "dev": true, "license": "MIT", "optional": true, "os": [ - "linux" - ] + "openharmony" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-linux-riscv64-musl": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.62.0.tgz", - "integrity": "sha512-krrCDilhXOwFkSkO3Wm9I/f9H0L92XHHwy2fwxjukxIbh0dem8gZqOW5Y8BsHrpJv5qwlRBV+Wl4ZFyRWhUpwg==", + "node_modules/@rolldown/binding-wasm32-wasi": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-wasm32-wasi/-/binding-wasm32-wasi-1.2.19.tgz", + "integrity": "sha512-7EH+skOsl5qpWnK0vzamgJFhOv1cwxQpsxm8tI883K9fur5c27p8q87fzEO6BbBPabA2/+s/zR63/pLc137iOg==", "cpu": [ - "riscv64" + "wasm32" ], "dev": true, "license": "MIT", "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.62.0.tgz", - "integrity": "sha512-7pfYFSTc4/rUC/FtAI0Qp6QthDBCIi6/AuP1xYqFk5vanI6KnL5dWKP60OM/05LOsbwTmIcvr6eXC4CJuJ75IA==", - "cpu": [ - "s390x" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.62.0.tgz", - "integrity": "sha512-7SDIalKeIpG0Ifogbbdn58HmSotYMlf23K3dCJEmiVd9Fg36Vmni82iPQec27N3wY4Bvbxftkxz6vSx9OcouTg==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.62.0.tgz", - "integrity": "sha512-eRZevouTH2i1HeAVLqJuLnt256krQkGY0TN6WsTmsIhuzbh457HuWDMakKwmi0Cjadux983CoSr8Lim2QhUIFw==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@rollup/rollup-openbsd-x64": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-openbsd-x64/-/rollup-openbsd-x64-4.62.0.tgz", - "integrity": "sha512-3oVS7FLGa4U1qcvao9ylGxrjXZyUQqR8UwxEcnUEyPX53O/C/mKDZegNXTdHCP+h3e6ta/f1EN38Yif1mmZHYg==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ] + "dependencies": { + "@emnapi/core": "2.0.0-beta.2", + "@emnapi/runtime": "2.0.0-beta.2", + "@napi-rs/wasm-runtime": "1.2.6" + }, + "engines": { + "node": "^20.19.0 || ^22.13.0 || >=23.5.0" + } }, - "node_modules/@rollup/rollup-openharmony-arm64": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.62.0.tgz", - "integrity": "sha512-yTB9TgfWj5wHe5QgktAgXTLLot1gvEjl1NiPPAUiCs4oPrIWFl5V4nC3GrkNdj9LaAU4s94nVrGbGOCqUpyWsg==", - "cpu": [ - "arm64" - ], + "node_modules/@rolldown/binding-wasm32-wasi/node_modules/@emnapi/runtime": { + "version": "2.0.0-beta.2", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-2.0.0-beta.2.tgz", + "integrity": "sha512-JcrSPzPvZuNZvJqPTF9Fw25LbOJ8avzFVlaf2grmH4Cku0oGP47tRgqPZadcfj3YoZMHkFVnCYFbQM8I+i5QEw==", "dev": true, "license": "MIT", "optional": true, - "os": [ - "openharmony" - ] + "dependencies": { + "tslib": "^2.4.0" + } }, - "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.62.0.tgz", - "integrity": "sha512-5LOhoaesY3doG1c+ac/2JtgREpKoJr5bUHH8tKY0V8di7+uSV6BwLs2PlR0/yzefGOkR+wE7ZolZphHCsyG5Rw==", + "node_modules/@rolldown/binding-win32-arm64-msvc": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-win32-arm64-msvc/-/binding-win32-arm64-msvc-1.2.19.tgz", + "integrity": "sha512-3Q1Yg1Q7tEvBWoZf5rFvG/GKZQPgwfru+p4wBajDfJFBs0SHCpL++dfTjW9gyAKd1T7ZpIYvdaUax7Pa/IhFVQ==", "cpu": [ "arm64" ], @@ -3966,26 +3723,15 @@ "optional": true, "os": [ "win32" - ] - }, - "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.62.0.tgz", - "integrity": "sha512-yYkWHhmbhRTWTnWos5HC4GcPQfjlzzCNbM9e/+GXrLuaBXYA3qSDR9f0Vgufd5S8yX81U8jPKp7ZnAjZFMtRnw==", - "cpu": [ - "ia32" ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] + "engines": { + "node": "^20.19.0 || >=22.12.0" + } }, - "node_modules/@rollup/rollup-win32-x64-gnu": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-gnu/-/rollup-win32-x64-gnu-4.62.0.tgz", - "integrity": "sha512-SoTb6lPg25xZlA2ibwQ++ahCCnH+FP0qmEuafMJ4gznZKOlXioKEAeJLgCrqjM98ACziXM9V1amFjICVL4IFoA==", + "node_modules/@rolldown/binding-win32-x64-msvc": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/@rolldown/binding-win32-x64-msvc/-/binding-win32-x64-msvc-1.2.19.tgz", + "integrity": "sha512-y/sqRRc6d7hECzOFc5n3LSeqctmIp9mMjY1Kq4s14uLPd/LZ4z7i1zrW6fMtp2mPeuQIC4e6ULMcwQzMomqQag==", "cpu": [ "x64" ], @@ -3994,21 +3740,23 @@ "optional": true, "os": [ "win32" - ] - }, - "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.62.0.tgz", - "integrity": "sha512-5L+T1fMX4RIEBoZzT0+sQ0PhTS36NULFmMXtl1TZo44TMAROIMHbZufSOjVWt/Y622BtxgxtaNOokbTDvfsrZA==", - "cpu": [ - "x64" ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/pluginutils": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@rolldown/pluginutils/-/pluginutils-1.1.1.tgz", + "integrity": "sha512-glFIJDvLNDtJhT9qrMFWLPbvS+skxgt4L0K8Ei2YtnhPysAJnsI7nyxSJxKj4ADeKX0OLjC4ntRkwpLOoS3rwA==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] + "license": "MIT" + }, + "node_modules/@silvia-odwyer/photon-node": { + "version": "0.3.4", + "resolved": "https://registry.npmjs.org/@silvia-odwyer/photon-node/-/photon-node-0.3.4.tgz", + "integrity": "sha512-bnly4BKB3KDTFxrUIcgCLbaeVVS8lrAkri1pEzskpmxu9MdfGQTy8b8EgcD83ywD3RPMsIulY8xJH5Awa+t9fA==", + "license": "Apache-2.0" }, "node_modules/@sindresorhus/is": { "version": "4.6.0", @@ -4024,12 +3772,12 @@ } }, "node_modules/@smithy/core": { - "version": "3.35.2", - "resolved": "https://registry.npmjs.org/@smithy/core/-/core-3.35.2.tgz", - "integrity": "sha512-ejTukBuP/Pg3t9N8Ux+0zKsXeHWm7p6W3HbXFOyltKasSxZwCFmvTut7kBdZSCF3m9y1bXXyVu6p2xuMFcsTyQ==", + "version": "3.41.0", + "resolved": "https://registry.npmjs.org/@smithy/core/-/core-3.41.0.tgz", + "integrity": "sha512-fuZ34H1uizS3WgcX9VXG7Uy8od5A5/kCc+CR3NkHLNm2H/BE9AUHG02VIdu8ZB7FYhLqsr/RZbqAoXuOCg/Oxg==", "license": "Apache-2.0", "dependencies": { - "@smithy/types": "^4.19.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -4051,13 +3799,13 @@ } }, "node_modules/@smithy/fetch-http-handler": { - "version": "5.8.0", - "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-5.8.0.tgz", - "integrity": "sha512-ycSJu3tFAQ4v04CBB0agqFMVsSQ1iG3yw+SpgxRqKfaURpQD4CZ8Wn0zPMmSnOuTpTh65Vz+EA0rMrw089wvkA==", + "version": "5.8.1", + "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-5.8.1.tgz", + "integrity": "sha512-h8BdMUrUBhMhMaeK7QqAdINRZezCGuYOCpcOZZ1ewxbHST9rdTd09xwNpvLTYfzDRehxQiReK4SKbdYZxBA+ew==", "license": "Apache-2.0", "dependencies": { - "@smithy/core": "^3.33.3", - "@smithy/types": "^4.18.0", + "@smithy/core": "^3.39.0", + "@smithy/types": "^4.20.0", "tslib": "^2.6.2" }, "engines": { @@ -4079,12 +3827,12 @@ } }, "node_modules/@smithy/signature-v4": { - "version": "5.7.4", - "resolved": "https://registry.npmjs.org/@smithy/signature-v4/-/signature-v4-5.7.4.tgz", - "integrity": "sha512-tHy0K0VtqNd5Y7Y41h0a0Lhh0L1GzC08dTWg0F7vRJWFtTENg7IZikf3wQkanYIRdb7ngoIPMTmqgUi401fEeQ==", + "version": "5.7.5", + "resolved": "https://registry.npmjs.org/@smithy/signature-v4/-/signature-v4-5.7.5.tgz", + "integrity": "sha512-WPjdr5oWOk1LArpI4pavu+fSo+/evi0Re1olxGvqwuZopd4gYR1UGCi+Soyn/IjmafqbWs+ZC+3AKxJS3ZpwUg==", "license": "Apache-2.0", "dependencies": { - "@smithy/core": "^3.35.0", + "@smithy/core": "^3.38.0", "@smithy/types": "^4.19.0", "tslib": "^2.6.2" }, @@ -4093,9 +3841,9 @@ } }, "node_modules/@smithy/types": { - "version": "4.19.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-4.19.0.tgz", - "integrity": "sha512-r7jh49VJxGerfAcTQA6gXcKc+98zOp/tqRwzYjgOE+iSQsP6cEU1hq2QzbuipmP68QtYdY9wKEhiCQZIzHgZ4Q==", + "version": "4.20.0", + "resolved": "https://registry.npmjs.org/@smithy/types/-/types-4.20.0.tgz", + "integrity": "sha512-lCA6QG22dPk9ecHbv91jDQZsmtPUjdS1aE2Il6NNPqe7DrYc0dZQi6DhcESk2KYXH2sp5xbAcGdYMZDFnuzA2A==", "license": "Apache-2.0", "dependencies": { "tslib": "^2.6.2" @@ -4110,13 +3858,6 @@ "integrity": "sha512-1bnPQqSxSuc3Ii6MhBysoWCg58j97aUjuCSZrGSmDxNqtytIi0k8utUenAwTZN4V5mXXYGsVUI9zeBqy+jBOSQ==", "license": "MIT" }, - "node_modules/@standard-schema/spec": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@standard-schema/spec/-/spec-1.1.0.tgz", - "integrity": "sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w==", - "dev": true, - "license": "MIT" - }, "node_modules/@szmarczak/http-timer": { "version": "4.0.6", "resolved": "https://registry.npmjs.org/@szmarczak/http-timer/-/http-timer-4.0.6.tgz", @@ -4130,49 +3871,15 @@ "node": ">=10" } }, - "node_modules/@types/babel__core": { - "version": "7.20.5", - "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", - "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@babel/parser": "^7.20.7", - "@babel/types": "^7.20.7", - "@types/babel__generator": "*", - "@types/babel__template": "*", - "@types/babel__traverse": "*" - } - }, - "node_modules/@types/babel__generator": { - "version": "7.27.0", - "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.27.0.tgz", - "integrity": "sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg==", - "dev": true, - "license": "MIT", - "dependencies": { - "@babel/types": "^7.0.0" - } - }, - "node_modules/@types/babel__template": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", - "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", - "dev": true, - "license": "MIT", - "dependencies": { - "@babel/parser": "^7.1.0", - "@babel/types": "^7.0.0" - } - }, - "node_modules/@types/babel__traverse": { - "version": "7.28.0", - "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.28.0.tgz", - "integrity": "sha512-8PvcXf70gTDZBgt9ptxJ8elBeBjcLOAcOtoO/mPJjtji1+CdGbHgm77om1GrsPxsiE+uXIpNSK64UYaIwQXd4Q==", + "node_modules/@tybys/wasm-util": { + "version": "0.10.5", + "resolved": "https://registry.npmjs.org/@tybys/wasm-util/-/wasm-util-0.10.5.tgz", + "integrity": "sha512-dOGOPxlaNV+G046mZzN+9C0dAcQZeSKcXiVaM0TYy/LM4ttTmgSBDxYfovcYI8Em3+eAbiAYpvWLOv8+ZVRJKA==", "dev": true, "license": "MIT", + "optional": true, "dependencies": { - "@babel/types": "^7.28.2" + "tslib": "^2.4.0" } }, "node_modules/@types/cacheable-request": { @@ -4215,10 +3922,17 @@ "dev": true, "license": "MIT" }, + "node_modules/@types/esrecurse": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/@types/esrecurse/-/esrecurse-4.3.1.tgz", + "integrity": "sha512-xJBAbDifo5hpffDBuHl0Y8ywswbiAp/Wi7Y/GtAgSlZyIABppyurxVueOPE8LUQOxdlgi6Zqce7uoEpqNTeiUw==", + "dev": true, + "license": "MIT" + }, "node_modules/@types/estree": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.9.tgz", - "integrity": "sha512-GhdPgy1el4/ImP05X05Uw4cw2/M93BCUmnEvWZNStlCzEKME4Fkk+YpoA5OiHNQmoS7Cafb8Xa3Pya8m1Qrzeg==", + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.10.tgz", + "integrity": "sha512-lTyOMnOcmRBzdCv6/4zUZCrEhV0xrqQiUZBZtVcbmLHBXKLnN8q89v/wKRF/Q0HbwVsqbIG3o5HDoFl9sduM+g==", "license": "MIT" }, "node_modules/@types/estree-jsx": { @@ -4241,9 +3955,9 @@ } }, "node_modules/@types/hast": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@types/hast/-/hast-3.0.4.tgz", - "integrity": "sha512-WPs+bbQw5aCj+x6laNGWLH3wviHtoCv/P3+otBhbOhJgG8qtpdAMlTCxLtsTWA7LH1Oh/bFCHsBn0TPS5m30EQ==", + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@types/hast/-/hast-3.0.5.tgz", + "integrity": "sha512-rp/ezSWaD1m44dPKICGhiskI13nVr7qTloFwDa/IYkhhf5nzwP+zIQcIJh3WIFSBOy/H1PzB40jPjMDksN4F+g==", "license": "MIT", "dependencies": { "@types/unist": "*" @@ -4289,18 +4003,18 @@ "license": "MIT" }, "node_modules/@types/node": { - "version": "22.19.21", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.19.21.tgz", - "integrity": "sha512-VMeFBSCKQKmm2swI2kW51SFusDqekC6q9trBCvJ/JliDchFSuoYYKN7yVNjPthP1HKZcx3U1gI/wTcEBjEFKTA==", + "version": "24.19.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-24.19.2.tgz", + "integrity": "sha512-93d49wCWJkCyN87MxLpNN6KXPCwFw7bVUg79mGUV1OS40JGWwVCr8n61DXCSqz7CV6/VfPkb7xec7uP2M+QHWQ==", "license": "MIT", "dependencies": { - "undici-types": "~6.21.0" + "undici-types": ">=7.24.0 <7.24.7" } }, "node_modules/@types/react": { - "version": "19.2.17", - "resolved": "https://registry.npmjs.org/@types/react/-/react-19.2.17.tgz", - "integrity": "sha512-MXfmqaVPEVgkBT/aY0aGCkRWWtByiYQXo3xdQ8r5RzuFrPiRn8Gar2tQdXSUQ2GKV3bkXckek89V8wQBY2Q/Aw==", + "version": "19.3.0", + "resolved": "https://registry.npmjs.org/@types/react/-/react-19.3.0.tgz", + "integrity": "sha512-N0rFCuH9YoxG9/m61l9MfpJKfmLOVU0em7ipIz6TRgSSkvReLB9vL85GB+yr8Bs5leqpvg96JSwF4ZS1s4viQg==", "dev": true, "license": "MIT", "dependencies": { @@ -4308,13 +4022,13 @@ } }, "node_modules/@types/react-dom": { - "version": "19.2.3", - "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-19.2.3.tgz", - "integrity": "sha512-jp2L/eY6fn+KgVVQAOqYItbF0VY/YApe5Mz2F0aykSO8gx31bYCZyvSeYxCHKvzHG5eZjc+zyaS5BrBWya2+kQ==", + "version": "19.3.0", + "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-19.3.0.tgz", + "integrity": "sha512-ZI7bU42mZXXKHn/qNLEw2IrbiINU7X5+vfgdixBHkCNpYWXjKgfQ/P+uyGb5CjOLB9UcnTeg3rylQtV2hym44Q==", "dev": true, "license": "MIT", "peerDependencies": { - "@types/react": "^19.2.0" + "@types/react": "^19.3.0" } }, "node_modules/@types/responselike": { @@ -4358,17 +4072,17 @@ } }, "node_modules/@typescript-eslint/eslint-plugin": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.61.1.tgz", - "integrity": "sha512-ZPlVl3PB3et/59Ne0fv/sci6ZXz4T4Hp4nTJ56i/Y0gR89ARb+KphojTq6j+56E5PIezmOIOOWyY+aWQFd+IkQ==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.73.0.tgz", + "integrity": "sha512-UkygMFer53Yzn29MCYFTHf34hGXf5KJhiDWfIm1tXtXRrym1CS6l5H9Y3yCtPWChpC0/f93H88gdj8tN0dd4kw==", "dev": true, "license": "MIT", "dependencies": { "@eslint-community/regexpp": "^4.12.2", - "@typescript-eslint/scope-manager": "8.61.1", - "@typescript-eslint/type-utils": "8.61.1", - "@typescript-eslint/utils": "8.61.1", - "@typescript-eslint/visitor-keys": "8.61.1", + "@typescript-eslint/scope-manager": "8.73.0", + "@typescript-eslint/type-utils": "8.73.0", + "@typescript-eslint/utils": "8.73.0", + "@typescript-eslint/visitor-keys": "8.73.0", "ignore": "^7.0.5", "natural-compare": "^1.4.0", "ts-api-utils": "^2.5.0" @@ -4381,22 +4095,22 @@ "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "@typescript-eslint/parser": "^8.61.1", + "@typescript-eslint/parser": "^8.73.0", "eslint": "^8.57.0 || ^9.0.0 || ^10.0.0", "typescript": ">=4.8.4 <6.1.0" } }, "node_modules/@typescript-eslint/parser": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.61.1.tgz", - "integrity": "sha512-PJ5vePq5/ognBbrIcoC5+SHO5dfpeLPzP9FpLkzWrguoYQEeeSjlJpVwOpo1JRSTEi7dRcwNy4h4dzV70PqHcg==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.73.0.tgz", + "integrity": "sha512-AuL45bVcmssHfZ3Di3cs9Q0l4gBm4ZFVrJOQEE7VpqW+PVgQaEwSwazz4TVIiFabXkk6U51EprYDwqw+HR8ePw==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/scope-manager": "8.61.1", - "@typescript-eslint/types": "8.61.1", - "@typescript-eslint/typescript-estree": "8.61.1", - "@typescript-eslint/visitor-keys": "8.61.1", + "@typescript-eslint/scope-manager": "8.73.0", + "@typescript-eslint/types": "8.73.0", + "@typescript-eslint/typescript-estree": "8.73.0", + "@typescript-eslint/visitor-keys": "8.73.0", "debug": "^4.4.3" }, "engines": { @@ -4412,14 +4126,14 @@ } }, "node_modules/@typescript-eslint/project-service": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.61.1.tgz", - "integrity": "sha512-PrC4JYGmR241lYnfhmKGTXkFqv8+ymbTFgSAY0fVXpY82/QkMw5TZPl+vGzuDDU2QYJk9fIDOBTntF+yDv9LEA==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.73.0.tgz", + "integrity": "sha512-/pEf8Rc4Mjk+qJnY0uO1+Gadeal8uv50xpuic+srG2vIVatA0XxvWMUeMtFvs6OCHqftiQ7/+qH4aehG5stzIA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/tsconfig-utils": "^8.61.1", - "@typescript-eslint/types": "^8.61.1", + "@typescript-eslint/tsconfig-utils": "^8.73.0", + "@typescript-eslint/types": "^8.73.0", "debug": "^4.4.3" }, "engines": { @@ -4434,14 +4148,14 @@ } }, "node_modules/@typescript-eslint/scope-manager": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.61.1.tgz", - "integrity": "sha512-L2bdIeoQS8FlKAvONAr20w6OcLXeB+qiDKbAooS9A0Ben+iSIkBef0FxqwKWYqt5sa0i4KJtxVyVmhMylKzF5w==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.73.0.tgz", + "integrity": "sha512-/TjD738Iq2rzj5z0ixVOi+TsvgjAzZPLPaH1yWdDBytR/HTR5gMpyYWZeCe5WTQZLwk3ho8AV7U3muoQCRtXBQ==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.61.1", - "@typescript-eslint/visitor-keys": "8.61.1" + "@typescript-eslint/types": "8.73.0", + "@typescript-eslint/visitor-keys": "8.73.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -4452,9 +4166,9 @@ } }, "node_modules/@typescript-eslint/tsconfig-utils": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.61.1.tgz", - "integrity": "sha512-UN/H4di+OO7EWx2ovME+8t31YO+KVnK0RRKEHR3kOt21/Ay8BOq3M1OMvWs5vNiqcFCYGYoxK3MXPZzmMUE+yg==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.73.0.tgz", + "integrity": "sha512-lmtCFOfYaJfpqZywGuXi4FpNtE+NQ+YLe3T0K9rtEDcW8ZuGWvfI++pj8r05sYMI8vWT2CYK4rWyedmD6Rp4og==", "dev": true, "license": "MIT", "engines": { @@ -4469,15 +4183,15 @@ } }, "node_modules/@typescript-eslint/type-utils": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.61.1.tgz", - "integrity": "sha512-GYRicKmVK0C4fsKgaACaknOUAq9Oa2kwsjnpFhFcS/5p4Ht5IP9OVLbgIgcK4SRk92nVHFluurg1lumD9dBcLw==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.73.0.tgz", + "integrity": "sha512-MOC9i4xy1F7KcDde7Ip8jf1SrRiALb2Km4UWxGNjUE2YlhjIEo1ayE27GHIwIQyfWuHTmEonQT14uyurlyC6aA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.61.1", - "@typescript-eslint/typescript-estree": "8.61.1", - "@typescript-eslint/utils": "8.61.1", + "@typescript-eslint/types": "8.73.0", + "@typescript-eslint/typescript-estree": "8.73.0", + "@typescript-eslint/utils": "8.73.0", "debug": "^4.4.3", "ts-api-utils": "^2.5.0" }, @@ -4494,9 +4208,9 @@ } }, "node_modules/@typescript-eslint/types": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.61.1.tgz", - "integrity": "sha512-G+CRlPqLv7Bz1IZVs03x5K59F1veqL0EJUROAdGhKsEq8qOiRiZbI+HUojPq5l0fEGOKModD9br6lObhB8zkoA==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.73.0.tgz", + "integrity": "sha512-O/1ytYzflF16QDKXx4/qOXg1IuZp+n7hr9t+S0nv7N/2Tl8rJiNCshztV1gcSUvHbPtoX3+zmNbtSAyVbzxVfw==", "dev": true, "license": "MIT", "engines": { @@ -4508,18 +4222,18 @@ } }, "node_modules/@typescript-eslint/typescript-estree": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.61.1.tgz", - "integrity": "sha512-u+oQD3BqYWPc8YV9Zab4vaJElJuwOLPRc10Jm1o/qS+6Qwen14HCWwx0Seo4LnSn2wxea2Ik8DxPt2/FHmuhrg==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.73.0.tgz", + "integrity": "sha512-InjlBkSdWceIwIBWSwS3ENUp+i0O02PGX3Zv2wnihWJC1WDVGvG7mTHuf8b57uAaITj94d6tRPDH+sUEtXdRQQ==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/project-service": "8.61.1", - "@typescript-eslint/tsconfig-utils": "8.61.1", - "@typescript-eslint/types": "8.61.1", - "@typescript-eslint/visitor-keys": "8.61.1", + "@typescript-eslint/project-service": "8.73.0", + "@typescript-eslint/tsconfig-utils": "8.73.0", + "@typescript-eslint/types": "8.73.0", + "@typescript-eslint/visitor-keys": "8.73.0", "debug": "^4.4.3", - "minimatch": "^10.2.2", + "minimatch": "^11.0.1", "semver": "^7.7.3", "tinyglobby": "^0.2.15", "ts-api-utils": "^2.5.0" @@ -4532,20 +4246,43 @@ "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { + "@typescript/native": "npm:typescript@>=7.1.0-dev.20261009.1 || >=7.1.0-beta <7.1.0-dev", "typescript": ">=4.8.4 <6.1.0" + }, + "peerDependenciesMeta": { + "@typescript/native": { + "optional": true + } + } + }, + "node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch": { + "version": "11.0.9", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-11.0.9.tgz", + "integrity": "sha512-KCFkfyjqerNlSstjlhIGNXIKZGA/6O4V4RlhZ+Dsr621SPPw0mzlypE9D9ZOoPiVefHID+j7/XuMMlqfD/F60Q==", + "dev": true, + "license": "BlueOak-1.0.0", + "dependencies": { + "@isaacs/nonrecursive-glob-match": "^1.1.0", + "brace-expansion": "^5.0.12" + }, + "engines": { + "node": "20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, "node_modules/@typescript-eslint/utils": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.61.1.tgz", - "integrity": "sha512-1+P/3Dj6jvtybE1q0HQ6yBt/gq+oKJyLdEv4HdnqasaEXRSYCAsD59mXEVQnM/ULNdQxbX77tdG4jPRjIS6knA==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.73.0.tgz", + "integrity": "sha512-j2SVJJvVkXdUL0WcEzo4vEH1mO1vIi8KlVukcYA2MgMZvYN2LlZR4PmsW+GTSxSW24j6Q/EP7+MOifLtg5hmsA==", "dev": true, "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.9.1", - "@typescript-eslint/scope-manager": "8.61.1", - "@typescript-eslint/types": "8.61.1", - "@typescript-eslint/typescript-estree": "8.61.1" + "@typescript-eslint/scope-manager": "8.73.0", + "@typescript-eslint/types": "8.73.0", + "@typescript-eslint/typescript-estree": "8.73.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -4560,13 +4297,13 @@ } }, "node_modules/@typescript-eslint/visitor-keys": { - "version": "8.61.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.61.1.tgz", - "integrity": "sha512-6fJ9MHWtK14C1DSkiMlHUSOmrVebL7150xZJBlJiL62jjhIA4JmOq6flwBgDxIdBKKdoiZRel+dfPD5MLfny3w==", + "version": "8.73.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.73.0.tgz", + "integrity": "sha512-k4lsFVpRZICbltkIEEH4hZRkwXkqDF1GHBpClKQOHQY+RkoZAAuyc1ci3I6p+CB6v3U4jaHIUshc4RzzQXZWLg==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.61.1", + "@typescript-eslint/types": "8.73.0", "eslint-visitor-keys": "^5.0.0" }, "engines": { @@ -4591,60 +4328,52 @@ } }, "node_modules/@vitejs/plugin-react": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@vitejs/plugin-react/-/plugin-react-5.2.0.tgz", - "integrity": "sha512-YmKkfhOAi3wsB1PhJq5Scj3GXMn3WvtQ/JC0xoopuHoXSdmtdStOpFrYaT1kie2YgFBcIe64ROzMYRjCrYOdYw==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@vitejs/plugin-react/-/plugin-react-6.3.0.tgz", + "integrity": "sha512-H9E955aVvD2F4zNHCw4eIZbIfF6xKldlh7MNu+hSU7xwQzh65lI/N+CJWqmfhi0PEjDXIt/H7T7J/4wU63KJiw==", "dev": true, "license": "MIT", "dependencies": { - "@babel/core": "^7.29.0", - "@babel/plugin-transform-react-jsx-self": "^7.27.1", - "@babel/plugin-transform-react-jsx-source": "^7.27.1", - "@rolldown/pluginutils": "1.0.0-rc.3", - "@types/babel__core": "^7.20.5", - "react-refresh": "^0.18.0" + "@rolldown/pluginutils": "^1.0.1" }, "engines": { "node": "^20.19.0 || >=22.12.0" }, "peerDependencies": { - "vite": "^4.2.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0" - } - }, - "node_modules/@vitest/expect": { - "version": "4.1.9", - "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-4.1.9.tgz", - "integrity": "sha512-vl/rYsUKcBr3SnQn166+XR5ZQcgMx3DQhFWdfli/cWpLnLUmbxZvyrJZotLFUryib+LtArYMSTJ5RbQ57ZqrlA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@standard-schema/spec": "^1.1.0", - "@types/chai": "^5.2.2", - "@vitest/spy": "4.1.9", - "@vitest/utils": "4.1.9", - "chai": "^6.2.2", - "tinyrainbow": "^3.1.0" + "@rolldown/plugin-babel": "^0.1.7 || ^0.2.0 || ^0.3.0", + "babel-plugin-react-compiler": "^1.0.0", + "oxc-transform-react": ">=0.152.0 <0.157.0", + "vite": "^8.0.0" }, - "funding": { - "url": "https://opencollective.com/vitest" + "peerDependenciesMeta": { + "@rolldown/plugin-babel": { + "optional": true + }, + "babel-plugin-react-compiler": { + "optional": true + }, + "oxc-transform-react": { + "optional": true + } } }, "node_modules/@vitest/mocker": { - "version": "4.1.9", - "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-4.1.9.tgz", - "integrity": "sha512-EVkXzBjrPGM+cK8/ANWgBrkUCfJfb38/EfTSO8h7pWvKkyPkpWxvR7BkD2MyItMF62C97zAEoqdpUixwR/e+Rw==", + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-5.1.1.tgz", + "integrity": "sha512-b2OgTB4+3ImWIVafXKazJXwLKwQxUNnix6b3xUvUTMh7RyXlrtzoxfZr8aEz9zkHOMAS4K5lu3TvFWoiVeVTQg==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/spy": "4.1.9", + "@jridgewell/trace-mapping": "0.3.31", + "@vitest/spy": "5.1.1", "estree-walker": "^3.0.3", - "magic-string": "^0.30.21" + "magic-string": "^1.4.5" }, "funding": { "url": "https://opencollective.com/vitest" }, "peerDependencies": { - "msw": "^2.4.9", + "msw": "^2.4.9 || ^3.0.0", "vite": "^6.0.0 || ^7.0.0 || ^8.0.0" }, "peerDependenciesMeta": { @@ -4656,105 +4385,78 @@ } } }, - "node_modules/@vitest/pretty-format": { - "version": "4.1.9", - "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-4.1.9.tgz", - "integrity": "sha512-s0iufns3iIFitdgm+YR7g1whCAaGtXz459VS9/PqyKDEEFgYIhsHOQmXgIgDuYCt7DeQmiZT0Qe2OA2p4ZPu5A==", - "dev": true, - "license": "MIT", - "dependencies": { - "tinyrainbow": "^3.1.0" - }, - "funding": { - "url": "https://opencollective.com/vitest" - } - }, - "node_modules/@vitest/runner": { - "version": "4.1.9", - "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-4.1.9.tgz", - "integrity": "sha512-KXLMDtc7oe70+3mJfGrPUWPesswH+3sTxAMAMl8DG7I8IUQT4XW718dY5ID3vPUcmlu27CcKfY4P3h3I29SLJg==", + "node_modules/@vitest/spy": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-5.1.1.tgz", + "integrity": "sha512-6K8C6alQG1/Yc8/ZI22iJS7JEsxPdVzqtqDq+/xM4Z0mGVykemMVjLhqMy/q6/IHYG3kKD8hKSwRen/ZdyI9vQ==", "dev": true, "license": "MIT", - "dependencies": { - "@vitest/utils": "4.1.9", - "pathe": "^2.0.3" - }, "funding": { "url": "https://opencollective.com/vitest" } }, - "node_modules/@vitest/snapshot": { - "version": "4.1.9", - "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-4.1.9.tgz", - "integrity": "sha512-Jc7RKGNBo8Z28WYIm0Niej4xdSPByRf6mU58VpHQkd6Zh05rlnA+twjbK5HyeIGHxrzsc3mJgS43uM0CZKzaIA==", - "dev": true, + "node_modules/@xmldom/xmldom": { + "version": "0.9.12", + "resolved": "https://registry.npmjs.org/@xmldom/xmldom/-/xmldom-0.9.12.tgz", + "integrity": "sha512-5AXjrcMClTryPe9LgZrygpB1lj7s0S9E0+W+AHaVKAVyHanafK86iPSvG5xHVSp/jC+VH1UXu0TAEmY279xH7A==", "license": "MIT", - "dependencies": { - "@vitest/pretty-format": "4.1.9", - "@vitest/utils": "4.1.9", - "magic-string": "^0.30.21", - "pathe": "^2.0.3" - }, - "funding": { - "url": "https://opencollective.com/vitest" + "optional": true, + "engines": { + "node": ">=14.6" } }, - "node_modules/@vitest/spy": { - "version": "4.1.9", - "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-4.1.9.tgz", - "integrity": "sha512-fHpsS6mIi+PiEW+vcRVOMkX1oSaPKne3VOclSFICPcGOmfKgXPU5iAah+wcNcj2xPrCCmfq99IDGf+EojhhvhA==", + "node_modules/abbrev": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-4.0.0.tgz", + "integrity": "sha512-a1wflyaL0tHtJSmLSOVybYhy22vRih4eduhhrkcjgrWGnRfrZtovJ2FRjxuTtkkj47O/baf0R86QU5OuYpz8fA==", "dev": true, - "license": "MIT", - "funding": { - "url": "https://opencollective.com/vitest" + "license": "ISC", + "engines": { + "node": "^20.17.0 || >=22.9.0" } }, - "node_modules/@vitest/utils": { - "version": "4.1.9", - "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-4.1.9.tgz", - "integrity": "sha512-A51o8ymO5PpqlWNnBP9ZHPXDIpuMtTLlGSjN7la4US+LJzoUMyhwjA5QXlm39JexgwHKW4Xjs8Z2d3dLCXOeuA==", - "dev": true, + "node_modules/accepts": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-2.0.0.tgz", + "integrity": "sha512-5cvg6CtKwfgdmVqY1WIiXKc3Q1bkRqGLi+2W/6ao+6Y7gu/RCwRuAhGEzh5B4KlszSuTLgZYuqFqo5bImjNKng==", "license": "MIT", "dependencies": { - "@vitest/pretty-format": "4.1.9", - "convert-source-map": "^2.0.0", - "tinyrainbow": "^3.1.0" + "mime-types": "^3.0.0", + "negotiator": "^1.0.0" }, - "funding": { - "url": "https://opencollective.com/vitest" + "engines": { + "node": ">= 0.6" } }, - "node_modules/@xmldom/xmldom": { - "version": "0.8.13", - "resolved": "https://registry.npmjs.org/@xmldom/xmldom/-/xmldom-0.8.13.tgz", - "integrity": "sha512-KRYzxepc14G/CEpEGc3Yn+JKaAeT63smlDr+vjB8jRfgTBBI9wRj/nkQEO+ucV8p8I9bfKLWp37uHgFrbntPvw==", - "dev": true, + "node_modules/accepts/node_modules/mime-db": { + "version": "1.54.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", + "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", "license": "MIT", "engines": { - "node": ">=10.0.0" + "node": ">= 0.6" } }, - "node_modules/@yarnpkg/lockfile": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@yarnpkg/lockfile/-/lockfile-1.1.0.tgz", - "integrity": "sha512-GpSwvyXOcOOlV70vbnzjj4fW5xW/FdUF6nQEt1ENy7m4ZCczi1+/buVUPAqmGfqznsORNFzUMjctTIp8a9tuCQ==", - "dev": true, - "license": "BSD-2-Clause" - }, - "node_modules/abbrev": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-4.0.0.tgz", - "integrity": "sha512-a1wflyaL0tHtJSmLSOVybYhy22vRih4eduhhrkcjgrWGnRfrZtovJ2FRjxuTtkkj47O/baf0R86QU5OuYpz8fA==", - "dev": true, - "license": "ISC", + "node_modules/accepts/node_modules/mime-types": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.2.tgz", + "integrity": "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==", + "license": "MIT", + "dependencies": { + "mime-db": "^1.54.0" + }, "engines": { - "node": "^20.17.0 || >=22.9.0" + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, "node_modules/acorn": { - "version": "8.17.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.17.0.tgz", - "integrity": "sha512-xRQbDb9BnwDafYNn6Vwl839DYVjqXYb1XVGtWAZ1kcDc6iwAL4hg3B1dZlRiuENFeO2H53gFG3in621AdERVAg==", + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.19.0.tgz", + "integrity": "sha512-oJlA3XiRm7Cyk6qFD2Jn8ak9B7jSy0qy00ADO3+8dpT0LSjFihQYv4C02LFCSYJV3Q37xYwwRy5m+IpIiUzqWw==", "license": "MIT", "bin": { "acorn": "bin/acorn" @@ -4773,16 +4475,17 @@ } }, "node_modules/acpx": { - "version": "0.13.1", - "resolved": "https://registry.npmjs.org/acpx/-/acpx-0.13.1.tgz", - "integrity": "sha512-9zhvUrAR4XxSIgaLCiiWmrwmEWh+m6jxu2KUFC8BMOiK4sFsnrRL7H6VF54ZLTTpt0IHrZQju2V7+8wiMf9DXQ==", + "version": "0.22.0", + "resolved": "https://registry.npmjs.org/acpx/-/acpx-0.22.0.tgz", + "integrity": "sha512-dD+xgRwLFOfwL7/VEdn3zrVNFleFoIA0EUETK35w/e+MeYB5FN5+vKERoV60d4SUirTqX610yb/wN+2OFcjpMQ==", "license": "MIT", "dependencies": { - "@agentclientprotocol/sdk": "^1.3.0", + "@agentclientprotocol/sdk": "^1.9.0", + "@openclaw/fs-safe": "^0.27.0", "commander": "^15.0.0", "skillflag": "^0.2.1", - "tsx": "^4.23.1", - "zod": "^4.4.3" + "tsx": "^4.23.15", + "zod": "^4.6.7" }, "bin": { "acpx": "dist/cli.js" @@ -4791,15 +4494,6 @@ "node": ">=22.13.0" } }, - "node_modules/acpx/node_modules/commander": { - "version": "15.0.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-15.0.0.tgz", - "integrity": "sha512-z67u4ZhzCL/Tydu1lJARtEZYWbWaN7oYLHbsuzocr6y4N6WZAagG3RQ4FW61V1/0+jImpj293XfrcYnd1qxtPg==", - "license": "MIT", - "engines": { - "node": ">=22.12.0" - } - }, "node_modules/adm-zip": { "version": "0.6.1", "resolved": "https://registry.npmjs.org/adm-zip/-/adm-zip-0.6.1.tgz", @@ -4810,31 +4504,47 @@ } }, "node_modules/agent-base": { - "version": "7.1.4", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", - "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-9.0.0.tgz", + "integrity": "sha512-TQf59BsZnytt8GdJKLPfUZ54g/iaUL2OWDSFCCvMOhsHduDQxO8xC4PNeyIkVcA5KwL2phPSv0douC0fgWzmnA==", "license": "MIT", "engines": { - "node": ">= 14" + "node": ">= 20" } }, "node_modules/ajv": { - "version": "6.15.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.15.0.tgz", - "integrity": "sha512-fgFx7Hfoq60ytK2c7DhnF8jIvzYgOMxfugjLOSMHjLIPgenqa7S7oaagATUq99mV6IYvN2tRmC0wnTYX6iPbMw==", - "dev": true, + "version": "8.20.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.20.0.tgz", + "integrity": "sha512-Thbli+OlOj+iMPYFBVBfJ3OmCAnaSyNn4M1vz9T6Gka5Jt9ba/HIR56joy65tY6kx/FCF5VXNB819Y7/GUrBGA==", "license": "MIT", "dependencies": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" + "fast-deep-equal": "^3.1.3", + "fast-uri": "^3.0.1", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2" }, "funding": { "type": "github", "url": "https://github.com/sponsors/epoberezkin" } }, + "node_modules/ajv-formats": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-3.0.1.tgz", + "integrity": "sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ==", + "license": "MIT", + "dependencies": { + "ajv": "^8.0.0" + }, + "peerDependencies": { + "ajv": "^8.0.0" + }, + "peerDependenciesMeta": { + "ajv": { + "optional": true + } + } + }, "node_modules/ansi-regex": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", @@ -4862,9 +4572,9 @@ } }, "node_modules/app-builder-lib": { - "version": "26.15.3", - "resolved": "https://registry.npmjs.org/app-builder-lib/-/app-builder-lib-26.15.3.tgz", - "integrity": "sha512-2VnyWkqsP5v5XbBhL3tD5Syx8iNPBYsoU7kY4S2fz7wg8Rj/nztWKCUzGKaFRTv0Xwf3/H058CR1Kvtd/3lRow==", + "version": "26.18.1", + "resolved": "https://registry.npmjs.org/app-builder-lib/-/app-builder-lib-26.18.1.tgz", + "integrity": "sha512-HxHcSQoy8RmiFCSxgKyt5Lrwx8HCURh5834TRaHEjkDkVS2wVt3RnkQDkG0zaQZfhz3d8WQtF8zv914xSm0ZpA==", "dev": true, "license": "MIT", "dependencies": { @@ -4873,24 +4583,24 @@ "@electron/get": "^3.0.0", "@electron/notarize": "2.5.0", "@electron/osx-sign": "1.3.3", - "@electron/rebuild": "^4.0.4", + "@electron/rebuild": "^4.2.1", "@electron/universal": "2.0.3", "@malept/flatpak-bundler": "^0.4.0", - "@noble/hashes": "^2.2.0", + "@noble/hashes": "^1.8.0", "@peculiar/webcrypto": "^1.7.1", "@types/fs-extra": "9.0.13", "ajv": "^8.18.0", "asn1js": "^3.0.10", "async-exit-hook": "^2.0.1", - "builder-util": "26.15.3", - "builder-util-runtime": "9.7.0", + "builder-util": "26.18.1", + "builder-util-runtime": "9.7.1", "chromium-pickle-js": "^0.2.0", "ci-info": "4.3.1", "debug": "^4.3.4", "dotenv": "^16.4.5", "dotenv-expand": "^11.0.6", "ejs": "^3.1.8", - "electron-publish": "26.15.3", + "electron-publish": "26.18.1", "fs-extra": "^10.1.0", "hosted-git-info": "^4.1.0", "isbinaryfile": "^5.0.0", @@ -4914,8 +4624,8 @@ "node": ">=14.0.0" }, "peerDependencies": { - "dmg-builder": "26.15.3", - "electron-builder-squirrel-windows": "26.15.3" + "dmg-builder": "26.18.1", + "electron-builder-squirrel-windows": "26.18.1" } }, "node_modules/app-builder-lib/node_modules/@electron/get": { @@ -4956,36 +4666,19 @@ } }, "node_modules/app-builder-lib/node_modules/@electron/get/node_modules/semver": { - "version": "6.3.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", - "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "version": "6.3.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.2.tgz", + "integrity": "sha512-GYrCADwpu6yV5OAvchkQ27Z5wwMxWAEMg5NNWjyHh/5DboFFqbdbvYNIvZouQpxXyeMPoTOh0vdPYKlf0ZswdQ==", "dev": true, "license": "ISC", "bin": { "semver": "bin/semver.js" } }, - "node_modules/app-builder-lib/node_modules/ajv": { - "version": "8.20.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.20.0.tgz", - "integrity": "sha512-Thbli+OlOj+iMPYFBVBfJ3OmCAnaSyNn4M1vz9T6Gka5Jt9ba/HIR56joy65tY6kx/FCF5VXNB819Y7/GUrBGA==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/app-builder-lib/node_modules/ci-info": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", - "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "node_modules/app-builder-lib/node_modules/ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", "dev": true, "funding": [ { @@ -5008,6 +4701,38 @@ "node": ">=6" } }, + "node_modules/app-builder-lib/node_modules/global-agent": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/global-agent/-/global-agent-3.0.0.tgz", + "integrity": "sha512-PT6XReJ+D07JvGoxQMkT6qji/jVNfX/h364XHZOWeRzy64sSFr+xJ5OX7LI3b4MPQzdL4H8Y8M0xzPpsVMwA8Q==", + "dev": true, + "license": "BSD-3-Clause", + "optional": true, + "dependencies": { + "boolean": "^3.0.1", + "es6-error": "^4.1.1", + "matcher": "^3.0.0", + "roarr": "^2.15.3", + "semver": "^7.3.2", + "serialize-error": "^7.0.1" + }, + "engines": { + "node": ">=10.0" + } + }, + "node_modules/app-builder-lib/node_modules/hosted-git-info": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", + "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", + "dev": true, + "license": "ISC", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/app-builder-lib/node_modules/isexe": { "version": "3.1.5", "resolved": "https://registry.npmjs.org/isexe/-/isexe-3.1.5.tgz", @@ -5018,13 +4743,6 @@ "node": ">=18" } }, - "node_modules/app-builder-lib/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true, - "license": "MIT" - }, "node_modules/app-builder-lib/node_modules/jsonfile": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", @@ -5035,6 +4753,33 @@ "graceful-fs": "^4.1.6" } }, + "node_modules/app-builder-lib/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/app-builder-lib/node_modules/matcher": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/matcher/-/matcher-3.0.0.tgz", + "integrity": "sha512-OkeDaAZ/bQCxeFAozM55PKcKU0yJMPGifLwV4Qgjitu+5MoAfSQN4lsLJeXZ1b8w0x+/Emda6MZgXS1jvsapng==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "escape-string-regexp": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/app-builder-lib/node_modules/semver": { "version": "7.7.4", "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.4.tgz", @@ -5048,6 +4793,37 @@ "node": ">=10" } }, + "node_modules/app-builder-lib/node_modules/serialize-error": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/serialize-error/-/serialize-error-7.0.1.tgz", + "integrity": "sha512-8I8TjW5KMOKsZQTvoxjuSIa7foAwPWGOts+6o7sgjz41/qMD9VQHEDxi6PBvK2l0MXUmqZyNpUK+T2tQaaElvw==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "type-fest": "^0.13.1" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/app-builder-lib/node_modules/type-fest": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.13.1.tgz", + "integrity": "sha512-34R7HTnG0XIJcBSn5XhDd7nNFPRcXYRZrBB2O2jdKqYODldSzBAqzsWoZYYvduky73toYS/ESqxPvkDf/F0XMg==", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "optional": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/app-builder-lib/node_modules/universalify": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", @@ -5074,6 +4850,13 @@ "node": "^18.17.0 || >=20.5.0" } }, + "node_modules/app-builder-lib/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true, + "license": "ISC" + }, "node_modules/argparse": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", @@ -5118,14 +4901,14 @@ } }, "node_modules/asn1js": { - "version": "3.0.10", - "resolved": "https://registry.npmjs.org/asn1js/-/asn1js-3.0.10.tgz", - "integrity": "sha512-S2s3aOytiKdFRdulw2qPE51MzjzVOisppcVv7jVFR+Kw0kxwvFrDcYA0h7Ndqbmj0HkMIXYWaoj7fli8kgx1eg==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/asn1js/-/asn1js-3.1.0.tgz", + "integrity": "sha512-HWYi1THkOqguCiO+vwj09ZkQFD2kKEsejYHAYCtX0D80WVdoDnvRc9IukXX/jeb0T9NRWJnRtqwdbHltnFjwXA==", "dev": true, "license": "BSD-3-Clause", "dependencies": { "pvtsutils": "^1.3.6", - "pvutils": "^1.1.5", + "pvutils": "^1.2.0", "tslib": "^2.8.1" }, "engines": { @@ -5208,9 +4991,9 @@ "license": "MIT" }, "node_modules/b4a": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/b4a/-/b4a-1.8.1.tgz", - "integrity": "sha512-aiqre1Nr0B/6DgE2N5vwTc+2/oQZ4Wh1t4NznYY4E00y8LCt6NqdRv81so00oo27D8MVKTpUa/MwUUtBLXCoDw==", + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/b4a/-/b4a-1.9.0.tgz", + "integrity": "sha512-dpfcF9fDNR6++cthXR67iyhgqWy9CBouAvIWhIntzBG6cvK/cnIPiZQjBwi/ZqjjBEDGfoNDtmB0kTjroOJ3pQ==", "license": "Apache-2.0", "peerDependencies": { "react-native-b4a": "*" @@ -5240,10 +5023,19 @@ "node": "18 || 20 || >=22" } }, + "node_modules/bare-buffer": { + "version": "3.7.3", + "resolved": "https://registry.npmjs.org/bare-buffer/-/bare-buffer-3.7.3.tgz", + "integrity": "sha512-77owW16RX6YgdOzddHtM0oGz8wsd0/F9k/0coz6TPmjUHnr/9FwWODVMNKwyYWM/a/ESdTum855nfQxnsKUygA==", + "license": "Apache-2.0", + "engines": { + "bare": ">=1.20.0" + } + }, "node_modules/bare-events": { - "version": "2.9.1", - "resolved": "https://registry.npmjs.org/bare-events/-/bare-events-2.9.1.tgz", - "integrity": "sha512-Z0oHEHAFDZkffN8Qc39zNZjQlMDkPJRyyyZieU1VH7u8c5S+qHZ2S8ixdKIAxEjfHO7FJxXmJWgteOghVanIsg==", + "version": "2.9.2", + "resolved": "https://registry.npmjs.org/bare-events/-/bare-events-2.9.2.tgz", + "integrity": "sha512-AIPKioV7/Y/8KfZ3AAhjPJxLLbY49S64Ym5DakZlUg75qQiTgUq9hEJoEwa4eUezPUlXRy/i5NpsKvo9jgKmoA==", "license": "Apache-2.0", "peerDependencies": { "bare-abort-controller": "*" @@ -5255,9 +5047,9 @@ } }, "node_modules/bare-fs": { - "version": "4.8.0", - "resolved": "https://registry.npmjs.org/bare-fs/-/bare-fs-4.8.0.tgz", - "integrity": "sha512-fM+MhCvdQhZ7NV6S95a07gPSqjIYKn6mFaXfx266wN3ajZGl/+1AzH+ubkXQ0fFZvOe2nk9VHkzdYkQE5zMV3Q==", + "version": "4.8.5", + "resolved": "https://registry.npmjs.org/bare-fs/-/bare-fs-4.8.5.tgz", + "integrity": "sha512-5gborbd4IEFpnyqAiwD0tl6sH9fvPvIaK2hdM8DXU+xAMxSB7B3D3D04CD21k4T5C6u5Oxw3iajkBQhNLxINKg==", "license": "Apache-2.0", "dependencies": { "bare-events": "^2.5.4", @@ -5279,15 +5071,15 @@ } }, "node_modules/bare-path": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/bare-path/-/bare-path-3.1.1.tgz", - "integrity": "sha512-JprUlveX3QjApC1cTpsUOiscADftCGVWkzitbHsRqv84hzYwYHw2mbluddsq5TvI8mH/8Ov1f4BiMAdcB0oYnQ==", + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/bare-path/-/bare-path-3.1.3.tgz", + "integrity": "sha512-8r+FVU/o4zcFmpCDqbqAYhHHbtXPP+cyZKo7DRGRWc7OLlNs4TMaSQEpXL/sIdzyEG0M7RHw4B7xYMGrTc+qrg==", "license": "Apache-2.0" }, "node_modules/bare-stream": { - "version": "2.13.3", - "resolved": "https://registry.npmjs.org/bare-stream/-/bare-stream-2.13.3.tgz", - "integrity": "sha512-Kc+brLqvEqGkjyfiwJmImAOqLZL7OsoLKuavx+hJjgVV3nLTOjloJyPMFxjUPerGGHrNH0fLU06jjykMLWrERQ==", + "version": "2.13.4", + "resolved": "https://registry.npmjs.org/bare-stream/-/bare-stream-2.13.4.tgz", + "integrity": "sha512-PcrQ8lVLbiJscNm1Kez+Yp4Gy4AHGcN1lzwjvf5NybWen7VvEgUfyfnXYJ2zNqWnzOfCb1Abq6lH8ti0syQszA==", "license": "Apache-2.0", "dependencies": { "b4a": "^1.8.1", @@ -5312,11 +5104,12 @@ } }, "node_modules/bare-url": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/bare-url/-/bare-url-2.5.2.tgz", - "integrity": "sha512-L13PCJzKG8RGvx8V1/DdMi12ERhC3tprr7/8a94BxpmnRsFqxh5XZNdhtMxu5HPkRshYOOWRGY8lDP7ZhpG9Cg==", + "version": "2.5.8", + "resolved": "https://registry.npmjs.org/bare-url/-/bare-url-2.5.8.tgz", + "integrity": "sha512-G5KTe5Bj6z5pqIxcn3lWlIFIv0rkXbccx0T0Xuf7t4RapfSWvFlcVbrwYXxFZ00PC4lp57OCIk6uXP/r3GbpDw==", "license": "Apache-2.0", "dependencies": { + "bare-buffer": "^3.0.0", "bare-path": "^3.0.0" } }, @@ -5341,9 +5134,9 @@ "license": "MIT" }, "node_modules/baseline-browser-mapping": { - "version": "2.10.38", - "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.10.38.tgz", - "integrity": "sha512-31/02mVB4yuQU6adKk5SlY6m+mxDwUq5KZkyYgnLrrKl7TEm1+3PyDtDBz2kOv/wxZz41GHsvV1A/u6RmiyBvw==", + "version": "2.11.39", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.11.39.tgz", + "integrity": "sha512-Q9buOYhr2ggrEZpImICecZTJHCCd8yXkRUokFlUEQ8uiD6oP82F4W4jWnhOHZYV+wlvrC51V7Wy0ULyWjil5Wg==", "dev": true, "license": "Apache-2.0", "bin": { @@ -5369,6 +5162,43 @@ "dev": true, "license": "MIT" }, + "node_modules/body-parser": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-2.4.0.tgz", + "integrity": "sha512-Ifk1KcLrxaGt1occQagQNFNNOqRt1LFuehEnHHzB8Z6cRgIxRU1TBaiIsUiCdA+gy5PL7Y1IX31DNKkRmxtXjQ==", + "license": "MIT", + "dependencies": { + "bytes": "^3.1.2", + "content-type": "^2.1.0", + "debug": "^4.4.3", + "http-errors": "^2.0.1", + "iconv-lite": "^0.7.3", + "on-finished": "^2.4.1", + "qs": "^6.16.1", + "raw-body": "^3.0.2", + "type-is": "^2.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/body-parser/node_modules/content-type": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-2.1.0.tgz", + "integrity": "sha512-mj7UPXE0jaqaOsukNZRUEfEi2AcL7C/vwmwcHV0O97eO1E1pxBZuyjlZrx5seTaNBg1U6+o35wpa35Qfcc+7ag==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, "node_modules/boolbase": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", @@ -5385,9 +5215,9 @@ "optional": true }, "node_modules/bowser": { - "version": "2.14.1", - "resolved": "https://registry.npmjs.org/bowser/-/bowser-2.14.1.tgz", - "integrity": "sha512-tzPjzCxygAKWFOJP011oxFHs57HzIhOEracIgAePE4pqB3LikALKnSzUyU4MGs9/iCEUuHlAJTjTc5M+u7YEGg==", + "version": "2.15.0", + "resolved": "https://registry.npmjs.org/bowser/-/bowser-2.15.0.tgz", + "integrity": "sha512-xic6KSZglg/I4ymp45fdM4GWfYpBK79Fxd/TOvJktlaPgQqqDxvmGwOPZl2V0dyeS3Lj5c180bLhXF43iyAjZQ==", "license": "MIT" }, "node_modules/brace-expansion": { @@ -5402,23 +5232,10 @@ "node": "20 || >=22" } }, - "node_modules/braces": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", - "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", - "dev": true, - "license": "MIT", - "dependencies": { - "fill-range": "^7.1.1" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/browserslist": { - "version": "4.28.2", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.2.tgz", - "integrity": "sha512-48xSriZYYg+8qXna9kwqjIVzuQxi+KYWp2+5nCYnYKPTr0LvD89Jqk2Or5ogxz0NUMfIjhh2lIUX/LyX9B4oIg==", + "version": "4.29.6", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.29.6.tgz", + "integrity": "sha512-CmVVIQ3RVc5HxYEc9X84GvxK/C8C1wH8TlKAiO7uTxF8PDwt7r8t9Qk3J9NkMOVzX5O/HbLv3yzxZg9HPrnI9w==", "dev": true, "funding": [ { @@ -5436,11 +5253,11 @@ ], "license": "MIT", "dependencies": { - "baseline-browser-mapping": "^2.10.12", - "caniuse-lite": "^1.0.30001782", - "electron-to-chromium": "^1.5.328", - "node-releases": "^2.0.36", - "update-browserslist-db": "^1.2.3" + "baseline-browser-mapping": "^2.11.37", + "caniuse-lite": "^1.0.30001826", + "electron-to-chromium": "^1.5.486", + "node-releases": "^2.0.64", + "update-browserslist-db": "^1.4.0" }, "bin": { "browserslist": "cli.js" @@ -5472,14 +5289,14 @@ "license": "MIT" }, "node_modules/builder-util": { - "version": "26.15.3", - "resolved": "https://registry.npmjs.org/builder-util/-/builder-util-26.15.3.tgz", - "integrity": "sha512-q2hn7Mbo2nFNkVekPiHFx6Nfo3hURmES3tfBn+k5Pqxl2RkmP3QGqZUhH/q9Pch/4G05NRhPjDlVj1O8q4Txvw==", + "version": "26.18.1", + "resolved": "https://registry.npmjs.org/builder-util/-/builder-util-26.18.1.tgz", + "integrity": "sha512-t+1Xnzj8jQ2FnJWtQOKVCuzv3QGjvNhE6er757omlKFysQexdrCVI9eM/uu4+39IiMCtM2l/30O1Yrqqbt4HQw==", "dev": true, "license": "MIT", "dependencies": { "@types/debug": "^4.1.6", - "builder-util-runtime": "9.7.0", + "builder-util-runtime": "9.7.1", "chalk": "^4.1.2", "cross-spawn": "^7.0.6", "debug": "^4.3.4", @@ -5498,9 +5315,9 @@ } }, "node_modules/builder-util-runtime": { - "version": "9.7.0", - "resolved": "https://registry.npmjs.org/builder-util-runtime/-/builder-util-runtime-9.7.0.tgz", - "integrity": "sha512-g/kR520giAFYkSXTzcmF3kqQq7wi8F6N6SzeDgZrqTBN+VHdmgWOyTdD1yD7AATDId/yXLvuP34CxW46/BwCdw==", + "version": "9.7.1", + "resolved": "https://registry.npmjs.org/builder-util-runtime/-/builder-util-runtime-9.7.1.tgz", + "integrity": "sha512-LLAn0Ddqz0YIyysCysBkg18qEdAzMASiADSZl5G8gpxsqu1RJrdFAqoAW9suwg0GHKMqrycISFSD/9RqSm5d6g==", "license": "MIT", "dependencies": { "debug": "^4.3.4", @@ -5510,6 +5327,70 @@ "node": ">=12.0.0" } }, + "node_modules/builder-util/node_modules/agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 14" + } + }, + "node_modules/builder-util/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/builder-util/node_modules/http-proxy-agent": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", + "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.0", + "debug": "^4.3.4" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/builder-util/node_modules/https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.2", + "debug": "4" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/bytes": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", + "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, "node_modules/bytestreamjs": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/bytestreamjs/-/bytestreamjs-2.0.1.tgz", @@ -5521,13 +5402,27 @@ } }, "node_modules/cac": { - "version": "6.7.14", - "resolved": "https://registry.npmjs.org/cac/-/cac-6.7.14.tgz", - "integrity": "sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==", + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/cac/-/cac-7.1.0.tgz", + "integrity": "sha512-LMDU/U2yA4IPIY8KT0NsNPWEYZvAMkbgyspxJ6btJaYV+WMDOHAZCmB0lsTObiHaRS1V/ztKAl7+TSkTqXyeoA==", "dev": true, "license": "MIT", "engines": { - "node": ">=8" + "node": ">=20.19.0" + } + }, + "node_modules/cacheable": { + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-2.5.0.tgz", + "integrity": "sha512-60cyAOytib/OzBw1JNSoSV/boK1AtHryDIjvVBk7XbN4ugfkM3+Sry7fEjNgPMGgOjuaZPAp8ruZ0Cxafwyq9g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@cacheable/memory": "^2.2.0", + "@cacheable/utils": "^2.5.0", + "hookified": "^1.15.0", + "keyv": "^5.6.0", + "qified": "^0.10.1" } }, "node_modules/cacheable-lookup": { @@ -5559,6 +5454,16 @@ "node": ">=8" } }, + "node_modules/cacheable/node_modules/keyv": { + "version": "5.6.0", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.6.0.tgz", + "integrity": "sha512-CYDD3SOtsHtyXeEORYRx2qBtpDJFjRTGXUtmNEMGyzYOKj1TE3tycdlho7kA1Ufx9OYWZzg52QFBGALTirzDSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@keyv/serialize": "^1.1.1" + } + }, "node_modules/call-bind": { "version": "1.0.9", "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.9.tgz", @@ -5606,20 +5511,10 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/callsites": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", - "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, "node_modules/caniuse-lite": { - "version": "1.0.30001799", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001799.tgz", - "integrity": "sha512-hG1bReV+OUU+MOqK4t/ZWI0tZOyz3rqS9XuhOUz1cIcbwBKjOyJEJuw9ER5JuNyqxNk8u/JUVbGibBOL1yrjFw==", + "version": "1.0.30001826", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001826.tgz", + "integrity": "sha512-wTB+9tIbLro/BCXwLuNV1meHE4L9dS6dArMDwgYfNBPMYScqClHyGunhkCSDtHhe/69Xl0sHlKgBVZ+fNsYtWA==", "dev": true, "funding": [ { @@ -5648,9 +5543,9 @@ } }, "node_modules/chai": { - "version": "6.2.2", - "resolved": "https://registry.npmjs.org/chai/-/chai-6.2.2.tgz", - "integrity": "sha512-NUPRluOfOiTKBKvWPtSD4PhFvWCqOi0BGStNWs57X9js7XGTprSmFoz5F0tWhR4WPjNeR9jXqdC7/UpSJTnlRg==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/chai/-/chai-6.3.0.tgz", + "integrity": "sha512-XWAtwJ6OHO+tj0EKCs0Y2UamnyOxseZWltU4x2U2wh8g4AigdjwvtUjvLP2tqkA/avxHEtzxNaqGq/YGNwckKg==", "dev": true, "license": "MIT", "engines": { @@ -5658,17 +5553,12 @@ } }, "node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-6.0.0.tgz", + "integrity": "sha512-2uNTXIuTTxk7ciZgAU1BQcgnchcG0xXnrs6jzkQfj9SsRa9M2s5zE8WT96hS6KmG4MzWHSrvH43DF1m4XRkrFg==", "license": "MIT", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, "engines": { - "node": ">=10" + "node": ">=22" }, "funding": { "url": "https://github.com/chalk/chalk?sponsor=1" @@ -5732,9 +5622,9 @@ "license": "MIT" }, "node_modules/ci-info": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.4.0.tgz", - "integrity": "sha512-77PSwercCZU2Fc4sX94eF8k8Pxte6JAwL4/ICZLFjJLqegs7kCuAsqqj/70NQF6TvDpgFjkubQB2FW2ZZddvQg==", + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.5.0.tgz", + "integrity": "sha512-d1uM8k5UZEyPza1n/MG3ko8nKupKN0KJpFsipgPcgaCCvV+IqIfJ+NzTjetlLM+UcXZx3+cLrNr76+eAO7G1Mw==", "dev": true, "funding": [ { @@ -5809,13 +5699,12 @@ } }, "node_modules/commander": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-5.1.0.tgz", - "integrity": "sha512-P0CysNDQ7rtVw4QIQtm+MRxV66vKFSvlsQvGYXZWR3qFU0jlMKHZZZgw8e+8DSah4UDKMqnknRDQz+xuQXQ/Zg==", - "dev": true, + "version": "15.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-15.1.0.tgz", + "integrity": "sha512-cgnQ88TRrWcC7pVq46RzJVRMktu3W2RcbnoidnfBsl1bmDCBwJS/udcIZpKoCrbAYYaCqsz1yZCVIgbIaU3ddQ==", "license": "MIT", "engines": { - "node": ">= 6" + "node": ">=22.12.0" } }, "node_modules/compare-version": { @@ -5835,19 +5724,76 @@ "dev": true, "license": "MIT" }, - "node_modules/convert-source-map": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", - "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", - "dev": true, - "license": "MIT" - }, - "node_modules/core-util-is": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", - "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", - "dev": true, - "license": "MIT" + "node_modules/content-disposition": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-2.0.1.tgz", + "integrity": "sha512-e+H0ZXHSWYrENhQzw1LPuP4oF5MzVKmDU6d3hxlvaPEYLLg62MxtQNPRx4SYSuYJSBUgnQIG4HIN2tEtNv7Dog==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/content-type": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.5.tgz", + "integrity": "sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "dev": true, + "license": "MIT" + }, + "node_modules/cookie": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.2.tgz", + "integrity": "sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/cookie-signature": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.2.2.tgz", + "integrity": "sha512-D76uU73ulSXrD1UXF4KE2TMxVVwhsnCgfAyTg9k8P6KGZjlXKrOLe4dJQKI3Bxi5wjesZoFXJWElNWBjPZMbhg==", + "license": "MIT", + "engines": { + "node": ">=6.6.0" + } + }, + "node_modules/core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", + "devOptional": true, + "license": "MIT" + }, + "node_modules/cors": { + "version": "2.8.6", + "resolved": "https://registry.npmjs.org/cors/-/cors-2.8.6.tgz", + "integrity": "sha512-tJtZBBHA6vjIAaF6EnIaq6laBBP9aq/Y3ouVJjEfoHbRBcHBAHYcMh/w8LDrk2PvIMMq8gmopa5D4V8RmbrxGw==", + "license": "MIT", + "dependencies": { + "object-assign": "^4", + "vary": "^1" + }, + "engines": { + "node": ">= 0.10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } }, "node_modules/cross-dirname": { "version": "0.1.0", @@ -5906,10 +5852,20 @@ "integrity": "sha512-iKuQcq+NdHqlAcwUY0o/HL69XQrUaQdMjmStJ8JFmUaiiQErlhrmuigkg/CU4E2J0IyUKUrMAgl36TvN67MqTw==", "license": "MIT" }, + "node_modules/cssomnom": { + "version": "0.1.12", + "resolved": "https://registry.npmjs.org/cssomnom/-/cssomnom-0.1.12.tgz", + "integrity": "sha512-nlsLjRxRN2RPomw3r+e+oD3KQBbEbKK0+oBUATbodf5N38FlOMg/5nqV0CdClNvpVsjFLikD63H6dgKTgeuuUg==", + "license": "Apache-2.0", + "optional": true, + "engines": { + "node": ">=20.0.0" + } + }, "node_modules/csstype": { - "version": "3.2.3", - "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.2.3.tgz", - "integrity": "sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==", + "version": "3.2.4", + "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.2.4.tgz", + "integrity": "sha512-PoKaoPzQapnEoqUSnHx1u6W6ku8CVEgKsnpmmzU3m1nwkidpPBQ8V/Zq2+bWNrsOKoKLwTGdbx6xF7BXP1zLVQ==", "dev": true, "license": "MIT" }, @@ -6083,6 +6039,274 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/defuddle": { + "version": "0.19.3", + "resolved": "https://registry.npmjs.org/defuddle/-/defuddle-0.19.3.tgz", + "integrity": "sha512-5ZbOQ/B+iiRRqSQWwmCx/zEuqZOA/5q7gxyE2/4O2Bxq7nUC0PgKw9EdyxqWbFF1nrrrYemSeR25jg4TmA2fsA==", + "license": "MIT", + "dependencies": { + "commander": "^12.1.0" + }, + "bin": { + "defuddle": "dist/cli.js" + }, + "optionalDependencies": { + "linkedom": "^0.18.12", + "mathml-to-latex": "^1.8.0", + "temml": "^0.13.3", + "turndown": "^7.2.0" + } + }, + "node_modules/defuddle/node_modules/boolbase": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-2.0.0.tgz", + "integrity": "sha512-DkVaaQHymRhpYEYo9x1oo7Q7B0Y6KJUsjm3c9eTyFDby4MHLBTwZ6ZDWBel5zrYxj1WsZgC5oLpiz+93MluXeA==", + "license": "ISC", + "optional": true, + "engines": { + "node": ">=20.19.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/defuddle/node_modules/commander": { + "version": "12.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-12.1.0.tgz", + "integrity": "sha512-Vw8qHK3bZM9y/P10u3Vib8o/DdkvA2OtPtZvD871QKjy74Wj1WSKFILMPRPSdUSx5RFK1arlJzEtA4PkFgnbuA==", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/defuddle/node_modules/css-select": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-7.0.0.tgz", + "integrity": "sha512-snmjEVXy+1LnwXdxhYvTMj1d9tOh4HxkA1YmoayVBeeyR2C14Pum7fcxJIm4SswYspVy866eYNwlH6xC3/VH5g==", + "license": "BSD-2-Clause", + "optional": true, + "dependencies": { + "boolbase": "^2.0.0", + "css-what": "^8.0.0", + "domhandler": "^6.0.1", + "domutils": "^4.0.2", + "nth-check": "^3.0.1" + }, + "engines": { + "node": ">=20.19.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/defuddle/node_modules/css-select/node_modules/domelementtype": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-3.0.0.tgz", + "integrity": "sha512-umCQid3jKbDmVjx8jGaW7uUykm4DEUeyV21hPxNMo2nV955DhUThwqyOIDtreepP31hl84X7G5U9ZfsWvIB3Pg==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "license": "BSD-2-Clause", + "optional": true, + "engines": { + "node": ">=20.19.0" + } + }, + "node_modules/defuddle/node_modules/css-select/node_modules/domhandler": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-6.0.1.tgz", + "integrity": "sha512-gYzvtM72ZtxQO0T048kd6HWSbbGCNOUwcnfQ01cqIJ4X2IYKFFHZ5mKvrQETcFXxsRObZulDaKmy//R7TPtsBg==", + "license": "BSD-2-Clause", + "optional": true, + "dependencies": { + "domelementtype": "^3.0.0" + }, + "engines": { + "node": ">=20.19.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/defuddle/node_modules/css-select/node_modules/domutils": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-4.0.2.tgz", + "integrity": "sha512-qI4JLRKnSzqFqr7hAlS5xQDusBCjKSEG4t4+7aNrIQMHBcsC2TGEhuyABJdYkgSewL57PNLYEiibY2iPKhKpaA==", + "license": "BSD-2-Clause", + "optional": true, + "dependencies": { + "dom-serializer": "^3.0.0", + "domelementtype": "^3.0.0", + "domhandler": "^6.0.0" + }, + "engines": { + "node": ">=20.19.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/fb55/domutils?sponsor=1" + } + }, + "node_modules/defuddle/node_modules/css-what": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-8.0.0.tgz", + "integrity": "sha512-DH0Bqq3DNp5tdOReuNyAA+Ev4Y2GS5FMbZpeTLP6C4CDi0h5nL0BmUPChXw3o/qbHLDWHl49sbNqQVY7bMSDdw==", + "license": "BSD-2-Clause", + "optional": true, + "engines": { + "node": ">=20.19.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/defuddle/node_modules/dom-serializer": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-3.1.1.tgz", + "integrity": "sha512-4MEa38/QexBob6gFNwu+EGdWvhJ1OKuNwdYY3Y3NyeWDQfnGeDYQUDfIRzWu5B5gsv03so2Uxd28YC6zrsx3Lw==", + "license": "MIT", + "optional": true, + "dependencies": { + "domelementtype": "^3.0.0", + "domhandler": "^6.0.0", + "entities": "^8.0.0" + }, + "engines": { + "node": ">=20.19.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + } + }, + "node_modules/defuddle/node_modules/dom-serializer/node_modules/domelementtype": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-3.0.0.tgz", + "integrity": "sha512-umCQid3jKbDmVjx8jGaW7uUykm4DEUeyV21hPxNMo2nV955DhUThwqyOIDtreepP31hl84X7G5U9ZfsWvIB3Pg==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "license": "BSD-2-Clause", + "optional": true, + "engines": { + "node": ">=20.19.0" + } + }, + "node_modules/defuddle/node_modules/dom-serializer/node_modules/domhandler": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-6.0.1.tgz", + "integrity": "sha512-gYzvtM72ZtxQO0T048kd6HWSbbGCNOUwcnfQ01cqIJ4X2IYKFFHZ5mKvrQETcFXxsRObZulDaKmy//R7TPtsBg==", + "license": "BSD-2-Clause", + "optional": true, + "dependencies": { + "domelementtype": "^3.0.0" + }, + "engines": { + "node": ">=20.19.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/defuddle/node_modules/dom-serializer/node_modules/entities": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-8.1.0.tgz", + "integrity": "sha512-kxL7msIffSuh9aaFAMD7rxAIuTRMAHMeBtgHW2yUdWw732ZNh4MehkF2gdjvtdmikkaIP9bFDDJOPlsvm7avrA==", + "license": "BSD-2-Clause", + "optional": true, + "engines": { + "node": ">=20.19.0" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/defuddle/node_modules/entities": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-7.0.1.tgz", + "integrity": "sha512-TWrgLOFUQTH994YUyl1yT4uyavY5nNB5muff+RtWaqNVCAK408b5ZnnbNAUEWLTCpum9w6arT70i1XdQ4UeOPA==", + "license": "BSD-2-Clause", + "optional": true, + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/defuddle/node_modules/htmlparser2": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-10.1.0.tgz", + "integrity": "sha512-VTZkM9GWRAtEpveh7MSF6SjjrpNVNNVJfFup7xTY3UpFtm67foy9HDVXneLtFVt4pMz5kZtgNcvCniNFb1hlEQ==", + "funding": [ + "https://github.com/fb55/htmlparser2?sponsor=1", + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "license": "MIT", + "optional": true, + "dependencies": { + "domelementtype": "^2.3.0", + "domhandler": "^5.0.3", + "domutils": "^3.2.2", + "entities": "^7.0.1" + } + }, + "node_modules/defuddle/node_modules/linkedom": { + "version": "0.18.15", + "resolved": "https://registry.npmjs.org/linkedom/-/linkedom-0.18.15.tgz", + "integrity": "sha512-o0w7eD/SvoCao+pUi6dzocCLuMR11g4Tv/et0W2OUzwWmUcewntSzyl+Ua/K+0yKym0Y/Mav3nFAaI5Av5jvZg==", + "license": "ISC", + "optional": true, + "dependencies": { + "css-select": "^7.0.0", + "cssomnom": "^0.1.11", + "html-escaper": "^3.0.3", + "htmlparser2": "^10.1.0", + "uhyphen": "^0.2.0" + }, + "engines": { + "node": ">=16" + }, + "peerDependencies": { + "canvas": ">= 2" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } + } + }, + "node_modules/defuddle/node_modules/nth-check": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-3.0.1.tgz", + "integrity": "sha512-GX0gsdbGVCgnRgbeGaubfjpBXyYRWOOCVeYh08bSQvDZqxz5ndXs1OTfAt/h36G1xvI94YIspsI0sVFqAV9+RQ==", + "license": "BSD-2-Clause", + "optional": true, + "dependencies": { + "boolbase": "^2.0.0" + }, + "engines": { + "node": ">=20.19.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/fb55/nth-check?sponsor=1" + } + }, "node_modules/delayed-stream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", @@ -6093,6 +6317,15 @@ "node": ">=0.4.0" } }, + "node_modules/depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, "node_modules/dequal": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/dequal/-/dequal-2.0.3.tgz", @@ -6160,9 +6393,9 @@ "license": "MIT" }, "node_modules/dir-compare/node_modules/brace-expansion": { - "version": "1.1.16", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.16.tgz", - "integrity": "sha512-IDw48K2/2kRkg9LdJxurvq3lV3aBgq0REY89duEqFRthjlPdXHKMj7EnQOXVckxzgisinf3nHfrcE2FufFLXMw==", + "version": "1.1.22", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.22.tgz", + "integrity": "sha512-CKLDTuSsN0+r1ThM0WkzzBI7dnPI6xEGfa/JnVYIK9JNBA1N1NyPwXVHor//NKD/y3sDxp764sZdLhFK7pH8XQ==", "dev": true, "license": "MIT", "dependencies": { @@ -6184,14 +6417,14 @@ } }, "node_modules/dmg-builder": { - "version": "26.15.3", - "resolved": "https://registry.npmjs.org/dmg-builder/-/dmg-builder-26.15.3.tgz", - "integrity": "sha512-O3zJUFUYHJKgzPqioHxfxzBzlSC1eXCSr79gMSBKBP5AgjjpmrydMsMLotEg9fAJF36vdUncb+4ndRNxoPdlSQ==", + "version": "26.18.1", + "resolved": "https://registry.npmjs.org/dmg-builder/-/dmg-builder-26.18.1.tgz", + "integrity": "sha512-ihBAAhXUQiO+fIQGirYSLuKfgGa81zIrIzgSSkbm1fPcE0cXqnxNLtUQgxYHpezxWOaeXxmh9AuPemONZuMKbg==", "dev": true, "license": "MIT", "dependencies": { - "app-builder-lib": "26.15.3", - "builder-util": "26.15.3", + "app-builder-lib": "26.18.1", + "builder-util": "26.18.1", "fs-extra": "^10.1.0", "js-yaml": "^4.1.0" } @@ -6238,9 +6471,9 @@ } }, "node_modules/dompurify": { - "version": "3.4.16", - "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-3.4.16.tgz", - "integrity": "sha512-sqo+pNp3qRhCIpbgRi1y8Tgk27Bo2Ry7w0dC1NBeNTdZChWjz9Xb/KOoZbRP/R6pQZ80Qw8YhXw13hWWBbMRnQ==", + "version": "3.4.18", + "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-3.4.18.tgz", + "integrity": "sha512-ofe3wI/uNm68HInABYFJYqQxRw1EaKAjNdrFVKqjUY+UZurvNd2L/HuQe097s/4RivWiZyP6tT7aoT8atjfhwg==", "dev": true, "license": "(MPL-2.0 OR Apache-2.0)", "optionalDependencies": { @@ -6323,6 +6556,12 @@ "safe-buffer": "^5.0.1" } }, + "node_modules/ee-first": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", + "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==", + "license": "MIT" + }, "node_modules/ejs": { "version": "3.1.10", "resolved": "https://registry.npmjs.org/ejs/-/ejs-3.1.10.tgz", @@ -6340,9 +6579,9 @@ } }, "node_modules/electron": { - "version": "42.4.1", - "resolved": "https://registry.npmjs.org/electron/-/electron-42.4.1.tgz", - "integrity": "sha512-8CYHJP5O4wFO+ycoJR98yy907MmPeo+vWXrzjxmGGgRNKqv8pOjjm+wphO0CCgQJnBU7+QUPSJS4QXhbKrO50w==", + "version": "45.4.1", + "resolved": "https://registry.npmjs.org/electron/-/electron-45.4.1.tgz", + "integrity": "sha512-DjsJ/eQhovkjf1vYFFyh5GB8NMx+L5bdYaonvGOlWselg3DQ0fwIF0N/+2hrPsoS4whmmNswh21ym/8dgt1y5Q==", "dev": true, "license": "MIT", "dependencies": { @@ -6359,18 +6598,18 @@ } }, "node_modules/electron-builder": { - "version": "26.15.3", - "resolved": "https://registry.npmjs.org/electron-builder/-/electron-builder-26.15.3.tgz", - "integrity": "sha512-a1KM5heqS3gQCZzizXEI8RjJy3QVogULPdeSknt76uLDpBIW/HDGsMg/XgP0riP6PI9COsRvFITKKGDqA8fJxA==", + "version": "26.18.1", + "resolved": "https://registry.npmjs.org/electron-builder/-/electron-builder-26.18.1.tgz", + "integrity": "sha512-uA3To9X/D4ozwP8k/o/MCfKi/xETyPV0FkhTaqdgIT679uexsQ8QFE+PhF8x6PY8W1jIJrw9/yadTuOWTpmAew==", "dev": true, "license": "MIT", "dependencies": { - "app-builder-lib": "26.15.3", - "builder-util": "26.15.3", - "builder-util-runtime": "9.7.0", + "app-builder-lib": "26.18.1", + "builder-util": "26.18.1", + "builder-util-runtime": "9.7.1", "chalk": "^4.1.2", "ci-info": "^4.2.0", - "dmg-builder": "26.15.3", + "dmg-builder": "26.18.1", "fs-extra": "^10.1.0", "lazy-val": "^1.0.5", "simple-update-notifier": "2.0.0", @@ -6385,50 +6624,84 @@ } }, "node_modules/electron-builder-squirrel-windows": { - "version": "26.15.3", - "resolved": "https://registry.npmjs.org/electron-builder-squirrel-windows/-/electron-builder-squirrel-windows-26.15.3.tgz", - "integrity": "sha512-Jc19XPV9y9+2bAdZPkXuVNGNIEFBq9poHC61l8Kv6FdK7DRG3+Ic0rerC0DXOaeHNz8yW0fg/JnF8GQROOF5MA==", + "version": "26.18.1", + "resolved": "https://registry.npmjs.org/electron-builder-squirrel-windows/-/electron-builder-squirrel-windows-26.18.1.tgz", + "integrity": "sha512-EZmCBoO1nJbtzTPTPcbQEqo1IGiu2iGID/qeFTQZsJ1ETPPdXHZSxvu9ie0+XhjjQWbK4JxzYyUtRB/qw+lSVQ==", "dev": true, "license": "MIT", "peer": true, "dependencies": { - "app-builder-lib": "26.15.3", - "builder-util": "26.15.3", + "app-builder-lib": "26.18.1", + "builder-util": "26.18.1", "electron-winstaller": "5.4.0" } }, - "node_modules/electron-publish": { - "version": "26.15.3", - "resolved": "https://registry.npmjs.org/electron-publish/-/electron-publish-26.15.3.tgz", - "integrity": "sha512-g/2bn8YTavY4cuS5F+jOS7zmZbXXBV8KZ8yHKfJjFPoKtzBqrpCdNPxBd3tqdBwP7BVd0lGzf7Bk2s0KesWZ4Q==", + "node_modules/electron-builder/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "license": "MIT", "dependencies": { - "@types/fs-extra": "^9.0.11", - "aws4": "^1.13.2", - "builder-util": "26.15.3", - "builder-util-runtime": "9.7.0", - "chalk": "^4.1.2", - "form-data": "^4.0.5", - "fs-extra": "^10.1.0", - "lazy-val": "^1.0.5", - "mime": "^2.5.2" - } - }, - "node_modules/electron-to-chromium": { - "version": "1.5.375", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.375.tgz", - "integrity": "sha512-ZWP5eB4BVPW/ZYo9252hQZHZ5XavtsTgpbhcmMmRwymavC5AsLWQWBPaKMeNd2LW0KGby5HPXvj7+sr4ta5j/Q==", - "dev": true, + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/electron-publish": { + "version": "26.18.1", + "resolved": "https://registry.npmjs.org/electron-publish/-/electron-publish-26.18.1.tgz", + "integrity": "sha512-VlAkMx9kgPP/TGn5q5sgCSYwKtMUXBGhXT2XwFi3p3lMJZDgCIWErikWBaI6tJg8PbMeXZ6vK1eR2+DzcZsb5w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/fs-extra": "^9.0.11", + "aws4": "^1.13.2", + "builder-util": "26.18.1", + "builder-util-runtime": "9.7.1", + "chalk": "^4.1.2", + "form-data": "^4.0.5", + "fs-extra": "^10.1.0", + "lazy-val": "^1.0.5", + "mime": "^2.5.2" + } + }, + "node_modules/electron-publish/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/electron-to-chromium": { + "version": "1.5.492", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.492.tgz", + "integrity": "sha512-4uMs7omhajKiud0GqALLTazS/zyvHLTLmDWVTR+e6BnyJo5bSNrph/JoRWEFJJmY75ct9hCiSGsbFF9fLe5gDw==", + "dev": true, "license": "ISC" }, "node_modules/electron-updater": { - "version": "6.8.9", - "resolved": "https://registry.npmjs.org/electron-updater/-/electron-updater-6.8.9.tgz", - "integrity": "sha512-ZhVxM9iGONUpZGI1FxdMRgJjUFXi7AYGVa5PwKlO1tV1/4zDxQmfKpXOHVztKrd6L9rLcFjERvi1Mf2vxyTkig==", + "version": "6.8.12", + "resolved": "https://registry.npmjs.org/electron-updater/-/electron-updater-6.8.12.tgz", + "integrity": "sha512-AK17iWH8zXu5Qqw2f2P0v+Fx4tAF9dWWOYAe2jgURpNz6i2LQc9ZX3hBq4K7iP9qjNnaDzRHKn8455+MEwlrbw==", "license": "MIT", "dependencies": { - "builder-util-runtime": "9.7.0", + "builder-util-runtime": "9.7.1", "fs-extra": "^10.1.0", "js-yaml": "^4.1.0", "lazy-val": "^1.0.5", @@ -6451,18 +6724,18 @@ } }, "node_modules/electron-vite": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/electron-vite/-/electron-vite-4.0.1.tgz", - "integrity": "sha512-QqacJbA8f1pmwUTqki1qLL5vIBaOQmeq13CZZefZ3r3vKVaIoC7cpoTgE+KPKxJDFTax+iFZV0VYvLVWPiQ8Aw==", + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/electron-vite/-/electron-vite-6.0.0.tgz", + "integrity": "sha512-zafg2uizgll7jdx0BNDkkzO/SowsUBsiHqYN3v9Ieq7XPDHreRGZ4G9IRY/+RslgBktpLOjLM4jlP+IVpV0BGw==", "dev": true, "license": "MIT", "dependencies": { - "@babel/core": "^7.27.7", - "@babel/plugin-transform-arrow-functions": "^7.27.1", - "cac": "^6.7.14", - "esbuild": "^0.25.5", - "magic-string": "^0.30.17", - "picocolors": "^1.1.1" + "@babel/core": "^7.29.7", + "@babel/plugin-transform-arrow-functions": "^7.29.7", + "cac": "^7.0.0", + "magic-string": "^1.4.2", + "picocolors": "^1.1.1", + "rolldown": "~1.2.10" }, "bin": { "electron-vite": "bin/electron-vite.js" @@ -6472,7 +6745,7 @@ }, "peerDependencies": { "@swc/core": "^1.0.0", - "vite": "^5.0.0 || ^6.0.0 || ^7.0.0" + "vite": "^6.0.0 || ^7.0.0 || ^8.0.0" }, "peerDependenciesMeta": { "@swc/core": { @@ -6540,23 +6813,6 @@ "node": ">= 4.0.0" } }, - "node_modules/electron/node_modules/@types/node": { - "version": "24.13.2", - "resolved": "https://registry.npmjs.org/@types/node/-/node-24.13.2.tgz", - "integrity": "sha512-fRa09kZTgu8o71KFcDjUFuc7F+dEbZYZmkI0mg5YBTRs0yMKjYHsq/c0urDKeDb+D5qVgXOdFcuu+DZPKOITwA==", - "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~7.18.0" - } - }, - "node_modules/electron/node_modules/undici-types": { - "version": "7.18.2", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.18.2.tgz", - "integrity": "sha512-AsuCzffGHJybSaRrmr5eHr81mwJU3kjw6M+uprWvCXiNeN9SOGwQ3Jn8jb8m3Z6izVgknn1R0FTCEAP2QrLY/w==", - "dev": true, - "license": "MIT" - }, "node_modules/emoji-regex": { "version": "8.0.0", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", @@ -6564,6 +6820,19 @@ "dev": true, "license": "MIT" }, + "node_modules/encodeurl": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.3.tgz", + "integrity": "sha512-mIteYONiEfc4xWf2F1WXovh1c8npzS00vNeiUPdwFF+QlVJni+gNvpQltLMQhob8rew/bWWc/bGTuUr0EUGt0w==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, "node_modules/end-of-stream": { "version": "1.4.5", "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.5.tgz", @@ -6711,9 +6980,9 @@ } }, "node_modules/es-module-lexer": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-2.1.0.tgz", - "integrity": "sha512-n27zTYMjYu1aj4MjCWzSP7G9r75utsaoc8m61weK+W8JMBGGQybd43GstCXZ3WNmSFtGT9wi59qQTW6mhTR5LQ==", + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-2.3.2.tgz", + "integrity": "sha512-poHGpORABojJJucnV9KbOavETW8lBVnphkW77ER5/BQ5Fz7oXSoCNek7IH3vR5nRjdsEz926ibFYX8KtLQmdyw==", "dev": true, "license": "MIT" }, @@ -6773,10 +7042,9 @@ "optional": true }, "node_modules/esbuild": { - "version": "0.25.12", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.12.tgz", - "integrity": "sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg==", - "dev": true, + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.28.2.tgz", + "integrity": "sha512-HKVLS8dvII+xoKW9kmqxbRKrnWEXfJJr/FZhhJmiqIB0e053QNYFqOBouTMO/k5sID4MvCiUCvv8b9M4h32wIA==", "hasInstallScript": true, "license": "MIT", "bin": { @@ -6786,32 +7054,32 @@ "node": ">=18" }, "optionalDependencies": { - "@esbuild/aix-ppc64": "0.25.12", - "@esbuild/android-arm": "0.25.12", - "@esbuild/android-arm64": "0.25.12", - "@esbuild/android-x64": "0.25.12", - "@esbuild/darwin-arm64": "0.25.12", - "@esbuild/darwin-x64": "0.25.12", - "@esbuild/freebsd-arm64": "0.25.12", - "@esbuild/freebsd-x64": "0.25.12", - "@esbuild/linux-arm": "0.25.12", - "@esbuild/linux-arm64": "0.25.12", - "@esbuild/linux-ia32": "0.25.12", - "@esbuild/linux-loong64": "0.25.12", - "@esbuild/linux-mips64el": "0.25.12", - "@esbuild/linux-ppc64": "0.25.12", - "@esbuild/linux-riscv64": "0.25.12", - "@esbuild/linux-s390x": "0.25.12", - "@esbuild/linux-x64": "0.25.12", - "@esbuild/netbsd-arm64": "0.25.12", - "@esbuild/netbsd-x64": "0.25.12", - "@esbuild/openbsd-arm64": "0.25.12", - "@esbuild/openbsd-x64": "0.25.12", - "@esbuild/openharmony-arm64": "0.25.12", - "@esbuild/sunos-x64": "0.25.12", - "@esbuild/win32-arm64": "0.25.12", - "@esbuild/win32-ia32": "0.25.12", - "@esbuild/win32-x64": "0.25.12" + "@esbuild/aix-ppc64": "0.28.2", + "@esbuild/android-arm": "0.28.2", + "@esbuild/android-arm64": "0.28.2", + "@esbuild/android-x64": "0.28.2", + "@esbuild/darwin-arm64": "0.28.2", + "@esbuild/darwin-x64": "0.28.2", + "@esbuild/freebsd-arm64": "0.28.2", + "@esbuild/freebsd-x64": "0.28.2", + "@esbuild/linux-arm": "0.28.2", + "@esbuild/linux-arm64": "0.28.2", + "@esbuild/linux-ia32": "0.28.2", + "@esbuild/linux-loong64": "0.28.2", + "@esbuild/linux-mips64el": "0.28.2", + "@esbuild/linux-ppc64": "0.28.2", + "@esbuild/linux-riscv64": "0.28.2", + "@esbuild/linux-s390x": "0.28.2", + "@esbuild/linux-x64": "0.28.2", + "@esbuild/netbsd-arm64": "0.28.2", + "@esbuild/netbsd-x64": "0.28.2", + "@esbuild/openbsd-arm64": "0.28.2", + "@esbuild/openbsd-x64": "0.28.2", + "@esbuild/openharmony-arm64": "0.28.2", + "@esbuild/sunos-x64": "0.28.2", + "@esbuild/win32-arm64": "0.28.2", + "@esbuild/win32-ia32": "0.28.2", + "@esbuild/win32-x64": "0.28.2" } }, "node_modules/escalade": { @@ -6824,6 +7092,12 @@ "node": ">=6" } }, + "node_modules/escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==", + "license": "MIT" + }, "node_modules/escape-string-regexp": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", @@ -6837,44 +7111,43 @@ } }, "node_modules/eslint": { - "version": "9.39.4", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.39.4.tgz", - "integrity": "sha512-XoMjdBOwe/esVgEvLmNsD3IRHkm7fbKIUGvrleloJXUZgDHig2IPWNniv+GwjyJXzuNqVjlr5+4yVUZjycJwfQ==", + "version": "10.15.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-10.15.0.tgz", + "integrity": "sha512-+5Wg4p+ze3sG1WErYgUO/3H1IQIfFBymVUA0Fo/XTeBOLS6UQIUekpSJ8sdRkn7O7wjh84b55w/roqavH2aScg==", "dev": true, "license": "MIT", + "workspaces": [ + "packages/*" + ], "dependencies": { "@eslint-community/eslint-utils": "^4.8.0", - "@eslint-community/regexpp": "^4.12.1", - "@eslint/config-array": "^0.21.2", - "@eslint/config-helpers": "^0.4.2", - "@eslint/core": "^0.17.0", - "@eslint/eslintrc": "^3.3.5", - "@eslint/js": "9.39.4", - "@eslint/plugin-kit": "^0.4.1", - "@humanfs/node": "^0.16.6", + "@eslint-community/regexpp": "^4.12.2", + "@eslint/config-array": "^0.23.6", + "@eslint/config-helpers": "^0.7.0", + "@eslint/core": "^1.2.1", + "@eslint/plugin-kit": "^0.7.3", + "@humanfs/node": "^0.16.8", "@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/retry": "^0.4.2", "@types/estree": "^1.0.6", "ajv": "^6.14.0", - "chalk": "^4.0.0", "cross-spawn": "^7.0.6", "debug": "^4.3.2", "escape-string-regexp": "^4.0.0", - "eslint-scope": "^8.4.0", - "eslint-visitor-keys": "^4.2.1", - "espree": "^10.4.0", - "esquery": "^1.5.0", + "eslint-scope": "^9.1.2", + "eslint-visitor-keys": "^5.0.1", + "espree": "^11.2.0", + "esquery": "^1.7.0", "esutils": "^2.0.2", "fast-deep-equal": "^3.1.3", - "file-entry-cache": "^8.0.0", + "file-entry-cache": "11.1.5 || >11.1.6 <12", "find-up": "^5.0.0", "glob-parent": "^6.0.2", "ignore": "^5.2.0", "imurmurhash": "^0.1.4", "is-glob": "^4.0.0", "json-stable-stringify-without-jsonify": "^1.0.1", - "lodash.merge": "^4.6.2", - "minimatch": "^3.1.5", + "minimatch": "^11.0.5", "natural-compare": "^1.4.0", "optionator": "^0.9.3" }, @@ -6882,7 +7155,7 @@ "eslint": "bin/eslint.js" }, "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node": "^20.19.0 || ^22.13.0 || >=24" }, "funding": { "url": "https://eslint.org/donate" @@ -6897,30 +7170,39 @@ } }, "node_modules/eslint-plugin-react-hooks": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-5.2.0.tgz", - "integrity": "sha512-+f15FfK64YQwZdJNELETdn5ibXEUQmW1DZL6KXhNnc2heoy/sg9VJJeT7n8TlMWouzWqSWavFkIhHyIbIAEapg==", + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-7.1.1.tgz", + "integrity": "sha512-f2I7Gw6JbvCexzIInuSbZpfdQ44D7iqdWX01FKLvrPgqxoE7oMj8clOfto8U6vYiz4yd5oKu39rRSVOe1zRu0g==", "dev": true, "license": "MIT", + "dependencies": { + "@babel/core": "^7.24.4", + "@babel/parser": "^7.24.4", + "hermes-parser": "^0.25.1", + "zod": "^3.25.0 || ^4.0.0", + "zod-validation-error": "^3.5.0 || ^4.0.0" + }, "engines": { - "node": ">=10" + "node": ">=18" }, "peerDependencies": { - "eslint": "^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0 || ^9.0.0" + "eslint": "^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0 || ^9.0.0 || ^10.0.0" } }, "node_modules/eslint-scope": { - "version": "8.4.0", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-8.4.0.tgz", - "integrity": "sha512-sNXOfKCn74rt8RICKMvJS7XKV/Xk9kA7DyJr8mJik3S7Cwgy3qlkkmyS2uQB3jiJg6VNdZd/pDBJu0nvG2NlTg==", + "version": "9.1.2", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-9.1.2.tgz", + "integrity": "sha512-xS90H51cKw0jltxmvmHy2Iai1LIqrfbw57b79w/J7MfvDfkIkFZ+kj6zC3BjtUwh150HsSSdxXZcsuv72miDFQ==", "dev": true, "license": "BSD-2-Clause", "dependencies": { + "@types/esrecurse": "^4.3.1", + "@types/estree": "^1.0.8", "esrecurse": "^4.3.0", "estraverse": "^5.2.0" }, "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node": "^20.19.0 || ^22.13.0 || >=24" }, "funding": { "url": "https://opencollective.com/eslint" @@ -6939,32 +7221,31 @@ "url": "https://opencollective.com/eslint" } }, - "node_modules/eslint/node_modules/balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true, - "license": "MIT" - }, - "node_modules/eslint/node_modules/brace-expansion": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.15.tgz", - "integrity": "sha512-EwOCDEex4quD37XhqM3omwtMoJjr//isUZz1JopUNWms+4Z2ViyM/k1YIRePpoVNnQhENnxtFjLaxNHrT7xIUg==", + "node_modules/eslint/node_modules/ajv": { + "version": "6.15.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.15.0.tgz", + "integrity": "sha512-fgFx7Hfoq60ytK2c7DhnF8jIvzYgOMxfugjLOSMHjLIPgenqa7S7oaagATUq99mV6IYvN2tRmC0wnTYX6iPbMw==", "dev": true, "license": "MIT", "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" } }, "node_modules/eslint/node_modules/eslint-visitor-keys": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.1.tgz", - "integrity": "sha512-Uhdk5sfqcee/9H/rCOJikYz67o0a2Tw2hGRPOG2Y1R2dg7brRe1uG0yaNQDHu+TO/uQPF/5eCapvYSmHUjt7JQ==", + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-5.0.1.tgz", + "integrity": "sha512-tD40eHxA35h0PEIZNeIjkHoDR4YjjJp34biM0mDvplBe//mB+IHCqHDGV7pxF+7MklTvighcCPPZC7ynWyjdTA==", "dev": true, "license": "Apache-2.0", "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node": "^20.19.0 || ^22.13.0 || >=24" }, "funding": { "url": "https://opencollective.com/eslint" @@ -6980,45 +7261,56 @@ "node": ">= 4" } }, + "node_modules/eslint/node_modules/json-schema-traverse": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", + "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "dev": true, + "license": "MIT" + }, "node_modules/eslint/node_modules/minimatch": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.5.tgz", - "integrity": "sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==", + "version": "11.0.9", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-11.0.9.tgz", + "integrity": "sha512-KCFkfyjqerNlSstjlhIGNXIKZGA/6O4V4RlhZ+Dsr621SPPw0mzlypE9D9ZOoPiVefHID+j7/XuMMlqfD/F60Q==", "dev": true, - "license": "ISC", + "license": "BlueOak-1.0.0", "dependencies": { - "brace-expansion": "^1.1.7" + "@isaacs/nonrecursive-glob-match": "^1.1.0", + "brace-expansion": "^5.0.12" }, "engines": { - "node": "*" + "node": "20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, "node_modules/espree": { - "version": "10.4.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-10.4.0.tgz", - "integrity": "sha512-j6PAQ2uUr79PZhBjP5C5fhl8e39FmRnOjsD5lGnWrFU8i2G776tBK7+nP8KuQUTTyAZUwfQqXAgrVH5MbH9CYQ==", + "version": "11.2.0", + "resolved": "https://registry.npmjs.org/espree/-/espree-11.2.0.tgz", + "integrity": "sha512-7p3DrVEIopW1B1avAGLuCSh1jubc01H2JHc8B4qqGblmg5gI9yumBgACjWo4JlIc04ufug4xJ3SQI8HkS/Rgzw==", "dev": true, "license": "BSD-2-Clause", "dependencies": { - "acorn": "^8.15.0", + "acorn": "^8.16.0", "acorn-jsx": "^5.3.2", - "eslint-visitor-keys": "^4.2.1" + "eslint-visitor-keys": "^5.0.1" }, "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node": "^20.19.0 || ^22.13.0 || >=24" }, "funding": { "url": "https://opencollective.com/eslint" } }, "node_modules/espree/node_modules/eslint-visitor-keys": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.1.tgz", - "integrity": "sha512-Uhdk5sfqcee/9H/rCOJikYz67o0a2Tw2hGRPOG2Y1R2dg7brRe1uG0yaNQDHu+TO/uQPF/5eCapvYSmHUjt7JQ==", + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-5.0.1.tgz", + "integrity": "sha512-tD40eHxA35h0PEIZNeIjkHoDR4YjjJp34biM0mDvplBe//mB+IHCqHDGV7pxF+7MklTvighcCPPZC7ynWyjdTA==", "dev": true, "license": "Apache-2.0", "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node": "^20.19.0 || ^22.13.0 || >=24" }, "funding": { "url": "https://opencollective.com/eslint" @@ -7104,6 +7396,15 @@ "node": ">=0.10.0" } }, + "node_modules/etag": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", + "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, "node_modules/events-universal": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/events-universal/-/events-universal-1.0.1.tgz", @@ -7113,10 +7414,31 @@ "bare-events": "^2.7.0" } }, + "node_modules/eventsource": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/eventsource/-/eventsource-3.0.7.tgz", + "integrity": "sha512-CRT1WTyuQoD771GW56XEZFQ/ZoSfWid1alKGDYMmkt2yl8UXrVR4pspqWNEcqKvVIzg6PAltWjxcSSPrboA4iA==", + "license": "MIT", + "dependencies": { + "eventsource-parser": "^3.0.1" + }, + "engines": { + "node": ">=18.0.0" + } + }, + "node_modules/eventsource-parser": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/eventsource-parser/-/eventsource-parser-3.1.1.tgz", + "integrity": "sha512-EKN1vKAMcZ8MlYMpaNuxN6R9yakzH6uajHcHVTqWJzvu5pWw9DyhbP35HH8MVBQ+dZjAfDxk+A8NiR9KWaXiyQ==", + "license": "MIT", + "engines": { + "node": ">=18.0.0" + } + }, "node_modules/expect-type": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/expect-type/-/expect-type-1.3.0.tgz", - "integrity": "sha512-knvyeauYhqjOYvQ66MznSMs83wmHrCycNEN6Ao+2AeYEfxUIkuiVxdEa1qlGEPK+We3n0THiDciYSsCcgW/DoA==", + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/expect-type/-/expect-type-1.4.0.tgz", + "integrity": "sha512-KfYbmpRm0VbLjEvVa9yGwCi9GI34xvi7A/HXYWQO65CSD2u3MczUJSuwXKFIxlGsgBQizV9q5J9NHj4VG0n+pA==", "dev": true, "license": "Apache-2.0", "engines": { @@ -7130,6 +7452,106 @@ "dev": true, "license": "Apache-2.0" }, + "node_modules/express": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/express/-/express-5.3.0.tgz", + "integrity": "sha512-qCqy1xSoaugxOD4IVHb1ZWdkvCF2W3aE2okKouWj8VwJ+ztskSiXoBnCSJqfKT+cVPJhuJqe9YLbY425+Zh00g==", + "license": "MIT", + "dependencies": { + "accepts": "^2.0.0", + "body-parser": "^2.3.0", + "content-disposition": "^2.0.1", + "content-type": "^2.0.0", + "cookie": "^0.7.1", + "cookie-signature": "^1.2.1", + "debug": "^4.4.0", + "depd": "^2.0.0", + "encodeurl": "^2.0.0", + "escape-html": "^1.0.3", + "etag": "^1.8.1", + "finalhandler": "^2.1.0", + "fresh": "^2.0.0", + "http-errors": "^2.0.0", + "merge-descriptors": "^2.0.0", + "mime-types": "^3.0.0", + "on-finished": "^2.4.1", + "once": "^1.4.0", + "parseurl": "^1.3.3", + "proxy-addr": "^2.0.8", + "qs": "^6.16.0", + "range-parser": "^1.2.1", + "router": "^2.2.0", + "send": "^1.1.0", + "serve-static": "^2.2.0", + "statuses": "^2.0.1", + "type-is": "^2.1.0", + "vary": "^1.1.2" + }, + "engines": { + "node": ">= 18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/express-rate-limit": { + "version": "8.7.5", + "resolved": "https://registry.npmjs.org/express-rate-limit/-/express-rate-limit-8.7.5.tgz", + "integrity": "sha512-wi+v38cx2EqD0JnhE/e74o5tFqKWUOAPFJIgyEiqJ8v2MNpoOAA3kI2hXYOI+YM+HE5yqbdAlVxm2GqOIeYOgA==", + "license": "MIT", + "dependencies": { + "debug": "^4.4.3", + "ip-address": "^10.2.0" + }, + "engines": { + "node": ">= 16" + }, + "funding": { + "url": "https://github.com/sponsors/express-rate-limit" + }, + "peerDependencies": { + "express": ">= 4.11" + } + }, + "node_modules/express/node_modules/content-type": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-2.1.0.tgz", + "integrity": "sha512-mj7UPXE0jaqaOsukNZRUEfEi2AcL7C/vwmwcHV0O97eO1E1pxBZuyjlZrx5seTaNBg1U6+o35wpa35Qfcc+7ag==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/express/node_modules/mime-db": { + "version": "1.54.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", + "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/express/node_modules/mime-types": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.2.tgz", + "integrity": "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==", + "license": "MIT", + "dependencies": { + "mime-db": "^1.54.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, "node_modules/extend": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", @@ -7140,7 +7562,6 @@ "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "dev": true, "license": "MIT" }, "node_modules/fast-fifo": { @@ -7185,10 +7606,9 @@ } }, "node_modules/fast-uri": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.4.tgz", - "integrity": "sha512-8JnbkQ4juDyvYs4mgFGQqg4yCYtFDtUtmp2QIQq11ZZe5CFQ5wcqm1rqDgAh/QdMySuBnPzMUiJUNZG5N/AiQw==", - "dev": true, + "version": "3.1.9", + "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.9.tgz", + "integrity": "sha512-hS/0Wt3Ya043oKXs0sIxrMpKQITXhMLIrVAKKXi4gozGC9v7YRWVnXIZzjNPTO02M9BdxLCWqK1yRXgNziVyJQ==", "funding": [ { "type": "github", @@ -7261,16 +7681,13 @@ } }, "node_modules/file-entry-cache": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-8.0.0.tgz", - "integrity": "sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==", + "version": "11.1.5", + "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-11.1.5.tgz", + "integrity": "sha512-+PFTHITI08JIGhnNpGNI8T8inUpgZfk3GNEqfT9R2zZV2iFXg3CvqzSl/uEhs7TSGujYRELEANyDvS8Fj7+S7Q==", "dev": true, "license": "MIT", "dependencies": { - "flat-cache": "^4.0.0" - }, - "engines": { - "node": ">=16.0.0" + "flat-cache": "^6.1.23" } }, "node_modules/filelist": { @@ -7291,9 +7708,9 @@ "license": "MIT" }, "node_modules/filelist/node_modules/brace-expansion": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.2.tgz", - "integrity": "sha512-w5JZcKgdhDOgOwm8H+KgbosopHMuGcl6qbulwjtz3SM7I7P3yW1eAjzMPLrIE+NQ9vjgANKHWeMHnrT0OXW1oA==", + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.8.tgz", + "integrity": "sha512-BnlDzDYQoplTsZSvPi86CNzmbcb07X8ufR8fk1zivaiEJlXJkiq1MQyDCVmlWcsWbj6aWXqHnrwwevbrm/Saig==", "dev": true, "license": "MIT", "dependencies": { @@ -7313,17 +7730,25 @@ "node": ">=10" } }, - "node_modules/fill-range": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", - "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", - "dev": true, + "node_modules/finalhandler": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-2.1.1.tgz", + "integrity": "sha512-S8KoZgRZN+a5rNwqTxlZZePjT/4cnm0ROV70LedRHZ0p8u9fRID0hJUZQpkKLzro8LfmC8sx23bY6tVNxv8pQA==", "license": "MIT", "dependencies": { - "to-regex-range": "^5.0.1" + "debug": "^4.4.0", + "encodeurl": "^2.0.0", + "escape-html": "^1.0.3", + "on-finished": "^2.4.1", + "parseurl": "^1.3.3", + "statuses": "^2.0.1" }, "engines": { - "node": ">=8" + "node": ">= 18.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, "node_modules/find-up": { @@ -7343,28 +7768,16 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/find-yarn-workspace-root": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/find-yarn-workspace-root/-/find-yarn-workspace-root-2.0.0.tgz", - "integrity": "sha512-1IMnbjt4KzsQfnhnzNd8wUEgXZ44IzZaZmnLYx7D5FZlaHt2gW20Cri8Q+E/t5tIj4+epTBub+2Zxu/vNILzqQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "micromatch": "^4.0.2" - } - }, "node_modules/flat-cache": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-4.0.1.tgz", - "integrity": "sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==", + "version": "6.1.23", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-6.1.23.tgz", + "integrity": "sha512-f++BY9pTk+983xK1FLzlLpmM0i0z+jHmx3QESGkURMXujQZz1k5wzwX6hjnQ8goaD0B+sYnDK1yZ6MTyZfUaqA==", "dev": true, "license": "MIT", "dependencies": { - "flatted": "^3.2.9", - "keyv": "^4.5.4" - }, - "engines": { - "node": ">=16" + "cacheable": "^2.5.0", + "flatted": "^3.4.2", + "hookified": "^1.15.0" } }, "node_modules/flatbuffers": { @@ -7374,9 +7787,9 @@ "license": "Apache-2.0" }, "node_modules/flatted": { - "version": "3.4.2", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.4.2.tgz", - "integrity": "sha512-PjDse7RzhcPkIJwy5t7KPWQSZ9cAbzQXcafsetQoD7sOJRQlGikNbx7yZp2OotDnJyrDcbyRq3Ttb18iYOqkxA==", + "version": "3.4.4", + "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.4.4.tgz", + "integrity": "sha512-5+ybhBZANEJxaH3X5evAFatUxLfEHSr7n6kYJ+1Qd0mUqr4eu9gIf6GDbWHf8RJijHrjjO8G+la14SlL2SeS1Q==", "dev": true, "license": "ISC" }, @@ -7424,6 +7837,24 @@ "node": ">=12.20.0" } }, + "node_modules/forwarded": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", + "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/fresh": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/fresh/-/fresh-2.0.0.tgz", + "integrity": "sha512-Rx/WycZ60HOaqLKAi6cHRKKI7zxWbJ31MhntmtwMoaTeF7XFH9hhBp8vITaMidfljRQ6eYWCKkaTK+ykVJHP2A==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, "node_modules/fs-extra": { "version": "10.1.0", "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz", @@ -7514,6 +7945,28 @@ "node": ">=18" } }, + "node_modules/gaxios/node_modules/agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "license": "MIT", + "engines": { + "node": ">= 14" + } + }, + "node_modules/gaxios/node_modules/https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.2", + "debug": "4" + }, + "engines": { + "node": ">= 14" + } + }, "node_modules/gcp-metadata": { "version": "8.1.2", "resolved": "https://registry.npmjs.org/gcp-metadata/-/gcp-metadata-8.1.2.tgz", @@ -7682,9 +8135,9 @@ "license": "MIT" }, "node_modules/glob/node_modules/brace-expansion": { - "version": "1.1.16", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.16.tgz", - "integrity": "sha512-IDw48K2/2kRkg9LdJxurvq3lV3aBgq0REY89duEqFRthjlPdXHKMj7EnQOXVckxzgisinf3nHfrcE2FufFLXMw==", + "version": "1.1.22", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.22.tgz", + "integrity": "sha512-CKLDTuSsN0+r1ThM0WkzzBI7dnPI6xEGfa/JnVYIK9JNBA1N1NyPwXVHor//NKD/y3sDxp764sZdLhFK7pH8XQ==", "dev": true, "license": "MIT", "dependencies": { @@ -7706,37 +8159,20 @@ } }, "node_modules/global-agent": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/global-agent/-/global-agent-3.0.0.tgz", - "integrity": "sha512-PT6XReJ+D07JvGoxQMkT6qji/jVNfX/h364XHZOWeRzy64sSFr+xJ5OX7LI3b4MPQzdL4H8Y8M0xzPpsVMwA8Q==", - "dev": true, + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/global-agent/-/global-agent-4.1.7.tgz", + "integrity": "sha512-pxaZqdsMwPA4i7TuRKpDUONm2xGRjvYdRoidCQz7VleUKVuUfh/4p5Q3QDTGrpAE5Kz5TxxcZ+uqEgTkoKRNtg==", "license": "BSD-3-Clause", - "optional": true, "dependencies": { - "boolean": "^3.0.1", - "es6-error": "^4.1.1", - "matcher": "^3.0.0", - "roarr": "^2.15.3", - "semver": "^7.3.2", - "serialize-error": "^7.0.1" + "globalthis": "^1.0.2", + "matcher": "^4.0.0", + "semver": "^7.3.5", + "serialize-error": "^8.1.0" }, "engines": { "node": ">=10.0" } }, - "node_modules/globals": { - "version": "14.0.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-14.0.0.tgz", - "integrity": "sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/globalthis": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.4.tgz", @@ -7818,10 +8254,10 @@ } }, "node_modules/graceful-fs": { - "version": "4.2.11", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", - "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", - "license": "ISC" + "version": "4.2.12", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.12.tgz", + "integrity": "sha512-iuyGF2E4oafQfPsRrG2wtY2ILupMhvtdrhzrxB+0VcjsPpSPttpfYdjnGFGsTi5MaJFjI1jOKHPQ6UTbTj9TAw==", + "license": "BlueOak-1.0.0" }, "node_modules/guid-typescript": { "version": "1.0.9", @@ -7905,6 +8341,19 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/hashery": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/hashery/-/hashery-1.5.1.tgz", + "integrity": "sha512-iZyKG96/JwPz1N55vj2Ie2vXbhu440zfUfJvSwEqEbeLluk7NnapfGqa7LH0mOsnDxTF85Mx8/dyR6HfqcbmbQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "hookified": "^1.15.0" + }, + "engines": { + "node": ">=20" + } + }, "node_modules/hasown": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.4.tgz", @@ -7917,48 +8366,68 @@ "node": ">= 0.4" } }, - "node_modules/highlight.js": { - "version": "11.11.2", - "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-11.11.2.tgz", - "integrity": "sha512-oaXMACAU0kzOMXBjWpNcX+vlwSBCIAiZ9BHa7gA15NOTtT2L/l8OSZDuqS2XppOhZBPJ7hm4o8ep2kyuip2uEQ==", + "node_modules/hermes-estree": { + "version": "0.25.1", + "resolved": "https://registry.npmjs.org/hermes-estree/-/hermes-estree-0.25.1.tgz", + "integrity": "sha512-0wUoCcLp+5Ev5pDW2OriHC2MJCbwLwuRx+gAqMTOkGKJJiBCLjtrvy4PWUGn6MIVefecRpzoOZ/UV6iGdOr+Cw==", "dev": true, + "license": "MIT" + }, + "node_modules/hermes-parser": { + "version": "0.25.1", + "resolved": "https://registry.npmjs.org/hermes-parser/-/hermes-parser-0.25.1.tgz", + "integrity": "sha512-6pEjquH3rqaI6cYAXYPcz9MS4rY6R4ngRgrgfDshRptUZIc3lw0MCIJIGDj9++mfySOuPTHB4nrSW99BCvOPIA==", + "dev": true, + "license": "MIT", + "dependencies": { + "hermes-estree": "0.25.1" + } + }, + "node_modules/highlight.js": { + "version": "10.7.3", + "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-10.7.3.tgz", + "integrity": "sha512-tzcUFauisWKNHaRkN4Wjl/ZA07gENAjFl3J/c480dprkGTg5EQstgaNFqBfUqCq54kZRIEcreTsAgF/m2quD7A==", "license": "BSD-3-Clause", "engines": { - "node": ">=12.0.0" + "node": "*" } }, - "node_modules/hosted-git-info": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", - "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", - "dev": true, - "license": "ISC", - "dependencies": { - "lru-cache": "^6.0.0" - }, + "node_modules/hono": { + "version": "4.13.19", + "resolved": "https://registry.npmjs.org/hono/-/hono-4.13.19.tgz", + "integrity": "sha512-KmXvQAXwcAHV+muzbIwoJ23niEB5nMoDVr9WcRkU8mvjUECm/1+7v4Jgp7P7a+H6MLFrh+vXrGonGrGS+RQfkA==", + "license": "MIT", "engines": { - "node": ">=10" + "node": ">=16.9.0" } }, - "node_modules/hosted-git-info/node_modules/lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "node_modules/hookified": { + "version": "1.15.1", + "resolved": "https://registry.npmjs.org/hookified/-/hookified-1.15.1.tgz", + "integrity": "sha512-MvG/clsADq1GPM2KGo2nyfaWVyn9naPiXrqIe4jYjXNZQt238kWyOGrsyc/DmRAQ+Re6yeo6yX/yoNCG5KAEVg==", "dev": true, + "license": "MIT" + }, + "node_modules/hosted-git-info": { + "version": "9.0.3", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-9.0.3.tgz", + "integrity": "sha512-Hc+ghLoSt6QaYZUv0WBiIvmMDZuZZ7oaDvdH8MbfOO4lOsxdXLEvuC6ePoGs9H1X9oCLyq6+NVN0MKqD+ydxyg==", "license": "ISC", "dependencies": { - "yallist": "^4.0.0" + "lru-cache": "^11.1.0" }, "engines": { - "node": ">=10" + "node": "^20.17.0 || >=22.9.0" } }, - "node_modules/hosted-git-info/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true, - "license": "ISC" + "node_modules/hosted-git-info/node_modules/lru-cache": { + "version": "11.5.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-11.5.3.tgz", + "integrity": "sha512-U4N8FgzmWxc8k1VH8Kr6lQg18U7Fjvby6wXHVRX/ZZ7IwWbRMgrRbP0Wrb5q5NVinryp4SQampHKdvtecItxUg==", + "license": "BlueOak-1.0.0", + "engines": { + "node": "20 || >=22" + } }, "node_modules/html-escaper": { "version": "3.0.3", @@ -7986,24 +8455,44 @@ } }, "node_modules/http-cache-semantics": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.2.0.tgz", - "integrity": "sha512-dTxcvPXqPvXBQpq5dUr6mEMJX4oIEFv6bwom3FDwKRDsuIjjJGANqhBuoAn9c1RQJIdAKav33ED65E2ys+87QQ==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.3.0.tgz", + "integrity": "sha512-M5t5LlJpS1UHMjvwRQVdFHvPISGeLAxNcrWuJkeGh0KxsqCHZ1O3NXZU/8x7cD0BDcGW8kapxMKTvwlqrNkHkA==", "dev": true, "license": "BSD-2-Clause" }, + "node_modules/http-errors": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.1.tgz", + "integrity": "sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==", + "license": "MIT", + "dependencies": { + "depd": "~2.0.0", + "inherits": "~2.0.4", + "setprototypeof": "~1.2.0", + "statuses": "~2.0.2", + "toidentifier": "~1.0.1" + }, + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, "node_modules/http-proxy-agent": { - "version": "7.0.2", - "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", - "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", - "dev": true, + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-9.1.0.tgz", + "integrity": "sha512-2NxoveTT58mjYT4n3RPTEfCZGLMbidoO8XEieXfpSYxu+PQJ1qpx4ypwH6N+uF9twBPIvRRgvkvW5HUTYWENig==", "license": "MIT", "dependencies": { - "agent-base": "^7.1.0", - "debug": "^4.3.4" + "agent-base": "9.0.0", + "debug": "^4.3.4", + "proxy-agent-negotiate": "1.1.0" }, "engines": { - "node": ">= 14" + "node": ">= 20" } }, "node_modules/http2-wrapper": { @@ -8021,44 +8510,51 @@ } }, "node_modules/https-proxy-agent": { - "version": "7.0.6", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", - "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-9.1.0.tgz", + "integrity": "sha512-ag87y7cJJ9/3+GxFr8Oy4O5faDsGRGnBGsJj/YjOSsSx/5eadKLYTMPlzuR6obgoCDDm0abAAZitXXQkMOPSpA==", "license": "MIT", "dependencies": { - "agent-base": "^7.1.2", - "debug": "4" + "agent-base": "9.0.0", + "debug": "^4.3.4", + "proxy-agent-negotiate": "1.1.0" }, "engines": { - "node": ">= 14" - } - }, - "node_modules/ignore": { - "version": "7.0.12", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.12.tgz", - "integrity": "sha512-/8UvqAPU9DGTI9k4mxtf49U37Isfwr8Uts96+SBHIkFxPJnHS0Ew4f00sM4Scd8V8EjM0jUNtVDdv1kPdt35lg==", - "license": "MIT", - "engines": { - "node": ">= 4" + "node": ">= 20" } }, - "node_modules/import-fresh": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.1.tgz", - "integrity": "sha512-TR3KfrTZTYLPB6jUjfx6MF9WcWrHL9su5TObK4ZkYgBdWKPOFoSoQIdEuTuR82pmtxH2spWG9h6etwfr1pLBqQ==", - "dev": true, + "node_modules/iconv-lite": { + "version": "0.7.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.7.3.tgz", + "integrity": "sha512-IKXpvIzjnC9XTAUbVBcMfGS0EPaIXtW6v+zr+RRp+hqULEpo0owZax6wyRwPOJbWbzjYspQwusTsfVr0ifh4uQ==", "license": "MIT", "dependencies": { - "parent-module": "^1.0.0", - "resolve-from": "^4.0.0" + "safer-buffer": ">= 2.1.2 < 3.0.0" }, "engines": { - "node": ">=6" + "node": ">=0.10.0" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/ignore": { + "version": "7.0.16", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.16.tgz", + "integrity": "sha512-52N+Y4HRMOJmbLmr+DqO4iSRyyB7N52gm7PWCT6h0p978+oKbqHCB7gIJIwZvBUsjlSdWbrBFqUSmIFNZMpn0A==", + "license": "MIT", + "engines": { + "node": ">= 4" } }, + "node_modules/immediate": { + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz", + "integrity": "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ==", + "license": "MIT", + "optional": true + }, "node_modules/imurmurhash": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", @@ -8085,7 +8581,6 @@ "version": "2.0.4", "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true, "license": "ISC" }, "node_modules/internal-slot": { @@ -8102,6 +8597,24 @@ "node": ">= 0.4" } }, + "node_modules/ip-address": { + "version": "10.7.6", + "resolved": "https://registry.npmjs.org/ip-address/-/ip-address-10.7.6.tgz", + "integrity": "sha512-00LYkM6byILa9eQIx6qoaXCM40xTLd56AZ4vyaPW3YTyb49VZYPo5xsiAq4tuQ54GH4R7gVdYScJ1B7B77PuTg==", + "license": "MIT", + "engines": { + "node": ">= 12" + } + }, + "node_modules/ipaddr.js": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", + "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==", + "license": "MIT", + "engines": { + "node": ">= 0.10" + } + }, "node_modules/is-alphabetical": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/is-alphabetical/-/is-alphabetical-2.0.1.tgz", @@ -8248,22 +8761,6 @@ "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/is-docker": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", - "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==", - "dev": true, - "license": "MIT", - "bin": { - "is-docker": "cli.js" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/is-document.all": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-document.all/-/is-document.all-1.0.0.tgz", @@ -8380,16 +8877,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.12.0" - } - }, "node_modules/is-number-object": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.1.1.tgz", @@ -8418,6 +8905,12 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/is-promise": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-4.0.0.tgz", + "integrity": "sha512-hvpoI6korhJMnej285dSg6nu1+e6uxs7zG3BYAm5byqDsgJNWwxzM6z6iZiAgQR4TJ30JmBTOwqZUw3WlyH3AQ==", + "license": "MIT" + }, "node_modules/is-regex": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.2.1.tgz", @@ -8554,24 +9047,11 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-wsl": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", - "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", - "dev": true, - "license": "MIT", - "dependencies": { - "is-docker": "^2.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/isarray": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==", - "dev": true, + "devOptional": true, "license": "MIT" }, "node_modules/isbinaryfile": { @@ -8620,6 +9100,15 @@ "jiti": "lib/jiti-cli.mjs" } }, + "node_modules/jose": { + "version": "6.2.18", + "resolved": "https://registry.npmjs.org/jose/-/jose-6.2.18.tgz", + "integrity": "sha512-doV4thUwgkrycJH4yLeqwTGIIZphHl+pk7CPReuMIhYhncmgzdko85MaCG4YQFTxqMFr1/oEH32tZuKKovcDEg==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/panva" + } + }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -8628,9 +9117,9 @@ "license": "MIT" }, "node_modules/js-yaml": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.2.0.tgz", - "integrity": "sha512-ePWsvanv0DWuDRsW8dnt+R4jQ31SCRCQ7hhNcPXZPsoBZiemuZNYGf7adZdqX2D86j6rvKp3RpCxVTSb8WQlOw==", + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.3.2.tgz", + "integrity": "sha512-SFNOvSJ+Dgf/9An904Yx+CgSlIPCkIpao4qo51lpee25TIRejdH3rhR4EZMGoNx3/TP3O+wzWuiTFl4sqbltzA==", "funding": [ { "type": "github", @@ -8692,31 +9181,16 @@ } }, "node_modules/json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "dev": true, + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", "license": "MIT" }, - "node_modules/json-stable-stringify": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.3.0.tgz", - "integrity": "sha512-qtYiSSFlwot9XHtF9bD9c7rwKjr+RecWT//ZnPvSmEjpV5mmPOCN4j8UjY5hbjNkOwZ/jQv3J6R1/pL7RwgMsg==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "call-bound": "^1.0.4", - "isarray": "^2.0.5", - "jsonify": "^0.0.1", - "object-keys": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } + "node_modules/json-schema-typed": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/json-schema-typed/-/json-schema-typed-8.0.2.tgz", + "integrity": "sha512-fQhoXdcvc3V28x7C7BMs4P5+kNlgUURe2jmUT1T//oBRMDrqy1QPelJimwZGo7Hg9VPV3EQV5Bnq4hbFy2vetA==", + "license": "BSD-2-Clause" }, "node_modules/json-stable-stringify-without-jsonify": { "version": "1.0.1", @@ -8725,13 +9199,6 @@ "dev": true, "license": "MIT" }, - "node_modules/json-stable-stringify/node_modules/isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "dev": true, - "license": "MIT" - }, "node_modules/json-stringify-safe": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", @@ -8765,14 +9232,17 @@ "graceful-fs": "^4.1.6" } }, - "node_modules/jsonify": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.1.tgz", - "integrity": "sha512-2/Ki0GcmuqSrgFyelQq9M05y7PS0mEwuIzrf3f1fPqkVDVRvZrPZtVSMHxdgo8Aq0sxAOb/cr2aqqA3LeWHVPg==", - "dev": true, - "license": "Public Domain", - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node_modules/jszip": { + "version": "3.10.2", + "resolved": "https://registry.npmjs.org/jszip/-/jszip-3.10.2.tgz", + "integrity": "sha512-3l+rb15IOWtUhU0H5MFqES/T6Kh7abYwjosBey/vD6hDt8zoEffkSC5Ws5SGtgVw3gBx2NEbhTeSW1+kWkpyTQ==", + "license": "(MIT OR GPL-3.0-or-later)", + "optional": true, + "dependencies": { + "lie": "~3.3.0", + "pako": "~1.0.2", + "readable-stream": "~2.3.6", + "setimmediate": "^1.0.5" } }, "node_modules/jwa": { @@ -8806,16 +9276,6 @@ "json-buffer": "3.0.1" } }, - "node_modules/klaw-sync": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/klaw-sync/-/klaw-sync-6.0.0.tgz", - "integrity": "sha512-nIeuVSzdCCs6TDPTqI8w1Yre34sSq7AkZ4B3sfOBbI2CgVSB4Du4aLQijFU2+lhAFCwt9+42Hel6lQNIv6AntQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "graceful-fs": "^4.1.11" - } - }, "node_modules/lazy-val": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/lazy-val/-/lazy-val-1.0.5.tgz", @@ -8836,6 +9296,289 @@ "node": ">= 0.8.0" } }, + "node_modules/lie": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/lie/-/lie-3.3.0.tgz", + "integrity": "sha512-UaiMJzeWRlEujzAuw5LokY1L5ecNQYZKfmyZ9L7wDHb/p5etKaxXhohBcrw0EYby+G/NA52vRSN4N39dxHAIwQ==", + "license": "MIT", + "optional": true, + "dependencies": { + "immediate": "~3.0.5" + } + }, + "node_modules/lightningcss": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.33.0.tgz", + "integrity": "sha512-WkUDrojuJs0xkgGf2udWxa3yGBRxPtxUkB79i6aCZLRgc7PM8fZe9TosfPDcvEpQZbuFASnHYmRLBLUbmLOIIA==", + "dev": true, + "license": "MPL-2.0", + "dependencies": { + "detect-libc": "^2.0.3" + }, + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + }, + "optionalDependencies": { + "lightningcss-android-arm64": "1.33.0", + "lightningcss-darwin-arm64": "1.33.0", + "lightningcss-darwin-x64": "1.33.0", + "lightningcss-freebsd-x64": "1.33.0", + "lightningcss-linux-arm-gnueabihf": "1.33.0", + "lightningcss-linux-arm64-gnu": "1.33.0", + "lightningcss-linux-arm64-musl": "1.33.0", + "lightningcss-linux-x64-gnu": "1.33.0", + "lightningcss-linux-x64-musl": "1.33.0", + "lightningcss-win32-arm64-msvc": "1.33.0", + "lightningcss-win32-x64-msvc": "1.33.0" + } + }, + "node_modules/lightningcss-android-arm64": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-android-arm64/-/lightningcss-android-arm64-1.33.0.tgz", + "integrity": "sha512-gEpRTalKdosp4Bb8qWtc2iOgE5SeIHlpS1up9bFq2wAyYhl1UdTObYiHe98zEM9SQvSoqQZ1IQD0JNpg3Ml5pg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-darwin-arm64": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.33.0.tgz", + "integrity": "sha512-Sciaz8eenNTKn9b3t7+xr0ipTp9YxKQY4npwQ3mrRuL0BAVHBLyZxofhaKBAVtzmtRZ/zTyo0/to4B1uWG/Djg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-darwin-x64": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.33.0.tgz", + "integrity": "sha512-Z5UPAxzrjlWNNyGy6i65cJzzvgJ5D3T6wMvs+gWpY9d7qRhANrxqAp6LhxIgZhWEw18RfJTGcRxjuLIBr+m8XQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-freebsd-x64": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-freebsd-x64/-/lightningcss-freebsd-x64-1.33.0.tgz", + "integrity": "sha512-QQM/Ti/hQajJwCY+RiWuCZ9sdtI/XQk7nDK5vC8kkdwixezOlDgvDx7+RT+QjK6FcFT4MpsuoBnHIo/O3StRRg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-arm-gnueabihf": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.33.0.tgz", + "integrity": "sha512-N7FVBe6iS24MlM6R/4RBTxGhQheZGs7tiQ9U32UtF75NzP5Q7xWPRqLBCKxlRQRk3rY1jCIPLzx7WzOhuUIRLQ==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-arm64-gnu": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.33.0.tgz", + "integrity": "sha512-j2v/itmy4HlNxlc6voKXYgBqNi0Ng2LShg4z7GufpEgs05P+2suBVyi9I6YHq5uoVFx9ETin3eCEhLVyXGQnKg==", + "cpu": [ + "arm64" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-arm64-musl": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.33.0.tgz", + "integrity": "sha512-yiO5ROMuYQgXbC60yjZU5CYSFZGKXL0HFATXt9mHJn1+zW55oCtMI9NfcVhYLMFDL7gV7oBPon/EmMMGg2OvtQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "libc": [ + "musl" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-x64-gnu": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.33.0.tgz", + "integrity": "sha512-ar+Ju7LmcN0Jo4FpL4hpFybwNG9/3A/Br5KW2n2jyODg3MEZXaDYADdemoNS+BDNfMgKvylJLj4S5tyRActuAg==", + "cpu": [ + "x64" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-x64-musl": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.33.0.tgz", + "integrity": "sha512-RYiYbkokw0trfKqqzfF55lginwEPrD3OJDfTuJzFs1MK6iFnDenaz1fqLLtX4ITG3OktJQXOeTaw1awrBAlZPw==", + "cpu": [ + "x64" + ], + "dev": true, + "libc": [ + "musl" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-win32-arm64-msvc": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-win32-arm64-msvc/-/lightningcss-win32-arm64-msvc-1.33.0.tgz", + "integrity": "sha512-1K+MPfLSFVpphzpdbfkhlWk6wBrTObBzS2T6db10PNOZgR9GoVsAWzwNyuhUYYbTp23j+4RrncfujZ4uAzXvwA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-win32-x64-msvc": { + "version": "1.33.0", + "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.33.0.tgz", + "integrity": "sha512-OlEICDx/Xl0FqSp4bry8zFnCvGpig3Gl4gCquvYwHuqJKEC1+n9NgDniFvqHGmMv1ZkqDJrDqKKSykTDX+ehuA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, "node_modules/linkedom": { "version": "0.16.11", "resolved": "https://registry.npmjs.org/linkedom/-/linkedom-0.16.11.tgz", @@ -8885,13 +9628,6 @@ "deprecated": "This package is deprecated. Use require('node:util').isDeepStrictEqual instead.", "license": "MIT" }, - "node_modules/lodash.merge": { - "version": "4.6.2", - "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", - "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", - "dev": true, - "license": "MIT" - }, "node_modules/long": { "version": "5.3.2", "resolved": "https://registry.npmjs.org/long/-/long-5.3.2.tgz", @@ -8908,6 +9644,15 @@ "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/lovely-mermaid": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/lovely-mermaid/-/lovely-mermaid-0.3.3.tgz", + "integrity": "sha512-EMLJS934qwt2MLO/a5o+T/89HGbuXZPwmCpHIhHO+DVrm+y5tHlEHgpZzlC2o4yW/rFPHRFO9xSMafzqH4wH5A==", + "license": "Apache-2.0", + "engines": { + "node": ">=18" + } + }, "node_modules/lowercase-keys": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-2.0.0.tgz", @@ -8934,6 +9679,16 @@ "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/lowlight/node_modules/highlight.js": { + "version": "11.11.2", + "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-11.11.2.tgz", + "integrity": "sha512-oaXMACAU0kzOMXBjWpNcX+vlwSBCIAiZ9BHa7gA15NOTtT2L/l8OSZDuqS2XppOhZBPJ7hm4o8ep2kyuip2uEQ==", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=12.0.0" + } + }, "node_modules/lru-cache": { "version": "5.1.1", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", @@ -8945,29 +9700,35 @@ } }, "node_modules/lucide-react": { - "version": "0.468.0", - "resolved": "https://registry.npmjs.org/lucide-react/-/lucide-react-0.468.0.tgz", - "integrity": "sha512-6koYRhnM2N0GGZIdXzSeiNwguv1gt/FAjZOiPl76roBi3xKEXa4WmfpxgQwTTL4KipXjefrnf3oV4IsYhi4JFA==", + "version": "1.77.0", + "resolved": "https://registry.npmjs.org/lucide-react/-/lucide-react-1.77.0.tgz", + "integrity": "sha512-VS6sOi8ZUH1qm6swBL/tpI4xAhB6pFTdHvw3pfCJD+DaTJwpyynVzfOS6mdyMZ+OCdY/GMSQbqinOMOPbNSrQA==", "dev": true, "license": "ISC", "peerDependencies": { - "react": "^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0-rc" + "@types/react": "*", + "react": "^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } } }, "node_modules/magic-string": { - "version": "0.30.21", - "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.21.tgz", - "integrity": "sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==", + "version": "1.4.5", + "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-1.4.5.tgz", + "integrity": "sha512-oLLC2+YvQUfAa+vxoufE/yc1icb87M9iXIRqAoR/2EhE/8cb3SF/+Gi0c2By1B+5Vz2e2vQtUvHiu1+63Znh+w==", "dev": true, "license": "MIT", "dependencies": { - "@jridgewell/sourcemap-codec": "^1.5.5" + "@jridgewell/sourcemap-codec": "^1.6.0" } }, "node_modules/markdown-table": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/markdown-table/-/markdown-table-3.0.4.tgz", - "integrity": "sha512-wiYz4+JrLyb/DqW2hkFJxP7Vd7JuTDm77fvbM8VfEQdmSMqcImWeeRbHwZjBjIFki/VaMK2BhFi7oUUZeM5bqw==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/markdown-table/-/markdown-table-3.1.0.tgz", + "integrity": "sha512-xpeSCdM+B+6P3ncfgaB7FoDbtJ30xAe6Z18TGT7AgXJsHqCElCICZovQqdRMm7kHgpTyYv36EupqewoFFSB8vw==", "license": "MIT", "funding": { "type": "github", @@ -8986,18 +9747,31 @@ "node": ">= 20" } }, + "node_modules/marked-cjk-friendly": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/marked-cjk-friendly/-/marked-cjk-friendly-0.1.2.tgz", + "integrity": "sha512-GUj8HjiEbur9yhgUo52FBgKizggF1QtT6gVdrYdWW6ZB4lVVjgS3EyyXPyfyRD0V4ghGRPlO7MO80rgSWbm0eA==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "marked": ">=15.0.0" + } + }, "node_modules/matcher": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/matcher/-/matcher-3.0.0.tgz", - "integrity": "sha512-OkeDaAZ/bQCxeFAozM55PKcKU0yJMPGifLwV4Qgjitu+5MoAfSQN4lsLJeXZ1b8w0x+/Emda6MZgXS1jvsapng==", - "dev": true, + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/matcher/-/matcher-4.0.0.tgz", + "integrity": "sha512-S6x5wmcDmsDRRU/c2dkccDwQPXoFczc5+HpQ2lON8pnvHlnvHAHj5WlLVvw6n6vNyHuVugYrFohYxbS+pvFpKQ==", "license": "MIT", - "optional": true, "dependencies": { "escape-string-regexp": "^4.0.0" }, "engines": { "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/math-intrinsics": { @@ -9009,16 +9783,26 @@ "node": ">= 0.4" } }, + "node_modules/mathml-to-latex": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/mathml-to-latex/-/mathml-to-latex-1.8.0.tgz", + "integrity": "sha512-gQ0uK3zqB8HwlfaXJkEL5rgaZNbKUiBMmBP/B/W+b+t6KcseLSuYb1b0BjLgS9ZiQa24ePkqTX8/6FaQuDL7wQ==", + "license": "MIT", + "optional": true, + "dependencies": { + "@xmldom/xmldom": "^0.9.10" + } + }, "node_modules/mdast-util-find-and-replace": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/mdast-util-find-and-replace/-/mdast-util-find-and-replace-3.0.2.tgz", - "integrity": "sha512-Tmd1Vg/m3Xz43afeNxDIhWRtFZgM2VLyaf4vSTYwudTyeuTneoL3qtWMA5jeLyz/O1vDJmmV4QuScFCA2tBPwg==", + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/mdast-util-find-and-replace/-/mdast-util-find-and-replace-3.0.5.tgz", + "integrity": "sha512-of3wZLEBWpK8mSYy8wmKnwyxfUKjhCkXxGLz45DVBqfcahTP37LscCK+0oAZh+ReZ5OunPDkB2zdGMIxrojLhw==", "license": "MIT", "dependencies": { "@types/mdast": "^4.0.0", "escape-string-regexp": "^5.0.0", "unist-util-is": "^6.0.0", - "unist-util-visit-parents": "^6.0.0" + "unist-util-visit-parents": "^6.1.0" }, "funding": { "type": "opencollective", @@ -9038,9 +9822,9 @@ } }, "node_modules/mdast-util-from-markdown": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/mdast-util-from-markdown/-/mdast-util-from-markdown-2.0.3.tgz", - "integrity": "sha512-W4mAWTvSlKvf8L6J+VN9yLSqQ9AOAAvHuoDAmPkz4dHf553m5gVj2ejadHJhoJmcmxEnOv6Pa8XJhpxE93kb8Q==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mdast-util-from-markdown/-/mdast-util-from-markdown-2.1.0.tgz", + "integrity": "sha512-KRLgmPaP2H1ul2bpoJkOS+9pAcDAAj9Nu1mqLnh8NLeJG5tlvj42TH80PIGBpROWlRXLk0lDrWNuZCFy/tsB4A==", "license": "MIT", "dependencies": { "@types/mdast": "^4.0.0", @@ -9081,9 +9865,9 @@ } }, "node_modules/mdast-util-gfm-autolink-literal": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-autolink-literal/-/mdast-util-gfm-autolink-literal-2.0.1.tgz", - "integrity": "sha512-5HVP2MKaP6L+G6YaxPNjuL0BPrq9orG3TsrZ9YXbA3vDw/ACI4MEsnoDpn6ZNm7GnZgtAcONJyPhOP8tNJQavQ==", + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/mdast-util-gfm-autolink-literal/-/mdast-util-gfm-autolink-literal-2.1.2.tgz", + "integrity": "sha512-rAlbZBGZfv2YRr6lSFGHTN305KkNawOYRRlbldFyPHnTlHJZwlGdzVwyIDvr3fxbhRbmJOSZc06c8H5Fgfu8Ng==", "license": "MIT", "dependencies": { "@types/mdast": "^4.0.0", @@ -9115,9 +9899,9 @@ } }, "node_modules/mdast-util-gfm-strikethrough": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-strikethrough/-/mdast-util-gfm-strikethrough-2.0.0.tgz", - "integrity": "sha512-mKKb915TF+OC5ptj5bJ7WFRPdYtuHv0yTRxK2tJvi+BDqbkiG7h7u/9SI89nRAYcmap2xHQL9D+QG/6wSrTtXg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/mdast-util-gfm-strikethrough/-/mdast-util-gfm-strikethrough-2.0.1.tgz", + "integrity": "sha512-OuJHqvr455pwu2OaOrir7dbzqs4jlWKOtlu9L6GjcIjjQwNyw02VntQsr/Ek6/A13vgnXfUhBekWRUP1OkNivw==", "license": "MIT", "dependencies": { "@types/mdast": "^4.0.0", @@ -9130,16 +9914,18 @@ } }, "node_modules/mdast-util-gfm-table": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-table/-/mdast-util-gfm-table-2.0.0.tgz", - "integrity": "sha512-78UEvebzz/rJIxLvE7ZtDd/vIQ0RHv+3Mh5DR96p7cS7HsBhYIICDBCu8csTNWNO6tBWfqXPWekRuj2FNOGOZg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/mdast-util-gfm-table/-/mdast-util-gfm-table-2.0.1.tgz", + "integrity": "sha512-fiIjPrAy4kz68/eFbPHhsiWDGHhqUSVoU1XsfLM5DsEPXw7MxgiVVyulUggFRckVWeT1KXQXkg5vm3kv4oMSOA==", "license": "MIT", "dependencies": { "@types/mdast": "^4.0.0", "devlop": "^1.0.0", "markdown-table": "^3.0.0", "mdast-util-from-markdown": "^2.0.0", - "mdast-util-to-markdown": "^2.0.0" + "mdast-util-to-markdown": "^2.0.0", + "mdast-util-to-string": "^4.0.0", + "unist-util-visit": "^5.0.0" }, "funding": { "type": "opencollective", @@ -9147,9 +9933,9 @@ } }, "node_modules/mdast-util-gfm-task-list-item": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdast-util-gfm-task-list-item/-/mdast-util-gfm-task-list-item-2.0.0.tgz", - "integrity": "sha512-IrtvNvjxC1o06taBAVJznEnkiHxLFTzgonUdy8hzFVeDun0uTjxxrRGVaNFqkU1wJR3RBPEfsxmU6jDWPofrTQ==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/mdast-util-gfm-task-list-item/-/mdast-util-gfm-task-list-item-2.0.1.tgz", + "integrity": "sha512-jXVO1hvB2hs82g1esi7I9nIJDqiijbQLIyH2jDUb5s7jIAZMr/79h0VHSq7XHKTqpLARRm+DDNjduB7S9+6XZA==", "license": "MIT", "dependencies": { "@types/mdast": "^4.0.0", @@ -9198,9 +9984,9 @@ } }, "node_modules/mdast-util-mdx-jsx": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/mdast-util-mdx-jsx/-/mdast-util-mdx-jsx-3.2.0.tgz", - "integrity": "sha512-lj/z8v0r6ZtsN/cGNNtemmmfoLAFZnjMbNyLzBafjzikOM+glrjNHPlf6lQDOTccj9n5b0PPihEBbhneMyGs1Q==", + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/mdast-util-mdx-jsx/-/mdast-util-mdx-jsx-3.2.2.tgz", + "integrity": "sha512-/0FHaZMv2fSjIL3z/NYmXnQTSdzYyamPpI1BXpSCngTUqpSvMNIlERa26ABz+Z6UFQbrh3I5Yhzp448WZsPfMA==", "license": "MIT", "dependencies": { "@types/estree-jsx": "^1.0.0", @@ -9254,9 +10040,9 @@ } }, "node_modules/mdast-util-to-markdown": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/mdast-util-to-markdown/-/mdast-util-to-markdown-2.1.2.tgz", - "integrity": "sha512-xj68wMTvGXVOKonmog6LwyJKrYXZPvlwabaryTjLh9LuvovB/KAH+kvi8Gjj+7rJjsFi23nkUxRQv1KqSroMqA==", + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/mdast-util-to-markdown/-/mdast-util-to-markdown-2.2.4.tgz", + "integrity": "sha512-aCsogoZ2Oz1EItAlC12A+/uGuzp+CWlDU0xZ3o5jbJaepLsOu2tlxpvHslnX5dRhspD1gxNVkBtYG0yMiIpXoQ==", "license": "MIT", "dependencies": { "@types/mdast": "^4.0.0", @@ -9264,8 +10050,10 @@ "longest-streak": "^3.0.0", "mdast-util-phrasing": "^4.0.0", "mdast-util-to-string": "^4.0.0", + "micromark-util-character": "^2.0.0", "micromark-util-classify-character": "^2.0.0", "micromark-util-decode-string": "^2.0.0", + "micromark-util-html-tag-name": "^2.0.0", "unist-util-visit": "^5.0.0", "zwitch": "^2.0.0" }, @@ -9287,10 +10075,35 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/media-typer": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-1.1.1.tgz", + "integrity": "sha512-yz3xRaG20c6/BOzvYoDaGtPmGscs7YivItZEEqe6GbwNfHuxu9YNmvnEkMzKldAGY4/80pRcQRZSEnhquk9XuQ==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/merge-descriptors": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-2.0.0.tgz", + "integrity": "sha512-Snk314V5ayFLhp3fkUREub6WtjBfPdCPY1Ln8/8munuLuiYhsABgBVWsozAG+MWMbVEvcdcpbi9R7ww22l9Q3g==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/micromark": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/micromark/-/micromark-4.0.2.tgz", - "integrity": "sha512-zpe98Q6kvavpCr1NPVSCMebCKfD7CA2NqZ+rykeNhONIJBpc1tFKt9hucLGwha3jNTNI8lHpctWJWoimVF4PfA==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/micromark/-/micromark-4.0.3.tgz", + "integrity": "sha512-oGYfQzHSG5dOMovQcJ3fyTmZlWAWpi0XA0sJwJs+i6OT88o1+Jtw/8z0CmdowSLxGhhFK89rQ/oXph/wN02PNw==", "funding": [ { "type": "GitHub Sponsors", @@ -9313,6 +10126,7 @@ "micromark-util-chunked": "^2.0.0", "micromark-util-combine-extensions": "^2.0.0", "micromark-util-decode-numeric-character-reference": "^2.0.0", + "micromark-util-edit-map": "^1.0.0", "micromark-util-encode": "^2.0.0", "micromark-util-normalize-identifier": "^2.0.0", "micromark-util-resolve-all": "^2.0.0", @@ -9323,9 +10137,9 @@ } }, "node_modules/micromark-core-commonmark": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/micromark-core-commonmark/-/micromark-core-commonmark-2.0.3.tgz", - "integrity": "sha512-RDBrHEMSxVFLg6xvnXmb1Ayr2WzLAWjeSATAoxwKYJV94TeNavgoIdA0a9ytzDSVzBy2YKFK+emCPOEibLeCrg==", + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/micromark-core-commonmark/-/micromark-core-commonmark-2.0.4.tgz", + "integrity": "sha512-wxEeE8v8XVvOrxn1TZj74qYhAtTQsSqufHVS3uNVyT1MupXxhyaHk8/9xDNPh9BmL77QNDgWTkZ3RsYHB2ry7w==", "funding": [ { "type": "GitHub Sponsors", @@ -9342,18 +10156,19 @@ "devlop": "^1.0.0", "micromark-factory-destination": "^2.0.0", "micromark-factory-label": "^2.0.0", - "micromark-factory-space": "^2.0.0", + "micromark-factory-space": "^2.1.0", "micromark-factory-title": "^2.0.0", "micromark-factory-whitespace": "^2.0.0", "micromark-util-character": "^2.0.0", "micromark-util-chunked": "^2.0.0", "micromark-util-classify-character": "^2.0.0", + "micromark-util-edit-map": "^1.0.0", "micromark-util-html-tag-name": "^2.0.0", "micromark-util-normalize-identifier": "^2.0.0", "micromark-util-resolve-all": "^2.0.0", "micromark-util-subtokenize": "^2.0.0", "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0" + "micromark-util-types": "^2.0.3" } }, "node_modules/micromark-extension-gfm": { @@ -9431,9 +10246,9 @@ } }, "node_modules/micromark-extension-gfm-table": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/micromark-extension-gfm-table/-/micromark-extension-gfm-table-2.1.1.tgz", - "integrity": "sha512-t2OU/dXXioARrC6yWfJ4hqB7rct14e8f7m0cbI5hUmDyyIlwv5vEtooptH8INkbLzOatzKuVbQmAYcbWoyz6Dg==", + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/micromark-extension-gfm-table/-/micromark-extension-gfm-table-2.1.2.tgz", + "integrity": "sha512-pRzm4kDTu0MjlmBkxmS9yYhw60nncfcEwu9NNdPFSQEFXS95ZKyIIyTSHu/o3ReBUrLKYEq+7YaXCRn/bPB4MA==", "license": "MIT", "dependencies": { "devlop": "^1.0.0", @@ -9650,9 +10465,9 @@ } }, "node_modules/micromark-factory-space": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-factory-space/-/micromark-factory-space-2.0.1.tgz", - "integrity": "sha512-zRkxjtBxxLd2Sc0d+fbnEunsTj46SWXgXciZmHq0kDYGnck/ZSGj9/wULTV95uoeYiK5hRXP2mJ98Uo4cq/LQg==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/micromark-factory-space/-/micromark-factory-space-2.1.0.tgz", + "integrity": "sha512-fS8hnLIjnjvdQIj39Geug8wWsR0HrYZ43KShKxNfwT7t2LOHo/LbWZEzEaSOjwtjdCsjoE6syHhonEzW0zv0+Q==", "funding": [ { "type": "GitHub Sponsors", @@ -9834,126 +10649,10 @@ "micromark-util-symbol": "^2.0.0" } }, - "node_modules/micromark-util-encode": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-encode/-/micromark-util-encode-2.0.1.tgz", - "integrity": "sha512-c3cVx2y4KqUnwopcO9b/SCdo2O67LwJJ/UyqGfbigahfegL9myoEFoDYZgkT7f36T0bLrM9hZTAaAyH+PCAXjw==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT" - }, - "node_modules/micromark-util-events-to-acorn": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/micromark-util-events-to-acorn/-/micromark-util-events-to-acorn-2.0.3.tgz", - "integrity": "sha512-jmsiEIiZ1n7X1Rr5k8wVExBQCg5jy4UXVADItHmNk1zkwEVhBuIUKRu3fqv+hs4nxLISi2DQGlqIOGiFxgbfHg==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "@types/estree": "^1.0.0", - "@types/unist": "^3.0.0", - "devlop": "^1.0.0", - "estree-util-visit": "^2.0.0", - "micromark-util-symbol": "^2.0.0", - "micromark-util-types": "^2.0.0", - "vfile-message": "^4.0.0" - } - }, - "node_modules/micromark-util-html-tag-name": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-html-tag-name/-/micromark-util-html-tag-name-2.0.1.tgz", - "integrity": "sha512-2cNEiYDhCWKI+Gs9T0Tiysk136SnR13hhO8yW6BGNyhOC4qYFnwF1nKfD3HFAIXA5c45RrIG1ub11GiXeYd1xA==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT" - }, - "node_modules/micromark-util-normalize-identifier": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-normalize-identifier/-/micromark-util-normalize-identifier-2.0.1.tgz", - "integrity": "sha512-sxPqmo70LyARJs0w2UclACPUUEqltCkJ6PhKdMIDuJ3gSf/Q+/GIe3WKl0Ijb/GyH9lOpUkRAO2wp0GVkLvS9Q==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-symbol": "^2.0.0" - } - }, - "node_modules/micromark-util-resolve-all": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-resolve-all/-/micromark-util-resolve-all-2.0.1.tgz", - "integrity": "sha512-VdQyxFWFT2/FGJgwQnJYbe1jjQoNTS4RjglmSjTUlpUMa95Htx9NHeYW4rGDJzbjvCsl9eLjMQwGeElsqmzcHg==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-types": "^2.0.0" - } - }, - "node_modules/micromark-util-sanitize-uri": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-sanitize-uri/-/micromark-util-sanitize-uri-2.0.1.tgz", - "integrity": "sha512-9N9IomZ/YuGGZZmQec1MbgxtlgougxTodVwDzzEouPKo3qFWvymFHWcnDi2vzV1ff6kas9ucW+o3yzJK9YB1AQ==", - "funding": [ - { - "type": "GitHub Sponsors", - "url": "https://github.com/sponsors/unifiedjs" - }, - { - "type": "OpenCollective", - "url": "https://opencollective.com/unified" - } - ], - "license": "MIT", - "dependencies": { - "micromark-util-character": "^2.0.0", - "micromark-util-encode": "^2.0.0", - "micromark-util-symbol": "^2.0.0" - } - }, - "node_modules/micromark-util-subtokenize": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/micromark-util-subtokenize/-/micromark-util-subtokenize-2.1.0.tgz", - "integrity": "sha512-XQLu552iSctvnEcgXw6+Sx75GflAPNED1qx7eBJ+wydBb2KCbRZe+NwvIEEMM83uml1+2WSXpBAcp9IUCgCYWA==", + "node_modules/micromark-util-edit-map": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/micromark-util-edit-map/-/micromark-util-edit-map-1.0.0.tgz", + "integrity": "sha512-Pa2ljlsEL6sVwFaYeyrOLSYbQt73JvGbPOYFq+9AElXiSnfI5Q4465RRZ1sHv7lDjDOnGRDDaqPXqClqWK/q1Q==", "funding": [ { "type": "GitHub Sponsors", @@ -9966,16 +10665,13 @@ ], "license": "MIT", "dependencies": { - "devlop": "^1.0.0", - "micromark-util-chunked": "^2.0.0", - "micromark-util-symbol": "^2.0.0", "micromark-util-types": "^2.0.0" } }, - "node_modules/micromark-util-symbol": { + "node_modules/micromark-util-encode": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/micromark-util-symbol/-/micromark-util-symbol-2.0.1.tgz", - "integrity": "sha512-vs5t8Apaud9N28kgCrRUdEed4UJ+wWNvicHLPxCa9ENlYuAY31M0ETy5y1vA33YoNPDFTghEbnh6efaE8h4x0Q==", + "resolved": "https://registry.npmjs.org/micromark-util-encode/-/micromark-util-encode-2.0.1.tgz", + "integrity": "sha512-c3cVx2y4KqUnwopcO9b/SCdo2O67LwJJ/UyqGfbigahfegL9myoEFoDYZgkT7f36T0bLrM9hZTAaAyH+PCAXjw==", "funding": [ { "type": "GitHub Sponsors", @@ -9988,10 +10684,10 @@ ], "license": "MIT" }, - "node_modules/micromark-util-types": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/micromark-util-types/-/micromark-util-types-2.0.2.tgz", - "integrity": "sha512-Yw0ECSpJoViF1qTU4DC6NwtC4aWGt1EkzaQB8KPPyCRR8z9TWeV0HbEFGTO+ZY1wB22zmxnJqhPyTpOVCpeHTA==", + "node_modules/micromark-util-events-to-acorn": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/micromark-util-events-to-acorn/-/micromark-util-events-to-acorn-2.0.3.tgz", + "integrity": "sha512-jmsiEIiZ1n7X1Rr5k8wVExBQCg5jy4UXVADItHmNk1zkwEVhBuIUKRu3fqv+hs4nxLISi2DQGlqIOGiFxgbfHg==", "funding": [ { "type": "GitHub Sponsors", @@ -10002,3002 +10698,2399 @@ "url": "https://opencollective.com/unified" } ], - "license": "MIT" - }, - "node_modules/micromatch": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", - "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", - "dev": true, - "license": "MIT", - "dependencies": { - "braces": "^3.0.3", - "picomatch": "^2.3.1" - }, - "engines": { - "node": ">=8.6" - } - }, - "node_modules/micromatch/node_modules/picomatch": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.2.tgz", - "integrity": "sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8.6" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, - "node_modules/mime": { - "version": "2.6.0", - "resolved": "https://registry.npmjs.org/mime/-/mime-2.6.0.tgz", - "integrity": "sha512-USPkMeET31rOMiarsBNIHZKLGgvKc/LrjofAnBlOttf5ajRvqiRA8QsenbcooctK6d6Ts6aqZXBA+XbkKthiQg==", - "dev": true, - "license": "MIT", - "bin": { - "mime": "cli.js" - }, - "engines": { - "node": ">=4.0.0" - } - }, - "node_modules/mime-db": { - "version": "1.52.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", - "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mime-types": { - "version": "2.1.35", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", - "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", - "dev": true, - "license": "MIT", - "dependencies": { - "mime-db": "1.52.0" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mimic-response": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-1.0.1.tgz", - "integrity": "sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=4" - } - }, - "node_modules/minimatch": { - "version": "10.2.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.5.tgz", - "integrity": "sha512-MULkVLfKGYDFYejP07QOurDLLQpcjk7Fw+7jXS2R2czRQzR56yHRveU5NDJEOviH+hETZKSkIk5c+T23GjFUMg==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "brace-expansion": "^5.0.5" - }, - "engines": { - "node": "18 || 20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/minimist": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", - "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", - "dev": true, - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/minipass": { - "version": "7.1.3", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.3.tgz", - "integrity": "sha512-tEBHqDnIoM/1rXME1zgka9g6Q2lcoCkxHLuc7ODJ5BxbP5d4c2Z5cGgtXAku59200Cx7diuHTOYfSBD8n6mm8A==", - "dev": true, - "license": "BlueOak-1.0.0", - "engines": { - "node": ">=16 || 14 >=14.17" - } - }, - "node_modules/minizlib": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-3.1.0.tgz", - "integrity": "sha512-KZxYo1BUkWD2TVFLr0MQoM8vUUigWD3LlD83a/75BqC+4qE0Hb1Vo5v1FgcfaNXvfXzr+5EhQ6ing/CaBijTlw==", - "dev": true, - "license": "MIT", - "dependencies": { - "minipass": "^7.1.2" - }, - "engines": { - "node": ">= 18" - } - }, - "node_modules/mkdirp": { - "version": "0.5.6", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz", - "integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==", - "dev": true, - "license": "MIT", - "peer": true, - "dependencies": { - "minimist": "^1.2.6" - }, - "bin": { - "mkdirp": "bin/cmd.js" - } - }, - "node_modules/ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "license": "MIT" - }, - "node_modules/nanoid": { - "version": "3.3.12", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.12.tgz", - "integrity": "sha512-ZB9RH/39qpq5Vu6Y+NmUaFhQR6pp+M2Xt76XBnEwDaGcVAqhlvxrl3B2bKS5D3NH3QR76v3aSrKaF/Kiy7lEtQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "MIT", - "bin": { - "nanoid": "bin/nanoid.cjs" - }, - "engines": { - "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" - } - }, - "node_modules/natural-compare": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", - "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", - "dev": true, - "license": "MIT" - }, - "node_modules/node-abi": { - "version": "4.33.0", - "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-4.33.0.tgz", - "integrity": "sha512-vLBWCKb+7LWsX+TbfzWOkw0W81m377tyx3hOweBTjO43CXZnRGS1/JPWs20fr0PgZyDXk6ROYrylsEycK8raDA==", - "dev": true, - "license": "MIT", - "dependencies": { - "semver": "^7.6.3" - }, - "engines": { - "node": ">=22.12.0" - } - }, - "node_modules/node-api-version": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/node-api-version/-/node-api-version-0.2.1.tgz", - "integrity": "sha512-2xP/IGGMmmSQpI1+O/k72jF/ykvZ89JeuKX3TLJAYPDVLUalrshrLHkeVcCCZqG/eEa635cr8IBYzgnDvM2O8Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "semver": "^7.3.5" - } - }, - "node_modules/node-domexception": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/node-domexception/-/node-domexception-1.0.0.tgz", - "integrity": "sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ==", - "deprecated": "Use your platform's native DOMException instead", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/jimmywarting" - }, - { - "type": "github", - "url": "https://paypal.me/jimmywarting" - } - ], - "license": "MIT", - "engines": { - "node": ">=10.5.0" - } - }, - "node_modules/node-fetch": { - "version": "3.3.2", - "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-3.3.2.tgz", - "integrity": "sha512-dRB78srN/l6gqWulah9SrxeYnxeddIG30+GOqK/9OlLVyLg3HPnr6SqOWTWOXKRwC2eGYCkZ59NNuSgvSrpgOA==", - "license": "MIT", - "dependencies": { - "data-uri-to-buffer": "^4.0.0", - "fetch-blob": "^3.1.4", - "formdata-polyfill": "^4.0.10" - }, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/node-fetch" - } - }, - "node_modules/node-gyp": { - "version": "12.4.0", - "resolved": "https://registry.npmjs.org/node-gyp/-/node-gyp-12.4.0.tgz", - "integrity": "sha512-OMcPNvqTCFUnNaBlmdgq+lfNqY7gTiSmNRDjY3uAXRyudeKZEZxu3CLtjMQrx4zZxCX2b/mpNqTtwuCJgXhHkw==", - "dev": true, - "license": "MIT", - "dependencies": { - "env-paths": "^2.2.0", - "exponential-backoff": "^3.1.1", - "graceful-fs": "^4.2.6", - "nopt": "^9.0.0", - "proc-log": "^6.0.0", - "semver": "^7.3.5", - "tar": "^7.5.4", - "tinyglobby": "^0.2.12", - "undici": "^6.25.0", - "which": "^6.0.0" - }, - "bin": { - "node-gyp": "bin/node-gyp.js" - }, - "engines": { - "node": "^20.17.0 || >=22.9.0" - } - }, - "node_modules/node-gyp/node_modules/env-paths": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", - "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/node-gyp/node_modules/isexe": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-4.0.0.tgz", - "integrity": "sha512-FFUtZMpoZ8RqHS3XeXEmHWLA4thH+ZxCv2lOiPIn1Xc7CxrqhWzNSDzD+/chS/zbYezmiwWLdQC09JdQKmthOw==", - "dev": true, - "license": "BlueOak-1.0.0", - "engines": { - "node": ">=20" - } - }, - "node_modules/node-gyp/node_modules/undici": { - "version": "6.27.0", - "resolved": "https://registry.npmjs.org/undici/-/undici-6.27.0.tgz", - "integrity": "sha512-YmfV3YnEDzXRC5lZ2jWtWWHKGUm1zIt8AhesR1tens+HTNv+YZlN/dp6G727LOvMJ8xjP9Be7Y2Sdr96LDm+pg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18.17" - } - }, - "node_modules/node-gyp/node_modules/which": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/which/-/which-6.0.1.tgz", - "integrity": "sha512-oGLe46MIrCRqX7ytPUf66EAYvdeMIZYn3WaocqqKZAxrBpkqHfL/qvTyJ/bTk5+AqHCjXmrv3CEWgy368zhRUg==", - "dev": true, - "license": "ISC", - "dependencies": { - "isexe": "^4.0.0" - }, - "bin": { - "node-which": "bin/which.js" - }, - "engines": { - "node": "^20.17.0 || >=22.9.0" - } - }, - "node_modules/node-int64": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", - "integrity": "sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==", - "dev": true, - "license": "MIT" - }, - "node_modules/node-releases": { - "version": "2.0.48", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.48.tgz", - "integrity": "sha512-1uz8041X6LoI6ZSdZacM9lVY28vuzDlSKitnpbSNK0RfKoIJkX29NBPVEFXhnuSuEOA9Ww0xnPJ+ILWbGAv8DA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - } - }, - "node_modules/nopt": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/nopt/-/nopt-9.0.0.tgz", - "integrity": "sha512-Zhq3a+yFKrYwSBluL4H9XP3m3y5uvQkB/09CwDruCiRmR/UJYnn9W4R48ry0uGC70aeTPKLynBtscP9efFFcPw==", - "dev": true, - "license": "ISC", - "dependencies": { - "abbrev": "^4.0.0" - }, - "bin": { - "nopt": "bin/nopt.js" - }, - "engines": { - "node": "^20.17.0 || >=22.9.0" - } - }, - "node_modules/normalize-url": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-6.1.0.tgz", - "integrity": "sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/nth-check": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.1.1.tgz", - "integrity": "sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==", - "license": "BSD-2-Clause", - "dependencies": { - "boolbase": "^1.0.0" - }, - "funding": { - "url": "https://github.com/fb55/nth-check?sponsor=1" - } - }, - "node_modules/object-inspect": { - "version": "1.13.4", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.4.tgz", - "integrity": "sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew==", - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/object-keys": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", - "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", - "license": "MIT", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/object.assign": { - "version": "4.1.7", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.7.tgz", - "integrity": "sha512-nK28WOo+QIjBkDduTINE4JkF/UJJKyf2EJxvJKfblDpyg0Q+pkOHNTL0Qwy6NP6FhE/EnzV73BxxqcJaXY9anw==", - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "call-bound": "^1.0.3", - "define-properties": "^1.2.1", - "es-object-atoms": "^1.0.0", - "has-symbols": "^1.1.0", - "object-keys": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/obug": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/obug/-/obug-2.1.3.tgz", - "integrity": "sha512-9miFgM2OFba7hB+pRgvtV84pYTBaoTHohvmIgiRt6dRIzbwEOIaNaP+dIlGs2fNFoB0SeISs0Jz5WFVRid6Xyg==", - "dev": true, - "funding": [ - "https://github.com/sponsors/sxzz", - "https://opencollective.com/debug" - ], - "license": "MIT", - "engines": { - "node": ">=12.20.0" - } - }, - "node_modules/once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", - "dev": true, - "license": "ISC", - "dependencies": { - "wrappy": "1" - } - }, - "node_modules/onnxruntime-common": { - "version": "1.30.0", - "resolved": "https://registry.npmjs.org/onnxruntime-common/-/onnxruntime-common-1.30.0.tgz", - "integrity": "sha512-7fdVWjAID1dVhH/G8qK3APARunV4VkBFoCQAP7qp4Wkab0mrorvmc+sqiT+mKXOzDqdjN5j+/Z9nb4gzNPWcyA==", - "license": "MIT" - }, - "node_modules/onnxruntime-node": { - "version": "1.30.0", - "resolved": "https://registry.npmjs.org/onnxruntime-node/-/onnxruntime-node-1.30.0.tgz", - "integrity": "sha512-twhs1C2C/BFkz1yc5OY0KIU2GUq6DURO7hD4bx5Q2Qy3nAMJwRXW8xU3NVczE29VA9lolLOYepoD8fjTGOfIqw==", - "hasInstallScript": true, - "license": "MIT", - "os": [ - "win32", - "darwin", - "linux" - ], - "dependencies": { - "adm-zip": "^0.6.0", - "global-agent": "^4.1.3", - "onnxruntime-common": "1.30.0" - } - }, - "node_modules/onnxruntime-node/node_modules/global-agent": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/global-agent/-/global-agent-4.1.3.tgz", - "integrity": "sha512-KUJEViiuFT3I97t+GYMikLPJS2Lfo/S2F+DQuBWzuzaMPnvt5yyZePzArx36fBzpGTxZjIpDbXLeySLgh+k76g==", - "license": "BSD-3-Clause", - "dependencies": { - "globalthis": "^1.0.2", - "matcher": "^4.0.0", - "semver": "^7.3.5", - "serialize-error": "^8.1.0" - }, - "engines": { - "node": ">=10.0" - } - }, - "node_modules/onnxruntime-node/node_modules/matcher": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/matcher/-/matcher-4.0.0.tgz", - "integrity": "sha512-S6x5wmcDmsDRRU/c2dkccDwQPXoFczc5+HpQ2lON8pnvHlnvHAHj5WlLVvw6n6vNyHuVugYrFohYxbS+pvFpKQ==", - "license": "MIT", - "dependencies": { - "escape-string-regexp": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/onnxruntime-node/node_modules/serialize-error": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/serialize-error/-/serialize-error-8.1.0.tgz", - "integrity": "sha512-3NnuWfM6vBYoy5gZFvHiYsVbafvI9vZv/+jlIigFn4oP4zjNPK3LhcY0xSCgeb1a5L8jO71Mit9LlNoi2UfDDQ==", - "license": "MIT", - "dependencies": { - "type-fest": "^0.20.2" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/onnxruntime-node/node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "license": "(MIT OR CC0-1.0)", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/onnxruntime-web": { - "version": "1.31.0-dev.20260914-8d85527a0", - "resolved": "https://registry.npmjs.org/onnxruntime-web/-/onnxruntime-web-1.31.0-dev.20260914-8d85527a0.tgz", - "integrity": "sha512-Iy7rtadoBgxS/LLvDr3QW38DB1PNXRnr0GJMcL0TAt7c9qjgVQl83UlGCVyeAnK2InpmW8Uc3PL8XIuqtDeF6g==", - "license": "MIT", - "dependencies": { - "flatbuffers": "^25.1.24", - "guid-typescript": "^1.0.9", - "long": "^5.2.3", - "onnxruntime-common": "1.31.0-dev.20260911-2a43ec07e", - "platform": "^1.3.6", - "protobufjs": "^7.2.4" - } - }, - "node_modules/onnxruntime-web/node_modules/onnxruntime-common": { - "version": "1.31.0-dev.20260911-2a43ec07e", - "resolved": "https://registry.npmjs.org/onnxruntime-common/-/onnxruntime-common-1.31.0-dev.20260911-2a43ec07e.tgz", - "integrity": "sha512-gBuF6U32YErKIAt+yD7DeGBpjRxhJ1uJwako6ygjokSZULDU6Pd+KWComX8Tumk1hYVHRxjPj7mdMnD0ryAPOw==", - "license": "MIT" - }, - "node_modules/open": { - "version": "7.4.2", - "resolved": "https://registry.npmjs.org/open/-/open-7.4.2.tgz", - "integrity": "sha512-MVHddDVweXZF3awtlAS+6pgKLlm/JgxZ90+/NBurBoQctVOOB/zDdVjcyPzQ+0laDGbsWgrRkflI65sQeOgT9Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "is-docker": "^2.0.0", - "is-wsl": "^2.1.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/openai": { - "version": "7.19.0", - "resolved": "https://registry.npmjs.org/openai/-/openai-7.19.0.tgz", - "integrity": "sha512-MX2s3u2L5racTO0CC/SWpCOasJQBCJrqLKXK+l82cAhdeF8mPMBEe/gxMm0ZFa2xpKpOFLRjxv5afYEZbBXmbQ==", - "license": "Apache-2.0", - "engines": { - "node": ">=22.0.0" - }, - "peerDependencies": { - "@aws-sdk/credential-provider-node": ">=3.972.0 <4", - "@smithy/hash-node": ">=4.3.0 <5", - "@smithy/signature-v4": ">=5.4.0 <6", - "undici": ">=5 <9", - "ws": "^8.21.0", - "zod": "^3.25 || ^4.0" - }, - "peerDependenciesMeta": { - "@aws-sdk/credential-provider-node": { - "optional": true - }, - "@smithy/hash-node": { - "optional": true - }, - "@smithy/signature-v4": { - "optional": true - }, - "undici": { - "optional": true - }, - "ws": { - "optional": true - }, - "zod": { - "optional": true - } - } - }, - "node_modules/optionator": { - "version": "0.9.4", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.4.tgz", - "integrity": "sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==", - "dev": true, - "license": "MIT", - "dependencies": { - "deep-is": "^0.1.3", - "fast-levenshtein": "^2.0.6", - "levn": "^0.4.1", - "prelude-ls": "^1.2.1", - "type-check": "^0.4.0", - "word-wrap": "^1.2.5" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/own-keys": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/own-keys/-/own-keys-1.0.2.tgz", - "integrity": "sha512-19YVAg7T+WTrxggPukVq7DjTv6+PJ867TmhCvBsYwmbFCsZd344rq2Ld1p0wo8f8Qrrhgp82c6FJRqdXWtSEhg==", - "license": "MIT", - "dependencies": { - "call-bound": "^1.0.4", - "get-intrinsic": "^1.3.0", - "object-keys": "^1.1.1", - "safe-push-apply": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/p-cancelable": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/p-cancelable/-/p-cancelable-2.1.1.tgz", - "integrity": "sha512-BZOr3nRQHOntUjTrH8+Lh54smKHoHyur8We1V8DSMVrl5A2malOOwuJRnKRDjSnkoeBh4at6BwEnb5I7Jl31wg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/p-limit": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", - "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "yocto-queue": "^0.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-locate": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", - "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", - "dev": true, - "license": "MIT", - "dependencies": { - "p-limit": "^3.0.2" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-retry": { - "version": "4.6.2", - "resolved": "https://registry.npmjs.org/p-retry/-/p-retry-4.6.2.tgz", - "integrity": "sha512-312Id396EbJdvRONlngUx0NydfrIQ5lsYu0znKVUzVvArzEIt08V1qhtyESbGVd1FGX7UKtiFp5uwKZdM8wIuQ==", - "license": "MIT", - "dependencies": { - "@types/retry": "0.12.0", - "retry": "^0.13.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/p-retry/node_modules/retry": { - "version": "0.13.1", - "resolved": "https://registry.npmjs.org/retry/-/retry-0.13.1.tgz", - "integrity": "sha512-XQBQ3I8W1Cge0Seh+6gjj03LbmRFWuoszgK9ooCpwYIrhhoO80pfq4cUkU5DkknwfOfFteRwlZ56PYOGYyFWdg==", - "license": "MIT", - "engines": { - "node": ">= 4" - } - }, - "node_modules/parent-module": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", - "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", - "dev": true, - "license": "MIT", - "dependencies": { - "callsites": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/parse-entities": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/parse-entities/-/parse-entities-4.0.2.tgz", - "integrity": "sha512-GG2AQYWoLgL877gQIKeRPGO1xF9+eG1ujIb5soS5gPvLQ1y2o8FL90w2QWNdf9I361Mpp7726c+lj3U0qK1uGw==", - "license": "MIT", - "dependencies": { - "@types/unist": "^2.0.0", - "character-entities-legacy": "^3.0.0", - "character-reference-invalid": "^2.0.0", - "decode-named-character-reference": "^1.0.0", - "is-alphanumerical": "^2.0.0", - "is-decimal": "^2.0.0", - "is-hexadecimal": "^2.0.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } - }, - "node_modules/parse-entities/node_modules/@types/unist": { - "version": "2.0.11", - "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.11.tgz", - "integrity": "sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==", - "license": "MIT" - }, - "node_modules/partial-json": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/partial-json/-/partial-json-0.1.7.tgz", - "integrity": "sha512-Njv/59hHaokb/hRUjce3Hdv12wd60MtM9Z5Olmn+nehe0QDAsRtRbJPvJ0Z91TusF0SuZRIvnM+S4l6EIP8leA==", - "license": "MIT" - }, - "node_modules/patch-package": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/patch-package/-/patch-package-8.0.1.tgz", - "integrity": "sha512-VsKRIA8f5uqHQ7NGhwIna6Bx6D9s/1iXlA1hthBVBEbkq+t4kXD0HHt+rJhf/Z+Ci0F/HCB2hvn0qLdLG+Qxlw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@yarnpkg/lockfile": "^1.1.0", - "chalk": "^4.1.2", - "ci-info": "^3.7.0", - "cross-spawn": "^7.0.3", - "find-yarn-workspace-root": "^2.0.0", - "fs-extra": "^10.0.0", - "json-stable-stringify": "^1.0.2", - "klaw-sync": "^6.0.0", - "minimist": "^1.2.6", - "open": "^7.4.2", - "semver": "^7.5.3", - "slash": "^2.0.0", - "tmp": "^0.2.4", - "yaml": "^2.2.2" - }, - "bin": { - "patch-package": "index.js" - }, - "engines": { - "node": ">=14", - "npm": ">5" - } - }, - "node_modules/patch-package/node_modules/ci-info": { - "version": "3.9.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", - "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/sibiraj-s" - } - ], - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/path-is-absolute": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/path-key": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", - "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/pathe": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.3.tgz", - "integrity": "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==", - "dev": true, - "license": "MIT" - }, - "node_modules/pdfjs-dist": { - "version": "6.1.200", - "resolved": "https://registry.npmjs.org/pdfjs-dist/-/pdfjs-dist-6.1.200.tgz", - "integrity": "sha512-o8MolyzirkkLrcdsae/HEOiIcXWI7DS5zGpvqW8xTC2YUsW30rltFw2bDGvw/fskUdEMrQm2br68jzDS5BH2vw==", - "license": "Apache-2.0", - "engines": { - "node": ">=22.13.0 || >=24" - }, - "optionalDependencies": { - "@napi-rs/canvas": "^1.0.0" - } - }, - "node_modules/pe-library": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/pe-library/-/pe-library-0.4.1.tgz", - "integrity": "sha512-eRWB5LBz7PpDu4PUlwT0PhnQfTQJlDDdPa35urV4Osrm0t0AqQFGn+UIkU3klZvwJ8KPO3VbBFsXquA6p6kqZw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12", - "npm": ">=6" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/jet2jet" - } - }, - "node_modules/pele": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/pele/-/pele-1.6.0.tgz", - "integrity": "sha512-VfAiVItsOGlGhvnBfphdT28VCG7mXMZxQNOwAGsCtxI2ztbUsT39MraEOYjsapLxVETkdUZscm0DdotYDQMLdw==", - "license": "MIT", - "engines": { - "node": ">=20" - } - }, - "node_modules/pend": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz", - "integrity": "sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==", - "license": "MIT" - }, - "node_modules/pi-web-access": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/pi-web-access/-/pi-web-access-0.18.0.tgz", - "integrity": "sha512-UVLWaNBHrbbe2jnpYq+uVJdPgoExz8HevkI7r3VSboZ6AT/S7oxsxpJY/a72mUt9jAy41512ndVxfxh/CIuYqg==", - "license": "MIT", - "dependencies": { - "@mozilla/readability": "^0.6.0", - "linkedom": "^0.16.0", - "p-limit": "^6.1.0", - "promise.try": "^2.0.1", - "turndown": "^7.2.0", - "typebox": "^1.1.38", - "unpdf": "^1.6.2" - }, - "peerDependencies": { - "@earendil-works/pi-ai": "*", - "@earendil-works/pi-coding-agent": "*", - "@earendil-works/pi-tui": "*" - } - }, - "node_modules/pi-web-access/node_modules/p-limit": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-6.2.0.tgz", - "integrity": "sha512-kuUqqHNUqoIWp/c467RI4X6mmyuojY5jGutNU0wVTmEOOfcuwLqyMVoAi9MKi2Ak+5i9+nhmrK4ufZE8069kHA==", - "license": "MIT", - "dependencies": { - "yocto-queue": "^1.1.1" - }, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/pi-web-access/node_modules/yocto-queue": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-1.2.2.tgz", - "integrity": "sha512-4LCcse/U2MHZ63HAJVE+v71o7yOdIe4cZ70Wpf8D/IyjDKYQLV5GD46B+hSTjJsvV5PztjvHoU580EftxjDZFQ==", - "license": "MIT", - "engines": { - "node": ">=12.20" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/picocolors": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", - "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", - "dev": true, - "license": "ISC" - }, - "node_modules/picomatch": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.4.tgz", - "integrity": "sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, - "node_modules/pkijs": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/pkijs/-/pkijs-3.4.0.tgz", - "integrity": "sha512-emEcLuomt2j03vxD54giVB4SxTjnsqkU692xZOZXHDVoYyypEm+b3jpiTcc+Cf+myooc+/Ly0z01jqeNHVgJGw==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "@noble/hashes": "1.4.0", - "asn1js": "^3.0.6", - "bytestreamjs": "^2.0.1", - "pvtsutils": "^1.3.6", - "pvutils": "^1.1.3", - "tslib": "^2.8.1" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/pkijs/node_modules/@noble/hashes": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.4.0.tgz", - "integrity": "sha512-V1JJ1WTRUqHHrOSh597hURcMqVKVGL/ea3kv0gSnEdsEZ0/+VyPghM1lMNGc00z7CIQorSvbKpuJkxvuHbvdbg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 16" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/platform": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/platform/-/platform-1.3.6.tgz", - "integrity": "sha512-fnWVljUchTro6RiCFvCXBbNhJc2NijN7oIQxbwsyL0buWJPG85v81ehlHI9fXrJsMNgTofEoWIQeClKpgxFLrg==", - "license": "MIT" - }, - "node_modules/playwright": { - "version": "1.61.0", - "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.61.0.tgz", - "integrity": "sha512-Z+7BeeqQPRRzklHsVFP4KTGIyMxKUmfeRA4WisM6G3/XW6nwGeX6fX9qYaDa+CiUqpOkb2f6X3nar05R3kSuJQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "playwright-core": "1.61.0" - }, - "bin": { - "playwright": "cli.js" - }, - "engines": { - "node": ">=18" - }, - "optionalDependencies": { - "fsevents": "2.3.2" - } - }, - "node_modules/playwright-core": { - "version": "1.61.0", - "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.61.0.tgz", - "integrity": "sha512-caX7TrY3Ml6egyDX0WUcTHDxodl/b51y5wJOdCEA36QviK/s2g081hvmGs8eaE3DWb6NYZQ6BjO/QkNRPenoPA==", - "dev": true, - "license": "Apache-2.0", - "bin": { - "playwright-core": "cli.js" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/playwright/node_modules/fsevents": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", - "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", - "dev": true, - "hasInstallScript": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" - } - }, - "node_modules/plist": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/plist/-/plist-3.1.0.tgz", - "integrity": "sha512-uysumyrvkUX0rX/dEVqt8gC3sTBzd4zoWfLeS29nb53imdaXVvLINYXTI2GNqzaMuvacNx4uJQ8+b3zXR0pkgQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@xmldom/xmldom": "^0.8.8", - "base64-js": "^1.5.1", - "xmlbuilder": "^15.1.1" - }, - "engines": { - "node": ">=10.4.0" - } - }, - "node_modules/possible-typed-array-names": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.1.0.tgz", - "integrity": "sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==", "license": "MIT", - "engines": { - "node": ">= 0.4" + "dependencies": { + "@types/estree": "^1.0.0", + "@types/unist": "^3.0.0", + "devlop": "^1.0.0", + "estree-util-visit": "^2.0.0", + "micromark-util-symbol": "^2.0.0", + "micromark-util-types": "^2.0.0", + "vfile-message": "^4.0.0" } }, - "node_modules/postcss": { - "version": "8.5.15", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.15.tgz", - "integrity": "sha512-FfR8sjd4em2T6fb3I2MwAJU7HWVMr9zba+enmQeeWFfCbm+UOC/0X4DS8XtpUTMwWMGbjKYP7xjfNekzyGmB3A==", - "dev": true, + "node_modules/micromark-util-html-tag-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/micromark-util-html-tag-name/-/micromark-util-html-tag-name-2.0.1.tgz", + "integrity": "sha512-2cNEiYDhCWKI+Gs9T0Tiysk136SnR13hhO8yW6BGNyhOC4qYFnwF1nKfD3HFAIXA5c45RrIG1ub11GiXeYd1xA==", "funding": [ { - "type": "opencollective", - "url": "https://opencollective.com/postcss/" + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" }, { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/postcss" + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "license": "MIT" + }, + "node_modules/micromark-util-normalize-identifier": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/micromark-util-normalize-identifier/-/micromark-util-normalize-identifier-2.0.1.tgz", + "integrity": "sha512-sxPqmo70LyARJs0w2UclACPUUEqltCkJ6PhKdMIDuJ3gSf/Q+/GIe3WKl0Ijb/GyH9lOpUkRAO2wp0GVkLvS9Q==", + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" }, { - "type": "github", - "url": "https://github.com/sponsors/ai" + "type": "OpenCollective", + "url": "https://opencollective.com/unified" } ], "license": "MIT", "dependencies": { - "nanoid": "^3.3.12", - "picocolors": "^1.1.1", - "source-map-js": "^1.2.1" - }, - "engines": { - "node": "^10 || ^12 || >=14" + "micromark-util-symbol": "^2.0.0" } }, - "node_modules/postject": { - "version": "1.0.0-alpha.6", - "resolved": "https://registry.npmjs.org/postject/-/postject-1.0.0-alpha.6.tgz", - "integrity": "sha512-b9Eb8h2eVqNE8edvKdwqkrY6O7kAwmI8kcnBv1NScolYJbo59XUF0noFq+lxbC1yN20bmC0WBEbDC5H/7ASb0A==", - "dev": true, + "node_modules/micromark-util-resolve-all": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/micromark-util-resolve-all/-/micromark-util-resolve-all-2.0.1.tgz", + "integrity": "sha512-VdQyxFWFT2/FGJgwQnJYbe1jjQoNTS4RjglmSjTUlpUMa95Htx9NHeYW4rGDJzbjvCsl9eLjMQwGeElsqmzcHg==", + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], "license": "MIT", - "optional": true, - "peer": true, "dependencies": { - "commander": "^9.4.0" - }, - "bin": { - "postject": "dist/cli.js" - }, - "engines": { - "node": ">=14.0.0" + "micromark-util-types": "^2.0.0" } }, - "node_modules/postject/node_modules/commander": { - "version": "9.5.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-9.5.0.tgz", - "integrity": "sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ==", - "dev": true, + "node_modules/micromark-util-sanitize-uri": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/micromark-util-sanitize-uri/-/micromark-util-sanitize-uri-2.0.1.tgz", + "integrity": "sha512-9N9IomZ/YuGGZZmQec1MbgxtlgougxTodVwDzzEouPKo3qFWvymFHWcnDi2vzV1ff6kas9ucW+o3yzJK9YB1AQ==", + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], "license": "MIT", - "optional": true, - "peer": true, - "engines": { - "node": "^12.20.0 || >=14" + "dependencies": { + "micromark-util-character": "^2.0.0", + "micromark-util-encode": "^2.0.0", + "micromark-util-symbol": "^2.0.0" } }, - "node_modules/prelude-ls": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", - "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", - "dev": true, + "node_modules/micromark-util-subtokenize": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/micromark-util-subtokenize/-/micromark-util-subtokenize-2.1.0.tgz", + "integrity": "sha512-XQLu552iSctvnEcgXw6+Sx75GflAPNED1qx7eBJ+wydBb2KCbRZe+NwvIEEMM83uml1+2WSXpBAcp9IUCgCYWA==", + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], "license": "MIT", - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/proc-log": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/proc-log/-/proc-log-6.1.0.tgz", - "integrity": "sha512-iG+GYldRf2BQ0UDUAd6JQ/RwzaQy6mXmsk/IzlYyal4A4SNFw54MeH4/tLkF4I5WoWG9SQwuqWzS99jaFQHBuQ==", - "dev": true, - "license": "ISC", - "engines": { - "node": "^20.17.0 || >=22.9.0" + "dependencies": { + "devlop": "^1.0.0", + "micromark-util-chunked": "^2.0.0", + "micromark-util-symbol": "^2.0.0", + "micromark-util-types": "^2.0.0" } }, - "node_modules/process-nextick-args": { + "node_modules/micromark-util-symbol": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", - "dev": true, + "resolved": "https://registry.npmjs.org/micromark-util-symbol/-/micromark-util-symbol-2.0.1.tgz", + "integrity": "sha512-vs5t8Apaud9N28kgCrRUdEed4UJ+wWNvicHLPxCa9ENlYuAY31M0ETy5y1vA33YoNPDFTghEbnh6efaE8h4x0Q==", + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], "license": "MIT" }, - "node_modules/progress": { + "node_modules/micromark-util-types": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", - "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.4.0" - } + "resolved": "https://registry.npmjs.org/micromark-util-types/-/micromark-util-types-2.0.3.tgz", + "integrity": "sha512-oxB2Ik03hI0gv+VNn9tnh1t1YEe9MDPptViAEgfdf3YQHsn0pzGTgCdlSCJXcwhqm8phaEuM7zeEu3QQzVBrPg==", + "funding": [ + { + "type": "GitHub Sponsors", + "url": "https://github.com/sponsors/unifiedjs" + }, + { + "type": "OpenCollective", + "url": "https://opencollective.com/unified" + } + ], + "license": "MIT" }, - "node_modules/promise-retry": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/promise-retry/-/promise-retry-2.0.1.tgz", - "integrity": "sha512-y+WKFlBR8BGXnsNlIHFGPZmyDf3DFMoLhaflAnyZgV6rG6xu+JwesTo2Q9R6XwYmtmwAFCkAk3e35jEdoeh/3g==", + "node_modules/mime": { + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/mime/-/mime-2.6.0.tgz", + "integrity": "sha512-USPkMeET31rOMiarsBNIHZKLGgvKc/LrjofAnBlOttf5ajRvqiRA8QsenbcooctK6d6Ts6aqZXBA+XbkKthiQg==", "dev": true, "license": "MIT", - "dependencies": { - "err-code": "^2.0.2", - "retry": "^0.12.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/promise.try": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/promise.try/-/promise.try-2.0.1.tgz", - "integrity": "sha512-7Lvq1rrywExCch6Uyw8P5G0HrgYs1u2rxY+0HFBMoA5IqndrJrSGc+ybRnPY1N78F8x+j9BaOWNbg7bzTMG9NA==", - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.8", - "define-properties": "^1.2.1", - "es-abstract": "^1.24.1", - "es-errors": "^1.3.0", - "set-function-name": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/proper-lockfile": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", - "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", - "license": "MIT", - "dependencies": { - "graceful-fs": "^4.2.4", - "retry": "^0.12.0", - "signal-exit": "^3.0.2" - } - }, - "node_modules/protobufjs": { - "version": "7.6.4", - "resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-7.6.4.tgz", - "integrity": "sha512-RJJPTTpvFfHcWLkIa2JFWK4XvtSzS0yEWDmunqHXli1h3JlkbcQZXDZdcWxv+JK3Xsl5/UFDPZ0iGm7DAengYw==", - "hasInstallScript": true, - "license": "BSD-3-Clause", - "dependencies": { - "@protobufjs/aspromise": "^1.1.2", - "@protobufjs/base64": "^1.1.2", - "@protobufjs/codegen": "^2.0.5", - "@protobufjs/eventemitter": "^1.1.1", - "@protobufjs/fetch": "^1.1.1", - "@protobufjs/float": "^1.0.2", - "@protobufjs/path": "^1.1.2", - "@protobufjs/pool": "^1.1.0", - "@protobufjs/utf8": "^1.1.1", - "@types/node": ">=13.7.0", - "long": "^5.3.2" + "bin": { + "mime": "cli.js" }, "engines": { - "node": ">=12.0.0" + "node": ">=4.0.0" } }, - "node_modules/proxy-agent-negotiate": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/proxy-agent-negotiate/-/proxy-agent-negotiate-1.1.0.tgz", - "integrity": "sha512-N8IBcM3UgCVzz2L2Lqv8DVntDnnC8/hiV4nEDUPkqq72TPUgYWjQc+bdZlBPZK9LzPAvOY//gAt0S0DApoOXWQ==", + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "dev": true, "license": "MIT", "engines": { - "node": ">= 20" - }, - "peerDependencies": { - "kerberos": "^2.0.0" - }, - "peerDependenciesMeta": { - "kerberos": { - "optional": true - } + "node": ">= 0.6" } }, - "node_modules/pump": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.4.tgz", - "integrity": "sha512-VS7sjc6KR7e1ukRFhQSY5LM2uBWAUPiOPa/A3mkKmiMwSmRFUITt0xuj+/lesgnCv+dPIEYlkzrcyXgquIHMcA==", + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", "dev": true, "license": "MIT", "dependencies": { - "end-of-stream": "^1.1.0", - "once": "^1.3.1" + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" } }, - "node_modules/punycode": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", - "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "node_modules/mimic-response": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-1.0.1.tgz", + "integrity": "sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ==", "dev": true, "license": "MIT", "engines": { - "node": ">=6" + "node": ">=4" } }, - "node_modules/pvtsutils": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/pvtsutils/-/pvtsutils-1.3.6.tgz", - "integrity": "sha512-PLgQXQ6H2FWCaeRak8vvk1GW462lMxB5s3Jm673N82zI4vqtVUPuZdffdZbPDFRoU8kAhItWFtPCWiPpp4/EDg==", + "node_modules/minimatch": { + "version": "10.2.6", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.6.tgz", + "integrity": "sha512-vpLQEs+VLCr1nU0BXS07maYoFwlDAH0gngQuuttxIwutDFEMHq2blX+8vpgxDdK3J1PwjCJiep77OitTZ4Ll1A==", "dev": true, - "license": "MIT", + "license": "BlueOak-1.0.0", "dependencies": { - "tslib": "^2.8.1" + "brace-expansion": "^5.0.8" + }, + "engines": { + "node": "18 || 20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/pvutils": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/pvutils/-/pvutils-1.1.5.tgz", - "integrity": "sha512-KTqnxsgGiQ6ZAzZCVlJH5eOjSnvlyEgx1m8bkRJfOhmGRqfo5KLvmAlACQkrjEtOQ4B7wF9TdSLIs9O90MX9xA==", + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", "dev": true, "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/minipass": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.3.tgz", + "integrity": "sha512-tEBHqDnIoM/1rXME1zgka9g6Q2lcoCkxHLuc7ODJ5BxbP5d4c2Z5cGgtXAku59200Cx7diuHTOYfSBD8n6mm8A==", + "dev": true, + "license": "BlueOak-1.0.0", "engines": { - "node": ">=16.0.0" + "node": ">=16 || 14 >=14.17" } }, - "node_modules/quick-lru": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-5.1.1.tgz", - "integrity": "sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==", + "node_modules/minizlib": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-3.1.0.tgz", + "integrity": "sha512-KZxYo1BUkWD2TVFLr0MQoM8vUUigWD3LlD83a/75BqC+4qE0Hb1Vo5v1FgcfaNXvfXzr+5EhQ6ing/CaBijTlw==", "dev": true, "license": "MIT", + "dependencies": { + "minipass": "^7.1.2" + }, "engines": { - "node": ">=10" + "node": ">= 18" + } + }, + "node_modules/mkdirp": { + "version": "0.5.6", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz", + "integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "minimist": "^1.2.6" }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "bin": { + "mkdirp": "bin/cmd.js" } }, - "node_modules/quickjs-wasi": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/quickjs-wasi/-/quickjs-wasi-3.6.2.tgz", - "integrity": "sha512-FCqGtGOrMgzUiIrMNMA2YnsOxCNwo31dzqXvclXUC6xeT35NJLKXQJsvbeCTjvoFAwZgEAPg8U6+KAPDGXn8Mg==", + "node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", "license": "MIT" }, - "node_modules/react": { - "version": "19.2.7", - "resolved": "https://registry.npmjs.org/react/-/react-19.2.7.tgz", - "integrity": "sha512-HNe9WslTbXmFK8o8cmwgAeJFSBvt1bPdHCVKtaaV+WlAN36mpT4hcRpwbf3fY56ar2oIXzsBpOAiIRHAdY0OlQ==", + "node_modules/nanoid": { + "version": "3.3.20", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.20.tgz", + "integrity": "sha512-uKdg2G3GNCKQn9byYOpxbGqrT2fGO5KRt5J/8b3pok8rT6qxGWF6hxMyJiEYtAf+FVyYuD9hRaDqX5uPFYJ4ZQ==", "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], "license": "MIT", + "bin": { + "nanoid": "bin/nanoid.cjs" + }, "engines": { - "node": ">=0.10.0" + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" } }, - "node_modules/react-dom": { - "version": "19.2.7", - "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.2.7.tgz", - "integrity": "sha512-t0BRVXvbiE/o20Hfw669rLbMCDWtYZLvmJigy2f0MxsXF+71pxhR3xOkspmsO8h3ZlNzyibAmtCa3l4lYKk6gQ==", + "node_modules/natural-compare": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", + "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", "dev": true, + "license": "MIT" + }, + "node_modules/negotiator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-1.1.0.tgz", + "integrity": "sha512-NMPBRMJgiQHjbd8phG3Vebdx4kZ1H121rbl5IkMqeOsahptB9BKo/d7oJ3zTXqTgagn2bWlNSXkh0QUGM31RYg==", "license": "MIT", "dependencies": { - "scheduler": "^0.27.0" + "content-type": "^2.1.0" }, - "peerDependencies": { - "react": "^19.2.7" + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/react-refresh": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/react-refresh/-/react-refresh-0.18.0.tgz", - "integrity": "sha512-QgT5//D3jfjJb6Gsjxv0Slpj23ip+HtOpnNgnb2S5zU3CB26G/IDPGoy4RJB42wzFE46DRsstbW6tKHoKbhAxw==", - "dev": true, + "node_modules/negotiator/node_modules/content-type": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-2.1.0.tgz", + "integrity": "sha512-mj7UPXE0jaqaOsukNZRUEfEi2AcL7C/vwmwcHV0O97eO1E1pxBZuyjlZrx5seTaNBg1U6+o35wpa35Qfcc+7ag==", "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/read-binary-file-arch": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/read-binary-file-arch/-/read-binary-file-arch-1.0.6.tgz", - "integrity": "sha512-BNg9EN3DD3GsDXX7Aa8O4p92sryjkmzYYgmgTAc6CA4uGLEDzFfxOxugu21akOxpcXHiEgsYkC6nPsQvLLLmEg==", + "node_modules/node-abi": { + "version": "4.43.0", + "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-4.43.0.tgz", + "integrity": "sha512-sey5XPoGJ2VBCcwtHhvwSbMMkYvXyvZkn+FjHsoFij3bcWjJRN4+3Zt7GsZOkgZ8J0maJFCWsYtralZDJVQncg==", "dev": true, "license": "MIT", "dependencies": { - "debug": "^4.3.4" + "semver": "^7.6.3" }, - "bin": { - "read-binary-file-arch": "cli.js" + "engines": { + "node": ">=22.12.0" } }, - "node_modules/readable-stream": { - "version": "2.3.8", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", - "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "node_modules/node-api-version": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/node-api-version/-/node-api-version-0.2.1.tgz", + "integrity": "sha512-2xP/IGGMmmSQpI1+O/k72jF/ykvZ89JeuKX3TLJAYPDVLUalrshrLHkeVcCCZqG/eEa635cr8IBYzgnDvM2O8Q==", "dev": true, "license": "MIT", "dependencies": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" + "semver": "^7.3.5" } }, - "node_modules/reflect.getprototypeof": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/reflect.getprototypeof/-/reflect.getprototypeof-1.0.10.tgz", - "integrity": "sha512-00o4I+DVrefhv+nX0ulyi3biSHCPDe+yLv5o/p6d/UVlirijB8E16FtfwSAi4g3tcqrQ4lRAqQSoFEZJehYEcw==", + "node_modules/node-domexception": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/node-domexception/-/node-domexception-1.0.0.tgz", + "integrity": "sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ==", + "deprecated": "Use your platform's native DOMException instead", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/jimmywarting" + }, + { + "type": "github", + "url": "https://paypal.me/jimmywarting" + } + ], + "license": "MIT", + "engines": { + "node": ">=10.5.0" + } + }, + "node_modules/node-fetch": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-3.3.2.tgz", + "integrity": "sha512-dRB78srN/l6gqWulah9SrxeYnxeddIG30+GOqK/9OlLVyLg3HPnr6SqOWTWOXKRwC2eGYCkZ59NNuSgvSrpgOA==", "license": "MIT", "dependencies": { - "call-bind": "^1.0.8", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.9", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0", - "get-intrinsic": "^1.2.7", - "get-proto": "^1.0.1", - "which-builtin-type": "^1.2.1" + "data-uri-to-buffer": "^4.0.0", + "fetch-blob": "^3.1.4", + "formdata-polyfill": "^4.0.10" }, "engines": { - "node": ">= 0.4" + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "type": "opencollective", + "url": "https://opencollective.com/node-fetch" } }, - "node_modules/regexp.prototype.flags": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.4.tgz", - "integrity": "sha512-dYqgNSZbDwkaJ2ceRd9ojCGjBq+mOm9LmtXnAnEGyHhN/5R7iDW2TRw3h+o/jCFxus3P2LfWIIiwowAjANm7IA==", + "node_modules/node-gyp": { + "version": "12.4.0", + "resolved": "https://registry.npmjs.org/node-gyp/-/node-gyp-12.4.0.tgz", + "integrity": "sha512-OMcPNvqTCFUnNaBlmdgq+lfNqY7gTiSmNRDjY3uAXRyudeKZEZxu3CLtjMQrx4zZxCX2b/mpNqTtwuCJgXhHkw==", + "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.8", - "define-properties": "^1.2.1", - "es-errors": "^1.3.0", - "get-proto": "^1.0.1", - "gopd": "^1.2.0", - "set-function-name": "^2.0.2" + "env-paths": "^2.2.0", + "exponential-backoff": "^3.1.1", + "graceful-fs": "^4.2.6", + "nopt": "^9.0.0", + "proc-log": "^6.0.0", + "semver": "^7.3.5", + "tar": "^7.5.4", + "tinyglobby": "^0.2.12", + "undici": "^6.25.0", + "which": "^6.0.0" }, - "engines": { - "node": ">= 0.4" + "bin": { + "node-gyp": "bin/node-gyp.js" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": "^20.17.0 || >=22.9.0" + } + }, + "node_modules/node-gyp/node_modules/env-paths": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", + "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/node-gyp/node_modules/isexe": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-4.0.0.tgz", + "integrity": "sha512-FFUtZMpoZ8RqHS3XeXEmHWLA4thH+ZxCv2lOiPIn1Xc7CxrqhWzNSDzD+/chS/zbYezmiwWLdQC09JdQKmthOw==", + "dev": true, + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=20" + } + }, + "node_modules/node-gyp/node_modules/undici": { + "version": "6.29.1", + "resolved": "https://registry.npmjs.org/undici/-/undici-6.29.1.tgz", + "integrity": "sha512-EvRlUt/QqAEvXdQeRMYUfwOQsfzpDztykrG2owGEE/rBOBoYv9uF39ZzsNDh4lTFHhTr2XOZjKkYgueD12ZmGA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18.17" } }, - "node_modules/remark-gfm": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/remark-gfm/-/remark-gfm-4.0.1.tgz", - "integrity": "sha512-1quofZ2RQ9EWdeN34S79+KExV1764+wCUGop5CPL1WGdD0ocPpu91lzPGbwWMECpEpd42kJGQwzRfyov9j4yNg==", - "license": "MIT", + "node_modules/node-gyp/node_modules/which": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/which/-/which-6.0.1.tgz", + "integrity": "sha512-oGLe46MIrCRqX7ytPUf66EAYvdeMIZYn3WaocqqKZAxrBpkqHfL/qvTyJ/bTk5+AqHCjXmrv3CEWgy368zhRUg==", + "dev": true, + "license": "ISC", "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-gfm": "^3.0.0", - "micromark-extension-gfm": "^3.0.0", - "remark-parse": "^11.0.0", - "remark-stringify": "^11.0.0", - "unified": "^11.0.0" + "isexe": "^4.0.0" }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "bin": { + "node-which": "bin/which.js" + }, + "engines": { + "node": "^20.17.0 || >=22.9.0" } }, - "node_modules/remark-mdx": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/remark-mdx/-/remark-mdx-3.1.1.tgz", - "integrity": "sha512-Pjj2IYlUY3+D8x00UJsIOg5BEvfMyeI+2uLPn9VO9Wg4MEtN/VTIq2NEJQfde9PnX15KgtHyl9S0BcTnWrIuWg==", + "node_modules/node-int64": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", + "integrity": "sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==", + "dev": true, + "license": "MIT" + }, + "node_modules/node-releases": { + "version": "2.0.65", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.65.tgz", + "integrity": "sha512-PfvofsGQ+MiOQIPkX9fU8ELUWmy5zL74CdQaph/ismKszfFkfwXaw0cGiwbwym2hT9k5+mdyl8O5WQ1MD8EHmA==", + "dev": true, "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/nopt": { + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-9.0.0.tgz", + "integrity": "sha512-Zhq3a+yFKrYwSBluL4H9XP3m3y5uvQkB/09CwDruCiRmR/UJYnn9W4R48ry0uGC70aeTPKLynBtscP9efFFcPw==", + "dev": true, + "license": "ISC", "dependencies": { - "mdast-util-mdx": "^3.0.0", - "micromark-extension-mdxjs": "^3.0.0" + "abbrev": "^4.0.0" }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "bin": { + "nopt": "bin/nopt.js" + }, + "engines": { + "node": "^20.17.0 || >=22.9.0" } }, - "node_modules/remark-parse": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/remark-parse/-/remark-parse-11.0.0.tgz", - "integrity": "sha512-FCxlKLNGknS5ba/1lmpYijMUzX2esxW5xQqjWxw2eHFfS2MSdaHVINFmhjo+qN1WhZhNimq0dZATN9pH0IDrpA==", + "node_modules/normalize-url": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-6.1.0.tgz", + "integrity": "sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==", + "dev": true, "license": "MIT", - "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-from-markdown": "^2.0.0", - "micromark-util-types": "^2.0.0", - "unified": "^11.0.0" + "engines": { + "node": ">=10" }, "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/remark-stringify": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/remark-stringify/-/remark-stringify-11.0.0.tgz", - "integrity": "sha512-1OSmLd3awB/t8qdoEOMazZkNsfVTeY4fTsgzcQFdXNq8ToTN4ZGwrMnlda4K6smTFKD+GRV6O48i6Z4iKgPPpw==", - "license": "MIT", + "node_modules/nth-check": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.1.1.tgz", + "integrity": "sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==", + "license": "BSD-2-Clause", "dependencies": { - "@types/mdast": "^4.0.0", - "mdast-util-to-markdown": "^2.0.0", - "unified": "^11.0.0" + "boolbase": "^1.0.0" }, "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "url": "https://github.com/fb55/nth-check?sponsor=1" } }, - "node_modules/require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", - "dev": true, + "node_modules/object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", "license": "MIT", "engines": { "node": ">=0.10.0" } }, - "node_modules/require-from-string": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", - "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", - "dev": true, + "node_modules/object-inspect": { + "version": "1.14.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.14.0.tgz", + "integrity": "sha512-IVgHNlp/jwQX271+Xzoq9LZNTWXxZK+cEOrGBOBxXNbn7fapnZ+Ts6TVMgNOuAezwG2wdtnMX97tTPK6VEnuOQ==", "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/resedit": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/resedit/-/resedit-1.7.2.tgz", - "integrity": "sha512-vHjcY2MlAITJhC0eRD/Vv8Vlgmu9Sd3LX9zZvtGzU5ZImdTN3+d6e/4mnTyV8vEbyf1sgNIrWxhWlrys52OkEA==", - "dev": true, + "node_modules/object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.assign": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.7.tgz", + "integrity": "sha512-nK28WOo+QIjBkDduTINE4JkF/UJJKyf2EJxvJKfblDpyg0Q+pkOHNTL0Qwy6NP6FhE/EnzV73BxxqcJaXY9anw==", "license": "MIT", "dependencies": { - "pe-library": "^0.4.1" + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", + "define-properties": "^1.2.1", + "es-object-atoms": "^1.0.0", + "has-symbols": "^1.1.0", + "object-keys": "^1.1.1" }, "engines": { - "node": ">=12", - "npm": ">=6" + "node": ">= 0.4" }, "funding": { - "type": "github", - "url": "https://github.com/sponsors/jet2jet" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/resolve-alpn": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/resolve-alpn/-/resolve-alpn-1.2.1.tgz", - "integrity": "sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g==", - "dev": true, - "license": "MIT" - }, - "node_modules/resolve-from": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", - "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", + "node_modules/obug": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/obug/-/obug-3.0.0.tgz", + "integrity": "sha512-5vvB5+W7ePv+p3uqxi+RcW1XAzLW0/hxt3/4X4Lc4qHudzOhmBiBwOY6DRob4WnanAEGvNcLjF+KNOufrUoEQw==", "dev": true, + "funding": [ + "https://github.com/sponsors/sxzz", + "https://opencollective.com/debug" + ], "license": "MIT", "engines": { - "node": ">=4" + "node": ">=12.20.0" } }, - "node_modules/responselike": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/responselike/-/responselike-2.0.1.tgz", - "integrity": "sha512-4gl03wn3hj1HP3yzgdI7d3lCkF95F21Pz4BPGvKHinyQzALR5CapwC8yIi0Rh58DEMQ/SguC03wFj2k0M/mHhw==", - "dev": true, + "node_modules/on-finished": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.2.tgz", + "integrity": "sha512-ATWUv387i+nLD49EiDoOft5scf32Vsdz3ktrQJG9bi7jRFmaXTssvyvj1EmeKVVgvesbqUtvQQvaS2TpTukAZQ==", "license": "MIT", "dependencies": { - "lowercase-keys": "^2.0.0" + "ee-first": "1.1.1" + }, + "engines": { + "node": ">= 0.8" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/retry": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", - "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", - "license": "MIT", - "engines": { - "node": ">= 4" + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "license": "ISC", + "dependencies": { + "wrappy": "1" } }, - "node_modules/rimraf": { - "version": "2.6.3", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", - "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", - "deprecated": "Rimraf versions prior to v4 are no longer supported", - "dev": true, - "license": "ISC", - "peer": true, + "node_modules/onnxruntime-common": { + "version": "1.30.0", + "resolved": "https://registry.npmjs.org/onnxruntime-common/-/onnxruntime-common-1.30.0.tgz", + "integrity": "sha512-7fdVWjAID1dVhH/G8qK3APARunV4VkBFoCQAP7qp4Wkab0mrorvmc+sqiT+mKXOzDqdjN5j+/Z9nb4gzNPWcyA==", + "license": "MIT" + }, + "node_modules/onnxruntime-node": { + "version": "1.30.0", + "resolved": "https://registry.npmjs.org/onnxruntime-node/-/onnxruntime-node-1.30.0.tgz", + "integrity": "sha512-twhs1C2C/BFkz1yc5OY0KIU2GUq6DURO7hD4bx5Q2Qy3nAMJwRXW8xU3NVczE29VA9lolLOYepoD8fjTGOfIqw==", + "hasInstallScript": true, + "license": "MIT", + "os": [ + "win32", + "darwin", + "linux" + ], "dependencies": { - "glob": "^7.1.3" - }, - "bin": { - "rimraf": "bin.js" + "adm-zip": "^0.6.0", + "global-agent": "^4.1.3", + "onnxruntime-common": "1.30.0" } }, - "node_modules/roarr": { - "version": "2.15.4", - "resolved": "https://registry.npmjs.org/roarr/-/roarr-2.15.4.tgz", - "integrity": "sha512-CHhPh+UNHD2GTXNYhPWLnU8ONHdI+5DI+4EYIAOaiD63rHeYlZvyh8P+in5999TTSFgUYuKUAjzRI4mdh/p+2A==", - "dev": true, - "license": "BSD-3-Clause", - "optional": true, + "node_modules/onnxruntime-web": { + "version": "1.31.0-dev.20260914-8d85527a0", + "resolved": "https://registry.npmjs.org/onnxruntime-web/-/onnxruntime-web-1.31.0-dev.20260914-8d85527a0.tgz", + "integrity": "sha512-Iy7rtadoBgxS/LLvDr3QW38DB1PNXRnr0GJMcL0TAt7c9qjgVQl83UlGCVyeAnK2InpmW8Uc3PL8XIuqtDeF6g==", + "license": "MIT", "dependencies": { - "boolean": "^3.0.1", - "detect-node": "^2.0.4", - "globalthis": "^1.0.1", - "json-stringify-safe": "^5.0.1", - "semver-compare": "^1.0.0", - "sprintf-js": "^1.1.2" + "flatbuffers": "^25.1.24", + "guid-typescript": "^1.0.9", + "long": "^5.2.3", + "onnxruntime-common": "1.31.0-dev.20260911-2a43ec07e", + "platform": "^1.3.6", + "protobufjs": "^7.2.4" + } + }, + "node_modules/onnxruntime-web/node_modules/onnxruntime-common": { + "version": "1.31.0-dev.20260911-2a43ec07e", + "resolved": "https://registry.npmjs.org/onnxruntime-common/-/onnxruntime-common-1.31.0-dev.20260911-2a43ec07e.tgz", + "integrity": "sha512-gBuF6U32YErKIAt+yD7DeGBpjRxhJ1uJwako6ygjokSZULDU6Pd+KWComX8Tumk1hYVHRxjPj7mdMnD0ryAPOw==", + "license": "MIT" + }, + "node_modules/openai": { + "version": "7.59.0", + "resolved": "https://registry.npmjs.org/openai/-/openai-7.59.0.tgz", + "integrity": "sha512-wPYKJkLPFEdNJ2tThSg4jE1Ptsv4X3u8g8LIvu0Qz/UIhsKeCzl73rl48PtQsDVrJL/ku0liXOsbyd2TsRsPJw==", + "license": "Apache-2.0", + "engines": { + "node": ">=22.0.0" + }, + "peerDependencies": { + "@aws-sdk/credential-provider-node": ">=3.972.0 <4", + "@smithy/hash-node": ">=4.3.0 <5", + "@smithy/signature-v4": ">=5.4.0 <6", + "google-auth-library": ">=9.15.1 <12", + "undici": ">=5 <9", + "ws": "^8.21.0", + "zod": "^3.25 || ^4.0" }, - "engines": { - "node": ">=8.0" + "peerDependenciesMeta": { + "@aws-sdk/credential-provider-node": { + "optional": true + }, + "@smithy/hash-node": { + "optional": true + }, + "@smithy/signature-v4": { + "optional": true + }, + "google-auth-library": { + "optional": true + }, + "undici": { + "optional": true + }, + "ws": { + "optional": true + }, + "zod": { + "optional": true + } } }, - "node_modules/rollup": { - "version": "4.62.0", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.62.0.tgz", - "integrity": "sha512-nc72Wgq62I7rtDV4izT5/aaS0zxy3kttkinf9586ApknY3jZO9NYsmtc24fUckA0X7Q2v+ML4a15pdUlV5V/jA==", + "node_modules/optionator": { + "version": "0.9.4", + "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.4.tgz", + "integrity": "sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==", "dev": true, "license": "MIT", "dependencies": { - "@types/estree": "1.0.9" - }, - "bin": { - "rollup": "dist/bin/rollup" + "deep-is": "^0.1.3", + "fast-levenshtein": "^2.0.6", + "levn": "^0.4.1", + "prelude-ls": "^1.2.1", + "type-check": "^0.4.0", + "word-wrap": "^1.2.5" }, "engines": { - "node": ">=18.0.0", - "npm": ">=8.0.0" - }, - "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.62.0", - "@rollup/rollup-android-arm64": "4.62.0", - "@rollup/rollup-darwin-arm64": "4.62.0", - "@rollup/rollup-darwin-x64": "4.62.0", - "@rollup/rollup-freebsd-arm64": "4.62.0", - "@rollup/rollup-freebsd-x64": "4.62.0", - "@rollup/rollup-linux-arm-gnueabihf": "4.62.0", - "@rollup/rollup-linux-arm-musleabihf": "4.62.0", - "@rollup/rollup-linux-arm64-gnu": "4.62.0", - "@rollup/rollup-linux-arm64-musl": "4.62.0", - "@rollup/rollup-linux-loong64-gnu": "4.62.0", - "@rollup/rollup-linux-loong64-musl": "4.62.0", - "@rollup/rollup-linux-ppc64-gnu": "4.62.0", - "@rollup/rollup-linux-ppc64-musl": "4.62.0", - "@rollup/rollup-linux-riscv64-gnu": "4.62.0", - "@rollup/rollup-linux-riscv64-musl": "4.62.0", - "@rollup/rollup-linux-s390x-gnu": "4.62.0", - "@rollup/rollup-linux-x64-gnu": "4.62.0", - "@rollup/rollup-linux-x64-musl": "4.62.0", - "@rollup/rollup-openbsd-x64": "4.62.0", - "@rollup/rollup-openharmony-arm64": "4.62.0", - "@rollup/rollup-win32-arm64-msvc": "4.62.0", - "@rollup/rollup-win32-ia32-msvc": "4.62.0", - "@rollup/rollup-win32-x64-gnu": "4.62.0", - "@rollup/rollup-win32-x64-msvc": "4.62.0", - "fsevents": "~2.3.2" + "node": ">= 0.8.0" } }, - "node_modules/safe-array-concat": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.1.4.tgz", - "integrity": "sha512-wtZlHyOje6OZTGqAoaDKxFkgRtkF9CnHAVnCHKfuj200wAgL+bSJhdsCD2l0Qx/2ekEXjPWcyKkfGb5CPboslg==", + "node_modules/own-keys": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/own-keys/-/own-keys-1.0.2.tgz", + "integrity": "sha512-19YVAg7T+WTrxggPukVq7DjTv6+PJ867TmhCvBsYwmbFCsZd344rq2Ld1p0wo8f8Qrrhgp82c6FJRqdXWtSEhg==", "license": "MIT", "dependencies": { - "call-bind": "^1.0.9", "call-bound": "^1.0.4", "get-intrinsic": "^1.3.0", - "has-symbols": "^1.1.0", - "isarray": "^2.0.5" + "object-keys": "^1.1.1", + "safe-push-apply": "^1.0.0" }, "engines": { - "node": ">=0.4" + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/safe-array-concat/node_modules/isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "license": "MIT" - }, - "node_modules/safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "license": "MIT" + "node_modules/p-cancelable": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/p-cancelable/-/p-cancelable-2.1.1.tgz", + "integrity": "sha512-BZOr3nRQHOntUjTrH8+Lh54smKHoHyur8We1V8DSMVrl5A2malOOwuJRnKRDjSnkoeBh4at6BwEnb5I7Jl31wg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } }, - "node_modules/safe-push-apply": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/safe-push-apply/-/safe-push-apply-1.0.0.tgz", - "integrity": "sha512-iKE9w/Z7xCzUMIZqdBsp6pEQvwuEebH4vdpjcDWnyzaI6yl6O9FHvVpmGelvEHNsoY6wGblkxR6Zty/h00WiSA==", + "node_modules/p-limit": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", + "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "dev": true, "license": "MIT", "dependencies": { - "es-errors": "^1.3.0", - "isarray": "^2.0.5" + "yocto-queue": "^0.1.0" }, "engines": { - "node": ">= 0.4" + "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/safe-push-apply/node_modules/isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "license": "MIT" - }, - "node_modules/safe-regex-test": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.1.0.tgz", - "integrity": "sha512-x/+Cz4YrimQxQccJf5mKEbIa1NzeCRNI5Ecl/ekmlYaampdNLPalVyIcCZNNH3MvmqBugV5TMYZXv0ljslUlaw==", + "node_modules/p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "dev": true, "license": "MIT", "dependencies": { - "call-bound": "^1.0.2", - "es-errors": "^1.3.0", - "is-regex": "^1.2.1" + "p-limit": "^3.0.2" }, "engines": { - "node": ">= 0.4" + "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/sanitize-filename": { - "version": "1.6.4", - "resolved": "https://registry.npmjs.org/sanitize-filename/-/sanitize-filename-1.6.4.tgz", - "integrity": "sha512-9ZyI08PsvdQl2r/bBIGubpVdR3RR9sY6RDiWFPreA21C/EFlQhmgo20UZlNjZMMZNubusLhAQozkA0Od5J21Eg==", - "dev": true, - "license": "WTFPL OR ISC", + "node_modules/p-retry": { + "version": "4.6.2", + "resolved": "https://registry.npmjs.org/p-retry/-/p-retry-4.6.2.tgz", + "integrity": "sha512-312Id396EbJdvRONlngUx0NydfrIQ5lsYu0znKVUzVvArzEIt08V1qhtyESbGVd1FGX7UKtiFp5uwKZdM8wIuQ==", + "license": "MIT", "dependencies": { - "truncate-utf8-bytes": "^1.0.0" - } - }, - "node_modules/sax": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.6.0.tgz", - "integrity": "sha512-6R3J5M4AcbtLUdZmRv2SygeVaM7IhrLXu9BmnOGmmACak8fiUtOsYNWUS4uK7upbmHIBbLBeFeI//477BKLBzA==", - "license": "BlueOak-1.0.0", + "@types/retry": "0.12.0", + "retry": "^0.13.1" + }, "engines": { - "node": ">=11.0.0" + "node": ">=8" } }, - "node_modules/saxes": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/saxes/-/saxes-5.0.1.tgz", - "integrity": "sha512-5LBh1Tls8c9xgGjw3QrMwETmTMVk0oFgvrFSvWx62llR2hcEInrKNZ2GZCCuuy2lvWrdl5jhbpeqc5hRYKFOcw==", - "license": "ISC", + "node_modules/pako": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/pako/-/pako-1.0.11.tgz", + "integrity": "sha512-4hLB8Py4zZce5s4yd9XzopqwVv/yGNhV1Bl8NTmCq1763HeK2+EwVTv+leGeL13Dnh2wfbqowVPXCIO0z4taYw==", + "license": "(MIT AND Zlib)", + "optional": true + }, + "node_modules/parse-entities": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/parse-entities/-/parse-entities-4.0.2.tgz", + "integrity": "sha512-GG2AQYWoLgL877gQIKeRPGO1xF9+eG1ujIb5soS5gPvLQ1y2o8FL90w2QWNdf9I361Mpp7726c+lj3U0qK1uGw==", + "license": "MIT", "dependencies": { - "xmlchars": "^2.2.0" + "@types/unist": "^2.0.0", + "character-entities-legacy": "^3.0.0", + "character-reference-invalid": "^2.0.0", + "decode-named-character-reference": "^1.0.0", + "is-alphanumerical": "^2.0.0", + "is-decimal": "^2.0.0", + "is-hexadecimal": "^2.0.0" }, - "engines": { - "node": ">=10" + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/scheduler": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.27.0.tgz", - "integrity": "sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q==", - "dev": true, + "node_modules/parse-entities/node_modules/@types/unist": { + "version": "2.0.11", + "resolved": "https://registry.npmjs.org/@types/unist/-/unist-2.0.11.tgz", + "integrity": "sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==", "license": "MIT" }, - "node_modules/semver": { - "version": "7.8.5", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.8.5.tgz", - "integrity": "sha512-Y7/KDsb8LjooZpwaqGyulO6DQlksgCncchHGk+sZIY4SBvUocMBEFH5Ur1fI4dV+Jvl0w6cjvucaIi40puRioA==", - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - }, + "node_modules/parseurl": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", + "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", + "license": "MIT", "engines": { - "node": ">=10" + "node": ">= 0.8" } }, - "node_modules/semver-compare": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/semver-compare/-/semver-compare-1.0.0.tgz", - "integrity": "sha512-YM3/ITh2MJ5MtzaM429anh+x2jiLVjqILF4m4oyQB18W7Ggea7BfqdH/wGMK7dDiMghv/6WG7znWMwUDzJiXow==", + "node_modules/partial-json": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/partial-json/-/partial-json-0.1.7.tgz", + "integrity": "sha512-Njv/59hHaokb/hRUjce3Hdv12wd60MtM9Z5Olmn+nehe0QDAsRtRbJPvJ0Z91TusF0SuZRIvnM+S4l6EIP8leA==", + "license": "MIT" + }, + "node_modules/path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", "dev": true, "license": "MIT", - "optional": true + "engines": { + "node": ">=8" + } }, - "node_modules/serialize-error": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/serialize-error/-/serialize-error-7.0.1.tgz", - "integrity": "sha512-8I8TjW5KMOKsZQTvoxjuSIa7foAwPWGOts+6o7sgjz41/qMD9VQHEDxi6PBvK2l0MXUmqZyNpUK+T2tQaaElvw==", + "node_modules/path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", "dev": true, "license": "MIT", - "optional": true, - "dependencies": { - "type-fest": "^0.13.1" - }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": ">=0.10.0" } }, - "node_modules/set-function-length": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", - "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", + "node_modules/path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", "license": "MIT", - "dependencies": { - "define-data-property": "^1.1.4", - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.2" - }, "engines": { - "node": ">= 0.4" + "node": ">=8" } }, - "node_modules/set-function-name": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.2.tgz", - "integrity": "sha512-7PGFlmtwsEADb0WYyvCMa1t+yke6daIG4Wirafur5kcf+MhUnPms1UeR0CKQdTZD81yESwMHbtn+TR+dMviakQ==", + "node_modules/path-to-regexp": { + "version": "8.4.2", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-8.4.2.tgz", + "integrity": "sha512-qRcuIdP69NPm4qbACK+aDogI5CBDMi1jKe0ry5rSQJz8JVLsC7jV8XpiJjGRLLol3N+R5ihGYcrPLTno6pAdBA==", "license": "MIT", - "dependencies": { - "define-data-property": "^1.1.4", - "es-errors": "^1.3.0", - "functions-have-names": "^1.2.3", - "has-property-descriptors": "^1.0.2" + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/pdfjs-dist": { + "version": "6.5.438", + "resolved": "https://registry.npmjs.org/pdfjs-dist/-/pdfjs-dist-6.5.438.tgz", + "integrity": "sha512-vg8Pw1x+AFKy4AMDvhuWl5cOYV8d698UoEANoFFhc79hqXDnZQqnOXoxw3HG907WHOg1JYOvLhP756boddFxpA==", + "license": "Apache-2.0", + "engines": { + "node": ">=22.13.0 || >=24" }, + "optionalDependencies": { + "@napi-rs/canvas": "^1.0.13" + } + }, + "node_modules/pe-library": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/pe-library/-/pe-library-0.4.1.tgz", + "integrity": "sha512-eRWB5LBz7PpDu4PUlwT0PhnQfTQJlDDdPa35urV4Osrm0t0AqQFGn+UIkU3klZvwJ8KPO3VbBFsXquA6p6kqZw==", + "dev": true, + "license": "MIT", "engines": { - "node": ">= 0.4" + "node": ">=12", + "npm": ">=6" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/jet2jet" } }, - "node_modules/set-proto": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/set-proto/-/set-proto-1.0.0.tgz", - "integrity": "sha512-RJRdvCo6IAnPdsvP/7m6bsQqNnn1FCBX5ZNtFL98MmFF/4xAIJTIg1YbHW5DC2W5SKZanrC6i4HsJqlajw/dZw==", + "node_modules/pele": { + "version": "1.13.0", + "resolved": "https://registry.npmjs.org/pele/-/pele-1.13.0.tgz", + "integrity": "sha512-Ie8UKY9x00MsuR3jO6AzUwzK2Z6MIV3Tf4EDdITiuk8Uaz8K7g0R082WqsqNaSU8DdgkrRvZThzhit83mi/uiw==", "license": "MIT", - "dependencies": { - "dunder-proto": "^1.0.1", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0" - }, "engines": { - "node": ">= 0.4" + "node": ">=20" } }, - "node_modules/sharp": { - "version": "0.35.5", - "resolved": "https://registry.npmjs.org/sharp/-/sharp-0.35.5.tgz", - "integrity": "sha512-Ywn4OnzGukp7CDMrp08RQ50YKmuwG47brZgIVPTvBaaAfQlRlygrRqSrxdCiL9M+LlzLBiJ68IR1QqvzHyjC7g==", - "license": "Apache-2.0", + "node_modules/pend": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz", + "integrity": "sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==", + "license": "MIT" + }, + "node_modules/pi-web-access": { + "version": "0.48.0", + "resolved": "https://registry.npmjs.org/pi-web-access/-/pi-web-access-0.48.0.tgz", + "integrity": "sha512-9+B5e2kLtN0qYs2LZ6D8yOI9TbjQTnf4AKON/Qy2nseE//fH71u60Icul6Ua7Pp7R5Ro1oPJpiDqdUut730UOg==", + "license": "MIT", "dependencies": { - "@img/colour": "^1.1.0", - "detect-libc": "^2.1.2", - "semver": "^7.8.5" + "@modelcontextprotocol/sdk": "1.32.1", + "@mozilla/readability": "^0.6.0", + "defuddle": "0.19.3", + "linkedom": "^0.16.0", + "p-limit": "^6.1.0", + "promise.try": "^2.0.1", + "turndown": "^7.2.0", + "undici": "^8.11.2", + "unpdf": "^1.6.2" }, - "engines": { - "node": ">=20.9.0" + "bin": { + "pi-web-access-mcp": "dist/mcp-cli.js" }, - "funding": { - "url": "https://opencollective.com/libvips" + "engines": { + "node": ">=22.19.0" }, - "optionalDependencies": { - "@img/sharp-darwin-arm64": "0.35.5", - "@img/sharp-darwin-x64": "0.35.5", - "@img/sharp-freebsd-wasm32": "0.35.5", - "@img/sharp-libvips-darwin-arm64": "1.3.4", - "@img/sharp-libvips-darwin-x64": "1.3.4", - "@img/sharp-libvips-linux-arm": "1.3.4", - "@img/sharp-libvips-linux-arm64": "1.3.4", - "@img/sharp-libvips-linux-ppc64": "1.3.4", - "@img/sharp-libvips-linux-riscv64": "1.3.4", - "@img/sharp-libvips-linux-s390x": "1.3.4", - "@img/sharp-libvips-linux-x64": "1.3.4", - "@img/sharp-libvips-linuxmusl-arm64": "1.3.4", - "@img/sharp-libvips-linuxmusl-x64": "1.3.4", - "@img/sharp-linux-arm": "0.35.5", - "@img/sharp-linux-arm64": "0.35.5", - "@img/sharp-linux-ppc64": "0.35.5", - "@img/sharp-linux-riscv64": "0.35.5", - "@img/sharp-linux-s390x": "0.35.5", - "@img/sharp-linux-x64": "0.35.5", - "@img/sharp-linuxmusl-arm64": "0.35.5", - "@img/sharp-linuxmusl-x64": "0.35.5", - "@img/sharp-webcontainers-wasm32": "0.35.5", - "@img/sharp-win32-arm64": "0.35.5", - "@img/sharp-win32-ia32": "0.35.5", - "@img/sharp-win32-x64": "0.35.5" + "peerDependencies": { + "@earendil-works/pi-ai": "*", + "@earendil-works/pi-coding-agent": "*", + "@earendil-works/pi-tui": "*", + "typebox": "*" }, "peerDependenciesMeta": { - "@types/node": { + "@earendil-works/pi-ai": { + "optional": true + }, + "@earendil-works/pi-coding-agent": { + "optional": true + }, + "@earendil-works/pi-tui": { "optional": true } } }, - "node_modules/shebang-command": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", - "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "node_modules/pi-web-access/node_modules/p-limit": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-6.2.0.tgz", + "integrity": "sha512-kuUqqHNUqoIWp/c467RI4X6mmyuojY5jGutNU0wVTmEOOfcuwLqyMVoAi9MKi2Ak+5i9+nhmrK4ufZE8069kHA==", "license": "MIT", "dependencies": { - "shebang-regex": "^3.0.0" + "yocto-queue": "^1.1.1" }, "engines": { - "node": ">=8" + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/shebang-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "node_modules/pi-web-access/node_modules/yocto-queue": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-1.2.2.tgz", + "integrity": "sha512-4LCcse/U2MHZ63HAJVE+v71o7yOdIe4cZ70Wpf8D/IyjDKYQLV5GD46B+hSTjJsvV5PztjvHoU580EftxjDZFQ==", "license": "MIT", "engines": { - "node": ">=8" + "node": ">=12.20" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/side-channel": { + "node_modules/picocolors": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.1.tgz", - "integrity": "sha512-6x6dK6zJdpTzF4sQeNYxwtvBzf6Eg4GtlesS94HOvTudUeyK2WXAaIfmDgsyslYrRBeFIlsi54AYsFGUuhmvrQ==", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true, + "license": "ISC" + }, + "node_modules/picomatch": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.7.tgz", + "integrity": "sha512-qcJu88Q2IWqJsDD529JKMdwGm/dvInW4HvQnRwiH9JtihJvzGOscDtHE3x1pBKeUOTysQ8kVmLnJ2kJu7yhcGA==", + "dev": true, "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "object-inspect": "^1.13.4", - "side-channel-list": "^1.0.1", - "side-channel-map": "^1.0.1", - "side-channel-weakmap": "^1.0.2" - }, "engines": { - "node": ">= 0.4" + "node": ">=12" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/side-channel-list": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.1.tgz", - "integrity": "sha512-mjn/0bi/oUURjc5Xl7IaWi/OJJJumuoJFQJfDDyO46+hBWsfaVM65TBHq2eoZBhzl9EchxOijpkbRC8SVBQU0w==", + "node_modules/pkce-challenge": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/pkce-challenge/-/pkce-challenge-5.0.1.tgz", + "integrity": "sha512-wQ0b/W4Fr01qtpHlqSqspcj3EhBvimsdh0KlHhH8HRZnMsEa0ea2fTULOXOS9ccQr3om+GcGRk4e+isrZWV8qQ==", "license": "MIT", + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/pkijs": { + "version": "3.4.3", + "resolved": "https://registry.npmjs.org/pkijs/-/pkijs-3.4.3.tgz", + "integrity": "sha512-V9kOzaItwDgqlryhXysQsAXUEKi5O7kqWUaP3dXI7MLvkPqWWMb4wVb1QAtmEDCKI+XIAINsZoNKMFF7sZb1eg==", + "dev": true, + "license": "BSD-3-Clause", + "workspaces": [ + "website" + ], "dependencies": { - "es-errors": "^1.3.0", - "object-inspect": "^1.13.4" + "@noble/hashes": "1.8.0", + "asn1js": "^3.0.6", + "bytestreamjs": "^2.0.1", + "pvtsutils": "^1.3.6", + "pvutils": "^1.1.3", + "tslib": "^2.8.1" }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">=16.0.0" } }, - "node_modules/side-channel-map": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz", - "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==", - "license": "MIT", + "node_modules/platform": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/platform/-/platform-1.3.6.tgz", + "integrity": "sha512-fnWVljUchTro6RiCFvCXBbNhJc2NijN7oIQxbwsyL0buWJPG85v81ehlHI9fXrJsMNgTofEoWIQeClKpgxFLrg==", + "license": "MIT" + }, + "node_modules/playwright": { + "version": "1.65.1", + "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.65.1.tgz", + "integrity": "sha512-vJ1FuoOrNwOKHUIVEvSt3jT1L+wjjDpwhwIstKtfvTh8XIG4FG4bIFuvNdMxi81LGfAhUgUZleVFaOLY4RIUUw==", + "dev": true, + "license": "Apache-2.0", "dependencies": { - "call-bound": "^1.0.2", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.5", - "object-inspect": "^1.13.3" + "playwright-core": "1.65.1" + }, + "bin": { + "playwright": "cli.js" }, "engines": { - "node": ">= 0.4" + "node": ">=20" + } + }, + "node_modules/playwright-core": { + "version": "1.65.1", + "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.65.1.tgz", + "integrity": "sha512-hqPpz7blSMPxWVdoeE1yiBSzXsKiVOd2k+kjCvmUywD2GPO2Dd9HfcWnq9NN0GHbNZDFgZ9JfBFr+X5/BLo0qw==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "playwright-core": "cli.js" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": ">=20" } }, - "node_modules/side-channel-weakmap": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz", - "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==", + "node_modules/plist": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/plist/-/plist-3.1.0.tgz", + "integrity": "sha512-uysumyrvkUX0rX/dEVqt8gC3sTBzd4zoWfLeS29nb53imdaXVvLINYXTI2GNqzaMuvacNx4uJQ8+b3zXR0pkgQ==", + "dev": true, "license": "MIT", "dependencies": { - "call-bound": "^1.0.2", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.5", - "object-inspect": "^1.13.3", - "side-channel-map": "^1.0.1" + "@xmldom/xmldom": "^0.8.8", + "base64-js": "^1.5.1", + "xmlbuilder": "^15.1.1" }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">=10.4.0" } }, - "node_modules/siginfo": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/siginfo/-/siginfo-2.0.0.tgz", - "integrity": "sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==", + "node_modules/plist/node_modules/@xmldom/xmldom": { + "version": "0.8.15", + "resolved": "https://registry.npmjs.org/@xmldom/xmldom/-/xmldom-0.8.15.tgz", + "integrity": "sha512-/5NV/vDALVFDXgLmfsy9TRCBlKwO2LNBFzpzvb9iIj+jR+eSc6DLYYvVOdivT/jm7MtU6TebYuRmzEOI7w40UA==", "dev": true, - "license": "ISC" + "license": "MIT", + "engines": { + "node": ">=10.0.0" + } }, - "node_modules/signal-exit": { - "version": "3.0.7", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", - "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", - "license": "ISC" + "node_modules/possible-typed-array-names": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.1.0.tgz", + "integrity": "sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + } }, - "node_modules/simple-update-notifier": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/simple-update-notifier/-/simple-update-notifier-2.0.0.tgz", - "integrity": "sha512-a2B9Y0KlNXl9u/vsW6sTIu9vGEpfKu2wRV6l1H3XEas/0gUIzGzBoP/IouTcUQbm9JWZLH3COxyn03TYlFax6w==", + "node_modules/postcss": { + "version": "8.5.33", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.33.tgz", + "integrity": "sha512-RVHEU9/Pp1Fnjr/MpAJsZoADukCKhfIi15OunEYiGktIkYLkPVvC1sioWolGDS7XByMTx9m/IGbro0Js13zhnQ==", "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], "license": "MIT", "dependencies": { - "semver": "^7.5.3" + "nanoid": "^3.3.20", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.2" }, "engines": { - "node": ">=10" + "node": "^10 || ^12 || >=14" } }, - "node_modules/sisteransi": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", - "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==", - "license": "MIT" - }, - "node_modules/skillflag": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/skillflag/-/skillflag-0.2.1.tgz", - "integrity": "sha512-47lfgUr6xzgljtTD5XfJrS+6muNb9R44OEr+o31Nco2R65W1xOA8Pi6QSbLa90tDYE6TqW5Hrh3N1egserGrhQ==", + "node_modules/postject": { + "version": "1.0.0-alpha.6", + "resolved": "https://registry.npmjs.org/postject/-/postject-1.0.0-alpha.6.tgz", + "integrity": "sha512-b9Eb8h2eVqNE8edvKdwqkrY6O7kAwmI8kcnBv1NScolYJbo59XUF0noFq+lxbC1yN20bmC0WBEbDC5H/7ASb0A==", + "dev": true, "license": "MIT", + "optional": true, + "peer": true, "dependencies": { - "@clack/prompts": "^1.0.1", - "tar-stream": "^3.1.7" + "commander": "^9.4.0" }, "bin": { - "skill-install": "dist/bin/skill-install.js", - "skillflag": "dist/bin/skillflag.js" + "postject": "dist/cli.js" }, "engines": { - "node": ">=18" + "node": ">=14.0.0" } }, - "node_modules/slash": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/slash/-/slash-2.0.0.tgz", - "integrity": "sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A==", + "node_modules/postject/node_modules/commander": { + "version": "9.5.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-9.5.0.tgz", + "integrity": "sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ==", "dev": true, "license": "MIT", + "optional": true, + "peer": true, "engines": { - "node": ">=6" + "node": "^12.20.0 || >=14" } }, - "node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "node_modules/prelude-ls": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", + "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", "dev": true, - "license": "BSD-3-Clause", + "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">= 0.8.0" } }, - "node_modules/source-map-js": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", - "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "node_modules/proc-log": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/proc-log/-/proc-log-6.1.0.tgz", + "integrity": "sha512-iG+GYldRf2BQ0UDUAd6JQ/RwzaQy6mXmsk/IzlYyal4A4SNFw54MeH4/tLkF4I5WoWG9SQwuqWzS99jaFQHBuQ==", "dev": true, - "license": "BSD-3-Clause", + "license": "ISC", "engines": { - "node": ">=0.10.0" + "node": "^20.17.0 || >=22.9.0" } }, - "node_modules/source-map-support": { - "version": "0.5.21", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz", - "integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==", + "node_modules/process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", + "devOptional": true, + "license": "MIT" + }, + "node_modules/progress": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", + "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", "dev": true, "license": "MIT", - "dependencies": { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0" + "engines": { + "node": ">=0.4.0" } }, - "node_modules/sprintf-js": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.1.3.tgz", - "integrity": "sha512-Oo+0REFV59/rz3gfJNKQiBlwfHaSESl1pcGyABQsnnIfWOFt6JNj5gCog2U6MLZ//IGYD+nA8nI+mTShREReaA==", - "dev": true, - "license": "BSD-3-Clause", - "optional": true - }, - "node_modules/stackback": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/stackback/-/stackback-0.0.2.tgz", - "integrity": "sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==", + "node_modules/promise-retry": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/promise-retry/-/promise-retry-2.0.1.tgz", + "integrity": "sha512-y+WKFlBR8BGXnsNlIHFGPZmyDf3DFMoLhaflAnyZgV6rG6xu+JwesTo2Q9R6XwYmtmwAFCkAk3e35jEdoeh/3g==", "dev": true, - "license": "MIT" - }, - "node_modules/standardwebhooks": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/standardwebhooks/-/standardwebhooks-1.1.1.tgz", - "integrity": "sha512-bCbX9ZEyFkWPsRz7Bl3NuQUJohmwGSev/yhr7vhaGPlc4AfIrspIRa6cPTBuI1ItmrTDJ4d/S2hCsfe4+vQGnQ==", "license": "MIT", "dependencies": { - "@stablelib/base64": "^1.0.0", - "fast-sha256": "^1.3.0" + "err-code": "^2.0.2", + "retry": "^0.12.0" + }, + "engines": { + "node": ">=10" } }, - "node_modules/stat-mode": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/stat-mode/-/stat-mode-1.0.0.tgz", - "integrity": "sha512-jH9EhtKIjuXZ2cWxmXS8ZP80XyC3iasQxMDV8jzhNJpfDb7VbQLVW4Wvsxz9QZvzV+G4YoSfBUVKDOyxLzi/sg==", + "node_modules/promise-retry/node_modules/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", "dev": true, "license": "MIT", "engines": { - "node": ">= 6" + "node": ">= 4" } }, - "node_modules/std-env": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/std-env/-/std-env-4.1.0.tgz", - "integrity": "sha512-Rq7ybcX2RuC55r9oaPVEW7/xu3tj8u4GeBYHBWCychFtzMIr86A7e3PPEBPT37sHStKX3+TiX/Fr/ACmJLVlLQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/stop-iteration-iterator": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.1.0.tgz", - "integrity": "sha512-eLoXW/DHyl62zxY4SCaIgnRhuMr6ri4juEYARS8E6sCEqzKpOiE521Ucofdx+KnDZl5xmvGYaaKCk5FEOxJCoQ==", + "node_modules/promise.try": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/promise.try/-/promise.try-2.0.2.tgz", + "integrity": "sha512-v52t0zwjhZX4x52T69jDMO11oKAt6l7NosmY+H+3MD7s16iXUYbFrA+DOcW5rvl+mBIWJAFbbTaExDxPUgaowg==", "license": "MIT", "dependencies": { + "call-bind": "^1.0.9", + "define-properties": "^1.2.1", + "es-abstract": "^1.24.2", "es-errors": "^1.3.0", - "internal-slot": "^1.1.0" + "set-function-name": "^2.0.2" }, "engines": { "node": ">= 0.4" } }, - "node_modules/streamx": { - "version": "2.28.0", - "resolved": "https://registry.npmjs.org/streamx/-/streamx-2.28.0.tgz", - "integrity": "sha512-1Yowhzjf0ivGMrTIkY9hav5TxobO9qIVqUE41fiCGMGgc3CLlf4MY+9AHmZqBWgDTue0fY9zWjYFVyf6Diuobw==", + "node_modules/proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", "license": "MIT", "dependencies": { - "events-universal": "^1.0.0", - "fast-fifo": "^1.3.2", - "text-decoder": "^1.1.0" + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" } }, - "node_modules/string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, + "node_modules/proper-lockfile/node_modules/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", "license": "MIT", - "dependencies": { - "safe-buffer": "~5.1.0" + "engines": { + "node": ">= 4" } }, - "node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "license": "MIT", + "node_modules/protobufjs": { + "version": "7.6.6", + "resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-7.6.6.tgz", + "integrity": "sha512-dYDWdjSl5RNb7SgPxGQcRU+GtvP7s2fpkrY0r432PcOIaZ0/rBcxEZnQN67iJhFuQiVw754JDoPruPCNdGsbjg==", + "hasInstallScript": true, + "license": "BSD-3-Clause", "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" + "@protobufjs/aspromise": "^1.1.2", + "@protobufjs/base64": "^1.1.2", + "@protobufjs/codegen": "^2.0.5", + "@protobufjs/eventemitter": "^1.1.1", + "@protobufjs/fetch": "^1.1.1", + "@protobufjs/float": "^1.0.2", + "@protobufjs/path": "^1.1.2", + "@protobufjs/pool": "^1.1.0", + "@protobufjs/utf8": "^1.1.1", + "@types/node": ">=13.7.0", + "long": "^5.3.2" }, "engines": { - "node": ">=8" + "node": ">=12.0.0" } }, - "node_modules/string.prototype.trim": { - "version": "1.2.11", - "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.11.tgz", - "integrity": "sha512-PwvK7BU+CMTJGYQCTZb5RWXIML92lftJLhQz1tBzgKiqGxJaMlBAa48POXaNAC2s4y8jr3EFqrkF9+44neS46w==", + "node_modules/proxy-addr": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.8.tgz", + "integrity": "sha512-5nnx0yGyVUcY6t9RnWcARWtwT9F1D8O9rt08htPvnd49W1IgZtmLkhu9WfMzQj1cFxjHIO6connUNVW5k7AVyQ==", "license": "MIT", "dependencies": { - "call-bind": "^1.0.9", - "call-bound": "^1.0.4", - "define-data-property": "^1.1.4", - "define-properties": "^1.2.1", - "es-abstract": "^1.24.2", - "es-object-atoms": "^1.1.2", - "has-property-descriptors": "^1.0.2", - "safe-regex-test": "^1.1.0" + "forwarded": "0.2.0", + "ipaddr.js": "1.9.1" }, "engines": { - "node": ">= 0.4" + "node": ">= 0.10" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/string.prototype.trimend": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.10.tgz", - "integrity": "sha512-2+3aDAOmPTmuFwjDnmJG2ctEkQKVki7vOSqaxkv42Mowj1V6PnvuwFCRrR5lChUux1TBskPjfkeTOhqczDMxTw==", + "node_modules/proxy-agent-negotiate": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/proxy-agent-negotiate/-/proxy-agent-negotiate-1.1.0.tgz", + "integrity": "sha512-N8IBcM3UgCVzz2L2Lqv8DVntDnnC8/hiV4nEDUPkqq72TPUgYWjQc+bdZlBPZK9LzPAvOY//gAt0S0DApoOXWQ==", + "license": "MIT", + "engines": { + "node": ">= 20" + }, + "peerDependencies": { + "kerberos": "^2.0.0" + }, + "peerDependenciesMeta": { + "kerberos": { + "optional": true + } + } + }, + "node_modules/pump": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.4.tgz", + "integrity": "sha512-VS7sjc6KR7e1ukRFhQSY5LM2uBWAUPiOPa/A3mkKmiMwSmRFUITt0xuj+/lesgnCv+dPIEYlkzrcyXgquIHMcA==", + "dev": true, + "license": "MIT", + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, + "node_modules/punycode": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", + "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "dev": true, "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/pvtsutils": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/pvtsutils/-/pvtsutils-1.3.6.tgz", + "integrity": "sha512-PLgQXQ6H2FWCaeRak8vvk1GW462lMxB5s3Jm673N82zI4vqtVUPuZdffdZbPDFRoU8kAhItWFtPCWiPpp4/EDg==", + "dev": true, + "license": "MIT", + "dependencies": { + "tslib": "^2.8.1" + } + }, + "node_modules/pvutils": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/pvutils/-/pvutils-1.2.0.tgz", + "integrity": "sha512-BbubeCEyTuQjVMakvJQ/Sxbc93F2pwmbsxONT/ZRrwU7Ua38d8unYTwXpTVLAKJ4BDuH9IGztCjQcd/N/39Dvg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=16.0.0" + } + }, + "node_modules/qified": { + "version": "0.10.1", + "resolved": "https://registry.npmjs.org/qified/-/qified-0.10.1.tgz", + "integrity": "sha512-+Owyggi9IxT1ePKGafcI87ubSmxol6smwJ+RAHDQlx9+9cPwFWDiKFFCPuWhr9ignlGpZ9vDQLw67N4dcTVFEA==", + "dev": true, + "license": "MIT", + "dependencies": { + "hookified": "^2.1.1" + }, + "engines": { + "node": ">=20" + } + }, + "node_modules/qified/node_modules/hookified": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/hookified/-/hookified-2.2.0.tgz", + "integrity": "sha512-p/LgFzRN5FeoD3DLS6bkUapeye6E4SI6yJs6KetENd18S+FBthqYq2amJUWpt5z0EQwwHemidjY5OqJGEKm5uA==", + "dev": true, + "license": "MIT" + }, + "node_modules/qs": { + "version": "6.17.1", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.17.1.tgz", + "integrity": "sha512-jd3COkaKVgGUW+ZHyEHCG9bH7RoaaiWuMgzsIBjUMVjLAaWGWpoUAVwljVvBHxRu/2qEHnadLGZrkutYUBPQJA==", + "license": "BSD-3-Clause", "dependencies": { - "call-bind": "^1.0.9", - "call-bound": "^1.0.4", - "define-properties": "^1.2.1", - "es-object-atoms": "^1.1.2" + "es-define-property": "^1.0.1", + "side-channel": "^1.1.1" }, "engines": { - "node": ">= 0.4" + "node": ">=0.6" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/string.prototype.trimstart": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.8.tgz", - "integrity": "sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==", + "node_modules/quick-lru": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-5.1.1.tgz", + "integrity": "sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==", + "dev": true, "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-object-atoms": "^1.0.0" - }, "engines": { - "node": ">= 0.4" + "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/stringify-entities": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/stringify-entities/-/stringify-entities-4.0.4.tgz", - "integrity": "sha512-IwfBptatlO+QCJUo19AqvrPNqlVMpW9YEL2LIVY+Rpv2qsjCGxaDLNRgeGsQWJhfItebuJhsGSLjaBbNSQ+ieg==", + "node_modules/quickjs-wasi": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/quickjs-wasi/-/quickjs-wasi-3.6.2.tgz", + "integrity": "sha512-FCqGtGOrMgzUiIrMNMA2YnsOxCNwo31dzqXvclXUC6xeT35NJLKXQJsvbeCTjvoFAwZgEAPg8U6+KAPDGXn8Mg==", + "license": "MIT" + }, + "node_modules/range-parser": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.3.0.tgz", + "integrity": "sha512-hek2mFQpPuI4E1BBKrSto+BU3e3x4xuarsbiwr3+lf7p44juvFMV0XFWQAP3xUyqXA4RrXLIoaSUGbSt056ZMw==", "license": "MIT", - "dependencies": { - "character-entities-html4": "^2.0.0", - "character-entities-legacy": "^3.0.0" + "engines": { + "node": ">= 0.6" }, "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, + "node_modules/raw-body": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-3.0.2.tgz", + "integrity": "sha512-K5zQjDllxWkf7Z5xJdV0/B0WTNqx6vxG70zJE4N0kBs4LovmEYWJzQGxC9bS9RAKu3bgM40lrd5zoLJ12MQ5BA==", "license": "MIT", "dependencies": { - "ansi-regex": "^5.0.1" + "bytes": "~3.1.2", + "http-errors": "~2.0.1", + "iconv-lite": "~0.7.0", + "unpipe": "~1.0.0" }, "engines": { - "node": ">=8" + "node": ">= 0.10" } }, - "node_modules/strip-json-comments": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", - "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", + "node_modules/react": { + "version": "19.3.1", + "resolved": "https://registry.npmjs.org/react/-/react-19.3.1.tgz", + "integrity": "sha512-QNhWdt7nrgVWWQG58QuGsAR3jv3Hbe4mb4vz7w2csnHavciZJgda1CPNaldF6eVxv90ud3jUXpKlHL69gO38yw==", "dev": true, "license": "MIT", "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/sumchecker": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/sumchecker/-/sumchecker-3.0.1.tgz", - "integrity": "sha512-MvjXzkz/BOfyVDkG0oFOtBxHX2u3gKbMHIF/dXblZsgD3BWOFLmHovIpZY7BykJdAjcqRCBi1WYBNdEC9yI7vg==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "debug": "^4.1.0" - }, - "engines": { - "node": ">= 8.0" + "node": ">=0.10.0" } }, - "node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/react-dom": { + "version": "19.3.1", + "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.3.1.tgz", + "integrity": "sha512-Y0bARz53lhEC1NMCASs0/j+faB/zqt3R8hpvg1e8+61ZVJ4UL0UdC4cBbXfZMcIuhrfgeILTLe+ZeBCavQPtKQ==", "dev": true, "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "scheduler": "^0.28.0" }, - "engines": { - "node": ">=8" + "peerDependencies": { + "react": "^19.3.1" } }, - "node_modules/tar": { - "version": "7.5.19", - "resolved": "https://registry.npmjs.org/tar/-/tar-7.5.19.tgz", - "integrity": "sha512-4LeEWl96twnS2Q7Bz4MGqgazLqO+hJN63GZxXoIqh1T3VweYD997gbU1ItNsQafqqXTXd5WFyFdReLtwvRBNiw==", + "node_modules/read-binary-file-arch": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/read-binary-file-arch/-/read-binary-file-arch-1.0.6.tgz", + "integrity": "sha512-BNg9EN3DD3GsDXX7Aa8O4p92sryjkmzYYgmgTAc6CA4uGLEDzFfxOxugu21akOxpcXHiEgsYkC6nPsQvLLLmEg==", "dev": true, - "license": "BlueOak-1.0.0", + "license": "MIT", "dependencies": { - "@isaacs/fs-minipass": "^4.0.0", - "chownr": "^3.0.0", - "minipass": "^7.1.2", - "minizlib": "^3.1.0", - "yallist": "^5.0.0" + "debug": "^4.3.4" }, - "engines": { - "node": ">=18" + "bin": { + "read-binary-file-arch": "cli.js" } }, - "node_modules/tar-stream": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-3.2.0.tgz", - "integrity": "sha512-ojzvCvVaNp6aOTFmG7jaRD0meowIAuPc3cMMhSgKiVWws1GyHbGd/xvnyuRKcKlMpt3qvxx6r0hreCNITP9hIg==", + "node_modules/readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "devOptional": true, "license": "MIT", "dependencies": { - "b4a": "^1.6.4", - "bare-fs": "^4.5.5", - "fast-fifo": "^1.2.0", - "streamx": "^2.15.0" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } }, - "node_modules/tar/node_modules/yallist": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-5.0.0.tgz", - "integrity": "sha512-YgvUTfwqyc7UXVMrB+SImsVYSmTS8X/tSrtdNZMImM+n7+QTriRXyXim0mBrTXNeqzVF0KWGgHPeiyViFFrNDw==", - "dev": true, - "license": "BlueOak-1.0.0", - "engines": { - "node": ">=18" - } + "node_modules/readable-stream/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "devOptional": true, + "license": "MIT" }, - "node_modules/teex": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/teex/-/teex-1.0.1.tgz", - "integrity": "sha512-eYE6iEI62Ni1H8oIa7KlDU6uQBtqr4Eajni3wX7rpfXD8ysFx8z0+dri+KWEPWpBsxXfxu58x/0jvTVT1ekOSg==", + "node_modules/reflect.getprototypeof": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/reflect.getprototypeof/-/reflect.getprototypeof-1.0.10.tgz", + "integrity": "sha512-00o4I+DVrefhv+nX0ulyi3biSHCPDe+yLv5o/p6d/UVlirijB8E16FtfwSAi4g3tcqrQ4lRAqQSoFEZJehYEcw==", "license": "MIT", "dependencies": { - "streamx": "^2.12.5" + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.9", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.0.0", + "get-intrinsic": "^1.2.7", + "get-proto": "^1.0.1", + "which-builtin-type": "^1.2.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/temp": { - "version": "0.9.4", - "resolved": "https://registry.npmjs.org/temp/-/temp-0.9.4.tgz", - "integrity": "sha512-yYrrsWnrXMcdsnu/7YMYAofM1ktpL5By7vZhf15CrXijWWrEYZks5AXBudalfSWJLlnen/QUJUB5aoB0kqZUGA==", - "dev": true, + "node_modules/regexp.prototype.flags": { + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.4.tgz", + "integrity": "sha512-dYqgNSZbDwkaJ2ceRd9ojCGjBq+mOm9LmtXnAnEGyHhN/5R7iDW2TRw3h+o/jCFxus3P2LfWIIiwowAjANm7IA==", "license": "MIT", - "peer": true, "dependencies": { - "mkdirp": "^0.5.1", - "rimraf": "~2.6.2" + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "es-errors": "^1.3.0", + "get-proto": "^1.0.1", + "gopd": "^1.2.0", + "set-function-name": "^2.0.2" }, "engines": { - "node": ">=6.0.0" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/temp-file": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/temp-file/-/temp-file-3.4.0.tgz", - "integrity": "sha512-C5tjlC/HCtVUOi3KWVokd4vHVViOmGjtLwIh4MuzPo/nMYTV/p1urt3RnMz2IWXDdKEGJH3k5+KPxtqRsUYGtg==", - "dev": true, + "node_modules/remark-gfm": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/remark-gfm/-/remark-gfm-4.0.1.tgz", + "integrity": "sha512-1quofZ2RQ9EWdeN34S79+KExV1764+wCUGop5CPL1WGdD0ocPpu91lzPGbwWMECpEpd42kJGQwzRfyov9j4yNg==", "license": "MIT", "dependencies": { - "async-exit-hook": "^2.0.1", - "fs-extra": "^10.0.0" + "@types/mdast": "^4.0.0", + "mdast-util-gfm": "^3.0.0", + "micromark-extension-gfm": "^3.0.0", + "remark-parse": "^11.0.0", + "remark-stringify": "^11.0.0", + "unified": "^11.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/text-decoder": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/text-decoder/-/text-decoder-1.2.7.tgz", - "integrity": "sha512-vlLytXkeP4xvEq2otHeJfSQIRyWxo/oZGEbXrtEEF9Hnmrdly59sUbzZ/QgyWuLYHctCHxFF4tRQZNQ9k60ExQ==", - "license": "Apache-2.0", + "node_modules/remark-mdx": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/remark-mdx/-/remark-mdx-3.1.1.tgz", + "integrity": "sha512-Pjj2IYlUY3+D8x00UJsIOg5BEvfMyeI+2uLPn9VO9Wg4MEtN/VTIq2NEJQfde9PnX15KgtHyl9S0BcTnWrIuWg==", + "license": "MIT", "dependencies": { - "b4a": "^1.6.4" + "mdast-util-mdx": "^3.0.0", + "micromark-extension-mdxjs": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/tiny-async-pool": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/tiny-async-pool/-/tiny-async-pool-1.3.0.tgz", - "integrity": "sha512-01EAw5EDrcVrdgyCLgoSPvqznC0sVxDSVeiOz09FUpjh71G79VCqneOr+xvt7T1r76CF6ZZfPjHorN2+d+3mqA==", - "dev": true, + "node_modules/remark-parse": { + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/remark-parse/-/remark-parse-11.0.0.tgz", + "integrity": "sha512-FCxlKLNGknS5ba/1lmpYijMUzX2esxW5xQqjWxw2eHFfS2MSdaHVINFmhjo+qN1WhZhNimq0dZATN9pH0IDrpA==", "license": "MIT", "dependencies": { - "semver": "^5.5.0" + "@types/mdast": "^4.0.0", + "mdast-util-from-markdown": "^2.0.0", + "micromark-util-types": "^2.0.0", + "unified": "^11.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/tiny-async-pool/node_modules/semver": { - "version": "5.7.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", - "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver" + "node_modules/remark-stringify": { + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/remark-stringify/-/remark-stringify-11.0.0.tgz", + "integrity": "sha512-1OSmLd3awB/t8qdoEOMazZkNsfVTeY4fTsgzcQFdXNq8ToTN4ZGwrMnlda4K6smTFKD+GRV6O48i6Z4iKgPPpw==", + "license": "MIT", + "dependencies": { + "@types/mdast": "^4.0.0", + "mdast-util-to-markdown": "^2.0.0", + "unified": "^11.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/tiny-typed-emitter": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/tiny-typed-emitter/-/tiny-typed-emitter-2.1.0.tgz", - "integrity": "sha512-qVtvMxeXbVej0cQWKqVSSAHmKZEHAvxdF8HEUBFWts8h+xEo5m/lEiPakuyZ3BnCBjOD8i24kzNOiOLLgsSxhA==", - "license": "MIT" - }, - "node_modules/tinybench": { - "version": "2.9.0", - "resolved": "https://registry.npmjs.org/tinybench/-/tinybench-2.9.0.tgz", - "integrity": "sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==", + "node_modules/require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } }, - "node_modules/tinyexec": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-1.3.1.tgz", - "integrity": "sha512-GCvB3aoys96IuDFBMcTB46JOR6mdMtAToqwiW8JlWhsoh1mhHi/xn9ss/Dg7N555GiJyEt2qzoG/NHCwM6h1EA==", - "dev": true, + "node_modules/require-from-string": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", + "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", "license": "MIT", "engines": { - "node": ">=18" + "node": ">=0.10.0" } }, - "node_modules/tinyglobby": { - "version": "0.2.17", - "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.17.tgz", - "integrity": "sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g==", + "node_modules/resedit": { + "version": "1.7.2", + "resolved": "https://registry.npmjs.org/resedit/-/resedit-1.7.2.tgz", + "integrity": "sha512-vHjcY2MlAITJhC0eRD/Vv8Vlgmu9Sd3LX9zZvtGzU5ZImdTN3+d6e/4mnTyV8vEbyf1sgNIrWxhWlrys52OkEA==", "dev": true, "license": "MIT", "dependencies": { - "fdir": "^6.5.0", - "picomatch": "^4.0.4" + "pe-library": "^0.4.1" }, "engines": { - "node": ">=12.0.0" + "node": ">=12", + "npm": ">=6" }, "funding": { - "url": "https://github.com/sponsors/SuperchupuDev" + "type": "github", + "url": "https://github.com/sponsors/jet2jet" } }, - "node_modules/tinyrainbow": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/tinyrainbow/-/tinyrainbow-3.1.0.tgz", - "integrity": "sha512-Bf+ILmBgretUrdJxzXM0SgXLZ3XfiaUuOj/IKQHuTXip+05Xn+uyEYdVg0kYDipTBcLrCVyUzAPz7QmArb0mmw==", + "node_modules/resolve-alpn": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/resolve-alpn/-/resolve-alpn-1.2.1.tgz", + "integrity": "sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g==", + "dev": true, + "license": "MIT" + }, + "node_modules/responselike": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/responselike/-/responselike-2.0.1.tgz", + "integrity": "sha512-4gl03wn3hj1HP3yzgdI7d3lCkF95F21Pz4BPGvKHinyQzALR5CapwC8yIi0Rh58DEMQ/SguC03wFj2k0M/mHhw==", "dev": true, "license": "MIT", - "engines": { - "node": ">=14.0.0" + "dependencies": { + "lowercase-keys": "^2.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/tmp": { - "version": "0.2.7", - "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.2.7.tgz", - "integrity": "sha512-e0votIpp4Uo2AJYSzVHV6xCcawuiez3DzqDAbrTc3YxBkplN6e+dM13ZeIcZnDg/QpSuU2zfZ3rzwY8ukEnaXw==", - "dev": true, + "node_modules/retry": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.13.1.tgz", + "integrity": "sha512-XQBQ3I8W1Cge0Seh+6gjj03LbmRFWuoszgK9ooCpwYIrhhoO80pfq4cUkU5DkknwfOfFteRwlZ56PYOGYyFWdg==", "license": "MIT", "engines": { - "node": ">=14.14" + "node": ">= 4" } }, - "node_modules/tmp-promise": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/tmp-promise/-/tmp-promise-3.0.3.tgz", - "integrity": "sha512-RwM7MoPojPxsOBYnyd2hy0bxtIlVrihNs9pj5SUvY8Zz1sQcQG2tG1hSr8PDxfgEB8RNKDhqbIlroIarSNDNsQ==", + "node_modules/rimraf": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", + "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", + "deprecated": "Rimraf versions prior to v4 are no longer supported", "dev": true, - "license": "MIT", + "license": "ISC", + "peer": true, "dependencies": { - "tmp": "^0.2.0" + "glob": "^7.1.3" + }, + "bin": { + "rimraf": "bin.js" } }, - "node_modules/to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "node_modules/roarr": { + "version": "2.15.4", + "resolved": "https://registry.npmjs.org/roarr/-/roarr-2.15.4.tgz", + "integrity": "sha512-CHhPh+UNHD2GTXNYhPWLnU8ONHdI+5DI+4EYIAOaiD63rHeYlZvyh8P+in5999TTSFgUYuKUAjzRI4mdh/p+2A==", "dev": true, - "license": "MIT", + "license": "BSD-3-Clause", + "optional": true, "dependencies": { - "is-number": "^7.0.0" + "boolean": "^3.0.1", + "detect-node": "^2.0.4", + "globalthis": "^1.0.1", + "json-stringify-safe": "^5.0.1", + "semver-compare": "^1.0.0", + "sprintf-js": "^1.1.2" }, "engines": { "node": ">=8.0" } }, - "node_modules/trough": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/trough/-/trough-2.2.0.tgz", - "integrity": "sha512-tmMpK00BjZiUyVyvrBK7knerNgmgvcV/KLVyuma/SC+TQN167GrMRciANTz09+k3zW8L8t60jWO1GpfkZdjTaw==", + "node_modules/rolldown": { + "version": "1.2.19", + "resolved": "https://registry.npmjs.org/rolldown/-/rolldown-1.2.19.tgz", + "integrity": "sha512-QIiV1J9d0pzN4jeeTH4sjPy0AZ6cAy2cG0ExeoE1+U8Rvj+hR3gYkokx0YbeUNGlZqiQJJ2utcETe0oKXwzsuA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@oxc-project/types": "=0.156.0", + "@rolldown/pluginutils": "^1.0.0" + }, + "bin": { + "rolldown": "bin/cli.mjs" + }, + "engines": { + "node": "^20.19.0 || >=22.12.0" + }, + "optionalDependencies": { + "@rolldown/binding-android-arm-eabi": "1.2.19", + "@rolldown/binding-android-arm64": "1.2.19", + "@rolldown/binding-darwin-arm64": "1.2.19", + "@rolldown/binding-darwin-x64": "1.2.19", + "@rolldown/binding-freebsd-x64": "1.2.19", + "@rolldown/binding-linux-arm-gnueabihf": "1.2.19", + "@rolldown/binding-linux-arm64-gnu": "1.2.19", + "@rolldown/binding-linux-arm64-musl": "1.2.19", + "@rolldown/binding-linux-ppc64-gnu": "1.2.19", + "@rolldown/binding-linux-s390x-gnu": "1.2.19", + "@rolldown/binding-linux-x64-gnu": "1.2.19", + "@rolldown/binding-linux-x64-musl": "1.2.19", + "@rolldown/binding-openharmony-arm64": "1.2.19", + "@rolldown/binding-wasm32-wasi": "1.2.19", + "@rolldown/binding-win32-arm64-msvc": "1.2.19", + "@rolldown/binding-win32-x64-msvc": "1.2.19" + } + }, + "node_modules/router": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/router/-/router-2.3.0.tgz", + "integrity": "sha512-bpowRfGjEPe8t9R6fJIzhwmyCGAXwKvxBUsgJm+bJukwdcWmUXbMo7p22w7aYmQBPQTUMNqMV39YX0kMou3z8w==", "license": "MIT", + "dependencies": { + "debug": "^4.4.0", + "depd": "^2.0.0", + "is-promise": "^4.0.0", + "parseurl": "^1.3.3", + "path-to-regexp": "^8.0.0" + }, + "engines": { + "node": ">= 18" + }, "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/truncate-utf8-bytes": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/truncate-utf8-bytes/-/truncate-utf8-bytes-1.0.2.tgz", - "integrity": "sha512-95Pu1QXQvruGEhv62XCMO3Mm90GscOCClvrIUwCM0PYOXK3kaF3l3sIHxx71ThJfcbM2O5Au6SO3AWCSEfW4mQ==", - "dev": true, - "license": "WTFPL", + "node_modules/safe-array-concat": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.1.4.tgz", + "integrity": "sha512-wtZlHyOje6OZTGqAoaDKxFkgRtkF9CnHAVnCHKfuj200wAgL+bSJhdsCD2l0Qx/2ekEXjPWcyKkfGb5CPboslg==", + "license": "MIT", "dependencies": { - "utf8-byte-length": "^1.0.1" + "call-bind": "^1.0.9", + "call-bound": "^1.0.4", + "get-intrinsic": "^1.3.0", + "has-symbols": "^1.1.0", + "isarray": "^2.0.5" + }, + "engines": { + "node": ">=0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/ts-algebra": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ts-algebra/-/ts-algebra-2.0.0.tgz", - "integrity": "sha512-FPAhNPFMrkwz76P7cdjdmiShwMynZYN6SgOujD1urY4oNm80Ou9oMdmbR45LotcKOXoy7wSmHkRFE6Mxbrhefw==", + "node_modules/safe-array-concat/node_modules/isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", "license": "MIT" }, - "node_modules/ts-api-utils": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/ts-api-utils/-/ts-api-utils-2.5.0.tgz", - "integrity": "sha512-OJ/ibxhPlqrMM0UiNHJ/0CKQkoKF243/AEmplt3qpRgkW8VG7IfOS41h7V8TjITqdByHzrjcS/2si+y4lIh8NA==", - "dev": true, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/safe-push-apply": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-push-apply/-/safe-push-apply-1.0.0.tgz", + "integrity": "sha512-iKE9w/Z7xCzUMIZqdBsp6pEQvwuEebH4vdpjcDWnyzaI6yl6O9FHvVpmGelvEHNsoY6wGblkxR6Zty/h00WiSA==", "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "isarray": "^2.0.5" + }, "engines": { - "node": ">=18.12" + "node": ">= 0.4" }, - "peerDependencies": { - "typescript": ">=4.8.4" + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/tslib": { - "version": "2.8.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", - "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", - "license": "0BSD" + "node_modules/safe-push-apply/node_modules/isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", + "license": "MIT" }, - "node_modules/tsx": { - "version": "4.23.12", - "resolved": "https://registry.npmjs.org/tsx/-/tsx-4.23.12.tgz", - "integrity": "sha512-FDf4L4sYzKtzWYhU/Xm0AQFdTjdIxNo9ElTf2mxXM6k8YMHXzYUe4yODVaXP4V9uMFbVg8c0qyBccK2OOxb45Q==", + "node_modules/safe-regex-test": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.1.0.tgz", + "integrity": "sha512-x/+Cz4YrimQxQccJf5mKEbIa1NzeCRNI5Ecl/ekmlYaampdNLPalVyIcCZNNH3MvmqBugV5TMYZXv0ljslUlaw==", "license": "MIT", "dependencies": { - "esbuild": "~0.28.0" + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "is-regex": "^1.2.1" }, - "bin": { - "tsx": "dist/cli.mjs" + "engines": { + "node": ">= 0.4" }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "license": "MIT" + }, + "node_modules/sanitize-filename": { + "version": "1.6.5", + "resolved": "https://registry.npmjs.org/sanitize-filename/-/sanitize-filename-1.6.5.tgz", + "integrity": "sha512-+dVApt46/oAFWRP0KBSnYNLRw1peY7o/b12tmpllPNFpjfwkPuZut1+DiKaD9zYx5r2SHwc+XMLSBaDiyUJw3g==", + "dev": true, + "license": "WTFPL OR ISC", + "dependencies": { + "truncate-utf8-bytes": "^1.0.0" + } + }, + "node_modules/sax": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.6.1.tgz", + "integrity": "sha512-42tBVwLWnaQvW5zc4HbZrTuWccECCZfBi92FDuwtqxasH+JbPB3/FOKb1m222K42R4WxuxzzMsTswfzgtSu64Q==", + "license": "BlueOak-1.0.0", "engines": { - "node": ">=18.0.0" + "node": ">=11.0.0" + } + }, + "node_modules/saxes": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/saxes/-/saxes-5.0.1.tgz", + "integrity": "sha512-5LBh1Tls8c9xgGjw3QrMwETmTMVk0oFgvrFSvWx62llR2hcEInrKNZ2GZCCuuy2lvWrdl5jhbpeqc5hRYKFOcw==", + "license": "ISC", + "dependencies": { + "xmlchars": "^2.2.0" }, - "optionalDependencies": { - "fsevents": "~2.3.3" + "engines": { + "node": ">=10" } }, - "node_modules/tsx/node_modules/@esbuild/aix-ppc64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.28.2.tgz", - "integrity": "sha512-XExcO+dvLKvVtNTibSTBej1NCAbaGhWn9Ww1ZPx80qsahhPFe/8jgWP0IchNe0F3HwkU7n8ejhH8bjonqht8mQ==", - "cpu": [ - "ppc64" - ], - "license": "MIT", - "optional": true, - "os": [ - "aix" - ], + "node_modules/scheduler": { + "version": "0.28.0", + "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.28.0.tgz", + "integrity": "sha512-juorfCmIkIw8tT+p5BXSm6PJjQF/ycEYmKyzURCIt/RaZIhL+PulbQ9Yu2z1HdOJDdqDTlxA1+xKBmHXJsczAw==", + "dev": true, + "license": "MIT" + }, + "node_modules/semver": { + "version": "7.8.5", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.8.5.tgz", + "integrity": "sha512-Y7/KDsb8LjooZpwaqGyulO6DQlksgCncchHGk+sZIY4SBvUocMBEFH5Ur1fI4dV+Jvl0w6cjvucaIi40puRioA==", + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, "engines": { - "node": ">=18" + "node": ">=10" } }, - "node_modules/tsx/node_modules/@esbuild/android-arm": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.28.2.tgz", - "integrity": "sha512-kXXoiPVVGQcnIYGOeaovwOURpniDBpSq4A03qkQ+BMQqtGG6HYap3xne9C1O1yo4TR3qxlCX5IqqmX6fFo2Lqg==", - "cpu": [ - "arm" - ], + "node_modules/semver-compare": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/semver-compare/-/semver-compare-1.0.0.tgz", + "integrity": "sha512-YM3/ITh2MJ5MtzaM429anh+x2jiLVjqILF4m4oyQB18W7Ggea7BfqdH/wGMK7dDiMghv/6WG7znWMwUDzJiXow==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "android" - ], - "engines": { - "node": ">=18" - } + "optional": true }, - "node_modules/tsx/node_modules/@esbuild/android-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.28.2.tgz", - "integrity": "sha512-5YfKeeI8qWfBZIX+u2xZC3Zlb3Os/gLS2sbEKM+I4ZOcsWmHS2WLysCcQZDAFRslDUU5Oiq44gf6PYN1vGwG5A==", - "cpu": [ - "arm64" - ], + "node_modules/send": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/send/-/send-1.2.1.tgz", + "integrity": "sha512-1gnZf7DFcoIcajTjTwjwuDjzuz4PPcY2StKPlsGAQ1+YH20IRVrBaXSWmdjowTJ6u8Rc01PoYOGHXfP1mYcZNQ==", "license": "MIT", - "optional": true, - "os": [ - "android" - ], + "dependencies": { + "debug": "^4.4.3", + "encodeurl": "^2.0.0", + "escape-html": "^1.0.3", + "etag": "^1.8.1", + "fresh": "^2.0.0", + "http-errors": "^2.0.1", + "mime-types": "^3.0.2", + "ms": "^2.1.3", + "on-finished": "^2.4.1", + "range-parser": "^1.2.1", + "statuses": "^2.0.2" + }, "engines": { - "node": ">=18" + "node": ">= 18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/tsx/node_modules/@esbuild/android-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.28.2.tgz", - "integrity": "sha512-O387ite7SzUyCcy3JQX4P4bLtEA7bLLkx+esve5JHnyYfNTxcVpXZo9jhdB0lTKN44gztELTdU7nS8Nr16Fs1Q==", - "cpu": [ - "x64" - ], + "node_modules/send/node_modules/mime-db": { + "version": "1.54.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", + "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", "license": "MIT", - "optional": true, - "os": [ - "android" - ], "engines": { - "node": ">=18" + "node": ">= 0.6" } }, - "node_modules/tsx/node_modules/@esbuild/darwin-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.28.2.tgz", - "integrity": "sha512-n4KqkOQrraxHJcgjM1RvwbigfQKIKJVpM7xp+KsxiyUSrRdIXnt73VhrPAx0fV44hgfmIVKjxMN9J1t5jySVkw==", - "cpu": [ - "arm64" - ], + "node_modules/send/node_modules/mime-types": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.2.tgz", + "integrity": "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==", "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], + "dependencies": { + "mime-db": "^1.54.0" + }, "engines": { "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/tsx/node_modules/@esbuild/darwin-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.28.2.tgz", - "integrity": "sha512-uq6suIWYP37qzGddBKPw5QEQPi6HiLGsO7UmkpfyaYNQ3D+rN6w6WfwH+nuqcGXWvawGwxOEroO4YGnFh95azw==", - "cpu": [ - "x64" - ], + "node_modules/serialize-error": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/serialize-error/-/serialize-error-8.1.0.tgz", + "integrity": "sha512-3NnuWfM6vBYoy5gZFvHiYsVbafvI9vZv/+jlIigFn4oP4zjNPK3LhcY0xSCgeb1a5L8jO71Mit9LlNoi2UfDDQ==", "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], + "dependencies": { + "type-fest": "^0.20.2" + }, "engines": { - "node": ">=18" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/tsx/node_modules/@esbuild/freebsd-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.28.2.tgz", - "integrity": "sha512-n+I0BTSRIoy+d6RPKnEVwql5UwBJolytvY4mAOIEJorKlqgPII8ix6slVVrfZ5Tnj7glIZvloylbB/EJPMWEXw==", - "cpu": [ - "arm64" - ], + "node_modules/serve-static": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-2.2.1.tgz", + "integrity": "sha512-xRXBn0pPqQTVQiC8wyQrKs2MOlX24zQ0POGaj0kultvoOCstBQM5yvOhAVSUwOMjQtTvsPWoNCHfPGwaaQJhTw==", "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], + "dependencies": { + "encodeurl": "^2.0.0", + "escape-html": "^1.0.3", + "parseurl": "^1.3.3", + "send": "^1.2.0" + }, "engines": { - "node": ">=18" + "node": ">= 18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/tsx/node_modules/@esbuild/freebsd-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.28.2.tgz", - "integrity": "sha512-78XJTJkvPs0kz2w61301PJjXl4g7q3JqiYMZ/M/yVI73EHBrCRTgkhu9oqG7vPqq+a/yadEW8aD+agKlk5xrmg==", - "cpu": [ - "x64" - ], + "node_modules/set-function-length": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", + "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], + "dependencies": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.2" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" } }, - "node_modules/tsx/node_modules/@esbuild/linux-arm": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.28.2.tgz", - "integrity": "sha512-XlDnu2q5yoqems+xay6wSAcg9DDD7K9RLKZEBOMZm3ckNpJBvOX20tSfby8KfrrhINDyv9V2YVZKY/SpoGJI8w==", - "cpu": [ - "arm" - ], + "node_modules/set-function-name": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.2.tgz", + "integrity": "sha512-7PGFlmtwsEADb0WYyvCMa1t+yke6daIG4Wirafur5kcf+MhUnPms1UeR0CKQdTZD81yESwMHbtn+TR+dMviakQ==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.2" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" } }, - "node_modules/tsx/node_modules/@esbuild/linux-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.28.2.tgz", - "integrity": "sha512-pW4AC0P3it8c7do9MVM4p51FzHzdM/TZrerurgRcHJ2WTa1VQ1CIq18xncfpBJw4ojkiZZrKW2yIBWBP92j6Ug==", - "cpu": [ - "arm64" - ], + "node_modules/set-proto": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/set-proto/-/set-proto-1.0.0.tgz", + "integrity": "sha512-RJRdvCo6IAnPdsvP/7m6bsQqNnn1FCBX5ZNtFL98MmFF/4xAIJTIg1YbHW5DC2W5SKZanrC6i4HsJqlajw/dZw==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "dunder-proto": "^1.0.1", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.0.0" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" } }, - "node_modules/tsx/node_modules/@esbuild/linux-ia32": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.28.2.tgz", - "integrity": "sha512-CYbnj78HsIeA+DhgUKgFCfvNsTHFhMMrinUrMZpDXJXKN8T3XViTZ/+wtHeVxEWY8ewSzTFN+nRmSwO2tZaLUQ==", - "cpu": [ - "ia32" - ], + "node_modules/setimmediate": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", + "integrity": "sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "optional": true + }, + "node_modules/setprototypeof": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", + "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", + "license": "ISC" + }, + "node_modules/sharp": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/sharp/-/sharp-0.35.5.tgz", + "integrity": "sha512-Ywn4OnzGukp7CDMrp08RQ50YKmuwG47brZgIVPTvBaaAfQlRlygrRqSrxdCiL9M+LlzLBiJ68IR1QqvzHyjC7g==", + "license": "Apache-2.0", + "dependencies": { + "@img/colour": "^1.1.0", + "detect-libc": "^2.1.2", + "semver": "^7.8.5" + }, "engines": { - "node": ">=18" + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-darwin-arm64": "0.35.5", + "@img/sharp-darwin-x64": "0.35.5", + "@img/sharp-freebsd-wasm32": "0.35.5", + "@img/sharp-libvips-darwin-arm64": "1.3.4", + "@img/sharp-libvips-darwin-x64": "1.3.4", + "@img/sharp-libvips-linux-arm": "1.3.4", + "@img/sharp-libvips-linux-arm64": "1.3.4", + "@img/sharp-libvips-linux-ppc64": "1.3.4", + "@img/sharp-libvips-linux-riscv64": "1.3.4", + "@img/sharp-libvips-linux-s390x": "1.3.4", + "@img/sharp-libvips-linux-x64": "1.3.4", + "@img/sharp-libvips-linuxmusl-arm64": "1.3.4", + "@img/sharp-libvips-linuxmusl-x64": "1.3.4", + "@img/sharp-linux-arm": "0.35.5", + "@img/sharp-linux-arm64": "0.35.5", + "@img/sharp-linux-ppc64": "0.35.5", + "@img/sharp-linux-riscv64": "0.35.5", + "@img/sharp-linux-s390x": "0.35.5", + "@img/sharp-linux-x64": "0.35.5", + "@img/sharp-linuxmusl-arm64": "0.35.5", + "@img/sharp-linuxmusl-x64": "0.35.5", + "@img/sharp-webcontainers-wasm32": "0.35.5", + "@img/sharp-win32-arm64": "0.35.5", + "@img/sharp-win32-ia32": "0.35.5", + "@img/sharp-win32-x64": "0.35.5" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } } }, - "node_modules/tsx/node_modules/@esbuild/linux-loong64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.28.2.tgz", - "integrity": "sha512-buwkd8nsph4R+ajRvw0qM5Hja/TXQow3ptzWO2EbG/cqcIkHloRrdlBtQlshyYGTNFvfkfJ5tpPLVkY4DtsPfQ==", - "cpu": [ - "loong64" - ], + "node_modules/shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "shebang-regex": "^3.0.0" + }, "engines": { - "node": ">=18" + "node": ">=8" } }, - "node_modules/tsx/node_modules/@esbuild/linux-mips64el": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.28.2.tgz", - "integrity": "sha512-ZVykbDyk7519VwiNb9Lcj9m8XM6v5V9uKPvrEMkkEedVewf+0itkhahp4HDpgERXhwLRpWFypsGbG/J8s0QjJA==", - "cpu": [ - "mips64el" - ], + "node_modules/shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], "engines": { - "node": ">=18" + "node": ">=8" } }, - "node_modules/tsx/node_modules/@esbuild/linux-ppc64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.28.2.tgz", - "integrity": "sha512-CAXl+Dtd9UUuJd8pKKdwh6MLm3MUMiqMPmhZ3tTSXPqfyQ3vDl6R5hZdZ/kYojK4ofXtdfSv1tFq8XzWx3heNQ==", - "cpu": [ - "ppc64" - ], + "node_modules/side-channel": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.1.tgz", + "integrity": "sha512-6x6dK6zJdpTzF4sQeNYxwtvBzf6Eg4GtlesS94HOvTudUeyK2WXAaIfmDgsyslYrRBeFIlsi54AYsFGUuhmvrQ==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.4", + "side-channel-list": "^1.0.1", + "side-channel-map": "^1.0.1", + "side-channel-weakmap": "^1.0.2" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/tsx/node_modules/@esbuild/linux-riscv64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.28.2.tgz", - "integrity": "sha512-GeXCej4IQtU1B+QlDV8W/RRvbzI3O/Stss+/bCXv4lZls5WGRtu2a+3JkA3i4qIUlMXpcHebWpF8AkJhATowuA==", - "cpu": [ - "riscv64" - ], + "node_modules/side-channel-list": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.1.tgz", + "integrity": "sha512-mjn/0bi/oUURjc5Xl7IaWi/OJJJumuoJFQJfDDyO46+hBWsfaVM65TBHq2eoZBhzl9EchxOijpkbRC8SVBQU0w==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.4" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/tsx/node_modules/@esbuild/linux-s390x": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.28.2.tgz", - "integrity": "sha512-3H1weTYZPxt/WOhByszQZybS9w5lKzUn1FDMsgEChbHWQwHYQQRfBxgCcZvPhjHfKyJjIievvMmEUawJrdY9Dg==", - "cpu": [ - "s390x" - ], + "node_modules/side-channel-map": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz", + "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/tsx/node_modules/@esbuild/linux-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.28.2.tgz", - "integrity": "sha512-4xTZr1FUmSoQW4XIWmit3tzQrUTZM+N3P0XV8xROKYF50XfI7xeO90+1bZvNwxIufQ9hDQVRJH5YhgPVF8A/HQ==", - "cpu": [ - "x64" - ], + "node_modules/side-channel-weakmap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz", + "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3", + "side-channel-map": "^1.0.1" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/tsx/node_modules/@esbuild/netbsd-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.28.2.tgz", - "integrity": "sha512-sSATRjPeDBg3pdgHoQfoYBob11Kk1FGa9lui5RIHZCoCkJa9QKlvl3/vKz2usCmYYjs7ymJR/2Nnsqe+Hjt5nw==", - "cpu": [ - "arm64" - ], + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "license": "ISC" + }, + "node_modules/simple-update-notifier": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/simple-update-notifier/-/simple-update-notifier-2.0.0.tgz", + "integrity": "sha512-a2B9Y0KlNXl9u/vsW6sTIu9vGEpfKu2wRV6l1H3XEas/0gUIzGzBoP/IouTcUQbm9JWZLH3COxyn03TYlFax6w==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], + "dependencies": { + "semver": "^7.5.3" + }, "engines": { - "node": ">=18" + "node": ">=10" } }, - "node_modules/tsx/node_modules/@esbuild/netbsd-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.28.2.tgz", - "integrity": "sha512-lqnzCV+mM0gIADaKihiCg6ifgfU2L3h5E33rNQBN1Y4MaVGnzryzmvvf7UHxprpQdE8hpqLolJ9Rl+SkIRDpyw==", - "cpu": [ - "x64" - ], + "node_modules/sisteransi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-2.0.0.tgz", + "integrity": "sha512-2WCqLdt12eN6ehLI50S2/ZxoowXU3DD1KVPRyVP0WEsFahrGZZmCdq1K59qjJljMRIDTwx1D9YaRK+hDneBUMg==", "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], "engines": { - "node": ">=18" + "node": ">=20" } }, - "node_modules/tsx/node_modules/@esbuild/openbsd-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.28.2.tgz", - "integrity": "sha512-AL2qJILH7lNjrDmCQDvdxMfAUIv8KMNZOvrwAQ8i8//ntL9FflhOyMJ8OZSMBb8/AWXe3/5v5S20y3zCoZWKoQ==", - "cpu": [ - "arm64" - ], + "node_modules/skillflag": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/skillflag/-/skillflag-0.2.1.tgz", + "integrity": "sha512-47lfgUr6xzgljtTD5XfJrS+6muNb9R44OEr+o31Nco2R65W1xOA8Pi6QSbLa90tDYE6TqW5Hrh3N1egserGrhQ==", "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], + "dependencies": { + "@clack/prompts": "^1.0.1", + "tar-stream": "^3.1.7" + }, + "bin": { + "skill-install": "dist/bin/skill-install.js", + "skillflag": "dist/bin/skillflag.js" + }, "engines": { "node": ">=18" } }, - "node_modules/tsx/node_modules/@esbuild/openbsd-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.28.2.tgz", - "integrity": "sha512-QtiuPytchRyC4rwUKhexJdQKvDuZ6hWloi3igqPQNUJCS1/v9EiO3UTOXR6A3FoMo4fnAKbWJdqaIwhOzh8qEw==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], + "node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true, + "license": "BSD-3-Clause", "engines": { - "node": ">=18" + "node": ">=0.10.0" } }, - "node_modules/tsx/node_modules/@esbuild/openharmony-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.28.2.tgz", - "integrity": "sha512-WkhYDmpTjLvGlScA1rwjRUmhl4k8oXR3cIbtqWmELgU/dFeHHlEllxDvdWcNJV9rbzCexB5vz8gtNewWLgCT7Q==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "openharmony" - ], + "node_modules/source-map-js": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.4.tgz", + "integrity": "sha512-J7ZjMvHd9O1fcT/5V09QWaaSl2BbWx3F6O08spde82Namf9UB0GxRVIPiNbVsdKkoizHiSpTodo3vp2bAy91MA==", + "dev": true, + "license": "BSD-3-Clause", "engines": { - "node": ">=18" + "node": ">=6.0.0" } }, - "node_modules/tsx/node_modules/@esbuild/sunos-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.28.2.tgz", - "integrity": "sha512-GPMSkTOtMnv2U2F8gxe4Io6qmVs+YKyp832Etqqxr0hFngmXQ3rzwytelm3GIn7T4VviRUlf3sOgBOiTdvaf7g==", - "cpu": [ - "x64" - ], + "node_modules/source-map-support": { + "version": "0.5.21", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz", + "integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "sunos" - ], - "engines": { - "node": ">=18" + "dependencies": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" } }, - "node_modules/tsx/node_modules/@esbuild/win32-arm64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.28.2.tgz", - "integrity": "sha512-PIhhEkE9uPBleRBrQEJpUn7MBnibZzbGzYWPmY3x+YoVg/95zbjB4CxPPOQ8l5tYYM4mMaCthF8/1DIfBQQyWQ==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" + "node_modules/sprintf-js": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.1.3.tgz", + "integrity": "sha512-Oo+0REFV59/rz3gfJNKQiBlwfHaSESl1pcGyABQsnnIfWOFt6JNj5gCog2U6MLZ//IGYD+nA8nI+mTShREReaA==", + "dev": true, + "license": "BSD-3-Clause", + "optional": true + }, + "node_modules/standardwebhooks": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/standardwebhooks/-/standardwebhooks-1.3.0.tgz", + "integrity": "sha512-5W9skHjqAm2dlA9wWvglTP+oX47JX4lFXVk1aJV7+TG1snvTR4QXaVgPscEzvOw9GRreeavMwbqEeL+MGhZHCg==", + "license": "MIT", + "dependencies": { + "@stablelib/base64": "^1.0.0", + "fast-sha256": "^1.3.0" } }, - "node_modules/tsx/node_modules/@esbuild/win32-ia32": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.28.2.tgz", - "integrity": "sha512-YmJbfTlvU7Sdn9BB+4PRES4oB6pxgS37MAONj+hBr/cpXS1aBPKXxNnDbu+QCWPj0o9dgyxeq79g6c5P8KeuYA==", - "cpu": [ - "ia32" - ], + "node_modules/stat-mode": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stat-mode/-/stat-mode-1.0.0.tgz", + "integrity": "sha512-jH9EhtKIjuXZ2cWxmXS8ZP80XyC3iasQxMDV8jzhNJpfDb7VbQLVW4Wvsxz9QZvzV+G4YoSfBUVKDOyxLzi/sg==", + "dev": true, "license": "MIT", - "optional": true, - "os": [ - "win32" - ], "engines": { - "node": ">=18" + "node": ">= 6" } }, - "node_modules/tsx/node_modules/@esbuild/win32-x64": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.28.2.tgz", - "integrity": "sha512-5ebpxr3nWMzrL/rnUI755Jkuee0bHL/Gq0WTF9lvcpv73wAp5eu8MfBUgWK9bhWvZjj7yX8etf/8tI8Ney695g==", - "cpu": [ - "x64" - ], + "node_modules/statuses": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.2.tgz", + "integrity": "sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==", "license": "MIT", - "optional": true, - "os": [ - "win32" - ], "engines": { - "node": ">=18" + "node": ">= 0.8" } }, - "node_modules/tsx/node_modules/esbuild": { - "version": "0.28.2", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.28.2.tgz", - "integrity": "sha512-HKVLS8dvII+xoKW9kmqxbRKrnWEXfJJr/FZhhJmiqIB0e053QNYFqOBouTMO/k5sID4MvCiUCvv8b9M4h32wIA==", - "hasInstallScript": true, + "node_modules/std-env": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/std-env/-/std-env-4.3.0.tgz", + "integrity": "sha512-OtU/EgQ1kIm5KwqQpBC6ZEMXrZRui11w8zgfTWp8cdO9B8OaPsbA8bTHO2P+HNo1VlUTGMVBwPhydu6poeXiag==", + "dev": true, + "license": "MIT" + }, + "node_modules/stop-iteration-iterator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.1.0.tgz", + "integrity": "sha512-eLoXW/DHyl62zxY4SCaIgnRhuMr6ri4juEYARS8E6sCEqzKpOiE521Ucofdx+KnDZl5xmvGYaaKCk5FEOxJCoQ==", "license": "MIT", - "bin": { - "esbuild": "bin/esbuild" + "dependencies": { + "es-errors": "^1.3.0", + "internal-slot": "^1.1.0" }, "engines": { - "node": ">=18" - }, - "optionalDependencies": { - "@esbuild/aix-ppc64": "0.28.2", - "@esbuild/android-arm": "0.28.2", - "@esbuild/android-arm64": "0.28.2", - "@esbuild/android-x64": "0.28.2", - "@esbuild/darwin-arm64": "0.28.2", - "@esbuild/darwin-x64": "0.28.2", - "@esbuild/freebsd-arm64": "0.28.2", - "@esbuild/freebsd-x64": "0.28.2", - "@esbuild/linux-arm": "0.28.2", - "@esbuild/linux-arm64": "0.28.2", - "@esbuild/linux-ia32": "0.28.2", - "@esbuild/linux-loong64": "0.28.2", - "@esbuild/linux-mips64el": "0.28.2", - "@esbuild/linux-ppc64": "0.28.2", - "@esbuild/linux-riscv64": "0.28.2", - "@esbuild/linux-s390x": "0.28.2", - "@esbuild/linux-x64": "0.28.2", - "@esbuild/netbsd-arm64": "0.28.2", - "@esbuild/netbsd-x64": "0.28.2", - "@esbuild/openbsd-arm64": "0.28.2", - "@esbuild/openbsd-x64": "0.28.2", - "@esbuild/openharmony-arm64": "0.28.2", - "@esbuild/sunos-x64": "0.28.2", - "@esbuild/win32-arm64": "0.28.2", - "@esbuild/win32-ia32": "0.28.2", - "@esbuild/win32-x64": "0.28.2" + "node": ">= 0.4" } }, - "node_modules/turndown": { - "version": "7.2.4", - "resolved": "https://registry.npmjs.org/turndown/-/turndown-7.2.4.tgz", - "integrity": "sha512-I8yFsfRzmzK0WV1pNNOA4A7y4RDfFxPRxb3t+e3ui14qSGOxGtiSP6GjeX+Y6CHb7HYaFj7ECUD7VE5kQMZWGQ==", + "node_modules/streamx": { + "version": "2.28.1", + "resolved": "https://registry.npmjs.org/streamx/-/streamx-2.28.1.tgz", + "integrity": "sha512-zEzXb0s5Cds7tqMH6rhZ05lcJydCWiQPEwiNngVqzsxCc962vLY4Uw+mW7od8kDH258k2Uz/JrOkdIAAhSh9VA==", "license": "MIT", "dependencies": { - "@mixmark-io/domino": "^2.2.0" - }, - "engines": { - "node": ">=18", - "npm": ">=9" + "events-universal": "^1.0.0", + "fast-fifo": "^1.3.2", + "text-decoder": "^1.1.0" } }, - "node_modules/type-check": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", - "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", + "node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "devOptional": true, + "license": "MIT", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/string_decoder/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "devOptional": true, + "license": "MIT" + }, + "node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", "dev": true, "license": "MIT", "dependencies": { - "prelude-ls": "^1.2.1" + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" }, "engines": { - "node": ">= 0.8.0" + "node": ">=8" } }, - "node_modules/type-fest": { - "version": "0.13.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.13.1.tgz", - "integrity": "sha512-34R7HTnG0XIJcBSn5XhDd7nNFPRcXYRZrBB2O2jdKqYODldSzBAqzsWoZYYvduky73toYS/ESqxPvkDf/F0XMg==", - "dev": true, - "license": "(MIT OR CC0-1.0)", - "optional": true, + "node_modules/string.prototype.trim": { + "version": "1.2.11", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.11.tgz", + "integrity": "sha512-PwvK7BU+CMTJGYQCTZb5RWXIML92lftJLhQz1tBzgKiqGxJaMlBAa48POXaNAC2s4y8jr3EFqrkF9+44neS46w==", + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.9", + "call-bound": "^1.0.4", + "define-data-property": "^1.1.4", + "define-properties": "^1.2.1", + "es-abstract": "^1.24.2", + "es-object-atoms": "^1.1.2", + "has-property-descriptors": "^1.0.2", + "safe-regex-test": "^1.1.0" + }, "engines": { - "node": ">=10" + "node": ">= 0.4" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/typebox": { - "version": "1.3.27", - "resolved": "https://registry.npmjs.org/typebox/-/typebox-1.3.27.tgz", - "integrity": "sha512-zu+jc1pcy4UiNThxikUr36f0Rybk9PEeCg/NE6adeWr/SKsdNO4EzZHYRDlv2YCVAfj3Odq3dESSo/jNyoBXzA==", - "license": "MIT" - }, - "node_modules/typed-array-buffer": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.3.tgz", - "integrity": "sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==", + "node_modules/string.prototype.trimend": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.10.tgz", + "integrity": "sha512-2+3aDAOmPTmuFwjDnmJG2ctEkQKVki7vOSqaxkv42Mowj1V6PnvuwFCRrR5lChUux1TBskPjfkeTOhqczDMxTw==", "license": "MIT", "dependencies": { - "call-bound": "^1.0.3", - "es-errors": "^1.3.0", - "is-typed-array": "^1.1.14" + "call-bind": "^1.0.9", + "call-bound": "^1.0.4", + "define-properties": "^1.2.1", + "es-object-atoms": "^1.1.2" }, "engines": { "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/typed-array-byte-length": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.3.tgz", - "integrity": "sha512-BaXgOuIxz8n8pIq3e7Atg/7s+DpiYrxn4vdot3w9KbnBhcRQq6o3xemQdIfynqSeXeDrF32x+WvfzmOjPiY9lg==", + "node_modules/string.prototype.trimstart": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.8.tgz", + "integrity": "sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==", "license": "MIT", "dependencies": { - "call-bind": "^1.0.8", - "for-each": "^0.3.3", - "gopd": "^1.2.0", - "has-proto": "^1.2.0", - "is-typed-array": "^1.1.14" + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-object-atoms": "^1.0.0" }, "engines": { "node": ">= 0.4" @@ -13006,918 +13099,881 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/typed-array-byte-offset": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.4.tgz", - "integrity": "sha512-bTlAFB/FBYMcuX81gbL4OcpH5PmlFHqlCCpAl8AlEzMz5k53oNDvN8p1PNOWLEmI2x4orp3raOFB51tv9X+MFQ==", + "node_modules/stringify-entities": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/stringify-entities/-/stringify-entities-4.0.5.tgz", + "integrity": "sha512-jNuI2fNNw5ecxrWmgm90R3iH0Kc/94AQwoQWoSUYphWzvmUA2pjFG34H56Z7Z3FkvH3FpYwwewKAa97oQnPFhw==", "license": "MIT", "dependencies": { - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.8", - "for-each": "^0.3.3", - "gopd": "^1.2.0", - "has-proto": "^1.2.0", - "is-typed-array": "^1.1.15", - "reflect.getprototypeof": "^1.0.9" + "character-entities-html4": "^2.0.0", + "character-entities-legacy": "^3.0.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, + "node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.1" }, "engines": { - "node": ">= 0.4" + "node": ">=8" + } + }, + "node_modules/sumchecker": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/sumchecker/-/sumchecker-3.0.1.tgz", + "integrity": "sha512-MvjXzkz/BOfyVDkG0oFOtBxHX2u3gKbMHIF/dXblZsgD3BWOFLmHovIpZY7BykJdAjcqRCBi1WYBNdEC9yI7vg==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "debug": "^4.1.0" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": ">= 8.0" + } + }, + "node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/tar": { + "version": "7.5.23", + "resolved": "https://registry.npmjs.org/tar/-/tar-7.5.23.tgz", + "integrity": "sha512-lkukzdoGngZHJZXxW4S/E4Fp9ghTDlyZXrQGRNoJ/LXvDKcXUTq2sg5yQe74po7Voea6n/IN09+wE/QvJMiifA==", + "dev": true, + "license": "BlueOak-1.0.0", + "dependencies": { + "@isaacs/fs-minipass": "^4.0.0", + "chownr": "^3.0.0", + "minipass": "^7.1.2", + "minizlib": "^3.1.0", + "yallist": "^5.0.0" + }, + "engines": { + "node": ">=18" } }, - "node_modules/typed-array-length": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.8.tgz", - "integrity": "sha512-phPGCwqr2+Qo0fwniCE8e4pKnGu/yFb5nD5Y8bf0EEeiI5GklnACYA9GFy/DrAeRrKHXvHn+1SUsOWgJp6RO+g==", + "node_modules/tar-stream": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-3.2.2.tgz", + "integrity": "sha512-+8NeqHRjQWH9nYlwo2gamAMImZCVzI4UoEgDpWorBt9OEfppiZn+uSkskzQKPWIZyji/C8fpWO7u69G0DX0tbg==", "license": "MIT", "dependencies": { - "call-bind": "^1.0.9", - "for-each": "^0.3.5", - "gopd": "^1.2.0", - "is-typed-array": "^1.1.15", - "possible-typed-array-names": "^1.1.0", - "reflect.getprototypeof": "^1.0.10" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "b4a": "^1.9.0", + "bare-fs": "^4.8.2", + "fast-fifo": "^1.3.2", + "streamx": "^2.28.1" } }, - "node_modules/typescript": { - "version": "5.9.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", - "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", + "node_modules/tar/node_modules/yallist": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-5.0.0.tgz", + "integrity": "sha512-YgvUTfwqyc7UXVMrB+SImsVYSmTS8X/tSrtdNZMImM+n7+QTriRXyXim0mBrTXNeqzVF0KWGgHPeiyViFFrNDw==", "dev": true, - "license": "Apache-2.0", - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, + "license": "BlueOak-1.0.0", "engines": { - "node": ">=14.17" + "node": ">=18" } }, - "node_modules/uhyphen": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/uhyphen/-/uhyphen-0.2.0.tgz", - "integrity": "sha512-qz3o9CHXmJJPGBdqzab7qAYuW8kQGKNEuoHFYrBwV6hWIMcpAmxDLXojcHfFr9US1Pe6zUswEIJIbLI610fuqA==", - "license": "ISC" - }, - "node_modules/unbox-primitive": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.1.0.tgz", - "integrity": "sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw==", + "node_modules/teex": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/teex/-/teex-1.0.1.tgz", + "integrity": "sha512-eYE6iEI62Ni1H8oIa7KlDU6uQBtqr4Eajni3wX7rpfXD8ysFx8z0+dri+KWEPWpBsxXfxu58x/0jvTVT1ekOSg==", "license": "MIT", "dependencies": { - "call-bound": "^1.0.3", - "has-bigints": "^1.0.2", - "has-symbols": "^1.1.0", - "which-boxed-primitive": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "streamx": "^2.12.5" } }, - "node_modules/undici": { - "version": "7.28.0", - "resolved": "https://registry.npmjs.org/undici/-/undici-7.28.0.tgz", - "integrity": "sha512-cRZYrTDwWznlnRiPjggAGxZXanty6M8RV1ff8Wm4LWXBp7/IG8v5DnOm74DtUBp9OONpK75YlPnIjQqX0dBDtA==", + "node_modules/temml": { + "version": "0.13.5", + "resolved": "https://registry.npmjs.org/temml/-/temml-0.13.5.tgz", + "integrity": "sha512-aPkDDgunanpLNL0ql32HbolqLep+w8DRcVXRql7rWrMt/PhczdLgL4UBYYVU3BYjCNjkGq4EqwIicu/zWr1iOg==", "license": "MIT", "optional": true, "engines": { - "node": ">=20.18.1" + "node": ">=18.13.0" } }, - "node_modules/undici-types": { - "version": "6.21.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", - "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", - "license": "MIT" - }, - "node_modules/unified": { - "version": "11.0.5", - "resolved": "https://registry.npmjs.org/unified/-/unified-11.0.5.tgz", - "integrity": "sha512-xKvGhPWw3k84Qjh8bI3ZeJjqnyadK+GEFtazSfZv/rKeTkTjOJho6mFqh2SM96iIcZokxiOpg78GazTSg8+KHA==", + "node_modules/temp": { + "version": "0.9.4", + "resolved": "https://registry.npmjs.org/temp/-/temp-0.9.4.tgz", + "integrity": "sha512-yYrrsWnrXMcdsnu/7YMYAofM1ktpL5By7vZhf15CrXijWWrEYZks5AXBudalfSWJLlnen/QUJUB5aoB0kqZUGA==", + "dev": true, "license": "MIT", + "peer": true, "dependencies": { - "@types/unist": "^3.0.0", - "bail": "^2.0.0", - "devlop": "^1.0.0", - "extend": "^3.0.0", - "is-plain-obj": "^4.0.0", - "trough": "^2.0.0", - "vfile": "^6.0.0" + "mkdirp": "^0.5.1", + "rimraf": "~2.6.2" }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "engines": { + "node": ">=6.0.0" } }, - "node_modules/unist-util-is": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-6.0.1.tgz", - "integrity": "sha512-LsiILbtBETkDz8I9p1dQ0uyRUWuaQzd/cuEeS1hoRSyW5E5XGmTzlwY1OrNzzakGowI9Dr/I8HVaw4hTtnxy8g==", + "node_modules/temp-file": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/temp-file/-/temp-file-3.4.0.tgz", + "integrity": "sha512-C5tjlC/HCtVUOi3KWVokd4vHVViOmGjtLwIh4MuzPo/nMYTV/p1urt3RnMz2IWXDdKEGJH3k5+KPxtqRsUYGtg==", + "dev": true, "license": "MIT", "dependencies": { - "@types/unist": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "async-exit-hook": "^2.0.1", + "fs-extra": "^10.0.0" } }, - "node_modules/unist-util-position-from-estree": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/unist-util-position-from-estree/-/unist-util-position-from-estree-2.0.0.tgz", - "integrity": "sha512-KaFVRjoqLyF6YXCbVLNad/eS4+OfPQQn2yOd7zF/h5T/CSL2v8NpN6a5TPvtbXthAGw5nG+PuTtq+DdIZr+cRQ==", - "license": "MIT", + "node_modules/text-decoder": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/text-decoder/-/text-decoder-1.2.7.tgz", + "integrity": "sha512-vlLytXkeP4xvEq2otHeJfSQIRyWxo/oZGEbXrtEEF9Hnmrdly59sUbzZ/QgyWuLYHctCHxFF4tRQZNQ9k60ExQ==", + "license": "Apache-2.0", "dependencies": { - "@types/unist": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "b4a": "^1.6.4" } }, - "node_modules/unist-util-stringify-position": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/unist-util-stringify-position/-/unist-util-stringify-position-4.0.0.tgz", - "integrity": "sha512-0ASV06AAoKCDkS2+xw5RXJywruurpbC4JZSm7nr7MOt1ojAzvyyaO+UxZf18j8FCF6kmzCZKcAgN/yu2gm2XgQ==", + "node_modules/tiny-async-pool": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/tiny-async-pool/-/tiny-async-pool-1.3.0.tgz", + "integrity": "sha512-01EAw5EDrcVrdgyCLgoSPvqznC0sVxDSVeiOz09FUpjh71G79VCqneOr+xvt7T1r76CF6ZZfPjHorN2+d+3mqA==", + "dev": true, "license": "MIT", "dependencies": { - "@types/unist": "^3.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "semver": "^5.5.0" } }, - "node_modules/unist-util-visit": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-5.1.0.tgz", - "integrity": "sha512-m+vIdyeCOpdr/QeQCu2EzxX/ohgS8KbnPDgFni4dQsfSCtpz8UqDyY5GjRru8PDKuYn7Fq19j1CQ+nJSsGKOzg==", + "node_modules/tiny-async-pool/node_modules/semver": { + "version": "5.7.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.3.tgz", + "integrity": "sha512-kM18BPOqTi0+TB68703/GJRpAML5Me+IDQsR1J26YB3EFKKNEyHIVZuWDX7+WKQB3tHwDwgk24BfhdpWUbytvQ==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/tiny-typed-emitter": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tiny-typed-emitter/-/tiny-typed-emitter-2.1.0.tgz", + "integrity": "sha512-qVtvMxeXbVej0cQWKqVSSAHmKZEHAvxdF8HEUBFWts8h+xEo5m/lEiPakuyZ3BnCBjOD8i24kzNOiOLLgsSxhA==", + "license": "MIT" + }, + "node_modules/tinybench": { + "version": "6.2.4", + "resolved": "https://registry.npmjs.org/tinybench/-/tinybench-6.2.4.tgz", + "integrity": "sha512-SQ52jEncXxbMCzJuY2A/jGIbbAu6NYsBWW7grz2pNE+EnzQdoGaoBfpk4qC/opE7qiUcGmGgaGIz5EoHdS1O9w==", + "dev": true, "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-is": "^6.0.0", - "unist-util-visit-parents": "^6.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "engines": { + "node": ">=20.0.0" } }, - "node_modules/unist-util-visit-parents": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-6.0.2.tgz", - "integrity": "sha512-goh1s1TBrqSqukSc8wrjwWhL0hiJxgA8m4kFxGlQ+8FYQ3C/m11FcTs4YYem7V664AhHVvgoQLk890Ssdsr2IQ==", + "node_modules/tinyexec": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-1.3.1.tgz", + "integrity": "sha512-GCvB3aoys96IuDFBMcTB46JOR6mdMtAToqwiW8JlWhsoh1mhHi/xn9ss/Dg7N555GiJyEt2qzoG/NHCwM6h1EA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/tinyglobby": { + "version": "0.2.17", + "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.17.tgz", + "integrity": "sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g==", + "dev": true, "license": "MIT", "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-is": "^6.0.0" + "fdir": "^6.5.0", + "picomatch": "^4.0.4" + }, + "engines": { + "node": ">=12.0.0" }, "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "url": "https://github.com/sponsors/SuperchupuDev" } }, - "node_modules/universalify": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", - "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", + "node_modules/tmp": { + "version": "0.2.7", + "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.2.7.tgz", + "integrity": "sha512-e0votIpp4Uo2AJYSzVHV6xCcawuiez3DzqDAbrTc3YxBkplN6e+dM13ZeIcZnDg/QpSuU2zfZ3rzwY8ukEnaXw==", + "dev": true, "license": "MIT", "engines": { - "node": ">= 10.0.0" + "node": ">=14.14" } }, - "node_modules/unpdf": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/unpdf/-/unpdf-1.8.0.tgz", - "integrity": "sha512-jQlkckbe5nKxRHQdbvo9IKHlU6Cjq00UlxxB8lrCIxvS2o5IbAL1wM+4a1Yc3+BIohg9p5AsoaftwO+G4Aq/qQ==", + "node_modules/tmp-promise": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/tmp-promise/-/tmp-promise-3.0.3.tgz", + "integrity": "sha512-RwM7MoPojPxsOBYnyd2hy0bxtIlVrihNs9pj5SUvY8Zz1sQcQG2tG1hSr8PDxfgEB8RNKDhqbIlroIarSNDNsQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "tmp": "^0.2.0" + } + }, + "node_modules/toidentifier": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", + "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", "license": "MIT", "engines": { - "node": ">=22" - }, - "peerDependencies": { - "@napi-rs/canvas": "^0.1.69 || ^1.0.0" - }, - "peerDependenciesMeta": { - "@napi-rs/canvas": { - "optional": true - } + "node": ">=0.6" } }, - "node_modules/unzipper": { - "version": "0.12.5", - "resolved": "https://registry.npmjs.org/unzipper/-/unzipper-0.12.5.tgz", - "integrity": "sha512-tXYOi9R57Uj/2Z25SOs5RRSzq886MBQj2gY8dPL+xl/kv6s6SvByoKfAtvfVeEuhntWDgjd2o9p2lb4TVPAz0A==", - "dev": true, + "node_modules/trough": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/trough/-/trough-2.2.0.tgz", + "integrity": "sha512-tmMpK00BjZiUyVyvrBK7knerNgmgvcV/KLVyuma/SC+TQN167GrMRciANTz09+k3zW8L8t60jWO1GpfkZdjTaw==", "license": "MIT", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, + "node_modules/truncate-utf8-bytes": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/truncate-utf8-bytes/-/truncate-utf8-bytes-1.0.2.tgz", + "integrity": "sha512-95Pu1QXQvruGEhv62XCMO3Mm90GscOCClvrIUwCM0PYOXK3kaF3l3sIHxx71ThJfcbM2O5Au6SO3AWCSEfW4mQ==", + "dev": true, + "license": "WTFPL", "dependencies": { - "bluebird": "~3.7.2", - "duplexer2": "~0.1.4", - "fs-extra": "11.3.1", - "graceful-fs": "^4.2.2", - "node-int64": "^0.4.0" + "utf8-byte-length": "^1.0.1" } }, - "node_modules/unzipper/node_modules/fs-extra": { - "version": "11.3.1", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.3.1.tgz", - "integrity": "sha512-eXvGGwZ5CL17ZSwHWd3bbgk7UUpF6IFHtP57NYYakPvHOs8GDgDe5KJI36jIJzDkJ6eJjuzRA8eBQb6SkKue0g==", + "node_modules/ts-algebra": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ts-algebra/-/ts-algebra-2.0.0.tgz", + "integrity": "sha512-FPAhNPFMrkwz76P7cdjdmiShwMynZYN6SgOujD1urY4oNm80Ou9oMdmbR45LotcKOXoy7wSmHkRFE6Mxbrhefw==", + "license": "MIT" + }, + "node_modules/ts-api-utils": { + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/ts-api-utils/-/ts-api-utils-2.5.0.tgz", + "integrity": "sha512-OJ/ibxhPlqrMM0UiNHJ/0CKQkoKF243/AEmplt3qpRgkW8VG7IfOS41h7V8TjITqdByHzrjcS/2si+y4lIh8NA==", "dev": true, "license": "MIT", - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, "engines": { - "node": ">=14.14" + "node": ">=18.12" + }, + "peerDependencies": { + "typescript": ">=4.8.4" } }, - "node_modules/update-browserslist-db": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.2.3.tgz", - "integrity": "sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==", - "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/browserslist" - }, - { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/browserslist" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], + "node_modules/tslib": { + "version": "2.9.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.9.1.tgz", + "integrity": "sha512-a4Ux9VKuIMHsOS7ENbEq6hK2ZGYIT27Rtl0E4eD9KqwxhKiQeMZE/9xb3IdYwWaSOyIBQLExhQgXDTYoiCxnWA==", + "license": "0BSD" + }, + "node_modules/tsx": { + "version": "4.23.15", + "resolved": "https://registry.npmjs.org/tsx/-/tsx-4.23.15.tgz", + "integrity": "sha512-Yiex1Ovn8z2xPpOWckIiysV1SSyRMY9BkLF++q0yKiDxCqRhosKfMg3janKkiLBwZ5c/YryloKwGZcrEmtwxKw==", "license": "MIT", "dependencies": { - "escalade": "^3.2.0", - "picocolors": "^1.1.1" + "esbuild": "~0.28.0" }, "bin": { - "update-browserslist-db": "cli.js" + "tsx": "dist/cli.mjs" }, - "peerDependencies": { - "browserslist": ">= 4.21.0" + "engines": { + "node": ">=18.0.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" } }, - "node_modules/uri-js": { - "version": "4.4.1", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", - "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", - "dev": true, - "license": "BSD-2-Clause", + "node_modules/turndown": { + "version": "7.2.5", + "resolved": "https://registry.npmjs.org/turndown/-/turndown-7.2.5.tgz", + "integrity": "sha512-EKZvCCFHh8sWttpAMs10U6niZFJ2cpz8LkCPlylxoG4JcHF50J7EHnnBW3AY1qXtUMu7kDjCp7dnggB1sIbqEQ==", + "license": "MIT", "dependencies": { - "punycode": "^2.1.0" + "@mixmark-io/domino": "^2.2.0" + }, + "engines": { + "node": ">=18", + "npm": ">=9" } }, - "node_modules/utf8-byte-length": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/utf8-byte-length/-/utf8-byte-length-1.0.5.tgz", - "integrity": "sha512-Xn0w3MtiQ6zoz2vFyUVruaCL53O/DwUvkEeOvj+uulMm0BkUGYWmBYVyElqZaSLhY6ZD0ulfU3aBra2aVT4xfA==", - "dev": true, - "license": "(WTFPL OR MIT)" - }, - "node_modules/util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", + "node_modules/type-check": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", + "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", "dev": true, - "license": "MIT" - }, - "node_modules/vfile": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/vfile/-/vfile-6.0.3.tgz", - "integrity": "sha512-KzIbH/9tXat2u30jf+smMwFCsno4wHVdNmzFyL+T/L3UGqqk6JKfVqOFOZEpZSHADH1k40ab6NUIXZq422ov3Q==", "license": "MIT", "dependencies": { - "@types/unist": "^3.0.0", - "vfile-message": "^4.0.0" + "prelude-ls": "^1.2.1" }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "engines": { + "node": ">= 0.8.0" } }, - "node_modules/vfile-message": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/vfile-message/-/vfile-message-4.0.3.tgz", - "integrity": "sha512-QTHzsGd1EhbZs4AsQ20JX1rC3cOlt/IWJruk893DfLRr57lcnOeMaWG4K0JrRta4mIJZKth2Au3mM3u03/JWKw==", - "license": "MIT", - "dependencies": { - "@types/unist": "^3.0.0", - "unist-util-stringify-position": "^4.0.0" + "node_modules/type-fest": { + "version": "0.20.2", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", + "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" }, "funding": { - "type": "opencollective", - "url": "https://opencollective.com/unified" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/vite": { - "version": "7.3.5", - "resolved": "https://registry.npmjs.org/vite/-/vite-7.3.5.tgz", - "integrity": "sha512-KuOaNhcnGFN2zIPGA7wRmzF+lJA1sea7rHq17aiJ++9lzY1WWG6Jpwqwe1KNbRVPIqHmr8GLYx7jbrQcN/7/ww==", - "dev": true, + "node_modules/type-is": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/type-is/-/type-is-2.1.0.tgz", + "integrity": "sha512-faYHw0anBbc/kWF3zFTEnxSFOAGUX9GFbOBthvDdLsIlEoWOFOtS0zgCiQYwIskL9iGXZL3kAXD8OoZ4GmMATA==", "license": "MIT", "dependencies": { - "esbuild": "^0.27.0", - "fdir": "^6.5.0", - "picomatch": "^4.0.3", - "postcss": "^8.5.6", - "rollup": "^4.43.0", - "tinyglobby": "^0.2.15" - }, - "bin": { - "vite": "bin/vite.js" + "content-type": "^2.0.0", + "media-typer": "^1.1.0", + "mime-types": "^3.0.0" }, "engines": { - "node": "^20.19.0 || >=22.12.0" + "node": ">= 18" }, "funding": { - "url": "https://github.com/vitejs/vite?sponsor=1" - }, - "optionalDependencies": { - "fsevents": "~2.3.3" - }, - "peerDependencies": { - "@types/node": "^20.19.0 || >=22.12.0", - "jiti": ">=1.21.0", - "less": "^4.0.0", - "lightningcss": "^1.21.0", - "sass": "^1.70.0", - "sass-embedded": "^1.70.0", - "stylus": ">=0.54.8", - "sugarss": "^5.0.0", - "terser": "^5.16.0", - "tsx": "^4.8.1", - "yaml": "^2.4.2" - }, - "peerDependenciesMeta": { - "@types/node": { - "optional": true - }, - "jiti": { - "optional": true - }, - "less": { - "optional": true - }, - "lightningcss": { - "optional": true - }, - "sass": { - "optional": true - }, - "sass-embedded": { - "optional": true - }, - "stylus": { - "optional": true - }, - "sugarss": { - "optional": true - }, - "terser": { - "optional": true - }, - "tsx": { - "optional": true - }, - "yaml": { - "optional": true - } + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/vite/node_modules/@esbuild/aix-ppc64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.27.7.tgz", - "integrity": "sha512-EKX3Qwmhz1eMdEJokhALr0YiD0lhQNwDqkPYyPhiSwKrh7/4KRjQc04sZ8db+5DVVnZ1LmbNDI1uAMPEUBnQPg==", - "cpu": [ - "ppc64" - ], - "dev": true, + "node_modules/type-is/node_modules/content-type": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-2.1.0.tgz", + "integrity": "sha512-mj7UPXE0jaqaOsukNZRUEfEi2AcL7C/vwmwcHV0O97eO1E1pxBZuyjlZrx5seTaNBg1U6+o35wpa35Qfcc+7ag==", "license": "MIT", - "optional": true, - "os": [ - "aix" - ], "engines": { "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/vite/node_modules/@esbuild/android-arm": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.27.7.tgz", - "integrity": "sha512-jbPXvB4Yj2yBV7HUfE2KHe4GJX51QplCN1pGbYjvsyCZbQmies29EoJbkEc+vYuU5o45AfQn37vZlyXy4YJ8RQ==", - "cpu": [ - "arm" - ], - "dev": true, + "node_modules/type-is/node_modules/mime-db": { + "version": "1.54.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", + "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", "license": "MIT", - "optional": true, - "os": [ - "android" - ], "engines": { - "node": ">=18" + "node": ">= 0.6" } }, - "node_modules/vite/node_modules/@esbuild/android-arm64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.27.7.tgz", - "integrity": "sha512-62dPZHpIXzvChfvfLJow3q5dDtiNMkwiRzPylSCfriLvZeq0a1bWChrGx/BbUbPwOrsWKMn8idSllklzBy+dgQ==", - "cpu": [ - "arm64" - ], - "dev": true, + "node_modules/type-is/node_modules/mime-types": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.2.tgz", + "integrity": "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==", "license": "MIT", - "optional": true, - "os": [ - "android" - ], + "dependencies": { + "mime-db": "^1.54.0" + }, "engines": { "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, - "node_modules/vite/node_modules/@esbuild/android-x64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.27.7.tgz", - "integrity": "sha512-x5VpMODneVDb70PYV2VQOmIUUiBtY3D3mPBG8NxVk5CogneYhkR7MmM3yR/uMdITLrC1ml/NV1rj4bMJuy9MCg==", - "cpu": [ - "x64" - ], - "dev": true, + "node_modules/typebox": { + "version": "1.4.7", + "resolved": "https://registry.npmjs.org/typebox/-/typebox-1.4.7.tgz", + "integrity": "sha512-KonYdBj3gOgG/rH96TlUs/f+eaEDqiKRW7KU4/LE/tEjEnRCcfpYLofBfHfNMBAiBosmY55e4YeCPuE+NXmJtg==", "license": "MIT", - "optional": true, - "os": [ - "android" - ], + "peer": true + }, + "node_modules/typed-array-buffer": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.3.tgz", + "integrity": "sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==", + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "es-errors": "^1.3.0", + "is-typed-array": "^1.1.14" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" } }, - "node_modules/vite/node_modules/@esbuild/darwin-arm64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.27.7.tgz", - "integrity": "sha512-5lckdqeuBPlKUwvoCXIgI2D9/ABmPq3Rdp7IfL70393YgaASt7tbju3Ac+ePVi3KDH6N2RqePfHnXkaDtY9fkw==", - "cpu": [ - "arm64" - ], - "dev": true, + "node_modules/typed-array-byte-length": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.3.tgz", + "integrity": "sha512-BaXgOuIxz8n8pIq3e7Atg/7s+DpiYrxn4vdot3w9KbnBhcRQq6o3xemQdIfynqSeXeDrF32x+WvfzmOjPiY9lg==", "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], + "dependencies": { + "call-bind": "^1.0.8", + "for-each": "^0.3.3", + "gopd": "^1.2.0", + "has-proto": "^1.2.0", + "is-typed-array": "^1.1.14" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/vite/node_modules/@esbuild/darwin-x64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.27.7.tgz", - "integrity": "sha512-rYnXrKcXuT7Z+WL5K980jVFdvVKhCHhUwid+dDYQpH+qu+TefcomiMAJpIiC2EM3Rjtq0sO3StMV/+3w3MyyqQ==", - "cpu": [ - "x64" - ], - "dev": true, + "node_modules/typed-array-byte-offset": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.5.tgz", + "integrity": "sha512-0FHJvLPqZ7KJzp17O13jfsAjsqazgrxBu2zEK95PmUz8lv2+GjRuxUInCr2Rk9Dms3ihN21zJ929ZO43yJ95QQ==", "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], + "dependencies": { + "available-typed-arrays": "^1.0.7", + "call-bind": "^1.0.9", + "for-each": "^0.3.5", + "gopd": "^1.2.0", + "is-typed-array": "^1.1.15", + "reflect.getprototypeof": "^1.0.10" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/vite/node_modules/@esbuild/freebsd-arm64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.27.7.tgz", - "integrity": "sha512-B48PqeCsEgOtzME2GbNM2roU29AMTuOIN91dsMO30t+Ydis3z/3Ngoj5hhnsOSSwNzS+6JppqWsuhTp6E82l2w==", - "cpu": [ - "arm64" - ], - "dev": true, + "node_modules/typed-array-length": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.8.tgz", + "integrity": "sha512-phPGCwqr2+Qo0fwniCE8e4pKnGu/yFb5nD5Y8bf0EEeiI5GklnACYA9GFy/DrAeRrKHXvHn+1SUsOWgJp6RO+g==", "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], + "dependencies": { + "call-bind": "^1.0.9", + "for-each": "^0.3.5", + "gopd": "^1.2.0", + "is-typed-array": "^1.1.15", + "possible-typed-array-names": "^1.1.0", + "reflect.getprototypeof": "^1.0.10" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/vite/node_modules/@esbuild/freebsd-x64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.27.7.tgz", - "integrity": "sha512-jOBDK5XEjA4m5IJK3bpAQF9/Lelu/Z9ZcdhTRLf4cajlB+8VEhFFRjWgfy3M1O4rO2GQ/b2dLwCUGpiF/eATNQ==", - "cpu": [ - "x64" - ], + "node_modules/typescript": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-6.0.3.tgz", + "integrity": "sha512-y2TvuxSZPDyQakkFRPZHKFm+KKVqIisdg9/CZwm9ftvKXLP8NRWj38/ODjNbr43SsoXqNuAisEf1GdCxqWcdBw==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ], + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, "engines": { - "node": ">=18" + "node": ">=14.17" } }, - "node_modules/vite/node_modules/@esbuild/linux-arm": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.27.7.tgz", - "integrity": "sha512-RkT/YXYBTSULo3+af8Ib0ykH8u2MBh57o7q/DAs3lTJlyVQkgQvlrPTnjIzzRPQyavxtPtfg0EopvDyIt0j1rA==", - "cpu": [ - "arm" - ], - "dev": true, + "node_modules/uhyphen": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/uhyphen/-/uhyphen-0.2.0.tgz", + "integrity": "sha512-qz3o9CHXmJJPGBdqzab7qAYuW8kQGKNEuoHFYrBwV6hWIMcpAmxDLXojcHfFr9US1Pe6zUswEIJIbLI610fuqA==", + "license": "ISC" + }, + "node_modules/unbox-primitive": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.1.0.tgz", + "integrity": "sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], + "dependencies": { + "call-bound": "^1.0.3", + "has-bigints": "^1.0.2", + "has-symbols": "^1.1.0", + "which-boxed-primitive": "^1.1.1" + }, "engines": { - "node": ">=18" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/vite/node_modules/@esbuild/linux-arm64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.27.7.tgz", - "integrity": "sha512-RZPHBoxXuNnPQO9rvjh5jdkRmVizktkT7TCDkDmQ0W2SwHInKCAV95GRuvdSvA7w4VMwfCjUiPwDi0ZO6Nfe9A==", - "cpu": [ - "arm64" - ], - "dev": true, + "node_modules/undici": { + "version": "8.13.0", + "resolved": "https://registry.npmjs.org/undici/-/undici-8.13.0.tgz", + "integrity": "sha512-mxbeyRlRhHUTWE1zf/FwDOXTKMhE1vMQRz/o2oOir/5fIWsB79TeZrByMkj019EdDuxPg03jprCjFLxLkmxTCQ==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], "engines": { - "node": ">=18" + "node": ">=22.19.0" } }, - "node_modules/vite/node_modules/@esbuild/linux-ia32": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.27.7.tgz", - "integrity": "sha512-GA48aKNkyQDbd3KtkplYWT102C5sn/EZTY4XROkxONgruHPU72l+gW+FfF8tf2cFjeHaRbWpOYa/uRBz/Xq1Pg==", - "cpu": [ - "ia32" - ], - "dev": true, + "node_modules/undici-types": { + "version": "7.24.6", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.24.6.tgz", + "integrity": "sha512-WRNW+sJgj5OBN4/0JpHFqtqzhpbnV0GuB+OozA9gCL7a993SmU+1JBZCzLNxYsbMfIeDL+lTsphD5jN5N+n0zg==", + "license": "MIT" + }, + "node_modules/unified": { + "version": "11.0.5", + "resolved": "https://registry.npmjs.org/unified/-/unified-11.0.5.tgz", + "integrity": "sha512-xKvGhPWw3k84Qjh8bI3ZeJjqnyadK+GEFtazSfZv/rKeTkTjOJho6mFqh2SM96iIcZokxiOpg78GazTSg8+KHA==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" + "dependencies": { + "@types/unist": "^3.0.0", + "bail": "^2.0.0", + "devlop": "^1.0.0", + "extend": "^3.0.0", + "is-plain-obj": "^4.0.0", + "trough": "^2.0.0", + "vfile": "^6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/vite/node_modules/@esbuild/linux-loong64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.27.7.tgz", - "integrity": "sha512-a4POruNM2oWsD4WKvBSEKGIiWQF8fZOAsycHOt6JBpZ+JN2n2JH9WAv56SOyu9X5IqAjqSIPTaJkqN8F7XOQ5Q==", - "cpu": [ - "loong64" - ], - "dev": true, + "node_modules/unist-util-is": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/unist-util-is/-/unist-util-is-6.0.1.tgz", + "integrity": "sha512-LsiILbtBETkDz8I9p1dQ0uyRUWuaQzd/cuEeS1hoRSyW5E5XGmTzlwY1OrNzzakGowI9Dr/I8HVaw4hTtnxy8g==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" + "dependencies": { + "@types/unist": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/vite/node_modules/@esbuild/linux-mips64el": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.27.7.tgz", - "integrity": "sha512-KabT5I6StirGfIz0FMgl1I+R1H73Gp0ofL9A3nG3i/cYFJzKHhouBV5VWK1CSgKvVaG4q1RNpCTR2LuTVB3fIw==", - "cpu": [ - "mips64el" - ], - "dev": true, + "node_modules/unist-util-position-from-estree": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/unist-util-position-from-estree/-/unist-util-position-from-estree-2.0.0.tgz", + "integrity": "sha512-KaFVRjoqLyF6YXCbVLNad/eS4+OfPQQn2yOd7zF/h5T/CSL2v8NpN6a5TPvtbXthAGw5nG+PuTtq+DdIZr+cRQ==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" + "dependencies": { + "@types/unist": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/vite/node_modules/@esbuild/linux-ppc64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.27.7.tgz", - "integrity": "sha512-gRsL4x6wsGHGRqhtI+ifpN/vpOFTQtnbsupUF5R5YTAg+y/lKelYR1hXbnBdzDjGbMYjVJLJTd2OFmMewAgwlQ==", - "cpu": [ - "ppc64" - ], - "dev": true, + "node_modules/unist-util-stringify-position": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/unist-util-stringify-position/-/unist-util-stringify-position-4.0.0.tgz", + "integrity": "sha512-0ASV06AAoKCDkS2+xw5RXJywruurpbC4JZSm7nr7MOt1ojAzvyyaO+UxZf18j8FCF6kmzCZKcAgN/yu2gm2XgQ==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" + "dependencies": { + "@types/unist": "^3.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/vite/node_modules/@esbuild/linux-riscv64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.27.7.tgz", - "integrity": "sha512-hL25LbxO1QOngGzu2U5xeXtxXcW+/GvMN3ejANqXkxZ/opySAZMrc+9LY/WyjAan41unrR3YrmtTsUpwT66InQ==", - "cpu": [ - "riscv64" - ], - "dev": true, + "node_modules/unist-util-visit": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/unist-util-visit/-/unist-util-visit-5.2.0.tgz", + "integrity": "sha512-fpsYs/VVoZxfGY9/j3FQpZmN8wdLJaV1Pt38AaJNZu9uKIHcFU3halCdBveEq1HGKO1OEfJY65w1zvoFV1b3qQ==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" + "dependencies": { + "@types/unist": "^3.0.0", + "unist-util-is": "^6.0.0", + "unist-util-visit-parents": "^6.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/vite/node_modules/@esbuild/linux-s390x": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.27.7.tgz", - "integrity": "sha512-2k8go8Ycu1Kb46vEelhu1vqEP+UeRVj2zY1pSuPdgvbd5ykAw82Lrro28vXUrRmzEsUV0NzCf54yARIK8r0fdw==", - "cpu": [ - "s390x" - ], - "dev": true, + "node_modules/unist-util-visit-parents": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/unist-util-visit-parents/-/unist-util-visit-parents-6.1.0.tgz", + "integrity": "sha512-vKXxz6O38sKDj1mtx/k2cWvkkFBuYGx6uGrlzBkVeWCRF/F8sdI0j3Wbkz/5rVNRRuVc8UrgRdbCxNhmYXgP3w==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "engines": { - "node": ">=18" + "dependencies": { + "@types/unist": "^3.0.0", + "unist-util-is": "^6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/vite/node_modules/@esbuild/linux-x64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.27.7.tgz", - "integrity": "sha512-hzznmADPt+OmsYzw1EE33ccA+HPdIqiCRq7cQeL1Jlq2gb1+OyWBkMCrYGBJ+sxVzve2ZJEVeePbLM2iEIZSxA==", - "cpu": [ - "x64" - ], - "dev": true, + "node_modules/universalify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", + "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", "license": "MIT", - "optional": true, - "os": [ - "linux" - ], "engines": { - "node": ">=18" + "node": ">= 10.0.0" } }, - "node_modules/vite/node_modules/@esbuild/netbsd-arm64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.27.7.tgz", - "integrity": "sha512-b6pqtrQdigZBwZxAn1UpazEisvwaIDvdbMbmrly7cDTMFnw/+3lVxxCTGOrkPVnsYIosJJXAsILG9XcQS+Yu6w==", - "cpu": [ - "arm64" - ], - "dev": true, + "node_modules/unpdf": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/unpdf/-/unpdf-1.9.1.tgz", + "integrity": "sha512-nO1npM2kNyd4hj1fKzUVU6bvnWjDSxI97eycM/DgzI83dYyW+pNRI9NeMQVEfef8fI3Q06i9lkMeE1HxrQqKoA==", "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], "engines": { - "node": ">=18" + "node": ">=22" + }, + "peerDependencies": { + "@napi-rs/canvas": "^0.1.69 || ^1.0.0" + }, + "peerDependenciesMeta": { + "@napi-rs/canvas": { + "optional": true + } } }, - "node_modules/vite/node_modules/@esbuild/netbsd-x64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.27.7.tgz", - "integrity": "sha512-OfatkLojr6U+WN5EDYuoQhtM+1xco+/6FSzJJnuWiUw5eVcicbyK3dq5EeV/QHT1uy6GoDhGbFpprUiHUYggrw==", - "cpu": [ - "x64" - ], - "dev": true, + "node_modules/unpipe": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", + "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", "license": "MIT", - "optional": true, - "os": [ - "netbsd" - ], "engines": { - "node": ">=18" + "node": ">= 0.8" } }, - "node_modules/vite/node_modules/@esbuild/openbsd-arm64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.27.7.tgz", - "integrity": "sha512-AFuojMQTxAz75Fo8idVcqoQWEHIXFRbOc1TrVcFSgCZtQfSdc1RXgB3tjOn/krRHENUB4j00bfGjyl2mJrU37A==", - "cpu": [ - "arm64" - ], + "node_modules/unzipper": { + "version": "0.12.5", + "resolved": "https://registry.npmjs.org/unzipper/-/unzipper-0.12.5.tgz", + "integrity": "sha512-tXYOi9R57Uj/2Z25SOs5RRSzq886MBQj2gY8dPL+xl/kv6s6SvByoKfAtvfVeEuhntWDgjd2o9p2lb4TVPAz0A==", "dev": true, "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], - "engines": { - "node": ">=18" + "dependencies": { + "bluebird": "~3.7.2", + "duplexer2": "~0.1.4", + "fs-extra": "11.3.1", + "graceful-fs": "^4.2.2", + "node-int64": "^0.4.0" } }, - "node_modules/vite/node_modules/@esbuild/openbsd-x64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.27.7.tgz", - "integrity": "sha512-+A1NJmfM8WNDv5CLVQYJ5PshuRm/4cI6WMZRg1by1GwPIQPCTs1GLEUHwiiQGT5zDdyLiRM/l1G0Pv54gvtKIg==", - "cpu": [ - "x64" - ], + "node_modules/unzipper/node_modules/fs-extra": { + "version": "11.3.1", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.3.1.tgz", + "integrity": "sha512-eXvGGwZ5CL17ZSwHWd3bbgk7UUpF6IFHtP57NYYakPvHOs8GDgDe5KJI36jIJzDkJ6eJjuzRA8eBQb6SkKue0g==", "dev": true, "license": "MIT", - "optional": true, - "os": [ - "openbsd" - ], + "dependencies": { + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, "engines": { - "node": ">=18" + "node": ">=14.14" } }, - "node_modules/vite/node_modules/@esbuild/openharmony-arm64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.27.7.tgz", - "integrity": "sha512-+KrvYb/C8zA9CU/g0sR6w2RBw7IGc5J2BPnc3dYc5VJxHCSF1yNMxTV5LQ7GuKteQXZtspjFbiuW5/dOj7H4Yw==", - "cpu": [ - "arm64" - ], + "node_modules/update-browserslist-db": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.4.0.tgz", + "integrity": "sha512-WPJuOnjI9FWDct4fB+ej4Mz8opLaw5CDcZ2t44tFZ0vIQVYWzBhWR3mkixuUj/A7+vY4V9+ApOZ2YYLwdgq46w==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "openharmony" + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } ], - "engines": { - "node": ">=18" + "license": "MIT", + "dependencies": { + "escalade": "^3.2.0", + "picocolors": "^1.1.1" + }, + "bin": { + "update-browserslist-db": "cli.js" + }, + "peerDependencies": { + "browserslist": ">= 4.21.0" } }, - "node_modules/vite/node_modules/@esbuild/sunos-x64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.27.7.tgz", - "integrity": "sha512-ikktIhFBzQNt/QDyOL580ti9+5mL/YZeUPKU2ivGtGjdTYoqz6jObj6nOMfhASpS4GU4Q/Clh1QtxWAvcYKamA==", - "cpu": [ - "x64" - ], + "node_modules/uri-js": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", + "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "sunos" - ], - "engines": { - "node": ">=18" + "license": "BSD-2-Clause", + "dependencies": { + "punycode": "^2.1.0" } }, - "node_modules/vite/node_modules/@esbuild/win32-arm64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.27.7.tgz", - "integrity": "sha512-7yRhbHvPqSpRUV7Q20VuDwbjW5kIMwTHpptuUzV+AA46kiPze5Z7qgt6CLCK3pWFrHeNfDd1VKgyP4O+ng17CA==", - "cpu": [ - "arm64" - ], + "node_modules/utf8-byte-length": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/utf8-byte-length/-/utf8-byte-length-1.0.5.tgz", + "integrity": "sha512-Xn0w3MtiQ6zoz2vFyUVruaCL53O/DwUvkEeOvj+uulMm0BkUGYWmBYVyElqZaSLhY6ZD0ulfU3aBra2aVT4xfA==", "dev": true, + "license": "(WTFPL OR MIT)" + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", + "devOptional": true, + "license": "MIT" + }, + "node_modules/vary": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", + "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", "license": "MIT", - "optional": true, - "os": [ - "win32" - ], "engines": { - "node": ">=18" + "node": ">= 0.8" } }, - "node_modules/vite/node_modules/@esbuild/win32-ia32": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.27.7.tgz", - "integrity": "sha512-SmwKXe6VHIyZYbBLJrhOoCJRB/Z1tckzmgTLfFYOfpMAx63BJEaL9ExI8x7v0oAO3Zh6D/Oi1gVxEYr5oUCFhw==", - "cpu": [ - "ia32" - ], - "dev": true, + "node_modules/vfile": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/vfile/-/vfile-6.0.3.tgz", + "integrity": "sha512-KzIbH/9tXat2u30jf+smMwFCsno4wHVdNmzFyL+T/L3UGqqk6JKfVqOFOZEpZSHADH1k40ab6NUIXZq422ov3Q==", "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" + "dependencies": { + "@types/unist": "^3.0.0", + "vfile-message": "^4.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/vite/node_modules/@esbuild/win32-x64": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.27.7.tgz", - "integrity": "sha512-56hiAJPhwQ1R4i+21FVF7V8kSD5zZTdHcVuRFMW0hn753vVfQN8xlx4uOPT4xoGH0Z/oVATuR82AiqSTDIpaHg==", - "cpu": [ - "x64" - ], - "dev": true, + "node_modules/vfile-message": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/vfile-message/-/vfile-message-4.0.4.tgz", + "integrity": "sha512-66ycRswIkNmHH9PHku7ADtv5RVwgIrOcuv3J8Svz6h4qgGRrKVa+9/neuKyJZUXyOpYwLTvS+whZ4R2urHHgQg==", "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "engines": { - "node": ">=18" + "dependencies": { + "@types/unist": "^3.0.0", + "unist-util-stringify-position": "^4.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/unified" } }, - "node_modules/vite/node_modules/esbuild": { - "version": "0.27.7", - "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.7.tgz", - "integrity": "sha512-IxpibTjyVnmrIQo5aqNpCgoACA/dTKLTlhMHihVHhdkxKyPO1uBBthumT0rdHmcsk9uMonIWS0m4FljWzILh3w==", + "node_modules/vite": { + "version": "8.3.8", + "resolved": "https://registry.npmjs.org/vite/-/vite-8.3.8.tgz", + "integrity": "sha512-LzOn3h9rG/0vhLdXrV4yJ4QFA9eEoqCl+Yx+kGJd7aB9w6nfNgVHKSYwLPZUHrz4ZGa+t+kXjV9itvcHDLQouA==", "dev": true, - "hasInstallScript": true, "license": "MIT", + "dependencies": { + "lightningcss": "^1.33.0", + "picomatch": "^4.0.7", + "postcss": "^8.5.32", + "rolldown": "~1.2.18", + "tinyglobby": "^0.2.17" + }, "bin": { - "esbuild": "bin/esbuild" + "vite": "bin/vite.js" }, "engines": { - "node": ">=18" + "node": "^20.19.0 || >=22.12.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" }, "optionalDependencies": { - "@esbuild/aix-ppc64": "0.27.7", - "@esbuild/android-arm": "0.27.7", - "@esbuild/android-arm64": "0.27.7", - "@esbuild/android-x64": "0.27.7", - "@esbuild/darwin-arm64": "0.27.7", - "@esbuild/darwin-x64": "0.27.7", - "@esbuild/freebsd-arm64": "0.27.7", - "@esbuild/freebsd-x64": "0.27.7", - "@esbuild/linux-arm": "0.27.7", - "@esbuild/linux-arm64": "0.27.7", - "@esbuild/linux-ia32": "0.27.7", - "@esbuild/linux-loong64": "0.27.7", - "@esbuild/linux-mips64el": "0.27.7", - "@esbuild/linux-ppc64": "0.27.7", - "@esbuild/linux-riscv64": "0.27.7", - "@esbuild/linux-s390x": "0.27.7", - "@esbuild/linux-x64": "0.27.7", - "@esbuild/netbsd-arm64": "0.27.7", - "@esbuild/netbsd-x64": "0.27.7", - "@esbuild/openbsd-arm64": "0.27.7", - "@esbuild/openbsd-x64": "0.27.7", - "@esbuild/openharmony-arm64": "0.27.7", - "@esbuild/sunos-x64": "0.27.7", - "@esbuild/win32-arm64": "0.27.7", - "@esbuild/win32-ia32": "0.27.7", - "@esbuild/win32-x64": "0.27.7" + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^20.19.0 || >=22.12.0", + "@vitejs/devtools": "^0.7.1 || ^0.8.0", + "esbuild": "^0.27.0 || ^0.28.0", + "jiti": ">=1.21.0", + "less": "^4.0.0", + "sass": "^1.70.0", + "sass-embedded": "^1.70.0", + "stylus": ">=0.54.8", + "sugarss": "^5.0.0", + "terser": "^5.16.0", + "tsx": "^4.8.1", + "yaml": "^2.4.2" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "@vitejs/devtools": { + "optional": true + }, + "esbuild": { + "optional": true + }, + "jiti": { + "optional": true + }, + "less": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + }, + "tsx": { + "optional": true + }, + "yaml": { + "optional": true + } } }, "node_modules/vitest": { - "version": "4.1.9", - "resolved": "https://registry.npmjs.org/vitest/-/vitest-4.1.9.tgz", - "integrity": "sha512-nE3/LEyc0z87uHYLZebqCUOaJr2hdtuPp7BQ4BosVFnfltxgAvMG08NyrSGlPpOUWvR27c5flSmYFTNr78L9GQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@vitest/expect": "4.1.9", - "@vitest/mocker": "4.1.9", - "@vitest/pretty-format": "4.1.9", - "@vitest/runner": "4.1.9", - "@vitest/snapshot": "4.1.9", - "@vitest/spy": "4.1.9", - "@vitest/utils": "4.1.9", - "es-module-lexer": "^2.0.0", - "expect-type": "^1.3.0", - "magic-string": "^0.30.21", - "obug": "^2.1.1", - "pathe": "^2.0.3", - "picomatch": "^4.0.3", - "std-env": "^4.0.0-rc.1", - "tinybench": "^2.9.0", - "tinyexec": "^1.0.2", - "tinyglobby": "^0.2.15", - "tinyrainbow": "^3.1.0", - "vite": "^6.0.0 || ^7.0.0 || ^8.0.0", - "why-is-node-running": "^2.3.0" + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/vitest/-/vitest-5.1.1.tgz", + "integrity": "sha512-trVmzUFOSraCZcI3uZIMD5FqBh4atFkC/XuJP/IU7qtyQay0FCs3Ia+0QiQ2JJwGyWG/xrcBoJNel2+O7kEZ0g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/chai": "^5.2.2", + "@vitest/mocker": "5.1.1", + "chai": "^6.3.0", + "es-module-lexer": "^2.3.2", + "expect-type": "^1.4.0", + "magic-string": "^1.4.5", + "obug": "^3.0.0", + "picomatch": "^4.0.7", + "std-env": "^4.3.0", + "tinybench": "^6.2.3", + "tinyexec": "^1.3.1", + "tinyglobby": "^0.2.17", + "why-is-node-running": "3.2.1" }, "bin": { "vitest": "vitest.mjs" }, "engines": { - "node": "^20.0.0 || ^22.0.0 || >=24.0.0" + "node": "^22.12.0 || ^24.0.0 || >=26.0.0" }, "funding": { "url": "https://opencollective.com/vitest" @@ -13925,16 +13981,16 @@ "peerDependencies": { "@edge-runtime/vm": "*", "@opentelemetry/api": "^1.9.0", - "@types/node": "^20.0.0 || ^22.0.0 || >=24.0.0", - "@vitest/browser-playwright": "4.1.9", - "@vitest/browser-preview": "4.1.9", - "@vitest/browser-webdriverio": "4.1.9", - "@vitest/coverage-istanbul": "4.1.9", - "@vitest/coverage-v8": "4.1.9", - "@vitest/ui": "4.1.9", + "@types/node": "^22.0.0 || >=24.0.0", + "@vitest/browser-playwright": "5.1.1", + "@vitest/browser-preview": "5.1.1", + "@vitest/browser-webdriverio": "^5.0.0-beta.5 || >=5.0.0", + "@vitest/coverage-istanbul": "5.1.1", + "@vitest/coverage-v8": "5.1.1", + "@vitest/ui": "5.1.1", "happy-dom": "*", "jsdom": "*", - "vite": "^6.0.0 || ^7.0.0 || ^8.0.0" + "vite": "^6.4.0 || ^7.0.0 || ^8.0.0" }, "peerDependenciesMeta": { "@edge-runtime/vm": { @@ -14084,9 +14140,9 @@ } }, "node_modules/which-typed-array": { - "version": "1.1.22", - "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.22.tgz", - "integrity": "sha512-fvO4ExWMFsqyhG3AiPAObMuY1lxaqgYcxbc49CNdWDDECOJNgQyvsOWVwbZc+qf3rzRtxojBK+CMEv0Ld5CYpw==", + "version": "1.1.24", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.24.tgz", + "integrity": "sha512-wk4Mf4pR5mRP7eYuuTBCIQ9d0ud2Fv2jRLQpfgnRjbOxAFHmjKFValgTpitVKzJJS8ajnYQV2Du1SZ8j6b/EUQ==", "license": "MIT", "dependencies": { "available-typed-arrays": "^1.0.7", @@ -14105,20 +14161,16 @@ } }, "node_modules/why-is-node-running": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/why-is-node-running/-/why-is-node-running-2.3.0.tgz", - "integrity": "sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==", + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/why-is-node-running/-/why-is-node-running-3.2.1.tgz", + "integrity": "sha512-Tb2FUhB4vUsGQlfSquQLYkApkuPAFQXGFzxWKHHumVz2dK+X1RUm/HnID4+TfIGYJ1kTcwOaCk/buYCEJr6YjQ==", "dev": true, "license": "MIT", - "dependencies": { - "siginfo": "^2.0.0", - "stackback": "0.0.2" - }, "bin": { "why-is-node-running": "cli.js" }, "engines": { - "node": ">=8" + "node": ">=20.11" } }, "node_modules/word-extractor": { @@ -14163,13 +14215,12 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", - "dev": true, "license": "ISC" }, "node_modules/ws": { - "version": "8.22.0", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.22.0.tgz", - "integrity": "sha512-Ydggc987+RO0AnWtZ/7Wq9FtNvcrL1b/RO0ud9mWjUPgDrsAAwQSF51sm2hm1XofbU/4jkpGEsLFsZZxU+1DOg==", + "version": "8.23.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.23.0.tgz", + "integrity": "sha512-wCkmX8QMOrKjgO8HW2WyDbTSGeqkocxgDzS9iR79rEAexty6/2qzilx3Ag8Tqf9ykop3irLKle0MtVn5qjVnoQ==", "license": "MIT", "engines": { "node": ">=10.0.0" @@ -14221,9 +14272,9 @@ "license": "ISC" }, "node_modules/yaml": { - "version": "2.9.0", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.9.0.tgz", - "integrity": "sha512-2AvhNX3mb8zd6Zy7INTtSpl1F15HW6Wnqj0srWlkKLcpYl/gMIMJiyuGq2KeI2YFxUPjdlB+3Lc10seMLtL4cA==", + "version": "2.9.1", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.9.1.tgz", + "integrity": "sha512-3NxN8+78OdzbT7C/WjGsyfPAtJaN3FNDsWxv7Y7mcDsT/oOmgW8BpyQQFFBnvZE3j9Y2Sdz1ULFLezL7Eb2yFw==", "license": "ISC", "bin": { "yaml": "bin.mjs" @@ -14288,14 +14339,36 @@ } }, "node_modules/zod": { - "version": "4.4.3", - "resolved": "https://registry.npmjs.org/zod/-/zod-4.4.3.tgz", - "integrity": "sha512-ytENFjIJFl2UwYglde2jchW2Hwm4GJFLDiSXWdTrJQBIN9Fcyp7n4DhxJEiWNAJMV1/BqWfW/kkg71UDcHJyTQ==", + "version": "4.6.7", + "resolved": "https://registry.npmjs.org/zod/-/zod-4.6.7.tgz", + "integrity": "sha512-g8W2D2kU6a8untc053fX1uVBKzM7yqAxW/3zwk83+6RyF2+SKOuV+c0wBDhUwzV1PaGapmZH+rmcUzPf+3CGwg==", "license": "MIT", "funding": { "url": "https://github.com/sponsors/colinhacks" } }, + "node_modules/zod-to-json-schema": { + "version": "3.25.2", + "resolved": "https://registry.npmjs.org/zod-to-json-schema/-/zod-to-json-schema-3.25.2.tgz", + "integrity": "sha512-O/PgfnpT1xKSDeQYSCfRI5Gy3hPf91mKVDuYLUHZJMiDFptvP41MSnWofm8dnCm0256ZNfZIM7DSzuSMAFnjHA==", + "license": "ISC", + "peerDependencies": { + "zod": "^3.25.28 || ^4" + } + }, + "node_modules/zod-validation-error": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/zod-validation-error/-/zod-validation-error-4.0.2.tgz", + "integrity": "sha512-Q6/nZLe6jxuU80qb/4uJ4t5v2VEZ44lzQjPDhYJNztRQ4wyWc6VF3D3Kb/fAuPetZQnhS3hnajCf9CsWesghLQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18.0.0" + }, + "peerDependencies": { + "zod": "^3.25.0 || ^4.0.0" + } + }, "node_modules/zwitch": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/zwitch/-/zwitch-2.0.4.tgz", diff --git a/package.json b/package.json index c783bda9..554720da 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "stem", - "version": "0.7.5", + "version": "0.8.0", "description": "An isolated, pi-backed personal assistant with rich MDX output, app-scoped skills, MCP, and Stem Recall memory.", "author": { "name": "Vladimir Schmotzer", @@ -12,7 +12,7 @@ "node": ">=24" }, "scripts": { - "postinstall": "patch-package && node scripts/ensure-electron.mjs", + "postinstall": "node scripts/ensure-electron.mjs", "preflight": "node scripts/preflight.mjs", "predev": "npm run preflight && node scripts/brand-electron-dev.mjs", "dev": "electron-vite dev", @@ -36,52 +36,58 @@ "eval:memory": "node scripts/memory-eval.mjs", "eval:skills": "node scripts/skill-author-eval.mjs", "eval:skill-retrieval": "node scripts/skill-retrieval-eval.mjs", + "eval:gate-canary": "node scripts/gate-canary.mjs", "fixtures:skills": "node scripts/skill-fixtures.mjs", "probe:quiet": "node scripts/quiet-mutants.mjs", "gen:shortcuts-doc": "node scripts/gen-shortcuts-doc.mjs", "eval:mdx": "node scripts/mdx-usage-eval.mjs" }, "dependencies": { - "@earendil-works/pi-coding-agent": "1.1.0", - "@huggingface/transformers": "^4.3.1", - "acpx": "0.13.1", - "electron-updater": "^6.8.9", - "ignore": "^7.0.12", - "pdfjs-dist": "^6.1.200", - "pele": "^1.6.0", - "pi-web-access": "0.18.0", + "@earendil-works/pi-coding-agent": "1.6.0", + "@huggingface/transformers": "^4.3.2", + "acpx": "0.22.0", + "electron-updater": "^6.8.12", + "ignore": "^7.0.16", + "pdfjs-dist": "^6.5.438", + "pele": "^1.13.0", + "pi-web-access": "0.48.0", "remark-gfm": "^4.0.0", "remark-mdx": "^3.1.0", "remark-parse": "^11.0.0", "unified": "^11.0.5", "word-extractor": "^1.0.4", - "yaml": "^2.6.1" + "yaml": "^2.9.1" }, "devDependencies": { "@electron-toolkit/preload": "^3.0.2", - "@eslint/js": "^9.39.4", - "@playwright/test": "^1.61.0", - "@types/node": "^22.18.6", - "@types/react": "^19.1.13", - "@types/react-dom": "^19.1.9", + "@eslint/js": "^10.0.1", + "@playwright/test": "^1.65.1", + "@types/node": "^24.19.2", + "@types/react": "^19.3.0", + "@types/react-dom": "^19.3.0", "@types/word-extractor": "^1.0.6", - "@typescript-eslint/eslint-plugin": "^8.44.0", - "@typescript-eslint/parser": "^8.44.0", - "@vitejs/plugin-react": "^5.0.4", - "dompurify": "^3.4.16", - "electron": "^42.4.1", - "electron-builder": "^26.15.3", - "electron-vite": "^4.0.0", - "eslint": "^9.36.0", - "eslint-plugin-react-hooks": "^5.2.0", + "@typescript-eslint/eslint-plugin": "^8.73.0", + "@typescript-eslint/parser": "^8.73.0", + "@vitejs/plugin-react": "^6.3.0", + "dompurify": "^3.4.18", + "electron": "^45.4.1", + "electron-builder": "^26.18.1", + "electron-vite": "^6.0.0", + "eslint": "^10.15.0", + "eslint-plugin-react-hooks": "^7.1.1", "lowlight": "^3.3.0", - "lucide-react": "^0.468.0", - "patch-package": "^8.0.1", - "playwright": "^1.61.0", - "react": "^19.1.1", - "react-dom": "^19.1.1", - "typescript": "^5.9.2", - "vite": "^7.1.7", - "vitest": "^4.1.9" + "lucide-react": "^1.77.0", + "playwright": "^1.65.1", + "react": "^19.3.1", + "react-dom": "^19.3.1", + "typescript": "^6.0.3", + "vite": "^8.3.8", + "vitest": "^5.1.1" + }, + "overrides": { + "@earendil-works/pi-coding-agent": { + "undici": "^8.12.3" + }, + "zod": "^4.6.7" } } diff --git a/patches/acpx+0.13.1.patch b/patches/acpx+0.13.1.patch deleted file mode 100644 index 9da31c19..00000000 --- a/patches/acpx+0.13.1.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff --git a/node_modules/acpx/dist/live-checkpoint-BSIrfgVo.js b/node_modules/acpx/dist/live-checkpoint-BSIrfgVo.js -index d454fd7..a764434 100644 ---- a/node_modules/acpx/dist/live-checkpoint-BSIrfgVo.js -+++ b/node_modules/acpx/dist/live-checkpoint-BSIrfgVo.js -@@ -1661,7 +1661,11 @@ const ZED_TAG_KEYS = /* @__PURE__ */ new Set([ - "RedactedThinking", - "ToolUse" - ]); --const MAP_OBJECT_PATHS = /* @__PURE__ */ new Set(["request_token_usage", "messages.Agent.tool_results"]); -+const MAP_OBJECT_PATHS = /* @__PURE__ */ new Set([ -+ "request_token_usage", -+ "messages.Agent.tool_results", -+ "acpx.session_options.env" -+]); - const OPAQUE_VALUE_PATHS = /* @__PURE__ */ new Set([ - "agent_capabilities", - "messages.Agent.content.ToolUse.input", diff --git a/patches/pi-web-access+0.18.0.patch b/patches/pi-web-access+0.18.0.patch deleted file mode 100644 index a20cfb7f..00000000 --- a/patches/pi-web-access+0.18.0.patch +++ /dev/null @@ -1,348 +0,0 @@ -diff --git a/node_modules/pi-web-access/gemini-search.ts b/node_modules/pi-web-access/gemini-search.ts -index 2e72e19..67a1ffc 100644 ---- a/node_modules/pi-web-access/gemini-search.ts -+++ b/node_modules/pi-web-access/gemini-search.ts -@@ -495,28 +495,6 @@ export async function search(query: string, options: FullSearchOptions = {}): Pr - } - } - -- if (shouldTryOpenAIInAuto(options)) { -- try { -- if (await isOpenAISearchAvailable(options.extensionContext)) { -- const result = await searchWithOpenAI(query, options, options.extensionContext); -- return { ...result, provider: "openai" }; -- } -- } catch (err) { -- if (isAbortError(err)) throw err; -- fallbackErrors.push(`OpenAI: ${errorMessage(err)}`); -- } -- } -- -- if (isExaAvailable()) { -- try { -- const result = await searchWithExa(query, options); -- if (result) return { ...result, provider: "exa" }; -- } catch (err) { -- if (err instanceof CredentialResolutionError || isAbortError(err)) throw err; -- fallbackErrors.push(`Exa: ${errorMessage(err)}`); -- } -- } -- - if (isBraveAvailable()) { - try { - const result = await searchWithBrave(query, options); -@@ -617,6 +595,38 @@ export async function search(query: string, options: FullSearchOptions = {}): Pr - } - } - -+ // Keyless terminus of the no-LLM half of the chain: Exa's public MCP endpoint -+ // needs no credential and answers in ~0.4s, so `auto` reaches a real search -+ // engine without a subscription, an API key, or a second inference. -+ if (isExaAvailable()) { -+ try { -+ const result = await searchWithExa(query, options); -+ if (result) return { ...result, provider: "exa" }; -+ } catch (err) { -+ if (err instanceof CredentialResolutionError || isAbortError(err)) throw err; -+ fallbackErrors.push(`Exa: ${errorMessage(err)}`); -+ } -+ } -+ -+ // ---- LLM-mediated backends: a whole model inference per query ---- -+ // -+ // These used to sit at the top of the chain, which meant `auto` spent 5-12s and -+ // a subscription's quota on a second model just to run a query and quote the -+ // results back — while an index lookup one branch below did the same job in -+ // under a second. They belong here: reached only when every engine above is -+ // unavailable or erroring, as a genuinely-better-than-nothing fallback. -+ if (shouldTryOpenAIInAuto(options)) { -+ try { -+ if (await isOpenAISearchAvailable(options.extensionContext)) { -+ const result = await searchWithOpenAI(query, options, options.extensionContext); -+ return { ...result, provider: "openai" }; -+ } -+ } catch (err) { -+ if (isAbortError(err)) throw err; -+ fallbackErrors.push(`OpenAI: ${errorMessage(err)}`); -+ } -+ } -+ - if (isPerplexityAvailable()) { - try { - const result = await searchWithPerplexity(query, options); -diff --git a/node_modules/pi-web-access/index.ts b/node_modules/pi-web-access/index.ts -index cd798e4..f431de2 100644 ---- a/node_modules/pi-web-access/index.ts -+++ b/node_modules/pi-web-access/index.ts -@@ -22,6 +22,7 @@ import { - type StoredSearchData, - } from "./storage.ts"; - import { activityMonitor, type ActivityEntry } from "./activity.ts"; -+import { runSearchBatch } from "./search-batch.ts"; - import { startCuratorServer, type CuratorSearchEntry, type CuratorServerHandle, type IndexedCuratorSearchEntry } from "./curator-server.ts"; - import { - buildDeterministicSummary, -@@ -1795,38 +1796,49 @@ export default function (pi: ExtensionAPI) { - const allInlineContent: ExtractedContent[] = []; - const resolvedProvider = resolveRequestedProvider(params.provider); - -- for (let i = 0; i < queryList.length; i++) { -- const query = queryList[i]; -- -- onUpdate?.({ -- content: [{ type: "text", text: `Searching ${i + 1}/${queryList.length}: "${query}"...` }], -- details: { phase: "search", progress: i / queryList.length, currentQuery: query }, -- }); -- -- try { -- const { answer, results, inlineContent, provider } = await search(query, { -+ // The queries are independent — each returns its own synthesized answer — -+ // so they run through a bounded worker pool with a deadline on the call -+ // as a whole, not one after another. See search-batch.ts. -+ const batch = await runSearchBatch( -+ queryList, -+ { -+ search: (query, _index, batchSignal) => search(query, { - provider: resolvedProvider, - numResults: params.numResults, - recencyFilter, - domainFilter: params.domainFilter, - includeContent: params.includeContent, -- signal, -+ signal: batchSignal, - extensionContext: ctx, -- }); -+ }), -+ onProgress: ({ settled, total, query }) => onUpdate?.({ -+ content: [{ type: "text", text: `Searching ${Math.min(settled + 1, total)}/${total}: "${query}"...` }], -+ details: { phase: "search", progress: settled / total, currentQuery: query }, -+ }), -+ }, -+ { signal }, -+ ); - -- searchResults.push({ query, answer, results, error: null, provider }); -- for (const r of results) { -- if (!allUrls.includes(r.url)) { -- allUrls.push(r.url); -- } -+ const requestedProvider = toCuratorProvider(resolvedProvider); -+ for (const entry of batch) { -+ if (!entry.value) { -+ searchResults.push({ -+ query: entry.query, -+ answer: "", -+ results: [], -+ error: entry.error ?? "Search failed", -+ provider: requestedProvider, -+ }); -+ continue; -+ } -+ const { answer, results, inlineContent, provider } = entry.value; -+ searchResults.push({ query: entry.query, answer, results, error: null, provider }); -+ for (const r of results) { -+ if (!allUrls.includes(r.url)) { -+ allUrls.push(r.url); - } -- if (inlineContent) allInlineContent.push(...inlineContent); -- } catch (err) { -- if (signal?.aborted || isAbortError(err)) throw err; -- const message = err instanceof Error ? err.message : String(err); -- const requestedProvider = toCuratorProvider(resolvedProvider); -- searchResults.push({ query, answer: "", results: [], error: message, provider: requestedProvider }); - } -+ if (inlineContent) allInlineContent.push(...inlineContent); - } - - let approvedSummary: string | undefined; -diff --git a/node_modules/pi-web-access/openai-search.ts b/node_modules/pi-web-access/openai-search.ts -index f562f57..9e63a9b 100644 ---- a/node_modules/pi-web-access/openai-search.ts -+++ b/node_modules/pi-web-access/openai-search.ts -@@ -172,7 +172,7 @@ async function resolvePiAuth(ctx: ExtensionContext, responsesUrl: string, modelO - provider, - apiKey: resolved.apiKey, - model: modelOverride ?? preferred.id, -- headers: resolved.headers ?? {}, -+ headers: definedHeaders(resolved.headers), - responsesUrl, - }; - } -@@ -472,3 +472,8 @@ export async function searchWithOpenAI( - throw redactedError; - } - } -+ -+// pi-ai marks a header to drop with null; fetch would send the string "null". -+function definedHeaders(headers: Record | undefined): Record { -+ return Object.fromEntries(Object.entries(headers ?? {}).filter((e): e is [string, string] => e[1] !== null)); -+} -diff --git a/node_modules/pi-web-access/search-batch.ts b/node_modules/pi-web-access/search-batch.ts -new file mode 100644 -index 0000000..ec2ec09 ---- /dev/null -+++ b/node_modules/pi-web-access/search-batch.ts -@@ -0,0 +1,141 @@ -+// Fan-out for a multi-query web_search call. -+// -+// One `web_search` with N queries used to be an indexed `for` loop with an -+// `await` inside: N sequential upstream round trips, each of which can be a full -+// model inference (the OpenAI/xAI backends post to a Responses endpoint and let -+// the provider's own hosted search tool run). With a 60s per-query timeout and no -+// ceiling on the call as a whole, a routine 4-query research request could hold a -+// turn for four minutes, and the tool schema actively encourages 2-4 queries. -+// -+// The queries are independent — each returns its own synthesized answer — so the -+// only reason they were serial was the shape of the loop. This runs them through -+// a small worker pool instead and gives the whole call a deadline: -+// -+// - results stay in query order regardless of completion order, -+// - a caller abort still aborts the batch (the tool call fails, as before), -+// - the deadline does NOT: it stops starting new queries, cancels the in-flight -+// ones, and returns what finished with an error string on the rest. A slow -+// provider degrades the answer instead of hanging the turn. -+ -+/** Concurrent upstream searches. Above ~4 the provider rate-limits are the wall. */ -+export const DEFAULT_SEARCH_CONCURRENCY = 4; -+ -+/** -+ * Ceiling for the whole call, across every wave. Per-query timeouts are 30-60s -+ * depending on backend, so a serial 4-query call could legitimately run past 4 -+ * minutes; this bounds the tool call itself. -+ */ -+export const DEFAULT_SEARCH_BUDGET_MS = 90_000; -+ -+export interface SearchBatchEntry { -+ query: string; -+ /** The backend's payload, or undefined when the query failed. */ -+ value?: T; -+ error: string | null; -+} -+ -+export interface SearchBatchDeps { -+ /** -+ * Run one query. The signal combines the caller's signal with the batch -+ * deadline — pass it through to the backend so a blown budget actually -+ * cancels the in-flight request rather than leaking it. -+ */ -+ search: (query: string, index: number, signal: AbortSignal) => Promise; -+ /** Fired when a query starts and again when it settles. */ -+ onProgress?: (state: { started: number; settled: number; total: number; query: string }) => void; -+} -+ -+export interface SearchBatchOptions { -+ concurrency?: number; -+ budgetMs?: number; -+ signal?: AbortSignal; -+} -+ -+function isAbortError(err: unknown): boolean { -+ return err instanceof Error && (err.name === "AbortError" || err.name === "TimeoutError"); -+} -+ -+/** -+ * Run every query concurrently (bounded), preserving input order in the result. -+ * Throws only when the caller's own signal aborts — every other failure, the -+ * deadline included, comes back as a per-query `error`. -+ */ -+export async function runSearchBatch( -+ queries: string[], -+ deps: SearchBatchDeps, -+ options: SearchBatchOptions = {}, -+): Promise[]> { -+ const total = queries.length; -+ const entries: SearchBatchEntry[] = queries.map((query) => ({ query, error: null })); -+ if (total === 0) return entries; -+ -+ const budgetMs = options.budgetMs ?? DEFAULT_SEARCH_BUDGET_MS; -+ const concurrency = Math.max(1, Math.min(options.concurrency ?? DEFAULT_SEARCH_CONCURRENCY, total)); -+ -+ // Separate from the caller's signal on purpose: a blown deadline is a partial -+ // result, not a failed tool call, so the two aborts must stay distinguishable. -+ const deadline = new AbortController(); -+ let deadlineFired = false; -+ const timer = setTimeout(() => { -+ deadlineFired = true; -+ deadline.abort(); -+ }, budgetMs); -+ // Node keeps the process alive for a pending timer; a batch that finishes -+ // early should not hold the event loop open for the rest of the budget. -+ (timer as unknown as { unref?: () => void }).unref?.(); -+ -+ const signal = options.signal -+ ? AbortSignal.any([options.signal, deadline.signal]) -+ : deadline.signal; -+ -+ let started = 0; -+ let settled = 0; -+ let next = 0; -+ let callerAborted: unknown; -+ -+ const worker = async (): Promise => { -+ for (;;) { -+ if (options.signal?.aborted || deadlineFired || callerAborted !== undefined) return; -+ const index = next++; -+ if (index >= total) return; -+ const query = queries[index]; -+ started++; -+ deps.onProgress?.({ started, settled, total, query }); -+ try { -+ entries[index].value = await deps.search(query, index, signal); -+ } catch (err) { -+ if (options.signal?.aborted || (isAbortError(err) && !deadlineFired)) { -+ // The turn itself was cancelled — surface it, don't paper over it. -+ callerAborted = err; -+ return; -+ } -+ entries[index].error = deadlineFired && isAbortError(err) -+ ? `Search budget of ${Math.round(budgetMs / 1000)}s exceeded before this query finished` -+ : err instanceof Error ? err.message : String(err); -+ } finally { -+ settled++; -+ deps.onProgress?.({ started, settled, total, query }); -+ } -+ } -+ }; -+ -+ try { -+ await Promise.all(Array.from({ length: concurrency }, () => worker())); -+ } finally { -+ clearTimeout(timer); -+ } -+ -+ if (callerAborted !== undefined) throw callerAborted; -+ -+ // Queries the deadline never let start still have to be accounted for, or the -+ // model silently believes it searched something it did not. -+ if (deadlineFired) { -+ for (const entry of entries) { -+ if (entry.value === undefined && entry.error === null) { -+ entry.error = `Search budget of ${Math.round(budgetMs / 1000)}s exceeded before this query started`; -+ } -+ } -+ } -+ -+ return entries; -+} -diff --git a/node_modules/pi-web-access/xai-search.ts b/node_modules/pi-web-access/xai-search.ts -index 7f515c1..ba8778b 100644 ---- a/node_modules/pi-web-access/xai-search.ts -+++ b/node_modules/pi-web-access/xai-search.ts -@@ -81,7 +81,7 @@ async function resolvePiAuth(ctx: ExtensionContext, modelOverride?: string): Pro - if (!model) continue; - const resolved = await ctx.modelRegistry.getApiKeyAndHeaders(model); - if (resolved.ok && resolved.apiKey) { -- return { apiKey: resolved.apiKey, model: modelOverride ?? modelId, headers: resolved.headers ?? {} }; -+ return { apiKey: resolved.apiKey, model: modelOverride ?? modelId, headers: definedHeaders(resolved.headers) }; - } - } catch { - } -@@ -338,3 +338,8 @@ export async function searchWithXai( - throw redactedError; - } - } -+ -+// pi-ai marks a header to drop with null; fetch would send the string "null". -+function definedHeaders(headers: Record | undefined): Record { -+ return Object.fromEntries(Object.entries(headers ?? {}).filter((e): e is [string, string] => e[1] !== null)); -+} diff --git a/relay/PROTOCOL.md b/relay/PROTOCOL.md index 63710ba0..86cb365b 100644 --- a/relay/PROTOCOL.md +++ b/relay/PROTOCOL.md @@ -179,9 +179,11 @@ relay. `K` = signed request by any key, registered or not. Errors are | `GET /v1/unsubscribe?t=` | — | email link; → confirmation page only | | `POST /v1/unsubscribe` | — | form `t=` → adds the address to the suppression list | | `POST /v1/push` | K | `{token, env, wake}` → `{result:"sent"\|"gone"}`; `409 token_bound`, `502 apns_failed` | -| `POST /v1/shares?ttl=&card=` | SC | blob bytes → `{id, url, expires}`; `400 bad_ttl`, `413`, `429`, `507 too_many_links`, `507 quota_full` | -| `GET /v1/shares` | SC | → `{shares:[{id, url, size, created, expires}]}` | -| `GET /v1/shares/{id}` | — | → blob bytes; `404 not_found`, `410 {error:"gone", why:"revoked"\|"taken_down"}` | +| `POST /v1/shares?ttl=&card=&to=` | SC | blob bytes → `{id, url, expires, recipients?}`; `400 bad_ttl`, `400 bad_recipients`, `413`, `429`, `507 too_many_links`, `507 quota_full` | +| `GET /v1/shares` | SC | → `{shares:[{id, url, size, created, expires, recipients?, opens?:[{address, first, last, count}]}]}` | +| `GET /v1/shares/{id}` | — (locked: the view cookie) | → blob bytes; `401 {error:"locked", recipients:[masked]}`, `404 not_found`, `410 {error:"gone", why:"revoked"\|"taken_down"}` | +| `POST /v1/shares/{id}/code` | — | `{r: index}` → `202 {}`; mails a code to that recipient; `400 bad_recipient`, `400 not_locked`, `429` | +| `POST /v1/shares/{id}/unlock` | — | `{r: index, code}` → `200 {}` + `Set-Cookie: stem_view`; `403 bad_code`, `429` | | `DELETE /v1/shares/{id}` | SC, the owner address | → `{}` | | `POST /v1/shares/{id}/report` | — | `{reason, detail?, contact?, key?}` → `202 {}` | @@ -283,6 +285,27 @@ card's `og:` tags (a removed link gets a "removed" card, a cardless one the page as built). Every share response carries `X-Robots-Tag: noindex`. `report` reasons: `illegal`, `privacy`, `harassment`, `spam`, `other`. + +#### Locked to recipients (feature `share-to`) + +`to` (optional) is base64url (no padding) of a JSON array of addresses, +in the signed path: 1 to `[share] max_recipients` (default 20), normalised +and deduplicated. The upload answer then carries `recipients`. A Stem must +check it: a relay without the feature ignores `to` and makes the link +public, so the Stem deletes the share when `recipients` is missing. + +A locked `GET /v1/shares/{id}` answers `401` with the recipients masked +(`m•••@gmail.com`), in upload order. The visitor picks one by index: +`code` mails a 6-digit code to that address (valid 15 minutes, 5 tries, +one request a minute per share and recipient; `codes_per_recipient_day` per +share and recipient, five times that over all shares; `codes_per_ip_day` +per client IP; a suppressed address answers the same `202` with no mail). +`unlock` with the right code sets `stem_view`: HttpOnly, SameSite=Strict, +Path `/v1/shares/{id}`, Max-Age `view_days` (default 7). With that cookie +the blob comes back (`Cache-Control: no-store`) and the opening is counted +for that recipient. The key still rides only in the fragment, so a visitor +needs both the link and the recipient's inbox. Revoking deletes the +recipients, codes, cookies and openings with the blob. `key` is optional: a reporter who includes it lets the operator see the content. diff --git a/relay/deploy/global/Caddyfile.snippet b/relay/deploy/global/Caddyfile.snippet index 5be81c82..8a37a6c3 100644 --- a/relay/deploy/global/Caddyfile.snippet +++ b/relay/deploy/global/Caddyfile.snippet @@ -45,7 +45,7 @@ relay.heystem.app { share.heystem.app { import cloudflare_dns_heystem header { - Content-Security-Policy "default-src 'none'; script-src 'self' 'wasm-unsafe-eval'; style-src 'self' 'unsafe-inline'; img-src 'self' data: blob:; font-src 'self' data:; connect-src 'self'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'" + Content-Security-Policy "default-src 'none'; script-src 'self' 'wasm-unsafe-eval'; style-src 'self' 'unsafe-inline'; img-src 'self' data: blob:; media-src blob:; font-src 'self' data:; connect-src 'self'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'" Referrer-Policy "no-referrer" X-Content-Type-Options "nosniff" X-Robots-Tag "noindex, nofollow, noarchive" diff --git a/relay/go.mod b/relay/go.mod index 3805821d..1ae34899 100644 --- a/relay/go.mod +++ b/relay/go.mod @@ -4,20 +4,20 @@ go 1.26.0 require ( github.com/BurntSushi/toml v1.6.0 - golang.org/x/crypto v0.58.0 - modernc.org/sqlite v1.60.1 + golang.org/x/crypto v0.59.0 + modernc.org/sqlite v1.62.0 ) require ( - github.com/dustin/go-humanize v1.0.1 // indirect + github.com/dustin/go-humanize v1.1.0 // indirect github.com/google/uuid v1.6.0 // indirect github.com/mattn/go-isatty v0.0.24 // indirect - github.com/ncruces/go-strftime v1.0.0 // indirect + github.com/ncruces/go-strftime v1.1.0 // indirect github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec // indirect - golang.org/x/net v0.60.0 // indirect - golang.org/x/sys v0.49.0 // indirect - golang.org/x/text v0.43.0 // indirect - modernc.org/libc v1.77.1 // indirect + golang.org/x/net v0.62.0 // indirect + golang.org/x/sys v0.50.0 // indirect + golang.org/x/text v0.44.0 // indirect + modernc.org/libc v1.80.1 // indirect modernc.org/mathutil v1.7.1 // indirect modernc.org/memory v1.12.1 // indirect ) diff --git a/relay/go.sum b/relay/go.sum index 96067374..1975beb6 100644 --- a/relay/go.sum +++ b/relay/go.sum @@ -1,47 +1,47 @@ github.com/BurntSushi/toml v1.6.0 h1:dRaEfpa2VI55EwlIW72hMRHdWouJeRF7TPYhI+AUQjk= github.com/BurntSushi/toml v1.6.0/go.mod h1:ukJfTF/6rtPPRCnwkur4qwRxa8vTRFBF0uk2lLoLwho= -github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= -github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= -github.com/google/pprof v0.0.0-20260802141513-ef3492d7dac3 h1:LMLX+LgTNWpfvCBdFebv6EsYotImrt/Ppc5cXIriCSo= -github.com/google/pprof v0.0.0-20260802141513-ef3492d7dac3/go.mod h1:jl5iWTm0/hd5PjEYEOuwAJ57L/CibdZfrqZ5XA5GrCk= +github.com/dustin/go-humanize v1.1.0 h1:dbKTrvD0klcbBV/h4AWJdMuZogJACoMlvWIWZ5b2xWg= +github.com/dustin/go-humanize v1.1.0/go.mod h1:hc1CvRkJMsgxqjmjMQF3QNRAZBwY8AXBAzKYoSX9sFI= +github.com/google/pprof v0.0.0-20261016150608-1facf8f91b50 h1:PlNWJRxu5APSV0pWqfIsZ0qt9OOGHSWfZQ4zvx+WgWs= +github.com/google/pprof v0.0.0-20261016150608-1facf8f91b50/go.mod h1:yUo1AMMpsPIDFGuwDK8nLcf8+vvAd5l2O6JDZ6hpwrM= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/hashicorp/golang-lru/v2 v2.0.7 h1:a+bsQ5rvGLjzHuww6tVxozPZFVghXaHOwFs4luLUK2k= github.com/hashicorp/golang-lru/v2 v2.0.7/go.mod h1:QeFd9opnmA6QUJc5vARoKUSoFhyfM2/ZepoAG6RGpeM= github.com/mattn/go-isatty v0.0.24 h1:tGZZoVgT/KiqK1c8ocVLeDS8BSWMRd47J3Lbz7vsReI= github.com/mattn/go-isatty v0.0.24/go.mod h1:nMCL3Zebbrt45jsMDgnfIwz6ydEQApk5oEI3HqDio6A= -github.com/ncruces/go-strftime v1.0.0 h1:HMFp8mLCTPp341M/ZnA4qaf7ZlsbTc+miZjCLOFAw7w= -github.com/ncruces/go-strftime v1.0.0/go.mod h1:Fwc5htZGVVkseilnfgOVb9mKy6w1naJmn9CehxcKcls= +github.com/ncruces/go-strftime v1.1.0 h1:vtPmPWMkb539RGV9WpWT9EwJGvrOCKvMNI4obWL47Hk= +github.com/ncruces/go-strftime v1.1.0/go.mod h1:yVaq7iwCN09vHRrKBrrflXT0M9tTMG2KmZ9Fj7xeG/g= github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec h1:W09IVJc94icq4NjY3clb7Lk8O1qJ8BdBEF8z0ibU0rE= github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo= -golang.org/x/crypto v0.58.0 h1:COkYLr4k7nDI4r6QtMML2AfzeIswWHAJthLS6K/M/54= -golang.org/x/crypto v0.58.0/go.mod h1:Xh+kl5A+M0gMiWDytH2Hhr5Z7WbNCpv/eB/EFgfSk+w= -golang.org/x/mod v0.41.0 h1:qJmnOUb4YB+FsEuM3HcWucdZASCPGhsX6uljO6pog0c= -golang.org/x/mod v0.41.0/go.mod h1:Ek9pY8RKWXwsWvd3rQiHYtMqkjSUV+s1Rj7j4H5Ur6o= -golang.org/x/net v0.60.0 h1:79p50tfZlm0J9YfoDsSi639qSXNGVwEzOPLCxM2FsYU= -golang.org/x/net v0.60.0/go.mod h1:2DA/G1UfVbCpQPeWTmMPGY7Cs2PkBkwu743bVX5PIVg= -golang.org/x/sync v0.24.0 h1:iqiDrGoDgyuvAKrhLQthUEzU/R378N78gXbBjxed7oA= -golang.org/x/sync v0.24.0/go.mod h1:sUUOizhqBxiL6pEWpqNLUiaJn1ShEbZ6BBqskPbjZm0= -golang.org/x/sys v0.49.0 h1:XbzkgYJHdqh/8m2Uu0W/dQv8nktxx4BFHp1M0gROTXA= -golang.org/x/sys v0.49.0/go.mod h1:hNLxWAXmnKAxqDtdwIYC4bM9oQPEecfsnNMuSxOs3og= -golang.org/x/text v0.43.0 h1:1QivrlhwAsnMOcqgOdl9my7s9OyZl8O5/UGUTJVXoWc= -golang.org/x/text v0.43.0/go.mod h1:hbSIYA/amXcRXTFSZqh8tWHEoqRvvbKPJ2uz/KU+a+s= -golang.org/x/tools v0.51.0 h1:k4Xc/1Om9jwkBJBo4NVLMSARBoWtK10mx+W5BnXCeAI= -golang.org/x/tools v0.51.0/go.mod h1:9eEncMayCV6zRMGhR5eZEC2iBx98qWcF1HZ9Z7wJOoA= -modernc.org/cc/v4 v4.29.7 h1:q+NXGJ0bK3b4TXFYQQVr9pYETGnmwFWkrUzJnMya/Tg= -modernc.org/cc/v4 v4.29.7/go.mod h1:OnovgIhbbMXMu1aISnJ0wvVD1KnW+cAUJkIrAWh+kVI= -modernc.org/ccgo/v4 v4.36.1 h1:ZNIUZAryN0UgnJwtyxrdEzcFc3yD4Cu4AzjfPXsLsIE= -modernc.org/ccgo/v4 v4.36.1/go.mod h1:rrtGc2QkS239nYb/mQNuBMyjq3/y3ZXWbBjPoV3wqzA= +golang.org/x/crypto v0.59.0 h1:xS2jhqYbzNrpvkWP2YTDf4TJwBy3ykR03i8vFDxEc7c= +golang.org/x/crypto v0.59.0/go.mod h1:veDyUwATGs3c+vN3VfTbzViMGXeTBk3WyhBOkn+F/4U= +golang.org/x/mod v0.42.0 h1:ICeL3t2L30ljSPHHxDnR4fqVcBt/zR2zJAb9juavmQg= +golang.org/x/mod v0.42.0/go.mod h1:u5fzIrRInkL8MaO1cbRkUHT64v303YIT5KEqpNr7jRs= +golang.org/x/net v0.62.0 h1:18ELalfM5+XNRwzM2nYqXsZQ9ByS1uhj2O/U7+5jqRY= +golang.org/x/net v0.62.0/go.mod h1:WgDCOTH8iwtB66T4/GfI94AHo/hhdb7Hah9NDseQfiI= +golang.org/x/sync v0.25.0 h1:dJnifr0nMV8/SBnBvdo4eSGGnrc3O4FFx6IqvtLcmRs= +golang.org/x/sync v0.25.0/go.mod h1:sUUOizhqBxiL6pEWpqNLUiaJn1ShEbZ6BBqskPbjZm0= +golang.org/x/sys v0.50.0 h1:dkKZEFTEKaLr1sjhs0WiKqoi8Jj5nHbS3Njmx1UoMJs= +golang.org/x/sys v0.50.0/go.mod h1:hNLxWAXmnKAxqDtdwIYC4bM9oQPEecfsnNMuSxOs3og= +golang.org/x/text v0.44.0 h1:YItdp/mQNGnsmrgpcdA5yQ3bnRxCfo/Tj/iByGW9GGo= +golang.org/x/text v0.44.0/go.mod h1:S4FR1waQ9LbjQTls97SyRjDaUUVkaM+cXwwuG/G+MwY= +golang.org/x/tools v0.52.0 h1:ryxg4U63oaUYk7uOLTF37n43f4qgtGvqV4Ioit1BaEs= +golang.org/x/tools v0.52.0/go.mod h1:ItcP5UNaVGG+Yc4eIYmaFLNJ4soEopkx5Y2d4lcEurs= +modernc.org/cc/v4 v4.30.6-0.20261101114202-1b9d1a076f6b h1:WE5SLOURcNd8s6uPR/n4WV4weQxxYKi5OpEZkfNVvdE= +modernc.org/cc/v4 v4.30.6-0.20261101114202-1b9d1a076f6b/go.mod h1:OnovgIhbbMXMu1aISnJ0wvVD1KnW+cAUJkIrAWh+kVI= +modernc.org/ccgo/v4 v4.38.1 h1:wdxJVBuFT8JufZnnQyS6Bbz3NOWhViD0xJOGR96Bpd4= +modernc.org/ccgo/v4 v4.38.1/go.mod h1:kOpEkJRbFwBvjUWwn4j1j9B7iFHbl1+orhgTMCDkDBk= modernc.org/fileutil v1.4.0 h1:j6ZzNTftVS054gi281TyLjHPp6CPHr2KCxEXjEbD6SM= modernc.org/fileutil v1.4.0/go.mod h1:EqdKFDxiByqxLk8ozOxObDSfcVOv/54xDs/DUHdvCUU= modernc.org/gc/v2 v2.6.5 h1:nyqdV8q46KvTpZlsw66kWqwXRHdjIlJOhG6kxiV/9xI= modernc.org/gc/v2 v2.6.5/go.mod h1:YgIahr1ypgfe7chRuJi2gD7DBQiKSLMPgBQe9oIiito= -modernc.org/gc/v3 v3.1.5 h1:21ldfPfRYE31Tb7B3mwAK8gy1AxP4+dKjrOQPfqakoc= -modernc.org/gc/v3 v3.1.5/go.mod h1:HFK/6AGESC7Ex+EZJhJ2Gni6cTaYpSMmU/cT9RmlfYY= +modernc.org/gc/v3 v3.2.0 h1:/Y3LGDMQaoYf55PebP1qsZ5FDGgAZyG1RYKEHeQzh1o= +modernc.org/gc/v3 v3.2.0/go.mod h1:HFK/6AGESC7Ex+EZJhJ2Gni6cTaYpSMmU/cT9RmlfYY= modernc.org/goabi0 v0.2.0 h1:HvEowk7LxcPd0eq6mVOAEMai46V+i7Jrj13t4AzuNks= modernc.org/goabi0 v0.2.0/go.mod h1:CEFRnnJhKvWT1c1JTI3Avm+tgOWbkOu5oPA8eH8LnMI= -modernc.org/libc v1.77.1 h1:Ct8j47QtiZ1Enj2DtFXQtUqrPCAjdCmPjtCuvrYQ0Hs= -modernc.org/libc v1.77.1/go.mod h1:87/pZ4L6nD1zqW4nItuS12YO7hN1igAah34xjnQo/W0= +modernc.org/libc v1.80.1 h1:ejn7HtTV3GknNKbklqWQ1nvUrfX8mTxs1D+xp/JQwy4= +modernc.org/libc v1.80.1/go.mod h1:pvo25Rs3OJEbDqhUV9jdEGevxeLJrJeDmNid/AcQV1g= modernc.org/mathutil v1.7.1 h1:GCZVGXdaN8gTqB1Mf/usp1Y/hSqgI2vAGGP4jZMCxOU= modernc.org/mathutil v1.7.1/go.mod h1:4p5IwJITfppl0G4sUEDtCr4DthTaT47/N3aT6MhfgJg= modernc.org/memory v1.12.1 h1:nFMiWrpStgZczNl6XI9GnIk/rWhYIyHGUaR04pGbp9g= @@ -50,8 +50,8 @@ modernc.org/opt v0.2.0 h1:tGyef5ApycA7FSEOMraay9SaTk5zmbx7Tu+cJs4QKZg= modernc.org/opt v0.2.0/go.mod h1:03fq9lsNfvkYSfxrfUhZCWPk1lm4cq4N+Bh//bEtgns= modernc.org/sortutil v1.2.1 h1:+xyoGf15mM3NMlPDnFqrteY07klSFxLElE2PVuWIJ7w= modernc.org/sortutil v1.2.1/go.mod h1:7ZI3a3REbai7gzCLcotuw9AC4VZVpYMjDzETGsSMqJE= -modernc.org/sqlite v1.60.1 h1:/blz53O951KWFOso4QQvEs/Fq6cDBKLtMVrYNSeJVKw= -modernc.org/sqlite v1.60.1/go.mod h1:1dIoEagfDE72QytD5scH1lxARtaUgKgHC/NuApA27r0= +modernc.org/sqlite v1.62.0 h1:gMaCjSM1qpl+iOjiWhR1LYP3zqrYDI+5GYLGt6veP2g= +modernc.org/sqlite v1.62.0/go.mod h1:Jzjh1mt4s0HuQ0KvtB1LIuHiGRmU2D5pgj8dUhW7/SE= modernc.org/strutil v1.2.1 h1:UneZBkQA+DX2Rp35KcM69cSsNES9ly8mQWD71HKlOA0= modernc.org/strutil v1.2.1/go.mod h1:EHkiggD70koQxjVdSBM3JKM7k6L0FbGE5eymy9i3B9A= modernc.org/token v1.1.0 h1:Xl7Ap9dKaEs5kLoOQeQmPWevfnk/DM5qcLcYlA8ys6Y= diff --git a/relay/internal/config/config.go b/relay/internal/config/config.go index 141242c8..57b556e6 100644 --- a/relay/internal/config/config.go +++ b/relay/internal/config/config.go @@ -71,6 +71,14 @@ type Share struct { MaxTTLDays int `toml:"max_ttl_days"` // Abuse reports per client IP per hour. ReportsPerIPHour int `toml:"reports_per_ip_hour"` + // Recipient-locked links: the most recipients per share, codes mailed to + // one address per share per day (five times that over all shares), code + // requests per client IP per day, and days a browser that entered a code + // keeps access. + MaxRecipients int `toml:"max_recipients"` + CodesPerRecipientDay int `toml:"codes_per_recipient_day"` + CodesPerIPDay int `toml:"codes_per_ip_day"` + ViewDays int `toml:"view_days"` } // Push is the APNs gateway: Stems without the app's APNs key send wake-ups @@ -165,7 +173,7 @@ func Defaults() Config { }, Push: Push{PerIPHour: 600, PerKeyHour: 120, PerTokenHour: 60, GlobalHour: 20000, RebindDays: 7}, Share: Share{MaxBytes: 12 << 20, PerAddressDay: 30, MaxLive: 100, QuotaBytes: 500 << 20, MaxTTLDays: 30, - ReportsPerIPHour: 20}, + ReportsPerIPHour: 20, MaxRecipients: 20, CodesPerRecipientDay: 10, CodesPerIPDay: 30, ViewDays: 7}, } } diff --git a/relay/internal/server/server.go b/relay/internal/server/server.go index d46db531..39523132 100644 --- a/relay/internal/server/server.go +++ b/relay/internal/server/server.go @@ -248,6 +248,8 @@ func (s *Server) Handler() http.Handler { mux.HandleFunc("GET /v1/shares/{id}", s.wrap(0, s.getShare)) mux.HandleFunc("DELETE /v1/shares/{id}", s.wrap(0, s.deleteShare)) mux.HandleFunc("POST /v1/shares/{id}/report", s.wrap(small, s.reportShare)) + mux.HandleFunc("POST /v1/shares/{id}/code", s.wrap(small, s.shareCode)) + mux.HandleFunc("POST /v1/shares/{id}/unlock", s.wrap(small, s.shareUnlock)) mux.HandleFunc("GET /s/{id}", s.wrap(0, s.sharePage)) mux.HandleFunc("GET /assets/", s.viewerAsset) mux.HandleFunc("GET /og.png", s.viewerAsset) @@ -450,7 +452,7 @@ func (s *Server) info(w http.ResponseWriter, r *http.Request, _ []byte) error { l := s.cfg.Limits limits := map[string]any{"maxMailBytes": l.MaxMailBytes, "powBits": l.PowBits, "holdDays": l.HoldDays} if s.cfg.Share.Enabled { - features = append(features, "share") + features = append(features, "share", "share-to") limits["maxShareBytes"] = s.cfg.Share.MaxBytes limits["maxShareTtlDays"] = s.cfg.Share.MaxTTLDays } diff --git a/relay/internal/server/share.go b/relay/internal/server/share.go index 4c0ecb1d..4eca39db 100644 --- a/relay/internal/server/share.go +++ b/relay/internal/server/share.go @@ -76,6 +76,10 @@ func (s *Server) postShare(w http.ResponseWriter, r *http.Request, body []byte) if err != nil { return err } + recipients, err := parseRecipients(r.URL.Query().Get("to"), cfg.MaxRecipients) + if err != nil { + return err + } live, used, err := s.st.OwnerShareUsage(addr) if err != nil { return err @@ -92,11 +96,17 @@ func (s *Server) postShare(w http.ResponseWriter, r *http.Request, body []byte) return fail(429, "rate_limited") } sh := &store.Share{ID: newShareID(), Owner: addr, Fp: fp, Size: int64(len(body)), Blob: body, - Created: s.Now().UnixMilli(), Expires: expires, CardTitle: cardTitle, CardDesc: cardDesc} + Created: s.Now().UnixMilli(), Expires: expires, CardTitle: cardTitle, CardDesc: cardDesc, Recipients: recipients} if err := s.st.PutShare(sh); err != nil { return err } - writeJSON(w, 200, map[string]any{"id": sh.ID, "url": s.shareURL(sh.ID), "expires": expires}) + out := map[string]any{"id": sh.ID, "url": s.shareURL(sh.ID), "expires": expires} + if len(recipients) > 0 { + // The Stem checks this: a relay without locked links would have + // ignored ?to= and made the link public. + out["recipients"] = recipients + } + writeJSON(w, 200, out) return nil } @@ -127,8 +137,24 @@ func (s *Server) getShare(w http.ResponseWriter, r *http.Request, _ []byte) erro writeJSON(w, 410, map[string]string{"error": "gone", "why": why}) return nil } - // Short cache, so a revoke takes effect within a minute. - h.Set("Cache-Control", "private, max-age=60") + if len(sh.Recipients) > 0 { + // Locked: only a browser that entered a mailed code gets the blob. + h.Set("Cache-Control", "no-store") + who, err := s.viewer(r, sh) + if err != nil { + return err + } + if who == "" { + writeJSON(w, 401, map[string]any{"error": "locked", "recipients": masked(sh.Recipients)}) + return nil + } + if err := s.st.RecordShareOpen(sh.ID, who, s.Now().UnixMilli()); err != nil { + return err + } + } else { + // Short cache, so a revoke takes effect within a minute. + h.Set("Cache-Control", "private, max-age=60") + } h.Set("Content-Type", "application/octet-stream") h.Set("Content-Length", strconv.Itoa(len(sh.Blob))) _, _ = w.Write(sh.Blob) @@ -175,9 +201,22 @@ func (s *Server) listShares(w http.ResponseWriter, r *http.Request, body []byte) if err != nil { return err } + opens, err := s.st.OwnerShareOpens(addr) + if err != nil { + return err + } out := make([]map[string]any, 0, len(rows)) for _, sh := range rows { - out = append(out, map[string]any{"id": sh.ID, "url": s.shareURL(sh.ID), "size": sh.Size, "created": sh.Created, "expires": sh.Expires}) + row := map[string]any{"id": sh.ID, "url": s.shareURL(sh.ID), "size": sh.Size, "created": sh.Created, "expires": sh.Expires} + if len(sh.Recipients) > 0 { + row["recipients"] = sh.Recipients + o := opens[sh.ID] + if o == nil { + o = []store.ShareOpen{} + } + row["opens"] = o + } + out = append(out, row) } writeJSON(w, 200, map[string]any{"shares": out}) return nil diff --git a/relay/internal/server/share_locked.go b/relay/internal/server/share_locked.go new file mode 100644 index 00000000..cf75944b --- /dev/null +++ b/relay/internal/server/share_locked.go @@ -0,0 +1,255 @@ +package server + +import ( + "encoding/base64" + "encoding/json" + "errors" + "fmt" + "log" + "net/http" + "strings" + "time" + + "github.com/join3r/stem/relay/internal/mailer" + "github.com/join3r/stem/relay/internal/proto" + "github.com/join3r/stem/relay/internal/store" +) + +// Recipient-locked share links (PROTOCOL.md, "Share links"). The sharer +// names the addresses that may open the link. A visitor must enter a code +// the relay mails to one of them before the relay hands out the blob. The +// key still rides only in the link's fragment, so a link needs both: the +// link (for the key) and the inbox (for the code). + +const ( + shareCodeTTL = 15 * time.Minute + shareViewCookie = "stem_view" +) + +// parseRecipients reads ?to=base64url(JSON ["a@b", …]); it rides in the +// signed path. Normalised, deduplicated, at most max. +func parseRecipients(v string, max int) ([]string, error) { + if v == "" { + return nil, nil + } + raw, err := base64.RawURLEncoding.DecodeString(v) + if err != nil || len(raw) > 16<<10 { + return nil, fail(400, "bad_recipients") + } + var in []string + if json.Unmarshal(raw, &in) != nil { + return nil, fail(400, "bad_recipients") + } + seen := map[string]bool{} + var out []string + for _, a := range in { + addr, err := addressArg(a) + if err != nil { + return nil, fail(400, "bad_recipients") + } + if !seen[addr] { + seen[addr] = true + out = append(out, addr) + } + } + if len(out) == 0 || max > 0 && len(out) > max { + return nil, fail(400, "bad_recipients") + } + return out, nil +} + +// maskAddress shows enough of an address for its owner to know it: +// "martin@gmail.com" → "m•••@gmail.com". +func maskAddress(a string) string { + at := strings.LastIndex(a, "@") + if at < 1 { + return "•••" + } + first := []rune(a[:at])[0] + return string(first) + "•••" + a[at:] +} + +func masked(r []string) []string { + out := make([]string, len(r)) + for i, a := range r { + out[i] = maskAddress(a) + } + return out +} + +func viewTokenHash(token string) string { + return proto.SHA256Hex([]byte("stem-share-view-v1\n" + token)) +} + +func shareCodeHash(code, share, address string) string { + return proto.SHA256Hex([]byte("stem-share-code-v1\n" + code + "\n" + share + "\n" + address)) +} + +// viewer returns the recipient this request's browser proved, or "". +func (s *Server) viewer(r *http.Request, sh *store.Share) (string, error) { + c, err := r.Cookie(shareViewCookie) + if err != nil || c.Value == "" { + return "", nil + } + addr, err := s.st.ShareView(viewTokenHash(c.Value), sh.ID) + if errors.Is(err, store.ErrNotFound) { + return "", nil + } + return addr, err +} + +// lockedShare loads a live, locked share for the code and unlock calls. +func (s *Server) lockedShare(r *http.Request) (*store.Share, error) { + if err := s.shareOn(); err != nil { + return nil, err + } + id := r.PathValue("id") + if !shareIDRe.MatchString(id) { + return nil, fail(404, "not_found") + } + sh, err := s.st.GetShare(id) + if errors.Is(err, store.ErrNotFound) { + return nil, fail(404, "not_found") + } else if err != nil { + return nil, err + } + if sh.Removed > 0 { + return nil, fail(410, "gone") + } + if len(sh.Recipients) == 0 { + return nil, fail(400, "not_locked") + } + return sh, nil +} + +func recipientArg(sh *store.Share, i *int) (string, error) { + if i == nil || *i < 0 || *i >= len(sh.Recipients) { + return "", fail(400, "bad_recipient") + } + return sh.Recipients[*i], nil +} + +// shareCode mails a one-time code to one of the share's recipients. The +// visitor picks the recipient by index, so the page never learns the full +// address. +func (s *Server) shareCode(w http.ResponseWriter, r *http.Request, body []byte) error { + sh, err := s.lockedShare(r) + if err != nil { + return err + } + var in struct { + R *int `json:"r"` + } + if err := decode(body, &in); err != nil { + return err + } + addr, err := recipientArg(sh, in.R) + if err != nil { + return err + } + cfg := s.cfg.Share + for _, c := range []struct { + k string + window time.Duration + n int + }{ + {"share:code:wait:" + sh.ID + ":" + addr, time.Minute, 1}, + // Per share, so a visitor of one link cannot use up the codes for + // the recipient's other links… + {"share:code:to:" + sh.ID + ":" + addr, day, cfg.CodesPerRecipientDay}, + // …and a wider cap over all shares, so a sharer cannot spam an + // address with many links. + {"share:code:all:" + addr, day, 5 * cfg.CodesPerRecipientDay}, + {"share:code:ip:" + ipBucket(s.clientIP(r)), day, cfg.CodesPerIPDay}, + } { + if ok, err := s.hit(c.k, c.window, c.n); err != nil { + return err + } else if !ok { + return fail(429, "rate_limited") + } + } + // An address that asked never to get mail from the relay reads the same + // as one that got it: the visitor learns nothing. + if sup, err := s.st.Suppressed(addr); err != nil { + return err + } else if sup { + writeJSON(w, 202, map[string]any{}) + return nil + } + code := randomDigits(6) + if err := s.st.PutShareCode(sh.ID, addr, shareCodeHash(code, sh.ID, addr), s.Now().Add(shareCodeTTL).UnixMilli()); err != nil { + return err + } + unsub := randomToken() + if err := s.st.PutUnsubToken(unsub, addr); err != nil { + return err + } + stop := s.cfg.URL + "/v1/unsubscribe?t=" + unsub + text := fmt.Sprintf("%s shared a page with you on Stem, and someone just asked to open it.\n\n"+ + "Your code is %s. It works for %d minutes.\n\n"+ + "If that was not you, ignore this email. The page stays locked without the code.\n\n"+ + "Never email me again: %s\n", sh.Owner, code, int(shareCodeTTL/time.Minute), stop) + msg := mailer.Message{Kind: mailer.Verify, To: addr, Subject: "Your Stem code: " + code, Body: text, Tag: "s-" + unsub[:12]} + if err := s.mail.Send(msg); err != nil { + log.Printf("share code mail to %s failed: %v", addr, err) + } + writeJSON(w, 202, map[string]any{}) + return nil +} + +// shareUnlock checks a code. A match sets a cookie, scoped to this share, +// that lets the browser read it for view_days. +func (s *Server) shareUnlock(w http.ResponseWriter, r *http.Request, body []byte) error { + sh, err := s.lockedShare(r) + if err != nil { + return err + } + var in struct { + R *int `json:"r"` + Code string `json:"code"` + } + if err := decode(body, &in); err != nil { + return err + } + addr, err := recipientArg(sh, in.R) + if err != nil { + return err + } + for _, c := range []struct { + k string + n int + }{{"share:unlock:ip:" + ipBucket(s.clientIP(r)), 30}, {"share:unlock:to:" + sh.ID + ":" + addr, 20}} { + if ok, err := s.hit(c.k, time.Hour, c.n); err != nil { + return err + } else if !ok { + return fail(429, "rate_limited") + } + } + code := strings.TrimSpace(in.Code) + ok, err := s.st.UseShareCode(sh.ID, addr, shareCodeHash(code, sh.ID, addr)) + if err != nil { + return err + } + if !ok { + return fail(403, "bad_code") + } + days := s.cfg.Share.ViewDays + if days < 1 { + days = 1 + } + token := randomToken() + if err := s.st.PutShareView(viewTokenHash(token), sh.ID, addr, s.Now().Add(time.Duration(days)*day).UnixMilli()); err != nil { + return err + } + http.SetCookie(w, &http.Cookie{ + Name: shareViewCookie, + Value: token, + Path: "/v1/shares/" + sh.ID, + MaxAge: days * 86400, + HttpOnly: true, + Secure: strings.HasPrefix(s.cfg.Share.ViewerURL, "https://"), + SameSite: http.SameSiteStrictMode, + }) + writeJSON(w, 200, map[string]any{}) + return nil +} diff --git a/relay/internal/server/share_locked_test.go b/relay/internal/server/share_locked_test.go new file mode 100644 index 00000000..889407ac --- /dev/null +++ b/relay/internal/server/share_locked_test.go @@ -0,0 +1,185 @@ +package server + +import ( + "bytes" + "encoding/base64" + "encoding/json" + "io" + "net/http" + "net/http/cookiejar" + "strings" + "testing" +) + +func toParam(addrs ...string) string { + b, _ := json.Marshal(addrs) + return base64.RawURLEncoding.EncodeToString(b) +} + +// browser is a visitor with its own cookies. +type browser struct { + t *testing.T + c *http.Client +} + +func newBrowser(t *testing.T) *browser { + jar, _ := cookiejar.New(nil) + return &browser{t, &http.Client{Jar: jar}} +} + +func (b *browser) get(url string) (int, []byte) { + b.t.Helper() + resp, err := b.c.Get(url) + if err != nil { + b.t.Fatal(err) + } + defer resp.Body.Close() + out, _ := io.ReadAll(resp.Body) + return resp.StatusCode, out +} + +func (b *browser) post(url, body string) (int, []byte) { + b.t.Helper() + resp, err := b.c.Post(url, "application/json", strings.NewReader(body)) + if err != nil { + b.t.Fatal(err) + } + defer resp.Body.Close() + out, _ := io.ReadAll(resp.Body) + return resp.StatusCode, out +} + +func TestLockedShareLinks(t *testing.T) { + w := newWorld(t) + g := w.global + a := w.newStem(g, "a@gmail.test") + a.register() + g.srv.cfg.Share.Enabled = true + g.srv.cfg.Share.ViewerURL = "https://share.example" + + // Bad recipient lists are refused, not turned into a public link. + for _, to := range []string{"!!", toParam(), toParam("not an address")} { + if code, out := a.doRaw(g.http.URL, "POST", "/v1/shares?to="+to, blob(64), true); code != 400 { + t.Fatalf("to=%q answered %d %s", to, code, out) + } + } + g.srv.cfg.Share.MaxRecipients = 2 + if code, _ := a.doRaw(g.http.URL, "POST", "/v1/shares?to="+toParam("x@x.test", "y@y.test", "z@z.test"), blob(64), true); code != 400 { + t.Fatalf("too many recipients answered %d", code) + } + + code, out := a.doRaw(g.http.URL, "POST", "/v1/shares?to="+toParam("Martin@Gmail.test", "martin@gmail.test", "eva@mail.test"), blob(64), true) + if code != 200 { + t.Fatalf("locked upload: %d %s", code, out) + } + var made struct { + ID string `json:"id"` + Recipients []string `json:"recipients"` + } + _ = json.Unmarshal(out, &made) + if strings.Join(made.Recipients, ",") != "martin@gmail.test,eva@mail.test" { + t.Fatalf("upload must echo the normalised recipients: %s", out) + } + base := g.http.URL + "/v1/shares/" + made.ID + + // Without a code: locked, with masked addresses only. + v := newBrowser(t) + code, out = v.get(base) + if code != 401 || !strings.Contains(string(out), `"m•••@gmail.test"`) || strings.Contains(string(out), "martin@") { + t.Fatalf("locked fetch: %d %s", code, out) + } + + // A code goes to the picked recipient only, and only once a minute. + before := len(g.mail.Messages()) + if code, out := v.post(base+"/code", `{"r":0}`); code != 202 { + t.Fatalf("code: %d %s", code, out) + } + msgs := g.mail.Messages()[before:] + if len(msgs) != 1 || msgs[0].To != "martin@gmail.test" || !strings.Contains(msgs[0].Body, "a@gmail.test shared a page") { + t.Fatalf("code mail: %+v", msgs) + } + if code, _ := v.post(base+"/code", `{"r":0}`); code != 429 { + t.Fatalf("second code within a minute answered %d", code) + } + if code, _ := v.post(base+"/code", `{"r":5}`); code != 400 { + t.Fatalf("bad index answered %d", code) + } + + // A wrong code fails; the right one sets the cookie and opens the blob. + if code, _ := v.post(base+"/unlock", `{"r":0,"code":"000000x"}`); code != 403 { + t.Fatalf("wrong code answered %d", code) + } + right := lastCode(t, g.mail, "martin@gmail.test") + if code, _ := v.post(base+"/unlock", `{"r":1,"code":"`+right+`"}`); code != 403 { + t.Fatalf("martin's code for eva answered %d", code) + } + if code, out := v.post(base+"/unlock", `{"r":0,"code":"`+right+`"}`); code != 200 { + t.Fatalf("unlock: %d %s", code, out) + } + if code, _ := v.post(base+"/unlock", `{"r":0,"code":"`+right+`"}`); code != 403 { + t.Fatalf("a used code answered %d", code) + } + code, got := v.get(base) + if code != 200 || !bytes.Equal(got, blob(64)) { + t.Fatalf("unlocked fetch: %d %s", code, got) + } + v.get(base) + + // Another browser with the same link is still locked. + if code, _ := newBrowser(t).get(base); code != 401 { + t.Fatalf("other browser answered %d", code) + } + + // The owner sees recipients and who opened, how often. + _, out = a.do(g.http.URL, "GET", "/v1/shares", nil, true) + var list struct { + Shares []struct { + ID string `json:"id"` + Recipients []string `json:"recipients"` + Opens []struct { + Address string `json:"address"` + First int64 `json:"first"` + Count int `json:"count"` + } `json:"opens"` + } `json:"shares"` + } + _ = json.Unmarshal(out, &list) + if len(list.Shares) != 1 || len(list.Shares[0].Recipients) != 2 || len(list.Shares[0].Opens) != 1 || + list.Shares[0].Opens[0].Address != "martin@gmail.test" || list.Shares[0].Opens[0].Count != 2 || list.Shares[0].Opens[0].First == 0 { + t.Fatalf("list: %s", out) + } + + // Five wrong codes use a code up. + if code, _ := v.post(base+"/code", `{"r":1}`); code != 202 { + t.Fatalf("code for eva answered %d", code) + } + eva := lastCode(t, g.mail, "eva@mail.test") + for range 5 { + v.post(base+"/unlock", `{"r":1,"code":"999999x"}`) + } + if code, _ := v.post(base+"/unlock", `{"r":1,"code":"`+eva+`"}`); code != 403 { + t.Fatalf("code after five misses answered %d", code) + } + + // A public share has no code flow. + code, out = a.doRaw(g.http.URL, "POST", "/v1/shares", blob(64), true) + var pub struct { + ID string `json:"id"` + Recipients []string `json:"recipients"` + } + _ = json.Unmarshal(out, &pub) + if code != 200 || pub.Recipients != nil { + t.Fatalf("public upload: %d %s", code, out) + } + if code, _ := v.post(g.http.URL+"/v1/shares/"+pub.ID+"/code", `{"r":0}`); code != 400 { + t.Fatalf("code on a public share answered %d", code) + } + + // Revoke: the unlocked browser is shut out too. + if code, _ := a.do(g.http.URL, "DELETE", "/v1/shares/"+made.ID, nil, true); code != 200 { + t.Fatalf("revoke answered %d", code) + } + if code, _ := v.get(base); code != 410 { + t.Fatalf("revoked locked fetch answered %d", code) + } +} diff --git a/relay/internal/store/shares.go b/relay/internal/store/shares.go index f382dc3d..79155a75 100644 --- a/relay/internal/store/shares.go +++ b/relay/internal/store/shares.go @@ -2,6 +2,7 @@ package store import ( "database/sql" + "encoding/json" "errors" ) @@ -19,12 +20,30 @@ type Share struct { // The link preview the sharer chose to publish in the clear (may be empty). CardTitle string CardDesc string + // The addresses that may open it; empty = anyone with the link. + Recipients []string +} + +func recipientsColumn(r []string) string { + if len(r) == 0 { + return "" + } + b, _ := json.Marshal(r) + return string(b) +} + +func parseRecipients(v string) []string { + var r []string + if v != "" { + _ = json.Unmarshal([]byte(v), &r) + } + return r } func (s *Store) PutShare(sh *Share) error { - _, err := s.db.Exec(`INSERT INTO shares (id, owner, fp, size, blob, created, expires, card_title, card_desc) - VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)`, - sh.ID, sh.Owner, sh.Fp, sh.Size, sh.Blob, sh.Created, sh.Expires, sh.CardTitle, sh.CardDesc) + _, err := s.db.Exec(`INSERT INTO shares (id, owner, fp, size, blob, created, expires, card_title, card_desc, recipients) + VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)`, + sh.ID, sh.Owner, sh.Fp, sh.Size, sh.Blob, sh.Created, sh.Expires, sh.CardTitle, sh.CardDesc, recipientsColumn(sh.Recipients)) return err } @@ -32,10 +51,12 @@ func (s *Store) PutShare(sh *Share) error { // reads as not found. func (s *Store) GetShare(id string) (*Share, error) { var sh Share - err := s.db.QueryRow(`SELECT id, owner, fp, size, blob, created, expires, removed, removed_why, card_title, card_desc + var recipients string + err := s.db.QueryRow(`SELECT id, owner, fp, size, blob, created, expires, removed, removed_why, card_title, card_desc, recipients FROM shares WHERE id = ?`, id). Scan(&sh.ID, &sh.Owner, &sh.Fp, &sh.Size, &sh.Blob, &sh.Created, &sh.Expires, &sh.Removed, &sh.RemovedWhy, - &sh.CardTitle, &sh.CardDesc) + &sh.CardTitle, &sh.CardDesc, &recipients) + sh.Recipients = parseRecipients(recipients) if errors.Is(err, sql.ErrNoRows) || err == nil && sh.Expires > 0 && sh.Expires <= now() { return nil, ErrNotFound } @@ -48,18 +69,27 @@ func (s *Store) GetShare(id string) (*Share, error) { // RemoveShare drops the blob and keeps a tombstone. It reports whether a // live share was removed. func (s *Store) RemoveShare(id, why string) (bool, error) { - res, err := s.db.Exec(`UPDATE shares SET blob = NULL, card_title = '', card_desc = '', removed = ?, removed_why = ? + res, err := s.db.Exec(`UPDATE shares SET blob = NULL, card_title = '', card_desc = '', recipients = '', removed = ?, removed_why = ? WHERE id = ? AND removed = 0`, now(), why, id) if err != nil { return false, err } n, err := res.RowsAffected() - return n == 1, err + if err != nil { + return false, err + } + // Who it was shared with goes with the content. + for _, q := range []string{`DELETE FROM share_codes WHERE share = ?`, `DELETE FROM share_views WHERE share = ?`, `DELETE FROM share_opens WHERE share = ?`} { + if _, err := s.db.Exec(q, id); err != nil { + return false, err + } + } + return n == 1, nil } // OwnerShares lists an address's live shares, newest first, without blobs. func (s *Store) OwnerShares(owner string) ([]Share, error) { - rows, err := s.db.Query(`SELECT id, size, created, expires FROM shares + rows, err := s.db.Query(`SELECT id, size, created, expires, recipients FROM shares WHERE owner = ? AND removed = 0 AND (expires = 0 OR expires > ?) ORDER BY created DESC`, owner, now()) if err != nil { return nil, err @@ -68,9 +98,11 @@ func (s *Store) OwnerShares(owner string) ([]Share, error) { var out []Share for rows.Next() { sh := Share{Owner: owner} - if err := rows.Scan(&sh.ID, &sh.Size, &sh.Created, &sh.Expires); err != nil { + var recipients string + if err := rows.Scan(&sh.ID, &sh.Size, &sh.Created, &sh.Expires, &recipients); err != nil { return nil, err } + sh.Recipients = parseRecipients(recipients) out = append(out, sh) } return out, rows.Err() @@ -83,6 +115,95 @@ func (s *Store) OwnerShareUsage(owner string) (count int, bytes int64, err error return count, bytes, err } +// ---- recipient-locked shares ---- + +// ShareCodeTries is how many wrong codes end a mailed code. +const ShareCodeTries = 5 + +// PutShareCode stores (or replaces) the code mailed to one recipient. +func (s *Store) PutShareCode(share, address, hash string, expires int64) error { + _, err := s.db.Exec(`INSERT INTO share_codes (share, address, code_hash, expires, tries) VALUES (?, ?, ?, ?, 0) + ON CONFLICT (share, address) DO UPDATE SET code_hash = excluded.code_hash, expires = excluded.expires, tries = 0`, + share, address, hash, expires) + return err +} + +// UseShareCode reports whether hash is the live code for that recipient. A +// match uses the code up; every try counts against ShareCodeTries. The try +// is taken in one atomic UPDATE before the compare, so parallel guesses +// cannot pass the limit. +func (s *Store) UseShareCode(share, address, hash string) (bool, error) { + var want string + err := s.db.QueryRow(`UPDATE share_codes SET tries = tries + 1 + WHERE share = ? AND address = ? AND tries < ? AND expires > ? RETURNING code_hash`, + share, address, ShareCodeTries, now()).Scan(&want) + if errors.Is(err, sql.ErrNoRows) { + return false, nil + } else if err != nil { + return false, err + } + if want != hash { + return false, nil + } + res, err := s.db.Exec(`DELETE FROM share_codes WHERE share = ? AND address = ? AND code_hash = ?`, share, address, hash) + if err != nil { + return false, err + } + n, err := res.RowsAffected() + return n == 1, err +} + +// PutShareView remembers a browser that proved an address (by token hash). +func (s *Store) PutShareView(tokenHash, share, address string, expires int64) error { + _, err := s.db.Exec(`INSERT INTO share_views (token, share, address, expires) VALUES (?, ?, ?, ?)`, tokenHash, share, address, expires) + return err +} + +// ShareView returns the address a live view token proved for that share. +func (s *Store) ShareView(tokenHash, share string) (string, error) { + var addr string + err := s.db.QueryRow(`SELECT address FROM share_views WHERE token = ? AND share = ? AND expires > ?`, tokenHash, share, now()).Scan(&addr) + if errors.Is(err, sql.ErrNoRows) { + return "", ErrNotFound + } + return addr, err +} + +// ShareOpen is one recipient's opening record. +type ShareOpen struct { + Address string `json:"address"` + First int64 `json:"first"` + Last int64 `json:"last"` + Count int `json:"count"` +} + +// RecordShareOpen counts one opening of share by address at t. +func (s *Store) RecordShareOpen(share, address string, t int64) error { + _, err := s.db.Exec(`INSERT INTO share_opens (share, address, first, last, count) VALUES (?, ?, ?, ?, 1) + ON CONFLICT (share, address) DO UPDATE SET last = excluded.last, count = count + 1`, share, address, t, t) + return err +} + +// OwnerShareOpens returns the opening records of an address's shares, by share id. +func (s *Store) OwnerShareOpens(owner string) (map[string][]ShareOpen, error) { + rows, err := s.db.Query(`SELECT o.share, o.address, o.first, o.last, o.count FROM share_opens o + JOIN shares sh ON sh.id = o.share WHERE sh.owner = ? AND sh.removed = 0 ORDER BY o.first`, owner) + if err != nil { + return nil, err + } + defer rows.Close() + out := map[string][]ShareOpen{} + for rows.Next() { + var id string + var o ShareOpen + if err := rows.Scan(&id, &o.Address, &o.First, &o.Last, &o.Count); err != nil { + return nil, err + } + out[id] = append(out[id], o) + } + return out, rows.Err() +} + type ShareReport struct { ID int64 Share string diff --git a/relay/internal/store/store.go b/relay/internal/store/store.go index 3261c03f..e210d98e 100644 --- a/relay/internal/store/store.go +++ b/relay/internal/store/store.go @@ -50,6 +50,14 @@ var migrations = []string{ handled INTEGER NOT NULL DEFAULT 0);`, `ALTER TABLE shares ADD COLUMN card_title TEXT NOT NULL DEFAULT ''; ALTER TABLE shares ADD COLUMN card_desc TEXT NOT NULL DEFAULT '';`, + // Recipient-locked share links: who may open, the codes mailed to them, + // the browsers that proved an address, and who opened when. + `ALTER TABLE shares ADD COLUMN recipients TEXT NOT NULL DEFAULT ''; + CREATE TABLE share_codes (share TEXT NOT NULL, address TEXT NOT NULL, code_hash TEXT NOT NULL, + expires INTEGER NOT NULL, tries INTEGER NOT NULL DEFAULT 0, PRIMARY KEY (share, address)); + CREATE TABLE share_views (token TEXT PRIMARY KEY, share TEXT NOT NULL, address TEXT NOT NULL, expires INTEGER NOT NULL); + CREATE TABLE share_opens (share TEXT NOT NULL, address TEXT NOT NULL, first INTEGER NOT NULL, last INTEGER NOT NULL, + count INTEGER NOT NULL, PRIMARY KEY (share, address));`, } func Open(path string) (*Store, error) { @@ -224,6 +232,9 @@ func (s *Store) Sweep(holdDays int) error { // tombstone (so the link says "removed") for a year. {`DELETE FROM shares WHERE expires > 0 AND expires <= ?`, []any{t}}, {`DELETE FROM shares WHERE removed > 0 AND removed <= ?`, []any{t - 365*86400000}}, + {`DELETE FROM share_codes WHERE expires <= ?`, []any{t}}, + {`DELETE FROM share_views WHERE expires <= ? OR share NOT IN (SELECT id FROM shares WHERE removed = 0)`, []any{t}}, + {`DELETE FROM share_opens WHERE share NOT IN (SELECT id FROM shares)`, nil}, } for _, st := range stmts { if _, err := s.db.Exec(st.q, st.args...); err != nil { diff --git a/scripts/browser-extension-live.mjs b/scripts/browser-extension-live.mjs index 9c0e1164..6997d141 100644 --- a/scripts/browser-extension-live.mjs +++ b/scripts/browser-extension-live.mjs @@ -55,7 +55,8 @@ async function main() { const recordFixture = process.argv.includes('--record-fixture'); const keep = process.argv.includes('--keep'); const { chromium } = await import('playwright'); - const executable = chromium.executablePath(); + // STEM_CHROME points at another Chrome for Testing when Playwright's own build is not installed. + const executable = process.env.STEM_CHROME || chromium.executablePath(); const manifest = JSON.parse(await readFile(join(extensionDir, 'manifest.json'), 'utf8')); const extensionId = extensionIdFromKey(manifest.key); diff --git a/scripts/code-mode-upside.mjs b/scripts/code-mode-upside.mjs new file mode 100644 index 00000000..00f63c07 --- /dev/null +++ b/scripts/code-mode-upside.mjs @@ -0,0 +1,288 @@ +// How much would "code mode" (the model writes one script that calls MCP tools, +// instead of one tool call per model round trip) save on real Stem sessions? +// +// Reads pi's session JSONL and counts the two things a script could improve: +// 1. chains: runs of MCP calls in one turn with no other tool between them. +// A run spread over N assistant messages costs N model round trips; a +// script would cost one, so the saving is N-1 per run. +// 2. big results: MCP results large enough that filtering them in a script +// before they reach the context would matter (and the ones the 100k cap +// already cut). +// +// It prints counts, sizes and tool names only, never message or result text, +// so the output is safe to paste. No dependencies: it can be piped into the +// server container as is. +// +// node scripts/code-mode-upside.mjs [sessionsDir] [--days=N] +// STEM_SESSIONS_DIR=/path/to/sessions node scripts/code-mode-upside.mjs +// ssh host 'cd ~/services/stem && docker compose exec -T stem \ +// node --input-type=module - /var/lib/stem/state/pi-home/sessions' < scripts/code-mode-upside.mjs +// +// What it cannot see: whether the model needed to read result k before it could +// write call k+1. A chain is therefore an upper bound on what one script could +// have covered. The read-only split is a guess from the tool's name. +import { existsSync, readdirSync, readFileSync, statSync } from 'node:fs'; +import { homedir } from 'node:os'; +import { join } from 'node:path'; + +const CHAIN_MIN = 3; // calls in a row before a script beats plain tool calls +const BIG_RESULT_CHARS = 20_000; // ~5k tokens: worth filtering before it lands +const TRUNCATION_MARK = '[Result truncated: the tool returned'; // capToolContent's notice +const DISCOVERY = new Set(['find_tools', 'describe_tool']); +const READ_VERB = /^(get|list|search|read|find|query|fetch|describe|show|view|lookup|check|count|export|download|whoami|status)/i; + +const args = process.argv.slice(2); +const daysArg = args.find((a) => a.startsWith('--days=')); +const days = daysArg ? Number(daysArg.slice('--days='.length)) : 0; +const dirArg = args.find((a) => !a.startsWith('--')); + +function resolveSessionsDir() { + const candidates = dirArg + ? [dirArg] + : process.env.STEM_SESSIONS_DIR + ? [process.env.STEM_SESSIONS_DIR] + : [ + '/var/lib/stem/state/pi-home/sessions', + join(homedir(), 'Library', 'Application Support', 'Stem', 'pi-home', 'sessions'), + join(homedir(), '.config', 'Stem', 'pi-home', 'sessions') + ]; + const found = candidates.find((d) => existsSync(d)); + if (!found) { + console.error(`No sessions directory found. Looked in:\n${candidates.map((c) => ` ${c}`).join('\n')}`); + process.exit(2); + } + return found; +} + +function sessionFiles(dir, since) { + const out = []; + for (const entry of readdirSync(dir, { withFileTypes: true })) { + const path = join(dir, entry.name); + if (entry.isDirectory()) out.push(...sessionFiles(path, since)); + else if (entry.name.endsWith('.jsonl') && (!since || statSync(path).mtimeMs >= since)) out.push(path); + } + return out; +} + +function readSession(path) { + const out = []; + for (const line of readFileSync(path, 'utf8').split('\n')) { + if (!line.trim()) continue; + try { + const obj = JSON.parse(line); + if (obj?.type === 'message' && obj.message) out.push(obj.message); + } catch { + // a partially flushed tail line + } + } + return out; +} + +function textChars(content) { + if (!Array.isArray(content)) return { chars: 0, truncated: false }; + let chars = 0; + let truncated = false; + for (const b of content) { + if (b?.type !== 'text' || typeof b.text !== 'string') continue; + chars += b.text.length; + if (b.text.includes(TRUNCATION_MARK)) truncated = true; + } + return { chars, truncated }; +} + +/** + * One turn = a user message up to the next. Each tool call becomes + * { step, mcp, server, tool, chars, truncated }, where `step` is the index of + * the assistant message that made it (calls sharing a step were one round trip). + * A call is MCP when it went through invoke_tool, or when its result carries + * the { server, tool } details callRoutedTool stamps (directly loaded tools). + */ +function turnsOf(messages) { + const turns = []; + let calls = null; + let step = 0; + const byId = new Map(); + for (const m of messages) { + if (m.role === 'user') { + if (calls) turns.push(calls); + calls = []; + step = 0; + byId.clear(); + continue; + } + if (!calls) continue; + if (m.role === 'assistant') { + let made = false; + for (const b of Array.isArray(m.content) ? m.content : []) { + if (b?.type !== 'toolCall') continue; + made = true; + const routed = b.name === 'invoke_tool'; + const call = { + step, + name: b.name, + mcp: routed, + server: routed ? String(b.arguments?.server ?? '?') : '', + tool: routed ? String(b.arguments?.tool ?? '?') : '', + chars: 0, + truncated: false + }; + calls.push(call); + if (typeof b.id === 'string') byId.set(b.id, call); + } + if (made) step++; + continue; + } + if (m.role === 'toolResult') { + const call = byId.get(m.toolCallId); + if (!call) continue; + const d = m.details; + if (!call.mcp && d && typeof d.server === 'string' && typeof d.tool === 'string') { + call.mcp = true; + call.server = d.server; + call.tool = d.tool; + } + const size = textChars(m.content); + call.chars = size.chars; + call.truncated = size.truncated; + } + } + if (calls) turns.push(calls); + return turns; +} + +/** Runs of MCP calls. Discovery lookups sit inside a run without counting; any other tool ends it. */ +function chainsOf(calls) { + const chains = []; + let run = []; + const flush = () => { + if (run.length) chains.push(run); + run = []; + }; + for (const c of calls) { + if (c.mcp) run.push(c); + else if (!DISCOVERY.has(c.name)) flush(); + } + flush(); + return chains; +} + +function pct(n, d) { + return d ? `${((100 * n) / d).toFixed(1)}%` : 'n/a'; +} + +function quantile(sorted, q) { + return sorted.length ? sorted[Math.min(sorted.length - 1, Math.floor(q * sorted.length))] : 0; +} + +function top(map, n) { + return [...map.entries()].sort((a, b) => b[1] - a[1]).slice(0, n); +} + +const dir = resolveSessionsDir(); +const files = sessionFiles(dir, days > 0 ? Date.now() - days * 86_400_000 : 0); + +let turns = 0; +let turnsWithMcp = 0; +let turnsWithChain = 0; +let mcpCalls = 0; +let allCalls = 0; +let discoveryCalls = 0; +let chainCalls = 0; +let chainReadOnly = 0; +let chainsAllRead = 0; +let chainCount = 0; +let roundTripsSaved = 0; +let sameToolLoops = 0; +let mcpRoundTrips = 0; +let truncated = 0; +let big = 0; +let bigChars = 0; +const sizes = []; +const lengthBuckets = new Map(); // chain length -> count +const chainTools = new Map(); +const bigTools = new Map(); +let mcpChars = 0; + +for (const file of files) { + for (const calls of turnsOf(readSession(file))) { + turns++; + allCalls += calls.length; + discoveryCalls += calls.filter((c) => DISCOVERY.has(c.name)).length; + const mcp = calls.filter((c) => c.mcp); + if (!mcp.length) continue; + turnsWithMcp++; + mcpCalls += mcp.length; + mcpRoundTrips += new Set(mcp.map((c) => c.step)).size; + for (const c of mcp) { + sizes.push(c.chars); + mcpChars += c.chars; + if (c.truncated) truncated++; + if (c.chars >= BIG_RESULT_CHARS) { + big++; + bigChars += c.chars; + const key = `${c.server}.${c.tool}`; + bigTools.set(key, (bigTools.get(key) ?? 0) + 1); + } + } + let hadChain = false; + for (const chain of chainsOf(calls)) { + const bucket = chain.length >= 10 ? '10+' : String(chain.length); + lengthBuckets.set(bucket, (lengthBuckets.get(bucket) ?? 0) + 1); + if (chain.length < CHAIN_MIN) continue; + hadChain = true; + chainCount++; + chainCalls += chain.length; + roundTripsSaved += new Set(chain.map((c) => c.step)).size - 1; + const reads = chain.filter((c) => READ_VERB.test(c.tool.replace(/^[a-z0-9]+[_-]/i, '')) || READ_VERB.test(c.tool)).length; + chainReadOnly += reads; + if (reads === chain.length) chainsAllRead++; + const perTool = new Map(); + for (const c of chain) { + const key = `${c.server}.${c.tool}`; + chainTools.set(key, (chainTools.get(key) ?? 0) + 1); + perTool.set(key, (perTool.get(key) ?? 0) + 1); + } + if ([...perTool.values()].some((n) => n >= CHAIN_MIN)) sameToolLoops++; + } + if (hadChain) turnsWithChain++; + } +} + +sizes.sort((a, b) => a - b); +const line = (label, value) => console.log(`${label.padEnd(44)}${value}`); + +console.log(`Code mode upside — ${dir}${days > 0 ? ` (last ${days} days)` : ''}\n`); +line('sessions', files.length); +line('turns', turns); +line('tool calls (all kinds)', allCalls); +line('MCP calls', `${mcpCalls} (${pct(mcpCalls, allCalls)} of tool calls)`); +line('find_tools / describe_tool calls', discoveryCalls); +line('turns with any MCP call', `${turnsWithMcp} (${pct(turnsWithMcp, turns)} of turns)`); + +console.log(`\nChains (runs of >= ${CHAIN_MIN} MCP calls, no other tool between)`); +line('turns with a chain', `${turnsWithChain} (${pct(turnsWithChain, turns)} of turns, ${pct(turnsWithChain, turnsWithMcp)} of MCP turns)`); +line('chains', chainCount); +line('MCP calls inside chains', `${chainCalls} (${pct(chainCalls, mcpCalls)} of MCP calls)`); +line('model round trips a script would save', `${roundTripsSaved} of ${mcpRoundTrips} MCP round trips (${pct(roundTripsSaved, mcpRoundTrips)})`); +line('chains repeating one tool >= 3 times', `${sameToolLoops} (${pct(sameToolLoops, chainCount)} of chains)`); +line('chain calls that look read-only (by name)', `${chainReadOnly} (${pct(chainReadOnly, chainCalls)})`); +line('chains that look read-only throughout', `${chainsAllRead} (${pct(chainsAllRead, chainCount)} of chains)`); +console.log(' run length -> runs'); +for (const key of ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10+']) { + if (lengthBuckets.has(key)) console.log(` ${key.padStart(3)} ${lengthBuckets.get(key)}`); +} + +console.log('\nResult sizes (text chars per MCP result)'); +line('median / p90 / p99 / max', `${quantile(sizes, 0.5)} / ${quantile(sizes, 0.9)} / ${quantile(sizes, 0.99)} / ${sizes.at(-1) ?? 0}`); +line(`results >= ${BIG_RESULT_CHARS} chars`, `${big} (${pct(big, mcpCalls)} of MCP calls)`); +line(' their share of all MCP result text', pct(bigChars, mcpChars)); +line('results cut by the 100k cap', truncated); + +if (chainTools.size) { + console.log('\nTools most often inside chains'); + for (const [key, n] of top(chainTools, 12)) console.log(` ${String(n).padStart(5)} ${key}`); +} +if (bigTools.size) { + console.log(`\nTools most often returning >= ${BIG_RESULT_CHARS} chars`); + for (const [key, n] of top(bigTools, 12)) console.log(` ${String(n).padStart(5)} ${key}`); +} diff --git a/scripts/deploy.sh b/scripts/deploy.sh new file mode 100755 index 00000000..6c097ce0 --- /dev/null +++ b/scripts/deploy.sh @@ -0,0 +1,378 @@ +#!/usr/bin/env bash +# Deploy Stem to every place that needs the change: +# vps stem-server container on the VPS +# relay global relay container +# viewer public share viewer (static files next to the relay) +# mac Mac dmg: build, quit Stem.app, install, start it again +# ios iOS app to TestFlight +# +# The script merges the source branch into the deploy worktree, runs the type +# check and the unit tests, and then ships only the targets whose part of the +# tree changed since that target's last deploy. +# +# Hosts, paths and keys come from a local file that is not in git: +# ${STEM_DEPLOY_ENV:-$HOME/.config/stem/deploy.env} +# See the CONFIG block below for the names. +# +# Usage: +# scripts/deploy.sh # merge 0.8.0, test, ship what changed +# scripts/deploy.sh --dry-run # show the plan, change nothing +# scripts/deploy.sh --only mac,vps # ship these targets, changed or not +# scripts/deploy.sh --skip ios # never ship these targets +# scripts/deploy.sh --source a --source b # merge more than one branch +# scripts/deploy.sh --no-tests +# +# The script never asks a question. It ships the plan without a stop, and for +# the Mac it quits Stem.app (force quits it if necessary), installs the new +# build and starts it again. +set -euo pipefail +case " $* " in *" -h "*|*" --help "*) sed -n '2,28p' "$0"; exit 0 ;; esac + +# ---------------------------------------------------------------- CONFIG +ENV_FILE="${STEM_DEPLOY_ENV:-$HOME/.config/stem/deploy.env}" +if [[ -f "$ENV_FILE" ]]; then + # shellcheck disable=SC1090 + source "$ENV_FILE" +fi +: "${DEPLOY_WORKTREE:?set DEPLOY_WORKTREE in $ENV_FILE (the worktree that builds the deploy commit)}" +: "${VPS_HOST:?set VPS_HOST in $ENV_FILE (for example user@host)}" +: "${VPS_DIR:=services/stem}" # relative to the VPS user's home +: "${RELAY_HOST:?set RELAY_HOST in $ENV_FILE}" +: "${RELAY_DIR:=/root/services/stem-relay}" +: "${RELAY_HEALTH_URL:=}" # optional, checked after a relay deploy +: "${DEFAULT_SOURCE:=0.8.0}" +: "${MAC_APP:=/Applications/Stem.app}" +# ASC_KEY_ID, ASC_ISSUER_ID, ASC_KEY_PATH: optional, passed to ios/scripts/testflight.sh +STATE_DIR="${XDG_STATE_HOME:-$HOME/.local/state}/stem-deploy" +LOG_DIR="${DEPLOY_LOG_DIR:-$STATE_DIR/logs/$(date +%Y%m%d-%H%M%S)}" + +ALL_TARGETS=(vps relay viewer mac ios) + +# Which paths make each target ship. Keep in step with the stem-deploy skill. +paths_for() { + case "$1" in + vps) echo "src/server src/shared scripts/sys-version.mjs Dockerfile package.json package-lock.json docker-compose.yml deploy docs/assistant" ;; + relay) echo "relay" ;; + viewer) echo "src/share src/shared/share.ts vite.share.config.ts" ;; + # The Mac app runs a local server too, so src/server counts. + mac) echo "src/desktop src/renderer src/preload src/shared src/server src/browser-extension electron.vite.config.ts electron-builder.yml package.json package-lock.json native build docs/assistant" ;; + ios) echo "ios" ;; + esac +} + +# ---------------------------------------------------------------- ARGS +SOURCES=() +ONLY="" +SKIP="" +DRY=0 +TESTS=1 +while [[ $# -gt 0 ]]; do + case "$1" in + --source) SOURCES+=("$2"); shift 2 ;; + --only) ONLY="$2"; shift 2 ;; + --skip) SKIP="$2"; shift 2 ;; + --dry-run|-n) DRY=1; shift ;; + --no-tests) TESTS=0; shift ;; + --yes|-y) shift ;; # no effect: the script never asks + -h|--help) sed -n '2,28p' "$0"; exit 0 ;; + *) echo "unknown option: $1" >&2; exit 2 ;; + esac +done +[[ ${#SOURCES[@]} -eq 0 ]] && SOURCES=("$DEFAULT_SOURCE") +LAST_SOURCE=${SOURCES[${#SOURCES[@]}-1]} + +in_list() { [[ ",$2," == *",$1,"* ]]; } +for t in ${ONLY//,/ } ${SKIP//,/ }; do + in_list "$t" "$(IFS=,; echo "${ALL_TARGETS[*]}")" || { echo "unknown target: $t" >&2; exit 2; } +done + +# ---------------------------------------------------------------- HELPERS +D="$DEPLOY_WORKTREE" +g() { git -C "$D" "$@"; } +say() { printf '\n\033[1m== %s\033[0m\n' "$*"; } +note() { printf ' %s\n' "$*"; } +die() { printf '\n\033[31mSTOP: %s\033[0m\n' "$*" >&2; exit 1; } +SSH_OPTS=(-o BatchMode=yes -o ConnectTimeout=15 -o ServerAliveInterval=15 -o ServerAliveCountMax=4 -o VisualHostKey=no -o LogLevel=ERROR) +vps() { ssh "${SSH_OPTS[@]}" "$VPS_HOST" "$@"; } +relay() { ssh "${SSH_OPTS[@]}" "$RELAY_HOST" "$@"; } +state_get() { [[ -f "$STATE_DIR/$1" ]] && cat "$STATE_DIR/$1" || true; } +state_set() { mkdir -p "$STATE_DIR"; echo "$2" > "$STATE_DIR/$1"; } +short() { echo "${1:0:8}"; } + +res() { printf -v "RESULT_$1" '%s' "$2"; } +resget() { local n="RESULT_$1"; echo "${!n:-?}"; } +base_set() { printf -v "BASE_$1" '%s' "$2"; } +base_get() { local n="BASE_$1"; echo "${!n}"; } +mkdir -p "$LOG_DIR" + +# ---------------------------------------------------------------- 1. NOW +say "What runs now" +[[ -d "$D/.git" || -f "$D/.git" ]] || die "no deploy worktree at $D" +V=$(vps "cd $VPS_DIR && git rev-parse HEAD") || die "cannot read the VPS checkout" +VPS_DIRTY=$(vps "cd $VPS_DIR && git status --porcelain --untracked-files=no") +[[ -z "$VPS_DIRTY" ]] || die "the VPS checkout has modified files (an earlier deploy stopped half way): +$VPS_DIRTY" +g cat-file -e "$V^{commit}" 2>/dev/null || die "VPS commit $(short "$V") is not in the local repo" +[[ -z "$(g status --porcelain --untracked-files=no)" ]] || die "the deploy worktree $D has local changes" +PREV=$(g rev-parse HEAD) +note "VPS: $(short "$V")" +note "deploy worktree: $(short "$PREV")" +for s in "${SOURCES[@]}"; do + g rev-parse -q --verify "$s^{commit}" >/dev/null || die "no branch or commit '$s'" + note "source $s: $(short "$(g rev-parse "$s")")" +done + +# Each target ships the diff since its own last deploy. The VPS knows its +# commit; for the others the script keeps a state file. With no state file, +# the VPS commit counts as deployed. The script writes that base to the state +# file before it ships, so a target that fails stays in the plan of the next +# run (a fallback to the worktree HEAD moved with each run and lost failures). +base_set vps "$V" +for t in relay viewer mac ios; do + b=$(state_get "$t") + if [[ -n "$b" ]] && g cat-file -e "$b^{commit}" 2>/dev/null; then base_set "$t" "$b"; else base_set "$t" "$V"; fi +done + +# ---------------------------------------------------------------- 2. MERGE +# In a dry run, plan against the source tips and do not touch the worktree. +if [[ $DRY -eq 1 ]]; then + HEAD_SHA=$(g rev-parse "$LAST_SOURCE") + say "Dry run: plan against $LAST_SOURCE ($(short "$HEAD_SHA")), no merge" +else + say "Merge into the deploy worktree" + if ! g merge-base --is-ancestor "$V" "$PREV"; then + note "deploy worktree does not contain the VPS commit; start from $(short "$V")" + g checkout -q --detach "$V" + fi + for s in "${SOURCES[@]}"; do + if g merge-base --is-ancestor "$s" HEAD; then note "$s: already in"; continue; fi + if g merge --no-edit -q "$s" >"$LOG_DIR/merge.log" 2>&1; then + note "$s: merged"; continue + fi + # Earlier deploys carry squashed copies of the same work, so most conflicts + # are duplicates. Take the source side only for files where our side has + # no line that the source does not also have. + bad=(_) + while IFS= read -r f; do + [[ -z "$f" ]] && continue + if ours=$(g show "HEAD:$f" 2>/dev/null) && theirs=$(g show "$s:$f" 2>/dev/null) && + [[ -z "$(comm -23 <(sort -u <<<"$ours") <(sort -u <<<"$theirs"))" ]]; then + g checkout -q --theirs -- "$f" && g add -- "$f" + note "conflict in $f: our side is a copy, took $s" + else + bad+=("$f") + fi + done < <(g diff --name-only --diff-filter=U) + bad=("${bad[@]:1}") + if [[ ${#bad[@]} -gt 0 ]]; then + g merge --abort + die "merge of $s has real conflicts; resolve them by hand in $D: +$(printf ' %s\n' "${bad[@]}")" + fi + g commit -q --no-edit + note "$s: merged after duplicate conflicts" + done + HEAD_SHA=$(g rev-parse HEAD) + if [[ ${#SOURCES[@]} -eq 1 ]] && ! g diff --quiet "${SOURCES[0]}" HEAD; then + note "WARNING: the deploy commit differs from ${SOURCES[0]}:" + g diff --stat "${SOURCES[0]}" HEAD | sed 's/^/ /' + fi + note "deploy commit: $(short "$HEAD_SHA")" +fi + +# ---------------------------------------------------------------- 3. PLAN +say "Plan" +PLAN=(_) # placeholder: bash 3.2 with set -u fails on an empty array +for t in "${ALL_TARGETS[@]}"; do + base=$(base_get "$t") + # shellcheck disable=SC2046 + changed=$(g diff --name-only "$base" "$HEAD_SHA" -- $(paths_for "$t") | wc -l | tr -d ' ') + if [[ -n "$SKIP" ]] && in_list "$t" "$SKIP"; then + note "$t: skip (--skip)"; res "$t" "skipped (--skip)" + elif [[ -n "$ONLY" ]]; then + if in_list "$t" "$ONLY"; then PLAN+=("$t"); note "$t: SHIP (--only, $changed files changed since $(short "$base"))" + else note "$t: skip (not in --only)"; res "$t" "skipped (not in --only)"; fi + elif [[ $changed -gt 0 ]]; then + PLAN+=("$t"); note "$t: SHIP ($changed files changed since $(short "$base"))" + else + note "$t: skip (no change since $(short "$base"))"; res "$t" "skipped (unchanged)" + fi +done +PLAN=("${PLAN[@]:1}") +has() { [[ ${#PLAN[@]} -gt 0 && " ${PLAN[*]} " == *" $1 "* ]]; } + +if [[ $DRY -eq 1 ]]; then echo; echo "Dry run: nothing changed."; exit 0; fi +for t in relay viewer mac ios; do + [[ -n "$(state_get "$t")" ]] || state_set "$t" "$(base_get "$t")" +done +if [[ ${#PLAN[@]} -eq 0 ]]; then + echo; echo "Nothing to ship. Deploy commit $(short "$HEAD_SHA") stays in $D."; exit 0 +fi + +# ---------------------------------------------------------------- 4. CHECK +if [[ -n "$(g diff --name-only "$PREV" HEAD -- package-lock.json)" ]]; then + say "package-lock.json changed: npm ci in the deploy worktree" + [[ -L "$D/node_modules" ]] && die "$D/node_modules is a symlink; install there by hand" + (cd "$D" && npm ci --no-audit --no-fund) >"$LOG_DIR/npm-ci.log" 2>&1 || die "npm ci failed, see $LOG_DIR/npm-ci.log" +fi + +if [[ $TESTS -eq 1 ]]; then + say "Type check and unit tests" + (cd "$D" && npm run -s typecheck) >"$LOG_DIR/typecheck.log" 2>&1 || die "typecheck failed, see $LOG_DIR/typecheck.log" + note "typecheck: clean" + # A busy machine sometimes gives one or two timing failures; run once more. + if ! (cd "$D" && npx vitest run tests/unit) >"$LOG_DIR/unit.log" 2>&1; then + note "unit tests failed once; run them again" + (cd "$D" && npx vitest run tests/unit) >"$LOG_DIR/unit.log" 2>&1 || die "unit tests failed two times, see $LOG_DIR/unit.log" + fi + note "unit tests: $(grep -Eo 'Tests +[0-9]+ passed' "$LOG_DIR/unit.log" | tail -1)" +fi + +say "Ship ${PLAN[*]} from $(short "$HEAD_SHA")" + +# ---------------------------------------------------------------- 5. LONG BUILDS +# The dmg and the TestFlight upload take minutes; start them now. +MAC_PID=""; IOS_PID="" +if has mac; then + say "Start the Mac dmg build (log: $LOG_DIR/dmg.log)" + (cd "$D" && npm run dist:mac) >"$LOG_DIR/dmg.log" 2>&1 & MAC_PID=$! +fi +if has ios; then + say "Start the TestFlight upload (log: $LOG_DIR/testflight.log)" + (cd "$D/ios" && ASC_KEY_ID="${ASC_KEY_ID:-}" ASC_ISSUER_ID="${ASC_ISSUER_ID:-}" ASC_KEY_PATH="${ASC_KEY_PATH:-}" \ + scripts/testflight.sh) >"$LOG_DIR/testflight.log" 2>&1 & IOS_PID=$! +fi + +# ---------------------------------------------------------------- 6. VPS +deploy_vps() { + say "VPS stem-server" + local bundle="$LOG_DIR/deploy.bundle" + # A bundle needs a ref: "V.." gives "Refusing to create empty bundle". + # HEAD of the deploy worktree is the deploy commit. + [[ "$(g rev-parse HEAD)" == "$HEAD_SHA" ]] || { res vps "FAILED: deploy worktree HEAD is not $(short "$HEAD_SHA")"; return 1; } + g bundle create "$bundle" "$V..HEAD" >"$LOG_DIR/vps-bundle.log" 2>&1 || + { res vps "FAILED: git bundle, see $LOG_DIR/vps-bundle.log"; return 1; } + scp -q "${SSH_OPTS[@]}" "$bundle" "$VPS_HOST:/tmp/stem-deploy.bundle" || { res vps "FAILED: scp of the bundle"; return 1; } + local got + got=$(vps "cd $VPS_DIR && git fetch -q /tmp/stem-deploy.bundle HEAD && git merge --ff-only -q FETCH_HEAD && rm -f /tmp/stem-deploy.bundle && git rev-parse HEAD") || got="" + [[ "$got" == "$HEAD_SHA" ]] || { res vps "FAILED: VPS HEAD is $(short "$got")"; return 1; } + note "checkout fast-forwarded to $(short "$got")" + local sha12=${HEAD_SHA:0:12} + vps "cd $VPS_DIR && STEM_GIT_SHA=$sha12 docker compose build stem" >"$LOG_DIR/vps-build.log" 2>&1 || + { res vps "FAILED: docker build, see $LOG_DIR/vps-build.log"; return 1; } + vps "cd $VPS_DIR && docker compose up -d stem" >>"$LOG_DIR/vps-build.log" 2>&1 || + { res vps "FAILED: docker compose up, see $LOG_DIR/vps-build.log"; return 1; } + local boot="" + for _ in $(seq 1 18); do + sleep 5 + boot=$(vps "cd $VPS_DIR && docker compose logs --since 3m stem 2>&1 | grep -E 'system persona.*build' | tail -1" || true) + [[ "$boot" == *"$sha12"* ]] && break + done + local ps + ps=$(vps "cd $VPS_DIR && docker compose ps stem --format '{{.Status}}'" || true) + note "boot: ${boot:-}" + note "container: $ps" + if [[ "$boot" == *"$sha12"* && "$ps" == Up* && "$ps" != *Restarting* ]]; then + res vps "shipped, build $sha12" + else + res vps "FAILED: no boot line for $sha12 or the container is not Up (check docker logs caddy for heap OOM)" + return 1 + fi +} + +# ---------------------------------------------------------------- 7. RELAY + VIEWER +deploy_relay() { + say "Global relay" + # The compose file has "build: ./src" (short form) or "context: ./src". + relay "grep -Eq '(build|context): *(\./)?src/?\$' $RELAY_DIR/docker-compose.yml" || + { res relay "FAILED: relay compose build context is not ./src; update this script"; return 1; } + g archive "$HEAD_SHA" relay | relay "cd $RELAY_DIR && rm -rf src.old && mv src src.old && mkdir src && tar -x --strip-components=1 -C src" || + { res relay "FAILED: copy of relay/ (old code is in $RELAY_DIR/src.old)"; return 1; } + relay "cd $RELAY_DIR && docker compose build && docker compose up -d" >"$LOG_DIR/relay.log" 2>&1 || + { res relay "FAILED: relay build, see $LOG_DIR/relay.log"; return 1; } + sleep 5 + relay "docker logs --since 1m stem-relay 2>&1 | tail -5" | sed 's/^/ | /' + if [[ -n "$RELAY_HEALTH_URL" ]] && ! curl -fsS --max-time 10 "$RELAY_HEALTH_URL" >/dev/null; then + res relay "FAILED: $RELAY_HEALTH_URL does not answer"; return 1 + fi + res relay "shipped" +} + +deploy_viewer() { + say "Share viewer" + (cd "$D" && npm run -s build:share) >"$LOG_DIR/viewer.log" 2>&1 || + { res viewer "FAILED: build:share, see $LOG_DIR/viewer.log"; return 1; } + # Copy into the same directory (rsync --delete), so a bind mount of it + # still sees the new files. Keep the old files in viewer.old. + relay "cd $RELAY_DIR && rm -rf viewer.old && cp -a viewer viewer.old" || { res viewer "FAILED: backup of viewer/"; return 1; } + rsync -a --delete -e "ssh ${SSH_OPTS[*]}" "$D/dist/share/" "$RELAY_HOST:$RELAY_DIR/viewer/" || + { res viewer "FAILED: rsync"; return 1; } + res viewer "shipped" +} + +# ---------------------------------------------------------------- 8. MAC +install_mac() { + say "Mac: install the dmg" + if ! wait "$MAC_PID"; then res mac "FAILED: dmg build, see $LOG_DIR/dmg.log"; return 1; fi + local dmg main mnt + dmg=$(/bin/ls -t "$D"/release/*.dmg | head -1) + main="$MAC_APP/Contents/MacOS/Stem" + note "dmg: $(basename "$dmg")" + mnt=$(hdiutil attach -nobrowse -noautoopen "$dmg" 2>/dev/null | awk -F'\t' '/\/Volumes\//{print $NF}') + [[ -n "$mnt" ]] || { res mac "FAILED: cannot mount $dmg"; return 1; } + # Match the main process exactly: Chrome keeps Stem native-host helpers + # alive, and the iOS Simulator's Stem app has the same name. + # Send SIGTERM, not an AppleScript quit: AppleScript can open a macOS + # automation permission dialog. Electron quits cleanly on SIGTERM. If Stem + # does not stop in 60 s, kill it. + pkill -TERM -fx "$main" 2>/dev/null || true + for _ in $(seq 1 60); do pgrep -fxq "$main" || break; sleep 1; done + if pgrep -fxq "$main"; then + note "Stem.app did not quit in 60 s; kill it" + pkill -KILL -fx "$main" 2>/dev/null || true + for _ in $(seq 1 10); do pgrep -fxq "$main" || break; sleep 1; done + fi + if pgrep -fxq "$main"; then + hdiutil detach -quiet "$mnt" || true + res mac "NOT INSTALLED: Stem.app did not stop, also after SIGKILL. dmg: $dmg" + return 1 + fi + if ! { rm -rf "$MAC_APP" && ditto "$mnt/Stem.app" "$MAC_APP"; }; then + hdiutil detach -quiet "$mnt" || true + res mac "FAILED: copy to $MAC_APP"; return 1 + fi + hdiutil detach -quiet "$mnt" || true + open -a "$MAC_APP" /dev/null 2>&1 + sleep 5 + local ver + ver=$(defaults read "$MAC_APP/Contents/Info" CFBundleShortVersionString 2>/dev/null || echo '?') + if pgrep -fxq "$main"; then res mac "shipped, Stem $ver installed and running" + else res mac "installed Stem $ver, but it is not running"; return 1; fi +} + +wait_ios() { + say "TestFlight" + if wait "$IOS_PID"; then + grep -E 'EXPORT SUCCEEDED|Upload succeeded' "$LOG_DIR/testflight.log" | tail -2 | sed 's/^/ /' + res ios "shipped" + else + grep -E 'error:' "$LOG_DIR/testflight.log" | tail -5 | sed 's/^/ /' + res ios "FAILED: see $LOG_DIR/testflight.log"; return 1 + fi +} + +# Run each target; one failure does not stop the others. A target records its +# commit only when it shipped. +FAIL=0 +run() { local t=$1 fn=$2; if "$fn"; then state_set "$t" "$HEAD_SHA"; else FAIL=1; fi; } +has vps && run vps deploy_vps +has relay && run relay deploy_relay +has viewer && run viewer deploy_viewer +has mac && run mac install_mac +has ios && run ios wait_ios + +# ---------------------------------------------------------------- 9. REPORT +say "Result: deploy commit $(short "$HEAD_SHA") (VPS base $(short "$V"))" +for t in "${ALL_TARGETS[@]}"; do printf ' %-7s %s\n' "$t" "$(resget "$t")"; done +note "logs: $LOG_DIR" +exit $FAIL diff --git a/scripts/files-verify.mjs b/scripts/files-verify.mjs index 25643949..390e3014 100644 --- a/scripts/files-verify.mjs +++ b/scripts/files-verify.mjs @@ -6,7 +6,7 @@ // Run (from repo root): // rm -rf .files-build // npx tsc src/server/files/store.ts src/server/files/inject.ts src/server/workspace/paths.ts \ -// --outDir .files-build --module commonjs --moduleResolution node --target es2022 \ +// --outDir .files-build --module commonjs --moduleResolution node --ignoreConfig --ignoreDeprecations 6.0 --target es2022 \ // --skipLibCheck --esModuleInterop --rootDir src // printf '{"type":"commonjs"}' > .files-build/package.json // STEM_FILES_DIR="$(mktemp -d)/files" ELECTRON_RUN_AS_NODE=1 \ diff --git a/scripts/gate-canary.mjs b/scripts/gate-canary.mjs new file mode 100644 index 00000000..3943a3c3 --- /dev/null +++ b/scripts/gate-canary.mjs @@ -0,0 +1,153 @@ +// Gate canary: score the synthetic pairs in src/server/recall/gate-canary.json +// with the released gate model (Stem GTE Memory), the way the worker scores a +// pair, and compare against the scores recorded where the gate floors were +// measured. See src/server/recall/gate-canary.ts for why. +// +// npm run eval:gate-canary # check this platform; exits 1 on drift +// node scripts/gate-canary.mjs --write # record this platform's scores as its reference +// node scripts/gate-canary.mjs --model # use model files already on disk +// node scripts/gate-canary.mjs --scores --platform linux-x64 [--write] +// # judge or record scores taken elsewhere +// +// The model (342 MB) is downloaded once into .embed-smoke-cache/, at the +// revision and checksums the app pins (gte-model-artifact.ts). +// +// Run --write only on a platform whose gate floors were measured, after a +// benchmark confirmed them: a new reference is a statement that the floors +// hold for these scores. +import { spawnSync } from 'node:child_process'; +import { createHash } from 'node:crypto'; +import { createReadStream, createWriteStream, existsSync, mkdirSync, readFileSync, renameSync, rmSync, statSync, writeFileSync } from 'node:fs'; +import { createRequire } from 'node:module'; +import { dirname, join, resolve } from 'node:path'; +import { Readable } from 'node:stream'; +import { pipeline } from 'node:stream/promises'; +import { fileURLToPath } from 'node:url'; + +const ROOT = resolve(dirname(fileURLToPath(import.meta.url)), '..'); +const BUILD_DIR = join(ROOT, '.gate-canary-build'); +const DATA = join(ROOT, 'src', 'server', 'recall', 'gate-canary.json'); +const args = process.argv.slice(2); +const flag = (name, fallback = null) => { + const i = args.indexOf(name); + return i >= 0 && args[i + 1] ? args[i + 1] : fallback; +}; +const write = args.includes('--write'); +const platform = flag('--platform', `${process.platform}-${process.arch}`); + +// The comparison and the model pin are the app's own modules, compiled as they +// are, so this script can never judge by a copy of the rule. +rmSync(BUILD_DIR, { recursive: true, force: true }); +const tsc = spawnSync( + 'npx', + [ + 'tsc', 'src/server/recall/gate-canary.ts', 'src/server/recall/gte-model-artifact.ts', + '--outDir', BUILD_DIR, '--module', 'commonjs', '--moduleResolution', 'node', '--ignoreConfig', '--ignoreDeprecations', '6.0', '--target', 'es2022', + '--skipLibCheck', '--esModuleInterop', '--resolveJsonModule', '--rootDir', 'src' + ], + { cwd: ROOT, stdio: 'inherit' } +); +if (tsc.status !== 0) process.exit(tsc.status ?? 1); +writeFileSync(join(BUILD_DIR, 'package.json'), '{"type":"commonjs"}'); +const require = createRequire(import.meta.url); +const { GATE_CANARY, gateDrift, scoreGateCanary } = require(join(BUILD_DIR, 'server', 'recall', 'gate-canary.js')); +const { GTE_MODEL_ARTIFACT, GTE_MODEL_VERSION } = require(join(BUILD_DIR, 'server', 'recall', 'gte-model-artifact.js')); + +if (GATE_CANARY.model !== GTE_MODEL_VERSION) { + console.error(`The canary's scores are for ${GATE_CANARY.model}, the app ships ${GTE_MODEL_VERSION}. Measure the floors for the new release, then record new references with --write.`); + process.exit(1); +} + +async function sha256(path) { + const hash = createHash('sha256'); + for await (const chunk of createReadStream(path)) hash.update(chunk); + return hash.digest('hex'); +} + +/** Fetch the pinned release into `dir`, skipping files already there and whole. */ +async function ensureModel(dir) { + for (const [file, expected] of Object.entries(GTE_MODEL_ARTIFACT.files)) { + if (file === 'LICENSE' || file === 'NOTICE') continue; + const path = join(dir, file); + if (existsSync(path) && statSync(path).size === expected.size && (await sha256(path)) === expected.sha256) continue; + const url = `https://huggingface.co/${GTE_MODEL_ARTIFACT.repo}/resolve/${GTE_MODEL_ARTIFACT.revision}/${file}`; + process.stderr.write(`downloading ${file} (${Math.round(expected.size / 1e6)} MB)\n`); + const res = await fetch(url); + if (!res.ok || !res.body) throw new Error(`${url}: HTTP ${res.status}`); + mkdirSync(dirname(path), { recursive: true }); + // To disk as it arrives, under another name until the checksum agrees: a + // run that is cut off must not leave a half file where a whole one is expected. + const partial = `${path}.partial`; + await pipeline(Readable.fromWeb(res.body), createWriteStream(partial)); + if ((await sha256(partial)) !== expected.sha256) { + rmSync(partial, { force: true }); + throw new Error(`${file} does not match the pinned checksum`); + } + renameSync(partial, path); + } +} + +/** The worker's GTE path (embed-worker.ts loadRerank + scoreGtePair), one pair per pass. */ +async function scoreWithModel(dir) { + const { AutoTokenizer, PreTrainedModel, env } = await import('@huggingface/transformers'); + env.allowRemoteModels = false; + const tokenizer = await AutoTokenizer.from_pretrained(dir, { local_files_only: true }); + const model = await PreTrainedModel.from_pretrained(dir, { + dtype: 'q8', + local_files_only: true, + session_options: { enableCpuMemArena: false } + }); + try { + return await scoreGateCanary(async (query, doc) => { + const inputs = tokenizer([query], { text_pair: [doc], padding: true, truncation: false }); + const { logits } = await model(inputs); + if (logits.data.length !== 1 || !Number.isFinite(logits.data[0])) throw new Error('expected one finite logit'); + return Number(logits.data[0]); + }); + } finally { + await model.dispose(); + } +} + +let scores; +const scoresFile = flag('--scores'); +if (scoresFile) { + scores = JSON.parse(readFileSync(scoresFile, 'utf8')); +} else { + const dir = resolve(flag('--model', process.env.STEM_GTE_FACT_MODEL_DIR || join(ROOT, '.embed-smoke-cache', GTE_MODEL_VERSION))); + if (!flag('--model') && !process.env.STEM_GTE_FACT_MODEL_DIR) await ensureModel(dir); + scores = await scoreWithModel(dir); +} +if (!Array.isArray(scores) || scores.length !== GATE_CANARY.pairs.length || scores.some((s) => !Number.isFinite(s))) { + console.error(`Expected ${GATE_CANARY.pairs.length} finite scores.`); + process.exit(1); +} + +const sorted = [...scores].sort((a, b) => a - b); +console.log(`${platform}: ${scores.length} pairs, logits ${sorted[0].toFixed(2)} … ${sorted[sorted.length - 1].toFixed(2)}, median ${sorted[Math.floor(sorted.length / 2)].toFixed(2)}`); +for (const name of Object.keys(GATE_CANARY.reference)) { + const d = gateDrift(scores, name, { ...GATE_CANARY, reference: { [name]: GATE_CANARY.reference[name] } }); + if (d) console.log(` against ${name}: median ${d.median.toFixed(3)}, max ${d.max.toFixed(2)}, moved ${(d.moved * 100).toFixed(0)}%${d.drifted ? ' DRIFT' : ''}`); +} + +if (write) { + const data = JSON.parse(readFileSync(DATA, 'utf8')); + data.reference[platform] = scores.map((s) => Math.round(s * 1e4) / 1e4); + const tf = require(join(ROOT, 'node_modules', '@huggingface', 'transformers', 'package.json')).version; + data.measured[platform] = `transformers.js ${tf}, ${new Date().toISOString().slice(0, 10)}`; + writeFileSync(DATA, `${JSON.stringify(data, null, 2)}\n`); + console.log(`recorded the reference for ${platform}`); + process.exit(0); +} + +const drift = gateDrift(scores, platform); +if (!drift) { + console.log('No reference to compare against. Record one with --write on a platform whose floors were measured.'); + process.exit(0); +} +if (!drift.ownPlatform) console.log(`No reference for ${platform}; held to the nearest one, ${drift.against}.`); +if (drift.drifted) { + console.error(`The gate model's scores moved against ${drift.against}. The gate floors (gte-fact-pilot.ts) were measured on those scores: benchmark them again before this ships.`); + process.exit(1); +} +console.log('The gate model scores as it did when its floors were measured.'); diff --git a/scripts/gen-shortcuts-doc.mjs b/scripts/gen-shortcuts-doc.mjs index dffb853e..bdc090f1 100644 --- a/scripts/gen-shortcuts-doc.mjs +++ b/scripts/gen-shortcuts-doc.mjs @@ -45,7 +45,15 @@ const TRICKS = `## Tricks range, then mark, move or delete them together. **Esc** clears the selection. - Drop a file on **This chat** to use it for one message. Drop it on **Files** to copy it into Stem and reuse it across chats. -- **Enter** sends. **Shift+Enter** starts a new line.`; +- **Enter** sends. **Shift+Enter** starts a new line. In mail, **Enter** starts a new + line and **⌘↵** (**Ctrl+Enter**) sends. +- **⌘+** (or **⌘=**), **⌘-** and **⌘0** zoom the main window in, out and back to actual + size; on Windows and Linux use **Ctrl**. Stem remembers the zoom. Quick Chat keeps its + own size. +- In an **Ask about this window** panel: **⌘T** opens another tab about the same + window, **⌘W** closes the tab you are in, **⌘⇧[** and **⌘⇧]** switch tabs, and + **⌘M** shrinks the panel to a pill beside its window. Use **Ctrl** on Windows and + Linux.`; /** Escape the characters a keycap can contain that Markdown tables would eat. */ const cell = (text) => text.replace(/\\/g, '\\\\').replace(/\|/g, '\\|'); diff --git a/scripts/linux-pc.mjs b/scripts/linux-pc.mjs index 1ec5ee3d..a41542c3 100644 --- a/scripts/linux-pc.mjs +++ b/scripts/linux-pc.mjs @@ -1,8 +1,9 @@ #!/usr/bin/env node -// Run Stem on a real Linux PC over SSH: the working tree is copied over, so -// uncommitted work is what gets tested, the way scripts/linux-test.mjs does it -// with a container. The PC needs Node 24, rsync and GNOME (mutter); the host -// comes from STEM_LINUX_HOST, e.g. `STEM_LINUX_HOST=join3r@192.168.1.164`. +// Run Stem on a real Linux PC over SSH: the working tree is copied over with +// git (scripts/remote-snapshot.mjs), so uncommitted work is what gets tested, +// the way scripts/linux-test.mjs does it with a container. The PC needs Node 24, git and GNOME (mutter); the host +// comes from STEM_LINUX_HOST, e.g. `STEM_LINUX_HOST=join3r@192.168.1.164`, and +// STEM_LINUX_JUMP=infra reaches it through a jump host when away from home. // // node scripts/linux-pc.mjs test [vitest args] unit tests // node scripts/linux-pc.mjs e2e [playwright args] the E2E suite on a headless Wayland desktop @@ -24,6 +25,7 @@ import { spawnSync } from 'node:child_process'; import { dirname, resolve } from 'node:path'; import { fileURLToPath } from 'node:url'; +import { BARE, PUBLIC_REPO, push, shQuote, snapshot } from './remote-snapshot.mjs'; const repo = resolve(dirname(fileURLToPath(import.meta.url)), '..'); const host = process.env.STEM_LINUX_HOST; @@ -32,7 +34,10 @@ if (!host) { process.exit(2); } const DIR = 'stem'; -const SSH = ['-o', 'BatchMode=yes', '-o', 'VisualHostKey=no']; +// STEM_LINUX_JUMP: optional jump host(s) for ssh -J, e.g. `infra` when away +// from the PC's network (comma-separate a chain). +const jump = process.env.STEM_LINUX_JUMP; +const SSH = ['-o', 'BatchMode=yes', '-o', 'VisualHostKey=no', ...(jump ? ['-J', jump] : [])]; const [mode = 'test', ...rest] = process.argv.slice(2); function run(cmd, args, opts = {}) { @@ -41,21 +46,25 @@ function run(cmd, args, opts = {}) { } const quote = (s) => `'${String(s).replace(/'/g, `'\\''`)}'`; -run('rsync', [ - '-az', '--delete', - '--filter=:- .gitignore', '--exclude=.git', '--exclude=.worktrees', - // node_modules and dist are the PC's own (Linux native modules), never the Mac's. - '--filter=P node_modules/', '--filter=P dist/', '--filter=P out/', - '-e', `ssh ${SSH.join(' ')}`, - `${repo}/`, `${host}:${DIR}/` -]); +// The PC fetches the public main from GitHub; only this checkout's own +// commits and uncommitted work go over SSH (scripts/remote-snapshot.mjs). +// node_modules, dist and out are ignored by git, so they stay the PC's own +// (Linux native modules), never the Mac's. +run('ssh', [...SSH, host, `bash -c ${quote(`test -d ~/${BARE} || git init -q --bare ~/${BARE} +git -C ~/${BARE} fetch -q ${PUBLIC_REPO} +refs/heads/main:refs/heads/main || echo "linux-pc: could not fetch main from GitHub; sending everything"`)}`]); +push(repo, snapshot(repo), { sshCommand: ['ssh', ...SSH].map(shQuote).join(' '), remote: `${host}:${BARE}` }); // Runs on the PC. `headless` starts a private mutter on a virtual monitor and // points Wayland apps at it; the trap takes it down with the session. const prelude = ` set -euo pipefail export PATH="$HOME/.local/bin:$PATH" XDG_RUNTIME_DIR=/run/user/$(id -u) +mkdir -p ~/${DIR} cd ~/${DIR} +[ -d .git ] || git init -q +git fetch -q ~/${BARE} snapshot +git reset -q --hard FETCH_HEAD +git clean -fdq want=$(sha256sum package-lock.json | cut -d' ' -f1) if [ "$(cat node_modules/.stem-lock 2>/dev/null)" != "$want" ]; then echo "linux-pc: npm ci (lockfile changed)" diff --git a/scripts/mdx-usage-eval.mjs b/scripts/mdx-usage-eval.mjs index b33a551c..5c9d5a1b 100644 --- a/scripts/mdx-usage-eval.mjs +++ b/scripts/mdx-usage-eval.mjs @@ -17,7 +17,7 @@ // old pointer prompt with that page inlined // // Optional: -// STEM_MDX_EVAL_MODEL=openai-codex/gpt-6.1-sol +// STEM_MDX_EVAL_MODEL=openai-codex/gpt-6.2-sol // STEM_MDX_EVAL_PI_DIR=~/.pi/agent (a pi home holding a working sign-in) // STEM_MDX_EVAL_CASES=chart-bills,plain-hi // STEM_MDX_EVAL_CONCURRENCY=4 @@ -32,7 +32,7 @@ import remarkGfm from 'remark-gfm'; import remarkMdx from 'remark-mdx'; const ROOT = fileURLToPath(new URL('..', import.meta.url)); -const [provider, ...modelParts] = (process.env.STEM_MDX_EVAL_MODEL ?? 'openai-codex/gpt-6.1-sol').split('/'); +const [provider, ...modelParts] = (process.env.STEM_MDX_EVAL_MODEL ?? 'openai-codex/gpt-6.2-sol').split('/'); const modelId = modelParts.join('/'); const piDir = process.env.STEM_MDX_EVAL_PI_DIR ?? join(homedir(), '.pi', 'agent'); const concurrency = Math.max(1, Number(process.env.STEM_MDX_EVAL_CONCURRENCY ?? 4)); diff --git a/scripts/recall-eval.mjs b/scripts/recall-eval.mjs index 12aa1c9a..572c7a0b 100644 --- a/scripts/recall-eval.mjs +++ b/scripts/recall-eval.mjs @@ -55,7 +55,7 @@ if (!skipBuild) { [ 'tsc', ...files, '--outDir', '.recall-build', - '--module', 'commonjs', '--moduleResolution', 'node', '--target', 'es2022', + '--module', 'commonjs', '--moduleResolution', 'node', '--ignoreConfig', '--ignoreDeprecations', '6.0', '--target', 'es2022', // noCheck: the graph type-includes the worker-host files, whose // import.meta is a TS1343 under commonjs. They are import-type-only, so // the emitted JS the eval loads never touches them. diff --git a/scripts/recall-verify.mjs b/scripts/recall-verify.mjs index b5a33cbc..4d04c01a 100644 --- a/scripts/recall-verify.mjs +++ b/scripts/recall-verify.mjs @@ -9,7 +9,7 @@ // src/server/recall/vector.ts \ // src/server/recall/capture.ts src/server/recall/distill.ts src/server/recall/consolidate.ts \ // --outDir .recall-build \ -// --module commonjs --moduleResolution node --target es2022 --skipLibCheck \ +// --module commonjs --moduleResolution node --ignoreConfig --ignoreDeprecations 6.0 --target es2022 --skipLibCheck \ // --esModuleInterop --rootDir src --noCheck // printf '{"type":"commonjs"}' > .recall-build/package.json // STEM_RECALL_DB="$PWD/.recall-build/verify.sqlite" ELECTRON_RUN_AS_NODE=1 \ diff --git a/scripts/remote-snapshot.mjs b/scripts/remote-snapshot.mjs new file mode 100644 index 00000000..f18d5b0b --- /dev/null +++ b/scripts/remote-snapshot.mjs @@ -0,0 +1,61 @@ +// Copies the working tree to a test machine with git instead of a full copy, +// for scripts/linux-pc.mjs and scripts/windows-vm.mjs. The machine fetches +// the public `main` from GitHub itself, so only what this checkout adds on top +// (unreleased commits plus uncommitted work) travels over SSH. That matters on +// a slow route, such as through a jump host over a Tailscale relay. +// +// The snapshot is a commit of the working tree (tracked files and untracked +// files that are not ignored), with HEAD as its parent, made through a +// temporary index so the real index and worktree are untouched. Nothing is +// pushed to GitHub: the snapshot goes only to the machine's own bare repo, +// `stem.git` in its home directory, as the branch `snapshot`. + +import { spawnSync } from 'node:child_process'; +import { mkdtempSync, rmSync } from 'node:fs'; +import { tmpdir } from 'node:os'; +import { join } from 'node:path'; + +export const PUBLIC_REPO = 'https://github.com/join3r/stem.git'; +export const BARE = 'stem.git'; + +function git(repo, args, env = {}) { + const r = spawnSync('git', args, { cwd: repo, encoding: 'utf8', env: { ...process.env, ...env } }); + if (r.status !== 0) { + process.stderr.write(r.stderr); + process.exit(r.status ?? 1); + } + return r.stdout.trim(); +} + +// Same tree and HEAD give the same commit, so an unchanged checkout pushes +// nothing. +export function snapshot(repo) { + const tmp = mkdtempSync(join(tmpdir(), 'stem-snap-')); + const index = { GIT_INDEX_FILE: join(tmp, 'index') }; + try { + git(repo, ['read-tree', 'HEAD'], index); + git(repo, ['add', '-A'], index); + const tree = git(repo, ['write-tree'], index); + const when = git(repo, ['log', '-1', '--format=%cI', 'HEAD']); + const who = { GIT_AUTHOR_NAME: 'stem-snapshot', GIT_AUTHOR_EMAIL: 'snapshot@localhost', GIT_COMMITTER_NAME: 'stem-snapshot', GIT_COMMITTER_EMAIL: 'snapshot@localhost', GIT_AUTHOR_DATE: when, GIT_COMMITTER_DATE: when }; + const sha = git(repo, ['commit-tree', tree, '-p', 'HEAD', '-m', 'working tree snapshot'], who); + // Keeps the pushed objects alive locally, so the next push can send only + // the difference from it. + git(repo, ['update-ref', 'refs/worktree/stem-snapshot', sha]); + return sha; + } finally { + rmSync(tmp, { recursive: true, force: true }); + } +} + +// `sshCommand` is a shell string for GIT_SSH_COMMAND; `remote` is an +// ssh://… URL. Windows' OpenSSH runs commands in PowerShell, where +// git-receive-pack is not on PATH, hence `git receive-pack`. +export function push(repo, sha, { sshCommand, remote }) { + const r = spawnSync('git', ['push', '-q', '--force', '--receive-pack=git receive-pack', remote, `${sha}:refs/heads/snapshot`], { + cwd: repo, stdio: 'inherit', env: { ...process.env, GIT_SSH_COMMAND: sshCommand } + }); + if (r.status !== 0) process.exit(r.status ?? 1); +} + +export const shQuote = (s) => `'${String(s).replace(/'/g, `'\\''`)}'`; diff --git a/scripts/server-boot.mjs b/scripts/server-boot.mjs index f6e2549d..cb62069f 100644 --- a/scripts/server-boot.mjs +++ b/scripts/server-boot.mjs @@ -191,7 +191,7 @@ function runServerCommand(args, commandEnv) { // runtime as ERR_MODULE_NOT_FOUND for a file nobody wrote, on a path the e2e // suite never walks, so it is asserted here where the build output is in hand. const distMain = join(appDir, 'dist', 'main'); -for (const rel of ['embed-worker.js', 'scan-worker.js', 'recall-mcp-server.js', 'pi/pi-node-shim.mjs', 'pi/stem-mcp-extension.mjs', 'pi/image-gen.mjs', 'pi/mcp-discovery.mjs']) { +for (const rel of ['embed-worker.js', 'scan-worker.js', 'recall-mcp-server.js', 'pi/pi-node-shim.mjs', 'pi/stem-mcp-extension.mjs', 'pi/image-gen.mjs', 'pi/mcp-discovery.mjs', 'pi/mcp-install-paths.mjs']) { check(`${rel} sits where its sibling join expects it`, existsSync(join(distMain, rel))); } check( diff --git a/scripts/skill-retrieval-eval.mjs b/scripts/skill-retrieval-eval.mjs index 7970c0f7..7f2fe1ab 100644 --- a/scripts/skill-retrieval-eval.mjs +++ b/scripts/skill-retrieval-eval.mjs @@ -89,7 +89,7 @@ if (!skipBuild) { [ 'tsc', 'src/server/recall/embed-catalog.ts', 'src/server/recall/rerank-catalog.ts', 'src/server/skills/gate.ts', '--outDir', '.skills-build', - '--module', 'commonjs', '--moduleResolution', 'node', '--target', 'es2022', + '--module', 'commonjs', '--moduleResolution', 'node', '--ignoreConfig', '--ignoreDeprecations', '6.0', '--target', 'es2022', '--skipLibCheck', '--esModuleInterop', '--rootDir', 'src' ], { cwd: ROOT, stdio: 'inherit' } diff --git a/scripts/sys-version.mjs b/scripts/sys-version.mjs index 9e183e92..b1dad5db 100644 --- a/scripts/sys-version.mjs +++ b/scripts/sys-version.mjs @@ -34,7 +34,7 @@ import { pathToFileURL } from 'node:url'; // in would make the hashes churn until they said nothing. Subsystem-specific // pieces that used to live there (the mail preamble) were moved out into their // subsystem's directory so they count. -const SHARED = ['src/server/pi/stem-mcp-extension.mjs', 'src/server/pi/mcp-discovery.mjs', 'src/server/pi/image-gen.mjs', 'src/server/workspace/bootstrap.ts', 'docs/assistant']; +const SHARED = ['src/server/pi/stem-mcp-extension.mjs', 'src/server/pi/mcp-discovery.mjs', 'src/server/pi/mcp-install-paths.mjs', 'src/server/pi/image-gen.mjs', 'src/server/workspace/bootstrap.ts', 'docs/assistant']; export const SUBSYSTEMS = { persona: ['src/server/mail', 'src/server/workspace/personas.ts', ...SHARED], diff --git a/scripts/windows-vm.mjs b/scripts/windows-vm.mjs index 34c259b3..e3b833c5 100644 --- a/scripts/windows-vm.mjs +++ b/scripts/windows-vm.mjs @@ -1,8 +1,9 @@ #!/usr/bin/env node // Run Stem on a Windows machine over SSH, the way scripts/linux-pc.mjs does on -// Linux: the working tree (uncommitted work included) is copied over and the -// command runs there. The machine needs OpenSSH with PowerShell as its shell, -// Node 24 on the user PATH, and Git for Windows. +// Linux: the working tree (uncommitted work included) is copied over with git +// (scripts/remote-snapshot.mjs) and the command runs there. The machine needs +// OpenSSH with PowerShell as its shell, Node 24 on the user PATH, and Git for +// Windows. // // STEM_WINDOWS_HOST user@host[:port], e.g. stem@127.0.0.1:2222 // STEM_WINDOWS_JUMP optional jump host, e.g. join3r@192.168.1.164 (a VM @@ -23,10 +24,9 @@ // scheduled task, and prints what it wrote; the user must be logged in. import { spawnSync } from 'node:child_process'; -import { mkdtempSync, rmSync } from 'node:fs'; -import { tmpdir } from 'node:os'; -import { dirname, join, resolve } from 'node:path'; +import { dirname, resolve } from 'node:path'; import { fileURLToPath } from 'node:url'; +import { BARE, PUBLIC_REPO, push, shQuote, snapshot } from './remote-snapshot.mjs'; const repo = resolve(dirname(fileURLToPath(import.meta.url)), '..'); const target = process.env.STEM_WINDOWS_HOST; @@ -48,29 +48,36 @@ function run(cmd, args, o = {}) { } const psQuote = (s) => `'${String(s).replace(/'/g, "''")}'`; -// The tracked and untracked-but-not-ignored files, as one tarball; Windows' -// own tar.exe unpacks it. -const tmp = mkdtempSync(join(tmpdir(), 'stem-win-')); -const tarball = join(tmp, 'stem.tgz'); -const files = spawnSync('git', ['ls-files', '-co', '--exclude-standard', '-z'], { cwd: repo }); -if (files.status !== 0) process.exit(1); -run('tar', ['--null', '-T', '-', '-czf', tarball], { cwd: repo, input: files.stdout, stdio: ['pipe', 'inherit', 'inherit'], env: { ...process.env, COPYFILE_DISABLE: '1' } }); -run('scp', ['-q', ...opts, '-P', port, tarball, `${userHost}:stem.tgz`]); -rmSync(tmp, { recursive: true, force: true }); +const ssh = ['-p', port, ...opts, userHost]; +// -EncodedCommand, not a script on stdin: `powershell -Command -` stops at the +// first block that spans lines. +const encoded = (script) => `powershell -NoProfile -NonInteractive -EncodedCommand ${Buffer.from(script, 'utf16le').toString('base64')}`; + +// The VM fetches the public main from GitHub; only this checkout's own commits +// and uncommitted work go over SSH (scripts/remote-snapshot.mjs). +run('ssh', [...ssh, encoded(`if (-not (Test-Path ${BARE})) { git init -q --bare ${BARE} } +git -C ${BARE} fetch -q ${PUBLIC_REPO} +refs/heads/main:refs/heads/main +if ($LASTEXITCODE -ne 0) { Write-Output 'windows-vm: could not fetch main from GitHub; sending everything' }`)]); +push(repo, snapshot(repo), { sshCommand: ['ssh', '-p', port, ...opts].map(shQuote).join(' '), remote: `${userHost}:${BARE}` }); // Runs on Windows. node_modules (the Windows builds of the native modules), -// dist and release (the last installer build) survive; everything else is -// replaced by the copy. +// dist and release (the last installer build) are ignored by git, so they +// survive; everything else becomes the snapshot. autocrlf stays off so files +// keep the LF endings they have on the Mac. const prelude = ` $ErrorActionPreference = 'Stop' $ProgressPreference = 'SilentlyContinue' $env:Path = [Environment]::GetEnvironmentVariable('Path','User') + ';' + [Environment]::GetEnvironmentVariable('Path','Machine') $dst = "$env:USERPROFILE\\stem" New-Item -ItemType Directory -Force $dst | Out-Null -Get-ChildItem -Force $dst | Where-Object { $_.Name -notin 'node_modules','dist','release' } | Remove-Item -Recurse -Force -tar -xzf "$env:USERPROFILE\\stem.tgz" -C $dst -Remove-Item "$env:USERPROFILE\\stem.tgz" Set-Location $dst +if (-not (Test-Path .git)) { git init -q } +git config core.autocrlf false +git fetch -q "$env:USERPROFILE\\${BARE}" snapshot +if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE } +git reset -q --hard FETCH_HEAD +if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE } +git clean -fdq $want = (Get-FileHash package-lock.json -Algorithm SHA256).Hash $have = if (Test-Path node_modules\\.stem-lock) { Get-Content node_modules\\.stem-lock } else { '' } if ($have -ne $want) { @@ -108,10 +115,6 @@ if (body === undefined) { process.exit(2); } -const ssh = ['-p', port, ...opts, userHost]; -// -EncodedCommand, not a script on stdin: `powershell -Command -` stops at the -// first block that spans lines. -const encoded = (script) => `powershell -NoProfile -NonInteractive -EncodedCommand ${Buffer.from(script, 'utf16le').toString('base64')}`; if (mode === 'shell') { run('ssh', [...ssh, encoded(prelude)]); run('ssh', ['-t', ...ssh, 'cd $env:USERPROFILE\\stem; powershell -NoProfile']); diff --git a/src/browser-extension/actions.js b/src/browser-extension/actions.js index 315065b6..2d420437 100644 --- a/src/browser-extension/actions.js +++ b/src/browser-extension/actions.js @@ -94,7 +94,11 @@ function dialogText(d) { } async function getTab(tabId) { - return chrome.tabs.get(tabId); + const tab = await chrome.tabs.get(tabId); + // An Electron browser (jbrow before 2026-11-03) answers { id: -1 } for a tab + // that isn't open instead of failing, as Chrome does: Stem then reported "tab -1". + if (!tab || typeof tab.id !== 'number' || tab.id < 0) throw new Error(`No tab with id: ${tabId}.`); + return tab; } async function targetTab(run, action) { diff --git a/src/browser-extension/background.js b/src/browser-extension/background.js index d5476826..56ccb429 100644 --- a/src/browser-extension/background.js +++ b/src/browser-extension/background.js @@ -33,6 +33,8 @@ let attempt = 0; let reconnectTimer = null; let hostConnected = null; let lastError = ''; +/** Stem said a newer native host of this profile has the link: no quick reconnects (the alarm still tries). */ +let replaced = false; /** What Stem calls this browser profile ("Work"), once it has said. */ let profileName = ''; @@ -124,6 +126,10 @@ async function connect() { hostConnected = null; void endAllRuns(); refreshBadge(); + if (replaced) { + replaced = false; + return; + } scheduleReconnect(); }); post({ @@ -214,7 +220,9 @@ async function onNativeMessage(msg) { if (typeof msg.threadId === 'string') await endRun(msg.threadId); return; case 'reload': - await endAllRuns(); + // Stem also sends this when the extension stopped answering: a debugger + // detach that never settles must not keep the restart from happening. + await Promise.race([endAllRuns(), new Promise((resolve) => setTimeout(resolve, 2_000))]); chrome.runtime.reload(); return; case 'uninstall': @@ -224,6 +232,10 @@ async function onNativeMessage(msg) { lastError = String((e && e.message) || e); }); return; + case 'replaced': + replaced = true; + lastError = 'Another connection from this profile took over'; + return; case 'host': hostConnected = !!msg.connected; refreshBadge(); @@ -303,6 +315,7 @@ chrome.tabs.onRemoved.addListener((tabId) => { chrome.tabs.onReplaced.addListener((added, removed) => { runs.replaceTab(removed, added); + cdp.tabReplaced(removed, added); }); // ---- popup, badge ---- diff --git a/src/browser-extension/cdp.js b/src/browser-extension/cdp.js index 25c0ed52..24206971 100644 --- a/src/browser-extension/cdp.js +++ b/src/browser-extension/cdp.js @@ -98,6 +98,8 @@ class Session { this.idleTimer = null; this.pillRect = null; this.pinging = false; + /** IDs this tab had before the browser replaced it (see tabReplaced). */ + this.formerIds = new Set(); } send(method, params) { @@ -112,7 +114,34 @@ class Session { } export function session(tabId) { - return sessions.get(tabId); + return sessions.get(currentTab(tabId)); +} + +/** + * Tab IDs the browser replaced, old to new. jbrow keeps a sleeping tab without + * its page and gives it a new ID when the debugger wakes it (tabs.onReplaced + * says so, often before the attach returns). Filed under the old ID, Stem's + * session missed the next call by the new one, which then tried to attach a + * second time and was refused by Stem's own debugger (2026-11-03). + */ +const replacedBy = new Map(); + +function currentTab(tabId) { + let id = tabId; + for (let i = 0; i < 8 && replacedBy.has(id); i++) id = replacedBy.get(id); + return id; +} + +/** tabs.onReplaced: the tab's session, if any, goes under its new ID. */ +export function tabReplaced(removed, added) { + replacedBy.set(removed, added); + if (replacedBy.size > 200) replacedBy.delete(replacedBy.keys().next().value); + const s = sessions.get(removed); + if (!s) return; + sessions.delete(removed); + s.formerIds.add(removed); + s.tabId = added; + if (!sessions.has(added)) sessions.set(added, s); } export function attachedTabs() { @@ -145,7 +174,8 @@ function attachError(tabId, message) { } /** The tab's session, attaching first if needed. Concurrent callers share one attach. */ -export function attach(tabId) { +export function attach(requested) { + const tabId = currentTab(requested); const existing = sessions.get(tabId); if (existing) return Promise.resolve(existing); if (attaching.has(tabId)) return attaching.get(tabId); @@ -194,6 +224,20 @@ async function doAttach(tabId) { await chrome.debugger.attach({ tabId }, '1.3'); } catch (err) { const message = cdpMessage(err); + // The debugger that holds the tab can be Stem's own, from before its + // service worker stopped: the attachment belongs to the extension and + // stays, but the new worker has no session for it (jbrow, 2026-11-09: + // after each worker crash every action in the tab was refused). The + // browser lets an extension detach only its own attachment, so a detach + // that works proves the tab was Stem's. + if (/another debugger/i.test(message) && (await releaseOwnStale(tabId))) { + try { + await chrome.debugger.attach({ tabId }, '1.3'); + } catch (again) { + throw attachError(tabId, cdpMessage(again)); + } + return startSession(tabId); + } // Another extension's frame (a password manager's fill menu) blocks the // debugger for the whole tab. It is that extension's overlay, not the // page: remove it and try once more. @@ -204,8 +248,27 @@ async function doAttach(tabId) { throw attachError(tabId, cdpMessage(again)); } } - const s = new Session(tabId); - sessions.set(tabId, s); + return startSession(tabId); +} + +/** Detach a debugger this worker has no session for; true when it was Stem's own. */ +async function releaseOwnStale(tabId) { + if (sessions.has(tabId)) return false; + try { + await chrome.debugger.detach({ tabId }); + return true; + } catch { + return false; + } +} + +/** Set up the session for a tab the debugger was just attached to. */ +async function startSession(tabId) { + // The attach may have woken the tab under a new ID. + const now = currentTab(tabId); + const s = new Session(now); + if (now !== tabId) s.formerIds.add(tabId); + sessions.set(now, s); try { await Promise.all([ s.send('Page.enable'), @@ -218,14 +281,14 @@ async function doAttach(tabId) { const { frameTree } = await s.send('Page.getFrameTree'); s.mainFrameId = frameTree.frame.id; s.loaderId = frameTree.frame.loaderId; - const orphan = orphanSnapshots.get(tabId); - orphanSnapshots.delete(tabId); + const orphan = orphanSnapshots.get(s.tabId); + orphanSnapshots.delete(s.tabId); if (orphan && orphan.snapshot.loaderId === s.loaderId && Date.now() - orphan.at < ORPHAN_SNAPSHOT_MS) s.snapshot = orphan.snapshot; await installMarkerHooks((m, p) => s.send(m, p)); await ping(s); } catch (err) { - sessions.delete(tabId); - await chrome.debugger.detach({ tabId }).catch(() => {}); + if (sessions.get(s.tabId) === s) sessions.delete(s.tabId); + await chrome.debugger.detach({ tabId: s.tabId }).catch(() => {}); throw err instanceof UserError ? err : attachError(tabId, err.message); } touchIdle(s); @@ -233,7 +296,8 @@ async function doAttach(tabId) { } /** Take the marker down and let go of the tab. Safe to call for a tab Stem is not in. */ -export async function detach(tabId) { +export async function detach(requested) { + const tabId = currentTab(requested); const s = sessions.get(tabId); if (!s) return; sessions.delete(tabId); @@ -366,11 +430,12 @@ chrome.debugger.onEvent.addListener((source, method, params) => { chrome.debugger.onDetach.addListener((source, reason) => { const tabId = source.tabId; - const s = sessions.get(tabId); + // A browser may report the detach by the tab's old ID. + const s = sessions.get(tabId) ?? [...sessions.values()].find((x) => x.formerIds.has(tabId)); if (s) { - sessions.delete(tabId); + sessions.delete(s.tabId); clearTimeout(s.idleTimer); - if (s.snapshot && reason !== 'canceled_by_user') orphanSnapshots.set(tabId, { snapshot: s.snapshot, at: Date.now() }); + if (s.snapshot && reason !== 'canceled_by_user') orphanSnapshots.set(s.tabId, { snapshot: s.snapshot, at: Date.now() }); } - handlers.detached(tabId, reason); + handlers.detached(s ? s.tabId : tabId, reason); }); diff --git a/src/desktop/app-menu.ts b/src/desktop/app-menu.ts index 13295a3f..486f480b 100644 --- a/src/desktop/app-menu.ts +++ b/src/desktop/app-menu.ts @@ -56,7 +56,11 @@ export interface AppMenuActions { /** Deliver a command to the main window. */ command(command: MenuCommand): void; toggleQuickChat(): void; + /** Window › Minimize: a Quick Chat window panel shrinks to its pill, other windows minimise. */ + minimize(): void; checkForUpdates(): void; + /** Step the main window's page zoom (see zoom.ts, which also owns the keys). */ + zoom(action: 'in' | 'out' | 'reset'): void; } /** @@ -192,16 +196,18 @@ export function appMenuTemplate( tab('chats', 'Chats'), tab('memory', 'Memory'), tab('mcp', 'Tools'), - tab('personas', 'Personas'), + tab('personas', 'Personas & People'), tab('folders', 'Sources'), tab('tasks', 'Scheduled Tasks'), sep, shortcut('toggle-inspector', 'Toggle Side Panel'), shortcut('toggle-format'), sep, - { role: 'resetZoom' }, - { role: 'zoomIn' }, - { role: 'zoomOut' }, + // Not the zoom roles: their ⌘+ needs Shift on a US keyboard. zoom.ts + // catches the keys before the menu sees them; these only print them. + { label: 'Actual Size', accelerator: 'CmdOrCtrl+0', ...display, click: () => actions.zoom('reset') }, + { label: 'Zoom In', accelerator: 'CmdOrCtrl+Plus', ...display, click: () => actions.zoom('in') }, + { label: 'Zoom Out', accelerator: 'CmdOrCtrl+-', ...display, click: () => actions.zoom('out') }, sep, { role: 'togglefullscreen' }, sep, @@ -229,14 +235,17 @@ export function appMenuTemplate( }; const chatsSection = chatItems.length ? [sep, ...chatItems] : []; + // Not the `minimize` role: ⌘M reaches the menu before any window, and in a + // Quick Chat window panel it shrinks the panel to its pill instead. + const minimize: MenuItemConstructorOptions = { label: 'Minimize', accelerator: 'CmdOrCtrl+M', click: () => actions.minimize() }; // Built by hand rather than with the `windowMenu` role: the role is not // extensible, and off macOS it is the one that carries Close. const window: MenuItemConstructorOptions = mac ? { role: 'window', - submenu: [{ role: 'minimize' }, { role: 'zoom' }, ...chatsSection, sep, { role: 'front' }] + submenu: [minimize, { role: 'zoom' }, ...chatsSection, sep, { role: 'front' }] } - : { label: 'Window', submenu: [{ role: 'minimize' }, ...chatsSection] }; + : { label: 'Window', submenu: [minimize, ...chatsSection] }; if (!mac) return [file, edit, view, chat, window]; diff --git a/src/desktop/browser-host/index.ts b/src/desktop/browser-host/index.ts index feb7bae0..0ada7a1d 100644 --- a/src/desktop/browser-host/index.ts +++ b/src/desktop/browser-host/index.ts @@ -105,6 +105,10 @@ export interface BrowserHostDeps { readArcSidebar?(): Promise<{ tabs: ArcSidebarTab[] } | { error: string }>; /** Tests shorten the launch wait. */ launchWaitMs?: number; + /** Tests shorten every action's deadline, the liveness check after one runs out, and the wait for a restarted extension. */ + actionTimeoutMs?: number; + aliveProbeMs?: number; + restartWaitMs?: number; } export interface BrowserHost { @@ -132,6 +136,10 @@ export interface BrowserHost { /** How long a peek may hold "Ask about this window" up. */ const PEEK_TIMEOUT_MS = 1_500; +/** After an action ran out of time: how long the extension has to answer a cheap check that it still listens at all. */ +const ALIVE_PROBE_MS = 5_000; +/** How long an extension Stem restarted has to connect again. */ +const RESTART_WAIT_MS = 15_000; /** A tab's title and its window's, one cut short or added to by the browser. */ export function sameTitle(page: string, window: string): boolean { @@ -140,6 +148,13 @@ export function sameTitle(page: string, window: string): boolean { return a.length >= 3 && b.length >= 3 && (a.includes(b) || b.includes(a)); } +/** A connection's profile for the log: the extension's profile id, cut short ("none" for a pre-0.7.0 extension, which sends none). */ +export function profileTag(key: string | null): string | null { + if (!key) return null; + const at = key.lastIndexOf('#'); + return at >= 0 ? key.slice(at + 1, at + 9) : 'none'; +} + /** "Google Chrome" ~ "Chrome", "Brave Browser" ~ "Brave": the window's app and the host's name for it. */ export function sameBrowser(windowApp: string, hostName: string): boolean { const norm = (s: string) => s.toLowerCase().replace(/\.app$|\.exe$/, '').replace(/[^a-z0-9]+/g, ' ').replace(/\b(google|microsoft|browser)\b/g, '').trim(); @@ -155,6 +170,13 @@ interface Conn { appPath: string; appName: string; version?: string; + /** HostHello.startedAt: which of two hosts claiming one profile is the newer. 0 when the host did not say. */ + startedAt: number; + /** Another connection of the same profile took this one's place. */ + replaced?: boolean; + /** When the extension said hello, and when it last sent anything: for the log when the link goes quiet or drops. */ + helloAt?: number; + heardAt?: number; pending: Map void>; /** * A sandboxed browser's relay (relay.ts), by its id: an upload's files go to @@ -367,6 +389,10 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { const paths = deps.paths ?? browserInstallPaths(); const launch = deps.launch ?? ((app: string) => defaultLaunch(app, platform)); const launchWaitMs = deps.launchWaitMs ?? LAUNCH_WAIT_MS; + const aliveProbeMs = deps.aliveProbeMs ?? ALIVE_PROBE_MS; + const restartWaitMs = deps.restartWaitMs ?? RESTART_WAIT_MS; + /** One restart per stuck connection, however many of its actions ran out of time. */ + const restarting = new WeakMap>(); const openWith = deps.openWith ?? ((app: string | null, target: string) => defaultOpenWith(app, target, platform)); /** A browser Stem knows, or on Linux an AppImage that vouches for itself. */ const mayLaunch = (app: string): boolean => launchableBrowser(app, platform) || (platform === 'linux' && launchableAppImage(app)); @@ -394,6 +420,8 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { * remembered again, so its hellos are refused until Set up runs again. */ const removed = new Set(); + /** Profiles a stale native host was already refused for, logged once each: an old one retries every two seconds. */ + const staleLogged = new Set(); const send = (conn: Conn, message: ToExtension): boolean => { const frame = encodeFrame(message); @@ -485,13 +513,35 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { typeof message.profileId === 'string' && /^[A-Za-z0-9-]{8,64}$/.test(message.profileId) ? message.profileId : null; // An extension from before 0.7.0 sends no profile id: one entry per app, as then. const key = profile ? `${conn.appPath}#${profile}` : conn.appPath; - log('browser-host', 'the extension said hello', { browser: conn.appName, version: conn.version, profile: !!profile }); + const old = conns.get(key); + if (old && old !== conn && conn.startedAt < old.startedAt) { + // A native host older than the one connected for this profile: the + // browser left it running when the extension's worker restarted, and it + // replays the old worker's hello on every retry. Letting it in would + // throw the live connection off, whose host would then retry and throw + // this one off, every two seconds (2026-11-02). Told to quit instead. + if (!staleLogged.has(key)) { + staleLogged.add(key); + log('browser-host', 'refused a stale native host; a newer one has this profile', { browser: conn.appName }); + } + conn.replaced = true; + send(conn, { type: 'replaced' }); + conn.socket.end(); + return; + } + conn.helloAt = Date.now(); + log('browser-host', 'the extension said hello', { browser: conn.appName, version: conn.version, profile: profileTag(key) }); if (conn.key !== key) { if (conn.key && conns.get(conn.key) === conn) conns.delete(conn.key); - // A browser that restarted connects again before the old socket is - // noticed gone: the new connection wins. - const old = conns.get(key); - if (old && old !== conn) old.socket.destroy(); + // A browser that restarted, or an extension whose worker restarted, + // connects again before the old socket is noticed gone: the newer + // connection wins, and the old host is told to stop retrying. + if (old && old !== conn) { + old.replaced = true; + send(old, { type: 'replaced' }); + old.socket.end(); + setTimeout(() => old.socket.destroy(), 1_000).unref?.(); + } conn.key = key; conns.set(key, conn); } @@ -513,6 +563,7 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { } function onFrame(conn: Conn, message: FromExtension): void { + conn.heardAt = Date.now(); if (message.type === 'hello') { void onHello(conn, message); return; @@ -590,12 +641,27 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { } function dropConn(conn: Conn): void { + // Unnoticed until 2026-11-03: a profile that went quiet left no trace of + // whether its link had dropped or stayed up with nobody answering. + if (conn.key) { + log('browser-host', 'a browser link closed', { + browser: conn.appName, + profile: profileTag(conn.key), + replaced: !!conn.replaced, + connectedS: conn.helloAt ? Math.round((Date.now() - conn.helloAt) / 1000) : null, + unfinishedActions: conn.pending.size + }); + } for (const settle of conn.pending.values()) { settle({ ok: false, - error: - `${conn.appName} disconnected from Stem during the action (it quit, or the extension reloaded). ` + - 'The action may or may not have happened: check the page before repeating it.' + error: conn.replaced + ? `Stem's link to ${conn.appName} was handed to a newer one from the same profile during the action ` + + '(the extension restarted; nothing the user did, and the browser is still connected). ' + + 'The action may or may not have happened: check the page, then carry on.' + : `Stem lost its link to ${conn.appName} during the action (the browser quit, or its Stem extension restarted). ` + + 'The action may or may not have happened: check the page before repeating it, and try once more ' + + 'before asking the user to do anything.' }); } conn.pending.clear(); @@ -644,7 +710,15 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { } clearTimeout(timer); socket.off('data', onText); - const conn: Conn = { socket, key: null, appPath: claimed.appPath, appName: claimed.appName, pending: new Map(), sandbox: claimed.appPath }; + const conn: Conn = { + socket, + key: null, + appPath: claimed.appPath, + appName: claimed.appName, + startedAt: 0, + pending: new Map(), + sandbox: claimed.appPath + }; socket.on('close', () => dropConn(conn)); // What the Node host tells the extension once it reaches Stem. send(conn, { type: 'host', connected: true }); @@ -683,7 +757,7 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { const reader = new FrameReader(); let conn: Conn | null = null; /** Between the host's hello and its proof: what it claimed, and the nonce it must answer. */ - let pending: { appPath: string; appName: string; nonce: string } | null = null; + let pending: { appPath: string; appName: string; startedAt: number; nonce: string } | null = null; const hello = setTimeout(() => socket.destroy(), 5000); hello.unref?.(); socket.on('data', (chunk: Buffer) => { @@ -724,6 +798,7 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { pending = { appPath: h.appPath, appName: typeof h.appName === 'string' && h.appName ? h.appName : 'Browser', + startedAt: typeof h.startedAt === 'number' && Number.isFinite(h.startedAt) && h.startedAt > 0 ? h.startedAt : 0, nonce: newNonce() }; socket.write(encodeFrame({ type: 'server-hello', nonce: pending.nonce, proof: handshakeProof(config.token, 'stem', h.nonce) })); @@ -737,11 +812,11 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { return; } clearTimeout(hello); - const { appPath, appName } = pending; + const { appPath, appName, startedAt } = pending; pending = null; // Which profile this is arrives with the extension's own hello, // right behind (the native host replays it on every connection). - conn = { socket, key: null, appPath, appName, pending: new Map() }; + conn = { socket, key: null, appPath, appName, startedAt, pending: new Map() }; continue; } if (conn) onFrame(conn, message as FromExtension); @@ -856,13 +931,14 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { return new Promise((resolve) => { const timer = setTimeout(() => { conn.pending.delete(request.requestId); - resolve({ - ok: false, - error: - `${conn.appName} did not finish the action in time. It may or may not have happened: check the page ` + - '(snapshot) before repeating it.' + log('browser-host', 'an action ran out of time', { + browser: conn.appName, + profile: profileTag(conn.key), + action: action.kind, + lastHeardS: conn.heardAt ? Math.round((Date.now() - conn.heardAt) / 1000) : null }); - }, actionTimeoutMs(action)); + void timedOut(conn).then((error) => resolve({ ok: false, error })); + }, deps.actionTimeoutMs ?? actionTimeoutMs(action)); conn.pending.set(request.requestId, (r) => { clearTimeout(timer); resolve(r); @@ -876,6 +952,89 @@ export function createBrowserHost(deps: BrowserHostDeps): BrowserHost { }); } + /** + * An action ran out of time. A slow or stuck page is the usual reason, and + * the model checks the page and carries on. But when the extension does not + * even answer a peek, its worker is wedged: every action in that profile, + * a bare `tabs` included, would time out the same way (2026-11-03, a jbrow + * profile went quiet after twelve idle minutes and the model handed the + * form back to the user). Stem restarts the extension then, and says + * whether it came back. + */ + async function timedOut(conn: Conn): Promise { + const slow = + `${conn.appName} did not finish the action in time. It may or may not have happened: check the page ` + + '(snapshot) before repeating it.'; + const key = conn.key; + if (!key || conn.replaced || conns.get(key) !== conn) return slow; + const pending = restarting.get(conn); + if (pending) return pending; + if (await answers(conn, aliveProbeMs)) { + log('browser-host', 'the extension still answers; the action itself was slow', { browser: conn.appName, profile: profileTag(key) }); + return slow; + } + if (conns.get(key) !== conn) return slow; + const restart = restartStuck(conn, key); + restarting.set(conn, restart); + return restart; + } + + /** Whether the extension answers a peek (whatever it says) within `ms`. */ + function answers(conn: Conn, ms: number): Promise { + return new Promise((resolve) => { + const id = `alive-${randomUUID()}`; + const timer = setTimeout(() => { + conn.pending.delete(id); + resolve(false); + }, ms); + conn.pending.set(id, () => { + clearTimeout(timer); + resolve(true); + }); + if (!send(conn, { type: 'peek', id })) { + clearTimeout(timer); + conn.pending.delete(id); + resolve(false); + } + }); + } + + async function restartStuck(conn: Conn, key: string): Promise { + log('browser-host', 'the extension stopped answering; restarting it', { browser: conn.appName }); + const back = new Promise((resolve) => { + const wake = (): void => { + const c = conns.get(key); + if (!c || c === conn) return; + cleanup(); + resolve(true); + }; + const timer = setTimeout(() => { + cleanup(); + resolve(false); + }, restartWaitMs); + const cleanup = (): void => { + clearTimeout(timer); + connectWaiters.delete(wake); + }; + connectWaiters.add(wake); + }); + send(conn, { type: 'reload' }); + if (await back) { + log('browser-host', 'the restarted extension is back', { browser: conn.appName }); + return ( + `${conn.appName}'s Stem extension had stopped answering (nothing the user did), so Stem restarted it, and it ` + + 'is connected again. The action did not finish: take a new snapshot of the tab (tab ids stay the same) and ' + + 'carry on yourself.' + ); + } + log('browser-host', 'the restarted extension did not come back', { browser: conn.appName }); + return ( + `${conn.appName}'s Stem extension stopped answering and did not come back after Stem restarted it. Try once ` + + 'more. If it fails again and another browser profile is open, a page that needs no sign-in can be done ' + + `there; otherwise ask the user to quit and reopen ${conn.appName}.` + ); + } + function peekConn(conn: Conn): Promise<{ url: string; title: string } | null> { return new Promise((resolve) => { const id = `peek-${randomUUID()}`; diff --git a/src/desktop/browser-host/native-host-main.ts b/src/desktop/browser-host/native-host-main.ts index e10c55e7..194eb0f1 100644 --- a/src/desktop/browser-host/native-host-main.ts +++ b/src/desktop/browser-host/native-host-main.ts @@ -23,7 +23,10 @@ // // It never exits on its own while the browser keeps the port open: with Stem // not running it retries the socket every two seconds, and that open port is -// what keeps the extension's service worker alive to see Stem come back. +// what keeps the extension's service worker alive to see Stem come back. The +// one exception is Stem saying `replaced`: a newer host of the same profile +// holds the link (the browser left this one running when the extension's +// worker restarted), so this one stops retrying and exits. // // No Electron imports: this runs as plain Node. @@ -146,6 +149,16 @@ async function spoolDownloads(downloads: ExtensionDownload[], spoolDir: string): return out; } +/** Is this frame the desktop's `replaced`: another host of this profile has the link? */ +export function isReplaced(body: Buffer): boolean { + if (body.length > 64) return false; + try { + return (JSON.parse(body.toString('utf8')) as { type?: unknown })?.type === 'replaced'; + } catch { + return false; + } +} + /** Is this frame the desktop's server-hello, with a proof under the token for our nonce? */ export function serverProved(token: string, nonce: string, body: Buffer): boolean { let m: { type?: unknown; nonce?: unknown; proof?: unknown }; @@ -160,7 +173,10 @@ export function serverProved(token: string, nonce: string, body: Buffer): boolea function main(): void { const config = JSON.parse(readFileSync(process.argv[2] ?? '', 'utf8')) as HostConfig; const browser = browserOf(parentCommand()); + const startedAt = Date.now(); let socket: Socket | null = null; + /** Stem handed this profile to a newer host: no more retries. */ + let replaced = false; let connected = false; /** The extension's latest hello, replayed to every new socket connection. */ let hello: Buffer | null = null; @@ -188,7 +204,7 @@ function main(): void { /** Set once the desktop proved it holds the token; until then nothing is relayed either way. */ let verified = false; s.on('connect', () => { - const first: HostHello = { type: 'host-hello', nonce, ...browser }; + const first: HostHello = { type: 'host-hello', nonce, ...browser, startedAt }; s.write(encodeFrame(first)); }); s.on('data', (chunk: Buffer) => { @@ -209,6 +225,14 @@ function main(): void { } const head = Buffer.alloc(4); head.writeUInt32LE(body.length, 0); + if (isReplaced(body)) { + log('a newer host of this profile has the link to Stem; exiting'); + replaced = true; + s.destroy(); + // Passed on so a still-running extension skips its quick reconnects. + process.stdout.write(Buffer.concat([head, body]), () => process.exit(0)); + return; + } toExtension(Buffer.concat([head, body])); } } catch (e) { @@ -219,6 +243,7 @@ function main(): void { s.on('error', () => undefined); s.on('close', () => { if (socket === s) socket = null; + if (replaced) return; status(false); setTimeout(connect, RETRY_MS).unref?.(); }); diff --git a/src/desktop/computer-host/index.ts b/src/desktop/computer-host/index.ts index 8497dd3d..ac23a73a 100644 --- a/src/desktop/computer-host/index.ts +++ b/src/desktop/computer-host/index.ts @@ -376,6 +376,26 @@ export function createComputerHost(deps: ComputerHostDeps): ComputerHost { }; } + /** + * Every helper leaves Stem's own windows out (the agent must never click its + * own approval cards), and says nothing about it. A model reading the list then + * concludes Stem is not open — the Fio chat told the user "Stem has no window" + * while it was on screen, after an `open -a Stem` that did nothing. Say it. + */ + function aboutStemItself(action: DeviceComputerRequest['action'], result: DeviceComputerResult): DeviceComputerResult { + const why = + "Stem's own windows are never listed and cannot be controlled with this tool, so this says nothing about whether " + + "Stem is open (it is: you are talking through it). Change Stem's settings with your own tools (for an MCP server, " + + 'edit_mcp_server), or tell the user exactly what to click.'; + if (action.kind === 'list_windows' && result.ok) { + return { ...result, text: result.text ? `${result.text}\n${why}` : why }; + } + if (action.kind === 'select_window' && !result.ok && action.app !== undefined && /\bstem\b/i.test(action.app)) { + return { ok: false, error: why }; + } + return result; + } + /** A reply that names the run's window (or its absence) relabels the banner. */ function noteTarget(r: Run, result: DeviceComputerResult): void { if (!result.ok || result.target === undefined || run !== r) return; @@ -430,7 +450,7 @@ export function createComputerHost(deps: ComputerHostDeps): ComputerHost { }; r!.inFlight = { requestId: request.requestId, fail: done }; void r!.helper.call(cmd, fields, timeout).then((reply) => { - let result = fromReply(reply); + let result = aboutStemItself(request.action, fromReply(reply)); noteTarget(r!, result); if (platformNote && result.ok && !r!.noted) { r!.noted = true; diff --git a/src/desktop/context-menu.ts b/src/desktop/context-menu.ts index e062b978..0789c612 100644 --- a/src/desktop/context-menu.ts +++ b/src/desktop/context-menu.ts @@ -1,4 +1,6 @@ -import { BrowserWindow, clipboard, Menu, type MenuItemConstructorOptions, type WebContents } from 'electron'; +import { BrowserWindow, clipboard, Menu, shell, type MenuItemConstructorOptions, type WebContents } from 'electron'; +import { appRelativeLink, linkFilePath, revealLabel, revealLink } from './open-link'; +import { SCRATCH_PREFIX } from '../shared/files-links'; import { saveImageToDownloads } from './save-image'; // A native right-click menu for page content: links (open/copy), selected text, @@ -22,63 +24,137 @@ async function imageSource(contents: WebContents, params: Electron.ContextMenuPa return typeof src === 'string' ? src : ''; } +/** + * What the menu does with a file on the server (desktop/local: files:open and + * files:download). `ref` is what GET /files/ takes. Set once at startup, so + * this file needs no server credentials of its own. + */ +export interface ServerFileActions { + open(ref: string): Promise; + reveal(ref: string): Promise; +} +let serverFiles: ServerFileActions | null = null; + +export function setServerFileActions(actions: ServerFileActions | null): void { + serverFiles = actions; +} + +/** The chat a right-clicked `scratch/…` link belongs to (renderer/mdx/render.tsx ScratchLink). */ +async function linkThread(contents: WebContents, params: Electron.ContextMenuParams): Promise { + const zoom = contents.getZoomFactor(); + const id: unknown = await contents.executeJavaScript( + `(() => { const el = document.elementFromPoint(${params.x / zoom}, ${params.y / zoom}); + return el?.closest('a[data-thread]')?.getAttribute('data-thread') ?? ''; })()` + ); + return typeof id === 'string' && /^[A-Za-z0-9_-]{1,128}$/.test(id) ? id : ''; +} + +/** + * A relative `files/…` or `scratch/…` link resolves against the app's own page, + * so its URL names a path inside Stem.app. The file is on the server: answer + * what GET /files/ takes for it. Null for a link into the app's own folder + * that names no such file; undefined for any other link. + */ +async function serverFileRef(contents: WebContents, params: Electron.ContextMenuParams): Promise { + if (!params.linkURL) return undefined; + const link = appRelativeLink(params.linkURL, contents.getURL()); + if (!link.inApp) return undefined; + if (link.files) return link.files; + if (!link.scratch) return null; + const thread = await linkThread(contents, params).catch(() => ''); + return thread ? `${SCRATCH_PREFIX}${thread}/${link.scratch}` : null; +} + export function installContextMenu(contents: WebContents, openExternalUrl: (url: string) => void): void { contents.on('context-menu', (_event, params) => { - const items: MenuItemConstructorOptions[] = []; + void serverFileRef(contents, params) + .then((ref) => showMenu(contents, params, ref, openExternalUrl)) + .catch((e) => console.warn('[context-menu] could not show the menu', e)); + }); +} - if (params.linkURL) { - items.push( - { label: 'Open Link', click: () => openExternalUrl(params.linkURL) }, - { label: 'Copy Link Address', click: () => clipboard.writeText(params.linkURL) }, - { type: 'separator' } - ); - } +function showMenu( + contents: WebContents, + params: Electron.ContextMenuParams, + serverRef: string | null | undefined, + openExternalUrl: (url: string) => void +): void { + const items: MenuItemConstructorOptions[] = []; - if (params.mediaType === 'image') { - items.push({ label: 'Copy Image', click: () => contents.copyImageAt(params.x, params.y) }); - // Chat pictures are data URLs; anything else goes through Chromium's own download. - items.push({ - label: 'Save Image to Downloads', - click: () => { - void imageSource(contents, params) - .then((src) => { - if (src.startsWith('data:image/')) return saveImageToDownloads(src, params.altText); - if (src) contents.downloadURL(src); - }) - .catch((e) => console.warn('[context-menu] could not save the image', e)); - } - }); - items.push({ type: 'separator' }); - } + const filePath = + serverRef === undefined && params.linkURL.startsWith('file:') ? linkFilePath(params.linkURL) : undefined; + if (serverRef && serverFiles) { + // A file on the server: fetch it, then open it or show it in Downloads. + const act = (fn: (ref: string) => Promise) => () => { + void fn(serverRef).catch((e) => console.warn('[context-menu] could not fetch the file', e)); + }; + items.push( + { label: 'Open', click: act(serverFiles.open) }, + { label: revealLabel(), click: act(serverFiles.reveal) }, + { type: 'separator' } + ); + } else if (serverRef !== undefined) { + // A link into the app's own folder: nothing of the user's to open or show. + } else if (filePath) { + // A file link from a reply (an agent naming the CSV it just wrote). + items.push( + { label: 'Open', click: () => openExternalUrl(params.linkURL) }, + { label: revealLabel(), click: () => revealLink(shell, params.linkURL) }, + { label: 'Copy Path', click: () => void clipboard.writeText(filePath) }, + { type: 'separator' } + ); + } else if (params.linkURL) { + items.push( + { label: 'Open Link', click: () => openExternalUrl(params.linkURL) }, + { label: 'Copy Link Address', click: () => void clipboard.writeText(params.linkURL) }, + { type: 'separator' } + ); + } - if (params.isEditable) { - for (const suggestion of params.dictionarySuggestions.slice(0, 4)) { - items.push({ label: suggestion, click: () => contents.replaceMisspelling(suggestion) }); - } - if (params.misspelledWord) { - items.push( - { - label: 'Add to Dictionary', - click: () => contents.session.addWordToSpellCheckerDictionary(params.misspelledWord) - }, - { type: 'separator' } - ); + if (params.mediaType === 'image') { + items.push({ label: 'Copy Image', click: () => contents.copyImageAt(params.x, params.y) }); + // Chat pictures are data URLs; anything else goes through Chromium's own download. + items.push({ + label: 'Save Image to Downloads', + click: () => { + void imageSource(contents, params) + .then((src) => { + if (src.startsWith('data:image/')) return saveImageToDownloads(src, params.altText); + if (src) contents.downloadURL(src); + }) + .catch((e) => console.warn('[context-menu] could not save the image', e)); } + }); + items.push({ type: 'separator' }); + } + + if (params.isEditable) { + for (const suggestion of params.dictionarySuggestions.slice(0, 4)) { + items.push({ label: suggestion, click: () => contents.replaceMisspelling(suggestion) }); + } + if (params.misspelledWord) { items.push( - { role: 'cut', enabled: params.editFlags.canCut }, - { role: 'copy', enabled: params.editFlags.canCopy }, - { role: 'paste', enabled: params.editFlags.canPaste }, - { type: 'separator' }, - { role: 'selectAll' } + { + label: 'Add to Dictionary', + click: () => contents.session.addWordToSpellCheckerDictionary(params.misspelledWord) + }, + { type: 'separator' } ); - } else if (params.selectionText.trim()) { - items.push({ role: 'copy' }); } + items.push( + { role: 'cut', enabled: params.editFlags.canCut }, + { role: 'copy', enabled: params.editFlags.canCopy }, + { role: 'paste', enabled: params.editFlags.canPaste }, + { type: 'separator' }, + { role: 'selectAll' } + ); + } else if (params.selectionText.trim()) { + items.push({ role: 'copy' }); + } - while (items.length > 0 && items[items.length - 1].type === 'separator') items.pop(); - if (items.length === 0) return; + while (items.length > 0 && items[items.length - 1].type === 'separator') items.pop(); + if (items.length === 0) return; - const window = BrowserWindow.fromWebContents(contents) ?? undefined; - Menu.buildFromTemplate(items).popup({ window }); - }); + const window = BrowserWindow.fromWebContents(contents) ?? undefined; + Menu.buildFromTemplate(items).popup({ window }); } diff --git a/src/desktop/file-transfer.ts b/src/desktop/file-transfer.ts index 4e8fb4a6..51de6963 100644 --- a/src/desktop/file-transfer.ts +++ b/src/desktop/file-transfer.ts @@ -127,7 +127,7 @@ async function upload( try { res = await answered; } catch (e) { - throw new Error(`“${name}” could not be sent to Stem's server: ${String((e as Error)?.message ?? e)}`); + throw new Error(`“${name}” could not be sent to Stem's server: ${String((e as Error)?.message ?? e)}`, { cause: e }); } const text = await readBody(res); if (res.statusCode !== 200) { @@ -196,7 +196,7 @@ export async function downloadFile( try { res = await answered; } catch (e) { - throw new Error(`“${name}” could not be fetched from Stem's server: ${String((e as Error)?.message ?? e)}`); + throw new Error(`“${name}” could not be fetched from Stem's server: ${String((e as Error)?.message ?? e)}`, { cause: e }); } if (res.statusCode !== 200) { const problem = problemIn(await readBody(res), `HTTP ${res.statusCode}`); @@ -209,7 +209,7 @@ export async function downloadFile( await pipeline(res, out); } catch (e) { await rm(path, { force: true }).catch(() => undefined); - throw new Error(`“${name}” did not finish downloading: ${String((e as Error)?.message ?? e)}`); + throw new Error(`“${name}” did not finish downloading: ${String((e as Error)?.message ?? e)}`, { cause: e }); } return path; } diff --git a/src/desktop/index.ts b/src/desktop/index.ts index 45ddb11a..2e832d65 100644 --- a/src/desktop/index.ts +++ b/src/desktop/index.ts @@ -13,15 +13,18 @@ import { shell } from 'electron'; import { dirname, join } from 'node:path'; -import { mkdirSync } from 'node:fs'; +import { spawn } from 'node:child_process'; +import { appendFileSync, mkdirSync } from 'node:fs'; import { IN_WINDOW_SHORTCUTS, installAppMenu, updateAppMenu } from './app-menu'; import { installContextMenu } from './context-menu'; -import { openLink } from './open-link'; +import { openLink, setFileViewer } from './open-link'; +import { openInViewer, registerViewerScheme } from './viewer'; +import { imagePreviewDataUrl } from '../server/pi/attachments'; import { electronHost } from './host'; import { setHost } from '../server/host'; import { startServer, type ServerHandle } from '../server'; import { log } from '../server/log'; -import { resolveProfileOverride } from '../server/workspace/paths'; +import { logFilePath, resolveProfileOverride } from '../server/workspace/paths'; import { bindServerChannels, handleLocal } from './ipc-bridge'; import { registerLocalIpc } from './local'; import { createMcpHost, type McpHost } from './mcp-host'; @@ -43,6 +46,7 @@ import { createPresenceHeartbeat, type PresenceHeartbeat } from './presence'; import { createServerProxy, type ServerProxy } from './proxy'; import { clientCredentials, resolveServerUrl } from './server-endpoint'; import { readClientSettings, seedReleaseNotesMarker } from './settings'; +import { applyZoom, installZoom } from './zoom'; import { currentThemeState, resolveWindowBackground, watchThemes } from './themes'; import { createUpdates } from './updates'; import { createQuickChat } from './quickchat'; @@ -150,6 +154,10 @@ if (process.env.ELECTRON_RENDERER_URL) { // a Wayland session. Must be set here: switches are read at Chromium startup. enableGlobalShortcutPortal(); +// Stem's file viewer serves its page on its own scheme (desktop/viewer.ts): +// privileges can be granted only before the app is ready. +registerViewerScheme(); + // Test seam: when STEM_E2E is set the server swaps in the hermetic FakeBackend. // On this side it only suppresses the tray, to keep the harness's window/process // accounting deterministic. @@ -264,6 +272,7 @@ function createWindow(hidden = false): void { if (BACKGROUND && !hidden) mainWindow.showInactive(); installNavigationGuards(mainWindow); + installZoom(mainWindow, isMac); // The renderer's HTML Stem otherwise clobbers the window title on // load; when running an alternate profile, keep the label pinned so the demo @@ -466,6 +475,13 @@ function reportClientVersion(): void { } app.whenReady().then(async () => { + // A file a reply links opens in Stem's own viewer when it can show it. + setFileViewer((path) => + openInViewer(path, { + heicToDataUrl: imagePreviewDataUrl, + anyWindow: () => mainWindow ?? BrowserWindow.getAllWindows()[0] ?? null + }) + ); // Strict CSP for the renderer in production: only self, no remote/inline // script. Skipped in dev so the Vite dev server / HMR can run. Installed // before any window is created, so nothing can load without it. @@ -474,7 +490,7 @@ app.whenReady().then(async () => { callback({ responseHeaders: { ...details.responseHeaders, - 'Content-Security-Policy': ["default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:"] + 'Content-Security-Policy': ["default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:; media-src 'self' blob:"] } }); }); @@ -491,7 +507,11 @@ app.whenReady().then(async () => { { command: runMenuCommand, toggleQuickChat: () => quickChat.toggle(), - checkForUpdates: () => void checkForUpdatesFromMenu() + minimize: () => { + if (!quickChat.minimizeFocused()) BrowserWindow.getFocusedWindow()?.minimize(); + }, + checkForUpdates: () => void checkForUpdatesFromMenu(), + zoom: applyZoom }, { canCheckForUpdates: updates.status().mode !== 'none' } ); @@ -735,7 +755,8 @@ app.whenReady().then(async () => { recorder, mirrorHost, claudeExport: claudeExport!, - themeChanged + themeChanged, + cachedThread: (threadId) => proxy?.cachedThread(threadId) }); // A theme file saved, added or removed in the themes folder is the same event // as picking one: every window repaints and the picker re-lists. @@ -849,8 +870,10 @@ app.whenReady().then(async () => { // it a window to drain in-flight work, then we exit for real (shutdown has its // own SIGKILL backstop). let quitting = false; +let quitWatchdog: NodeJS.Timeout | null = null; app.on('before-quit', (event) => { if (quitting) return; + armQuitWatchdog(); updates.close(); presence?.close(); proxy?.close(); @@ -883,6 +906,77 @@ app.on('will-quit', () => { globalShortcut.unregisterAll(); }); +// A quit that never finishes leaves Stem half-alive: its hosts are closed but +// the process stays, and the only way out is Force Quit. Seen on the Mac after +// long uptimes, with the hosts' close lines in the log and nothing after — so +// whatever holds the process is past our own teardown (a window that never +// finishes closing, a native handle). Past the deadline, write down what is +// still alive for the next diagnosis and exit anyway. The embedded server gets +// longer: its drain is legitimate work with its own SIGKILL backstop. +const QUIT_DEADLINE_MS = 8_000; +const QUIT_DEADLINE_WITH_SERVER_MS = 30_000; + +function armQuitWatchdog(): void { + if (quitWatchdog) return; + const startedAt = Date.now(); + log('app', 'quitting'); + armQuitSentinel(server ? QUIT_DEADLINE_WITH_SERVER_MS : QUIT_DEADLINE_MS); + // Not unref'd: holding the loop open is what lets it fire when nothing else does. + quitWatchdog = setTimeout( + () => { + try { + const windows = BrowserWindow.getAllWindows().map((w) => ({ + title: w.getTitle(), + visible: w.isVisible(), + url: w.webContents.isDestroyed() ? null : w.webContents.getURL().slice(0, 120), + crashed: w.webContents.isDestroyed() ? null : w.webContents.isCrashed() + })); + const line = `${new Date().toISOString()} [app] quit stalled, exiting anyway ${JSON.stringify({ + waitedMs: Date.now() - startedAt, + windows, + resources: process.getActiveResourcesInfo() + })}\n`; + // Sync on purpose: the async logger's queue would die with the exit below. + appendFileSync(logFilePath(), line); + } catch { + // quiet: the report is a nicety; the exit below is the point. + } + app.exit(0); + }, + server ? QUIT_DEADLINE_WITH_SERVER_MS : QUIT_DEADLINE_MS + ); +} + +// The timer above needs this process's main thread; a quit wedged in native +// code (or a JS loop) never runs it. So a detached shell watches from outside: +// a few seconds past the in-process deadline, if this pid is still here it +// samples every thread's native stack into quit-stall-sample.txt beside +// stem.log (macOS), notes it in stem.log, and kills the process — what the +// user would otherwise do by hand with Force Quit, minus the evidence loss. +function armQuitSentinel(deadlineMs: number): void { + if (process.platform === 'win32') return; + try { + const logFile = logFilePath(); + const sampleFile = join(dirname(logFile), 'quit-stall-sample.txt'); + const graceS = Math.ceil(deadlineMs / 1000) + 4; + const script = [ + `sleep ${graceS}`, + 'kill -0 "$P" 2>/dev/null || exit 0', + '[ -x /usr/bin/sample ] && /usr/bin/sample "$P" 3 -file "$SAMPLE" >/dev/null 2>&1', + 'printf "%s [app] quit wedged, killed by the sentinel (native stacks in %s)\\n" "$(date -u +%Y-%m-%dT%H:%M:%SZ)" "$SAMPLE" >> "$LOG"', + 'kill -9 "$P" 2>/dev/null' + ].join('; '); + const child = spawn('/bin/sh', ['-c', script], { + detached: true, + stdio: 'ignore', + env: { P: String(process.pid), LOG: logFile, SAMPLE: sampleFile, PATH: '/usr/bin:/bin' } + }); + child.unref(); + } catch { + // quiet: no sentinel just means a wedged quit needs Force Quit, as before. + } +} + app.on('window-all-closed', () => { // Dead-in-practice by design: the overlay + HUD windows are created at startup // and only ever hidden, so this event can't fire while they exist. Closing the diff --git a/src/desktop/ipc-bridge.ts b/src/desktop/ipc-bridge.ts index 6c362468..d728ecc2 100644 --- a/src/desktop/ipc-bridge.ts +++ b/src/desktop/ipc-bridge.ts @@ -35,11 +35,16 @@ const LOCAL_IPC_ARGS: Record = { 'files:preview': [a.string], 'files:previewData': [a.string, a.optional(a.nullish(a.string)), a.optional(a.nullish(a.string))], 'files:download': [a.string], + 'attachments:stage': [a.object], + 'files:open': [a.string], + 'scratch:open': [a.string, a.string], 'link:open': [a.string], 'image:saveToDownloads': [a.string, a.string], + 'audio:saveToDownloads': [a.string, a.string], 'image:copy': [a.string], 'cfolders:reveal': [a.string], 'client:pair': [a.string, a.string], + 'chats:cached': [a.string], 'stem:exportState': [a.object], 'settings:updateReleaseNotes': [a.object], 'settings:updateUpdates': [a.object], @@ -86,6 +91,9 @@ const LOCAL_IPC_ARGS: Record = { 'quickchat:handoff': [a.object], // Whether the compact bar keeps room for the window chip ("Ask about this window"). 'quickchat:compact': [a.optional(a.boolean)], + // A window panel's tab, by the id main gave it. + 'quickchat:switchTab': [a.string], + 'quickchat:closeTab': [a.string], // The System Settings pane the chip's missing-permission link opens. 'quickchat:openPrivacy': [a.oneOf(['screen', 'accessibility'])], // The chip's Connect / Set up: the panel tab to open, and where in it (checked again in the handler). diff --git a/src/desktop/local/index.ts b/src/desktop/local/index.ts index 052ebecb..c796ec61 100644 --- a/src/desktop/local/index.ts +++ b/src/desktop/local/index.ts @@ -1,8 +1,12 @@ -import { clipboard, dialog, nativeImage, shell, type BrowserWindow } from 'electron'; -import { stat } from 'node:fs/promises'; +import { clipboard, ClipboardItem, dialog, nativeImage, shell, type BrowserWindow } from 'electron'; +import { execFile } from 'node:child_process'; +import { mkdtemp, stat } from 'node:fs/promises'; +import { tmpdir } from 'node:os'; import { join } from 'node:path'; +import { setServerFileActions } from '../context-menu'; import { handleLocal } from '../ipc-bridge'; -import { openLink } from '../open-link'; +import { openFilesItem, openLink } from '../open-link'; +import { filesPlaceRel, isSafeRel, SCRATCH_PREFIX } from '../../shared/files-links'; import { ensureFilesRoot, filePathWithin } from '../../server/files/store'; import { imagePreviewDataUrl, imagePreviewFromBytes } from '../../server/pi/attachments'; import { connectedFolderPath } from '../../server/workspace/connected-folders'; @@ -12,8 +16,9 @@ import { exportState } from '../../server/workspace/state-transfer'; import { readClientIdentity, storedServerUrl } from '../client-store'; import { cancelDictation, dictationAudio, dictationLanguages, startDictation, stopDictation } from '../dictation'; import { downloadFile } from '../file-transfer'; +import { stageAttachment } from '../proxy'; import { markReleaseNotesRead, releaseNotesSnapshot } from '../release-notes'; -import { downloadsDir, saveImageToDownloads } from '../save-image'; +import { downloadsDir, saveAudioToDownloads, saveImageToDownloads } from '../save-image'; import { pairWithServer, useBuiltInServer, type ServerCredentials } from '../server-endpoint'; import { updateClientReleaseNotes, updateClientTheme, updateClientUpdates, withClientSettings } from '../settings'; import { currentThemeState, ensureThemesDir, listThemes } from '../themes'; @@ -36,6 +41,7 @@ import type { StateExportReport, ThemeSettings, ThemeState, + TurnAttachment, UpdatesSettings } from '../../shared/types'; @@ -113,6 +119,8 @@ export interface LocalIpcDeps { claudeExport: ClaudeExportHost; /** The theme changed: push the new state to all three windows at once. */ themeChanged(state: ThemeState): void; + /** The offline cache's copy of a transcript (see ServerProxy.cachedThread). */ + cachedThread(threadId: string): unknown; } export function registerLocalIpc(deps: LocalIpcDeps): void { @@ -140,6 +148,12 @@ export function registerLocalIpc(deps: LocalIpcDeps): void { // whether it can be reached. handleLocal('client:connection', () => ({ reachable: deps.reachable() })); + // The offline cache's copy of one transcript, read off this disk. The sidebar + // shows it the moment a chat is clicked while the server's own answer is on + // its way — on a slow link, or one busy streaming two running chats, that + // round trip is seconds the person used to stare at the previous chat for. + handleLocal('chats:cached', (_e, threadId: string) => deps.cachedThread(threadId) ?? null); + // Settings → Server. Pairing is the whole act: the address and the credential // are written together, because a token means nothing to a server that never // issued it. Nothing re-points at runtime — the event stream, the bound channel @@ -391,7 +405,14 @@ export function registerLocalIpc(deps: LocalIpcDeps): void { * go, then show it there — the two halves of what "Download" means on a desktop. * Answers with the path it landed at, so the renderer can name it if it wants. */ - handleLocal('files:download', async (_e, rel: string): Promise => { + handleLocal('files:download', (_e, rel: string): Promise => downloadAndReveal(rel)); + // The mail composer's background upload: a file attached to a draft goes up + // to a remote server at once, so Send carries only its handle. Against the + // built-in server the server reads the path itself and nothing is copied. + handleLocal('attachments:stage', (_e, att: TurnAttachment): Promise | TurnAttachment => + deps.connection().remote ? stageAttachment(deps.credentials(), att) : att + ); + async function downloadAndReveal(rel: string): Promise { const saved = await downloadFile(deps.credentials(), rel, downloadsDir()); // Opening a Finder window is the one part of this a test run must not do: // STEM_BACKGROUND is set for exactly the runs that are forbidden to take @@ -399,15 +420,56 @@ export function registerLocalIpc(deps: LocalIpcDeps): void { // skipped under the same kind of flag for the same kind of reason). if (!process.env.STEM_BACKGROUND) shell.showItemInFolder(saved); return saved; + } + + /** + * A `files/…` link in a reply (shared/files-links.ts): fetch the file from the + * server's Files folder into a fresh temporary folder, then treat it as a + * clicked file: link, so a document opens and anything else is only shown. + * A temporary folder, not Downloads: a link clicked twice must not leave two + * copies where the user keeps their own files. + */ + handleLocal('files:open', async (_e, rel: string): Promise => { + // The renderer checked it too; this side is the one that has to hold. + const checked = filesPlaceRel(`files/${encodeURI(rel)}`); + if (!checked || checked !== rel) throw new Error('That is not a file in your Files folder.'); + await fetchAndOpen(rel); + }); + /** A `scratch/…` link: the same, from one chat's scratch folder (server/exec/scratch.ts scratchDownload). */ + handleLocal('scratch:open', async (_e, threadId: string, rel: string): Promise => { + if (!/^[A-Za-z0-9_-]{1,128}$/.test(threadId) || !isSafeRel(rel)) throw new Error('That is not a file in this chat.'); + await fetchAndOpen(`${SCRATCH_PREFIX}${threadId}/${rel}`); + }); + async function fetchAndOpen(rel: string): Promise { + const saved = await downloadFile(deps.credentials(), rel, await mkdtemp(join(tmpdir(), 'stem-files-'))); + // Mark it as downloaded, as a browser would, so macOS applies its usual + // checks to whatever opens it. quiet: without xattr the file still opens + // under the document allowlist below. + if (process.platform === 'darwin') { + const flags = `0081;${Math.floor(Date.now() / 1000).toString(16)};Stem;`; + await new Promise((done) => execFile('/usr/bin/xattr', ['-w', 'com.apple.quarantine', flags, saved], () => done())); + } + // Test runs must not open apps (see files:download). + if (!process.env.STEM_BACKGROUND) openFilesItem(shell, saved); + } + + // The right-click menu on a `files/…` or `scratch/…` link (desktop/context-menu.ts). + setServerFileActions({ + open: fetchAndOpen, + reveal: async (rel) => void (await downloadAndReveal(rel)) }); /** Save a chat image (the data URL the renderer is already showing) straight into Downloads. */ handleLocal('image:saveToDownloads', (_e, dataUrl: string, name: string) => saveImageToDownloads(dataUrl, name)); + handleLocal('audio:saveToDownloads', (_e, dataUrl: string, name: string) => saveAudioToDownloads(dataUrl, name)); - handleLocal('image:copy', (_e, dataUrl: string) => { + handleLocal('image:copy', async (_e, dataUrl: string) => { const img = nativeImage.createFromDataURL(dataUrl); if (img.isEmpty()) throw new Error('Not an image.'); - clipboard.writeImage(img); + // Electron 44 dropped clipboard.writeImage for the W3C-shaped write(). + // Re-encoded as PNG so a JPEG/WebP data URL lands as an image every app pastes. + const png = new Blob([new Uint8Array(img.toPNG())], { type: 'image/png' }); + await clipboard.write([new ClipboardItem({ 'image/png': png })]); }); /** diff --git a/src/desktop/open-link.ts b/src/desktop/open-link.ts index c497efc8..683c587b 100644 --- a/src/desktop/open-link.ts +++ b/src/desktop/open-link.ts @@ -1,6 +1,8 @@ import { fileURLToPath } from 'node:url'; -import { extname } from 'node:path'; +import { homedir } from 'node:os'; +import { extname, join } from 'node:path'; import type { Shell } from 'electron'; +import { filesPlaceRel, scratchRel } from '../shared/files-links'; // How a link clicked in the renderer leaves the app. Web, mail and phone links // go to the browser / mail client / FaceTime. file:// links (an agent pointing at a CSV it just @@ -28,7 +30,7 @@ const DOCUMENT_EXTENSIONS = new Set([ '.zip', ]); -export function classifyLink(url: string): LinkAction { +export function classifyLink(url: string, home: () => string = homedir): LinkAction { let parsed: URL; try { parsed = new URL(url); @@ -42,10 +44,23 @@ export function classifyLink(url: string): LinkAction { if (parsed.hostname) return { kind: 'ignore' }; let path: string; try { - path = fileURLToPath(parsed); + // file:///~/… is the renderer's spelling of a home-relative path + // (shared/file-paths.ts): only this side knows where home is. + if (parsed.pathname === '/~' || parsed.pathname.startsWith('/~/')) { + const rest = decodeURIComponent(parsed.pathname.slice(3)); + if (rest.split('/').includes('..')) return { kind: 'ignore' }; + path = join(home(), rest); // keeps a trailing slash: still a folder + } else { + path = fileURLToPath(parsed); + } } catch { return { kind: 'ignore' }; } + return classifyPath(path); +} + +/** Open or only reveal a local path, by the allowlist above. */ +function classifyPath(path: string): LinkAction { // A trailing slash is a folder (or a bundle like Foo.app/): never opened. const ext = /[/\\]$/.test(path) ? '' : extname(path).toLowerCase(); return DOCUMENT_EXTENSIONS.has(ext) ? { kind: 'open', path } : { kind: 'reveal', path }; @@ -57,11 +72,116 @@ export function classifyLink(url: string): LinkAction { * links — Chromium refuses a file: navigation from a page not itself served * from file: (the dev server) before Electron is ever asked. */ -export function openLink(shell: Pick, url: string): void { +type LinkShell = Pick; + +/** + * Stem's own viewer (desktop/viewer.ts), set once at startup. Answers false for + * a type it does not show. Kept as a hook so this file stays free of Electron + * windows and its tests run without one. + */ +type FileViewer = (path: string) => Promise; +let fileViewer: FileViewer | null = null; + +export function setFileViewer(viewer: FileViewer | null): void { + fileViewer = viewer; +} + +/** + * Try the viewer first; when it does not show the type, do `otherwise`. When + * the viewer fails, the file is only shown in Finder: an agent-written HTML + * page must not land in a browser, outside the sandbox the viewer exists for. + */ +function viewOr(shell: LinkShell, path: string, otherwise: () => void): void { + if (!fileViewer) return otherwise(); + fileViewer(path).then( + (shown) => { + if (!shown) otherwise(); + }, + // quiet: the file is revealed instead; the user sees where it is. + () => shell.showItemInFolder(path) + ); +} + +export function openLink(shell: LinkShell, url: string): void { const action = classifyLink(url); + if (action.kind === 'open' || action.kind === 'reveal') { + // A folder (trailing slash) is never a file to view. + if (/[/\\]$/.test(action.path)) return actOn(shell, action); + return viewOr(shell, action.path, () => actOn(shell, action)); + } + actOn(shell, action); +} + +function actOn(shell: LinkShell, action: LinkAction): void { if (action.kind === 'external') void shell.openExternal(action.url).catch(() => undefined); // openPath resolves with an error string (never rejects) when the file is // missing, e.g. a link to another device's Downloads; nothing to open then. else if (action.kind === 'open') void shell.openPath(action.path); else if (action.kind === 'reveal') shell.showItemInFolder(action.path); } + +/** + * Types a `files/…` link (desktop files:open) only shows, never opens: the file + * comes from the server's Files folder, where the agent itself can write. Legacy + * Office files can carry macros, an SVG opens in a browser as a page with + * script, and a zip unpacks on open. + */ +const FILES_ITEM_REVEAL_ONLY = new Set(['.doc', '.xls', '.ppt', '.svg', '.zip']); + +/** + * Show a file fetched for a `files/…` link in Stem's viewer, which is closed + * off for any type it shows (an SVG there is safe, a .doc goes to Quick Look, + * which runs no macros). Otherwise the file: rules, minus the types above. + */ +export function openFilesItem(shell: LinkShell, path: string): void { + viewOr(shell, path, () => { + if (FILES_ITEM_REVEAL_ONLY.has(extname(path).toLowerCase())) shell.showItemInFolder(path); + else actOn(shell, classifyPath(path)); + }); +} + +/** The file a file:// link names, for "Show in Finder" and "Copy Path". */ +export function linkFilePath(url: string): string | undefined { + const action = classifyLink(url); + return action.kind === 'open' || action.kind === 'reveal' ? action.path.replace(/(.)[/\\]+$/, '$1') : undefined; +} + +/** Show a file:// link's file selected in Finder/Explorer, whatever its type. */ +export function revealLink(shell: Pick, url: string): void { + const path = linkFilePath(url); + if (path) shell.showItemInFolder(path); +} + +export function revealLabel(platform: NodeJS.Platform = process.platform): string { + if (platform === 'darwin') return 'Show in Finder'; + if (platform === 'win32') return 'Show in Explorer'; + return 'Show in Folder'; +} + +/** + * A link the page wrote as a relative `files/…` or `scratch/…` path + * (shared/files-links.ts). Chromium resolves it against the page's own URL, so + * in the packaged app it arrives as file:///…/Stem.app/…/renderer/scratch/…, a + * path that is not on the disk. The file is on the server: answer which one. + * `inApp` is true for any link inside the app's own folder, which is never a + * file of the user's to show or open. + */ +export type AppRelativeLink = + | { inApp: true; files?: string; scratch?: string } + | { inApp: false }; + +export function appRelativeLink(linkURL: string, pageURL: string): AppRelativeLink { + let base: string; + try { + base = new URL('.', pageURL).href; + } catch { + return { inApp: false }; + } + if (!linkURL.startsWith(base)) return { inApp: false }; + const rest = linkURL.slice(base.length); + const files = filesPlaceRel(rest); + if (files) return { inApp: true, files }; + const scratch = scratchRel(rest); + if (scratch) return { inApp: true, scratch }; + return { inApp: true }; +} diff --git a/src/desktop/proxy.ts b/src/desktop/proxy.ts index 4366c399..51aeabeb 100644 --- a/src/desktop/proxy.ts +++ b/src/desktop/proxy.ts @@ -1,6 +1,7 @@ import { randomUUID } from 'node:crypto'; import { request as httpRequest } from 'node:http'; import { request as httpsRequest } from 'node:https'; +import { createGunzip } from 'node:zlib'; import { log } from '../server/log'; import { BROWSER_END_FRAME, @@ -36,8 +37,11 @@ import { type LiveTurnInfo, type TurnAttachment } from '../shared/types'; -import { convertHeicAttachments } from '../server/pi/heic'; +import { convertHeicAttachment, convertHeicAttachments } from '../server/pi/heic'; +import { isUploadHandle } from '../server/files/staging'; +import type { ServerCredentials } from './server-endpoint'; import { uploadBytes, uploadFile } from './file-transfer'; +import { MAIL_DELTA_HEADER, MAIL_DELTA_VALUE } from '../shared/mail-delta'; import { createOfflineCache } from './offline-cache'; import type { OAuthCourier } from './oauth-courier'; import { updateClientQuickChat, withClientSettings } from './settings'; @@ -376,6 +380,13 @@ export interface ServerProxy { start(): Promise; /** Call a server channel: wrapped client behavior, then POST /rpc. */ invoke(channel: string, args: unknown[]): Promise; + /** + * The offline cache's copy of one transcript, flagged `offline`, without a + * call on the wire — what lets the sidebar open a chat at once on a slow + * link (the renderer still asks the server and merges its answer over it). + * Undefined on an embedded install, which keeps no cache. + */ + cachedThread(threadId: string): unknown; /** Drop the stream and stop reconnecting (quit; tests). */ close(): void; } @@ -410,12 +421,23 @@ function postJson( return new Promise((resolve, reject) => { const req = openStream( url, - { method: 'POST', headers: { ...headers, 'content-length': String(Buffer.byteLength(body)) }, signal }, + { + method: 'POST', + // The server gzips big answers for a caller that asks (transport/server.ts + // sendJsonCompressed). mail:list is the whole mail store, 1.6 MB by + // November, and every mutator answers with it: uncompressed, a send + // waited tens of seconds on the user's uplink. + headers: { ...headers, 'accept-encoding': 'gzip', 'content-length': String(Buffer.byteLength(body)) }, + signal + }, (res) => { const chunks: Buffer[] = []; - res.on('data', (c: Buffer) => chunks.push(c)); - res.on('end', () => resolve({ status: res.statusCode ?? 0, text: Buffer.concat(chunks).toString('utf8') })); - res.on('error', reject); + const zipped = /\bgzip\b/i.test(String(res.headers['content-encoding'] ?? '')); + const stream = zipped ? res.pipe(createGunzip()) : res; + if (zipped) res.on('error', reject); + stream.on('data', (c: Buffer) => chunks.push(c)); + stream.on('end', () => resolve({ status: res.statusCode ?? 0, text: Buffer.concat(chunks).toString('utf8') })); + stream.on('error', reject); } ); req.on('error', reject); @@ -427,6 +449,28 @@ function openStream(url: string, options: Parameters[1], onR return (url.startsWith('https:') ? httpsRequest : httpRequest)(url, options, onRes); } +/** + * Put one attachment on a remote server NOW and answer the attachment that + * stands for it there (`path` = an upload handle). The mail composer calls this + * the moment a file is attached, so pressing Send carries only handles and the + * text: the upload happened while the user was still writing. + * + * Unlike attachmentsForServer, pasted bytes go up too — a screenshot paste is + * the common case, and the whole point is that nothing heavy rides with Send. + * HEIC is decoded first, as at send time. Throws with the file's name, so a + * failure can be shown on its chip and tried again when the mail is sent. + */ +export async function stageAttachment(creds: ServerCredentials, att: TurnAttachment): Promise { + if (att.path && isUploadHandle(att.path)) return att; + const ready = await convertHeicAttachment(att); + if (ready.dataBase64) { + const handle = await uploadBytes(creds, ready !== att ? jpegName(att.name) : att.name, Buffer.from(ready.dataBase64, 'base64')); + return { name: att.name, ...(ready.mime ? { mime: ready.mime } : {}), path: handle }; + } + if (!ready.path) return att; + return { ...ready, path: await uploadFile(creds, ready.path) }; +} + export function createServerProxy(deps: ProxyDeps): ServerProxy { const base = deps.url.replace(/\/$/, ''); const auth = `Bearer ${deps.token}`; @@ -483,6 +527,9 @@ export function createServerProxy(deps: ProxyDeps): ServerProxy { const converted = await convertHeicAttachments(atts); return Promise.all( converted.map(async (att, i) => { + // Already on the server: the mail composer stages a file the moment it + // is attached (stageAttachment below), so the send carries the handle. + if (att.path && isUploadHandle(att.path)) return att; // convertHeicAttachments returns a new object only for a decoded HEIC; // everything else comes back as the same reference. if (att !== atts[i] && att.dataBase64) { @@ -541,6 +588,13 @@ export function createServerProxy(deps: ProxyDeps): ServerProxy { return [threadId, { ...ex, steps, unmatched }, draftId]; } }, + 'mail:composeExternal': { + before: async ([input]) => { + const mail = input as { attachments?: TurnAttachment[] }; + if (!mail?.attachments?.length) return; + return [{ ...mail, attachments: await attachmentsForServer(mail.attachments) }]; + } + }, 'mail:reply': { before: async ([conversationId, body, attachments]) => { const list = attachments as TurnAttachment[] | undefined; @@ -576,7 +630,8 @@ export function createServerProxy(deps: ProxyDeps): ServerProxy { try { res = await postJson( `${base}/rpc`, - { 'content-type': 'application/json', authorization: auth }, + // Mail answers as deltas: the renderer merges them (useMail.ts). + { 'content-type': 'application/json', authorization: auth, [MAIL_DELTA_HEADER]: MAIL_DELTA_VALUE }, JSON.stringify({ channel, args }), // A caller's own signal (a cancellable prefetch) on top of the timeout // every call gets. Either one aborting aborts the request. @@ -593,7 +648,7 @@ export function createServerProxy(deps: ProxyDeps): ServerProxy { if (cached !== undefined) return cached; // Distinct from a call the server answered, and the only error shape here // the renderer could not have seen before the split. - throw new Error(`Stem's server is unreachable: ${String((e as Error)?.message ?? e)}`); + throw new Error(`Stem's server is unreachable: ${String((e as Error)?.message ?? e)}`, { cause: e }); } type RpcReply = { ok?: boolean; result?: unknown; error?: string } | null; let body: RpcReply; @@ -1303,6 +1358,9 @@ export function createServerProxy(deps: ProxyDeps): ServerProxy { return list; }, invoke, + // replay() and not peek(): the copy goes out flagged `offline`, which is + // what keeps the renderer from treating it as a complete, current read. + cachedThread: (threadId) => cache.replay('chats:open', [threadId]), close() { closed = true; clearRetry(); diff --git a/src/desktop/quickchat/index.ts b/src/desktop/quickchat/index.ts index 69cbd942..a2cd6319 100644 --- a/src/desktop/quickchat/index.ts +++ b/src/desktop/quickchat/index.ts @@ -22,10 +22,17 @@ import { compactOverlay, placeOverlay, placeOverlayBeside, + orderOverlayWithWindow, + surfaceOverlay, + overlayStacksWithWindow, + parkOverlay, + restoreOverlayOpacity, + unparkOverlay, setOverlayWorkspaceVisibility, + stackOverlayWithWindows, type DockRect } from './windows'; -import { peekFrontWindow, readWindowText, stopWindowPeek, warmWindowPeek, windowBounds, windowPeekSupported } from './window-peek'; +import { focusWindowApp, peekFrontWindow, readWindowText, stopWindowPeek, warmWindowPeek, windowPeekSupported, windowState } from './window-peek'; import { eventTurnId } from '../../shared/settledTurns'; import { isBrowserApp } from '../../shared/browser-apps'; import { PillTurns, type PillEventParams } from './pill-turns'; @@ -42,6 +49,8 @@ import type { QuickChatSettings, QuickChatShortcutStatus, QuickChatStatus, + QuickChatTabs, + QuickChatMini, QuickChatWindow, StartTurnInput, StartTurnResult, @@ -105,6 +114,11 @@ export interface QuickChatSurface { registerIpc(): void; /** Summon or dismiss the overlay — the shortcut, the tray, the CLI, the HUD. */ toggle(): void; + /** + * Window › Minimize (⌘M) while a Quick Chat panel has the keyboard: a window + * panel shrinks to its pill. True when a panel had it (a panel never minimises). + */ + minimizeFocused(): boolean; /** "Ask about this window" — its shortcut, or `stem --ask-window` (the Wayland path). */ askAboutWindow(): void; /** Is any Quick Chat panel on screen? (app.on('activate') asks before reopening the app.) */ @@ -141,16 +155,48 @@ export interface QuickChatSurface { * One Quick Chat panel: an overlay window and the conversation it owns. The * plain panel (the Quick Chat shortcut) sits centred and always exists; every * window asked about gets a panel of its own, docked beside that window, so - * several can be open — and answering — at once. + * several can be open — and answering — at once. A window can hold several + * conversations as tabs: each tab is a panel of its own (its own overlay + * window, session and turn), stacked in the same spot with one in front. */ interface Panel { + /** Names the panel to its renderer's tab strip. */ + readonly id: string; win: BrowserWindow | null; + /** The window's tabs this panel is one of; null for the plain panel. */ + group: WindowGroup | null; + /** The first question asked in the current conversation (the tab's label). */ + label: string | null; + /** An answer finished while this tab was out of sight. */ + unread: boolean; + /** Showing a conversation (tall panel) rather than the compact bar. */ + expanded: boolean; + /** + * Shrunk to a small pill beside its window (window panels only): ⌘M, the + * header button, or a click back into the window while an answer runs. + */ + mini: boolean; + /** What the pill shows while `mini`: the answer's last progress. */ + miniStatus: QuickChatStatus | null; + /** The compact bar carries the window chip. */ + chip: boolean; /** * The window this panel was asked about: it docks beside it (never on top * when the screen has room) and follows it while shown, and the first prompt * sent with its chip carries its text. Null for the plain panel. */ - peek: { window: QuickChatWindow; bounds: DockRect; text: Promise } | null; + peek: { + window: QuickChatWindow; + bounds: DockRect; + text: Promise; + /** Last seen minimised, hidden or on another Space (absent: on screen). */ + away?: boolean; + } | null; + /** + * Hidden because its window went out of sight (minimised, app hidden, other + * Space), not dismissed: it comes back when the window does. macOS only. + */ + parked: boolean; /** Thread ownership and turn state — see OverlaySession. */ readonly overlay: OverlaySession; readonly handoffBarrier: QuickChatHandoffBarrier; @@ -164,18 +210,36 @@ interface Panel { lastShown: number; } -/** Window panels kept at most; past this the longest-unused idle hidden one closes. */ -const MAX_WINDOW_PANELS = 6; +/** The conversations open about one window: its tabs, one of them in front. */ +interface WindowGroup { + readonly windowId: number; + readonly tabs: Panel[]; + active: Panel; +} + +/** Window panels (tabs included) kept at most; past this the longest-unused idle hidden one closes. */ +const MAX_WINDOW_PANELS = 8; +/** Tabs one window may hold. */ +const MAX_TABS_PER_WINDOW = 5; function newPanel(win: BrowserWindow | null): Panel { return { + id: randomUUID(), win, + group: null, + label: null, + unread: false, + expanded: false, + mini: false, + miniStatus: null, + chip: false, peek: null, overlay: new OverlaySession(), handoffBarrier: new QuickChatHandoffBarrier(), resetBarrier: new QuickChatResetBarrier(), turnId: null, followTimer: null, + parked: false, lastShown: 0 }; } @@ -188,6 +252,16 @@ function onScreen(panel: Panel): boolean { return live(panel.win) && panel.win.isVisible(); } +/** On screen, or a tab behind one that is: its window's panel is in front of the user. */ +function inSight(panel: Panel): boolean { + return onScreen(panel) || (!!panel.group && onScreen(panel.group.active)); +} + +/** The compact bar shows a tab strip: its window has more than one conversation. */ +function showsTabs(panel: Panel): boolean { + return !!panel.group && panel.group.tabs.length > 1; +} + /** Permission asks: shown by the panel whose thread asked, else by the plain one. */ const APPROVAL_REQUESTS = new Set([ 'exec:approvalRequest', @@ -233,8 +307,10 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { // events to the main window from then on. All of that state lives in the panel's // OverlaySession — every mutation is a named transition, never a bare flag. const plain = newPanel(null); - /** "Ask about this window" panels, by the id of the window each was asked about. */ - const windowPanels = new Map(); + /** "Ask about this window" panels, as tabs grouped by the id of the window they were asked about. */ + const windowPanels = new Map(); + /** Tabs closed while their answer winds down: still routed to until it settles. */ + const closing = new Set(); /** * A hidden, already-loaded overlay waiting to become the next window panel, so * asking about a new window is as instant as re-summoning a known one. @@ -254,6 +330,9 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { // running, the pill mirrors that progress so you don't lose sight of it. /** Show the pill for main threads when the main window loses focus. */ let followAcrossSpaces = true; + /** Window panels keep to their window's stacking and visibility (macOS). */ + let stayWithWindow = false; + const stacking = () => overlayStacksWithWindow && stayWithWindow; /** Play a chime when a turn finishes while the pill is visible. */ let finishSound = false; /** Locally initiated interactive turns shared by both HUD paths. */ @@ -291,7 +370,9 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { } const panel = ownerOf(threadId); if (panel) { - if (hudShows(panel) && !onScreen(panel) && hud.lastPhase !== 'finished') + if (miniShown(panel.group) && panel.group!.active === panel && panel.overlay.turnRunning) + showPanelHud(panel, { phase: 'working', label: 'Working…' }); + else if (hudShows(panel) && !onScreen(panel) && hud.lastPhase !== 'finished') showPanelHud(panel, { phase: 'working', label: 'Working…' }); } else syncMainHud(); } @@ -303,7 +384,7 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { } function panels(): Panel[] { - return [plain, ...windowPanels.values()]; + return [plain, ...[...windowPanels.values()].flatMap((g) => g.tabs), ...closing]; } /** Every overlay window, the spare included: theme and connection changes reach all. */ @@ -349,31 +430,134 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { } /** - * A panel for a window asked about for the first time. Too many already: the - * longest-unused hidden one with nothing running closes first. + * A panel for a window asked about for the first time, or another tab in + * `group`. Too many already: the longest-unused hidden one with nothing + * running closes first (never a tab of the window in front of the user). */ - function openWindowPanel(windowId: number): Panel { - if (windowPanels.size >= MAX_WINDOW_PANELS) { - const idle = [...windowPanels.values()] - .filter((p) => !onScreen(p) && !p.overlay.turnRunning && !p.resetBarrier.pending) + function openWindowPanel(windowId: number, group: WindowGroup | null = null): Panel { + const open = panels().filter((p) => p.group); + if (open.length >= MAX_WINDOW_PANELS) { + const idle = open + .filter((p) => !inSight(p) && p.group !== group && !p.overlay.turnRunning && !p.resetBarrier.pending) .sort((a, b) => a.lastShown - b.lastShown)[0]; idle?.win?.destroy(); } const win = live(spare) ? spare : createPanelWindow(); spare = null; + // Lives in its window's stacking order rather than over everything, when set so. + stackOverlayWithWindows(win, stayWithWindow); const panel = newPanel(win); - windowPanels.set(windowId, panel); + if (group) group.tabs.push(panel); + else { + group = { windowId, tabs: [panel], active: panel }; + windowPanels.set(windowId, group); + } + panel.group = group; + // A click back into the window (or anywhere else) while an answer runs + // shrinks the panel to its pill, so it stops covering the user's work. + // Deferred: a tab switch or a dismiss hides the panel in the same tick. + win.on('blur', () => { + setTimeout(() => { + if (panel.group?.active === panel && panel.overlay.turnRunning && !win.isFocused()) minimize(panel, false); + }, 0); + }); win.on('closed', () => { stopFollowing(panel); panel.win = null; - if (windowPanels.get(windowId) === panel) windowPanels.delete(windowId); if (hudPanel === panel) hudPanel = null; + leaveGroup(panel); }); // The next window's panel loads while this one is in use. setTimeout(ensureSpare, 1_000); return panel; } + /** Take a tab out of its window's group; the most recently used one left takes the front. */ + function leaveGroup(panel: Panel): void { + const group = panel.group; + if (!group) return; + panel.group = null; + group.tabs.splice(group.tabs.indexOf(panel), 1); + if (!group.tabs.length) { + if (windowPanels.get(group.windowId) === group) windowPanels.delete(group.windowId); + return; + } + if (group.active === panel) group.active = [...group.tabs].sort((a, b) => b.lastShown - a.lastShown)[0]; + pushTabs(group); + } + + /** + * Tell every tab of a window what the strip shows. The compact bar grows or + * shrinks by the strip when the second tab opens or the last but one closes. + */ + function pushTabs(group: WindowGroup): void { + const tabs = group.tabs.map((p) => ({ + id: p.id, + label: p.label, + active: p === group.active, + running: p.overlay.turnRunning, + unread: p.unread + })); + const canAdd = group.tabs.length < MAX_TABS_PER_WINDOW; + for (const p of group.tabs) sendTo(p, 'quickchat:tabs', { tabs, canAdd, self: p.id } satisfies QuickChatTabs); + if (onScreen(group.active) && !group.active.expanded) place(group.active); + pushMini(group.active); + } + + /** Size and dock a window panel beside its window for what it shows now. */ + function place(panel: Panel): void { + if (!live(panel.win) || !panel.peek) return; + placeOverlayBeside(panel.win, panel.peek.bounds, panel.expanded, panel.chip, showsTabs(panel), panel.mini); + } + + /** The pill of `group` is on screen: its front tab is shrunk and shown. */ + function miniShown(group: WindowGroup | null): boolean { + return !!group && group.active.mini && onScreen(group.active); + } + + /** Tell a shrunk panel what its pill shows. */ + function pushMini(panel: Panel): void { + if (!panel.mini || !panel.peek) return; + sendTo(panel, 'quickchat:mini', { + status: panel.miniStatus, + app: panel.peek.window.app, + tabs: panel.group?.tabs.length ?? 1 + } satisfies QuickChatMini); + } + + /** + * Shrink a window panel with a conversation to a pill beside its window. + * `giveBackKeys`: the user asked for it from inside the panel, so the + * keyboard goes back to the window (a click into the window already did that). + */ + function minimize(panel: Panel, giveBackKeys: boolean): void { + if (panel.mini || !panel.group || !panel.peek || !panel.expanded || !onScreen(panel)) return; + panel.mini = true; + panel.miniStatus = panel.overlay.turnRunning + ? awaitingApproval(panel.overlay.threadId) + ? WAITING + : { phase: 'working', label: 'Working…' } + : null; + pushMini(panel); + place(panel); + if (giveBackKeys && panel.win!.isFocused()) { + // Hidden and shown again without focus: the panel stops being the key + // window. macOS then gives the keyboard to no app, so the helper makes + // the window's app the active one again. + panel.win!.hide(); + panel.win!.showInactive(); + void focusWindowApp(panel.peek.window.windowId); + } + } + + /** Grow a pill back to the full panel; present() then puts it in front. */ + function unminimize(panel: Panel): void { + if (!panel.mini) return; + panel.mini = false; + panel.miniStatus = null; + sendTo(panel, 'quickchat:mini', null); + } + function ensureHudWindow(): BrowserWindow { if (!hudWindow || hudWindow.isDestroyed()) { hudWindow = createHudWindow({ installNavigationGuards: deps.installNavigationGuards }); @@ -400,6 +584,16 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { * pill is visible. */ function showHud(status: QuickChatStatus, owner: 'quickchat' | 'main', panel: Panel | null = null): void { + // A window shrunk to its pill: the pill beside it shows the front tab's + // progress, and no tab of that window uses the shared pill. + if (owner === 'quickchat' && panel?.group && miniShown(panel.group)) { + if (panel !== panel.group.active) return; + const finished = status.phase === 'finished' && panel.miniStatus?.phase !== 'finished'; + panel.miniStatus = status; + pushMini(panel); + if (finished && finishSound) platformFinishChime(ensureHudWindow()); + return; + } if (!pillTurns.connected) return; const win = ensureHudWindow(); if (!win.isVisible()) { @@ -440,7 +634,9 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { const p = (event.params ?? {}) as PillEventParams; if (eventTurnId(p) !== panel.turnId || !pillTurns.event(event.method, p)) return; const { overlay } = panel; - const visible = onScreen(panel); + // A tab behind the one in front shows its progress in the strip, not the + // pill. A window shrunk to its pill shows the progress there (see showHud). + const visible = inSight(panel) && !miniShown(panel.group); switch (event.method) { case 'item/started': { if (visible) break; @@ -473,6 +669,10 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { : 'Stopped'; overlay.settleTurn(Date.now()); dropApprovals(overlay.threadId); + if (panel.group) { + if (event.method === 'turn/completed' && !onScreen(panel) && !panel.resetBarrier.pending) panel.unread = true; + pushTabs(panel.group); + } // A reset must not release the old thread until this terminal event has // been routed. Otherwise its trailing deltas can be mistaken for the next // Quick Chat session. @@ -536,50 +736,112 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { * hide/show, so resuming needs no payload beyond the reset flag. */ function showQuickChat(panel: Panel, reset: boolean, window?: QuickChatWindow): void { + panel.expanded = !reset; + if (reset) panel.chip = !!panel.peek; + present(panel); + panel.win!.webContents.send('quickchat:focus', window ? { reset, window } : { reset }); + } + + /** + * Put a panel on screen as it stands. A tab comes to the front of its + * window's panel, in the spot the one it replaces was in, and that one hides. + */ + function present(panel: Panel): void { const win = panelWindow(panel); // Resuming puts the answer in front of the user: that's reading it. - if (!reset && !panel.overlay.turnRunning) markOverlayThreadRead(panel); - // Another panel's running turn keeps its pill. - if (hud.owner !== 'quickchat' || hudPanel === panel) hideHud(); + if (panel.expanded && !panel.overlay.turnRunning) markOverlayThreadRead(panel); + // Another panel's running turn keeps its pill; a tab of this window's does + // not, the strip shows it. + if (hud.owner !== 'quickchat' || hudPanel === panel || (!!panel.group && hudPanel?.group === panel.group)) hideHud(); deps.beginSummon(); panel.lastShown = Date.now(); + panel.parked = false; + unminimize(panel); + const group = panel.group; + if (group) { + const before = group.active; + if (before !== panel && before.peek && panel.peek && onScreen(before)) panel.peek.bounds = before.peek.bounds; + group.active = panel; + panel.unread = false; + } if (panel.peek) { - placeOverlayBeside(win, panel.peek.bounds, !reset, reset); + place(panel); followWindow(panel); - } else placeOverlay(win, reset); + } else placeOverlay(win, !panel.expanded); // Surface the panel on whatever Space the user is on and make it the key window // so it receives keystrokes (typing, Escape) — without activating Stem, so the // previous app stays active underneath and the main window is never pulled // forward. The macOS ordering is subtle; see presentOverlayWindow. + restoreOverlayOpacity(win); + // A panel sunk behind another app's windows comes back to its own level. + if (group) stackOverlayWithWindows(win, stayWithWindow); presentOverlayWindow(win); - win.webContents.send('quickchat:focus', window ? { reset, window } : { reset }); + if (group) { + for (const tab of group.tabs) if (tab !== panel) dismissQuickChat(tab); + pushTabs(group); + } } /** - * Keep a docked panel beside its window while both are on screen: the window - * may be dragged or resized with the panel open. Stops itself once the panel - * hides or the window closes. + * Keep a docked panel with its window while the panel is on screen: beside it + * when the window is dragged or resized, and (macOS) directly above it in the + * stacking order — whatever covers the window covers the panel, and when the + * window comes forward the panel comes with it. A window that is minimised, + * hidden or moved to another Space takes its panel along, and brings it back + * on return. Only the change is acted on: a panel the user brings back while + * its window is still away stays up. Stops once the panel is dismissed or the + * window closes. */ function followWindow(panel: Panel): void { if (panel.followTimer) return; + const following = (win: BrowserWindow | null): win is BrowserWindow => live(win) && (win.isVisible() || panel.parked); panel.followTimer = setInterval(() => { const win = panel.win; const anchored = panel.peek; - if (!live(win) || !win.isVisible() || !anchored) { + if (!following(win) || !anchored) { stopFollowing(panel); return; } - void windowBounds(anchored.window.windowId) - .then((b) => { - if (!b || panel.peek !== anchored || win.isDestroyed() || !win.isVisible()) return; + void windowState(anchored.window.windowId) + .then((state) => { + if (panel.peek !== anchored || !following(win)) return; + if (!state) { + // Closed (or, off macOS, minimised): the panel stays where it is, + // and one parked with it is let go. + surfaceOverlay(win); + if (panel.parked) { + panel.parked = false; + stopFollowing(panel); + } + return; + } + const wasAway = !!anchored.away; + anchored.away = !state.onScreen; + if (stacking() && anchored.away !== wasAway) { + if (anchored.away) { + if (win.isVisible()) { + panel.parked = true; + parkOverlay(win); + } + return; + } + if (panel.parked) { + panel.parked = false; + unparkOverlay(win); + if (hudShows(panel)) hideHud(); + } + } + if (anchored.away) return; + const b = state.bounds; const p = anchored.bounds; - if (b.x === p.x && b.y === p.y && b.width === p.width && b.height === p.height) return; - anchored.bounds = b; - const expanded = win.getBounds().height > 200; - placeOverlayBeside(win, b, expanded, !expanded); + if (b.x !== p.x || b.y !== p.y || b.width !== p.width || b.height !== p.height) { + anchored.bounds = b; + place(panel); + } + if (stacking()) orderOverlayWithWindow(win, anchored.window.windowId, state.frontmost); }) .catch(() => undefined); - }, 400); + }, stacking() ? 250 : 400); } function stopFollowing(panel: Panel): void { @@ -612,7 +874,14 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { } const w = peeked.window; await addBrowserState(w); - const known = windowPanels.get(w.windowId); + // A window with several tabs comes back on the one last in front. + const known = windowPanels.get(w.windowId)?.active; + if (known && onScreen(known) && known.mini) { + // Shrunk to its pill: the full panel comes back, keyboard and all. + present(known); + known.win!.webContents.send('quickchat:focus', { reset: false }); + return; + } if (known && onScreen(known)) { // Already open beside it: just put the keyboard back in it. known.lastShown = Date.now(); @@ -623,7 +892,10 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { } const panel = known ?? openWindowPanel(w.windowId); const reset = panel.overlay.shouldStartFresh(Date.now(), newThreadTimeoutMs); - if (reset) panel.overlay.clearForFreshSession(); + if (reset) { + panel.overlay.clearForFreshSession(); + panel.label = null; + } // The text is read while the user types; the send waits for it (see runQuickChat). const text = reset || !panel.peek ? w.missing.includes('accessibility') @@ -655,6 +927,8 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { async function repeekPanelWindow(panel: Panel): Promise<{ window: QuickChatWindow | null } | null> { const anchored = panel.peek; if (!anchored) return null; + panel.label = null; + if (panel.group) pushTabs(panel.group); const peeked = await peekFrontWindow(anchored.window.windowId); if (!peeked) return { window: null }; const w = peeked.window; @@ -707,6 +981,7 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { */ function dismissQuickChat(panel: Panel): void { stopFollowing(panel); + panel.parked = false; if (onScreen(panel)) panel.win!.hide(); } @@ -843,6 +1118,8 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { overlay.stopTurn(); if (hudShows(panel)) hideHud(); dismissQuickChat(panel); + // Its conversation now lives in the main window; the tab has nothing left. + if (showsTabs(panel)) void closeTab(panel); deps.sendToMain('quickchat:adopt', transition.snapshot); for (const bufferedEvent of transition.events) { deps.sendToMain('backend:event', bufferedEvent); @@ -875,7 +1152,7 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { } sendTo(owner, 'backend:event', event); driveHud(owner, event); - if (event.method === 'turn/completed' && onScreen(owner)) markOverlayThreadRead(owner); + if (event.method === 'turn/completed' && onScreen(owner) && !owner.mini) markOverlayThreadRead(owner); return true; } if (!threadId) { @@ -914,6 +1191,40 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { return false; } + /** + * Close one of a window's tabs. The next one comes to the front where it + * stood; the last tab only hides, like Escape. A tab whose answer is still + * winding down (its renderer already stopped it) keeps its thread until the + * turn's last event has routed, the same way New thread does, then goes. + */ + async function closeTab(panel: Panel): Promise { + const group = panel.group; + if (!group) return; + if (group.tabs.length === 1) { + dismissQuickChat(panel); + return; + } + const i = group.tabs.indexOf(panel); + const wasInFront = onScreen(panel); + leaveGroup(panel); + if (wasInFront) { + const next = group.tabs[Math.min(i, group.tabs.length - 1)]; + if (panel.peek && next.peek) next.peek.bounds = panel.peek.bounds; + present(next); + next.win!.webContents.send('quickchat:focus', { reset: false }); + } + dismissQuickChat(panel); + if (hudShows(panel)) hideHud(); + if (!panel.overlay.handedOff) { + closing.add(panel); + panel.overlay.prepareManualReset(); + if (panel.overlay.turnRunning) await panel.resetBarrier.wait(); + else finishOverlayReset(panel); + closing.delete(panel); + } + panel.win?.destroy(); + } + /** * Run a prompt in the panel's own thread. For a fresh session we pre-create * the thread (so its events route correctly from the very first event), then @@ -926,11 +1237,16 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { const turnId = prompt.turnId || randomUUID(); panel.turnId = turnId; overlay.beginTurn(Date.now()); + if (panel.group) { + if (!overlay.owns(prompt.threadId)) panel.label = prompt.input.trim().slice(0, 80) || null; + pushTabs(panel.group); + } if (panel.peek && onScreen(panel)) { // Docked beside a window: the answer is read right there, next to what // it is about, so the panel grows in place instead of giving way to the // pill. (driveHud shows no pill while the panel is visible.) - placeOverlayBeside(panel.win!, panel.peek.bounds, true, false); + panel.expanded = true; + place(panel); } else { // Hide just the panel (NOT app.hide — that would also hide the HUD we're // about to show, and re-showing the HUD would reactivate the app and surface @@ -1002,6 +1318,7 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { return result; } catch (e) { overlay.settleTurn(Date.now()); + if (panel.group) pushTabs(panel.group); if (hudShows(panel)) hideHud(); if (panel.resetBarrier.pending) finishOverlayReset(panel); if (overlay.handedOff && overlay.threadId) { @@ -1042,10 +1359,13 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { } if (running && !onScreen(panel)) { panel.overlay.beginTurn(Date.now()); - if (!shown) showPanelHud(panel, { phase: 'working', label: 'Working…' }); - shown = true; + if (!shown && !inSight(panel)) { + showPanelHud(panel, { phase: 'working', label: 'Working…' }); + shown = true; + } } } + for (const group of windowPanels.values()) pushTabs(group); if (!shown) syncMainHud(); }, start(settings) { @@ -1054,6 +1374,7 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { overlayOnAllDisplays = settings.showOnAllDisplays; newThreadTimeoutMs = settings.newThreadTimeoutMs; followAcrossSpaces = settings.followAcrossSpaces; + stayWithWindow = settings.stayWithWindow; finishSound = settings.finishSound; // Pre-create the windows (hidden) so the shortcut summons instantly, and // bind the global accelerators from the saved settings. @@ -1101,6 +1422,7 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { if (panel.resetBarrier.pending) finishOverlayReset(panel); if (hudShows(panel)) hideHud(); dismissQuickChat(panel); + if (showsTabs(panel)) void closeTab(panel); deps.revealMainWindow(); deps.sendToMain('quickchat:adopt', payload); for (const bufferedEvent of bufferedEvents) { @@ -1148,11 +1470,65 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { // to the compact bar instead of leaving a tall empty card. handleLocalFrom('quickchat:compact', (sender, chip?: boolean) => { const panel = panelFor(sender); - if (onScreen(panel)) compactOverlay(panel.win!, chip === true); + panel.expanded = false; + panel.chip = chip === true; + if (onScreen(panel) && !panel.mini) compactOverlay(panel.win!, panel.chip, showsTabs(panel)); + }); + + // A window panel's tabs: another conversation about the same window, + // with a fresh picture of it (the window may show something new by now). + handleLocalFrom('quickchat:newTab', async (sender) => { + const from = panelFor(sender); + const group = from.group; + if (!group || group.tabs.length >= MAX_TABS_PER_WINDOW) return; + const peeked = await peekFrontWindow(group.windowId); + // The window closed: nothing to ask about. + if (!peeked || !group.tabs.length) return; + const w = peeked.window; + await addBrowserState(w); + const tab = openWindowPanel(group.windowId, group); + const text = w.missing.includes('accessibility') ? Promise.resolve(null) : readWindowText(w.windowId); + // Where the panel stands now, not where the window was when it was first asked about. + tab.peek = { window: w, bounds: from.peek?.bounds ?? peeked.bounds, text }; + showQuickChat(tab, true, w); + }); + + // ⌘M / the header button: shrink to the pill. A click on the pill grows it back. + handleLocalFrom('quickchat:minimize', (sender) => { + minimize(panelFor(sender), true); + }); + handleLocalFrom('quickchat:expand', (sender) => { + const panel = panelFor(sender); + if (!panel.mini) return; + present(panel); + sendTo(panel, 'quickchat:focus', { reset: false }); + }); + + handleLocalFrom('quickchat:switchTab', (sender, id: string) => { + const tab = panelFor(sender).group?.tabs.find((p) => p.id === id); + if (!tab || (tab.group!.active === tab && onScreen(tab))) return; + present(tab); + tab.win!.webContents.send('quickchat:focus', { reset: false }); + }); + + // A tab stops its own answer before it goes (it owns the turn's ids), so + // closing another tab asks that one to close itself. + handleLocalFrom('quickchat:closeTab', async (sender, id: string) => { + const from = panelFor(sender); + const tab = from.group?.tabs.find((p) => p.id === id); + if (!tab) return; + if (tab !== from) sendTo(tab, 'quickchat:closeTabRequest', { id }); + else await closeTab(tab); }); }, toggle: toggleQuickChat, + minimizeFocused: () => { + const panel = panels().find((p) => onScreen(p) && p.win!.isFocused()); + if (!panel) return false; + minimize(panel, true); + return true; + }, askAboutWindow: () => void askAboutWindow(), @@ -1171,6 +1547,24 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { if (!followAcrossSpaces && hud.owner === 'main') hideHud(); } if ('finishSound' in patch) finishSound = next.finishSound; + if ('stayWithWindow' in patch && next.stayWithWindow !== stayWithWindow) { + stayWithWindow = next.stayWithWindow; + for (const panel of panels()) { + if (!panel.group || !live(panel.win)) continue; + stackOverlayWithWindows(panel.win, stayWithWindow); + // A panel parked with its window comes back once the binding is off. + if (!stayWithWindow && panel.parked) { + panel.parked = false; + unparkOverlay(panel.win); + if (hudShows(panel)) hideHud(); + } + // The poll rate follows the setting. + if (panel.followTimer) { + stopFollowing(panel); + followWindow(panel); + } + } + } }, shortcutStatus: quickChatShortcutStatus, @@ -1195,7 +1589,7 @@ export function createQuickChat(deps: QuickChatDeps): QuickChatSurface { // A panel may be hidden while its turn runs. Bring the originating panel // back so mounting a card actually makes the confirmation visible. const panel = threadId ? ownerOf(threadId) : undefined; - if (panel && !onScreen(panel)) showQuickChat(panel, false); + if (panel && !onScreen(panel) && !closing.has(panel)) showQuickChat(panel, false); }, routeBackendEvent, diff --git a/src/desktop/quickchat/window-peek.ts b/src/desktop/quickchat/window-peek.ts index c44baa30..af4f41c6 100644 --- a/src/desktop/quickchat/window-peek.ts +++ b/src/desktop/quickchat/window-peek.ts @@ -119,11 +119,36 @@ export async function readWindowText(windowId: number): Promise { } } -/** Where the window is now, or null once it has closed. */ -export async function windowBounds(windowId: number): Promise { +/** + * Where the window is now and whether it is on screen (false while minimised, + * its app hidden, or on another Space; helpers that cannot tell say nothing and + * count as on screen). Null once it has closed — or, on helpers that report + * minimised windows as gone, while minimised. + */ +export interface WindowState { + bounds: Rect; + onScreen: boolean; + /** Its app is the one in front. Null when the helper cannot tell (older helper). */ + frontmost: boolean | null; +} + +export async function windowState(windowId: number): Promise { if (!helper?.alive) return null; - const reply = (await helper.call('window-bounds', { windowId }, 2_000)) as unknown as { ok: boolean; bounds?: unknown }; - return reply.ok ? asRect(reply.bounds) : null; + const reply = (await helper.call('window-bounds', { windowId }, 2_000)) as unknown as { + ok: boolean; + bounds?: unknown; + onScreen?: unknown; + frontmost?: unknown; + }; + const bounds = reply.ok ? asRect(reply.bounds) : null; + if (!bounds) return null; + return { bounds, onScreen: reply.onScreen !== false, frontmost: typeof reply.frontmost === 'boolean' ? reply.frontmost : null }; +} + +/** Give the keyboard back to the app that owns `windowId` (macOS). Best effort. */ +export async function focusWindowApp(windowId: number): Promise { + if (!helper?.alive) return; + await helper.call('focus-app', { windowId }, 2_000).catch(() => undefined); } export function stopWindowPeek(): void { diff --git a/src/desktop/quickchat/windows.ts b/src/desktop/quickchat/windows.ts index 6b749b6a..01db18cc 100644 --- a/src/desktop/quickchat/windows.ts +++ b/src/desktop/quickchat/windows.ts @@ -98,6 +98,85 @@ export function setOverlayWorkspaceVisibility(win: BrowserWindow, onAllWorkspace win.setVisibleOnAllWorkspaces(onAllWorkspaces, workspaceVisibilityOptions()); } +/** + * Whether a window panel can live in the asked-about window's stacking order + * instead of floating over everything: macOS orders a window relative to any + * other app's window by its window-server id. Elsewhere the panel stays + * always-on-top and only follows the window's position. + */ +export const overlayStacksWithWindow = process.platform === 'darwin'; + +/** + * A window panel's level. Stacked (the "Keep with its window" setting): an + * ordinary level, so the window it was asked about (and anything stacked over + * that) can cover it. Otherwise above everything, like the plain panel. + */ +export function stackOverlayWithWindows(win: BrowserWindow, stacked: boolean): void { + if (!overlayStacksWithWindow) return; + sunk.delete(win); + if (stacked) win.setAlwaysOnTop(false); + else win.setAlwaysOnTop(true, 'screen-saver'); +} + +/** A panel whose window closed: back to the ordinary level, where it can be seen. */ +export function surfaceOverlay(win: BrowserWindow): void { + if (sunk.delete(win)) win.setAlwaysOnTop(false); +} + +/** Panels put one level below ordinary windows while another app is in front. */ +const sunk = new WeakSet(); + +/** + * Keep the panel in the stacking order of the window `windowId`. While that + * window's app is in front, the panel goes directly above the window. While + * another app is in front (`frontmost` false), the panel goes one level below + * ordinary windows, so that app's windows cover it, as they cover the window. + * + * Why a level and not an order: macOS keeps a window that joins all Spaces in + * front of the other windows of its level when a different app comes forward, + * and it does not accept an order relative to another app's window for it. + * Electron's panel type always joins all Spaces. A panel the user types in + * stays where it is. Never makes the panel key or activates Stem. + */ +export function orderOverlayWithWindow(win: BrowserWindow, windowId: number, frontmost: boolean | null): void { + if (!overlayStacksWithWindow) return; + if (frontmost === false && !win.isFocused()) { + if (!sunk.has(win)) { + sunk.add(win); + win.setAlwaysOnTop(true, 'normal', -1); + } + return; + } + if (sunk.delete(win)) win.setAlwaysOnTop(false); + try { + win.moveAbove(`window:${windowId}:0`); + } catch { + // The window closed between the check and the call. + } +} + +/** + * Hide a window panel whose window just went away (minimised, app hidden, other + * Space) at once. macOS fades a panel out on hide, which next to the window's + * own minimise animation looks like a second, lagging one; a panel already at + * zero opacity has nothing to fade. unparkOverlay puts the opacity back. + */ +export function parkOverlay(win: BrowserWindow): void { + win.setOpacity(0); + win.hide(); +} + +/** Bring a parked panel back without taking focus, at once rather than fading in. */ +export function unparkOverlay(win: BrowserWindow): void { + win.showInactive(); + restoreOverlayOpacity(win); +} + +/** Undo parkOverlay's zero opacity; any show of a panel goes through this. */ +export function restoreOverlayOpacity(win: BrowserWindow): void { + if (win.getOpacity() !== 1) win.setOpacity(1); +} + /** * The status HUD: a tiny, non-focusable, always-on-top pill in the bottom-left. * `focusable: false` is critical — showing it must never steal focus from the app @@ -166,6 +245,19 @@ export function placeOverlay(win: BrowserWindow, reset: boolean): void { /** Height the window chip adds to the compact bar ("Ask about this window"). */ const WINDOW_CHIP_HEIGHT = 58; +/** + * Height the tab strip adds to the compact bar when a window has more than one + * conversation open. The expanded panel carries the tabs in its own header. + */ +const TAB_STRIP_HEIGHT = 37; + +/** The compact bar's height: the chip and the tab strip each add a row. */ +function compactHeight(chip: boolean, tabs: boolean): number { + return QUICK_CHAT_HEIGHT + (chip ? WINDOW_CHIP_HEIGHT : 0) + (tabs ? TAB_STRIP_HEIGHT : 0); +} +/** The pill a window panel shrinks to (⌘M, or a click back into its window while it works). */ +const MINI_WIDTH = 248; +const MINI_HEIGHT = 40; /** Space between the panel and the window it docks against. */ const DOCK_GAP = 12; @@ -203,9 +295,10 @@ export function dockBeside(target: DockRect, panel: { width: number; height: num /** * Place the overlay beside the window it was summoned for (see dockBeside), - * on that window's display. `chip`: the compact bar carries the window chip. + * on that window's display. `chip`: the compact bar carries the window chip; + * `tabs`: it carries the tab strip. */ -export function placeOverlayBeside(win: BrowserWindow, target: DockRect, expanded: boolean, chip: boolean): void { +export function placeOverlayBeside(win: BrowserWindow, target: DockRect, expanded: boolean, chip: boolean, tabs = false, mini = false): void { const { workArea } = screen.getDisplayMatching({ x: Math.round(target.x), y: Math.round(target.y), @@ -213,19 +306,38 @@ export function placeOverlayBeside(win: BrowserWindow, target: DockRect, expande height: Math.max(1, Math.round(target.height)) }); const w = QUICK_CHAT_WIDTH; - const h = expanded ? QUICK_CHAT_PANEL_HEIGHT : QUICK_CHAT_HEIGHT + (chip ? WINDOW_CHIP_HEIGHT : 0); - const { x, y } = dockBeside(target, { width: w, height: h }, workArea); - win.setBounds(overlayOuterBounds({ x, y, width: w, height: h })); + const h = expanded ? QUICK_CHAT_PANEL_HEIGHT : compactHeight(chip, tabs); + const spot = dockBeside(target, { width: w, height: h }, workArea); + win.setBounds(overlayOuterBounds(mini ? miniSpot(target, { ...spot, width: w, height: h }) : { ...spot, width: w, height: h })); +} + +/** + * Where the pill goes inside the spot the full panel takes: on the edge next + * to the window, so it reads as belonging to it. Docked right of the window: + * the panel's top-left; left of it: top-right; below: top, centred; above: + * bottom, centred. A panel over the window's corner (the window fills the + * screen) shrinks into that corner, the panel's bottom-right, rather than + * leaving the pill in the middle of the window's content. Pure, for the tests. + */ +export function miniSpot(target: DockRect, panel: DockRect): DockRect { + const pill = (x: number, y: number): DockRect => ({ x: Math.round(x), y: Math.round(y), width: MINI_WIDTH, height: MINI_HEIGHT }); + const centredX = panel.x + (panel.width - MINI_WIDTH) / 2; + if (panel.x >= target.x + target.width) return pill(panel.x, panel.y); + if (panel.x + panel.width <= target.x) return pill(panel.x + panel.width - MINI_WIDTH, panel.y); + if (panel.y >= target.y + target.height) return pill(centredX, panel.y); + if (panel.y + panel.height <= target.y) return pill(centredX, panel.y + panel.height - MINI_HEIGHT); + return pill(panel.x + panel.width - MINI_WIDTH, panel.y + panel.height - MINI_HEIGHT); } /** * Shrink a visible overlay back to the compact bar where it stands (New thread, * or a deleted thread, empties the panel). Keeps the top edge, so the bar stays * where the panel's head was rather than jumping to the cursor's display. - * `chip`: the bar carries a window chip ("Ask about this window"). + * `chip`: the bar carries a window chip ("Ask about this window"); `tabs`: the + * tab strip of a window with several conversations. */ -export function compactOverlay(win: BrowserWindow, chip = false): void { - const outer = overlayOuterBounds({ x: 0, y: 0, width: QUICK_CHAT_WIDTH, height: QUICK_CHAT_HEIGHT + (chip ? WINDOW_CHIP_HEIGHT : 0) }); +export function compactOverlay(win: BrowserWindow, chip = false, tabs = false): void { + const outer = overlayOuterBounds({ x: 0, y: 0, width: QUICK_CHAT_WIDTH, height: compactHeight(chip, tabs) }); const { x, y, width } = win.getBounds(); win.setBounds({ x, y, width, height: outer.height }); } diff --git a/src/desktop/save-image.ts b/src/desktop/save-image.ts index acf3c8f4..b8b1e065 100644 --- a/src/desktop/save-image.ts +++ b/src/desktop/save-image.ts @@ -28,12 +28,32 @@ export function imageFileBase(hint: string | undefined): string { export async function saveImageToDownloads(dataUrl: string, hint?: string): Promise { const m = /^data:(image\/(png|jpeg|webp|gif));base64,(.+)$/s.exec(dataUrl); if (!m) throw new Error('Not an image.'); - const ext = `.${m[2] === 'jpeg' ? 'jpg' : m[2]}`; + return writeNextTo(`.${m[2] === 'jpeg' ? 'jpg' : m[2]}`, imageFileBase(hint), Buffer.from(m[3], 'base64')); +} + +const AUDIO_EXT: Record = { + mpeg: '.mp3', + mp4: '.m4a', + aac: '.aac', + wav: '.wav', + ogg: '.ogg', + flac: '.flac', + webm: '.webm' +}; + +/** Write a sound data URL (share_audio) into Downloads, like saveImageToDownloads. */ +export async function saveAudioToDownloads(dataUrl: string, hint?: string): Promise { + const m = /^data:audio\/([a-z0-9]+);base64,(.+)$/s.exec(dataUrl); + const ext = m ? AUDIO_EXT[m[1]] : undefined; + if (!m || !ext) throw new Error('Not a sound file.'); + return writeNextTo(ext, imageFileBase(hint || 'Stem audio'), Buffer.from(m[2], 'base64')); +} + +async function writeNextTo(ext: string, base: string, bytes: Buffer): Promise { const dir = downloadsDir(); await mkdir(dir, { recursive: true }); - const name = basename(`${imageFileBase(hint)}${ext}`); + const name = basename(`${base}${ext}`); const stem = basename(name, extname(name)); - const bytes = Buffer.from(m[3], 'base64'); for (let i = 0; ; i++) { const path = join(dir, i === 0 ? name : `${stem} ${i + 1}${ext}`); try { diff --git a/src/desktop/server-endpoint.ts b/src/desktop/server-endpoint.ts index a7aa1ef9..4919e4fe 100644 --- a/src/desktop/server-endpoint.ts +++ b/src/desktop/server-endpoint.ts @@ -133,7 +133,7 @@ export async function pairWithServer( signal: AbortSignal.timeout(30_000) }); } catch (e) { - throw new Error(`could not reach ${url} to pair: ${String((e as Error)?.message ?? e)}`); + throw new Error(`could not reach ${url} to pair: ${String((e as Error)?.message ?? e)}`, { cause: e }); } const body = (await res.json().catch(() => null)) as | { ok?: boolean; result?: { deviceId?: string; token?: string }; error?: string } diff --git a/src/desktop/settings.ts b/src/desktop/settings.ts index 33027013..ed15a0d9 100644 --- a/src/desktop/settings.ts +++ b/src/desktop/settings.ts @@ -39,7 +39,9 @@ const DEFAULTS: ClientSettings = { showOnAllDisplays: true, // Show the progress pill for main-window threads when the main window loses // focus (switch Spaces/apps), so an active thread stays visible. - followAcrossSpaces: true + followAcrossSpaces: true, + // Window panels float on top unless the user binds them to their window. + stayWithWindow: false }, // "What's new" popup: on, with nothing recorded as seen yet. A null marker // means "show the version you are running, once" — which is right for an @@ -86,7 +88,8 @@ function coerceClientSettings(raw: Partial | undefined): ClientS showOnAllDisplays: typeof qc.showOnAllDisplays === 'boolean' ? qc.showOnAllDisplays : d.quickChat.showOnAllDisplays, followAcrossSpaces: - typeof qc.followAcrossSpaces === 'boolean' ? qc.followAcrossSpaces : d.quickChat.followAcrossSpaces + typeof qc.followAcrossSpaces === 'boolean' ? qc.followAcrossSpaces : d.quickChat.followAcrossSpaces, + stayWithWindow: typeof qc.stayWithWindow === 'boolean' ? qc.stayWithWindow : d.quickChat.stayWithWindow }, releaseNotes: { showOnUpdate: @@ -156,6 +159,7 @@ export function updateClientQuickChat(patch: Partial): Promis if ('windowShortcut' in patch) mine.windowShortcut = patch.windowShortcut ?? null; if ('showOnAllDisplays' in patch) mine.showOnAllDisplays = patch.showOnAllDisplays; if ('followAcrossSpaces' in patch) mine.followAcrossSpaces = patch.followAcrossSpaces; + if ('stayWithWindow' in patch) mine.stayWithWindow = patch.stayWithWindow; doc.settings = coerceClientSettings({ ...cur, quickChat: { ...cur.quickChat, ...mine } }); return doc.settings; }); diff --git a/src/desktop/viewer.ts b/src/desktop/viewer.ts new file mode 100644 index 00000000..14df4f6f --- /dev/null +++ b/src/desktop/viewer.ts @@ -0,0 +1,347 @@ +import { BrowserWindow, dialog, net, protocol, session, shell, type Session } from 'electron'; +import { randomUUID } from 'node:crypto'; +import { open, readFile, stat } from 'node:fs/promises'; +import { basename, extname } from 'node:path'; +import { pathToFileURL } from 'node:url'; + +// Stem's own file viewer: a file the user clicks in a reply (a file: link, or a +// `files/…` link fetched from the server) opens in a window of Stem instead of +// another app, when Chromium can show it. Before this, an agent-written HTML +// page opened in the default browser from file://, where it could read other +// local files in some browsers. +// +// Each viewer window is closed off on its own: +// - sandboxed renderer, no preload, no Node; +// - its own in-memory session, gone when the window closes; +// - every request outside the one document is cancelled (no network at all), +// and a CSP with connect-src 'none' says the same thing a second time; +// - no navigation, no new windows, no downloads, no permissions. A web link on +// the page opens in the user's browser only after the user says yes in a +// Stem dialog that shows the whole address: the page's script can navigate +// on its own, and a URL it builds could carry what the document holds. +// +// HTML, images, audio, video and text go through the `stem-view:` scheme, which +// serves only that one file. PDF is the exception: Electron's PDF viewer runs +// only in the default session (in a private one the load fails with ERR_FAILED, +// checked on Electron 42), so a PDF loads from file: in the default session, +// sandboxed and with the same navigation guards. That viewer is the one Chrome +// uses for every PDF on the web, and a PDF runs no page script in it. + +export const VIEWER_SCHEME = 'stem-view'; +const ORIGIN = `${VIEWER_SCHEME}://doc`; + +/** Call before app ready: media needs `stream` to seek, and `standard` gives the page a real origin. */ +export function registerViewerScheme(): void { + protocol.registerSchemesAsPrivileged([ + { scheme: VIEWER_SCHEME, privileges: { standard: true, secure: true, stream: true } } + ]); +} + +export type ViewKind = 'html' | 'pdf' | 'image' | 'heic' | 'video' | 'audio' | 'text' | 'table' | 'quicklook'; + +const KINDS: Record = { + '.html': 'html', '.htm': 'html', + '.pdf': 'pdf', + '.png': 'image', '.jpg': 'image', '.jpeg': 'image', '.gif': 'image', '.webp': 'image', '.svg': 'image', '.bmp': 'image', + '.heic': 'heic', '.heif': 'heic', + '.mp4': 'video', '.mov': 'video', '.m4v': 'video', '.webm': 'video', + '.mp3': 'audio', '.m4a': 'audio', '.wav': 'audio', '.ogg': 'audio', '.flac': 'audio', + '.txt': 'text', '.log': 'text', '.json': 'text', '.md': 'text', '.yaml': 'text', '.yml': 'text', '.xml': 'text', + '.csv': 'table', '.tsv': 'table' +}; + +// Quick Look shows these read-only on macOS; it runs no macros. +const QUICK_LOOK = new Set([ + '.docx', '.xlsx', '.pptx', '.doc', '.xls', '.ppt', '.rtf', '.odt', '.ods', '.odp', '.pages', '.numbers', '.key', '.tif', '.tiff' +]); + +/** How the viewer shows a file, or undefined when it does not (the caller opens or shows it as before). */ +export function viewKind(path: string, platform: NodeJS.Platform = process.platform): ViewKind | undefined { + const ext = extname(path).toLowerCase(); + if (KINDS[ext]) return KINDS[ext]; + return platform === 'darwin' && QUICK_LOOK.has(ext) ? 'quicklook' : undefined; +} + +const MIME: Record = { + '.html': 'text/html', '.htm': 'text/html', + '.png': 'image/png', '.jpg': 'image/jpeg', '.jpeg': 'image/jpeg', '.gif': 'image/gif', '.webp': 'image/webp', + '.svg': 'image/svg+xml', '.bmp': 'image/bmp', + '.mp4': 'video/mp4', '.mov': 'video/quicktime', '.m4v': 'video/mp4', '.webm': 'video/webm', + '.mp3': 'audio/mpeg', '.m4a': 'audio/mp4', '.wav': 'audio/wav', '.ogg': 'audio/ogg', '.flac': 'audio/flac' +}; + +/** Text past this is cut, with a note: the viewer is for reading, not for a 200 MB log. */ +export const TEXT_MAX_BYTES = 4 * 1024 * 1024; +export const TABLE_MAX_ROWS = 5000; + +// The page's own CSP: scripts may run (an explainer is interactive), nothing may leave. +const DOC_CSP = + "default-src 'none'; script-src 'self' 'unsafe-inline' 'unsafe-eval' data: blob:; style-src 'self' 'unsafe-inline' data: blob:; " + + "img-src 'self' data: blob:; media-src 'self' data: blob:; font-src 'self' data:; frame-src 'self' data: blob:; " + + "connect-src 'none'; form-action 'none'; base-uri 'none'"; +// Stem's own wrapper pages run no script at all. +const WRAPPER_CSP = "default-src 'none'; style-src 'unsafe-inline'; img-src 'self' data:; media-src 'self'"; + +export function escapeHtml(text: string): string { + return text.replace(/[&<>"']/g, (c) => ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''' })[c]!); +} + +const PAGE_STYLE = ` + :root { color-scheme: light dark; } + body { margin: 0; font: 13px -apple-system, system-ui, sans-serif; background: Canvas; color: CanvasText; } + .center { min-height: 100vh; display: flex; align-items: center; justify-content: center; } + .center img, .center video { max-width: 100vw; max-height: 100vh; object-fit: contain; } + pre { margin: 0; padding: 16px; font: 12px ui-monospace, Menlo, monospace; white-space: pre-wrap; word-break: break-word; } + table { border-collapse: collapse; font: 12px ui-monospace, Menlo, monospace; } + td { border: 1px solid color-mix(in srgb, CanvasText 18%, transparent); padding: 3px 8px; white-space: nowrap; } + tr:first-child td { font-weight: 600; position: sticky; top: 0; background: Canvas; } + .note { padding: 8px 16px; opacity: .7; }`; + +function wrapperPage(title: string, body: string): string { + return `${escapeHtml(title)}${body}`; +} + +/** One CSV/TSV line split into cells, with "quoted, fields" kept whole. */ +export function splitRow(line: string, sep: string): string[] { + const cells: string[] = []; + let cell = ''; + let quoted = false; + for (let i = 0; i < line.length; i += 1) { + const c = line[i]!; + if (quoted) { + if (c === '"' && line[i + 1] === '"') { + cell += '"'; + i += 1; + } else if (c === '"') quoted = false; + else cell += c; + } else if (c === '"' && cell === '') quoted = true; + else if (c === sep) { + cells.push(cell); + cell = ''; + } else cell += c; + } + cells.push(cell); + return cells; +} + +/** The wrapper page for a text or table file. Exported for tests. */ +export function textPage(name: string, text: string, kind: 'text' | 'table', cut: boolean): string { + const note = cut ? `
Only the first ${TEXT_MAX_BYTES / 1024 / 1024} MB is shown.
` : ''; + if (kind === 'text') return wrapperPage(name, `${note}
${escapeHtml(text)}
`); + const sep = extname(name).toLowerCase() === '.tsv' ? '\t' : ','; + const lines = text.split(/\r?\n/).filter((l) => l.length > 0); + const rows = lines.slice(0, TABLE_MAX_ROWS).map((l) => `${splitRow(l, sep).map((c) => `${escapeHtml(c)}`).join('')}`); + const more = lines.length > TABLE_MAX_ROWS ? `
Only the first ${TABLE_MAX_ROWS} rows are shown.
` : ''; + return wrapperPage(name, `${note}${more}${rows.join('')}
`); +} + +/** The first TEXT_MAX_BYTES of a file, read as such: a 2 GB log never lands in the main process whole. */ +export async function readTextHead(path: string): Promise<{ text: string; cut: boolean }> { + const file = await open(path, 'r'); + try { + // One byte more tells a file of exactly the limit from a longer one. + const buf = Buffer.alloc(TEXT_MAX_BYTES + 1); + let got = 0; + while (got < buf.length) { + const { bytesRead } = await file.read(buf, got, buf.length - got, got); + if (bytesRead === 0) break; + got += bytesRead; + } + const cut = got > TEXT_MAX_BYTES; + return { text: buf.subarray(0, Math.min(got, TEXT_MAX_BYTES)).toString('utf8'), cut }; + } finally { + await file.close(); + } +} + +/** What `stem-view://doc/` serves: the page, and for media the file itself. */ +async function pageFor(path: string, kind: ViewKind, heicToDataUrl: (path: string) => Promise): Promise { + const name = basename(path); + switch (kind) { + case 'html': + return null; // the file itself + case 'image': + return wrapperPage(name, `
${escapeHtml(name)}
`); + case 'heic': { + const url = await heicToDataUrl(path); + return wrapperPage(name, url ? `
${escapeHtml(name)}
` : `
This picture could not be shown.
`); + } + case 'video': + return wrapperPage(name, `
`); + case 'audio': + return wrapperPage(name, `
`); + case 'text': + case 'table': { + const { text, cut } = await readTextHead(path); + return textPage(name, text, kind, cut); + } + default: + return null; + } +} + +/** Cancel every request but the document's own. */ +function lockDown(ses: Session, allowed: (url: string) => boolean): void { + ses.setPermissionRequestHandler((_wc, _permission, callback) => callback(false)); + ses.setPermissionCheckHandler(() => false); + ses.on('will-download', (event) => event.preventDefault()); + ses.webRequest.onBeforeRequest((details, callback) => callback({ cancel: !allowed(details.url) })); +} + +/** The answer from the "open this link?" dialog. */ +export interface LinkAnswer { + open: boolean; + /** The user ticked "block other links from this page": every later link is refused quietly. */ + block: boolean; +} + +/** + * What a viewer window does with a web address its page tries to open. Nothing + * opens without the user's yes: Electron does not say whether a click started + * a navigation, and a page script can navigate by itself. One question at a + * time; links that come while it is open are dropped, so a page cannot pile + * up dialogs. Exported for tests. + */ +export function externalLinkGate(ask: (url: string) => Promise, openUrl: (url: string) => void): (url: string) => void { + let asking = false; + let blocked = false; + return (url) => { + if (blocked || asking || !/^https?:/i.test(url)) return; + asking = true; + void ask(url) + .then((a) => { + if (a.block) blocked = true; + if (a.open) openUrl(url); + }) + .catch(() => undefined) // quiet: no answer (the window closed) opens nothing. + .finally(() => (asking = false)); + }; +} + +/** + * The dialog shows the whole address, since that is what the user approves. + * A longer one would not fit, so it is not offered at all. + */ +export const LINK_MAX_CHARS = 2000; + +async function askOpenLink(win: BrowserWindow, url: string): Promise { + if (win.isDestroyed()) return { open: false, block: false }; + const tooLong = url.length > LINK_MAX_CHARS; + const r = await dialog.showMessageBox(win, { + type: tooLong ? 'warning' : 'question', + message: tooLong ? 'This page tried to open a link that is too long to show.' : 'Open this link in your browser?', + detail: tooLong + ? `It goes to ${new URL(url).host} and was not opened. Copy the link from the page if you trust it.` + : `The page you are viewing wants to open:\n\n${url}\n\nAnything in the address goes to that site.`, + buttons: tooLong ? ['OK'] : ['Cancel', 'Open in Browser'], + defaultId: 0, + cancelId: 0, + checkboxLabel: 'Block other links from this page', + checkboxChecked: false + }); + return { open: !tooLong && r.response === 1, block: r.checkboxChecked }; +} + +function guardContents(win: BrowserWindow, title: string): void { + const wc = win.webContents; + const external = externalLinkGate( + (url) => askOpenLink(win, url), + (url) => void shell.openExternal(url).catch(() => undefined) + ); + wc.setWindowOpenHandler(({ url }) => { + external(url); + return { action: 'deny' }; + }); + wc.on('will-navigate', (event, url) => { + // An in-page #anchor is not a navigation away. + try { + const next = new URL(url); + const cur = new URL(wc.getURL()); + if (next.origin === cur.origin && next.pathname === cur.pathname && next.search === cur.search) return; + } catch { + // quiet: an unparsable target is refused like any other. + } + event.preventDefault(); + external(url); + }); + wc.on('will-redirect', (event) => event.preventDefault()); + wc.on('will-attach-webview', (event) => event.preventDefault()); + // The window keeps the file's name: a page must not pass itself off as Stem. + win.on('page-title-updated', (event) => event.preventDefault()); + win.setTitle(title); +} + +export interface ViewerDeps { + /** HEIC → a JPEG `data:` URL (server/pi/attachments.ts imagePreviewDataUrl). */ + heicToDataUrl: (path: string) => Promise; + /** A window for Quick Look to attach to (macOS). */ + anyWindow: () => BrowserWindow | null; +} + +/** + * Show `path` in Stem. Answers false when the viewer does not show this type, + * so the caller opens or reveals it the way it did before. + */ +export async function openInViewer(path: string, deps: ViewerDeps): Promise { + const kind = viewKind(path); + if (!kind) return false; + const info = await stat(path).catch(() => null); + if (!info?.isFile()) return false; + const name = basename(path); + + if (kind === 'quicklook') { + const win = deps.anyWindow(); + if (!win) return false; + win.previewFile(path, name); + return true; + } + + // No "persist:": in memory only. Not for PDF (see the note at the top). + const ses = kind === 'pdf' ? session.defaultSession : session.fromPartition(`stem-viewer-${randomUUID()}`); + const fileUrl = pathToFileURL(path).href; + const page = await pageFor(path, kind, deps.heicToDataUrl); + + if (kind !== 'pdf') { + lockDown(ses, (url) => url.startsWith(`${ORIGIN}/`) || /^(data|blob):/i.test(url)); + ses.protocol.handle(VIEWER_SCHEME, async (request) => { + const { pathname } = new URL(request.url); + if (pathname === '/' && page !== null) { + return new Response(page, { headers: { 'content-type': 'text/html; charset=utf-8', 'content-security-policy': WRAPPER_CSP } }); + } + if (pathname === '/' && kind === 'html') { + return new Response(await readFile(path), { headers: { 'content-type': 'text/html; charset=utf-8', 'content-security-policy': DOC_CSP } }); + } + if (pathname === '/file' && kind !== 'html') { + // net.fetch on the one file answers range requests, so video can seek. + const res = await net.fetch(fileUrl, { headers: request.headers, bypassCustomProtocolHandlers: true }); + const headers = new Headers(res.headers); + const mime = MIME[extname(path).toLowerCase()]; + if (mime) headers.set('content-type', mime); + return new Response(res.body, { status: res.status, headers }); + } + return new Response('Not found', { status: 404 }); + }); + } + + const win = new BrowserWindow({ + width: kind === 'audio' ? 520 : 1100, + height: kind === 'audio' ? 200 : 820, + title: name, + autoHideMenuBar: true, + show: !process.env.STEM_BACKGROUND, + webPreferences: { + session: ses, + sandbox: true, + contextIsolation: true, + nodeIntegration: false, + webviewTag: false, + spellcheck: false, + plugins: kind === 'pdf', + // Only a page the user opened may run script; Stem's own wrappers need none. + javascript: kind === 'html' || kind === 'pdf' + } + }); + guardContents(win, name); + await win.loadURL(kind === 'pdf' ? fileUrl : `${ORIGIN}/`); + return true; +} diff --git a/src/desktop/zoom.ts b/src/desktop/zoom.ts new file mode 100644 index 00000000..d5ce1e95 --- /dev/null +++ b/src/desktop/zoom.ts @@ -0,0 +1,121 @@ +import { readFile, writeFile } from 'node:fs/promises'; +import { join } from 'node:path'; +import type { BrowserWindow, Input } from 'electron'; +import { host } from '../server/host'; + +// Page zoom for the main window: ⌘+ / ⌘= bigger, ⌘- smaller, ⌘0 back to 100% +// (Ctrl off macOS). +// +// Electron's zoomIn menu role listens for CmdOrCtrl+Plus only, which on a US +// keyboard means ⌘⇧= — the plain ⌘= every browser accepts did nothing. Other +// layouts put +, - and 0 on different keys again (Slovak has + on the 1 key). So +// the keys are caught here, in before-input-event, by the character the layout +// produced first and by the physical key second; preventDefault keeps the menu +// from acting on the same press. +// +// The level is remembered in zoom.json next to client.json and put back on every +// load. file:// zoom is per window in Electron, so the Quick Chat overlay and the +// progress pill keep their own fixed size. + +export type ZoomAction = 'in' | 'out' | 'reset'; + +/** Chrome's zoom steps, trimmed to the range a chat window is still usable in. */ +export const ZOOM_STEPS = [0.5, 0.67, 0.75, 0.8, 0.9, 1, 1.1, 1.25, 1.5, 1.75, 2, 2.5, 3] as const; + +type KeyInput = Pick; + +/** The zoom a key press asks for, or null when it is not a zoom key. */ +export function zoomActionFor(input: KeyInput, mac: boolean): ZoomAction | null { + if (input.type !== 'keyDown' || input.alt) return null; + const mod = mac ? input.meta && !input.control : input.control && !input.meta; + if (!mod) return null; + switch (input.key) { + case '+': + case '=': + return 'in'; + case '-': + case '_': + return 'out'; + case '0': + return input.shift ? null : 'reset'; + } + switch (input.code) { + case 'Equal': + case 'NumpadAdd': + return 'in'; + case 'Minus': + case 'NumpadSubtract': + return 'out'; + case 'Digit0': + case 'Numpad0': + return input.shift ? null : 'reset'; + } + return null; +} + +/** The factor one step from `current`; 1 for a reset. */ +export function nextZoomFactor(current: number, action: ZoomAction): number { + if (action === 'reset') return 1; + if (action === 'in') return ZOOM_STEPS.find((s) => s > current + 0.001) ?? ZOOM_STEPS[ZOOM_STEPS.length - 1]; + for (let i = ZOOM_STEPS.length - 1; i >= 0; i--) if (ZOOM_STEPS[i] < current - 0.001) return ZOOM_STEPS[i]; + return ZOOM_STEPS[0]; +} + +function clampFactor(value: unknown): number { + if (typeof value !== 'number' || !Number.isFinite(value)) return 1; + return Math.min(ZOOM_STEPS[ZOOM_STEPS.length - 1], Math.max(ZOOM_STEPS[0], value)); +} + +function zoomFilePath(): string { + return join(host().stateRoot(), 'zoom.json'); +} + +let factor = 1; +let loaded: Promise | null = null; + +function loadOnce(): Promise { + loaded ??= readFile(zoomFilePath(), 'utf8') + .then((text) => { + factor = clampFactor((JSON.parse(text) as { factor?: unknown }).factor); + }) + .catch(() => { + factor = 1; + }); + return loaded; +} + +function save(): void { + void writeFile(zoomFilePath(), JSON.stringify({ factor }) + '\n').catch(() => {}); +} + +let target: BrowserWindow | null = null; + +/** Step the main window's zoom; also what the View menu items call. */ +export function applyZoom(action: ZoomAction): void { + void loadOnce().then(() => { + factor = nextZoomFactor(factor, action); + save(); + if (target && !target.isDestroyed()) target.webContents.setZoomFactor(factor); + }); +} + +/** Catch the zoom keys on the main window and keep its zoom across loads. */ +export function installZoom(win: BrowserWindow, mac: boolean): void { + target = win; + const contents = win.webContents; + const restore = (): void => { + void loadOnce().then(() => { + if (!win.isDestroyed()) contents.setZoomFactor(factor); + }); + }; + contents.on('did-finish-load', restore); + contents.on('before-input-event', (event, input) => { + const action = zoomActionFor(input, mac); + if (!action) return; + event.preventDefault(); + applyZoom(action); + }); + win.on('closed', () => { + if (target === win) target = null; + }); +} diff --git a/src/preload/dictation-capture.ts b/src/preload/dictation-capture.ts index 8f12be13..3d615f7b 100644 --- a/src/preload/dictation-capture.ts +++ b/src/preload/dictation-capture.ts @@ -24,7 +24,8 @@ export async function startCapture(onBlock: (samples: Float32Array) => void): Pr ? 'No microphone is connected to this computer.' : name === 'NotAllowedError' ? 'Stem is not allowed to use the microphone. Allow it in the system’s privacy settings.' - : `The microphone could not be opened: ${e instanceof Error ? e.message : String(e)}` + : `The microphone could not be opened: ${e instanceof Error ? e.message : String(e)}`, + { cause: e } ); } context = new AudioContext({ sampleRate: SAMPLE_RATE }); diff --git a/src/preload/index.ts b/src/preload/index.ts index c341139a..a026e718 100644 --- a/src/preload/index.ts +++ b/src/preload/index.ts @@ -1,6 +1,7 @@ import { contextBridge, ipcRenderer, webUtils } from 'electron'; import { startCapture, stopCapture } from './dictation-capture'; import type { + MailChange, FolderSettings, ServerUpgradeStatus, ActivitySnapshot, @@ -56,8 +57,11 @@ import type { QuickChatSettings, QuickChatSessionStarted, QuickChatStatus, + QuickChatTabs, + QuickChatMini, MailComposeInput, Persona, + Person, ScheduledTask, SkillProposal, SkillsMode, @@ -130,6 +134,9 @@ const api: StemApi = { listSkills: () => ipcRenderer.invoke('skills:list'), setSkillEnabled: (slug: string, enabled: boolean) => ipcRenderer.invoke('skills:setEnabled', slug, enabled), removeSkill: (slug: string) => ipcRenderer.invoke('skills:remove', slug), + setSkillRecurrence: (slug: string, recurs: string) => ipcRenderer.invoke('skills:setRecurrence', slug, recurs), + listSkillVersions: (slug: string) => ipcRenderer.invoke('skills:versions', slug), + restoreSkillVersion: (slug: string, version: number) => ipcRenderer.invoke('skills:restore', slug, version), curateSkills: () => ipcRenderer.invoke('skills:curate'), learnFromChat: (threadId: string, focus?: string) => ipcRenderer.invoke('skills:learn', threadId, focus), skillsResetStatus: () => ipcRenderer.invoke('skills:resetStatus'), @@ -147,6 +154,8 @@ const api: StemApi = { removeFilesSubdir: (name: string) => ipcRenderer.invoke('files:rmdir', name), revealFiles: (rel?: string) => ipcRenderer.invoke('files:reveal', rel), downloadFile: (rel: string) => ipcRenderer.invoke('files:download', rel), + openFilesItem: (rel: string) => ipcRenderer.invoke('files:open', rel), + openScratchItem: (threadId: string, rel: string) => ipcRenderer.invoke('scratch:open', threadId, rel), previewImage: (path: string) => ipcRenderer.invoke('files:preview', path), previewImageData: (dataBase64: string, mime?: string, name?: string) => ipcRenderer.invoke('files:previewData', dataBase64, mime, name), @@ -463,7 +472,10 @@ const api: StemApi = { searchChats: (query: string) => ipcRenderer.invoke('chats:search', query), openChat: (threadId: string) => ipcRenderer.invoke('chats:open', threadId), readChatHistory: (threadId: string) => ipcRenderer.invoke('chats:history', threadId), + cachedChat: (threadId: string) => ipcRenderer.invoke('chats:cached', threadId), getChatImage: (threadId: string, imageId: string) => ipcRenderer.invoke('chats:image', threadId, imageId), + getChatAudio: (threadId: string, audioId: string) => ipcRenderer.invoke('chats:audio', threadId, audioId), + saveAudioToDownloads: (dataUrl: string, name: string) => ipcRenderer.invoke('audio:saveToDownloads', dataUrl, name), saveImageToDownloads: (dataUrl: string, name: string) => ipcRenderer.invoke('image:saveToDownloads', dataUrl, name), copyImage: (dataUrl: string) => ipcRenderer.invoke('image:copy', dataUrl), rollbackToTurn: (threadId: string, turnId: string) => @@ -472,6 +484,7 @@ const api: StemApi = { compactChat: (threadId: string, instructions?: string) => ipcRenderer.invoke('chats:compact', threadId, instructions), voiceConnect: (offerSdp: string) => ipcRenderer.invoke('voice:connect', offerSdp), voiceCheck: () => ipcRenderer.invoke('voice:check'), + chatgptPlanUsage: () => ipcRenderer.invoke('providers:chatgptUsage'), listPins: (threadId: string) => ipcRenderer.invoke('pins:list', threadId), addPin: (threadId: string, input: ChatPinInput) => ipcRenderer.invoke('pins:add', threadId, input), updatePin: (threadId: string, pinId: string, patch: ChatPinPatch) => @@ -511,7 +524,19 @@ const api: StemApi = { consolidatePersonaNotes: (personaId: string) => ipcRenderer.invoke('personas:notes:consolidate', personaId), + listPeople: () => ipcRenderer.invoke('people:list'), + savePerson: (person: Person) => ipcRenderer.invoke('people:save', person), + deletePerson: (id: string) => ipcRenderer.invoke('people:delete', id), + personFacts: (id: string) => ipcRenderer.invoke('people:facts', id), + suggestPeople: () => ipcRenderer.invoke('people:suggest'), + onPeopleChanged: (listener: () => void) => { + const handler = () => listener(); + ipcRenderer.on('people:changed', handler); + return () => ipcRenderer.removeListener('people:changed', handler); + }, + listMail: () => ipcRenderer.invoke('mail:list'), + listMailConversations: (conversationIds: string[]) => ipcRenderer.invoke('mail:conversations', conversationIds), getMailWork: (conversationId: string) => ipcRenderer.invoke('mail:work', conversationId), onMailWorkChanged: (listener: (event: { conversationId: string }) => void) => { const handler = (_event: Electron.IpcRendererEvent, value: { conversationId: string }) => listener(value); @@ -519,6 +544,7 @@ const api: StemApi = { return () => ipcRenderer.removeListener('mail:workChanged', handler); }, composeMail: (input: MailComposeInput) => ipcRenderer.invoke('mail:compose', input), + stageAttachment: (att: TurnAttachment) => ipcRenderer.invoke('attachments:stage', att), // The third argument rides only when there is something in it: a server // predating it rejects a 3-arg call outright, and a plain reply must keep // working across that skew. @@ -528,6 +554,8 @@ const api: StemApi = { : ipcRenderer.invoke('mail:reply', conversationId, body), addMailParticipant: (conversationId: string, personaId: string) => ipcRenderer.invoke('mail:addParticipant', conversationId, personaId), + setMailParticipants: (conversationId: string, personaIds: string[]) => + ipcRenderer.invoke('mail:setParticipants', conversationId, personaIds), stopMail: (conversationId: string) => ipcRenderer.invoke('mail:stop', conversationId), // The edited draft body rides only for a send draft (older servers reject a 3rd arg). resolveMailApproval: (itemId: string, decision: 'allow' | 'deny', body?: string) => @@ -581,8 +609,8 @@ const api: StemApi = { ipcRenderer.on('personas:changed', handler); return () => ipcRenderer.removeListener('personas:changed', handler); }, - onMailChanged: (listener: () => void) => { - const handler = () => listener(); + onMailChanged: (listener: (change?: MailChange) => void) => { + const handler = (_e: unknown, change?: MailChange) => listener(change ?? undefined); ipcRenderer.on('mail:changed', handler); return () => ipcRenderer.removeListener('mail:changed', handler); }, @@ -732,6 +760,26 @@ const api: StemApi = { openQuickChatPrivacy: (which: 'screen' | 'accessibility') => ipcRenderer.invoke('quickchat:openPrivacy', which), openManageFromQuickChat: (tab: ManageTabId, intent?: ManageIntent) => ipcRenderer.invoke('quickchat:openManage', tab, intent), compactQuickChat: (chip?: boolean) => ipcRenderer.invoke('quickchat:compact', chip === true), + newQuickChatTab: () => ipcRenderer.invoke('quickchat:newTab'), + switchQuickChatTab: (id: string) => ipcRenderer.invoke('quickchat:switchTab', id), + closeQuickChatTab: (id: string) => ipcRenderer.invoke('quickchat:closeTab', id), + onQuickChatTabs: (listener: (tabs: QuickChatTabs) => void) => { + const handler = (_e: unknown, tabs: QuickChatTabs) => listener(tabs); + ipcRenderer.on('quickchat:tabs', handler); + return () => ipcRenderer.removeListener('quickchat:tabs', handler); + }, + minimizeQuickChat: () => ipcRenderer.invoke('quickchat:minimize'), + expandQuickChat: () => ipcRenderer.invoke('quickchat:expand'), + onQuickChatMini: (listener: (mini: QuickChatMini | null) => void) => { + const handler = (_e: unknown, mini: QuickChatMini | null) => listener(mini); + ipcRenderer.on('quickchat:mini', handler); + return () => ipcRenderer.removeListener('quickchat:mini', handler); + }, + onQuickChatCloseTab: (listener: (request: { id: string }) => void) => { + const handler = (_e: unknown, request: { id: string }) => listener(request); + ipcRenderer.on('quickchat:closeTabRequest', handler); + return () => ipcRenderer.removeListener('quickchat:closeTabRequest', handler); + }, onQuickChatFocus: (listener: (focus: QuickChatFocus) => void) => { const handler = (_e: unknown, focus: QuickChatFocus) => listener(focus); ipcRenderer.on('quickchat:focus', handler); diff --git a/src/renderer/App.tsx b/src/renderer/App.tsx index 9b6fc866..76047f72 100644 --- a/src/renderer/App.tsx +++ b/src/renderer/App.tsx @@ -6,7 +6,9 @@ import type { AppSettings, AuthProviderId, ChatFormat, + ChatHistory, ChatListResult, + ChatMessage, ChatSummary, EscapeAction, MessageMeta, @@ -22,6 +24,7 @@ import type { ManageTabId } from '../shared/types'; import { AUTH_PROVIDER_IDS, providerName } from '../shared/providers'; +import { chatAfterArchive } from './chats/archive-next'; import { emptyInboxState, isUnread, placement, withArchived, withRead, type InboxState } from '../shared/inbox'; import { previewText } from '../shared/plain-text'; import { resendAttachments } from './attachments'; @@ -39,7 +42,7 @@ import { useApprovals } from './manage/approvalStore'; import { DeleteThreadDialog } from './DeleteThreadDialog'; import { ShareDialog } from './share/ShareDialog'; import type { ShareSource } from '../shared/share'; -import { CHATS_TAB_IDS, CHATS_TAB_KEY, type ChatsTab } from './chats/ChatList'; +import { CHATS_TAB_IDS, CHATS_TAB_KEY, type ChatsTab, type SendingDraftRow } from './chats/ChatList'; import { persistReturnChatId, readReturnChatId, @@ -98,6 +101,20 @@ const DRAFT = '__draft__'; /** How long a spoken request waits for the chat to finish its current reply. */ const VOICE_IDLE_WAIT_MS = 3 * 60_000; +/** A new chat between Enter and the server taking its first message (see sendingDrafts). */ +interface SendingDraft { + turnId: string; + /** The DRAFT generation it was sent from. */ + seq: number; + title: string; + /** The draft's messages as sent, the user's own bubble last. */ + messages: ChatMessage[]; + folderId: string | null; + private: boolean; + /** Set when the start failed: the message never reached the server. */ + error?: unknown; +} + // "This smells like an auth failure" match on a failed turn's error text. Used as // the fallback classifier for API-key/local providers, where the getApiKey probe // can't validate a stored key server-side. (OAuth providers are classified by the @@ -206,6 +223,14 @@ export default function App() { // returned yet (a brand-new thread isn't listed until its first turn persists). // Keyed by threadId; dropped once the real list includes them. const [pendingChats, setPendingChats] = useState>({}); + // New chats whose first send has not been taken by the server yet, keyed by + // the turn id. Until the start returns there is no thread id and so no row + // in pendingChats: a 10 MB PDF on a slow uplink is minutes of that, and a + // user who opened another chat meanwhile lost sight of theirs — for good if + // the upload then failed. ChatList shows these as Sending… / Not sent rows. + const [sendingDrafts, setSendingDrafts] = useState>({}); + const sendingDraftsRef = useRef(sendingDrafts); + sendingDraftsRef.current = sendingDrafts; const inspectorScroll = useOverlayScrollbar(); // Imperative handle to the active ChatView so the drop overlay can push files // ("Add to this conversation") into its composer. @@ -224,6 +249,8 @@ export default function App() { // Navigation state the event pipeline and IPC continuations need synchronously. const activeThreadIdRef = useRef(activeThreadId); + // The Chats tab's rows top to bottom, written by ChatList on every render. + const chatOrderRef = useRef([]); activeThreadIdRef.current = activeThreadId; // Bumped every time the DRAFT slice is reset (New chat / Quick Chat). Captured // at send time so a turn that resolves late only adopts its real thread id when @@ -859,21 +886,48 @@ export default function App() { ...(sendKey === DRAFT ? { draftGeneration: sendSeq, captureDraftMessages: true } : {}), start: async (input) => { hooks?.onTurnId?.(input.turnId); - const result = await window.stem.startTurn({ - input: input.text, - turnId: input.turnId, - threadId: sendKey === DRAFT ? undefined : sendKey, - // Only meaningful on the creating turn; the server stores it with the thread. - ...(sendKey === DRAFT && sendPrivate ? { private: true } : {}), - model: modelId ?? undefined, - effort: effort ?? undefined, - serviceTier, - // Only meaningful on the creating turn, like `private`. - ...(sendKey === DRAFT ? { format: defaultFormat } : {}), - attachments: input.attachments.length ? input.attachments : undefined, - // A draft card's "Practice run": this send starts it (recorder-store). - ...(sendKey !== DRAFT ? practiceInput(sendKey) : {}) - }); + const tracked = sendKey === DRAFT ? input.turnId : null; + if (tracked) { + const draft: SendingDraft = { + turnId: tracked, + seq: sendSeq, + title: previewText(text) || 'New chat', + // Registered by sendTurn before it calls start. + messages: core.pendingSends.get(DRAFT)?.draftMessages ?? [], + folderId: sendFolder ?? null, + private: sendPrivate + }; + setSendingDrafts((prev) => ({ ...prev, [tracked]: draft })); + } + let result: StartTurnResult; + try { + result = await window.stem.startTurn({ + input: input.text, + turnId: input.turnId, + threadId: sendKey === DRAFT ? undefined : sendKey, + // Only meaningful on the creating turn; the server stores it with the thread. + ...(sendKey === DRAFT && sendPrivate ? { private: true } : {}), + model: modelId ?? undefined, + effort: effort ?? undefined, + serviceTier, + // Only meaningful on the creating turn, like `private`. + ...(sendKey === DRAFT ? { format: defaultFormat } : {}), + attachments: input.attachments.length ? input.attachments : undefined, + // A draft card's "Practice run": this send starts it (recorder-store). + ...(sendKey !== DRAFT ? practiceInput(sendKey) : {}) + }); + } catch (e) { + if (tracked) { + // Failed in plain sight: the draft shows the error and Retry itself. + const seen = draftSeqRef.current === sendSeq && activeThreadIdRef.current === null; + setSendingDrafts(({ [tracked]: draft, ...rest }) => + draft && !seen ? { ...rest, [tracked]: { ...draft, error: e ?? 'failed' } } : rest + ); + } + throw e; + } + // Taken: onStarted gives it a real row (or it was handled in place). + if (tracked) setSendingDrafts(({ [tracked]: _gone, ...rest }) => rest); hooks?.onResult?.(result); return result; }, @@ -1056,6 +1110,10 @@ export default function App() { const existing = prev[threadId]; return { ...prev, [threadId]: mergeQuickChatHandoff(existing, payload) }; }); + // The snapshot is what the panel saw, and a panel can miss events (a + // hidden or closing tab). A settled conversation is checked against the + // server's transcript; a running one is, when its turn settles here. + if (!transferredRunning) void refreshThreadHistory(threadId); if (transferredRunning && transferredTurnId) { const lastUser = [...adopted].reverse().find((m) => m.role === 'user'); if (lastUser) { @@ -1085,7 +1143,7 @@ export default function App() { })); refreshChats(); }); - }, [core, refreshChats, noteChatOpened]); + }, [core, refreshChats, noteChatOpened, refreshThreadHistory]); // Quick Chat session started → show the thread in the sidebar immediately // (the backend won't list it until its first turn persists), reusing the optimistic @@ -1201,8 +1259,65 @@ export default function App() { useShortcut('open-settings', () => { setShowInspector(true); setManageTab('settings'); + requestManageIntent({ kind: 'settings-search' }); }); + // Back to a new chat whose first message the server has not taken (see + // sendingDrafts). Opening another chat leaves the DRAFT slice in place, but + // New chat replaces it — then the sent snapshot is put back. Reclaiming the + // draft generation is what lets a start that is still running adopt its real + // thread id and keep focus, exactly as if the user had never left. + const openSendingDraft = useCallback( + (turnId: string) => { + const draft = sendingDraftsRef.current[turnId]; + if (!draft) return; + const pending = core.pendingSends.get(DRAFT); + // A newer new-chat send owns the DRAFT key right now; taking it back would + // put this chat over that one. The row stays; it resolves on its own. + if (pending && pending.turnId !== turnId) return; + // Still running but no longer pending: the start has just returned, and + // the real row is about to replace this one. + if (!draft.error && !pending) return; + draftSeqRef.current = draft.seq; + openGateRef.current.invalidate(); + const userMsg = draft.messages[draft.messages.length - 1]; + const slice = core.store.getThread(DRAFT); + if (userMsg && !slice?.messages.some((m) => m.id === userMsg.id)) { + core.store.replace( + DRAFT, + draft.error + ? appendSystemMessage( + { + ...EMPTY_STATE, + messages: draft.messages.map((m) => (m.id === userMsg.id ? { ...m, sendFailed: true } : m)) + }, + draft.error + ) + : { ...EMPTY_STATE, messages: draft.messages, running: true, status: 'running' } + ); + } + pendingDraftFolderRef.current = draft.folderId; + setDraftFolderId(draft.folderId); + pendingDraftPrivateRef.current = draft.private; + setDraftPrivate(draft.private); + setMailView(null); + activeThreadIdRef.current = null; + setActiveThreadId(null); + // A failed one now lives in the draft itself, with Retry on its bubble. + if (draft.error) setSendingDrafts(({ [turnId]: _gone, ...rest }) => rest); + }, + [core] + ); + // Only the ones the user is not looking at: the open draft shows itself. + const viewingDraftSeq = activeThreadId === null && mailView === null ? draftSeqRef.current : null; + const sendingDraftRows = useMemo( + () => + Object.values(sendingDrafts) + .filter((d) => d.error !== undefined || d.seq !== viewingDraftSeq) + .map((d) => ({ id: d.turnId, title: d.title, failed: d.error !== undefined })), + [sendingDrafts, viewingDraftSeq] + ); + const openChat = useCallback( // `userNavigation` separates the user opening a chat (clicks, alerts, forks — // which may pin the Inbox's Return-to-chat row) from the system re-opening @@ -1240,15 +1355,52 @@ export default function App() { void refreshThreadHistory(threadId); return; } - const history = await window.stem.openChat(threadId); - if (!openGateRef.current.isCurrent(request) || deletedThreadsRef.current.has(threadId)) return; + // Not loaded in this window yet. A remote install keeps this Mac's own copy + // of recent transcripts on disk: paint that now, and let the server's + // answer replace it when it lands. On a slow link — or one busy streaming + // two running chats — that round trip used to leave the previous chat on + // screen for seconds. The copy stays un-hydrated (it is not a complete, + // current read), so a failed fetch leaves the next open asking again. + let atRequest = existing; + let shown = false; + const cached = await window.stem.cachedChat?.(threadId).catch(() => null); + if (cached && openGateRef.current.isCurrent(request) && !deletedThreadsRef.current.has(threadId)) { + core.store.update((prev) => ({ + ...prev, + [threadId]: { ...mergeRefreshedThread(cached, prev[threadId], existing), hydrated: false } + })); + atRequest = core.store.getThread(threadId); + shown = true; + setActiveThreadId(threadId); + if (userNavigation) noteChatOpened(threadId); + } + let history: ChatHistory; + try { + history = await window.stem.openChat(threadId); + } catch (e) { + // The open itself failed — most often a Quick Chat hand-off that never + // got its snapshot. A cached copy is already on screen and nothing else + // would ever replace it, so read the transcript plainly (no hand-off, no + // pre-warm) rather than leave the stale copy standing. + if (!shown) throw e; + history = await window.stem.readChatHistory(threadId); + if (history.offline) throw e; + } + if (deletedThreadsRef.current.has(threadId)) return; + // The server's answer is the transcript, whoever moved the view since: a + // chat painted from the cache, or adopted from a Quick Chat hand-off while + // this read was on the wire, takes it — otherwise the stale copy would be + // what the user comes back to. Only navigation is the gate's to cancel. + const current = openGateRef.current.isCurrent(request); + if (!current && !shown && !core.store.getThread(history.threadId)) return; core.store.update((prev) => ({ ...prev, // An entire turn can start and settle while the disk read is pending, so // `running` alone cannot identify a raced live slice. Compare against the // state captured when the request began and merge any newer events. - [history.threadId]: mergeRefreshedThread(history, prev[history.threadId], existing) + [history.threadId]: mergeRefreshedThread(history, prev[history.threadId], atRequest) })); + if (!current || shown) return; setActiveThreadId(history.threadId); if (userNavigation) noteChatOpened(history.threadId); }, @@ -1464,8 +1616,20 @@ export default function App() { (inbox) => withArchived(inbox, threadIds, archived, now), () => window.stem.setInboxArchived(threadIds, archived) ); + // Archiving the open chat opens the next one in the list (the one above + // when it was the last), so a run of chats can be answered or archived one + // after another. Nothing left: the draft, any typed text kept. + const active = activeThreadIdRef.current; + if (archived && active && threadIds.includes(active)) { + const next = chatAfterArchive(chatOrderRef.current, active, threadIds); + if (next) void openChat(next); + else { + openGateRef.current.invalidate(); + setActiveThreadId(null); + } + } }, - [mutateInbox] + [mutateInbox, openChat] ); // ---- mail actions the rail and centre pane share ---- @@ -1490,20 +1654,25 @@ export default function App() { }, [mailApi] ); - /** Send from the compose form, then open the new conversation: the mail you - * just sent stays in view, with the personas' progress on it, instead of - * vanishing into a folded Sent section. */ + /** Send from the compose form and close it, like email: the mail goes to + * Sent and the answer comes back to the Inbox. A failed send throws, so the + * form stays open with its text and the error. */ const onComposeSend = useCallback( async (input: Parameters[0] | ExternalComposeInput) => { - const before = new Set(mailRef.current.conversations.map((c) => c.id)); - const list = 'external' in input ? await mailApi.composeExternal(input) : await mailApi.compose(input); - const created = list.conversations - .filter((c) => !before.has(c.id)) - .sort((a, b) => b.createdAt - a.createdAt)[0]; - if (created) openMail(created.id); - else setMailView(null); + if ('external' in input) await mailApi.composeExternal(input); + else await mailApi.compose(input); + setMailView((v) => (v?.kind === 'compose' ? null : v)); + }, + [mailApi] + ); + /** A reply, sent, closes its conversation the same way; a failed one keeps + * it open so the failed send (with Retry) stays in view. */ + const onMailReply = useCallback( + async (conversationId: string, body: string, attachments?: TurnAttachment[]) => { + if (!(await mailApi.reply(conversationId, body, attachments))) return; + setMailView((v) => (v?.kind === 'conversation' && v.id === conversationId ? null : v)); }, - [mailApi, openMail] + [mailApi] ); const onShareMessage = useCallback((turnId: string) => { const threadId = activeThreadIdRef.current; @@ -1595,8 +1764,8 @@ export default function App() { setMailView(null); return; } - // The chat stays open: archiving tidies the list, it doesn't close what you - // are reading. Pressed again on an archived chat, it brings it back. + // Archiving moves on to the next chat (onSetArchived). Pressed on an + // archived chat opened from the Archived section, it brings it back. const id = activeThreadIdRef.current; if (!id) return; const chat = displayList.chats.find((c) => c.threadId === id); @@ -1989,14 +2158,12 @@ export default function App() { items={mail.items} currentSys={mail.sys} personas={mailApi.personas} - onReply={(body, attachments) => - void mailApi.reply(conversation.id, body, attachments) - } + onReply={(body, attachments) => void onMailReply(conversation.id, body, attachments)} pending={mailApi.pending.filter((p) => p.conversationId === conversation.id)} onRetrySend={mailApi.retrySend} onDropSend={mailApi.dropSend} - onAddParticipant={(personaId) => - mailApi.addParticipant(conversation.id, personaId) + onSetParticipants={(to) => + mailApi.setParticipants(conversation.id, conversation.participants, to) } onStop={() => void mailApi.stop(conversation.id)} onShare={(itemId) => @@ -2075,6 +2242,8 @@ export default function App() { modelId={modelId} onSelectModel={onSelectModel} onOpen={openChat} + sendingDrafts={sendingDraftRows} + onOpenSendingDraft={openSendingDraft} onNewChat={newConversation} onCreateFolder={onCreateFolder} onRenameFolder={onRenameFolder} @@ -2087,6 +2256,7 @@ export default function App() { onMoveChat={onMoveChat} onSetRead={onSetRead} onSetArchived={onSetArchived} + chatOrderRef={chatOrderRef} onWriteSubject={onWriteSubject} mail={mail} personas={mailApi.personas} diff --git a/src/renderer/RecallRecommendation.tsx b/src/renderer/RecallRecommendation.tsx index e0ab3230..beca7e1f 100644 --- a/src/renderer/RecallRecommendation.tsx +++ b/src/renderer/RecallRecommendation.tsx @@ -14,7 +14,7 @@ import { recallSetupStatus, recommendedRetrievalPatch } from '../shared/recall-r /** Human name for the stages a setup is running, for the "you have X" line. */ function describe(retrieval: RetrievalSettings): string { - const { embedOk, rerankOk, factOk } = recallSetupStatus(retrieval); + const { embedOk, rerankOk } = recallSetupStatus(retrieval); const parts: string[] = []; if (!embedOk) { const e = retrieval.embeddings; @@ -23,8 +23,6 @@ function describe(retrieval: RetrievalSettings): string { if (!rerankOk) { const r = retrieval.reranker; parts.push(r.mode === 'off' ? 'no reranker' : `the ${r.localModel} reranker`); - } else if (!factOk) { - parts.push('the Qwen3 reranker alone'); } return parts.join(' and '); } @@ -41,11 +39,9 @@ export function RecallRecommendation({ const [error, setError] = useState(null); const patch = recommendedRetrievalPatch(retrieval); if (!patch) return null; - const { rerankOk, factOk } = recallSetupStatus(retrieval); - // One download per stage the patch moves: the embedder (and a re-index), the - // Qwen3 reranker, and GTE on top of it. + // One download per stage the patch moves: the embedder (and a re-index) and GTE. const embedChanges = Boolean(patch.embeddings); - const downloads = (embedChanges ? 1 : 0) + (!rerankOk ? 1 : 0) + (!factOk ? 1 : 0); + const downloads = (embedChanges ? 1 : 0) + (patch.reranker ? 1 : 0); async function apply() { if (!patch) return; diff --git a/src/renderer/assets.d.ts b/src/renderer/assets.d.ts index 8edfef96..2610951a 100644 --- a/src/renderer/assets.d.ts +++ b/src/renderer/assets.d.ts @@ -4,3 +4,7 @@ declare module '*.wav' { const url: string; export default url; } + +// TypeScript 6 checks side-effect imports (noUncheckedSideEffectImports is on by +// default); Vite bundles the stylesheets. +declare module '*.css'; diff --git a/src/renderer/chat/ActivityRows.tsx b/src/renderer/chat/ActivityRows.tsx index 2b9a150b..71832423 100644 --- a/src/renderer/chat/ActivityRows.tsx +++ b/src/renderer/chat/ActivityRows.tsx @@ -211,10 +211,17 @@ function siteName(url: string): string { } } -function SourceIcon({ url }: { url: string }) { +/** A site's icon: `icon` when the caller has it (a share page's snapshot), else fetched from Stem. */ +function SourceIcon({ url, icon }: { url: string; icon?: string }) { const host = siteName(url); - const [src, setSrc] = useState(null); + const [src, setSrc] = useState(icon ?? null); useEffect(() => { + if (icon) { + setSrc(icon); + return; + } + // A share page has no Stem to ask: the letter tile stands in. + if (!window.stem?.sourceFavicon) return; let live = true; let hostname = ''; try { @@ -222,13 +229,13 @@ function SourceIcon({ url }: { url: string }) { } catch { return; } - void favicon(hostname).then((icon) => { - if (live) setSrc(icon); + void favicon(hostname).then((got) => { + if (live) setSrc(got); }); return () => { live = false; }; - }, [url]); + }, [url, icon]); return src ? ( ) : ( @@ -238,7 +245,7 @@ function SourceIcon({ url }: { url: string }) { ); } -export function SourcesList({ sources }: { sources: SourceRef[] }) { +export function SourcesList({ sources }: { sources: (SourceRef & { icon?: string })[] }) { const [open, setOpen] = useState(false); const safe = sources.filter((s) => safeSourceUrl(s.url)); if (!safe.length) return null; @@ -254,7 +261,7 @@ export function SourcesList({ sources }: { sources: SourceRef[] }) { {/* The first few sites at a glance, before the list is opened. */} Sources ({safe.length}) @@ -265,7 +272,7 @@ export function SourcesList({ sources }: { sources: SourceRef[] }) {
  • - + {siteName(s.url)} {s.title?.trim() || s.url} diff --git a/src/renderer/chat/ChatAudio.tsx b/src/renderer/chat/ChatAudio.tsx new file mode 100644 index 00000000..ba221352 --- /dev/null +++ b/src/renderer/chat/ChatAudio.tsx @@ -0,0 +1,348 @@ +import { useEffect, useRef, useState, type KeyboardEvent, type PointerEvent } from 'react'; +import { Check, Download, Pause, Play, TriangleAlert } from 'lucide-react'; +import type { ChatAudioRef } from '../../shared/types'; + +// Sounds share_audio put in a chat, shown under the assistant reply as a +// player card: play/pause, a waveform you can click or drag to seek, the time, +// and Download. Like GeneratedImage, the history and the event stream carry +// only refs; each card fetches its bytes once over `chats:audio`. +// +// The bytes become a blob: URL for an