8lueberry / google-material-color Goto Github PK
View Code? Open in Web Editor NEWGoogle material color for SASS, LESS, Stylus, CSS, JS, etc
Home Page: https://github.com/danlevan/google-material-color
License: MIT License
Google material color for SASS, LESS, Stylus, CSS, JS, etc
Home Page: https://github.com/danlevan/google-material-color
License: MIT License
Hi,
it seems the description README.md, section about CSS shows incorrect pattern and usage example for the CSS version:
The class name in the example mentions classes with "-Secondary" at the end
Actual classes inside the palette.css do not have that suffix (except for Black and White)
Description example:
<div class="palette-Light-Blue-700-Secondary bg">
The background is Light Blue
The text is White
</div>
.palette-Light-Blue-700.bg {
background-color: #0288D1;
}
.palette-Light-Blue-700.text {
color: #0288D1;
}
As you can see from the Google Material color specs certain colors require different text colors (black or white).
It would be quite useful to have this available.
Hi,
When I attempt to call palette('Light Blue', 700);
I get the error:
$result: map-get($colorMap, $shade);
^
Argument `$map` of `map-get($map, $key)` must be a map
Backtrace:
node_modules/google-material-color/dist/palette.scss:637, in function `map-get`
node_modules/google-material-color/dist/palette.scss:637, in function `palette`
But palette('Blue', 700);
works fine.
Are you aware of this? node-sass
is a commonly used library.
I will post a reference to this issue there also to see if they simply don't support spaces.
Hi,
Can you please update Lodash in you dependencies?
I'm seeing one vulnerability - Lodash Prototype Pollution.
Thanks
For example: to get back rgb and rgba
I have used google-material-color on my project.
It works well, but my project base on Angular2 and TypeScript.
Once I compile my project, tsc(typscript compiler) show me the error, which say 'cannot find module ...'
Do you have any plan for typings?
in https://material.google.com/style/color.html#color-color-palette there is a "Black" palette with just a "white" entry
This seems to be missing from the list of colors in this lib
Hi,
in the README file there's an error.
@import 'palette';
...
.my-div {
.palette('Light Blue', '700');
background-color: @palette;
.palette('Red'); // default shade is 500
color: @palette;
}
In LESS you can't do this.
The @palette
variable will be orverwritten by the second mixin call.
So, @palette is equal to Red color both for background-color and color assignments.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.