Skip to content
This repository was archived by the owner on Dec 19, 2024. It is now read-only.

Commit d265dce

Browse files
committed
Support new colors
1 parent 02a20e3 commit d265dce

File tree

4 files changed

+23
-1
lines changed

4 files changed

+23
-1
lines changed

index.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ var features = {
66
import: require("postcss-import"),
77
customProperties: require("postcss-custom-properties"),
88
calc: require("postcss-calc"),
9-
customMedia: require("postcss-custom-media")
9+
customMedia: require("postcss-custom-media"),
10+
color: require("postcss-color")
1011
}
1112

1213
/**

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
"dependencies": {
2626
"postcss": "^2.1.0",
2727
"postcss-calc": "^2.0.1",
28+
"postcss-color": "^1.0.0",
2829
"postcss-custom-media": "^1.0.0",
2930
"postcss-custom-properties": "^0.1.0",
3031
"postcss-import": "^1.0.0",

test/features/color.css

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
body {
2+
background:
3+
rgb(102, 51, 153)
4+
linear-gradient(
5+
color(rebeccapurple a(50%)),
6+
hwb(0, 20%, 40%),
7+
color(hwb(0, 20%, 40%, .5) a(+10%)),
8+
color(#9d9c a(90%))
9+
)
10+
}

test/features/color.expected.css

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
body {
2+
background:
3+
rgb(102, 51, 153)
4+
linear-gradient(
5+
rgba(102, 51, 153, 0.5),
6+
rgb(153, 51, 51),
7+
rgba(153, 51, 51, 0.55),
8+
rgba(153, 221, 153, 0.9)
9+
)
10+
}

0 commit comments

Comments
 (0)