Skip to content

Commit cdf2860

Browse files
authored
Allow panel to prevent auto-opening (#5)
2 parents 681725a + c783b84 commit cdf2860

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.idea

resources/js/cookiepanel.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
}
1919
});
2020

21-
if (! selectedCategories.length) {
21+
if (! selectedCategories.length && ! this.panelElement.getAttribute('data-preventopen')) {
2222
this.open();
2323
}
2424

0 commit comments

Comments
 (0)