@atlaskit/editor-common 121.2.4 → 121.3.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,23 @@
1
1
  # @atlaskit/editor-common
2
2
 
3
+ ## 121.3.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`2ca8a0b02c20e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/2ca8a0b02c20e) -
8
+ Clean up experiment `platform_editor_bodiedextension_layoutshift_fix` by making the bodied
9
+ extension layout shift fix permanent.
10
+ - Updated dependencies
11
+
12
+ ## 121.3.0
13
+
14
+ ### Minor Changes
15
+
16
+ - [`9e88561b1811e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/9e88561b1811e) -
17
+ Add generic extension API insertion and node-type replacement support. Use these APIs to preserve
18
+ the position of newly inserted inline-bodied Forge macros and to restore inline placement when an
19
+ inline Connect macro is harmonized to Forge while platform_forge_inline_bodied_macro is enabled.
20
+
3
21
  ## 121.2.4
4
22
 
5
23
  ### Patch Changes
@@ -276,7 +276,7 @@ var ExtensionNode = exports.ExtensionNode = /*#__PURE__*/function (_ReactNodeVie
276
276
  contentDomWrapper.className = "".concat(this.node.type.name, "-content-dom-wrapper");
277
277
  var isBodiedExtension = this.node.type.name === 'bodiedExtension';
278
278
  var showMacroInteractionDesignUpdates = (_this$reactComponentP3 = this.reactComponentProps) === null || _this$reactComponentP3 === void 0 || (_this$reactComponentP3 = _this$reactComponentP3.macroInteractionDesignFeatureFlags) === null || _this$reactComponentP3 === void 0 ? void 0 : _this$reactComponentP3.showMacroInteractionDesignUpdates;
279
- if (isBodiedExtension && showMacroInteractionDesignUpdates && (0, _expValEquals.expValEquals)('platform_editor_bodiedextension_layoutshift_fix', 'isEnabled', true)) {
279
+ if (isBodiedExtension && showMacroInteractionDesignUpdates) {
280
280
  // Create outer wrapper to hold space for the lozenge
281
281
  var outerWrapper = document.createElement('div');
282
282
  outerWrapper.className = "".concat(this.node.type.name, "-content-outer-wrapper");
@@ -27,7 +27,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
27
27
  var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
28
28
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
29
29
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
30
- var packageVersion = "121.2.3";
30
+ var packageVersion = "121.3.0";
31
31
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
32
32
  // Remove URL as it has UGC
33
33
  // Ignored via go/ees007
@@ -24,7 +24,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
24
24
  * @jsx jsx
25
25
  */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
26
26
  var packageName = "@atlaskit/editor-common";
27
- var packageVersion = "121.2.3";
27
+ var packageVersion = "121.3.0";
28
28
  var halfFocusRing = 1;
29
29
  var dropOffset = '0, 8';
30
30
  var fadeIn = (0, _react2.keyframes)({
@@ -232,7 +232,7 @@ export class ExtensionNode extends ReactNodeView {
232
232
  contentDomWrapper.className = `${this.node.type.name}-content-dom-wrapper`;
233
233
  const isBodiedExtension = this.node.type.name === 'bodiedExtension';
234
234
  const showMacroInteractionDesignUpdates = (_this$reactComponentP4 = this.reactComponentProps) === null || _this$reactComponentP4 === void 0 ? void 0 : (_this$reactComponentP5 = _this$reactComponentP4.macroInteractionDesignFeatureFlags) === null || _this$reactComponentP5 === void 0 ? void 0 : _this$reactComponentP5.showMacroInteractionDesignUpdates;
235
- if (isBodiedExtension && showMacroInteractionDesignUpdates && expValEquals('platform_editor_bodiedextension_layoutshift_fix', 'isEnabled', true)) {
235
+ if (isBodiedExtension && showMacroInteractionDesignUpdates) {
236
236
  // Create outer wrapper to hold space for the lozenge
237
237
  const outerWrapper = document.createElement('div');
238
238
  outerWrapper.className = `${this.node.type.name}-content-outer-wrapper`;
@@ -13,7 +13,7 @@ const NETWORK_FAILURE_REGEX = /^network failure/i;
13
13
  const RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
14
14
  const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
15
15
  const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
16
- const packageVersion = "121.2.3";
16
+ const packageVersion = "121.3.0";
17
17
  const sanitiseSentryEvents = (data, _hint) => {
18
18
  // Remove URL as it has UGC
19
19
  // Ignored via go/ees007
@@ -14,7 +14,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
14
14
  import { fg } from '@atlaskit/platform-feature-flags/fg';
15
15
  import Layer from '../Layer';
16
16
  const packageName = "@atlaskit/editor-common";
17
- const packageVersion = "121.2.3";
17
+ const packageVersion = "121.3.0";
18
18
  const halfFocusRing = 1;
19
19
  const dropOffset = '0, 8';
20
20
  const fadeIn = keyframes({
@@ -268,7 +268,7 @@ export var ExtensionNode = /*#__PURE__*/function (_ReactNodeView) {
268
268
  contentDomWrapper.className = "".concat(this.node.type.name, "-content-dom-wrapper");
269
269
  var isBodiedExtension = this.node.type.name === 'bodiedExtension';
270
270
  var showMacroInteractionDesignUpdates = (_this$reactComponentP3 = this.reactComponentProps) === null || _this$reactComponentP3 === void 0 || (_this$reactComponentP3 = _this$reactComponentP3.macroInteractionDesignFeatureFlags) === null || _this$reactComponentP3 === void 0 ? void 0 : _this$reactComponentP3.showMacroInteractionDesignUpdates;
271
- if (isBodiedExtension && showMacroInteractionDesignUpdates && expValEquals('platform_editor_bodiedextension_layoutshift_fix', 'isEnabled', true)) {
271
+ if (isBodiedExtension && showMacroInteractionDesignUpdates) {
272
272
  // Create outer wrapper to hold space for the lozenge
273
273
  var outerWrapper = document.createElement('div');
274
274
  outerWrapper.className = "".concat(this.node.type.name, "-content-outer-wrapper");
@@ -19,7 +19,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
19
19
  var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
20
20
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
21
21
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
22
- var packageVersion = "121.2.3";
22
+ var packageVersion = "121.3.0";
23
23
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
24
24
  // Remove URL as it has UGC
25
25
  // Ignored via go/ees007
@@ -21,7 +21,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
21
21
  import { fg } from '@atlaskit/platform-feature-flags/fg';
22
22
  import Layer from '../Layer';
23
23
  var packageName = "@atlaskit/editor-common";
24
- var packageVersion = "121.2.3";
24
+ var packageVersion = "121.3.0";
25
25
  var halfFocusRing = 1;
26
26
  var dropOffset = '0, 8';
27
27
  var fadeIn = keyframes({
@@ -23,8 +23,9 @@ export type ExtensionAPI<T extends Parameters = Parameters> = {
23
23
  allowSelectionNearNewNode?: boolean;
24
24
  allowSelectionToNewNode?: boolean;
25
25
  }) => void;
26
+ insertAtSelection?: (adf: ADFEntity) => void;
26
27
  scrollTo: (localId: string) => void;
27
- update: (localId: string, mutationCallback: (currentValue: Pick<ADFEntity, 'content' | 'attrs' | 'marks'>) => Pick<ADFEntity, 'content' | 'attrs' | 'marks'>, options?: {
28
+ update: (localId: string, mutationCallback: (currentValue: Pick<ADFEntity, 'content' | 'attrs' | 'marks'> & Partial<Pick<ADFEntity, 'type'>>) => Pick<ADFEntity, 'content' | 'attrs' | 'marks'> & Partial<Pick<ADFEntity, 'type'>>, options?: {
28
29
  addToHistory?: boolean;
29
30
  scrollIntoView?: boolean;
30
31
  }) => void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-common",
3
- "version": "121.2.4",
3
+ "version": "121.3.1",
4
4
  "description": "A package that contains common classes and components for editor and renderer",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -84,7 +84,7 @@
84
84
  "@atlaskit/task-decision": "^21.9.0",
85
85
  "@atlaskit/teams-app-config": "^3.1.0",
86
86
  "@atlaskit/textfield": "^10.2.0",
87
- "@atlaskit/tmp-editor-statsig": "^184.0.0",
87
+ "@atlaskit/tmp-editor-statsig": "^185.0.0",
88
88
  "@atlaskit/tokens": "^16.11.0",
89
89
  "@atlaskit/tooltip": "^24.3.0",
90
90
  "@atlaskit/width-detector": "^7.2.0",