accoutrement-fonts
Advanced tools
Comparing version 2.0.0-alpha.4 to 2.0.0-rc.1
{ | ||
"name": "accoutrement-fonts", | ||
"version": "2.0.0-alpha.4", | ||
"version": "2.0.0-rc.1", | ||
"description": "Sass webfont utilities.", | ||
@@ -17,4 +17,4 @@ "homepage": "https://github.com/oddbird/accoutrement-fonts", | ||
"sass-true": "^2.0.3", | ||
"sassdoc": "^2.1.15", | ||
"sassdoc-theme-oddbird": "^0.1.0" | ||
"sassdoc": "^2.1.19", | ||
"sassdoc-theme-herman": "^0.2.1" | ||
}, | ||
@@ -21,0 +21,0 @@ "author": "Miriam Suzanne <miriam@oddbird.net>", |
@@ -1,8 +0,76 @@ | ||
accoutrement-fonts | ||
Accoutrement-Fonts | ||
================== | ||
Font helpers | ||
Webfont management tools. | ||
Gather all your fonts into a single map, | ||
access them by name, | ||
and easily import the webfonts. | ||
## Installation | ||
``bower install accoutrement-fonts`` | ||
Quick Start | ||
----------- | ||
```bash | ||
npm install accoutrement-fonts | ||
``` | ||
Configure your font settings: | ||
```scss | ||
$font-formats: 'woff' 'ttf'; // Define what webfont formats need importing | ||
$font-path: '../fonts/'; // Set the a path to your fonts directory | ||
$fonts: ( | ||
'heading': ( // give your font a semantic name for reference | ||
'name': 'maven', // optionally set a different font name | ||
'stack': ('helvetica', 'arial', sans-serif), // define the stack | ||
'normal': 'maven/maven_pro_regular-webfont', // point to any webfont files | ||
'bold': 'maven/maven_pro_bold-webfont', | ||
), | ||
'body': ( | ||
'name': 'exo', | ||
'stack': ('helvetica', 'arial', sans-serif), | ||
'normal': 'exo/exo2-regular-webfont', | ||
'italic': 'exo/exo2-italic-webfont', | ||
'bold': 'exo/exo2-bold-webfont', | ||
'bold' 'italic': 'exo/exo2-bolditalic-webfont', | ||
), | ||
'alias': 'body', // create aliases when useful | ||
); | ||
``` | ||
Import a webfont, | ||
or all your configured fonts with a mixin: | ||
```scss | ||
@include font-face('body'); // Import one font by configuration key | ||
@include import-webfonts; // Import all defined fonts | ||
``` | ||
And set your font-family anywhere, | ||
using the semantic names you set earlier: | ||
```scss | ||
html { | ||
@include font-family('body'); | ||
} | ||
h1, h2, h3 { | ||
@include font-family('heading'); | ||
} | ||
``` | ||
About OddBird Accoutrement | ||
-------------------------- | ||
[OddBird][oddbird]'s *Accourement* modules | ||
are individual Sass toolkits | ||
that work together to form | ||
the central nervous system of a project. | ||
They help to establish and access a projects configuration | ||
in consistent and inter-connected ways. | ||
[oddbird]: http://oddbird.net/ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
1220454
46
177
77
1