oasis-editor 0.0.311 → 0.0.313

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.
@@ -1,6 +1,6 @@
1
1
  import { EditorState, ReviewDisplayMode } from '../model.js';
2
2
  /** The display sections Word's Show Markup menu filters. */
3
- export type MarkupSection = "insertions" | "deletions" | "comments";
3
+ export type MarkupSection = "insertions" | "deletions" | "comments" | "formatting";
4
4
  /**
5
5
  * View-only Show Markup presentation flags. They live on `EditorState`
6
6
  * (never on the document), so Display for Review modes, tracked-change
@@ -14,6 +14,8 @@ export interface MarkupVisibilityState {
14
14
  showMarkupDeletions?: boolean;
15
15
  /** Paint comment highlights (default on). */
16
16
  showMarkupComments?: boolean;
17
+ /** Paint run-level formatting (property) revisions (default on). */
18
+ showMarkupFormatting?: boolean;
17
19
  /**
18
20
  * Visible markup authors. `undefined` means every author is visible;
19
21
  * an array is the explicit author allow-list.
@@ -39,6 +41,7 @@ export interface MarkupOptionsSnapshot {
39
41
  insertions: boolean;
40
42
  deletions: boolean;
41
43
  comments: boolean;
44
+ formatting: boolean;
42
45
  /** `true` when `markupAuthors` is absent (all authors visible). */
43
46
  allAuthors: boolean;
44
47
  /** Explicitly visible authors (empty when all authors are visible). */
@@ -57,9 +60,10 @@ export declare function applyShowMarkup(state: EditorState, payload: ShowMarkupP
57
60
  export declare function isMarkupAuthorShown(state: EditorState, author: string): boolean;
58
61
  /**
59
62
  * Whether one revision is shown by the current Show Markup filters. Used by
60
- * both the painted overlay and the Reviewing Pane list so the two surfaces
61
- * never disagree. Non-insert/delete revision types are not category-filtered
62
- * (Word's menu only has insertion/deletion/comment categories).
63
+ * the painted overlay, the Reviewing Pane list and Simple Markup change bars
64
+ * so the surfaces never disagree. Insertions, deletions and formatting each
65
+ * have a dedicated category checkbox; other revision types are only filtered
66
+ * by reviewer (there is no category for them).
63
67
  */
64
68
  export declare function isRevisionMarkupShown(state: EditorState, type: string, author: string): boolean;
65
69
  /**
@@ -73,10 +77,10 @@ export declare function reviewDisplayProjection(mode: ReviewDisplayMode | undefi
73
77
  /**
74
78
  * Paragraph ids that should carry a Simple Markup change bar: every paragraph
75
79
  * in the raw document with at least one visible insert/delete text revision or
76
- * run-level formatting (property) revision. Show Markup reviewer filters are
77
- * applied through `isRevisionMarkupShown`, so a hidden reviewer removes its
78
- * bar; category flags only apply to insert/delete (Word has no formatting
79
- * category in this menu). Endnotes have no editable zone and are not walked.
80
+ * run-level formatting (property) revision. Show Markup category and reviewer
81
+ * filters are applied through `isRevisionMarkupShown`, so hiding insertions,
82
+ * deletions, formatting or a reviewer removes the matching bar. Endnotes have
83
+ * no editable zone and are not walked.
80
84
  */
81
85
  export declare function collectChangeBarParagraphIds(state: EditorState): Set<string>;
82
86
  /** The explicit author allow-list, or null when all authors are shown. */
@@ -42,6 +42,8 @@ export interface EditorState {
42
42
  showMarkupDeletions?: boolean;
43
43
  /** Paint comment highlights (default on). */
44
44
  showMarkupComments?: boolean;
45
+ /** Paint run-level formatting (property) revisions (default on). */
46
+ showMarkupFormatting?: boolean;
45
47
  /**
46
48
  * Visible markup authors. `undefined` means every author is visible;
47
49
  * an array is the explicit author allow-list.