| 1 |
import { AiAgentDemo } from './AiAgentDemo/AiAgentDemo' |
| 2 |
import { BlueprintsDemo } from './BlueprintsDemo/BlueprintsDemo' |
| 3 |
import { CloudLibraryDemo } from './CloudLibraryDemo/CloudLibraryDemo' |
| 4 |
import { CommunityCloud } from './CommunityCloud/CommunityCloud' |
| 5 |
import { SnippetsTable } from './SnippetsTable' |
| 6 |
import type React from 'react' |
| 7 |
|
| 8 |
export const SUBPAGES = ['snippets', 'blueprints', 'cloud-community', 'cloud-library', 'ai-agent'] as const |
| 9 |
|
| 10 |
export type SubpageName = typeof SUBPAGES[number] |
| 11 |
|
| 12 |
export interface Subpage { |
| 13 |
Component: React.FC |
| 14 |
|
| 15 |
/** |
| 16 |
* Marks a walkthrough tab. An 'announce' tab advertises itself as new until |
| 17 |
* its walkthrough has been watched, which only a tab with a recorded demo |
| 18 |
* can do; a 'quiet' tab is only ever labelled as a demo. |
| 19 |
*/ |
| 20 |
demo?: 'announce' | 'quiet' |
| 21 |
|
| 22 |
/** |
| 23 |
* Marks a premium tab, which is chipped as such without a licence. |
| 24 |
*/ |
| 25 |
isPro?: boolean |
| 26 |
} |
| 27 |
|
| 28 |
/** |
| 29 |
* What each subpage of the manage screen renders, and how its toolbar tab |
| 30 |
* advertises itself. |
| 31 |
* |
| 32 |
* The toolbar and the page body read the same entry, so a subpage is described |
| 33 |
* once here rather than being kept in step across the two. |
| 34 |
*/ |
| 35 |
export const SUBPAGE_ENTRIES: Record<SubpageName, Subpage> = { |
| 36 |
'snippets': { Component: SnippetsTable }, |
| 37 |
'blueprints': { Component: BlueprintsDemo, demo: 'announce' }, |
| 38 |
'cloud-community': { Component: CommunityCloud }, |
| 39 |
'cloud-library': { Component: CloudLibraryDemo, demo: 'quiet' }, |
| 40 |
'ai-agent': { Component: AiAgentDemo, demo: 'announce' }, |
| 41 |
} |
| 42 |
|