Getting Started

This is the living style guide and pattern library for the Mardigian Library.

We use Foundation for our CSS framework.

To edit this guide:
Add the code to the /markup folder (they will be .html files) and the documentation to /doc folder (they will be .md files) folder.

Colors

Accessibility

Color alone should not be used to convey meaning (for example, RED for alert).

Primary Palette

Maize
#ffcb05
Blue
#00274c

Secondary Palette

The Rock Gray
#989c97
Anchor Gray
#e5e1de
Matthaei Violet
#575294
Grey - Panel
#555555

Secondary Page

Body Background
#eff0f2
Facts Panel
#333333
Side Top Nav Block
#e5e5e5
Side Bottom Nav Block
#F7EBA5

Colors for Topic Tiles

Green
#48736A
Orange
#AC5600
Purple
#575294
Toxic Green
#7E732F
Red
#7A121C
Blue
#587ABC

Font Stacks

Primary Font:
"Open Sans", sans-serif;
Primary Font Italic:
"OpenSans", sans-serif;
Primary Font Bold:
"OpenSans", sans-serif;
Secondary Font: None Currently

accessibility

tools

Our Tools for Assessment:

Wave
Web Accessibility Evaluation Tool

WebAIM Color Contrast Checker

W3C HTML Validator

W3C CSS Validator

Development Tools:

PostCSS
WCAG Contrast checks CSS for color contrast compliance with Web Content Accessibility Guidelines (WCAG) 2.0.

Add Gulp PostCSS to your build tool:

npm install gulp-postcss --save-dev

Enable WCAG Contrast within your Gulpfile:

var postcss = require('gulp-postcss');

gulp.task('css', function () {
    return gulp.src('./src/*.css').pipe(
        postcss([
            require('postcss-wcag-contrast')({ /* options */ })
        ])
    ).pipe(
        gulp.dest('.')
    );
});

base

accordion

Accordion background color: #FAFAFB Remove active from class for panels to remain closed upon load. *Use class="accordionInner" on the ul if using a list with links.

Example

Back to Top
<!--
Commented out due to FontAwesome Fonts.  
  <ul class="accordion" data-accordion role="tablist">
  <li class="accordion-navigation">
    <a href="#panel1d" role="tab" id="panel1d-heading" aria-controls="panel1d">Accordion 1<i class="fa fa-chevron-circle-down"></i></a>
    <div id="panel1d" class="content active" role="tabpanel" aria-labelledby="panel1d-heading">
      Panel 1. Lorem ipsum dolor
    </div>
  </li>
  <li class="accordion-navigation">
    <a href="#panel2d"  role="tab" id="panel2d-heading" aria-controls="panel2d">Accordion 2<i class="fa fa-chevron-circle-down"></i></a>
    <div id="panel2d" class="content" role="tabpanel" aria-labelledby="panel2d-heading">
      Panel 2. Lorem ipsum dolor
    </div>
  </li>
  <li class="accordion-navigation">
    <a href="#panel3d" role="tab" id="panel3d-heading" aria-controls="panel3d">Accordion 3<i class="fa fa-chevron-circle-down"></i></a>
    <div id="panel3d" class="content" role="tabpanel" aria-labelledby="panel3d-heading">
      Panel 3. Lorem ipsum dolor
    </div>
  </li>
</ul>
-->

headings

Mark up headings in a logical order from H1 (usually the page title) to H2 to H3, and so on. Don't skip levels to avoid confusion. Use CSS to change the visual display as needed.

Accessibility: Users of adaptive technologies, including screen readers and others, navigate pages via headings. You should mark up headings (H1) and subheadings (H2 - H6) using heading tags.

Example

Heading 1 with small text and a link

Heading 2 with small text and a link

Heading 3 with small text and a link

Heading 4 with small text and a link

Heading 5 with small text and a link
Heading 6 with small text and a link
Back to Top
<h1>Heading 1 with <small>small text</small> and a <a href="#">link</a></h1>
<h2>Heading 2 with <small>small text</small> and a <a href="#">link</a></h2>
<h3>Heading 3 with <small>small text</small> and a <a href="#">link</a></h3>
<h4>Heading 4 with <small>small text</small> and a <a href="#">link</a></h4>
<h5>Heading 5 with <small>small text</small> and a <a href="#">link</a></h5>
<h6>Heading 6 with <small>small text</small> and a <a href="#">link</a></h6>

icons

We use Font Awesome for all of our icon needs. You can place Font Awesome icons just about anywhere using the CSS Prefix fa and the icon's name. Font Awesome is designed to be used with inline elements.

To increase icon sizes relative to their container, use the fa-lg (33% increase), fa-2x, fa-3x, fa-4x, or fa-5x classes.

Accessibility:

  1. Use the Font Awesome CDN to automatic accessibility support. All updates will then be applied automatically.

  2. To improve web accessibility, FA recommends using aria-hidden="true" to hide icons used purely for decoration.

  3. Modern versions of assistive technology, like screen readers, will read CSS generated content (how Font Awesome icons are rendered), as well as specific Unicode characters. Assisistive technology may have the following problems: The assistive technology may not find any content to read out to a user. The assistive technology may read the unicode equivalent, which could not match up to what the icon means in context, or worse is just plain confusing

More info on Accessibility and Font Awesome at http://fontawesome.io/accessibility/

Example

This is where the content Copy goes. It is slightly indented.

Another placeholder

Back to Top
<div class="contentCopy"> <!--Copy Content Here-->
	<p>This is where the content Copy goes. It is slightly indented.</p>
	<p>Another placeholder</p>
</div>

intro

class="intro"

Bolded section headers for the secodary pages are put in the .intro class div.

It is typically used above the .centerCopy div.

Example

The class .intro is used here for Bolded Section Header

Back to Top
<div class="intro"><!--Bolded Section Header-->
	<p>The class .intro is used here for Bolded Section Header</p>
</div>

linkBlueBold

class="linkBlueBold"

Example

Put the class on the div and the anchor within the div.

Back to Top
<div class="linkBlueBold">
	<a href="#">Use class .linkBlueBold to create an anchor with bold blue text and a maize hover.</a>
</div>
<p>Put the class on the div and the anchor within the div.</p>

maizeEmphasisBox

class="maizeEmphasisBox"

Example

Use class .maizeEmphasisBox to create a yellow box for emphasis.

Surrounding copy

Back to Top
<div class="maizeEmphasisBox ">
	<p>Use class .maizeEmphasisBox to create a yellow box for emphasis.</p>
</div>
<p>Surrounding copy</p>

patterns

breadcrumbs

Foundation: Add a class of .breadcrumbs to a ul element. List items will automatically be styled, and you can add .current or .unavailable classes to list items to denote their state.

You can also add a .breadcrumbs class to a nav element containing anchor links to get the same result.

Accessibility: Adding the role attribute gives context to a screen reader. The aria-label attribute will allow a screen reader to call out what the component is to the user. If you are using an unavailable link, give it an aria-disabled attribute.

Example

Back to Top
<div class="row">
 <div class="large-12 columns">
	 <nav class="breadcrumbs" role="menubar" aria-label="breadcrumbs">
	   <li role="menuitem"><a href="http://umdearborn.edu/library">Home</a></li>
	   <li role="menuitem" class="unavailable" role="button" aria-disabled="true"><a href="#">Parent Nav Link</a></li><!--Update Parent Nav (Find, Services, About Us) HERE--> 		   
	   <li role="menuitem" class="current"><a href="http://umdearborn.edu/library/Services/course_reserves.php">Page Title Here</a></li><!--BREAD CRUMB PAGE TITLE HERE-->
	</nav>
</div>
Back to Top
<div class="large-12 columns">
	<div class="copy">
 		<h3>Copy Title</h3>
  		<p>Fill copy here</p>
  	</div>	
<!--Code for Link Block component-->
 	<ul class="linkBlock small-block-grid-1 medium-block-grid-2 large-block-grid-2">
 		<li><a href="#">Link Block 1<i class="fa fa-chevron-circle-right"></i></a></li>
		<li><a href="#">Link Block 2<i class="fa fa-chevron-circle-right"></i></a></li>
  		<li><a href="#">Link Block 3<i class="fa fa-chevron-circle-right"></i></a></li>
		<li><a href="#">Link Block 4<i class="fa fa-chevron-circle-right"></i></a></li>
	</ul>
</div>

topicTile

Example

Copy Title

Fill copy here