From 45e0b7652552867f7f99ffe22c968641510d5143 Mon Sep 17 00:00:00 2001 From: Lukasz Kasprzak Date: Mon, 27 Jul 2026 21:25:43 +0200 Subject: feat(calfeed): day wire model + JSON renderer --- internal/calfeed/calfeed.go | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 internal/calfeed/calfeed.go (limited to 'internal/calfeed/calfeed.go') diff --git a/internal/calfeed/calfeed.go b/internal/calfeed/calfeed.go new file mode 100644 index 0000000..cb2a8ff --- /dev/null +++ b/internal/calfeed/calfeed.go @@ -0,0 +1,30 @@ +package calfeed + +type ReadingView struct { + Part string `json:"part"` + Citation string `json:"citation"` +} + +type CelView struct { + Slug string `json:"slug"` + Name string `json:"name"` + Rank string `json:"rank"` + Class int `json:"class"` +} + +type DayView struct { + Date string `json:"date"` // YYYY-MM-DD + Season string `json:"season"` + Week int `json:"week"` + Weekday string `json:"weekday"` + Colour string `json:"colour"` + Observed CelView `json:"observed"` + Others []CelView `json:"others"` + Cycles Cycles `json:"cycles"` + Readings []ReadingView `json:"readings"` +} + +type Cycles struct { + Sunday string `json:"sunday"` + Weekday string `json:"weekday"` +} -- cgit v1.3