@atlaskit/adf-schema 25.10.0 → 26.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.
Files changed (41) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/cjs/index.js +18 -0
  3. package/dist/cjs/schema/default-schema.js +2 -1
  4. package/dist/cjs/schema/index.js +18 -0
  5. package/dist/cjs/schema/nodes/block-card.js +2 -2
  6. package/dist/cjs/schema/nodes/index.js +18 -0
  7. package/dist/cjs/schema/nodes/media-single.js +69 -23
  8. package/dist/cjs/version.json +1 -1
  9. package/dist/es2019/index.js +1 -1
  10. package/dist/es2019/schema/create-schema.js +1 -1
  11. package/dist/es2019/schema/default-schema.js +3 -2
  12. package/dist/es2019/schema/index.js +1 -1
  13. package/dist/es2019/schema/nodes/block-card.js +2 -2
  14. package/dist/es2019/schema/nodes/index.js +1 -1
  15. package/dist/es2019/schema/nodes/media-single.js +69 -21
  16. package/dist/es2019/version.json +1 -1
  17. package/dist/esm/index.js +1 -1
  18. package/dist/esm/schema/create-schema.js +1 -1
  19. package/dist/esm/schema/default-schema.js +3 -2
  20. package/dist/esm/schema/index.js +1 -1
  21. package/dist/esm/schema/nodes/block-card.js +2 -2
  22. package/dist/esm/schema/nodes/index.js +1 -1
  23. package/dist/esm/schema/nodes/media-single.js +65 -22
  24. package/dist/esm/version.json +1 -1
  25. package/dist/json-schema/v1/stage-0.json +82 -42
  26. package/dist/types/index.d.ts +2 -2
  27. package/dist/types/schema/index.d.ts +2 -2
  28. package/dist/types/schema/nodes/block-card.d.ts +1 -1
  29. package/dist/types/schema/nodes/index.d.ts +2 -2
  30. package/dist/types/schema/nodes/media-single.d.ts +10 -4
  31. package/dist/types/schema/nodes/types/rich-media-common.d.ts +21 -0
  32. package/dist/types-ts4.5/index.d.ts +2 -2
  33. package/dist/types-ts4.5/schema/index.d.ts +2 -2
  34. package/dist/types-ts4.5/schema/nodes/block-card.d.ts +1 -1
  35. package/dist/types-ts4.5/schema/nodes/index.d.ts +2 -2
  36. package/dist/types-ts4.5/schema/nodes/media-single.d.ts +10 -4
  37. package/dist/types-ts4.5/schema/nodes/types/rich-media-common.d.ts +21 -0
  38. package/json-schema/v1/stage-0.json +82 -42
  39. package/package.json +2 -2
  40. package/report.api.md +36 -1
  41. package/tmp/api-report-tmp.d.ts +31 -1
package/report.api.md CHANGED
@@ -495,6 +495,11 @@ export interface DecisionListDefinition {
495
495
  // @public (undocumented)
496
496
  export const decisionListSelector: string;
497
497
 
498
+ // @public (undocumented)
499
+ interface DefaultMediaAttributes extends RichMediaAttributes {
500
+ widthType?: 'percentage';
501
+ }
502
+
498
503
  // @public (undocumented)
499
504
  export const doc: NodeSpec;
500
505
 
@@ -596,6 +601,11 @@ export const expandToJSON: (node: Node_2) => {
596
601
  type ExpandWithBreakoutDefinition = ExpandBaseDefinition &
597
602
  MarksObject<BreakoutMarkDefinition>;
598
603
 
604
+ // @public (undocumented)
605
+ export type ExtendedMediaAttributes =
606
+ | DefaultMediaAttributes
607
+ | FixedLayoutMediaAttributes;
608
+
599
609
  // @public (undocumented)
600
610
  export const extension: NodeSpec;
601
611
 
@@ -648,6 +658,16 @@ export interface ExternalMediaAttributes {
648
658
  width?: number;
649
659
  }
650
660
 
661
+ // @public
662
+ interface FixedLayoutMediaAttributes {
663
+ // (undocumented)
664
+ layout: RichMediaLayout;
665
+ // (undocumented)
666
+ width: number;
667
+ // (undocumented)
668
+ widthType: 'pixel';
669
+ }
670
+
651
671
  // @public (undocumented)
652
672
  export const fragment: MarkSpec;
653
673
 
@@ -1114,7 +1134,7 @@ export const mediaSingle: NodeSpec;
1114
1134
  // @public
1115
1135
  interface MediaSingleBaseDefinition {
1116
1136
  // (undocumented)
1117
- attrs?: RichMediaAttributes;
1137
+ attrs?: ExtendedMediaAttributes;
1118
1138
  // (undocumented)
1119
1139
  marks?: Array<LinkDefinition>;
1120
1140
  // (undocumented)
@@ -1126,6 +1146,9 @@ export type MediaSingleDefinition =
1126
1146
  | MediaSingleFullDefinition
1127
1147
  | MediaSingleWithCaptionDefinition;
1128
1148
 
1149
+ // @public (undocumented)
1150
+ export const mediaSingleFull: NodeSpec;
1151
+
1129
1152
  // @public
1130
1153
  interface MediaSingleFullContent {
1131
1154
  content: Array<MediaDefinition>;
@@ -1135,6 +1158,15 @@ interface MediaSingleFullContent {
1135
1158
  type MediaSingleFullDefinition = MediaSingleBaseDefinition &
1136
1159
  MediaSingleFullContent;
1137
1160
 
1161
+ // @public (undocumented)
1162
+ export const mediaSingleSpec: ({
1163
+ withCaption,
1164
+ withExtendedWidthTypes,
1165
+ }: {
1166
+ withCaption?: boolean | undefined;
1167
+ withExtendedWidthTypes?: boolean | undefined;
1168
+ }) => NodeSpec;
1169
+
1138
1170
  // @public (undocumented)
1139
1171
  export const mediaSingleToJSON: (node: Node_2) => {
1140
1172
  attrs: any;
@@ -1147,6 +1179,9 @@ export const mediaSingleWithCaption: NodeSpec;
1147
1179
  type MediaSingleWithCaptionDefinition = MediaSingleBaseDefinition &
1148
1180
  MediaCaptionContent;
1149
1181
 
1182
+ // @public (undocumented)
1183
+ export const mediaSingleWithWidthType: NodeSpec;
1184
+
1150
1185
  // @public (undocumented)
1151
1186
  export const mediaToJSON: (node: Node_2) => {
1152
1187
  attrs: Record<string, any>;
@@ -441,6 +441,11 @@ export interface DecisionListDefinition {
441
441
  // @public (undocumented)
442
442
  export const decisionListSelector: string;
443
443
 
444
+ // @public (undocumented)
445
+ interface DefaultMediaAttributes extends RichMediaAttributes {
446
+ widthType?: 'percentage';
447
+ }
448
+
444
449
  // @public (undocumented)
445
450
  export const doc: NodeSpec;
446
451
 
@@ -535,6 +540,9 @@ export const expandToJSON: (node: Node_2) => {
535
540
  // @public
536
541
  type ExpandWithBreakoutDefinition = ExpandBaseDefinition & MarksObject<BreakoutMarkDefinition>;
537
542
 
543
+ // @public (undocumented)
544
+ export type ExtendedMediaAttributes = DefaultMediaAttributes | FixedLayoutMediaAttributes;
545
+
538
546
  // @public (undocumented)
539
547
  export const extension: NodeSpec;
540
548
 
@@ -586,6 +594,16 @@ export interface ExternalMediaAttributes {
586
594
  width?: number;
587
595
  }
588
596
 
597
+ // @public
598
+ interface FixedLayoutMediaAttributes {
599
+ // (undocumented)
600
+ layout: RichMediaLayout;
601
+ // (undocumented)
602
+ width: number;
603
+ // (undocumented)
604
+ widthType: 'pixel';
605
+ }
606
+
589
607
  // @public (undocumented)
590
608
  export const fragment: MarkSpec;
591
609
 
@@ -1011,7 +1029,7 @@ export const mediaSingle: NodeSpec;
1011
1029
  // @public
1012
1030
  interface MediaSingleBaseDefinition {
1013
1031
  // (undocumented)
1014
- attrs?: RichMediaAttributes;
1032
+ attrs?: ExtendedMediaAttributes;
1015
1033
  // (undocumented)
1016
1034
  marks?: Array<LinkDefinition>;
1017
1035
  // (undocumented)
@@ -1021,6 +1039,9 @@ interface MediaSingleBaseDefinition {
1021
1039
  // @public (undocumented)
1022
1040
  export type MediaSingleDefinition = MediaSingleFullDefinition | MediaSingleWithCaptionDefinition;
1023
1041
 
1042
+ // @public (undocumented)
1043
+ export const mediaSingleFull: NodeSpec;
1044
+
1024
1045
  // @public
1025
1046
  interface MediaSingleFullContent {
1026
1047
  content: Array<MediaDefinition>;
@@ -1029,6 +1050,12 @@ interface MediaSingleFullContent {
1029
1050
  // @public
1030
1051
  type MediaSingleFullDefinition = MediaSingleBaseDefinition & MediaSingleFullContent;
1031
1052
 
1053
+ // @public (undocumented)
1054
+ export const mediaSingleSpec: ({ withCaption, withExtendedWidthTypes, }: {
1055
+ withCaption?: boolean | undefined;
1056
+ withExtendedWidthTypes?: boolean | undefined;
1057
+ }) => NodeSpec;
1058
+
1032
1059
  // @public (undocumented)
1033
1060
  export const mediaSingleToJSON: (node: Node_2) => {
1034
1061
  attrs: any;
@@ -1040,6 +1067,9 @@ export const mediaSingleWithCaption: NodeSpec;
1040
1067
  // @public
1041
1068
  type MediaSingleWithCaptionDefinition = MediaSingleBaseDefinition & MediaCaptionContent;
1042
1069
 
1070
+ // @public (undocumented)
1071
+ export const mediaSingleWithWidthType: NodeSpec;
1072
+
1043
1073
  // @public (undocumented)
1044
1074
  export const mediaToJSON: (node: Node_2) => {
1045
1075
  attrs: Record<string, any>;