Element: msContentZoom event

You’re reading the English version of this content since no translation exists yet for this locale. Help us translate this article!

Non-standard
This feature is non-standard and is not on a standards track. Do not use it on production sites facing the Web: it will not work for every user. There may also be large incompatibilities between implementations and the behavior may change in the future.

The msContentZoom event fires when a user zooms the element (changes the scale of the content).

It is a proprietary event specific to Microsoft Edge and Internet Explorer.

Zoomed elements can expose their zoom level through msContentZoom (ie. scrollTop/Left). The zoom level can be reset with Element.msZoomTo().

Bubbles Unknown
Cancelable Unknown
Interface Unknown
Event handler property Unknown

Example

  contentZoom.addEventListener("MSContentZoom", function(e) {
     zoomFactor.value = contentZoom.msContentZoomFactor.toFixed(2);
  });

Specifications

Not part of any specification.

Browser compatibility

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidFirefox for AndroidOpera for AndroidSafari on iOSSamsung Internet
msContentZoom event
Non-standard
Chrome No support NoEdge Full support YesFirefox No support NoIE Full support YesOpera No support NoSafari No support NoWebView Android No support NoChrome Android No support NoFirefox Android No support NoOpera Android No support NoSafari iOS No support NoSamsung Internet Android No support No

Legend

Full support  
Full support
No support  
No support
Non-standard. Expect poor cross-browser support.
Non-standard. Expect poor cross-browser support.

See also