F
F
fajjet2015-10-06 16:44:14
JavaScript
fajjet, 2015-10-06 16:44:14

How to track browser zoom on mobile and tablets?

Let's say I have a slider. That's when the user accidentally or intentionally scales the browser - you need to track this and do nothing. And then it is perceived as resize and unnecessary transformations occur.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
H
HoHsi, 2015-10-06
@HoHsi

What do you mean by "do nothing"? If you do not have a percentage layout, but a fixed one, the browser will not do anything.

V
v-orlov, 2015-10-15
@v-orlov

set a hard width (or minimum) in css at the desired resolution,
such as

@media (min-width: 920px) and (max-width: 1600px) {
  .slider {
  width: 1000px;
  }
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question