Skip to content

Commit

Permalink
Merge pull request #64 from envato/cookie-bot-swift-banner-fix
Browse files Browse the repository at this point in the history
Remove CSS opacity rule for CookieBot banner
  • Loading branch information
rafaelgonzalez committed May 30, 2024
2 parents eefd8b9 + 82a62e1 commit 34c1410
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
14 changes: 0 additions & 14 deletions cookiebot.css
Original file line number Diff line number Diff line change
Expand Up @@ -190,17 +190,3 @@ a.CybotCookiebotDialogDetailBodyContentTabsItem {
.CybotCookiebotDialogDetailBodyContentTabsItemSelected {
border-bottom: 3px solid hsl(0, 0%, 100%) !important;
}

/* The Cookiebot banner modifies the `top` attribute when it's loaded, causing
// a large layout shift. We force `top: 0 !important` in CSS and intercept any
// attempts to change the height of the banner using `translateY` instead,
// which does not trigger CLS issues.
// IMPORTANT: This CSS is dependent on the JS snippet. If you use this CSS without it,
// the banner will remain hidden.
*/

#CybotCookiebotDialog {
top: 0 !important;
opacity: 0 !important;
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@envato/cookie-consent",
"version": "2.0.1",
"version": "3.0.0.pre1",
"description": "Some helper functions to deal with cookie-consent",
"main": "dist/index.js",
"engines": {
Expand Down

0 comments on commit 34c1410

Please sign in to comment.