A link keyboard users meet first that moves focus past the navigation to the main content.
Installation
Components are distributed as source. Copy it and what it depends on into your project, then change it as you need:
cargo run --release --bin amenui -- add skip-link --to ../my-appFiles copied: src/widgets/skip_link.rs, src/widgets/mod.rs
Usage
use amenui::widgets::{skip_link};API
| Functions | skip_link |
|---|---|
| Props | key, label, target (the key of the element to jump to; focus goes to it, or to the |
| Files | src/widgets/skip_link.rs |
| Depends on | base |
| Response to fronts | nudge (a control: pushed as one piece by fronts, held and condensing at most to Look::legible_cap) |
| Recomposition | keyed labels recompose when their text changes |
Keyboard and accessibility
| States | shown only while it has focus. |
|---|---|
| Keys and messages | none (the runtime moves focus itself). |
On the web every control is mirrored into the page as an element with its role and name, so screen readers and the browser's own focus see it (DESIGN.md §1.14).