diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:47:29 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:47:29 +0000 |
commit | 0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d (patch) | |
tree | a31f07c9bcca9d56ce61e9a1ffd30ef350d513aa /testing/web-platform/tests/css/css-ui/text-overflow-012.html | |
parent | Initial commit. (diff) | |
download | firefox-esr-0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d.tar.xz firefox-esr-0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d.zip |
Adding upstream version 115.8.0esr.upstream/115.8.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testing/web-platform/tests/css/css-ui/text-overflow-012.html')
-rw-r--r-- | testing/web-platform/tests/css/css-ui/text-overflow-012.html | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/css-ui/text-overflow-012.html b/testing/web-platform/tests/css/css-ui/text-overflow-012.html new file mode 100644 index 0000000000..a75908026a --- /dev/null +++ b/testing/web-platform/tests/css/css-ui/text-overflow-012.html @@ -0,0 +1,47 @@ +<!DOCTYPE html> +<html> +<meta charset="utf-8"> +<title>CSS Basic User Interface Test: ellipsis and extended grapheme cluster</title> +<link rel="author" title="Florian Rivoal" href="http://florian.rivoal.net/"> +<link rel="help" href="http://www.w3.org/TR/css3-ui/#text-overflow"> +<link rel="match" href="reference/text-overflow-012-ref.html"> +<meta name="flags" content="should"> +<!-- This is SHOULD because although CSS-UI defines "character" as "grapheme cluster" in a non optional manner + UAX29 itself defines grapheme cluster as either legacy or extended grapheme clusters, + and says (emphasis mine): + The extended grapheme clusters **should** be used + in implementations in preference to legacy grapheme clusters + --> +<meta name="assert" content="Implementations must hide characters, i.e. entire garpheme clusters, not part of them, to make room for the ellipsis"> +<style> +#sizer { + font-size: 50px; + white-space: pre; + color: white; + float: left; + position: relative; +} + +#test { + overflow: hidden; + text-overflow: ellipsis; + position: absolute; + top: 0; right: 2px; bottom: 0; left: 0; + color: green; +} +span { + color: red; +} + +</style> + +<p>Test passes if there are three green dots below and <strong>no red</strong>.</p> + +<!--Starting the line with an space because the first character on the line is clipped rather than ellided, so we need the tested grapheme cluster to be non-first--> +<!-- +sizer shrinkwraps to the size of a space, plus the grapheme cluster, plus the ellipsis. +test is 2px shorter than that, so it can only fit part of the grapheme cluster. +The whole grapheme cluster should be removed, not just its second character. +--> + +<div id=sizer> กำ…<div id=test> <span>กำfiller text to make things overflow</span></div><div> |