@atlaskit/editor-plugin-card 3.3.0 → 3.4.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 +21 -0
- package/dist/cjs/nodeviews/genericCard.js +1 -1
- package/dist/cjs/nodeviews/inlineCard.js +1 -1
- package/dist/cjs/pm-plugins/main.js +2 -2
- package/dist/es2019/nodeviews/genericCard.js +1 -1
- package/dist/es2019/nodeviews/inlineCard.js +1 -1
- package/dist/es2019/pm-plugins/main.js +2 -2
- package/dist/esm/nodeviews/genericCard.js +1 -1
- package/dist/esm/nodeviews/inlineCard.js +1 -1
- package/dist/esm/pm-plugins/main.js +2 -2
- package/dist/types/nodeviews/genericCard.d.ts +0 -6
- package/dist/types-ts4.5/nodeviews/genericCard.d.ts +0 -6
- package/package.json +8 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,26 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-card
|
|
2
2
|
|
|
3
|
+
## 3.4.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#146891](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/146891)
|
|
8
|
+
[`17f2c59f06b04`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/17f2c59f06b04) -
|
|
9
|
+
Migrate smart links in live pages feature flag to Statsig
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
12
|
+
## 3.4.0
|
|
13
|
+
|
|
14
|
+
### Minor Changes
|
|
15
|
+
|
|
16
|
+
- [#147220](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/147220)
|
|
17
|
+
[`07a9416026f88`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/07a9416026f88) -
|
|
18
|
+
Remove showActions and showServerActions from smart-card
|
|
19
|
+
|
|
20
|
+
### Patch Changes
|
|
21
|
+
|
|
22
|
+
- Updated dependencies
|
|
23
|
+
|
|
3
24
|
## 3.3.0
|
|
4
25
|
|
|
5
26
|
### Minor Changes
|
|
@@ -46,7 +46,7 @@ var WithClickHandler = function WithClickHandler(_ref) {
|
|
|
46
46
|
} catch (_unused) {}
|
|
47
47
|
}
|
|
48
48
|
}, [url, onClickCallback]);
|
|
49
|
-
if ((0, _platformFeatureFlags.fg)('
|
|
49
|
+
if ((0, _platformFeatureFlags.fg)('linking_platform_smart_links_in_live_pages')) {
|
|
50
50
|
/**
|
|
51
51
|
* @todo: Add a check to determine if we're currently in a live page once ED-23920 and plugin
|
|
52
52
|
* is complete. The logic for which should allow navigation if we're in a live page and no callback
|
|
@@ -122,7 +122,7 @@ function InlineCardNodeView(props) {
|
|
|
122
122
|
editorViewModeState = _useSharedPluginState.editorViewModeState,
|
|
123
123
|
floatingToolbarState = _useSharedPluginState.floatingToolbarState;
|
|
124
124
|
var floatingToolbarNode = floatingToolbarState === null || floatingToolbarState === void 0 || (_floatingToolbarState = floatingToolbarState.configWithNodeInfo) === null || _floatingToolbarState === void 0 ? void 0 : _floatingToolbarState.node;
|
|
125
|
-
if (__livePage && (0, _platformFeatureFlags.fg)('
|
|
125
|
+
if (__livePage && (0, _platformFeatureFlags.fg)('linking_platform_smart_links_in_live_pages')) {
|
|
126
126
|
var showHoverPreview = floatingToolbarNode !== node;
|
|
127
127
|
var livePagesHoverCardFadeInDelay = 800;
|
|
128
128
|
var inlineCard = /*#__PURE__*/_react.default.createElement(WrappedInlineCard, {
|
|
@@ -39,7 +39,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
39
39
|
var LOCAL_STORAGE_DISCOVERY_KEY_SMART_LINK = 'smart-link-upgrade-pulse';
|
|
40
40
|
var ALLOW_EVENTS_CLASSNAME = exports.ALLOW_EVENTS_CLASSNAME = 'card-plugin-element-allow-events';
|
|
41
41
|
var stopEvent = exports.stopEvent = function stopEvent(event) {
|
|
42
|
-
if (!(0, _platformFeatureFlags.fg)('
|
|
42
|
+
if (!(0, _platformFeatureFlags.fg)('linking_platform_smart_links_in_live_pages')) {
|
|
43
43
|
return false;
|
|
44
44
|
}
|
|
45
45
|
var target = event.target;
|
|
@@ -88,7 +88,7 @@ var createPlugin = exports.createPlugin = function createPlugin(options, pluginI
|
|
|
88
88
|
onClickCallback: onClickCallback,
|
|
89
89
|
__livePage: __livePage
|
|
90
90
|
}
|
|
91
|
-
}, __livePage && (0, _platformFeatureFlags.fg)('
|
|
91
|
+
}, __livePage && (0, _platformFeatureFlags.fg)('linking_platform_smart_links_in_live_pages') && {
|
|
92
92
|
extraNodeViewProps: {
|
|
93
93
|
stopEvent: stopEvent
|
|
94
94
|
}
|
|
@@ -30,7 +30,7 @@ const WithClickHandler = ({
|
|
|
30
30
|
} catch {}
|
|
31
31
|
}
|
|
32
32
|
}, [url, onClickCallback]);
|
|
33
|
-
if (fg('
|
|
33
|
+
if (fg('linking_platform_smart_links_in_live_pages')) {
|
|
34
34
|
/**
|
|
35
35
|
* @todo: Add a check to determine if we're currently in a live page once ED-23920 and plugin
|
|
36
36
|
* is complete. The logic for which should allow navigation if we're in a live page and no callback
|
|
@@ -112,7 +112,7 @@ export function InlineCardNodeView(props) {
|
|
|
112
112
|
floatingToolbarState
|
|
113
113
|
} = useSharedPluginState(pluginInjectionApi, ['floatingToolbar', 'editorViewMode']);
|
|
114
114
|
const floatingToolbarNode = floatingToolbarState === null || floatingToolbarState === void 0 ? void 0 : (_floatingToolbarState = floatingToolbarState.configWithNodeInfo) === null || _floatingToolbarState === void 0 ? void 0 : _floatingToolbarState.node;
|
|
115
|
-
if (__livePage && fg('
|
|
115
|
+
if (__livePage && fg('linking_platform_smart_links_in_live_pages')) {
|
|
116
116
|
const showHoverPreview = floatingToolbarNode !== node;
|
|
117
117
|
const livePagesHoverCardFadeInDelay = 800;
|
|
118
118
|
const inlineCard = /*#__PURE__*/React.createElement(WrappedInlineCard, {
|
|
@@ -22,7 +22,7 @@ export { pluginKey } from './plugin-key';
|
|
|
22
22
|
const LOCAL_STORAGE_DISCOVERY_KEY_SMART_LINK = 'smart-link-upgrade-pulse';
|
|
23
23
|
export const ALLOW_EVENTS_CLASSNAME = 'card-plugin-element-allow-events';
|
|
24
24
|
export const stopEvent = event => {
|
|
25
|
-
if (!fg('
|
|
25
|
+
if (!fg('linking_platform_smart_links_in_live_pages')) {
|
|
26
26
|
return false;
|
|
27
27
|
}
|
|
28
28
|
const target = event.target;
|
|
@@ -73,7 +73,7 @@ export const createPlugin = (options, pluginInjectionApi) => pmPluginFactoryPara
|
|
|
73
73
|
onClickCallback,
|
|
74
74
|
__livePage
|
|
75
75
|
},
|
|
76
|
-
...(__livePage && fg('
|
|
76
|
+
...(__livePage && fg('linking_platform_smart_links_in_live_pages') && {
|
|
77
77
|
extraNodeViewProps: {
|
|
78
78
|
stopEvent
|
|
79
79
|
}
|
|
@@ -36,7 +36,7 @@ var WithClickHandler = function WithClickHandler(_ref) {
|
|
|
36
36
|
} catch (_unused) {}
|
|
37
37
|
}
|
|
38
38
|
}, [url, onClickCallback]);
|
|
39
|
-
if (fg('
|
|
39
|
+
if (fg('linking_platform_smart_links_in_live_pages')) {
|
|
40
40
|
/**
|
|
41
41
|
* @todo: Add a check to determine if we're currently in a live page once ED-23920 and plugin
|
|
42
42
|
* is complete. The logic for which should allow navigation if we're in a live page and no callback
|
|
@@ -111,7 +111,7 @@ export function InlineCardNodeView(props) {
|
|
|
111
111
|
editorViewModeState = _useSharedPluginState.editorViewModeState,
|
|
112
112
|
floatingToolbarState = _useSharedPluginState.floatingToolbarState;
|
|
113
113
|
var floatingToolbarNode = floatingToolbarState === null || floatingToolbarState === void 0 || (_floatingToolbarState = floatingToolbarState.configWithNodeInfo) === null || _floatingToolbarState === void 0 ? void 0 : _floatingToolbarState.node;
|
|
114
|
-
if (__livePage && fg('
|
|
114
|
+
if (__livePage && fg('linking_platform_smart_links_in_live_pages')) {
|
|
115
115
|
var showHoverPreview = floatingToolbarNode !== node;
|
|
116
116
|
var livePagesHoverCardFadeInDelay = 800;
|
|
117
117
|
var inlineCard = /*#__PURE__*/React.createElement(WrappedInlineCard, {
|
|
@@ -26,7 +26,7 @@ export { pluginKey } from './plugin-key';
|
|
|
26
26
|
var LOCAL_STORAGE_DISCOVERY_KEY_SMART_LINK = 'smart-link-upgrade-pulse';
|
|
27
27
|
export var ALLOW_EVENTS_CLASSNAME = 'card-plugin-element-allow-events';
|
|
28
28
|
export var stopEvent = function stopEvent(event) {
|
|
29
|
-
if (!fg('
|
|
29
|
+
if (!fg('linking_platform_smart_links_in_live_pages')) {
|
|
30
30
|
return false;
|
|
31
31
|
}
|
|
32
32
|
var target = event.target;
|
|
@@ -75,7 +75,7 @@ export var createPlugin = function createPlugin(options, pluginInjectionApi) {
|
|
|
75
75
|
onClickCallback: onClickCallback,
|
|
76
76
|
__livePage: __livePage
|
|
77
77
|
}
|
|
78
|
-
}, __livePage && fg('
|
|
78
|
+
}, __livePage && fg('linking_platform_smart_links_in_live_pages') && {
|
|
79
79
|
extraNodeViewProps: {
|
|
80
80
|
stopEvent: stopEvent
|
|
81
81
|
}
|
|
@@ -29,12 +29,6 @@ export interface CardProps extends CardNodeViewProps {
|
|
|
29
29
|
allowResizing?: boolean;
|
|
30
30
|
fullWidthMode?: boolean;
|
|
31
31
|
useAlternativePreloader?: boolean;
|
|
32
|
-
/**
|
|
33
|
-
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6348 Internal documentation for deprecation (no external access)}
|
|
34
|
-
*
|
|
35
|
-
* Prefer `actionOptions` prop.
|
|
36
|
-
*/
|
|
37
|
-
showServerActions?: boolean;
|
|
38
32
|
actionOptions?: BaseCardProps['actionOptions'];
|
|
39
33
|
pluginInjectionApi?: ExtractInjectionAPI<typeof cardPlugin>;
|
|
40
34
|
onClickCallback?: OnClickCallback;
|
|
@@ -29,12 +29,6 @@ export interface CardProps extends CardNodeViewProps {
|
|
|
29
29
|
allowResizing?: boolean;
|
|
30
30
|
fullWidthMode?: boolean;
|
|
31
31
|
useAlternativePreloader?: boolean;
|
|
32
|
-
/**
|
|
33
|
-
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6348 Internal documentation for deprecation (no external access)}
|
|
34
|
-
*
|
|
35
|
-
* Prefer `actionOptions` prop.
|
|
36
|
-
*/
|
|
37
|
-
showServerActions?: boolean;
|
|
38
32
|
actionOptions?: BaseCardProps['actionOptions'];
|
|
39
33
|
pluginInjectionApi?: ExtractInjectionAPI<typeof cardPlugin>;
|
|
40
34
|
onClickCallback?: OnClickCallback;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-card",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.4.1",
|
|
4
4
|
"description": "Card plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"@atlaskit/adf-schema": "^40.9.0",
|
|
35
35
|
"@atlaskit/analytics-next": "^10.1.0",
|
|
36
36
|
"@atlaskit/custom-steps": "^0.7.0",
|
|
37
|
-
"@atlaskit/editor-common": "^
|
|
37
|
+
"@atlaskit/editor-common": "^92.1.0",
|
|
38
38
|
"@atlaskit/editor-plugin-analytics": "^1.8.0",
|
|
39
39
|
"@atlaskit/editor-plugin-decorations": "^1.3.0",
|
|
40
40
|
"@atlaskit/editor-plugin-editor-disabled": "^1.3.0",
|
|
@@ -46,16 +46,16 @@
|
|
|
46
46
|
"@atlaskit/editor-prosemirror": "6.0.0",
|
|
47
47
|
"@atlaskit/editor-shared-styles": "^3.0.0",
|
|
48
48
|
"@atlaskit/frontend-utilities": "^2.7.0",
|
|
49
|
-
"@atlaskit/icon": "^22.
|
|
49
|
+
"@atlaskit/icon": "^22.20.0",
|
|
50
50
|
"@atlaskit/link-analytics": "^8.5.0",
|
|
51
51
|
"@atlaskit/link-client-extension": "^2.4.0",
|
|
52
|
-
"@atlaskit/link-datasource": "^3.
|
|
52
|
+
"@atlaskit/link-datasource": "^3.2.0",
|
|
53
53
|
"@atlaskit/linking-common": "^5.11.0",
|
|
54
54
|
"@atlaskit/linking-types": "^9.0.0",
|
|
55
55
|
"@atlaskit/menu": "2.12.5",
|
|
56
56
|
"@atlaskit/platform-feature-flags": "^0.3.0",
|
|
57
57
|
"@atlaskit/primitives": "^12.2.0",
|
|
58
|
-
"@atlaskit/smart-card": "^
|
|
58
|
+
"@atlaskit/smart-card": "^29.0.0",
|
|
59
59
|
"@atlaskit/theme": "^13.0.0",
|
|
60
60
|
"@atlaskit/tmp-editor-statsig": "^2.1.8",
|
|
61
61
|
"@atlaskit/tokens": "^2.0.0",
|
|
@@ -117,9 +117,6 @@
|
|
|
117
117
|
"platform.linking-platform.enable-datasource-edit-dropdown-toolbar": {
|
|
118
118
|
"type": "boolean"
|
|
119
119
|
},
|
|
120
|
-
"platform.linking-platform.smart-links-in-live-pages": {
|
|
121
|
-
"type": "boolean"
|
|
122
|
-
},
|
|
123
120
|
"platform.linking-platform.datasource-word_wrap": {
|
|
124
121
|
"type": "boolean"
|
|
125
122
|
},
|
|
@@ -143,6 +140,9 @@
|
|
|
143
140
|
},
|
|
144
141
|
"linking_platform_disable_live_view_inline_overlay": {
|
|
145
142
|
"type": "boolean"
|
|
143
|
+
},
|
|
144
|
+
"linking_platform_smart_links_in_live_pages": {
|
|
145
|
+
"type": "boolean"
|
|
146
146
|
}
|
|
147
147
|
},
|
|
148
148
|
"stricter": {
|