ADRS STYLE GUIDE

Built uppon and extending the Tachyons framework and CSS Flex-Box.

Introduction

This is a quick introduction to the modules and functionality built into the ADRS application. While this style-guide is usefull in of itself, it is meant to be used and understood along side the rendered template files found in the root of this project (basically everything with a .html in the file name). So please also look at the markup of these files in your own implementation.

Notes

Further resources

This toolset is built uppon a subset of the Tachions CSS framework. Check out the Tachyons docs for an in-depth look at how each module works.

A useful Tachyons cheat-sheet can be found here.

Conventions Used

For more info and resources on how this project is structured, and the sass conventions being used, see the SASS Structure Notes, found in the /resources/docs/ directory.

Build Pipeline

The process of concatenating and optimizing JS and SCSS files, as well as images and other resources is outlined in the Project Resources Build Pipeline notes.

Getting Started

Paths

The project build-pipeline generally takes resoruces found in /resources/src/**/* and renders/processes them to the /resources/dist/**/* directory.

Styles

At the time of this writing, there is one master stylesheet which should be included in the <head> of all pages like so:

<link rel='stylesheet' href='/resources/dist/styles/main-public.css'>
JavaScript

In addition to jQuery as a project dependancy, there are two main JS files which contain the bulk of the application's logic. main-public-min.js is for all public faceing logic and is intentionally is as light as possible for fast loading time.

The second file main-app-min.js is much larger and includes all the libraries needed to operate the more complex application logic, including graphing etc. Due to its size, this file should only be downloaded by those people who are logged in. To improve user experience and the perception of speed, larger files can be 'hinted to' for background loading by the browser on pages that don't need them, and only required on pages where these resources are absolutely necessary. In this way by the time a logged in user navigates to a page where these libraries are needed, it is expected that a good portion of the resource is already downloaded into the browser's memory, thereby resulting in a 'snappy' user experience.

All JS scripts should be included before the <body> element at the foot of the document like so:

// Load jQuery from CDN if avalable, else load from server
<script src='https://code.jquery.com/jquery-3.3.1.min.js'
    integrity='sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=' crossorigin='anonymous'></script>
<script>window.jQuery || document.write('<script src=\'/resources/dist/js/jquery-3.3.1-min.js\'><\/script>')</script>

// Load the public JS
<script src='/resources/dist/js/main-public-min.js'></script>

// Preload the heavy application JS on non-application pages, where the user is logged out.
<link rel='prefetch' href='/resources/dist/js/main-app-min.js'>

// And only include it where needed:
<!-- <script src='/resources/dist/js/main-app-min.js'></script> -->
                        

Enabled Tachyons Modules

To keep things as lite and speedy as possible, we're not using the entire Tachyons suite in our bulild. But as previously mentioned, this page's style sheet is hotlinked to the tachyons' CDN. So in the markup on this page, you will find modules not used in the main application.

    
    //  Modules
    @import 'scss/box-sizing';
    // @import 'scss/aspect-ratios';
    @import 'scss/images';
    // @import 'scss/background-size';
    // @import 'scss/background-position';
    @import 'scss/outlines';
    @import 'scss/borders';
    //  @import 'scss/border-colors';
    @import 'scss/border-radius';
    @import 'scss/border-style';
    @import 'scss/border-widths';
    @import 'scss/box-shadow';
    @import 'scss/code';
    // @import 'scss/coordinates';
    @import 'scss/clears';
    @import 'scss/flexbox';
    @import 'scss/display';
    @import 'scss/floats';
    @import 'scss/font-family';
    @import 'scss/font-style';
    @import 'scss/font-weight';
    @import 'scss/forms';
    @import 'scss/heights';
    @import 'scss/letter-spacing';
    @import 'scss/line-height';
    @import 'scss/links';
    @import 'scss/lists';
    @import 'scss/max-widths';
    @import 'scss/widths';
    @import 'scss/overflow';
    @import 'scss/position';
    //  @import 'scss/opacity';
    //  @import 'scss/rotations';
    //  @import 'scss/skins';
    //  @import 'scss/skins-pseudo';
    @import 'scss/spacing';
    @import 'scss/negative-margins';
    @import 'scss/tables';
    @import 'scss/text-decoration';
    @import 'scss/text-align';
    @import 'scss/text-transform';
    @import 'scss/type-scale';
    @import 'scss/typography';
    @import 'scss/utilities';
    @import 'scss/visibility';
    @import 'scss/white-space';
    @import 'scss/vertical-align';
    @import 'scss/hovers';
    // @import 'scss/z-index';
    // @import 'scss/nested';
    //  @import 'scss/styles';
    
    

Typography

Level 1 Heading

Level 2 Heading

Level 3 Heading

Level 4 Heading

Level 5 Heading
Level 6 Heading
    
    .f1 { font-size: 3rem; }
    .f2 { font-size: 2.25rem; }
    .f3 { font-size: 1.5rem; }
    .f4 { font-size: 1.25rem; }
    .f5 { font-size: 1rem; }
    .f6 { font-size: .875rem; }
    
    

Type Styles

Italicize: to write or print (text) in italics.

Some text that needs to be super bold.

This text wants to be underlined.

This text should be crossed out.

This text should be capitalized.

This text should be uppercase.

    
    .i {         font-style: italic; }
    .b {         font-weight: bold; }
    .underline { text-decoration: underline; }
    .strike {    text-decoration: line-through; }
    .ttc {       text-transform: capitalize; }
    .ttu {       text-transform: uppercase; }
    
    

Typefaces

serif

a b c d e f g h i j k l m n o p q r s t u v w x y z

a b c d e f g h i j k l m n o p q r s t u v w x y z

sans-serif

a b c d e f g h i j k l m n o p q r s t u v w x y z

a b c d e f g h i j k l m n o p q r s t u v w x y z

sans-serif-heading

a b c d e f g h i j k l m n o p q r s t u v w x y z

a b c d e f g h i j k l m n o p q r s t u v w x y z

Code

a b c d e f g h i j k l m n o p q r s t u v w x y z

a b c d e f g h i j k l m n o p q r s t u v w x y z

    
    // _fonts.scss
    @import url("https://fonts.googleapis.com/css?family=Crimson+Text:400,400i,700,700i|Montserrat:400,500,700|Open+Sans:400,400i,600,600i");
    $serif: "Crimson Text", georgia, unquote("Bodoni MT"), serif;
    $sans-serif: "Open Sans", -apple-system, BlinkMacSystemFont,
        "avenir next", avenir, helvetica, "helvetica neue", ubuntu,
        roboto, noto, "segoe ui", arial sans-serif;
    $sans-serif-headline: Montserrat, -apple-system, BlinkMacSystemFont,
        "avenir next", avenir, helvetica, "helvetica neue",
        ubuntu, roboto, noto, "segoe ui", arial, sans-serif;

    // produces:
    .sans-serif {
        font-family: "Open Sans", -apple-system, BlinkMacSystemFont,
                    'avenir next', avenir,
                    helvetica, 'helvetica neue',
                    ubuntu,
                    roboto, noto,
                    'segoe ui', arial,
                    sans-serif;
    }
    .serif { font-family: georgia, 'Bodoni MT', times, serif; }
    .code { font-family: Consolas, monaco, monospace; }
    
    
    

Measure

Wide Measure

Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.

Measure

Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.

Narrow Measure

Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.

    
    .measure-wide {   max-width: 34em; }
    .measure {        max-width: 30em; }
    .measure-narrow { max-width: 20em; }
    
    

Grids

Floats, widths, and padding can be combined to build a wide variety of grids.

fl w-100
fl w-90
fl w-10
fl w-80
fl w-20
fl w-75
fl w-25
fl w-70
fl w-30
fl w-60
fl w-40
fl w-50
fl w-50
fl w-third
fl w-third
fl w-third
fl w-third
fl w-two-thirds
fl w-25
fl w-25
fl w-25
fl w-25
fl w-20
fl w-20
fl w-20
fl w-20
fl w-20
fl w-10
fl w-10
fl w-10
fl w-10
fl w-10
fl w-10
fl w-10
fl w-10
fl w-10
fl w-10

Borders

ba = border on all sides
bt = border top
br = border right
bb = border bottom
bl = border left
bn = border none
    
    .ba { border-style: solid; border-width: 1px; }
    .bt { border-top-style: solid; border-top-width: 1px; }
    .br { border-right-style: solid; border-right-width: 1px; }
    .bb { border-bottom-style: solid; border-bottom-width: 1px; }
    .bl { border-left-style: solid; border-left-width: 1px; }
    .bn { border-style: none; border-width: 0; }
    
                

Border Styles

dotted
dashed
solid
none
    
    .b--dotted { border-style: dotted; }
    .b--dashed { border-style: dashed; }
    .b--solid {  border-style: solid; }
    .b--none {   border-style: none; }
    
                

Border Widths

default
.125rem
.25rem
.5rem
1rem
2rem
    
    .bw0 { border-width: 0; }
    .bw1 { border-width: .125rem; }
    .bw2 { border-width: .25rem; }
    .bw3 { border-width: .5rem; }
    .bw4 { border-width: 1rem; }
    .bw5 { border-width: 2rem; }
    
                

Border Radii

br1
br2
br3
br4
pill
br--bottom
br--top

br--left
br--right
    
    .br0 {        border-radius: 0; }
    .br1 {        border-radius: .125rem; }
    .br2 {        border-radius: .25rem; }
    .br3 {        border-radius: .5rem; }
    .br4 {        border-radius: 1rem; }
    .br-100 {     border-radius: 100%; }
    .br-pill {    border-radius: 9999px; }
    .br--bottom {
        border-top-left-radius: 0;
        border-top-right-radius: 0;
    }
    .br--top {
        border-bottom-left-radius: 0;
        border-bottom-right-radius: 0;
    }
    .br--right {
        border-top-left-radius: 0;
        border-bottom-left-radius: 0;
    }
    .br--left {
        border-top-right-radius: 0;
        border-bottom-right-radius: 0;
    }
    
                

Colors

Primary Theme Color
$theme-primary-{modifier}

.-is-bg-primary-dark
.-is-bg-primary
.-is-bg-primary-light

Secondary Theme Color
$theme-secondary-{modifier}

.-is-bg-secondary-dark
.-is-bg-secondary
.-is-bg-secondary-light

Success
$theme-success-{modifier}

.-is-bg-success-dark
.-is-bg-success
.-is-bg-success-light

Caution
$theme-caution-{modifier}

.-is-bg-caution-dark
.-is-bg-caution
.-is-bg-caution-light

Error
$theme-error-{modifier}

.-is-bg-error-dark
.-is-bg-error
.-is-bg-error-light

Red
$theme-red-{modifier}

.-is-bg-red-darkest
.-is-bg-red-dark
.-is-bg-red
.-is-bg-red-light
.-is-bg-red-lightest
.-is-bg-red-silver
.-is-bg-red-accent

Orange
$theme-orange-{modifier}

.-is-bg-orange-darkest
.-is-bg-orange-dark
.-is-bg-orange
.-is-bg-orange-light
.-is-bg-orange-lightest
.-is-bg-orange-silver
.-is-bg-orange-accent

Amber
$theme-amber-{modifier}

.-is-bg-amber-darkest
.-is-bg-amber-dark
.-is-bg-amber
.-is-bg-amber-light
.-is-bg-amber-lightest
.-is-bg-amber-silver
.-is-bg-amber-accent

Yellow
$theme-yellow-{modifier}

.-is-bg-yellow-darkest
.-is-bg-yellow-dark
.-is-bg-yellow
.-is-bg-yellow-light
.-is-bg-yellow-lightest
.-is-bg-yellow-silver
.-is-bg-yellow-accent

Lime
$theme-lime-{modifier}

.-is-bg-lime-darkest
.-is-bg-lime-dark
.-is-bg-lime
.-is-bg-lime-light
.-is-bg-lime-lightest
.-is-bg-lime-silver
.-is-bg-lime-accent

Green
$theme-green-{modifier}

.-is-bg-green-darkest
.-is-bg-green-dark
.-is-bg-green
.-is-bg-green-light
.-is-bg-green-lightest
.-is-bg-green-silver
.-is-bg-green-accent

Teal
$theme-teal-{modifier}

.-is-bg-teal-darkest
.-is-bg-teal-dark
.-is-bg-teal
.-is-bg-teal-light
.-is-bg-teal-lightest
.-is-bg-teal-silver
.-is-bg-teal-accent

Cyan
$theme-cyan-{modifier}

.-is-bg-cyan-darkest
.-is-bg-cyan-dark
.-is-bg-cyan
.-is-bg-cyan-light
.-is-bg-cyan-lightest
.-is-bg-cyan-silver
.-is-bg-cyan-accent

Blue
$theme-blue-{modifier}

.-is-bg-blue-darkest
.-is-bg-blue-dark
.-is-bg-blue
.-is-bg-blue-light
.-is-bg-blue-lightest
.-is-bg-blue-silver
.-is-bg-blue-accent

Indigo
$theme-indigo-{modifier}

.-is-bg-indigo-darkest
.-is-bg-indigo-dark
.-is-bg-indigo
.-is-bg-indigo-light
.-is-bg-indigo-lightest
.-is-bg-indigo-silver
.-is-bg-indigo-accent

Violet
$theme-violet-{modifier}

.-is-bg-violet-darkest
.-is-bg-violet-dark
.-is-bg-violet
.-is-bg-violet-light
.-is-bg-violet-lightest
.-is-bg-violet-silver
.-is-bg-violet-accent

Magenta
$theme-magenta-{modifier}

.-is-bg-magenta-darkest
.-is-bg-magenta-dark
.-is-bg-magenta
.-is-bg-magenta-light
.-is-bg-magenta-lightest
.-is-bg-magenta-silver
.-is-bg-magenta-accent

Pink
$theme-pink-{modifier}

.-is-bg-pink-darkest
.-is-bg-pink-dark
.-is-bg-pink
.-is-bg-pink-light
.-is-bg-pink-lightest
.-is-bg-pink-silver
.-is-bg-pink-accent

B&W gray scale, with hue shift twards blue to match theme.
$theme-gray-{modifier}

.-is-bg-gray-darkest
.-is-bg-gray-dark
.-is-bg-gray
.-is-bg-gray-light
.-is-bg-gray-lightest
.-is-bg-gray-silver
.-is-bg-black
.-is-bg-black-near
.-is-bg-white-near
.-is-bg-gray-silver
.-is-bg-white

Translucent Blacks Translucent Blacks in 10% increments.
$theme-black-{modifier}

.-is-bg-black-near
.-is-bg-black-90
.-is-bg-black-80
.-is-bg-black-70
.-is-bg-black-60
.-is-bg-black-50
.-is-bg-black-40
.-is-bg-black-30
.-is-bg-black-20
.-is-bg-black-10

Alerts

Some alert
Some alert: primary
Some alert: secondary
Some alert: success
Some alert: caution
Some alert: error
Some alert: the size of its content (compact).
Some alert: dismissible success (floating)
Some alert: dismissible error (floating)
Use of details element Using html5 <details> and <summary> elements for a nifty collapsing notice.

<div class="v1-m-alert">Some alert </div>
<div class="v1-m-alert -is-primary">Some alert: primary</div>
<div class="v1-m-alert -is-secondary">Some alert: secondary</div>
<div class="v1-m-alert -is-success">Some alert: success</div>
<div class="v1-m-alert -is-caution">Some alert: caution</div>
<div class="v1-m-alert -is-danger">Some alert: danger</div>
<div class="v1-m-alert -is-compact">Some alert: compact</div>

                            

// Requires u-alertDismiss.js
// Note: Dissmissing js will remove the element from the DOM.
<div class="v1-m-alert -is-caution -is-floating -is-dismissible">Some Alert: dismissible error
    <button type="button" class="-is-dismissible" data-dismiss="alert" aria-label="Close">
        <i class="v1-a-icon icon-x" aria-hidden="true"></i>
    </button>
</div>

<details class="v1-m-alert -is-secondary">
    <summary>Some notice</summary>
    ... a nifty collapsing notice.
</details>

                            

Buttons

                            
        // Example of base styling for button-type elements
<button>Button Element</button>
<input type="reset" value="Input Clear">
<input type="submit" value="Input Submit">
                            
                            // Link elements can be used too.
                            <a href="#" class="v1-a-btns"> ... </a>
                        
                            <a href="#" class="v1-a-btns -is-lg -is-rounded"> ... </a>
                        
                            <a href="#" class="v1-a-btns -is-med -is-rounded"> ... </a>
                        
                            <a href="#" class="v1-a-btns -is-medsm -is-rounded"> ... </a>
                        
some link
                            
                                    <a href="#" class="v1-a-btns -is-small -is-rounded -is-disabled"> ... </a>
<a href="#" class="v1-a-btns -is-small -is-rounded" disabled> ... </button>
                                    
                                        // centers icons when there is no text.
<button class="v1-a-btns -is-rounded -is-icon"><i class="v1-a-icon icon-help-circle"></i></button>
                            <a href="#" class="v1-a-btns -is-lg -is-pill -is-shadow -is-primary -is-trans-swipe -is-callToAction"> ... </a>
                        
                        <a href="#" class="v1-a-btns -is-rounded -is-med -is-primary"> ... </a>
                        
                            <a href="#" class="v1-a-btns -is-med -is-bg-blue -is-trans-blue"> ... </a>
                        
                            <a href="#" class="v1-a-btns -is-pill -is-bg-white  -is-bdr-blue -is-bdr-dotted -is-med"> ... </a>
                        
                            <a href="#" class="v1-a-btns -is-medsm -is-bdr-blue -is-txt-blue -is-bg-white"> ... </a>
                        
                            <a href="#" class="v1-a-btns -is-medsm -is-bg-success"> ... </a>
                        
                                            <a href="#" class="v1-a-btns -is-medsm -is-bg-caution"> ... </a>
                                        
                                            <a href="#" class="v1-a-btns -is-medsm -is-bg-error"> ... </a>
                                        
                            <a href="#" class="v1-a-btns -is-medsm -is-bg-primary -is-callToAction"> ... </a>
                        
                            <a href="#" class="-is-callToAction"> ... </a>
                        

Pagination

// Example with active element as span with the .-is-active class
<nav class="v1-m-pagination">
    <div class="v1-m-pagination__wrap">
        <ul class="v1-m-pagination__pager">
            <li class="v1-m-pagination__link -is-entry -is-prev"><a aria-label="Previous" class="v1-a-btns -is-pill -is-bg-white -is-bdr-blue -is-bdr-dotted -is-med" href="page-news-entry.php">← previous</a></li>
            <li class="v1-m-pagination__link -is-entry"><a aria-label="Page 7" class="v1-a-btns -is-pill -is-bg-white -is-bdr-blue -is-bdr-dotted -is-med" href="page-news-entry.php">7</a></li>
            <li class="v1-m-pagination__link -is-entry"><span aria-label="Current Page" class="v1-a-btns -is-pill -is-bg-white -is-bdr-blue -is-bdr-dotted -is-med -is-active" href="page-news-entry.php">8</span></li>
            <li class="v1-m-pagination__link -is-entry"><a aria-label="Page 9" class="v1-a-btns -is-pill -is-bg-white -is-bdr-blue -is-bdr-dotted -is-med" href="page-news-entry.php">9</a></li>
        </ul>
    </div>
</nav>
                    

Tabs

Tab 1

The important achievement of Apollo was demonstrating that humanity is not forever chained to this planet and our visions go rather further than that and our opportunities are unlimited.

// Example with active element with the .-is-current class
// Required js: u-tabs.js
// https://a11y-style-guide.com/style-guide/section-structure.html#kssref-structure-tabs

<div class="v1-m-navTabs">
    <nav class="v1-m-navTabs" aria-multiselectable="false">
        <ul class="v1-m-navTabs__navList" role="tablist">
            <li class="v1-m-navTabs__navItem -is-current" role="presentation">
                <a class="v1-m-navTabs__navTrigger" id="tab-label-1" role="tab" aria-setsize="3" aria-posinset="1" aria-controls="tab-panel-1" aria-selected="true" href="#">Tab 1</a>
            </li>
            <li class="v1-m-navTabs__navItem" role="presentation">
                <a class="v1-m-navTabs__navTrigger" id="tab-label-2" role="tab" aria-setsize="3" aria-posinset="2" aria-controls="tab-panel-2" aria-selected="false" href="#">Tab 2</a>
            </li>
            <li class="v1-m-navTabs__navItem" role="presentation">
                <a class="v1-m-navTabs__navTrigger" id="tab-label-3" role="tab" aria-setsize="3" aria-posinset="3" aria-controls="tab-panel-3" aria-selected="false" href="#">Tab 3</a>
            </li>
        </ul>
    </nav>
    <div class="v1-m-navTabPanel__wrap">
        <div class="v1-m-navTabPanel -is-current" id="tab-panel-1" role="tabpanel" aria-labelledby="tab-label-1" tabindex="-1">
            <h3>Tab 1</h3>
            <div class="v1-m-navTabPanel__body">
                <p>The important achievement of Apollo ... </p>
            </div>
        </div>
        <div class="v1-m-navTabPanel" id="tab-panel-2" aria-hidden="true" role="tabpanel" aria-labelledby="tab-label-2" tabindex="-1">
            <h3>Tab 2</h3>
            <div class="v1-m-navTabPanel__body">
                <p>Never limit yourself because of others' ... </p>
            </div>
        </div>
        <div class="v1-m-navTabPanel" id="tab-panel-3" aria-hidden="true" role="tabpanel" aria-labelledby="tab-label-3" tabindex="-1">
            <h3>Tab 3</h3>
            <div class="v1-m-navTabPanel__body">
                <p>After Apollo 17, ... </p>
            </div>
        </div>
    </div>
</div>

                    

Tables

This is a table caption
Table Header 1 Table Header 2 Table Header 3 Table Header 4 Table Header 5 Table Header 6
Division 1 Division 2 Division 3 Division 4 Division 5 Division 6
Division 1 Division 2 Division 3 Division 4 Division 5 Division 6
Division 1 Division 2 Division 3 Division 4 Division 5 Division 6
A row with a cell spanning all 6 columns
Table Footer 1 Table Footer 2 Table Footer 3 Table Footer 4 Table Footer 5 Table Footer 6
// Note the use of .v1-o-table__nest.-is-overflowX to trigger shadded effect on overflowing tables.
<div class="v1-o-table__wrap">
    <div class="v1-o-table__nest -is-overflowX">
        <table class="v1-o-table">
            <caption>This is a table caption</caption>
            <thead>
                <tr>
                <th>Table Header 1</th><th>Table Header 2</th><th>Table Header 3</th><th>Table Header 4</th><th>Table Header 5</th><th>Table Header 6</th>
                </tr>
            </thead>
            <tbody>
                <tr>
                    <td>Division 1</td><td>Division 2</td><td>Division 3</td><td>Division 4</td><td>Division 5</td><td>Division 6</td>
                </tr>
                <tr>
                    <td>Division 1</td><td>Division 2</td><td>Division 3</td><td>Division 4</td><td>Division 5</td><td>Division 6</td>
                </tr>
                <tr>
                    <td>Division 1</td><td>Division 2</td><td>Division 3</td><td>Division 4</td><td>Division 5</td><td>Division 6</td>
                </tr>
                <tr>
                    <td colspan="6">A row with a cell spanning all 6 columns</td>
                </tr>
            </tbody>
            <tfoot>
                <tr>
                    <th>Table Footer 1</th><th>Table Footer 2</th><th>Table Footer 3</th><th>Table Footer 4</th><th>Table Footer 5</th><th>Table Footer 6</th>
                </tr>
            </tfoot>
        </table>
    </div>
</div>

                    

Inputs

Radio Buttons:




Checkboxes:






// Semantic, keyboard acessable, yet styled inputs.
// Note: use of id and for attributes & the label must follow the input.

<input type="radio" id="radioButton1"class="v1-a-radioButton" name="radio_button" value="radio_1" />
<label for="radioButton1">radiobutton 1</label>

<input type="checkbox" id="checkbox1"class="v1-a-checkBox" name="checkboxes" value="check_1" />
<label for="checkbox1">Checkbox 1</label>

<label for="select_element">Select Element:</label> <br/>
<select class='v1-a-select' id="select_element">
    <optgroup label="Option Group 1">
        <option value="1">Option 1</option>
        <option value="2">Option 2</option>
    </optgroup>
    <optgroup label="Option Group 2">
        <option value="1">Option 1</option>
        <option value="2">Option 2</option>
        <option value="3" disabled="">Disabled Option</option>
    </optgroup>
</select>

                    

// Keyboard accessable file upload using css only
<label for="file-upload" class="v1-a-fileUploadBttn">
    Custom Upload
    <input id="file-upload" type="file"/>
</label>
                    

Modals

Modals using the lightweight, accessible and responsive lightbox lity library.
Full documentation on Github.
Using inline content:

Help
                                    
<a href="#helpdialog" id="helpbutton" class="v1-a-btns -is-pill -is-bg-blue" data-lity="">Help <i
        class="v1-a-icon icon-help-circle"></i></a>

<aside id="helpdialog" class="v1-o-helpPopup lity-hide" title="Help">
    <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit...</p>
</aside>
                                    
                            
Using external content via iframe:

Google Maps
                                    <a href="//maps.google.com/maps?q=1600+Amphitheatre+Parkway,+Mountain+View,+CA" data-lity>
    Google Maps <i class="v1-a-icon icon-language -is-round -is-bg-secondary-light" aria-hidden="true"></i>
</a>
                                
                            

Icons

Custom icon set via IcoMoon

icon-cog
icon-loop
<span class="v1-a-icon icon-cog"></span>
<i class="v1-a-icon icon-loop"></i>
                            

Tools

icon-tag
icon-trash-2
icon-delete
icon-link-2
icon-filter
icon-alert-triangle
icon-check
icon-download
icon-activity
icon-popup
icon-cog
icon-loop
icon-life-buoy
icon-help-circle
icon-search
icon-check_box
icon-trending
icon-language
icon-log-out

Connections

icon-twitter-with-circle
icon-facebook-with-circle
icon-mail

Arrows & Indicators

icon-chevron-right
icon-chevron-left
icon-chevron-down
icon-chevron-up
icon-arrow-right-circle
icon-arrow-left-circle
icon-arrow-down-circle
icon-arrow-up-circle
icon-arrow-down-left
icon-arrow-down-right
icon-arrow-up-left
icon-arrow-up-right
icon-arrow-right
icon-arrow-left
icon-arrow-down
icon-arrow-up
icon-minus-circle
icon-minus-square
icon-minus
icon-plus-circle
icon-plus-square
icon-plus
icon-x-circle
icon-x-square
icon-x
icon-spinner-1
icon-spinner-2

Charts & Graphs

icon-bar-chart-1
icon-bar-chart-2
icon-pie-chart
icon-chart
icon-chart1
icon-chart2
icon-chart3

Icon modifiers

Any icon can be turned into a spinner with the addion of the .-is-spinner or .-is-spinner-counter classes.


<i class="v1-a-icon icon-spinner-1 -is-spinner" aria-hidden="true"> </i>

                    

Disable an icon with the .-is-disabled class.


<i class="v1-a-icon icon-cog -is-disabled" aria-hidden="true"></i>

                    

Round an icon with the .-is-round or .-is-rounded classes.


<i class="v1-a-icon icon-check -is-rounded -is-txt-white -is-bg-success" aria-hidden="true"></i>

                    

<i class="v1-a-icon icon-language -is-round -is-bg-secondary-light" aria-hidden="true"></i>

                    

Element Test Suite

The following is a "bare metal" test suite with no Tachyons styles applied. The elements below are either styled by our resets + theme, or by browser defaults.

This pragmagtic test suite is derived from Bryan Braun's Poor man's style guide.

Headings

Heading 1

Heading 2

Heading 3

Heading 4

Heading 5
Heading 6

Headings with Text

Heading 1

Lorem ipsum dolor sit amet, adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl.

Heading 2

Lorem ipsum dolor sit amet, adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl.

Heading 3

Lorem ipsum dolor sit amet, adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl.

Heading 4

Lorem ipsum dolor sit amet, adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl.

Heading 5

Lorem ipsum dolor sit amet, adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl.

Heading 6

Lorem ipsum dolor sit amet, adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl.


Block Elements

Paragraphs and Images

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl. Praesent mattis, massa quis luctus fermentum, turpis mi volutpat justo, eu volutpat enim diam eget metus. Maecenas ornare tortor.

Placeholder Image and Some Alt Text

Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem.

Blockquote

This is a standard paragraph. Lorem ipsum dolor sit amet, consectetuer adipiscing elit.

"This is a blockquote. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl."

This is a standard paragraph. Lorem ipsum dolor sit amet, consectetuer adipiscing elit.

Figure-Caption

A placeholder figure image.
The figcaption element example

Details-Summary

The summary element example

The details example text. It may be styled differently based on what browser or operating system you are using.


Text Elements

The a element and external a element examples

The abbr element and an abbr element with title examples

The ACRONYM element example

The b element example

The cite element example

The code element example

The data element example

The del element example

The dfn element and dfn element with title examples

The em element example

The i element example

The ins element example

The kbd element example

The mark element example

The q element example

The q element inside a q element example

The s element example

The samp element example

The small element example

The span element example

The strong element example

The sub element example

The sup element example

The example

The u element example

The var element example


Monospace / Preformatted

Code block wrapped in "pre" and "code" tags

// Loop through Divs using Javascript.
            var divs = document.querySelectorAll('div'), i;

            for (i = 0; i < divs.length; ++i) {
            divs[i].style.color = "green";
            }

Monospace Text wrapped in "pre" tags

Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl

List Types

Ordered List

  1. List Item 1
  2. List Item 2
  3. List Item 3
    1. List Item 3.1
    2. List Item 3.2
      1. List Item 3.2.1
      2. List Item 3.2.2
    3. List Item 3.3
  4. List Item 4

Unordered List

  • List Item 1
  • List Item 2
  • List Item 3
    • List Item 3.1
    • List Item 3.2
      • List Item 3.2.1
      • List Item 3.2.2
    • List Item 3.3
  • List Item 4

Definition List

Definition Term 1
Definition Description 1
Definition Term 2
Definition Description 2

Tables

This is a table caption
Table Header 1 Table Header 2 Table Header 3
Division 1 Division 2 Division 3
Division 1 Division 2 Division 3
Division 1 Division 2 Division 3
A row with a cell spanning all 3 columns
Table Footer 1 Table Footer 2 Table Footer 3

Media

The Audio Element:

The Video Element:

Embedded content:

YouTube video (iframe):


Form Elements

The Fieldset:

Legend

The Form:









Radio Buttons:




Checkboxes:





<input type="radio" class="radio" name="radio_button" value="radio_1" />
<label> Radio 1 </label> <br/>
                        



// Keyboard accessable file upload using css only
<label for="file-upload" class="v1-a-fileUploadBttn">
    Custom Upload
    <input id="file-upload" type="file"/>
</label>
                    

HTML5-specific Form Elements












42



350 degrees