Skip to content

Commit f793742

Browse files
committed
Add optional hub field to Newsroom type
Mirrors the additive `hub` field introduced by prezly/prezly#18567, which exposes the parent HUB and active siblings (each with `cultures`) on child-newsroom API responses so themes can render cross-site language pickers. Field is marked optional so the SDK release is not gated on backend deploy order.
1 parent 42864f9 commit f793742

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[];
146+
}
147+
143148
export enum Status {
144149
ACTIVE = 'active', // i.e. "Live"
145150
INACTIVE = 'inactive', // i.e. "Not live"

0 commit comments

Comments
 (0)