Live Countdown Sync
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.
LiveCountdownSync
import { LiveCountdownSync } from '@gxp-dev/app-ui'
Props
| Name | Type | Required / default | Description |
|---|---|---|---|
endAt | string | Required | ISO timestamp (e.g. '2026-05-11T12:34:56Z') of when the countdown should hit zero. |
durationSeconds | number | undefined | 30 | Original duration in seconds, used for the progress bar's denominator. |
showProgress | boolean | undefined | true | — |
warningThreshold | number | undefined | 10 | Seconds remaining at which the warning severity kicks in. |
dangerThreshold | number | undefined | 5 | Seconds remaining at which the danger severity kicks in. |
hideIcon | boolean | undefined | false | Hide the default clock icon. |
Events
| Name | Type | Required / default | Description |
|---|---|---|---|
tick | [remainingSeconds: number] | — | — |
warning | [remainingSeconds: number] | — | — |
danger | [remainingSeconds: number] | — | — |
expired | [] | — | — |
Slots
| Name | Type | Required / default | Description |
|---|---|---|---|
icon | { severity: LiveCountdownSyncSeverity; } | — | — |
time | { remainingSeconds: number; severity: LiveCountdownSyncSeverity; } | — | — |
progress | { percent: number; severity: LiveCountdownSyncSeverity; remainingSeconds: number; } | — | — |
Exposed methods and values
| Name | Type | Required / default | Description |
|---|---|---|---|
remainingSeconds | number | — | — |
startTimer | () => void | — | — |
stopTimer | () => void | — | — |
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 LiveCountdownSync from './LiveCountdownSync.vue'
{
args: {
endAt: inFuture(60),
durationSeconds: 60,
warningThreshold: 10,
dangerThreshold: 5,
showProgress: true,
},
render,
}
WarningState
import type { Meta, StoryObj } from '@storybook/vue3-vite'
import LiveCountdownSync from './LiveCountdownSync.vue'
{
args: {
endAt: inFuture(15),
durationSeconds: 60,
warningThreshold: 20,
dangerThreshold: 5,
},
render,
}
DangerState
import type { Meta, StoryObj } from '@storybook/vue3-vite'
import LiveCountdownSync from './LiveCountdownSync.vue'
{
args: {
endAt: inFuture(4),
durationSeconds: 60,
warningThreshold: 20,
dangerThreshold: 5,
},
render,
}