@atlaskit/adf-utils 19.8.1 → 19.9.1
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 +18 -0
- package/afm-post-office/tsconfig.json +5 -1
- package/dist/cjs/validator/specs/index.js +24 -30
- package/dist/cjs/validator/validator.js +4 -4
- package/dist/es2019/validator/specs/index.js +2 -2
- package/dist/esm/validator/specs/index.js +2 -2
- package/dist/esm/validator/validator.js +3 -3
- package/dist/types/validator/specs/index.d.ts +2 -2
- package/dist/types-ts4.5/validator/specs/index.d.ts +2 -2
- package/package.json +3 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @atlaskit/adf-utils
|
|
2
2
|
|
|
3
|
+
## 19.9.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#152510](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/152510)
|
|
8
|
+
[`dcf9edde7ac7b`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/dcf9edde7ac7b) -
|
|
9
|
+
bump adf-schema to 42.0.1
|
|
10
|
+
|
|
11
|
+
## 19.9.0
|
|
12
|
+
|
|
13
|
+
### Minor Changes
|
|
14
|
+
|
|
15
|
+
- [#151190](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/151190)
|
|
16
|
+
[`a3723b1cdede2`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/a3723b1cdede2) -
|
|
17
|
+
[ux] [ED-25037] this change bumps @atlaskit/adf-schema from 40.9.0 to 40.9.4 which makes the
|
|
18
|
+
blockquote selectable, adds missing marks to the PM node spec and fixes a bug that converted
|
|
19
|
+
pasted external images to media groups.
|
|
20
|
+
|
|
3
21
|
## 19.8.1
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
|
@@ -15,12 +15,6 @@ Object.defineProperty(exports, "annotation", {
|
|
|
15
15
|
return _schemaValidator.annotation;
|
|
16
16
|
}
|
|
17
17
|
});
|
|
18
|
-
Object.defineProperty(exports, "atomic_inline", {
|
|
19
|
-
enumerable: true,
|
|
20
|
-
get: function get() {
|
|
21
|
-
return _schemaValidator.atomic_inline;
|
|
22
|
-
}
|
|
23
|
-
});
|
|
24
18
|
Object.defineProperty(exports, "backgroundColor", {
|
|
25
19
|
enumerable: true,
|
|
26
20
|
get: function get() {
|
|
@@ -111,10 +105,10 @@ Object.defineProperty(exports, "codeBlock_with_no_marks", {
|
|
|
111
105
|
return _schemaValidator.codeBlock_with_no_marks;
|
|
112
106
|
}
|
|
113
107
|
});
|
|
114
|
-
Object.defineProperty(exports, "
|
|
108
|
+
Object.defineProperty(exports, "confluenceInlineComment", {
|
|
115
109
|
enumerable: true,
|
|
116
110
|
get: function get() {
|
|
117
|
-
return _schemaValidator.
|
|
111
|
+
return _schemaValidator.confluenceInlineComment;
|
|
118
112
|
}
|
|
119
113
|
});
|
|
120
114
|
Object.defineProperty(exports, "dataConsumer", {
|
|
@@ -207,12 +201,6 @@ Object.defineProperty(exports, "extension_with_marks", {
|
|
|
207
201
|
return _schemaValidator.extension_with_marks;
|
|
208
202
|
}
|
|
209
203
|
});
|
|
210
|
-
Object.defineProperty(exports, "formatted_text_inline", {
|
|
211
|
-
enumerable: true,
|
|
212
|
-
get: function get() {
|
|
213
|
-
return _schemaValidator.formatted_text_inline;
|
|
214
|
-
}
|
|
215
|
-
});
|
|
216
204
|
Object.defineProperty(exports, "fragment", {
|
|
217
205
|
enumerable: true,
|
|
218
206
|
get: function get() {
|
|
@@ -255,12 +243,6 @@ Object.defineProperty(exports, "indentation", {
|
|
|
255
243
|
return _schemaValidator.indentation;
|
|
256
244
|
}
|
|
257
245
|
});
|
|
258
|
-
Object.defineProperty(exports, "inline", {
|
|
259
|
-
enumerable: true,
|
|
260
|
-
get: function get() {
|
|
261
|
-
return _schemaValidator.inline;
|
|
262
|
-
}
|
|
263
|
-
});
|
|
264
246
|
Object.defineProperty(exports, "inlineCard", {
|
|
265
247
|
enumerable: true,
|
|
266
248
|
get: function get() {
|
|
@@ -279,10 +261,10 @@ Object.defineProperty(exports, "inlineExtension_with_marks", {
|
|
|
279
261
|
return _schemaValidator.inlineExtension_with_marks;
|
|
280
262
|
}
|
|
281
263
|
});
|
|
282
|
-
Object.defineProperty(exports, "
|
|
264
|
+
Object.defineProperty(exports, "inline_content", {
|
|
283
265
|
enumerable: true,
|
|
284
266
|
get: function get() {
|
|
285
|
-
return _schemaValidator.
|
|
267
|
+
return _schemaValidator.inline_content;
|
|
286
268
|
}
|
|
287
269
|
});
|
|
288
270
|
Object.defineProperty(exports, "layoutColumn", {
|
|
@@ -315,12 +297,6 @@ Object.defineProperty(exports, "link", {
|
|
|
315
297
|
return _schemaValidator.link;
|
|
316
298
|
}
|
|
317
299
|
});
|
|
318
|
-
Object.defineProperty(exports, "link_text_inline", {
|
|
319
|
-
enumerable: true,
|
|
320
|
-
get: function get() {
|
|
321
|
-
return _schemaValidator.link_text_inline;
|
|
322
|
-
}
|
|
323
|
-
});
|
|
324
300
|
Object.defineProperty(exports, "listItem", {
|
|
325
301
|
enumerable: true,
|
|
326
302
|
get: function get() {
|
|
@@ -489,10 +465,10 @@ Object.defineProperty(exports, "tableCell", {
|
|
|
489
465
|
return _schemaValidator.tableCell;
|
|
490
466
|
}
|
|
491
467
|
});
|
|
492
|
-
Object.defineProperty(exports, "
|
|
468
|
+
Object.defineProperty(exports, "tableCellContent", {
|
|
493
469
|
enumerable: true,
|
|
494
470
|
get: function get() {
|
|
495
|
-
return _schemaValidator.
|
|
471
|
+
return _schemaValidator.tableCellContent;
|
|
496
472
|
}
|
|
497
473
|
});
|
|
498
474
|
Object.defineProperty(exports, "tableHeader", {
|
|
@@ -531,6 +507,24 @@ Object.defineProperty(exports, "textColor", {
|
|
|
531
507
|
return _schemaValidator.textColor;
|
|
532
508
|
}
|
|
533
509
|
});
|
|
510
|
+
Object.defineProperty(exports, "text_code_inline", {
|
|
511
|
+
enumerable: true,
|
|
512
|
+
get: function get() {
|
|
513
|
+
return _schemaValidator.text_code_inline;
|
|
514
|
+
}
|
|
515
|
+
});
|
|
516
|
+
Object.defineProperty(exports, "text_formatted", {
|
|
517
|
+
enumerable: true,
|
|
518
|
+
get: function get() {
|
|
519
|
+
return _schemaValidator.text_formatted;
|
|
520
|
+
}
|
|
521
|
+
});
|
|
522
|
+
Object.defineProperty(exports, "text_link_inline", {
|
|
523
|
+
enumerable: true,
|
|
524
|
+
get: function get() {
|
|
525
|
+
return _schemaValidator.text_link_inline;
|
|
526
|
+
}
|
|
527
|
+
});
|
|
534
528
|
Object.defineProperty(exports, "underline", {
|
|
535
529
|
enumerable: true,
|
|
536
530
|
get: function get() {
|
|
@@ -15,7 +15,7 @@ var _utils = require("./utils");
|
|
|
15
15
|
var _rules = require("./rules");
|
|
16
16
|
var _excluded = ["items"];
|
|
17
17
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
18
|
-
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u &&
|
|
18
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
19
19
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
20
20
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
21
21
|
function mapMarksItems(spec) {
|
|
@@ -139,14 +139,14 @@ function getOptionsForType(type, list) {
|
|
|
139
139
|
}
|
|
140
140
|
for (var i = 0, len = list.length; i < len; i++) {
|
|
141
141
|
var spec = list[i];
|
|
142
|
-
var
|
|
142
|
+
var name = spec;
|
|
143
143
|
var options = {};
|
|
144
144
|
if (Array.isArray(spec)) {
|
|
145
145
|
var _spec = (0, _slicedToArray2.default)(spec, 2);
|
|
146
|
-
|
|
146
|
+
name = _spec[0];
|
|
147
147
|
options = _spec[1];
|
|
148
148
|
}
|
|
149
|
-
if (
|
|
149
|
+
if (name === type) {
|
|
150
150
|
return options;
|
|
151
151
|
}
|
|
152
152
|
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { alignment, annotation,
|
|
1
|
+
export { alignment, annotation, backgroundColor, blockCard, block_content, blockquote, blockquote_without_nested_codeblock_or_media, bodiedExtension, bodiedExtension_with_marks, border, breakout, bulletList, caption, code, codeBlock, codeBlock_with_marks, codeBlock_with_no_marks, confluenceInlineComment, dataConsumer, date, decisionItem, decisionList, doc, em, embedCard, emoji, expand, expand_with_breakout_mark, expand_with_no_mark, expand_without_nested_expand, extension, extensionFrame, extension_with_marks, fragment, hardBreak, heading, heading_with_alignment, heading_with_indentation, heading_with_no_marks, indentation, inlineCard, inlineExtension, inlineExtension_with_marks, inline_content, layoutColumn, layoutSection, layoutSection_full, layoutSection_with_single_column, link, listItem, media, mediaGroup, mediaInline, mediaSingle, mediaSingle_caption, mediaSingle_full, mention, multiBodiedExtension, nestedExpand, nestedExpand_content, nestedExpand_with_no_marks, non_nestable_block_content, orderedList, panel, panel_with_nested_blockquote,
|
|
2
2
|
// Stage-0
|
|
3
|
-
paragraph, paragraph_with_alignment, paragraph_with_indentation, paragraph_with_no_marks, placeholder, rule, status, strike, strong, subsup, table, tableCell,
|
|
3
|
+
paragraph, paragraph_with_alignment, paragraph_with_indentation, paragraph_with_no_marks, placeholder, rule, status, strike, strong, subsup, table, tableCell, tableCellContent, tableHeader, tableRow, taskItem, taskList, text, textColor, text_code_inline, text_formatted, text_link_inline, underline } from '@atlaskit/adf-schema/schema-validator';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { alignment, annotation,
|
|
1
|
+
export { alignment, annotation, backgroundColor, blockCard, block_content, blockquote, blockquote_without_nested_codeblock_or_media, bodiedExtension, bodiedExtension_with_marks, border, breakout, bulletList, caption, code, codeBlock, codeBlock_with_marks, codeBlock_with_no_marks, confluenceInlineComment, dataConsumer, date, decisionItem, decisionList, doc, em, embedCard, emoji, expand, expand_with_breakout_mark, expand_with_no_mark, expand_without_nested_expand, extension, extensionFrame, extension_with_marks, fragment, hardBreak, heading, heading_with_alignment, heading_with_indentation, heading_with_no_marks, indentation, inlineCard, inlineExtension, inlineExtension_with_marks, inline_content, layoutColumn, layoutSection, layoutSection_full, layoutSection_with_single_column, link, listItem, media, mediaGroup, mediaInline, mediaSingle, mediaSingle_caption, mediaSingle_full, mention, multiBodiedExtension, nestedExpand, nestedExpand_content, nestedExpand_with_no_marks, non_nestable_block_content, orderedList, panel, panel_with_nested_blockquote,
|
|
2
2
|
// Stage-0
|
|
3
|
-
paragraph, paragraph_with_alignment, paragraph_with_indentation, paragraph_with_no_marks, placeholder, rule, status, strike, strong, subsup, table, tableCell,
|
|
3
|
+
paragraph, paragraph_with_alignment, paragraph_with_indentation, paragraph_with_no_marks, placeholder, rule, status, strike, strong, subsup, table, tableCell, tableCellContent, tableHeader, tableRow, taskItem, taskList, text, textColor, text_code_inline, text_formatted, text_link_inline, underline } from '@atlaskit/adf-schema/schema-validator';
|
|
@@ -128,14 +128,14 @@ function getOptionsForType(type, list) {
|
|
|
128
128
|
}
|
|
129
129
|
for (var i = 0, len = list.length; i < len; i++) {
|
|
130
130
|
var spec = list[i];
|
|
131
|
-
var
|
|
131
|
+
var name = spec;
|
|
132
132
|
var options = {};
|
|
133
133
|
if (Array.isArray(spec)) {
|
|
134
134
|
var _spec = _slicedToArray(spec, 2);
|
|
135
|
-
|
|
135
|
+
name = _spec[0];
|
|
136
136
|
options = _spec[1];
|
|
137
137
|
}
|
|
138
|
-
if (
|
|
138
|
+
if (name === type) {
|
|
139
139
|
return options;
|
|
140
140
|
}
|
|
141
141
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { alignment, annotation,
|
|
2
|
-
paragraph, paragraph_with_alignment, paragraph_with_indentation, paragraph_with_no_marks, placeholder, rule, status, strike, strong, subsup, table, tableCell,
|
|
1
|
+
export { alignment, annotation, backgroundColor, blockCard, block_content, blockquote, blockquote_without_nested_codeblock_or_media, bodiedExtension, bodiedExtension_with_marks, border, breakout, bulletList, caption, code, codeBlock, codeBlock_with_marks, codeBlock_with_no_marks, confluenceInlineComment, dataConsumer, date, decisionItem, decisionList, doc, em, embedCard, emoji, expand, expand_with_breakout_mark, expand_with_no_mark, expand_without_nested_expand, extension, extensionFrame, extension_with_marks, fragment, hardBreak, heading, heading_with_alignment, heading_with_indentation, heading_with_no_marks, indentation, inlineCard, inlineExtension, inlineExtension_with_marks, inline_content, layoutColumn, layoutSection, layoutSection_full, layoutSection_with_single_column, link, listItem, media, mediaGroup, mediaInline, mediaSingle, mediaSingle_caption, mediaSingle_full, mention, multiBodiedExtension, nestedExpand, nestedExpand_content, nestedExpand_with_no_marks, non_nestable_block_content, orderedList, panel, panel_with_nested_blockquote, // Stage-0
|
|
2
|
+
paragraph, paragraph_with_alignment, paragraph_with_indentation, paragraph_with_no_marks, placeholder, rule, status, strike, strong, subsup, table, tableCell, tableCellContent, tableHeader, tableRow, taskItem, taskList, text, textColor, text_code_inline, text_formatted, text_link_inline, underline, } from '@atlaskit/adf-schema/schema-validator';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { alignment, annotation,
|
|
2
|
-
paragraph, paragraph_with_alignment, paragraph_with_indentation, paragraph_with_no_marks, placeholder, rule, status, strike, strong, subsup, table, tableCell,
|
|
1
|
+
export { alignment, annotation, backgroundColor, blockCard, block_content, blockquote, blockquote_without_nested_codeblock_or_media, bodiedExtension, bodiedExtension_with_marks, border, breakout, bulletList, caption, code, codeBlock, codeBlock_with_marks, codeBlock_with_no_marks, confluenceInlineComment, dataConsumer, date, decisionItem, decisionList, doc, em, embedCard, emoji, expand, expand_with_breakout_mark, expand_with_no_mark, expand_without_nested_expand, extension, extensionFrame, extension_with_marks, fragment, hardBreak, heading, heading_with_alignment, heading_with_indentation, heading_with_no_marks, indentation, inlineCard, inlineExtension, inlineExtension_with_marks, inline_content, layoutColumn, layoutSection, layoutSection_full, layoutSection_with_single_column, link, listItem, media, mediaGroup, mediaInline, mediaSingle, mediaSingle_caption, mediaSingle_full, mention, multiBodiedExtension, nestedExpand, nestedExpand_content, nestedExpand_with_no_marks, non_nestable_block_content, orderedList, panel, panel_with_nested_blockquote, // Stage-0
|
|
2
|
+
paragraph, paragraph_with_alignment, paragraph_with_indentation, paragraph_with_no_marks, placeholder, rule, status, strike, strong, subsup, table, tableCell, tableCellContent, tableHeader, tableRow, taskItem, taskList, text, textColor, text_code_inline, text_formatted, text_link_inline, underline, } from '@atlaskit/adf-schema/schema-validator';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/adf-utils",
|
|
3
|
-
"version": "19.
|
|
3
|
+
"version": "19.9.1",
|
|
4
4
|
"description": "Set of utilities to traverse, modify and create ADF documents.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -23,9 +23,7 @@
|
|
|
23
23
|
"sideEffects": false,
|
|
24
24
|
"atlaskit:src": "src/index.ts",
|
|
25
25
|
"atlassian": {
|
|
26
|
-
"team": "Editor: ADF"
|
|
27
|
-
"inPublicMirror": true,
|
|
28
|
-
"releaseModel": "continuous"
|
|
26
|
+
"team": "Editor: ADF"
|
|
29
27
|
},
|
|
30
28
|
"af:exports": {
|
|
31
29
|
"./builders": "./src/builders.ts",
|
|
@@ -38,7 +36,7 @@
|
|
|
38
36
|
"./validatorTypes": "./src/types/validatorTypes.ts"
|
|
39
37
|
},
|
|
40
38
|
"dependencies": {
|
|
41
|
-
"@atlaskit/adf-schema": "^
|
|
39
|
+
"@atlaskit/adf-schema": "^42.0.2",
|
|
42
40
|
"@atlaskit/codemod-utils": "^4.2.0",
|
|
43
41
|
"@babel/runtime": "^7.0.0"
|
|
44
42
|
},
|