@atlaskit/renderer 84.0.0 → 86.0.0
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 +100 -0
- package/dist/cjs/actions/index.js +3 -3
- package/dist/cjs/analytics/enums.js +2 -0
- package/dist/cjs/analytics/unsupported-content.js +3 -3
- package/dist/cjs/messages.js +47 -1
- package/dist/cjs/react/hooks/use-observed-width.js +94 -0
- package/dist/cjs/react/index.js +15 -9
- package/dist/cjs/react/marks/annotation.js +2 -2
- package/dist/cjs/react/marks/breakout.js +5 -3
- package/dist/cjs/react/marks/textColor.js +15 -4
- package/dist/cjs/react/nodes/blockCard.js +2 -2
- package/dist/cjs/react/nodes/caption.js +2 -2
- package/dist/cjs/react/nodes/copy-text-provider.js +2 -1
- package/dist/cjs/react/nodes/date.js +6 -4
- package/dist/cjs/react/nodes/embedCard.js +5 -5
- package/dist/cjs/react/nodes/emoji.js +2 -2
- package/dist/cjs/react/nodes/extension.js +6 -4
- package/dist/cjs/react/nodes/heading-anchor.js +11 -3
- package/dist/cjs/react/nodes/index.js +80 -55
- package/dist/cjs/react/nodes/inlineCard.js +14 -3
- package/dist/cjs/react/nodes/layoutColumn.js +2 -2
- package/dist/cjs/react/nodes/media.js +5 -3
- package/dist/cjs/react/nodes/mediaGroup.js +2 -2
- package/dist/cjs/react/nodes/mediaInline.js +2 -2
- package/dist/cjs/react/nodes/mediaSingle/index.js +146 -152
- package/dist/cjs/react/nodes/mediaSingle/styles.js +2 -2
- package/dist/cjs/react/nodes/mention.js +2 -4
- package/dist/cjs/react/nodes/panel.js +18 -20
- package/dist/cjs/react/nodes/status.js +2 -1
- package/dist/cjs/react/nodes/table/colgroup.js +2 -2
- package/dist/cjs/react/nodes/table/sticky.js +4 -4
- package/dist/cjs/react/nodes/table.js +19 -13
- package/dist/cjs/react/nodes/tableCell.js +34 -21
- package/dist/cjs/react/nodes/tableRow.js +6 -4
- package/dist/cjs/react/nodes/task-item-with-providers.js +6 -2
- package/dist/cjs/react/nodes/taskItem.js +4 -3
- package/dist/cjs/render-document.js +40 -4
- package/dist/cjs/text/nodes/date.js +3 -3
- package/dist/cjs/types/smartLinksOptions.js +5 -0
- package/dist/cjs/ui/Expand.js +9 -9
- package/dist/cjs/ui/ExtensionRenderer.js +8 -4
- package/dist/cjs/ui/MediaCard.js +4 -4
- package/dist/cjs/ui/Renderer/breakout-ssr.js +50 -7
- package/dist/cjs/ui/Renderer/index.js +23 -18
- package/dist/cjs/ui/Renderer/style.js +8 -6
- package/dist/cjs/ui/SortingIcon.js +30 -17
- package/dist/cjs/ui/annotations/draft/component.js +2 -2
- package/dist/cjs/ui/annotations/element/index.js +2 -2
- package/dist/cjs/ui/annotations/element/mark.js +4 -4
- package/dist/cjs/ui/annotations/hooks/use-events.js +11 -11
- package/dist/cjs/ui/annotations/hooks/use-load-annotations.js +4 -4
- package/dist/cjs/utils.js +4 -3
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/actions/index.js +1 -1
- package/dist/es2019/analytics/enums.js +2 -0
- package/dist/es2019/analytics/unsupported-content.js +1 -1
- package/dist/es2019/messages.js +44 -0
- package/dist/es2019/react/hooks/use-observed-width.js +59 -0
- package/dist/es2019/react/index.js +4 -1
- package/dist/es2019/react/marks/breakout.js +2 -1
- package/dist/es2019/react/marks/textColor.js +7 -4
- package/dist/es2019/react/nodes/blockCard.js +1 -1
- package/dist/es2019/react/nodes/caption.js +1 -1
- package/dist/es2019/react/nodes/copy-text-provider.js +2 -1
- package/dist/es2019/react/nodes/date.js +2 -1
- package/dist/es2019/react/nodes/embedCard.js +1 -1
- package/dist/es2019/react/nodes/emoji.js +1 -1
- package/dist/es2019/react/nodes/extension.js +2 -1
- package/dist/es2019/react/nodes/heading-anchor.js +11 -2
- package/dist/es2019/react/nodes/index.js +32 -7
- package/dist/es2019/react/nodes/inlineCard.js +12 -2
- package/dist/es2019/react/nodes/layoutColumn.js +1 -1
- package/dist/es2019/react/nodes/media.js +2 -1
- package/dist/es2019/react/nodes/mediaInline.js +1 -1
- package/dist/es2019/react/nodes/mediaSingle/index.js +132 -112
- package/dist/es2019/react/nodes/mediaSingle/styles.js +1 -1
- package/dist/es2019/react/nodes/mention.js +1 -3
- package/dist/es2019/react/nodes/panel.js +14 -12
- package/dist/es2019/react/nodes/status.js +2 -1
- package/dist/es2019/react/nodes/table/colgroup.js +1 -1
- package/dist/es2019/react/nodes/table/sticky.js +1 -1
- package/dist/es2019/react/nodes/table.js +4 -1
- package/dist/es2019/react/nodes/tableCell.js +22 -10
- package/dist/es2019/react/nodes/tableRow.js +2 -1
- package/dist/es2019/react/nodes/task-item-with-providers.js +3 -1
- package/dist/es2019/react/nodes/taskItem.js +2 -1
- package/dist/es2019/render-document.js +37 -3
- package/dist/es2019/text/nodes/date.js +1 -1
- package/dist/es2019/types/smartLinksOptions.js +1 -0
- package/dist/es2019/ui/Expand.js +1 -1
- package/dist/es2019/ui/ExtensionRenderer.js +3 -1
- package/dist/es2019/ui/MediaCard.js +1 -1
- package/dist/es2019/ui/Renderer/breakout-ssr.js +46 -5
- package/dist/es2019/ui/Renderer/index.js +4 -1
- package/dist/es2019/ui/Renderer/style.js +3 -1
- package/dist/es2019/ui/SortingIcon.js +23 -11
- package/dist/es2019/ui/annotations/draft/component.js +1 -1
- package/dist/es2019/ui/annotations/element/index.js +1 -1
- package/dist/es2019/ui/annotations/element/mark.js +1 -1
- package/dist/es2019/ui/annotations/hooks/use-events.js +1 -1
- package/dist/es2019/ui/annotations/hooks/use-load-annotations.js +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/actions/index.js +1 -1
- package/dist/esm/analytics/enums.js +2 -0
- package/dist/esm/analytics/unsupported-content.js +1 -1
- package/dist/esm/messages.js +44 -0
- package/dist/esm/react/hooks/use-observed-width.js +80 -0
- package/dist/esm/react/index.js +8 -4
- package/dist/esm/react/marks/annotation.js +2 -2
- package/dist/esm/react/marks/breakout.js +2 -1
- package/dist/esm/react/marks/textColor.js +8 -4
- package/dist/esm/react/nodes/blockCard.js +1 -1
- package/dist/esm/react/nodes/caption.js +1 -1
- package/dist/esm/react/nodes/copy-text-provider.js +2 -1
- package/dist/esm/react/nodes/date.js +2 -1
- package/dist/esm/react/nodes/embedCard.js +1 -1
- package/dist/esm/react/nodes/emoji.js +1 -1
- package/dist/esm/react/nodes/extension.js +2 -1
- package/dist/esm/react/nodes/heading-anchor.js +12 -3
- package/dist/esm/react/nodes/index.js +62 -7
- package/dist/esm/react/nodes/inlineCard.js +12 -2
- package/dist/esm/react/nodes/layoutColumn.js +1 -1
- package/dist/esm/react/nodes/media.js +2 -1
- package/dist/esm/react/nodes/mediaGroup.js +2 -2
- package/dist/esm/react/nodes/mediaInline.js +1 -1
- package/dist/esm/react/nodes/mediaSingle/index.js +140 -141
- package/dist/esm/react/nodes/mediaSingle/styles.js +1 -1
- package/dist/esm/react/nodes/mention.js +1 -3
- package/dist/esm/react/nodes/panel.js +14 -12
- package/dist/esm/react/nodes/status.js +2 -1
- package/dist/esm/react/nodes/table/colgroup.js +1 -1
- package/dist/esm/react/nodes/table/sticky.js +1 -1
- package/dist/esm/react/nodes/table.js +4 -1
- package/dist/esm/react/nodes/tableCell.js +19 -9
- package/dist/esm/react/nodes/tableRow.js +2 -1
- package/dist/esm/react/nodes/task-item-with-providers.js +5 -2
- package/dist/esm/react/nodes/taskItem.js +2 -1
- package/dist/esm/render-document.js +36 -3
- package/dist/esm/text/nodes/date.js +1 -1
- package/dist/esm/types/smartLinksOptions.js +1 -0
- package/dist/esm/ui/Expand.js +1 -1
- package/dist/esm/ui/ExtensionRenderer.js +3 -1
- package/dist/esm/ui/MediaCard.js +3 -3
- package/dist/esm/ui/Renderer/breakout-ssr.js +48 -5
- package/dist/esm/ui/Renderer/index.js +6 -3
- package/dist/esm/ui/Renderer/style.js +4 -3
- package/dist/esm/ui/SortingIcon.js +21 -11
- package/dist/esm/ui/annotations/draft/component.js +1 -1
- package/dist/esm/ui/annotations/element/index.js +1 -1
- package/dist/esm/ui/annotations/element/mark.js +3 -3
- package/dist/esm/ui/annotations/hooks/use-events.js +3 -3
- package/dist/esm/ui/annotations/hooks/use-load-annotations.js +3 -3
- package/dist/esm/utils.js +3 -2
- package/dist/esm/version.json +1 -1
- package/dist/types/actions/index.d.ts +1 -1
- package/dist/types/analytics/enums.d.ts +3 -1
- package/dist/types/analytics/events.d.ts +9 -2
- package/dist/types/analytics/unsupported-content.d.ts +1 -1
- package/dist/types/messages.d.ts +44 -0
- package/dist/types/react/hooks/use-observed-width.d.ts +3 -0
- package/dist/types/react/index.d.ts +6 -1
- package/dist/types/react/nodes/blockCard.d.ts +1 -1
- package/dist/types/react/nodes/bodiedExtension.d.ts +2 -1
- package/dist/types/react/nodes/codeBlock.d.ts +3 -3
- package/dist/types/react/nodes/embedCard.d.ts +1 -1
- package/dist/types/react/nodes/emoji.d.ts +1 -1
- package/dist/types/react/nodes/extension.d.ts +14 -13
- package/dist/types/react/nodes/index.d.ts +39 -15
- package/dist/types/react/nodes/inlineCard.d.ts +23 -21
- package/dist/types/react/nodes/inlineExtension.d.ts +2 -1
- package/dist/types/react/nodes/media.d.ts +2 -2
- package/dist/types/react/nodes/mediaGroup.d.ts +1 -1
- package/dist/types/react/nodes/mediaInline.d.ts +1 -1
- package/dist/types/react/nodes/mediaSingle/index.d.ts +3 -7
- package/dist/types/react/nodes/mediaSingle/styles.d.ts +1 -1
- package/dist/types/react/nodes/mention.d.ts +2 -2
- package/dist/types/react/nodes/panel.d.ts +3 -1
- package/dist/types/react/nodes/table/sticky.d.ts +1 -1
- package/dist/types/react/nodes/table.d.ts +22 -21
- package/dist/types/react/nodes/tableCell.d.ts +7 -60
- package/dist/types/react/nodes/tableRow.d.ts +1 -1
- package/dist/types/react/nodes/task-item-with-providers.d.ts +2 -1
- package/dist/types/react/nodes/taskItem.d.ts +1 -1
- package/dist/types/react/types.d.ts +3 -1
- package/dist/types/react/utils/getCardClickHandler.d.ts +1 -1
- package/dist/types/render-document.d.ts +1 -1
- package/dist/types/types/smartLinksOptions.d.ts +3 -0
- package/dist/types/ui/ExtensionRenderer.d.ts +3 -1
- package/dist/types/ui/MediaCard.d.ts +3 -2
- package/dist/types/ui/SortingIcon.d.ts +7 -4
- package/dist/types/ui/annotations/context.d.ts +1 -1
- package/dist/types/ui/annotations/element/mark.d.ts +1 -1
- package/dist/types/ui/annotations/hooks/use-events.d.ts +2 -1
- package/dist/types/ui/annotations/hooks/use-inline-comment-subscriber.d.ts +1 -1
- package/dist/types/ui/annotations/selection/mounter.d.ts +1 -1
- package/dist/types/ui/annotations/selection/range-validator.d.ts +1 -1
- package/dist/types/ui/annotations/types.d.ts +1 -1
- package/dist/types/ui/renderer-props.d.ts +8 -1
- package/dist/types/utils.d.ts +3 -1
- package/package.json +21 -22
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { getUnsupportedContentLevelData, getAnalyticsAppearance } from '@atlaskit/editor-common';
|
|
1
|
+
import { getUnsupportedContentLevelData, getAnalyticsAppearance } from '@atlaskit/editor-common/utils';
|
|
2
2
|
import { ACTION, ACTION_SUBJECT, EVENT_TYPE } from './enums';
|
|
3
3
|
import { PLATFORM } from './events';
|
|
4
4
|
var rendersMap = {};
|
package/dist/esm/messages.js
CHANGED
|
@@ -14,6 +14,50 @@ export var headingAnchorLinkMessages = defineMessages({
|
|
|
14
14
|
id: 'fabric.editor.headingLink.failedToCopy',
|
|
15
15
|
defaultMessage: 'Copy failed',
|
|
16
16
|
description: 'failed to copy heading link to clipboard'
|
|
17
|
+
},
|
|
18
|
+
copyAriaLabel: {
|
|
19
|
+
id: 'fabric.editor.headingLink.copyAriaLabel',
|
|
20
|
+
defaultMessage: 'Copy',
|
|
21
|
+
description: 'copy aria label for link icon'
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
export var tableCellMessages = defineMessages({
|
|
25
|
+
noneSortingLabel: {
|
|
26
|
+
id: 'fabric.editor.headingLink.noneSortingLabel',
|
|
27
|
+
defaultMessage: 'none',
|
|
28
|
+
description: 'this table column is not sorted'
|
|
29
|
+
},
|
|
30
|
+
ascSortingLabel: {
|
|
31
|
+
id: 'fabric.editor.headingLink.ascSortingLabel',
|
|
32
|
+
defaultMessage: 'ascending',
|
|
33
|
+
description: 'this table column is sorted in ascending order'
|
|
34
|
+
},
|
|
35
|
+
descSortingLabel: {
|
|
36
|
+
id: 'fabric.editor.headingLink.noneSortingLabel',
|
|
37
|
+
defaultMessage: 'descending',
|
|
38
|
+
description: 'this table column is sorted in descending order'
|
|
39
|
+
}
|
|
40
|
+
});
|
|
41
|
+
export var sortingIconMessages = defineMessages({
|
|
42
|
+
noOrderLabel: {
|
|
43
|
+
id: 'fabric.editor.headingLink.noOrderLabel',
|
|
44
|
+
defaultMessage: 'Sort column A to Z',
|
|
45
|
+
description: 'Sort the column in ascending order'
|
|
46
|
+
},
|
|
47
|
+
ascOrderLabel: {
|
|
48
|
+
id: 'fabric.editor.headingLink.ascOrderLabel',
|
|
49
|
+
defaultMessage: 'Sort column Z to A',
|
|
50
|
+
description: 'Sort the column in descending order'
|
|
51
|
+
},
|
|
52
|
+
descOrderLabel: {
|
|
53
|
+
id: 'fabric.editor.headingLink.descOrderLabel',
|
|
54
|
+
defaultMessage: 'Clear sorting',
|
|
55
|
+
description: 'clear the sorting from this column'
|
|
56
|
+
},
|
|
57
|
+
invalidLabel: {
|
|
58
|
+
id: 'fabric.editor.headingLink.descOrderLabel',
|
|
59
|
+
defaultMessage: "\u26A0\uFE0F You can't sort a table with merged cell",
|
|
60
|
+
description: 'this sort is invalid for merged cells'
|
|
17
61
|
}
|
|
18
62
|
});
|
|
19
63
|
export var codeBlockCopyButtonMessages = defineMessages({
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
2
|
+
|
|
3
|
+
function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
|
|
4
|
+
|
|
5
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
6
|
+
|
|
7
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
8
|
+
|
|
9
|
+
import React from 'react';
|
|
10
|
+
var resizeObserver;
|
|
11
|
+
var nodeToCallback = new WeakMap();
|
|
12
|
+
export var useObservedWidth = function useObservedWidth(node, useObservedWidthFlag) {
|
|
13
|
+
var _React$useState = React.useState({
|
|
14
|
+
x: 0,
|
|
15
|
+
y: 0,
|
|
16
|
+
width: 0,
|
|
17
|
+
height: 0,
|
|
18
|
+
top: 0,
|
|
19
|
+
left: 0,
|
|
20
|
+
bottom: 0,
|
|
21
|
+
right: 0
|
|
22
|
+
}),
|
|
23
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
24
|
+
rect = _React$useState2[0],
|
|
25
|
+
setRect = _React$useState2[1];
|
|
26
|
+
|
|
27
|
+
React.useEffect(function () {
|
|
28
|
+
if (!node || !useObservedWidthFlag) {
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
if (!resizeObserver) {
|
|
33
|
+
resizeObserver = new ResizeObserver(function (entries) {
|
|
34
|
+
var _iterator = _createForOfIteratorHelper(entries),
|
|
35
|
+
_step;
|
|
36
|
+
|
|
37
|
+
try {
|
|
38
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
39
|
+
var entry = _step.value;
|
|
40
|
+
|
|
41
|
+
if (nodeToCallback.has(entry.target)) {
|
|
42
|
+
nodeToCallback.get(entry.target)(entry.contentRect);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
} catch (err) {
|
|
46
|
+
_iterator.e(err);
|
|
47
|
+
} finally {
|
|
48
|
+
_iterator.f();
|
|
49
|
+
}
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
nodeToCallback.set(node, function (rect) {
|
|
54
|
+
var x = rect.x,
|
|
55
|
+
y = rect.y,
|
|
56
|
+
width = rect.width,
|
|
57
|
+
height = rect.height,
|
|
58
|
+
top = rect.top,
|
|
59
|
+
left = rect.left,
|
|
60
|
+
bottom = rect.bottom,
|
|
61
|
+
right = rect.right;
|
|
62
|
+
return setRect({
|
|
63
|
+
x: x,
|
|
64
|
+
y: y,
|
|
65
|
+
width: width,
|
|
66
|
+
height: height,
|
|
67
|
+
top: top,
|
|
68
|
+
left: left,
|
|
69
|
+
bottom: bottom,
|
|
70
|
+
right: right
|
|
71
|
+
});
|
|
72
|
+
});
|
|
73
|
+
resizeObserver.observe(node);
|
|
74
|
+
return function () {
|
|
75
|
+
resizeObserver.unobserve(node);
|
|
76
|
+
nodeToCallback.delete(node);
|
|
77
|
+
};
|
|
78
|
+
}, [node, useObservedWidthFlag]);
|
|
79
|
+
return rect;
|
|
80
|
+
};
|
package/dist/esm/react/index.js
CHANGED
|
@@ -4,10 +4,11 @@ import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
|
4
4
|
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
5
5
|
import _createClass from "@babel/runtime/helpers/createClass";
|
|
6
6
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
7
|
+
var _excluded = ["key"];
|
|
7
8
|
|
|
8
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
9
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
9
10
|
|
|
10
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
11
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
11
12
|
|
|
12
13
|
import React from 'react';
|
|
13
14
|
import { MarkType } from 'prosemirror-model';
|
|
@@ -15,7 +16,8 @@ import { isNestedHeaderLinksEnabled } from './utils/links';
|
|
|
15
16
|
import { Doc, DocWithSelectAllTrap, mergeTextNodes, isTextWrapper, isTextNode, toReact } from './nodes';
|
|
16
17
|
import TextWrapperComponent from './nodes/text-wrapper';
|
|
17
18
|
import { toReact as markToReact, isAnnotationMark } from './marks';
|
|
18
|
-
import { getMarksByOrder, isSameMark
|
|
19
|
+
import { getMarksByOrder, isSameMark } from '@atlaskit/editor-common/validator';
|
|
20
|
+
import { calcTableColumnWidths } from '@atlaskit/editor-common/utils';
|
|
19
21
|
import { getText } from '../utils';
|
|
20
22
|
import { findChildrenByType } from 'prosemirror-utils';
|
|
21
23
|
import { insideBreakoutLayout } from './renderer-node';
|
|
@@ -141,7 +143,7 @@ var ReactSerializer = /*#__PURE__*/function () {
|
|
|
141
143
|
|
|
142
144
|
var _mark$attrs = mark.attrs,
|
|
143
145
|
key = _mark$attrs.key,
|
|
144
|
-
otherAttrs = _objectWithoutProperties(_mark$attrs,
|
|
146
|
+
otherAttrs = _objectWithoutProperties(_mark$attrs, _excluded);
|
|
145
147
|
|
|
146
148
|
var extraProps = {
|
|
147
149
|
isInline: node === null || node === void 0 ? void 0 : node.isInline
|
|
@@ -191,6 +193,7 @@ var ReactSerializer = /*#__PURE__*/function () {
|
|
|
191
193
|
this.allowAnnotations = Boolean(init.allowAnnotations);
|
|
192
194
|
this.surroundTextNodesWithTextWrapper = Boolean(init.surroundTextNodesWithTextWrapper);
|
|
193
195
|
this.media = init.media;
|
|
196
|
+
this.smartLinks = init.smartLinks;
|
|
194
197
|
this.allowSelectAllTrap = init.allowSelectAllTrap;
|
|
195
198
|
}
|
|
196
199
|
|
|
@@ -555,6 +558,7 @@ var ReactSerializer = /*#__PURE__*/function () {
|
|
|
555
558
|
fireAnalyticsEvent: this.fireAnalyticsEvent,
|
|
556
559
|
nodeType: node.type.name,
|
|
557
560
|
marks: node.marks,
|
|
561
|
+
smartLinks: this.smartLinks,
|
|
558
562
|
dataAttributes: {
|
|
559
563
|
// We need to account for depth (path.length gives up depth) here
|
|
560
564
|
// but depth doesnt increment the pos, only accounted for.
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
|
|
4
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
4
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
5
5
|
|
|
6
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
6
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7
7
|
|
|
8
8
|
import React from 'react';
|
|
9
9
|
import { buildAnnotationMarkDataAttributes } from '@atlaskit/adf-schema';
|
|
@@ -4,7 +4,8 @@ var _templateObject;
|
|
|
4
4
|
|
|
5
5
|
import React from 'react';
|
|
6
6
|
import styled from 'styled-components';
|
|
7
|
-
import {
|
|
7
|
+
import { WidthConsumer } from '@atlaskit/editor-common/ui';
|
|
8
|
+
import { calcBreakoutWidth } from '@atlaskit/editor-common/utils';
|
|
8
9
|
import { blockNodesVerticalMargin } from '@atlaskit/editor-shared-styles';
|
|
9
10
|
export var Wrapper = styled.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n margin: ", " 0;\n margin-left: 50%;\n transform: translateX(-50%);\n"])), blockNodesVerticalMargin);
|
|
10
11
|
export default function Breakout(props) {
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import
|
|
2
|
+
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
|
+
import React, { useMemo } from 'react';
|
|
3
4
|
export default function TextColor(props) {
|
|
5
|
+
var style = useMemo(function () {
|
|
6
|
+
return _defineProperty({}, '--custom-text-color', props.color);
|
|
7
|
+
}, [props.color]);
|
|
4
8
|
return /*#__PURE__*/React.createElement("span", _extends({}, props.dataAttributes, {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
9
|
+
"data-text-custom-color": props.color,
|
|
10
|
+
className: "fabric-text-color-mark",
|
|
11
|
+
style: style
|
|
8
12
|
}), props.children);
|
|
9
13
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React, { useMemo } from 'react';
|
|
3
3
|
import { Card } from '@atlaskit/smart-card';
|
|
4
|
-
import { UnsupportedBlock } from '@atlaskit/editor-common';
|
|
4
|
+
import { UnsupportedBlock } from '@atlaskit/editor-common/ui';
|
|
5
5
|
import { getPlatform } from '../../utils';
|
|
6
6
|
import { CardErrorBoundary } from './fallback';
|
|
7
7
|
import { getCardClickHandler } from '../utils/getCardClickHandler';
|
|
@@ -79,7 +79,8 @@ var Provider = CopyTextContext.Provider,
|
|
|
79
79
|
Consumer = CopyTextContext.Consumer;
|
|
80
80
|
export var CopyArea = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
81
81
|
return /*#__PURE__*/React.createElement("div", _extends({
|
|
82
|
-
ref: ref
|
|
82
|
+
ref: ref // eslint-disable-next-line @atlaskit/design-system/use-visually-hidden
|
|
83
|
+
,
|
|
83
84
|
style: {
|
|
84
85
|
position: 'absolute',
|
|
85
86
|
left: '-9999px',
|
|
@@ -10,7 +10,8 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
10
10
|
|
|
11
11
|
import React from 'react';
|
|
12
12
|
import { PureComponent } from 'react';
|
|
13
|
-
import {
|
|
13
|
+
import { DateSharedCssClassName } from '@atlaskit/editor-common/styles';
|
|
14
|
+
import { isPastDate, timestampToString, timestampToTaskContext } from '@atlaskit/editor-common/utils';
|
|
14
15
|
import { injectIntl } from 'react-intl-next';
|
|
15
16
|
|
|
16
17
|
var Date = /*#__PURE__*/function (_PureComponent) {
|
|
@@ -6,7 +6,7 @@ var _templateObject, _templateObject2;
|
|
|
6
6
|
|
|
7
7
|
import React, { useMemo, useContext, useState, useRef } from 'react';
|
|
8
8
|
import { Card, Context as CardContext, EmbedResizeMessageListener } from '@atlaskit/smart-card';
|
|
9
|
-
import { WidthConsumer, mapBreakpointToLayoutMaxWidth, UnsupportedBlock, MediaSingle as UIMediaSingle } from '@atlaskit/editor-common';
|
|
9
|
+
import { WidthConsumer, mapBreakpointToLayoutMaxWidth, UnsupportedBlock, MediaSingle as UIMediaSingle } from '@atlaskit/editor-common/ui';
|
|
10
10
|
import { akEditorDefaultLayoutWidth, akEditorFullWidthLayoutWidth, DEFAULT_EMBED_CARD_HEIGHT, DEFAULT_EMBED_CARD_WIDTH, getAkEditorFullPageMaxWidth } from '@atlaskit/editor-shared-styles';
|
|
11
11
|
import { getPlatform } from '../../utils';
|
|
12
12
|
import { CardErrorBoundary } from './fallback';
|
|
@@ -10,7 +10,7 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
10
10
|
|
|
11
11
|
import React from 'react';
|
|
12
12
|
import { PureComponent } from 'react';
|
|
13
|
-
import { Emoji } from '@atlaskit/editor-common';
|
|
13
|
+
import { Emoji } from '@atlaskit/editor-common/emoji';
|
|
14
14
|
|
|
15
15
|
var EmojiItem = /*#__PURE__*/function (_PureComponent) {
|
|
16
16
|
_inherits(EmojiItem, _PureComponent);
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import ExtensionRenderer from '../../ui/ExtensionRenderer';
|
|
4
|
-
import {
|
|
4
|
+
import { overflowShadow, WidthConsumer } from '@atlaskit/editor-common/ui';
|
|
5
|
+
import { calcBreakoutWidth } from '@atlaskit/editor-common/utils';
|
|
5
6
|
import { RendererCssClassName } from '../../consts';
|
|
6
7
|
export var renderExtension = function renderExtension(content, layout) {
|
|
7
8
|
var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
@@ -13,6 +13,8 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
|
13
13
|
|
|
14
14
|
var _templateObject;
|
|
15
15
|
|
|
16
|
+
var _excluded = ["children"];
|
|
17
|
+
|
|
16
18
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
17
19
|
|
|
18
20
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
@@ -27,7 +29,7 @@ import { headingAnchorLinkMessages } from '../../messages';
|
|
|
27
29
|
export var HeadingAnchorWrapperClassName = 'heading-anchor-wrapper';
|
|
28
30
|
var CopyAnchorWrapperWithRef = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
29
31
|
var children = props.children,
|
|
30
|
-
rest = _objectWithoutProperties(props,
|
|
32
|
+
rest = _objectWithoutProperties(props, _excluded);
|
|
31
33
|
|
|
32
34
|
return /*#__PURE__*/React.createElement("span", _extends({}, rest, {
|
|
33
35
|
className: HeadingAnchorWrapperClassName,
|
|
@@ -61,11 +63,17 @@ var HeadingAnchor = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
61
63
|
var isClicked = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
62
64
|
|
|
63
65
|
_this.setState({
|
|
66
|
+
// TODO: ED-14403 investigate why this does not translate
|
|
64
67
|
tooltipMessage: _this.props.intl.formatMessage(message),
|
|
65
68
|
isClicked: isClicked
|
|
66
69
|
});
|
|
67
70
|
});
|
|
68
71
|
|
|
72
|
+
_defineProperty(_assertThisInitialized(_this), "getCopyAriaLabel", function () {
|
|
73
|
+
var copyAriaLabel = headingAnchorLinkMessages.copyAriaLabel;
|
|
74
|
+
return _this.props.intl.formatMessage(copyAriaLabel);
|
|
75
|
+
});
|
|
76
|
+
|
|
69
77
|
_defineProperty(_assertThisInitialized(_this), "copyToClipboard", /*#__PURE__*/function () {
|
|
70
78
|
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(event) {
|
|
71
79
|
var copiedHeadingLinkToClipboard, failedToCopyHeadingLink;
|
|
@@ -111,9 +119,10 @@ var HeadingAnchor = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
111
119
|
_defineProperty(_assertThisInitialized(_this), "renderAnchorButton", function () {
|
|
112
120
|
return /*#__PURE__*/React.createElement(CopyAnchorButton, {
|
|
113
121
|
onMouseLeave: _this.resetMessage,
|
|
114
|
-
onClick: _this.copyToClipboard
|
|
122
|
+
onClick: _this.copyToClipboard,
|
|
123
|
+
"aria-label": _this.state.tooltipMessage
|
|
115
124
|
}, /*#__PURE__*/React.createElement(LinkIcon, {
|
|
116
|
-
label:
|
|
125
|
+
label: _this.getCopyAriaLabel(),
|
|
117
126
|
size: _this.props.level > 3 ? 'small' : 'medium',
|
|
118
127
|
primaryColor: _this.state.isClicked ? B400 : N200
|
|
119
128
|
}));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
+
import Loadable from 'react-loadable';
|
|
1
2
|
import Blockquote from './blockquote';
|
|
2
3
|
import BodiedExtension from './bodiedExtension';
|
|
3
4
|
import BulletList from './bulletList';
|
|
4
|
-
import DecisionList from './decisionList';
|
|
5
5
|
import Doc, { DocWithSelectAllTrap } from './doc';
|
|
6
6
|
import Extension from './extension';
|
|
7
7
|
import HardBreak from './hardBreak';
|
|
@@ -10,21 +10,16 @@ import InlineExtension from './inlineExtension';
|
|
|
10
10
|
import LayoutSection from './layoutSection';
|
|
11
11
|
import LayoutColumn from './layoutColumn';
|
|
12
12
|
import ListItem from './listItem';
|
|
13
|
-
import MediaSingle from './mediaSingle';
|
|
14
13
|
import Caption from './caption';
|
|
15
14
|
import OrderedList from './orderedList';
|
|
16
|
-
import Panel from './panel';
|
|
17
15
|
import Paragraph from './paragraph';
|
|
18
16
|
import Placeholder from './placeholder';
|
|
19
17
|
import Rule from './rule';
|
|
20
|
-
import TaskList from './taskList';
|
|
21
18
|
import Table from './table';
|
|
22
19
|
import { TableCell, TableHeader } from './tableCell';
|
|
23
20
|
import TableRow from './tableRow';
|
|
24
21
|
import UnknownBlock from './unknownBlock';
|
|
25
|
-
import
|
|
26
|
-
import EmbedCard from './embedCard';
|
|
27
|
-
import { UnsupportedBlock, UnsupportedInline } from '@atlaskit/editor-common';
|
|
22
|
+
import { UnsupportedBlock, UnsupportedInline } from '@atlaskit/editor-common/ui';
|
|
28
23
|
var CodeBlock = Loadable({
|
|
29
24
|
loader: function loader() {
|
|
30
25
|
return import(
|
|
@@ -37,6 +32,18 @@ var CodeBlock = Loadable({
|
|
|
37
32
|
return null;
|
|
38
33
|
}
|
|
39
34
|
});
|
|
35
|
+
var TaskList = Loadable({
|
|
36
|
+
loader: function loader() {
|
|
37
|
+
return import(
|
|
38
|
+
/* webpackChunkName: "@atlaskit-internal_renderer-node_TaskList" */
|
|
39
|
+
'./taskList').then(function (mod) {
|
|
40
|
+
return mod.default;
|
|
41
|
+
});
|
|
42
|
+
},
|
|
43
|
+
loading: function loading() {
|
|
44
|
+
return null;
|
|
45
|
+
}
|
|
46
|
+
});
|
|
40
47
|
var TaskItem = Loadable({
|
|
41
48
|
loader: function loader() {
|
|
42
49
|
return import(
|
|
@@ -49,6 +56,18 @@ var TaskItem = Loadable({
|
|
|
49
56
|
return null;
|
|
50
57
|
}
|
|
51
58
|
});
|
|
59
|
+
var DecisionList = Loadable({
|
|
60
|
+
loader: function loader() {
|
|
61
|
+
return import(
|
|
62
|
+
/* webpackChunkName: "@atlaskit-internal_renderer-node_DecisionList" */
|
|
63
|
+
'./decisionList').then(function (mod) {
|
|
64
|
+
return mod.default;
|
|
65
|
+
});
|
|
66
|
+
},
|
|
67
|
+
loading: function loading() {
|
|
68
|
+
return null;
|
|
69
|
+
}
|
|
70
|
+
});
|
|
52
71
|
var DecisionItem = Loadable({
|
|
53
72
|
loader: function loader() {
|
|
54
73
|
return import(
|
|
@@ -97,6 +116,30 @@ var Emoji = Loadable({
|
|
|
97
116
|
return null;
|
|
98
117
|
}
|
|
99
118
|
});
|
|
119
|
+
var Panel = Loadable({
|
|
120
|
+
loader: function loader() {
|
|
121
|
+
return import(
|
|
122
|
+
/* webpackChunkName: "@atlaskit-internal_renderer-node_Panel" */
|
|
123
|
+
'./panel').then(function (mod) {
|
|
124
|
+
return mod.default;
|
|
125
|
+
});
|
|
126
|
+
},
|
|
127
|
+
loading: function loading() {
|
|
128
|
+
return null;
|
|
129
|
+
}
|
|
130
|
+
});
|
|
131
|
+
var EmbedCard = Loadable({
|
|
132
|
+
loader: function loader() {
|
|
133
|
+
return import(
|
|
134
|
+
/* webpackChunkName: "@atlaskit-internal_renderer-node_EmbedCard" */
|
|
135
|
+
'./embedCard').then(function (mod) {
|
|
136
|
+
return mod.default;
|
|
137
|
+
});
|
|
138
|
+
},
|
|
139
|
+
loading: function loading() {
|
|
140
|
+
return null;
|
|
141
|
+
}
|
|
142
|
+
});
|
|
100
143
|
var InlineCard = Loadable({
|
|
101
144
|
loader: function loader() {
|
|
102
145
|
return import(
|
|
@@ -157,6 +200,18 @@ var MediaInline = Loadable({
|
|
|
157
200
|
return null;
|
|
158
201
|
}
|
|
159
202
|
});
|
|
203
|
+
var MediaSingle = Loadable({
|
|
204
|
+
loader: function loader() {
|
|
205
|
+
return import(
|
|
206
|
+
/* webpackChunkName: "@atlaskit-internal_renderer-node_MediaSingle" */
|
|
207
|
+
'./mediaSingle').then(function (mod) {
|
|
208
|
+
return mod.default;
|
|
209
|
+
});
|
|
210
|
+
},
|
|
211
|
+
loading: function loading() {
|
|
212
|
+
return null;
|
|
213
|
+
}
|
|
214
|
+
});
|
|
160
215
|
var Mention = Loadable({
|
|
161
216
|
loader: function loader() {
|
|
162
217
|
return import(
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { Card } from '@atlaskit/smart-card';
|
|
4
|
-
import {
|
|
4
|
+
import { CardSSR } from '@atlaskit/smart-card/ssr';
|
|
5
|
+
import { UnsupportedInline } from '@atlaskit/editor-common/ui';
|
|
5
6
|
import { CardErrorBoundary } from './fallback';
|
|
6
7
|
import { withSmartCardStorage } from '../../ui/SmartCardStorage';
|
|
7
8
|
import { getCardClickHandler } from '../utils/getCardClickHandler';
|
|
@@ -10,7 +11,8 @@ var InlineCard = function InlineCard(props) {
|
|
|
10
11
|
var url = props.url,
|
|
11
12
|
data = props.data,
|
|
12
13
|
eventHandlers = props.eventHandlers,
|
|
13
|
-
portal = props.portal
|
|
14
|
+
portal = props.portal,
|
|
15
|
+
smartLinks = props.smartLinks;
|
|
14
16
|
var onClick = getCardClickHandler(eventHandlers, url);
|
|
15
17
|
var cardProps = {
|
|
16
18
|
url: url,
|
|
@@ -18,6 +20,14 @@ var InlineCard = function InlineCard(props) {
|
|
|
18
20
|
onClick: onClick,
|
|
19
21
|
container: portal
|
|
20
22
|
};
|
|
23
|
+
|
|
24
|
+
if (smartLinks !== null && smartLinks !== void 0 && smartLinks.ssr && url) {
|
|
25
|
+
return /*#__PURE__*/React.createElement(CardSSR, {
|
|
26
|
+
appearance: "inline",
|
|
27
|
+
url: url
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
|
|
21
31
|
return /*#__PURE__*/React.createElement("span", {
|
|
22
32
|
"data-inline-card": true,
|
|
23
33
|
"data-card-data": data ? JSON.stringify(data) : undefined,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { WidthProvider, ClearNextSiblingMarginTop } from '@atlaskit/editor-common';
|
|
2
|
+
import { WidthProvider, ClearNextSiblingMarginTop } from '@atlaskit/editor-common/ui';
|
|
3
3
|
export default function LayoutSection(props) {
|
|
4
4
|
return /*#__PURE__*/React.createElement("div", {
|
|
5
5
|
"data-layout-column": true,
|
|
@@ -13,7 +13,8 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
13
13
|
|
|
14
14
|
import React from 'react';
|
|
15
15
|
import { PureComponent } from 'react';
|
|
16
|
-
import { WithProviders
|
|
16
|
+
import { WithProviders } from '@atlaskit/editor-common/provider-factory';
|
|
17
|
+
import { MediaLink } from '@atlaskit/editor-common/ui';
|
|
17
18
|
import { MediaCard } from '../../ui/MediaCard';
|
|
18
19
|
import { getEventHandler } from '../../utils';
|
|
19
20
|
import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE } from '../../analytics/enums';
|
|
@@ -6,9 +6,9 @@ import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstruct
|
|
|
6
6
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
7
7
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
8
8
|
|
|
9
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
9
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
10
10
|
|
|
11
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
11
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
12
12
|
|
|
13
13
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
14
14
|
|
|
@@ -3,7 +3,7 @@ import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
|
3
3
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
4
4
|
import React, { useEffect, useState } from 'react';
|
|
5
5
|
import { MediaInlineCard } from '@atlaskit/media-card';
|
|
6
|
-
import { WithProviders } from '@atlaskit/editor-common';
|
|
6
|
+
import { WithProviders } from '@atlaskit/editor-common/provider-factory';
|
|
7
7
|
export var RenderMediaInline = function RenderMediaInline(props) {
|
|
8
8
|
var mediaProvider = props.mediaProvider;
|
|
9
9
|
|