@atlaskit/editor-plugin-selection 8.0.5 → 8.0.7

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,20 @@
1
1
  # @atlaskit/editor-plugin-selection
2
2
 
3
+ ## 8.0.7
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 8.0.6
10
+
11
+ ### Patch Changes
12
+
13
+ - [`ba5257de9a045`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/ba5257de9a045) -
14
+ Removed feature flag platform_editor_paste_before_first_block_node for solved editor paste bug
15
+ before certain block nodes.
16
+ - Updated dependencies
17
+
3
18
  ## 8.0.5
4
19
 
5
20
  ### Patch Changes
@@ -10,7 +10,6 @@ var _state = require("@atlaskit/editor-prosemirror/state");
10
10
  var _utils = require("@atlaskit/editor-prosemirror/utils");
11
11
  var _view2 = require("@atlaskit/editor-prosemirror/view");
12
12
  var _cellSelection = require("@atlaskit/editor-tables/cell-selection");
13
- var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
14
13
  var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
15
14
  var _types = require("../types");
16
15
  var _gapCursorPluginKey = require("./gap-cursor-plugin-key");
@@ -103,7 +102,7 @@ var plugin = new _safePlugin.SafePlugin({
103
102
  return _view2.DecorationSet.create(doc, [_view2.Decoration.widget(position, _placeGapCursor.toDOM, {
104
103
  key: "".concat(_selection.JSON_ID, "-").concat(side, "-").concat(layoutMode),
105
104
  // position === 0: if gap cursor at start of document, render it on the left side of the selection to enable pasting (otherwise Chrome doesn't pick up the paste event)
106
- side: layoutMode || position === 0 && (0, _expValEquals.expValEquals)('platform_editor_paste_before_first_block_node', 'isEnabled', true) ? -1 : 0
105
+ side: layoutMode || position === 0 ? -1 : 0
107
106
  })]);
108
107
  }
109
108
  return null;
@@ -4,7 +4,6 @@ import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
4
4
  import { findPositionOfNodeBefore } from '@atlaskit/editor-prosemirror/utils';
5
5
  import { Decoration, DecorationSet } from '@atlaskit/editor-prosemirror/view';
6
6
  import { CellSelection } from '@atlaskit/editor-tables/cell-selection';
7
- import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
8
7
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
9
8
  import { selectionPluginKey } from '../types';
10
9
  import { gapCursorPluginKey } from './gap-cursor-plugin-key';
@@ -101,7 +100,7 @@ const plugin = new SafePlugin({
101
100
  return DecorationSet.create(doc, [Decoration.widget(position, toDOM, {
102
101
  key: `${JSON_ID}-${side}-${layoutMode}`,
103
102
  // position === 0: if gap cursor at start of document, render it on the left side of the selection to enable pasting (otherwise Chrome doesn't pick up the paste event)
104
- side: layoutMode || position === 0 && expValEquals('platform_editor_paste_before_first_block_node', 'isEnabled', true) ? -1 : 0
103
+ side: layoutMode || position === 0 ? -1 : 0
105
104
  })]);
106
105
  }
107
106
  return null;
@@ -4,7 +4,6 @@ import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
4
4
  import { findPositionOfNodeBefore } from '@atlaskit/editor-prosemirror/utils';
5
5
  import { Decoration, DecorationSet } from '@atlaskit/editor-prosemirror/view';
6
6
  import { CellSelection } from '@atlaskit/editor-tables/cell-selection';
7
- import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
8
7
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
9
8
  import { selectionPluginKey } from '../types';
10
9
  import { gapCursorPluginKey } from './gap-cursor-plugin-key';
@@ -97,7 +96,7 @@ var plugin = new SafePlugin({
97
96
  return DecorationSet.create(doc, [Decoration.widget(position, toDOM, {
98
97
  key: "".concat(JSON_ID, "-").concat(side, "-").concat(layoutMode),
99
98
  // position === 0: if gap cursor at start of document, render it on the left side of the selection to enable pasting (otherwise Chrome doesn't pick up the paste event)
100
- side: layoutMode || position === 0 && expValEquals('platform_editor_paste_before_first_block_node', 'isEnabled', true) ? -1 : 0
99
+ side: layoutMode || position === 0 ? -1 : 0
101
100
  })]);
102
101
  }
103
102
  return null;
@@ -1,8 +1,8 @@
1
1
  import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
2
2
  type GapCursorPluginState = {
3
- selectionIsGapCursor: boolean;
4
3
  displayGapCursor: boolean;
5
4
  hideCursor: boolean;
5
+ selectionIsGapCursor: boolean;
6
6
  };
7
7
  declare const plugin: SafePlugin<GapCursorPluginState>;
8
8
  export default plugin;
@@ -1,8 +1,8 @@
1
1
  import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
2
2
  type GapCursorPluginState = {
3
- selectionIsGapCursor: boolean;
4
3
  displayGapCursor: boolean;
5
4
  hideCursor: boolean;
5
+ selectionIsGapCursor: boolean;
6
6
  };
7
7
  declare const plugin: SafePlugin<GapCursorPluginState>;
8
8
  export default plugin;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-selection",
3
- "version": "8.0.5",
3
+ "version": "8.0.7",
4
4
  "description": "Selection plugin for @atlaskit/editor-core",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -25,12 +25,12 @@
25
25
  "@atlaskit/editor-shared-styles": "^3.10.0",
26
26
  "@atlaskit/editor-tables": "^2.9.0",
27
27
  "@atlaskit/platform-feature-flags": "^1.1.0",
28
- "@atlaskit/tmp-editor-statsig": "^40.0.0",
28
+ "@atlaskit/tmp-editor-statsig": "^42.0.0",
29
29
  "@atlaskit/tokens": "^11.1.0",
30
30
  "@babel/runtime": "^7.0.0"
31
31
  },
32
32
  "peerDependencies": {
33
- "@atlaskit/editor-common": "^112.4.0",
33
+ "@atlaskit/editor-common": "^112.7.0",
34
34
  "react": "^18.2.0"
35
35
  },
36
36
  "techstack": {