@atlaskit/editor-plugin-show-diff 3.2.3 → 3.2.4

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.
@@ -0,0 +1,48 @@
1
+ import type { IntlShape } from 'react-intl-next';
2
+ import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
3
+ export declare const deletedStyleQuoteNode: string;
4
+ export declare const deletedBlockOutline: string;
5
+ export declare const deletedBlockOutlineRounded: string;
6
+ export declare const getDeletedStyleNode: (nodeName: string) => string | undefined;
7
+ export declare const shouldShowRemovedLozenge: (nodeName: string) => boolean;
8
+ export declare const shouldAddShowDiffDeletedNodeClass: (nodeName: string) => boolean;
9
+ /**
10
+ * Checks if a node should apply deleted styles directly without wrapper
11
+ * to preserve natural block-level margins
12
+ */
13
+ export declare const shouldApplyDeletedStylesDirectly: (nodeName: string) => boolean;
14
+ /**
15
+ * Creates a "Removed" lozenge to be displayed at the top right corner of deleted block nodes
16
+ */
17
+ export declare const createRemovedLozenge: (intl: IntlShape, nodeName?: string) => HTMLElement;
18
+ /**
19
+ * Wraps a block node in a container with relative positioning to support absolute positioned lozenge
20
+ */
21
+ export declare const createBlockNodeWrapper: (nodeName: string) => HTMLDivElement;
22
+ /**
23
+ * Wraps content with deleted styling without opacity (for use when content is a direct child of dom)
24
+ */
25
+ export declare const createDeletedStyleWrapperWithoutOpacity: (colourScheme?: "standard" | "traditional") => HTMLSpanElement;
26
+ /**
27
+ * Applies deleted styles directly to an HTML element by merging with existing styles
28
+ */
29
+ export declare const applyDeletedStylesToElement: (element: HTMLElement, targetNode: PMNode, colourScheme: "standard" | "traditional" | undefined) => void;
30
+ /**
31
+ * Creates a content wrapper with deleted styles for a block node
32
+ */
33
+ export declare const createBlockNodeContentWrapper: (nodeView: Node, targetNode: PMNode, colourScheme: "standard" | "traditional" | undefined) => HTMLElement;
34
+ /**
35
+ * Handles special mediaSingle node rendering with lozenge on child media element
36
+ * @returns true if mediaSingle was handled, false otherwise
37
+ */
38
+ export declare const handleMediaSingleWithLozenge: (dom: HTMLElement, nodeView: Node, targetNode: PMNode, lozenge: HTMLElement) => boolean;
39
+ /**
40
+ * Appends a block node with wrapper, lozenge, and appropriate styling
41
+ */
42
+ export declare const appendBlockNodeWithWrapper: (dom: HTMLElement, nodeView: Node, targetNode: PMNode, colourScheme: "standard" | "traditional" | undefined, intl: IntlShape) => void;
43
+ /**
44
+ * Handles all block node rendering with appropriate deleted styling.
45
+ * For blockquote and heading nodes, applies styles directly to preserve natural margins.
46
+ * For other block nodes, uses wrapper approach with optional lozenge.
47
+ */
48
+ export declare const handleBlockNodeView: (dom: HTMLElement, nodeView: Node, targetNode: PMNode, colourScheme: "standard" | "traditional" | undefined, intl: IntlShape) => void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-show-diff",
3
- "version": "3.2.3",
3
+ "version": "3.2.4",
4
4
  "description": "ShowDiff plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -39,7 +39,7 @@
39
39
  "prosemirror-changeset": "^2.2.1"
40
40
  },
41
41
  "peerDependencies": {
42
- "@atlaskit/editor-common": "^110.24.0",
42
+ "@atlaskit/editor-common": "^110.27.0",
43
43
  "react": "^18.2.0"
44
44
  },
45
45
  "techstack": {