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

getting-started.html « docs - github.com/picturepan2/spectre.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 7b6e6ed38075502dd8aa28c3260b2c286a26939f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta name="robots" content="index, follow">
  <meta name="viewport" content="width=device-width, initial-scale=1.0, shrink-to-fit=no">
  <meta http-equiv="x-ua-compatible" content="ie=edge">
  <meta name="author" content="https://github.com/picturepan2/">
  <title>Getting started - Spectre.css CSS Framework</title>
  <link rel="stylesheet" href="dist/spectre.css">
  <link rel="stylesheet" href="dist/spectre-icons.css">
  <link rel="stylesheet" href="dist/spectre-exp.css">
  <link rel="stylesheet" href="css/docs.css">
</head>
<body>
  <div class="docs-container off-canvas">
    <div class="docs-navbar">
      <a class="off-canvas-toggle btn btn-link btn-action" href="#sidebar">
        <i class="icon icon-menu"></i>
      </a>
      <a href="https://github.com/picturepan2/spectre" target="_blank" class="btn btn-primary">GitHub</a>
    </div>

    <div id="sidebar" class="docs-sidebar off-canvas-sidebar">
      <div class="docs-brand">
        <a href="index.html" class="docs-logo">
          <img src="img/spectre-logo.svg" alt="Spectre.css CSS Framework">
          <h2>Spectre.css</h2>
        </a>
      </div>
      <div class="docs-nav">
        <div class="accordion-container">
          <div class="accordion">
            <input type="checkbox" id="docs-accordion-1" name="docs-accordion-checkbox" hidden checked>
            <label class="accordion-header c-hand" for="docs-accordion-1">
              Getting started
            </label>
            <div class="accordion-body">
              <ul class="menu menu-nav">
                <li class="menu-item">
                  <a href="getting-started.html#introduction">Introduction</a>
                </li>
                <li class="menu-item">
                  <a href="getting-started.html#installation">Installation</a>
                </li>
                <li class="menu-item">
                  <a href="getting-started.html#custom">Custom version</a>
                </li>
                <li class="menu-item">
                  <a href="getting-started.html#browsers">Browser support</a>
                </li>
                <li class="menu-item">
                  <a href="getting-started.html#whatsnew">What's new</a>
                </li>
              </ul>
            </div>
          </div>
          <div class="accordion">
            <input type="checkbox" id="docs-accordion-2" name="docs-accordion-checkbox" hidden>
            <label class="accordion-header c-hand" for="docs-accordion-2">
              Elements
            </label>
            <div class="accordion-body">
              <ul class="menu menu-nav">
                <li class="menu-item">
                  <a href="elements.html#typography">Typography</a>
                </li>
                <li class="menu-item">
                  <a href="elements.html#tables">Tables</a>
                </li>
                <li class="menu-item">
                  <a href="elements.html#buttons">Buttons</a>
                </li>
                <li class="menu-item">
                  <a href="elements.html#forms">Forms</a>
                </li>
                <li class="menu-item">
                  <a href="elements.html#icons">Icons</a>
                </li>
                <li class="menu-item">
                  <a href="elements.html#labels">Labels</a>
                </li>
                <li class="menu-item">
                  <a href="elements.html#codes">Codes</a>
                </li>
                <li class="menu-item">
                  <a href="elements.html#media">Media</a>
                </li>
              </ul>
            </div>
          </div>
          <div class="accordion">
            <input type="checkbox" id="docs-accordion-3" name="docs-accordion-checkbox" hidden>
            <label class="accordion-header c-hand" for="docs-accordion-3">
              Layout
            </label>
            <div class="accordion-body">
              <ul class="menu menu-nav">
                <li class="menu-item">
                  <a href="layout.html#grid">Flexbox grid</a>
                </li>
                <li class="menu-item">
                  <a href="layout.html#responsive">Responsive</a>
                </li>
                <li class="menu-item">
                  <a href="layout.html#navbar">Navbar</a>
                </li>
              </ul>
            </div>
          </div>
          <div class="accordion">
            <input type="checkbox" id="docs-accordion-4" name="docs-accordion-checkbox" hidden>
            <label class="accordion-header c-hand" for="docs-accordion-4">
              Components
            </label>
            <div class="accordion-body">
              <ul class="menu menu-nav">
                <li class="menu-item">
                  <a href="components.html#accordions">Accordions</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#autocomplete">Autocomplete</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#avatars">Avatars</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#badges">Badges</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#bars">Bars</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#breadcrumbs">Breadcrumbs</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#cards">Cards</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#chips">Chips</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#empty">Empty states</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#menus">Menus</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#modals">Modals</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#navs">Navs</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#pagination">Pagination</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#panels">Panels</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#popovers">Popovers</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#steps">Steps</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#tabs">Tabs</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#tiles">Tiles</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#toasts">Toasts</a>
                </li>
                <li class="menu-item">
                  <a href="components.html#tooltips">Tooltips</a>
                </li>
              </ul>
            </div>
          </div>
          <div class="accordion">
            <input type="checkbox" id="docs-accordion-5" name="docs-accordion-checkbox" hidden>
            <label class="accordion-header c-hand" for="docs-accordion-5">
              Utilities
            </label>
            <div class="accordion-body">
              <ul class="menu menu-nav">
                <li class="menu-item">
                  <a href="utilities.html#colors">Colors</a>
                </li>
                <li class="menu-item">
                  <a href="utilities.html#cursors">Cursors</a>
                </li>
                <li class="menu-item">
                  <a href="utilities.html#display">Display</a>
                </li>
                <li class="menu-item">
                  <a href="utilities.html#divider">Divider</a>
                </li>
                <li class="menu-item">
                  <a href="utilities.html#loading">Loading</a>
                </li>
                <li class="menu-item">
                  <a href="utilities.html#position">Position</a>
                </li>
                <li class="menu-item">
                  <a href="utilities.html#shapes">Shapes</a>
                </li>
                <li class="menu-item">
                  <a href="utilities.html#text">Text</a>
                </li>
              </ul>
            </div>
          </div>
          <div class="accordion">
            <input type="checkbox" id="docs-accordion-6" name="docs-accordion-checkbox" hidden>
            <label class="accordion-header c-hand" for="docs-accordion-6">
              Experimentals
            </label>
            <div class="accordion-body">
              <ul class="menu menu-nav">
                <li class="menu-item">
                  <a href="experimentals.html#calendars">Calendars</a>
                </li>
                <li class="menu-item">
                  <a href="experimentals.html#carousels">Carousels</a>
                </li>
                <li class="menu-item">
                  <a href="experimentals.html#comparison">Comparison sliders</a>
                </li>
                <li class="menu-item">
                  <a href="experimentals.html#filters">Filters</a>
                </li>
                <li class="menu-item">
                  <a href="experimentals.html#meters">Meters</a>
                </li>
                <li class="menu-item">
                  <a href="experimentals.html#off-canvas">Off-canvas</a>
                </li>
                <li class="menu-item">
                  <a href="experimentals.html#parallax">Parallax</a>
                </li>
                <li class="menu-item">
                  <a href="experimentals.html#progress">Progress</a>
                </li>
                <li class="menu-item">
                  <a href="experimentals.html#sliders">Sliders</a>
                </li>
                <li class="menu-item">
                  <a href="experimentals.html#timelines">Timelines</a>
                </li>
              </ul>
            </div>
          </div>
        </div>
      </div>
    </div>

    <a class="off-canvas-overlay" href="#close"></a>

    <div id="content" class="docs-content off-canvas-content">
      <div id="introduction" class="container">
        <h3 class="s-title"><a href="#introduction" class="anchor" aria-hidden="true">#</a>Introduction</h3>
        <div class="docs-note">
          <p><strong>Spectre.css</strong> is a lightweight, responsive and modern CSS framework for faster and extensible development.</p>
          <p>Spectre provides basic styles for typography and elements, flexbox based responsive layout system, CSS components and utilities with best practice coding and consistent design language.</p>
        </div>
      </div>

      <div class="container">
        <div class="docs-ad">
          <div class="hide-md">
            <script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
            <!-- GitHub-lg -->
            <ins class="adsbygoogle"
                  style="display:inline-block;width:728px;height:90px"
                  data-ad-client="ca-pub-2225124559530218"
                  data-ad-slot="9894180784"></ins>
            <script>
            (adsbygoogle = window.adsbygoogle || []).push({});
            </script>
          </div>
          <div class="show-md">
            <!-- GitHub-sm -->
            <ins class="adsbygoogle"
                  style="display:inline-block;width:300px;height:250px"
                  data-ad-client="ca-pub-2225124559530218"
                  data-ad-slot="9278881734"></ins>
            <script>
            (adsbygoogle = window.adsbygoogle || []).push({});
            </script>
          </div>
        </div>
      </div>

      <div id="installation" class="container">
        <h3 class="s-title"><a href="#installation" class="anchor" aria-hidden="true">#</a>Installation</h3>
        <div class="docs-note">
          <p>There are 5 ways to get started with Spectre CSS framework in your projects. You can either install manually, from CDN or use package managers.</p>
        </div>
        <div class="docs-note">
          <p class="h5">Install manually</p>
          <p>Download the compiled and minified <a href="https://github.com/picturepan2/spectre/releases" target="_blank">Spectre CSS file</a> (core ~10KB min+gzip):</p>
          <p><a href="https://github.com/picturepan2/spectre/releases" target="_blank" class="btn btn-primary">Download Spectre.css</a></p>
          <p>Include <code>spectre.css</code> located in <strong>/docs/dist</strong> in your website or Web app &lt;head&gt;. Also, you can add <code>spectre-icons.css</code> and <code>spectre-exp.css</code> accordingly.</p>
        </div>

<!-- install manually -->
<pre class="code" data-lang="HTML"><code>&lt;<span class="tag">link</span> <span class="atn">rel</span>=<span class="atv">&quot;stylesheet&quot;</span> <span class="atn">href</span>=<span class="atv">&quot;spectre.min.css&quot;</span>&gt;
&lt;<span class="tag">link</span> <span class="atn">rel</span>=<span class="atv">&quot;stylesheet&quot;</span> <span class="atn">href</span>=<span class="atv">&quot;spectre-exp.min.css&quot;</span>&gt;
&lt;<span class="tag">link</span> <span class="atn">rel</span>=<span class="atv">&quot;stylesheet&quot;</span> <span class="atn">href</span>=<span class="atv">&quot;spectre-icons.min.css&quot;</span>&gt;
</code></pre>

        <div class="docs-note">
          <p class="h5">Install from CDN</p>
          <p>Alternatively, you can use the <a href="https://unpkg.com/" target="_blank">unpkg</a> or <a href="https://cdnjs.com/libraries/spectre.css" target="_blank">cdnjs</a> CDN to load compiled Spectre.css.</p>
        </div>

<!-- install from CDN -->
<pre class="code" data-lang="HTML"><code>&lt;<span class="tag">link</span> <span class="atn">rel</span>=<span class="atv">&quot;stylesheet&quot;</span> <span class="atn">href</span>=<span class="atv">&quot;https://unpkg.com/spectre.css/dist/spectre.min.css&quot;</span>&gt;
&lt;<span class="tag">link</span> <span class="atn">rel</span>=<span class="atv">&quot;stylesheet&quot;</span> <span class="atn">href</span>=<span class="atv">&quot;https://unpkg.com/spectre.css/dist/spectre-exp.min.css&quot;</span>&gt;
&lt;<span class="tag">link</span> <span class="atn">rel</span>=<span class="atv">&quot;stylesheet&quot;</span> <span class="atn">href</span>=<span class="atv">&quot;https://unpkg.com/spectre.css/dist/spectre-icons.min.css&quot;</span>&gt;
</code></pre>

        <div class="docs-note">
          <p class="h5">Install with NPM</p>
        </div>

<!-- install with npm -->
<pre class="code" data-lang="Bash"><code><span class="tag">$</span>npm install <span class="atv">spectre.css</span> --save
</code></pre>

        <div class="docs-note">
          <p class="h5">Install with Yarn</p>
        </div>

<!-- install with yarn -->
<pre class="code" data-lang="Bash"><code><span class="tag">$</span>yarn add <span class="atv">spectre.css</span>
</code></pre>

        <div class="docs-note">
          <p class="h5">Install with Bower</p>
        </div>

<!-- install with bower -->
<pre class="code" data-lang="Bash"><code><span class="tag">$</span>bower install <span class="atv">spectre.css</span> --save
</code></pre>

      </div>

      <div id="custom" class="container">
        <h3 class="s-title"><a href="#custom" class="anchor" aria-hidden="true">#</a>Custom version</h3>
        <div class="docs-note">
          <p>You can customize your version of Spectre.css by editing SASS files in <code>/src</code> directory or removing unneeded components from <code>.scss</code> source files.</p>
          <p><a href="https://github.com/picturepan2/spectre/" target="_blank" class="btn btn-primary">SASS Source Code</a></p>
          <p>If you are looking for LESS version of Spectre.css, please switch to <code>LESS</code> branch.</p>
          <p><a href="https://github.com/picturepan2/spectre/tree/less" target="_blank" class="btn">LESS Branch</a></p>
        </div>
        <h4 id="compiling" class="s-subtitle">Compiling CSS</h4>
        <div class="docs-note">
          <p>Spectre uses <a href="http://gulpjs.com/" target="_blank">Gulp</a> for compiling CSS. Firstly you need to <a href="https://www.npmjs.com/get-npm" target="_blank">install NPM</a>, which is used to manage Gulp and other dependencies.</p>
          <p>Then, you can build the CSS file from the command line:</p>
          <ol>
            <li>Navigate to the root directory of Spectre.</li>
            <li>Run <code>npm install</code>. NPM will install all dev dependencies as listed in package.json.</li>
            <li>When completed, run <code>gulp build</code> task to compile SASS to CSS and minify files.</li>
            <li>You can find compiled CSS files in <code>/dist</code> directory.</li>
          </ol>
          <p>All available Gulp tasks:</p>
          <ul>
            <li><code>gulp build</code> - compile SASS to CSS and minify files (default)</li>
            <li><code>gulp docs</code> - compile Docs related files</li>
            <li><code>gulp watch</code> - watch file changes and re-compile CSS files</li>
          </ul>
        </div>
        <h4 id="importing" class="s-subtitle">Importing SASS</h4>
        <div class="docs-note">
          <p>It is recommended to custom Spectre by importing SASS source files to your projects. In this way, you can keep Spectre up to date without conflicts, since Spectre code and your custom code are separate.</p>
          <ul>
            <li>First, create your own project and install Spectre via <a href="#installation">NPM or other package managers</a>.</li>
            <li>Then create your <code>project-name.scss</code> file in the root folder. You can use <code>project-name.scss</code> to define your variables.</li>
            <li>Compile the SASS file to CSS to get the custom version of Spectre.</li>
          </ul>

<!-- importing -->
<pre class="code" data-lang="SASS"><code><span class="com">// Example of project-name.scss</span>
<span class="com">// Define variables to override default ones</span>
<span class="tag">$primary-color</span>: <span class="atn"></span>#2e5bec</span>;
<span class="tag">$dark-color</span>: <span class="atn"></span>#3e396b</span>;

<span class="com">// Import full Spectre source code</span>
<span class="tag">@import</span> &quot;node_modules/spectre.css/src/spectre&quot;;
</code></pre>

          <p>Alternatively, you can create custom <code>_variables.scss</code> and import it to <code>project-name.scss</code>. </p>

<!-- importing -->
<pre class="code" data-lang="SASS"><code><span class="com">// Example of project-name.scss</span>
<span class="tag">@import</span> &quot;variables&quot;;

<span class="com">// Import only the needed components</span>
<span class="tag">@import</span> &quot;node_modules/spectre.css/src/buttons&quot;;
<span class="tag">@import</span> &quot;node_modules/spectre.css/src/forms&quot;;
</code></pre>

        </div>

        <h4 id="folders" class="s-subtitle">Folder Structure</h4>

<!-- folder structure -->
<pre class="code"><code>spectre/
├── dist/                           <span class="com">// Build folder (Git ignored)</span>
│   ├── spectre-exp.css
│   ├── spectre-exp.min.css
│   ├── spectre-icons.css
│   ├── spectre-icons.min.css
│   ├── spectre.css
│   └── spectre.min.css
│
├── docs/
│   ├── dist/                       <span class="com">// Pre-built CSS folder</span>
│   │   ├── spectre-exp.css
│   │   ├── spectre-exp.min.css
│   │   ├── spectre-icons.css
│   │   ├── spectre-icons.min.css
│   │   ├── spectre.css
│   │   └── spectre.min.css
|   ├── css/                        <span class="com">// Docs CSS file</span>
│   │   └── docs.css
|   ├── src/
│   │   └── docs.scss
│   ├── examples/                   <span class="com">// Example tempalte</span>
│   │   └── starter.html
│   ├── ../
│   ├── index.html
│   └── ...
│
├── src/                            <span class="com">// Source SASS files</span>
│   ├── spectre.scss
│   ├── spectre-icons.scss
│   ├── spectre-exp.scss
│   ├── _mixins.scss
│   ├── _variables.scss
│   └── ...
│
├── gulpfile.js
├── package.json
└── ...
</code></pre>

        <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 use your own variables to create your new or match existing design. All variables in <code>_variables.scss</code> include <code>!default</code> flag. You can redefine the variables to override the values.</p>
        </div>
        <h5 id="variables-colors" class="s-subtitle">Colors</h5>
        <div class="columns">
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#5755d9;color:#fff;">
              <div class="color-title">#5755d9</div>
              <div class="color-subtitle">Primary</div>
            </div>
          </div>
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#f1f1fc;color:#5755d9;">
              <div class="color-title">#f1f1fc</div>
              <div class="color-subtitle">Secondary</div>
            </div>
          </div>
        </div>
        <div class="columns">
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#32b643;color:#fff;">
              <div class="color-title">#32b643</div>
              <div class="color-subtitle">Success</div>
            </div>
          </div>
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#ffb700;color:#fff;">
              <div class="color-title">#ffb700</div>
              <div class="color-subtitle">Warning</div>
            </div>
          </div>
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#e85600;color:#fff;">
              <div class="color-title">#e85600</div>
              <div class="color-subtitle">Error</div>
            </div>
          </div>
        </div>
        <div class="columns">
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#454d5d;color:#fff;">
              <div class="color-title">#454d5d</div>
              <div class="color-subtitle">Dark</div>
            </div>
          </div>
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#727e96;color:#fff;">
              <div class="color-title">#727e96</div>
              <div class="color-subtitle">Gray dark</div>
            </div>
          </div>
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#acb3c2;color:#fff;">
              <div class="color-title">#acb3c2</div>
              <div class="color-subtitle">Gray</div>
            </div>
          </div>
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#e7e9ed;color:#727e96;">
              <div class="color-title">#e7e9ed</div>
              <div class="color-subtitle">Gray light</div>
            </div>
          </div>
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#f0f1f4;color:#727e96;">
              <div class="color-title">#f0f1f4</div>
              <div class="color-subtitle">Border</div>
            </div>
          </div>
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#f8f9fa;color:#727e96;">
              <div class="color-title">#f8f9fa</div>
              <div class="color-subtitle">Background</div>
            </div>
          </div>
          <div class="column col-3 col-md-6">
            <div class="docs-color" style="background:#fff;color:#727e96;">
              <div class="color-title">#fff</div>
              <div class="color-subtitle">Light</div>
            </div>
          </div>
        </div>

        <h5 id="variables-buttons" class="s-subtitle">Buttons</h5>
        <div class="docs-note">
          <p>There are 2 button variant mixins in <code>_mixins.scss</code> to generate different color variants. </p>
          <ul>
            <li>@mixin button-variant(<code>$color</code>: $primary-color);</li>
            <li>@mixin button-outline-variant(<code>$color</code>: $primary-color);</li>
          </ul>

<!-- button variables -->
<pre class="code" data-lang="SASS"><code><span class="com">&lt;!-- filled button with the success color --&gt;</span>
<span class="tag">.btn-success</span> {
  <span class="tag">@include</span> button-variant(<span class="atv">$success-color</span>);
}

<span class="com">&lt;!-- outlined button with the success color --&gt;</span>
<span class="tag">.btn-outline-success</span> {
  <span class="tag">@include</span> button-outline-variant(<span class="atv">$success-color</span>);
}
</code></pre>

        </div>
        
        <h5 id="variables-sizes" 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 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 id="variables-custom-prefix" 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 -->
<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 -->
<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>

      <div id="accessibility" class="container">
        <h3 class="s-title"><a href="#accessibility" class="anchor" aria-hidden="true">#</a>Accessibility <small class="label">coming soon</small></h3>
      </div>

      <div id="browsers" class="container">
        <h3 class="s-title"><a href="#browsers" class="anchor" aria-hidden="true">#</a>Browser support</h3>
        <div class="docs-note">
          <p>Spectre uses <a href="https://github.com/postcss/autoprefixer" target="_blank">Autoprefixer</a> to make most styles compatible with earlier browsers and <a href="https://necolas.github.io/normalize.css/" target="_blank">Normalize.css</a> for CSS resets. Spectre is designed for modern browsers. For best compatibility, these browsers are recommended:</p>
          <ul>
            <li>Chrome <small class="label label-success">LAST 4</small></li>
            <li>Microsoft Edge <small class="label label-success">LAST 4</small></li>
            <li>Firefox <small class="label label-success text-uppercase">Extended Support Release</small></li>
            <li>Safari <small class="label label-success">LAST 4</small></li>
            <li>Opera <small class="label label-success">LAST 4</small></li>
            <li>Internet Explorer 10+</li>
          </ul>
        </div>
      </div>

      <div id="whatsnew" class="container">
        <h3 class="s-title"><a href="#whatsnew" class="anchor" aria-hidden="true">#</a>What's new</h3>
        <div class="docs-note">
          <p><strong>September 2017</strong></p>
          <ul>
            <li>
              <a href="experimentals.html#off-canvas">Off-canvas</a>: navigation layout that the sidebar can slide in and out of the viewport <small class="label label-primary">NEW</small>
            </li>
          </ul>
          <p><strong>August 2017</strong></p>
          <ul>
            <li>
              <a href="getting-started.html">Switch to SASS</a> <small class="label label-primary">NEW</small>
            </li>
            <li>
              <a href="getting-started.html">New Docs Experience</a> <small class="label label-primary">NEW</small>
            </li>
          </ul>
          <p><strong>April 2017</strong></p>
          <ul>
            <li>
              <a href="components.html#accordions">Accordions</a>: used to toggle sections of content 
            </li>
            <li>
              <a href="experimentals.html#filters">Filters</a>: CSS only content filters 
            </li>
            <li>
              <a href="experimentals.html#comparison">Comparison Sliders</a>: sliders for comparing two images
            </li>
            <li>
              <a href="experimentals.html#timelines">Timelines</a>: ordered sequences of activities
            </li>
          </ul>
          <p><strong>March 2017</strong></p>
          <ul>
            <li>
              <a href="elements.html#icons">Icons</a>: single-element, responsive and pure CSS icons
            </li>
            <li>
              <a href="components.html#popovers">Popovers</a>: small overlay content containers
            </li>
            <li>
              <a href="layout.html#panels">Panels</a>: flexible view container layout with auto-expand content section
            </li>
            <li>
              <a href="experimentals.html#carousels">Carousels</a>: slideshows for cycling images
            </li>
            <li>
              <a href="experimentals.html#calendars">Calendars</a>: date or date range picker and events display
            </li>
          </ul>
          <p><strong>February 2017</strong></p>
          <ul>
            <li>New Documents experience</li>
            <li>
              <a href="components.html#bars">Bars</a>: represent the progress of a task or the value within the known range
            </li>
            <li>
              <a href="components.html#steps">Steps</a>: progress indicators of a sequence of task steps
            </li>
            <li>
              <a href="components.html#tiles">Tiles</a>: repeatable or embeddable information blocks
            </li>
            <li>
              <a href="experimentals.html">Experimentals</a>: experimental elements and features
            </li>
            <li>
              <a href="experimentals.html#meters">Meters</a>, <a href="experimentals.html#parallax">Parallax</a>, <a href="experimentals.html#progress">Progress</a> and <a href="experimentals.html#sliders">Sliders</a>
            </li>
          </ul>
          <p><strong>March 2016</strong></p>
          <ul>
            <li>Initial commit</li>
          </ul>
          <p><a href="https://github.com/picturepan2/spectre/releases" target="_blank" class="btn btn-primary">Releases</a></p>
        </div>
      </div>

      <footer class="docs-footer">
        <p><a href="https://github.com/picturepan2/spectre" target="_blank">GitHub</a> | <a href="https://twitter.com/spectrecss" target="_blank">Twitter</a> | <a href="https://www.paypal.me/picturepan2" target="_blank">PayPal Donate</a> | Version <span class="version"></span></p>
        <p>Designed and built with ♥ by <a href="https://twitter.com/picturepan2" target="_blank">Yan Zhu</a>. Licensed under the <a href="https://github.com/picturepan2/spectre/blob/master/LICENSE" target="_blank">MIT License</a>.</p>
      </footer>

    </div>
  </div>

  <script>
      (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
                  (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
              m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
      })(window,document,'script','https://www.google-analytics.com/analytics.js','ga');

      ga('create', 'UA-2702768-8', 'auto');
      ga('send', 'pageview');
  </script>
</body>
</html>