@atlaskit/editor-plugin-block-controls 13.1.0 → 13.1.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,13 @@
1
1
  # @atlaskit/editor-plugin-block-controls
2
2
 
3
+ ## 13.1.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`b2f53114889ac`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/b2f53114889ac) -
8
+ Clean up feature gate `platform_editor_block_menu_jira_patch_1`
9
+ - Updated dependencies
10
+
3
11
  ## 13.1.0
4
12
 
5
13
  ### Minor Changes
@@ -391,10 +391,7 @@ var _apply = exports.apply = function apply(api, formatMessage, tr, currentState
391
391
  } else {
392
392
  if (latestActiveNode && (!isActiveNodeDeleted || isReplacedWithSameSize)) {
393
393
  var _nodeDecAtActivePos = getDecorationAtPos(newState, decorations, latestActiveNode.pos, to);
394
- // Guard against rootPos being undefined (keyboard-triggered handles do not set it),
395
- // which would cause a RangeError in ProseMirror. When the gate is off, the original
396
- // behaviour is preserved for safe incremental rollout.
397
- var rootNodeDecAtActivePos = (0, _platformFeatureFlags.fg)('platform_editor_block_menu_jira_patch_1') ? latestActiveNode.rootPos !== undefined ? getDecorationAtPos(newState, decorations, latestActiveNode.rootPos, to) : undefined : getDecorationAtPos(newState, decorations, latestActiveNode.rootPos, to);
394
+ var rootNodeDecAtActivePos = latestActiveNode.rootPos !== undefined ? getDecorationAtPos(newState, decorations, latestActiveNode.rootPos, to) : undefined;
398
395
  if (_nodeDecAtActivePos || rootNodeDecAtActivePos) {
399
396
  isActiveNodeModified = true;
400
397
  }
@@ -1045,7 +1045,7 @@ var DragHandle = exports.DragHandle = function DragHandle(_ref) {
1045
1045
  css: [(0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') ? dragHandleButtonStyles : dragHandleButtonStylesOld, (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') && dragHandleColor,
1046
1046
  // ED-26266: Fixed the drag handle highlight when selecting multiple line in Firefox
1047
1047
  // See https://product-fabric.atlassian.net/browse/ED-26266
1048
- browser.gecko && dragHandleMultiLineSelectionFixFirefox, (0, _experiments.editorExperiment)('advanced_layouts', true) && isLayoutColumn && layoutColumnDragHandleStyles, dragHandleSelected && hasHadInteraction && selectedStyles, (0, _experiments.editorExperiment)('platform_editor_preview_panel_responsiveness', true) && (0, _experiments.editorExperiment)('platform_editor_controls', 'control') && dragHandleButtonSmallScreenStyles, (0, _experiments.editorExperiment)('platform_editor_block_menu', true) && isFocused && keyboardFocusedDragHandleStyles, (0, _experiments.editorExperiment)('platform_editor_block_menu', true) ? focusedStyles : focusedStylesOld, ((0, _expValEquals.expValEquals)('confluence_compact_text_format', 'isEnabled', true) || (0, _expValEquals.expValEquals)('cc_editor_ai_content_mode', 'variant', 'test') && (0, _platformFeatureFlags.fg)('platform_editor_content_mode_button_mvp') || (0, _experiments.editorExperiment)('platform_editor_block_menu', true) && (0, _platformFeatureFlags.fg)('platform_editor_block_menu_jira_patch_1')) && dragHandleButtonScaledStyles],
1048
+ browser.gecko && dragHandleMultiLineSelectionFixFirefox, (0, _experiments.editorExperiment)('advanced_layouts', true) && isLayoutColumn && layoutColumnDragHandleStyles, dragHandleSelected && hasHadInteraction && selectedStyles, (0, _experiments.editorExperiment)('platform_editor_preview_panel_responsiveness', true) && (0, _experiments.editorExperiment)('platform_editor_controls', 'control') && dragHandleButtonSmallScreenStyles, (0, _experiments.editorExperiment)('platform_editor_block_menu', true) && isFocused && keyboardFocusedDragHandleStyles, (0, _experiments.editorExperiment)('platform_editor_block_menu', true) ? focusedStyles : focusedStylesOld, ((0, _expValEquals.expValEquals)('confluence_compact_text_format', 'isEnabled', true) || (0, _expValEquals.expValEquals)('cc_editor_ai_content_mode', 'variant', 'test') && (0, _platformFeatureFlags.fg)('platform_editor_content_mode_button_mvp') || (0, _experiments.editorExperiment)('platform_editor_block_menu', true)) && dragHandleButtonScaledStyles],
1049
1049
  ref: buttonRef
1050
1050
  // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
1051
1051
  ,
@@ -381,10 +381,7 @@ export const apply = (api, formatMessage, tr, currentState, newState, flags, nod
381
381
  } else {
382
382
  if (latestActiveNode && (!isActiveNodeDeleted || isReplacedWithSameSize)) {
383
383
  const nodeDecAtActivePos = getDecorationAtPos(newState, decorations, latestActiveNode.pos, to);
384
- // Guard against rootPos being undefined (keyboard-triggered handles do not set it),
385
- // which would cause a RangeError in ProseMirror. When the gate is off, the original
386
- // behaviour is preserved for safe incremental rollout.
387
- const rootNodeDecAtActivePos = fg('platform_editor_block_menu_jira_patch_1') ? latestActiveNode.rootPos !== undefined ? getDecorationAtPos(newState, decorations, latestActiveNode.rootPos, to) : undefined : getDecorationAtPos(newState, decorations, latestActiveNode.rootPos, to);
384
+ const rootNodeDecAtActivePos = latestActiveNode.rootPos !== undefined ? getDecorationAtPos(newState, decorations, latestActiveNode.rootPos, to) : undefined;
388
385
  if (nodeDecAtActivePos || rootNodeDecAtActivePos) {
389
386
  isActiveNodeModified = true;
390
387
  }
@@ -1024,7 +1024,7 @@ export const DragHandle = ({
1024
1024
  css: [editorExperiment('platform_editor_controls', 'variant1') ? dragHandleButtonStyles : dragHandleButtonStylesOld, editorExperiment('platform_editor_controls', 'variant1') && dragHandleColor,
1025
1025
  // ED-26266: Fixed the drag handle highlight when selecting multiple line in Firefox
1026
1026
  // See https://product-fabric.atlassian.net/browse/ED-26266
1027
- browser.gecko && dragHandleMultiLineSelectionFixFirefox, editorExperiment('advanced_layouts', true) && isLayoutColumn && layoutColumnDragHandleStyles, dragHandleSelected && hasHadInteraction && selectedStyles, editorExperiment('platform_editor_preview_panel_responsiveness', true) && editorExperiment('platform_editor_controls', 'control') && dragHandleButtonSmallScreenStyles, editorExperiment('platform_editor_block_menu', true) && isFocused && keyboardFocusedDragHandleStyles, editorExperiment('platform_editor_block_menu', true) ? focusedStyles : focusedStylesOld, (expValEquals('confluence_compact_text_format', 'isEnabled', true) || expValEquals('cc_editor_ai_content_mode', 'variant', 'test') && fg('platform_editor_content_mode_button_mvp') || editorExperiment('platform_editor_block_menu', true) && fg('platform_editor_block_menu_jira_patch_1')) && dragHandleButtonScaledStyles],
1027
+ browser.gecko && dragHandleMultiLineSelectionFixFirefox, editorExperiment('advanced_layouts', true) && isLayoutColumn && layoutColumnDragHandleStyles, dragHandleSelected && hasHadInteraction && selectedStyles, editorExperiment('platform_editor_preview_panel_responsiveness', true) && editorExperiment('platform_editor_controls', 'control') && dragHandleButtonSmallScreenStyles, editorExperiment('platform_editor_block_menu', true) && isFocused && keyboardFocusedDragHandleStyles, editorExperiment('platform_editor_block_menu', true) ? focusedStyles : focusedStylesOld, (expValEquals('confluence_compact_text_format', 'isEnabled', true) || expValEquals('cc_editor_ai_content_mode', 'variant', 'test') && fg('platform_editor_content_mode_button_mvp') || editorExperiment('platform_editor_block_menu', true)) && dragHandleButtonScaledStyles],
1028
1028
  ref: buttonRef
1029
1029
  // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
1030
1030
  ,
@@ -384,10 +384,7 @@ var _apply = function apply(api, formatMessage, tr, currentState, newState, flag
384
384
  } else {
385
385
  if (latestActiveNode && (!isActiveNodeDeleted || isReplacedWithSameSize)) {
386
386
  var _nodeDecAtActivePos = getDecorationAtPos(newState, decorations, latestActiveNode.pos, to);
387
- // Guard against rootPos being undefined (keyboard-triggered handles do not set it),
388
- // which would cause a RangeError in ProseMirror. When the gate is off, the original
389
- // behaviour is preserved for safe incremental rollout.
390
- var rootNodeDecAtActivePos = fg('platform_editor_block_menu_jira_patch_1') ? latestActiveNode.rootPos !== undefined ? getDecorationAtPos(newState, decorations, latestActiveNode.rootPos, to) : undefined : getDecorationAtPos(newState, decorations, latestActiveNode.rootPos, to);
387
+ var rootNodeDecAtActivePos = latestActiveNode.rootPos !== undefined ? getDecorationAtPos(newState, decorations, latestActiveNode.rootPos, to) : undefined;
391
388
  if (_nodeDecAtActivePos || rootNodeDecAtActivePos) {
392
389
  isActiveNodeModified = true;
393
390
  }
@@ -1041,7 +1041,7 @@ export var DragHandle = function DragHandle(_ref) {
1041
1041
  css: [editorExperiment('platform_editor_controls', 'variant1') ? dragHandleButtonStyles : dragHandleButtonStylesOld, editorExperiment('platform_editor_controls', 'variant1') && dragHandleColor,
1042
1042
  // ED-26266: Fixed the drag handle highlight when selecting multiple line in Firefox
1043
1043
  // See https://product-fabric.atlassian.net/browse/ED-26266
1044
- browser.gecko && dragHandleMultiLineSelectionFixFirefox, editorExperiment('advanced_layouts', true) && isLayoutColumn && layoutColumnDragHandleStyles, dragHandleSelected && hasHadInteraction && selectedStyles, editorExperiment('platform_editor_preview_panel_responsiveness', true) && editorExperiment('platform_editor_controls', 'control') && dragHandleButtonSmallScreenStyles, editorExperiment('platform_editor_block_menu', true) && isFocused && keyboardFocusedDragHandleStyles, editorExperiment('platform_editor_block_menu', true) ? focusedStyles : focusedStylesOld, (expValEquals('confluence_compact_text_format', 'isEnabled', true) || expValEquals('cc_editor_ai_content_mode', 'variant', 'test') && fg('platform_editor_content_mode_button_mvp') || editorExperiment('platform_editor_block_menu', true) && fg('platform_editor_block_menu_jira_patch_1')) && dragHandleButtonScaledStyles],
1044
+ browser.gecko && dragHandleMultiLineSelectionFixFirefox, editorExperiment('advanced_layouts', true) && isLayoutColumn && layoutColumnDragHandleStyles, dragHandleSelected && hasHadInteraction && selectedStyles, editorExperiment('platform_editor_preview_panel_responsiveness', true) && editorExperiment('platform_editor_controls', 'control') && dragHandleButtonSmallScreenStyles, editorExperiment('platform_editor_block_menu', true) && isFocused && keyboardFocusedDragHandleStyles, editorExperiment('platform_editor_block_menu', true) ? focusedStyles : focusedStylesOld, (expValEquals('confluence_compact_text_format', 'isEnabled', true) || expValEquals('cc_editor_ai_content_mode', 'variant', 'test') && fg('platform_editor_content_mode_button_mvp') || editorExperiment('platform_editor_block_menu', true)) && dragHandleButtonScaledStyles],
1045
1045
  ref: buttonRef
1046
1046
  // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
1047
1047
  ,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-block-controls",
3
- "version": "13.1.0",
3
+ "version": "13.1.1",
4
4
  "description": "Block controls plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -48,7 +48,7 @@
48
48
  "@atlaskit/pragmatic-drag-and-drop-react-drop-indicator": "^4.0.0",
49
49
  "@atlaskit/primitives": "^20.0.0",
50
50
  "@atlaskit/theme": "^26.0.0",
51
- "@atlaskit/tmp-editor-statsig": "^111.0.0",
51
+ "@atlaskit/tmp-editor-statsig": "^112.0.0",
52
52
  "@atlaskit/tokens": "^15.0.0",
53
53
  "@atlaskit/tooltip": "^23.0.0",
54
54
  "@babel/runtime": "^7.0.0",
@@ -59,7 +59,7 @@
59
59
  "uuid": "^3.1.0"
60
60
  },
61
61
  "peerDependencies": {
62
- "@atlaskit/editor-common": "^116.11.0",
62
+ "@atlaskit/editor-common": "^116.12.0",
63
63
  "react": "^18.2.0",
64
64
  "react-dom": "^18.2.0",
65
65
  "react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
@@ -130,9 +130,6 @@
130
130
  "platform_editor_table_sticky_header_patch_6": {
131
131
  "type": "boolean"
132
132
  },
133
- "platform_editor_block_menu_jira_patch_1": {
134
- "type": "boolean"
135
- },
136
133
  "platform_editor_block_menu_jira_patch_2": {
137
134
  "type": "boolean"
138
135
  },