vde-open 0.1.10 → 0.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,9 +3,9 @@
3
3
  <head>
4
4
  <meta charset="utf-8" />
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1" />
6
- <title>vde-open</title>
7
- <script type="module" crossorigin src="/assets/index-DOobMckY.js"></script>
8
- <link rel="stylesheet" crossorigin href="/assets/index-HOxygmIG.css">
6
+ <title>vo</title>
7
+ <script type="module" crossorigin src="/assets/index-DgSLK2vB.js"></script>
8
+ <link rel="stylesheet" crossorigin href="/assets/index-Bk9FUbvl.css">
9
9
  </head>
10
10
  <body>
11
11
  <div id="root"></div>
@@ -1,5 +1,5 @@
1
- import { d as analyzeDocument, u as ParseLimitError } from "../html-static-BDV6MgA7.js";
2
- import { n as scanReferences, t as renderDocument } from "../render-BX3arVZj.js";
1
+ import { d as analyzeDocument, u as ParseLimitError } from "../html-static-C_wwQAJx.js";
2
+ import { n as scanReferences, t as renderDocument } from "../render-BJa4uW0H.js";
3
3
  import { n as measureHeap, t as collectGarbage } from "../heap-C3qHm7SE.js";
4
4
  import { parentPort } from "node:worker_threads";
5
5
  //#region src/workers/parse-worker.ts
@@ -16,7 +16,7 @@ async function run(request) {
16
16
  if (request.op === "analyze") return analyzeDocument(request.text, request.format);
17
17
  if (request.op === "scan") return scanReferences(request.kind, request.text);
18
18
  if (request.op === "print" || request.op === "printHtml") {
19
- printModule ??= import("../print-Cfa1Ytrj.js");
19
+ printModule ??= import("../print-vae7mHCU.js");
20
20
  const printer = await printModule;
21
21
  return request.op === "print" ? printer.renderPrintDocument(request.input) : printer.renderHtmlPrintDocument(request.input);
22
22
  }
@@ -1,4 +1,4 @@
1
- import { t as SearchIndex } from "../search-index-NiN4l6Hg.js";
1
+ import { t as SearchIndex } from "../search-index-B-hHn9RV.js";
2
2
  import { n as measureHeap, t as collectGarbage } from "../heap-C3qHm7SE.js";
3
3
  import { parentPort } from "node:worker_threads";
4
4
  //#region src/workers/search-worker.ts
@@ -57,6 +57,7 @@ Pass the `revision` from a `search` result to `read --revision` to get the same
57
57
  ## What is extracted
58
58
 
59
59
  - `--section` and search work on the text extracted from the document. Markdown has `extraction: "markdown"`; HTML has `extraction: "static-html"`.
60
+ - Images can be opened directly (`vo open image.png --json`) and searched by title and path. Image search hits have `extraction: "image"`. There is no OCR, source text, outline, or section content; `vo read` returns `E_UNSUPPORTED_FORMAT` for images.
60
61
  - HTML is parsed statically. Scripts are not run, so content created by scripts, the contents of scripts and styles, and form input values are not included. Content hidden by CSS is not distinguished.
61
62
  - The position of a section (`sourceRange`) is `null`. When you need source lines, use `--lines`.
62
63
 
package/package.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "name": "vde-open",
3
- "version": "0.1.10",
4
- "description": "A local document viewer shared by agents and people: open Markdown and HTML documents, search and read them from the CLI, and ask the person questions.",
3
+ "version": "0.1.12",
4
+ "description": "A local document viewer shared by agents and people: open Markdown, HTML, and images, search documents and read text from the CLI, and ask the person questions.",
5
5
  "keywords": [
6
6
  "agent",
7
7
  "cli",
8
8
  "documents",
9
9
  "html",
10
+ "images",
10
11
  "markdown",
11
12
  "search",
12
13
  "viewer"
@@ -1,11 +1,11 @@
1
1
  ---
2
2
  name: vde-open
3
- description: Read, search, and open documents that a person is looking at in vde-open (`vo` / `vde-open`), and ask that person questions through its answer panel. Use when the user mentions vde-open or `vo`, asks you to look at "the documents I have open", to show them a Markdown or HTML file to read, or to collect their decisions on a design, review, or plan through a form instead of chat.
3
+ description: Read, search, and open documents that a person is looking at in vde-open (`vo` / `vde-open`), and ask that person questions through its answer panel. Use when the user mentions vde-open or `vo`, asks you to look at "the documents I have open", to show them a Markdown, HTML, or image file to view, or to collect their decisions on a design, review, or plan through a form instead of chat.
4
4
  ---
5
5
 
6
6
  # vde-open
7
7
 
8
- vde-open is a local document viewer shared by a person and agents. The person reads Markdown and HTML documents in a browser UI; you list, search, and read the same open documents from the CLI, and can ask the person questions that they answer in the UI.
8
+ vde-open is a local document viewer shared by a person and agents. The person views Markdown, HTML, and image files in a browser UI; you list, search, and read the same open documents from the CLI, and can ask the person questions that they answer in the UI.
9
9
 
10
10
  ## Before you start
11
11
 
@@ -31,6 +31,7 @@ vde-open is a local document viewer shared by a person and agents. The person re
31
31
  - Keep `revision` and `sectionId` together; a `sectionId` only means something within its revision. Reading with the revision from a search result returns exactly what was searched; if that revision is gone you get `E_REVISION_UNAVAILABLE` (never a silent substitute).
32
32
  - Results are cut by `--max-bytes` (default 16384). When `truncated` is true, run the same command with `--cursor <nextCursor>`. Cursors expire after 5 minutes; on `E_CURSOR_STALE`, start over.
33
33
  - If `search` returns `incomplete: true`, some documents were not searched (`failedDocuments`, `indexingDocuments`). `E_INDEX_NOT_READY` means nothing could be searched yet; wait a moment and retry.
34
+ - Images are searchable by title and path only (`--mode path`); they have no OCR or text source. Do not call `read`, `--outline`, or `--section` for a document whose `format` is `image`: those return `E_UNSUPPORTED_FORMAT`.
34
35
  - HTML is extracted statically: script output, script and style contents, and form values are not included. `sourceRange` is `null`.
35
36
 
36
37
  ## Show documents to the person
@@ -39,6 +40,7 @@ vde-open is a local document viewer shared by a person and agents. The person re
39
40
  vo open docs/design.md notes.md --json # open files (adds them to the person's list)
40
41
  vo open docs -R --json # open every document under a directory
41
42
  vo open docs -w --json # also open documents that appear later
43
+ vo open diagram.png --focus --json # show an image (decoded by the person's browser)
42
44
  vo open docs/design.md --focus --json # open and switch the person's view to it
43
45
  vo focus <documentId> --json # switch the view to an open document
44
46
  vo close docs/design.md --json # remove from the list (the file is kept)