1.0.3 • Published 6 years ago

@citizensadvice/font-size v1.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
6 years ago

Font-size npm (scoped)

Defines the size of the text.

Classes

Class nameValue
.font-size-1$font-size-1 (14px)
.font-size-2$font-size-2 (16px)
.font-size-3$font-size-3 (20px)
.font-size-4$font-size-4 (28px)
.font-size-5$font-size-5 (36px)

Responsive font-size classes

To apply specific classes at set screen widths, use the following classes:

Class nameDescription
[aboveClassName]-nsScreens with a min-width of 48rem
[aboveClassName]-mScreens with widths from 48rem to 64rem
[aboveClassName]-lScreens with a min-width of 64rem

Examples

<div class="font-size-1 font-size-4-ns">...</div>
<div class="font-size-2 font-size-3-ns font-size-5-l">...</div>

Installation

$ npm install @citizensadvice/font-size

now import into your stylesheet...

@import '@citizensadvice/font-size/index.scss';

You can also make use of the unpkg service, try adding the link below to the head of your HTML file

<link src="https://unpkg.com/@citizensadvice/font-size@latest/build/font-size.css" />