@atlaskit/editor-plugin-analytics 11.0.16 → 12.0.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,39 @@
1
1
  # @atlaskit/editor-plugin-analytics
2
2
 
3
+ ## 12.0.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`5331d96345ae9`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/5331d96345ae9) -
8
+ Clean up stale experiment platform_editor_insert_location_check
9
+ - Updated dependencies
10
+
11
+ ## 12.0.0
12
+
13
+ ### Major Changes
14
+
15
+ - [`f2dc9097319f0`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/f2dc9097319f0) - ###
16
+ Dropped support for _legacy_ Typescript 4 types. **Typescript 5 is now the new minimum**.
17
+
18
+ Removes the `typesVersions` property and `dist/types-ts4.5` directory from the dist.
19
+
20
+ Types are now exclusively via the `"types": "dist/types/index.d.ts"` property.
21
+
22
+ ```diff
23
+ - "typesVersions": {
24
+ - ">=4.5 <4.9": {
25
+ - "*": [
26
+ - "dist/types-ts4.5/*",
27
+ - "dist/types-ts4.5/index.d.ts"
28
+ - ]
29
+ - }
30
+ - },
31
+ ```
32
+
33
+ ### Patch Changes
34
+
35
+ - Updated dependencies
36
+
3
37
  ## 11.0.16
4
38
 
5
39
  ### Patch Changes
@@ -10,7 +10,6 @@ var _analytics2 = require("@atlaskit/editor-common/utils/analytics");
10
10
  var _state = require("@atlaskit/editor-prosemirror/state");
11
11
  var _utils = require("@atlaskit/editor-prosemirror/utils");
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
  function getSelectionType(selection) {
16
15
  var _selection$constructo;
@@ -57,10 +56,8 @@ function findInsertedLocation(oldSelection, newSelection, tr) {
57
56
  return node.type !== paragraph;
58
57
  })(oldSelection);
59
58
  var pos = (insertLocationInfo === null || insertLocationInfo === void 0 ? void 0 : insertLocationInfo.start) || 0;
60
- if ((0, _expValEquals.expValEquals)('platform_editor_insert_location_check', 'isEnabled', true)) {
61
- // Map the old document position through the transaction's steps
62
- pos = tr.mapping.map(pos);
63
- }
59
+ // Map the old document position through the transaction's steps
60
+ pos = tr.mapping.map(pos);
64
61
  var parentNodePos = newDoc.resolve(pos);
65
62
 
66
63
  // Keep going one level above the attempted insert position till we find a node that contains the current cursor position in it's range
@@ -3,7 +3,6 @@ import { findInsertLocation } from '@atlaskit/editor-common/utils/analytics';
3
3
  import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
4
4
  import { findParentNode, findParentNodeOfType } from '@atlaskit/editor-prosemirror/utils';
5
5
  import { CellSelection } from '@atlaskit/editor-tables/cell-selection';
6
- import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
7
6
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
8
7
  export function getSelectionType(selection) {
9
8
  var _selection$constructo;
@@ -55,10 +54,8 @@ function findInsertedLocation(oldSelection, newSelection, tr) {
55
54
  const newDoc = newSelection.$from.doc;
56
55
  const insertLocationInfo = findParentNode(node => node.type !== paragraph)(oldSelection);
57
56
  let pos = (insertLocationInfo === null || insertLocationInfo === void 0 ? void 0 : insertLocationInfo.start) || 0;
58
- if (expValEquals('platform_editor_insert_location_check', 'isEnabled', true)) {
59
- // Map the old document position through the transaction's steps
60
- pos = tr.mapping.map(pos);
61
- }
57
+ // Map the old document position through the transaction's steps
58
+ pos = tr.mapping.map(pos);
62
59
  let parentNodePos = newDoc.resolve(pos);
63
60
 
64
61
  // Keep going one level above the attempted insert position till we find a node that contains the current cursor position in it's range
@@ -3,7 +3,6 @@ import { findInsertLocation } from '@atlaskit/editor-common/utils/analytics';
3
3
  import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
4
4
  import { findParentNode, findParentNodeOfType } from '@atlaskit/editor-prosemirror/utils';
5
5
  import { CellSelection } from '@atlaskit/editor-tables/cell-selection';
6
- import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
7
6
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
8
7
  export function getSelectionType(selection) {
9
8
  var _selection$constructo;
@@ -50,10 +49,8 @@ function findInsertedLocation(oldSelection, newSelection, tr) {
50
49
  return node.type !== paragraph;
51
50
  })(oldSelection);
52
51
  var pos = (insertLocationInfo === null || insertLocationInfo === void 0 ? void 0 : insertLocationInfo.start) || 0;
53
- if (expValEquals('platform_editor_insert_location_check', 'isEnabled', true)) {
54
- // Map the old document position through the transaction's steps
55
- pos = tr.mapping.map(pos);
56
- }
52
+ // Map the old document position through the transaction's steps
53
+ pos = tr.mapping.map(pos);
57
54
  var parentNodePos = newDoc.resolve(pos);
58
55
 
59
56
  // Keep going one level above the attempted insert position till we find a node that contains the current cursor position in it's range
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-analytics",
3
- "version": "11.0.16",
3
+ "version": "12.0.1",
4
4
  "description": "Analytics plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -16,29 +16,21 @@
16
16
  "module": "dist/esm/index.js",
17
17
  "module:es2019": "dist/es2019/index.js",
18
18
  "types": "dist/types/index.d.ts",
19
- "typesVersions": {
20
- ">=4.5 <4.9": {
21
- "*": [
22
- "dist/types-ts4.5/*",
23
- "dist/types-ts4.5/index.d.ts"
24
- ]
25
- }
26
- },
27
19
  "sideEffects": false,
28
20
  "atlaskit:src": "src/index.ts",
29
21
  "dependencies": {
30
- "@atlaskit/adf-schema": "^54.0.0",
31
- "@atlaskit/analytics-listeners": "^10.1.0",
32
- "@atlaskit/analytics-next": "^11.3.0",
33
- "@atlaskit/editor-plugin-feature-flags": "^10.0.0",
34
- "@atlaskit/editor-prosemirror": "^7.3.0",
35
- "@atlaskit/editor-tables": "^2.10.0",
36
- "@atlaskit/platform-feature-flags": "^1.1.0",
37
- "@atlaskit/tmp-editor-statsig": "^103.0.0",
22
+ "@atlaskit/adf-schema": "^55.0.0",
23
+ "@atlaskit/analytics-listeners": "^11.0.0",
24
+ "@atlaskit/analytics-next": "^12.0.0",
25
+ "@atlaskit/editor-plugin-feature-flags": "^11.0.0",
26
+ "@atlaskit/editor-prosemirror": "^8.0.0",
27
+ "@atlaskit/editor-tables": "^3.0.0",
28
+ "@atlaskit/platform-feature-flags": "^2.0.0",
29
+ "@atlaskit/tmp-editor-statsig": "^105.0.0",
38
30
  "@babel/runtime": "^7.0.0"
39
31
  },
40
32
  "peerDependencies": {
41
- "@atlaskit/editor-common": "^115.15.0",
33
+ "@atlaskit/editor-common": "^116.1.0",
42
34
  "react": "^18.2.0"
43
35
  },
44
36
  "techstack": {