mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Implement the unitless length quirk for vertical-align
This commit is contained in:
parent
16dd554534
commit
59a7819aa9
2 changed files with 2 additions and 19 deletions
|
@ -264,6 +264,7 @@ ${helpers.single_keyword("position", "static absolute relative fixed",
|
|||
use std::fmt;
|
||||
use style_traits::ToCss;
|
||||
use values::HasViewportPercentage;
|
||||
use values::specified::AllowQuirks;
|
||||
|
||||
<% vertical_align = data.longhands_by_name["vertical-align"] %>
|
||||
<% vertical_align.keyword = Keyword("vertical-align",
|
||||
|
@ -306,7 +307,7 @@ ${helpers.single_keyword("position", "static absolute relative fixed",
|
|||
/// baseline | sub | super | top | text-top | middle | bottom | text-bottom
|
||||
/// | <percentage> | <length>
|
||||
pub fn parse(context: &ParserContext, input: &mut Parser) -> Result<SpecifiedValue, ()> {
|
||||
input.try(|i| specified::LengthOrPercentage::parse(context, i))
|
||||
input.try(|i| specified::LengthOrPercentage::parse_quirky(context, i, AllowQuirks::Yes))
|
||||
.map(SpecifiedValue::LengthOrPercentage)
|
||||
.or_else(|_| {
|
||||
match_ignore_ascii_case! { &try!(input.expect_ident()),
|
||||
|
|
|
@ -24,9 +24,6 @@
|
|||
expected:
|
||||
if os == "mac": FAIL
|
||||
|
||||
[vertical-align: 1 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
[word-spacing: 1 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
|
@ -54,9 +51,6 @@
|
|||
expected:
|
||||
if os == "mac": FAIL
|
||||
|
||||
[vertical-align: +1 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
[word-spacing: +1 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
|
@ -84,9 +78,6 @@
|
|||
expected:
|
||||
if os == "mac": FAIL
|
||||
|
||||
[vertical-align: -1 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
[word-spacing: -1 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
|
@ -114,9 +105,6 @@
|
|||
expected:
|
||||
if os == "mac": FAIL
|
||||
|
||||
[vertical-align: 1.5 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
[word-spacing: 1.5 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
|
@ -144,9 +132,6 @@
|
|||
expected:
|
||||
if os == "mac": FAIL
|
||||
|
||||
[vertical-align: +1.5 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
[word-spacing: +1.5 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
|
@ -174,9 +159,6 @@
|
|||
expected:
|
||||
if os == "mac": FAIL
|
||||
|
||||
[vertical-align: -1.5 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
[word-spacing: -1.5 (quirks)]
|
||||
expected: FAIL
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue