Skip to content

Commit

Permalink
Merge pull request #22 from cmalven/next
Browse files Browse the repository at this point in the history
Next
  • Loading branch information
cmalven authored Jan 1, 2020
2 parents 3da84db + 1e8233f commit e2a4b5e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
14 changes: 8 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ Works for any of the following classes:
<h1 class="h-fluid-size-top-margin-s">Ground control to Major Tom</h1>
```
The exact names of the keys in this map aren't important, as long as `@include spacing(foo)` has a matching key `foo` in the map.
The exact names of the keys in this map aren't important, as long as `@include fluid-size(foo)` has a matching key `foo` in the map.

### Fluid

Expand All @@ -319,25 +319,27 @@ Inspired by the work of [Indrek Paas](https://github.com/indrekpaas) and the wri
@include fluid($properties)
/* Single property */
html {
@include fluid(font-size, 320px, 1366px, 14px, 18px);
@include fluid(font-size, 320px, 1440px, 14px, 18px);
}

/* Multiple properties with same values */
h1 {
@include fluid(padding-bottom padding-top, 20em, 70em, 2em, 4em);
@include fluid(padding-bottom padding-top, 320px, 1440px, 200px, 300px);
}

/* If you have a $mq-breakpoints map, you can use its keys in place of values */
p {
@include fluid(margin-top, medium, large, 2em, 4em);
@include fluid(margin-top, medium, large, 100px, 200px);
}

/* …and you can use `default` to refer to your $fluid-min-width value */
p {
@include fluid(margin-top, default, large, 2em, 4em);
@include fluid(margin-top, default, large, 100px, 200px);
}
```

/* Substitute vertical units, for queries that respond to device height */
@include fluid(margin-top, 600px, 900px, 100px, 200px, $size-unit: height, $viewport-unit: vh );
```

## Development

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@malven/sass-toolkit",
"version": "2.5.7",
"version": "2.5.8",
"description": "A collection of foundational utilities for Sass",
"repository": {
"type": "git",
Expand Down

0 comments on commit e2a4b5e

Please sign in to comment.