@atlaskit/editor-plugin-code-block 3.3.18 → 3.4.0
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
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-code-block
|
|
2
2
|
|
|
3
|
+
## 3.4.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#146025](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/146025)
|
|
8
|
+
[`03eae90c614d1`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/03eae90c614d1) -
|
|
9
|
+
Remove platform.editor.live-view.disable-editing-in-view-mode_fi1rx feature flag
|
|
10
|
+
|
|
11
|
+
## 3.3.19
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- Updated dependencies
|
|
16
|
+
|
|
3
17
|
## 3.3.18
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
|
@@ -35,7 +35,7 @@ var toDOM = function toDOM(node, contentEditable, formattedAriaLabel) {
|
|
|
35
35
|
}, ['code', {
|
|
36
36
|
'data-language': node.attrs.language || '',
|
|
37
37
|
spellcheck: 'false',
|
|
38
|
-
contenteditable:
|
|
38
|
+
contenteditable: contentEditable ? 'true' : 'false',
|
|
39
39
|
'data-testid': 'code-block--code',
|
|
40
40
|
'aria-label': formattedAriaLabel
|
|
41
41
|
}, 0]]], ['div', {
|
|
@@ -107,7 +107,7 @@ var CodeBlockView = exports.CodeBlockView = /*#__PURE__*/function () {
|
|
|
107
107
|
value: function handleEditorDisabledChanged() {
|
|
108
108
|
var _this$api,
|
|
109
109
|
_this2 = this;
|
|
110
|
-
if ((_this$api = this.api) !== null && _this$api !== void 0 && _this$api.editorDisabled
|
|
110
|
+
if ((_this$api = this.api) !== null && _this$api !== void 0 && _this$api.editorDisabled) {
|
|
111
111
|
this.cleanupEditorDisabledListener = this.api.editorDisabled.sharedState.onChange(function (sharedState) {
|
|
112
112
|
if (_this2.contentDOM) {
|
|
113
113
|
_this2.contentDOM.setAttribute('contenteditable', sharedState.nextSharedState.editorDisabled ? 'false' : 'true');
|
|
@@ -24,7 +24,7 @@ const toDOM = (node, contentEditable, formattedAriaLabel) => ['div', {
|
|
|
24
24
|
}, ['code', {
|
|
25
25
|
'data-language': node.attrs.language || '',
|
|
26
26
|
spellcheck: 'false',
|
|
27
|
-
contenteditable:
|
|
27
|
+
contenteditable: contentEditable ? 'true' : 'false',
|
|
28
28
|
'data-testid': 'code-block--code',
|
|
29
29
|
'aria-label': formattedAriaLabel
|
|
30
30
|
}, 0]]], ['div', {
|
|
@@ -91,7 +91,7 @@ export class CodeBlockView {
|
|
|
91
91
|
}
|
|
92
92
|
handleEditorDisabledChanged() {
|
|
93
93
|
var _this$api;
|
|
94
|
-
if ((_this$api = this.api) !== null && _this$api !== void 0 && _this$api.editorDisabled
|
|
94
|
+
if ((_this$api = this.api) !== null && _this$api !== void 0 && _this$api.editorDisabled) {
|
|
95
95
|
this.cleanupEditorDisabledListener = this.api.editorDisabled.sharedState.onChange(sharedState => {
|
|
96
96
|
if (this.contentDOM) {
|
|
97
97
|
this.contentDOM.setAttribute('contenteditable', sharedState.nextSharedState.editorDisabled ? 'false' : 'true');
|
|
@@ -27,7 +27,7 @@ var toDOM = function toDOM(node, contentEditable, formattedAriaLabel) {
|
|
|
27
27
|
}, ['code', {
|
|
28
28
|
'data-language': node.attrs.language || '',
|
|
29
29
|
spellcheck: 'false',
|
|
30
|
-
contenteditable:
|
|
30
|
+
contenteditable: contentEditable ? 'true' : 'false',
|
|
31
31
|
'data-testid': 'code-block--code',
|
|
32
32
|
'aria-label': formattedAriaLabel
|
|
33
33
|
}, 0]]], ['div', {
|
|
@@ -99,7 +99,7 @@ export var CodeBlockView = /*#__PURE__*/function () {
|
|
|
99
99
|
value: function handleEditorDisabledChanged() {
|
|
100
100
|
var _this$api,
|
|
101
101
|
_this2 = this;
|
|
102
|
-
if ((_this$api = this.api) !== null && _this$api !== void 0 && _this$api.editorDisabled
|
|
102
|
+
if ((_this$api = this.api) !== null && _this$api !== void 0 && _this$api.editorDisabled) {
|
|
103
103
|
this.cleanupEditorDisabledListener = this.api.editorDisabled.sharedState.onChange(function (sharedState) {
|
|
104
104
|
if (_this2.contentDOM) {
|
|
105
105
|
_this2.contentDOM.setAttribute('contenteditable', sharedState.nextSharedState.editorDisabled ? 'false' : 'true');
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-code-block",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.4.0",
|
|
4
4
|
"description": "Code block plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"@atlaskit/adf-schema": "^40.9.0",
|
|
35
35
|
"@atlaskit/code": "^15.6.0",
|
|
36
|
-
"@atlaskit/editor-common": "^
|
|
36
|
+
"@atlaskit/editor-common": "^91.1.0",
|
|
37
37
|
"@atlaskit/editor-plugin-analytics": "^1.8.0",
|
|
38
38
|
"@atlaskit/editor-plugin-composition": "^1.2.0",
|
|
39
39
|
"@atlaskit/editor-plugin-decorations": "^1.3.0",
|
|
@@ -100,9 +100,6 @@
|
|
|
100
100
|
"editor_code_block_wrapping_language_change_bug": {
|
|
101
101
|
"type": "boolean"
|
|
102
102
|
},
|
|
103
|
-
"platform.editor.live-view.disable-editing-in-view-mode_fi1rx": {
|
|
104
|
-
"type": "boolean"
|
|
105
|
-
},
|
|
106
103
|
"editor_nest_media_and_codeblock_in_quotes_jira": {
|
|
107
104
|
"type": "boolean"
|
|
108
105
|
}
|