forge
Explore
Log in

Don't you dare go Hollow

project_note

Clone
★ 0

0 watching0 forksRust3.6 MiBc49f5e7Tahinli1 month ago2 commits

segmented.rs15 lines, 656 bytesHistoryRawDownload
1//! Segmented controls: a short row of buttons where one is pressed, such as the theme
2//! and language switches in the sidebar.
3//!
4//! The look lives in `styles.css` (`.segmented`, `.segment`) and keys the raised pressed
5//! segment on `aria-pressed="true"`. That keeps it correct for controls whose state is set
6//! by script (the theme) as well as by the server (the language).
7
8/// The track around the segments. It is 28px tall.
9pub const TRACK: &str = "segmented";
10
11/// A segment with a text label. It is 24px tall.
12pub const SEGMENT: &str = "segment";
13
14/// A square segment for a single icon.
15pub const SEGMENT_ICON: &str = "segment segment-icon";