Skip to content

[css-ruby][css-display] Are ruby containers atomic? Specs contradict #1180

Closed

Description

@Loirooriol

CSS Display defines atomic inline as

An inline-level box that is replaced or that establishes a new formatting context

An element with display: ruby has the inline outer display role, so

The element generates an inline-level box.

, and has the ruby inner display layout model, so

The element generates a principal ruby container box, and establishes a ruby formatting context.

Therefore, display: ruby should produce an atomic inline box according to CSS Display.

However, CSS Ruby explicitly says otherwise:

Ruby containers are non-atomic inline-level boxes.

Activity

  1. SelenIT commented on Apr 7, 2017

    @SelenIT
    Collaborator

    Yes, the ruby formatting context appears to be an exception from the general rule that the inline-level box that establishes a new formatting context is usually atomic. Ruby containers can break between lines, so they are definitely non-atomic.

    I suppose that the CSS Display spec should be changed to something like

    An inline-level box that is replaced or that establishes a new block, flexbox, grid, or table formatting context

    An inline-level element can't establish the inline formatting context, and establishing ruby formatting context doesn't make an inline-level box atomic. If new formatting contexts that make inline-level boxes atomic appear in the future, they should be explicitly added to that list.

  2. fantasai commented on Apr 7, 2017

    @fantasai
    Collaborator

    Ruby containers are weird... they establish a new ruby formatting context, but their content also participates in their parent's inline formatting context. That's going to be odd to explain. :) I'd rather call out ruby as an exception than list out the things that aren't exceptional though.

  3. fantasai commented on Apr 7, 2017

    @fantasai
    Collaborator

    Okay, this should be fixed now. Let me know if you have an further improvements to suggest on this point.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions