Skip to content
SilktideHelp

RP and RT elements

Silktide examines ruby annotations, the small pronunciation hints written above East Asian text, and reports any that are missing the elements that carry the pronunciation or provide a fallback for older browsers.

Ruby annotations are written with the <ruby> element. Inside it, <rt> holds the pronunciation text and <rp> holds fallback parentheses shown by browsers that do not support ruby.

<!-- Problem: no pronunciation (<rt>) or fallback (<rp>) -->
<ruby>漢字</ruby>

<!-- Fix: pronunciation plus fallback parentheses -->
<ruby>漢字<rp>(</rp><rt>kanji</rt><rp>)</rp></ruby>

Why this matters

Ruby annotations exist to tell readers how to pronounce characters, which is essential for languages like Japanese where the same characters can be read in several ways, and helpful for anyone still learning to read them. A <ruby> element without <rt> conveys no pronunciation at all, and without <rp> a visitor on a browser that lacks ruby support sees the annotation run into the surrounding text as an unreadable jumble.

This supports success criterion 3.1.6 (Pronunciation), a requirement.

How to fix it

  1. Add an <rt> element inside each flagged <ruby> containing the pronunciation or annotation text.
  2. Wrap the annotation in <rp> elements containing opening and closing parentheses, so browsers without ruby support show something readable.

How Silktide tests this

  1. Find every <ruby> element on the page, skipping any elements you have excluded from checking.
  2. Report the element if it contains no <rt> descendant.
  3. Report the element separately if it contains no <rp> descendant.

Learn more

Last updated

Was this page helpful?

RP and RT elements | Silktide Help