Deprecated: array_first(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/october/rain/src/Support/helpers.php on line 376
Deprecated: array_last(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/october/rain/src/Support/helpers.php on line 443
Deprecated: optional(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Support/helpers.php on line 202
Deprecated: with(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Support/helpers.php on line 434
Deprecated: Illuminate\Container\Container::beforeResolving(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 1128
Deprecated: Illuminate\Container\Container::resolving(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 1148
Deprecated: Illuminate\Container\Container::afterResolving(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 1168
Deprecated: Illuminate\Container\Container::setInstance(): Implicitly marking parameter $container as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 1407
Deprecated: Illuminate\Contracts\Container\Container::beforeResolving(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Contracts/Container/Container.php on line 191
Deprecated: Illuminate\Contracts\Container\Container::resolving(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Contracts/Container/Container.php on line 200
Deprecated: Illuminate\Contracts\Container\Container::afterResolving(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Contracts/Container/Container.php on line 209
Deprecated: Illuminate\Support\Arr::first(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Collections/Arr.php on line 188
Deprecated: Illuminate\Support\Arr::last(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Collections/Arr.php on line 217
Deprecated: Illuminate\Routing\Router::__construct(): Implicitly marking parameter $container as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Routing/Router.php on line 134
Deprecated: Illuminate\Routing\Router::model(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Routing/Router.php on line 1135
Deprecated: Illuminate\Events\Dispatcher::__construct(): Implicitly marking parameter $container as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Events/Dispatcher.php on line 65
Deprecated: Illuminate\Http\Request::duplicate(): Implicitly marking parameter $query as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Http/Request.php on line 501
Deprecated: Illuminate\Http\Request::duplicate(): Implicitly marking parameter $request as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Http/Request.php on line 501
Deprecated: Illuminate\Http\Request::duplicate(): Implicitly marking parameter $attributes as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Http/Request.php on line 501
Deprecated: Illuminate\Http\Request::duplicate(): Implicitly marking parameter $cookies as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Http/Request.php on line 501
Deprecated: Illuminate\Http\Request::duplicate(): Implicitly marking parameter $files as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Http/Request.php on line 501
Deprecated: Illuminate\Http\Request::duplicate(): Implicitly marking parameter $server as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Http/Request.php on line 501
Deprecated: Illuminate\Http\Concerns\InteractsWithInput::whenHas(): Implicitly marking parameter $default as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithInput.php on line 123
Deprecated: Illuminate\Http\Concerns\InteractsWithInput::whenFilled(): Implicitly marking parameter $default as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithInput.php on line 201
Deprecated: Illuminate\Http\Concerns\InteractsWithInput::whenMissing(): Implicitly marking parameter $default as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithInput.php on line 235
Deprecated: Illuminate\Support\Str::createRandomStringsUsing(): Implicitly marking parameter $factory as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Support/Str.php on line 755
Deprecated: Illuminate\Support\Str::createUuidsUsing(): Implicitly marking parameter $factory as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Support/Str.php on line 1274
Deprecated: Illuminate\Support\Str::freezeUuids(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Support/Str.php on line 1319
Deprecated: Illuminate\Support\Traits\Conditionable::when(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Conditionable/Traits/Conditionable.php on line 21
Deprecated: Illuminate\Support\Traits\Conditionable::when(): Implicitly marking parameter $default as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Conditionable/Traits/Conditionable.php on line 21
Deprecated: Illuminate\Support\Traits\Conditionable::unless(): Implicitly marking parameter $callback as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Conditionable/Traits/Conditionable.php on line 53
Deprecated: Illuminate\Support\Traits\Conditionable::unless(): Implicitly marking parameter $default as nullable is deprecated, the explicit nullable type must be used instead in /www/s/a/u8413/public_html/vendor/laravel/framework/src/Illuminate/Conditionable/Traits/Conditionable.php on line 53
document.addEventListener('DOMContentLoaded', function () {
const navbarToggler = document.querySelector(".navbar-toggler");
const navbarCollapse = document.querySelector(".navbar-collapse");
const navLinks = document.querySelectorAll(".nav-link, .dropdown-item");
const header = document.querySelector(".header");
// Spoľahlivé prepínanie menu s Bootstrap udalosťami
navbarCollapse.addEventListener('show.bs.collapse', function () {
navbarToggler.classList.add("open");
header.classList.add("open");
document.body.classList.add("overflow-hidden");
});
navbarCollapse.addEventListener('hide.bs.collapse', function () {
navbarToggler.classList.remove("open");
header.classList.remove("open");
document.body.classList.remove("overflow-hidden");
});
// Kliknutie na anchor odkaz (zatvorenie menu + skok na sekciu)
navLinks.forEach(link => {
link.addEventListener("click", function (event) {
const targetId = this.getAttribute("href");
if (targetId.startsWith("#") && window.innerWidth <= 991) {
event.preventDefault(); // Zabráni okamžitému skoku na sekciu
closeMenu(); // Najprv zatvoríme menu
setTimeout(() => {
const targetElement = document.querySelector(targetId);
if (targetElement) {
// Ak sme na domovskej stránke, smooth scroll na sekciu
window.scrollTo({
top: targetElement.offsetTop - 50, // Posun, aby sekcia nebola zakrytá headerom
behavior: "smooth"
});
} else {
// Ak sme na inej stránke, presmerujeme na home + anchor
window.location.href = "/" + targetId;
}
}, 300); // Dáme Bootstrapu čas na zatvorenie menu
}
});
});
/**
* Dropdown behavior
*/
const dropdownToggles = document.querySelectorAll('.nav-item.dropdown > .nav-link');
const mobileBreakpoint = 991;
function updateDropdownBehavior() {
dropdownToggles.forEach(toggle => {
if (window.innerWidth <= mobileBreakpoint) {
toggle.setAttribute('data-bs-toggle', 'dropdown');
} else {
toggle.removeAttribute('data-bs-toggle');
}
});
}
updateDropdownBehavior();
window.addEventListener('resize', updateDropdownBehavior);
/**
* Navbar links styling
*/
function applyStyles() {
if (window.innerWidth < 991) {
const navLinks = document.querySelectorAll('.nav-link');
navLinks.forEach((link, index) => {
if (index < 3) {
link.style.fontSize = '2rem';
link.style.lineHeight = '2.5rem';
link.style.fontWeight = '700';
} else {
link.style.fontSize = '';
link.style.lineHeight = '';
link.style.fontWeight = '';
}
});
} else {
const navLinks = document.querySelectorAll('.nav-link');
navLinks.forEach((link) => {
link.style.fontSize = '';
link.style.lineHeight = '';
link.style.fontWeight = '';
});
}
}
document.addEventListener('DOMContentLoaded', applyStyles);
window.addEventListener('resize', applyStyles);
});