Skip to content

[css-logical] flow-relative ordering #1500

@jonathantneal

Description

@jonathantneal

From directly above and including https://drafts.csswg.org/css-logical/#example-368bde23

If four values are set, they apply to the block-start, inline-start, block-end, and inline-end sides in that order.

blockquote {
  margin: logical 1em 2em 3em 4em;
}
blockquote {
  margin-block-start:  1em;
  margin-inline-start: 2em;
  margin-block-end:    3em;
  margin-inline-end:   4em;
}

This ordering seems illogical, especially if the block-first wasn’t logical enough that it would be reconsidered, as opposed to merely swapping out top/right/bottom/left for bs/ie/be/is.

In existing web technology, graphic design, or plotting, the ordering is usually inline (width, X) before block (height, Y). This is found in most forms of printing or plotting design, 2D graphic applications like Photoshop or Gimp, 3D graphic applications Blender or Maya, existing web technology measurements like screen resolutions or DOM / Canvas / SVG offset coordinates. It’s colloquialism likely stems from the 14th century Cartesian coordinate system.

If my “six centuries standard” claim is not too bold, I would recommend the ordering be updated to place inline (width, X) first before block (height, Y), preserving start before end, and then continuing in that clockwise direction:

blockquote {
  margin: logical 1em 2em 3em 4em;
}
blockquote {
  margin-inline-start: 1em;
  margin-block-start:  2em;
  margin-inline-end:   3em;
  margin-block-end:    4em;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions