PageSourceSearch

https://flamboyanturbanismo.com.br/wp-content/themes/flamboyant-urbanismo/js/script.js?v=0.2.3

js flamboyanturbanismo.com.br collected 2026-10-06 04:44:55 UTC 6,104 bytes, 186 lines download raw bytes

1$(function () {
2    $('a.page-scroll').bind('click', function (event) {
3        var topMenuHeight = $(".navbar").height();
4        console.log(topMenuHeight);
5        var $anchor = $(this);
6        $('html, body').stop().animate({
7            scrollTop: $($anchor.attr('href')).offset().top
8        }, 1000, 'easeInOutExpo');
9        event.preventDefault();
10    });
11
12    $('a.scroll-link').on('click', function(e) {
13        e.preventDefault();
14    
15        var target = $(this).attr('href');
16        $('html, body').animate({
17            scrollTop: $(target).offset().top
18        }, 'slow');
19    });
20});
21
22jQuery(document).ready(function ($) {
23    // var topMenu = jQuery(".navbar"),
24    //     offset = 0,
25    //     topMenuHeight = jQuery(".navbar").height(),
26    //     // All list items
27    //     menuItems = topMenu.find('a[href*="#"]'),
28    //     // Anchors corresponding to menu items
29    //     scrollItems = menuItems.map(function () {
30    //         var href = jQuery(this).attr("href"),
31    //             id = href.substring(href.indexOf("#") + 1),
32    //             item = jQuery(id);
33    //         // console.log(item)
34    //         if (item.length) { return item; }
35    //     });
36
37    // Bind to scroll
38    // jQuery(window).scroll(function () {
39    //     // Get container scroll position
40    //     var fromTop = jQuery(this).scrollTop() + topMenuHeight;
41
42    //     // Get id of current scroll item
43    //     var cur = scrollItems.map(function () {
44    //         if (jQuery(this).offset().top < fromTop)
45    //             return this;
46    //     });
47
48    //     // Get the id of the current element
49    //     cur = cur[cur.length - 1];
50    //     var id = cur && cur.length ? cur[0].id : "";
51
52    //     menuItems.parent().removeClass("active");
53    //     if (id) {
54    //         menuItems.parent().end().filter(`href='#${id}'`).addClass("active");
55    //     }
56    // });
57
58    function checkWidth() {
59        var windowSize = $(window).width();
60
61        if(windowSize > 1199) {
62            $('.aux_container_left').css( "margin-left",  ($('footer .container').width()-windowSize)/2);
63            $('.aux_container_left_padding').css( "padding-left",  (windowSize-$('footer .container').width())/2);
64            $('.aux_container_right_margin').css( "margin-right",  ($('footer .container').width()-windowSize)/2);
65            $('.aux_container_right_padding').css( "padding-right",  (windowSize-$('footer .container').width())/2);
66        }
67    }
68    // Execute on load
69    checkWidth();
70    // Bind event listener
71    $(window).resize(function(){
72        checkWidth();
73    });
74});
75
76
77
78// AOS.init({
79//     offset: 50,
80//     once: true,
81// });
82
83// AOS.init({
84//     once: true
85// });
86
87jQuery(function ($) {
88    if ($("#modalVideo").length) {
89        var url = $("#modalVideo iframe").attr('src');
90
91        /* Remove iframe src attribute on page load to
92        prevent autoplay in background */
93        // $("#modalVideo iframe").attr('src', '');
94
95        /* Assign the initially stored url back to the iframe src
96        attribute when modal is displayed */
97        $("#modalVideo").on('shown.bs.modal', function () {
98            $("#modalVideo iframe").attr('src', url + '&autoplay=1');
99        });
100
101        /* Assign empty url value to the iframe src attribute when
102        modal hide, which stop the video playing */
103        $("#modalVideo").on('hide.bs.modal', function () {
104            $("#modalVideo iframe").attr('src', '');
105        });
106    }
107    // if($('.celular').length) {
108    //     $('.celular').mask("(99) 99999-9999", {reverse: false});
109    // }
110
111    // if($('.cpf').length) {
112    //     $('.cpf').mask("999.999.999-99", {reverse: false});
113    // }
114});
115
116function MostrarLoad(){
117    if($('#loader-wrapper').length) {
118        $('#loader-wrapper').removeClass('stoped');
119    } else {
120        $('body').append('<div id="loader-wrapper"><div id="loader"></div><div class="loader-section section-left"></div><div class="loader-section section-right"></div></div>');
121    }
122    //console.log("Mostrando mensagem de load");
123}
124
125function PararLoad(ObjLoad){
126    $('#loader-wrapper').addClass('stoped');
127    //console.log("Parando mensagem de load");
128}
129
130function MostrarSucesso(RetornoSucesso, funcaoAceite){
131    console.log("Atividade realizada com sucesso");
132    console.log(RetornoSucesso);
133}
134
135function MostrarErro(RetornoErro){
136    console.log("Atividade realizada com erros");
137    console.log(RetornoErro);
138
139    let mensagemErroText = '';
140    
141    if(RetornoErro.hasOwnProperty('responseJSON')) {
142        if(RetornoErro.responseJSON.hasOwnProperty('mensagenserro')) {
143            $.each(RetornoErro.responseJSON.mensagenserro, function(i, item){
144                mensagemErroText += '<p>'+item+'</p>';
145            });    
146        }
147    }
148    
149    if(mensagemErroText == '') {
150        if(RetornoErro.hasOwnProperty('responseJSON')) {
151            if(RetornoErro.responseJSON.hasOwnProperty('mensagem')) {
152                mensagemErroText = '<p>'+RetornoErro.responseJSON.mensagem+'</p>';
153            }
154        }
155    }
156
157    Swal.fire({
158        title: 'Erro!'
159        , html: mensagemErroText
160        , icon: 'error'
161        , confirmButtonText: 'OK'
162    })
163}
164
165// Função para criar um cookie
166function setCookie(name, value, days) {
167    var expires = "";
168    if (days) {
169        var date = new Date();
170        date.setTime(date.getTime() + (days * 24 * 60 * 60 * 1000));
171        expires = "; expires=" + date.toUTCString();
172    }
173    document.cookie = name + "=" + (value || "") + expires + "; path=/";
174}
175
176// Função para obter o valor de um cookie
177function getCookie(name) {
178    var nameEQ = name + "=";
179    var ca = document.cookie.split(';');
180    for (var i = 0; i < ca.length; i++) {
181        var c = ca[i];
182        while (c.charAt(0) === ' ') c = c.substring(1, c.length);
183        if (c.indexOf(nameEQ) === 0) return c.substring(nameEQ.length, c.length);
184    }
185    return null;
186}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.