Skip to content

Commit 89f1e16

Browse files
committed
restore ability to match space-separated percent sign in rgb() values
1 parent 10d9a9e commit 89f1e16

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

after/syntax/css.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ function! s:PreviewCSSColorInLine()
134134
call substitute( substitute( substitute( getline('.'),
135135
\ '#\(\x\)\(\x\)\(\x\)\>', '\=s:SetMatcher(submatch(1).submatch(1).submatch(2).submatch(2).submatch(3).submatch(3), submatch(0))', 'g' ),
136136
\ '#\(\x\{6}\)\>', '\=s:SetMatcher(submatch(1), submatch(0))', 'g' ),
137-
\ 'rgba\?(\(\d\{1,3}%\?\)\s*,\s*\(\d\{1,3}%\?\)\s*,\s*\(\d\{1,3}%\?\)\s*\%(,[^)]*\)\?)', '\=s:SetMatcher(s:CalcRGBHexColor(submatch(1),submatch(2),submatch(3)),submatch(0))', 'g' )
137+
\ 'rgba\?(\(\d\{1,3}\s*%\?\)\s*,\s*\(\d\{1,3}\s*%\?\)\s*,\s*\(\d\{1,3}\s*%\?\)\s*\%(,[^)]*\)\?)', '\=s:SetMatcher(s:CalcRGBHexColor(submatch(1),submatch(2),submatch(3)),submatch(0))', 'g' )
138138
endfunction
139139

140140
if has("gui_running") || &t_Co==256

0 commit comments

Comments
 (0)