Sign In

@ailang/parse

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ailang/parse - npm Package Compare versions

Comparing version
0.8.0
to
0.9.0
+1
-1
package.json
{
"name": "@ailang/parse",
"version": "0.8.0",
"version": "0.9.0",
"mcpName": "io.github.sunholo-data/parse",

@@ -5,0 +5,0 @@ "description": "JavaScript/TypeScript client and MCP server for the AILANG Parse document parsing API",

@@ -96,4 +96,23 @@ /** AILANG Parse types — Block ADT, ParseResult, metadata, errors. */

/**
* A run of text with uniform character formatting inside a paragraph.
* Populated by the DOCX, HTML, PPTX and ODT parsers; absent when the source
* carried no inline formatting.
*
* `text` and the block's `text` are allowed to differ: HTML keeps Markdown
* markers in `text` for readability while `runs` carries the same formatting
* structurally. `text` is for reading, runs are for rendering.
*/
export interface InlineRun {
text: string;
bold?: boolean;
italic?: boolean;
underline?: boolean;
strike?: boolean;
code?: boolean;
vertAlign?: string;
}
export interface Block {
type: "text" | "heading" | "table" | "list" | "image" | "audio" | "video" | "section" | "change";
type: "text" | "heading" | "table" | "list" | "image" | "audio" | "video" | "section" | "change" | "link" | "comment";
text: string;

@@ -112,2 +131,6 @@ level: number;

ordered?: boolean;
// Inline character formatting. `runs` applies to text/heading blocks;
// `itemRuns` is parallel to `items` — same length, or absent.
runs?: InlineRun[];
itemRuns?: InlineRun[][];
// ImageBlock / AudioBlock / VideoBlock

@@ -118,2 +141,13 @@ description?: string;

dataLength?: number;
// CommentBlock. `anchorText` is the span of document text this comment
// annotates. When `anchored` is false the anchor could not be resolved and
// `anchorText` is empty — the comment has no known target, and callers must
// not infer one from surrounding blocks.
id?: string;
anchorText?: string;
anchorKind?: "range" | "point" | "cell" | "slide" | "none";
anchored?: boolean;
anchorBlockIndex?: number;
parentId?: string; // set on threaded replies
resolved?: boolean;
// SectionBlock

@@ -120,0 +154,0 @@ kind?: string;