Simple demo page to show viewer behavior during resizing of the container. The viewers' container elements are styled with width and height of 100%, with dimensions set by CSS properties on a parent element.

Pick options to test:

These options apply to both of the demo viewers on the left (top and bottom).

Use v3.1 resize logic
Use new resize logic
Use polling
Use ResizeObserver
preserveImageSizeOnResize: false
preserveImageSizeOnResize: true
autoResize: true
autoResize: false

Click to resize the viewer: