@open-document/core 0.13.2 → 0.14.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-CvsOak5B.js → build-CyBlmrjS.js} +1 -1
- package/dist/{check-CbUBwYmf.js → check-DUKDEem-.js} +3 -3
- package/dist/cli/bin.js +10 -21
- package/dist/{config-BWtOZ1jc.d.ts → config-cAV1OCuY.d.ts} +9 -1
- package/dist/{config-CltJJVsw.js → config-cNpYUpF6.js} +2746 -369
- package/dist/{context-CWgfsHoE.js → context-BPApOW9n.js} +1 -1
- package/dist/{dev-B8H2qT6G.js → dev-DrnOvsX3.js} +1 -1
- package/dist/{diff-BvIjjgnc.js → diff-BPMD2Knh.js} +2 -2
- package/dist/{export-DX30_s2q.js → export-DeVtL8aX.js} +3 -3
- package/dist/{import-DgsdJT5e.js → import-WAgWsuOv.js} +3 -2
- package/dist/index.d.ts +2 -2
- package/dist/ops/index.d.ts +3 -1
- package/dist/ops/index.js +2 -2
- package/dist/{ops-CSR5RlrE.js → ops-raK6424A.js} +2 -854
- package/dist/{preview-DYMUNjXL.js → preview-B8Vw9QCh.js} +1 -1
- package/dist/rolldown-runtime-D7D4PA-g.js +13 -0
- package/dist/{templates-B5Tz0AKb.js → templates-D9jAFJ8R.js} +3 -3
- package/dist/vite/index.d.ts +1 -1
- package/dist/vite/index.js +1 -1
- package/package.json +1 -1
- package/skills/create-doc/SKILL.md +1 -1
- package/skills/doc-authoring/SKILL.md +6 -0
- package/src/app/app.tsx +2 -0
- package/src/app/components/agent/agent-dock.tsx +75 -0
- package/src/app/components/agent/agent-markdown.tsx +45 -0
- package/src/app/components/agent/agent-panel.tsx +690 -0
- package/src/app/components/agent/agent-presence.tsx +74 -0
- package/src/app/components/agent/composer.tsx +120 -0
- package/src/app/components/agent/connect-view.tsx +183 -0
- package/src/app/components/agent/history-view.tsx +134 -0
- package/src/app/components/agent/provider-logo.tsx +23 -0
- package/src/app/components/agent/transcript.tsx +609 -0
- package/src/app/components/comments/comments-panel.tsx +26 -2
- package/src/app/components/inspector/inspector.tsx +17 -0
- package/src/app/components/note-markdown.tsx +85 -0
- package/src/app/components/page-error-boundary.tsx +84 -0
- package/src/app/components/page-frame.tsx +2 -1
- package/src/app/components/panel/resize-handle.tsx +129 -0
- package/src/app/components/ui/button.tsx +97 -0
- package/src/app/components/ui/popover.tsx +144 -0
- package/src/app/components/ui/tooltip.tsx +123 -0
- package/src/app/lib/agent/use-agent.ts +543 -0
- package/src/app/lib/diagnostics.ts +13 -0
- package/src/app/lib/docx/from-dom.ts +91 -6
- package/src/app/lib/docx/ooxml.test.ts +58 -0
- package/src/app/lib/docx/ooxml.ts +58 -9
- package/src/app/lib/export-dom.ts +2 -1
- package/src/app/lib/export-pdf.ts +2 -1
- package/src/app/lib/i18n-ja/agent-panel.ts +107 -0
- package/src/app/lib/i18n-ja/agent.ts +9 -0
- package/src/app/lib/i18n-ja/index.ts +9 -1
- package/src/app/lib/i18n-ko/agent-panel.ts +106 -0
- package/src/app/lib/i18n-ko/agent.ts +9 -0
- package/src/app/lib/i18n-ko/index.ts +9 -1
- package/src/app/lib/i18n-zh-cn/agent-panel.ts +105 -0
- package/src/app/lib/i18n-zh-cn/agent.ts +9 -0
- package/src/app/lib/i18n-zh-cn/index.ts +9 -1
- package/src/app/lib/i18n-zh-tw/agent-panel.ts +105 -0
- package/src/app/lib/i18n-zh-tw/agent.ts +9 -0
- package/src/app/lib/i18n-zh-tw/index.ts +9 -1
- package/src/app/lib/note-markdown.ts +116 -0
- package/src/app/lib/toast.ts +50 -0
- package/src/app/lib/use-auto-grow.ts +15 -0
- package/src/app/lib/use-doc-titles.ts +28 -0
- package/src/app/lib/use-locale.ts +144 -0
- package/src/app/lib/utils.ts +4 -0
- package/src/app/routes/doc-preview.tsx +103 -0
- package/src/app/routes/doc.tsx +118 -11
- package/src/app/routes/home.tsx +43 -8
- package/src/app/styles.css +193 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as readCoreVersion } from "./package-version-C89gtYSk.js";
|
|
2
2
|
import { n as loadUserConfig } from "./open-doc-plugin-DnX5usgI.js";
|
|
3
|
-
import {
|
|
3
|
+
import { R as makeContext } from "./config-cNpYUpF6.js";
|
|
4
4
|
//#region src/cli/context.ts
|
|
5
5
|
/** The same context the dev API and the MCP server run on, for commands that call `ops/`. */
|
|
6
6
|
async function cliContext(userCwd = process.cwd()) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t as cliContext } from "./context-
|
|
1
|
+
import { a as diffDocument } from "./ops-raK6424A.js";
|
|
2
|
+
import { t as cliContext } from "./context-BPApOW9n.js";
|
|
3
3
|
import chalk from "chalk";
|
|
4
4
|
//#region src/cli/diff.ts
|
|
5
5
|
const MARK = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as EXPORT_FORMATS } from "./sdk-CqNZzbkz.js";
|
|
2
|
-
import {
|
|
3
|
-
import { n as closeRenderSession, r as exportDocument } from "./ops-
|
|
4
|
-
import { t as cliContext } from "./context-
|
|
2
|
+
import { M as listDocIds } from "./config-cNpYUpF6.js";
|
|
3
|
+
import { n as closeRenderSession, r as exportDocument } from "./ops-raK6424A.js";
|
|
4
|
+
import { t as cliContext } from "./context-BPApOW9n.js";
|
|
5
5
|
import chalk from "chalk";
|
|
6
6
|
//#region src/cli/export.ts
|
|
7
7
|
const FORMATS = EXPORT_FORMATS;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
1
|
+
import { y as importMarkdown } from "./config-cNpYUpF6.js";
|
|
2
|
+
import "./ops-raK6424A.js";
|
|
3
|
+
import { t as cliContext } from "./context-BPApOW9n.js";
|
|
3
4
|
import chalk from "chalk";
|
|
4
5
|
import path from "node:path";
|
|
5
6
|
//#region src/cli/import.ts
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { A as DesignPalette, B as useDocLabels, C as isPageSizeName, D as FieldProps, E as Field, F as designToCssVars, I as LabelEntry, L as LabelKind, M as DesignTypeScale, N as cssVarsToString, O as useRecord, P as defaultDesign, R as LabelVocabulary, S as isOrientation, T as DataRecord, _ as Orientation, a as isFlowSection, b as PageGeometry, c as DEFAULT_PAGE_SIZE, d as DocModule, f as DocPage, g as ORIENTATIONS, h as FlowSection, i as flow, j as DesignSystem, k as DesignFonts, l as DocEntry, n as BlockSlice, o as paginateBlocks, r as PaginationResult, s as DEFAULT_ORIENTATION, t as BlockMetrics, u as DocMeta, v as PAGE_SIZES, w as resolvePageGeometry, x as PageSizeName, y as PAGE_SIZE_NAMES, z as useDocLabel } from "./flow-CS5apebG.js";
|
|
2
|
-
import {
|
|
2
|
+
import { a as OpenDocGcpDeployConfig, i as OpenDocDeployConfig, n as OpenDocBuildConfig, r as OpenDocConfig, t as OpenDocAgentConfig } from "./config-cAV1OCuY.js";
|
|
3
3
|
import { CSSProperties, ReactNode } from "react";
|
|
4
4
|
//#region src/app/lib/source-loc.d.ts
|
|
5
5
|
/**
|
|
@@ -489,4 +489,4 @@ type CompileOptions = LayoutOptions & RenderOptions;
|
|
|
489
489
|
/** Mermaid-flavoured text in, themed SVG out. One call, no browser. */
|
|
490
490
|
declare function compileDiagram(source: string, options?: CompileOptions): CompiledDiagram;
|
|
491
491
|
//#endregion
|
|
492
|
-
export { Bibliography, type BibliographyItem, type BibliographyProps, type BlockMetrics, type BlockSlice, Callout, type CalloutProps, type CalloutVariant, type CellValue, Chart, type ChartFormat, type ChartProps, type ChartType, Cite, type CiteProps, CodeBlock, type CodeBlockProps, type CompileOptions, type CompiledDiagram, DEFAULT_ORIENTATION, DEFAULT_PAGE_SIZE, type DataAlign, type DataColumn, type DataFormat, type DataRecord, type DataSummaryOp, DataTable, type DataTableProps, type DelimitedTable, type DesignFonts, type DesignPalette, type DesignSystem, type DesignTypeScale, Diagram, type DiagramProps, type DiagramSource, type DiagramSubgraph, DiagramSyntaxError, type DocEntry, type DocMeta, type DocModule, type DocPage, Field, type FieldProps, Figure, type FigureProps, type FlowSection, Footnote, type FootnoteProps, Footnotes, type FootnotesProps, ImagePlaceholder, type ImagePlaceholderProps, type LabelEntry, type LabelKind, type LabelVocabulary, type LaidOutLifeline, type LaidOutSubgraph, ListOf, ListOfFigures, type ListOfProps, ListOfTables, ORIENTATIONS, type OpenDocBuildConfig, type OpenDocConfig, type OpenDocDeployConfig, type OpenDocGcpDeployConfig, type Orientation, type OutlineEntry, PAGE_SIZES, PAGE_SIZE_NAMES, type PageGeometry, type PageSizeName, type PaginationResult, Ref, type RefProps, type SequenceMessage, type SequenceParticipant, Sparkline, type SparklineProps, TableOfContents, type TableOfContentsProps, compileDiagram, cssVarsToString, defaultDesign, designToCssVars, flow, isFlowSection, isOrientation, isPageSizeName, paginateBlocks, parseDelimited, resolvePageGeometry, useDocLabel, useDocLabels, useDocOutline, useDocPageCount, useDocPageNumber, useRecord };
|
|
492
|
+
export { Bibliography, type BibliographyItem, type BibliographyProps, type BlockMetrics, type BlockSlice, Callout, type CalloutProps, type CalloutVariant, type CellValue, Chart, type ChartFormat, type ChartProps, type ChartType, Cite, type CiteProps, CodeBlock, type CodeBlockProps, type CompileOptions, type CompiledDiagram, DEFAULT_ORIENTATION, DEFAULT_PAGE_SIZE, type DataAlign, type DataColumn, type DataFormat, type DataRecord, type DataSummaryOp, DataTable, type DataTableProps, type DelimitedTable, type DesignFonts, type DesignPalette, type DesignSystem, type DesignTypeScale, Diagram, type DiagramProps, type DiagramSource, type DiagramSubgraph, DiagramSyntaxError, type DocEntry, type DocMeta, type DocModule, type DocPage, Field, type FieldProps, Figure, type FigureProps, type FlowSection, Footnote, type FootnoteProps, Footnotes, type FootnotesProps, ImagePlaceholder, type ImagePlaceholderProps, type LabelEntry, type LabelKind, type LabelVocabulary, type LaidOutLifeline, type LaidOutSubgraph, ListOf, ListOfFigures, type ListOfProps, ListOfTables, ORIENTATIONS, type OpenDocAgentConfig, type OpenDocBuildConfig, type OpenDocConfig, type OpenDocDeployConfig, type OpenDocGcpDeployConfig, type Orientation, type OutlineEntry, PAGE_SIZES, PAGE_SIZE_NAMES, type PageGeometry, type PageSizeName, type PaginationResult, Ref, type RefProps, type SequenceMessage, type SequenceParticipant, Sparkline, type SparklineProps, TableOfContents, type TableOfContentsProps, compileDiagram, cssVarsToString, defaultDesign, designToCssVars, flow, isFlowSection, isOrientation, isPageSizeName, paginateBlocks, parseDelimited, resolvePageGeometry, useDocLabel, useDocLabels, useDocOutline, useDocPageCount, useDocPageNumber, useRecord };
|
package/dist/ops/index.d.ts
CHANGED
|
@@ -22,6 +22,8 @@ type ApiPluginOptions = {
|
|
|
22
22
|
assetsDir?: string;
|
|
23
23
|
coreVersion: string;
|
|
24
24
|
serverOrigin?: string;
|
|
25
|
+
/** Mount the agent panel's endpoints. Defaults to true. */
|
|
26
|
+
agent?: boolean;
|
|
25
27
|
};
|
|
26
28
|
declare function makeContext(opts: ApiPluginOptions): ApiContext;
|
|
27
29
|
//#endregion
|
|
@@ -116,7 +118,7 @@ declare function assertExpectedSource(current: string, opts?: {
|
|
|
116
118
|
declare function withFileLock<T>(filePath: string, fn: () => Promise<T>): Promise<T>;
|
|
117
119
|
//#endregion
|
|
118
120
|
//#region src/app/lib/diagnostics.d.ts
|
|
119
|
-
type LayoutRule = 'unresolved-ref' | 'duplicate-id' | 'heading-skip' | 'page-overflow' | 'off-page' | 'blank-page' | 'oversized-block' | 'orphan-heading' | 'tiny-text' | 'broken-image';
|
|
121
|
+
type LayoutRule = 'render-error' | 'unresolved-ref' | 'duplicate-id' | 'heading-skip' | 'page-overflow' | 'off-page' | 'blank-page' | 'oversized-block' | 'orphan-heading' | 'tiny-text' | 'broken-image';
|
|
120
122
|
type LayoutSeverity = 'error' | 'warn';
|
|
121
123
|
type LayoutFinding = {
|
|
122
124
|
/** 1-based sheet the problem is on. */
|
package/dist/ops/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { i as ORIENTATIONS, o as PAGE_SIZE_NAMES, r as EXPORT_FORMATS } from "../sdk-CqNZzbkz.js";
|
|
2
|
-
import { A as
|
|
3
|
-
import { a as
|
|
2
|
+
import { A as docDir, C as revertChange, D as OpsError, E as withFileLock, F as renameDocument, I as resolveEntry, L as writeDocument, M as listDocIds, N as listDocuments, O as createDocument, P as readDocument, R as makeContext, S as readChanges, T as hashSource, _ as readTheme, a as writeText, b as slugify, c as listTemplates, d as deleteAsset, f as fileDocument, g as listThemes, h as listFolders, i as writeEdits, j as duplicateDocument, k as deleteDocument, l as suggestDocId, m as listAssets, n as addComment, o as writeTexts, p as findAssetUsages, r as readText, s as createFromTemplate, u as createFolder, v as writeAsset, w as assertExpectedSource, x as listRevisions, y as importMarkdown } from "../config-cNpYUpF6.js";
|
|
3
|
+
import { a as diffDocument, i as renderDocPage, n as closeRenderSession, r as exportDocument, t as checkLayout } from "../ops-raK6424A.js";
|
|
4
4
|
export { EXPORT_FORMATS, ORIENTATIONS, OpsError, PAGE_SIZE_NAMES, addComment, assertExpectedSource, checkLayout, closeRenderSession, createDocument, createFolder, createFromTemplate, deleteAsset, deleteDocument, diffDocument, docDir, duplicateDocument, exportDocument, fileDocument, findAssetUsages, hashSource, importMarkdown, listAssets, listDocIds, listDocuments, listFolders, listRevisions, listTemplates, listThemes, makeContext, readChanges, readDocument, readText, readTheme, renameDocument, renderDocPage, resolveEntry, revertChange, slugify, suggestDocId, withFileLock, writeAsset, writeDocument, writeEdits, writeText, writeTexts };
|