RESOLVED FIXED330373
[css-overflow] Forced line breaks in a text-overflow string are not converted to a space
https://bugs.webkit.org/show_bug.cgi?id=330373
Summary [css-overflow] Forced line breaks in a text-overflow string are not converted...
Christian Biesinger
Reported 2026-11-05 13:12:33 PST

The CSSWG resolved that each sequence of forced line breaks in a text-overflow string is converted to a single space: https://github.com/w3c/csswg-drafts/issues/12557#issuecomment-3960400974

WebKit uses the string as is:
<div style="width: 5ch; overflow: hidden; white-space: nowrap; text-overflow: 'Hi\A\A\AHi'">overflowing text</div>
shows "Hi Hi" (one space per line feed) instead of "Hi Hi". Line tabulation, form feed, U+0085, U+2028 and U+2029 aren't converted to a space either.

Failing tests: imported/w3c/web-platform-tests/css/css-overflow/text-overflow-string-016.html and -018 to -022 (and -023 on GLib).

Chromium implemented this in https://chromium-review.googlesource.com/c/chromium/src/+/7710192.

Attachments
Christian Biesinger
Comment 1 2026-11-05 13:14:00 PST
EWS
Comment 2 2026-11-09 12:49:00 PST
Committed 326188@main (fbb0ef3287a7): <https://commits.webkit.org/326188@main> Reviewed commits have been landed. Closing PR #79839 and removing active labels.
Radar WebKit Bug Importer
Comment 3 2026-11-09 12:50:18 PST
Christian Biesinger
Comment 4 2026-11-09 15:54:39 PST
Submitted web-platform-tests pull request: https://github.com/web-platform-tests/wpt/pull/64970
Note You need to log in before you can comment on or make changes to this bug.