Skip to content

[css-inline-3] initial-letters: interaction of shape-margin and regular margin #5119

Closed
@faceless2

Description

@faceless2

@fantasai as you're working on these.

p::first-letter {
    initial-letters: 3;
    margin-right: 20px;
    shape-margin: 10px;
    initial-letters-wrap: all;
}

Do we add the 20px margin to whatever the 10px margin around the shape is calculated to be at that point, or do we use the maximum of the two values?

We've implemented using the maximum of the two margins, which seems to work better - you can set shape-margin to ensure the shape isn't adhered to too closely, and margin-right to push the content along. This also makes more sense with initial-letters-wrap: first, where both properties apply to the first line but only margin-right on subsequent lines.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions