The ruby-position property determines where ruby annotations appear relative to their base text. It accommodates traditional East Asian typography conventions where annotations may appear above, below, or to the side of base characters depending on writing mode and layout needs.ruby {
ruby-position: over;
}rt {
ruby-position: alternate over;
}alternateThe default value. Different annotation levels alternate between over and under positions. The first level behaves as over (or under if combined with it).overThe ruby annotation appears line-over the base — above in horizontal writing or to the right in vertical writing.underThe ruby annotation appears line-under the base — below in horizontal writing or to the left in vertical writing.inter-characterFor horizontal text, creates vertical annotations on the right side of bases (used in Taiwanese Bopomofo) and forces writing-mode: vertical-rl on ruby annotation children. In vertical writing, behaves as over.CSS Ruby Annotation Layout Module Level 1Editor's DraftW3CMDN
漢字
Show all codeEdit CSS onlineThe plugin that remembers hundreds of CSS items for youEvery CSS property — in a live demonstrationThe bilingual CSS referencedefinitionexamplessyntaxmodulespecificationsourcesvisual demonstrationpreviousnext