- From: Tab Atkins Jr. <jackalmage@gmail.com>
- Date: Tue, 21 Oct 2014 15:50:38 -0700
- To: Bruno Racineux <bruno@hexanet.net>
- Cc: "www-style@w3.org" <www-style@w3.org>
On Tue, Oct 21, 2014 at 2:33 PM, Bruno Racineux <bruno@hexanet.net> wrote: > It seems that both Firefox and IE have a bug with absolutely-positioned > items. > The spec is hard to grasp for absolute items, but in any case, there is a > discrepancy with webkit. > > I am wanting to use an absolutely positioning flex item on mobile > as fallback with -webkit–box and -moz–box for their lack of flex-flow > support. > > So for example, I have vertical flex items [ABC], with [B] and [C] at > 'order: 10', > [B] at 'order: 1' and [A] set to 'position: absolute' with 'top: inherit'. > > The way webkit behaves is that [A] absolutely-position below [B] with top > either set at 'initial' or 'inherit', > and acknowledge the reordering step of [A] now in second position (after B). > > If I set 'top' with a value, the 'top: 0' basis of [A] is the top root of > the flex wrapper in all browsers. > > What is the correct behavior for 'initial' or 'inherit' in this > circumstance? There's nothing special about "initial" or "inherit" here - they both just resolve to "auto" in this case. The behavior where B is placed below A is from older spec text, when we tried to make abspos children of flex containers act like they were flex items for the purpose of determining their "auto" position. That's no longer the case; they now act like they're all alone in the container and just determine their "auto" position from the justify-self/align-self properties. WebKit appears to have not yet been fixed to match this. Feel free to file a bug on them. ^_^ ~TJ
Received on Tuesday, 21 October 2014 22:51:25 UTC