// Data the Rust side fills in. Every page is a list of Lines (src/page.rs); // all lengths here are design px (1920x1080 grid), multiplied by Tv.u. // A button / choice / text field on a line. x, y relative to the line. export struct Chip { id: string, text: string, icon: string, x: float, y: float, w: float, h: float, // Selected (a choice, the current tab). active: bool, // "" | "primary" (accent glass) | "include" | "exclude" | "danger" | "field" (text field) tone: string, enabled: bool, } // A card in a cards line. export struct Card { id: string, title: string, // Under the card (cards lines with captions). caption: string, detail: string, image: image, // 0..1 watched; negative = no bar. progress: float, // Small pill over the top-left corner, and its tone ("dub", "sub", "accent", ""). badge: string, badge-tone: string, // "check" = watched mark (top-right). mark: string, // Big number over a dimmed picture (a season without its own poster). big: string, // Highlighted (the current season / franchise entry). current: bool, } // One line of a checks list: state 1 = ok, 0 = failed, -1 = unknown. export struct Check { state: int, label: string, detail: string, } // One line of a page. // hero big title block with buttons (detail pages, spotlight) // heading section title (+ subtitle) // text paragraph (style "body" | "caption" | "label" | "warn" | "bad" | "good") // notice icon + title + text, toned ("good" | "bad" | "warn" | "info") // chips a row of chips (title = label above them) // cards a row of cards (style "poster" | "landscape" | "season"; captions under them) // item list row: optional picture, title, meta, text, progress, chips // checks two columns of check rows // keyboard room for the page's on-screen keyboard export struct Line { id: string, kind: string, y: float, h: float, x: float, w: float, title: string, subtitle: string, meta: string, extra: string, text: string, note: string, style: string, tone: string, icon: string, image: image, logo: image, progress: float, col: int, captions: bool, cards: [Card], chips: [Chip], checks: [Check], }