@atlaskit/adf-schema 36.14.0 → 36.15.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.
Files changed (116) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/cjs/next-schema/full-schema.adf.js +3 -2
  3. package/dist/cjs/next-schema/generated/markTypes.js +23 -23
  4. package/dist/cjs/next-schema/generated/nodeTypes.js +136 -202
  5. package/dist/cjs/next-schema/groups/blockGroup.js +5 -1
  6. package/dist/cjs/next-schema/groups/inlineGroup.js +1 -3
  7. package/dist/cjs/next-schema/nodes/blockCard.js +7 -3
  8. package/dist/cjs/next-schema/nodes/caption.js +1 -0
  9. package/dist/cjs/next-schema/nodes/codeBlock.js +2 -2
  10. package/dist/cjs/next-schema/nodes/decisionItem.js +1 -0
  11. package/dist/cjs/next-schema/nodes/inlineExtension.js +5 -1
  12. package/dist/cjs/next-schema/nodes/layoutColumn.js +2 -1
  13. package/dist/cjs/next-schema/nodes/media.js +2 -2
  14. package/dist/cjs/next-schema/nodes/mediaInline.js +29 -12
  15. package/dist/cjs/next-schema/nodes/mediaSingle.js +2 -1
  16. package/dist/cjs/next-schema/nodes/mention.js +2 -1
  17. package/dist/cjs/next-schema/nodes/placeholder.js +2 -0
  18. package/dist/cjs/next-schema/nodes/table.js +1 -0
  19. package/dist/cjs/next-schema/nodes/tableCell.js +2 -2
  20. package/dist/cjs/next-schema/nodes/tableHeader.js +2 -2
  21. package/dist/cjs/next-schema/nodes/tableRow.js +2 -1
  22. package/dist/cjs/next-schema/nodes/task.js +1 -0
  23. package/dist/es2019/next-schema/full-schema.adf.js +3 -2
  24. package/dist/es2019/next-schema/generated/markTypes.js +23 -23
  25. package/dist/es2019/next-schema/generated/nodeTypes.js +135 -201
  26. package/dist/es2019/next-schema/groups/blockGroup.js +5 -1
  27. package/dist/es2019/next-schema/groups/inlineGroup.js +1 -3
  28. package/dist/es2019/next-schema/nodes/blockCard.js +7 -3
  29. package/dist/es2019/next-schema/nodes/caption.js +1 -0
  30. package/dist/es2019/next-schema/nodes/codeBlock.js +1 -1
  31. package/dist/es2019/next-schema/nodes/decisionItem.js +1 -0
  32. package/dist/es2019/next-schema/nodes/inlineExtension.js +5 -1
  33. package/dist/es2019/next-schema/nodes/layoutColumn.js +2 -1
  34. package/dist/es2019/next-schema/nodes/media.js +2 -2
  35. package/dist/es2019/next-schema/nodes/mediaInline.js +29 -12
  36. package/dist/es2019/next-schema/nodes/mediaSingle.js +2 -1
  37. package/dist/es2019/next-schema/nodes/mention.js +2 -1
  38. package/dist/es2019/next-schema/nodes/placeholder.js +2 -0
  39. package/dist/es2019/next-schema/nodes/table.js +1 -0
  40. package/dist/es2019/next-schema/nodes/tableCell.js +2 -2
  41. package/dist/es2019/next-schema/nodes/tableHeader.js +2 -2
  42. package/dist/es2019/next-schema/nodes/tableRow.js +2 -1
  43. package/dist/es2019/next-schema/nodes/task.js +1 -0
  44. package/dist/esm/next-schema/full-schema.adf.js +3 -2
  45. package/dist/esm/next-schema/generated/markTypes.js +23 -23
  46. package/dist/esm/next-schema/generated/nodeTypes.js +135 -201
  47. package/dist/esm/next-schema/groups/blockGroup.js +5 -1
  48. package/dist/esm/next-schema/groups/inlineGroup.js +1 -3
  49. package/dist/esm/next-schema/nodes/blockCard.js +7 -3
  50. package/dist/esm/next-schema/nodes/caption.js +1 -0
  51. package/dist/esm/next-schema/nodes/codeBlock.js +1 -1
  52. package/dist/esm/next-schema/nodes/decisionItem.js +1 -0
  53. package/dist/esm/next-schema/nodes/inlineExtension.js +5 -1
  54. package/dist/esm/next-schema/nodes/layoutColumn.js +2 -1
  55. package/dist/esm/next-schema/nodes/media.js +2 -2
  56. package/dist/esm/next-schema/nodes/mediaInline.js +29 -12
  57. package/dist/esm/next-schema/nodes/mediaSingle.js +2 -1
  58. package/dist/esm/next-schema/nodes/mention.js +2 -1
  59. package/dist/esm/next-schema/nodes/placeholder.js +2 -0
  60. package/dist/esm/next-schema/nodes/table.js +1 -0
  61. package/dist/esm/next-schema/nodes/tableCell.js +2 -2
  62. package/dist/esm/next-schema/nodes/tableHeader.js +2 -2
  63. package/dist/esm/next-schema/nodes/tableRow.js +2 -1
  64. package/dist/esm/next-schema/nodes/task.js +1 -0
  65. package/dist/types/next-schema/full-schema.adf.d.ts +3 -0
  66. package/dist/types/next-schema/generated/markTypes.d.ts +36 -36
  67. package/dist/types/next-schema/generated/nodeGroupTypes.d.ts +4 -4
  68. package/dist/types/next-schema/generated/nodeTypes.d.ts +59 -120
  69. package/dist/types/next-schema/groups/nonNestableBlockContentGroup.d.ts +12 -0
  70. package/dist/types/next-schema/nodes/blockCard.d.ts +3 -0
  71. package/dist/types/next-schema/nodes/blockquote.d.ts +3 -0
  72. package/dist/types/next-schema/nodes/bodiedExtension.d.ts +3 -0
  73. package/dist/types/next-schema/nodes/caption.d.ts +3 -0
  74. package/dist/types/next-schema/nodes/codeBlock.d.ts +7 -1
  75. package/dist/types/next-schema/nodes/confluenceUnsupportedBlock.d.ts +3 -0
  76. package/dist/types/next-schema/nodes/confluenceUnsupportedInline.d.ts +3 -0
  77. package/dist/types/next-schema/nodes/date.d.ts +3 -0
  78. package/dist/types/next-schema/nodes/decisionItem.d.ts +3 -0
  79. package/dist/types/next-schema/nodes/decisionList.d.ts +3 -0
  80. package/dist/types/next-schema/nodes/embedCard.d.ts +3 -0
  81. package/dist/types/next-schema/nodes/emoji.d.ts +3 -0
  82. package/dist/types/next-schema/nodes/expand.d.ts +3 -0
  83. package/dist/types/next-schema/nodes/extension.d.ts +3 -0
  84. package/dist/types/next-schema/nodes/extensionFrame.d.ts +3 -0
  85. package/dist/types/next-schema/nodes/hardBreak.d.ts +3 -0
  86. package/dist/types/next-schema/nodes/heading.d.ts +3 -0
  87. package/dist/types/next-schema/nodes/inlineCard.d.ts +3 -0
  88. package/dist/types/next-schema/nodes/inlineExtension.d.ts +5 -0
  89. package/dist/types/next-schema/nodes/layoutColumn.d.ts +3 -0
  90. package/dist/types/next-schema/nodes/layoutSection.d.ts +3 -0
  91. package/dist/types/next-schema/nodes/list.d.ts +6 -0
  92. package/dist/types/next-schema/nodes/media.d.ts +3 -0
  93. package/dist/types/next-schema/nodes/mediaGroup.d.ts +3 -0
  94. package/dist/types/next-schema/nodes/mediaInline.d.ts +3 -0
  95. package/dist/types/next-schema/nodes/mediaSingle.d.ts +3 -0
  96. package/dist/types/next-schema/nodes/mention.d.ts +3 -0
  97. package/dist/types/next-schema/nodes/multiBodiedExtension.d.ts +3 -0
  98. package/dist/types/next-schema/nodes/nestedExpand.d.ts +3 -0
  99. package/dist/types/next-schema/nodes/panel.d.ts +3 -0
  100. package/dist/types/next-schema/nodes/paragraph.d.ts +3 -0
  101. package/dist/types/next-schema/nodes/placeholder.d.ts +3 -0
  102. package/dist/types/next-schema/nodes/rule.d.ts +3 -0
  103. package/dist/types/next-schema/nodes/status.d.ts +3 -0
  104. package/dist/types/next-schema/nodes/table.d.ts +3 -0
  105. package/dist/types/next-schema/nodes/tableCell.d.ts +3 -0
  106. package/dist/types/next-schema/nodes/tableHeader.d.ts +3 -0
  107. package/dist/types/next-schema/nodes/tableRow.d.ts +3 -0
  108. package/dist/types/next-schema/nodes/task.d.ts +6 -0
  109. package/dist/types/next-schema/nodes/text.d.ts +3 -0
  110. package/dist/types/next-schema/nodes/unsupportedBlock.d.ts +3 -0
  111. package/dist/types/next-schema/nodes/unsupportedInline.d.ts +3 -0
  112. package/package.json +2 -2
  113. package/schema-generators/__tests__/helpers/_utils.ts +123 -0
  114. package/schema-generators/__tests__/helpers/utils.unit.ts +66 -0
  115. package/schema-generators/__tests__/unit/json-full-schema.unit.ts +1142 -1231
  116. package/schema-generators/__tests__/unit/validate-pm-schema.unit.ts +157 -36
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @atlaskit/adf-schema
2
2
 
3
+ ## 36.15.0
4
+
5
+ ### Minor Changes
6
+
7
+ - e0c8b0e: Add suuport for all and no child marks in DSL
8
+
9
+ ## 36.14.1
10
+
11
+ ### Patch Changes
12
+
13
+ - 32308a7: add test to validate generated nodeSpec from ADF DSL
14
+
3
15
  ## 36.14.0
4
16
 
5
17
  ### Minor Changes
@@ -8,12 +8,13 @@ var _adfSchemaGenerator = require("@atlaskit/adf-schema-generator");
8
8
  var _blockGroup = require("./groups/blockGroup");
9
9
  var _layoutSection = require("./nodes/layoutSection");
10
10
  var _blockRootOnlyGroup = require("./groups/blockRootOnlyGroup");
11
- var _nestedExpand = require("./nodes/nestedExpand");
12
11
  var _paragraph = require("./nodes/paragraph");
12
+ var _expand = require("./nodes/expand");
13
+ var _codeBlock = require("./nodes/codeBlock");
13
14
  var _unsupportedBlock = require("./nodes/unsupportedBlock");
14
15
  var doc = (0, _adfSchemaGenerator.adfNode)('doc').define({
15
16
  root: true,
16
17
  version: 1,
17
- content: [(0, _adfSchemaGenerator.$onePlus)((0, _adfSchemaGenerator.$or)(_blockGroup.blockGroup, _layoutSection.layoutSection, _layoutSection.layoutSection.use('full'), _blockRootOnlyGroup.blockRootOnlyGroup, _nestedExpand.nestedExpand, _paragraph.paragraph, _unsupportedBlock.unsupportedBlock))]
18
+ content: [(0, _adfSchemaGenerator.$onePlus)((0, _adfSchemaGenerator.$or)(_blockGroup.blockGroup, _layoutSection.layoutSection, _layoutSection.layoutSection.use('full'), _blockRootOnlyGroup.blockRootOnlyGroup, _expand.expand.use('with_breakout_mark'), _codeBlock.codeBlock.use('with_no_marks'), _codeBlock.codeBlock.use('with_marks'), _paragraph.paragraph.use('with_indentation'), _unsupportedBlock.unsupportedBlock))]
18
19
  });
19
20
  var _default = exports.default = doc;
@@ -22,15 +22,6 @@ var unsupportedMark = exports.unsupportedMark = (0, _adfSchemaGenerator.createPM
22
22
  }
23
23
  }
24
24
  });
25
- var breakout = exports.breakout = (0, _adfSchemaGenerator.createPMMarkSpecFactory)({
26
- attrs: {
27
- mode: {
28
- default: 'wide'
29
- }
30
- },
31
- inclusive: false,
32
- spanning: false
33
- });
34
25
  var link = exports.link = (0, _adfSchemaGenerator.createPMMarkSpecFactory)({
35
26
  attrs: {
36
27
  href: {},
@@ -109,20 +100,6 @@ var code = exports.code = (0, _adfSchemaGenerator.createPMMarkSpecFactory)({
109
100
  inclusive: true,
110
101
  excludes: 'fontStyle link searchQuery color'
111
102
  });
112
- var alignment = exports.alignment = (0, _adfSchemaGenerator.createPMMarkSpecFactory)({
113
- attrs: {
114
- align: {}
115
- },
116
- excludes: 'alignment indentation',
117
- group: 'alignment'
118
- });
119
- var indentation = exports.indentation = (0, _adfSchemaGenerator.createPMMarkSpecFactory)({
120
- attrs: {
121
- level: {}
122
- },
123
- excludes: 'indentation alignment',
124
- group: 'indentation'
125
- });
126
103
  var dataConsumer = exports.dataConsumer = (0, _adfSchemaGenerator.createPMMarkSpecFactory)({
127
104
  attrs: {
128
105
  sources: {
@@ -140,4 +117,27 @@ var fragment = exports.fragment = (0, _adfSchemaGenerator.createPMMarkSpecFactor
140
117
  }
141
118
  },
142
119
  inclusive: false
120
+ });
121
+ var alignment = exports.alignment = (0, _adfSchemaGenerator.createPMMarkSpecFactory)({
122
+ attrs: {
123
+ align: {}
124
+ },
125
+ excludes: 'alignment indentation',
126
+ group: 'alignment'
127
+ });
128
+ var indentation = exports.indentation = (0, _adfSchemaGenerator.createPMMarkSpecFactory)({
129
+ attrs: {
130
+ level: {}
131
+ },
132
+ excludes: 'indentation alignment',
133
+ group: 'indentation'
134
+ });
135
+ var breakout = exports.breakout = (0, _adfSchemaGenerator.createPMMarkSpecFactory)({
136
+ attrs: {
137
+ mode: {
138
+ default: 'wide'
139
+ }
140
+ },
141
+ inclusive: false,
142
+ spanning: false
143
143
  });