Skip to main content

interactive_rules

Function interactive_rules 

Source
pub fn interactive_rules(selector: &str) -> String
Expand description

Hover and pressed, for a selector that answers a click.

Pressed emits Depth::pressed in full, fill and edge together. Emitting only the edge is what left goingson hand-writing background: var(--surface-sunken) on three separate rules, and a fill that does not travel with its edge is precisely the disagreement Depth exists to make unrepresentable. So the pressed fill comes from the description (--surface-well) rather than from whatever each app reached for.

Hover has no member in the description and is renderer policy: a terminal and an immediate-mode painter have no hover to express. It resolves against --hover-surface, which makeover already derives and which nothing consumed until now.