Viewport tag does not working on Android Teams WebApp

김종진 1 Reputation point
2021-08-30T06:04:27.23+00:00

I'm tring to make task module that naviate url include viewport 'user-scalable=yes' on Teams WebApp.
I want to zoom out/in the page by pinch gesture.

It works very well on iOS phone, but does not work on android.

What can I do to work viewport 'user-scalable=yes' to pinch in task module on android teams webapp?

Microsoft Teams | Development
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Prasad-MSFT 9,061 Reputation points Microsoft External Staff Moderator
    2021-08-31T09:28:13.907+00:00

    Once try using 1 instead of yes for user-scalable:

    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=1">

    It can be set to either yes or 1
    The user-scalable property is translated into user-zoom with the following value translations.

    • yes and no are translated into zoom and fixed respectively.
    • Numbers ≥ 1, numbers ≤ -1, device-width and device-height are mapped to zoom
    • Numbers in the range <-1, 1>, and unknown values, are mapped to fixed

    Ref: https://drafts.csswg.org/css-device-adapt/#translate-meta-to-at-viewport
    https://www.prestashop.com/forums/topic/367462-solved-viewport-dude-zoom-on-mobile-devices/

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.