@atlaskit/editor-plugin-hyperlink 12.1.4 → 12.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,23 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-hyperlink
|
|
2
2
|
|
|
3
|
+
## 12.2.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 12.2.0
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- [`3990f4a500c27`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/3990f4a500c27) -
|
|
14
|
+
Fix RovoLinkPicker rendering off-screen by using correct dimensions for popup placement
|
|
15
|
+
calculations
|
|
16
|
+
|
|
17
|
+
### Patch Changes
|
|
18
|
+
|
|
19
|
+
- Updated dependencies
|
|
20
|
+
|
|
3
21
|
## 12.1.4
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
|
@@ -241,6 +241,7 @@ var getToolbarConfig = exports.getToolbarConfig = function getToolbarConfig(opti
|
|
|
241
241
|
case 'EDIT_INSERTED':
|
|
242
242
|
case 'INSERT':
|
|
243
243
|
{
|
|
244
|
+
var _options$linkPicker$p, _options$linkPicker, _options$linkPicker$p2, _options$linkPicker2;
|
|
244
245
|
var _link;
|
|
245
246
|
if (isEditLink(activeLinkMark) && activeLinkMark.node) {
|
|
246
247
|
var _linkMark = activeLinkMark.node.marks.filter(function (mark) {
|
|
@@ -249,11 +250,8 @@ var getToolbarConfig = exports.getToolbarConfig = function getToolbarConfig(opti
|
|
|
249
250
|
_link = _linkMark[0] && _linkMark[0].attrs.href;
|
|
250
251
|
}
|
|
251
252
|
var displayText = isEditLink(activeLinkMark) ? getLinkText(activeLinkMark, state) : linkState.activeText;
|
|
252
|
-
var popupHeight = lpLinkPicker ? _ui.LINKPICKER_HEIGHT_IN_PX : _ui.RECENT_SEARCH_HEIGHT_IN_PX;
|
|
253
|
-
|
|
254
|
-
// Removing popupWidth to ensure that we the popup always positions setting positon left instead of flipping to position right
|
|
255
|
-
// inside of a narrow space like Preview panel
|
|
256
|
-
var popupWidth = !lpLinkPicker ? undefined : _ui.RECENT_SEARCH_WIDTH_IN_PX;
|
|
253
|
+
var popupHeight = (_options$linkPicker$p = options === null || options === void 0 || (_options$linkPicker = options.linkPicker) === null || _options$linkPicker === void 0 ? void 0 : _options$linkPicker.popupHeight) !== null && _options$linkPicker$p !== void 0 ? _options$linkPicker$p : lpLinkPicker ? _ui.LINKPICKER_HEIGHT_IN_PX : _ui.RECENT_SEARCH_HEIGHT_IN_PX;
|
|
254
|
+
var popupWidth = (_options$linkPicker$p2 = options === null || options === void 0 || (_options$linkPicker2 = options.linkPicker) === null || _options$linkPicker2 === void 0 ? void 0 : _options$linkPicker2.popupWidth) !== null && _options$linkPicker$p2 !== void 0 ? _options$linkPicker$p2 : !lpLinkPicker ? undefined : _ui.RECENT_SEARCH_WIDTH_IN_PX;
|
|
257
255
|
return _objectSpread(_objectSpread({}, hyperLinkToolbar), {}, {
|
|
258
256
|
preventPopupOverflow: true,
|
|
259
257
|
height: popupHeight,
|
|
@@ -227,17 +227,15 @@ export const getToolbarConfig = (options, pluginInjectionApi) => (state, intl, p
|
|
|
227
227
|
case 'EDIT_INSERTED':
|
|
228
228
|
case 'INSERT':
|
|
229
229
|
{
|
|
230
|
+
var _options$linkPicker$p, _options$linkPicker, _options$linkPicker$p2, _options$linkPicker2;
|
|
230
231
|
let link;
|
|
231
232
|
if (isEditLink(activeLinkMark) && activeLinkMark.node) {
|
|
232
233
|
const linkMark = activeLinkMark.node.marks.filter(mark => mark.type === state.schema.marks.link);
|
|
233
234
|
link = linkMark[0] && linkMark[0].attrs.href;
|
|
234
235
|
}
|
|
235
236
|
const displayText = isEditLink(activeLinkMark) ? getLinkText(activeLinkMark, state) : linkState.activeText;
|
|
236
|
-
const popupHeight = lpLinkPicker ? LINKPICKER_HEIGHT_IN_PX : RECENT_SEARCH_HEIGHT_IN_PX;
|
|
237
|
-
|
|
238
|
-
// Removing popupWidth to ensure that we the popup always positions setting positon left instead of flipping to position right
|
|
239
|
-
// inside of a narrow space like Preview panel
|
|
240
|
-
const popupWidth = !lpLinkPicker ? undefined : RECENT_SEARCH_WIDTH_IN_PX;
|
|
237
|
+
const popupHeight = (_options$linkPicker$p = options === null || options === void 0 ? void 0 : (_options$linkPicker = options.linkPicker) === null || _options$linkPicker === void 0 ? void 0 : _options$linkPicker.popupHeight) !== null && _options$linkPicker$p !== void 0 ? _options$linkPicker$p : lpLinkPicker ? LINKPICKER_HEIGHT_IN_PX : RECENT_SEARCH_HEIGHT_IN_PX;
|
|
238
|
+
const popupWidth = (_options$linkPicker$p2 = options === null || options === void 0 ? void 0 : (_options$linkPicker2 = options.linkPicker) === null || _options$linkPicker2 === void 0 ? void 0 : _options$linkPicker2.popupWidth) !== null && _options$linkPicker$p2 !== void 0 ? _options$linkPicker$p2 : !lpLinkPicker ? undefined : RECENT_SEARCH_WIDTH_IN_PX;
|
|
241
239
|
return {
|
|
242
240
|
...hyperLinkToolbar,
|
|
243
241
|
preventPopupOverflow: true,
|
|
@@ -232,6 +232,7 @@ export var getToolbarConfig = function getToolbarConfig(options, pluginInjection
|
|
|
232
232
|
case 'EDIT_INSERTED':
|
|
233
233
|
case 'INSERT':
|
|
234
234
|
{
|
|
235
|
+
var _options$linkPicker$p, _options$linkPicker, _options$linkPicker$p2, _options$linkPicker2;
|
|
235
236
|
var _link;
|
|
236
237
|
if (isEditLink(activeLinkMark) && activeLinkMark.node) {
|
|
237
238
|
var _linkMark = activeLinkMark.node.marks.filter(function (mark) {
|
|
@@ -240,11 +241,8 @@ export var getToolbarConfig = function getToolbarConfig(options, pluginInjection
|
|
|
240
241
|
_link = _linkMark[0] && _linkMark[0].attrs.href;
|
|
241
242
|
}
|
|
242
243
|
var displayText = isEditLink(activeLinkMark) ? getLinkText(activeLinkMark, state) : linkState.activeText;
|
|
243
|
-
var popupHeight = lpLinkPicker ? LINKPICKER_HEIGHT_IN_PX : RECENT_SEARCH_HEIGHT_IN_PX;
|
|
244
|
-
|
|
245
|
-
// Removing popupWidth to ensure that we the popup always positions setting positon left instead of flipping to position right
|
|
246
|
-
// inside of a narrow space like Preview panel
|
|
247
|
-
var popupWidth = !lpLinkPicker ? undefined : RECENT_SEARCH_WIDTH_IN_PX;
|
|
244
|
+
var popupHeight = (_options$linkPicker$p = options === null || options === void 0 || (_options$linkPicker = options.linkPicker) === null || _options$linkPicker === void 0 ? void 0 : _options$linkPicker.popupHeight) !== null && _options$linkPicker$p !== void 0 ? _options$linkPicker$p : lpLinkPicker ? LINKPICKER_HEIGHT_IN_PX : RECENT_SEARCH_HEIGHT_IN_PX;
|
|
245
|
+
var popupWidth = (_options$linkPicker$p2 = options === null || options === void 0 || (_options$linkPicker2 = options.linkPicker) === null || _options$linkPicker2 === void 0 ? void 0 : _options$linkPicker2.popupWidth) !== null && _options$linkPicker$p2 !== void 0 ? _options$linkPicker$p2 : !lpLinkPicker ? undefined : RECENT_SEARCH_WIDTH_IN_PX;
|
|
248
246
|
return _objectSpread(_objectSpread({}, hyperLinkToolbar), {}, {
|
|
249
247
|
preventPopupOverflow: true,
|
|
250
248
|
height: popupHeight,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-hyperlink",
|
|
3
|
-
"version": "12.1
|
|
3
|
+
"version": "12.2.1",
|
|
4
4
|
"description": "Hyperlink plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -29,10 +29,10 @@
|
|
|
29
29
|
],
|
|
30
30
|
"atlaskit:src": "src/index.ts",
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@atlaskit/adf-schema": "^52.
|
|
32
|
+
"@atlaskit/adf-schema": "^52.14.0",
|
|
33
33
|
"@atlaskit/analytics-next": "^11.2.0",
|
|
34
34
|
"@atlaskit/editor-plugin-analytics": "^10.1.0",
|
|
35
|
-
"@atlaskit/editor-plugin-card": "^16.
|
|
35
|
+
"@atlaskit/editor-plugin-card": "^16.10.0",
|
|
36
36
|
"@atlaskit/editor-plugin-connectivity": "^10.1.0",
|
|
37
37
|
"@atlaskit/editor-plugin-editor-viewmode": "^12.1.0",
|
|
38
38
|
"@atlaskit/editor-plugin-primary-toolbar": "^11.1.0",
|
|
@@ -40,18 +40,18 @@
|
|
|
40
40
|
"@atlaskit/editor-plugin-toolbar": "^7.3.0",
|
|
41
41
|
"@atlaskit/editor-plugin-user-intent": "^8.2.0",
|
|
42
42
|
"@atlaskit/editor-prosemirror": "^7.3.0",
|
|
43
|
-
"@atlaskit/editor-toolbar": "^1.
|
|
43
|
+
"@atlaskit/editor-toolbar": "^1.7.0",
|
|
44
44
|
"@atlaskit/editor-toolbar-model": "^0.5.0",
|
|
45
|
-
"@atlaskit/icon": "^35.
|
|
45
|
+
"@atlaskit/icon": "^35.1.0",
|
|
46
46
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
47
47
|
"@atlaskit/prosemirror-input-rules": "^3.7.0",
|
|
48
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
48
|
+
"@atlaskit/tmp-editor-statsig": "^83.0.0",
|
|
49
49
|
"@babel/runtime": "^7.0.0",
|
|
50
50
|
"@emotion/react": "^11.7.1",
|
|
51
51
|
"uuid": "^3.1.0"
|
|
52
52
|
},
|
|
53
53
|
"peerDependencies": {
|
|
54
|
-
"@atlaskit/editor-common": "^114.
|
|
54
|
+
"@atlaskit/editor-common": "^114.46.0",
|
|
55
55
|
"react": "^18.2.0",
|
|
56
56
|
"react-dom": "^18.2.0",
|
|
57
57
|
"react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
|
|
@@ -59,6 +59,8 @@
|
|
|
59
59
|
"devDependencies": {
|
|
60
60
|
"@testing-library/react": "^16.3.0",
|
|
61
61
|
"raf-stub": "^2.0.1",
|
|
62
|
+
"react": "^18.2.0",
|
|
63
|
+
"react-dom": "^18.2.0",
|
|
62
64
|
"react-intl": "^6.6.2",
|
|
63
65
|
"wait-for-expect": "^1.2.0"
|
|
64
66
|
},
|