@atlaskit/editor-plugin-show-diff 9.0.5 → 9.0.7
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/CHANGELOG.md +14 -0
- package/dist/cjs/pm-plugins/decorations/colorSchemes/standard.js +20 -1
- package/dist/cjs/pm-plugins/decorations/createInlineChangedDecoration.js +1 -1
- package/dist/cjs/pm-plugins/decorations/createNodeChangedDecorationWidget.js +2 -2
- package/dist/cjs/pm-plugins/decorations/utils/wrapBlockNodeView.js +2 -2
- package/dist/es2019/pm-plugins/decorations/colorSchemes/standard.js +19 -0
- package/dist/es2019/pm-plugins/decorations/createInlineChangedDecoration.js +2 -2
- package/dist/es2019/pm-plugins/decorations/createNodeChangedDecorationWidget.js +3 -3
- package/dist/es2019/pm-plugins/decorations/utils/wrapBlockNodeView.js +3 -3
- package/dist/esm/pm-plugins/decorations/colorSchemes/standard.js +19 -0
- package/dist/esm/pm-plugins/decorations/createInlineChangedDecoration.js +2 -2
- package/dist/esm/pm-plugins/decorations/createNodeChangedDecorationWidget.js +3 -3
- package/dist/esm/pm-plugins/decorations/utils/wrapBlockNodeView.js +3 -3
- package/dist/types/pm-plugins/decorations/colorSchemes/standard.d.ts +3 -0
- package/dist/types-ts4.5/pm-plugins/decorations/colorSchemes/standard.d.ts +3 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-show-diff
|
|
2
2
|
|
|
3
|
+
## 9.0.7
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 9.0.6
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [`ca2189db06329`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/ca2189db06329) -
|
|
14
|
+
Update diff style
|
|
15
|
+
- Updated dependencies
|
|
16
|
+
|
|
3
17
|
## 9.0.5
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
|
@@ -3,8 +3,9 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.standardDecorationMarkerVariable = exports.editingStyleRuleNode = exports.editingStyleQuoteNode = exports.editingStyleNode = exports.editingStyleCardBlockNode = exports.editingStyleActive = exports.editingStyle = exports.editingContentStyleInBlock = exports.deletedStyleQuoteNodeWithLozengeActive = exports.deletedStyleQuoteNodeWithLozenge = exports.deletedStyleQuoteNode = exports.deletedRowStyle = exports.deletedInlineContentBackground = exports.deletedContentStyleUnbounded = exports.deletedContentStyleNew = exports.deletedContentStyleActive = exports.deletedContentStyle = exports.deletedCellOverlayStyle = exports.deletedBlockOutlineRoundedActive = exports.deletedBlockOutlineRounded = exports.deletedBlockOutlineActive = exports.deletedBlockOutline = exports.addedCellOverlayStyle = void 0;
|
|
6
|
+
exports.standardDecorationMarkerVariable = exports.editingStyleRuleNode = exports.editingStyleQuoteNode = exports.editingStyleNode = exports.editingStyleExtended = exports.editingStyleCardBlockNode = exports.editingStyleActiveExtended = exports.editingStyleActive = exports.editingStyle = exports.editingContentStyleInBlockExtended = exports.editingContentStyleInBlock = exports.deletedStyleQuoteNodeWithLozengeActive = exports.deletedStyleQuoteNodeWithLozenge = exports.deletedStyleQuoteNode = exports.deletedRowStyle = exports.deletedInlineContentBackground = exports.deletedContentStyleUnbounded = exports.deletedContentStyleNew = exports.deletedContentStyleActive = exports.deletedContentStyle = exports.deletedCellOverlayStyle = exports.deletedBlockOutlineRoundedActive = exports.deletedBlockOutlineRounded = exports.deletedBlockOutlineActive = exports.deletedBlockOutline = exports.addedCellOverlayStyle = void 0;
|
|
7
7
|
var _lazyNodeView = require("@atlaskit/editor-common/lazy-node-view");
|
|
8
|
+
// delete on platform_editor_diff_plugin_extended cleanup
|
|
8
9
|
var editingStyle = exports.editingStyle = (0, _lazyNodeView.convertToInlineCss)({
|
|
9
10
|
background: "var(--ds-background-accent-purple-subtlest, #F8EEFE)",
|
|
10
11
|
textDecoration: 'underline',
|
|
@@ -12,12 +13,16 @@ var editingStyle = exports.editingStyle = (0, _lazyNodeView.convertToInlineCss)(
|
|
|
12
13
|
textDecorationThickness: "var(--ds-space-025, 2px)",
|
|
13
14
|
textDecorationColor: "var(--ds-border-accent-purple, #AF59E1)"
|
|
14
15
|
});
|
|
16
|
+
|
|
17
|
+
// delete on platform_editor_diff_plugin_extended cleanup
|
|
15
18
|
var editingContentStyleInBlock = exports.editingContentStyleInBlock = (0, _lazyNodeView.convertToInlineCss)({
|
|
16
19
|
textDecoration: 'underline',
|
|
17
20
|
textDecorationStyle: 'dotted',
|
|
18
21
|
textDecorationThickness: "var(--ds-space-025, 2px)",
|
|
19
22
|
textDecorationColor: "var(--ds-border-accent-purple, #AF59E1)"
|
|
20
23
|
});
|
|
24
|
+
|
|
25
|
+
// delete on platform_editor_diff_plugin_extended cleanup
|
|
21
26
|
var editingStyleActive = exports.editingStyleActive = (0, _lazyNodeView.convertToInlineCss)({
|
|
22
27
|
background: "var(--ds-background-accent-purple-subtler-pressed, #D8A0F7)",
|
|
23
28
|
textDecoration: 'underline',
|
|
@@ -25,6 +30,20 @@ var editingStyleActive = exports.editingStyleActive = (0, _lazyNodeView.convertT
|
|
|
25
30
|
textDecorationThickness: "var(--ds-space-025, 2px)",
|
|
26
31
|
textDecorationColor: "var(--ds-text-accent-purple, #803FA5)"
|
|
27
32
|
});
|
|
33
|
+
var editingStyleExtended = exports.editingStyleExtended = (0, _lazyNodeView.convertToInlineCss)({
|
|
34
|
+
background: "var(--ds-background-accent-purple-subtlest, #F8EEFE)",
|
|
35
|
+
borderBottom: "2px solid ".concat("var(--ds-border-accent-purple, #AF59E1)"),
|
|
36
|
+
padding: "1px 0 2px"
|
|
37
|
+
});
|
|
38
|
+
var editingContentStyleInBlockExtended = exports.editingContentStyleInBlockExtended = (0, _lazyNodeView.convertToInlineCss)({
|
|
39
|
+
borderBottom: "2px solid ".concat("var(--ds-border-accent-purple, #AF59E1)"),
|
|
40
|
+
padding: "1px 0 2px"
|
|
41
|
+
});
|
|
42
|
+
var editingStyleActiveExtended = exports.editingStyleActiveExtended = (0, _lazyNodeView.convertToInlineCss)({
|
|
43
|
+
background: "var(--ds-background-accent-purple-subtler-pressed, #D8A0F7)",
|
|
44
|
+
borderBottom: "2px solid ".concat("var(--ds-border-accent-purple, #AF59E1)"),
|
|
45
|
+
padding: "1px 0 2px"
|
|
46
|
+
});
|
|
28
47
|
var deletedContentStyle = exports.deletedContentStyle = (0, _lazyNodeView.convertToInlineCss)({
|
|
29
48
|
color: "var(--ds-text-accent-gray, #505258)",
|
|
30
49
|
textDecoration: 'line-through',
|
|
@@ -41,7 +41,7 @@ var createInlineChangedDecoration = exports.createInlineChangedDecoration = func
|
|
|
41
41
|
if (colorScheme === 'traditional') {
|
|
42
42
|
style = isActive ? _traditional.traditionalInsertStyleActive : _traditional.traditionalInsertStyle;
|
|
43
43
|
} else {
|
|
44
|
-
style = isActive ? _standard.
|
|
44
|
+
style = isActive ? _standard.editingStyleActiveExtended : _standard.editingStyleExtended;
|
|
45
45
|
}
|
|
46
46
|
} else {
|
|
47
47
|
if (colorScheme === 'traditional') {
|
|
@@ -33,9 +33,9 @@ var getInsertedContentStyle = function getInsertedContentStyle(colorScheme) {
|
|
|
33
33
|
return _traditional.traditionalInsertStyle;
|
|
34
34
|
}
|
|
35
35
|
if (isActive) {
|
|
36
|
-
return _standard.editingStyleActive;
|
|
36
|
+
return (0, _expValEquals.expValEquals)('platform_editor_diff_plugin_extended', 'isEnabled', true) ? _standard.editingStyleActiveExtended : _standard.editingStyleActive;
|
|
37
37
|
}
|
|
38
|
-
return _standard.editingStyle;
|
|
38
|
+
return (0, _expValEquals.expValEquals)('platform_editor_diff_plugin_extended', 'isEnabled', true) ? _standard.editingStyleExtended : _standard.editingStyle;
|
|
39
39
|
};
|
|
40
40
|
var getDeletedContentStyle = function getDeletedContentStyle(colorScheme) {
|
|
41
41
|
var isActive = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
@@ -65,7 +65,7 @@ var getChangedContentStyle = function getChangedContentStyle(colorScheme) {
|
|
|
65
65
|
if (colorScheme === 'traditional') {
|
|
66
66
|
return isActive ? _traditional.traditionalInsertStyleActive : _traditional.traditionalInsertStyle;
|
|
67
67
|
}
|
|
68
|
-
return isActive ? _standard.
|
|
68
|
+
return isActive ? _standard.editingStyleActiveExtended : _standard.editingStyleExtended;
|
|
69
69
|
}
|
|
70
70
|
if (colorScheme === 'traditional') {
|
|
71
71
|
return (0, _traditional.getDeletedTraditionalInlineStyle)(isActive);
|
|
@@ -81,7 +81,7 @@ var getChangedNodeStyle = function getChangedNodeStyle(nodeName, colorScheme) {
|
|
|
81
81
|
var isTraditional = colorScheme === 'traditional';
|
|
82
82
|
if ((0, _expValEquals.expValEquals)('platform_editor_diff_plugin_extended', 'isEnabled', true) && isInserted) {
|
|
83
83
|
if (isMultiContainerBlockNode(nodeName)) {
|
|
84
|
-
return _standard.
|
|
84
|
+
return _standard.editingContentStyleInBlockExtended;
|
|
85
85
|
}
|
|
86
86
|
if (isTextLikeBlockNode(nodeName)) {
|
|
87
87
|
return undefined;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
2
|
+
// delete on platform_editor_diff_plugin_extended cleanup
|
|
2
3
|
export const editingStyle = convertToInlineCss({
|
|
3
4
|
background: "var(--ds-background-accent-purple-subtlest, #F8EEFE)",
|
|
4
5
|
textDecoration: 'underline',
|
|
@@ -6,12 +7,16 @@ export const editingStyle = convertToInlineCss({
|
|
|
6
7
|
textDecorationThickness: "var(--ds-space-025, 2px)",
|
|
7
8
|
textDecorationColor: "var(--ds-border-accent-purple, #AF59E1)"
|
|
8
9
|
});
|
|
10
|
+
|
|
11
|
+
// delete on platform_editor_diff_plugin_extended cleanup
|
|
9
12
|
export const editingContentStyleInBlock = convertToInlineCss({
|
|
10
13
|
textDecoration: 'underline',
|
|
11
14
|
textDecorationStyle: 'dotted',
|
|
12
15
|
textDecorationThickness: "var(--ds-space-025, 2px)",
|
|
13
16
|
textDecorationColor: "var(--ds-border-accent-purple, #AF59E1)"
|
|
14
17
|
});
|
|
18
|
+
|
|
19
|
+
// delete on platform_editor_diff_plugin_extended cleanup
|
|
15
20
|
export const editingStyleActive = convertToInlineCss({
|
|
16
21
|
background: "var(--ds-background-accent-purple-subtler-pressed, #D8A0F7)",
|
|
17
22
|
textDecoration: 'underline',
|
|
@@ -19,6 +24,20 @@ export const editingStyleActive = convertToInlineCss({
|
|
|
19
24
|
textDecorationThickness: "var(--ds-space-025, 2px)",
|
|
20
25
|
textDecorationColor: "var(--ds-text-accent-purple, #803FA5)"
|
|
21
26
|
});
|
|
27
|
+
export const editingStyleExtended = convertToInlineCss({
|
|
28
|
+
background: "var(--ds-background-accent-purple-subtlest, #F8EEFE)",
|
|
29
|
+
borderBottom: `2px solid ${"var(--ds-border-accent-purple, #AF59E1)"}`,
|
|
30
|
+
padding: `1px 0 2px`
|
|
31
|
+
});
|
|
32
|
+
export const editingContentStyleInBlockExtended = convertToInlineCss({
|
|
33
|
+
borderBottom: `2px solid ${"var(--ds-border-accent-purple, #AF59E1)"}`,
|
|
34
|
+
padding: `1px 0 2px`
|
|
35
|
+
});
|
|
36
|
+
export const editingStyleActiveExtended = convertToInlineCss({
|
|
37
|
+
background: "var(--ds-background-accent-purple-subtler-pressed, #D8A0F7)",
|
|
38
|
+
borderBottom: `2px solid ${"var(--ds-border-accent-purple, #AF59E1)"}`,
|
|
39
|
+
padding: `1px 0 2px`
|
|
40
|
+
});
|
|
22
41
|
export const deletedContentStyle = convertToInlineCss({
|
|
23
42
|
color: "var(--ds-text-accent-gray, #505258)",
|
|
24
43
|
textDecoration: 'line-through',
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
2
2
|
import { Decoration } from '@atlaskit/editor-prosemirror/view';
|
|
3
3
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
4
|
-
import { editingStyle, editingStyleActive, deletedContentStyle, deletedContentStyleActive, deletedInlineContentBackground } from './colorSchemes/standard';
|
|
4
|
+
import { editingStyle, editingStyleExtended, editingStyleActive, editingStyleActiveExtended, deletedContentStyle, deletedContentStyleActive, deletedInlineContentBackground } from './colorSchemes/standard';
|
|
5
5
|
import { traditionalInsertStyle, traditionalInsertStyleActive, getDeletedTraditionalInlineStyle } from './colorSchemes/traditional';
|
|
6
6
|
const displayNoneStyle = convertToInlineCss({
|
|
7
7
|
display: 'none'
|
|
@@ -33,7 +33,7 @@ export const createInlineChangedDecoration = ({
|
|
|
33
33
|
if (colorScheme === 'traditional') {
|
|
34
34
|
style = isActive ? traditionalInsertStyleActive : traditionalInsertStyle;
|
|
35
35
|
} else {
|
|
36
|
-
style = isActive ?
|
|
36
|
+
style = isActive ? editingStyleActiveExtended : editingStyleExtended;
|
|
37
37
|
}
|
|
38
38
|
} else {
|
|
39
39
|
if (colorScheme === 'traditional') {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
2
2
|
import { Decoration } from '@atlaskit/editor-prosemirror/view';
|
|
3
3
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
4
|
-
import { editingStyle, editingStyleActive, deletedContentStyle, deletedContentStyleActive, deletedContentStyleNew, deletedContentStyleUnbounded, deletedInlineContentBackground } from './colorSchemes/standard';
|
|
4
|
+
import { editingStyle, editingStyleExtended, editingStyleActive, editingStyleActiveExtended, deletedContentStyle, deletedContentStyleActive, deletedContentStyleNew, deletedContentStyleUnbounded, deletedInlineContentBackground } from './colorSchemes/standard';
|
|
5
5
|
import { traditionalInsertStyle, traditionalInsertStyleActive, getDeletedTraditionalInlineStyle, deletedTraditionalContentStyleUnbounded, deletedTraditionalContentStyleUnboundedActive } from './colorSchemes/traditional';
|
|
6
6
|
import { createChangedRowDecorationWidgets } from './createChangedRowDecorationWidgets';
|
|
7
7
|
import { findSafeInsertPos } from './utils/findSafeInsertPos';
|
|
@@ -20,9 +20,9 @@ const getInsertedContentStyle = (colorScheme, isActive = false) => {
|
|
|
20
20
|
return traditionalInsertStyle;
|
|
21
21
|
}
|
|
22
22
|
if (isActive) {
|
|
23
|
-
return editingStyleActive;
|
|
23
|
+
return expValEquals('platform_editor_diff_plugin_extended', 'isEnabled', true) ? editingStyleActiveExtended : editingStyleActive;
|
|
24
24
|
}
|
|
25
|
-
return editingStyle;
|
|
25
|
+
return expValEquals('platform_editor_diff_plugin_extended', 'isEnabled', true) ? editingStyleExtended : editingStyle;
|
|
26
26
|
};
|
|
27
27
|
const getDeletedContentStyle = (colorScheme, isActive = false) => {
|
|
28
28
|
if (colorScheme === 'traditional') {
|
|
@@ -2,7 +2,7 @@ import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
|
2
2
|
import { trackChangesMessages } from '@atlaskit/editor-common/messages';
|
|
3
3
|
import { getBaseNodeTypeName } from '@atlaskit/editor-common/utils/node-type-utils';
|
|
4
4
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
5
|
-
import { deletedBlockOutline, deletedBlockOutlineActive, deletedBlockOutlineRounded, deletedBlockOutlineRoundedActive, deletedContentStyle, deletedContentStyleActive, deletedContentStyleNew, deletedStyleQuoteNodeWithLozenge, deletedStyleQuoteNodeWithLozengeActive,
|
|
5
|
+
import { deletedBlockOutline, deletedBlockOutlineActive, deletedBlockOutlineRounded, deletedBlockOutlineRoundedActive, deletedContentStyle, deletedContentStyleActive, deletedContentStyleNew, deletedStyleQuoteNodeWithLozenge, deletedStyleQuoteNodeWithLozengeActive, editingContentStyleInBlockExtended, editingStyleExtended, editingStyleActiveExtended, editingStyleNode, addedCellOverlayStyle, deletedCellOverlayStyle } from '../colorSchemes/standard';
|
|
6
6
|
import { deletedTraditionalBlockOutlineActive, deletedTraditionalBlockOutlineNew, deletedTraditionalBlockOutlineRoundedActive, deletedTraditionalBlockOutlineRoundedNew, getDeletedTraditionalInlineStyle, deletedTraditionalStyleQuoteNode, deletedTraditionalStyleQuoteNodeActive, traditionalInsertStyle, traditionalInsertStyleActive, traditionalStyleNodeActive, traditionalStyleNodeNew, traditionalAddedCellOverlayStyleNew, deletedTraditionalCellOverlayStyle } from '../colorSchemes/traditional';
|
|
7
7
|
const lozengeStyle = convertToInlineCss({
|
|
8
8
|
display: 'inline-flex',
|
|
@@ -57,7 +57,7 @@ const getChangedContentStyle = (colorScheme, isActive = false, isInserted = fals
|
|
|
57
57
|
if (colorScheme === 'traditional') {
|
|
58
58
|
return isActive ? traditionalInsertStyleActive : traditionalInsertStyle;
|
|
59
59
|
}
|
|
60
|
-
return isActive ?
|
|
60
|
+
return isActive ? editingStyleActiveExtended : editingStyleExtended;
|
|
61
61
|
}
|
|
62
62
|
if (colorScheme === 'traditional') {
|
|
63
63
|
return getDeletedTraditionalInlineStyle(isActive);
|
|
@@ -71,7 +71,7 @@ const getChangedNodeStyle = (nodeName, colorScheme, isInserted = false, isActive
|
|
|
71
71
|
const isTraditional = colorScheme === 'traditional';
|
|
72
72
|
if (expValEquals('platform_editor_diff_plugin_extended', 'isEnabled', true) && isInserted) {
|
|
73
73
|
if (isMultiContainerBlockNode(nodeName)) {
|
|
74
|
-
return
|
|
74
|
+
return editingContentStyleInBlockExtended;
|
|
75
75
|
}
|
|
76
76
|
if (isTextLikeBlockNode(nodeName)) {
|
|
77
77
|
return undefined;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
2
|
+
// delete on platform_editor_diff_plugin_extended cleanup
|
|
2
3
|
export var editingStyle = convertToInlineCss({
|
|
3
4
|
background: "var(--ds-background-accent-purple-subtlest, #F8EEFE)",
|
|
4
5
|
textDecoration: 'underline',
|
|
@@ -6,12 +7,16 @@ export var editingStyle = convertToInlineCss({
|
|
|
6
7
|
textDecorationThickness: "var(--ds-space-025, 2px)",
|
|
7
8
|
textDecorationColor: "var(--ds-border-accent-purple, #AF59E1)"
|
|
8
9
|
});
|
|
10
|
+
|
|
11
|
+
// delete on platform_editor_diff_plugin_extended cleanup
|
|
9
12
|
export var editingContentStyleInBlock = convertToInlineCss({
|
|
10
13
|
textDecoration: 'underline',
|
|
11
14
|
textDecorationStyle: 'dotted',
|
|
12
15
|
textDecorationThickness: "var(--ds-space-025, 2px)",
|
|
13
16
|
textDecorationColor: "var(--ds-border-accent-purple, #AF59E1)"
|
|
14
17
|
});
|
|
18
|
+
|
|
19
|
+
// delete on platform_editor_diff_plugin_extended cleanup
|
|
15
20
|
export var editingStyleActive = convertToInlineCss({
|
|
16
21
|
background: "var(--ds-background-accent-purple-subtler-pressed, #D8A0F7)",
|
|
17
22
|
textDecoration: 'underline',
|
|
@@ -19,6 +24,20 @@ export var editingStyleActive = convertToInlineCss({
|
|
|
19
24
|
textDecorationThickness: "var(--ds-space-025, 2px)",
|
|
20
25
|
textDecorationColor: "var(--ds-text-accent-purple, #803FA5)"
|
|
21
26
|
});
|
|
27
|
+
export var editingStyleExtended = convertToInlineCss({
|
|
28
|
+
background: "var(--ds-background-accent-purple-subtlest, #F8EEFE)",
|
|
29
|
+
borderBottom: "2px solid ".concat("var(--ds-border-accent-purple, #AF59E1)"),
|
|
30
|
+
padding: "1px 0 2px"
|
|
31
|
+
});
|
|
32
|
+
export var editingContentStyleInBlockExtended = convertToInlineCss({
|
|
33
|
+
borderBottom: "2px solid ".concat("var(--ds-border-accent-purple, #AF59E1)"),
|
|
34
|
+
padding: "1px 0 2px"
|
|
35
|
+
});
|
|
36
|
+
export var editingStyleActiveExtended = convertToInlineCss({
|
|
37
|
+
background: "var(--ds-background-accent-purple-subtler-pressed, #D8A0F7)",
|
|
38
|
+
borderBottom: "2px solid ".concat("var(--ds-border-accent-purple, #AF59E1)"),
|
|
39
|
+
padding: "1px 0 2px"
|
|
40
|
+
});
|
|
22
41
|
export var deletedContentStyle = convertToInlineCss({
|
|
23
42
|
color: "var(--ds-text-accent-gray, #505258)",
|
|
24
43
|
textDecoration: 'line-through',
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
2
2
|
import { Decoration } from '@atlaskit/editor-prosemirror/view';
|
|
3
3
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
4
|
-
import { editingStyle, editingStyleActive, deletedContentStyle, deletedContentStyleActive, deletedInlineContentBackground } from './colorSchemes/standard';
|
|
4
|
+
import { editingStyle, editingStyleExtended, editingStyleActive, editingStyleActiveExtended, deletedContentStyle, deletedContentStyleActive, deletedInlineContentBackground } from './colorSchemes/standard';
|
|
5
5
|
import { traditionalInsertStyle, traditionalInsertStyleActive, getDeletedTraditionalInlineStyle } from './colorSchemes/traditional';
|
|
6
6
|
var displayNoneStyle = convertToInlineCss({
|
|
7
7
|
display: 'none'
|
|
@@ -35,7 +35,7 @@ export var createInlineChangedDecoration = function createInlineChangedDecoratio
|
|
|
35
35
|
if (colorScheme === 'traditional') {
|
|
36
36
|
style = isActive ? traditionalInsertStyleActive : traditionalInsertStyle;
|
|
37
37
|
} else {
|
|
38
|
-
style = isActive ?
|
|
38
|
+
style = isActive ? editingStyleActiveExtended : editingStyleExtended;
|
|
39
39
|
}
|
|
40
40
|
} else {
|
|
41
41
|
if (colorScheme === 'traditional') {
|
|
@@ -5,7 +5,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
5
5
|
import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
6
6
|
import { Decoration } from '@atlaskit/editor-prosemirror/view';
|
|
7
7
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
8
|
-
import { editingStyle, editingStyleActive, deletedContentStyle, deletedContentStyleActive, deletedContentStyleNew, deletedContentStyleUnbounded, deletedInlineContentBackground } from './colorSchemes/standard';
|
|
8
|
+
import { editingStyle, editingStyleExtended, editingStyleActive, editingStyleActiveExtended, deletedContentStyle, deletedContentStyleActive, deletedContentStyleNew, deletedContentStyleUnbounded, deletedInlineContentBackground } from './colorSchemes/standard';
|
|
9
9
|
import { traditionalInsertStyle, traditionalInsertStyleActive, getDeletedTraditionalInlineStyle, deletedTraditionalContentStyleUnbounded, deletedTraditionalContentStyleUnboundedActive } from './colorSchemes/traditional';
|
|
10
10
|
import { createChangedRowDecorationWidgets } from './createChangedRowDecorationWidgets';
|
|
11
11
|
import { findSafeInsertPos } from './utils/findSafeInsertPos';
|
|
@@ -26,9 +26,9 @@ var getInsertedContentStyle = function getInsertedContentStyle(colorScheme) {
|
|
|
26
26
|
return traditionalInsertStyle;
|
|
27
27
|
}
|
|
28
28
|
if (isActive) {
|
|
29
|
-
return editingStyleActive;
|
|
29
|
+
return expValEquals('platform_editor_diff_plugin_extended', 'isEnabled', true) ? editingStyleActiveExtended : editingStyleActive;
|
|
30
30
|
}
|
|
31
|
-
return editingStyle;
|
|
31
|
+
return expValEquals('platform_editor_diff_plugin_extended', 'isEnabled', true) ? editingStyleExtended : editingStyle;
|
|
32
32
|
};
|
|
33
33
|
var getDeletedContentStyle = function getDeletedContentStyle(colorScheme) {
|
|
34
34
|
var isActive = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
@@ -2,7 +2,7 @@ import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
|
2
2
|
import { trackChangesMessages } from '@atlaskit/editor-common/messages';
|
|
3
3
|
import { getBaseNodeTypeName } from '@atlaskit/editor-common/utils/node-type-utils';
|
|
4
4
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
5
|
-
import { deletedBlockOutline, deletedBlockOutlineActive, deletedBlockOutlineRounded, deletedBlockOutlineRoundedActive, deletedContentStyle, deletedContentStyleActive, deletedContentStyleNew, deletedStyleQuoteNodeWithLozenge, deletedStyleQuoteNodeWithLozengeActive,
|
|
5
|
+
import { deletedBlockOutline, deletedBlockOutlineActive, deletedBlockOutlineRounded, deletedBlockOutlineRoundedActive, deletedContentStyle, deletedContentStyleActive, deletedContentStyleNew, deletedStyleQuoteNodeWithLozenge, deletedStyleQuoteNodeWithLozengeActive, editingContentStyleInBlockExtended, editingStyleExtended, editingStyleActiveExtended, editingStyleNode, addedCellOverlayStyle, deletedCellOverlayStyle } from '../colorSchemes/standard';
|
|
6
6
|
import { deletedTraditionalBlockOutlineActive, deletedTraditionalBlockOutlineNew, deletedTraditionalBlockOutlineRoundedActive, deletedTraditionalBlockOutlineRoundedNew, getDeletedTraditionalInlineStyle, deletedTraditionalStyleQuoteNode, deletedTraditionalStyleQuoteNodeActive, traditionalInsertStyle, traditionalInsertStyleActive, traditionalStyleNodeActive, traditionalStyleNodeNew, traditionalAddedCellOverlayStyleNew, deletedTraditionalCellOverlayStyle } from '../colorSchemes/traditional';
|
|
7
7
|
var lozengeStyle = convertToInlineCss({
|
|
8
8
|
display: 'inline-flex',
|
|
@@ -59,7 +59,7 @@ var getChangedContentStyle = function getChangedContentStyle(colorScheme) {
|
|
|
59
59
|
if (colorScheme === 'traditional') {
|
|
60
60
|
return isActive ? traditionalInsertStyleActive : traditionalInsertStyle;
|
|
61
61
|
}
|
|
62
|
-
return isActive ?
|
|
62
|
+
return isActive ? editingStyleActiveExtended : editingStyleExtended;
|
|
63
63
|
}
|
|
64
64
|
if (colorScheme === 'traditional') {
|
|
65
65
|
return getDeletedTraditionalInlineStyle(isActive);
|
|
@@ -75,7 +75,7 @@ var getChangedNodeStyle = function getChangedNodeStyle(nodeName, colorScheme) {
|
|
|
75
75
|
var isTraditional = colorScheme === 'traditional';
|
|
76
76
|
if (expValEquals('platform_editor_diff_plugin_extended', 'isEnabled', true) && isInserted) {
|
|
77
77
|
if (isMultiContainerBlockNode(nodeName)) {
|
|
78
|
-
return
|
|
78
|
+
return editingContentStyleInBlockExtended;
|
|
79
79
|
}
|
|
80
80
|
if (isTextLikeBlockNode(nodeName)) {
|
|
81
81
|
return undefined;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
export declare const editingStyle: string;
|
|
2
2
|
export declare const editingContentStyleInBlock: string;
|
|
3
3
|
export declare const editingStyleActive: string;
|
|
4
|
+
export declare const editingStyleExtended: string;
|
|
5
|
+
export declare const editingContentStyleInBlockExtended: string;
|
|
6
|
+
export declare const editingStyleActiveExtended: string;
|
|
4
7
|
export declare const deletedContentStyle: string;
|
|
5
8
|
export declare const deletedContentStyleActive: string;
|
|
6
9
|
export declare const deletedContentStyleNew: string;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
export declare const editingStyle: string;
|
|
2
2
|
export declare const editingContentStyleInBlock: string;
|
|
3
3
|
export declare const editingStyleActive: string;
|
|
4
|
+
export declare const editingStyleExtended: string;
|
|
5
|
+
export declare const editingContentStyleInBlockExtended: string;
|
|
6
|
+
export declare const editingStyleActiveExtended: string;
|
|
4
7
|
export declare const deletedContentStyle: string;
|
|
5
8
|
export declare const deletedContentStyleActive: string;
|
|
6
9
|
export declare const deletedContentStyleNew: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-show-diff",
|
|
3
|
-
"version": "9.0.
|
|
3
|
+
"version": "9.0.7",
|
|
4
4
|
"description": "ShowDiff plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"@atlaskit/editor-prosemirror": "^7.3.0",
|
|
36
36
|
"@atlaskit/editor-tables": "^2.10.0",
|
|
37
37
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
38
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
38
|
+
"@atlaskit/tmp-editor-statsig": "^92.0.0",
|
|
39
39
|
"@atlaskit/tokens": "^13.3.0",
|
|
40
40
|
"@babel/runtime": "^7.0.0",
|
|
41
41
|
"lodash": "^4.17.21",
|