@thetimes/times-public-api-types 1.0.5037 → 1.0.5058

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/common.d.ts CHANGED
@@ -13,6 +13,8 @@ export declare type BigInt = number & {
13
13
  _: "Revision";
14
14
  };
15
15
  export declare type DataSource = "NEWSPRESS" | "METHODE" | null;
16
+ export declare type PageSliceType = "PAGE_SLICE" | "TOPIC_AUTHOR_SLICE" | null;
17
+ export declare type PageTileType = "ARTICLE_REFERENCE" | "TOPIC_ARTICLE_REFERENCE" | "CUSTOM_COMPONENT" | "EXTERNAL_REFERENCE" | null;
16
18
  export declare type DateTime = Date;
17
19
  export declare type Dictionary = {
18
20
  [key: string]: string;
package/index.d.ts CHANGED
@@ -21,6 +21,7 @@ export * from "./queries/layout";
21
21
  export * from "./queries/link";
22
22
  export * from "./queries/media";
23
23
  export * from "./queries/menu";
24
+ export * from "./queries/page-tile";
24
25
  export * from "./queries/page";
25
26
  export * from "./queries/puff";
26
27
  export * from "./queries/puzzle";
@@ -28,6 +29,7 @@ export * from "./queries/puzzles";
28
29
  export * from "./queries/query";
29
30
  export * from "./queries/section";
30
31
  export * from "./queries/slice";
32
+ export * from "./queries/standard-page-slice";
31
33
  export * from "./queries/synonym-connection";
32
34
  export * from "./queries/synonym";
33
35
  export * from "./queries/tag-article-connection";
@@ -61,6 +63,7 @@ export * from "./mutations/draft-tile-input";
61
63
  export * from "./mutations/edition-input";
62
64
  export * from "./mutations/edition-upsert-result";
63
65
  export * from "./mutations/page-input";
66
+ export * from "./mutations/page-tile-input";
64
67
  export * from "./mutations/page-upsert-result";
65
68
  export * from "./mutations/puff-input";
66
69
  export * from "./mutations/puzzle-input";
@@ -68,6 +71,7 @@ export * from "./mutations/section-input";
68
71
  export * from "./mutations/section-update-result";
69
72
  export * from "./mutations/slice-input";
70
73
  export * from "./mutations/slice-update-result";
74
+ export * from "./mutations/standard-page-slice-input";
71
75
  export * from "./mutations/synonym-input";
72
76
  export * from "./mutations/tag-merge-result";
73
77
  export * from "./mutations/tag-split-result";
@@ -1,9 +1,11 @@
1
1
  import { StandardSectionSliceInput } from "./section-input";
2
2
  import { URL, Slug, UUID } from "../common";
3
+ import { StandardPageSliceInput } from "./standard-page-slice-input";
3
4
  export declare type CollectionInput = {
4
5
  title: string | null;
5
6
  link: CollectionLinkInput;
6
- slices: StandardSectionSliceInput[];
7
+ slices?: StandardSectionSliceInput[] | null;
8
+ children?: StandardPageSliceInput[] | null;
7
9
  topic?: Slug | null;
8
10
  id?: UUID | null;
9
11
  };
@@ -0,0 +1,31 @@
1
+ import { Slug, UUID } from "../common";
2
+ export declare type PageTileInput = {
3
+ articleRef?: ArticleRefInput | null;
4
+ topicArticleRef?: TopicArticleRefInput | null;
5
+ customComponent?: CustomComponentInput | null;
6
+ externalRef?: ExternalRefInput | null;
7
+ };
8
+ export declare type ArticleRefInput = {
9
+ articleId: UUID;
10
+ };
11
+ export declare type TopicArticleRefInput = {
12
+ topic: Slug;
13
+ isComment: boolean;
14
+ };
15
+ export declare type CustomComponentInput = {
16
+ name: string;
17
+ url: string;
18
+ parameters?: string | null;
19
+ };
20
+ export declare type ExternalRefImageInput = {
21
+ url: string;
22
+ resizeUrl: string;
23
+ width: number;
24
+ height: number;
25
+ };
26
+ export declare type ExternalRefInput = {
27
+ headline: string;
28
+ url: string;
29
+ label?: string | null;
30
+ image?: ExternalRefImageInput | null;
31
+ };
@@ -0,0 +1,13 @@
1
+ import { Slug } from "../common";
2
+ import { PageTileInput } from "./page-tile-input";
3
+ export declare type PageSliceInput = {
4
+ name: string;
5
+ children: PageTileInput[];
6
+ };
7
+ export declare type TopicAuthorSliceInput = {
8
+ topic: Slug;
9
+ };
10
+ export declare type StandardPageSliceInput = {
11
+ pageSlice?: PageSliceInput | null;
12
+ topicAuthorSlice?: TopicAuthorSliceInput | null;
13
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thetimes/times-public-api-types",
3
- "version": "1.0.5037",
3
+ "version": "1.0.5058",
4
4
  "description": "",
5
5
  "main": "index.d.ts",
6
6
  "types": "index.d.ts",
@@ -1,8 +1,12 @@
1
+ import { UUID } from "../common";
1
2
  import { Link } from "./link";
2
3
  import { StandardSectionSlice } from "./slice";
4
+ import { StandardPageSlice } from "./standard-page-slice";
3
5
  export declare type Collection = {
4
6
  title: string | null;
5
7
  link: Link;
6
8
  slices: StandardSectionSlice[];
9
+ children: StandardPageSlice[];
7
10
  collectionId: number;
11
+ id: UUID | null;
8
12
  };
@@ -0,0 +1,21 @@
1
+ import { UUID, URL } from "../common";
2
+ import { Article } from "./article";
3
+ export declare type PageTile = ArticleReference | CustomComponent | ExternalReference;
4
+ export declare type ArticleReference = {
5
+ articleId: UUID;
6
+ article: Article;
7
+ };
8
+ export declare type CustomComponent = {
9
+ name: string;
10
+ url: string;
11
+ parameters: string;
12
+ };
13
+ export declare type ExternalReference = {
14
+ headline: string;
15
+ url: string;
16
+ label: string;
17
+ image: PageImage | null;
18
+ };
19
+ export declare type PageImage = {
20
+ url: URL;
21
+ };
@@ -0,0 +1,11 @@
1
+ import { Slug } from "../common";
2
+ import { PageTile } from "./page-tile";
3
+ export declare type StandardPageSlice = PageSlice | TopicAuthorSlice;
4
+ export declare type PageSlice = {
5
+ name: string;
6
+ children: PageTile[];
7
+ };
8
+ export declare type TopicAuthorSlice = {
9
+ topic: Slug;
10
+ articles: PageTile[];
11
+ };