smrt
Open the smrt source on GitHub Switch to dark color scheme
← All UI components

Reports · Components

SavedReportsWidget

The `saved-reports` overview widget: the Reports section page's default (`sectionDefault`), the team's saved reports as cards with their headline figures, "New report" (asks the page's assistant) and a hint. It reads through the shared browser client of the app's runtime-report routes; a host with its own transport (the planner's sample data) passes `client`.

Public export

typescript
import { SavedReportsWidget } from '@happyvertical/smrt-reports/svelte';
Import path
@happyvertical/smrt-reports/svelte
Props
9
Props described
9 of 9
Bindable state
0
Callback events
0
Verified release
0.62.10

Props

NameTypeRequiredDescription
optionsRecord<string, string | number | boolean | null>NoThe widget's options from the host's layout; `limit` (a positive number) caps the cards shown, default 6.
titlestringNoThe widget's heading as set in the host's layout. This widget does not render it; the host places it.
localestringNoBCP 47 locale for dates, numbers and relative times; default `en`.
clientRuntimeReportsClientNoA host-owned transport; omitted, the app's shared browser client.
reportHref(id: string) => stringNoThe page of one report by id; default `/reports/<id>`.
listHrefstringNoThe Saved reports page ("View all"); default `/reports`.
sourcesreadonly ReportSourceInfo[]NoThe report sources by label and fields (`reports.runtime.sources`), for each card's description line.
authorLabel(userId: string) => string | undefinedNoHost-owned identity projection naming who saved a report; report transport never expands users.
currencystringNoISO 4217 code that formats currency measures; default `USD`.

Bindable state

This component has no bindable public state.

Callback events

This component declares no callback event props.

Examples and explanation