@atlaskit/editor-plugin-block-controls 12.3.6 → 12.4.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,22 @@
1
1
  # @atlaskit/editor-plugin-block-controls
2
2
 
3
+ ## 12.4.1
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 12.4.0
10
+
11
+ ### Minor Changes
12
+
13
+ - [`a3a227e567efe`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/a3a227e567efe) -
14
+ [ux] [EDITOR-7662] disabled block controls when viewing diffs
15
+
16
+ ### Patch Changes
17
+
18
+ - Updated dependencies
19
+
3
20
  ## 12.3.6
4
21
 
5
22
  ### Patch Changes
@@ -13,6 +13,7 @@ var _react2 = require("@emotion/react");
13
13
  var _hooks = require("@atlaskit/editor-common/hooks");
14
14
  var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
15
15
  var _primitives = require("@atlaskit/primitives");
16
+ var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
16
17
  var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
17
18
  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); }
18
19
  /**
@@ -87,7 +88,7 @@ var VisibilityContainer = exports.VisibilityContainer = function VisibilityConta
87
88
  // When forceVisibleOnMouseOut is true (e.g. drag handle focused via keyboard Shift+Ctrl+H),
88
89
  // override the mouse-out condition so the control stays visible regardless of mouse position.
89
90
  var shouldHideWhenMouseOut = forceVisibleOnMouseOut ? false : hideOnMouseOut;
90
- var shouldHideImmediate = isTypeAheadOpen || isEditing || shouldHideWhenMouseOut || userIntent === 'aiStreaming' || sideHidden;
91
+ var shouldHideImmediate = isTypeAheadOpen || isEditing || shouldHideWhenMouseOut || userIntent === 'aiStreaming' || userIntent === 'viewingDiff' && (0, _expValEquals.expValEquals)('platform_editor_diff_plugin_extended', 'isEnabled', true) || sideHidden;
91
92
 
92
93
  // Delay hiding the right control in view mode to reduce flickering when moving from block
93
94
  // toward the right-edge button (avoids rapid show/hide as mouse crosses boundaries).
@@ -10,6 +10,7 @@ import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks'
10
10
  import { akEditorFullPageNarrowBreakout } from '@atlaskit/editor-shared-styles';
11
11
  // eslint-disable-next-line @atlaskit/design-system/no-emotion-primitives -- to be migrated to @atlaskit/primitives/compiled – go/akcss
12
12
  import { Box, xcss } from '@atlaskit/primitives';
13
+ import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
13
14
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
14
15
  const RIGHT_CONTROL_HIDE_DELAY_MS = 150;
15
16
  const baseStyles = xcss({
@@ -78,7 +79,7 @@ export const VisibilityContainer = ({
78
79
  // When forceVisibleOnMouseOut is true (e.g. drag handle focused via keyboard Shift+Ctrl+H),
79
80
  // override the mouse-out condition so the control stays visible regardless of mouse position.
80
81
  const shouldHideWhenMouseOut = forceVisibleOnMouseOut ? false : hideOnMouseOut;
81
- const shouldHideImmediate = isTypeAheadOpen || isEditing || shouldHideWhenMouseOut || userIntent === 'aiStreaming' || sideHidden;
82
+ const shouldHideImmediate = isTypeAheadOpen || isEditing || shouldHideWhenMouseOut || userIntent === 'aiStreaming' || userIntent === 'viewingDiff' && expValEquals('platform_editor_diff_plugin_extended', 'isEnabled', true) || sideHidden;
82
83
 
83
84
  // Delay hiding the right control in view mode to reduce flickering when moving from block
84
85
  // toward the right-edge button (avoids rapid show/hide as mouse crosses boundaries).
@@ -12,6 +12,7 @@ import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks'
12
12
  import { akEditorFullPageNarrowBreakout } from '@atlaskit/editor-shared-styles';
13
13
  // eslint-disable-next-line @atlaskit/design-system/no-emotion-primitives -- to be migrated to @atlaskit/primitives/compiled – go/akcss
14
14
  import { Box, xcss } from '@atlaskit/primitives';
15
+ import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
15
16
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
16
17
  var RIGHT_CONTROL_HIDE_DELAY_MS = 150;
17
18
  var baseStyles = xcss({
@@ -76,7 +77,7 @@ export var VisibilityContainer = function VisibilityContainer(_ref) {
76
77
  // When forceVisibleOnMouseOut is true (e.g. drag handle focused via keyboard Shift+Ctrl+H),
77
78
  // override the mouse-out condition so the control stays visible regardless of mouse position.
78
79
  var shouldHideWhenMouseOut = forceVisibleOnMouseOut ? false : hideOnMouseOut;
79
- var shouldHideImmediate = isTypeAheadOpen || isEditing || shouldHideWhenMouseOut || userIntent === 'aiStreaming' || sideHidden;
80
+ var shouldHideImmediate = isTypeAheadOpen || isEditing || shouldHideWhenMouseOut || userIntent === 'aiStreaming' || userIntent === 'viewingDiff' && expValEquals('platform_editor_diff_plugin_extended', 'isEnabled', true) || sideHidden;
80
81
 
81
82
  // Delay hiding the right control in view mode to reduce flickering when moving from block
82
83
  // toward the right-edge button (avoids rapid show/hide as mouse crosses boundaries).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-block-controls",
3
- "version": "12.3.6",
3
+ "version": "12.4.1",
4
4
  "description": "Block controls plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -42,13 +42,13 @@
42
42
  "@atlaskit/editor-plugin-selection": "^11.0.0",
43
43
  "@atlaskit/editor-plugin-toolbar": "^8.0.0",
44
44
  "@atlaskit/editor-plugin-type-ahead": "^11.3.0",
45
- "@atlaskit/editor-plugin-user-intent": "^9.0.0",
45
+ "@atlaskit/editor-plugin-user-intent": "^9.1.0",
46
46
  "@atlaskit/editor-plugin-width": "^12.0.0",
47
47
  "@atlaskit/editor-prosemirror": "^7.3.0",
48
48
  "@atlaskit/editor-shared-styles": "^3.11.0",
49
49
  "@atlaskit/editor-tables": "^2.10.0",
50
50
  "@atlaskit/icon": "^35.4.0",
51
- "@atlaskit/icon-lab": "^6.13.0",
51
+ "@atlaskit/icon-lab": "^6.14.0",
52
52
  "@atlaskit/link": "^3.4.0",
53
53
  "@atlaskit/platform-feature-flags": "^1.1.0",
54
54
  "@atlaskit/pragmatic-drag-and-drop": "^1.8.0",
@@ -56,7 +56,7 @@
56
56
  "@atlaskit/pragmatic-drag-and-drop-react-drop-indicator": "^3.2.0",
57
57
  "@atlaskit/primitives": "^19.0.0",
58
58
  "@atlaskit/theme": "^25.0.0",
59
- "@atlaskit/tmp-editor-statsig": "^100.0.0",
59
+ "@atlaskit/tmp-editor-statsig": "^102.0.0",
60
60
  "@atlaskit/tokens": "^13.4.0",
61
61
  "@atlaskit/tooltip": "^22.6.0",
62
62
  "@babel/runtime": "^7.0.0",