Device depending display of different zoom options

Depending on the setup, sometimes it is required for different types of zoom depending on the available screen dimensions,
e.g. you prefer to use FSI QuickZoom on desktop devices, but would like to use FSI Viewer JS on mobile devices to present
a satisfying zoom experience to the user.

The following code snippet demonstrates how to achieve the given setup:

Copy to Clipboard

Here we create an <fsi-viewer> tag when the webpage is visited by a mobile device or a normal <image> tag otherwise.
The created tag is appended to a <DIV> which will hold the image or FSI Viewer JS somewhere in your HTML:

Copy to Clipboard

After the tag has been appended, the preferred zoom feature from FSI gets activated.

View Sample with isMobile

If you like to target touch devices in general, instead of checking for

Copy to Clipboard

you can also check for

Copy to Clipboard

this will also create an FSI Viewer JS on touch enabled desktop monitors.

View Sample with isTouch