@atlaskit/renderer 148.1.0 → 149.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 +24 -0
- package/dist/cjs/actions/index.js +35 -3
- package/dist/cjs/react/index.js +8 -0
- package/dist/cjs/react/marks/annotation.js +3 -1
- package/dist/cjs/react/nodes/extension-comments.compiled.css +4 -0
- package/dist/cjs/react/nodes/extension-comments.js +144 -0
- package/dist/cjs/react/nodes/extension.js +86 -11
- package/dist/cjs/steps/index.js +23 -0
- package/dist/cjs/ui/Renderer/index.js +1 -1
- package/dist/cjs/ui/annotations/contexts/AnnotationRangeContext.js +29 -11
- package/dist/cjs/ui/annotations/element/extension.compiled.css +6 -0
- package/dist/cjs/ui/annotations/element/extension.js +34 -0
- package/dist/cjs/ui/annotations/element/index.js +4 -2
- package/dist/cjs/ui/annotations/element/mark.js +11 -1
- package/dist/cjs/ui/annotations/index.js +2 -1
- package/dist/es2019/actions/index.js +33 -3
- package/dist/es2019/react/index.js +8 -0
- package/dist/es2019/react/marks/annotation.js +3 -1
- package/dist/es2019/react/nodes/extension-comments.compiled.css +4 -0
- package/dist/es2019/react/nodes/extension-comments.js +115 -0
- package/dist/es2019/react/nodes/extension.js +83 -7
- package/dist/es2019/steps/index.js +25 -0
- package/dist/es2019/ui/Renderer/index.js +1 -1
- package/dist/es2019/ui/annotations/contexts/AnnotationRangeContext.js +28 -12
- package/dist/es2019/ui/annotations/element/extension.compiled.css +6 -0
- package/dist/es2019/ui/annotations/element/extension.js +26 -0
- package/dist/es2019/ui/annotations/element/index.js +4 -2
- package/dist/es2019/ui/annotations/element/mark.js +11 -1
- package/dist/es2019/ui/annotations/index.js +2 -1
- package/dist/esm/actions/index.js +35 -3
- package/dist/esm/react/index.js +8 -0
- package/dist/esm/react/marks/annotation.js +3 -1
- package/dist/esm/react/nodes/extension-comments.compiled.css +4 -0
- package/dist/esm/react/nodes/extension-comments.js +135 -0
- package/dist/esm/react/nodes/extension.js +86 -7
- package/dist/esm/steps/index.js +23 -0
- package/dist/esm/ui/Renderer/index.js +1 -1
- package/dist/esm/ui/annotations/contexts/AnnotationRangeContext.js +30 -12
- package/dist/esm/ui/annotations/element/extension.compiled.css +6 -0
- package/dist/esm/ui/annotations/element/extension.js +27 -0
- package/dist/esm/ui/annotations/element/index.js +4 -2
- package/dist/esm/ui/annotations/element/mark.js +11 -1
- package/dist/esm/ui/annotations/index.js +2 -1
- package/dist/types/actions/index.d.ts +13 -0
- package/dist/types/react/marks/annotation.d.ts +1 -1
- package/dist/types/react/nodes/extension-comments.d.ts +17 -0
- package/dist/types/react/nodes/extension.d.ts +12 -0
- package/dist/types/react/types.d.ts +1 -0
- package/dist/types/ui/annotations/contexts/AnnotationRangeContext.d.ts +4 -2
- package/dist/types/ui/annotations/element/extension.d.ts +17 -0
- package/dist/types/ui/annotations/element/index.d.ts +2 -1
- package/dist/types/ui/annotations/element/mark.d.ts +3 -107
- package/package.json +4 -4
|
@@ -12,7 +12,8 @@ var MarkElement = function MarkElement(_ref) {
|
|
|
12
12
|
children = _ref.children,
|
|
13
13
|
dataAttributes = _ref.dataAttributes,
|
|
14
14
|
id = _ref.id,
|
|
15
|
-
useBlockLevel = _ref.useBlockLevel
|
|
15
|
+
useBlockLevel = _ref.useBlockLevel,
|
|
16
|
+
isExtension = _ref.isExtension;
|
|
16
17
|
var updateSubscriber = useInlineCommentSubscriberContext();
|
|
17
18
|
var states = useContext(InlineCommentsStateContext);
|
|
18
19
|
var _useHasFocusEvent = useHasFocusEvent({
|
|
@@ -90,7 +91,8 @@ var MarkElement = function MarkElement(_ref) {
|
|
|
90
91
|
hasFocus: hasFocus,
|
|
91
92
|
isHovered: isHovered,
|
|
92
93
|
state: states[id],
|
|
93
|
-
useBlockLevel: useBlockLevel
|
|
94
|
+
useBlockLevel: useBlockLevel,
|
|
95
|
+
isExtension: isExtension
|
|
94
96
|
}, children);
|
|
95
97
|
};
|
|
96
98
|
export { MarkElement };
|
|
@@ -16,6 +16,7 @@ import { AnnotationMarkStates } from '@atlaskit/adf-schema/annotation';
|
|
|
16
16
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
17
17
|
import { inlineCommentMessages } from '../../../messages';
|
|
18
18
|
import { useAnnotationManagerDispatch, useAnnotationManagerState } from '../contexts/AnnotationManagerContext';
|
|
19
|
+
import { ExtensionAnnotation } from './extension';
|
|
19
20
|
var markStyles = css(_defineProperty({
|
|
20
21
|
color: 'inherit',
|
|
21
22
|
backgroundColor: 'unset',
|
|
@@ -120,7 +121,8 @@ export var MarkComponent = function MarkComponent(_ref) {
|
|
|
120
121
|
hasFocus = _ref.hasFocus,
|
|
121
122
|
isHovered = _ref.isHovered,
|
|
122
123
|
onClick = _ref.onClick,
|
|
123
|
-
useBlockLevel = _ref.useBlockLevel
|
|
124
|
+
useBlockLevel = _ref.useBlockLevel,
|
|
125
|
+
isExtension = _ref.isExtension;
|
|
124
126
|
var intl = useIntl();
|
|
125
127
|
var annotationIds = useMemo(function () {
|
|
126
128
|
return _toConsumableArray(new Set([].concat(_toConsumableArray(annotationParentIds), [id])));
|
|
@@ -210,6 +212,14 @@ export var MarkComponent = function MarkComponent(_ref) {
|
|
|
210
212
|
} : _objectSpread({
|
|
211
213
|
'aria-details': annotationIds.join(', ')
|
|
212
214
|
}, desktopAccessibilityAttributes);
|
|
215
|
+
if (isExtension && fg('cc_maui_annotations_on_extensions')) {
|
|
216
|
+
// The chart's badge owns interaction. Anchors only supply geometry and annotation state.
|
|
217
|
+
return jsx(ExtensionAnnotation, {
|
|
218
|
+
id: id,
|
|
219
|
+
dataAttributes: overriddenData,
|
|
220
|
+
markRef: id === currentSelectedAnnotationId ? markRef : undefined
|
|
221
|
+
});
|
|
222
|
+
}
|
|
213
223
|
return jsx(useBlockLevel ? 'div' : 'mark', _objectSpread(_objectSpread(_objectSpread(_defineProperty({
|
|
214
224
|
ref: id === currentSelectedAnnotationId ? markRef : undefined,
|
|
215
225
|
id: id
|
|
@@ -29,7 +29,7 @@ export var AnnotationsPositionContext = /*#__PURE__*/React.createContext({
|
|
|
29
29
|
startPos: 1
|
|
30
30
|
});
|
|
31
31
|
export var AnnotationsWrapperInner = function AnnotationsWrapperInner(props) {
|
|
32
|
-
var _providers$inlineComm, _providers$inlineComm2;
|
|
32
|
+
var _providers$inlineComm, _providers$inlineComm2, _providers$inlineComm3;
|
|
33
33
|
var children = props.children,
|
|
34
34
|
rendererRef = props.rendererRef,
|
|
35
35
|
adfDocument = props.adfDocument,
|
|
@@ -47,6 +47,7 @@ export var AnnotationsWrapperInner = function AnnotationsWrapperInner(props) {
|
|
|
47
47
|
value: inlineCommentAnnotationsState
|
|
48
48
|
}, /*#__PURE__*/React.createElement(AnnotationRangeProvider, {
|
|
49
49
|
allowCommentsOnMedia: (_providers$inlineComm = providers === null || providers === void 0 || (_providers$inlineComm2 = providers.inlineComment) === null || _providers$inlineComm2 === void 0 ? void 0 : _providers$inlineComm2.allowCommentsOnMedia) !== null && _providers$inlineComm !== void 0 ? _providers$inlineComm : false,
|
|
50
|
+
hasBlockNodeSupport: Boolean(providers === null || providers === void 0 || (_providers$inlineComm3 = providers.inlineComment) === null || _providers$inlineComm3 === void 0 ? void 0 : _providers$inlineComm3.isBlockNodeSupported),
|
|
50
51
|
isNestedRender: isNestedRender
|
|
51
52
|
}, /*#__PURE__*/React.createElement(AnnotationHoverContext, null, /*#__PURE__*/React.createElement(AnnotationsContextWrapper, {
|
|
52
53
|
createAnalyticsEvent: createAnalyticsEvent,
|
|
@@ -71,6 +71,19 @@ export default class RendererActions implements RendererActionsOptions, Annotati
|
|
|
71
71
|
annotate(range: Range, annotationId: string, _annotationType: 'inlineComment'): AnnotationActionResult;
|
|
72
72
|
isValidAnnotationRange(range: Range | null): boolean;
|
|
73
73
|
isRangeAnnotatable(range: Range | null): boolean;
|
|
74
|
+
/**
|
|
75
|
+
* A range only threatens a nested renderer's own document (e.g. a bodiedExtension's macro
|
|
76
|
+
* body, which renders its own nested `<Renderer>`) when it sits inside that nested renderer's
|
|
77
|
+
* `.ak-renderer-document`. Landing directly on the extension's own outer wrapper -- with no
|
|
78
|
+
* nested document in between -- must stay annotatable so the whole chart/extension can be
|
|
79
|
+
* targeted (MAUI-1256), rather than being rejected outright the way any range touching
|
|
80
|
+
* `.ak-renderer-extension` previously was.
|
|
81
|
+
*
|
|
82
|
+
* Behind `cc_maui_annotations_on_extensions` -- the same gate MAUI-1255 added for extension
|
|
83
|
+
* node-mark support -- to preserve the previous behaviour (reject anything touching
|
|
84
|
+
* `.ak-renderer-extension`) while the feature is off.
|
|
85
|
+
*/
|
|
86
|
+
private isInsideNestedExtensionRenderer;
|
|
74
87
|
/**
|
|
75
88
|
* This is replaced by `isRangeAnnotatable`.
|
|
76
89
|
*
|
|
@@ -2,5 +2,5 @@ import React from 'react';
|
|
|
2
2
|
import type { Mark } from '@atlaskit/editor-prosemirror/model';
|
|
3
3
|
import type { MarkProps, AnnotationMarkMeta } from '../types';
|
|
4
4
|
export declare const isAnnotationMark: (mark: Mark) => boolean;
|
|
5
|
-
declare const AnnotationComponent: ({ id, annotationType, children, dataAttributes, annotationParentIds, allowAnnotations, useBlockLevel, isMediaInline, }: MarkProps<AnnotationMarkMeta>) => React.JSX.Element;
|
|
5
|
+
declare const AnnotationComponent: ({ id, annotationType, children, dataAttributes, annotationParentIds, allowAnnotations, useBlockLevel, isExtension, isMediaInline, }: MarkProps<AnnotationMarkMeta>) => React.JSX.Element;
|
|
6
6
|
export default AnnotationComponent;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
4
|
+
* @jsxFrag React.Fragment
|
|
5
|
+
*/
|
|
6
|
+
import React from 'react';
|
|
7
|
+
import type { Mark } from '@atlaskit/editor-prosemirror/model';
|
|
8
|
+
type Props = React.PropsWithChildren<{
|
|
9
|
+
allowAnnotations?: boolean;
|
|
10
|
+
allowAnnotationsDraftMode?: boolean;
|
|
11
|
+
enabled?: boolean;
|
|
12
|
+
marks?: readonly Mark[];
|
|
13
|
+
startPos?: number;
|
|
14
|
+
}>;
|
|
15
|
+
/** Only node-aware provider-approved extensions receive comment visuals. */
|
|
16
|
+
export declare const ExtensionComments: (props: Props) => React.JSX.Element;
|
|
17
|
+
export {};
|
|
@@ -12,8 +12,14 @@ import type { AnalyticsEventPayload } from '../../analytics/events';
|
|
|
12
12
|
import type { RendererAppearance } from '../../ui/Renderer/types';
|
|
13
13
|
import type { RendererContext, ExtensionViewportSize } from '../types';
|
|
14
14
|
interface Props {
|
|
15
|
+
allowAnnotations?: boolean;
|
|
16
|
+
allowAnnotationsDraftMode?: boolean;
|
|
17
|
+
dataAttributes?: {
|
|
18
|
+
'data-renderer-start-pos': number;
|
|
19
|
+
};
|
|
15
20
|
extensionHandlers?: ExtensionHandlers;
|
|
16
21
|
extensionKey: string;
|
|
22
|
+
extensionNode?: PMNode;
|
|
17
23
|
extensionType: string;
|
|
18
24
|
extensionViewportSizes?: ExtensionViewportSize[];
|
|
19
25
|
/**
|
|
@@ -40,8 +46,14 @@ type AllOrNone<T> = T | {
|
|
|
40
46
|
[K in keyof T]?: never;
|
|
41
47
|
};
|
|
42
48
|
type RenderExtensionOptions = {
|
|
49
|
+
dataAttributes?: Props['dataAttributes'];
|
|
43
50
|
fireAnalyticsEvent?: (event: AnalyticsEventPayload) => void;
|
|
51
|
+
isCommentTarget?: boolean;
|
|
44
52
|
isTopLevel?: boolean;
|
|
53
|
+
onBlur?: React.FocusEventHandler<HTMLDivElement>;
|
|
54
|
+
onFocus?: React.FocusEventHandler<HTMLDivElement>;
|
|
55
|
+
onMouseEnter?: React.MouseEventHandler<HTMLDivElement>;
|
|
56
|
+
onMouseLeave?: React.MouseEventHandler<HTMLDivElement>;
|
|
45
57
|
rendererAppearance?: RendererAppearance;
|
|
46
58
|
} & AllOrNone<OverflowShadowProps>;
|
|
47
59
|
export declare const renderExtension: (content: any, layout: ExtensionLayout, options?: RenderExtensionOptions, removeOverflow?: boolean, extensionId?: string, extensionViewportSizes?: ExtensionViewportSize[], nodeHeight?: string, localId?: string, shouldDisplayExtensionAsInline?: (extensionParams?: ExtensionParams<Parameters>) => boolean, node?: ExtensionParams<Parameters>, isInsideOfInlineExtension?: boolean) => React.JSX.Element;
|
|
@@ -36,13 +36,15 @@ interface AnnotationRangeDispatchContext {
|
|
|
36
36
|
}
|
|
37
37
|
export declare const AnnotationRangeStateContext: React.Context<AnnotationRangeStateContext>;
|
|
38
38
|
export declare const AnnotationRangeDispatchContext: React.Context<AnnotationRangeDispatchContext>;
|
|
39
|
-
export declare const AnnotationRangeProviderInner: ({ children, allowCommentsOnMedia, }: {
|
|
39
|
+
export declare const AnnotationRangeProviderInner: ({ children, allowCommentsOnMedia, hasBlockNodeSupport, }: {
|
|
40
40
|
allowCommentsOnMedia?: boolean;
|
|
41
41
|
children?: ReactNode;
|
|
42
|
+
hasBlockNodeSupport?: boolean;
|
|
42
43
|
}) => React.JSX.Element;
|
|
43
|
-
export declare const AnnotationRangeProvider: ({ children, allowCommentsOnMedia, isNestedRender, }: {
|
|
44
|
+
export declare const AnnotationRangeProvider: ({ children, allowCommentsOnMedia, hasBlockNodeSupport, isNestedRender, }: {
|
|
44
45
|
allowCommentsOnMedia?: boolean;
|
|
45
46
|
children?: ReactNode;
|
|
47
|
+
hasBlockNodeSupport?: boolean;
|
|
46
48
|
isNestedRender?: boolean;
|
|
47
49
|
}) => React.JSX.Element;
|
|
48
50
|
export declare const useAnnotationRangeState: () => AnnotationRangeStateContext;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
4
|
+
*/
|
|
5
|
+
import React from 'react';
|
|
6
|
+
import type { AnnotationDataAttributes } from '@atlaskit/adf-schema/annotation';
|
|
7
|
+
/** Full-chart anchors for comment navigation, without wrapping or intercepting the iframe. */
|
|
8
|
+
export declare const ExtensionAnnotation: ({ id, dataAttributes, markRef, }: {
|
|
9
|
+
dataAttributes: AnnotationDataAttributes & {
|
|
10
|
+
'data-block-mark'?: boolean;
|
|
11
|
+
'data-has-focus'?: boolean;
|
|
12
|
+
'data-is-hovered'?: boolean;
|
|
13
|
+
'data-renderer-mark'?: boolean;
|
|
14
|
+
};
|
|
15
|
+
id: string;
|
|
16
|
+
markRef?: React.Ref<HTMLDivElement>;
|
|
17
|
+
}) => React.JSX.Element;
|
|
@@ -5,7 +5,8 @@ type MarkElementProps = React.PropsWithChildren<{
|
|
|
5
5
|
annotationType: AnnotationTypes;
|
|
6
6
|
dataAttributes: AnnotationDataAttributes;
|
|
7
7
|
id: AnnotationId;
|
|
8
|
+
isExtension?: boolean;
|
|
8
9
|
useBlockLevel?: boolean;
|
|
9
10
|
}>;
|
|
10
|
-
declare const MarkElement: ({ annotationParentIds, children, dataAttributes, id, useBlockLevel, }: MarkElementProps) => React.JSX.Element;
|
|
11
|
+
declare const MarkElement: ({ annotationParentIds, children, dataAttributes, id, useBlockLevel, isExtension, }: MarkElementProps) => React.JSX.Element;
|
|
11
12
|
export { MarkElement };
|
|
@@ -3,8 +3,7 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import type React from 'react';
|
|
6
|
-
import {
|
|
7
|
-
import type { AnnotationId, AnnotationDataAttributes, AnnotationTypes } from '@atlaskit/adf-schema/annotation';
|
|
6
|
+
import type { AnnotationId, AnnotationDataAttributes } from '@atlaskit/adf-schema/annotation';
|
|
8
7
|
import { AnnotationMarkStates } from '@atlaskit/adf-schema/annotation';
|
|
9
8
|
import type { OnAnnotationClickPayload } from '@atlaskit/editor-common/types';
|
|
10
9
|
type MarkComponentProps = {
|
|
@@ -12,114 +11,11 @@ type MarkComponentProps = {
|
|
|
12
11
|
dataAttributes: AnnotationDataAttributes;
|
|
13
12
|
hasFocus: boolean;
|
|
14
13
|
id: AnnotationId;
|
|
14
|
+
isExtension?: boolean;
|
|
15
15
|
isHovered: boolean;
|
|
16
16
|
onClick: (props: OnAnnotationClickPayload) => void;
|
|
17
17
|
state: AnnotationMarkStates | null;
|
|
18
18
|
useBlockLevel?: boolean;
|
|
19
19
|
};
|
|
20
|
-
export declare const MarkComponent: ({ annotationParentIds, children, dataAttributes, id, state, hasFocus, isHovered, onClick, useBlockLevel, }: React.PropsWithChildren<MarkComponentProps>) => React.
|
|
21
|
-
'aria-disabled': boolean;
|
|
22
|
-
css?: (false | SerializedStyles)[] | undefined;
|
|
23
|
-
'data-id': AnnotationId;
|
|
24
|
-
'data-mark-annotation-state'?: AnnotationMarkStates;
|
|
25
|
-
'data-mark-annotation-type': AnnotationTypes;
|
|
26
|
-
'data-mark-type': string;
|
|
27
|
-
id: string;
|
|
28
|
-
ref: ((node: HTMLElement | null) => void) | undefined;
|
|
29
|
-
style?: {
|
|
30
|
-
'--ak-renderer-annotation-endmarker': string;
|
|
31
|
-
'--ak-renderer-annotation-startmarker': string;
|
|
32
|
-
} | undefined;
|
|
33
|
-
} | {
|
|
34
|
-
'aria-disabled': boolean;
|
|
35
|
-
css?: (false | SerializedStyles)[] | undefined;
|
|
36
|
-
'data-has-focus': boolean;
|
|
37
|
-
'data-id': AnnotationId;
|
|
38
|
-
'data-is-hovered': boolean;
|
|
39
|
-
'data-mark-annotation-state': AnnotationMarkStates;
|
|
40
|
-
'data-mark-annotation-type': AnnotationTypes;
|
|
41
|
-
'data-mark-type': string;
|
|
42
|
-
id: string;
|
|
43
|
-
ref: ((node: HTMLElement | null) => void) | undefined;
|
|
44
|
-
style?: {
|
|
45
|
-
'--ak-renderer-annotation-endmarker': string;
|
|
46
|
-
'--ak-renderer-annotation-startmarker': string;
|
|
47
|
-
} | undefined;
|
|
48
|
-
} | {
|
|
49
|
-
'aria-details': string;
|
|
50
|
-
'aria-disabled'?: undefined;
|
|
51
|
-
'aria-expanded'?: undefined;
|
|
52
|
-
css?: (false | SerializedStyles)[] | undefined;
|
|
53
|
-
'data-id': AnnotationId;
|
|
54
|
-
'data-mark-annotation-state'?: AnnotationMarkStates;
|
|
55
|
-
'data-mark-annotation-type': AnnotationTypes;
|
|
56
|
-
'data-mark-type': string;
|
|
57
|
-
id: string;
|
|
58
|
-
onKeyDown?: undefined;
|
|
59
|
-
ref: ((node: HTMLElement | null) => void) | undefined;
|
|
60
|
-
role?: undefined;
|
|
61
|
-
style?: {
|
|
62
|
-
'--ak-renderer-annotation-endmarker': string;
|
|
63
|
-
'--ak-renderer-annotation-startmarker': string;
|
|
64
|
-
} | undefined;
|
|
65
|
-
tabIndex?: undefined;
|
|
66
|
-
} | {
|
|
67
|
-
'aria-details': string;
|
|
68
|
-
'aria-disabled'?: undefined;
|
|
69
|
-
'aria-expanded'?: undefined;
|
|
70
|
-
css?: (false | SerializedStyles)[] | undefined;
|
|
71
|
-
'data-has-focus': boolean;
|
|
72
|
-
'data-id': AnnotationId;
|
|
73
|
-
'data-is-hovered': boolean;
|
|
74
|
-
'data-mark-annotation-state': AnnotationMarkStates;
|
|
75
|
-
'data-mark-annotation-type': AnnotationTypes;
|
|
76
|
-
'data-mark-type': string;
|
|
77
|
-
id: string;
|
|
78
|
-
onKeyDown?: undefined;
|
|
79
|
-
ref: ((node: HTMLElement | null) => void) | undefined;
|
|
80
|
-
role?: undefined;
|
|
81
|
-
style?: {
|
|
82
|
-
'--ak-renderer-annotation-endmarker': string;
|
|
83
|
-
'--ak-renderer-annotation-startmarker': string;
|
|
84
|
-
} | undefined;
|
|
85
|
-
tabIndex?: undefined;
|
|
86
|
-
} | {
|
|
87
|
-
'aria-details': string;
|
|
88
|
-
'aria-disabled'?: undefined;
|
|
89
|
-
'aria-expanded': boolean;
|
|
90
|
-
css?: (false | SerializedStyles)[] | undefined;
|
|
91
|
-
'data-id': AnnotationId;
|
|
92
|
-
'data-mark-annotation-state'?: AnnotationMarkStates;
|
|
93
|
-
'data-mark-annotation-type': AnnotationTypes;
|
|
94
|
-
'data-mark-type': string;
|
|
95
|
-
id: string;
|
|
96
|
-
onKeyDown: (evt: KeyboardEvent) => void;
|
|
97
|
-
ref: ((node: HTMLElement | null) => void) | undefined;
|
|
98
|
-
role: string;
|
|
99
|
-
style?: {
|
|
100
|
-
'--ak-renderer-annotation-endmarker': string;
|
|
101
|
-
'--ak-renderer-annotation-startmarker': string;
|
|
102
|
-
} | undefined;
|
|
103
|
-
tabIndex: number;
|
|
104
|
-
} | {
|
|
105
|
-
'aria-details': string;
|
|
106
|
-
'aria-disabled'?: undefined;
|
|
107
|
-
'aria-expanded': boolean;
|
|
108
|
-
css?: (false | SerializedStyles)[] | undefined;
|
|
109
|
-
'data-has-focus': boolean;
|
|
110
|
-
'data-id': AnnotationId;
|
|
111
|
-
'data-is-hovered': boolean;
|
|
112
|
-
'data-mark-annotation-state': AnnotationMarkStates;
|
|
113
|
-
'data-mark-annotation-type': AnnotationTypes;
|
|
114
|
-
'data-mark-type': string;
|
|
115
|
-
id: string;
|
|
116
|
-
onKeyDown: (evt: KeyboardEvent) => void;
|
|
117
|
-
ref: ((node: HTMLElement | null) => void) | undefined;
|
|
118
|
-
role: string;
|
|
119
|
-
style?: {
|
|
120
|
-
'--ak-renderer-annotation-endmarker': string;
|
|
121
|
-
'--ak-renderer-annotation-startmarker': string;
|
|
122
|
-
} | undefined;
|
|
123
|
-
tabIndex: number;
|
|
124
|
-
}>;
|
|
20
|
+
export declare const MarkComponent: ({ annotationParentIds, children, dataAttributes, id, state, hasFocus, isHovered, onClick, useBlockLevel, isExtension, }: React.PropsWithChildren<MarkComponentProps>) => React.JSX.Element;
|
|
125
21
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/renderer",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "149.0.0",
|
|
4
4
|
"description": "Renderer component",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"@atlaskit/task-decision": "^21.12.0",
|
|
75
75
|
"@atlaskit/theme": "^28.2.0",
|
|
76
76
|
"@atlaskit/tmp-editor-statsig": "^227.0.0",
|
|
77
|
-
"@atlaskit/tokens": "^20.
|
|
77
|
+
"@atlaskit/tokens": "^20.4.0",
|
|
78
78
|
"@atlaskit/tooltip": "^24.4.0",
|
|
79
79
|
"@atlaskit/visually-hidden": "^4.4.0",
|
|
80
80
|
"@babel/runtime": "^7.0.0",
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
"uuid": "^11.1.1"
|
|
89
89
|
},
|
|
90
90
|
"peerDependencies": {
|
|
91
|
-
"@atlaskit/editor-common": "^
|
|
91
|
+
"@atlaskit/editor-common": "^130.0.0",
|
|
92
92
|
"@atlaskit/link-provider": "^6.0.0",
|
|
93
93
|
"@atlaskit/media-core": "^39.0.0",
|
|
94
94
|
"react": "^18.2.0 || ^19.2.0",
|
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
"@af/visual-regression": "workspace:^",
|
|
101
101
|
"@atlaskit/analytics-gas-types": "^6.2.0",
|
|
102
102
|
"@atlaskit/checkbox": "^19.3.0",
|
|
103
|
-
"@atlaskit/editor-plugin-media": "^
|
|
103
|
+
"@atlaskit/editor-plugin-media": "^28.0.0",
|
|
104
104
|
"@atlaskit/editor-test-helpers": "workspace:^",
|
|
105
105
|
"@atlaskit/inline-edit": "^16.4.0",
|
|
106
106
|
"@atlaskit/json-ld-types": "^2.0.0",
|