Open ajeanmahoney opened 1 year ago
CSS was designed this way [1] to match text output.
/* Elements that should not be rendered on the same line as a <dt> */
/* This should match the element list in writer.text.TextWriter.render_dl() */
dd > div.artwork:first-child,
dd > aside:first-child,
dd > figure:first-child,
dd > ol:first-child,
dd > div.sourcecode:first-child,
dd > table:first-child,
dd > ul:first-child {
clear: left;
}
[1] https://github.com/ietf-tools/xml2rfc/blob/main/xml2rfc/data/xml2rfc.css#L1140-L1142
Note that the alternative version with <t/>
will not give you the desired results in text output.
Flags (1 octet): 0 1 2 3 4 5 6 7
+-+-+-+-+-+-+-+-+
|D| Reserved |
+-+-+-+-+-+-+-+-+
D-flag: When the Prefix is leaked from level-2 to level-1, the D
bit MUST be set. Otherwise, this bit MUST be clear. Prefixes
with the D bit set MUST NOT be leaked from level-1 to level-2.
This is to prevent looping.
RFC 7991 assumes that you know which of the elements it defines are block-level elements (as opposed to span-level elements, which generally can occur in mixed content with "text" interspersed). This is never said anywhere, but <artwork is a block-level element.
(Block-level elements arrange vertically down the page; span-level elements arrange horizontally on the line.)
Describe the issue
Somewhat of a corner case, but in the following definition list, artwork is used as the definition:
As coded above (see [1] and look for [JM] in the comments), the HTML output shows the artwork appearing on a new line. The question is, should it? The newline attribute was set to false. There is also a lack of whitespace between the artwork at the "Flags (1 octet):" line.
Adding an empty
<t/>
in front of the artwork (see [2]) causes the artwork to be placed inline, which is unexpected behavior. The expectation is that the empty<t/>
would start the artwork on a newline and perhaps fix the whitespace issue.Adding text in front of the artwork (e.g.,
<t>The following flags are defined:</t>
; see Section 6.3) causes the output to be formatted correctly (this is the workaround).[1] https://www.rfc-editor.org/v3test/draft-ietf-lsr-ip-flexalgo-16.xml [2] https://www.rfc-editor.org/v3test/draft-ietf-lsr-ip-flexalgo-16-alt.xml
Code of Conduct