Skip to content

Commit 519acb0

Browse files
committed
1 parent eacc98e commit 519acb0

File tree

5 files changed

+39
-3
lines changed

5 files changed

+39
-3
lines changed

after/syntax/css/css-color-4.vim

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
syn match cssColorProp contained "\<color-adjust\>"
2+
syn keyword cssColor contained rebeccapurple
3+
syn region cssFunction contained matchgroup=cssFunctionName start="\<\(hwb\|lab\|lch\|gray\|color\|device-cmyk\|color-mod\=\)\s*(" end=")" oneline keepend
4+
syn match cssFontDescriptor "@color-profile\>" nextgroup=cssFontDescriptorBlock skipwhite skipnl

after/syntax/css/css3-color.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
syn region cssFunction contained matchgroup=cssFunctionName start="\<\(rgba\|hsla\=\)\s*(" end=")" oneline keepend
22
syn keyword cssColorProp contained opacity
3-
syn match cssColor contained "\<currentColor\>"
3+
syn match cssColor contained "\<currentcolor\>"

after/syntax/html.vim

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ syn include @htmlCss syntax/css/css-break-3.vim
55
syn include @htmlCss syntax/css/css-cascade-3.vim
66
syn include @htmlCss syntax/css/css-cascade-4.vim
77
syn include @htmlCss syntax/css/css-content-3.vim
8+
syn include @htmlCss syntax/css/css-color-4.vim
89
syn include @htmlCss syntax/css/css-counter-styles-3.vim
910
syn include @htmlCss syntax/css/css-device-adapt-1.vim
1011
syn include @htmlCss syntax/css/css-display-3.vim

test/test.css

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,22 @@
9090
.color {
9191
opacity: rgba(0, 0, 0, 1);
9292
display: hsla(0, 0, 0, 1);
93-
display: currentColor;
93+
display: currentcolor;
94+
}
95+
96+
@color-profile swopc {
97+
src: url('http://example.org/swop-coated.icc');
98+
}
99+
100+
.color-4 {
101+
color-adjust: rebeccapurple;
102+
display: hwb(120deg, 44%, 50%);
103+
display: lab(1 2 3);
104+
display: lch(4 5 6);
105+
display: gray(50%);
106+
display: color(swopc, 0 206 190 77);
107+
display: device-cmyk(0, 81%, 81%, 30%);
108+
display: color-mod(#112233 tint(50%));
94109
}
95110

96111
@supports (display: auto) or

test/test.html

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,23 @@
108108
.color {
109109
opacity: rgba(0, 0, 0, 1);
110110
display: hsla(0, 0, 0, 1);
111-
display: currentColor;
111+
display: currentcolor;
112+
}
113+
</style>
114+
<style>
115+
@color-profile swopc {
116+
src: url('http://example.org/swop-coated.icc');
117+
}
118+
119+
.color-4 {
120+
color-adjust: rebeccapurple;
121+
display: hwb(120deg, 44%, 50%);
122+
display: lab(1 2 3);
123+
display: lch(4 5 6);
124+
display: gray(50%);
125+
display: color(swopc, 0 206 190 77);
126+
display: device-cmyk(0, 81%, 81%, 30%);
127+
display: color-mod(#112233 tint(50%));
112128
}
113129
</style>
114130
<style>

0 commit comments

Comments
 (0)