mirror of
https://github.com/servo/servo.git
synced 2025-08-24 22:58:21 +01:00
Reject negative value for border-image-width
This commit is contained in:
parent
8b9dc9392b
commit
bf52419716
1 changed files with 2 additions and 2 deletions
|
@ -521,12 +521,12 @@ ${helpers.single_keyword("-moz-float-edge", "content-box margin-box",
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Parse for SingleSpecifiedValue {
|
impl Parse for SingleSpecifiedValue {
|
||||||
fn parse(context: &ParserContext, input: &mut Parser) -> Result<Self, ()> {
|
fn parse(_context: &ParserContext, input: &mut Parser) -> Result<Self, ()> {
|
||||||
if input.try(|input| input.expect_ident_matching("auto")).is_ok() {
|
if input.try(|input| input.expect_ident_matching("auto")).is_ok() {
|
||||||
return Ok(SingleSpecifiedValue::Auto);
|
return Ok(SingleSpecifiedValue::Auto);
|
||||||
}
|
}
|
||||||
|
|
||||||
if let Ok(len) = input.try(|input| LengthOrPercentage::parse(context, input)) {
|
if let Ok(len) = input.try(|input| LengthOrPercentage::parse_non_negative(input)) {
|
||||||
return Ok(SingleSpecifiedValue::LengthOrPercentage(len));
|
return Ok(SingleSpecifiedValue::LengthOrPercentage(len));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue