You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to dev-pl...@lists.mozilla.org
Summary: Mobile web pages contain two viewports, the layout viewport and
the visual viewport. The layout viewport consists of all the page contents
and is specified by the meta-viewport tag. The visual viewport is the
actual visible portion of the page on the screen excluding on-screen
keyboards, areas outside of a pinch-zoom area or any other on-screen
artifact that does not scale with the dimensions of the page. The purpose
of the Visual Viewport API is to allow web developers to explicitly query
the properties of the visual viewport.
Web developers can use this API in situations where they need to position
web page elements to remain visible on the screen regardless of the visible
portion of the web page. For example, if an image needs to be visible
regardless of the pinch-zoom level of the device, it can be positioned
relative to what’s shown on the screen using methods of the Visual Viewport
API.
Platform coverage: Available on both Android and Desktop. However, the API
will be useful on desktop after desktop pinch zooming has been implemented.
Without pinch zooming, there is no difference between the visual viewport
and the layout viewport.
Estimated release: In Firefox 63, we will release the API without event
handler attributes behind a pref. The event handlers onresize and onscroll
may be pushed to a later release. The timeline for enabling it by default
has not been decided yet.
Preference behind which this will be implemented:
dom.visualviewport.enabled
Is this feature enabled by default in sandboxed iframes? Yes
If allowed, does it preserve the current invariants in terms of what
sandboxed iframes can do? Yes
I'm not sure what this line means here. The spec does not restrict this
API to secure contexts, right? Do we plan to thus restrict it in our
implementation?
Implementing looks good to me, but we should make sure issues like that
are shaken out before we ship.
-Boris
Michael de Boer
unread,
Jul 24, 2018, 4:23:01 AM7/24/18
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Tanushree Podder, Mozilla dev-platform mailing list mailing list
> On 24 Jul 2018, at 01:36, Tanushree Podder <tpo...@mozilla.com> wrote:
>
> Summary: Mobile web pages contain two viewports, the layout viewport and
> the visual viewport. The layout viewport consists of all the page contents
> and is specified by the meta-viewport tag. The visual viewport is the
> actual visible portion of the page on the screen excluding on-screen
> keyboards, areas outside of a pinch-zoom area or any other on-screen
> artifact that does not scale with the dimensions of the page. The purpose
> of the Visual Viewport API is to allow web developers to explicitly query
> the properties of the visual viewport.
>
> Web developers can use this API in situations where they need to position
> web page elements to remain visible on the screen regardless of the visible
> portion of the web page. For example, if an image needs to be visible
> regardless of the pinch-zoom level of the device, it can be positioned
> relative to what’s shown on the screen using methods of the Visual Viewport
> API.
About the desktop perspective: is pinch-to-zoom a completely separate thing from full-page-zoom as can be controlled right now with Ctrl+ and Ctrl- using the
keyboard?
If that’s the case, I can see synchronization issues between the two features when they’re both in use.
My perception is that pinch-to-zoom is really full-page-zoom, but using the pointer coordinates as focal point instead of [0,0] and step-less zooming behaviour, instead of clamping to predefined steps.
If that’s not the case, I’d say the new API seems usable on desktop already once the page has been zoomed in.
Thanks,
Mike.
Cameron McCormack
unread,
Jul 24, 2018, 4:52:07 AM7/24/18
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Boris Zbarsky, dev-pl...@lists.mozilla.org
On Tue, Jul 24, 2018, at 12:22 PM, Boris Zbarsky wrote:
> On 7/23/18 7:36 PM, Tanushree Podder wrote:
> > Secure contexts: Yes
>
> I'm not sure what this line means here.
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
On 7/24/18 4:22 AM, Michael de Boer wrote:
> About the desktop perspective: is pinch-to-zoom a completely separate thing from full-page-zoom as can be controlled right now with Ctrl+ and Ctrl- using the
> keyboard?
Yes. As a simple example, full-page-zoom does relayout (e.g. can change
where linebreaks happen). pinch-to-zoom does not do relayout, as far as
I know.
-Boris
Botond Ballo
unread,
Jul 24, 2018, 6:33:09 PM7/24/18
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Michael de Boer, Mozilla dev-platform mailing list mailing list, Tanushree Podder
On Tue, Jul 24, 2018 at 4:22 AM, Michael de Boer <mde...@mozilla.com> wrote:
> About the desktop perspective: is pinch-to-zoom a completely separate thing from full-page-zoom as can be controlled right now with Ctrl+ and Ctrl- using the
> keyboard?
Yes. The two have different behaviours (as Boris mentioned, one
reflows the page, one does not).
> If that’s the case, I can see synchronization issues between the two features when they’re both in use.
Could you elaborate? As far as I'm aware, other browsers like Chrome
and Safari support both at the same time on desktop.
> My perception is that pinch-to-zoom is really full-page-zoom, but using the pointer coordinates as focal point instead of [0,0] and step-less zooming behaviour, instead of clamping to predefined steps.
Currently, pinch gestures on a trackpad are hooked up to perform
full-page zooming on desktop. This is a temporary measure until pinch
zooming is implemented on desktop. Once pinch zooming is implemented
on desktop, pinch gestures will be hooked up to perform that.
Thanks,
Botond
tpo...@mozilla.com
unread,
Jul 26, 2018, 2:08:11 PM7/26/18
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
On Monday, July 23, 2018 at 10:22:48 PM UTC-4, Boris Zbarsky wrote:
> On 7/23/18 7:36 PM, Tanushree Podder wrote:
> > Secure contexts: Yes
>
> I'm not sure what this line means here. The spec does not restrict this
> API to secure contexts, right? Do we plan to thus restrict it in our
> implementation?
>
Chrome supports the Visual Viewport API for non-secure contexts. As the spec does not mention any restrictions to secure contexts, we will also default to Chrome's behavior and make the API available to non-secure contexts for now. However, I have filed an issue (https://github.com/WICG/visual-viewport/issues/57) to discuss if the API should be restricted to secure contexts.