Skip to content

Sco 2704 create an api endpoint to return available stories for each - #175

Merged
timosville merged 8 commits into
mainfrom
sco-2704-create-an-api-endpoint-to-return-available-stories-for-each
Jul 23, 2026
Merged

Sco 2704 create an api endpoint to return available stories for each#175
timosville merged 8 commits into
mainfrom
sco-2704-create-an-api-endpoint-to-return-available-stories-for-each

Conversation

@timosville

Copy link
Copy Markdown
Contributor

No description provided.

@timosville
timosville requested a review from JannieT July 22, 2026 12:31
@linear-code

linear-code Bot commented Jul 22, 2026

Copy link
Copy Markdown

SCO-2704

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 22, 2026

Copy link
Copy Markdown

Deploying kit with  Cloudflare Pages  Cloudflare Pages

Latest commit: d6cb621
Status: ✅  Deploy successful!
Preview URL: https://e9b3919e.kit-atq.pages.dev
Branch Preview URL: https://sco-2704-create-an-api-endpo.kit-atq.pages.dev

View logs

const { app } = await service.storiesByLocale();

assert.deepEqual(app, [
{ locale: 'en', name: 'English', nativeName: 'English' },

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@timosville @JannieT in the app locale list we will also need a isRTL field as well.

@JannieT JannieT left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please merge when you have refactored the suggested name changes

Comment thread src/types.ts Outdated
stories: StoryIndexItem[];
}

export interface LocaleStoriesItem {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There might be other content types in the future:

Suggested change
export interface LocaleStoriesItem {
export interface LocaleContentItem {

Comment thread src/backend/services/locale_service.ts Outdated
export class LocaleService {
public constructor(protected readonly config: CmsConfig) {}

public async storiesByLocale(): Promise<LocaleStoriesResponse> {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
public async storiesByLocale(): Promise<LocaleStoriesResponse> {
public async localeIndex(): Promise<LocaleIndexResponse> {

Comment thread src/types.ts Outdated
nativeName: string;
}

export interface LocaleStoriesResponse {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a response describing the locale setup and stories is just a part of the content and configuration it reports on:

Suggested change
export interface LocaleStoriesResponse {
export interface LocaleIndexResponse {

@timosville
timosville merged commit ce99c68 into main Jul 23, 2026
5 checks passed
@timosville
timosville deleted the sco-2704-create-an-api-endpoint-to-return-available-stories-for-each branch July 23, 2026 10:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants