Skip to content

Commit 9b670b4

Browse files
committed
Do not print warning if print-color-adjust is also in the rule
1 parent bcc5ff6 commit 9b670b4

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

lib/processor.js

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -113,11 +113,13 @@ class Processor {
113113
let value = decl.value
114114

115115
if (prop === 'color-adjust') {
116-
result.warn(
117-
'Replace color-adjust to print-color-adjust. ' +
118-
'The color-adjust shorthand is currently deprecated.',
119-
{ node: decl }
120-
)
116+
if (parent.every(i => i.prop !== 'print-color-adjust')) {
117+
result.warn(
118+
'Replace color-adjust to print-color-adjust. ' +
119+
'The color-adjust shorthand is currently deprecated.',
120+
{ node: decl }
121+
)
122+
}
121123
} else if (prop === 'grid-row-span') {
122124
result.warn(
123125
'grid-row-span is not part of final Grid Layout. Use grid-row.',

0 commit comments

Comments
 (0)