Skip to content

Commit

Permalink
Merge pull request #103 from makeen-project/bug_ALS-1736_safari-backg…
Browse files Browse the repository at this point in the history
…round-issue_main

[Bug ALS-1736] safari background issue
  • Loading branch information
wadhawh authored Nov 15, 2023
2 parents 811a9cc + e2211d2 commit 631a6b5
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/atomicui/pages/DemoPage/DemoPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,14 @@ const DemoPage: React.FC = () => {
[show.unauthGeofenceBox, show.unauthTrackerBox, isUserAwsAccountConnected, isGrabAvailableInRegion]
);

useEffect(() => {
document.addEventListener("visibilitychange", () => {
if (document.visibilityState === "visible") {
window.location.reload();
}
});
}, []);

useEffect(() => {
let previousWidth = document.body.clientWidth;
const resizeObserver = new ResizeObserver(() => {
Expand Down

0 comments on commit 631a6b5

Please sign in to comment.