@atlaskit/editor-core 187.34.1 → 187.34.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,11 @@
1
1
  # @atlaskit/editor-core
2
2
 
3
+ ## 187.34.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [`5e0bef65120`](https://bitbucket.org/atlassian/atlassian-frontend/commits/5e0bef65120) - [ux] Fix copy button for mediaSingle with link or border
8
+
3
9
  ## 187.34.1
4
10
 
5
11
  ### Patch Changes
@@ -132,7 +132,8 @@ var createToolbarCopyCommandForNode = function createToolbarCopyCommandForNode(n
132
132
  div.firstChild.setAttribute('data-pm-slice', '0 0 []');
133
133
  }
134
134
  // ED-17083 safari seems have bugs for extension copy because exntension do not have a child text(innerText) and it will not recognized as html in clipboard, this could be merge into one if this extension fixed children issue or safari fix the copy bug
135
- if (_utils2.browser.safari && state.selection instanceof _state.NodeSelection && state.selection.node.type === state.schema.nodes.extension) {
135
+ // MEX-2528 safari has a bug related to the mediaSingle node with border or link. The image tag within the clipboard is not recognized as HTML when using the ClipboardItem API. To address this, we have to switch to ClipboardPolyfill
136
+ if (_utils2.browser.safari && state.selection instanceof _state.NodeSelection && (state.selection.node.type === state.schema.nodes.extension || state.selection.node.type === state.schema.nodes.mediaSingle)) {
136
137
  (0, _clipboard.copyHTMLToClipboardPolyfill)(div);
137
138
  } else {
138
139
  (0, _clipboard.copyHTMLToClipboard)(div);
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.version = exports.nextMajorVersion = exports.name = void 0;
7
7
  var name = "@atlaskit/editor-core";
8
8
  exports.name = name;
9
- var version = "187.34.1";
9
+ var version = "187.34.2";
10
10
  exports.version = version;
11
11
  var nextMajorVersion = function nextMajorVersion() {
12
12
  return [Number(version.split('.')[0]) + 1, 0, 0].join('.');
@@ -123,7 +123,8 @@ export const createToolbarCopyCommandForNode = nodeType => (state, dispatch) =>
123
123
  div.firstChild.setAttribute('data-pm-slice', '0 0 []');
124
124
  }
125
125
  // ED-17083 safari seems have bugs for extension copy because exntension do not have a child text(innerText) and it will not recognized as html in clipboard, this could be merge into one if this extension fixed children issue or safari fix the copy bug
126
- if (browser.safari && state.selection instanceof NodeSelection && state.selection.node.type === state.schema.nodes.extension) {
126
+ // MEX-2528 safari has a bug related to the mediaSingle node with border or link. The image tag within the clipboard is not recognized as HTML when using the ClipboardItem API. To address this, we have to switch to ClipboardPolyfill
127
+ if (browser.safari && state.selection instanceof NodeSelection && (state.selection.node.type === state.schema.nodes.extension || state.selection.node.type === state.schema.nodes.mediaSingle)) {
127
128
  copyHTMLToClipboardPolyfill(div);
128
129
  } else {
129
130
  copyHTMLToClipboard(div);
@@ -1,5 +1,5 @@
1
1
  export const name = "@atlaskit/editor-core";
2
- export const version = "187.34.1";
2
+ export const version = "187.34.2";
3
3
  export const nextMajorVersion = () => {
4
4
  return [Number(version.split('.')[0]) + 1, 0, 0].join('.');
5
5
  };
@@ -122,7 +122,8 @@ export var createToolbarCopyCommandForNode = function createToolbarCopyCommandFo
122
122
  div.firstChild.setAttribute('data-pm-slice', '0 0 []');
123
123
  }
124
124
  // ED-17083 safari seems have bugs for extension copy because exntension do not have a child text(innerText) and it will not recognized as html in clipboard, this could be merge into one if this extension fixed children issue or safari fix the copy bug
125
- if (browser.safari && state.selection instanceof NodeSelection && state.selection.node.type === state.schema.nodes.extension) {
125
+ // MEX-2528 safari has a bug related to the mediaSingle node with border or link. The image tag within the clipboard is not recognized as HTML when using the ClipboardItem API. To address this, we have to switch to ClipboardPolyfill
126
+ if (browser.safari && state.selection instanceof NodeSelection && (state.selection.node.type === state.schema.nodes.extension || state.selection.node.type === state.schema.nodes.mediaSingle)) {
126
127
  copyHTMLToClipboardPolyfill(div);
127
128
  } else {
128
129
  copyHTMLToClipboard(div);
@@ -1,5 +1,5 @@
1
1
  export var name = "@atlaskit/editor-core";
2
- export var version = "187.34.1";
2
+ export var version = "187.34.2";
3
3
  export var nextMajorVersion = function nextMajorVersion() {
4
4
  return [Number(version.split('.')[0]) + 1, 0, 0].join('.');
5
5
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-core",
3
- "version": "187.34.1",
3
+ "version": "187.34.2",
4
4
  "description": "A package contains Atlassian editor core functionality",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -90,8 +90,8 @@
90
90
  "@atlaskit/locale": "^2.5.0",
91
91
  "@atlaskit/logo": "^13.14.0",
92
92
  "@atlaskit/media-card": "^76.1.0",
93
- "@atlaskit/media-client": "^23.1.0",
94
- "@atlaskit/media-common": "^8.1.0",
93
+ "@atlaskit/media-client": "^23.2.0",
94
+ "@atlaskit/media-common": "^8.2.0",
95
95
  "@atlaskit/media-filmstrip": "^47.0.0",
96
96
  "@atlaskit/media-picker": "^66.2.0",
97
97
  "@atlaskit/media-ui": "^24.0.0",