@superdoc-dev/cli 0.17.0-next.37 → 0.17.0-next.38

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.
Files changed (2) hide show
  1. package/dist/index.js +244 -198
  2. package/package.json +8 -8
package/dist/index.js CHANGED
@@ -180566,157 +180566,6 @@ var __plugin_vue_export_helper_default = (sfc, props) => {
180566
180566
  };
180567
180567
  var init__plugin_vue_export_helper_HmhZBO0u_es = () => {};
180568
180568
 
180569
- // ../../packages/superdoc/dist/chunks/ui-BMYSpkne.es.js
180570
- function buildAnnotationSelector() {
180571
- return `.${DOM_CLASS_NAMES.ANNOTATION}[${DATA_ATTRS.PM_START}]`;
180572
- }
180573
- function findRenderedCommentElements(host, commentId, storyKey) {
180574
- if (!host || !commentId)
180575
- return [];
180576
- return Array.from(host.querySelectorAll("[data-comment-ids]")).filter((el) => {
180577
- const raw = el.dataset.commentIds;
180578
- if (!raw)
180579
- return false;
180580
- if (!raw.split(",").some((token) => token.trim() === commentId))
180581
- return false;
180582
- if (!storyKey)
180583
- return true;
180584
- const elStoryKey = el.dataset.storyKey;
180585
- if (elStoryKey)
180586
- return elStoryKey === storyKey;
180587
- return storyKey === BODY_STORY_KEY;
180588
- });
180589
- }
180590
- function findRenderedTrackedChangeElementsStrict(host, entityId, escapeAttrValue, storyKey) {
180591
- if (!host || !entityId)
180592
- return [];
180593
- const baseSelector = `[data-track-change-id="${escapeAttrValue(entityId)}"]`;
180594
- if (!storyKey)
180595
- return Array.from(host.querySelectorAll(baseSelector));
180596
- const storySelector = `${baseSelector}[data-story-key="${escapeAttrValue(storyKey)}"]`;
180597
- return Array.from(host.querySelectorAll(storySelector));
180598
- }
180599
- function findRenderedContentControlElements(host, entityId, escapeAttrValue, _storyKey) {
180600
- if (!host || !entityId)
180601
- return [];
180602
- const id2 = escapeAttrValue(entityId);
180603
- const selector = `.${DOM_CLASS_NAMES.INLINE_SDT_WRAPPER}[data-sdt-id="${id2}"][data-sdt-type="structuredContent"],.${DOM_CLASS_NAMES.BLOCK_SDT}[data-sdt-id="${id2}"][data-sdt-type="structuredContent"]`;
180604
- return Array.from(host.querySelectorAll(selector));
180605
- }
180606
- function elementsToRangeRects(elements) {
180607
- const result = [];
180608
- for (const element of elements) {
180609
- const rect = element.getBoundingClientRect();
180610
- if (![
180611
- rect.top,
180612
- rect.left,
180613
- rect.right,
180614
- rect.bottom,
180615
- rect.width,
180616
- rect.height
180617
- ].every(Number.isFinite))
180618
- continue;
180619
- const pageEl = element.closest(".superdoc-page");
180620
- const pageIndexAttr = Number(pageEl?.dataset?.pageIndex ?? 0);
180621
- result.push({
180622
- pageIndex: Number.isFinite(pageIndexAttr) ? pageIndexAttr : 0,
180623
- left: rect.left,
180624
- top: rect.top,
180625
- right: rect.right,
180626
- bottom: rect.bottom,
180627
- width: rect.width,
180628
- height: rect.height
180629
- });
180630
- }
180631
- return result;
180632
- }
180633
- var DOM_CLASS_NAMES, STRUCTURED_CONTENT_CHROME_LABEL_CLASS_NAMES, DATA_ATTRS, DATASET_KEYS, encodeLayoutStoryDataset = (story) => story.kind === "body" ? "body" : story.id ? `${story.kind}:${story.id}` : story.kind, decodeLayoutStoryDataset = (raw) => {
180634
- if (!raw)
180635
- return { kind: "unknown" };
180636
- if (raw === "body")
180637
- return { kind: "body" };
180638
- const idx = raw.indexOf(":");
180639
- const kind = idx === -1 ? raw : raw.slice(0, idx);
180640
- const id2 = idx === -1 ? undefined : raw.slice(idx + 1);
180641
- switch (kind) {
180642
- case "body":
180643
- case "header":
180644
- case "footer":
180645
- case "footnote":
180646
- case "endnote":
180647
- return id2 ? {
180648
- kind,
180649
- id: id2
180650
- } : { kind };
180651
- default:
180652
- return { kind: "unknown" };
180653
- }
180654
- }, DRAGGABLE_SELECTOR;
180655
- var init_ui_BMYSpkne_es = __esm(() => {
180656
- init_SuperConverter_Du0apG1R_es();
180657
- DOM_CLASS_NAMES = {
180658
- PAGE: "superdoc-page",
180659
- FRAGMENT: "superdoc-fragment",
180660
- LINE: "superdoc-line",
180661
- INLINE_SDT_WRAPPER: "superdoc-structured-content-inline",
180662
- INLINE_SDT_LABEL: "superdoc-structured-content-inline__label",
180663
- BLOCK_SDT: "superdoc-structured-content-block",
180664
- BLOCK_SDT_LABEL: "superdoc-structured-content__label",
180665
- TABLE_FRAGMENT: "superdoc-table-fragment",
180666
- DOCUMENT_SECTION: "superdoc-document-section",
180667
- SDT_GROUP_HOVER: "sdt-group-hover",
180668
- TOC_ENTRY: "superdoc-toc-entry",
180669
- TOC_GROUP_HOVER: "toc-group-hover",
180670
- IMAGE_FRAGMENT: "superdoc-image-fragment",
180671
- INLINE_IMAGE: "superdoc-inline-image",
180672
- LIST_MARKER: "superdoc-list-marker",
180673
- INLINE_IMAGE_CLIP_WRAPPER: "superdoc-inline-image-clip-wrapper",
180674
- ANNOTATION: "annotation",
180675
- ANNOTATION_CONTENT: "annotation-content",
180676
- ANNOTATION_CARET_ANCHOR: "annotation-caret-anchor"
180677
- };
180678
- STRUCTURED_CONTENT_CHROME_LABEL_CLASS_NAMES = [DOM_CLASS_NAMES.INLINE_SDT_LABEL, DOM_CLASS_NAMES.BLOCK_SDT_LABEL];
180679
- DATA_ATTRS = {
180680
- PM_START: "data-pm-start",
180681
- PM_END: "data-pm-end",
180682
- LAYOUT_EPOCH: "data-layout-epoch",
180683
- TABLE_BOUNDARIES: "data-table-boundaries",
180684
- SDT_ID: "data-sdt-id",
180685
- SDT_TYPE: "data-sdt-type",
180686
- FIELD_ID: "data-field-id",
180687
- FIELD_TYPE: "data-field-type",
180688
- DRAGGABLE: "data-draggable",
180689
- DISPLAY_LABEL: "data-display-label",
180690
- VARIANT: "data-variant",
180691
- TYPE: "data-type",
180692
- LAYOUT_BOUNDARY_SCHEMA: "data-layout-boundary-schema",
180693
- LAYOUT_FRAGMENT_ID: "data-layout-fragment-id",
180694
- LAYOUT_STORY: "data-layout-story",
180695
- LAYOUT_BLOCK_REF: "data-layout-block-ref"
180696
- };
180697
- DATASET_KEYS = {
180698
- PM_START: "pmStart",
180699
- PM_END: "pmEnd",
180700
- LAYOUT_EPOCH: "layoutEpoch",
180701
- TABLE_BOUNDARIES: "tableBoundaries",
180702
- SDT_ID: "sdtId",
180703
- SDT_TYPE: "sdtType",
180704
- FIELD_ID: "fieldId",
180705
- FIELD_TYPE: "fieldType",
180706
- DRAGGABLE: "draggable",
180707
- DISPLAY_LABEL: "displayLabel",
180708
- VARIANT: "variant",
180709
- TYPE: "type",
180710
- LAYOUT_BOUNDARY_SCHEMA: "layoutBoundarySchema",
180711
- LAYOUT_FRAGMENT_ID: "layoutFragmentId",
180712
- LAYOUT_STORY: "layoutStory",
180713
- LAYOUT_BLOCK_REF: "layoutBlockRef"
180714
- };
180715
- `${DOM_CLASS_NAMES.BLOCK_SDT}${DATA_ATTRS.SDT_ID}`;
180716
- DRAGGABLE_SELECTOR = `[${DATA_ATTRS.DRAGGABLE}="true"]`;
180717
- DATA_ATTRS.LAYOUT_EPOCH;
180718
- });
180719
-
180720
180569
  // ../../packages/superdoc/dist/chunks/eventemitter3-UwU_CLPU.es.js
180721
180570
  var import_eventemitter3;
180722
180571
  var init_eventemitter3_UwU_CLPU_es = __esm(() => {
@@ -227233,7 +227082,7 @@ var init_remark_gfm_DCND_V_3_es = __esm(() => {
227233
227082
  init_remark_gfm_BUJjZJLy_es();
227234
227083
  });
227235
227084
 
227236
- // ../../packages/superdoc/dist/chunks/src-bGJhSgx_.es.js
227085
+ // ../../packages/superdoc/dist/chunks/src-DfMY3HP9.es.js
227237
227086
  function deleteProps(obj, propOrProps) {
227238
227087
  const props = typeof propOrProps === "string" ? [propOrProps] : propOrProps;
227239
227088
  const removeNested = (target, pathParts, index2 = 0) => {
@@ -236683,6 +236532,9 @@ function replaceCommand(wrap5, moveForward) {
236683
236532
  return true;
236684
236533
  };
236685
236534
  }
236535
+ function buildAnnotationSelector() {
236536
+ return `.${DOM_CLASS_NAMES.ANNOTATION}[${DATA_ATTRS.PM_START}]`;
236537
+ }
236686
236538
  function isPresenting(editor) {
236687
236539
  const presentationCtx = editor?.presentationEditor;
236688
236540
  if (!presentationCtx)
@@ -275105,7 +274957,7 @@ function getMeasurementContext() {
275105
274957
  function getRunFontString(run2) {
275106
274958
  if (run2.kind === "tab" || run2.kind === "lineBreak" || run2.kind === "break" || run2.kind === "fieldAnnotation" || run2.kind === "math" || "src" in run2)
275107
274959
  return "normal normal 16px Arial";
275108
- return `${run2.italic ? "italic" : "normal"} ${run2.bold ? "bold" : "normal"} ${run2.fontSize ?? 16}px ${DEFAULT_FONT_MEASURE_CONTEXT.resolvePhysical(run2.fontFamily ?? "Arial", faceOf$1(run2))}`;
274960
+ return `${run2.italic ? "italic" : "normal"} ${run2.bold ? "bold" : "normal"} ${run2.fontSize ?? 16}px ${run2.fontFamily ?? "Arial"}`;
275109
274961
  }
275110
274962
  function measureCharacterX(block, line, charOffset, availableWidthOverride, alignmentOverride) {
275111
274963
  const ctx$1 = getMeasurementContext();
@@ -275245,43 +275097,97 @@ function charOffsetToPm(block, line, charOffset, fallbackPmStart) {
275245
275097
  return lastPm;
275246
275098
  }
275247
275099
  function findCharacterAtX(block, line, x, pmStart, availableWidthOverride, alignmentOverride) {
275248
- const maxOffset = lineCharLength(block, line);
275249
- const xAtOffset = (offset$1) => measureCharacterX(block, line, offset$1, availableWidthOverride, alignmentOverride);
275250
- const charOffset = nearestOffsetToX(x, maxOffset, xAtOffset);
275251
- return {
275252
- charOffset,
275253
- pmPosition: charOffsetToPm(block, line, charOffset, pmStart)
275254
- };
275255
- }
275256
- function lineCharLength(block, line) {
275257
- let length$12 = 0;
275258
- for (const run2 of sliceRunsForLine(block, line)) {
275100
+ const ctx$1 = getMeasurementContext();
275101
+ const availableWidth = availableWidthOverride ?? line.maxWidth ?? line.width;
275102
+ const justify = getJustifyAdjustment({
275103
+ block,
275104
+ line,
275105
+ availableWidthOverride: availableWidth,
275106
+ alignmentOverride
275107
+ });
275108
+ const alignment$1 = alignmentOverride ?? (block.kind === "paragraph" ? block.attrs?.alignment : undefined);
275109
+ const renderedLineWidth = alignment$1 === "justify" ? line.width + Math.max(0, availableWidth - line.width) : line.width;
275110
+ const hasExplicitPositioning = line.segments?.some((seg) => seg.x !== undefined);
275111
+ const alignmentOffset = !hasExplicitPositioning && alignment$1 === "center" ? Math.max(0, (availableWidth - renderedLineWidth) / 2) : !hasExplicitPositioning && alignment$1 === "right" ? Math.max(0, availableWidth - renderedLineWidth) : 0;
275112
+ if (!ctx$1) {
275113
+ const runs$1 = sliceRunsForLine(block, line);
275114
+ const charsInLine = Math.max(1, runs$1.reduce((sum, run2) => {
275115
+ if (isTabRun$1(run2))
275116
+ return sum + TAB_CHAR_LENGTH;
275117
+ if ("src" in run2 || run2.kind === "lineBreak" || run2.kind === "break" || run2.kind === "fieldAnnotation" || run2.kind === "math")
275118
+ return sum;
275119
+ return sum + (run2.text ?? "").length;
275120
+ }, 0));
275121
+ const ratio = Math.max(0, Math.min(1, (x - alignmentOffset) / renderedLineWidth));
275122
+ const charOffset = Math.round(ratio * charsInLine);
275123
+ return {
275124
+ charOffset,
275125
+ pmPosition: charOffsetToPm(block, line, charOffset, pmStart)
275126
+ };
275127
+ }
275128
+ const runs2 = sliceRunsForLine(block, line);
275129
+ const safeX = Math.max(0, Math.min(renderedLineWidth, x - alignmentOffset));
275130
+ let currentX = 0;
275131
+ let currentCharOffset = 0;
275132
+ let spaceTally = 0;
275133
+ for (const run2 of runs2) {
275259
275134
  if (isTabRun$1(run2)) {
275260
- length$12 += TAB_CHAR_LENGTH;
275135
+ const tabWidth = run2.width ?? 0;
275136
+ const startX = currentX;
275137
+ const endX = currentX + tabWidth;
275138
+ if (safeX <= endX) {
275139
+ const offsetInRun = safeX < startX + tabWidth / 2 ? 0 : TAB_CHAR_LENGTH;
275140
+ const charOffset = currentCharOffset + offsetInRun;
275141
+ return {
275142
+ charOffset,
275143
+ pmPosition: charOffsetToPm(block, line, charOffset, pmStart)
275144
+ };
275145
+ }
275146
+ currentX = endX;
275147
+ currentCharOffset += TAB_CHAR_LENGTH;
275261
275148
  continue;
275262
275149
  }
275263
- if ("src" in run2 || run2.kind === "lineBreak" || run2.kind === "break" || run2.kind === "fieldAnnotation" || run2.kind === "math")
275150
+ const text5 = "src" in run2 || run2.kind === "lineBreak" || run2.kind === "break" || run2.kind === "fieldAnnotation" || run2.kind === "math" ? "" : run2.text ?? "";
275151
+ const runLength = text5.length;
275152
+ const displayText = applyTextTransform$3(text5, isTabRun$1(run2) || "src" in run2 || run2.kind === "lineBreak" || run2.kind === "break" || run2.kind === "fieldAnnotation" || run2.kind === "math" ? undefined : run2.textTransform);
275153
+ if (runLength === 0)
275264
275154
  continue;
275265
- length$12 += (run2.text ?? "").length;
275266
- }
275267
- return length$12;
275268
- }
275269
- function nearestOffsetToX(x, maxOffset, xAtOffset) {
275270
- if (maxOffset <= 0 || x <= xAtOffset(0))
275271
- return 0;
275272
- if (x >= xAtOffset(maxOffset))
275273
- return maxOffset;
275274
- let lo = 0;
275275
- let hi = maxOffset;
275276
- while (lo < hi) {
275277
- const mid = lo + hi + 1 >> 1;
275278
- if (xAtOffset(mid) <= x)
275279
- lo = mid;
275280
- else
275281
- hi = mid - 1;
275155
+ ctx$1.font = getRunFontString(run2);
275156
+ for (let i3 = 0;i3 <= runLength; i3++) {
275157
+ const textUpToChar = displayText.slice(0, i3);
275158
+ const measured$1 = ctx$1.measureText(textUpToChar);
275159
+ const spacesInPortion = justify.extraPerSpace > 0 ? countSpaces(text5.slice(0, i3)) : 0;
275160
+ const charX = currentX + measured$1.width + computeLetterSpacingWidth(run2, i3, runLength) + justify.extraPerSpace * (spaceTally + spacesInPortion);
275161
+ if (charX >= safeX) {
275162
+ if (i3 === 0) {
275163
+ const pmPosition$1 = charOffsetToPm(block, line, currentCharOffset, pmStart);
275164
+ return {
275165
+ charOffset: currentCharOffset,
275166
+ pmPosition: pmPosition$1
275167
+ };
275168
+ }
275169
+ const prevText = displayText.slice(0, i3 - 1);
275170
+ const prevMeasured = ctx$1.measureText(prevText);
275171
+ const prevX = currentX + prevMeasured.width + computeLetterSpacingWidth(run2, i3 - 1, runLength);
275172
+ const charOffset = Math.abs(safeX - prevX) < Math.abs(safeX - charX) ? currentCharOffset + i3 - 1 : currentCharOffset + i3;
275173
+ return {
275174
+ charOffset,
275175
+ pmPosition: charOffsetToPm(block, line, charOffset, pmStart)
275176
+ };
275177
+ }
275178
+ }
275179
+ const measured = ctx$1.measureText(displayText);
275180
+ const runLetterSpacing = computeLetterSpacingWidth(run2, runLength, runLength);
275181
+ const spacesInRun = justify.extraPerSpace > 0 ? countSpaces(text5) : 0;
275182
+ currentX += measured.width + runLetterSpacing + justify.extraPerSpace * spacesInRun;
275183
+ spaceTally += spacesInRun;
275184
+ currentCharOffset += runLength;
275282
275185
  }
275283
- const upper = Math.min(lo + 1, maxOffset);
275284
- return x - xAtOffset(lo) < xAtOffset(upper) - x ? lo : upper;
275186
+ const pmPosition = charOffsetToPm(block, line, currentCharOffset, pmStart);
275187
+ return {
275188
+ charOffset: currentCharOffset,
275189
+ pmPosition
275190
+ };
275285
275191
  }
275286
275192
  function getWordLayoutConfig(block) {
275287
275193
  if (!block || block.kind !== "paragraph")
@@ -280938,6 +280844,66 @@ function createHiddenHost(doc$12, widthPx) {
280938
280844
  host
280939
280845
  };
280940
280846
  }
280847
+ function findRenderedCommentElements(host, commentId, storyKey) {
280848
+ if (!host || !commentId)
280849
+ return [];
280850
+ return Array.from(host.querySelectorAll("[data-comment-ids]")).filter((el) => {
280851
+ const raw = el.dataset.commentIds;
280852
+ if (!raw)
280853
+ return false;
280854
+ if (!raw.split(",").some((token$1) => token$1.trim() === commentId))
280855
+ return false;
280856
+ if (!storyKey)
280857
+ return true;
280858
+ const elStoryKey = el.dataset.storyKey;
280859
+ if (elStoryKey)
280860
+ return elStoryKey === storyKey;
280861
+ return storyKey === BODY_STORY_KEY;
280862
+ });
280863
+ }
280864
+ function findRenderedTrackedChangeElementsStrict(host, entityId, escapeAttrValue$1, storyKey) {
280865
+ if (!host || !entityId)
280866
+ return [];
280867
+ const baseSelector = `[data-track-change-id="${escapeAttrValue$1(entityId)}"]`;
280868
+ if (!storyKey)
280869
+ return Array.from(host.querySelectorAll(baseSelector));
280870
+ const storySelector = `${baseSelector}[data-story-key="${escapeAttrValue$1(storyKey)}"]`;
280871
+ return Array.from(host.querySelectorAll(storySelector));
280872
+ }
280873
+ function findRenderedContentControlElements(host, entityId, escapeAttrValue$1, _storyKey) {
280874
+ if (!host || !entityId)
280875
+ return [];
280876
+ const id2 = escapeAttrValue$1(entityId);
280877
+ const selector = `.${DOM_CLASS_NAMES.INLINE_SDT_WRAPPER}[data-sdt-id="${id2}"][data-sdt-type="structuredContent"],.${DOM_CLASS_NAMES.BLOCK_SDT}[data-sdt-id="${id2}"][data-sdt-type="structuredContent"]`;
280878
+ return Array.from(host.querySelectorAll(selector));
280879
+ }
280880
+ function elementsToRangeRects(elements) {
280881
+ const result = [];
280882
+ for (const element3 of elements) {
280883
+ const rect = element3.getBoundingClientRect();
280884
+ if (![
280885
+ rect.top,
280886
+ rect.left,
280887
+ rect.right,
280888
+ rect.bottom,
280889
+ rect.width,
280890
+ rect.height
280891
+ ].every(Number.isFinite))
280892
+ continue;
280893
+ const pageEl = element3.closest(".superdoc-page");
280894
+ const pageIndexAttr = Number(pageEl?.dataset?.pageIndex ?? 0);
280895
+ result.push({
280896
+ pageIndex: Number.isFinite(pageIndexAttr) ? pageIndexAttr : 0,
280897
+ left: rect.left,
280898
+ top: rect.top,
280899
+ right: rect.right,
280900
+ bottom: rect.bottom,
280901
+ width: rect.width,
280902
+ height: rect.height
280903
+ });
280904
+ }
280905
+ return result;
280906
+ }
280941
280907
  function getFallbackCursorColor(clientId, fallbackColors) {
280942
280908
  return fallbackColors[clientId % fallbackColors.length];
280943
280909
  }
@@ -302516,7 +302482,28 @@ var Node$13 = class Node$14 {
302516
302482
  if (!allowedRanges?.length)
302517
302483
  return false;
302518
302484
  return allowedRanges.some((allowed) => range.from >= allowed.from && range.to <= allowed.to);
302519
- }, PermissionRanges, Protection, VerticalNavigationPluginKey, createDefaultState = () => ({
302485
+ }, PermissionRanges, Protection, DOM_CLASS_NAMES, STRUCTURED_CONTENT_CHROME_LABEL_CLASS_NAMES, DATA_ATTRS, DATASET_KEYS, encodeLayoutStoryDataset = (story) => story.kind === "body" ? "body" : story.id ? `${story.kind}:${story.id}` : story.kind, decodeLayoutStoryDataset = (raw) => {
302486
+ if (!raw)
302487
+ return { kind: "unknown" };
302488
+ if (raw === "body")
302489
+ return { kind: "body" };
302490
+ const idx = raw.indexOf(":");
302491
+ const kind = idx === -1 ? raw : raw.slice(0, idx);
302492
+ const id2 = idx === -1 ? undefined : raw.slice(idx + 1);
302493
+ switch (kind) {
302494
+ case "body":
302495
+ case "header":
302496
+ case "footer":
302497
+ case "footnote":
302498
+ case "endnote":
302499
+ return id2 ? {
302500
+ kind,
302501
+ id: id2
302502
+ } : { kind };
302503
+ default:
302504
+ return { kind: "unknown" };
302505
+ }
302506
+ }, DRAGGABLE_SELECTOR, VerticalNavigationPluginKey, createDefaultState = () => ({
302520
302507
  goalX: null,
302521
302508
  goalClientX: null
302522
302509
  }), VerticalNavigation, STRONG_RTL_CHAR_RE$1, STRONG_LTR_CHAR_RE, isStrongRtl = (char) => STRONG_RTL_CHAR_RE$1.test(char), isStrongLtr = (char) => STRONG_LTR_CHAR_RE.test(char), hasMixedDirectionBoundary = (leftChar, rightChar) => isStrongRtl(leftChar) && isStrongLtr(rightChar) || isStrongLtr(leftChar) && isStrongRtl(rightChar), resolveCaretPoint = (doc$12, range) => {
@@ -314672,7 +314659,7 @@ menclose::after {
314672
314659
  container.style.width = `${Math.max(0, data.contentWidth)}px`;
314673
314660
  else
314674
314661
  container.style.width = `calc(100% - ${marginLeft + marginRight}px)`;
314675
- container.style.pointerEvents = "auto";
314662
+ container.style.pointerEvents = "none";
314676
314663
  container.style.height = `${effectiveHeight}px`;
314677
314664
  container.style.top = `${Math.max(0, effectiveOffset)}px`;
314678
314665
  container.style.zIndex = "1";
@@ -317042,10 +317029,7 @@ menclose::after {
317042
317029
  return run2.text?.length ?? 0;
317043
317030
  }, isVisualOnlyRun = (run2) => {
317044
317031
  return getRunDataAttrs(run2)?.[FOOTNOTE_MARKER_DATA_ATTR$1] === "true";
317045
- }, SPACE_CHARS$1, isTabRun$1 = (run2) => run2?.kind === "tab", faceOf$1 = (run2) => ({
317046
- weight: run2.bold ? "700" : "400",
317047
- style: run2.italic ? "italic" : "normal"
317048
- }), isWordChar$3 = (char) => {
317032
+ }, SPACE_CHARS$1, isTabRun$1 = (run2) => run2?.kind === "tab", isWordChar$3 = (char) => {
317049
317033
  if (!char)
317050
317034
  return false;
317051
317035
  const code6 = char.charCodeAt(0);
@@ -326216,7 +326200,7 @@ menclose::after {
326216
326200
  return;
326217
326201
  console.log(...args$1);
326218
326202
  }, 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, TRACKED_MARK_NAMES;
326219
- var init_src_bGJhSgx__es = __esm(() => {
326203
+ var init_src_DfMY3HP9_es = __esm(() => {
326220
326204
  init_rolldown_runtime_Bg48TavK_es();
326221
326205
  init_SuperConverter_Du0apG1R_es();
326222
326206
  init_jszip_C49i9kUs_es();
@@ -326229,7 +326213,6 @@ var init_src_bGJhSgx__es = __esm(() => {
326229
326213
  init_remark_stringify_BZvKOjUX_es();
326230
326214
  init_DocxZipper_BzS208BW_es();
326231
326215
  init__plugin_vue_export_helper_HmhZBO0u_es();
326232
- init_ui_BMYSpkne_es();
326233
326216
  init_eventemitter3_UwU_CLPU_es();
326234
326217
  init_errors_C_DoKMoN_es();
326235
326218
  init_blank_docx_CDDHd6CH_es();
@@ -351403,6 +351386,66 @@ function print() { __p += __j.call(arguments, '') }
351403
351386
  };
351404
351387
  }
351405
351388
  });
351389
+ DOM_CLASS_NAMES = {
351390
+ PAGE: "superdoc-page",
351391
+ FRAGMENT: "superdoc-fragment",
351392
+ LINE: "superdoc-line",
351393
+ INLINE_SDT_WRAPPER: "superdoc-structured-content-inline",
351394
+ INLINE_SDT_LABEL: "superdoc-structured-content-inline__label",
351395
+ BLOCK_SDT: "superdoc-structured-content-block",
351396
+ BLOCK_SDT_LABEL: "superdoc-structured-content__label",
351397
+ TABLE_FRAGMENT: "superdoc-table-fragment",
351398
+ DOCUMENT_SECTION: "superdoc-document-section",
351399
+ SDT_GROUP_HOVER: "sdt-group-hover",
351400
+ TOC_ENTRY: "superdoc-toc-entry",
351401
+ TOC_GROUP_HOVER: "toc-group-hover",
351402
+ IMAGE_FRAGMENT: "superdoc-image-fragment",
351403
+ INLINE_IMAGE: "superdoc-inline-image",
351404
+ LIST_MARKER: "superdoc-list-marker",
351405
+ INLINE_IMAGE_CLIP_WRAPPER: "superdoc-inline-image-clip-wrapper",
351406
+ ANNOTATION: "annotation",
351407
+ ANNOTATION_CONTENT: "annotation-content",
351408
+ ANNOTATION_CARET_ANCHOR: "annotation-caret-anchor"
351409
+ };
351410
+ STRUCTURED_CONTENT_CHROME_LABEL_CLASS_NAMES = [DOM_CLASS_NAMES.INLINE_SDT_LABEL, DOM_CLASS_NAMES.BLOCK_SDT_LABEL];
351411
+ DATA_ATTRS = {
351412
+ PM_START: "data-pm-start",
351413
+ PM_END: "data-pm-end",
351414
+ LAYOUT_EPOCH: "data-layout-epoch",
351415
+ TABLE_BOUNDARIES: "data-table-boundaries",
351416
+ SDT_ID: "data-sdt-id",
351417
+ SDT_TYPE: "data-sdt-type",
351418
+ FIELD_ID: "data-field-id",
351419
+ FIELD_TYPE: "data-field-type",
351420
+ DRAGGABLE: "data-draggable",
351421
+ DISPLAY_LABEL: "data-display-label",
351422
+ VARIANT: "data-variant",
351423
+ TYPE: "data-type",
351424
+ LAYOUT_BOUNDARY_SCHEMA: "data-layout-boundary-schema",
351425
+ LAYOUT_FRAGMENT_ID: "data-layout-fragment-id",
351426
+ LAYOUT_STORY: "data-layout-story",
351427
+ LAYOUT_BLOCK_REF: "data-layout-block-ref"
351428
+ };
351429
+ DATASET_KEYS = {
351430
+ PM_START: "pmStart",
351431
+ PM_END: "pmEnd",
351432
+ LAYOUT_EPOCH: "layoutEpoch",
351433
+ TABLE_BOUNDARIES: "tableBoundaries",
351434
+ SDT_ID: "sdtId",
351435
+ SDT_TYPE: "sdtType",
351436
+ FIELD_ID: "fieldId",
351437
+ FIELD_TYPE: "fieldType",
351438
+ DRAGGABLE: "draggable",
351439
+ DISPLAY_LABEL: "displayLabel",
351440
+ VARIANT: "variant",
351441
+ TYPE: "type",
351442
+ LAYOUT_BOUNDARY_SCHEMA: "layoutBoundarySchema",
351443
+ LAYOUT_FRAGMENT_ID: "layoutFragmentId",
351444
+ LAYOUT_STORY: "layoutStory",
351445
+ LAYOUT_BLOCK_REF: "layoutBlockRef"
351446
+ };
351447
+ `${DOM_CLASS_NAMES.BLOCK_SDT}${DATA_ATTRS.SDT_ID}`;
351448
+ DRAGGABLE_SELECTOR = `[${DATA_ATTRS.DRAGGABLE}="true"]`;
351406
351449
  VerticalNavigationPluginKey = new PluginKey("verticalNavigation");
351407
351450
  VerticalNavigation = Extension.create({
351408
351451
  name: "verticalNavigation",
@@ -368411,9 +368454,9 @@ function print() { __p += __j.call(arguments, '') }
368411
368454
  ]);
368412
368455
  });
368413
368456
 
368414
- // ../../packages/superdoc/dist/chunks/create-super-doc-ui-NCPalg_h.es.js
368457
+ // ../../packages/superdoc/dist/chunks/create-super-doc-ui-oSlpT6HI.es.js
368415
368458
  var DEFAULT_TEXT_ALIGN_OPTIONS, DEFAULT_LINE_HEIGHT_OPTIONS, DEFAULT_ZOOM_OPTIONS, DEFAULT_DOCUMENT_MODE_OPTIONS, DEFAULT_FONT_SIZE_OPTIONS, headlessToolbarConstants, MOD_ALIASES, ALT_ALIASES, CTRL_ALIASES, SHIFT_ALIASES, BUILTIN_CONTEXT_MENU_GROUPS, BUILTIN_GROUP_ORDER, RESERVED_PROXY_PROPERTY_NAMES, ALL_TOOLBAR_COMMAND_IDS, EMPTY_ACTIVE_IDS, FONT_SIZE_OPTIONS;
368416
- var init_create_super_doc_ui_NCPalg_h_es = __esm(() => {
368459
+ var init_create_super_doc_ui_oSlpT6HI_es = __esm(() => {
368417
368460
  init_SuperConverter_Du0apG1R_es();
368418
368461
  init_create_headless_toolbar_BNcguDpP_es();
368419
368462
  DEFAULT_TEXT_ALIGN_OPTIONS = [
@@ -368693,6 +368736,9 @@ var init_create_super_doc_ui_NCPalg_h_es = __esm(() => {
368693
368736
  }));
368694
368737
  });
368695
368738
 
368739
+ // ../../packages/superdoc/dist/chunks/ui-CGB3qmy3.es.js
368740
+ var init_ui_CGB3qmy3_es = () => {};
368741
+
368696
368742
  // ../../packages/superdoc/dist/chunks/zipper-BxRAi0-5.es.js
368697
368743
  var import_jszip_min3;
368698
368744
  var init_zipper_BxRAi0_5_es = __esm(() => {
@@ -368703,7 +368749,7 @@ var init_zipper_BxRAi0_5_es = __esm(() => {
368703
368749
 
368704
368750
  // ../../packages/superdoc/dist/super-editor.es.js
368705
368751
  var init_super_editor_es = __esm(() => {
368706
- init_src_bGJhSgx__es();
368752
+ init_src_DfMY3HP9_es();
368707
368753
  init_SuperConverter_Du0apG1R_es();
368708
368754
  init_jszip_C49i9kUs_es();
368709
368755
  init_xml_js_CqGKpaft_es();
@@ -368711,8 +368757,8 @@ var init_super_editor_es = __esm(() => {
368711
368757
  init_constants_D9qj59G2_es();
368712
368758
  init_unified_BDuVPlMu_es();
368713
368759
  init_DocxZipper_BzS208BW_es();
368714
- init_ui_BMYSpkne_es();
368715
- init_create_super_doc_ui_NCPalg_h_es();
368760
+ init_create_super_doc_ui_oSlpT6HI_es();
368761
+ init_ui_CGB3qmy3_es();
368716
368762
  init_eventemitter3_UwU_CLPU_es();
368717
368763
  init_errors_C_DoKMoN_es();
368718
368764
  init_zipper_BxRAi0_5_es();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@superdoc-dev/cli",
3
- "version": "0.17.0-next.37",
3
+ "version": "0.17.0-next.38",
4
4
  "type": "module",
5
5
  "bin": {
6
6
  "superdoc": "./dist/index.js"
@@ -26,20 +26,20 @@
26
26
  "lib0": "^0.2.114",
27
27
  "typescript": "^5.9.2",
28
28
  "y-protocols": "^1.0.6",
29
- "@superdoc/document-api": "0.1.0-alpha.0",
29
+ "@superdoc/super-editor": "0.0.1",
30
30
  "superdoc": "1.41.0",
31
- "@superdoc/super-editor": "0.0.1"
31
+ "@superdoc/document-api": "0.1.0-alpha.0"
32
32
  },
33
33
  "module": "src/index.ts",
34
34
  "publishConfig": {
35
35
  "access": "public"
36
36
  },
37
37
  "optionalDependencies": {
38
- "@superdoc-dev/cli-darwin-x64": "0.17.0-next.37",
39
- "@superdoc-dev/cli-darwin-arm64": "0.17.0-next.37",
40
- "@superdoc-dev/cli-linux-x64": "0.17.0-next.37",
41
- "@superdoc-dev/cli-linux-arm64": "0.17.0-next.37",
42
- "@superdoc-dev/cli-windows-x64": "0.17.0-next.37"
38
+ "@superdoc-dev/cli-darwin-arm64": "0.17.0-next.38",
39
+ "@superdoc-dev/cli-darwin-x64": "0.17.0-next.38",
40
+ "@superdoc-dev/cli-linux-x64": "0.17.0-next.38",
41
+ "@superdoc-dev/cli-windows-x64": "0.17.0-next.38",
42
+ "@superdoc-dev/cli-linux-arm64": "0.17.0-next.38"
43
43
  },
44
44
  "scripts": {
45
45
  "predev": "node scripts/ensure-superdoc-build.js",