Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

postcss-typescale

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

postcss-typescale - npm Package Compare versions

Comparing version 0.1.1 to 0.1.2

1

lib/index.js

@@ -53,2 +53,3 @@ 'use strict';

}
if (values[0]) {

@@ -55,0 +56,0 @@ options.tmp.index = values[0];

4

package.json
{
"name": "postcss-typescale",
"version": "0.1.1",
"description": "A PostCSS plugin to create a typographic scale.",
"version": "0.1.2",
"description": "A PostCSS plugin to set type based on a typographic scale.",
"keywords": [

@@ -6,0 +6,0 @@ "postcss",

@@ -7,3 +7,3 @@ # postcss-typescale

A [PostCSS] plugin to set type.
A [PostCSS] plugin to set type based on a [typographic scale](http://type-scale.com).

@@ -44,5 +44,5 @@ [github.io]: http://francoisromain.github.io/postcss-typescale

@typescale ([name]) {
scale: 1.25; /* See type-scale.com to choose a scale */
font-size: 1rem; /* default font size */
line-height: 1.5rem; /* If no unit is provided, line-height is relative to font-size */
scale: 1.25; /* Typographic scale */
font-size: 1rem; /* Default font size */
line-height: 1.5rem; /* Baseline grid */
}

@@ -53,2 +53,4 @@ ```

The line-height can be relative to the font-size if _line-height_ is set to 1 without unit.
* * *

@@ -64,14 +66,20 @@

#### Examples
* * *
## Examples
```css
.my-title {
.title {
typescale: 3 1.5;
}
.my-small-text {
.text {
typescale: 0;
}
.small-text {
typescale: -1;
}
.my-extra-small-text {
.extra-small-text {
typescale: -2 0.5;

@@ -81,3 +89,16 @@ }

[input](https://github.com/francoisromain/postcss-typescale/blob/gh-pages/test/src/01.css), [output](https://github.com/francoisromain/postcss-typescale/blob/gh-pages/test/dist/01.css), [markup](https://github.com/francoisromain/postcss-typescale/blob/gh-pages/test/01.html), [demo](http://localhost/francoisromain.github.io/postcss-typescale/test/01.html)
``` css
@typescale my-scale {
scale: 1.25;
font-size: 1rem;
line-height: 1.5rem;
}
.my-small-text {
typescale: my-scale -2 0.5;
}
```
01: [input](https://github.com/francoisromain/postcss-typescale/blob/gh-pages/test/src/01.css), [output](https://github.com/francoisromain/postcss-typescale/blob/gh-pages/test/dist/01.css), [markup](https://github.com/francoisromain/postcss-typescale/blob/gh-pages/test/01.html), [demo](http://localhost/francoisromain.github.io/postcss-typescale/test/01.html)
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc