Vanilla Breeze v0.7.4

Vanilla Breeze v0.7.4 released

0.7.4 gives the Ambient pack weather. A page names one feed URL on its own site, and the pack sets data-weather from it, uses its sunrise and sunset for dawn and dusk, and never shows a stale observation. Helpers for producing the feed from Open-Meteo are included. Ambient p…

Read the release notes

rt

Specifies the ruby text (annotation) in a ruby annotation, providing pronunciation or other guidance above base text.

Description

The <rt> element specifies the ruby text — the small annotation that appears above (or beside) base text. It must be contained within a <ruby> element.

VB styles <rt> at 0.5em with centered alignment. Annotations are visible by default on every page. CJK readings get the CJK script face; romanised readings tagged -Latn (pinyin, romaji, Jyutping) keep the body face. data-ruby on any ancestor can hide them — see Visibility Control.

When to Use

  • Inside <ruby> to provide pronunciation guides
  • Japanese furigana (hiragana readings for kanji)
  • Chinese pinyin (romanized pronunciation) or bopomofo
  • Pronunciation guides for words in any language

Examples

CSS Reference

Visibility Control

<rt> is visible unless a data-ruby attribute on an ancestor (or on the <ruby>) says otherwise; the nearest one wins. hide hides every annotation visually, auto hides those whose language is not CJK, and show undoes an outer setting. See the ruby element page for details.

Accessibility

  • Screen readers handle ruby differently: some read the base text then the annotation, some read only one, and some let the user choose
  • Ruby text is valuable for language learners and those with reading difficulties
  • When data-ruby="hide" (or auto) hides an <rt>, it collapses to zero size and is clipped, but stays in the accessibility tree — it is not visibility: hidden or display: none

Related

  • <ruby> — Parent element for ruby annotations (required)
  • <rp> — Fallback parentheses for non-supporting browsers
  • Internationalization guide — Ruby visibility control, script-specific typography
↑