##// END OF EJS Templates
processes: shorten the message and remove exit code which isn't shown properly anyway.
processes: shorten the message and remove exit code which isn't shown properly anyway.

File last commit:

r1900:7da9bb63 default
r3492:a7095130 default
Show More
typography.html
507 lines | 22.2 KiB | text/html | HtmlLexer
## -*- coding: utf-8 -*-
<%inherit file="/debug_style/index.html"/>
<%def name="breadcrumbs_links()">
${h.link_to(_('Style'), h.route_path('debug_style_home'))}
&raquo;
${c.active}
</%def>
<%def name="real_main()">
<div class="box">
<div class="title">
${self.breadcrumbs()}
</div>
</div>
##main
<div class='sidebar-col-wrapper'>
${self.sidebar()}
<div class="main-content">
<div class="bs-docs-section">
<h1 id="type" class="page-header">Typography</h1>
<!-- Headings -->
<h2 id="type-headings">Headings</h2>
<p>All HTML headings, <code>&lt;h1&gt;</code> through <code>&lt;h6&gt;</code>, are available. <code>.h1</code> through <code>.h6</code> classes are also available, for when you want to match the font styling of a heading but still want your text to be displayed inline.
</p>
<p>All headings have no top/side margins and a bottom margin which corresponds to variable <code>@textmargin</code>, a color corresponding to <code>@text-color</code>, and a line-height of 1.8em.
<div class="bs-example bs-example-type" data-example-id="simple-headings">
<table class="table">
<tbody>
<tr>
<td><h1>h1. RhodeCode heading</h1></td>
<td class="type-info">Bold</td>
<td class="type-info">1.54em</td>
</tr>
<tr>
<td><h2>h2. RhodeCode heading</h2></td>
<td class="type-info">Semi-Bold</td>
<td class="type-info">1.23em</td>
</tr>
<tr>
<td><h3>h3. RhodeCode heading</h3></td>
<td class="type-info">Regular</td>
<td class="type-info">1.23em</td>
</tr>
<tr>
<td><h4>h4. RhodeCode heading</h4></td>
<td class="type-info">Bold</td>
<td class="type-info">1em</td>
</tr>
<tr>
<td><h5>h5. RhodeCode heading</h5></td>
<td class="type-info">Bold Italic</td>
<td class="type-info">1em</td>
</tr>
<tr>
<td><h6>h6. RhodeCode heading</h6></td>
<td class="type-info">Bold Italic</td>
<td class="type-info">1em</td>
</tr>
</tbody>
</table>
</div>
<div class="highlight-html"><xmp>
<h1>h1. RhodeCode heading</h1>
<h2>h2. RhodeCode heading</h2>
<h3>h3. RhodeCode heading</h3>
<h4>h4. RhodeCode heading</h4>
<h5>h5. RhodeCode heading</h5>
<h6>h6. RhodeCode heading</h6>
</xmp></div> <!-- end highlight -->
<p>Create lighter, secondary text in any heading with a generic <code>&lt;small&gt;</code> tag or the <code>.small</code> class.</p>
<div class="bs-example bs-example-type" data-example-id="small- headings">
<table class="table">
<tbody>
<tr>
<td><h1>h1. RhodeCode heading <small>Secondary text</small></h1></td>
</tr>
<tr>
<td><h2>h2. RhodeCode heading <small>Secondary text</small></h2></td>
</tr>
<tr>
<td><h3>h3. RhodeCode heading <small>Secondary text</small></h3></td>
</tr>
<tr>
<td><h4>h4. RhodeCode heading <small>Secondary text</small></h4></td>
</tr>
<tr>
<td><h5>h5. RhodeCode heading <small>Secondary text</small></h5></td>
</tr>
<tr>
<td><h6>h6. RhodeCode heading <small>Secondary text</small></h6></td>
</tr>
</tbody>
</table>
</div>
<div class="highlight-html"><xmp>
<h1>h1. RhodeCode heading <small>Secondary text</small></h1>
<h2>h2. RhodeCode heading <small>Secondary text</small></h2>
<h3>h3. RhodeCode heading <small>Secondary text</small></h3>
<h4>h4. RhodeCode heading <small>Secondary text</small></h4>
<h5>h5. RhodeCode heading <small>Secondary text</small></h5>
<h6>h6. RhodeCode heading <small>Secondary text</small></h6>
</xmp></div> <!-- end highlight -->
<!-- Body copy -->
<h2 id="type-body-copy">Body copy</h2>
<p>RhodeCode's global default <code>font-size</code> is <strong>13px</strong>, with a <code>line-height</code> of <strong>2em</strong>. This is applied to the <code>&lt;body&gt;</code> and all paragraphs. In addition, <code>&lt;p&gt;</code> (paragraphs) receive a bottom margin of designated by @textmargin (20px).</p>
<div class="bs-example" data-example-id="body-copy">
<p>Nullam quis risus eget urna mollis ornare vel eu leo. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Nullam id dolor id nibh ultricies vehicula.</p>
<p>Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec ullamcorper nulla non metus auctor fringilla. Duis mollis, est non commodo luctus, nisi erat porttitor ligula, eget lacinia odio sem nec elit. Donec ullamcorper nulla non metus auctor fringilla.</p>
<p>Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Duis mollis, est non commodo luctus, nisi erat porttitor ligula, eget lacinia odio sem nec elit.</p>
</div>
<div class="highlight-html"><xmp>
<p>...</p>
</xmp></div> <!-- end highlight -->
<!-- Body copy .lead -->
<h3>Lead body copy</h3>
<p>Make a paragraph stand out by adding <code>.lead</code>.</p>
<div class="bs-example" data-example-id="lead-copy">
<p class="lead">Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Duis mollis, est non commodo luctus.</p>
</div>
<div class="highlight-html"><xmp>
<p class="lead">...</p>
</xmp></div> <!-- end highlight -->
<!-- Using Less -->
<h3>Built with Less</h3>
<p>The typographic scale is based on Less variables in <strong>variables.less</strong>. Font sizes are calculated from <code>@basefontsize</code>, line-heights are calculated with em, and font families are handled by:
<ul class="list-unstyled">
<li><code>@text-regular</code></li>
<li><code>@text-italic</code></li>
<li><code>@text-bold</code></li>
<li><code>@text-semibold</code></li>
<li><code>@text-bold-italic</code></li>
<li><code>@text-light</code></li>
<li><code>@text-light-italic</code></li>
</ul>
</p>
<!-- Inline text elements -->
<h2 id="type-inline-text">Inline text elements</h2>
<h3>Marked text</h3>
<p>For highlighting a run of text due to its relevance in another context, use the <code>&lt;mark&gt;</code> tag.</p>
<div class="bs-example" data-example-id="simple-mark">
<p>You can use the mark tag to <mark>highlight</mark> text.</p>
</div>
<div class="highlight-html"><xmp>
You can use the mark tag to <mark>highlight</mark> text.
</xmp></div> <!-- end highlight -->
<h3>Deleted text</h3>
<p>For indicating blocks of text that have been deleted use the <code>&lt;del&gt;</code> tag.</p>
<div class="bs-example" data-example-id="simple-del">
<p><del>This line of text is meant to be treated as deleted text.</del></p>
</div>
<div class="highlight-html"><xmp>
<del>This line of text is meant to be treated as deleted text.</del>
</xmp></div> <!-- end highlight -->
<h3>Strikethrough text</h3>
<p>For indicating blocks of text that are no longer relevant use the <code>&lt;s&gt;</code> tag.</p>
<div class="bs-example" data-example-id="simple-s">
<p><s>This line of text is meant to be treated as no longer accurate.</s></p>
</div>
<div class="highlight-html"><xmp>
<s>This line of text is meant to be treated as no longer accurate.</s>
</xmp></div> <!-- end highlight -->
<h3>Inserted text</h3>
<p>For indicating additions to the document use the <code>&lt;ins&gt;</code> tag.</p>
<div class="bs-example" data-example-id="simple-ins">
<p><ins>This line of text is meant to be treated as an addition to the document.</ins></p>
</div>
<div class="highlight-html"><xmp>
<ins>This line of text is meant to be treated as an addition to the document.</ins>
</xmp></div> <!-- end highlight -->
<h3>Underlined text</h3>
<p>To underline text use the <code>&lt;u&gt;</code> tag.</p>
<div class="bs-example" data-example-id="simple-u">
<p><u>This line of text will render as underlined</u></p>
</div>
<div class="highlight-html"><xmp>
<u>This line of text will render as underlined</u>
</xmp></div> <!-- end highlight -->
<p>Make use of HTML's default emphasis tags with lightweight styles.</p>
<h3>Small text</h3>
<p>For de-emphasizing inline or blocks of text, use the <code>&lt;small&gt;</code> tag to set text at 85% the size of the parent. Heading elements receive their own <code>font-size</code> for nested <code>&lt;small&gt;</code> elements.</p>
<p>You may alternatively use an inline element with <code>.small</code> in place of any <code>&lt;small&gt;</code>.</p>
<div class="bs-example" data-example-id="simple-small">
<p><small>This line of text is meant to be treated as fine print.</small></p>
</div>
<div class="highlight-html"><xmp>
<small>This line of text is meant to be treated as fine print.</small>
</xmp></div> <!-- end highlight -->
<h3>Bold</h3>
<p>For emphasizing a snippet of text with a heavier font-weight.</p>
<div class="bs-example" data-example-id="simple-strong">
<p>The following snippet of text is <strong>rendered as bold text</strong>.</p>
</div>
<div class="highlight-html"><xmp>
<strong>rendered as bold text</strong>
</xmp></div> <!-- end highlight -->
<h3>Italics</h3>
<p>For emphasizing a snippet of text with italics.</p>
<div class="bs-example" data-example-id="simple-em">
<p>The following snippet of text is <em>rendered as italicized text</em>.</p>
</div>
<div class="highlight-html"><xmp>
<em>rendered as italicized text</em>
</xmp></div> <!-- end highlight -->
<div class="bs-callout bs-callout-info" id="callout-type-b-i-elems">
<h4>Alternate elements</h4>
<p>Feel free to use <code>&lt;b&gt;</code> and <code>&lt;i&gt;</code> in HTML5. <code>&lt;b&gt;</code> is meant to highlight words or phrases without conveying additional importance while <code>&lt;i&gt;</code> is mostly for voice, technical terms, etc.</p>
</div>
<h2 id="type-alignment">Alignment classes</h2>
<p>Easily realign text to components with text alignment classes.</p>
<div class="bs-example" data-example-id="text-alignment">
<p class="text-left">Left aligned text.</p>
<p class="text-center">Center aligned text.</p>
<p class="text-right">Right aligned text.</p>
<p class="text-justify">Justified text.</p>
<p class="text-nowrap">No wrap text.</p>
</div>
<div class="highlight-html"><xmp>
<p class="text-left">Left aligned text.</p>
<p class="text-center">Center aligned text.</p>
<p class="text-right">Right aligned text.</p>
<p class="text-justify">Justified text.</p>
<p class="text-nowrap">No wrap text.</p>
</xmp></div> <!-- end highlight -->
<h2 id="type-transformation">Transformation classes</h2>
<p>Transform text in components with text capitalization classes.</p>
<div class="bs-example" data-example-id="text-capitalization">
<p class="text-lowercase">Lowercased text.</p>
<p class="text-uppercase">Uppercased text.</p>
<p class="text-capitalize">Capitalized text.</p>
</div>
<div class="highlight-html"><xmp>
<p class="text-lowercase">Lowercased text.</p>
<p class="text-uppercase">Uppercased text.</p>
<p class="text-capitalize">Capitalized text.</p>
</xmp></div> <!-- end highlight -->
<!-- Abbreviations -->
<h2 id="type-abbreviations">Abbreviations</h2>
<p>Stylized implementation of HTML's <code>&lt;abbr&gt;</code> element for abbreviations and acronyms to show the expanded version on hover. Abbreviations with a <code>title</code> attribute have a light dotted bottom border and a help cursor on hover, providing additional context on hover and to users of assistive technologies.</p>
<h3>Basic abbreviation</h3>
<div class="bs-example" data-example-id="simple-abbr">
<p>An abbreviation of the word attribute is <abbr title="attribute">attr</abbr>.</p>
</div>
<div class="highlight-html"><xmp>
<abbr title="attribute">attr</abbr>
</xmp></div> <!-- end highlight -->
<h3>Initialism</h3>
<p>Add <code>.initialism</code> to an abbreviation for a slightly smaller font-size.</p>
<div class="bs-example" data-example-id="simple-initialism">
<p><abbr title="HyperText Markup Language" class="initialism">HTML</abbr> is the best thing since sliced bread.</p>
</div>
<div class="highlight-html"><xmp>
<abbr title="HyperText Markup Language" class="initialism">HTML</abbr>
</xmp></div> <!-- end highlight -->
<!-- Addresses -->
<h2 id="type-addresses">Addresses</h2>
<p>Present contact information for the nearest ancestor or the entire body of work. Preserve formatting by ending all lines with <code>&lt;br&gt;</code>.</p>
<div class="bs-example" data-example-id="simple-address">
<address>
<strong>Twitter, Inc.</strong><br>
795 Folsom Ave, Suite 600<br>
San Francisco, CA 94107<br>
<abbr title="Phone">P:</abbr> (123) 456-7890
</address>
<address>
<strong>Full Name</strong><br>
<a href="mailto:#">first.last@example.com</a>
</address>
</div>
<div class="highlight-html"><xmp>
<address>
<strong>Twitter, Inc.</strong><br>
795 Folsom Ave, Suite 600<br>
San Francisco, CA 94107<br>
<abbr title="Phone">P:</abbr> (123) 456-7890
</address>
<address>
<strong>Full Name</strong><br>
<a href="mailto:#">first.last@example.com</a>
</address>
</xmp></div> <!-- end highlight -->
<!-- Blockquotes -->
<h2 id="type-blockquotes">Blockquotes</h2>
<p>For quoting blocks of content from another source within your document.</p>
<h3>Default blockquote</h3>
<p>Wrap <code>&lt;blockquote&gt;</code> around any <abbr title="HyperText Markup Language">HTML</abbr> as the quote. For straight quotes, we recommend a <code>&lt;p&gt;</code>.</p>
<div class="bs-example" data-example-id="simple-blockquote">
<blockquote>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere erat a ante.</p>
</blockquote>
</div>
<div class="highlight-html"><xmp>
<blockquote>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere erat a ante.</p>
</blockquote>
</xmp></div> <!-- end highlight -->
<h3>Blockquote options</h3>
<p>Style and content changes for simple variations on a standard <code>&lt;blockquote&gt;</code>.</p>
<h4>Naming a source</h4>
<p>Add a <code>&lt;footer&gt;</code> for identifying the source. Wrap the name of the source work in <code>&lt;cite&gt;</code>.</p>
<div class="bs-example" data-example-id="blockquote-cite">
<blockquote>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere erat a ante.</p>
<footer>Someone famous in <cite title="Source Title">Source Title</cite></footer>
</blockquote>
</div>
<div class="highlight-html"><xmp>
<blockquote>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere erat a ante.</p>
<footer>Someone famous in <cite title="Source Title">Source Title</cite></footer>
</blockquote>
</xmp></div> <!-- end highlight -->
<h4>Alternate displays</h4>
<p>Add <code>.blockquote-reverse</code> for a blockquote with right-aligned content.</p>
<div class="bs-example" style="overflow: hidden;" data-example-id="blockquote-reverse">
<blockquote class="blockquote-reverse">
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere erat a ante.</p>
<footer>Someone famous in <cite title="Source Title">Source Title</cite></footer>
</blockquote>
</div>
<div class="highlight-html"><xmp>
<blockquote class="blockquote-reverse">
...
</blockquote>
</xmp></div> <!-- end highlight -->
<h2>Tooltip</h2>
<p>Any element with a class <code>tooltip</code> and a <code>title</code> attribute will replaced with the custom tooltip via Javascript. <br />Tooltips should be used with care as touch devices won't activate them.
</p>
<div class="bs-example">
<p class="tooltip" title="I am a tooltip in a `p`">Hover me, please!</p>
</div>
<!-- Lists -->
<h2 id="type-lists">Lists</h2>
<h3>Unordered</h3>
<p>A list of items in which the order does <em>not</em> explicitly matter.</p>
<div class="bs-example" data-example-id="simple-ul">
<ul>
<li>Lorem ipsum dolor sit amet</li>
<li>Consectetur adipiscing elit</li>
<li>Integer molestie lorem at massa</li>
<li>Facilisis in pretium nisl aliquet</li>
<li>Nulla volutpat aliquam velit
<ul>
<li>Phasellus iaculis neque</li>
<li>Purus sodales ultricies</li>
<li>Vestibulum laoreet porttitor sem</li>
<li>Ac tristique libero volutpat at</li>
</ul>
</li>
<li>Faucibus porta lacus fringilla vel</li>
<li>Aenean sit amet erat nunc</li>
<li>Eget porttitor lorem</li>
</ul>
</div>
<div class="highlight-html"><xmp>
<ul>
<li>...</li>
</ul>
</xmp></div> <!-- end highlight -->
<h3>Ordered</h3>
<p>A list of items in which the order <em>does</em> explicitly matter.</p>
<div class="bs-example" data-example-id="simple-ol">
<ol>
<li>Lorem ipsum dolor sit amet</li>
<li>Consectetur adipiscing elit</li>
<li>Integer molestie lorem at massa</li>
<li>Facilisis in pretium nisl aliquet</li>
<li>Nulla volutpat aliquam velit</li>
<li>Faucibus porta lacus fringilla vel</li>
<li>Aenean sit amet erat nunc</li>
<li>Eget porttitor lorem</li>
</ol>
</div>
<div class="highlight-html"><xmp>
<ol>
<li>...</li>
</ol>
</xmp></div> <!-- end highlight -->
<h3>Unstyled</h3>
<p>Remove the default <code>list-style</code> and left margin on list items (immediate children only). <strong>This only applies to immediate children list items</strong>, meaning you will need to add the class for any nested lists as well.< /p>
<div class="bs-example" data-example-id="unstyled-list">
<ul class="list-unstyled">
<li>Lorem ipsum dolor sit amet</li>
<li>Consectetur adipiscing elit</li>
<li>Integer molestie lorem at massa</li>
<li>Facilisis in pretium nisl aliquet</li>
<li>Nulla volutpat aliquam velit
<ul>
<li>Phasellus iaculis neque</li>
<li>Purus sodales ultricies</li>
<li>Vestibulum laoreet porttitor sem</li>
<li>Ac tristique libero volutpat at</li>
</ul>
</li>
<li>Faucibus porta lacus fringilla vel</li>
<li>Aenean sit amet erat nunc</li>
<li>Eget porttitor lorem</li>
</ul>
</div>
<div class="highlight-html"><xmp>
<ul class="list-unstyled">
<li>...</li>
</ul>
</xmp></div> <!-- end highlight -->
<h3>Inline</h3>
<p>Place all list items on a single line with <code>display: inline-block;</code> and some light padding.</p>
<div class="bs-example" data-example-id="list-inline">
<ul class="list-inline">
<li>Lorem ipsum</li>
<li>Phasellus iaculis</li>
<li>Nulla volutpat</li>
</ul>
</div>
<div class="highlight-html"><xmp>
<ul class="list-inline">
<li>...</li>
</ul>
</xmp></div> <!-- end highlight -->
<h3>Description</h3>
<p>A list of terms with their associated descriptions.</p>
<div class="bs-example" data-example-id="simple-dl">
<dl>
<dt>Description lists</dt>
<dd>A description list is perfect for defining terms.</dd>
<dt>Euismod</dt>
<dd>Vestibulum id ligula porta felis euismod semper eget lacinia odio sem nec elit.</dd>
<dd>Donec id elit non mi porta gravida at eget metus.</dd>
<dt>Malesuada porta</dt>
<dd>Etiam porta sem malesuada magna mollis euismod.</dd>
</dl>
</div>
<div class="highlight-html"><xmp>
<dl>
<dt>...</dt>
<dd>...</dd>
</dl>
</xmp></div> <!-- end highlight -->
<h4>Horizontal description</h4>
<p>Make terms and descriptions in <code>&lt;dl&gt;</code> line up side-by-side. Starts off stacked like default <code>&lt;dl&gt;</code>s, but when the navbar expands, so do these. This really only looks good if there is one line for the definition and one for the term.</p>
<div class="bs-example" data-example-id="horizontal-dl">
<dl class="dl-horizontal">
<dt>Description lists</dt>
<dd>A description list is perfect for defining terms.</dd>
<dt>Donec id elit non mi porta gravida at eget metus.</dt>
<dd>Vestibulum id ligula porta felis euismod semper eget lacinia odio sem nec elit.</dd>
<dd>Donec id elit non mi porta gravida at eget metus.</dd>
<dt>Malesuada porta</dt>
<dd>Etiam porta sem malesuada magna mollis euismod.</dd>
<dt>Felis euismod semper eget lacinia</dt>
<dd>Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus.</dd>
</dl>
</div>
<div class="highlight-html"><xmp>
<dl class="dl-horizontal">
<dt>...</dt>
<dd>...</dd>
</dl>
</xmp></div> <!-- end highlight -->
</div>
</div>
</div>
</%def>