Month#
Calendar month example rendered by the production Go component.
days[15].Selected, days[15].Today = true, true
previous, next := tree.ID(page, "previous"), tree.ID(page, "next")
// value selects the visible month snapshot; monthTitle and days follow it.
components.BeginCalendar(canvas, theme, bounds, components.CalendarOptions{
MonthTitle: monthTitle, Weekdays: weekdays, Days: days,
PreviousID: previous, NextID: next,
}).Paint()
if canvas.Clicked(previous) {
value = -1
} else if canvas.Clicked(next) {
value = 1
}Range#
Calendar range example rendered by the production Go component.
previous, next := tree.ID(page, "previous"), tree.ID(page, "next")
days[22].RangeStart = true
days[23].RangeMiddle = true
days[24].RangeEnd = true
components.BeginCalendar(canvas, theme, bounds, components.CalendarOptions{
MonthTitle: monthTitle, Weekdays: weekdays, Days: days,
PreviousID: previous, NextID: next,
}).Paint()Installation
Copy the recipe into your own project.
go run ./cmd/viva add --out ./components/local calendarSource-owned usage#
This preview calls the production Go component directly. Stable IDs, values and open state remain owned by the application; the component only paints and declares interaction semantics.
- Read the linked component source for every option and visual decision.
- Use the native command to verify system text, focus, accessibility and platform integration.
- The browser preview validates shared layout and scene behavior, not native performance.
Verification boundary#
The examples cover representative states supported by the current API. They do not imply that every desktop backend has completed hardware validation.
Keyboard
Use Tab to move between controls and Ctrl/⌘ K to search the catalog. Inside a preview, the Go runtime handles keyboard input.