Skip to content

Commit

Permalink
Fix read section for less (issue #7)
Browse files Browse the repository at this point in the history
  • Loading branch information
8lueberry committed Aug 7, 2015
1 parent 075dab1 commit 1d3ee44
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
12 changes: 8 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,16 +86,20 @@ Import [palette.less](http://danlevan.github.io/google-material-color/dist/palet
@import 'palette';
...

.my-div {
.issue-7 {
.palette('Light Blue', '700');
background-color: @palette;

.palette('Red'); // default shade is 500
color: @palette;
// get @palette in its own scope otherwise @palette will be overwritten
&{
.palette('Red'); // default shade is 500
color: @palette;
}
}

```

If you need access to the variables, you can access it through variablec like `@palette-Light-Blue-500`
If you need access to the variables, you can access it through variable like `@palette-Light-Blue-500`


### CSS
Expand Down
2 changes: 1 addition & 1 deletion test/less.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* google-material-color v1.1.0
* google-material-color v1.2.2
* https://github.com/danlevan/google-material-color
*/
.less.Red {
Expand Down
2 changes: 1 addition & 1 deletion test/sass.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* google-material-color v1.1.0
* google-material-color v1.2.2
* https://github.com/danlevan/google-material-color
*/
.sass.Red {
Expand Down

0 comments on commit 1d3ee44

Please sign in to comment.