Skip to content

Commit 01b084a

Browse files
committed
Add inherit as value for border-bottom-color
Added additional tests to prevent a regression Fixes #71
1 parent 49f6d68 commit 01b084a

File tree

2 files changed

+65
-1
lines changed

2 files changed

+65
-1
lines changed

src/css/Properties.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ var Properties = {
9595
"bookmark-target" : "none | <uri> | <attr>",
9696
"border" : "<border-width> || <border-style> || <color>",
9797
"border-bottom" : "<border-width> || <border-style> || <color>",
98-
"border-bottom-color" : "<color>",
98+
"border-bottom-color" : "<color> | inherit",
9999
"border-bottom-left-radius" : "<x-one-radius>",
100100
"border-bottom-right-radius" : "<x-one-radius>",
101101
"border-bottom-style" : "<border-style>",

tests/css/Validation.js

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,70 @@
260260
"invert" : "Expected (<color> | inherit) but found 'invert'.",
261261
}
262262
}));
263+
264+
suite.add(new ValidationTestCase({
265+
property: "border-bottom-color",
266+
267+
valid: [
268+
"red",
269+
"#f00",
270+
"inherit",
271+
"transparent"
272+
],
273+
274+
invalid: {
275+
"foo" : "Expected (<color> | inherit) but found 'foo'.",
276+
"invert" : "Expected (<color> | inherit) but found 'invert'.",
277+
}
278+
}));
279+
280+
suite.add(new ValidationTestCase({
281+
property: "border-top-color",
282+
283+
valid: [
284+
"red",
285+
"#f00",
286+
"inherit",
287+
"transparent"
288+
],
289+
290+
invalid: {
291+
"foo" : "Expected (<color> | inherit) but found 'foo'.",
292+
"invert" : "Expected (<color> | inherit) but found 'invert'.",
293+
}
294+
}));
295+
296+
suite.add(new ValidationTestCase({
297+
property: "border-left-color",
298+
299+
valid: [
300+
"red",
301+
"#f00",
302+
"inherit",
303+
"transparent"
304+
],
305+
306+
invalid: {
307+
"foo" : "Expected (<color> | inherit) but found 'foo'.",
308+
"invert" : "Expected (<color> | inherit) but found 'invert'.",
309+
}
310+
}));
311+
312+
suite.add(new ValidationTestCase({
313+
property: "border-right-color",
314+
315+
valid: [
316+
"red",
317+
"#f00",
318+
"inherit",
319+
"transparent"
320+
],
321+
322+
invalid: {
323+
"foo" : "Expected (<color> | inherit) but found 'foo'.",
324+
"invert" : "Expected (<color> | inherit) but found 'invert'.",
325+
}
326+
}));
263327

264328
suite.add(new ValidationTestCase({
265329
property: "border-bottom-left-radius",

0 commit comments

Comments
 (0)