@atlaskit/editor-synced-block-renderer 24.0.1 → 24.0.2
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/ui/AKRendererWrapper.js +8 -6
- package/dist/cjs/ui/SyncedBlockEntityNotFoundError.js +4 -4
- package/dist/cjs/ui/SyncedBlockErrorComponent.js +15 -15
- package/dist/cjs/ui/SyncedBlockErrorStateCard.js +5 -4
- package/dist/cjs/ui/SyncedBlockGenericError.js +2 -2
- package/dist/cjs/ui/SyncedBlockLoadError.js +3 -3
- package/dist/cjs/ui/SyncedBlockLoadingState.js +4 -4
- package/dist/cjs/ui/SyncedBlockNodeComponentRenderer.js +10 -8
- package/dist/cjs/ui/SyncedBlockNotFoundError.js +9 -8
- package/dist/cjs/ui/SyncedBlockOfflineError.js +2 -2
- package/dist/cjs/ui/SyncedBlockPermissionDenied.js +15 -14
- package/dist/cjs/ui/SyncedBlockRenderer.js +6 -6
- package/dist/cjs/ui/SyncedBlockUnpublishedError.js +2 -2
- package/dist/cjs/ui/renderSyncedBlockContent.js +7 -7
- package/dist/cjs/useSyncedBlockNodeComponent.js +8 -7
- package/dist/es2019/ui/AKRendererWrapper.js +4 -2
- package/dist/es2019/ui/SyncedBlockEntityNotFoundError.js +2 -2
- package/dist/es2019/ui/SyncedBlockErrorComponent.js +5 -5
- package/dist/es2019/ui/SyncedBlockErrorStateCard.js +2 -1
- package/dist/es2019/ui/SyncedBlockGenericError.js +1 -1
- package/dist/es2019/ui/SyncedBlockLoadError.js +1 -1
- package/dist/es2019/ui/SyncedBlockLoadingState.js +2 -2
- package/dist/es2019/ui/SyncedBlockNodeComponentRenderer.js +5 -3
- package/dist/es2019/ui/SyncedBlockNotFoundError.js +3 -2
- package/dist/es2019/ui/SyncedBlockOfflineError.js +1 -1
- package/dist/es2019/ui/SyncedBlockPermissionDenied.js +6 -5
- package/dist/es2019/ui/SyncedBlockRenderer.js +3 -3
- package/dist/es2019/ui/SyncedBlockUnpublishedError.js +1 -1
- package/dist/es2019/ui/renderSyncedBlockContent.js +2 -2
- package/dist/es2019/useSyncedBlockNodeComponent.js +4 -3
- package/dist/esm/ui/AKRendererWrapper.js +4 -2
- package/dist/esm/ui/SyncedBlockEntityNotFoundError.js +2 -2
- package/dist/esm/ui/SyncedBlockErrorComponent.js +5 -5
- package/dist/esm/ui/SyncedBlockErrorStateCard.js +2 -1
- package/dist/esm/ui/SyncedBlockGenericError.js +1 -1
- package/dist/esm/ui/SyncedBlockLoadError.js +1 -1
- package/dist/esm/ui/SyncedBlockLoadingState.js +2 -2
- package/dist/esm/ui/SyncedBlockNodeComponentRenderer.js +5 -3
- package/dist/esm/ui/SyncedBlockNotFoundError.js +3 -2
- package/dist/esm/ui/SyncedBlockOfflineError.js +1 -1
- package/dist/esm/ui/SyncedBlockPermissionDenied.js +6 -5
- package/dist/esm/ui/SyncedBlockRenderer.js +3 -3
- package/dist/esm/ui/SyncedBlockUnpublishedError.js +1 -1
- package/dist/esm/ui/renderSyncedBlockContent.js +2 -2
- package/dist/esm/useSyncedBlockNodeComponent.js +4 -3
- package/dist/types/getSyncedBlockRenderer.d.ts +1 -1
- package/dist/types/types.d.ts +1 -1
- package/dist/types/ui/AKRendererWrapper.d.ts +1 -1
- package/dist/types/ui/SyncedBlockErrorComponent.d.ts +2 -2
- package/dist/types/ui/SyncedBlockNodeComponentRenderer.d.ts +2 -2
- package/dist/types/ui/SyncedBlockPermissionDenied.d.ts +1 -1
- package/dist/types/ui/SyncedBlockRenderer.d.ts +3 -3
- package/dist/types/ui/SyncedBlockUnpublishedError.d.ts +1 -1
- package/dist/types/ui/renderSyncedBlockContent.d.ts +3 -3
- package/dist/types/useSyncedBlockNodeComponent.d.ts +3 -2
- package/package.json +2 -2
|
@@ -6,17 +6,18 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.useMemoizedSyncedBlockNodeComponent = exports.getSyncBlockNodesFromDoc = void 0;
|
|
8
8
|
var _react = _interopRequireWildcard(require("react"));
|
|
9
|
-
var
|
|
9
|
+
var _enums = require("@atlaskit/editor-common/analytics/types/enums");
|
|
10
10
|
var _errorBoundary = require("@atlaskit/editor-common/error-boundary");
|
|
11
|
-
var
|
|
12
|
-
var
|
|
11
|
+
var _SyncBlockActionsContext = require("@atlaskit/editor-common/sync-block/SyncBlockActionsContext");
|
|
12
|
+
var _syncBlockStoreManager = require("@atlaskit/editor-synced-block-provider/syncBlockStoreManager");
|
|
13
|
+
var _utils = require("@atlaskit/editor-synced-block-provider/utils");
|
|
13
14
|
var _SyncedBlockNodeComponentRenderer = require("./ui/SyncedBlockNodeComponentRenderer");
|
|
14
15
|
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" != _typeof(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); }
|
|
15
16
|
var getSyncBlockNodesFromDoc = exports.getSyncBlockNodesFromDoc = function getSyncBlockNodesFromDoc(doc) {
|
|
16
17
|
var content = doc.content;
|
|
17
18
|
var isEmpty = !content || !Array.isArray(content) || content.length === 0;
|
|
18
19
|
var syncBlockNodes = isEmpty ? [] : content.map(function (node) {
|
|
19
|
-
return (0,
|
|
20
|
+
return (0, _utils.convertSyncBlockJSONNodeToSyncBlockNode)(node);
|
|
20
21
|
}).filter(function (node) {
|
|
21
22
|
return node !== undefined;
|
|
22
23
|
});
|
|
@@ -30,7 +31,7 @@ var useMemoizedSyncedBlockNodeComponent = exports.useMemoizedSyncedBlockNodeComp
|
|
|
30
31
|
getAccountId = _ref.getAccountId,
|
|
31
32
|
getPrefetchedData = _ref.getPrefetchedData,
|
|
32
33
|
enableRealTimeSubscriptions = _ref.enableRealTimeSubscriptions;
|
|
33
|
-
var syncBlockStoreManager = (0,
|
|
34
|
+
var syncBlockStoreManager = (0, _syncBlockStoreManager.useMemoizedSyncBlockStoreManager)(syncBlockProvider, fireAnalyticsEvent, {
|
|
34
35
|
enableRealTimeSubscriptions: enableRealTimeSubscriptions
|
|
35
36
|
});
|
|
36
37
|
|
|
@@ -60,10 +61,10 @@ var useMemoizedSyncedBlockNodeComponent = exports.useMemoizedSyncedBlockNodeComp
|
|
|
60
61
|
}, [syncBlockNodes, syncBlockStoreManager.referenceManager]);
|
|
61
62
|
return (0, _react.useCallback)(function (props) {
|
|
62
63
|
return /*#__PURE__*/_react.default.createElement(_errorBoundary.ErrorBoundary, {
|
|
63
|
-
component:
|
|
64
|
+
component: _enums.ACTION_SUBJECT.SYNCED_BLOCK,
|
|
64
65
|
dispatchAnalyticsEvent: fireAnalyticsEvent,
|
|
65
66
|
fallbackComponent: null
|
|
66
|
-
}, /*#__PURE__*/_react.default.createElement(
|
|
67
|
+
}, /*#__PURE__*/_react.default.createElement(_SyncBlockActionsContext.SyncBlockActionsProvider
|
|
67
68
|
// eslint-disable-next-line @atlassian/perf-linting/no-unstable-inline-props -- Ignored via go/ees017 (to be fixed)
|
|
68
69
|
, {
|
|
69
70
|
fetchSyncBlockSourceInfo: function fetchSyncBlockSourceInfo(sourceAri) {
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React, { memo, useMemo } from 'react';
|
|
3
3
|
import { useIntl } from 'react-intl';
|
|
4
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
4
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
5
5
|
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
6
|
-
import { ReactRenderer, ValidationContextProvider, defaultNodeComponents } from '@atlaskit/renderer';
|
|
7
6
|
import { RendererActionsContext } from '@atlaskit/renderer/actions/renderer-actions-context';
|
|
7
|
+
import { nodeToReact as defaultNodeComponents } from '@atlaskit/renderer/nodes';
|
|
8
|
+
import ReactRenderer from '@atlaskit/renderer/renderer';
|
|
8
9
|
import { RendererContextProvider } from '@atlaskit/renderer/renderer-context';
|
|
10
|
+
import { ValidationContextProvider } from '@atlaskit/renderer/validation-context';
|
|
9
11
|
import Tooltip from '@atlaskit/tooltip/Tooltip';
|
|
10
12
|
const ValidationContextWrapper = ({
|
|
11
13
|
children
|
|
@@ -3,8 +3,8 @@ import "./SyncedBlockEntityNotFoundError.compiled.css";
|
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl';
|
|
6
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
7
|
-
import { SYNCED_BLOCKS_DOCUMENTATION_URL } from '@atlaskit/editor-common/sync-block';
|
|
6
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
7
|
+
import { SYNCED_BLOCKS_DOCUMENTATION_URL } from '@atlaskit/editor-common/sync-block/constants';
|
|
8
8
|
import LinkBrokenIcon from '@atlaskit/icon/core/link-broken';
|
|
9
9
|
import { Anchor } from '@atlaskit/primitives/compiled';
|
|
10
10
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React, { useMemo, useEffect } from 'react';
|
|
2
|
-
import { logException } from '@atlaskit/editor-common/monitoring';
|
|
3
|
-
import { SyncBlockSharedCssClassName } from '@atlaskit/editor-common/sync-block';
|
|
4
|
-
import {
|
|
5
|
-
import { buildFetchErrorAttribution } from '@atlaskit/editor-synced-block-provider/errorHandling';
|
|
6
|
-
import { getSourceProductFromResourceIdSafe } from '@atlaskit/editor-synced-block-provider/utils';
|
|
2
|
+
import { logException } from '@atlaskit/editor-common/monitoring/error';
|
|
3
|
+
import { SyncBlockSharedCssClassName } from '@atlaskit/editor-common/styles/sync-block';
|
|
4
|
+
import { SyncBlockError } from '@atlaskit/editor-synced-block-provider/common/types';
|
|
5
|
+
import { buildFetchErrorAttribution, fetchErrorPayload } from '@atlaskit/editor-synced-block-provider/errorHandling';
|
|
6
|
+
import { getSourceProductFromResourceIdSafe, getContentIdAndProductFromResourceId } from '@atlaskit/editor-synced-block-provider/utils';
|
|
7
7
|
import { SyncedBlockEntityNotFoundError } from './SyncedBlockEntityNotFoundError';
|
|
8
8
|
import { SyncedBlockGenericError } from './SyncedBlockGenericError';
|
|
9
9
|
import { SyncedBlockLoadError } from './SyncedBlockLoadError';
|
|
@@ -3,7 +3,8 @@ import "./SyncedBlockErrorStateCard.compiled.css";
|
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import WarningOutlineIcon from '@atlaskit/icon-lab/core/warning-outline';
|
|
6
|
-
import { Box
|
|
6
|
+
import { Box } from '@atlaskit/primitives/compiled/box';
|
|
7
|
+
import { Text } from '@atlaskit/primitives/compiled/text';
|
|
7
8
|
const styles = {
|
|
8
9
|
wrapper: "_zulppxbi _1rjc12x7 _bozgpxbi _1e0c1txw _1bahv2br _4cvr1h6o",
|
|
9
10
|
container: "_1e0c1txw"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { useIntl } from 'react-intl';
|
|
3
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
3
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
4
4
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
5
5
|
export const SyncedBlockGenericError = () => {
|
|
6
6
|
const {
|
|
@@ -4,7 +4,7 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl';
|
|
6
6
|
import Button from '@atlaskit/button/default/button';
|
|
7
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
7
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
8
8
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
9
9
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
10
10
|
const styles = {
|
|
@@ -3,8 +3,8 @@ import "./SyncedBlockLoadingState.compiled.css";
|
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl';
|
|
6
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
7
|
-
import { SyncBlockSharedCssClassName } from '@atlaskit/editor-common/sync-block';
|
|
6
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
7
|
+
import { SyncBlockSharedCssClassName } from '@atlaskit/editor-common/styles/sync-block';
|
|
8
8
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
9
9
|
import Spinner from '@atlaskit/spinner/spinner';
|
|
10
10
|
const styles = {
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import React, { useEffect, useMemo } from 'react';
|
|
2
|
-
import { isSSR } from '@atlaskit/editor-common/
|
|
3
|
-
import { SyncBlockSharedCssClassName, SyncBlockRendererDataAttributeName
|
|
4
|
-
import {
|
|
2
|
+
import { isSSR } from '@atlaskit/editor-common/is-ssr';
|
|
3
|
+
import { SyncBlockSharedCssClassName, SyncBlockRendererDataAttributeName } from '@atlaskit/editor-common/styles/sync-block';
|
|
4
|
+
import { handleSSRErrorsAnalytics } from '@atlaskit/editor-common/sync-block/ssr_error';
|
|
5
|
+
import { SyncBlockError } from '@atlaskit/editor-synced-block-provider/common/types';
|
|
6
|
+
import { useFetchSyncBlockData } from '@atlaskit/editor-synced-block-provider/useFetchSyncBlockData';
|
|
5
7
|
import { renderSyncedBlockContent } from './renderSyncedBlockContent';
|
|
6
8
|
export const SyncedBlockNodeComponentRenderer = ({
|
|
7
9
|
nodeProps,
|
|
@@ -4,8 +4,9 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
4
4
|
import React, { useEffect, useState } from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl';
|
|
6
6
|
import IconButton from '@atlaskit/button/icon/button';
|
|
7
|
-
import commonMessages
|
|
8
|
-
import {
|
|
7
|
+
import commonMessages from '@atlaskit/editor-common/messages';
|
|
8
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
9
|
+
import { useSyncBlockActions } from '@atlaskit/editor-common/sync-block/SyncBlockActionsContext';
|
|
9
10
|
import CrossIcon from '@atlaskit/icon/core/cross';
|
|
10
11
|
import EyeOpenStrikethroughIcon from '@atlaskit/icon/core/eye-open-strikethrough';
|
|
11
12
|
import LinkBrokenIcon from '@atlaskit/icon/core/link-broken';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { useIntl } from 'react-intl';
|
|
3
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
3
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
4
4
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
5
5
|
export const SyncedBlockOfflineError = () => {
|
|
6
6
|
const {
|
|
@@ -6,11 +6,12 @@ import React, { useCallback, useState } from 'react';
|
|
|
6
6
|
import { useIntl } from 'react-intl';
|
|
7
7
|
import { useMutation, graphql } from 'react-relay';
|
|
8
8
|
import Button from '@atlaskit/button/default/button';
|
|
9
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
9
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
10
10
|
import { requestJiraSpaceAccess } from '@atlaskit/editor-synced-block-provider/requestJiraIssueAccess';
|
|
11
11
|
import Heading from '@atlaskit/heading/heading';
|
|
12
12
|
import StatusSuccessIcon from '@atlaskit/icon/core/status-success';
|
|
13
13
|
import Image from '@atlaskit/image';
|
|
14
|
+
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
14
15
|
import { Text, Flex, Stack, Box } from '@atlaskit/primitives/compiled';
|
|
15
16
|
import PermissionDenied from './assets/PermissionDenied.svg';
|
|
16
17
|
import { SyncedBlockGenericError } from './SyncedBlockGenericError';
|
|
@@ -64,9 +65,9 @@ const SyncedBlockPermissionDeniedConfluencePage = ({
|
|
|
64
65
|
space: "space.100"
|
|
65
66
|
}, /*#__PURE__*/React.createElement(Heading, {
|
|
66
67
|
size: "xsmall"
|
|
67
|
-
}, formatMessage(messages.permissionDeniedHeading)), /*#__PURE__*/React.createElement(Text, {
|
|
68
|
+
}, formatMessage(isExperimentEnabled('platform_editor_blocks_patch_12') ? messages.contentUnavailableHeading : messages.permissionDeniedHeading)), /*#__PURE__*/React.createElement(Text, {
|
|
68
69
|
color: "color.text.subtle"
|
|
69
|
-
}, formatMessage(messages.permissionDeniedDescription)), requestAccessState === RequestAccessState.pending ? /*#__PURE__*/React.createElement(Flex, {
|
|
70
|
+
}, formatMessage(isExperimentEnabled('platform_editor_blocks_patch_12') ? messages.contentUnavailableDescription : messages.permissionDeniedDescription)), requestAccessState === RequestAccessState.pending ? /*#__PURE__*/React.createElement(Flex, {
|
|
70
71
|
columnGap: "space.050",
|
|
71
72
|
alignItems: "center"
|
|
72
73
|
}, /*#__PURE__*/React.createElement(StatusSuccessIcon, {
|
|
@@ -134,9 +135,9 @@ const SyncedBlockPermissionDeniedJiraWorkItem = ({
|
|
|
134
135
|
space: "space.100"
|
|
135
136
|
}, /*#__PURE__*/React.createElement(Heading, {
|
|
136
137
|
size: "xsmall"
|
|
137
|
-
}, formatMessage(messages.permissionDeniedHeading)), /*#__PURE__*/React.createElement(Text, {
|
|
138
|
+
}, formatMessage(isExperimentEnabled('platform_editor_blocks_patch_12') ? messages.contentUnavailableHeading : messages.permissionDeniedHeading)), /*#__PURE__*/React.createElement(Text, {
|
|
138
139
|
color: "color.text.subtle"
|
|
139
|
-
}, formatMessage(messages.permissionDeniedDescription)), requestAccessState === RequestAccessState.pending ? /*#__PURE__*/React.createElement(Flex, {
|
|
140
|
+
}, formatMessage(isExperimentEnabled('platform_editor_blocks_patch_12') ? messages.contentUnavailableDescription : messages.permissionDeniedDescription)), requestAccessState === RequestAccessState.pending ? /*#__PURE__*/React.createElement(Flex, {
|
|
140
141
|
columnGap: "space.050",
|
|
141
142
|
alignItems: "center"
|
|
142
143
|
}, /*#__PURE__*/React.createElement(StatusSuccessIcon, {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { memo, useEffect, useMemo } from 'react';
|
|
2
|
-
import { isSSR } from '@atlaskit/editor-common/
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
2
|
+
import { isSSR } from '@atlaskit/editor-common/is-ssr';
|
|
3
|
+
import { handleSSRErrorsAnalytics } from '@atlaskit/editor-common/sync-block/ssr_error';
|
|
4
|
+
import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/useSharedPluginStateWithSelector';
|
|
5
5
|
import { renderSyncedBlockContent } from './renderSyncedBlockContent';
|
|
6
6
|
const SyncedBlockRendererComponent = ({
|
|
7
7
|
syncBlockRendererOptions,
|
|
@@ -3,7 +3,7 @@ import "./SyncedBlockUnpublishedError.compiled.css";
|
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl';
|
|
6
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
6
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
7
7
|
import EyeOpenStrikethroughIcon from '@atlaskit/icon/core/eye-open-strikethrough';
|
|
8
8
|
import { Anchor } from '@atlaskit/primitives/compiled';
|
|
9
9
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { isSSR } from '@atlaskit/editor-common/
|
|
3
|
-
import { SyncBlockError } from '@atlaskit/editor-synced-block-provider';
|
|
2
|
+
import { isSSR } from '@atlaskit/editor-common/is-ssr';
|
|
3
|
+
import { SyncBlockError } from '@atlaskit/editor-synced-block-provider/common/types';
|
|
4
4
|
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
5
5
|
import { AKRendererWrapper } from './AKRendererWrapper';
|
|
6
6
|
import { SyncedBlockErrorComponent } from './SyncedBlockErrorComponent';
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import React, { useCallback, useEffect } from 'react';
|
|
2
|
-
import { ACTION_SUBJECT } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import { ACTION_SUBJECT } from '@atlaskit/editor-common/analytics/types/enums';
|
|
3
3
|
import { ErrorBoundary } from '@atlaskit/editor-common/error-boundary';
|
|
4
|
-
import { SyncBlockActionsProvider } from '@atlaskit/editor-common/sync-block';
|
|
5
|
-
import {
|
|
4
|
+
import { SyncBlockActionsProvider } from '@atlaskit/editor-common/sync-block/SyncBlockActionsContext';
|
|
5
|
+
import { useMemoizedSyncBlockStoreManager } from '@atlaskit/editor-synced-block-provider/syncBlockStoreManager';
|
|
6
|
+
import { convertSyncBlockJSONNodeToSyncBlockNode } from '@atlaskit/editor-synced-block-provider/utils';
|
|
6
7
|
import { SyncedBlockNodeComponentRenderer } from './ui/SyncedBlockNodeComponentRenderer';
|
|
7
8
|
export const getSyncBlockNodesFromDoc = doc => {
|
|
8
9
|
const {
|
|
@@ -6,11 +6,13 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
6
6
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
7
7
|
import React, { memo, useMemo } from 'react';
|
|
8
8
|
import { useIntl } from 'react-intl';
|
|
9
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
9
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
10
10
|
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
11
|
-
import { ReactRenderer, ValidationContextProvider, defaultNodeComponents } from '@atlaskit/renderer';
|
|
12
11
|
import { RendererActionsContext } from '@atlaskit/renderer/actions/renderer-actions-context';
|
|
12
|
+
import { nodeToReact as defaultNodeComponents } from '@atlaskit/renderer/nodes';
|
|
13
|
+
import ReactRenderer from '@atlaskit/renderer/renderer';
|
|
13
14
|
import { RendererContextProvider } from '@atlaskit/renderer/renderer-context';
|
|
15
|
+
import { ValidationContextProvider } from '@atlaskit/renderer/validation-context';
|
|
14
16
|
import Tooltip from '@atlaskit/tooltip/Tooltip';
|
|
15
17
|
var ValidationContextWrapper = function ValidationContextWrapper(_ref) {
|
|
16
18
|
var children = _ref.children;
|
|
@@ -3,8 +3,8 @@ import "./SyncedBlockEntityNotFoundError.compiled.css";
|
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl';
|
|
6
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
7
|
-
import { SYNCED_BLOCKS_DOCUMENTATION_URL } from '@atlaskit/editor-common/sync-block';
|
|
6
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
7
|
+
import { SYNCED_BLOCKS_DOCUMENTATION_URL } from '@atlaskit/editor-common/sync-block/constants';
|
|
8
8
|
import LinkBrokenIcon from '@atlaskit/icon/core/link-broken';
|
|
9
9
|
import { Anchor } from '@atlaskit/primitives/compiled';
|
|
10
10
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React, { useMemo, useEffect } from 'react';
|
|
2
|
-
import { logException } from '@atlaskit/editor-common/monitoring';
|
|
3
|
-
import { SyncBlockSharedCssClassName } from '@atlaskit/editor-common/sync-block';
|
|
4
|
-
import {
|
|
5
|
-
import { buildFetchErrorAttribution } from '@atlaskit/editor-synced-block-provider/errorHandling';
|
|
6
|
-
import { getSourceProductFromResourceIdSafe } from '@atlaskit/editor-synced-block-provider/utils';
|
|
2
|
+
import { logException } from '@atlaskit/editor-common/monitoring/error';
|
|
3
|
+
import { SyncBlockSharedCssClassName } from '@atlaskit/editor-common/styles/sync-block';
|
|
4
|
+
import { SyncBlockError } from '@atlaskit/editor-synced-block-provider/common/types';
|
|
5
|
+
import { buildFetchErrorAttribution, fetchErrorPayload } from '@atlaskit/editor-synced-block-provider/errorHandling';
|
|
6
|
+
import { getSourceProductFromResourceIdSafe, getContentIdAndProductFromResourceId } from '@atlaskit/editor-synced-block-provider/utils';
|
|
7
7
|
import { SyncedBlockEntityNotFoundError } from './SyncedBlockEntityNotFoundError';
|
|
8
8
|
import { SyncedBlockGenericError } from './SyncedBlockGenericError';
|
|
9
9
|
import { SyncedBlockLoadError } from './SyncedBlockLoadError';
|
|
@@ -3,7 +3,8 @@ import "./SyncedBlockErrorStateCard.compiled.css";
|
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import WarningOutlineIcon from '@atlaskit/icon-lab/core/warning-outline';
|
|
6
|
-
import { Box
|
|
6
|
+
import { Box } from '@atlaskit/primitives/compiled/box';
|
|
7
|
+
import { Text } from '@atlaskit/primitives/compiled/text';
|
|
7
8
|
var styles = {
|
|
8
9
|
wrapper: "_zulppxbi _1rjc12x7 _bozgpxbi _1e0c1txw _1bahv2br _4cvr1h6o",
|
|
9
10
|
container: "_1e0c1txw"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { useIntl } from 'react-intl';
|
|
3
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
3
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
4
4
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
5
5
|
export var SyncedBlockGenericError = function SyncedBlockGenericError() {
|
|
6
6
|
var _useIntl = useIntl(),
|
|
@@ -4,7 +4,7 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl';
|
|
6
6
|
import Button from '@atlaskit/button/default/button';
|
|
7
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
7
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
8
8
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
9
9
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
10
10
|
var styles = {
|
|
@@ -3,8 +3,8 @@ import "./SyncedBlockLoadingState.compiled.css";
|
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl';
|
|
6
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
7
|
-
import { SyncBlockSharedCssClassName } from '@atlaskit/editor-common/sync-block';
|
|
6
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
7
|
+
import { SyncBlockSharedCssClassName } from '@atlaskit/editor-common/styles/sync-block';
|
|
8
8
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
9
9
|
import Spinner from '@atlaskit/spinner/spinner';
|
|
10
10
|
var styles = {
|
|
@@ -3,9 +3,11 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
3
3
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4
4
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
5
5
|
import React, { useEffect, useMemo } from 'react';
|
|
6
|
-
import { isSSR } from '@atlaskit/editor-common/
|
|
7
|
-
import { SyncBlockSharedCssClassName, SyncBlockRendererDataAttributeName
|
|
8
|
-
import {
|
|
6
|
+
import { isSSR } from '@atlaskit/editor-common/is-ssr';
|
|
7
|
+
import { SyncBlockSharedCssClassName, SyncBlockRendererDataAttributeName } from '@atlaskit/editor-common/styles/sync-block';
|
|
8
|
+
import { handleSSRErrorsAnalytics } from '@atlaskit/editor-common/sync-block/ssr_error';
|
|
9
|
+
import { SyncBlockError } from '@atlaskit/editor-synced-block-provider/common/types';
|
|
10
|
+
import { useFetchSyncBlockData } from '@atlaskit/editor-synced-block-provider/useFetchSyncBlockData';
|
|
9
11
|
import { renderSyncedBlockContent } from './renderSyncedBlockContent';
|
|
10
12
|
export var SyncedBlockNodeComponentRenderer = function SyncedBlockNodeComponentRenderer(_ref) {
|
|
11
13
|
var _syncBlockInstance$er, _syncBlockInstance$da, _syncBlockInstance$da2;
|
|
@@ -7,8 +7,9 @@ import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
|
7
7
|
import React, { useEffect, useState } from 'react';
|
|
8
8
|
import { useIntl } from 'react-intl';
|
|
9
9
|
import IconButton from '@atlaskit/button/icon/button';
|
|
10
|
-
import commonMessages
|
|
11
|
-
import {
|
|
10
|
+
import commonMessages from '@atlaskit/editor-common/messages';
|
|
11
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
12
|
+
import { useSyncBlockActions } from '@atlaskit/editor-common/sync-block/SyncBlockActionsContext';
|
|
12
13
|
import CrossIcon from '@atlaskit/icon/core/cross';
|
|
13
14
|
import EyeOpenStrikethroughIcon from '@atlaskit/icon/core/eye-open-strikethrough';
|
|
14
15
|
import LinkBrokenIcon from '@atlaskit/icon/core/link-broken';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { useIntl } from 'react-intl';
|
|
3
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
3
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
4
4
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
5
5
|
export var SyncedBlockOfflineError = function SyncedBlockOfflineError() {
|
|
6
6
|
var _useIntl = useIntl(),
|
|
@@ -9,11 +9,12 @@ import React, { useCallback, useState } from 'react';
|
|
|
9
9
|
import { useIntl } from 'react-intl';
|
|
10
10
|
import { useMutation, graphql } from 'react-relay';
|
|
11
11
|
import Button from '@atlaskit/button/default/button';
|
|
12
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
12
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
13
13
|
import { requestJiraSpaceAccess } from '@atlaskit/editor-synced-block-provider/requestJiraIssueAccess';
|
|
14
14
|
import Heading from '@atlaskit/heading/heading';
|
|
15
15
|
import StatusSuccessIcon from '@atlaskit/icon/core/status-success';
|
|
16
16
|
import Image from '@atlaskit/image';
|
|
17
|
+
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
17
18
|
import { Text, Flex, Stack, Box } from '@atlaskit/primitives/compiled';
|
|
18
19
|
import PermissionDenied from './assets/PermissionDenied.svg';
|
|
19
20
|
import { SyncedBlockGenericError } from './SyncedBlockGenericError';
|
|
@@ -70,9 +71,9 @@ var SyncedBlockPermissionDeniedConfluencePage = function SyncedBlockPermissionDe
|
|
|
70
71
|
space: "space.100"
|
|
71
72
|
}, /*#__PURE__*/React.createElement(Heading, {
|
|
72
73
|
size: "xsmall"
|
|
73
|
-
}, formatMessage(messages.permissionDeniedHeading)), /*#__PURE__*/React.createElement(Text, {
|
|
74
|
+
}, formatMessage(isExperimentEnabled('platform_editor_blocks_patch_12') ? messages.contentUnavailableHeading : messages.permissionDeniedHeading)), /*#__PURE__*/React.createElement(Text, {
|
|
74
75
|
color: "color.text.subtle"
|
|
75
|
-
}, formatMessage(messages.permissionDeniedDescription)), requestAccessState === RequestAccessState.pending ? /*#__PURE__*/React.createElement(Flex, {
|
|
76
|
+
}, formatMessage(isExperimentEnabled('platform_editor_blocks_patch_12') ? messages.contentUnavailableDescription : messages.permissionDeniedDescription)), requestAccessState === RequestAccessState.pending ? /*#__PURE__*/React.createElement(Flex, {
|
|
76
77
|
columnGap: "space.050",
|
|
77
78
|
alignItems: "center"
|
|
78
79
|
}, /*#__PURE__*/React.createElement(StatusSuccessIcon, {
|
|
@@ -155,9 +156,9 @@ var SyncedBlockPermissionDeniedJiraWorkItem = function SyncedBlockPermissionDeni
|
|
|
155
156
|
space: "space.100"
|
|
156
157
|
}, /*#__PURE__*/React.createElement(Heading, {
|
|
157
158
|
size: "xsmall"
|
|
158
|
-
}, formatMessage(messages.permissionDeniedHeading)), /*#__PURE__*/React.createElement(Text, {
|
|
159
|
+
}, formatMessage(isExperimentEnabled('platform_editor_blocks_patch_12') ? messages.contentUnavailableHeading : messages.permissionDeniedHeading)), /*#__PURE__*/React.createElement(Text, {
|
|
159
160
|
color: "color.text.subtle"
|
|
160
|
-
}, formatMessage(messages.permissionDeniedDescription)), requestAccessState === RequestAccessState.pending ? /*#__PURE__*/React.createElement(Flex, {
|
|
161
|
+
}, formatMessage(isExperimentEnabled('platform_editor_blocks_patch_12') ? messages.contentUnavailableDescription : messages.permissionDeniedDescription)), requestAccessState === RequestAccessState.pending ? /*#__PURE__*/React.createElement(Flex, {
|
|
161
162
|
columnGap: "space.050",
|
|
162
163
|
alignItems: "center"
|
|
163
164
|
}, /*#__PURE__*/React.createElement(StatusSuccessIcon, {
|
|
@@ -2,9 +2,9 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
import { memo, useEffect, useMemo } from 'react';
|
|
5
|
-
import { isSSR } from '@atlaskit/editor-common/
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
5
|
+
import { isSSR } from '@atlaskit/editor-common/is-ssr';
|
|
6
|
+
import { handleSSRErrorsAnalytics } from '@atlaskit/editor-common/sync-block/ssr_error';
|
|
7
|
+
import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/useSharedPluginStateWithSelector';
|
|
8
8
|
import { renderSyncedBlockContent } from './renderSyncedBlockContent';
|
|
9
9
|
var SyncedBlockRendererComponent = function SyncedBlockRendererComponent(_ref) {
|
|
10
10
|
var _api$analytics2;
|
|
@@ -3,7 +3,7 @@ import "./SyncedBlockUnpublishedError.compiled.css";
|
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl';
|
|
6
|
-
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
6
|
+
import { syncBlockMessages as messages } from '@atlaskit/editor-common/messages/syncBlock';
|
|
7
7
|
import EyeOpenStrikethroughIcon from '@atlaskit/icon/core/eye-open-strikethrough';
|
|
8
8
|
import { Anchor } from '@atlaskit/primitives/compiled';
|
|
9
9
|
import { SyncedBlockErrorStateCard } from './SyncedBlockErrorStateCard';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { isSSR } from '@atlaskit/editor-common/
|
|
3
|
-
import { SyncBlockError } from '@atlaskit/editor-synced-block-provider';
|
|
2
|
+
import { isSSR } from '@atlaskit/editor-common/is-ssr';
|
|
3
|
+
import { SyncBlockError } from '@atlaskit/editor-synced-block-provider/common/types';
|
|
4
4
|
import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
|
|
5
5
|
import { AKRendererWrapper } from './AKRendererWrapper';
|
|
6
6
|
import { SyncedBlockErrorComponent } from './SyncedBlockErrorComponent';
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import React, { useCallback, useEffect } from 'react';
|
|
2
|
-
import { ACTION_SUBJECT } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import { ACTION_SUBJECT } from '@atlaskit/editor-common/analytics/types/enums';
|
|
3
3
|
import { ErrorBoundary } from '@atlaskit/editor-common/error-boundary';
|
|
4
|
-
import { SyncBlockActionsProvider } from '@atlaskit/editor-common/sync-block';
|
|
5
|
-
import {
|
|
4
|
+
import { SyncBlockActionsProvider } from '@atlaskit/editor-common/sync-block/SyncBlockActionsContext';
|
|
5
|
+
import { useMemoizedSyncBlockStoreManager } from '@atlaskit/editor-synced-block-provider/syncBlockStoreManager';
|
|
6
|
+
import { convertSyncBlockJSONNodeToSyncBlockNode } from '@atlaskit/editor-synced-block-provider/utils';
|
|
6
7
|
import { SyncedBlockNodeComponentRenderer } from './ui/SyncedBlockNodeComponentRenderer';
|
|
7
8
|
export var getSyncBlockNodesFromDoc = function getSyncBlockNodesFromDoc(doc) {
|
|
8
9
|
var content = doc.content;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { SyncedBlockRendererProps } from '@atlaskit/editor-plugin-synced-block';
|
|
2
|
+
import type { SyncedBlockRendererProps } from '@atlaskit/editor-plugin-synced-block/synced-block-plugin-type';
|
|
3
3
|
import type { SyncedBlockRendererOptions } from './types';
|
|
4
4
|
type GetSyncedBlockRendererProps = {
|
|
5
5
|
getAccountId?: () => string | null;
|
package/dist/types/types.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { RendererProps } from '@atlaskit/renderer';
|
|
1
|
+
import type { RendererProps } from '@atlaskit/renderer/renderer-props';
|
|
2
2
|
export type SyncedBlockRendererOptions = Pick<RendererProps, 'appearance' | 'allowAltTextOnImages' | 'allowAnnotations' | 'allowColumnSorting' | 'allowCopyToClipboard' | 'allowCustomPanels' | 'allowHeadingAnchorLinks' | 'allowPlaceholderText' | 'allowRendererContainerStyles' | 'allowSelectAllTrap' | 'allowUgcScrubber' | 'allowWrapCodeBlock' | 'emojiResourceConfig' | 'eventHandlers' | 'media' | 'mentionNodeDataProvider' | 'smartLinks' | 'stickyHeaders' | 'contentMode'>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { DocNode } from '@atlaskit/adf-schema/doc';
|
|
3
|
-
import type
|
|
3
|
+
import type ProviderFactory from '@atlaskit/editor-common/provider-factory/provider-factory';
|
|
4
4
|
import type { SyncedBlockRendererOptions } from '../types';
|
|
5
5
|
export declare const AKRendererWrapper: React.MemoExoticComponent<({ doc, dataProviders, options, headingIdPrefix, }: {
|
|
6
6
|
dataProviders: ProviderFactory | undefined;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { RendererSyncBlockEventPayload } from '@atlaskit/editor-common/analytics';
|
|
3
|
-
import type { SyncBlockInstance } from '@atlaskit/editor-synced-block-provider';
|
|
2
|
+
import type { RendererSyncBlockEventPayload } from '@atlaskit/editor-common/analytics/types/sync-block-events';
|
|
3
|
+
import type { SyncBlockInstance } from '@atlaskit/editor-synced-block-provider/providers/types';
|
|
4
4
|
export declare const SyncedBlockErrorComponent: ({ error, isLoading, onRetry, resourceId, fireAnalyticsEvent, sourceURL, getAccountId, }: {
|
|
5
5
|
error: SyncBlockInstance['error'];
|
|
6
6
|
fireAnalyticsEvent?: (payload: RendererSyncBlockEventPayload) => void;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { SyncBlockStoreManager } from '@atlaskit/editor-synced-block-provider';
|
|
3
|
-
import type { NodeProps } from '@atlaskit/renderer';
|
|
2
|
+
import type { SyncBlockStoreManager } from '@atlaskit/editor-synced-block-provider/syncBlockStoreManager';
|
|
3
|
+
import type { NodeProps } from '@atlaskit/renderer/react/types';
|
|
4
4
|
import type { SyncedBlockRendererOptions } from '../types';
|
|
5
5
|
export interface SyncedBlockProps {
|
|
6
6
|
localId?: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { SyncBlockProduct } from '@atlaskit/editor-synced-block-provider';
|
|
2
|
+
import type { SyncBlockProduct } from '@atlaskit/editor-synced-block-provider/common/types';
|
|
3
3
|
export interface SyncedBlockPermissionDeniedProps {
|
|
4
4
|
accountId: string | null;
|
|
5
5
|
sourceContentId: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
3
|
-
import type { SyncedBlockPlugin } from '@atlaskit/editor-plugin-synced-block';
|
|
4
|
-
import type { UseFetchSyncBlockDataResult } from '@atlaskit/editor-synced-block-provider';
|
|
2
|
+
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types/next-editor-plugin';
|
|
3
|
+
import type { SyncedBlockPlugin } from '@atlaskit/editor-plugin-synced-block/synced-block-plugin-type';
|
|
4
|
+
import type { UseFetchSyncBlockDataResult } from '@atlaskit/editor-synced-block-provider/useFetchSyncBlockData';
|
|
5
5
|
import type { SyncedBlockRendererOptions } from '../types';
|
|
6
6
|
export type SyncedBlockRendererProps = {
|
|
7
7
|
api?: ExtractInjectionAPI<SyncedBlockPlugin>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { SyncBlockProduct } from '@atlaskit/editor-synced-block-provider';
|
|
2
|
+
import type { SyncBlockProduct } from '@atlaskit/editor-synced-block-provider/common/types';
|
|
3
3
|
export declare const SyncedBlockUnpublishedError: ({ sourceURL, sourceProduct, }: {
|
|
4
4
|
sourceProduct?: SyncBlockProduct;
|
|
5
5
|
sourceURL?: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { RendererSyncBlockEventPayload } from '@atlaskit/editor-common/analytics';
|
|
3
|
-
import type
|
|
4
|
-
import type { SyncBlockInstance } from '@atlaskit/editor-synced-block-provider';
|
|
2
|
+
import type { RendererSyncBlockEventPayload } from '@atlaskit/editor-common/analytics/types/sync-block-events';
|
|
3
|
+
import type ProviderFactory from '@atlaskit/editor-common/provider-factory/provider-factory';
|
|
4
|
+
import type { SyncBlockInstance } from '@atlaskit/editor-synced-block-provider/providers/types';
|
|
5
5
|
import type { SyncedBlockRendererOptions } from '../types';
|
|
6
6
|
export type RenderSyncedBlockContentParams = {
|
|
7
7
|
error?: SyncBlockInstance['error'];
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { DocNode } from '@atlaskit/adf-schema/doc';
|
|
3
|
-
import type { AnalyticsEventPayload } from '@atlaskit/editor-common/analytics';
|
|
4
|
-
import type { SyncBlockNode,
|
|
3
|
+
import type { AnalyticsEventPayload } from '@atlaskit/editor-common/analytics/types/events';
|
|
4
|
+
import type { SyncBlockNode, SyncBlockPrefetchData } from '@atlaskit/editor-synced-block-provider/common/types';
|
|
5
|
+
import type { SyncedBlockProvider } from '@atlaskit/editor-synced-block-provider/syncBlockProvider';
|
|
5
6
|
import type { SyncedBlockRendererOptions } from './types';
|
|
6
7
|
import type { SyncedBlockNodeProps } from './ui/SyncedBlockNodeComponentRenderer';
|
|
7
8
|
export type GetSyncedBlockNodeComponentProps = {
|