Skip to content

Commit

Permalink
Merge pull request #17644 from chalbert/17135-fix-version-change
Browse files Browse the repository at this point in the history
Reload iframe when the url changes
  • Loading branch information
ndelangen authored Mar 22, 2022
2 parents 1c1e95d + 2096016 commit 7450c40
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/components/src/Zoom/ZoomIFrame.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ export class ZoomIFrame extends Component<IZoomIFrameProps> {

// this component renders an iframe, which gets updates via post-messages
// never update this component, it will cause the iframe to refresh
return false;
// the only exception is when the url changes, which happens when the version changes
return nextProps.children.props.src !== this.props.children.props.src;
}

setIframeInnerZoom(scale: number) {
Expand Down

0 comments on commit 7450c40

Please sign in to comment.