Skip to content

Sibling layout interactions in content, like p+ul #162

Open
@gnprice

Description

@gnprice

Zulip web has a couple of CSS rules that adjust spacing between sibling block elements. From web/styles/rendered_markdown.css:

    /* The spacing between two paragraphs is significantly larger.  We
       arrange things so that this spacing matches the spacing between
       paragraphs in two consecutive 1-line messages. */
    & p + p {
        margin-top: 10px;
    }
// …

    /* Reduce top-margin when a paragraph is followed by an ordered or bulleted list */
    & p + ul,
    p + ol {
        margin-top: 0;
    }

(The details have changed occasionally over the years, as in zulip/zulip@d7aa186 and
zulip/zulip@62f2396.)

We should either match that behavior, or determine there's a good reason for mobile to differ from web here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    a-contentParsing and rendering Zulip HTML content, notably message contentsa-designVisual and UX design

    Type

    No type

    Projects

    Status

    No status

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions