mirror of
https://github.com/mozilla-firefox/firefox
synced 2026-08-12 20:45:22 +00:00
Automatic update from web-platform-tests Import tests for html ruby extensions (#58150) These cover: * permutations of the allowed syntax for ruby base markup (with or without rb, interleaved and tabular markup, with too many bases, with too many annotations) * usage of rt alone, rtc alone, and rt with rtc, and variants where (some) rt are implied * spanning annotations using rtc * multi-level ruby using rtc (both spanning and non-spanning) * the presence of rp, and the lack of interference with segmentation and pairing, not only when rp respect the content model, but even when it doesn't * inter-element spaces not interferring with segmentation and pairing See the README for some more info on the approach followed. -- wpt-commits: 0828f9ec7da741aea4ecaf817f9a5a09cfe8ff1a wpt-pr: 58150
50 lines
2.8 KiB
HTML
50 lines
2.8 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en" >
|
|
<meta charset="utf-8">
|
|
<title>Ruby Markup Content Model: single ruby element, rb bases, interleaved markup, annotation with rtc, extra bases, adding rp in all the places where it's allowed by the content model, as well as some where it's not.</title>
|
|
<!-- Even then, the spec states that Ruby Segmentation and Pairing occurs ignoring rp elements, without limiting itself to validly placed rp elements. -->
|
|
<!-- Same markup pattern as -311 -->
|
|
<link rel="author" title="Florian Rivoal" href="https://florian.rivoal.net">
|
|
<link rel="help" href="https://www.w3.org/TR/html-ruby-extensions/#the-ruby-element">
|
|
<link rel="help" href="https://www.w3.org/TR/html-ruby-extensions/#the-rb-element">
|
|
<link rel="help" href="https://www.w3.org/TR/html-ruby-extensions/#the-rtc-element">
|
|
<link rel="help" href="https://www.w3.org/TR/html-ruby-extensions/#the-rp-element">
|
|
<link rel="help" href="https://www.w3.org/TR/html-ruby-extensions/#ruby-pairing">
|
|
<link rel="mismatch" href="reference/html-ruby-010-a-ref.html">
|
|
<link rel="mismatch" href="reference/html-ruby-010-b-ref.html">
|
|
<link rel="mismatch" href="reference/html-ruby-010-c-ref.html">
|
|
<link rel="mismatch" href="reference/html-ruby-010-d-ref.html">
|
|
<link rel="mismatch" href="reference/html-ruby-010-e-ref.html">
|
|
<link rel="mismatch" href="reference/html-ruby-010-f-ref.html">
|
|
<link rel="mismatch" href="reference/html-ruby-010-y-ref.html">
|
|
<link rel="mismatch" href="reference/html-ruby-010-z-ref.html">
|
|
<style>
|
|
.r1 { color: orange; }
|
|
.r2 { color: blue; }
|
|
.r3 { color: purple; }
|
|
ruby { ruby-merge: separate; } /* Not strictly required, but added just in case some user agent otherwise has a jukugo-like default rendering. */
|
|
</style>
|
|
<body>
|
|
<p>The example below consists of 3 base characters, the first being annotated with its pronunciation.
|
|
“<span class=r1>浄</span>” is annotated by “<span class=r1>じょう</span>”.
|
|
“<span class=r2>瑠</span>” is not annotated.
|
|
“<span class=r3>璃</span>” is not annotated.
|
|
For ease of comparison, it is preceded by some context text: “例文は”.
|
|
This test passes if:
|
|
<ul>
|
|
<li>each base character is presented inline with and similarly to the context text, as if they are all part of the same sentence, and
|
|
<li>the annotation is presented as an annotation, and
|
|
<li>the annotation is only associated with the first base, not shared with the others.
|
|
</ul>
|
|
|
|
<p>Note: The colors are not part of the test,
|
|
they are merely provided as help to the person running the test,
|
|
to make it easier to recognize the various parts of the text.
|
|
|
|
<p>Note: This is not a layout or rendering test.
|
|
The precise appearance is not specified,
|
|
and implementations may therefore validly vary.
|
|
|
|
<hr>
|
|
例文は<ruby><rb class=r1>浄<rp>!</rp><rtc class=r1><rp>!</rp>じょう<rp>!</rp></rtc><rp>!</rp><rb class=r2>瑠<rb class=r3>璃</ruby>
|