@superdoc-dev/cli 0.8.0-next.92 → 0.8.0-next.93
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/index.js +56 -21
- package/package.json +7 -7
package/dist/index.js
CHANGED
|
@@ -208524,7 +208524,7 @@ var init_remark_gfm_eZN6yzWQ_es = __esm(() => {
|
|
|
208524
208524
|
init_remark_gfm_BhnWr3yf_es();
|
|
208525
208525
|
});
|
|
208526
208526
|
|
|
208527
|
-
// ../../packages/superdoc/dist/chunks/src-
|
|
208527
|
+
// ../../packages/superdoc/dist/chunks/src-BdpJXQ5F.es.js
|
|
208528
208528
|
function deleteProps(obj, propOrProps) {
|
|
208529
208529
|
const props = typeof propOrProps === "string" ? [propOrProps] : propOrProps;
|
|
208530
208530
|
const removeNested = (target, pathParts, index2 = 0) => {
|
|
@@ -263352,7 +263352,7 @@ function extractCellPadding(cellAttrs) {
|
|
|
263352
263352
|
return;
|
|
263353
263353
|
return normalizeCellPaddingTopBottom(padding);
|
|
263354
263354
|
}
|
|
263355
|
-
function textNodeToRun({ node: node3, positions, storyKey, defaultFont, defaultSize, inheritedMarks = [], sdtMetadata, hyperlinkConfig = DEFAULT_HYPERLINK_CONFIG, themeColors, enableComments, runProperties, converterContext }) {
|
|
263355
|
+
function textNodeToRun({ node: node3, positions, storyKey, defaultFont, defaultSize, inheritedMarks = [], sdtMetadata, hyperlinkConfig = DEFAULT_HYPERLINK_CONFIG, themeColors, enableComments, runProperties, inlineRunProperties, converterContext }) {
|
|
263356
263356
|
let run2 = {
|
|
263357
263357
|
text: node3.text || "",
|
|
263358
263358
|
fontFamily: defaultFont,
|
|
@@ -263366,7 +263366,7 @@ function textNodeToRun({ node: node3, positions, storyKey, defaultFont, defaultS
|
|
|
263366
263366
|
applyMarksToRun(run2, [...node3.marks ?? [], ...inheritedMarks ?? []], hyperlinkConfig, themeColors, converterContext?.backgroundColor, enableComments, storyKey);
|
|
263367
263367
|
if (sdtMetadata)
|
|
263368
263368
|
run2.sdt = sdtMetadata;
|
|
263369
|
-
run2 = applyInlineRunProperties(run2, runProperties, converterContext);
|
|
263369
|
+
run2 = applyInlineRunProperties(run2, runProperties, converterContext, inlineRunProperties);
|
|
263370
263370
|
return run2;
|
|
263371
263371
|
}
|
|
263372
263372
|
function buildReferenceMarkerRun(displayText, params$1) {
|
|
@@ -263399,7 +263399,7 @@ function runNodeChildrenToRuns({ node: node3, inheritedMarks, sdtMetadata, conve
|
|
|
263399
263399
|
if (runProperties.vanish)
|
|
263400
263400
|
throw new HiddenByVanishError;
|
|
263401
263401
|
const resolvedRunProperties = resolveRunProperties(converterContext, runProperties, paragraphProperties, converterContext.tableInfo, false, false);
|
|
263402
|
-
node3.content?.forEach((child) => visitNode(child, mergedMarks, sdtMetadata, resolvedRunProperties, false));
|
|
263402
|
+
node3.content?.forEach((child) => visitNode(child, mergedMarks, sdtMetadata, resolvedRunProperties, false, runProperties));
|
|
263403
263403
|
}
|
|
263404
263404
|
function resolveSdtMetadata(input2) {
|
|
263405
263405
|
if (!input2)
|
|
@@ -264172,12 +264172,12 @@ function handleTableOfAuthoritiesNode(node3, context) {
|
|
|
264172
264172
|
sectionState.currentParagraphIndex++;
|
|
264173
264173
|
});
|
|
264174
264174
|
}
|
|
264175
|
-
function structuredContentNodeToBlocks({ node: node3, inheritedMarks, sdtMetadata, visitNode, runProperties }) {
|
|
264175
|
+
function structuredContentNodeToBlocks({ node: node3, inheritedMarks, sdtMetadata, visitNode, runProperties, inlineRunProperties }) {
|
|
264176
264176
|
const nextSdt = resolveNodeSdtMetadata(node3, "structuredContent") ?? sdtMetadata;
|
|
264177
|
-
node3.content?.forEach((child) => visitNode(child, inheritedMarks, nextSdt, runProperties, false));
|
|
264177
|
+
node3.content?.forEach((child) => visitNode(child, inheritedMarks, nextSdt, runProperties, false, inlineRunProperties));
|
|
264178
264178
|
}
|
|
264179
264179
|
function pageReferenceNodeToBlock(params$1) {
|
|
264180
|
-
const { node: node3, inheritedMarks, visitNode, sdtMetadata, positions, converterContext, paragraphProperties } = params$1;
|
|
264180
|
+
const { node: node3, inheritedMarks, visitNode, sdtMetadata, positions, converterContext, paragraphProperties, inlineRunProperties: parentInlineRunProperties } = params$1;
|
|
264181
264181
|
const instruction = getNodeInstruction(node3) || "";
|
|
264182
264182
|
const nodeAttrs = typeof node3.attrs === "object" && node3.attrs !== null ? node3.attrs : {};
|
|
264183
264183
|
const mergedMarks = [...Array.isArray(nodeAttrs.marksAsAttrs) ? nodeAttrs.marksAsAttrs : [], ...inheritedMarks ?? []];
|
|
@@ -264207,7 +264207,8 @@ function pageReferenceNodeToBlock(params$1) {
|
|
|
264207
264207
|
text: fallbackText
|
|
264208
264208
|
},
|
|
264209
264209
|
inheritedMarks: mergedMarks,
|
|
264210
|
-
runProperties: resolvedRunProperties
|
|
264210
|
+
runProperties: resolvedRunProperties,
|
|
264211
|
+
inlineRunProperties: runProperties
|
|
264211
264212
|
});
|
|
264212
264213
|
if (pageRefPos) {
|
|
264213
264214
|
tokenRun.pmStart = pageRefPos.start;
|
|
@@ -264231,7 +264232,7 @@ function pageReferenceNodeToBlock(params$1) {
|
|
|
264231
264232
|
tokenRun.sdt = sdtMetadata;
|
|
264232
264233
|
return tokenRun;
|
|
264233
264234
|
} else if (Array.isArray(node3.content))
|
|
264234
|
-
node3.content.forEach((child) => visitNode(child, mergedMarks, sdtMetadata, runProperties));
|
|
264235
|
+
node3.content.forEach((child) => visitNode(child, mergedMarks, sdtMetadata, runProperties, false, parentInlineRunProperties));
|
|
264235
264236
|
}
|
|
264236
264237
|
function fieldAnnotationNodeToRun({ node: node3, positions }) {
|
|
264237
264238
|
const fieldMetadata = resolveNodeSdtMetadata(node3, "fieldAnnotation");
|
|
@@ -264334,7 +264335,7 @@ function fieldAnnotationNodeToRun({ node: node3, positions }) {
|
|
|
264334
264335
|
return run2;
|
|
264335
264336
|
}
|
|
264336
264337
|
function bookmarkStartNodeToBlocks(params$1) {
|
|
264337
|
-
const { node: node3, positions, bookmarks, visitNode, inheritedMarks, sdtMetadata, runProperties, converterContext } = params$1;
|
|
264338
|
+
const { node: node3, positions, bookmarks, visitNode, inheritedMarks, sdtMetadata, runProperties, inlineRunProperties, converterContext } = params$1;
|
|
264338
264339
|
const nodeAttrs = typeof node3.attrs === "object" && node3.attrs !== null ? node3.attrs : {};
|
|
264339
264340
|
const bookmarkName = typeof nodeAttrs.name === "string" ? nodeAttrs.name : undefined;
|
|
264340
264341
|
if (bookmarkName && bookmarks) {
|
|
@@ -264364,7 +264365,7 @@ function bookmarkStartNodeToBlocks(params$1) {
|
|
|
264364
264365
|
converterContext.renderedBookmarkIds.add(bookmarkId);
|
|
264365
264366
|
}
|
|
264366
264367
|
if (Array.isArray(node3.content))
|
|
264367
|
-
node3.content.forEach((child) => visitNode(child, inheritedMarks, sdtMetadata, runProperties));
|
|
264368
|
+
node3.content.forEach((child) => visitNode(child, inheritedMarks, sdtMetadata, runProperties, false, inlineRunProperties));
|
|
264368
264369
|
return run2;
|
|
264369
264370
|
}
|
|
264370
264371
|
function bookmarkEndNodeToRun(params$1) {
|
|
@@ -264414,7 +264415,7 @@ function tabNodeToRun({ node: node3, positions, storyKey, tabOrdinal, paragraphA
|
|
|
264414
264415
|
applyMarksToRun(run2, marks, undefined, undefined, undefined, true, storyKey);
|
|
264415
264416
|
return run2;
|
|
264416
264417
|
}
|
|
264417
|
-
function noBreakHyphenNodeToRun({ node: node3, positions, storyKey, defaultFont, defaultSize, inheritedMarks = [], sdtMetadata, hyperlinkConfig = DEFAULT_HYPERLINK_CONFIG, themeColors, enableComments, runProperties, converterContext }) {
|
|
264418
|
+
function noBreakHyphenNodeToRun({ node: node3, positions, storyKey, defaultFont, defaultSize, inheritedMarks = [], sdtMetadata, hyperlinkConfig = DEFAULT_HYPERLINK_CONFIG, themeColors, enableComments, runProperties, inlineRunProperties, converterContext }) {
|
|
264418
264419
|
let run2 = {
|
|
264419
264420
|
text: NON_BREAKING_HYPHEN,
|
|
264420
264421
|
fontFamily: defaultFont,
|
|
@@ -264428,14 +264429,14 @@ function noBreakHyphenNodeToRun({ node: node3, positions, storyKey, defaultFont,
|
|
|
264428
264429
|
applyMarksToRun(run2, [...node3.marks ?? [], ...inheritedMarks ?? []], hyperlinkConfig, themeColors, converterContext?.backgroundColor, enableComments, storyKey);
|
|
264429
264430
|
if (sdtMetadata)
|
|
264430
264431
|
run2.sdt = sdtMetadata;
|
|
264431
|
-
run2 = applyInlineRunProperties(run2, runProperties, converterContext);
|
|
264432
|
+
run2 = applyInlineRunProperties(run2, runProperties, converterContext, inlineRunProperties);
|
|
264432
264433
|
return run2;
|
|
264433
264434
|
}
|
|
264434
|
-
function tokenNodeToRun({ node: node3, positions, storyKey, defaultFont, defaultSize, inheritedMarks, hyperlinkConfig, themeColors, sdtMetadata, runProperties, converterContext }) {
|
|
264435
|
+
function tokenNodeToRun({ node: node3, positions, storyKey, defaultFont, defaultSize, inheritedMarks, hyperlinkConfig, themeColors, sdtMetadata, runProperties, inlineRunProperties, converterContext }) {
|
|
264435
264436
|
const token$1 = TOKEN_INLINE_TYPES.get(node3.type);
|
|
264436
264437
|
if (!token$1)
|
|
264437
264438
|
return null;
|
|
264438
|
-
|
|
264439
|
+
let run2 = {
|
|
264439
264440
|
text: "0",
|
|
264440
264441
|
token: token$1,
|
|
264441
264442
|
fontFamily: defaultFont,
|
|
@@ -264448,8 +264449,9 @@ function tokenNodeToRun({ node: node3, positions, storyKey, defaultFont, default
|
|
|
264448
264449
|
}
|
|
264449
264450
|
const nodeMarks = node3.marks ?? [];
|
|
264450
264451
|
const marksAsAttrs = Array.isArray(node3.attrs?.marksAsAttrs) ? node3.attrs.marksAsAttrs : [];
|
|
264451
|
-
|
|
264452
|
-
|
|
264452
|
+
const marks = [...nodeMarks.length > 0 ? nodeMarks : marksAsAttrs, ...inheritedMarks ?? []];
|
|
264453
|
+
applyMarksToRun(run2, marks, hyperlinkConfig, themeColors, undefined, true, storyKey);
|
|
264454
|
+
run2 = applyInlineRunProperties(run2, runProperties, converterContext, inlineRunProperties);
|
|
264453
264455
|
if (marksAsAttrs.length > 0)
|
|
264454
264456
|
run2._explicitFont = true;
|
|
264455
264457
|
if (sdtMetadata)
|
|
@@ -265440,7 +265442,7 @@ function paragraphToFlowBlocks({ para, nextBlockId, positions, storyKey, tracked
|
|
|
265440
265442
|
});
|
|
265441
265443
|
partIndex += 1;
|
|
265442
265444
|
};
|
|
265443
|
-
const visitNode = (node3, inheritedMarks = [], activeSdt, activeRunProperties, activeHidden = false) => {
|
|
265445
|
+
const visitNode = (node3, inheritedMarks = [], activeSdt, activeRunProperties, activeHidden = false, activeInlineRunProperties) => {
|
|
265444
265446
|
if (activeHidden && node3.type !== "run") {
|
|
265445
265447
|
suppressedByVanish = true;
|
|
265446
265448
|
return;
|
|
@@ -265459,6 +265461,7 @@ function paragraphToFlowBlocks({ para, nextBlockId, positions, storyKey, tracked
|
|
|
265459
265461
|
themeColors,
|
|
265460
265462
|
enableComments,
|
|
265461
265463
|
runProperties: activeRunProperties,
|
|
265464
|
+
inlineRunProperties: activeInlineRunProperties,
|
|
265462
265465
|
paragraphProperties: resolvedParagraphProperties,
|
|
265463
265466
|
converterContext,
|
|
265464
265467
|
visitNode,
|
|
@@ -296057,7 +296060,31 @@ menclose::after {
|
|
|
296057
296060
|
if (!normalizedExisting || isAutoColorValue || isDefaultBlack)
|
|
296058
296061
|
run2.color = resolveAutoColor(backgroundColor);
|
|
296059
296062
|
}
|
|
296060
|
-
}, HiddenByVanishError, NotInlineNodeError,
|
|
296063
|
+
}, HiddenByVanishError, NotInlineNodeError, buildBidiContext = (runProperties) => {
|
|
296064
|
+
if (runProperties.rtl == null)
|
|
296065
|
+
return;
|
|
296066
|
+
return { rtl: runProperties.rtl === true };
|
|
296067
|
+
}, buildScriptContext = (runProperties) => {
|
|
296068
|
+
const cs = runProperties.cs;
|
|
296069
|
+
const lang = runProperties.lang;
|
|
296070
|
+
const hasLang = lang != null && (lang.val != null || lang.bidi != null || lang.eastAsia != null);
|
|
296071
|
+
if (cs == null && !hasLang)
|
|
296072
|
+
return;
|
|
296073
|
+
const ctx$1 = {};
|
|
296074
|
+
if (cs != null)
|
|
296075
|
+
ctx$1.complexScript = cs === true;
|
|
296076
|
+
if (hasLang) {
|
|
296077
|
+
const language = {};
|
|
296078
|
+
if (lang.val != null)
|
|
296079
|
+
language.default = lang.val;
|
|
296080
|
+
if (lang.bidi != null)
|
|
296081
|
+
language.complexScript = lang.bidi;
|
|
296082
|
+
if (lang.eastAsia != null)
|
|
296083
|
+
language.eastAsian = lang.eastAsia;
|
|
296084
|
+
ctx$1.language = language;
|
|
296085
|
+
}
|
|
296086
|
+
return ctx$1;
|
|
296087
|
+
}, applyInlineRunProperties = (run2, runProperties, converterContext, inlineRunProperties) => {
|
|
296061
296088
|
if (!runProperties)
|
|
296062
296089
|
return run2;
|
|
296063
296090
|
const runAttrs = computeRunAttrs(runProperties, converterContext);
|
|
@@ -296065,6 +296092,14 @@ menclose::after {
|
|
|
296065
296092
|
for (const key2 of Object.keys(runAttrs))
|
|
296066
296093
|
if (runAttrs[key2] !== undefined)
|
|
296067
296094
|
merged[key2] = runAttrs[key2];
|
|
296095
|
+
if (inlineRunProperties) {
|
|
296096
|
+
const bidi = buildBidiContext(inlineRunProperties);
|
|
296097
|
+
if (bidi)
|
|
296098
|
+
merged.bidi = bidi;
|
|
296099
|
+
const script = buildScriptContext(inlineRunProperties);
|
|
296100
|
+
if (script)
|
|
296101
|
+
merged.script = script;
|
|
296102
|
+
}
|
|
296068
296103
|
return merged;
|
|
296069
296104
|
}, buildSyntheticTextNode = (displayText, marks) => ({
|
|
296070
296105
|
type: "text",
|
|
@@ -302079,7 +302114,7 @@ menclose::after {
|
|
|
302079
302114
|
return;
|
|
302080
302115
|
console.log(...args$1);
|
|
302081
302116
|
}, HEADER_FOOTER_INIT_BUDGET_MS = 200, MAX_ZOOM_WARNING_THRESHOLD = 10, MAX_SELECTION_RECTS_PER_USER = 100, SEMANTIC_RESIZE_DEBOUNCE_MS = 120, MIN_SEMANTIC_CONTENT_WIDTH_PX = 1, GLOBAL_PERFORMANCE, PresentationEditor, ICONS, TEXTS, tableActionsOptions;
|
|
302082
|
-
var
|
|
302117
|
+
var init_src_BdpJXQ5F_es = __esm(() => {
|
|
302083
302118
|
init_rolldown_runtime_Bg48TavK_es();
|
|
302084
302119
|
init_SuperConverter_BInxZk0I_es();
|
|
302085
302120
|
init_jszip_C49i9kUs_es();
|
|
@@ -340140,7 +340175,7 @@ var init_zipper_BxRAi0_5_es = __esm(() => {
|
|
|
340140
340175
|
|
|
340141
340176
|
// ../../packages/superdoc/dist/super-editor.es.js
|
|
340142
340177
|
var init_super_editor_es = __esm(() => {
|
|
340143
|
-
|
|
340178
|
+
init_src_BdpJXQ5F_es();
|
|
340144
340179
|
init_SuperConverter_BInxZk0I_es();
|
|
340145
340180
|
init_jszip_C49i9kUs_es();
|
|
340146
340181
|
init_xml_js_CqGKpaft_es();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@superdoc-dev/cli",
|
|
3
|
-
"version": "0.8.0-next.
|
|
3
|
+
"version": "0.8.0-next.93",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"bin": {
|
|
6
6
|
"superdoc": "./dist/index.js"
|
|
@@ -24,8 +24,8 @@
|
|
|
24
24
|
"@types/node": "22.19.2",
|
|
25
25
|
"@types/ws": "^8.5.13",
|
|
26
26
|
"typescript": "^5.9.2",
|
|
27
|
-
"@superdoc/pm-adapter": "0.0.0",
|
|
28
27
|
"@superdoc/document-api": "0.0.1",
|
|
28
|
+
"@superdoc/pm-adapter": "0.0.0",
|
|
29
29
|
"@superdoc/super-editor": "0.0.1",
|
|
30
30
|
"superdoc": "1.32.0"
|
|
31
31
|
},
|
|
@@ -34,11 +34,11 @@
|
|
|
34
34
|
"access": "public"
|
|
35
35
|
},
|
|
36
36
|
"optionalDependencies": {
|
|
37
|
-
"@superdoc-dev/cli-darwin-arm64": "0.8.0-next.
|
|
38
|
-
"@superdoc-dev/cli-darwin-x64": "0.8.0-next.
|
|
39
|
-
"@superdoc-dev/cli-linux-
|
|
40
|
-
"@superdoc-dev/cli-
|
|
41
|
-
"@superdoc-dev/cli-
|
|
37
|
+
"@superdoc-dev/cli-darwin-arm64": "0.8.0-next.93",
|
|
38
|
+
"@superdoc-dev/cli-darwin-x64": "0.8.0-next.93",
|
|
39
|
+
"@superdoc-dev/cli-linux-arm64": "0.8.0-next.93",
|
|
40
|
+
"@superdoc-dev/cli-linux-x64": "0.8.0-next.93",
|
|
41
|
+
"@superdoc-dev/cli-windows-x64": "0.8.0-next.93"
|
|
42
42
|
},
|
|
43
43
|
"scripts": {
|
|
44
44
|
"predev": "node scripts/ensure-superdoc-build.js",
|