@atlaskit/editor-plugin-selection-marker 6.2.0 → 6.2.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-selection-marker
2
2
 
3
+ ## 6.2.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`a9d1ffcf3e2d0`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/a9d1ffcf3e2d0) -
8
+ EDITOR-2344: Should not hide selection marker based on AIFC flag.
9
+ - Updated dependencies
10
+
3
11
  ## 6.2.0
4
12
 
5
13
  ### Minor Changes
@@ -8,7 +8,6 @@ exports.selectionMarkerPlugin = void 0;
8
8
  var _react = _interopRequireWildcard(require("react"));
9
9
  var _hooks = require("@atlaskit/editor-common/hooks");
10
10
  var _useSharedPluginStateSelector = require("@atlaskit/editor-common/use-shared-plugin-state-selector");
11
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
12
11
  var _expValEqualsNoExposure = require("@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure");
13
12
  var _main = require("./pm-plugins/main");
14
13
  var _globalStyles = require("./ui/global-styles");
@@ -114,7 +113,7 @@ var selectionMarkerPlugin = exports.selectionMarkerPlugin = function selectionMa
114
113
  * - Via the API: If another plugin has requested it to be hidden (force hidden).
115
114
  * - If danger styles is shown in decorationsPlugin, then we don't need to show the selection marker
116
115
  */
117
- var shouldHide = (config === null || config === void 0 ? void 0 : config.hideCursorOnInit) && editorHasNotBeenFocused.current || hasFocus || (isOpen !== null && isOpen !== void 0 ? isOpen : false) || isForcedHidden || (editorDisabled !== null && editorDisabled !== void 0 ? editorDisabled : false) || (showToolbar !== null && showToolbar !== void 0 ? showToolbar : false) || (0, _platformFeatureFlags.fg)('aifc_create_enabled') || !!hasDangerDecorations && (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_block_menu', 'isEnabled', true) && (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_block_menu_keyboard_navigation', 'isEnabled', true);
116
+ var shouldHide = (config === null || config === void 0 ? void 0 : config.hideCursorOnInit) && editorHasNotBeenFocused.current || hasFocus || (isOpen !== null && isOpen !== void 0 ? isOpen : false) || isForcedHidden || (editorDisabled !== null && editorDisabled !== void 0 ? editorDisabled : false) || (showToolbar !== null && showToolbar !== void 0 ? showToolbar : false) || !!hasDangerDecorations && (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_block_menu', 'isEnabled', true) && (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_block_menu_keyboard_navigation', 'isEnabled', true);
118
117
  requestAnimationFrame(function () {
119
118
  return (0, _main.dispatchShouldHideDecorations)(editorView, shouldHide);
120
119
  });
@@ -1,7 +1,6 @@
1
1
  import React, { useEffect, useRef } from 'react';
2
2
  import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
3
3
  import { useSharedPluginStateSelector } from '@atlaskit/editor-common/use-shared-plugin-state-selector';
4
- import { fg } from '@atlaskit/platform-feature-flags';
5
4
  import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
6
5
  import { createPlugin, dispatchShouldHideDecorations, key } from './pm-plugins/main';
7
6
  import { GlobalStylesWrapper } from './ui/global-styles';
@@ -107,7 +106,7 @@ export const selectionMarkerPlugin = ({
107
106
  * - Via the API: If another plugin has requested it to be hidden (force hidden).
108
107
  * - If danger styles is shown in decorationsPlugin, then we don't need to show the selection marker
109
108
  */
110
- const shouldHide = (config === null || config === void 0 ? void 0 : config.hideCursorOnInit) && editorHasNotBeenFocused.current || hasFocus || (isOpen !== null && isOpen !== void 0 ? isOpen : false) || isForcedHidden || (editorDisabled !== null && editorDisabled !== void 0 ? editorDisabled : false) || (showToolbar !== null && showToolbar !== void 0 ? showToolbar : false) || fg('aifc_create_enabled') || !!hasDangerDecorations && expValEqualsNoExposure('platform_editor_block_menu', 'isEnabled', true) && expValEqualsNoExposure('platform_editor_block_menu_keyboard_navigation', 'isEnabled', true);
109
+ const shouldHide = (config === null || config === void 0 ? void 0 : config.hideCursorOnInit) && editorHasNotBeenFocused.current || hasFocus || (isOpen !== null && isOpen !== void 0 ? isOpen : false) || isForcedHidden || (editorDisabled !== null && editorDisabled !== void 0 ? editorDisabled : false) || (showToolbar !== null && showToolbar !== void 0 ? showToolbar : false) || !!hasDangerDecorations && expValEqualsNoExposure('platform_editor_block_menu', 'isEnabled', true) && expValEqualsNoExposure('platform_editor_block_menu_keyboard_navigation', 'isEnabled', true);
111
110
  requestAnimationFrame(() => dispatchShouldHideDecorations(editorView, shouldHide));
112
111
  }, [editorView, hasFocus, isOpen, isForcedHidden, editorDisabled, showToolbar, hasDangerDecorations]);
113
112
  },
@@ -1,7 +1,6 @@
1
1
  import React, { useEffect, useRef } from 'react';
2
2
  import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
3
3
  import { useSharedPluginStateSelector } from '@atlaskit/editor-common/use-shared-plugin-state-selector';
4
- import { fg } from '@atlaskit/platform-feature-flags';
5
4
  import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
6
5
  import { createPlugin, dispatchShouldHideDecorations, key } from './pm-plugins/main';
7
6
  import { GlobalStylesWrapper } from './ui/global-styles';
@@ -106,7 +105,7 @@ export var selectionMarkerPlugin = function selectionMarkerPlugin(_ref) {
106
105
  * - Via the API: If another plugin has requested it to be hidden (force hidden).
107
106
  * - If danger styles is shown in decorationsPlugin, then we don't need to show the selection marker
108
107
  */
109
- var shouldHide = (config === null || config === void 0 ? void 0 : config.hideCursorOnInit) && editorHasNotBeenFocused.current || hasFocus || (isOpen !== null && isOpen !== void 0 ? isOpen : false) || isForcedHidden || (editorDisabled !== null && editorDisabled !== void 0 ? editorDisabled : false) || (showToolbar !== null && showToolbar !== void 0 ? showToolbar : false) || fg('aifc_create_enabled') || !!hasDangerDecorations && expValEqualsNoExposure('platform_editor_block_menu', 'isEnabled', true) && expValEqualsNoExposure('platform_editor_block_menu_keyboard_navigation', 'isEnabled', true);
108
+ var shouldHide = (config === null || config === void 0 ? void 0 : config.hideCursorOnInit) && editorHasNotBeenFocused.current || hasFocus || (isOpen !== null && isOpen !== void 0 ? isOpen : false) || isForcedHidden || (editorDisabled !== null && editorDisabled !== void 0 ? editorDisabled : false) || (showToolbar !== null && showToolbar !== void 0 ? showToolbar : false) || !!hasDangerDecorations && expValEqualsNoExposure('platform_editor_block_menu', 'isEnabled', true) && expValEqualsNoExposure('platform_editor_block_menu_keyboard_navigation', 'isEnabled', true);
110
109
  requestAnimationFrame(function () {
111
110
  return dispatchShouldHideDecorations(editorView, shouldHide);
112
111
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-selection-marker",
3
- "version": "6.2.0",
3
+ "version": "6.2.1",
4
4
  "description": "Selection marker plugin for @atlaskit/editor-core.",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -29,23 +29,23 @@
29
29
  "atlaskit:src": "src/index.ts",
30
30
  "dependencies": {
31
31
  "@atlaskit/editor-plugin-decorations": "^6.1.0",
32
- "@atlaskit/editor-plugin-editor-disabled": "^6.0.0",
32
+ "@atlaskit/editor-plugin-editor-disabled": "^6.1.0",
33
33
  "@atlaskit/editor-plugin-focus": "^5.0.0",
34
- "@atlaskit/editor-plugin-toolbar": "^3.0.0",
35
- "@atlaskit/editor-plugin-type-ahead": "^6.1.0",
34
+ "@atlaskit/editor-plugin-toolbar": "^3.2.0",
35
+ "@atlaskit/editor-plugin-type-ahead": "^6.4.0",
36
36
  "@atlaskit/editor-prosemirror": "7.0.0",
37
37
  "@atlaskit/link": "^3.2.0",
38
38
  "@atlaskit/platform-feature-flags": "^1.1.0",
39
39
  "@atlaskit/primitives": "^14.15.0",
40
40
  "@atlaskit/theme": "^21.0.0",
41
- "@atlaskit/tmp-editor-statsig": "^13.1.0",
41
+ "@atlaskit/tmp-editor-statsig": "^13.10.0",
42
42
  "@atlaskit/tokens": "^6.4.0",
43
43
  "@babel/runtime": "^7.0.0",
44
44
  "@emotion/react": "^11.7.1",
45
45
  "lodash": "^4.17.21"
46
46
  },
47
47
  "peerDependencies": {
48
- "@atlaskit/editor-common": "^110.4.0",
48
+ "@atlaskit/editor-common": "^110.11.0",
49
49
  "react": "^18.2.0",
50
50
  "react-dom": "^18.2.0"
51
51
  },
@@ -98,9 +98,6 @@
98
98
  },
99
99
  "platform_editor_inline_selection_marker_cursor": {
100
100
  "type": "boolean"
101
- },
102
- "aifc_create_enabled": {
103
- "type": "boolean"
104
101
  }
105
102
  }
106
103
  }