W3C home > Mailing lists > Public > public-css-archive@w3.org > December 2018

Re: [csswg-drafts] [css-break-4] Should margin-break apply to elements or fragmentation containers? (#3314)

From: Bernhard Fey via GitHub <sysbot+gh@w3.org>
Date: Fri, 14 Dec 2018 16:30:06 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-447377781-1544805005-sysbot+gh@w3.org>
Thanks @fantasai for the confirmation (And belated thanks @frivoal for the warm welcome.)

With collapsing being applied last, I think the implementation side is safe. However, collapsing of nested elements seemingly changing truncated margins to non-zero values may be confusing for some authors. (In my personal experience margin collapsing, as it is, is already considered confusing by quite a few.) This may be solved by considering truncated margins to not be adjacent to any other margins or similar limitations to collapsing.

I still believe the simpler approach, setting the property on the fragmentation container, would eliminate these problems entirely. The desired result in the [sample above](https://github.com/w3c/csswg-drafts/issues/3314#issuecomment-438530286) can be achieved without using `margin-break` and the CSS would still be compact. And I have failed to come up with any more complex and realistic use-case that requires the finer control. Maybe someone else can.

Would adding properties for both elements and fragment containers, similar to `*-self` and `*-items`, be an option? It would provide the advantages of both, at, what seems to me, a very minor increase of complexity.

-- 
GitHub Notification of comment by bernhardf-ro
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/3314#issuecomment-447377781 using your GitHub account
Received on Friday, 14 December 2018 16:30:07 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:41 UTC