@atlaskit/renderer 109.32.5 → 109.33.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +18 -0
- package/dist/cjs/actions/index.js +14 -0
- package/dist/cjs/react/marks/alignment.js +1 -0
- package/dist/cjs/react/marks/border.js +1 -0
- package/dist/cjs/react/marks/breakout.js +1 -0
- package/dist/cjs/react/marks/link.js +2 -0
- package/dist/cjs/react/nodes/blockCard.js +2 -0
- package/dist/cjs/react/nodes/codeBlock/codeBlock.js +2 -0
- package/dist/cjs/react/nodes/codeBlock/components/codeBlockButtonContainer.js +1 -0
- package/dist/cjs/react/nodes/codeBlock/components/codeBlockContainer.js +1 -0
- package/dist/cjs/react/nodes/codeBlock/components/codeBlockCopyButton.js +1 -0
- package/dist/cjs/react/nodes/codeBlock/components/codeBlockWrapButton.js +1 -0
- package/dist/cjs/react/nodes/codeBlock/components/lightWeightCodeBlock.js +1 -0
- package/dist/cjs/react/nodes/codeBlock/windowedCodeBlock.js +1 -1
- package/dist/cjs/react/nodes/embedCard.js +1 -0
- package/dist/cjs/react/nodes/emoji.js +1 -0
- package/dist/cjs/react/nodes/extensionFrame.js +2 -0
- package/dist/cjs/react/nodes/heading-anchor.js +1 -0
- package/dist/cjs/react/nodes/inlineCard.js +1 -0
- package/dist/cjs/react/nodes/layoutColumn.js +2 -0
- package/dist/cjs/react/nodes/media/index.js +1 -0
- package/dist/cjs/react/nodes/mediaSingle/index.js +2 -0
- package/dist/cjs/react/nodes/mediaSingle/styles.js +1 -0
- package/dist/cjs/react/nodes/multiBodiedExtension.js +2 -1
- package/dist/cjs/react/nodes/panel.js +1 -0
- package/dist/cjs/react/nodes/table/sticky.js +4 -0
- package/dist/cjs/ui/Expand.js +1 -0
- package/dist/cjs/ui/ExtensionRenderer.js +1 -1
- package/dist/cjs/ui/Renderer/index.js +2 -2
- package/dist/cjs/ui/Renderer/style.js +2 -0
- package/dist/cjs/ui/Renderer/truncated-wrapper.js +1 -1
- package/dist/cjs/ui/annotations/draft/component.js +2 -0
- package/dist/cjs/ui/annotations/element/mark.js +1 -0
- package/dist/cjs/ui/annotations/view/index.js +9 -1
- package/dist/es2019/actions/index.js +13 -1
- package/dist/es2019/react/marks/alignment.js +1 -0
- package/dist/es2019/react/marks/border.js +1 -0
- package/dist/es2019/react/marks/breakout.js +1 -0
- package/dist/es2019/react/marks/link.js +1 -0
- package/dist/es2019/react/nodes/blockCard.js +1 -0
- package/dist/es2019/react/nodes/codeBlock/codeBlock.js +1 -0
- package/dist/es2019/react/nodes/codeBlock/components/codeBlockButtonContainer.js +1 -0
- package/dist/es2019/react/nodes/codeBlock/components/codeBlockContainer.js +1 -0
- package/dist/es2019/react/nodes/codeBlock/components/codeBlockCopyButton.js +1 -0
- package/dist/es2019/react/nodes/codeBlock/components/codeBlockWrapButton.js +1 -0
- package/dist/es2019/react/nodes/codeBlock/components/lightWeightCodeBlock.js +1 -0
- package/dist/es2019/react/nodes/codeBlock/windowedCodeBlock.js +1 -0
- package/dist/es2019/react/nodes/embedCard.js +1 -0
- package/dist/es2019/react/nodes/emoji.js +1 -0
- package/dist/es2019/react/nodes/extensionFrame.js +1 -0
- package/dist/es2019/react/nodes/heading-anchor.js +1 -0
- package/dist/es2019/react/nodes/inlineCard.js +1 -0
- package/dist/es2019/react/nodes/layoutColumn.js +1 -0
- package/dist/es2019/react/nodes/media/index.js +1 -0
- package/dist/es2019/react/nodes/mediaSingle/index.js +1 -0
- package/dist/es2019/react/nodes/mediaSingle/styles.js +1 -0
- package/dist/es2019/react/nodes/multiBodiedExtension.js +2 -1
- package/dist/es2019/react/nodes/panel.js +1 -0
- package/dist/es2019/react/nodes/table/sticky.js +3 -0
- package/dist/es2019/ui/Expand.js +1 -0
- package/dist/es2019/ui/ExtensionRenderer.js +1 -0
- package/dist/es2019/ui/Renderer/index.js +2 -1
- package/dist/es2019/ui/Renderer/style.js +2 -0
- package/dist/es2019/ui/Renderer/truncated-wrapper.js +1 -0
- package/dist/es2019/ui/annotations/draft/component.js +1 -0
- package/dist/es2019/ui/annotations/element/mark.js +1 -0
- package/dist/es2019/ui/annotations/view/index.js +8 -2
- package/dist/esm/actions/index.js +15 -1
- package/dist/esm/react/marks/alignment.js +1 -0
- package/dist/esm/react/marks/border.js +1 -0
- package/dist/esm/react/marks/breakout.js +1 -0
- package/dist/esm/react/marks/link.js +1 -0
- package/dist/esm/react/nodes/blockCard.js +1 -0
- package/dist/esm/react/nodes/codeBlock/codeBlock.js +1 -0
- package/dist/esm/react/nodes/codeBlock/components/codeBlockButtonContainer.js +1 -0
- package/dist/esm/react/nodes/codeBlock/components/codeBlockContainer.js +1 -0
- package/dist/esm/react/nodes/codeBlock/components/codeBlockCopyButton.js +1 -0
- package/dist/esm/react/nodes/codeBlock/components/codeBlockWrapButton.js +1 -0
- package/dist/esm/react/nodes/codeBlock/components/lightWeightCodeBlock.js +1 -0
- package/dist/esm/react/nodes/codeBlock/windowedCodeBlock.js +1 -0
- package/dist/esm/react/nodes/embedCard.js +1 -0
- package/dist/esm/react/nodes/emoji.js +1 -0
- package/dist/esm/react/nodes/extensionFrame.js +1 -0
- package/dist/esm/react/nodes/heading-anchor.js +1 -0
- package/dist/esm/react/nodes/inlineCard.js +1 -0
- package/dist/esm/react/nodes/layoutColumn.js +1 -0
- package/dist/esm/react/nodes/media/index.js +1 -0
- package/dist/esm/react/nodes/mediaSingle/index.js +1 -0
- package/dist/esm/react/nodes/mediaSingle/styles.js +1 -0
- package/dist/esm/react/nodes/multiBodiedExtension.js +2 -1
- package/dist/esm/react/nodes/panel.js +1 -0
- package/dist/esm/react/nodes/table/sticky.js +3 -0
- package/dist/esm/ui/Expand.js +1 -0
- package/dist/esm/ui/ExtensionRenderer.js +1 -0
- package/dist/esm/ui/Renderer/index.js +2 -1
- package/dist/esm/ui/Renderer/style.js +2 -0
- package/dist/esm/ui/Renderer/truncated-wrapper.js +1 -0
- package/dist/esm/ui/annotations/draft/component.js +1 -0
- package/dist/esm/ui/annotations/element/mark.js +1 -0
- package/dist/esm/ui/annotations/view/index.js +10 -2
- package/dist/types/actions/index.d.ts +1 -0
- package/dist/types-ts4.5/actions/index.d.ts +1 -0
- package/package.json +10 -10
|
@@ -2,8 +2,9 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
/* eslint-disable @atlaskit/design-system/prefer-primitives */
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
|
|
5
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
5
6
|
import { jsx } from '@emotion/react';
|
|
6
|
-
// eslint-disable-next-line @typescript-eslint/no-duplicate-imports
|
|
7
|
+
// eslint-disable-next-line @typescript-eslint/no-duplicate-imports, @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
7
8
|
import { css } from '@emotion/react';
|
|
8
9
|
import { N40 } from '@atlaskit/theme/colors';
|
|
9
10
|
import React, { useState } from 'react';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/** @jsx jsx */
|
|
3
3
|
import React from 'react';
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
5
|
import { css, jsx } from '@emotion/react';
|
|
5
6
|
import TipIcon from '@atlaskit/icon/glyph/editor/hint';
|
|
6
7
|
import { PanelType } from '@atlaskit/adf-schema';
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/** @jsx jsx */
|
|
3
3
|
import React from 'react';
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
5
|
+
|
|
6
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
7
|
import { css, jsx } from '@emotion/react';
|
|
5
8
|
import { TableSharedCssClassName } from '@atlaskit/editor-common/styles';
|
|
6
9
|
import { akEditorStickyHeaderZIndex } from '@atlaskit/editor-shared-styles';
|
package/dist/es2019/ui/Expand.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/** @jsx jsx */
|
|
3
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
3
4
|
import { css, jsx } from '@emotion/react';
|
|
4
5
|
import React, { useCallback, useMemo, useRef } from 'react';
|
|
5
6
|
// eslint-disable-next-line @atlaskit/design-system/no-deprecated-imports
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
2
|
/** @jsx jsx */
|
|
3
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
3
4
|
import { css, jsx } from '@emotion/react';
|
|
4
5
|
import React, { Fragment } from 'react';
|
|
5
6
|
import memoizeOne from 'memoize-one';
|
|
@@ -2,6 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
import React, { Fragment, useContext, useLayoutEffect, useRef, PureComponent } from 'react';
|
|
5
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
5
6
|
import { jsx } from '@emotion/react';
|
|
6
7
|
import { getSchemaBasedOnStage } from '@atlaskit/adf-schema/schema-default';
|
|
7
8
|
import { reduce } from '@atlaskit/adf-utils/traverse';
|
|
@@ -37,7 +38,7 @@ import { nodeToReact } from '../../react/nodes';
|
|
|
37
38
|
export const NORMAL_SEVERITY_THRESHOLD = 2000;
|
|
38
39
|
export const DEGRADED_SEVERITY_THRESHOLD = 3000;
|
|
39
40
|
const packageName = "@atlaskit/renderer";
|
|
40
|
-
const packageVersion = "109.
|
|
41
|
+
const packageVersion = "109.33.1";
|
|
41
42
|
export const defaultNodeComponents = nodeToReact;
|
|
42
43
|
export class Renderer extends PureComponent {
|
|
43
44
|
constructor(props) {
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/design-system/no-css-tagged-template-expression -- needs manual remediation */
|
|
2
2
|
/* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
|
|
3
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
3
4
|
|
|
5
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
6
|
import { css } from '@emotion/react';
|
|
5
7
|
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
6
8
|
import { fontFamily, fontSize } from '@atlaskit/theme/constants';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/** @jsx jsx */
|
|
3
3
|
import React, { Fragment } from 'react';
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
5
|
import { css, jsx } from '@emotion/react';
|
|
5
6
|
import { InsertDraftPosition } from '../types';
|
|
6
7
|
import { AnnotationsDraftContext } from '../context';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
2
|
|
|
3
3
|
import { useMemo, useCallback } from 'react';
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
5
|
import { css, jsx } from '@emotion/react';
|
|
5
6
|
import { AnnotationSharedCSSByState } from '@atlaskit/editor-common/styles';
|
|
6
7
|
import { AnnotationMarkStates } from '@atlaskit/adf-schema';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React, { useContext, useMemo } from 'react';
|
|
1
|
+
import React, { useContext, useMemo, useCallback } from 'react';
|
|
2
2
|
import { ProvidersContext } from '../context';
|
|
3
3
|
import { useAnnotationClickEvent } from '../hooks';
|
|
4
4
|
import { RendererContext } from '../../../ui/RendererActionsContext';
|
|
@@ -15,6 +15,11 @@ const AnnotationView = props => {
|
|
|
15
15
|
});
|
|
16
16
|
const ViewComponent = inlineCommentProvider && inlineCommentProvider.viewComponent;
|
|
17
17
|
const deleteAnnotation = useMemo(() => annotationInfo => actionContext.deleteAnnotation(annotationInfo.id, annotationInfo.type), [actionContext]);
|
|
18
|
+
|
|
19
|
+
// For view mode, the finding of inline node types is a bit more complex,
|
|
20
|
+
// that's why we will not provide it as a `inlineNodeTypes` props to the view component,
|
|
21
|
+
// to speed up the rendering process.
|
|
22
|
+
const getInlineNodeTypes = useCallback(annotationId => actionContext.getInlineNodeTypes(annotationId), [actionContext]);
|
|
18
23
|
if (ViewComponent && viewComponentProps) {
|
|
19
24
|
const {
|
|
20
25
|
annotations,
|
|
@@ -23,7 +28,8 @@ const AnnotationView = props => {
|
|
|
23
28
|
return /*#__PURE__*/React.createElement(ViewComponent, {
|
|
24
29
|
annotations: annotations,
|
|
25
30
|
clickElementTarget: clickElementTarget,
|
|
26
|
-
deleteAnnotation: deleteAnnotation
|
|
31
|
+
deleteAnnotation: deleteAnnotation,
|
|
32
|
+
getInlineNodeTypes: getInlineNodeTypes
|
|
27
33
|
});
|
|
28
34
|
}
|
|
29
35
|
return null;
|
|
@@ -5,7 +5,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
5
5
|
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; }
|
|
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 { JSONTransformer } from '@atlaskit/editor-json-transformer';
|
|
8
|
-
import { canApplyAnnotationOnRange, getAnnotationIdsFromRange } from '@atlaskit/editor-common/utils';
|
|
8
|
+
import { canApplyAnnotationOnRange, getAnnotationIdsFromRange, getAnnotationInlineNodeTypes } from '@atlaskit/editor-common/utils';
|
|
9
9
|
import { AnnotationTypes } from '@atlaskit/adf-schema';
|
|
10
10
|
import { AddNodeMarkStep, RemoveMarkStep, RemoveNodeMarkStep } from '@atlaskit/editor-prosemirror/transform';
|
|
11
11
|
import { createAnnotationStep, getPosFromRange } from '../steps';
|
|
@@ -308,6 +308,20 @@ var RendererActions = /*#__PURE__*/function () {
|
|
|
308
308
|
pos: blockNodePos
|
|
309
309
|
};
|
|
310
310
|
}
|
|
311
|
+
|
|
312
|
+
// TODO: Do not forget to remove `undefined` when the
|
|
313
|
+
// `platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz` is removed.
|
|
314
|
+
}, {
|
|
315
|
+
key: "getInlineNodeTypes",
|
|
316
|
+
value: function getInlineNodeTypes(annotationId) {
|
|
317
|
+
if (!this.doc || !this.schema) {
|
|
318
|
+
return [];
|
|
319
|
+
}
|
|
320
|
+
return getAnnotationInlineNodeTypes({
|
|
321
|
+
doc: this.doc,
|
|
322
|
+
schema: this.schema
|
|
323
|
+
}, annotationId);
|
|
324
|
+
}
|
|
311
325
|
}]);
|
|
312
326
|
return RendererActions;
|
|
313
327
|
}();
|
|
@@ -3,6 +3,7 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
|
3
3
|
var _templateObject;
|
|
4
4
|
/** @jsx jsx */
|
|
5
5
|
import React from 'react';
|
|
6
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
6
7
|
import { css, jsx } from '@emotion/react';
|
|
7
8
|
import { alignmentPositionMap } from '@atlaskit/adf-schema';
|
|
8
9
|
var MarkWrapper = function MarkWrapper(props) {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
2
3
|
import { css, jsx } from '@emotion/react';
|
|
3
4
|
import { WidthConsumer } from '@atlaskit/editor-common/ui';
|
|
4
5
|
import { calcBreakoutWidth } from '@atlaskit/editor-common/utils';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/** @jsx jsx */
|
|
3
3
|
import React, { Fragment } from 'react';
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
5
|
import { css, jsx } from '@emotion/react';
|
|
5
6
|
import { B400, B300, B500 } from '@atlaskit/theme/colors';
|
|
6
7
|
import { getEventHandler } from '../../utils';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/** @jsx jsx */
|
|
3
3
|
import { useMemo } from 'react';
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
5
|
import { css, jsx } from '@emotion/react';
|
|
5
6
|
import { Card } from '@atlaskit/smart-card';
|
|
6
7
|
import { UnsupportedBlock, UnsupportedInline, WidthConsumer } from '@atlaskit/editor-common/ui';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
2
2
|
/** @jsx jsx */
|
|
3
3
|
import { useState } from 'react';
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
5
|
import { jsx } from '@emotion/react';
|
|
5
6
|
import { injectIntl } from 'react-intl-next';
|
|
6
7
|
import { CodeBlockSharedCssClassName } from '@atlaskit/editor-common/styles';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
|
2
2
|
var _templateObject;
|
|
3
3
|
/** @jsx jsx */
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
5
|
import { jsx, css } from '@emotion/react';
|
|
5
6
|
import { overflowShadow, relativeFontSizeToBase16 } from '@atlaskit/editor-shared-styles';
|
|
6
7
|
import { N20 } from '@atlaskit/theme/colors';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
2
2
|
/** @jsx jsx */
|
|
3
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
3
4
|
import { jsx } from '@emotion/react';
|
|
4
5
|
import { useState } from 'react';
|
|
5
6
|
import { injectIntl } from 'react-intl-next';
|
|
@@ -2,6 +2,7 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
|
2
2
|
var _templateObject, _templateObject2;
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
import React, { forwardRef, useMemo } from 'react';
|
|
5
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
5
6
|
import { css, jsx } from '@emotion/react';
|
|
6
7
|
import { blockNodesVerticalMargin } from '@atlaskit/editor-shared-styles';
|
|
7
8
|
import { codeBlockSharedStyles, CodeBlockSharedCssClassName } from '@atlaskit/editor-common/styles';
|
|
@@ -3,6 +3,7 @@ import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
|
3
3
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
4
4
|
/** @jsx jsx */
|
|
5
5
|
import { Fragment, lazy, memo, Suspense, useState } from 'react';
|
|
6
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
6
7
|
import { jsx } from '@emotion/react';
|
|
7
8
|
import { CodeBlockSharedCssClassName } from '@atlaskit/editor-common/styles';
|
|
8
9
|
import { useInViewport } from '../../hooks/use-in-viewport';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
3
|
/** @jsx jsx */
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
5
|
import { css, jsx } from '@emotion/react';
|
|
5
6
|
import { useMemo, useContext, useState, useRef } from 'react';
|
|
6
7
|
import { Card, EmbedResizeMessageListener } from '@atlaskit/smart-card';
|
|
@@ -15,6 +15,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
15
15
|
/** @jsx jsx */
|
|
16
16
|
|
|
17
17
|
import React from 'react';
|
|
18
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
18
19
|
import { css, jsx } from '@emotion/react';
|
|
19
20
|
import { N200, N500, B400 } from '@atlaskit/theme/colors';
|
|
20
21
|
import LinkIcon from '@atlaskit/icon/glyph/link';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/** @jsx jsx */
|
|
3
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
3
4
|
import { jsx } from '@emotion/react';
|
|
4
5
|
import { Card } from '@atlaskit/smart-card';
|
|
5
6
|
import { CardSSR } from '@atlaskit/smart-card/ssr';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
2
|
import React from 'react';
|
|
3
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
3
4
|
import { jsx, css } from '@emotion/react';
|
|
4
5
|
import { WidthProvider, clearNextSiblingMarginTopStyle, clearNextSiblingBlockMarkMarginTopStyle } from '@atlaskit/editor-common/ui';
|
|
5
6
|
|
|
@@ -18,6 +18,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
18
18
|
/** @jsx jsx */
|
|
19
19
|
|
|
20
20
|
import React, { PureComponent, Fragment, useEffect, useState, useMemo, useContext } from 'react';
|
|
21
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
21
22
|
import { jsx, css } from '@emotion/react';
|
|
22
23
|
import { AnalyticsContext } from '@atlaskit/analytics-next';
|
|
23
24
|
import { MEDIA_CONTEXT } from '@atlaskit/analytics-namespaced-context';
|
|
@@ -3,6 +3,7 @@ import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
|
|
5
5
|
import { default as React, Fragment, useCallback, useContext, useMemo, useEffect } from 'react';
|
|
6
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
6
7
|
import { jsx } from '@emotion/react';
|
|
7
8
|
import { injectIntl } from 'react-intl-next';
|
|
8
9
|
import { MediaSingle as UIMediaSingle, WidthContext } from '@atlaskit/editor-common/ui';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
2
3
|
import { css } from '@emotion/react';
|
|
3
4
|
|
|
4
5
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
|
|
@@ -5,8 +5,9 @@ var _templateObject, _templateObject2;
|
|
|
5
5
|
/* eslint-disable @atlaskit/design-system/prefer-primitives */
|
|
6
6
|
/** @jsx jsx */
|
|
7
7
|
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
9
|
import { jsx } from '@emotion/react';
|
|
9
|
-
// eslint-disable-next-line @typescript-eslint/no-duplicate-imports
|
|
10
|
+
// eslint-disable-next-line @typescript-eslint/no-duplicate-imports, @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
10
11
|
import { css } from '@emotion/react';
|
|
11
12
|
import { N40 } from '@atlaskit/theme/colors';
|
|
12
13
|
import React, { useState } from 'react';
|
|
@@ -5,6 +5,7 @@ var _templateObject, _templateObject2;
|
|
|
5
5
|
var _excluded = ["backgroundColor", "hasIcon"];
|
|
6
6
|
/** @jsx jsx */
|
|
7
7
|
import React from 'react';
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
9
|
import { css, jsx } from '@emotion/react';
|
|
9
10
|
import TipIcon from '@atlaskit/icon/glyph/editor/hint';
|
|
10
11
|
import { PanelType } from '@atlaskit/adf-schema';
|
|
@@ -4,6 +4,9 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
4
4
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
5
5
|
/** @jsx jsx */
|
|
6
6
|
import React from 'react';
|
|
7
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
|
+
|
|
9
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
7
10
|
import { css, jsx } from '@emotion/react';
|
|
8
11
|
import { TableSharedCssClassName } from '@atlaskit/editor-common/styles';
|
|
9
12
|
import { akEditorStickyHeaderZIndex } from '@atlaskit/editor-shared-styles';
|
package/dist/esm/ui/Expand.js
CHANGED
|
@@ -5,6 +5,7 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
|
5
5
|
var _excluded = ["expanded"];
|
|
6
6
|
var _templateObject, _templateObject2, _templateObject3;
|
|
7
7
|
/** @jsx jsx */
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
9
|
import { css, jsx } from '@emotion/react';
|
|
9
10
|
import React, { useCallback, useMemo, useRef } from 'react';
|
|
10
11
|
// eslint-disable-next-line @atlaskit/design-system/no-deprecated-imports
|
|
@@ -8,6 +8,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
8
8
|
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); }; }
|
|
9
9
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
10
10
|
/** @jsx jsx */
|
|
11
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
11
12
|
import { css, jsx } from '@emotion/react';
|
|
12
13
|
import React, { Fragment } from 'react';
|
|
13
14
|
import memoizeOne from 'memoize-one';
|
|
@@ -12,6 +12,7 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
|
|
|
12
12
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
13
13
|
/** @jsx jsx */
|
|
14
14
|
import React, { Fragment, useContext, useLayoutEffect, useRef, PureComponent } from 'react';
|
|
15
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
15
16
|
import { jsx } from '@emotion/react';
|
|
16
17
|
import { getSchemaBasedOnStage } from '@atlaskit/adf-schema/schema-default';
|
|
17
18
|
import { reduce } from '@atlaskit/adf-utils/traverse';
|
|
@@ -47,7 +48,7 @@ import { nodeToReact } from '../../react/nodes';
|
|
|
47
48
|
export var NORMAL_SEVERITY_THRESHOLD = 2000;
|
|
48
49
|
export var DEGRADED_SEVERITY_THRESHOLD = 3000;
|
|
49
50
|
var packageName = "@atlaskit/renderer";
|
|
50
|
-
var packageVersion = "109.
|
|
51
|
+
var packageVersion = "109.33.1";
|
|
51
52
|
export var defaultNodeComponents = nodeToReact;
|
|
52
53
|
export var Renderer = /*#__PURE__*/function (_PureComponent) {
|
|
53
54
|
_inherits(Renderer, _PureComponent);
|
|
@@ -2,7 +2,9 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
|
2
2
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9;
|
|
3
3
|
/* eslint-disable @atlaskit/design-system/no-css-tagged-template-expression -- needs manual remediation */
|
|
4
4
|
/* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
|
|
5
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
5
6
|
|
|
7
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
6
8
|
import { css } from '@emotion/react';
|
|
7
9
|
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
8
10
|
import { fontFamily, fontSize } from '@atlaskit/theme/constants';
|
|
@@ -6,6 +6,7 @@ import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
|
6
6
|
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); }; }
|
|
7
7
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
8
8
|
/** @jsx jsx */
|
|
9
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
9
10
|
import { css, jsx } from '@emotion/react';
|
|
10
11
|
import { Component } from 'react';
|
|
11
12
|
var fadeOutStyles = function fadeOutStyles(maxHeight, top, backgroundColor) {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/** @jsx jsx */
|
|
3
3
|
import React, { Fragment } from 'react';
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
4
5
|
import { css, jsx } from '@emotion/react';
|
|
5
6
|
import { InsertDraftPosition } from '../types';
|
|
6
7
|
import { AnnotationsDraftContext } from '../context';
|
|
@@ -7,6 +7,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
7
7
|
/** @jsx jsx */
|
|
8
8
|
|
|
9
9
|
import { useMemo, useCallback } from 'react';
|
|
10
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
10
11
|
import { css, jsx } from '@emotion/react';
|
|
11
12
|
import { AnnotationSharedCSSByState } from '@atlaskit/editor-common/styles';
|
|
12
13
|
import { AnnotationMarkStates } from '@atlaskit/adf-schema';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React, { useContext, useMemo } from 'react';
|
|
1
|
+
import React, { useContext, useMemo, useCallback } from 'react';
|
|
2
2
|
import { ProvidersContext } from '../context';
|
|
3
3
|
import { useAnnotationClickEvent } from '../hooks';
|
|
4
4
|
import { RendererContext } from '../../../ui/RendererActionsContext';
|
|
@@ -19,13 +19,21 @@ var AnnotationView = function AnnotationView(props) {
|
|
|
19
19
|
return actionContext.deleteAnnotation(annotationInfo.id, annotationInfo.type);
|
|
20
20
|
};
|
|
21
21
|
}, [actionContext]);
|
|
22
|
+
|
|
23
|
+
// For view mode, the finding of inline node types is a bit more complex,
|
|
24
|
+
// that's why we will not provide it as a `inlineNodeTypes` props to the view component,
|
|
25
|
+
// to speed up the rendering process.
|
|
26
|
+
var getInlineNodeTypes = useCallback(function (annotationId) {
|
|
27
|
+
return actionContext.getInlineNodeTypes(annotationId);
|
|
28
|
+
}, [actionContext]);
|
|
22
29
|
if (ViewComponent && viewComponentProps) {
|
|
23
30
|
var annotations = viewComponentProps.annotations,
|
|
24
31
|
clickElementTarget = viewComponentProps.clickElementTarget;
|
|
25
32
|
return /*#__PURE__*/React.createElement(ViewComponent, {
|
|
26
33
|
annotations: annotations,
|
|
27
34
|
clickElementTarget: clickElementTarget,
|
|
28
|
-
deleteAnnotation: deleteAnnotation
|
|
35
|
+
deleteAnnotation: deleteAnnotation,
|
|
36
|
+
getInlineNodeTypes: getInlineNodeTypes
|
|
29
37
|
});
|
|
30
38
|
}
|
|
31
39
|
return null;
|
|
@@ -60,5 +60,6 @@ export default class RendererActions implements RendererActionsOptions, Annotati
|
|
|
60
60
|
getAnnotationsByPosition(range: Range): string[];
|
|
61
61
|
applyAnnotation(pos: Position, annotation: Annotation, isCommentsOnMediaBugFixEnabled?: boolean, isCommentsOnMediaBugVideoCommentEnabled?: boolean): AnnotationActionResult;
|
|
62
62
|
generateAnnotationIndexMatch(pos: Position): AnnotationByMatches | false;
|
|
63
|
+
getInlineNodeTypes(annotationId: string): string[] | undefined;
|
|
63
64
|
}
|
|
64
65
|
export {};
|
|
@@ -60,5 +60,6 @@ export default class RendererActions implements RendererActionsOptions, Annotati
|
|
|
60
60
|
getAnnotationsByPosition(range: Range): string[];
|
|
61
61
|
applyAnnotation(pos: Position, annotation: Annotation, isCommentsOnMediaBugFixEnabled?: boolean, isCommentsOnMediaBugVideoCommentEnabled?: boolean): AnnotationActionResult;
|
|
62
62
|
generateAnnotationIndexMatch(pos: Position): AnnotationByMatches | false;
|
|
63
|
+
getInlineNodeTypes(annotationId: string): string[] | undefined;
|
|
63
64
|
}
|
|
64
65
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/renderer",
|
|
3
|
-
"version": "109.
|
|
3
|
+
"version": "109.33.1",
|
|
4
4
|
"description": "Renderer component",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -29,20 +29,20 @@
|
|
|
29
29
|
"@atlaskit/analytics-listeners": "^8.10.0",
|
|
30
30
|
"@atlaskit/analytics-namespaced-context": "^6.10.0",
|
|
31
31
|
"@atlaskit/analytics-next": "^9.3.0",
|
|
32
|
-
"@atlaskit/button": "^
|
|
33
|
-
"@atlaskit/code": "^15.
|
|
34
|
-
"@atlaskit/editor-common": "^82.
|
|
32
|
+
"@atlaskit/button": "^18.0.0",
|
|
33
|
+
"@atlaskit/code": "^15.3.0",
|
|
34
|
+
"@atlaskit/editor-common": "^82.11.0",
|
|
35
35
|
"@atlaskit/editor-json-transformer": "^8.13.0",
|
|
36
36
|
"@atlaskit/editor-palette": "1.6.0",
|
|
37
37
|
"@atlaskit/editor-prosemirror": "4.0.1",
|
|
38
38
|
"@atlaskit/editor-shared-styles": "^2.12.0",
|
|
39
39
|
"@atlaskit/emoji": "^67.6.0",
|
|
40
|
-
"@atlaskit/icon": "^22.
|
|
40
|
+
"@atlaskit/icon": "^22.4.0",
|
|
41
41
|
"@atlaskit/link-datasource": "^2.3.0",
|
|
42
42
|
"@atlaskit/media-card": "^77.12.0",
|
|
43
|
-
"@atlaskit/media-client": "^27.
|
|
43
|
+
"@atlaskit/media-client": "^27.3.0",
|
|
44
44
|
"@atlaskit/media-client-react": "^2.0.0",
|
|
45
|
-
"@atlaskit/media-common": "^11.
|
|
45
|
+
"@atlaskit/media-common": "^11.3.0",
|
|
46
46
|
"@atlaskit/media-filmstrip": "^47.0.0",
|
|
47
47
|
"@atlaskit/media-ui": "^25.10.0",
|
|
48
48
|
"@atlaskit/media-viewer": "^48.6.0",
|
|
@@ -50,9 +50,9 @@
|
|
|
50
50
|
"@atlaskit/smart-card": "^27.6.0",
|
|
51
51
|
"@atlaskit/status": "^1.4.0",
|
|
52
52
|
"@atlaskit/task-decision": "^17.10.0",
|
|
53
|
-
"@atlaskit/theme": "^12.
|
|
54
|
-
"@atlaskit/tokens": "^1.
|
|
55
|
-
"@atlaskit/tooltip": "^18.
|
|
53
|
+
"@atlaskit/theme": "^12.11.0",
|
|
54
|
+
"@atlaskit/tokens": "^1.52.0",
|
|
55
|
+
"@atlaskit/tooltip": "^18.5.0",
|
|
56
56
|
"@babel/runtime": "^7.0.0",
|
|
57
57
|
"@emotion/react": "^11.7.1",
|
|
58
58
|
"lodash": "^4.17.21",
|