@atlaskit/adf-schema 48.0.0 → 49.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 +6 -0
- package/dist/cjs/index.js +0 -42
- package/dist/cjs/next-schema/generated/nodeTypes.js +1 -58
- package/dist/cjs/next-schema/groups/blockContentGroup.js +1 -1
- package/dist/cjs/next-schema/groups/blockGroup.js +1 -1
- package/dist/cjs/next-schema/groups/tableCellContentPseudoGroup.js +1 -1
- package/dist/cjs/next-schema/nodes/blockquote.js +0 -8
- package/dist/cjs/next-schema/nodes/expand.js +1 -1
- package/dist/cjs/next-schema/nodes/list.js +2 -6
- package/dist/cjs/next-schema/nodes/nestedExpand.js +0 -6
- package/dist/cjs/next-schema/nodes/panel.js +0 -4
- package/dist/cjs/schema/create-schema.js +1 -1
- package/dist/cjs/schema/index.js +0 -42
- package/dist/cjs/schema/nodes/blockquote.js +2 -34
- package/dist/cjs/schema/nodes/index.js +0 -42
- package/dist/cjs/schema/nodes/list-item.js +1 -19
- package/dist/cjs/schema/nodes/nested-expand.js +2 -32
- package/dist/cjs/schema/nodes/panel.js +1 -4
- package/dist/es2019/index.js +2 -2
- package/dist/es2019/next-schema/generated/nodeTypes.js +0 -57
- package/dist/es2019/next-schema/groups/blockContentGroup.js +1 -1
- package/dist/es2019/next-schema/groups/blockGroup.js +1 -1
- package/dist/es2019/next-schema/groups/tableCellContentPseudoGroup.js +1 -1
- package/dist/es2019/next-schema/nodes/blockquote.js +0 -8
- package/dist/es2019/next-schema/nodes/expand.js +1 -1
- package/dist/es2019/next-schema/nodes/list.js +2 -6
- package/dist/es2019/next-schema/nodes/nestedExpand.js +0 -6
- package/dist/es2019/next-schema/nodes/panel.js +0 -4
- package/dist/es2019/schema/create-schema.js +2 -2
- package/dist/es2019/schema/index.js +1 -1
- package/dist/es2019/schema/nodes/blockquote.js +2 -34
- package/dist/es2019/schema/nodes/index.js +4 -4
- package/dist/es2019/schema/nodes/list-item.js +1 -19
- package/dist/es2019/schema/nodes/nested-expand.js +2 -32
- package/dist/es2019/schema/nodes/panel.js +2 -3
- package/dist/esm/index.js +2 -2
- package/dist/esm/next-schema/generated/nodeTypes.js +0 -57
- package/dist/esm/next-schema/groups/blockContentGroup.js +1 -1
- package/dist/esm/next-schema/groups/blockGroup.js +1 -1
- package/dist/esm/next-schema/groups/tableCellContentPseudoGroup.js +1 -1
- package/dist/esm/next-schema/nodes/blockquote.js +0 -8
- package/dist/esm/next-schema/nodes/expand.js +1 -1
- package/dist/esm/next-schema/nodes/list.js +2 -6
- package/dist/esm/next-schema/nodes/nestedExpand.js +0 -6
- package/dist/esm/next-schema/nodes/panel.js +0 -4
- package/dist/esm/schema/create-schema.js +2 -2
- package/dist/esm/schema/index.js +1 -1
- package/dist/esm/schema/nodes/blockquote.js +2 -34
- package/dist/esm/schema/nodes/index.js +4 -4
- package/dist/esm/schema/nodes/list-item.js +1 -19
- package/dist/esm/schema/nodes/nested-expand.js +2 -32
- package/dist/esm/schema/nodes/panel.js +1 -4
- package/dist/types/index.d.ts +2 -2
- package/dist/types/next-schema/generated/nodeGroupTypes.d.ts +2 -2
- package/dist/types/next-schema/generated/nodeTypes.d.ts +8 -53
- package/dist/types/next-schema/groups/nonNestableBlockContentGroup.d.ts +1 -11
- package/dist/types/next-schema/groups/tableCellContentPseudoGroup.d.ts +1 -17
- package/dist/types/next-schema/nodes/blockquote.d.ts +1 -7
- package/dist/types/next-schema/nodes/nestedExpand.d.ts +1 -7
- package/dist/types/next-schema/nodes/panel.d.ts +1 -5
- package/dist/types/schema/index.d.ts +1 -1
- package/dist/types/schema/nodes/blockquote.d.ts +0 -15
- package/dist/types/schema/nodes/index.d.ts +4 -4
- package/dist/types/schema/nodes/list-item.d.ts +0 -10
- package/dist/types/schema/nodes/nested-expand.d.ts +0 -5
- package/dist/types/schema/nodes/panel.d.ts +0 -1
- package/package.json +1 -1
@@ -41,20 +41,6 @@ export const blockquoteLegacy = createPMNodeSpecFactory({
|
|
41
41
|
selectable: true,
|
42
42
|
defining: true
|
43
43
|
});
|
44
|
-
export const blockquoteWithoutNestedCodeblockOrMedia = createPMNodeSpecFactory({
|
45
|
-
content: '(paragraph | orderedList | bulletList | unsupportedBlock)+',
|
46
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
47
|
-
group: 'block',
|
48
|
-
selectable: true,
|
49
|
-
defining: true
|
50
|
-
});
|
51
|
-
export const blockquoteWithoutNonBodiedMacros = createPMNodeSpecFactory({
|
52
|
-
content: '(paragraph | orderedList | bulletList | unsupportedBlock | codeBlock | mediaSingle | mediaGroup)+',
|
53
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
54
|
-
group: 'block',
|
55
|
-
selectable: true,
|
56
|
-
defining: true
|
57
|
-
});
|
58
44
|
export const bodiedExtension = createPMNodeSpecFactory({
|
59
45
|
content: '(paragraph | panel | blockquote | orderedList | bulletList | rule | heading | codeBlock | mediaGroup | mediaSingle | decisionList | taskList | table | blockCard | embedCard | extension | unsupportedBlock)+',
|
60
46
|
marks: 'dataConsumer fragment unsupportedMark unsupportedNodeAttribute',
|
@@ -577,12 +563,6 @@ export const listItemWithNestedDecisionStage0 = createPMNodeSpecFactory({
|
|
577
563
|
selectable: false,
|
578
564
|
defining: true
|
579
565
|
});
|
580
|
-
export const listItemWithoutNonBodiedMacros = createPMNodeSpecFactory({
|
581
|
-
content: '(paragraph | mediaSingle | codeBlock | unsupportedBlock) (paragraph | bulletList | orderedList | taskList | mediaSingle | codeBlock | unsupportedBlock)*',
|
582
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
583
|
-
selectable: false,
|
584
|
-
defining: true
|
585
|
-
});
|
586
566
|
export const media = createPMNodeSpecFactory({
|
587
567
|
attrs: {
|
588
568
|
type: {
|
@@ -855,20 +835,6 @@ export const nestedExpandWithNoMarks = createPMNodeSpecFactory({
|
|
855
835
|
selectable: true,
|
856
836
|
isolating: true
|
857
837
|
});
|
858
|
-
export const nestedExpandWithoutNonBodiedMacros = createPMNodeSpecFactory({
|
859
|
-
content: '(paragraph | heading | mediaSingle | mediaGroup | codeBlock | bulletList | orderedList | taskList | decisionList | rule | panel | blockquote | unsupportedBlock)+',
|
860
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
861
|
-
attrs: {
|
862
|
-
title: {
|
863
|
-
default: ''
|
864
|
-
},
|
865
|
-
__expanded: {
|
866
|
-
default: true
|
867
|
-
}
|
868
|
-
},
|
869
|
-
selectable: true,
|
870
|
-
isolating: true
|
871
|
-
});
|
872
838
|
export const orderedList = createPMNodeSpecFactory({
|
873
839
|
content: 'listItem+',
|
874
840
|
marks: 'unsupportedMark unsupportedNodeAttribute',
|
@@ -903,29 +869,6 @@ export const panel = createPMNodeSpecFactory({
|
|
903
869
|
},
|
904
870
|
selectable: true
|
905
871
|
});
|
906
|
-
export const panelWithoutNestedNonBodiedMacros = createPMNodeSpecFactory({
|
907
|
-
content: '(paragraph | heading | bulletList | orderedList | blockCard | mediaGroup | mediaSingle | codeBlock | taskList | rule | decisionList | unsupportedBlock)+',
|
908
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
909
|
-
group: 'block',
|
910
|
-
attrs: {
|
911
|
-
panelType: {
|
912
|
-
default: 'info'
|
913
|
-
},
|
914
|
-
panelIcon: {
|
915
|
-
default: null
|
916
|
-
},
|
917
|
-
panelIconId: {
|
918
|
-
default: null
|
919
|
-
},
|
920
|
-
panelIconText: {
|
921
|
-
default: null
|
922
|
-
},
|
923
|
-
panelColor: {
|
924
|
-
default: null
|
925
|
-
}
|
926
|
-
},
|
927
|
-
selectable: true
|
928
|
-
});
|
929
872
|
export const paragraph = createPMNodeSpecFactory({
|
930
873
|
content: 'inline*',
|
931
874
|
marks: 'link em strong strike subsup underline textColor annotation backgroundColor typeAheadQuery confluenceInlineComment unsupportedNodeAttribute unsupportedMark code dataConsumer fragment border',
|
@@ -30,7 +30,7 @@ import { unsupportedBlock } from '../nodes/unsupportedBlock';
|
|
30
30
|
* - no base mediaSingle
|
31
31
|
* - no base heading
|
32
32
|
*/
|
33
|
-
export const blockContentGroup = adfNodeGroup('block_content', [blockCard, paragraph.use('with_no_marks'), paragraph.use('with_alignment'), paragraph.use('with_indentation'), mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, taskList, bulletList, orderedList, heading.use('with_no_marks'), heading.use('with_alignment'), heading.use('with_indentation'), mediaGroup, decisionList, rule, panel,
|
33
|
+
export const blockContentGroup = adfNodeGroup('block_content', [blockCard, paragraph.use('with_no_marks'), paragraph.use('with_alignment'), paragraph.use('with_indentation'), mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, taskList, bulletList, orderedList, heading.use('with_no_marks'), heading.use('with_alignment'), heading.use('with_indentation'), mediaGroup, decisionList, rule, panel, blockquote, extension.use('with_marks'), embedCard, table,
|
34
34
|
// @ts-expect-error - types don't deal well with circular references for the variant
|
35
35
|
table.use('with_nested_table'), expand, bodiedExtension.use('with_marks'), confluenceUnsupportedBlock, unsupportedBlock], {
|
36
36
|
ignore: ['pm-spec']
|
@@ -18,7 +18,7 @@ import { rule } from '../nodes/rule';
|
|
18
18
|
import { table } from '../nodes/tableNodes';
|
19
19
|
import { taskList } from '../nodes/task';
|
20
20
|
import { unsupportedBlock } from '../nodes/unsupportedBlock';
|
21
|
-
export const blockGroup = adfNodeGroup('block', [blockCard, codeBlock, mediaSingle, mediaSingle.use('caption'), mediaSingle.use('full'), mediaSingle.use('width_type'), paragraph, paragraph.use('with_alignment'), paragraph.use('with_indentation'), paragraph.use('with_no_marks'), taskList, orderedList, bulletList, blockquote, blockquote.use('legacy'),
|
21
|
+
export const blockGroup = adfNodeGroup('block', [blockCard, codeBlock, mediaSingle, mediaSingle.use('caption'), mediaSingle.use('full'), mediaSingle.use('width_type'), paragraph, paragraph.use('with_alignment'), paragraph.use('with_indentation'), paragraph.use('with_no_marks'), taskList, orderedList, bulletList, blockquote, blockquote.use('legacy'), decisionList, embedCard, extension, extension.use('with_marks'), heading, heading.use('with_indentation'), heading.use('with_no_marks'), heading.use('with_alignment'), mediaGroup, rule, panel, table,
|
22
22
|
// @ts-expect-error - types don't deal well with circular references for the variant
|
23
23
|
table.use('with_nested_table'), bodiedExtension, bodiedExtension.use('with_marks'), expand, confluenceUnsupportedBlock, unsupportedBlock], {
|
24
24
|
// @DSLCompatibilityException
|
@@ -15,7 +15,7 @@ import { paragraph } from '../nodes/paragraph';
|
|
15
15
|
import { rule } from '../nodes/rule';
|
16
16
|
import { taskList } from '../nodes/task';
|
17
17
|
import { unsupportedBlock } from '../nodes/unsupportedBlock';
|
18
|
-
export const tableCellContentNodes = [paragraph.use('with_no_marks'), paragraph.use('with_alignment'), panel, blockquote, orderedList, bulletList, rule, heading.use('with_no_marks'), heading.use('with_alignment'), heading.use('with_indentation'), codeBlock, mediaSingle.use('caption'), mediaSingle.use('full'), mediaGroup, decisionList, taskList, blockCard, embedCard, extension.use('with_marks'), nestedExpand.use('content'), nestedExpand.use('with_no_marks')
|
18
|
+
export const tableCellContentNodes = [paragraph.use('with_no_marks'), paragraph.use('with_alignment'), panel, blockquote, orderedList, bulletList, rule, heading.use('with_no_marks'), heading.use('with_alignment'), heading.use('with_indentation'), codeBlock, mediaSingle.use('caption'), mediaSingle.use('full'), mediaGroup, decisionList, taskList, blockCard, embedCard, extension.use('with_marks'), nestedExpand.use('content'), nestedExpand.use('with_no_marks')];
|
19
19
|
|
20
20
|
// This is not an actual group, but a collection of nodes
|
21
21
|
// @DSLCompatibilityException JSON Schema and PM Spec are not in sync. We need to fix it
|
@@ -17,12 +17,4 @@ export const blockquote = adfNode('blockquote').define({
|
|
17
17
|
}).variant('legacy', {
|
18
18
|
ignore: ['json-schema', 'validator-spec'],
|
19
19
|
content: [$onePlus($or(paragraph, unsupportedBlock))]
|
20
|
-
}).variant('without_non_bodied_macros', {
|
21
|
-
content: [$onePlus($or(paragraph.use('with_no_marks'), orderedList, bulletList, unsupportedBlock, codeBlock, mediaSingle.use('caption'), mediaSingle.use('full'), mediaGroup))],
|
22
|
-
ignore: ['json-schema', 'validator-spec']
|
23
|
-
})
|
24
|
-
// TODO: Clean up this variant
|
25
|
-
.variant('without_nested_codeblock_or_media', {
|
26
|
-
content: [$onePlus($or(paragraph.use('with_no_marks'), orderedList, bulletList, unsupportedBlock))],
|
27
|
-
ignore: ['json-schema', 'validator-spec']
|
28
20
|
});
|
@@ -20,7 +20,7 @@ export const expand = adfNode('expand').define({
|
|
20
20
|
optional: true
|
21
21
|
}
|
22
22
|
},
|
23
|
-
content: [$onePlus($or(nonNestableBlockContentGroup, nestedExpand.use('with_no_marks')
|
23
|
+
content: [$onePlus($or(nonNestableBlockContentGroup, nestedExpand.use('with_no_marks')))]
|
24
24
|
}).variant('root_only', {
|
25
25
|
marks: [breakout, unsupportedMark, unsupportedNodeAttribute],
|
26
26
|
noMarks: false,
|
@@ -20,10 +20,6 @@ const listItem = adfNode('listItem').define({
|
|
20
20
|
content: [$or(paragraph.use('with_no_marks'), mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, unsupportedBlock, decisionList, extension.use('with_marks')), $zeroPlus($or(paragraph.use('with_no_marks'), bulletList, orderedList, taskList, mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, unsupportedBlock, decisionList, extension.use('with_marks')))],
|
21
21
|
noExtend: true,
|
22
22
|
stage0: true
|
23
|
-
}).variant('without_non_bodied_macros', {
|
24
|
-
content: [$or(paragraph.use('with_no_marks'), mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, unsupportedBlock), $zeroPlus($or(paragraph.use('with_no_marks'), bulletList, orderedList, taskList, mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, unsupportedBlock))],
|
25
|
-
noExtend: true,
|
26
|
-
ignore: ['json-schema', 'validator-spec']
|
27
23
|
});
|
28
24
|
orderedList.define({
|
29
25
|
selectable: false,
|
@@ -36,10 +32,10 @@ orderedList.define({
|
|
36
32
|
optional: true
|
37
33
|
}
|
38
34
|
},
|
39
|
-
content: [$onePlus($or(listItem, listItem.use('with_nested_decision')
|
35
|
+
content: [$onePlus($or(listItem, listItem.use('with_nested_decision')))]
|
40
36
|
});
|
41
37
|
bulletList.define({
|
42
38
|
selectable: false,
|
43
39
|
marks: [unsupportedMark, unsupportedNodeAttribute],
|
44
|
-
content: [$onePlus($or(listItem, listItem.use('with_nested_decision')
|
40
|
+
content: [$onePlus($or(listItem, listItem.use('with_nested_decision')))]
|
45
41
|
});
|
@@ -54,10 +54,4 @@ export const nestedExpand = adfNode('nestedExpand').define({
|
|
54
54
|
marks: [],
|
55
55
|
content: [],
|
56
56
|
noMarks: true
|
57
|
-
}).variant('without_non_bodied_macros', {
|
58
|
-
marks: [],
|
59
|
-
content: [$onePlus($or(...nestedExpandContent))],
|
60
|
-
noMarks: true,
|
61
|
-
noExtend: true,
|
62
|
-
ignore: ['json-schema', 'validator-spec']
|
63
57
|
});
|
@@ -45,8 +45,4 @@ export const panel = adfNode('panel').define({
|
|
45
45
|
}
|
46
46
|
},
|
47
47
|
content: [$onePlus($or(...panelContent, extension.use('with_marks')))]
|
48
|
-
}).variant('without_nested_non_bodied_macros', {
|
49
|
-
content: [$onePlus($or(...panelContent))],
|
50
|
-
noExtend: true,
|
51
|
-
ignore: ['json-schema', 'validator-spec']
|
52
48
|
});
|
@@ -2,7 +2,7 @@ import { Schema } from '@atlaskit/editor-prosemirror/model';
|
|
2
2
|
import { COLOR, FONT_STYLE, SEARCH_QUERY, LINK } from './groups';
|
3
3
|
import { sanitizeNodes } from './sanitizeNodes';
|
4
4
|
import { link, em, strong, textColor, strike, subsup, underline, code, typeAheadQuery, confluenceInlineComment, breakout, alignment, indentation, annotation, unsupportedMark, unsupportedNodeAttribute, dataConsumer, fragment, border, backgroundColor } from './marks';
|
5
|
-
import { confluenceJiraIssue, confluenceUnsupportedBlock, confluenceUnsupportedInline, doc, paragraph, text, bulletList, orderedListWithOrder,
|
5
|
+
import { confluenceJiraIssue, confluenceUnsupportedBlock, confluenceUnsupportedInline, doc, paragraph, text, bulletList, orderedListWithOrder, listItem, heading, codeBlock, extendedPanel, rule, image, mention, media, mediaInline, mediaSingleFull, mediaGroup, hardBreak, emoji, table, tableCell, tableHeader, tableRow, decisionList, decisionItem, taskList, taskItem, unknownBlock, extension, inlineExtension, bodiedExtension, multiBodiedExtension, extensionFrame, date, placeholder, layoutSection, layoutColumn, inlineCard, blockCard, unsupportedBlock, unsupportedInline, status, expandWithNestedExpand, nestedExpand, embedCard, caption, extendedBlockquote } from './nodes';
|
6
6
|
function addItems(builtInItems, config, customSpecs = {}) {
|
7
7
|
if (!config) {
|
8
8
|
return {};
|
@@ -67,7 +67,7 @@ const nodesInOrder = [{
|
|
67
67
|
spec: orderedListWithOrder
|
68
68
|
}, {
|
69
69
|
name: 'listItem',
|
70
|
-
spec:
|
70
|
+
spec: listItem
|
71
71
|
}, {
|
72
72
|
name: 'heading',
|
73
73
|
spec: heading
|
@@ -1,4 +1,4 @@
|
|
1
|
-
export { PanelType, blockCard, blockquote,
|
1
|
+
export { PanelType, blockCard, blockquote, extendedBlockquote, bodiedExtension, bulletList, bulletListSelector, caption, codeBlock, codeBlockToJSON, confluenceJiraIssue, confluenceUnsupportedBlock, confluenceUnsupportedInline, copyPrivateMediaAttributes, date, decisionItem, decisionList, decisionListSelector, doc, embedCard, emoji, expandWithNestedExpand, expandToJSON, extension, hardBreak, heading, image, inlineCard, inlineExtension, layoutColumn, layoutSection, layoutSectionWithSingleColumn, listItem, listItemWithDecisionStage0, media, mediaGroup, mediaSingle, mediaSingleSpec, mediaInline, mediaSingleWithCaption, mediaSingleWithWidthType, mediaSingleFull, mediaSingleToJSON, mediaToJSON, mention, mentionToJSON, nestedExpand, orderedList, orderedListSelector, orderedListWithOrder, extendedPanel, paragraph, placeholder, rule, getCellAttrs, getCellDomAttrs, status, table, tableStage0, tableWithCustomWidth, tableBackgroundBorderColor, tableBackgroundColorNames, tableBackgroundColorPalette, tableCell, tableCellContentDomSelector, tableCellContentWrapperSelector, tableCellSelector, tableHeader, tableHeaderSelector, tablePrefixSelector, tableRow, tableToJSON, taskItem, taskList, taskListSelector, text, toJSONTableCell, toJSONTableHeader, unknownBlock, unsupportedBlock, unsupportedInline, extensionFrame, multiBodiedExtension, tableWithNestedTable, tableRowWithNestedTable, tableCellWithNestedTable, tableHeaderWithNestedTable } from './nodes';
|
2
2
|
export { AnnotationTypes, alignment, alignmentPositionMap, annotation, breakout, code, colorPalette, /** @deprecated [ED-15849] The extended palette is now rolled into the main one. Use `colorPalette` instead. */
|
3
3
|
colorPaletteExtended, confluenceInlineComment, dataConsumer, dataConsumerToJSON, em, fragment, fragmentToJSON, indentation, link, linkToJSON, strike, strong, subsup, textColor, typeAheadQuery, underline, buildAnnotationMarkDataAttributes, AnnotationMarkStates, unsupportedMark, unsupportedNodeAttribute, border, borderColorPalette, backgroundColor, backgroundColorPalette } from './marks';
|
4
4
|
export { unsupportedNodeTypesForMediaCards } from './unsupported';
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { blockquote as blockquoteFactory } from '../../next-schema/generated/nodeTypes';
|
2
|
-
import { blockquoteLegacy as blockquoteLegacyFactory
|
2
|
+
import { blockquoteLegacy as blockquoteLegacyFactory } from '../../next-schema/generated/nodeTypes';
|
3
3
|
|
4
4
|
/**
|
5
5
|
* @name blockquote_node
|
@@ -15,40 +15,8 @@ const nodeSpecOptions = {
|
|
15
15
|
};
|
16
16
|
export const blockquote = blockquoteLegacyFactory(nodeSpecOptions);
|
17
17
|
|
18
|
-
/**
|
19
|
-
* @name blockquoteWithNestedCodeblockOrMedia
|
20
|
-
* @deprecated use extentedBlockquote instead
|
21
|
-
*/
|
22
|
-
export const blockquoteWithNestedCodeblockOrMedia = blockquoteWithoutNonBodiedMacrosFactory(nodeSpecOptions);
|
23
|
-
|
24
18
|
/**
|
25
19
|
* @name extentedBlockquote
|
26
20
|
* @description the block quote node with nested code block, media, and extension
|
27
21
|
*/
|
28
|
-
export const extendedBlockquote = blockquoteFactory(nodeSpecOptions);
|
29
|
-
|
30
|
-
/**
|
31
|
-
* @name blockquote_with_list_node
|
32
|
-
* @deprecated use extentedBlockquote instead
|
33
|
-
* TODO: remove this node in the next major version
|
34
|
-
*/
|
35
|
-
export const blockquoteWithList = blockquoteWithoutNestedCodeblockOrMediaFactory({
|
36
|
-
parseDOM: [{
|
37
|
-
tag: 'blockquote'
|
38
|
-
}],
|
39
|
-
toDOM() {
|
40
|
-
return ['blockquote', 0];
|
41
|
-
}
|
42
|
-
});
|
43
|
-
|
44
|
-
/**
|
45
|
-
* @name blockquote_without_non_bodied_macros_node
|
46
|
-
*/
|
47
|
-
export const blockquoteWithoutNonBodiedMacros = blockquoteWithoutNonBodiedMacrosFactory({
|
48
|
-
parseDOM: [{
|
49
|
-
tag: 'blockquote'
|
50
|
-
}],
|
51
|
-
toDOM() {
|
52
|
-
return ['blockquote', 0];
|
53
|
-
}
|
54
|
-
});
|
22
|
+
export const extendedBlockquote = blockquoteFactory(nodeSpecOptions);
|
@@ -3,7 +3,7 @@ export { confluenceJiraIssue } from './confluence-jira-issue';
|
|
3
3
|
export { confluenceUnsupportedBlock } from './confluence-unsupported-block';
|
4
4
|
export { confluenceUnsupportedInline } from './confluence-unsupported-inline';
|
5
5
|
export { doc } from './doc';
|
6
|
-
export { blockquote,
|
6
|
+
export { blockquote, extendedBlockquote } from './blockquote';
|
7
7
|
export { bulletList, bulletListSelector } from './bullet-list';
|
8
8
|
export { codeBlock, toJSON as codeBlockToJSON } from './code-block';
|
9
9
|
export { hardBreak } from './hard-break';
|
@@ -14,8 +14,8 @@ export { paragraph } from './paragraph';
|
|
14
14
|
export { emoji } from './emoji';
|
15
15
|
export { image } from './image';
|
16
16
|
export { mention, toJSON as mentionToJSON } from './mention';
|
17
|
-
export { listItem,
|
18
|
-
export { extendedPanel,
|
17
|
+
export { listItem, listItemWithDecisionStage0 } from './list-item';
|
18
|
+
export { extendedPanel, PanelType } from './panel';
|
19
19
|
export { text } from './text';
|
20
20
|
export { default as unknownBlock } from './unknown-block';
|
21
21
|
export { caption } from './caption';
|
@@ -37,7 +37,7 @@ export { blockCard } from './block-card';
|
|
37
37
|
export { unsupportedBlock } from './unsupported-block';
|
38
38
|
export { unsupportedInline } from './unsupported-inline';
|
39
39
|
export { status } from './status';
|
40
|
-
export { nestedExpand
|
40
|
+
export { nestedExpand } from './nested-expand';
|
41
41
|
export { embedCard } from './embed-card';
|
42
42
|
// Extensions
|
43
43
|
export { extension } from './extension';
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { listItem as listItemFactory, listItemWithNestedDecisionStage0 as listItemWithNestedDecisionStage0Factory
|
1
|
+
import { listItem as listItemFactory, listItemWithNestedDecisionStage0 as listItemWithNestedDecisionStage0Factory } from '../../next-schema/generated/nodeTypes';
|
2
2
|
|
3
3
|
/**
|
4
4
|
* @name list_item
|
@@ -13,12 +13,6 @@ export const listItem = listItemFactory({
|
|
13
13
|
}
|
14
14
|
});
|
15
15
|
|
16
|
-
/**
|
17
|
-
* @name list_item_with_task
|
18
|
-
* @description this node allows task-list to be nested inside list-item
|
19
|
-
*/
|
20
|
-
export const listItemWithTask = listItem;
|
21
|
-
|
22
16
|
/**
|
23
17
|
* @name list_item_with_decision_stage0
|
24
18
|
* @description this node allows decisions to be nested inside list-item
|
@@ -30,16 +24,4 @@ export const listItemWithDecisionStage0 = listItemWithNestedDecisionStage0Factor
|
|
30
24
|
toDOM() {
|
31
25
|
return ['li', 0];
|
32
26
|
}
|
33
|
-
});
|
34
|
-
/**
|
35
|
-
* @name list_item_without_non_bodied_macros
|
36
|
-
* @description this node does not allow extension inside list-item
|
37
|
-
*/
|
38
|
-
export const listItemWithoutNonBodiedMacros = listItemWithoutNonBodiedMacrosFactory({
|
39
|
-
parseDOM: [{
|
40
|
-
tag: 'li'
|
41
|
-
}],
|
42
|
-
toDOM() {
|
43
|
-
return ['li', 0];
|
44
|
-
}
|
45
27
|
});
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { nestedExpand as nestedExpandFactory
|
1
|
+
import { nestedExpand as nestedExpandFactory } from '../../next-schema/generated/nodeTypes';
|
2
2
|
|
3
3
|
/**
|
4
4
|
* @name nestedExpand_content
|
@@ -45,39 +45,9 @@ const nestedExpandFactoryOptions = {
|
|
45
45
|
return ['div', attrs, 0];
|
46
46
|
}
|
47
47
|
};
|
48
|
-
const nestedExpandWithoutNonBodiedMacrosFactoryOptions = {
|
49
|
-
parseDOM: [{
|
50
|
-
context: 'nestedExpand//',
|
51
|
-
tag: '[data-node-type="nestedExpand"]',
|
52
|
-
getAttrs: getExpandAttrs
|
53
|
-
}, {
|
54
|
-
tag: '[data-node-type="nestedExpand"] button',
|
55
|
-
ignore: true
|
56
|
-
}, {
|
57
|
-
tag: '[data-node-type="expand"] button',
|
58
|
-
ignore: true
|
59
|
-
}, {
|
60
|
-
tag: 'div[data-node-type="nestedExpand"]',
|
61
|
-
getAttrs: getExpandAttrs
|
62
|
-
}],
|
63
|
-
toDOM(node) {
|
64
|
-
const attrs = {
|
65
|
-
'data-node-type': 'nestedExpand',
|
66
|
-
'data-title': node.attrs.title,
|
67
|
-
'data-expanded': node.attrs.__expanded
|
68
|
-
};
|
69
|
-
return ['div', attrs, 0];
|
70
|
-
}
|
71
|
-
};
|
72
48
|
|
73
49
|
/**
|
74
50
|
* @name nestedExpand
|
75
51
|
* @description an expand that can be nested (eg. inside table, layout).
|
76
52
|
*/
|
77
|
-
export const nestedExpand = nestedExpandFactory(nestedExpandFactoryOptions);
|
78
|
-
|
79
|
-
/**
|
80
|
-
* @name nestedExpandWithNonBodiedMacros
|
81
|
-
* @description an expand that can be nested (eg. inside table, layout).
|
82
|
-
*/
|
83
|
-
export const nestedExpandWithoutNonBodiedMacros = nestedExpandWithoutNonBodiedMacrosFactory(nestedExpandWithoutNonBodiedMacrosFactoryOptions);
|
53
|
+
export const nestedExpand = nestedExpandFactory(nestedExpandFactoryOptions);
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { panel as panelFactory
|
1
|
+
import { panel as panelFactory } from '../../next-schema/generated/nodeTypes';
|
2
2
|
export let PanelType = /*#__PURE__*/function (PanelType) {
|
3
3
|
PanelType["INFO"] = "info";
|
4
4
|
PanelType["NOTE"] = "note";
|
@@ -61,5 +61,4 @@ const createPanelNodeSpecOptions = allowCustomPanel => ({
|
|
61
61
|
* Specifically, it allows Media, action, code-block, rule and decision nodes in
|
62
62
|
* addition to content allowed inside panel
|
63
63
|
*/
|
64
|
-
export const extendedPanel = allowCustomPanel => panelFactory(createPanelNodeSpecOptions(allowCustomPanel));
|
65
|
-
export const panelWithoutNestedNonBodiedMacros = allowCustomPanel => panelWithoutNestedNonBodiedMacrosFactory(createPanelNodeSpecOptions(allowCustomPanel));
|
64
|
+
export const extendedPanel = allowCustomPanel => panelFactory(createPanelNodeSpecOptions(allowCustomPanel));
|
package/dist/esm/index.js
CHANGED
@@ -1,5 +1,5 @@
|
|
1
|
-
export { PanelType, AnnotationTypes, alignment, alignmentPositionMap, annotation, blockCard, blockquote,
|
2
|
-
colorPaletteExtended, confluenceInlineComment, confluenceJiraIssue, confluenceUnsupportedBlock, confluenceUnsupportedInline, copyPrivateMediaAttributes, createSchema, dataConsumer, dataConsumerToJSON, date, decisionItem, decisionList, decisionListSelector, doc, em, embedCard, emoji, expandWithNestedExpand, expandToJSON, extension, fragment, fragmentToJSON, hardBreak, heading, image, indentation, inlineCard, inlineExtension, inlineNodes, layoutColumn, layoutSection, link, linkToJSON, listItem,
|
1
|
+
export { PanelType, AnnotationTypes, alignment, alignmentPositionMap, annotation, blockCard, blockquote, extendedBlockquote, bodiedExtension, breakout, bulletList, bulletListSelector, caption, code, codeBlock, codeBlockToJSON, colorPalette, /** @deprecated [ED-15849] The extended palette is now rolled into the main one. Use `colorPalette` instead. */
|
2
|
+
colorPaletteExtended, confluenceInlineComment, confluenceJiraIssue, confluenceUnsupportedBlock, confluenceUnsupportedInline, copyPrivateMediaAttributes, createSchema, dataConsumer, dataConsumerToJSON, date, decisionItem, decisionList, decisionListSelector, doc, em, embedCard, emoji, expandWithNestedExpand, expandToJSON, extension, fragment, fragmentToJSON, hardBreak, heading, image, indentation, inlineCard, inlineExtension, inlineNodes, layoutColumn, layoutSection, link, linkToJSON, listItem, listItemWithDecisionStage0, media, mediaGroup, mediaSingle, mediaSingleWithCaption, mediaSingleWithWidthType, mediaSingleFull, mediaSingleSpec, mediaInline, mediaSingleToJSON, mediaToJSON, mention, mentionToJSON, nestedExpand, orderedList, orderedListSelector, orderedListWithOrder, extendedPanel, paragraph, placeholder, rule, sanitizeNodes, getCellAttrs, getCellDomAttrs, status, strike, strong, subsup, table, tableStage0, tableWithCustomWidth, tableBackgroundBorderColor, tableBackgroundColorNames, tableBackgroundColorPalette, tableCell, tableCellContentDomSelector, tableCellContentWrapperSelector, tableCellSelector, tableHeader, tableHeaderSelector, tablePrefixSelector, tableRow, tableToJSON, taskItem, taskList, taskListSelector, text, textColor, toJSONTableCell, toJSONTableHeader, typeAheadQuery, underline, unknownBlock, unsupportedBlock, unsupportedInline, unsupportedNodeTypesForMediaCards, buildAnnotationMarkDataAttributes, AnnotationMarkStates, unsupportedMark, unsupportedNodeAttribute, border, borderColorPalette, extensionFrame, multiBodiedExtension, backgroundColor, backgroundColorPalette, tableWithNestedTable, tableRowWithNestedTable, tableCellWithNestedTable, tableHeaderWithNestedTable } from './schema';
|
3
3
|
export { B100, B400, B50, B500, B75, G200, G300, G400, G50, G500, G75, N0, N20, N200, N30, N300, N40, N50, N500, N60, N80, N800, N90, P100, P300, P400, P50, P500, P75, R100, R300, R400, R50, R500, R75, T100, T300, T50, T500, T75, Y200, Y400, Y50, Y500, Y75, acNameToEmoji, acShortcutToEmoji, emojiIdToAcName, generateUuid, getEmojiAcName, getLinkMatch, hexToRgb, hexToRgba, isHex, isRgb, isSafeUrl, linkify, linkifyMatch, normalizeHexColor, normalizeUrl, rgbToHex, uuid, getDarkModeLCHColor } from './utils';
|
4
4
|
|
5
5
|
// ADF createPMSpecFactory
|
@@ -41,20 +41,6 @@ export var blockquoteLegacy = createPMNodeSpecFactory({
|
|
41
41
|
selectable: true,
|
42
42
|
defining: true
|
43
43
|
});
|
44
|
-
export var blockquoteWithoutNestedCodeblockOrMedia = createPMNodeSpecFactory({
|
45
|
-
content: '(paragraph | orderedList | bulletList | unsupportedBlock)+',
|
46
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
47
|
-
group: 'block',
|
48
|
-
selectable: true,
|
49
|
-
defining: true
|
50
|
-
});
|
51
|
-
export var blockquoteWithoutNonBodiedMacros = createPMNodeSpecFactory({
|
52
|
-
content: '(paragraph | orderedList | bulletList | unsupportedBlock | codeBlock | mediaSingle | mediaGroup)+',
|
53
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
54
|
-
group: 'block',
|
55
|
-
selectable: true,
|
56
|
-
defining: true
|
57
|
-
});
|
58
44
|
export var bodiedExtension = createPMNodeSpecFactory({
|
59
45
|
content: '(paragraph | panel | blockquote | orderedList | bulletList | rule | heading | codeBlock | mediaGroup | mediaSingle | decisionList | taskList | table | blockCard | embedCard | extension | unsupportedBlock)+',
|
60
46
|
marks: 'dataConsumer fragment unsupportedMark unsupportedNodeAttribute',
|
@@ -577,12 +563,6 @@ export var listItemWithNestedDecisionStage0 = createPMNodeSpecFactory({
|
|
577
563
|
selectable: false,
|
578
564
|
defining: true
|
579
565
|
});
|
580
|
-
export var listItemWithoutNonBodiedMacros = createPMNodeSpecFactory({
|
581
|
-
content: '(paragraph | mediaSingle | codeBlock | unsupportedBlock) (paragraph | bulletList | orderedList | taskList | mediaSingle | codeBlock | unsupportedBlock)*',
|
582
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
583
|
-
selectable: false,
|
584
|
-
defining: true
|
585
|
-
});
|
586
566
|
export var media = createPMNodeSpecFactory({
|
587
567
|
attrs: {
|
588
568
|
type: {
|
@@ -855,20 +835,6 @@ export var nestedExpandWithNoMarks = createPMNodeSpecFactory({
|
|
855
835
|
selectable: true,
|
856
836
|
isolating: true
|
857
837
|
});
|
858
|
-
export var nestedExpandWithoutNonBodiedMacros = createPMNodeSpecFactory({
|
859
|
-
content: '(paragraph | heading | mediaSingle | mediaGroup | codeBlock | bulletList | orderedList | taskList | decisionList | rule | panel | blockquote | unsupportedBlock)+',
|
860
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
861
|
-
attrs: {
|
862
|
-
title: {
|
863
|
-
default: ''
|
864
|
-
},
|
865
|
-
__expanded: {
|
866
|
-
default: true
|
867
|
-
}
|
868
|
-
},
|
869
|
-
selectable: true,
|
870
|
-
isolating: true
|
871
|
-
});
|
872
838
|
export var orderedList = createPMNodeSpecFactory({
|
873
839
|
content: 'listItem+',
|
874
840
|
marks: 'unsupportedMark unsupportedNodeAttribute',
|
@@ -903,29 +869,6 @@ export var panel = createPMNodeSpecFactory({
|
|
903
869
|
},
|
904
870
|
selectable: true
|
905
871
|
});
|
906
|
-
export var panelWithoutNestedNonBodiedMacros = createPMNodeSpecFactory({
|
907
|
-
content: '(paragraph | heading | bulletList | orderedList | blockCard | mediaGroup | mediaSingle | codeBlock | taskList | rule | decisionList | unsupportedBlock)+',
|
908
|
-
marks: 'unsupportedMark unsupportedNodeAttribute',
|
909
|
-
group: 'block',
|
910
|
-
attrs: {
|
911
|
-
panelType: {
|
912
|
-
default: 'info'
|
913
|
-
},
|
914
|
-
panelIcon: {
|
915
|
-
default: null
|
916
|
-
},
|
917
|
-
panelIconId: {
|
918
|
-
default: null
|
919
|
-
},
|
920
|
-
panelIconText: {
|
921
|
-
default: null
|
922
|
-
},
|
923
|
-
panelColor: {
|
924
|
-
default: null
|
925
|
-
}
|
926
|
-
},
|
927
|
-
selectable: true
|
928
|
-
});
|
929
872
|
export var paragraph = createPMNodeSpecFactory({
|
930
873
|
content: 'inline*',
|
931
874
|
marks: 'link em strong strike subsup underline textColor annotation backgroundColor typeAheadQuery confluenceInlineComment unsupportedNodeAttribute unsupportedMark code dataConsumer fragment border',
|
@@ -30,7 +30,7 @@ import { unsupportedBlock } from '../nodes/unsupportedBlock';
|
|
30
30
|
* - no base mediaSingle
|
31
31
|
* - no base heading
|
32
32
|
*/
|
33
|
-
export var blockContentGroup = adfNodeGroup('block_content', [blockCard, paragraph.use('with_no_marks'), paragraph.use('with_alignment'), paragraph.use('with_indentation'), mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, taskList, bulletList, orderedList, heading.use('with_no_marks'), heading.use('with_alignment'), heading.use('with_indentation'), mediaGroup, decisionList, rule, panel,
|
33
|
+
export var blockContentGroup = adfNodeGroup('block_content', [blockCard, paragraph.use('with_no_marks'), paragraph.use('with_alignment'), paragraph.use('with_indentation'), mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, taskList, bulletList, orderedList, heading.use('with_no_marks'), heading.use('with_alignment'), heading.use('with_indentation'), mediaGroup, decisionList, rule, panel, blockquote, extension.use('with_marks'), embedCard, table,
|
34
34
|
// @ts-expect-error - types don't deal well with circular references for the variant
|
35
35
|
table.use('with_nested_table'), expand, bodiedExtension.use('with_marks'), confluenceUnsupportedBlock, unsupportedBlock], {
|
36
36
|
ignore: ['pm-spec']
|
@@ -18,7 +18,7 @@ import { rule } from '../nodes/rule';
|
|
18
18
|
import { table } from '../nodes/tableNodes';
|
19
19
|
import { taskList } from '../nodes/task';
|
20
20
|
import { unsupportedBlock } from '../nodes/unsupportedBlock';
|
21
|
-
export var blockGroup = adfNodeGroup('block', [blockCard, codeBlock, mediaSingle, mediaSingle.use('caption'), mediaSingle.use('full'), mediaSingle.use('width_type'), paragraph, paragraph.use('with_alignment'), paragraph.use('with_indentation'), paragraph.use('with_no_marks'), taskList, orderedList, bulletList, blockquote, blockquote.use('legacy'),
|
21
|
+
export var blockGroup = adfNodeGroup('block', [blockCard, codeBlock, mediaSingle, mediaSingle.use('caption'), mediaSingle.use('full'), mediaSingle.use('width_type'), paragraph, paragraph.use('with_alignment'), paragraph.use('with_indentation'), paragraph.use('with_no_marks'), taskList, orderedList, bulletList, blockquote, blockquote.use('legacy'), decisionList, embedCard, extension, extension.use('with_marks'), heading, heading.use('with_indentation'), heading.use('with_no_marks'), heading.use('with_alignment'), mediaGroup, rule, panel, table,
|
22
22
|
// @ts-expect-error - types don't deal well with circular references for the variant
|
23
23
|
table.use('with_nested_table'), bodiedExtension, bodiedExtension.use('with_marks'), expand, confluenceUnsupportedBlock, unsupportedBlock], {
|
24
24
|
// @DSLCompatibilityException
|
@@ -15,7 +15,7 @@ import { paragraph } from '../nodes/paragraph';
|
|
15
15
|
import { rule } from '../nodes/rule';
|
16
16
|
import { taskList } from '../nodes/task';
|
17
17
|
import { unsupportedBlock } from '../nodes/unsupportedBlock';
|
18
|
-
export var tableCellContentNodes = [paragraph.use('with_no_marks'), paragraph.use('with_alignment'), panel, blockquote, orderedList, bulletList, rule, heading.use('with_no_marks'), heading.use('with_alignment'), heading.use('with_indentation'), codeBlock, mediaSingle.use('caption'), mediaSingle.use('full'), mediaGroup, decisionList, taskList, blockCard, embedCard, extension.use('with_marks'), nestedExpand.use('content'), nestedExpand.use('with_no_marks')
|
18
|
+
export var tableCellContentNodes = [paragraph.use('with_no_marks'), paragraph.use('with_alignment'), panel, blockquote, orderedList, bulletList, rule, heading.use('with_no_marks'), heading.use('with_alignment'), heading.use('with_indentation'), codeBlock, mediaSingle.use('caption'), mediaSingle.use('full'), mediaGroup, decisionList, taskList, blockCard, embedCard, extension.use('with_marks'), nestedExpand.use('content'), nestedExpand.use('with_no_marks')];
|
19
19
|
|
20
20
|
// This is not an actual group, but a collection of nodes
|
21
21
|
// @DSLCompatibilityException JSON Schema and PM Spec are not in sync. We need to fix it
|
@@ -17,12 +17,4 @@ export var blockquote = adfNode('blockquote').define({
|
|
17
17
|
}).variant('legacy', {
|
18
18
|
ignore: ['json-schema', 'validator-spec'],
|
19
19
|
content: [$onePlus($or(paragraph, unsupportedBlock))]
|
20
|
-
}).variant('without_non_bodied_macros', {
|
21
|
-
content: [$onePlus($or(paragraph.use('with_no_marks'), orderedList, bulletList, unsupportedBlock, codeBlock, mediaSingle.use('caption'), mediaSingle.use('full'), mediaGroup))],
|
22
|
-
ignore: ['json-schema', 'validator-spec']
|
23
|
-
})
|
24
|
-
// TODO: Clean up this variant
|
25
|
-
.variant('without_nested_codeblock_or_media', {
|
26
|
-
content: [$onePlus($or(paragraph.use('with_no_marks'), orderedList, bulletList, unsupportedBlock))],
|
27
|
-
ignore: ['json-schema', 'validator-spec']
|
28
20
|
});
|
@@ -20,7 +20,7 @@ export var expand = adfNode('expand').define({
|
|
20
20
|
optional: true
|
21
21
|
}
|
22
22
|
},
|
23
|
-
content: [$onePlus($or(nonNestableBlockContentGroup, nestedExpand.use('with_no_marks')
|
23
|
+
content: [$onePlus($or(nonNestableBlockContentGroup, nestedExpand.use('with_no_marks')))]
|
24
24
|
}).variant('root_only', {
|
25
25
|
marks: [breakout, unsupportedMark, unsupportedNodeAttribute],
|
26
26
|
noMarks: false,
|
@@ -20,10 +20,6 @@ var listItem = adfNode('listItem').define({
|
|
20
20
|
content: [$or(paragraph.use('with_no_marks'), mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, unsupportedBlock, decisionList, extension.use('with_marks')), $zeroPlus($or(paragraph.use('with_no_marks'), bulletList, orderedList, taskList, mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, unsupportedBlock, decisionList, extension.use('with_marks')))],
|
21
21
|
noExtend: true,
|
22
22
|
stage0: true
|
23
|
-
}).variant('without_non_bodied_macros', {
|
24
|
-
content: [$or(paragraph.use('with_no_marks'), mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, unsupportedBlock), $zeroPlus($or(paragraph.use('with_no_marks'), bulletList, orderedList, taskList, mediaSingle.use('caption'), mediaSingle.use('full'), codeBlock, unsupportedBlock))],
|
25
|
-
noExtend: true,
|
26
|
-
ignore: ['json-schema', 'validator-spec']
|
27
23
|
});
|
28
24
|
orderedList.define({
|
29
25
|
selectable: false,
|
@@ -36,10 +32,10 @@ orderedList.define({
|
|
36
32
|
optional: true
|
37
33
|
}
|
38
34
|
},
|
39
|
-
content: [$onePlus($or(listItem, listItem.use('with_nested_decision')
|
35
|
+
content: [$onePlus($or(listItem, listItem.use('with_nested_decision')))]
|
40
36
|
});
|
41
37
|
bulletList.define({
|
42
38
|
selectable: false,
|
43
39
|
marks: [unsupportedMark, unsupportedNodeAttribute],
|
44
|
-
content: [$onePlus($or(listItem, listItem.use('with_nested_decision')
|
40
|
+
content: [$onePlus($or(listItem, listItem.use('with_nested_decision')))]
|
45
41
|
});
|
@@ -54,10 +54,4 @@ export var nestedExpand = adfNode('nestedExpand').define({
|
|
54
54
|
marks: [],
|
55
55
|
content: [],
|
56
56
|
noMarks: true
|
57
|
-
}).variant('without_non_bodied_macros', {
|
58
|
-
marks: [],
|
59
|
-
content: [$onePlus($or.apply(void 0, nestedExpandContent))],
|
60
|
-
noMarks: true,
|
61
|
-
noExtend: true,
|
62
|
-
ignore: ['json-schema', 'validator-spec']
|
63
57
|
});
|
@@ -45,8 +45,4 @@ export var panel = adfNode('panel').define({
|
|
45
45
|
}
|
46
46
|
},
|
47
47
|
content: [$onePlus($or.apply(void 0, panelContent.concat([extension.use('with_marks')])))]
|
48
|
-
}).variant('without_nested_non_bodied_macros', {
|
49
|
-
content: [$onePlus($or.apply(void 0, panelContent))],
|
50
|
-
noExtend: true,
|
51
|
-
ignore: ['json-schema', 'validator-spec']
|
52
48
|
});
|
@@ -2,7 +2,7 @@ import { Schema } from '@atlaskit/editor-prosemirror/model';
|
|
2
2
|
import { COLOR, FONT_STYLE, SEARCH_QUERY, LINK } from './groups';
|
3
3
|
import { sanitizeNodes } from './sanitizeNodes';
|
4
4
|
import { link, em, strong, textColor, strike, subsup, underline, code, typeAheadQuery, confluenceInlineComment, breakout, alignment, indentation, annotation, unsupportedMark, unsupportedNodeAttribute, dataConsumer, fragment, border, backgroundColor } from './marks';
|
5
|
-
import { confluenceJiraIssue, confluenceUnsupportedBlock, confluenceUnsupportedInline, doc, paragraph, text, bulletList, orderedListWithOrder,
|
5
|
+
import { confluenceJiraIssue, confluenceUnsupportedBlock, confluenceUnsupportedInline, doc, paragraph, text, bulletList, orderedListWithOrder, listItem, heading, codeBlock, extendedPanel, rule, image, mention, media, mediaInline, mediaSingleFull, mediaGroup, hardBreak, emoji, table, tableCell, tableHeader, tableRow, decisionList, decisionItem, taskList, taskItem, unknownBlock, extension, inlineExtension, bodiedExtension, multiBodiedExtension, extensionFrame, date, placeholder, layoutSection, layoutColumn, inlineCard, blockCard, unsupportedBlock, unsupportedInline, status, expandWithNestedExpand, nestedExpand, embedCard, caption, extendedBlockquote } from './nodes';
|
6
6
|
function addItems(builtInItems, config) {
|
7
7
|
var customSpecs = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
8
8
|
if (!config) {
|
@@ -69,7 +69,7 @@ var nodesInOrder = [{
|
|
69
69
|
spec: orderedListWithOrder
|
70
70
|
}, {
|
71
71
|
name: 'listItem',
|
72
|
-
spec:
|
72
|
+
spec: listItem
|
73
73
|
}, {
|
74
74
|
name: 'heading',
|
75
75
|
spec: heading
|