https://github.com/whatwg/html/pull/10265 is proposing changes to specify the rendering of the <details> element in more detail. (See also https://github.com/WebKit/standards-positions/issues/351 .) Some of these changes match existing implementations. However, I'm aware of a number of things that would need to change in WebKit to match these changes: * the existing changes in bug 157323 and bug 228843 would be needed to match what is already in the HTML spec * the display property would need to be allowed to change more generally on both the <details> and also (I think) <summary> elements * the ::details-content pseudo-element specified in https://drafts.csswg.org/css-pseudo-4/#details-content-pseudo would need to be implemented and made to match the correct element. (There may be some work here to implement the "part-like pseudo-element" concept.) * the default display of the internal <slot> matched by the ::details-content pseudo-element would need to change to block rather than contents. (This is the one part here that involves compatibility risk, and it's possible we may need to revert this piece.)
<rdar://problem/129786929>
Bug 157323 covers a lot of this (using display/content-visibility, stop forcing the display value, etc.), I'll use this bug to expose the ::details-content pseudo-element