@open-document/core 0.9.0 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{build-CFL7nhz0.js → build-DJMLK50m.js} +1 -1
- package/dist/{check-CL0-0eB8.js → check-CUKuufBm.js} +3 -3
- package/dist/cli/bin.js +10 -6
- package/dist/{config-4nz5NnxW.js → config-CvzpyAUA.js} +558 -546
- package/dist/{context-BH8C-dSW.js → context-B4ip7SoI.js} +1 -1
- package/dist/{dev-BCSUczXW.js → dev-dnH7DTlD.js} +1 -1
- package/dist/{diagram-xlVDekYk.js → diagram-BK4jTZr4.js} +231 -158
- package/dist/diff-QTo0A5Rx.js +44 -0
- package/dist/{export-CmVJdl9a.js → export-BrRFrexj.js} +3 -3
- package/dist/{import-E6vRo7xm.js → import-C14Vn9ER.js} +2 -2
- package/dist/index.d.ts +54 -3
- package/dist/index.js +457 -18
- package/dist/ops/index.d.ts +72 -17
- package/dist/ops/index.js +3 -3
- package/dist/{ops-OZZVBgsM.js → ops-DKidjLXP.js} +642 -124
- package/dist/{preview-CwCrw-i3.js → preview-wKM4C6Uk.js} +1 -1
- package/dist/{sdk-BqU6mwD_.d.ts → sdk-CpDEGRIo.d.ts} +2 -0
- package/dist/vite/index.js +1 -1
- package/package.json +2 -2
- package/skills/doc-authoring/SKILL.md +13 -6
- package/skills/doc-authoring/references/pagination.md +1 -1
- package/skills/doc-authoring/references/tables-and-charts.md +18 -1
- package/src/app/components/browser/browser-ui.tsx +105 -0
- package/src/app/components/chart.tsx +239 -0
- package/src/app/components/command-palette.tsx +284 -0
- package/src/app/components/design-panel/design-panel.tsx +22 -20
- package/src/app/components/design-panel/design-provider.tsx +4 -2
- package/src/app/components/diagram.tsx +11 -1
- package/src/app/components/doc-assets.tsx +6 -5
- package/src/app/components/doc-search.tsx +12 -10
- package/src/app/components/doc-sidebar.tsx +24 -18
- package/src/app/components/flow-page.tsx +2 -0
- package/src/app/components/inspector/inspector.tsx +75 -48
- package/src/app/components/language-toggle.tsx +38 -0
- package/src/app/components/palette-items.ts +128 -0
- package/src/app/components/panel/edit-save-card.tsx +4 -2
- package/src/app/components/panel/fields.tsx +5 -2
- package/src/app/components/panel/save-card.tsx +18 -10
- package/src/app/components/sidebar/folder-item.tsx +10 -8
- package/src/app/components/sidebar/icon-picker.tsx +3 -1
- package/src/app/components/sidebar/sidebar.tsx +44 -13
- package/src/app/components/theme-toggle.tsx +5 -3
- package/src/app/components/ui/menu.tsx +5 -0
- package/src/app/lib/agent-bridge.ts +8 -2
- package/src/app/lib/chart.test.ts +108 -0
- package/src/app/lib/chart.ts +343 -0
- package/src/app/lib/doc-preview.tsx +0 -10
- package/src/app/lib/docs.ts +3 -0
- package/src/app/lib/docx/from-dom.ts +11 -11
- package/src/app/lib/docx/ooxml.test.ts +25 -9
- package/src/app/lib/docx/ooxml.ts +58 -37
- package/src/app/lib/export-docx.ts +13 -8
- package/src/app/lib/export-dom.ts +4 -0
- package/src/app/lib/export-image.ts +2 -0
- package/src/app/lib/export-pdf.ts +6 -0
- package/src/app/lib/flow-measure.ts +3 -0
- package/src/app/lib/flow.ts +1 -1
- package/src/app/lib/i18n-ja/browser.ts +88 -0
- package/src/app/lib/i18n-ja/doc.ts +65 -0
- package/src/app/lib/i18n-ja/index.ts +5 -0
- package/src/app/lib/i18n-ja/panels.ts +104 -0
- package/src/app/lib/i18n-ko/browser.ts +87 -0
- package/src/app/lib/i18n-ko/doc.ts +65 -0
- package/src/app/lib/i18n-ko/index.ts +5 -0
- package/src/app/lib/i18n-ko/panels.ts +102 -0
- package/src/app/lib/i18n-zh-cn/browser.ts +84 -0
- package/src/app/lib/i18n-zh-cn/doc.ts +64 -0
- package/src/app/lib/i18n-zh-cn/index.ts +5 -0
- package/src/app/lib/i18n-zh-cn/panels.ts +98 -0
- package/src/app/lib/i18n-zh-tw/browser.ts +84 -0
- package/src/app/lib/i18n-zh-tw/doc.ts +64 -0
- package/src/app/lib/i18n-zh-tw/index.ts +5 -0
- package/src/app/lib/i18n-zh-tw/panels.ts +99 -0
- package/src/app/lib/i18n.test.ts +24 -0
- package/src/app/lib/i18n.tsx +109 -0
- package/src/app/lib/outline.ts +23 -0
- package/src/app/lib/page-range.test.ts +10 -1
- package/src/app/lib/page-range.ts +26 -0
- package/src/app/lib/sdk.ts +2 -0
- package/src/app/lib/svg-ids.ts +37 -0
- package/src/app/main.tsx +4 -1
- package/src/app/routes/assets.tsx +193 -132
- package/src/app/routes/doc.tsx +666 -310
- package/src/app/routes/home-shell.tsx +115 -88
- package/src/app/routes/home.tsx +200 -67
- package/src/app/routes/themes.tsx +42 -35
- package/src/app/styles.css +99 -0
- package/src/app/virtual.d.ts +1 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { d as closeRenderSession, u as checkLayout } from "./ops-
|
|
3
|
-
import { t as cliContext } from "./context-
|
|
1
|
+
import { f as listDocIds } from "./config-CvzpyAUA.js";
|
|
2
|
+
import { d as closeRenderSession, u as checkLayout } from "./ops-DKidjLXP.js";
|
|
3
|
+
import { t as cliContext } from "./context-B4ip7SoI.js";
|
|
4
4
|
import chalk from "chalk";
|
|
5
5
|
//#region src/cli/check.ts
|
|
6
6
|
function line(finding) {
|
package/dist/cli/bin.js
CHANGED
|
@@ -165,27 +165,31 @@ async function run(argv) {
|
|
|
165
165
|
program.name("open-doc").description("Author documents — we handle the Vite/React stack, pagination, and export.").version(version, "-v, --version", "print version").helpOption("-h, --help", "show help").showHelpAfterError(chalk.dim("(run `open-doc --help` for usage)"));
|
|
166
166
|
program.command("dev").description("Start the dev server").addOption(new Option("-p, --port <port>", "port to listen on").argParser(parsePort)).addOption(new Option("--host [host]", "expose on the network (optional host)")).option("--open", "open the browser on start").option("--no-skills-check", "skip the built-in skills drift check").option("--mcp", "serve an MCP endpoint at /mcp (requires @open-document/mcp)").action(async (flags) => {
|
|
167
167
|
if (flags.skillsCheck !== false) await runSkillsDriftCheck(resolveBuiltinSkillsDir());
|
|
168
|
-
const { dev } = await import("../dev-
|
|
168
|
+
const { dev } = await import("../dev-dnH7DTlD.js");
|
|
169
169
|
await dev(flags);
|
|
170
170
|
});
|
|
171
171
|
program.command("build").description("Build a static site").option("--out-dir <dir>", "output directory (defaults to `dist`)").action(async (flags) => {
|
|
172
|
-
const { build } = await import("../build-
|
|
172
|
+
const { build } = await import("../build-DJMLK50m.js");
|
|
173
173
|
await build(flags);
|
|
174
174
|
});
|
|
175
175
|
program.command("preview").description("Preview the production build").addOption(new Option("-p, --port <port>", "port to listen on").argParser(parsePort)).addOption(new Option("--host [host]", "expose on the network (optional host)")).option("--open", "open the browser on start").action(async (flags) => {
|
|
176
|
-
const { preview } = await import("../preview-
|
|
176
|
+
const { preview } = await import("../preview-wKM4C6Uk.js");
|
|
177
177
|
await preview(flags);
|
|
178
178
|
});
|
|
179
179
|
program.command("export [docIds...]").description("Render documents headlessly to PDF, HTML, PNG, or DOCX").addOption(new Option("-f, --format <format>", "output format").choices([...EXPORT_FORMATS])).option("-o, --out-dir <dir>", "directory to write into (defaults to `out`)").option("--all", "export every document under docs/").action(async (docIds, flags) => {
|
|
180
|
-
const { exportDocs } = await import("../export-
|
|
180
|
+
const { exportDocs } = await import("../export-BrRFrexj.js");
|
|
181
181
|
await exportDocs(docIds, flags);
|
|
182
182
|
});
|
|
183
|
+
program.command("diff <docId>").description("Show what changed in a document since a git revision, page by page").option("-s, --since <rev>", "revision to compare against (defaults to HEAD)").option("-o, --out-dir <dir>", "directory to write the report into (defaults to `out`)").option("--json", "print the result as JSON").action(async (docId, flags) => {
|
|
184
|
+
const { diffDoc } = await import("../diff-QTo0A5Rx.js");
|
|
185
|
+
await diffDoc(docId, flags);
|
|
186
|
+
});
|
|
183
187
|
program.command("check [docIds...]").description("Report layout faults — clipped content, blank sheets, stranded headings").option("--json", "print the full report as JSON").action(async (docIds, flags) => {
|
|
184
|
-
const { checkDocs } = await import("../check-
|
|
188
|
+
const { checkDocs } = await import("../check-CUKuufBm.js");
|
|
185
189
|
await checkDocs(docIds, flags);
|
|
186
190
|
});
|
|
187
191
|
program.command("import <file>").description("Turn a Markdown file into a document under docs/").option("--id <id>", "document id (defaults to a slug of the title)").option("--title <title>", "override the title").option("--subtitle <subtitle>", "subtitle, also used as the cover eyebrow").option("--author <author>", "author line on the cover").option("--theme <theme>", "theme id to back-link from meta.theme").addOption(new Option("--page-size <size>", "page size").choices(PAGE_SIZE_NAMES)).addOption(new Option("--orientation <orientation>", "page orientation").choices(ORIENTATIONS)).option("--no-cover", "skip the title page").option("--contents", "add a self-filling contents page").action(async (file, flags) => {
|
|
188
|
-
const { importDoc } = await import("../import-
|
|
192
|
+
const { importDoc } = await import("../import-C14Vn9ER.js");
|
|
189
193
|
await importDoc(file, flags);
|
|
190
194
|
});
|
|
191
195
|
program.command("sync:skills").description("Sync built-in skills from @open-document/core into this workspace").option("--dry-run", "show what would change without writing").action(async (flags) => {
|