@atlaskit/adf-schema 36.15.0 → 36.17.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 +12 -0
- package/dist/cjs/next-schema/full-schema.adf.js +1 -5
- package/dist/cjs/next-schema/generated/markTypes.js +19 -19
- package/dist/cjs/next-schema/generated/nodeTypes.js +422 -316
- package/dist/cjs/next-schema/groups/blockGroup.js +1 -5
- package/dist/cjs/next-schema/groups/blockRootOnlyGroup.js +2 -1
- package/dist/cjs/next-schema/groups/inlineGroup.js +3 -1
- package/dist/cjs/next-schema/nodes/blockCard.js +1 -0
- package/dist/cjs/next-schema/nodes/bodiedExtension.js +1 -0
- package/dist/cjs/next-schema/nodes/codeBlock.js +5 -0
- package/dist/cjs/next-schema/nodes/confluenceJiraIssue.js +38 -0
- package/dist/cjs/next-schema/nodes/decisionItem.js +1 -2
- package/dist/cjs/next-schema/nodes/extension.js +1 -0
- package/dist/cjs/next-schema/nodes/extensionFrame.js +3 -1
- package/dist/cjs/next-schema/nodes/heading.js +1 -2
- package/dist/cjs/next-schema/nodes/image.js +28 -0
- package/dist/cjs/next-schema/nodes/inlineCard.js +1 -0
- package/dist/cjs/next-schema/nodes/inlineExtension.js +1 -0
- package/dist/cjs/next-schema/nodes/mediaGroup.js +2 -0
- package/dist/cjs/next-schema/nodes/mediaInline.js +0 -3
- package/dist/cjs/next-schema/nodes/mediaSingle.js +1 -1
- package/dist/cjs/next-schema/nodes/multiBodiedExtension.js +1 -0
- package/dist/cjs/next-schema/nodes/paragraph.js +1 -2
- package/dist/cjs/next-schema/nodes/status.js +1 -0
- package/dist/cjs/next-schema/nodes/table.js +1 -1
- package/dist/cjs/next-schema/nodes/task.js +1 -2
- package/dist/cjs/schema/create-schema.js +21 -0
- package/dist/cjs/schema/nodes/multi-bodied-extension.js +0 -2
- package/dist/cjs/schema/nodes/paragraph.js +2 -2
- package/dist/es2019/next-schema/full-schema.adf.js +1 -5
- package/dist/es2019/next-schema/generated/markTypes.js +19 -19
- package/dist/es2019/next-schema/generated/nodeTypes.js +421 -315
- package/dist/es2019/next-schema/groups/blockGroup.js +1 -5
- package/dist/es2019/next-schema/groups/blockRootOnlyGroup.js +2 -1
- package/dist/es2019/next-schema/groups/inlineGroup.js +3 -1
- package/dist/es2019/next-schema/nodes/blockCard.js +1 -0
- package/dist/es2019/next-schema/nodes/bodiedExtension.js +1 -0
- package/dist/es2019/next-schema/nodes/codeBlock.js +5 -0
- package/dist/es2019/next-schema/nodes/confluenceJiraIssue.js +32 -0
- package/dist/es2019/next-schema/nodes/decisionItem.js +1 -2
- package/dist/es2019/next-schema/nodes/extension.js +1 -0
- package/dist/es2019/next-schema/nodes/extensionFrame.js +3 -1
- package/dist/es2019/next-schema/nodes/heading.js +1 -2
- package/dist/es2019/next-schema/nodes/image.js +22 -0
- package/dist/es2019/next-schema/nodes/inlineCard.js +1 -0
- package/dist/es2019/next-schema/nodes/inlineExtension.js +1 -0
- package/dist/es2019/next-schema/nodes/mediaGroup.js +2 -0
- package/dist/es2019/next-schema/nodes/mediaInline.js +0 -3
- package/dist/es2019/next-schema/nodes/mediaSingle.js +1 -1
- package/dist/es2019/next-schema/nodes/multiBodiedExtension.js +1 -0
- package/dist/es2019/next-schema/nodes/paragraph.js +1 -2
- package/dist/es2019/next-schema/nodes/status.js +1 -0
- package/dist/es2019/next-schema/nodes/table.js +1 -1
- package/dist/es2019/next-schema/nodes/task.js +1 -2
- package/dist/es2019/schema/create-schema.js +22 -0
- package/dist/es2019/schema/nodes/multi-bodied-extension.js +0 -2
- package/dist/es2019/schema/nodes/paragraph.js +2 -2
- package/dist/esm/next-schema/full-schema.adf.js +1 -5
- package/dist/esm/next-schema/generated/markTypes.js +19 -19
- package/dist/esm/next-schema/generated/nodeTypes.js +421 -315
- package/dist/esm/next-schema/groups/blockGroup.js +1 -5
- package/dist/esm/next-schema/groups/blockRootOnlyGroup.js +2 -1
- package/dist/esm/next-schema/groups/inlineGroup.js +3 -1
- package/dist/esm/next-schema/nodes/blockCard.js +1 -0
- package/dist/esm/next-schema/nodes/bodiedExtension.js +1 -0
- package/dist/esm/next-schema/nodes/codeBlock.js +5 -0
- package/dist/esm/next-schema/nodes/confluenceJiraIssue.js +32 -0
- package/dist/esm/next-schema/nodes/decisionItem.js +1 -2
- package/dist/esm/next-schema/nodes/extension.js +1 -0
- package/dist/esm/next-schema/nodes/extensionFrame.js +3 -1
- package/dist/esm/next-schema/nodes/heading.js +1 -2
- package/dist/esm/next-schema/nodes/image.js +22 -0
- package/dist/esm/next-schema/nodes/inlineCard.js +1 -0
- package/dist/esm/next-schema/nodes/inlineExtension.js +1 -0
- package/dist/esm/next-schema/nodes/mediaGroup.js +2 -0
- package/dist/esm/next-schema/nodes/mediaInline.js +0 -3
- package/dist/esm/next-schema/nodes/mediaSingle.js +1 -1
- package/dist/esm/next-schema/nodes/multiBodiedExtension.js +1 -0
- package/dist/esm/next-schema/nodes/paragraph.js +1 -2
- package/dist/esm/next-schema/nodes/status.js +1 -0
- package/dist/esm/next-schema/nodes/table.js +1 -1
- package/dist/esm/next-schema/nodes/task.js +1 -2
- package/dist/esm/schema/create-schema.js +20 -0
- package/dist/esm/schema/nodes/multi-bodied-extension.js +0 -2
- package/dist/esm/schema/nodes/paragraph.js +2 -2
- package/dist/types/next-schema/generated/markTypes.d.ts +24 -24
- package/dist/types/next-schema/generated/nodeGroupTypes.d.ts +6 -4
- package/dist/types/next-schema/generated/nodeTypes.d.ts +342 -246
- package/dist/types/next-schema/nodes/confluenceJiraIssue.d.ts +22 -0
- package/dist/types/next-schema/nodes/image.d.ts +22 -0
- package/dist/types/schema/create-schema.d.ts +4 -0
- package/package.json +2 -2
- package/schema-generators/__tests__/unit/json-full-schema.unit.ts +303 -20
- package/schema-generators/__tests__/unit/validate-pm-schema.unit.ts +21 -30
@@ -1,26 +1,4 @@
|
|
1
1
|
import { createPMNodeSpecFactory } from '@atlaskit/adf-schema-generator';
|
2
|
-
export const blockCard = createPMNodeSpecFactory({
|
3
|
-
group: 'block',
|
4
|
-
attrs: {
|
5
|
-
url: {
|
6
|
-
default: null
|
7
|
-
},
|
8
|
-
datasource: {
|
9
|
-
default: null
|
10
|
-
},
|
11
|
-
width: {
|
12
|
-
default: null
|
13
|
-
},
|
14
|
-
layout: {
|
15
|
-
default: null
|
16
|
-
},
|
17
|
-
data: {
|
18
|
-
default: null
|
19
|
-
}
|
20
|
-
},
|
21
|
-
selectable: true,
|
22
|
-
draggable: true
|
23
|
-
});
|
24
2
|
export const text = createPMNodeSpecFactory({
|
25
3
|
group: 'inline'
|
26
4
|
});
|
@@ -36,102 +14,91 @@ export const unsupportedInline = createPMNodeSpecFactory({
|
|
36
14
|
});
|
37
15
|
export const codeBlockWithNoMarks = createPMNodeSpecFactory({
|
38
16
|
content: '(text | unsupportedInline)*',
|
17
|
+
marks: 'unsupportedMark unsupportedNodeAttribute',
|
39
18
|
group: 'block',
|
40
19
|
attrs: {
|
41
20
|
language: {
|
42
21
|
default: null
|
22
|
+
},
|
23
|
+
uniqueId: {
|
24
|
+
default: null
|
43
25
|
}
|
44
26
|
},
|
45
27
|
code: true,
|
46
28
|
defining: true
|
47
29
|
});
|
48
|
-
export const
|
30
|
+
export const blockCard = createPMNodeSpecFactory({
|
31
|
+
group: 'block',
|
49
32
|
attrs: {
|
50
|
-
|
51
|
-
default: 'file'
|
52
|
-
},
|
53
|
-
id: {
|
54
|
-
default: ''
|
55
|
-
},
|
56
|
-
alt: {
|
57
|
-
default: ''
|
58
|
-
},
|
59
|
-
collection: {
|
60
|
-
default: ''
|
61
|
-
},
|
62
|
-
height: {
|
33
|
+
url: {
|
63
34
|
default: null
|
64
35
|
},
|
65
|
-
|
36
|
+
datasource: {
|
66
37
|
default: null
|
67
38
|
},
|
68
39
|
width: {
|
69
40
|
default: null
|
70
41
|
},
|
71
|
-
|
72
|
-
default: null
|
73
|
-
},
|
74
|
-
__displayType: {
|
75
|
-
default: null
|
76
|
-
},
|
77
|
-
__external: {
|
78
|
-
default: false
|
79
|
-
},
|
80
|
-
__fileMimeType: {
|
81
|
-
default: null
|
82
|
-
},
|
83
|
-
__fileName: {
|
84
|
-
default: null
|
85
|
-
},
|
86
|
-
__fileSize: {
|
87
|
-
default: null
|
88
|
-
},
|
89
|
-
__mediaTraceId: {
|
42
|
+
layout: {
|
90
43
|
default: null
|
91
44
|
},
|
92
|
-
|
45
|
+
data: {
|
93
46
|
default: null
|
94
47
|
}
|
95
48
|
},
|
96
|
-
selectable: true
|
49
|
+
selectable: true,
|
50
|
+
draggable: true
|
97
51
|
});
|
98
|
-
export const
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
52
|
+
export const textFormatted = createPMNodeSpecFactory({
|
53
|
+
group: 'inline'
|
54
|
+
});
|
55
|
+
export const textCodeInline = createPMNodeSpecFactory({
|
56
|
+
group: 'inline'
|
57
|
+
});
|
58
|
+
export const date = createPMNodeSpecFactory({
|
59
|
+
group: 'inline',
|
60
|
+
inline: true,
|
103
61
|
attrs: {
|
104
|
-
|
105
|
-
default:
|
106
|
-
},
|
107
|
-
layout: {
|
108
|
-
default: 'center'
|
109
|
-
},
|
110
|
-
widthType: {
|
111
|
-
default: 'pixel'
|
62
|
+
timestamp: {
|
63
|
+
default: ''
|
112
64
|
}
|
113
65
|
},
|
114
66
|
selectable: true
|
115
67
|
});
|
116
|
-
export const
|
117
|
-
group: '
|
118
|
-
|
68
|
+
export const emoji = createPMNodeSpecFactory({
|
69
|
+
group: 'inline',
|
70
|
+
inline: true,
|
119
71
|
attrs: {
|
120
|
-
|
121
|
-
default:
|
72
|
+
shortName: {
|
73
|
+
default: ''
|
74
|
+
},
|
75
|
+
id: {
|
76
|
+
default: ''
|
77
|
+
},
|
78
|
+
text: {
|
79
|
+
default: ''
|
122
80
|
}
|
123
81
|
},
|
124
82
|
selectable: true
|
125
83
|
});
|
126
84
|
export const hardBreak = createPMNodeSpecFactory({
|
85
|
+
group: 'inline',
|
86
|
+
inline: true,
|
87
|
+
selectable: false
|
88
|
+
});
|
89
|
+
export const inlineCard = createPMNodeSpecFactory({
|
127
90
|
group: 'inline',
|
128
91
|
inline: true,
|
129
92
|
attrs: {
|
130
|
-
|
131
|
-
default:
|
93
|
+
url: {
|
94
|
+
default: null
|
95
|
+
},
|
96
|
+
data: {
|
97
|
+
default: null
|
132
98
|
}
|
133
99
|
},
|
134
|
-
selectable:
|
100
|
+
selectable: true,
|
101
|
+
draggable: true
|
135
102
|
});
|
136
103
|
export const mention = createPMNodeSpecFactory({
|
137
104
|
group: 'inline',
|
@@ -155,32 +122,6 @@ export const mention = createPMNodeSpecFactory({
|
|
155
122
|
},
|
156
123
|
selectable: true
|
157
124
|
});
|
158
|
-
export const emoji = createPMNodeSpecFactory({
|
159
|
-
group: 'inline',
|
160
|
-
inline: true,
|
161
|
-
attrs: {
|
162
|
-
shortName: {
|
163
|
-
default: ''
|
164
|
-
},
|
165
|
-
id: {
|
166
|
-
default: ''
|
167
|
-
},
|
168
|
-
text: {
|
169
|
-
default: ''
|
170
|
-
}
|
171
|
-
},
|
172
|
-
selectable: true
|
173
|
-
});
|
174
|
-
export const date = createPMNodeSpecFactory({
|
175
|
-
group: 'inline',
|
176
|
-
inline: true,
|
177
|
-
attrs: {
|
178
|
-
timestamp: {
|
179
|
-
default: ''
|
180
|
-
}
|
181
|
-
},
|
182
|
-
selectable: true
|
183
|
-
});
|
184
125
|
export const placeholder = createPMNodeSpecFactory({
|
185
126
|
marks: '',
|
186
127
|
group: 'inline',
|
@@ -192,22 +133,9 @@ export const placeholder = createPMNodeSpecFactory({
|
|
192
133
|
},
|
193
134
|
selectable: false
|
194
135
|
});
|
195
|
-
export const inlineCard = createPMNodeSpecFactory({
|
196
|
-
group: 'inline',
|
197
|
-
inline: true,
|
198
|
-
attrs: {
|
199
|
-
url: {
|
200
|
-
default: null
|
201
|
-
},
|
202
|
-
data: {
|
203
|
-
default: null
|
204
|
-
}
|
205
|
-
},
|
206
|
-
selectable: true,
|
207
|
-
draggable: true
|
208
|
-
});
|
209
136
|
export const status = createPMNodeSpecFactory({
|
210
137
|
group: 'inline',
|
138
|
+
inline: true,
|
211
139
|
attrs: {
|
212
140
|
text: {
|
213
141
|
default: ''
|
@@ -224,54 +152,6 @@ export const status = createPMNodeSpecFactory({
|
|
224
152
|
},
|
225
153
|
selectable: true
|
226
154
|
});
|
227
|
-
export const textFormatted = createPMNodeSpecFactory({
|
228
|
-
group: 'inline'
|
229
|
-
});
|
230
|
-
export const textCodeInline = createPMNodeSpecFactory({
|
231
|
-
group: 'inline'
|
232
|
-
});
|
233
|
-
export const caption = createPMNodeSpecFactory({
|
234
|
-
content: '(hardBreak | mention | emoji | date | placeholder | inlineCard | status | text | unsupportedInline)*',
|
235
|
-
marks: '_',
|
236
|
-
selectable: false,
|
237
|
-
isolating: true
|
238
|
-
});
|
239
|
-
export const mediaSingleCaption = createPMNodeSpecFactory({
|
240
|
-
content: '(media | unsupportedBlock) (caption | unsupportedBlock)',
|
241
|
-
marks: 'link annotation border unsupportedNodeAttribute unsupportedMark',
|
242
|
-
group: 'block',
|
243
|
-
atom: false,
|
244
|
-
attrs: {
|
245
|
-
width: {
|
246
|
-
default: null
|
247
|
-
},
|
248
|
-
layout: {
|
249
|
-
default: 'center'
|
250
|
-
},
|
251
|
-
widthType: {
|
252
|
-
default: 'pixel'
|
253
|
-
}
|
254
|
-
},
|
255
|
-
selectable: true
|
256
|
-
});
|
257
|
-
export const mediaSingleFull = createPMNodeSpecFactory({
|
258
|
-
content: 'media',
|
259
|
-
marks: 'link annotation border unsupportedNodeAttribute unsupportedMark',
|
260
|
-
group: 'block',
|
261
|
-
atom: false,
|
262
|
-
attrs: {
|
263
|
-
width: {
|
264
|
-
default: null
|
265
|
-
},
|
266
|
-
layout: {
|
267
|
-
default: 'center'
|
268
|
-
},
|
269
|
-
widthType: {
|
270
|
-
default: 'pixel'
|
271
|
-
}
|
272
|
-
},
|
273
|
-
selectable: true
|
274
|
-
});
|
275
155
|
export const inlineExtensionWithMarks = createPMNodeSpecFactory({
|
276
156
|
group: 'inline',
|
277
157
|
inline: true,
|
@@ -298,7 +178,6 @@ export const mediaInline = createPMNodeSpecFactory({
|
|
298
178
|
group: 'inline',
|
299
179
|
inline: true,
|
300
180
|
attrs: {
|
301
|
-
data: {},
|
302
181
|
type: {
|
303
182
|
default: 'file'
|
304
183
|
},
|
@@ -347,179 +226,212 @@ export const mediaInline = createPMNodeSpecFactory({
|
|
347
226
|
},
|
348
227
|
selectable: true
|
349
228
|
});
|
350
|
-
export const
|
229
|
+
export const image = createPMNodeSpecFactory({
|
351
230
|
group: 'inline',
|
352
231
|
inline: true,
|
353
|
-
atom: true,
|
354
232
|
attrs: {
|
355
|
-
|
233
|
+
src: {
|
234
|
+
default: ''
|
235
|
+
},
|
236
|
+
alt: {
|
237
|
+
default: ''
|
238
|
+
},
|
239
|
+
title: {
|
356
240
|
default: null
|
357
241
|
}
|
358
|
-
}
|
359
|
-
|
360
|
-
export const paragraph = createPMNodeSpecFactory({
|
361
|
-
content: '(inline | unsupportedInline)*',
|
362
|
-
marks: 'link em strong strike subsup underline textColor annotation backgroundColor unsupportedNodeAttribute unsupportedMark code dataConsumer fragment border',
|
363
|
-
group: 'block',
|
364
|
-
selectable: false
|
365
|
-
});
|
366
|
-
export const paragraphWithAlignment = createPMNodeSpecFactory({
|
367
|
-
content: '(inline | unsupportedInline)*',
|
368
|
-
marks: 'link em strong strike subsup underline textColor annotation backgroundColor unsupportedNodeAttribute unsupportedMark code dataConsumer fragment border',
|
369
|
-
group: 'block',
|
370
|
-
selectable: false
|
371
|
-
});
|
372
|
-
export const paragraphWithIndentation = createPMNodeSpecFactory({
|
373
|
-
content: '(inline | unsupportedInline)*',
|
374
|
-
marks: 'link em strong strike subsup underline textColor annotation backgroundColor unsupportedNodeAttribute unsupportedMark code dataConsumer fragment border',
|
375
|
-
group: 'block',
|
376
|
-
selectable: false
|
242
|
+
},
|
243
|
+
draggable: true
|
377
244
|
});
|
378
|
-
export const
|
379
|
-
|
380
|
-
|
245
|
+
export const confluenceJiraIssue = createPMNodeSpecFactory({
|
246
|
+
group: 'inline',
|
247
|
+
inline: true,
|
248
|
+
atom: true,
|
381
249
|
attrs: {
|
382
|
-
|
250
|
+
issueKey: {
|
383
251
|
default: ''
|
384
252
|
},
|
385
|
-
|
386
|
-
default:
|
253
|
+
macroId: {
|
254
|
+
default: null
|
255
|
+
},
|
256
|
+
schemaVersion: {
|
257
|
+
default: null
|
258
|
+
},
|
259
|
+
server: {
|
260
|
+
default: null
|
261
|
+
},
|
262
|
+
serverId: {
|
263
|
+
default: null
|
387
264
|
}
|
388
|
-
}
|
389
|
-
selectable: false,
|
390
|
-
defining: true
|
265
|
+
}
|
391
266
|
});
|
392
|
-
export const
|
393
|
-
|
394
|
-
|
395
|
-
|
267
|
+
export const confluenceUnsupportedInline = createPMNodeSpecFactory({
|
268
|
+
group: 'inline',
|
269
|
+
inline: true,
|
270
|
+
atom: true,
|
396
271
|
attrs: {
|
397
|
-
|
398
|
-
default:
|
272
|
+
cxhtml: {
|
273
|
+
default: null
|
399
274
|
}
|
400
|
-
}
|
401
|
-
selectable: false,
|
402
|
-
defining: true
|
275
|
+
}
|
403
276
|
});
|
404
277
|
export const paragraphWithNoMarks = createPMNodeSpecFactory({
|
405
|
-
content: '
|
278
|
+
content: 'inline*',
|
406
279
|
marks: 'link em strong strike subsup underline textColor annotation backgroundColor unsupportedNodeAttribute unsupportedMark code dataConsumer fragment border',
|
407
280
|
selectable: false
|
408
281
|
});
|
409
|
-
export const
|
410
|
-
content: 'listItem+',
|
411
|
-
marks: 'unsupportedNodeAttribute unsupportedMark',
|
412
|
-
group: 'block',
|
413
|
-
selectable: false
|
414
|
-
});
|
415
|
-
export const listItem = createPMNodeSpecFactory({
|
416
|
-
content: '(codeBlock | paragraph | mediaSingle | unsupportedBlock) (codeBlock | paragraph | mediaSingle | taskList | bulletList | orderedList | unsupportedBlock)*',
|
417
|
-
marks: 'unsupportedNodeAttribute unsupportedMark',
|
418
|
-
selectable: false,
|
419
|
-
defining: true
|
420
|
-
});
|
421
|
-
export const orderedList = createPMNodeSpecFactory({
|
422
|
-
content: 'listItem+',
|
423
|
-
marks: 'unsupportedNodeAttribute unsupportedMark',
|
424
|
-
group: 'block',
|
425
|
-
attrs: {
|
426
|
-
order: {
|
427
|
-
default: 1
|
428
|
-
}
|
429
|
-
},
|
430
|
-
selectable: false
|
431
|
-
});
|
432
|
-
export const blockquoteWithList = createPMNodeSpecFactory({
|
433
|
-
content: '(paragraph | orderedList | bulletList | unsupportedBlock)+',
|
434
|
-
marks: 'unsupportedNodeAttribute unsupportedMark',
|
435
|
-
group: 'block',
|
436
|
-
selectable: false,
|
437
|
-
defining: true
|
438
|
-
});
|
439
|
-
export const decisionItem = createPMNodeSpecFactory({
|
440
|
-
content: '(inline | unsupportedBlock)*',
|
441
|
-
marks: '_',
|
282
|
+
export const media = createPMNodeSpecFactory({
|
442
283
|
attrs: {
|
443
|
-
|
284
|
+
type: {
|
285
|
+
default: 'file'
|
286
|
+
},
|
287
|
+
id: {
|
444
288
|
default: ''
|
445
289
|
},
|
446
|
-
|
447
|
-
default: '
|
290
|
+
alt: {
|
291
|
+
default: ''
|
292
|
+
},
|
293
|
+
collection: {
|
294
|
+
default: ''
|
295
|
+
},
|
296
|
+
height: {
|
297
|
+
default: null
|
298
|
+
},
|
299
|
+
occurrenceKey: {
|
300
|
+
default: null
|
301
|
+
},
|
302
|
+
width: {
|
303
|
+
default: null
|
304
|
+
},
|
305
|
+
__contextId: {
|
306
|
+
default: null
|
307
|
+
},
|
308
|
+
__displayType: {
|
309
|
+
default: null
|
310
|
+
},
|
311
|
+
__external: {
|
312
|
+
default: false
|
313
|
+
},
|
314
|
+
__fileMimeType: {
|
315
|
+
default: null
|
316
|
+
},
|
317
|
+
__fileName: {
|
318
|
+
default: null
|
319
|
+
},
|
320
|
+
__fileSize: {
|
321
|
+
default: null
|
322
|
+
},
|
323
|
+
__mediaTraceId: {
|
324
|
+
default: null
|
325
|
+
},
|
326
|
+
url: {
|
327
|
+
default: null
|
448
328
|
}
|
449
329
|
},
|
450
|
-
|
330
|
+
selectable: true
|
451
331
|
});
|
452
|
-
export const
|
453
|
-
content: '(decisionItem | unsupportedBlock)+',
|
454
|
-
marks: 'unsupportedNodeAttribute unsupportedMark',
|
332
|
+
export const unsupportedBlock = createPMNodeSpecFactory({
|
455
333
|
group: 'block',
|
334
|
+
atom: true,
|
456
335
|
attrs: {
|
457
|
-
|
458
|
-
default:
|
336
|
+
originalValue: {
|
337
|
+
default: {}
|
459
338
|
}
|
460
339
|
},
|
340
|
+
selectable: true
|
341
|
+
});
|
342
|
+
export const caption = createPMNodeSpecFactory({
|
343
|
+
content: '(hardBreak | mention | emoji | date | placeholder | inlineCard | status | text | unsupportedInline)*',
|
344
|
+
marks: '_',
|
461
345
|
selectable: false,
|
462
|
-
|
346
|
+
isolating: true
|
463
347
|
});
|
464
|
-
export const
|
348
|
+
export const mediaSingleCaption = createPMNodeSpecFactory({
|
349
|
+
content: '(media | unsupportedBlock) (caption | unsupportedBlock)',
|
350
|
+
marks: 'link annotation border unsupportedNodeAttribute unsupportedMark',
|
465
351
|
group: 'block',
|
352
|
+
atom: false,
|
466
353
|
attrs: {
|
467
|
-
|
468
|
-
default:
|
354
|
+
width: {
|
355
|
+
default: null
|
469
356
|
},
|
470
357
|
layout: {
|
471
358
|
default: 'center'
|
472
359
|
},
|
473
|
-
|
474
|
-
default: 100
|
475
|
-
},
|
476
|
-
originalHeight: {
|
477
|
-
default: null
|
478
|
-
},
|
479
|
-
originalWidth: {
|
360
|
+
widthType: {
|
480
361
|
default: null
|
481
362
|
}
|
482
363
|
},
|
483
364
|
selectable: true
|
484
365
|
});
|
485
|
-
export const
|
366
|
+
export const mediaSingleFull = createPMNodeSpecFactory({
|
367
|
+
content: 'media',
|
368
|
+
marks: 'link annotation border unsupportedNodeAttribute unsupportedMark',
|
486
369
|
group: 'block',
|
487
|
-
atom:
|
370
|
+
atom: false,
|
488
371
|
attrs: {
|
489
|
-
|
490
|
-
default: ''
|
491
|
-
},
|
492
|
-
extensionType: {
|
493
|
-
default: ''
|
494
|
-
},
|
495
|
-
parameters: {
|
496
|
-
default: null
|
497
|
-
},
|
498
|
-
text: {
|
372
|
+
width: {
|
499
373
|
default: null
|
500
374
|
},
|
501
375
|
layout: {
|
502
|
-
default: '
|
376
|
+
default: 'center'
|
377
|
+
},
|
378
|
+
widthType: {
|
379
|
+
default: null
|
380
|
+
}
|
381
|
+
},
|
382
|
+
selectable: true
|
383
|
+
});
|
384
|
+
export const taskItem = createPMNodeSpecFactory({
|
385
|
+
content: 'inline*',
|
386
|
+
marks: '_',
|
387
|
+
attrs: {
|
388
|
+
localId: {
|
389
|
+
default: ''
|
503
390
|
},
|
391
|
+
state: {
|
392
|
+
default: 'TODO'
|
393
|
+
}
|
394
|
+
},
|
395
|
+
selectable: false,
|
396
|
+
defining: true
|
397
|
+
});
|
398
|
+
export const taskList = createPMNodeSpecFactory({
|
399
|
+
content: '(taskItem | unsupportedBlock)+ (taskItem | taskList | unsupportedBlock)*',
|
400
|
+
marks: 'unsupportedNodeAttribute unsupportedMark',
|
401
|
+
group: 'block',
|
402
|
+
attrs: {
|
504
403
|
localId: {
|
505
|
-
default:
|
404
|
+
default: ''
|
506
405
|
}
|
507
406
|
},
|
508
|
-
selectable:
|
407
|
+
selectable: false,
|
408
|
+
defining: true
|
509
409
|
});
|
510
|
-
export const
|
511
|
-
content: '
|
410
|
+
export const orderedList = createPMNodeSpecFactory({
|
411
|
+
content: 'listItem+',
|
412
|
+
marks: 'unsupportedNodeAttribute unsupportedMark',
|
512
413
|
group: 'block',
|
513
414
|
attrs: {
|
514
|
-
|
415
|
+
order: {
|
515
416
|
default: 1
|
516
417
|
}
|
517
418
|
},
|
419
|
+
selectable: false
|
420
|
+
});
|
421
|
+
export const listItem = createPMNodeSpecFactory({
|
422
|
+
content: '(codeBlock | paragraph | mediaSingle | unsupportedBlock) (codeBlock | paragraph | mediaSingle | taskList | bulletList | orderedList | unsupportedBlock)*',
|
423
|
+
marks: 'unsupportedNodeAttribute unsupportedMark',
|
518
424
|
selectable: false,
|
519
425
|
defining: true
|
520
426
|
});
|
427
|
+
export const bulletList = createPMNodeSpecFactory({
|
428
|
+
content: 'listItem+',
|
429
|
+
marks: 'unsupportedNodeAttribute unsupportedMark',
|
430
|
+
group: 'block',
|
431
|
+
selectable: false
|
432
|
+
});
|
521
433
|
export const headingWithNoMarks = createPMNodeSpecFactory({
|
522
|
-
content: '
|
434
|
+
content: 'inline*',
|
523
435
|
group: 'block',
|
524
436
|
attrs: {
|
525
437
|
level: {
|
@@ -533,8 +445,34 @@ export const mediaGroup = createPMNodeSpecFactory({
|
|
533
445
|
content: '(media | unsupportedBlock)+',
|
534
446
|
marks: 'link annotation border unsupportedNodeAttribute unsupportedMark',
|
535
447
|
group: 'block',
|
448
|
+
attrs: {},
|
536
449
|
selectable: false
|
537
450
|
});
|
451
|
+
export const decisionItem = createPMNodeSpecFactory({
|
452
|
+
content: 'inline*',
|
453
|
+
marks: '_',
|
454
|
+
attrs: {
|
455
|
+
localId: {
|
456
|
+
default: ''
|
457
|
+
},
|
458
|
+
state: {
|
459
|
+
default: 'DECIDED'
|
460
|
+
}
|
461
|
+
},
|
462
|
+
defining: true
|
463
|
+
});
|
464
|
+
export const decisionList = createPMNodeSpecFactory({
|
465
|
+
content: '(decisionItem | unsupportedBlock)+',
|
466
|
+
marks: 'unsupportedNodeAttribute unsupportedMark',
|
467
|
+
group: 'block',
|
468
|
+
attrs: {
|
469
|
+
localId: {
|
470
|
+
default: ''
|
471
|
+
}
|
472
|
+
},
|
473
|
+
selectable: false,
|
474
|
+
defining: true
|
475
|
+
});
|
538
476
|
export const rule = createPMNodeSpecFactory({
|
539
477
|
group: 'block'
|
540
478
|
});
|
@@ -561,8 +499,27 @@ export const panel = createPMNodeSpecFactory({
|
|
561
499
|
},
|
562
500
|
selectable: true
|
563
501
|
});
|
502
|
+
export const paragraph = createPMNodeSpecFactory({
|
503
|
+
content: 'inline*',
|
504
|
+
marks: 'link em strong strike subsup underline textColor annotation backgroundColor unsupportedNodeAttribute unsupportedMark code dataConsumer fragment border',
|
505
|
+
group: 'block',
|
506
|
+
selectable: false
|
507
|
+
});
|
508
|
+
export const paragraphWithMarks = createPMNodeSpecFactory({
|
509
|
+
content: 'inline*',
|
510
|
+
marks: 'link em strong strike subsup underline textColor annotation backgroundColor unsupportedNodeAttribute unsupportedMark code dataConsumer fragment border',
|
511
|
+
group: 'block',
|
512
|
+
selectable: false
|
513
|
+
});
|
514
|
+
export const blockquoteWithList = createPMNodeSpecFactory({
|
515
|
+
content: '(paragraph | orderedList | bulletList | unsupportedBlock)+',
|
516
|
+
group: 'block',
|
517
|
+
selectable: false,
|
518
|
+
defining: true
|
519
|
+
});
|
564
520
|
export const headingWithAlignment = createPMNodeSpecFactory({
|
565
|
-
content: '
|
521
|
+
content: 'inline*',
|
522
|
+
group: 'block',
|
566
523
|
attrs: {
|
567
524
|
level: {
|
568
525
|
default: 1
|
@@ -572,7 +529,8 @@ export const headingWithAlignment = createPMNodeSpecFactory({
|
|
572
529
|
defining: true
|
573
530
|
});
|
574
531
|
export const headingWithIndentation = createPMNodeSpecFactory({
|
575
|
-
content: '
|
532
|
+
content: 'inline*',
|
533
|
+
group: 'block',
|
576
534
|
attrs: {
|
577
535
|
level: {
|
578
536
|
default: 1
|
@@ -581,12 +539,62 @@ export const headingWithIndentation = createPMNodeSpecFactory({
|
|
581
539
|
selectable: false,
|
582
540
|
defining: true
|
583
541
|
});
|
542
|
+
export const paragraphWithAlignment = createPMNodeSpecFactory({
|
543
|
+
content: 'inline*',
|
544
|
+
marks: 'link em strong strike subsup underline textColor annotation backgroundColor unsupportedNodeAttribute unsupportedMark code dataConsumer fragment border',
|
545
|
+
selectable: false
|
546
|
+
});
|
584
547
|
export const blockquote = createPMNodeSpecFactory({
|
585
548
|
content: '(paragraph | bulletList | orderedList | unsupportedBlock)+',
|
586
|
-
marks: 'unsupportedNodeAttribute unsupportedMark',
|
587
549
|
selectable: false,
|
588
550
|
defining: true
|
589
551
|
});
|
552
|
+
export const extensionWithMarks = createPMNodeSpecFactory({
|
553
|
+
group: 'block',
|
554
|
+
atom: true,
|
555
|
+
attrs: {
|
556
|
+
extensionKey: {
|
557
|
+
default: ''
|
558
|
+
},
|
559
|
+
extensionType: {
|
560
|
+
default: ''
|
561
|
+
},
|
562
|
+
parameters: {
|
563
|
+
default: null
|
564
|
+
},
|
565
|
+
text: {
|
566
|
+
default: null
|
567
|
+
},
|
568
|
+
layout: {
|
569
|
+
default: 'default'
|
570
|
+
},
|
571
|
+
localId: {
|
572
|
+
default: null
|
573
|
+
}
|
574
|
+
},
|
575
|
+
selectable: true
|
576
|
+
});
|
577
|
+
export const embedCard = createPMNodeSpecFactory({
|
578
|
+
group: 'block',
|
579
|
+
attrs: {
|
580
|
+
url: {
|
581
|
+
default: ''
|
582
|
+
},
|
583
|
+
layout: {
|
584
|
+
default: 'center'
|
585
|
+
},
|
586
|
+
width: {
|
587
|
+
default: 100
|
588
|
+
},
|
589
|
+
originalHeight: {
|
590
|
+
default: null
|
591
|
+
},
|
592
|
+
originalWidth: {
|
593
|
+
default: null
|
594
|
+
}
|
595
|
+
},
|
596
|
+
selectable: true
|
597
|
+
});
|
590
598
|
export const nestedExpandWithNoMarks = createPMNodeSpecFactory({
|
591
599
|
content: '(codeBlock | paragraph | mediaSingle | taskList | bulletList | orderedList | heading | mediaGroup | decisionList | rule | panel | blockquote | unsupportedBlock)+',
|
592
600
|
marks: 'unsupportedNodeAttribute unsupportedMark',
|
@@ -655,7 +663,7 @@ export const table = createPMNodeSpecFactory({
|
|
655
663
|
group: 'block',
|
656
664
|
attrs: {
|
657
665
|
displayMode: {
|
658
|
-
default:
|
666
|
+
default: null
|
659
667
|
},
|
660
668
|
isNumberColumnEnabled: {
|
661
669
|
default: false
|
@@ -677,10 +685,25 @@ export const table = createPMNodeSpecFactory({
|
|
677
685
|
isolating: true,
|
678
686
|
tableRole: 'table'
|
679
687
|
});
|
680
|
-
export const
|
688
|
+
export const expandWithNoMark = createPMNodeSpecFactory({
|
681
689
|
content: '(codeBlock | blockCard | paragraph | mediaSingle | taskList | bulletList | orderedList | heading | mediaGroup | decisionList | rule | panel | blockquote | extension | embedCard | table | unsupportedBlock)+',
|
682
690
|
marks: 'unsupportedNodeAttribute unsupportedMark dataConsumer fragment',
|
683
691
|
group: 'block',
|
692
|
+
attrs: {
|
693
|
+
title: {
|
694
|
+
default: ''
|
695
|
+
},
|
696
|
+
__expanded: {
|
697
|
+
default: true
|
698
|
+
}
|
699
|
+
},
|
700
|
+
selectable: true,
|
701
|
+
isolating: true
|
702
|
+
});
|
703
|
+
export const bodiedExtensionWithMarks = createPMNodeSpecFactory({
|
704
|
+
content: '(codeBlock | blockCard | paragraph | mediaSingle | taskList | bulletList | orderedList | heading | mediaGroup | decisionList | rule | panel | blockquote | extension | embedCard | table | unsupportedBlock)+',
|
705
|
+
marks: 'dataConsumer fragment',
|
706
|
+
group: 'block',
|
684
707
|
attrs: {
|
685
708
|
extensionKey: {
|
686
709
|
default: ''
|
@@ -705,21 +728,6 @@ export const bodiedExtensionWithMarks = createPMNodeSpecFactory({
|
|
705
728
|
defining: true,
|
706
729
|
isolating: true
|
707
730
|
});
|
708
|
-
export const expandWithNoMark = createPMNodeSpecFactory({
|
709
|
-
content: '(codeBlock | blockCard | paragraph | mediaSingle | taskList | bulletList | orderedList | heading | mediaGroup | decisionList | rule | panel | blockquote | extension | embedCard | table | unsupportedBlock)+',
|
710
|
-
marks: 'unsupportedNodeAttribute unsupportedMark dataConsumer fragment',
|
711
|
-
group: 'block',
|
712
|
-
attrs: {
|
713
|
-
title: {
|
714
|
-
default: ''
|
715
|
-
},
|
716
|
-
__expanded: {
|
717
|
-
default: true
|
718
|
-
}
|
719
|
-
},
|
720
|
-
selectable: true,
|
721
|
-
isolating: true
|
722
|
-
});
|
723
731
|
export const confluenceUnsupportedBlock = createPMNodeSpecFactory({
|
724
732
|
group: 'block',
|
725
733
|
attrs: {
|
@@ -730,7 +738,7 @@ export const confluenceUnsupportedBlock = createPMNodeSpecFactory({
|
|
730
738
|
});
|
731
739
|
export const layoutColumn = createPMNodeSpecFactory({
|
732
740
|
content: '(block | unsupportedBlock)+',
|
733
|
-
marks: 'unsupportedNodeAttribute unsupportedMark alignment indentation dataConsumer
|
741
|
+
marks: 'unsupportedNodeAttribute unsupportedMark alignment indentation fragment dataConsumer',
|
734
742
|
attrs: {
|
735
743
|
width: {}
|
736
744
|
},
|
@@ -742,36 +750,134 @@ export const layoutSection = createPMNodeSpecFactory({
|
|
742
750
|
marks: 'unsupportedNodeAttribute unsupportedMark',
|
743
751
|
isolating: true
|
744
752
|
});
|
745
|
-
export const
|
746
|
-
content: '(layoutColumn | unsupportedBlock){1,3}',
|
747
|
-
marks: 'unsupportedNodeAttribute unsupportedMark',
|
748
|
-
isolating: true
|
749
|
-
});
|
750
|
-
export const expandWithBreakoutMark = createPMNodeSpecFactory({
|
753
|
+
export const bodiedExtension = createPMNodeSpecFactory({
|
751
754
|
content: '(codeBlock | blockCard | paragraph | mediaSingle | taskList | bulletList | orderedList | heading | mediaGroup | decisionList | rule | panel | blockquote | extension | embedCard | table | unsupportedBlock)+',
|
752
|
-
marks: '
|
755
|
+
marks: 'dataConsumer fragment',
|
753
756
|
attrs: {
|
754
|
-
|
757
|
+
extensionKey: {
|
755
758
|
default: ''
|
756
759
|
},
|
757
|
-
|
758
|
-
default:
|
760
|
+
extensionType: {
|
761
|
+
default: ''
|
762
|
+
},
|
763
|
+
parameters: {
|
764
|
+
default: null
|
765
|
+
},
|
766
|
+
text: {
|
767
|
+
default: null
|
768
|
+
},
|
769
|
+
layout: {
|
770
|
+
default: 'default'
|
771
|
+
},
|
772
|
+
localId: {
|
773
|
+
default: null
|
759
774
|
}
|
760
775
|
},
|
761
776
|
selectable: true,
|
777
|
+
defining: true,
|
762
778
|
isolating: true
|
763
779
|
});
|
764
|
-
export const
|
780
|
+
export const heading = createPMNodeSpecFactory({
|
781
|
+
content: 'inline*',
|
782
|
+
attrs: {
|
783
|
+
level: {
|
784
|
+
default: 1
|
785
|
+
}
|
786
|
+
},
|
787
|
+
selectable: false,
|
788
|
+
defining: true
|
789
|
+
});
|
790
|
+
export const codeBlock = createPMNodeSpecFactory({
|
765
791
|
content: '(text | unsupportedInline)*',
|
792
|
+
marks: 'unsupportedMark unsupportedNodeAttribute',
|
766
793
|
attrs: {
|
767
794
|
language: {
|
768
795
|
default: null
|
796
|
+
},
|
797
|
+
uniqueId: {
|
798
|
+
default: null
|
769
799
|
}
|
770
800
|
},
|
771
801
|
code: true,
|
772
802
|
defining: true
|
773
803
|
});
|
804
|
+
export const mediaSingle = createPMNodeSpecFactory({
|
805
|
+
content: 'media',
|
806
|
+
marks: 'link annotation border unsupportedNodeAttribute unsupportedMark',
|
807
|
+
atom: false,
|
808
|
+
attrs: {
|
809
|
+
width: {
|
810
|
+
default: null
|
811
|
+
},
|
812
|
+
layout: {
|
813
|
+
default: 'center'
|
814
|
+
},
|
815
|
+
widthType: {
|
816
|
+
default: null
|
817
|
+
}
|
818
|
+
},
|
819
|
+
selectable: true
|
820
|
+
});
|
821
|
+
export const extension = createPMNodeSpecFactory({
|
822
|
+
atom: true,
|
823
|
+
attrs: {
|
824
|
+
extensionKey: {
|
825
|
+
default: ''
|
826
|
+
},
|
827
|
+
extensionType: {
|
828
|
+
default: ''
|
829
|
+
},
|
830
|
+
parameters: {
|
831
|
+
default: null
|
832
|
+
},
|
833
|
+
text: {
|
834
|
+
default: null
|
835
|
+
},
|
836
|
+
layout: {
|
837
|
+
default: 'default'
|
838
|
+
},
|
839
|
+
localId: {
|
840
|
+
default: null
|
841
|
+
}
|
842
|
+
},
|
843
|
+
selectable: true
|
844
|
+
});
|
845
|
+
export const extensionFrame = createPMNodeSpecFactory({
|
846
|
+
content: '(bodiedExtension | panel | paragraph | blockquote | orderedList | bulletList | rule | heading | codeBlock | mediaGroup | mediaSingle | decisionList | taskList | table | extension | blockCard | embedCard | unsupportedBlock)+',
|
847
|
+
marks: 'dataConsumer fragment',
|
848
|
+
attrs: {},
|
849
|
+
selectable: false,
|
850
|
+
definingAsContext: false,
|
851
|
+
definingForContent: true,
|
852
|
+
isolating: true
|
853
|
+
});
|
854
|
+
export const multiBodiedExtension = createPMNodeSpecFactory({
|
855
|
+
content: 'extensionFrame+',
|
856
|
+
group: 'blockRootOnly',
|
857
|
+
attrs: {
|
858
|
+
extensionKey: {
|
859
|
+
default: ''
|
860
|
+
},
|
861
|
+
extensionType: {
|
862
|
+
default: ''
|
863
|
+
},
|
864
|
+
parameters: {
|
865
|
+
default: null
|
866
|
+
},
|
867
|
+
text: {
|
868
|
+
default: null
|
869
|
+
},
|
870
|
+
layout: {
|
871
|
+
default: 'default'
|
872
|
+
},
|
873
|
+
localId: {
|
874
|
+
default: null
|
875
|
+
}
|
876
|
+
},
|
877
|
+
selectable: true,
|
878
|
+
definingAsContext: true
|
879
|
+
});
|
774
880
|
export const doc = createPMNodeSpecFactory({
|
775
|
-
content: '(block | layoutSection | blockRootOnly
|
776
|
-
marks: 'unsupportedNodeAttribute unsupportedMark alignment indentation dataConsumer
|
881
|
+
content: '(block | layoutSection | blockRootOnly)+',
|
882
|
+
marks: 'unsupportedNodeAttribute unsupportedMark alignment indentation fragment dataConsumer breakout'
|
777
883
|
});
|