@atlaskit/editor-plugin-block-menu 9.2.5 → 9.2.6

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,13 @@
1
1
  # @atlaskit/editor-plugin-block-menu
2
2
 
3
+ ## 9.2.6
4
+
5
+ ### Patch Changes
6
+
7
+ - [`fe16d6a5e7c9b`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/fe16d6a5e7c9b) -
8
+ Gate the block menu Change format copy behind the MAUI experiment and phase 3 feature gate.
9
+ - Updated dependencies
10
+
3
11
  ## 9.2.5
4
12
 
5
13
  ### Patch Changes
@@ -14,6 +14,7 @@ var _editorToolbar = require("@atlaskit/editor-toolbar");
14
14
  var _changes = _interopRequireDefault(require("@atlaskit/icon/core/changes"));
15
15
  var _chevronRight = _interopRequireDefault(require("@atlaskit/icon/core/chevron-right"));
16
16
  var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
17
+ var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
17
18
  var _consts = require("./consts");
18
19
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
19
20
  var FormatMenuComponent = exports.FormatMenuComponent = function FormatMenuComponent(_ref) {
@@ -21,7 +22,9 @@ var FormatMenuComponent = exports.FormatMenuComponent = function FormatMenuCompo
21
22
  children = _ref.children;
22
23
  var _useIntl = (0, _reactIntl.useIntl)(),
23
24
  formatMessage = _useIntl.formatMessage;
24
- var formatMenuLabel = (0, _platformFeatureFlags.fg)('platform_editor_block_menu_v2_patch_2') ? _messages.blockMenuMessages.changeFormat : _messages.blockMenuMessages.turnInto;
25
+
26
+ // eslint-disable-next-line @atlaskit/platform/no-preconditioning -- gate + experiment layering for MAUI rollout (cc-maui-experiment + cc-maui-phase-3); will simplify post-rollout
27
+ var formatMenuLabel = (0, _expValEquals.expValEquals)('cc-maui-experiment', 'isEnabled', true) && (0, _platformFeatureFlags.fg)('cc-maui-phase-3') ? _messages.blockMenuMessages.changeFormat : _messages.blockMenuMessages.turnInto;
25
28
  var handleClick = (0, _react.useCallback)(function () {
26
29
  api === null || api === void 0 || api.core.actions.execute(function (_ref2) {
27
30
  var _api$analytics;
@@ -6,6 +6,7 @@ import { ToolbarNestedDropdownMenu } from '@atlaskit/editor-toolbar';
6
6
  import ChangesIcon from '@atlaskit/icon/core/changes';
7
7
  import ChevronRightIcon from '@atlaskit/icon/core/chevron-right';
8
8
  import { fg } from '@atlaskit/platform-feature-flags';
9
+ import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
9
10
  import { BLOCK_MENU_ITEM_NAME } from './consts';
10
11
  export const FormatMenuComponent = ({
11
12
  api,
@@ -14,7 +15,9 @@ export const FormatMenuComponent = ({
14
15
  const {
15
16
  formatMessage
16
17
  } = useIntl();
17
- const formatMenuLabel = fg('platform_editor_block_menu_v2_patch_2') ? blockMenuMessages.changeFormat : blockMenuMessages.turnInto;
18
+
19
+ // eslint-disable-next-line @atlaskit/platform/no-preconditioning -- gate + experiment layering for MAUI rollout (cc-maui-experiment + cc-maui-phase-3); will simplify post-rollout
20
+ const formatMenuLabel = expValEquals('cc-maui-experiment', 'isEnabled', true) && fg('cc-maui-phase-3') ? blockMenuMessages.changeFormat : blockMenuMessages.turnInto;
18
21
  const handleClick = useCallback(() => {
19
22
  api === null || api === void 0 ? void 0 : api.core.actions.execute(({
20
23
  tr
@@ -6,13 +6,16 @@ import { ToolbarNestedDropdownMenu } from '@atlaskit/editor-toolbar';
6
6
  import ChangesIcon from '@atlaskit/icon/core/changes';
7
7
  import ChevronRightIcon from '@atlaskit/icon/core/chevron-right';
8
8
  import { fg } from '@atlaskit/platform-feature-flags';
9
+ import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
9
10
  import { BLOCK_MENU_ITEM_NAME } from './consts';
10
11
  export var FormatMenuComponent = function FormatMenuComponent(_ref) {
11
12
  var api = _ref.api,
12
13
  children = _ref.children;
13
14
  var _useIntl = useIntl(),
14
15
  formatMessage = _useIntl.formatMessage;
15
- var formatMenuLabel = fg('platform_editor_block_menu_v2_patch_2') ? blockMenuMessages.changeFormat : blockMenuMessages.turnInto;
16
+
17
+ // eslint-disable-next-line @atlaskit/platform/no-preconditioning -- gate + experiment layering for MAUI rollout (cc-maui-experiment + cc-maui-phase-3); will simplify post-rollout
18
+ var formatMenuLabel = expValEquals('cc-maui-experiment', 'isEnabled', true) && fg('cc-maui-phase-3') ? blockMenuMessages.changeFormat : blockMenuMessages.turnInto;
16
19
  var handleClick = useCallback(function () {
17
20
  api === null || api === void 0 || api.core.actions.execute(function (_ref2) {
18
21
  var _api$analytics;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-block-menu",
3
- "version": "9.2.5",
3
+ "version": "9.2.6",
4
4
  "description": "BlockMenu plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -38,7 +38,7 @@
38
38
  "@atlaskit/editor-prosemirror": "^7.3.0",
39
39
  "@atlaskit/editor-shared-styles": "^3.11.0",
40
40
  "@atlaskit/editor-tables": "^2.10.0",
41
- "@atlaskit/editor-toolbar": "^1.6.0",
41
+ "@atlaskit/editor-toolbar": "^1.7.0",
42
42
  "@atlaskit/flag": "^17.12.0",
43
43
  "@atlaskit/icon": "^35.0.0",
44
44
  "@atlaskit/platform-feature-flags": "^1.1.0",
@@ -50,7 +50,7 @@
50
50
  "bind-event-listener": "^3.0.0"
51
51
  },
52
52
  "peerDependencies": {
53
- "@atlaskit/editor-common": "^114.36.0",
53
+ "@atlaskit/editor-common": "^114.38.0",
54
54
  "react": "^18.2.0",
55
55
  "react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
56
56
  },
@@ -102,6 +102,9 @@
102
102
  },
103
103
  "platform_editor_block_menu_v2_patch_2": {
104
104
  "type": "boolean"
105
+ },
106
+ "cc-maui-phase-3": {
107
+ "type": "boolean"
105
108
  }
106
109
  },
107
110
  "devDependencies": {