Skip to content

Commit afa7573

Browse files
authored
Merge pull request #404 from prezly/feature/newsroom-hub-context
Add optional `hub` field to Newsroom type
2 parents 42864f9 + 33e6a49 commit afa7573

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/types/Newsroom.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ export interface NewsroomRef {
8181

8282
export interface Newsroom extends NewsroomRef {
8383
is_hub: boolean;
84+
hub: { parent: Newsroom.HubPeer; siblings: Newsroom.HubPeer[] } | null;
8485
// extended details
8586
cultures: CultureRef[];
8687
campaigns_number: number;
@@ -140,6 +141,10 @@ export interface Newsroom extends NewsroomRef {
140141
}
141142

142143
export namespace Newsroom {
144+
export interface HubPeer extends NewsroomRef {
145+
cultures: (CultureRef & { is_default: boolean })[];
146+
}
147+
143148
export enum Status {
144149
ACTIVE = 'active', // i.e. "Live"
145150
INACTIVE = 'inactive', // i.e. "Not live"

0 commit comments

Comments
 (0)