@financial-times/content-tree 0.12.0-beta.3 → 0.12.0-beta.7

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/SPEC.md CHANGED
@@ -1011,10 +1011,23 @@ interface InfoPair extends Parent {
1011
1011
  #### `CarouselCard`
1012
1012
  ```ts
1013
1013
  interface CarouselCard extends Node {
1014
- type: "carousel-card"
1015
- image: ImageSet
1016
- title?: string
1017
- copy: Paragraph[]
1014
+ type: "carousel-card",
1015
+ id: "string"
1016
+ /**
1017
+ * @description Heading (60 characters recommended)
1018
+ */
1019
+ title: string
1020
+ /**
1021
+ * @description Image
1022
+ */
1023
+ children: [ImageSet]
1024
+ /**
1025
+ * @description Body text (200 characters recommended)
1026
+ */
1027
+ copy: string
1028
+ /**
1029
+ * @description Details (optional, 60 characters recommended)
1030
+ */
1018
1031
  additionalInfo?: string
1019
1032
  }
1020
1033
  ```
@@ -1023,6 +1036,7 @@ interface CarouselCard extends Node {
1023
1036
  #### `CarouselChildren`
1024
1037
  ```ts
1025
1038
  /**
1039
+ * @description Carousel item
1026
1040
  * @maxItems 10
1027
1041
  * @minItems 4
1028
1042
  * @sparkRepeater true
@@ -1044,10 +1058,11 @@ interface CarouselHeading extends Node {
1044
1058
  #### `Carousel`
1045
1059
  ```ts
1046
1060
  /**
1047
- * @sparkGenerateStoryBlock true
1061
+ * @sparkGenerateStoryblock true
1048
1062
  */
1049
1063
  interface Carousel extends Parent {
1050
1064
  type: "carousel"
1065
+ id: "string"
1051
1066
  heading?: CarouselHeading
1052
1067
  children: CarouselChildren
1053
1068
  }
package/content-tree.d.ts CHANGED
@@ -441,12 +441,26 @@ export declare namespace ContentTree {
441
441
  }
442
442
  interface CarouselCard extends Node {
443
443
  type: "carousel-card";
444
- image: ImageSet;
445
- title?: string;
446
- copy: Paragraph[];
444
+ id: "string";
445
+ /**
446
+ * @description Heading (60 characters recommended)
447
+ */
448
+ title: string;
449
+ /**
450
+ * @description Image
451
+ */
452
+ children: [ImageSet];
453
+ /**
454
+ * @description Body text (200 characters recommended)
455
+ */
456
+ copy: string;
457
+ /**
458
+ * @description Details (optional, 60 characters recommended)
459
+ */
447
460
  additionalInfo?: string;
448
461
  }
449
462
  /**
463
+ * @description Carousel item
450
464
  * @maxItems 10
451
465
  * @minItems 4
452
466
  * @sparkRepeater true
@@ -458,10 +472,11 @@ export declare namespace ContentTree {
458
472
  standfirst?: string;
459
473
  }
460
474
  /**
461
- * @sparkGenerateStoryBlock true
475
+ * @sparkGenerateStoryblock true
462
476
  */
463
477
  interface Carousel extends Parent {
464
478
  type: "carousel";
479
+ id: "string";
465
480
  heading?: CarouselHeading;
466
481
  children: CarouselChildren;
467
482
  }
@@ -908,12 +923,26 @@ export declare namespace ContentTree {
908
923
  }
909
924
  interface CarouselCard extends Node {
910
925
  type: "carousel-card";
911
- image: ImageSet;
912
- title?: string;
913
- copy: Paragraph[];
926
+ id: "string";
927
+ /**
928
+ * @description Heading (60 characters recommended)
929
+ */
930
+ title: string;
931
+ /**
932
+ * @description Image
933
+ */
934
+ children: [ImageSet];
935
+ /**
936
+ * @description Body text (200 characters recommended)
937
+ */
938
+ copy: string;
939
+ /**
940
+ * @description Details (optional, 60 characters recommended)
941
+ */
914
942
  additionalInfo?: string;
915
943
  }
916
944
  /**
945
+ * @description Carousel item
917
946
  * @maxItems 10
918
947
  * @minItems 4
919
948
  * @sparkRepeater true
@@ -925,10 +954,11 @@ export declare namespace ContentTree {
925
954
  standfirst?: string;
926
955
  }
927
956
  /**
928
- * @sparkGenerateStoryBlock true
957
+ * @sparkGenerateStoryblock true
929
958
  */
930
959
  interface Carousel extends Parent {
931
960
  type: "carousel";
961
+ id: "string";
932
962
  heading?: CarouselHeading;
933
963
  children: CarouselChildren;
934
964
  }
@@ -1349,12 +1379,26 @@ export declare namespace ContentTree {
1349
1379
  }
1350
1380
  interface CarouselCard extends Node {
1351
1381
  type: "carousel-card";
1352
- image: ImageSet;
1353
- title?: string;
1354
- copy: Paragraph[];
1382
+ id: "string";
1383
+ /**
1384
+ * @description Heading (60 characters recommended)
1385
+ */
1386
+ title: string;
1387
+ /**
1388
+ * @description Image
1389
+ */
1390
+ children: [ImageSet];
1391
+ /**
1392
+ * @description Body text (200 characters recommended)
1393
+ */
1394
+ copy: string;
1395
+ /**
1396
+ * @description Details (optional, 60 characters recommended)
1397
+ */
1355
1398
  additionalInfo?: string;
1356
1399
  }
1357
1400
  /**
1401
+ * @description Carousel item
1358
1402
  * @maxItems 10
1359
1403
  * @minItems 4
1360
1404
  * @sparkRepeater true
@@ -1366,10 +1410,11 @@ export declare namespace ContentTree {
1366
1410
  standfirst?: string;
1367
1411
  }
1368
1412
  /**
1369
- * @sparkGenerateStoryBlock true
1413
+ * @sparkGenerateStoryblock true
1370
1414
  */
1371
1415
  interface Carousel extends Parent {
1372
1416
  type: "carousel";
1417
+ id: "string";
1373
1418
  heading?: CarouselHeading;
1374
1419
  children: CarouselChildren;
1375
1420
  }
@@ -1817,12 +1862,26 @@ export declare namespace ContentTree {
1817
1862
  }
1818
1863
  interface CarouselCard extends Node {
1819
1864
  type: "carousel-card";
1820
- image: ImageSet;
1821
- title?: string;
1822
- copy: Paragraph[];
1865
+ id: "string";
1866
+ /**
1867
+ * @description Heading (60 characters recommended)
1868
+ */
1869
+ title: string;
1870
+ /**
1871
+ * @description Image
1872
+ */
1873
+ children: [ImageSet];
1874
+ /**
1875
+ * @description Body text (200 characters recommended)
1876
+ */
1877
+ copy: string;
1878
+ /**
1879
+ * @description Details (optional, 60 characters recommended)
1880
+ */
1823
1881
  additionalInfo?: string;
1824
1882
  }
1825
1883
  /**
1884
+ * @description Carousel item
1826
1885
  * @maxItems 10
1827
1886
  * @minItems 4
1828
1887
  * @sparkRepeater true
@@ -1834,10 +1893,11 @@ export declare namespace ContentTree {
1834
1893
  standfirst?: string;
1835
1894
  }
1836
1895
  /**
1837
- * @sparkGenerateStoryBlock true
1896
+ * @sparkGenerateStoryblock true
1838
1897
  */
1839
1898
  interface Carousel extends Parent {
1840
1899
  type: "carousel";
1900
+ id: "string";
1841
1901
  heading?: CarouselHeading;
1842
1902
  children: CarouselChildren;
1843
1903
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@financial-times/content-tree",
3
3
  "description": "content tree format",
4
- "version": "0.12.0-beta.3",
4
+ "version": "0.12.0-beta.7",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -253,6 +253,7 @@
253
253
  "additionalProperties": false,
254
254
  "properties": {
255
255
  "children": {
256
+ "description": "Carousel item",
256
257
  "items": {
257
258
  "$ref": "#/definitions/ContentTree.transit.CarouselCard"
258
259
  },
@@ -265,6 +266,10 @@
265
266
  "heading": {
266
267
  "$ref": "#/definitions/ContentTree.transit.CarouselHeading"
267
268
  },
269
+ "id": {
270
+ "const": "string",
271
+ "type": "string"
272
+ },
268
273
  "type": {
269
274
  "const": "carousel",
270
275
  "type": "string"
@@ -272,27 +277,41 @@
272
277
  },
273
278
  "required": [
274
279
  "children",
280
+ "id",
275
281
  "type"
276
282
  ],
283
+ "sparkGenerateStoryblock": true,
277
284
  "type": "object"
278
285
  },
279
286
  "ContentTree.transit.CarouselCard": {
280
287
  "additionalProperties": false,
281
288
  "properties": {
282
289
  "additionalInfo": {
290
+ "description": "Details (optional, 60 characters recommended)",
283
291
  "type": "string"
284
292
  },
285
- "copy": {
286
- "items": {
287
- "$ref": "#/definitions/ContentTree.transit.Paragraph"
288
- },
293
+ "children": {
294
+ "description": "Image",
295
+ "items": [
296
+ {
297
+ "$ref": "#/definitions/ContentTree.transit.ImageSet"
298
+ }
299
+ ],
300
+ "maxItems": 1,
301
+ "minItems": 1,
289
302
  "type": "array"
290
303
  },
304
+ "copy": {
305
+ "description": "Body text (200 characters recommended)",
306
+ "type": "string"
307
+ },
291
308
  "data": {},
292
- "image": {
293
- "$ref": "#/definitions/ContentTree.transit.ImageSet"
309
+ "id": {
310
+ "const": "string",
311
+ "type": "string"
294
312
  },
295
313
  "title": {
314
+ "description": "Heading (60 characters recommended)",
296
315
  "type": "string"
297
316
  },
298
317
  "type": {
@@ -301,8 +320,10 @@
301
320
  }
302
321
  },
303
322
  "required": [
323
+ "children",
304
324
  "copy",
305
- "image",
325
+ "id",
326
+ "title",
306
327
  "type"
307
328
  ],
308
329
  "type": "object"
@@ -290,6 +290,7 @@
290
290
  "additionalProperties": false,
291
291
  "properties": {
292
292
  "children": {
293
+ "description": "Carousel item",
293
294
  "items": {
294
295
  "$ref": "#/definitions/ContentTree.full.CarouselCard"
295
296
  },
@@ -301,6 +302,10 @@
301
302
  "heading": {
302
303
  "$ref": "#/definitions/ContentTree.full.CarouselHeading"
303
304
  },
305
+ "id": {
306
+ "const": "string",
307
+ "type": "string"
308
+ },
304
309
  "type": {
305
310
  "const": "carousel",
306
311
  "type": "string"
@@ -308,6 +313,7 @@
308
313
  },
309
314
  "required": [
310
315
  "children",
316
+ "id",
311
317
  "type"
312
318
  ],
313
319
  "type": "object"
@@ -316,19 +322,31 @@
316
322
  "additionalProperties": false,
317
323
  "properties": {
318
324
  "additionalInfo": {
325
+ "description": "Details (optional, 60 characters recommended)",
319
326
  "type": "string"
320
327
  },
321
- "copy": {
322
- "items": {
323
- "$ref": "#/definitions/ContentTree.full.Paragraph"
324
- },
328
+ "children": {
329
+ "description": "Image",
330
+ "items": [
331
+ {
332
+ "$ref": "#/definitions/ContentTree.full.ImageSet"
333
+ }
334
+ ],
335
+ "maxItems": 1,
336
+ "minItems": 1,
325
337
  "type": "array"
326
338
  },
339
+ "copy": {
340
+ "description": "Body text (200 characters recommended)",
341
+ "type": "string"
342
+ },
327
343
  "data": {},
328
- "image": {
329
- "$ref": "#/definitions/ContentTree.full.ImageSet"
344
+ "id": {
345
+ "const": "string",
346
+ "type": "string"
330
347
  },
331
348
  "title": {
349
+ "description": "Heading (60 characters recommended)",
332
350
  "type": "string"
333
351
  },
334
352
  "type": {
@@ -337,8 +355,10 @@
337
355
  }
338
356
  },
339
357
  "required": [
358
+ "children",
340
359
  "copy",
341
- "image",
360
+ "id",
361
+ "title",
342
362
  "type"
343
363
  ],
344
364
  "type": "object"
@@ -278,6 +278,7 @@
278
278
  "additionalProperties": false,
279
279
  "properties": {
280
280
  "children": {
281
+ "description": "Carousel item",
281
282
  "items": {
282
283
  "$ref": "#/definitions/ContentTree.transit.CarouselCard"
283
284
  },
@@ -289,6 +290,10 @@
289
290
  "heading": {
290
291
  "$ref": "#/definitions/ContentTree.transit.CarouselHeading"
291
292
  },
293
+ "id": {
294
+ "const": "string",
295
+ "type": "string"
296
+ },
292
297
  "type": {
293
298
  "const": "carousel",
294
299
  "type": "string"
@@ -296,6 +301,7 @@
296
301
  },
297
302
  "required": [
298
303
  "children",
304
+ "id",
299
305
  "type"
300
306
  ],
301
307
  "type": "object"
@@ -304,19 +310,31 @@
304
310
  "additionalProperties": false,
305
311
  "properties": {
306
312
  "additionalInfo": {
313
+ "description": "Details (optional, 60 characters recommended)",
307
314
  "type": "string"
308
315
  },
309
- "copy": {
310
- "items": {
311
- "$ref": "#/definitions/ContentTree.transit.Paragraph"
312
- },
316
+ "children": {
317
+ "description": "Image",
318
+ "items": [
319
+ {
320
+ "$ref": "#/definitions/ContentTree.transit.ImageSet"
321
+ }
322
+ ],
323
+ "maxItems": 1,
324
+ "minItems": 1,
313
325
  "type": "array"
314
326
  },
327
+ "copy": {
328
+ "description": "Body text (200 characters recommended)",
329
+ "type": "string"
330
+ },
315
331
  "data": {},
316
- "image": {
317
- "$ref": "#/definitions/ContentTree.transit.ImageSet"
332
+ "id": {
333
+ "const": "string",
334
+ "type": "string"
318
335
  },
319
336
  "title": {
337
+ "description": "Heading (60 characters recommended)",
320
338
  "type": "string"
321
339
  },
322
340
  "type": {
@@ -325,8 +343,10 @@
325
343
  }
326
344
  },
327
345
  "required": [
346
+ "children",
328
347
  "copy",
329
- "image",
348
+ "id",
349
+ "title",
330
350
  "type"
331
351
  ],
332
352
  "type": "object"