@financial-times/content-tree 0.6.0 → 0.8.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/SPEC.md CHANGED
@@ -336,6 +336,7 @@ type StoryBlock =
336
336
  | Video
337
337
  | YoutubeVideo
338
338
  | VimeoVideo
339
+ | AcastPodcast
339
340
  | Timeline
340
341
  | ImagePair
341
342
  | InNumbers
@@ -526,7 +527,7 @@ interface Tweet extends Node {
526
527
  }
527
528
  ```
528
529
 
529
- **Tweet** represents a tweet.
530
+ **Tweet** represents a tweet. Rather than embedding the tweet directly in an article, we typically fetch and cache the HTML server-side to avoid the client-side dependencies.
530
531
 
531
532
  ### `Flourish`
532
533
 
@@ -599,6 +600,20 @@ interface VimeoVideo extends Node {
599
600
 
600
601
  _Note: this is currently only used by Specialist Titles_
601
602
 
603
+ ### `AcastPodcast`
604
+
605
+ ```ts
606
+ interface AcastPodcast extends Node {
607
+ type: "acast-podcast"
608
+ /** Acast Podcast embed url e.g. https://embed.acast.com/* */
609
+ url: string
610
+ }
611
+ ```
612
+
613
+ **AcastPodcast** represents an audio embed from Acast referenced by an Acast embed URL.
614
+
615
+ _Note: this is currently only used by Specialist Titles_
616
+
602
617
  ### `ClipSet`
603
618
  ```ts
604
619
  interface ClipSet extends Node {
package/content-tree.d.ts CHANGED
@@ -87,7 +87,7 @@ export declare namespace ContentTree {
87
87
  type: "blockquote";
88
88
  children: (Paragraph | Phrasing)[];
89
89
  }
90
- type StoryBlock = ImageSet | Flourish | BigNumber | CustomCodeComponent | Layout | Pullquote | ScrollyBlock | ClipSet | Table | Recommended | RecommendedList | Tweet | Video | YoutubeVideo | VimeoVideo | Timeline | ImagePair | InNumbers | Definition | InfoBox | InfoPair;
90
+ type StoryBlock = ImageSet | Flourish | BigNumber | CustomCodeComponent | Layout | Pullquote | ScrollyBlock | ClipSet | Table | Recommended | RecommendedList | Tweet | Video | YoutubeVideo | VimeoVideo | AcastPodcast | Timeline | ImagePair | InNumbers | Definition | InfoBox | InfoPair;
91
91
  interface Pullquote extends Node {
92
92
  type: "pullquote";
93
93
  text: string;
@@ -205,6 +205,11 @@ export declare namespace ContentTree {
205
205
  /** Vimeo embed URL e.g. https://player.vimeo.com/player/<id> or https://vimeo.com/<id>*/
206
206
  url: string;
207
207
  }
208
+ interface AcastPodcast extends Node {
209
+ type: "acast-podcast";
210
+ /** Acast Podcast embed url e.g. https://embed.acast.com/* */
211
+ url: string;
212
+ }
208
213
  interface ClipSet extends Node {
209
214
  type: "clip-set";
210
215
  id: string;
@@ -510,7 +515,7 @@ export declare namespace ContentTree {
510
515
  type: "blockquote";
511
516
  children: (Paragraph | Phrasing)[];
512
517
  }
513
- type StoryBlock = ImageSet | Flourish | BigNumber | CustomCodeComponent | Layout | Pullquote | ScrollyBlock | ClipSet | Table | Recommended | RecommendedList | Tweet | Video | YoutubeVideo | VimeoVideo | Timeline | ImagePair | InNumbers | Definition | InfoBox | InfoPair;
518
+ type StoryBlock = ImageSet | Flourish | BigNumber | CustomCodeComponent | Layout | Pullquote | ScrollyBlock | ClipSet | Table | Recommended | RecommendedList | Tweet | Video | YoutubeVideo | VimeoVideo | AcastPodcast | Timeline | ImagePair | InNumbers | Definition | InfoBox | InfoPair;
514
519
  interface Pullquote extends Node {
515
520
  type: "pullquote";
516
521
  text: string;
@@ -628,6 +633,11 @@ export declare namespace ContentTree {
628
633
  /** Vimeo embed URL e.g. https://player.vimeo.com/player/<id> or https://vimeo.com/<id>*/
629
634
  url: string;
630
635
  }
636
+ interface AcastPodcast extends Node {
637
+ type: "acast-podcast";
638
+ /** Acast Podcast embed url e.g. https://embed.acast.com/* */
639
+ url: string;
640
+ }
631
641
  interface ClipSet extends Node {
632
642
  type: "clip-set";
633
643
  id: string;
@@ -934,7 +944,7 @@ export declare namespace ContentTree {
934
944
  type: "blockquote";
935
945
  children: (Paragraph | Phrasing)[];
936
946
  }
937
- type StoryBlock = ImageSet | Flourish | BigNumber | CustomCodeComponent | Layout | Pullquote | ScrollyBlock | ClipSet | Table | Recommended | RecommendedList | Tweet | Video | YoutubeVideo | VimeoVideo | Timeline | ImagePair | InNumbers | Definition | InfoBox | InfoPair;
947
+ type StoryBlock = ImageSet | Flourish | BigNumber | CustomCodeComponent | Layout | Pullquote | ScrollyBlock | ClipSet | Table | Recommended | RecommendedList | Tweet | Video | YoutubeVideo | VimeoVideo | AcastPodcast | Timeline | ImagePair | InNumbers | Definition | InfoBox | InfoPair;
938
948
  interface Pullquote extends Node {
939
949
  type: "pullquote";
940
950
  text: string;
@@ -1047,6 +1057,11 @@ export declare namespace ContentTree {
1047
1057
  /** Vimeo embed URL e.g. https://player.vimeo.com/player/<id> or https://vimeo.com/<id>*/
1048
1058
  url: string;
1049
1059
  }
1060
+ interface AcastPodcast extends Node {
1061
+ type: "acast-podcast";
1062
+ /** Acast Podcast embed url e.g. https://embed.acast.com/* */
1063
+ url: string;
1064
+ }
1050
1065
  interface ClipSet extends Node {
1051
1066
  type: "clip-set";
1052
1067
  id: string;
@@ -1331,7 +1346,7 @@ export declare namespace ContentTree {
1331
1346
  type: "blockquote";
1332
1347
  children: (Paragraph | Phrasing)[];
1333
1348
  }
1334
- type StoryBlock = ImageSet | Flourish | BigNumber | CustomCodeComponent | Layout | Pullquote | ScrollyBlock | ClipSet | Table | Recommended | RecommendedList | Tweet | Video | YoutubeVideo | VimeoVideo | Timeline | ImagePair | InNumbers | Definition | InfoBox | InfoPair;
1349
+ type StoryBlock = ImageSet | Flourish | BigNumber | CustomCodeComponent | Layout | Pullquote | ScrollyBlock | ClipSet | Table | Recommended | RecommendedList | Tweet | Video | YoutubeVideo | VimeoVideo | AcastPodcast | Timeline | ImagePair | InNumbers | Definition | InfoBox | InfoPair;
1335
1350
  interface Pullquote extends Node {
1336
1351
  type: "pullquote";
1337
1352
  text: string;
@@ -1449,6 +1464,11 @@ export declare namespace ContentTree {
1449
1464
  /** Vimeo embed URL e.g. https://player.vimeo.com/player/<id> or https://vimeo.com/<id>*/
1450
1465
  url: string;
1451
1466
  }
1467
+ interface AcastPodcast extends Node {
1468
+ type: "acast-podcast";
1469
+ /** Acast Podcast embed url e.g. https://embed.acast.com/* */
1470
+ url: string;
1471
+ }
1452
1472
  interface ClipSet extends Node {
1453
1473
  type: "clip-set";
1454
1474
  id: string;
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.6.0",
4
+ "version": "0.8.0",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -2,6 +2,25 @@
2
2
  "$schema": "http://json-schema.org/draft-07/schema#",
3
3
  "additionalProperties": false,
4
4
  "definitions": {
5
+ "ContentTree.transit.AcastPodcast": {
6
+ "additionalProperties": false,
7
+ "properties": {
8
+ "data": {},
9
+ "type": {
10
+ "const": "acast-podcast",
11
+ "type": "string"
12
+ },
13
+ "url": {
14
+ "description": "Acast Podcast embed url e.g. https://embed.acast.com/*",
15
+ "type": "string"
16
+ }
17
+ },
18
+ "required": [
19
+ "type",
20
+ "url"
21
+ ],
22
+ "type": "object"
23
+ },
5
24
  "ContentTree.transit.BigNumber": {
6
25
  "additionalProperties": false,
7
26
  "properties": {
@@ -135,6 +154,9 @@
135
154
  {
136
155
  "$ref": "#/definitions/ContentTree.transit.VimeoVideo"
137
156
  },
157
+ {
158
+ "$ref": "#/definitions/ContentTree.transit.AcastPodcast"
159
+ },
138
160
  {
139
161
  "$ref": "#/definitions/ContentTree.transit.Timeline"
140
162
  },
@@ -2,6 +2,25 @@
2
2
  "$schema": "http://json-schema.org/draft-07/schema#",
3
3
  "additionalProperties": false,
4
4
  "definitions": {
5
+ "ContentTree.full.AcastPodcast": {
6
+ "additionalProperties": false,
7
+ "properties": {
8
+ "data": {},
9
+ "type": {
10
+ "const": "acast-podcast",
11
+ "type": "string"
12
+ },
13
+ "url": {
14
+ "description": "Acast Podcast embed url e.g. https://embed.acast.com/*",
15
+ "type": "string"
16
+ }
17
+ },
18
+ "required": [
19
+ "type",
20
+ "url"
21
+ ],
22
+ "type": "object"
23
+ },
5
24
  "ContentTree.full.AssetFormat": {
6
25
  "enum": [
7
26
  "desktop",
@@ -172,6 +191,9 @@
172
191
  {
173
192
  "$ref": "#/definitions/ContentTree.full.VimeoVideo"
174
193
  },
194
+ {
195
+ "$ref": "#/definitions/ContentTree.full.AcastPodcast"
196
+ },
175
197
  {
176
198
  "$ref": "#/definitions/ContentTree.full.Timeline"
177
199
  },
@@ -2,6 +2,25 @@
2
2
  "$schema": "http://json-schema.org/draft-07/schema#",
3
3
  "additionalProperties": false,
4
4
  "definitions": {
5
+ "ContentTree.transit.AcastPodcast": {
6
+ "additionalProperties": false,
7
+ "properties": {
8
+ "data": {},
9
+ "type": {
10
+ "const": "acast-podcast",
11
+ "type": "string"
12
+ },
13
+ "url": {
14
+ "description": "Acast Podcast embed url e.g. https://embed.acast.com/*",
15
+ "type": "string"
16
+ }
17
+ },
18
+ "required": [
19
+ "type",
20
+ "url"
21
+ ],
22
+ "type": "object"
23
+ },
5
24
  "ContentTree.transit.BigNumber": {
6
25
  "additionalProperties": false,
7
26
  "properties": {
@@ -160,6 +179,9 @@
160
179
  {
161
180
  "$ref": "#/definitions/ContentTree.transit.VimeoVideo"
162
181
  },
182
+ {
183
+ "$ref": "#/definitions/ContentTree.transit.AcastPodcast"
184
+ },
163
185
  {
164
186
  "$ref": "#/definitions/ContentTree.transit.Timeline"
165
187
  },