@atlaskit/editor-plugin-card 23.0.6 → 23.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 +9 -0
- package/dist/cjs/pm-plugins/main.js +4 -4
- package/dist/es2019/pm-plugins/main.js +4 -4
- package/dist/esm/pm-plugins/main.js +4 -4
- package/package.json +6 -6
- package/dist/cjs/nodeviews/lazy-block-card.js +0 -32
- package/dist/cjs/nodeviews/lazy-embed-card.js +0 -32
- package/dist/es2019/nodeviews/lazy-block-card.js +0 -24
- package/dist/es2019/nodeviews/lazy-embed-card.js +0 -24
- package/dist/esm/nodeviews/lazy-block-card.js +0 -21
- package/dist/esm/nodeviews/lazy-embed-card.js +0 -21
- package/dist/types/nodeviews/lazy-block-card.d.ts +0 -3
- package/dist/types/nodeviews/lazy-embed-card.d.ts +0 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-card
|
|
2
2
|
|
|
3
|
+
## 23.0.7
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`aca1f7aaf3fd6`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/aca1f7aaf3fd6) -
|
|
8
|
+
Remove the fully rolled-out `platform_editor_exp_lazy_node_views` experiment and call the block
|
|
9
|
+
card, embed card, extension, table, and task node views directly.
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
3
12
|
## 23.0.6
|
|
4
13
|
|
|
5
14
|
### Patch Changes
|
|
@@ -15,9 +15,9 @@ var _styles = require("@atlaskit/editor-common/styles");
|
|
|
15
15
|
var _state = require("@atlaskit/editor-prosemirror/state");
|
|
16
16
|
var _utils = require("@atlaskit/editor-prosemirror/utils");
|
|
17
17
|
var _linkingCommon = require("@atlaskit/linking-common");
|
|
18
|
+
var _blockCard = require("../nodeviews/blockCard");
|
|
19
|
+
var _embedCard = require("../nodeviews/embedCard");
|
|
18
20
|
var _inlineCard = require("../nodeviews/inlineCard");
|
|
19
|
-
var _lazyBlockCard = require("../nodeviews/lazy-block-card");
|
|
20
|
-
var _lazyEmbedCard = require("../nodeviews/lazy-embed-card");
|
|
21
21
|
var _lazyInlineCard = require("../nodeviews/lazy-inline-card");
|
|
22
22
|
var _eventsFromTr = require("../ui/analytics/events-from-tr");
|
|
23
23
|
var _utils2 = require("../ui/LayoutButton/utils");
|
|
@@ -268,7 +268,7 @@ var createPlugin = exports.createPlugin = function createPlugin(options, pluginI
|
|
|
268
268
|
isPageSSRed: isPageSSRed
|
|
269
269
|
// no need provider here, it's in the inlineCardViewProducer.extraComponentProps
|
|
270
270
|
}),
|
|
271
|
-
blockCard: (0,
|
|
271
|
+
blockCard: (0, _blockCard.blockCardNodeView)({
|
|
272
272
|
pmPluginFactoryParams: pmPluginFactoryParams,
|
|
273
273
|
actionOptions: actionOptions,
|
|
274
274
|
pluginInjectionApi: pluginInjectionApi,
|
|
@@ -281,7 +281,7 @@ var createPlugin = exports.createPlugin = function createPlugin(options, pluginI
|
|
|
281
281
|
intl: intl,
|
|
282
282
|
smartCardContext: smartCardContext
|
|
283
283
|
}),
|
|
284
|
-
embedCard: (0,
|
|
284
|
+
embedCard: (0, _embedCard.embedCardNodeView)({
|
|
285
285
|
allowResizing: allowResizing,
|
|
286
286
|
fullWidthMode: fullWidthMode,
|
|
287
287
|
pmPluginFactoryParams: pmPluginFactoryParams,
|
|
@@ -6,9 +6,9 @@ import { DATASOURCE_INNER_CONTAINER_CLASSNAME } from '@atlaskit/editor-common/st
|
|
|
6
6
|
import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
|
|
7
7
|
import { findDomRefAtPos } from '@atlaskit/editor-prosemirror/utils';
|
|
8
8
|
import { DATASOURCE_DEFAULT_LAYOUT } from '@atlaskit/linking-common';
|
|
9
|
+
import { blockCardNodeView } from '../nodeviews/blockCard';
|
|
10
|
+
import { embedCardNodeView } from '../nodeviews/embedCard';
|
|
9
11
|
import { InlineCardNodeView } from '../nodeviews/inlineCard';
|
|
10
|
-
import { lazyBlockCardView } from '../nodeviews/lazy-block-card';
|
|
11
|
-
import { lazyEmbedCardView } from '../nodeviews/lazy-embed-card';
|
|
12
12
|
import { lazyInlineCardView } from '../nodeviews/lazy-inline-card';
|
|
13
13
|
import { eventsFromTransaction } from '../ui/analytics/events-from-tr';
|
|
14
14
|
import { isDatasourceTableLayout } from '../ui/LayoutButton/utils';
|
|
@@ -263,7 +263,7 @@ export const createPlugin = (options, pluginInjectionApi) => pmPluginFactoryPara
|
|
|
263
263
|
isPageSSRed
|
|
264
264
|
// no need provider here, it's in the inlineCardViewProducer.extraComponentProps
|
|
265
265
|
}),
|
|
266
|
-
blockCard:
|
|
266
|
+
blockCard: blockCardNodeView({
|
|
267
267
|
pmPluginFactoryParams,
|
|
268
268
|
actionOptions,
|
|
269
269
|
pluginInjectionApi,
|
|
@@ -276,7 +276,7 @@ export const createPlugin = (options, pluginInjectionApi) => pmPluginFactoryPara
|
|
|
276
276
|
intl,
|
|
277
277
|
smartCardContext
|
|
278
278
|
}),
|
|
279
|
-
embedCard:
|
|
279
|
+
embedCard: embedCardNodeView({
|
|
280
280
|
allowResizing,
|
|
281
281
|
fullWidthMode,
|
|
282
282
|
pmPluginFactoryParams,
|
|
@@ -10,9 +10,9 @@ import { DATASOURCE_INNER_CONTAINER_CLASSNAME } from '@atlaskit/editor-common/st
|
|
|
10
10
|
import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
|
|
11
11
|
import { findDomRefAtPos } from '@atlaskit/editor-prosemirror/utils';
|
|
12
12
|
import { DATASOURCE_DEFAULT_LAYOUT } from '@atlaskit/linking-common';
|
|
13
|
+
import { blockCardNodeView } from '../nodeviews/blockCard';
|
|
14
|
+
import { embedCardNodeView } from '../nodeviews/embedCard';
|
|
13
15
|
import { InlineCardNodeView } from '../nodeviews/inlineCard';
|
|
14
|
-
import { lazyBlockCardView } from '../nodeviews/lazy-block-card';
|
|
15
|
-
import { lazyEmbedCardView } from '../nodeviews/lazy-embed-card';
|
|
16
16
|
import { lazyInlineCardView } from '../nodeviews/lazy-inline-card';
|
|
17
17
|
import { eventsFromTransaction } from '../ui/analytics/events-from-tr';
|
|
18
18
|
import { isDatasourceTableLayout } from '../ui/LayoutButton/utils';
|
|
@@ -261,7 +261,7 @@ export var createPlugin = function createPlugin(options, pluginInjectionApi) {
|
|
|
261
261
|
isPageSSRed: isPageSSRed
|
|
262
262
|
// no need provider here, it's in the inlineCardViewProducer.extraComponentProps
|
|
263
263
|
}),
|
|
264
|
-
blockCard:
|
|
264
|
+
blockCard: blockCardNodeView({
|
|
265
265
|
pmPluginFactoryParams: pmPluginFactoryParams,
|
|
266
266
|
actionOptions: actionOptions,
|
|
267
267
|
pluginInjectionApi: pluginInjectionApi,
|
|
@@ -274,7 +274,7 @@ export var createPlugin = function createPlugin(options, pluginInjectionApi) {
|
|
|
274
274
|
intl: intl,
|
|
275
275
|
smartCardContext: smartCardContext
|
|
276
276
|
}),
|
|
277
|
-
embedCard:
|
|
277
|
+
embedCard: embedCardNodeView({
|
|
278
278
|
allowResizing: allowResizing,
|
|
279
279
|
fullWidthMode: fullWidthMode,
|
|
280
280
|
pmPluginFactoryParams: pmPluginFactoryParams,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-card",
|
|
3
|
-
"version": "23.0.
|
|
3
|
+
"version": "23.0.7",
|
|
4
4
|
"description": "Card plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"@atlaskit/editor-plugin-ui-control-registry": "^11.0.0",
|
|
43
43
|
"@atlaskit/editor-plugin-width": "^18.0.0",
|
|
44
44
|
"@atlaskit/editor-prosemirror": "^8.0.0",
|
|
45
|
-
"@atlaskit/editor-shared-styles": "^4.
|
|
45
|
+
"@atlaskit/editor-shared-styles": "^4.2.0",
|
|
46
46
|
"@atlaskit/editor-smart-link-draggable": "^1.2.0",
|
|
47
47
|
"@atlaskit/editor-toolbar": "^2.6.0",
|
|
48
48
|
"@atlaskit/editor-ui-control-model": "^2.9.0",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"@atlaskit/link": "^5.1.0",
|
|
53
53
|
"@atlaskit/link-analytics": "^12.4.0",
|
|
54
54
|
"@atlaskit/link-client-extension": "^7.3.0",
|
|
55
|
-
"@atlaskit/link-datasource": "^6.
|
|
55
|
+
"@atlaskit/link-datasource": "^6.13.0",
|
|
56
56
|
"@atlaskit/link-extractors": "^4.2.0",
|
|
57
57
|
"@atlaskit/linking-common": "^12.1.0",
|
|
58
58
|
"@atlaskit/linking-types": "^15.3.0",
|
|
@@ -63,8 +63,8 @@
|
|
|
63
63
|
"@atlaskit/primitives": "^22.5.0",
|
|
64
64
|
"@atlaskit/prosemirror-history": "^1.2.0",
|
|
65
65
|
"@atlaskit/smart-card": "^45.21.0",
|
|
66
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
67
|
-
"@atlaskit/tokens": "^16.
|
|
66
|
+
"@atlaskit/tmp-editor-statsig": "^186.0.0",
|
|
67
|
+
"@atlaskit/tokens": "^16.12.0",
|
|
68
68
|
"@babel/runtime": "^7.0.0",
|
|
69
69
|
"@emotion/react": "^11.7.1",
|
|
70
70
|
"lodash": "^4.17.21",
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
"uuid": "^11.1.1"
|
|
74
74
|
},
|
|
75
75
|
"peerDependencies": {
|
|
76
|
-
"@atlaskit/editor-common": "^121.
|
|
76
|
+
"@atlaskit/editor-common": "^121.4.0",
|
|
77
77
|
"@atlaskit/link-provider": "^5.6.0",
|
|
78
78
|
"react": "^18.2.0 || ^19.2.0",
|
|
79
79
|
"react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
Object.defineProperty(exports, "__esModule", {
|
|
5
|
-
value: true
|
|
6
|
-
});
|
|
7
|
-
exports.lazyBlockCardView = void 0;
|
|
8
|
-
var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
|
|
9
|
-
var _lazyNodeView = require("@atlaskit/editor-common/lazy-node-view");
|
|
10
|
-
var _editorExperiment = require("@atlaskit/tmp-editor-statsig/editor-experiment");
|
|
11
|
-
var _blockCard = require("./blockCard");
|
|
12
|
-
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != (0, _typeof2.default)(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
13
|
-
var lazyBlockCardView = exports.lazyBlockCardView = function lazyBlockCardView(props) {
|
|
14
|
-
var isPageSSRed = props.isPageSSRed;
|
|
15
|
-
if ((0, _editorExperiment.editorExperiment)('platform_editor_exp_lazy_node_views', false) || isPageSSRed) {
|
|
16
|
-
return (0, _blockCard.blockCardNodeView)(props);
|
|
17
|
-
}
|
|
18
|
-
return (0, _lazyNodeView.withLazyLoading)({
|
|
19
|
-
nodeName: 'blockCard',
|
|
20
|
-
getNodeViewOptions: function getNodeViewOptions() {},
|
|
21
|
-
loader: function loader() {
|
|
22
|
-
var result = Promise.resolve().then(function () {
|
|
23
|
-
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_editor-plugin-block-card-item-nodeview" */
|
|
24
|
-
'./blockCard'));
|
|
25
|
-
}).then(function (_ref) {
|
|
26
|
-
var blockCardNodeView = _ref.blockCardNodeView;
|
|
27
|
-
return blockCardNodeView(props);
|
|
28
|
-
});
|
|
29
|
-
return result;
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
};
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
Object.defineProperty(exports, "__esModule", {
|
|
5
|
-
value: true
|
|
6
|
-
});
|
|
7
|
-
exports.lazyEmbedCardView = void 0;
|
|
8
|
-
var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
|
|
9
|
-
var _lazyNodeView = require("@atlaskit/editor-common/lazy-node-view");
|
|
10
|
-
var _editorExperiment = require("@atlaskit/tmp-editor-statsig/editor-experiment");
|
|
11
|
-
var _embedCard = require("./embedCard");
|
|
12
|
-
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != (0, _typeof2.default)(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
13
|
-
var lazyEmbedCardView = exports.lazyEmbedCardView = function lazyEmbedCardView(props) {
|
|
14
|
-
var isPageSSRed = props.isPageSSRed;
|
|
15
|
-
if ((0, _editorExperiment.editorExperiment)('platform_editor_exp_lazy_node_views', false) || isPageSSRed) {
|
|
16
|
-
return (0, _embedCard.embedCardNodeView)(props);
|
|
17
|
-
}
|
|
18
|
-
return (0, _lazyNodeView.withLazyLoading)({
|
|
19
|
-
nodeName: 'embedCard',
|
|
20
|
-
getNodeViewOptions: function getNodeViewOptions() {},
|
|
21
|
-
loader: function loader() {
|
|
22
|
-
var result = Promise.resolve().then(function () {
|
|
23
|
-
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_editor-plugin-embed-card-item-nodeview" */
|
|
24
|
-
'./embedCard'));
|
|
25
|
-
}).then(function (_ref) {
|
|
26
|
-
var embedCardNodeView = _ref.embedCardNodeView;
|
|
27
|
-
return embedCardNodeView(props);
|
|
28
|
-
});
|
|
29
|
-
return result;
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { withLazyLoading } from '@atlaskit/editor-common/lazy-node-view';
|
|
2
|
-
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
3
|
-
import { blockCardNodeView } from './blockCard';
|
|
4
|
-
export const lazyBlockCardView = props => {
|
|
5
|
-
const {
|
|
6
|
-
isPageSSRed
|
|
7
|
-
} = props;
|
|
8
|
-
if (editorExperiment('platform_editor_exp_lazy_node_views', false) || isPageSSRed) {
|
|
9
|
-
return blockCardNodeView(props);
|
|
10
|
-
}
|
|
11
|
-
return withLazyLoading({
|
|
12
|
-
nodeName: 'blockCard',
|
|
13
|
-
getNodeViewOptions: () => {},
|
|
14
|
-
loader: () => {
|
|
15
|
-
const result = import( /* webpackChunkName: "@atlaskit-internal_editor-plugin-block-card-item-nodeview" */
|
|
16
|
-
'./blockCard').then(({
|
|
17
|
-
blockCardNodeView
|
|
18
|
-
}) => {
|
|
19
|
-
return blockCardNodeView(props);
|
|
20
|
-
});
|
|
21
|
-
return result;
|
|
22
|
-
}
|
|
23
|
-
});
|
|
24
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { withLazyLoading } from '@atlaskit/editor-common/lazy-node-view';
|
|
2
|
-
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
3
|
-
import { embedCardNodeView } from './embedCard';
|
|
4
|
-
export const lazyEmbedCardView = props => {
|
|
5
|
-
const {
|
|
6
|
-
isPageSSRed
|
|
7
|
-
} = props;
|
|
8
|
-
if (editorExperiment('platform_editor_exp_lazy_node_views', false) || isPageSSRed) {
|
|
9
|
-
return embedCardNodeView(props);
|
|
10
|
-
}
|
|
11
|
-
return withLazyLoading({
|
|
12
|
-
nodeName: 'embedCard',
|
|
13
|
-
getNodeViewOptions: () => {},
|
|
14
|
-
loader: () => {
|
|
15
|
-
const result = import( /* webpackChunkName: "@atlaskit-internal_editor-plugin-embed-card-item-nodeview" */
|
|
16
|
-
'./embedCard').then(({
|
|
17
|
-
embedCardNodeView
|
|
18
|
-
}) => {
|
|
19
|
-
return embedCardNodeView(props);
|
|
20
|
-
});
|
|
21
|
-
return result;
|
|
22
|
-
}
|
|
23
|
-
});
|
|
24
|
-
};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { withLazyLoading } from '@atlaskit/editor-common/lazy-node-view';
|
|
2
|
-
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
3
|
-
import { blockCardNodeView } from './blockCard';
|
|
4
|
-
export var lazyBlockCardView = function lazyBlockCardView(props) {
|
|
5
|
-
var isPageSSRed = props.isPageSSRed;
|
|
6
|
-
if (editorExperiment('platform_editor_exp_lazy_node_views', false) || isPageSSRed) {
|
|
7
|
-
return blockCardNodeView(props);
|
|
8
|
-
}
|
|
9
|
-
return withLazyLoading({
|
|
10
|
-
nodeName: 'blockCard',
|
|
11
|
-
getNodeViewOptions: function getNodeViewOptions() {},
|
|
12
|
-
loader: function loader() {
|
|
13
|
-
var result = import( /* webpackChunkName: "@atlaskit-internal_editor-plugin-block-card-item-nodeview" */
|
|
14
|
-
'./blockCard').then(function (_ref) {
|
|
15
|
-
var blockCardNodeView = _ref.blockCardNodeView;
|
|
16
|
-
return blockCardNodeView(props);
|
|
17
|
-
});
|
|
18
|
-
return result;
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { withLazyLoading } from '@atlaskit/editor-common/lazy-node-view';
|
|
2
|
-
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
|
|
3
|
-
import { embedCardNodeView } from './embedCard';
|
|
4
|
-
export var lazyEmbedCardView = function lazyEmbedCardView(props) {
|
|
5
|
-
var isPageSSRed = props.isPageSSRed;
|
|
6
|
-
if (editorExperiment('platform_editor_exp_lazy_node_views', false) || isPageSSRed) {
|
|
7
|
-
return embedCardNodeView(props);
|
|
8
|
-
}
|
|
9
|
-
return withLazyLoading({
|
|
10
|
-
nodeName: 'embedCard',
|
|
11
|
-
getNodeViewOptions: function getNodeViewOptions() {},
|
|
12
|
-
loader: function loader() {
|
|
13
|
-
var result = import( /* webpackChunkName: "@atlaskit-internal_editor-plugin-embed-card-item-nodeview" */
|
|
14
|
-
'./embedCard').then(function (_ref) {
|
|
15
|
-
var embedCardNodeView = _ref.embedCardNodeView;
|
|
16
|
-
return embedCardNodeView(props);
|
|
17
|
-
});
|
|
18
|
-
return result;
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
};
|