@atlaskit/editor-plugin-hyperlink 4.5.1 → 4.5.3

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-hyperlink
2
2
 
3
+ ## 4.5.3
4
+
5
+ ### Patch Changes
6
+
7
+ - [#173379](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/173379)
8
+ [`99e2b882f5cf0`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/99e2b882f5cf0) -
9
+ Clean up platform_editor_controls_patch_3
10
+ - Updated dependencies
11
+
12
+ ## 4.5.2
13
+
14
+ ### Patch Changes
15
+
16
+ - Updated dependencies
17
+
3
18
  ## 4.5.1
4
19
 
5
20
  ### Patch Changes
@@ -24,7 +24,6 @@ var _utils2 = require("@atlaskit/editor-prosemirror/utils");
24
24
  var _edit = _interopRequireDefault(require("@atlaskit/icon/core/edit"));
25
25
  var _linkBrokenEditorUnlink = _interopRequireDefault(require("@atlaskit/icon/core/migration/link-broken--editor-unlink"));
26
26
  var _linkExternalShortcut = _interopRequireDefault(require("@atlaskit/icon/core/migration/link-external--shortcut"));
27
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
28
27
  var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
29
28
  var _commands = require("../../editor-commands/commands");
30
29
  var _main = require("../../pm-plugins/main");
@@ -155,7 +154,7 @@ var getToolbarConfig = exports.getToolbarConfig = function getToolbarConfig(opti
155
154
  // getDomRef by default uses view.state.selection.from to position the toolbar.
156
155
  // However, when the user clicks in right after the link the view.state.selection.from references to the dom after the selection.
157
156
  // So instead we want to use the activeLinkMark.pos which has been calculated as the position before the click so that would be the link node
158
- getDomRef: activeLinkMark && (activeLinkMark.type === 'EDIT_INSERTED' || activeLinkMark.type === 'EDIT') && (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') && (0, _platformFeatureFlags.fg)('platform_editor_controls_patch_3') ? function (view) {
157
+ getDomRef: activeLinkMark && (activeLinkMark.type === 'EDIT_INSERTED' || activeLinkMark.type === 'EDIT') && (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') ? function (view) {
159
158
  var domRef = (0, _utils2.findDomRefAtPos)(activeLinkMark.pos, view.domAtPos.bind(view));
160
159
  return domRef instanceof HTMLElement ? domRef : undefined;
161
160
  } : undefined
@@ -13,7 +13,6 @@ import { findDomRefAtPos } from '@atlaskit/editor-prosemirror/utils';
13
13
  import EditIcon from '@atlaskit/icon/core/edit';
14
14
  import LinkBrokenIcon from '@atlaskit/icon/core/migration/link-broken--editor-unlink';
15
15
  import LinkExternalIcon from '@atlaskit/icon/core/migration/link-external--shortcut';
16
- import { fg } from '@atlaskit/platform-feature-flags';
17
16
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
18
17
  import { editInsertedLink, insertLinkWithAnalytics, onClickAwayCallback, onEscapeCallback, removeLink, updateLink } from '../../editor-commands/commands';
19
18
  import { stateKey } from '../../pm-plugins/main';
@@ -141,7 +140,7 @@ export const getToolbarConfig = (options, pluginInjectionApi) => (state, intl, p
141
140
  // getDomRef by default uses view.state.selection.from to position the toolbar.
142
141
  // However, when the user clicks in right after the link the view.state.selection.from references to the dom after the selection.
143
142
  // So instead we want to use the activeLinkMark.pos which has been calculated as the position before the click so that would be the link node
144
- getDomRef: activeLinkMark && (activeLinkMark.type === 'EDIT_INSERTED' || activeLinkMark.type === 'EDIT') && editorExperiment('platform_editor_controls', 'variant1') && fg('platform_editor_controls_patch_3') ? view => {
143
+ getDomRef: activeLinkMark && (activeLinkMark.type === 'EDIT_INSERTED' || activeLinkMark.type === 'EDIT') && editorExperiment('platform_editor_controls', 'variant1') ? view => {
145
144
  const domRef = findDomRefAtPos(activeLinkMark.pos, view.domAtPos.bind(view));
146
145
  return domRef instanceof HTMLElement ? domRef : undefined;
147
146
  } : undefined
@@ -17,7 +17,6 @@ import { findDomRefAtPos } from '@atlaskit/editor-prosemirror/utils';
17
17
  import EditIcon from '@atlaskit/icon/core/edit';
18
18
  import LinkBrokenIcon from '@atlaskit/icon/core/migration/link-broken--editor-unlink';
19
19
  import LinkExternalIcon from '@atlaskit/icon/core/migration/link-external--shortcut';
20
- import { fg } from '@atlaskit/platform-feature-flags';
21
20
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
22
21
  import { editInsertedLink, insertLinkWithAnalytics, onClickAwayCallback, onEscapeCallback, removeLink, updateLink } from '../../editor-commands/commands';
23
22
  import { stateKey } from '../../pm-plugins/main';
@@ -146,7 +145,7 @@ export var getToolbarConfig = function getToolbarConfig(options, pluginInjection
146
145
  // getDomRef by default uses view.state.selection.from to position the toolbar.
147
146
  // However, when the user clicks in right after the link the view.state.selection.from references to the dom after the selection.
148
147
  // So instead we want to use the activeLinkMark.pos which has been calculated as the position before the click so that would be the link node
149
- getDomRef: activeLinkMark && (activeLinkMark.type === 'EDIT_INSERTED' || activeLinkMark.type === 'EDIT') && editorExperiment('platform_editor_controls', 'variant1') && fg('platform_editor_controls_patch_3') ? function (view) {
148
+ getDomRef: activeLinkMark && (activeLinkMark.type === 'EDIT_INSERTED' || activeLinkMark.type === 'EDIT') && editorExperiment('platform_editor_controls', 'variant1') ? function (view) {
150
149
  var domRef = findDomRefAtPos(activeLinkMark.pos, view.domAtPos.bind(view));
151
150
  return domRef instanceof HTMLElement ? domRef : undefined;
152
151
  } : undefined
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-hyperlink",
3
- "version": "4.5.1",
3
+ "version": "4.5.3",
4
4
  "description": "Hyperlink plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -35,7 +35,7 @@
35
35
  "dependencies": {
36
36
  "@atlaskit/adf-schema": "^47.6.0",
37
37
  "@atlaskit/analytics-next": "^11.1.0",
38
- "@atlaskit/editor-common": "^106.9.0",
38
+ "@atlaskit/editor-common": "^107.0.0",
39
39
  "@atlaskit/editor-plugin-analytics": "^2.3.0",
40
40
  "@atlaskit/editor-plugin-card": "^6.6.0",
41
41
  "@atlaskit/editor-plugin-connectivity": "^2.0.0",
@@ -46,7 +46,7 @@
46
46
  "@atlaskit/icon": "^27.0.0",
47
47
  "@atlaskit/platform-feature-flags": "^1.1.0",
48
48
  "@atlaskit/prosemirror-input-rules": "^3.3.0",
49
- "@atlaskit/tmp-editor-statsig": "^7.1.0",
49
+ "@atlaskit/tmp-editor-statsig": "^7.2.0",
50
50
  "@babel/runtime": "^7.0.0",
51
51
  "@emotion/react": "^11.7.1",
52
52
  "uuid": "^3.1.0"
@@ -59,7 +59,7 @@
59
59
  "devDependencies": {
60
60
  "@atlaskit/activity-provider": "^2.5.0",
61
61
  "@atlaskit/link-test-helpers": "^8.0.0",
62
- "@atlaskit/media-test-helpers": "^36.1.0",
62
+ "@atlaskit/media-test-helpers": "^37.0.0",
63
63
  "@atlaskit/ssr": "workspace:^",
64
64
  "@atlaskit/util-data-test": "^18.0.0",
65
65
  "@atlaskit/visual-regression": "workspace:^",
@@ -107,9 +107,6 @@
107
107
  },
108
108
  "platform_editor_use_preferences_plugin": {
109
109
  "type": "boolean"
110
- },
111
- "platform_editor_controls_patch_3": {
112
- "type": "boolean"
113
110
  }
114
111
  }
115
112
  }