mirror of
https://github.com/alextselegidis/easyappointments.git
synced 2024-11-28 02:43:32 +03:00
Do not block the booking page if the cookieconsent is blocked (#1398)
This commit is contained in:
parent
341c79085c
commit
29e5fce89e
1 changed files with 2 additions and 3 deletions
|
@ -65,7 +65,7 @@ App.Pages.Booking = (function () {
|
||||||
* Initialize the module.
|
* Initialize the module.
|
||||||
*/
|
*/
|
||||||
function initialize() {
|
function initialize() {
|
||||||
if (Boolean(Number(vars('display_cookie_notice')))) {
|
if (Boolean(Number(vars('display_cookie_notice'))) && window?.cookieconsent) {
|
||||||
cookieconsent.initialise({
|
cookieconsent.initialise({
|
||||||
palette: {
|
palette: {
|
||||||
popup: {
|
popup: {
|
||||||
|
@ -426,11 +426,10 @@ App.Pages.Booking = (function () {
|
||||||
});
|
});
|
||||||
|
|
||||||
// Scroll to the top of the page. On a small screen, especially on a mobile device, this is very useful.
|
// Scroll to the top of the page. On a small screen, especially on a mobile device, this is very useful.
|
||||||
const scrollingElement = (document.scrollingElement || document.body);
|
const scrollingElement = document.scrollingElement || document.body;
|
||||||
if (window.innerHeight < scrollingElement.scrollHeight) {
|
if (window.innerHeight < scrollingElement.scrollHeight) {
|
||||||
scrollingElement.scrollTop = 0;
|
scrollingElement.scrollTop = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in a new issue