W3C home > Mailing lists > Public > www-style@w3.org > June 2012

Re: Sticky Positioning

From: Alexandre Elias <aelias@chromium.org>
Date: Thu, 28 Jun 2012 13:52:14 -0700
Message-ID: <CADeTeo4b4wpFQJOR0TT+azf6MgChkCgvGpkV5R3O9zv9iTqXZA@mail.gmail.com>
To: Maciej Stachowiak <mjs@apple.com>
Cc: Ojan Vafai <ojan@chromium.org>, "Edward O'Connor" <eoconnor@apple.com>, www-style@w3.org, James Robinson <jamesr@chromium.org>
Sorry about that, looks like the behavior is currently restricted to
Android.

You can simulate an Android browser in desktop Chrome (I tested the
following using version 20 beta) by doing the following:
- Visit http://google.com/
- Click "Developer tools", then the small gear at the bottom right of the
panel.
- Click "Override User Agent" and select "Android 2.3 - Nexus S" (not
Galaxy Nexus as the high resolution somehow breaks the behavior I'm
describing in this desktop simulation mode -- though it does happen on a
real Galaxy Nexus)
- Reload the page to see the mobile version, then click "Restaurants" as
before.

You should see the map is sticky, then appears to reach a limit and
gradually falls out of view if you scroll down to the bottom of the page.



On Thu, Jun 28, 2012 at 1:27 PM, Maciej Stachowiak <mjs@apple.com> wrote:

>
> On Jun 27, 2012, at 11:48 AM, Alexandre Elias <aelias@chromium.org> wrote:
>
> I was also discussing this with jamesr just last week, we definitely agree
> the problem needs addressing.
>
> Like Ojan, I prefer a "position-contain" type approach as it's more
> general.  For an example of a site that would benefit, if you visit
> http://google.com/ on a phone and tap "Restaurants", you'll get to a
> search results view with a fixed-positioned map with the "sticky"-style
> behavior (simulated in JS).  Observe that the map drops out of view when
> you reach the bottom of the page, which I don't think is expressible by
> "sticky".
>
>
> Sounds like a very interesting use case! I'd really like to check it out
> to understand it. But I was unable to replicate the behavior you described
> on my iPhone. The map did not stick. Is there something else I can try to
> see the example?
>
> Cheers,
> Maciej
>
>
Received on Thursday, 28 June 2012 20:52:44 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:55 GMT