185 lines
5.1 KiB
HTML
185 lines
5.1 KiB
HTML
{literal}
|
|
<!--[if IE 9]>
|
|
<style type="text/css">
|
|
select.form-control
|
|
{
|
|
padding-right: 0;
|
|
background-image: none;
|
|
}
|
|
</style>
|
|
<![endif]-->
|
|
<script type="text/javascript">
|
|
//<![CDATA[
|
|
jQuery(function($) {
|
|
var menuHeight = $('#header-navbar').height();
|
|
var dropdown = $('#nav-menu .dropdown-menu');
|
|
|
|
$(document).ready(function(){
|
|
$('body [data-equalizer]').equalizer({ use_tallest: true });
|
|
|
|
$(window).scroll(function () {
|
|
if ($(this).scrollTop() > 200) {
|
|
$('#toTopNew').addClass('show');
|
|
} else {
|
|
$('#toTopNew').removeClass('show');
|
|
}
|
|
});
|
|
|
|
$('#toTopNew').click(function () {
|
|
$("html, body").animate({
|
|
scrollTop: 0
|
|
}, 300);
|
|
return false;
|
|
});
|
|
|
|
$(window).load(function(){
|
|
setTimeout(function(){
|
|
if (($('#chat-application').length == 1) || ($('#livechat').length == 1) || ($('.fb_dialog_content iframe').length == 1)) {
|
|
$('#toTopNew').addClass('upper');
|
|
}
|
|
}, 500);
|
|
});
|
|
|
|
var scroll = false;
|
|
var $window = $(window);
|
|
$window.scroll(function() {
|
|
scroll = true;
|
|
});
|
|
|
|
setInterval(function() {
|
|
if (scroll) {
|
|
if($window.scrollTop() + $window.height() >= $(document).height()-250) {
|
|
$('#phone-call').addClass('show');
|
|
}else{
|
|
$('#phone-call').removeClass('show');
|
|
}
|
|
scroll = false;
|
|
}
|
|
}, 255);
|
|
|
|
$('#nav-button-search.collapsed').click(function() {
|
|
setTimeout(function(){
|
|
$('#nav-search .form-control').focus();
|
|
}, 300);
|
|
});
|
|
|
|
if ($('#nav-settings > ul > li:empty').length == 2)
|
|
{
|
|
$('#nav-button-settings').hide();
|
|
}
|
|
|
|
if ($(window).width() < 768) {
|
|
var windowHeightMobile = $(window).height();
|
|
var menuHeightMobile = $('#header-navbar').height();
|
|
$('#header-navbar .navbar-collapse').css('max-height', windowHeightMobile - menuHeightMobile);
|
|
};
|
|
|
|
$("#homepage-carousel .social .icons").hover(
|
|
function() {
|
|
$('#homepage-carousel .social .h5, #homepage-carousel .social .space').css( "opacity", '0' );
|
|
}, function() {
|
|
$('#homepage-carousel .social .h5, #homepage-carousel .social .space').css( "opacity", '' );
|
|
}
|
|
);
|
|
|
|
});
|
|
|
|
$(window).load(function(){
|
|
setTimeout(function() {
|
|
$('#homepage-carousel .social').addClass('show-social');
|
|
}, 1000);
|
|
|
|
setTimeout(function() {
|
|
$('#homepage-carousel .swiper-pagination').addClass('show-pagination');
|
|
}, 1200);
|
|
|
|
});
|
|
|
|
});
|
|
//]]>
|
|
</script>
|
|
{/literal}
|
|
|
|
|
|
{if ($sf_context->getActionName()=='index' && $sf_context->getModuleName()=='stFrontendMain')}
|
|
{if $theme_config->getConfigParameter('layout_config.menu_show') === 'show'}
|
|
{literal}
|
|
<style>
|
|
#homepage-layout
|
|
{
|
|
padding-top: 70px;
|
|
}
|
|
</style>
|
|
{/literal}
|
|
{else}
|
|
{literal}
|
|
<script type="text/javascript">
|
|
//<![CDATA[
|
|
jQuery(function($) {
|
|
$(document).ready(function(){
|
|
|
|
const bannerHomepage = $('#homepage-carousel').length;
|
|
if (bannerHomepage){
|
|
var st = $(this).scrollTop();
|
|
if (st > 75){
|
|
$('#header-navbar').addClass('bg-menu');
|
|
}else{
|
|
$('#header-navbar').removeClass('bg-menu');
|
|
}
|
|
|
|
var lastScrollTop = 0;
|
|
$(window).scroll(function(event){
|
|
var st = $(this).scrollTop();
|
|
if (st > 75){
|
|
$('#header-navbar').addClass('bg-menu');
|
|
}else{
|
|
$('#header-navbar').removeClass('bg-menu');
|
|
}
|
|
});
|
|
}else{
|
|
const topHeight = $('#header-navbar').height();
|
|
$('#header-navbar').addClass('bg-menu');
|
|
$('#homepage-layout').css('padding-top', topHeight+20);
|
|
}
|
|
|
|
});
|
|
});
|
|
//]]>
|
|
</script>
|
|
{/literal}
|
|
{/if}
|
|
{literal}
|
|
<script type="text/javascript">
|
|
//<![CDATA[
|
|
jQuery(function($) {
|
|
$(document).ready(function(){
|
|
const baner1Pagination = document.querySelector('#homepage-carousel .swiper-pagination');
|
|
const baner2Pagination = document.querySelector('#homepage-carouselbaner2 .swiper-pagination');
|
|
|
|
const observerPagination = new MutationObserver((mutationsList, observer) => {
|
|
mutationsList.forEach(mutation => {
|
|
const svgCode = '<svg width="22" height="20" viewBox="0 0 22 20" xmlns="http://www.w3.org/2000/svg"><path d="M21.4363 9.54809C23.1709 17.6429 17.8385 21.2407 11.0927 18.9921C4.79668 16.8934 2.54809 13.1457 0.749216 9.54809C-0.599941 4.60104 5.2464 1.43094 11.0927 0.553716C20.0871 -0.795589 20.0871 3.25193 21.4363 9.54809Z" fill="white"/></svg>';
|
|
|
|
if (mutation.type === 'childList') {
|
|
mutation.target.querySelectorAll('span').forEach(spanElement => {
|
|
spanElement.insertAdjacentHTML('beforeend', svgCode);
|
|
});
|
|
}
|
|
});
|
|
});
|
|
|
|
const configPaginationObserver = { childList: true, subtree: true };
|
|
|
|
if(baner1Pagination){
|
|
observerPagination.observe(baner1Pagination, configPaginationObserver);
|
|
}
|
|
if(baner2Pagination){
|
|
observerPagination.observe(baner2Pagination, configPaginationObserver);
|
|
}
|
|
});
|
|
});
|
|
//]]>
|
|
</script>
|
|
{/literal}
|
|
{/if}
|