$('img').error(function () { $(this).attr("src", "https://www.casadoforromaringa.com.br/imagens/semfoto.jpg"); }); ; if ($('.bloco1').length > 0) { //http://manos.malihu.gr/code-example/responsive-custom-scrollbar-with-css3-media-queries/ $(".bloco1").mCustomScrollbar({ axis: "y", setHeight: 300, mouseWheel: {scrollAmount: 200} }); $(".bloco2").mCustomScrollbar({ axis: "y", setHeight: 300, mouseWheel: {scrollAmount: 200} }); $(".bloco3").mCustomScrollbar({ axis: "y", setHeight: 300, mouseWheel: {scrollAmount: 270} }); } new WOW().init(); $('#avalieHome').hover( function () { $('#avalieHome i').addClass('fa-star'); $('#avalieHome i').removeClass('fa-star-o'); }, function () { $('#avalieHome i').removeClass('fa-star'); $('#avalieHome i').addClass('fa-star-o'); ; } ); function showProd(idProd) { $('.hideProd').hide(); $('.hideProd' + idProd).fadeIn(); $('.hideSub').removeClass('prodActive'); $('#sub' + idProd).addClass('prodActive'); } function showSub2(idSub) { $('.hideSub').removeClass('prodActive'); $('.hideProd').hide(); $('.todosSub').hide(); $('#todosSub' + idSub).fadeIn(); $('.hideSub' + idSub).fadeIn(); } function showSub(idSub) { $('.selecioneCat').hide(); $('.hideSub').hide(); $('.hideProd').hide(); $('.todosSub').hide(); $('#todosSub' + idSub).fadeIn(); $('.hideSub' + idSub).fadeIn(); $('.prodActive').removeClass('prodActive'); $('#cat' + idSub).addClass('prodActive'); } var EstaTop = 1; var heightImgParallax1 = Array; $(window).scroll(function () { scroll(); }); function scroll() { if ($(window).scrollTop() > 153 && !$('#fixmargintop').hasClass('espacofixmenu')) { $('#fixmargintop').addClass('espacofixmenu'); $('#affixMenu').addClass('fidextop'); } else if ($(window).scrollTop() <= 153 && $('#fixmargintop').hasClass('espacofixmenu')) { $('#fixmargintop').removeClass('espacofixmenu'); $('#affixMenu').removeClass('fidextop'); } } if ($('#listaProd').length > 0) { rolaElem($('#rolaAqui'), false); } $(document).ready(function () { $('.banner').show(); scroll(); $('#fixBannerLoad').hide(); $('.telefone').focusout(function () { var phone, element; element = $(this); element.unmask(); phone = element.val().replace(/\D/g, ''); if (phone.length > 10) { element.mask("(99) 99999-999?9"); } else { element.mask("(99) 9999-9999?9"); } }).trigger('focusout'); if ($("#owl-demo").length > 0) { $("#owl-demo").owlCarousel({ navigation: false, // Show next and prev buttons slideSpeed: 300, paginationSpeed: 400, singleItem: true }); } }); $(window).resize(function () { scroll(); }); $(window).load(function () { $('.carousel').carousel({ interval: 4000 }) }); function rolaElem(elem, pc) { if(!elem.length)return; if (!pc) { if ($(window).width() <= 1000) { var scrtop = elem.offset().top - 95; $('html, body').animate({ scrollTop: scrtop }, 1000); } } else { var scrtop = elem.offset().top - 95; $('html, body').animate({ scrollTop: scrtop }, 1000); } } if ($(".banner").length > 0) { $(".tp-bannertimer").show(); $('.slider-banner-container .slider-banner').show().revolution({ delay: 10000, startwidth: 1140, startheight: 520, navigationArrows: "solo", navigationStyle: "round", navigationHAlign: "center", navigationVAlign: "bottom", navigationHOffset: 0, navigationVOffset: 20, soloArrowLeftHalign: "left", soloArrowLeftValign: "center", soloArrowLeftHOffset: 20, soloArrowLeftVOffset: 0, soloArrowRightHalign: "right", soloArrowRightValign: "center", soloArrowRightHOffset: 20, soloArrowRightVOffset: 0, fullWidth: "on", spinner: "spinner0", stopLoop: "off", stopAfterLoops: -1, stopAtSlide: -1, onHoverStop: "off", shuffle: "off", autoHeight: "off", forceFullWidth: "off", hideThumbsOnMobile: "off", hideNavDelayOnMobile: 1500, hideBulletsOnMobile: "off", hideArrowsOnMobile: "off", hideThumbsUnderResolution: 0, hideSliderAtLimit: 0, hideCaptionAtLimit: 0, hideAllCaptionAtLilmit: 0, startWithSlide: 0 }); $('.slider-banner-container .slider-banner-2').show().revolution({ delay: 10000, startwidth: 1140, startheight: 520, navigationArrows: "solo", navigationStyle: "preview4", navigationHAlign: "center", navigationVAlign: "bottom", navigationHOffset: 0, navigationVOffset: 20, soloArrowLeftHalign: "left", soloArrowLeftValign: "center", soloArrowLeftHOffset: 20, soloArrowLeftVOffset: 0, soloArrowRightHalign: "right", soloArrowRightValign: "center", soloArrowRightHOffset: 20, soloArrowRightVOffset: 0, fullWidth: "on", spinner: "spinner0", stopLoop: "off", stopAfterLoops: -1, stopAtSlide: -1, onHoverStop: "off", shuffle: "off", autoHeight: "off", forceFullWidth: "off", hideThumbsOnMobile: "off", hideNavDelayOnMobile: 1500, hideBulletsOnMobile: "off", hideArrowsOnMobile: "off", hideThumbsUnderResolution: 0, hideSliderAtLimit: 0, hideCaptionAtLimit: 0, hideAllCaptionAtLilmit: 0, startWithSlide: 0 }); $('.slider-banner-container .slider-banner-3').show().revolution({ delay: 10000, startwidth: 1140, startheight: 520, dottedOverlay: "twoxtwo", parallax: "mouse", parallaxBgFreeze: "on", parallaxLevels: [3, 2, 1], navigationArrows: "solo", navigationStyle: "preview5", navigationHAlign: "center", navigationVAlign: "bottom", navigationHOffset: 0, navigationVOffset: 20, soloArrowLeftHalign: "left", soloArrowLeftValign: "center", soloArrowLeftHOffset: 20, soloArrowLeftVOffset: 0, soloArrowRightHalign: "right", soloArrowRightValign: "center", soloArrowRightHOffset: 20, soloArrowRightVOffset: 0, fullWidth: "on", spinner: "spinner0", stopLoop: "off", stopAfterLoops: -1, stopAtSlide: -1, onHoverStop: "off", shuffle: "off", autoHeight: "off", forceFullWidth: "off", hideThumbsOnMobile: "off", hideNavDelayOnMobile: 1500, hideBulletsOnMobile: "off", hideArrowsOnMobile: "off", hideThumbsUnderResolution: 0, hideSliderAtLimit: 0, hideCaptionAtLimit: 0, hideAllCaptionAtLilmit: 0, startWithSlide: 0 }); $('.slider-banner-container .slider-banner-fullscreen').show().revolution({ delay: 10000, startwidth: 1140, startheight: 520, fullWidth: "off", fullScreen: "on", fullScreenOffsetContainer: "", fullScreenOffset: "82px", navigationArrows: "solo", navigationStyle: "preview4", navigationHAlign: "center", navigationVAlign: "bottom", navigationHOffset: 0, navigationVOffset: 20, soloArrowLeftHalign: "left", soloArrowLeftValign: "center", soloArrowLeftHOffset: 20, soloArrowLeftVOffset: 0, soloArrowRightHalign: "right", soloArrowRightValign: "center", soloArrowRightHOffset: 20, soloArrowRightVOffset: 0, spinner: "spinner4", stopLoop: "off", stopAfterLoops: -1, stopAtSlide: -1, onHoverStop: "off", shuffle: "off", hideTimerBar: "on", autoHeight: "off", forceFullWidth: "off", hideThumbsOnMobile: "off", hideNavDelayOnMobile: 1500, hideBulletsOnMobile: "off", hideArrowsOnMobile: "off", hideThumbsUnderResolution: 0, hideSliderAtLimit: 0, hideCaptionAtLimit: 0, hideAllCaptionAtLilmit: 0, startWithSlide: 0 }); }