Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Otto <markotto@twitter.com>2012-09-03 11:47:48 +0400
committerMark Otto <markotto@twitter.com>2012-09-03 11:47:48 +0400
commit9d5f9eca85b9d413b4389b744bbf57c20c447c2b (patch)
tree2747047d4690afac05dbcd86e3aff2369a045a70
parent69d4c3f9a13df95267deccce9a20c5f822893155 (diff)
fixes #4909: add color utility classes .text-warning, etc and document them
-rw-r--r--docs/assets/css/bootstrap.css16
-rw-r--r--docs/base-css.html21
-rw-r--r--docs/templates/pages/base-css.mustache21
-rw-r--r--less/type.less14
4 files changed, 68 insertions, 4 deletions
diff --git a/docs/assets/css/bootstrap.css b/docs/assets/css/bootstrap.css
index d64ff51ab9..ccafb83bb4 100644
--- a/docs/assets/css/bootstrap.css
+++ b/docs/assets/css/bootstrap.css
@@ -609,6 +609,22 @@ cite {
color: #999999;
}
+.text-warning {
+ color: #c09853;
+}
+
+.text-error {
+ color: #b94a48;
+}
+
+.text-info {
+ color: #3a87ad;
+}
+
+.text-success {
+ color: #468847;
+}
+
h1,
h2,
h3,
diff --git a/docs/base-css.html b/docs/base-css.html
index 6240573a9f..dcb1814800 100644
--- a/docs/base-css.html
+++ b/docs/base-css.html
@@ -154,14 +154,14 @@
&lt;/p&gt;
</pre>
- <h3><code>&lt;strong&gt;</code></h3>
+ <h3>Bold</h3>
<p>For emphasizing a snippet of text with <strong>important</strong></p>
<div class="bs-docs-example">
<p>The following snippet of text is <strong>rendered as bold text</strong>.</p>
</div>
<pre class="prettyprint">&lt;strong&gt;rendered as bold text&lt;/strong&gt;</pre>
- <h3><code>&lt;em&gt;</code></h3>
+ <h3>Italics</h3>
<p>For emphasizing a snippet of text with <em>stress</em></p>
<div class="bs-docs-example">
<p>The following snippet of text is <em>rendered as italicized text</em>.</p>
@@ -170,6 +170,23 @@
<p><span class="label label-info">Heads up!</span> 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>
+ <h3>Emphasis classes</h3>
+ <p>Convey meaning through color with a handful of emphasis utility classes.</p>
+ <div class="bs-docs-example">
+ <p class="muted">Fusce dapibus, tellus ac cursus commodo, tortor mauris nibh.</p>
+ <p class="text-warning">Etiam porta sem malesuada magna mollis euismod.</p>
+ <p class="text-error">Donec ullamcorper nulla non metus auctor fringilla.</p>
+ <p class="text-info">Aenean eu leo quam. Pellentesque ornare sem lacinia quam venenatis.</p>
+ <p class="text-success">Duis mollis, est non commodo luctus, nisi erat porttitor ligula.</p>
+ </div>
+<pre class="prettyprint linenums">
+&lt;p class="muted"&gt;Fusce dapibus, tellus ac cursus commodo, tortor mauris nibh.&lt;/p&gt;
+&lt;p class="text-warning"&gt;Etiam porta sem malesuada magna mollis euismod.&lt;/p&gt;
+&lt;p class="text-error"&gt;Donec ullamcorper nulla non metus auctor fringilla.&lt;/p&gt;
+&lt;p class="text-info"&gt;Aenean eu leo quam. Pellentesque ornare sem lacinia quam venenatis.&lt;/p&gt;
+&lt;p class="text-success"&gt;Duis mollis, est non commodo luctus, nisi erat porttitor ligula.&lt;/p&gt;
+</pre>
+
<hr class="bs-docs-separator">
diff --git a/docs/templates/pages/base-css.mustache b/docs/templates/pages/base-css.mustache
index 1a437f112f..1fe63a6092 100644
--- a/docs/templates/pages/base-css.mustache
+++ b/docs/templates/pages/base-css.mustache
@@ -88,14 +88,14 @@
&lt;/p&gt;
</pre>
- <h3><code>&lt;strong&gt;</code></h3>
+ <h3>{{_i}}Bold{{/i}}</h3>
<p>{{_i}}For emphasizing a snippet of text with <strong>important</strong>{{/i}}</p>
<div class="bs-docs-example">
<p>The following snippet of text is <strong>rendered as bold text</strong>.</p>
</div>
<pre class="prettyprint">&lt;strong&gt;rendered as bold text&lt;/strong&gt;</pre>
- <h3><code>&lt;em&gt;</code></h3>
+ <h3>{{_i}}Italics{{/i}}</h3>
<p>{{_i}}For emphasizing a snippet of text with <em>stress</em>{{/i}}</p>
<div class="bs-docs-example">
<p>The following snippet of text is <em>rendered as italicized text</em>.</p>
@@ -104,6 +104,23 @@
<p><span class="label label-info">{{_i}}Heads up!{{/i}}</span> {{_i}}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.{{/i}}</p>
+ <h3>{{_i}}Emphasis classes{{/i}}</h3>
+ <p>{{_i}}Convey meaning through color with a handful of emphasis utility classes.{{/i}}</p>
+ <div class="bs-docs-example">
+ <p class="muted">Fusce dapibus, tellus ac cursus commodo, tortor mauris nibh.</p>
+ <p class="text-warning">Etiam porta sem malesuada magna mollis euismod.</p>
+ <p class="text-error">Donec ullamcorper nulla non metus auctor fringilla.</p>
+ <p class="text-info">Aenean eu leo quam. Pellentesque ornare sem lacinia quam venenatis.</p>
+ <p class="text-success">Duis mollis, est non commodo luctus, nisi erat porttitor ligula.</p>
+ </div>
+<pre class="prettyprint linenums">
+&lt;p class="muted"&gt;Fusce dapibus, tellus ac cursus commodo, tortor mauris nibh.&lt;/p&gt;
+&lt;p class="text-warning"&gt;Etiam porta sem malesuada magna mollis euismod.&lt;/p&gt;
+&lt;p class="text-error"&gt;Donec ullamcorper nulla non metus auctor fringilla.&lt;/p&gt;
+&lt;p class="text-info"&gt;Aenean eu leo quam. Pellentesque ornare sem lacinia quam venenatis.&lt;/p&gt;
+&lt;p class="text-success"&gt;Duis mollis, est non commodo luctus, nisi erat porttitor ligula.&lt;/p&gt;
+</pre>
+
<hr class="bs-docs-separator">
diff --git a/less/type.less b/less/type.less
index 669c55fd59..2e0f386eef 100644
--- a/less/type.less
+++ b/less/type.less
@@ -32,9 +32,23 @@ em {
cite {
font-style: normal;
}
+
+// Utility classes
.muted {
color: @grayLight;
}
+.text-warning {
+ color: @warningText;
+}
+.text-error {
+ color: @errorText;
+}
+.text-info {
+ color: @infoText;
+}
+.text-success {
+ color: @successText;
+}
// Headings