@atlaskit/adf-schema 25.6.1 → 25.6.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 +7 -0
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/version.json +1 -1
- package/dist/json-schema/package.json +2 -2
- package/dist/types/schema/default-schema.d.ts +2 -2
- package/dist/types/schema/marks/annotation.d.ts +3 -3
- package/dist/types/schema/marks/border.d.ts +2 -2
- package/dist/types/schema/marks/breakout.d.ts +1 -1
- package/dist/types/schema/marks/data-consumer.d.ts +1 -1
- package/dist/types/schema/marks/fragment.d.ts +1 -1
- package/dist/types/schema/marks/text-color.d.ts +1 -1
- package/dist/types/schema/nodes/block-card.d.ts +1 -1
- package/dist/types/schema/nodes/bodied-extension.d.ts +1 -1
- package/dist/types/schema/nodes/code-block.d.ts +4 -4
- package/dist/types/schema/nodes/expand.d.ts +2 -2
- package/dist/types/schema/nodes/extension.d.ts +1 -1
- package/dist/types/schema/nodes/heading.d.ts +4 -4
- package/dist/types/schema/nodes/inline-extension.d.ts +1 -1
- package/dist/types/schema/nodes/layout-section.d.ts +4 -4
- package/dist/types/schema/nodes/media-single.d.ts +3 -3
- package/dist/types/schema/nodes/media.d.ts +4 -4
- package/dist/types/schema/nodes/mention.d.ts +1 -1
- package/dist/types/schema/nodes/nested-expand.d.ts +2 -2
- package/dist/types/schema/nodes/paragraph.d.ts +4 -4
- package/dist/types/schema/nodes/tableNodes.d.ts +3 -3
- package/dist/types/schema/nodes/types/block-content.d.ts +1 -1
- package/dist/types/schema/nodes/types/extensions.d.ts +1 -1
- package/dist/types/schema/nodes/types/inline-content.d.ts +5 -5
- package/dist/types/schema/nodes/types/non-nestable-block-content.d.ts +1 -1
- package/dist/types/schema/nodes/types/rich-media-common.d.ts +1 -1
- package/dist/types/steps/analytics.d.ts +2 -2
- package/dist/types/steps/link-meta-step.d.ts +1 -1
- package/dist/types/steps/table/types.d.ts +1 -1
- package/dist/types/steps/table/utils/side-effects/types.d.ts +2 -2
- package/dist/types/steps/type-ahead.d.ts +1 -1
- package/dist/types/utils/confluence/emoji.d.ts +1 -1
- package/json-schema/package.json +2 -2
- package/package.json +12 -4
- package/schema/package.json +2 -2
- package/schema-bitbucket/package.json +2 -2
- package/schema-confluence/package.json +2 -2
- package/schema-default/package.json +2 -2
- package/schema-jira/package.json +2 -2
- package/steps/package.json +2 -2
- package/url/package.json +2 -2
- package/dist/types-ts4.0/index.d.ts +0 -6
- package/dist/types-ts4.0/json-schema/index.d.ts +0 -2
- package/dist/types-ts4.0/schema/bitbucket-schema.d.ts +0 -5
- package/dist/types-ts4.0/schema/confluence-schema.d.ts +0 -9
- package/dist/types-ts4.0/schema/create-schema.d.ts +0 -32
- package/dist/types-ts4.0/schema/default-schema.d.ts +0 -7
- package/dist/types-ts4.0/schema/groups.d.ts +0 -6
- package/dist/types-ts4.0/schema/index.d.ts +0 -9
- package/dist/types-ts4.0/schema/inline-nodes.d.ts +0 -1
- package/dist/types-ts4.0/schema/jira-schema.d.ts +0 -65
- package/dist/types-ts4.0/schema/marks/alignment.d.ts +0 -16
- package/dist/types-ts4.0/schema/marks/annotation.d.ts +0 -32
- package/dist/types-ts4.0/schema/marks/border.d.ts +0 -24
- package/dist/types-ts4.0/schema/marks/breakout.d.ts +0 -12
- package/dist/types-ts4.0/schema/marks/code.d.ts +0 -8
- package/dist/types-ts4.0/schema/marks/confluence-inline-comment.d.ts +0 -12
- package/dist/types-ts4.0/schema/marks/data-consumer.d.ts +0 -48
- package/dist/types-ts4.0/schema/marks/em.d.ts +0 -8
- package/dist/types-ts4.0/schema/marks/fragment.d.ts +0 -29
- package/dist/types-ts4.0/schema/marks/indentation.d.ts +0 -16
- package/dist/types-ts4.0/schema/marks/index.d.ts +0 -34
- package/dist/types-ts4.0/schema/marks/link.d.ts +0 -35
- package/dist/types-ts4.0/schema/marks/strike.d.ts +0 -8
- package/dist/types-ts4.0/schema/marks/strong.d.ts +0 -8
- package/dist/types-ts4.0/schema/marks/subsup.d.ts +0 -15
- package/dist/types-ts4.0/schema/marks/text-color.d.ts +0 -22
- package/dist/types-ts4.0/schema/marks/type-ahead-query.d.ts +0 -2
- package/dist/types-ts4.0/schema/marks/underline.d.ts +0 -8
- package/dist/types-ts4.0/schema/marks/unsupported-mark.d.ts +0 -2
- package/dist/types-ts4.0/schema/marks/unsupported-node-attributes.d.ts +0 -2
- package/dist/types-ts4.0/schema/nodes/block-card.d.ts +0 -22
- package/dist/types-ts4.0/schema/nodes/blockquote.d.ts +0 -14
- package/dist/types-ts4.0/schema/nodes/bodied-extension.d.ts +0 -24
- package/dist/types-ts4.0/schema/nodes/bullet-list.d.ts +0 -3
- package/dist/types-ts4.0/schema/nodes/caption.d.ts +0 -20
- package/dist/types-ts4.0/schema/nodes/code-block.d.ts +0 -31
- package/dist/types-ts4.0/schema/nodes/confluence-jira-issue.d.ts +0 -2
- package/dist/types-ts4.0/schema/nodes/confluence-unsupported-block.d.ts +0 -2
- package/dist/types-ts4.0/schema/nodes/confluence-unsupported-inline.d.ts +0 -2
- package/dist/types-ts4.0/schema/nodes/date.d.ts +0 -14
- package/dist/types-ts4.0/schema/nodes/decision-item.d.ts +0 -17
- package/dist/types-ts4.0/schema/nodes/decision-list.d.ts +0 -18
- package/dist/types-ts4.0/schema/nodes/doc.d.ts +0 -18
- package/dist/types-ts4.0/schema/nodes/embed-card.d.ts +0 -18
- package/dist/types-ts4.0/schema/nodes/emoji.d.ts +0 -14
- package/dist/types-ts4.0/schema/nodes/expand.d.ts +0 -33
- package/dist/types-ts4.0/schema/nodes/extension.d.ts +0 -18
- package/dist/types-ts4.0/schema/nodes/hard-break.d.ts +0 -11
- package/dist/types-ts4.0/schema/nodes/heading.d.ts +0 -36
- package/dist/types-ts4.0/schema/nodes/image.d.ts +0 -2
- package/dist/types-ts4.0/schema/nodes/index.d.ts +0 -93
- package/dist/types-ts4.0/schema/nodes/inline-card.d.ts +0 -10
- package/dist/types-ts4.0/schema/nodes/inline-extension.d.ts +0 -18
- package/dist/types-ts4.0/schema/nodes/layout-column.d.ts +0 -21
- package/dist/types-ts4.0/schema/nodes/layout-section.d.ts +0 -44
- package/dist/types-ts4.0/schema/nodes/list-item.d.ts +0 -2
- package/dist/types-ts4.0/schema/nodes/media-group.d.ts +0 -14
- package/dist/types-ts4.0/schema/nodes/media-inline.d.ts +0 -16
- package/dist/types-ts4.0/schema/nodes/media-single.d.ts +0 -61
- package/dist/types-ts4.0/schema/nodes/media.d.ts +0 -62
- package/dist/types-ts4.0/schema/nodes/mention.d.ts +0 -26
- package/dist/types-ts4.0/schema/nodes/nested-expand.d.ts +0 -27
- package/dist/types-ts4.0/schema/nodes/ordered-list.d.ts +0 -4
- package/dist/types-ts4.0/schema/nodes/panel.d.ts +0 -38
- package/dist/types-ts4.0/schema/nodes/paragraph.d.ts +0 -37
- package/dist/types-ts4.0/schema/nodes/placeholder.d.ts +0 -11
- package/dist/types-ts4.0/schema/nodes/rule.d.ts +0 -8
- package/dist/types-ts4.0/schema/nodes/status.d.ts +0 -20
- package/dist/types-ts4.0/schema/nodes/tableNodes.d.ts +0 -114
- package/dist/types-ts4.0/schema/nodes/task-item.d.ts +0 -17
- package/dist/types-ts4.0/schema/nodes/task-list.d.ts +0 -21
- package/dist/types-ts4.0/schema/nodes/text.d.ts +0 -15
- package/dist/types-ts4.0/schema/nodes/types/block-content.d.ts +0 -22
- package/dist/types-ts4.0/schema/nodes/types/extensions.d.ts +0 -34
- package/dist/types-ts4.0/schema/nodes/types/inline-content.d.ts +0 -32
- package/dist/types-ts4.0/schema/nodes/types/list.d.ts +0 -42
- package/dist/types-ts4.0/schema/nodes/types/mark.d.ts +0 -15
- package/dist/types-ts4.0/schema/nodes/types/non-nestable-block-content.d.ts +0 -20
- package/dist/types-ts4.0/schema/nodes/types/rich-media-common.d.ts +0 -9
- package/dist/types-ts4.0/schema/nodes/unknown-block.d.ts +0 -3
- package/dist/types-ts4.0/schema/nodes/unsupported-block.d.ts +0 -2
- package/dist/types-ts4.0/schema/nodes/unsupported-inline.d.ts +0 -2
- package/dist/types-ts4.0/schema/unsupported.d.ts +0 -1
- package/dist/types-ts4.0/steps/analytics.d.ts +0 -59
- package/dist/types-ts4.0/steps/link-meta-step.d.ts +0 -51
- package/dist/types-ts4.0/steps/set-attrs.d.ts +0 -23
- package/dist/types-ts4.0/steps/table/add-column.d.ts +0 -88
- package/dist/types-ts4.0/steps/table/constants.d.ts +0 -4
- package/dist/types-ts4.0/steps/table/sort-column.d.ts +0 -18
- package/dist/types-ts4.0/steps/table/types.d.ts +0 -39
- package/dist/types-ts4.0/steps/table/utils/cell-step.d.ts +0 -51
- package/dist/types-ts4.0/steps/table/utils/cells-at-column.d.ts +0 -20
- package/dist/types-ts4.0/steps/table/utils/find-column.d.ts +0 -8
- package/dist/types-ts4.0/steps/table/utils/get-table-rect-from-doc.d.ts +0 -8
- package/dist/types-ts4.0/steps/table/utils/side-effects/rows.d.ts +0 -25
- package/dist/types-ts4.0/steps/table/utils/side-effects/side-effects.d.ts +0 -15
- package/dist/types-ts4.0/steps/table/utils/side-effects/table.d.ts +0 -16
- package/dist/types-ts4.0/steps/table/utils/side-effects/types.d.ts +0 -33
- package/dist/types-ts4.0/steps/table/utils/table-map.d.ts +0 -6
- package/dist/types-ts4.0/steps/type-ahead.d.ts +0 -35
- package/dist/types-ts4.0/steps.d.ts +0 -10
- package/dist/types-ts4.0/utils/colors.d.ts +0 -74
- package/dist/types-ts4.0/utils/confluence/emoji.d.ts +0 -50
- package/dist/types-ts4.0/utils/extensions.d.ts +0 -3
- package/dist/types-ts4.0/utils/index.d.ts +0 -6
- package/dist/types-ts4.0/utils/parseDOM.d.ts +0 -1
- package/dist/types-ts4.0/utils/url.d.ts +0 -31
- package/dist/types-ts4.0/utils/uuid.d.ts +0 -5
package/CHANGELOG.md
CHANGED
@@ -1,5 +1,12 @@
|
|
1
1
|
# @atlaskit/adf-schema
|
2
2
|
|
3
|
+
## 25.6.2
|
4
|
+
|
5
|
+
### Patch Changes
|
6
|
+
|
7
|
+
- [`41fae2c6f68`](https://bitbucket.org/atlassian/atlassian-frontend/commits/41fae2c6f68) - Upgrade Typescript from `4.5.5` to `4.9.5`
|
8
|
+
- Updated dependencies
|
9
|
+
|
3
10
|
## 25.6.1
|
4
11
|
|
5
12
|
### Patch Changes
|
package/dist/cjs/version.json
CHANGED
package/dist/es2019/version.json
CHANGED
package/dist/esm/version.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { SchemaConfig } from './create-schema';
|
2
|
-
|
3
|
-
|
2
|
+
type DefaultSchemaNodes = 'doc' | 'paragraph' | 'text' | 'bulletList' | 'orderedList' | 'listItem' | 'heading' | 'blockquote' | 'codeBlock' | 'panel' | 'rule' | 'image' | 'mention' | 'media' | 'caption' | 'mediaGroup' | 'mediaSingle' | 'mediaInline' | 'confluenceUnsupportedBlock' | 'confluenceUnsupportedInline' | 'confluenceJiraIssue' | 'expand' | 'nestedExpand' | 'extension' | 'inlineExtension' | 'bodiedExtension' | 'hardBreak' | 'emoji' | 'table' | 'tableCell' | 'tableHeader' | 'tableRow' | 'decisionList' | 'decisionItem' | 'taskList' | 'taskItem' | 'unknownBlock' | 'date' | 'status' | 'placeholder' | 'layoutSection' | 'layoutColumn' | 'inlineCard' | 'blockCard' | 'embedCard' | 'unsupportedBlock' | 'unsupportedInline';
|
3
|
+
type DefaultSchemaMarks = 'link' | 'em' | 'strong' | 'strike' | 'subsup' | 'underline' | 'code' | 'textColor' | 'confluenceInlineComment' | 'breakout' | 'alignment' | 'indentation' | 'annotation' | 'unsupportedMark' | 'unsupportedNodeAttribute' | 'typeAheadQuery' | 'dataConsumer' | 'fragment';
|
4
4
|
export declare const defaultSchemaConfig: SchemaConfig<DefaultSchemaNodes, DefaultSchemaMarks>;
|
5
5
|
export declare const getSchemaBasedOnStage: (stage?: string) => import("prosemirror-model").Schema<DefaultSchemaNodes, DefaultSchemaMarks>;
|
6
6
|
export declare const defaultSchema: import("prosemirror-model").Schema<DefaultSchemaNodes, DefaultSchemaMarks>;
|
@@ -10,7 +10,7 @@ export interface AnnotationMarkAttributes {
|
|
10
10
|
id: AnnotationId;
|
11
11
|
annotationType: AnnotationTypes;
|
12
12
|
}
|
13
|
-
export
|
13
|
+
export type AnnotationId = string;
|
14
14
|
export declare enum AnnotationTypes {
|
15
15
|
INLINE_COMMENT = "inlineComment"
|
16
16
|
}
|
@@ -18,13 +18,13 @@ export declare enum AnnotationMarkStates {
|
|
18
18
|
RESOLVED = "resolved",
|
19
19
|
ACTIVE = "active"
|
20
20
|
}
|
21
|
-
export
|
21
|
+
export type AnnotationDataAttributes = {
|
22
22
|
'data-mark-type': string;
|
23
23
|
'data-mark-annotation-type': AnnotationTypes;
|
24
24
|
'data-id': AnnotationId;
|
25
25
|
'data-mark-annotation-state'?: AnnotationMarkStates;
|
26
26
|
};
|
27
|
-
|
27
|
+
type BuildDataAttributesProps = AnnotationMarkAttributes & {
|
28
28
|
state?: AnnotationMarkStates | undefined | null;
|
29
29
|
};
|
30
30
|
export declare function buildDataAttributes({ id, annotationType, state, }: BuildDataAttributesProps): AnnotationDataAttributes;
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { MarkSpec } from 'prosemirror-model';
|
2
|
-
export
|
2
|
+
export type BorderMarkAttributes = {
|
3
3
|
/**
|
4
4
|
* @minimum 1
|
5
5
|
* @maximum 3
|
@@ -19,6 +19,6 @@ export interface BorderMarkDefinition {
|
|
19
19
|
type: 'border';
|
20
20
|
attrs: BorderMarkAttributes;
|
21
21
|
}
|
22
|
-
export
|
22
|
+
export type BorderColorKey = 'Subtle gray' | 'Gray' | 'Bold gray';
|
23
23
|
export declare const borderColorPalette: Map<string, BorderColorKey>;
|
24
24
|
export declare const border: MarkSpec;
|
@@ -15,7 +15,7 @@ export interface TextColorDefinition {
|
|
15
15
|
export interface TextColorMark extends Mark {
|
16
16
|
attrs: TextColorAttributes;
|
17
17
|
}
|
18
|
-
export
|
18
|
+
export type TextColorKey = 'Light gray' | 'Purple' | 'Teal' | 'Green' | 'Red' | 'Orange' | 'Dark gray' | 'Blue' | 'Yellow' | 'Dark blue' | 'Dark teal' | 'Dark green' | 'Dark red' | 'Dark purple' | 'White' | 'Light blue' | 'Light teal' | 'Light green' | 'Light yellow' | 'Light red' | 'Light purple';
|
19
19
|
export declare const colorPalette: Map<string, TextColorKey>;
|
20
20
|
/** @deprecated [ED-15849] The extended palette is now rolled into the main one. Use `colorPalette` instead. */
|
21
21
|
export declare const colorPaletteExtended: Map<string, TextColorKey>;
|
@@ -20,5 +20,5 @@ export interface BodiedExtensionBaseDefinition {
|
|
20
20
|
/**
|
21
21
|
* @name bodiedExtension_with_marks_node
|
22
22
|
*/
|
23
|
-
export
|
23
|
+
export type BodiedExtensionDefinition = BodiedExtensionBaseDefinition & MarksObject<DataConsumerDefinition | FragmentDefinition>;
|
24
24
|
export declare const bodiedExtension: NodeSpec;
|
@@ -5,7 +5,7 @@ import { MarksObject, NoMark } from './types/mark';
|
|
5
5
|
/**
|
6
6
|
* @name codeBlock_node
|
7
7
|
*/
|
8
|
-
export
|
8
|
+
export type CodeBlockBaseDefinition = {
|
9
9
|
type: 'codeBlock';
|
10
10
|
/**
|
11
11
|
* @allowUnsupportedInline true
|
@@ -14,17 +14,17 @@ export declare type CodeBlockBaseDefinition = {
|
|
14
14
|
marks?: Array<any>;
|
15
15
|
attrs?: CodeBlockAttrs;
|
16
16
|
};
|
17
|
-
export
|
17
|
+
export type CodeBlockAttrs = {
|
18
18
|
language?: string;
|
19
19
|
};
|
20
20
|
/**
|
21
21
|
* @name codeBlock_with_no_marks_node
|
22
22
|
*/
|
23
|
-
export
|
23
|
+
export type CodeBlockDefinition = CodeBlockBaseDefinition & NoMark;
|
24
24
|
/**
|
25
25
|
* @name codeBlock_with_marks_node
|
26
26
|
*/
|
27
|
-
export
|
27
|
+
export type CodeBlockWithMarksDefinition = CodeBlockBaseDefinition & MarksObject<BreakoutMarkDefinition>;
|
28
28
|
export declare const codeBlock: NodeSpec;
|
29
29
|
export declare const toJSON: (node: PMNode) => {
|
30
30
|
attrs: Record<string, any>;
|
@@ -20,11 +20,11 @@ export interface ExpandBaseDefinition {
|
|
20
20
|
/**
|
21
21
|
* @name expand_with_no_mark_node
|
22
22
|
*/
|
23
|
-
export
|
23
|
+
export type ExpandDefinition = ExpandBaseDefinition & NoMark;
|
24
24
|
/**
|
25
25
|
* @name expand_with_breakout_mark_node
|
26
26
|
*/
|
27
|
-
export
|
27
|
+
export type ExpandWithBreakoutDefinition = ExpandBaseDefinition & MarksObject<BreakoutMarkDefinition>;
|
28
28
|
export declare const expand: NodeSpec;
|
29
29
|
export declare const toJSON: (node: PMNode) => {
|
30
30
|
attrs: {
|
@@ -14,5 +14,5 @@ export interface ExtensionBaseDefinition {
|
|
14
14
|
/**
|
15
15
|
* @name extension_with_marks_node
|
16
16
|
*/
|
17
|
-
export
|
17
|
+
export type ExtensionDefinition = ExtensionBaseDefinition & MarksObject<DataConsumerDefinition | FragmentDefinition>;
|
18
18
|
export declare const extension: NodeSpec;
|
@@ -23,14 +23,14 @@ export interface HeadingBaseDefinition {
|
|
23
23
|
/**
|
24
24
|
* @name heading_with_no_marks_node
|
25
25
|
*/
|
26
|
-
export
|
26
|
+
export type HeadingDefinition = HeadingBaseDefinition & NoMark;
|
27
27
|
/**
|
28
28
|
* @name heading_with_alignment_node
|
29
29
|
*/
|
30
|
-
export
|
30
|
+
export type HeadingWithAlignmentDefinition = HeadingBaseDefinition & MarksObject<AlignmentMarkDefinition>;
|
31
31
|
/**
|
32
32
|
* @name heading_with_indentation_node
|
33
33
|
*/
|
34
|
-
export
|
35
|
-
export
|
34
|
+
export type HeadingWithIndentationDefinition = HeadingBaseDefinition & MarksObject<IndentationMarkDefinition>;
|
35
|
+
export type HeadingWithMarksDefinition = HeadingWithAlignmentDefinition | HeadingWithIndentationDefinition;
|
36
36
|
export declare const heading: NodeSpec;
|
@@ -14,5 +14,5 @@ export interface InlineExtensionBaseDefinition {
|
|
14
14
|
/**
|
15
15
|
* @name inlineExtension_with_marks_node
|
16
16
|
*/
|
17
|
-
export
|
17
|
+
export type InlineExtensionDefinition = InlineExtensionBaseDefinition & MarksObject<DataConsumerDefinition | FragmentDefinition>;
|
18
18
|
export declare const inlineExtension: NodeSpec;
|
@@ -4,7 +4,7 @@ import { BreakoutMarkDefinition } from '../marks';
|
|
4
4
|
/**
|
5
5
|
* @name layoutSection_node
|
6
6
|
*/
|
7
|
-
export
|
7
|
+
export type LayoutSectionBaseDefinition = {
|
8
8
|
type: 'layoutSection';
|
9
9
|
marks?: Array<BreakoutMarkDefinition>;
|
10
10
|
content: Array<LayoutColumnDefinition>;
|
@@ -15,7 +15,7 @@ export declare type LayoutSectionBaseDefinition = {
|
|
15
15
|
/**
|
16
16
|
* @name layoutSection_full_node
|
17
17
|
*/
|
18
|
-
export
|
18
|
+
export type LayoutSectionFullDefinition = LayoutSectionBaseDefinition & {
|
19
19
|
type: 'layoutSection';
|
20
20
|
marks?: Array<BreakoutMarkDefinition>;
|
21
21
|
/**
|
@@ -29,7 +29,7 @@ export declare type LayoutSectionFullDefinition = LayoutSectionBaseDefinition &
|
|
29
29
|
* @stage 0
|
30
30
|
* @name layoutSection_with_single_column_node
|
31
31
|
*/
|
32
|
-
export
|
32
|
+
export type LayoutSectionWithSingleColumnDefinition = LayoutSectionBaseDefinition & {
|
33
33
|
type: 'layoutSection';
|
34
34
|
marks?: Array<BreakoutMarkDefinition>;
|
35
35
|
/**
|
@@ -39,6 +39,6 @@ export declare type LayoutSectionWithSingleColumnDefinition = LayoutSectionBaseD
|
|
39
39
|
*/
|
40
40
|
content: Array<LayoutColumnDefinition>;
|
41
41
|
};
|
42
|
-
export
|
42
|
+
export type LayoutSectionDefinition = LayoutSectionFullDefinition | LayoutSectionWithSingleColumnDefinition;
|
43
43
|
export declare const layoutSection: NodeSpec;
|
44
44
|
export declare const layoutSectionWithSingleColumn: NodeSpec;
|
@@ -3,7 +3,7 @@ import { MediaDefinition as Media } from './media';
|
|
3
3
|
import { LinkDefinition } from '../marks/link';
|
4
4
|
import { RichMediaAttributes } from './types/rich-media-common';
|
5
5
|
import { CaptionDefinition as Caption } from './caption';
|
6
|
-
export
|
6
|
+
export type MediaSingleDefinition = MediaSingleFullDefinition | MediaSingleWithCaptionDefinition;
|
7
7
|
/**
|
8
8
|
* @name mediaSingle_node
|
9
9
|
* @additionalProperties true
|
@@ -27,7 +27,7 @@ export interface MediaCaptionContent {
|
|
27
27
|
/**
|
28
28
|
* @name mediaSingle_caption_node
|
29
29
|
*/
|
30
|
-
export
|
30
|
+
export type MediaSingleWithCaptionDefinition = MediaSingleBaseDefinition & MediaCaptionContent;
|
31
31
|
/**
|
32
32
|
* @additionalProperties true
|
33
33
|
*/
|
@@ -42,7 +42,7 @@ export interface MediaSingleFullContent {
|
|
42
42
|
/**
|
43
43
|
* @name mediaSingle_full_node
|
44
44
|
*/
|
45
|
-
export
|
45
|
+
export type MediaSingleFullDefinition = MediaSingleBaseDefinition & MediaSingleFullContent;
|
46
46
|
export declare const defaultAttrs: {
|
47
47
|
width: {
|
48
48
|
default: null;
|
@@ -1,9 +1,9 @@
|
|
1
1
|
import { NodeSpec, Node as PMNode } from 'prosemirror-model';
|
2
2
|
import { BorderMarkDefinition } from '../marks/border';
|
3
3
|
import { LinkDefinition } from '../marks/link';
|
4
|
-
export
|
5
|
-
export
|
6
|
-
export
|
4
|
+
export type MediaType = 'file' | 'link' | 'external';
|
5
|
+
export type DisplayType = 'file' | 'thumbnail';
|
6
|
+
export type DefaultAttributes<T> = {
|
7
7
|
[P in keyof T]: {
|
8
8
|
default?: T[P] | null;
|
9
9
|
};
|
@@ -51,7 +51,7 @@ export interface ExternalMediaAttributes {
|
|
51
51
|
height?: number;
|
52
52
|
__external?: boolean;
|
53
53
|
}
|
54
|
-
export
|
54
|
+
export type MediaADFAttrs = MediaAttributes | ExternalMediaAttributes;
|
55
55
|
export declare const defaultAttrs: DefaultAttributes<MediaADFAttrs>;
|
56
56
|
export declare const createMediaSpec: (attributes: Partial<NodeSpec['attrs']>, inline?: boolean) => NodeSpec;
|
57
57
|
export declare const media: NodeSpec;
|
@@ -9,7 +9,7 @@ import { MediaGroupDefinition as MediaGroup } from './media-group';
|
|
9
9
|
* @minItems 1
|
10
10
|
* @allowUnsupportedBlock true
|
11
11
|
*/
|
12
|
-
export
|
12
|
+
export type NestedExpandContent = Array<Paragraph | Heading | MediaSingle | MediaGroup>;
|
13
13
|
/**
|
14
14
|
* @name nestedExpand_node
|
15
15
|
*/
|
@@ -23,5 +23,5 @@ export interface NestedExpandBaseDefinition {
|
|
23
23
|
/**
|
24
24
|
* @name nestedExpand_with_no_marks_node
|
25
25
|
*/
|
26
|
-
export
|
26
|
+
export type NestedExpandDefinition = NestedExpandBaseDefinition & NoMark;
|
27
27
|
export declare const nestedExpand: NodeSpec;
|
@@ -16,7 +16,7 @@ export interface ParagraphBaseDefinition {
|
|
16
16
|
/**
|
17
17
|
* @name paragraph_with_no_marks_node
|
18
18
|
*/
|
19
|
-
export
|
19
|
+
export type ParagraphDefinition = ParagraphBaseDefinition & NoMark;
|
20
20
|
/**
|
21
21
|
* NOTE: Need this because TS is too smart and inline everything.
|
22
22
|
* So we need to give them separate identity.
|
@@ -28,10 +28,10 @@ export declare type ParagraphDefinition = ParagraphBaseDefinition & NoMark;
|
|
28
28
|
/**
|
29
29
|
* @name paragraph_with_alignment_node
|
30
30
|
*/
|
31
|
-
export
|
31
|
+
export type ParagraphWithAlignmentDefinition = ParagraphBaseDefinition & MarksObject<AlignmentMarkDefinition>;
|
32
32
|
/**
|
33
33
|
* @name paragraph_with_indentation_node
|
34
34
|
*/
|
35
|
-
export
|
36
|
-
export
|
35
|
+
export type ParagraphWithIndentationDefinition = ParagraphBaseDefinition & MarksObject<IndentationMarkDefinition>;
|
36
|
+
export type ParagraphWithMarksDefinition = ParagraphWithAlignmentDefinition | ParagraphWithIndentationDefinition;
|
37
37
|
export declare const paragraph: NodeSpec;
|
@@ -29,7 +29,7 @@ export declare const getCellAttrs: (dom: HTMLElement, defaultValues?: CellAttrib
|
|
29
29
|
colwidth: number[] | null;
|
30
30
|
background: string | null;
|
31
31
|
};
|
32
|
-
export
|
32
|
+
export type CellDomAttrs = {
|
33
33
|
colspan?: string;
|
34
34
|
rowspan?: string;
|
35
35
|
style?: string;
|
@@ -46,7 +46,7 @@ export declare const getCellDomAttrs: (node: PmNode) => CellDomAttrs;
|
|
46
46
|
export declare const tableBackgroundColorPalette: Map<string, string>;
|
47
47
|
export declare const tableBackgroundBorderColor: string;
|
48
48
|
export declare const tableBackgroundColorNames: Map<string, string>;
|
49
|
-
export
|
49
|
+
export type Layout = 'default' | 'full-width' | 'wide';
|
50
50
|
export interface TableAttributes {
|
51
51
|
isNumberColumnEnabled?: boolean;
|
52
52
|
layout?: Layout;
|
@@ -80,7 +80,7 @@ export interface TableRow {
|
|
80
80
|
* @minItems 1
|
81
81
|
* @allowUnsupportedBlock true
|
82
82
|
*/
|
83
|
-
export
|
83
|
+
export type TableCellContent = Array<Panel | Paragraph | ParagraphWithMarks | Blockquote | OrderedList | BulletList | Rule | Heading | HeadingWithMarks | CodeBlock | MediaGroup | MediaSingle | DecisionList | TaskList | Extension | BlockCard | NestedExpand | EmbedCard>;
|
84
84
|
/**
|
85
85
|
* @name table_cell_node
|
86
86
|
*/
|
@@ -19,4 +19,4 @@ import { EmbedCardDefinition as EmbedCard } from '../embed-card';
|
|
19
19
|
/**
|
20
20
|
* @name block_content
|
21
21
|
*/
|
22
|
-
export
|
22
|
+
export type BlockContent = Panel | Paragraph | ParagraphWithMarks | Blockquote | OrderedList | BulletList | Rule | Heading | HeadingWithMarks | CodeBlock | MediaGroup | MediaSingle | DecisionList | TaskList | Table | Expand | Extension | BodiedExtension | BlockCard | EmbedCard;
|
@@ -13,20 +13,20 @@ import { MediaInlineDefinition } from '../media-inline';
|
|
13
13
|
/**
|
14
14
|
* @name formatted_text_inline_node
|
15
15
|
*/
|
16
|
-
export
|
16
|
+
export type InlineFormattedText = Text & MarksObject<Link | Em | Strong | Strike | SubSup | Underline | TextColor | Annotation>;
|
17
17
|
/**
|
18
18
|
* @name link_text_inline_node
|
19
19
|
*/
|
20
|
-
export
|
20
|
+
export type InlineLinkText = Text & MarksObject<Link>;
|
21
21
|
/**
|
22
22
|
* @name code_inline_node
|
23
23
|
*/
|
24
|
-
export
|
24
|
+
export type InlineCode = Text & MarksObject<Code | Link | Annotation>;
|
25
25
|
/**
|
26
26
|
* @name atomic_inline_node
|
27
27
|
*/
|
28
|
-
export
|
28
|
+
export type InlineAtomic = HardBreak | Mention | Emoji | InlineExtensionDefinition | Date | Placeholder | InlineCard | Status | MediaInlineDefinition;
|
29
29
|
/**
|
30
30
|
* @name inline_node
|
31
31
|
*/
|
32
|
-
export
|
32
|
+
export type Inline = InlineFormattedText | InlineCode | InlineAtomic;
|
@@ -17,4 +17,4 @@ import { EmbedCardDefinition as EmbedCard } from '../embed-card';
|
|
17
17
|
/**
|
18
18
|
* @name non_nestable_block_content
|
19
19
|
*/
|
20
|
-
export
|
20
|
+
export type NonNestableBlockContent = Panel | Paragraph | Blockquote | OrderedList | BulletList | Rule | Heading | CodeBlock | MediaGroup | MediaSingle | DecisionList | TaskList | Table | Extension | BlockCard | EmbedCard;
|
@@ -1,4 +1,4 @@
|
|
1
|
-
export
|
1
|
+
export type Layout = 'wrap-right' | 'center' | 'wrap-left' | 'wide' | 'full-width' | 'align-end' | 'align-start';
|
2
2
|
export interface RichMediaAttributes {
|
3
3
|
/**
|
4
4
|
* @minimum 0
|
@@ -31,8 +31,8 @@ interface RedoAnalyticsEventPayload {
|
|
31
31
|
attributes?: Record<string, any>;
|
32
32
|
eventType: string;
|
33
33
|
}
|
34
|
-
|
35
|
-
export
|
34
|
+
type AnalyticsInvertPayload = UndoAnalyticsEventPayload | RedoAnalyticsEventPayload;
|
35
|
+
export type AnalyticsInvertStep = AnalyticsStep<AnalyticsInvertPayload>;
|
36
36
|
/**
|
37
37
|
* Custom Prosemirror Step to fire our GAS V3 analytics events
|
38
38
|
* Using a Step means that it will work with prosemirror-history and we get
|
@@ -2,7 +2,7 @@ import { Node as PMNode, Schema } from 'prosemirror-model';
|
|
2
2
|
import { ReplaceStep, Step, StepMap, StepResult, Mappable } from 'prosemirror-transform';
|
3
3
|
export declare const stepType = "editor-linking-meta";
|
4
4
|
export declare const invertStepType = "editor-linking-meta-invert";
|
5
|
-
export
|
5
|
+
export type LinkStepMetadata = {
|
6
6
|
/**
|
7
7
|
* Editor action performed
|
8
8
|
*/
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { Node as ProseMirrorNode } from 'prosemirror-model';
|
2
2
|
import { SideEffects, SideEffectsJSON } from './utils/side-effects/types';
|
3
3
|
import { SortOrder } from './constants';
|
4
|
-
export
|
4
|
+
export type ColumnInfo = Map<number, CellStep>;
|
5
5
|
export interface AddColumnStepInfo {
|
6
6
|
cells: CellStep[];
|
7
7
|
sideEffects?: SideEffects;
|
@@ -23,11 +23,11 @@ export interface RowSideEffectJSON {
|
|
23
23
|
[key: string]: any;
|
24
24
|
};
|
25
25
|
}
|
26
|
-
export
|
26
|
+
export type SideEffects = {
|
27
27
|
table?: TableSideEffect;
|
28
28
|
rows?: RowSideEffect[];
|
29
29
|
};
|
30
|
-
export
|
30
|
+
export type SideEffectsJSON = {
|
31
31
|
table?: TableSideEffectJSON;
|
32
32
|
rows?: RowSideEffectJSON[];
|
33
33
|
};
|
@@ -31,7 +31,7 @@ declare const acNameToEmojiMap: {
|
|
31
31
|
heart: string[];
|
32
32
|
'broken-heart': string[];
|
33
33
|
};
|
34
|
-
export
|
34
|
+
export type NameToEmoji = keyof typeof acNameToEmojiMap;
|
35
35
|
export declare function acNameToEmoji(acName: NameToEmoji): {
|
36
36
|
id: string;
|
37
37
|
shortName: string;
|
package/json-schema/package.json
CHANGED
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@atlaskit/adf-schema",
|
3
|
-
"version": "25.6.
|
3
|
+
"version": "25.6.2",
|
4
4
|
"description": "Shared package that contains the ADF-schema (json) and ProseMirror node/mark specs",
|
5
5
|
"publishConfig": {
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
@@ -12,6 +12,14 @@
|
|
12
12
|
"module": "dist/esm/index.js",
|
13
13
|
"module:es2019": "dist/es2019/index.js",
|
14
14
|
"types": "dist/types/index.d.ts",
|
15
|
+
"typesVersions": {
|
16
|
+
">=4.5 <4.9": {
|
17
|
+
"*": [
|
18
|
+
"dist/types-ts4.5/*",
|
19
|
+
"dist/types-ts4.5/index.d.ts"
|
20
|
+
]
|
21
|
+
}
|
22
|
+
},
|
15
23
|
"sideEffects": false,
|
16
24
|
"atlaskit:src": "src/index.ts",
|
17
25
|
"atlassian": {
|
@@ -40,9 +48,9 @@
|
|
40
48
|
},
|
41
49
|
"dependencies": {
|
42
50
|
"@atlaskit/codemod-utils": "^4.2.0",
|
43
|
-
"@atlaskit/editor-palette": "1.4.
|
51
|
+
"@atlaskit/editor-palette": "1.4.1",
|
44
52
|
"@atlaskit/editor-tables": "^2.3.0",
|
45
|
-
"@atlaskit/tokens": "^1.
|
53
|
+
"@atlaskit/tokens": "^1.4.0",
|
46
54
|
"@babel/runtime": "^7.0.0",
|
47
55
|
"@types/linkify-it": "^2.0.4",
|
48
56
|
"@types/prosemirror-model": "^1.11.0",
|
@@ -66,7 +74,7 @@
|
|
66
74
|
"json-schema-diff-validator": "^0.4.1",
|
67
75
|
"prosemirror-history": "^1.1.3",
|
68
76
|
"prosemirror-state": "1.3.4",
|
69
|
-
"typescript": "4.
|
77
|
+
"typescript": "~4.9.5"
|
70
78
|
},
|
71
79
|
"techstack": {
|
72
80
|
"@atlassian/frontend": {
|
package/schema/package.json
CHANGED
@@ -6,9 +6,9 @@
|
|
6
6
|
"sideEffects": false,
|
7
7
|
"types": "../dist/types/schema/bitbucket-schema.d.ts",
|
8
8
|
"typesVersions": {
|
9
|
-
">=4.
|
9
|
+
">=4.5 <4.9": {
|
10
10
|
"*": [
|
11
|
-
"../dist/types-ts4.
|
11
|
+
"../dist/types-ts4.5/schema/bitbucket-schema.d.ts"
|
12
12
|
]
|
13
13
|
}
|
14
14
|
}
|
@@ -6,9 +6,9 @@
|
|
6
6
|
"sideEffects": false,
|
7
7
|
"types": "../dist/types/schema/confluence-schema.d.ts",
|
8
8
|
"typesVersions": {
|
9
|
-
">=4.
|
9
|
+
">=4.5 <4.9": {
|
10
10
|
"*": [
|
11
|
-
"../dist/types-ts4.
|
11
|
+
"../dist/types-ts4.5/schema/confluence-schema.d.ts"
|
12
12
|
]
|
13
13
|
}
|
14
14
|
}
|