Loading
Generated from public Vue/TypeScript exports by
pnpm docs:generate. Edit source comments and stories to update this reference. Types describe the declared API; browser/device constraints are covered in the guides. This catalog reflects source commitfc6bfb108634735f1657e533206c3f8702ad357d; match your installed package and typed manifest before using an export. Source review does not establish registry-release availability.
LoadingPage
import { LoadingPage } from '@gxp-dev/app-ui'
Flow defaults: action Disabled, result key loadingResult (when data/result is produced).
Props
| Name | Type | Required / default | Description |
|---|---|---|---|
variant | LoadingVariant | undefined | 'spinner' | — |
class | string | undefined | undefined | — |
logoImage | string | undefined | undefined | — |
messages | string[] | undefined | ['Working on it…'] | — |
context | Record<string, unknown> | undefined | {} | — |
messageInterval | number | undefined | 2.5 | — |
disclaimer | string | undefined | undefined | — |
timeoutSeconds | number | undefined | 0 | — |
task | LoadingTask<unknown> | undefined | undefined | — |
Events
| Name | Type | Required / default | Description |
|---|---|---|---|
next | [result: unknown] | — | — |
error | [err: Error] | — | — |
exit | [] | — | — |
Slots
| Name | Type | Required / default | Description |
|---|---|---|---|
header | {} | — | — |
activity | {} | — | — |
footer | {} | — | — |
Examples
These are authored Storybook excerpts, not complete standalone modules. Relative imports refer to the story file; in an app import public components from @gxp-dev/app-ui. Default meta arguments are applied before each story.
Default
import type { Meta, StoryObj } from '@storybook/vue3-vite'
import LoadingPageComponent from './LoadingPage.vue'
{
args: {
logoImage: 'https://placehold.co/180x90?text=Logo',
messages: ['Posting your note…'],
disclaimer: 'Your post is being published.',
},
render: (args) => ({
components: { LoadingPage: LoadingPageComponent },
setup: () => ({ args }),
template: '<div class="h-screen w-screen"><LoadingPage v-bind="args" /></div>',
}),
}
RotatingMessages
import type { Meta, StoryObj } from '@storybook/vue3-vite'
import LoadingPageComponent from './LoadingPage.vue'
{
args: {
messages: ['Working on it…', 'Almost there…', 'Wrapping up…'],
messageInterval: 1.5,
},
render: (args) => ({
components: { LoadingPage: LoadingPageComponent },
setup: () => ({ args }),
template: '<div class="h-screen w-screen"><LoadingPage v-bind="args" /></div>',
}),
}
ActivityVariant
import type { Meta, StoryObj } from '@storybook/vue3-vite'
import LoadingPageComponent from './LoadingPage.vue'
{
args: {
variant: 'activity',
messages: ['Generating your image…'],
disclaimer: 'This can take up to a minute.',
},
render: (args) => ({
components: { LoadingPage: LoadingPageComponent },
setup: () => ({ args }),
template: `
<div class="h-screen w-screen">
<LoadingPage v-bind="args">
<template #activity>
<div class="flex h-64 w-64 items-center justify-center rounded-xl border-2 border-dashed border-border text-muted-foreground">
your mini-game here
</div>
</template>
</LoadingPage>
</div>
`,
}),
}