@atlaskit/editor-plugin-paste 1.0.0 → 1.0.2
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,18 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-paste
|
|
2
2
|
|
|
3
|
+
## 1.0.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#74284](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/74284) [`c88cf104546f`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/c88cf104546f) - fix copy paste issue in excel and numbers that paste table results in screenshot of table pasted
|
|
8
|
+
- Updated dependencies
|
|
9
|
+
|
|
10
|
+
## 1.0.1
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- Updated dependencies
|
|
15
|
+
|
|
3
16
|
## 1.0.0
|
|
4
17
|
|
|
5
18
|
### Major Changes
|
|
@@ -27,6 +27,7 @@ var _editorMarkdownTransformer = require("@atlaskit/editor-markdown-transformer"
|
|
|
27
27
|
var _model = require("@atlaskit/editor-prosemirror/model");
|
|
28
28
|
var _utils2 = require("@atlaskit/editor-prosemirror/utils");
|
|
29
29
|
var _utils3 = require("@atlaskit/editor-tables/utils");
|
|
30
|
+
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
30
31
|
var _actions = require("../actions");
|
|
31
32
|
var _commands = require("../commands");
|
|
32
33
|
var _handlers = require("../handlers");
|
|
@@ -175,7 +176,13 @@ function createPlugin(schema, dispatchAnalyticsEvent, dispatch, featureFlags, pl
|
|
|
175
176
|
if ((0, _util.htmlContainsSingleFile)(html)) {
|
|
176
177
|
return true;
|
|
177
178
|
}
|
|
178
|
-
|
|
179
|
+
|
|
180
|
+
/**
|
|
181
|
+
* https://product-fabric.atlassian.net/browse/ED-21993
|
|
182
|
+
* stopImmediatePropagation will run the first event attached to the same element
|
|
183
|
+
* Which chould have race condition issue
|
|
184
|
+
*/
|
|
185
|
+
(0, _platformFeatureFlags.getBooleanFF)('platform.editor.media.fix-copy-paste-excel_62g4s') ? event.stopPropagation() : event.stopImmediatePropagation();
|
|
179
186
|
}
|
|
180
187
|
var state = view.state;
|
|
181
188
|
var analyticsPlugin = pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$a2 = pluginInjectionApi.analytics) === null || _pluginInjectionApi$a2 === void 0 || (_pluginInjectionApi$a2 = _pluginInjectionApi$a2.sharedState) === null || _pluginInjectionApi$a2 === void 0 ? void 0 : _pluginInjectionApi$a2.currentState();
|
|
@@ -11,6 +11,7 @@ import { MarkdownTransformer } from '@atlaskit/editor-markdown-transformer';
|
|
|
11
11
|
import { Fragment, Slice } from '@atlaskit/editor-prosemirror/model';
|
|
12
12
|
import { contains, hasParentNodeOfType } from '@atlaskit/editor-prosemirror/utils';
|
|
13
13
|
import { handlePaste as handlePasteTable } from '@atlaskit/editor-tables/utils';
|
|
14
|
+
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
14
15
|
import { PastePluginActionTypes } from '../actions';
|
|
15
16
|
import { splitParagraphs, upgradeTextToLists } from '../commands';
|
|
16
17
|
import { handleMacroAutoConvert, handleMention, handleParagraphBlockMarks } from '../handlers';
|
|
@@ -139,7 +140,13 @@ export function createPlugin(schema, dispatchAnalyticsEvent, dispatch, featureFl
|
|
|
139
140
|
if (htmlContainsSingleFile(html)) {
|
|
140
141
|
return true;
|
|
141
142
|
}
|
|
142
|
-
|
|
143
|
+
|
|
144
|
+
/**
|
|
145
|
+
* https://product-fabric.atlassian.net/browse/ED-21993
|
|
146
|
+
* stopImmediatePropagation will run the first event attached to the same element
|
|
147
|
+
* Which chould have race condition issue
|
|
148
|
+
*/
|
|
149
|
+
getBooleanFF('platform.editor.media.fix-copy-paste-excel_62g4s') ? event.stopPropagation() : event.stopImmediatePropagation();
|
|
143
150
|
}
|
|
144
151
|
const {
|
|
145
152
|
state
|
|
@@ -13,6 +13,7 @@ import { MarkdownTransformer } from '@atlaskit/editor-markdown-transformer';
|
|
|
13
13
|
import { Fragment, Slice } from '@atlaskit/editor-prosemirror/model';
|
|
14
14
|
import { contains, hasParentNodeOfType } from '@atlaskit/editor-prosemirror/utils';
|
|
15
15
|
import { handlePaste as handlePasteTable } from '@atlaskit/editor-tables/utils';
|
|
16
|
+
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
16
17
|
import { PastePluginActionTypes } from '../actions';
|
|
17
18
|
import { splitParagraphs, upgradeTextToLists } from '../commands';
|
|
18
19
|
import { handleMacroAutoConvert, handleMention, handleParagraphBlockMarks } from '../handlers';
|
|
@@ -162,7 +163,13 @@ export function createPlugin(schema, dispatchAnalyticsEvent, dispatch, featureFl
|
|
|
162
163
|
if (htmlContainsSingleFile(html)) {
|
|
163
164
|
return true;
|
|
164
165
|
}
|
|
165
|
-
|
|
166
|
+
|
|
167
|
+
/**
|
|
168
|
+
* https://product-fabric.atlassian.net/browse/ED-21993
|
|
169
|
+
* stopImmediatePropagation will run the first event attached to the same element
|
|
170
|
+
* Which chould have race condition issue
|
|
171
|
+
*/
|
|
172
|
+
getBooleanFF('platform.editor.media.fix-copy-paste-excel_62g4s') ? event.stopPropagation() : event.stopImmediatePropagation();
|
|
166
173
|
}
|
|
167
174
|
var state = view.state;
|
|
168
175
|
var analyticsPlugin = pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$a2 = pluginInjectionApi.analytics) === null || _pluginInjectionApi$a2 === void 0 || (_pluginInjectionApi$a2 = _pluginInjectionApi$a2.sharedState) === null || _pluginInjectionApi$a2 === void 0 ? void 0 : _pluginInjectionApi$a2.currentState();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-paste",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "Paste plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
".": "./src/index.ts"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@atlaskit/editor-common": "^
|
|
36
|
+
"@atlaskit/editor-common": "^78.3.0",
|
|
37
37
|
"@atlaskit/editor-markdown-transformer": "^5.3.0",
|
|
38
38
|
"@atlaskit/editor-plugin-analytics": "^1.0.0",
|
|
39
39
|
"@atlaskit/editor-plugin-annotation": "^1.0.0",
|
|
@@ -41,10 +41,10 @@
|
|
|
41
41
|
"@atlaskit/editor-plugin-card": "^1.0.0",
|
|
42
42
|
"@atlaskit/editor-plugin-feature-flags": "^1.0.0",
|
|
43
43
|
"@atlaskit/editor-plugin-list": "^3.1.0",
|
|
44
|
-
"@atlaskit/editor-plugin-media": "^1.
|
|
44
|
+
"@atlaskit/editor-plugin-media": "^1.2.0",
|
|
45
45
|
"@atlaskit/editor-prosemirror": "3.0.0",
|
|
46
46
|
"@atlaskit/editor-tables": "^2.5.0",
|
|
47
|
-
"@atlaskit/media-client": "^26.
|
|
47
|
+
"@atlaskit/media-client": "^26.2.0",
|
|
48
48
|
"@atlaskit/media-common": "^11.0.0",
|
|
49
49
|
"@atlaskit/platform-feature-flags": "^0.2.0",
|
|
50
50
|
"@babel/runtime": "^7.0.0",
|
|
@@ -122,6 +122,9 @@
|
|
|
122
122
|
},
|
|
123
123
|
"platform.editor.allow-action-in-list": {
|
|
124
124
|
"type": "boolean"
|
|
125
|
+
},
|
|
126
|
+
"platform.editor.media.fix-copy-paste-excel_62g4s": {
|
|
127
|
+
"type": "boolean"
|
|
125
128
|
}
|
|
126
129
|
}
|
|
127
130
|
}
|