@atlaskit/editor-plugin-extension 10.1.0 → 10.1.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,17 @@
1
1
  # @atlaskit/editor-plugin-extension
2
2
 
3
+ ## 10.1.2
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 10.1.1
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies
14
+
3
15
  ## 10.1.0
4
16
 
5
17
  ### Minor Changes
@@ -334,6 +334,12 @@ var getToolbarConfig = exports.getToolbarConfig = function getToolbarConfig(_ref
334
334
  var breakoutItems = breakoutOptions(state, formatMessage, extensionState, breakoutEnabled, editorAnalyticsAPI, extensionApi);
335
335
  var extensionObj = (0, _utils3.getSelectedExtension)(state, true);
336
336
 
337
+ // If this is a native-embed extension, skip providing a toolbar config to allow
338
+ // the native-embed plugin to provide a custom toolbar config.
339
+ if ((extensionObj === null || extensionObj === void 0 ? void 0 : extensionObj.node.attrs.extensionType) === _extensions.NATIVE_EMBED_EXTENSION_TYPE) {
340
+ return;
341
+ }
342
+
337
343
  // Check if we need to show confirm dialog for delete button
338
344
  var confirmDialog;
339
345
  if ((0, _utils.isReferencedSource)(state, extensionObj === null || extensionObj === void 0 ? void 0 : extensionObj.node)) {
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
3
- import { messages } from '@atlaskit/editor-common/extensions';
3
+ import { messages, NATIVE_EMBED_EXTENSION_TYPE } from '@atlaskit/editor-common/extensions';
4
4
  import commonMessages from '@atlaskit/editor-common/messages';
5
5
  import { BODIED_EXT_MBE_MARGIN_TOP } from '@atlaskit/editor-common/styles';
6
6
  import { areToolbarFlagsEnabled } from '@atlaskit/editor-common/toolbar-flag-check';
@@ -339,6 +339,12 @@ export const getToolbarConfig = ({
339
339
  const breakoutItems = breakoutOptions(state, formatMessage, extensionState, breakoutEnabled, editorAnalyticsAPI, extensionApi);
340
340
  const extensionObj = getSelectedExtension(state, true);
341
341
 
342
+ // If this is a native-embed extension, skip providing a toolbar config to allow
343
+ // the native-embed plugin to provide a custom toolbar config.
344
+ if ((extensionObj === null || extensionObj === void 0 ? void 0 : extensionObj.node.attrs.extensionType) === NATIVE_EMBED_EXTENSION_TYPE) {
345
+ return;
346
+ }
347
+
342
348
  // Check if we need to show confirm dialog for delete button
343
349
  let confirmDialog;
344
350
  if (isReferencedSource(state, extensionObj === null || extensionObj === void 0 ? void 0 : extensionObj.node)) {
@@ -4,7 +4,7 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
4
4
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
5
5
  import React from 'react';
6
6
  import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
7
- import { messages } from '@atlaskit/editor-common/extensions';
7
+ import { messages, NATIVE_EMBED_EXTENSION_TYPE } from '@atlaskit/editor-common/extensions';
8
8
  import commonMessages from '@atlaskit/editor-common/messages';
9
9
  import { BODIED_EXT_MBE_MARGIN_TOP } from '@atlaskit/editor-common/styles';
10
10
  import { areToolbarFlagsEnabled } from '@atlaskit/editor-common/toolbar-flag-check';
@@ -328,6 +328,12 @@ export var getToolbarConfig = function getToolbarConfig(_ref2) {
328
328
  var breakoutItems = breakoutOptions(state, formatMessage, extensionState, breakoutEnabled, editorAnalyticsAPI, extensionApi);
329
329
  var extensionObj = getSelectedExtension(state, true);
330
330
 
331
+ // If this is a native-embed extension, skip providing a toolbar config to allow
332
+ // the native-embed plugin to provide a custom toolbar config.
333
+ if ((extensionObj === null || extensionObj === void 0 ? void 0 : extensionObj.node.attrs.extensionType) === NATIVE_EMBED_EXTENSION_TYPE) {
334
+ return;
335
+ }
336
+
331
337
  // Check if we need to show confirm dialog for delete button
332
338
  var confirmDialog;
333
339
  if (isReferencedSource(state, extensionObj === null || extensionObj === void 0 ? void 0 : extensionObj.node)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-extension",
3
- "version": "10.1.0",
3
+ "version": "10.1.2",
4
4
  "description": "editor-plugin-extension plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -50,13 +50,13 @@
50
50
  "@atlaskit/radio": "^8.4.0",
51
51
  "@atlaskit/section-message": "^8.12.0",
52
52
  "@atlaskit/select": "^21.7.0",
53
- "@atlaskit/smart-user-picker": "^8.9.0",
53
+ "@atlaskit/smart-user-picker": "^9.0.0",
54
54
  "@atlaskit/spinner": "^19.0.0",
55
55
  "@atlaskit/tabs": "^18.3.0",
56
56
  "@atlaskit/textarea": "^8.2.0",
57
57
  "@atlaskit/textfield": "^8.2.0",
58
58
  "@atlaskit/theme": "^21.0.0",
59
- "@atlaskit/tmp-editor-statsig": "^25.2.0",
59
+ "@atlaskit/tmp-editor-statsig": "^26.0.0",
60
60
  "@atlaskit/toggle": "^15.2.0",
61
61
  "@atlaskit/tokens": "^11.0.0",
62
62
  "@atlaskit/tooltip": "^20.14.0",
@@ -70,7 +70,7 @@
70
70
  "uuid": "^3.1.0"
71
71
  },
72
72
  "peerDependencies": {
73
- "@atlaskit/editor-common": "^111.13.0",
73
+ "@atlaskit/editor-common": "^111.16.0",
74
74
  "react": "^18.2.0",
75
75
  "react-intl-next": "npm:react-intl@^5.18.1"
76
76
  },