@atlaskit/editor-plugin-media 9.7.3 → 9.8.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-plugin-media
2
2
 
3
+ ## 9.8.1
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 9.8.0
10
+
11
+ ### Minor Changes
12
+
13
+ - [`17119fb95e0a4`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/17119fb95e0a4) -
14
+ [EDITOR-3747](https://hello.jira.atlassian.cloud/browse/EDITOR-3747) - clean up
15
+ platform_editor_ssr_renderer experiment
16
+
17
+ ### Patch Changes
18
+
19
+ - Updated dependencies
20
+
3
21
  ## 9.7.3
4
22
 
5
23
  ### Patch Changes
@@ -121,9 +121,7 @@ var MediaNodeView = /*#__PURE__*/function (_SelectionBasedNodeVi) {
121
121
  if ((0, _expValEquals.expValEquals)('platform_editor_media_vc_fixes', 'isEnabled', true)) {
122
122
  return mediaOptions.provider;
123
123
  }
124
- if ((0, _expValEquals.expValEquals)('platform_editor_ssr_renderer', 'isEnabled', true)) {
125
- return mediaOptions.syncProvider ? Promise.resolve(mediaOptions.syncProvider) : mediaOptions.provider;
126
- }
124
+ return mediaOptions.syncProvider ? Promise.resolve(mediaOptions.syncProvider) : mediaOptions.provider;
127
125
  });
128
126
  (0, _defineProperty2.default)(_this, "renderMediaNodeWithState", function (contextIdentifierProvider) {
129
127
  return function (_ref2) {
@@ -28,7 +28,6 @@ var _cellSelection = require("@atlaskit/editor-tables/cell-selection");
28
28
  var _mediaClient = require("@atlaskit/media-client");
29
29
  var _mediaCommon = require("@atlaskit/media-common");
30
30
  var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
31
- var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
32
31
  var _helpers = _interopRequireWildcard(require("../pm-plugins/commands/helpers"));
33
32
  var helpers = _helpers;
34
33
  var _mediaCommon2 = require("../pm-plugins/utils/media-common");
@@ -418,13 +417,8 @@ var MediaPluginStateImplementation = exports.MediaPluginStateImplementation = /*
418
417
  return true;
419
418
  });
420
419
  (0, _defineProperty2.default)(this, "selectedMediaContainerNode", function () {
421
- var selection;
422
- if ((0, _expValEquals.expValEquals)('platform_editor_ssr_renderer', 'isEnabled', true)) {
423
- var _this$view;
424
- selection = (_this$view = _this.view) === null || _this$view === void 0 || (_this$view = _this$view.state) === null || _this$view === void 0 ? void 0 : _this$view.selection;
425
- } else {
426
- selection = _this.view.state.selection;
427
- }
420
+ var _this$view;
421
+ var selection = (_this$view = _this.view) === null || _this$view === void 0 || (_this$view = _this$view.state) === null || _this$view === void 0 ? void 0 : _this$view.selection;
428
422
  if (selection instanceof _state2.NodeSelection && _this.isMediaSchemaNode(selection.node)) {
429
423
  return selection.node;
430
424
  }
@@ -101,9 +101,7 @@ class MediaNodeView extends SelectionBasedNodeView {
101
101
  if (expValEquals('platform_editor_media_vc_fixes', 'isEnabled', true)) {
102
102
  return mediaOptions.provider;
103
103
  }
104
- if (expValEquals('platform_editor_ssr_renderer', 'isEnabled', true)) {
105
- return mediaOptions.syncProvider ? Promise.resolve(mediaOptions.syncProvider) : mediaOptions.provider;
106
- }
104
+ return mediaOptions.syncProvider ? Promise.resolve(mediaOptions.syncProvider) : mediaOptions.provider;
107
105
  });
108
106
  _defineProperty(this, "renderMediaNodeWithState", contextIdentifierProvider => {
109
107
  return ({
@@ -17,7 +17,6 @@ import { CellSelection } from '@atlaskit/editor-tables/cell-selection';
17
17
  import { isFileIdentifier } from '@atlaskit/media-client';
18
18
  import { getMediaFeatureFlag } from '@atlaskit/media-common';
19
19
  import { fg } from '@atlaskit/platform-feature-flags';
20
- import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
21
20
  // Ignored via go/ees005
22
21
  // eslint-disable-next-line import/no-namespace
23
22
  import * as helpers from '../pm-plugins/commands/helpers';
@@ -389,15 +388,8 @@ export class MediaPluginStateImplementation {
389
388
  return true;
390
389
  });
391
390
  _defineProperty(this, "selectedMediaContainerNode", () => {
392
- let selection;
393
- if (expValEquals('platform_editor_ssr_renderer', 'isEnabled', true)) {
394
- var _this$view, _this$view$state;
395
- selection = (_this$view = this.view) === null || _this$view === void 0 ? void 0 : (_this$view$state = _this$view.state) === null || _this$view$state === void 0 ? void 0 : _this$view$state.selection;
396
- } else {
397
- ({
398
- selection
399
- } = this.view.state);
400
- }
391
+ var _this$view, _this$view$state;
392
+ const selection = (_this$view = this.view) === null || _this$view === void 0 ? void 0 : (_this$view$state = _this$view.state) === null || _this$view$state === void 0 ? void 0 : _this$view$state.selection;
401
393
  if (selection instanceof NodeSelection && this.isMediaSchemaNode(selection.node)) {
402
394
  return selection.node;
403
395
  }
@@ -115,9 +115,7 @@ var MediaNodeView = /*#__PURE__*/function (_SelectionBasedNodeVi) {
115
115
  if (expValEquals('platform_editor_media_vc_fixes', 'isEnabled', true)) {
116
116
  return mediaOptions.provider;
117
117
  }
118
- if (expValEquals('platform_editor_ssr_renderer', 'isEnabled', true)) {
119
- return mediaOptions.syncProvider ? Promise.resolve(mediaOptions.syncProvider) : mediaOptions.provider;
120
- }
118
+ return mediaOptions.syncProvider ? Promise.resolve(mediaOptions.syncProvider) : mediaOptions.provider;
121
119
  });
122
120
  _defineProperty(_this, "renderMediaNodeWithState", function (contextIdentifierProvider) {
123
121
  return function (_ref2) {
@@ -26,7 +26,6 @@ import { CellSelection } from '@atlaskit/editor-tables/cell-selection';
26
26
  import { isFileIdentifier } from '@atlaskit/media-client';
27
27
  import { getMediaFeatureFlag } from '@atlaskit/media-common';
28
28
  import { fg } from '@atlaskit/platform-feature-flags';
29
- import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
30
29
  // Ignored via go/ees005
31
30
  // eslint-disable-next-line import/no-namespace
32
31
  import * as helpers from '../pm-plugins/commands/helpers';
@@ -410,13 +409,8 @@ export var MediaPluginStateImplementation = /*#__PURE__*/function () {
410
409
  return true;
411
410
  });
412
411
  _defineProperty(this, "selectedMediaContainerNode", function () {
413
- var selection;
414
- if (expValEquals('platform_editor_ssr_renderer', 'isEnabled', true)) {
415
- var _this$view;
416
- selection = (_this$view = _this.view) === null || _this$view === void 0 || (_this$view = _this$view.state) === null || _this$view === void 0 ? void 0 : _this$view.selection;
417
- } else {
418
- selection = _this.view.state.selection;
419
- }
412
+ var _this$view;
413
+ var selection = (_this$view = _this.view) === null || _this$view === void 0 || (_this$view = _this$view.state) === null || _this$view === void 0 ? void 0 : _this$view.selection;
420
414
  if (selection instanceof NodeSelection && _this.isMediaSchemaNode(selection.node)) {
421
415
  return selection.node;
422
416
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-media",
3
- "version": "9.7.3",
3
+ "version": "9.8.1",
4
4
  "description": "Media plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -66,7 +66,7 @@
66
66
  "@atlaskit/primitives": "^18.0.0",
67
67
  "@atlaskit/textfield": "^8.2.0",
68
68
  "@atlaskit/theme": "^22.0.0",
69
- "@atlaskit/tmp-editor-statsig": "^33.1.0",
69
+ "@atlaskit/tmp-editor-statsig": "^34.0.0",
70
70
  "@atlaskit/tokens": "^11.0.0",
71
71
  "@atlaskit/tooltip": "^20.14.0",
72
72
  "@babel/runtime": "^7.0.0",
@@ -78,7 +78,7 @@
78
78
  "uuid": "^3.1.0"
79
79
  },
80
80
  "peerDependencies": {
81
- "@atlaskit/editor-common": "^111.27.0",
81
+ "@atlaskit/editor-common": "^111.28.0",
82
82
  "@atlaskit/media-core": "^37.0.0",
83
83
  "react": "^18.2.0",
84
84
  "react-dom": "^18.2.0",