@atlaskit/editor-plugin-block-menu 5.0.13 → 5.0.14

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
+ ## 5.0.14
4
+
5
+ ### Patch Changes
6
+
7
+ - [`b5dc6946c55d9`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/b5dc6946c55d9) -
8
+ Clean up platform_editor_block_menu_layout_format
9
+ - Updated dependencies
10
+
3
11
  ## 5.0.13
4
12
 
5
13
  ### Patch Changes
@@ -146,10 +146,7 @@ var formatNode = exports.formatNode = function formatNode(api) {
146
146
  return newTr;
147
147
  } else {
148
148
  var _newTr = formatNodeWhenSelectionEmpty(tr, targetType, nodePos, schema);
149
- var allowedNodes = [nodes.blockquote, nodes.panel, nodes.codeBlock];
150
- if ((0, _expValEquals.expValEquals)('platform_editor_block_menu_layout_format', 'isEnabled', true)) {
151
- allowedNodes.push(nodes.layoutSection);
152
- }
149
+ var allowedNodes = [nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.layoutSection];
153
150
  if ((0, _expValEquals.expValEquals)('platform_editor_block_menu_expand_format', 'isEnabled', true)) {
154
151
  allowedNodes.push(nodes.expand);
155
152
  }
@@ -22,10 +22,7 @@ var getIsFormatMenuHidden = function getIsFormatMenuHidden(selection, schema, me
22
22
  return !!disabledNode || isNested && !(0, _platformFeatureFlags.fg)('platform_editor_block_menu_transform_nested_node');
23
23
  }
24
24
  var content;
25
- var allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList];
26
- if ((0, _expValEquals.expValEquals)('platform_editor_block_menu_layout_format', 'isEnabled', true)) {
27
- allowedNodes.push(nodes.layoutSection);
28
- }
25
+ var allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList, nodes.layoutSection];
29
26
  if ((0, _expValEquals.expValEquals)('platform_editor_block_menu_expand_format', 'isEnabled', true)) {
30
27
  allowedNodes.push(nodes.expand);
31
28
  }
@@ -59,10 +56,7 @@ var getIsFormatMenuHiddenEmptyLine = function getIsFormatMenuHiddenEmptyLine(sel
59
56
  return true;
60
57
  } else {
61
58
  var content;
62
- var allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList];
63
- if ((0, _expValEquals.expValEquals)('platform_editor_block_menu_layout_format', 'isEnabled', true)) {
64
- allowedNodes.push(nodes.layoutSection);
65
- }
59
+ var allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList, nodes.layoutSection];
66
60
  if ((0, _expValEquals.expValEquals)('platform_editor_block_menu_expand_format', 'isEnabled', true)) {
67
61
  allowedNodes.push(nodes.expand);
68
62
  }
@@ -151,10 +151,7 @@ export const formatNode = api => (targetType, analyticsAttrs) => {
151
151
  return newTr;
152
152
  } else {
153
153
  const newTr = formatNodeWhenSelectionEmpty(tr, targetType, nodePos, schema);
154
- const allowedNodes = [nodes.blockquote, nodes.panel, nodes.codeBlock];
155
- if (expValEquals('platform_editor_block_menu_layout_format', 'isEnabled', true)) {
156
- allowedNodes.push(nodes.layoutSection);
157
- }
154
+ const allowedNodes = [nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.layoutSection];
158
155
  if (expValEquals('platform_editor_block_menu_expand_format', 'isEnabled', true)) {
159
156
  allowedNodes.push(nodes.expand);
160
157
  }
@@ -16,10 +16,7 @@ const getIsFormatMenuHidden = (selection, schema, menuTriggerBy) => {
16
16
  return !!disabledNode || isNested && !fg('platform_editor_block_menu_transform_nested_node');
17
17
  }
18
18
  let content;
19
- const allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList];
20
- if (expValEquals('platform_editor_block_menu_layout_format', 'isEnabled', true)) {
21
- allowedNodes.push(nodes.layoutSection);
22
- }
19
+ const allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList, nodes.layoutSection];
23
20
  if (expValEquals('platform_editor_block_menu_expand_format', 'isEnabled', true)) {
24
21
  allowedNodes.push(nodes.expand);
25
22
  }
@@ -53,10 +50,7 @@ const getIsFormatMenuHiddenEmptyLine = (selection, schema, menuTriggerBy) => {
53
50
  return true;
54
51
  } else {
55
52
  let content;
56
- const allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList];
57
- if (expValEquals('platform_editor_block_menu_layout_format', 'isEnabled', true)) {
58
- allowedNodes.push(nodes.layoutSection);
59
- }
53
+ const allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList, nodes.layoutSection];
60
54
  if (expValEquals('platform_editor_block_menu_expand_format', 'isEnabled', true)) {
61
55
  allowedNodes.push(nodes.expand);
62
56
  }
@@ -141,10 +141,7 @@ export var formatNode = function formatNode(api) {
141
141
  return newTr;
142
142
  } else {
143
143
  var _newTr = formatNodeWhenSelectionEmpty(tr, targetType, nodePos, schema);
144
- var allowedNodes = [nodes.blockquote, nodes.panel, nodes.codeBlock];
145
- if (expValEquals('platform_editor_block_menu_layout_format', 'isEnabled', true)) {
146
- allowedNodes.push(nodes.layoutSection);
147
- }
144
+ var allowedNodes = [nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.layoutSection];
148
145
  if (expValEquals('platform_editor_block_menu_expand_format', 'isEnabled', true)) {
149
146
  allowedNodes.push(nodes.expand);
150
147
  }
@@ -16,10 +16,7 @@ var getIsFormatMenuHidden = function getIsFormatMenuHidden(selection, schema, me
16
16
  return !!disabledNode || isNested && !fg('platform_editor_block_menu_transform_nested_node');
17
17
  }
18
18
  var content;
19
- var allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList];
20
- if (expValEquals('platform_editor_block_menu_layout_format', 'isEnabled', true)) {
21
- allowedNodes.push(nodes.layoutSection);
22
- }
19
+ var allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList, nodes.layoutSection];
23
20
  if (expValEquals('platform_editor_block_menu_expand_format', 'isEnabled', true)) {
24
21
  allowedNodes.push(nodes.expand);
25
22
  }
@@ -53,10 +50,7 @@ var getIsFormatMenuHiddenEmptyLine = function getIsFormatMenuHiddenEmptyLine(sel
53
50
  return true;
54
51
  } else {
55
52
  var content;
56
- var allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList];
57
- if (expValEquals('platform_editor_block_menu_layout_format', 'isEnabled', true)) {
58
- allowedNodes.push(nodes.layoutSection);
59
- }
53
+ var allowedNodes = [nodes.paragraph, nodes.heading, nodes.blockquote, nodes.panel, nodes.codeBlock, nodes.bulletList, nodes.orderedList, nodes.taskList, nodes.layoutSection];
60
54
  if (expValEquals('platform_editor_block_menu_expand_format', 'isEnabled', true)) {
61
55
  allowedNodes.push(nodes.expand);
62
56
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-block-menu",
3
- "version": "5.0.13",
3
+ "version": "5.0.14",
4
4
  "description": "BlockMenu plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -44,8 +44,8 @@
44
44
  "@atlaskit/platform-feature-flags": "^1.1.0",
45
45
  "@atlaskit/platform-feature-flags-react": "^0.4.0",
46
46
  "@atlaskit/primitives": "^16.2.0",
47
- "@atlaskit/tmp-editor-statsig": "^13.40.0",
48
- "@atlaskit/tokens": "^8.1.0",
47
+ "@atlaskit/tmp-editor-statsig": "^13.41.0",
48
+ "@atlaskit/tokens": "^8.2.0",
49
49
  "@babel/runtime": "^7.0.0"
50
50
  },
51
51
  "peerDependencies": {