Skip to content

Commit

Permalink
Merge pull request #225 from hlxsites/issue-170
Browse files Browse the repository at this point in the history
Fixing screen fliker issue
  • Loading branch information
hparwani2 authored May 8, 2023
2 parents 22293c4 + d57bb97 commit eeb8287
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 0 deletions.
1 change: 1 addition & 0 deletions blocks/header/nav-utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ const REPLACE_SCRIPTS = new Map([
const IGNORE_SCRIPTS = new Set([
'/etc.clientlibs/nedbank/components/socialshare/clientlibs.min.js',
'/etc.clientlibs/nedbank/components/bankfilter/clientlibs.min.js',
'/6422e0f550a2/017d80491d7e/launch-e08352bc3db4.min.js',
]);

function cssLoaded() {
Expand Down
1 change: 1 addition & 0 deletions head.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<style id="at-body-style">body {opacity: 1 !important}</style>
<script src="/scripts/scripts.js" type="module" crossorigin="use-credentials"></script>
<link rel="stylesheet" href="/styles/styles.css"/>
<link rel="icon" href="data:,">
8 changes: 8 additions & 0 deletions scripts/delayed.js
Original file line number Diff line number Diff line change
Expand Up @@ -182,3 +182,11 @@ function createDigitalData() {
adobeotmscript.setAttribute('src', 'https://assets.adobedtm.com/6422e0f550a2/017d80491d7e/launch-1e8527b948f6-development.min.js');
document.head.append(adobeotmscript);
}());

setTimeout(() => {
const head = document.getElementsByTagName('head')[0];
if (head) {
const atBodyStyle = document.getElementById('at-body-style');
head.removeChild(atBodyStyle);
}
}, 30000);

0 comments on commit eeb8287

Please sign in to comment.