Summary Files Commits Branches @commit @diff @stats
path: root / docs / getting-started.html
diff options
context:
space:
mode:
Commit82e0eef89b185eddbdee9b43beab76d3effa7501 (patch)
Author
 Yan Zhu <picturepan2@hotmail.com>
2017-08-16 18:33:44 +0800
Committer
 Yan Zhu <picturepan2@hotmail.com>
2017-08-16 18:33:44 +0800
Filesd2e1af1b8d6424700b6f8ca620525d0cd99e0cb1 /docs/getting-started.html
Spectre-Dark-Gruvbox-82e0eef89b185eddbdee9b43beab76d3effa7501.tar
Spectre-Dark-Gruvbox-82e0eef89b185eddbdee9b43beab76d3effa7501.tar.gz
Spectre-Dark-Gruvbox-82e0eef89b185eddbdee9b43beab76d3effa7501.zip
Parente1889c840e060b51e4b551a3e30f142ce4b9ec2b (diff)
Rename display utilities and add custom prefix
1 files changed, 30 insertions, 4 deletions
-rw-r--r--docs/getting-started.html34
diff --git a/docs/getting-started.html b/docs/getting-started.html
index 5a1afc1..124890d 100644
--- a/docs/getting-started.html
+++ b/docs/getting-started.html
@@ -364,9 +364,9 @@
<h4 id="variables" class="s-subtitle"><a href="#variables" class="anchor" aria-hidden="true">#</a>Variables</h4>
<div class="docs-note">
- <p>Spectre.css is designed with consistent design language. You can modify <code>variables.less</code> to create your new or match existing design.
+ <p>Spectre.css is designed with consistent design language. You can modify <code>variables.less</code> to create your new or match existing design.</p>
</div>
- <h5 class="s-subtitle">Colors</h5>
+ <h5 class="s-subtitle">Colors</h5>
<div class="columns">
<div class="column col-3 col-md-6">
<div class="docs-color" style="background:#5764c6;color:#fff;">
@@ -448,8 +448,34 @@
<h5 class="s-subtitle">Sizes</h5>
<div class="docs-note">
<p>The default REM (root em) size in Spectre.css is <code>20px</code>. </p>
- <p>Please note in Chinese/Japanese/Korean Chrome, Chrome uses 12px as default minimum font size. That is why Spectre sets rem default html font size to <code>20px</code>, which is relatively easy to calculate. </p>
- <p>Spectre also use <code>4px</code> as the unit size. Sizes of components are based on the unit size. </p>
+ <p>Please note in the Chinese/Japanese/Korean version, Chrome uses 12px as default minimum font size. That is why Spectre sets rem default html font size to <code>20px</code>, which is relatively easy to calculate. </p>
+ <p>Spectre uses <code>4px</code> as the unit size. Sizes of components are based on the unit size. </p>
+ </div>
+ <h5 class="s-subtitle">Custom prefix</h5>
+ <div class="docs-note">
+ <p>There is also a way to add custom prefix to all CSS classes. You can use <a href="https://www.npmjs.com/package/gulp-css-prefix" target="_blank">gulp-css-prefix</a> plugin and add a new Gulp task to enable it. </p>
+ </div>
+
+<!-- custom prefix example -->
+<pre class="code"><code><span class="tag">$</span> npm install <span class="atv">gulp-css-prefix</span>
+</code></pre>
+
+ <div class="docs-note">
+ <p>To add <code>spectre-</code> to all classes, you can add the Gulp task to <code>gulpfile.js</code> file.</p>
+ </div>
+
+<!-- custom prefix example -->
+<pre class="code"><code>var cssPrefix = require('<span class="atv">gulp-css-prefix</span>');
+
+gulp.task('prefix', function() {
+ gulp.src('./dist/*.css')
+ .pipe(cssPrefix('<span class="atv">spectre-</span>'))
+ .pipe(gulp.dest('./dist'))
+});
+</code></pre>
+
+ <div class="docs-note">
+ <p>After you compile your version of Spectre in the /dist, run <code>gulp prefix</code> in the directory of Spectre.</p>
</div>
</div>