oasis-editor 0.0.343 → 0.0.345

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.
@@ -15,7 +15,7 @@ export interface EditorCommandsControllerDeps extends EditorTransactionPort, Foc
15
15
  openImageAltDialog: (initialAlt: string) => void;
16
16
  openImageCaptionDialog: (initialCaption: string) => void;
17
17
  openFontDialog: () => void;
18
- openParagraphDialog: () => void;
18
+ openParagraphDialog: (tabPosition?: number) => void;
19
19
  imageCaptionLabel: () => string;
20
20
  }
21
21
  export declare function createEditorCommandsController(deps: EditorCommandsControllerDeps): ReturnType<typeof createEditorCommandsControllerImpl>;
@@ -50,7 +50,7 @@ declare function createEditorCommandsControllerImpl(deps: EditorCommandsControll
50
50
  applyLinkCommand: (href: string | null) => void;
51
51
  promptForLink: () => void;
52
52
  openFontDialog: () => void;
53
- openParagraphDialog: () => void;
53
+ openParagraphDialog: (tabPosition?: number) => void;
54
54
  openStylesDialog: () => void;
55
55
  openPageSetupDialog: () => void;
56
56
  removeLinkCommand: () => void;
@@ -21,7 +21,7 @@ export type { EditorReviewActivity, EditorReviewActivityKind, } from './types/do
21
21
  export type { EditorOpcPartKind, EditorOpcPartEncoding, EditorOpcRelationship, EditorOpcContentTypes, EditorOpcPart, EditorDocxDiagnostic, EditorDocxSourcePackage, } from './types/docxSourcePackage.js';
22
22
  export type { EditorPageMargins, EditorPageSettings, EditorColumnsSettings, EditorSection, EditorSectionBreakType, EditorSectionPropertiesSnapshot, EditorPageNumbering, EditorSectionVerticalAlign, EditorFontInfo, EditorFootnoteSettings, EditorFootnotes, EditorEndnoteSettings, EditorEndnotes, EditorDocumentDesign, EditorThemeData, EditorWatermark, EditorPageBorder, EditorDocument, } from './types/document.js';
23
23
  export type { EditorPosition, EditorSelection, EditorEditingZone, } from './types/selection.js';
24
- export type { EditorCaretSlot, EditorLayoutFragmentChar, EditorLayoutFragment, EditorLayoutLine, EditorLayoutParagraph, EditorLayoutBlock, TableCellBlockPosition, EditorLayoutPage, EditorLayoutDocument, } from './types/layout.js';
24
+ export type { EditorCaretSlot, EditorLayoutFragmentChar, EditorLayoutFragment, EditorLayoutLine, EditorResolvedTab, EditorLayoutParagraph, EditorLayoutBlock, TableCellBlockPosition, EditorLayoutPage, EditorLayoutDocument, } from './types/layout.js';
25
25
  export type { EditorState, ReviewDisplayMode } from './editorState.js';
26
26
  export { EDITOR_ASSET_REF_PREFIX } from './types/primitives.js';
27
27
  export { DEFAULT_TEXT_STYLE, DEFAULT_PARAGRAPH_STYLE, EFFECTIVE_TEXT_STYLE_DEFAULTS, EFFECTIVE_PARAGRAPH_STYLE_DEFAULTS, } from './styleDefaults.js';
@@ -1,7 +1,7 @@
1
1
  import { EditorBlockNode, EditorTextBoxData } from './nodes.js';
2
2
  import { EditorMathExpression } from './math.js';
3
3
  import { EditorPageSettings } from './document.js';
4
- import { EditorRevision, EditorImageRunData } from './primitives.js';
4
+ import { EditorRevision, EditorImageRunData, EditorTabStop } from './primitives.js';
5
5
  import { EditorTextStyle } from './styles.js';
6
6
  export interface EditorCaretSlot {
7
7
  paragraphId: string;
@@ -28,6 +28,12 @@ export interface EditorLayoutFragment {
28
28
  revision?: EditorRevision;
29
29
  chars: EditorLayoutFragmentChar[];
30
30
  }
31
+ /** Resolved tab identity; the associated caret slots define final paint bounds. */
32
+ export interface EditorResolvedTab {
33
+ stopPositionPx: number;
34
+ type: Exclude<EditorTabStop["type"], "bar" | "clear">;
35
+ leader?: Exclude<NonNullable<EditorTabStop["leader"]>, "none">;
36
+ }
31
37
  export interface EditorLayoutLine {
32
38
  paragraphId: string;
33
39
  index: number;
@@ -38,6 +44,10 @@ export interface EditorLayoutLine {
38
44
  slots: EditorCaretSlot[];
39
45
  fragments: EditorLayoutFragment[];
40
46
  availableWidth?: number;
47
+ /** Resolved tabs keyed by document paragraph offset, not shifted screen x. */
48
+ resolvedTabs?: Record<number, EditorResolvedTab>;
49
+ /** Column-relative x positions of independent vertical bar decorations. */
50
+ barTabPositionsPx?: number[];
41
51
  /**
42
52
  * Set when the line ends mid-word due to automatic hyphenation. Renderers draw
43
53
  * a trailing hyphen glyph after the last fragment; it is not part of the text