@atlaskit/editor-plugin-editor-disabled 6.1.0 → 6.1.1
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,14 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-editor-disabled
|
|
2
2
|
|
|
3
|
+
## 6.1.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`4d676bbdb3ce6`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4d676bbdb3ce6) -
|
|
8
|
+
ts-ignore added temporarily to unblock local consumption for help-center, will be removed once
|
|
9
|
+
project refs are setup
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
3
12
|
## 6.1.0
|
|
4
13
|
|
|
5
14
|
### Minor Changes
|
|
@@ -49,7 +58,6 @@
|
|
|
49
58
|
shared context or singletons.
|
|
50
59
|
|
|
51
60
|
**HOW TO ADJUST:**
|
|
52
|
-
|
|
53
61
|
- Consumers must now explicitly install `@atlaskit/editor-common` in their own project if they use
|
|
54
62
|
any of these editor plugins.
|
|
55
63
|
- Ensure the version you install matches the version required by the plugins.
|
|
@@ -45,6 +45,8 @@ function createPlugin(dispatch, options) {
|
|
|
45
45
|
disabledByPlugin: false
|
|
46
46
|
};
|
|
47
47
|
},
|
|
48
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
49
|
+
|
|
48
50
|
apply: function apply(tr, pluginState) {
|
|
49
51
|
var meta = tr.getMeta(pluginKey);
|
|
50
52
|
if (meta) {
|
|
@@ -61,7 +63,7 @@ function createPlugin(dispatch, options) {
|
|
|
61
63
|
props: {
|
|
62
64
|
// If we set to undefined it respects the previous value.
|
|
63
65
|
// Prosemirror doesn't have this typed correctly for this type of behaviour
|
|
64
|
-
// @ts-
|
|
66
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
65
67
|
editable: (0, _platformFeatureFlags.fg)('platform_editor_ai_aifc_patch_beta') ? function (state) {
|
|
66
68
|
var _pluginKey$getState;
|
|
67
69
|
var _ref = (_pluginKey$getState = pluginKey.getState(state)) !== null && _pluginKey$getState !== void 0 ? _pluginKey$getState : {
|
|
@@ -71,13 +73,17 @@ function createPlugin(dispatch, options) {
|
|
|
71
73
|
return disabledByPlugin ? false : undefined;
|
|
72
74
|
} : undefined
|
|
73
75
|
},
|
|
76
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
77
|
+
|
|
74
78
|
view: function view(_view) {
|
|
75
79
|
// schedule on mount
|
|
76
80
|
scheduleEditorDisabledUpdate(_view);
|
|
77
81
|
return {
|
|
82
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
78
83
|
update: function update(view) {
|
|
79
84
|
scheduleEditorDisabledUpdate(view);
|
|
80
85
|
},
|
|
86
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
81
87
|
destroy: function destroy() {
|
|
82
88
|
scheduleEditorDisabledUpdate.cancel();
|
|
83
89
|
}
|
|
@@ -36,6 +36,8 @@ function createPlugin(dispatch, options) {
|
|
|
36
36
|
disabledByPlugin: false
|
|
37
37
|
};
|
|
38
38
|
},
|
|
39
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
40
|
+
|
|
39
41
|
apply: (tr, pluginState) => {
|
|
40
42
|
const meta = tr.getMeta(pluginKey);
|
|
41
43
|
if (meta) {
|
|
@@ -55,7 +57,7 @@ function createPlugin(dispatch, options) {
|
|
|
55
57
|
props: {
|
|
56
58
|
// If we set to undefined it respects the previous value.
|
|
57
59
|
// Prosemirror doesn't have this typed correctly for this type of behaviour
|
|
58
|
-
// @ts-
|
|
60
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
59
61
|
editable: fg('platform_editor_ai_aifc_patch_beta') ? state => {
|
|
60
62
|
var _pluginKey$getState;
|
|
61
63
|
const {
|
|
@@ -66,13 +68,19 @@ function createPlugin(dispatch, options) {
|
|
|
66
68
|
return disabledByPlugin ? false : undefined;
|
|
67
69
|
} : undefined
|
|
68
70
|
},
|
|
71
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
72
|
+
|
|
69
73
|
view: view => {
|
|
70
74
|
// schedule on mount
|
|
71
75
|
scheduleEditorDisabledUpdate(view);
|
|
72
76
|
return {
|
|
77
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
78
|
+
|
|
73
79
|
update(view) {
|
|
74
80
|
scheduleEditorDisabledUpdate(view);
|
|
75
81
|
},
|
|
82
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
83
|
+
|
|
76
84
|
destroy() {
|
|
77
85
|
scheduleEditorDisabledUpdate.cancel();
|
|
78
86
|
}
|
|
@@ -38,6 +38,8 @@ function createPlugin(dispatch, options) {
|
|
|
38
38
|
disabledByPlugin: false
|
|
39
39
|
};
|
|
40
40
|
},
|
|
41
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
42
|
+
|
|
41
43
|
apply: function apply(tr, pluginState) {
|
|
42
44
|
var meta = tr.getMeta(pluginKey);
|
|
43
45
|
if (meta) {
|
|
@@ -54,7 +56,7 @@ function createPlugin(dispatch, options) {
|
|
|
54
56
|
props: {
|
|
55
57
|
// If we set to undefined it respects the previous value.
|
|
56
58
|
// Prosemirror doesn't have this typed correctly for this type of behaviour
|
|
57
|
-
// @ts-
|
|
59
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
58
60
|
editable: fg('platform_editor_ai_aifc_patch_beta') ? function (state) {
|
|
59
61
|
var _pluginKey$getState;
|
|
60
62
|
var _ref = (_pluginKey$getState = pluginKey.getState(state)) !== null && _pluginKey$getState !== void 0 ? _pluginKey$getState : {
|
|
@@ -64,13 +66,17 @@ function createPlugin(dispatch, options) {
|
|
|
64
66
|
return disabledByPlugin ? false : undefined;
|
|
65
67
|
} : undefined
|
|
66
68
|
},
|
|
69
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
70
|
+
|
|
67
71
|
view: function view(_view) {
|
|
68
72
|
// schedule on mount
|
|
69
73
|
scheduleEditorDisabledUpdate(_view);
|
|
70
74
|
return {
|
|
75
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
71
76
|
update: function update(view) {
|
|
72
77
|
scheduleEditorDisabledUpdate(view);
|
|
73
78
|
},
|
|
79
|
+
// @ts-ignore - Workaround for help-center local consumption
|
|
74
80
|
destroy: function destroy() {
|
|
75
81
|
scheduleEditorDisabledUpdate.cancel();
|
|
76
82
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-editor-disabled",
|
|
3
|
-
"version": "6.1.
|
|
3
|
+
"version": "6.1.1",
|
|
4
4
|
"description": "Editor disabled plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"raf-schd": "^4.0.3"
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
|
-
"@atlaskit/editor-common": "^110.
|
|
33
|
+
"@atlaskit/editor-common": "^110.34.0",
|
|
34
34
|
"react": "^18.2.0",
|
|
35
35
|
"react-dom": "^18.2.0"
|
|
36
36
|
},
|