Skip to content

[css-text-decor-4] Should the spec for text-decoration-trim suggest applying auto to Chinese & Japanese content by default? #12951

@jfkthame

Description

@jfkthame

Spec: https://drafts.csswg.org/css-text-decor-4/#text-decoration-skip-inset-property

The spec says that the initial value of text-decoration-trim is zero, so no trimming happens by default.

I'm wondering, though, whether we should recommend that browsers apply text-decoration-trim: auto (e.g. via the default HTML stylesheet) to elements that are styled with decoration lines if the content language is Chinese or Japanese.

Here's a screenshot of a fragment from Japanese wikipedia, with the Firefox preference to "always underline links" enabled:

Image

Note the two regions circled in red: the first of these contains four separate links, and the second contains three. But in each case, we see a single continuous underline, making it far from obvious to the user that there are multiple short links.

With a rule such as

a:lang(ja) { text-decoration-trim: auto; }

we'd get something like this instead:

Image

This seems to me a significant improvement. Should we include some such recommendation as a note in the spec?

Metadata

Metadata

Assignees

No one assigned

    Labels

    css-text-decor-4i18n-clreqChinese language enablementi18n-jlreqJapanese language enablementi18n-trackerGroup bringing to attention of Internationalization, or tracked by i18n but not needing response.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions