Skip to content

[css-overflow] Bidi handling for text-overflow and line-clamp ellipses #12617

@jja08111

Description

@jja08111

The CSS Overflow Module Level 4 draft specifies inconsistent bidirectional (bidi) handling for the ellipsis generated by text-overflow versus the one generated by the line-clamp property.

  1. text-overflow: ellipsis: The specification implies that the ellipsis is part of its paragraph for bidi purposes. Implementations typically treat it as inheriting the direction of the line it is attached to.
  2. line-clamp (block-ellipsis): The specification for block-ellipsis states that it behaves as if it had unicode-bidi: plaintext.

This leads to two different implementation approaches for what is visually the same feature:

  • text-overflow ellipsis inherits the parent's direction.
  • line-clamp ellipsis uses plaintext logic to determine its direction.

This difference in behavior is surprising and seems unintentional. We'd like to ensure this behavior.

Context: https://chromium-review.googlesource.com/c/chromium/src/+/6817921/comment/c4178435_9956b836/

cc. @andreubotella @kojiishi

Metadata

Metadata

Assignees

No one assigned

    Labels

    Agenda+css-overflow-4topic: line-clampline-clamp, -webkit-line-clamp, and related long hands, not including continue:discard

    Type

    No type

    Projects

    Status

    Agenda+

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions