<?xml version="1.0" encoding="UTF-8"?>
  <?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>

<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
<!ENTITY RFC5741 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5741.xml">
<!ENTITY RFC7322 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.7322.xml">
<!ENTITY I-D.hildebrand-html-rfc SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml3/reference.I-D.hildebrand-html-rfc.xml">
<!ENTITY I-D.flanagan-rfc-framework SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml3/reference.I-D.flanagan-rfc-framework.xml">
]>

<rfc ipr="trust200902" docName="draft-flanagan-rfc-css-01" category="info">

<?rfc toc="yes"?>

  <front>
    <title abbrev="I-D">CSS Requirements for RFCs</title>

    <author initials="H." surname="Flanagan" fullname="Heather Flanagan">
      <organization>RFC Editor</organization>
      <address>
        <email>rse@rfc-editor.org</email>
        <uri>http://orcid.org/0000-0002-2647-2220</uri> 
      </address>
    </author>

    <date year="2015" month="August" day="24"/>
    

    <abstract>


<t>While individuals may choose their own Cascading Style Sheet for presenting
 HTML-formatted RFCs, the default offered by the RFC Editor must meet certain 
requirements.  This draft describes those requirements and is based on the 
classes defined in draft-hildebrand-html-rfc.</t>

<t>Discussion of this draft takes place on the rfc-interest mailing list (rfc-interest@rfc-editor.org), which has its home page at https://www.rfc-editor.org/mailman/listinfo/rfc-interest.</t>



    </abstract>


  </front>

  <middle>


<section anchor="introduction" title="Introduction">

<t>The HTML format for RFCs, described in <xref target="I-D.hildebrand-html-rfc"/> assigns style guidance to an RFC Editor-defined Cascading Style Sheet (CSS).  This CSS will be embedded in the published HTML, and may be overridden by a locally defined CSS as desired.  The embedded, default CSS as included by the RFC Editor is expected to take into account accessibility needs and be built along a responsive design model.</t>

<t>This document describes the requirements for the default CSS used by the RFC Editor. Unless called out otherwise, any styling provided for these classes must not alter the natural language content in any visible way.  Many of these classes are provided to mark the elements semantically: elements using them should simply inherit their surrounding styling. Exceptions are called out below. A class is identified for Internet Drafts, such that certain features found only in I-Ds may be made distinct in some fashion within those drafts.  The requirements will only be applied to HTML documents published by the RFC Editor as per <xref target="I-D.flanagan-rfc-framework"/>.</t>

<t>The details described in this document are expected to change based on experience gained in implementing the RFC production center's toolset. Revised documents will be published capturing those changes as the toolset is completed. Other implementers must not expect those changes to remain backwards-compatible with the details described this document.</t>

</section>
<section anchor="design-goals" title="Design Goal">

<t>RFCs must be adaptable to a wide variety of devices and displays, accessible to assisted readers, and printable.</t>

</section>
<section anchor="general-requirements" title="General Requirements">

<t><list style='symbols'>
  <t>Support the display of the semantic HTML described in <xref target="I-D.hildebrand-html-rfc"/>.</t>
  <t>Follow best practice for accessibility, as defined by the W3C's "Best Practices for Authoring HTML" <xref target="HTMLBP"/>.</t>
  <t>Follow best practice for mobile devices, as defined by the W3C's "Best Practices for Authoring HTML."</t>
  <t>Allow for a broad range of internationalized scripts.</t>
</list></t>

</section>
<section anchor="page-layout" title="Page Layout">

<section anchor="title-page-header" title="Title Page Header">

<t>The document header must be at the top of the page and include all information described in the "Style Guide" and "RFC Streams, Headers, and Boilerplates" <xref target="RFC7322"/> <xref target="RFC5741"/></t>

</section>
<section anchor="body" title="Body">

<t>The body of the document must conform to the following:</t>

<t><list style='symbols'>
  <t>Examples and code blocks must be in a fixed-width font</t>
  <t>ASCII art must be in a fixed-width font</t>
  <t>Reflow the text as the screen gets smaller and limit max width </t>
  <t>Block quotes must be indented </t>
  <t>Tables must allow for distinct header rows</t>
  <t>Paragraphs should include a hover-over paragraph identifier</t>
</list></t>
  <t>All anchor tags and URLs should be clearly distinguished as links, for example through the use of color and/or text decoration, following appropriate accessibility standards.</t>

</section>
<section anchor="font-choices" title="Font Choices">

<t><list style='symbols'>
  <t>Default to a sans-serif font family with broad Unicode support for web browser viewing.</t>
  <t>Default to a serif font family with broad Unicode support for printing.</t>
  <t>A fixed-width font must be used for code and artwork-tagged sections.</t>
  <t>All fonts should be publicly licensed and supported by all major web browsers.</t>
</list></t>

</section>
</section>
<section anchor="printing" title="Printing">

<t>The CSS must include support for a printer-friendly output.  The print rules should be a part of the embedded style sheet; consumers of an RFC may develop their own print-specific style sheet as desired.</t>

</section>
<section anchor="lists" title="Lists">
  <t>Lists should provide ample whitespace between list elements for legibility unless a ‘compact’ class is specified (e.g., .dlcompact, .ulcompact, .olcompact).</t>
</section>

<section anchor="css-classes" title="CSS Classes and Attributes">
<t>This section describes the CSS classes that result in specific changes to the natural language content of a document. A full list of available classes, not including basic selectors, are included in "Appendix A".</t>

  <section anchor="artwork" title=".artwork">
  <t>These classes will mostly be styled as part of .artwork.  Specific
  classes may include '.art-ascii-art' and '.art-svg'. Artwork will be held 
  in its own block of space, centered in the page flow, and will not float. 
  Images shoul dhave a max width of 100% so views will scale properly across
  a variety of screens and devices.</t>

    <section anchor="art-ascii-art" title=".art-ascii-art">
    <t>Must use a mono-spaced font.</t>
    </section>

    <section anchor="art-logo" title=".art-logo">
    <t>No visible changes to the natural language content; keep in default style. Note that such images are not currently allowed in RFCs.</t>
    </section>
  </section>

  <section anchor="cref" title=".cref">
    <t>A comment within an I-D; should be visually distinct.</t>
    <t>For I-Ds only; not for RFCs.</t>
  </section>

  <section anchor="crefAnchor" title=".crefAnchor">
    <t>A comment within an I-D; should be visually distinct.</t>
    <t>For I-Ds only; not for RFCs.</t>
  </section>

  <section anchor="cref-source" title=".cref-source">
    <t>A comment within an I-D; should be visually distinct.</t>
    <t>For I-Ds only; not for RFCs.</t>
  </section>

  <section anchor="dlparallel" title=".dlparallel">
    <t>Do not use the standard hanging indent for a definition list; align terms and definitions along left side.</t>
  </section>

  <section anchor="dlcompact" title=".dlcompact">
    <t>Use less spacing on a definition list than the default.</t>
  </section>

  <section anchor="docinfo" title=".docinfo">
    <t>Hide from visible content.</t>
  </section>

  <section anchor="eref" title=".eref">
    <t>Standard link formatting (underlined, change in color).</t>
  </section>

  <section anchor="finalized" title=".finalized">
    <t>Hide from visible content.</t>
  </section>

  <section anchor="note" title=".note"> 
    <t>Notes should be emphasized and distinct from normal paragraph text.
    </t>
    <section anchor="rfceditor-remove" title=".rfceditor-remove">
      <t>An rfceditor note may be added after the standard boilerplage. It should be visually distinct to highlight final removal of the note by the RFC Editor.</t>
    </section>
  </section>

  <section anchor="olcompact" title=".olcompact">
    <t>Use less spacing on a numbered list than the default.</t>
  </section>

  <section anchor="olpercent" title=".olpercent">
    <t>If the style attribute from the source XML contains a percent sign, a particular style setting will be required to make this setting behave like an HTML ordered list.</t>
  </section>

  <section anchor="pilcrow" title=".pilcrow">
    <t>Pilcrows, when used as described in draft-hildebrand-html-rfc, should 
       appear at the end of the paragraph, artwork, or sourcecode segment.</t>
  </section>

  <section anchor="relref" title=".relref">
    <t>Should be clearly distinguished as links.</t>
  </section>

  <section anchor="rendered" title=".rendered">
    <t>Hide from visible content.</t>
  </section>

  <section anchor="sourcecode" title=".sourcecode">
    <t>Code examples or components should be in a fixed-width font if the human language used has an available fixed-width font option, and should be visually distinct. If no fixed-width font is available, use the default font for that human language.</t>
    <section anchor="lang-" title=".lang-">
    <t>Example: lang-c</t>
    </section>
  </section>

  <section anchor="toc" title=".toc">
    <t>should be clearly distinguished using an indented, ordered list with the list style set to 'none', allowing for hyperlinked, in-line dotted number notation (e.g., 1., 1.1., 1.1.1.).</t>
  </section>

  <section anchor="type" title=".type">
    <t>No visible changes to the natural language content; keep in default style.</t>
  </section>

  <section anchor="ulcompact" title=".ulcompact">
    <t>Use less spacing on a bulleted list than the default.</t>
  </section>

  <section anchor="url" title=".url">
    <t>Should be clearly distinguished as links.</t>
  </section>

  <section anchor="workgroup" title=".workgroup">
    <t>No visible changes to the natural language content; keep in default style.</t>
  </section>
 
  <section anchor="xref" title=".xref">
    <t>Should be clearly distinguished as links.</t>
  </section>

</section>


<section anchor="security-considerations" title="Security Considerations">

<t>Security vulnerabilities can be introduced through the CSS.  How much detail do we need to go into here to say "don't do foolish things and introduce security issues?"</t>

</section>

<section anchor="iana-considerations" title="IANA Considerations">

<t>This draft contains no action for IANA</t>

</section>
<section anchor="acknowledgements" title="Acknowledgements">
<t>With many thanks to the RFC Format Design Team for their efforts in making this transition successful: Nevil Brownlee (ISE), Tony Hansen, Joe Hildebrand, Paul Hoffman, Ted Lemon, Julian Reschke, Adam Roach, Alice Russo, Robert Sparks (Tools Team liaison), and Dave Thaler.</t>
<t>Additional thanks to Arlen Johnson of Spherical Cow Group, LLC, for his assistance in clarifying the requirements in more CSS designer-friendly language.</t>

</section>

<section anchor="change-log" title="Draft Change Log">
<t>To be removed before publication</t>
<section anchor="change-01" title="Changes from -00 to -01">
<t>Moved full list of classes to Appendix; only discussed classes that will have visible changes to the text in the body</t>
<t>Introduction: text regarding expected future changes added.</t>
<t>Body: added text regarding anchors and tags; this text also applied to .relref, .url, .xref</t>
<t>Artwork: clarified non-floating behavior of artwork</t>
<t>List behavior: clarified the behavior of .ulcompact, .olcompact, and .dlcompact as distinct from default list behavior; clarified behavior of .dlparallel</t>
<t>Note: clarified text around behavior of notes</t>
<t>RFC: added additional class to allow the CSS to distinguish between RFCs and Internet Drafts if desired</t>
<t>TOC: clarified text around behavior of table of contents</t>
</section>
</section>

<section anchor="appendix-a" title="Appendix A. List of classes">
<t>
<list style="symbols">
<t>.adr</t>
<t>.annotation</t>
<t>.anticomma</t>
<t>.artwork
<list style='empty'>
<t>.art-ascii-art</t>
<t>.art-logo</t>
<t>.art-svg</t>
</list>
</t>
<t>.ascii</t>
<t>.author</t>
<t>.authors</t>
<t>.bcp14</t>
<t>.city</t>
<t>.comma</t>
<t>.compact</t>
<t>.country-name</t>
<t>.cref</t>
<t>.crefAnchor</t>
<t>.cref-source</t>
<t>.dlparallel</t>
<t>.dlcompact</t>
<t>.docinfo</t>
<t>.email</t>
<t>.eref</t>
<t>.finalized</t>
<t>.fn</t>
<t>.index</t>
<t>.indexChar</t>
<t>.indexComma</t>
<t>.indexIndex</t>
<t>.indexItem</t>
<t>.indexPrimary</t>
<t>.indexSubItem</t>
<t>.initial</t>
<t>.iref</t>
<t>.irefItem</t>
<t>.irefRefs</t>
<t>.irefSubItem</t>
<t>.label</t>
<t>.locality</t>
<t>.namerole</t>
<t>.note
<list style="empty">
<t>.rfceditor-remove</t>
</list>
</t>
<t>.olcompact</t>
<t>.olpercent</t>
<t>.org</t>
<t>.organization</t>
<t>.pilcrow</t>
<t>.postal-code</t>
<t>.published</t>
<t>.refauthor</t>
<t>.refcontent</t>
<t>.reference</t>
<t>.referencegroup</t>
<t>.region</t>
<t>.relref</t>
<t>.rendered</t>
<t>.RFC</t>
<t>.role</t>
<t>.self-ref</t>
<t>.series</t>
<t>.seriesInfo</t>
<t>.sourcecode
<list style="empty">
<t>.lang-</t>
</list>
</t>
<t>.street-address</t>
<t>.status</t>
<t>.street-address</t>
<t>.surname</t>
<t>.tel</t>
<t>.toc</t>
<t>.type</t>
<t>.ulcompact</t>
<t>.url</t>
<t>.workgroup</t>
<t>.xref</t>
<t>.vcard</t>
</list>
</t>
</section>

  </middle>

  <back>

    <references title='Normative References'>

<reference anchor="HTMLBP" target="http://www.w3.org/standards/techs/htmlbp">
  <front>
    <title>Best Practices for Authoring HTML Current Status</title>
    <author >
      <organization>W3C</organization>
    </author>
    <date year="n.d."/>
  </front>
</reference>
&RFC5741;
&RFC7322;
&I-D.hildebrand-html-rfc;
&I-D.flanagan-rfc-framework;


    </references>

  </back>
</rfc>


