PageSourceSearch

https://indianstreetfoodco.com/wp-content/themes/hello-elementor-child/assets/js/script.js?ver=1766497011

js indianstreetfoodco.com collected 2026-10-02 12:16:22 UTC 7,236 bytes, 136 lines download raw bytes

1/*
2 * SingleApp Website Cached Scripts
3 * www.indianstreetfoodco.com.vertical-2.script.js
4 * 2025-12-22 @ 04:31:31
5 */
6
7(function ($) {
8    "use strict";
9var thisWebsite = $("#website");
10var thisHeader = $("#header");              // hoặc $("#site-header") tùy theme
11var thisContent = $("#content");            // fallback
12window.templateSettings = window.templateSettings || {};
13window.templateSettings.bodyScrolledOffset = window.templateSettings.bodyScrolledOffset || 1;
14window.onLoadFunctions = window.onLoadFunctions || [];
15    jQuery(document).ready(function ($) {
16        if ($("#website").length) {
17            var thisNav = $("#nav");
18            $(".nav_toggle", thisWebsite).click(function (e) {
19                e.preventDefault();
20                if (thisWebsite.hasClass("nav_expanded")) {
21                    thisWebsite.removeClass("nav_expanded");
22                } else {
23                    thisWebsite.addClass("nav_expanded");
24                }
25            });
26            $(".item_page", thisNav).filter(".active").addClass("active2");
27            $(".item_page", thisNav).hover(
28                function (e) {
29                    if ($(this).hasClass("active2")) {
30                        return false;
31                    }
32                    $(".item_page", thisNav).filter(".active").removeClass("active");
33                    $(this).addClass("active");
34                    if ($(this).has(".list_subs")) {
35                        var thisSubs = $(this).find(".list_subs");
36                        var thisSubsHeight = thisSubs.outerHeight();
37                        thisSubs.css({ opacity: 0, height: 0 }).animate({ opacity: 1, height: thisSubsHeight + "px" }, 400, "swing", function () {
38                            thisSubs.css({ height: "" });
39                        });
40                    }
41                },
42                function (e) {
43                    if ($(this).hasClass("active2")) {
44                        return false;
45                    }
46                    $(".item_page", thisNav).filter(".active2").addClass("active");
47                    $(this).removeClass("active");
48                }
49            );
50            var thisPages = $("#pages");
51            $('.top_link, a[href="#top"]', thisPages).unbind("click");
52            $('.top_link, a[href="#top"]', thisPages)
53                .not("a[data-anchor]")
54                .click(function (e) {
55                    e.preventDefault();
56                    $("html, body").animate({ scrollTop: 0 }, 1000);
57                    return true;
58                });
59            $("a[data-anchor]", thisWebsite)
60                .not($("a[data-anchor]", thisNav))
61                .click(function (e) {
62                    e.preventDefault();
63                    e.stopPropagation();
64                    var tempAnchor = $(this).attr("data-anchor");
65                    var tempAnchorToken = tempAnchor.slice(1);
66                    var headerHeight = thisHeader.outerHeight();
67                    if ($('a[data-anchor="' + tempAnchor + '"]', thisNav).length) {
68                        $('a[data-anchor="' + tempAnchor + '"]', thisNav).trigger("click");
69                    } else if ($(tempAnchor + " a.anchor", thisPages).length) {
70                        $("html, body").animate({ scrollTop: parseInt($(tempAnchor + " a.anchor", thisPages).offset().top) - headerHeight + "px" }, 1000, "swing", function () {});
71                    } else if ($(tempAnchor, thisPages).length) {
72                        $("html, body").animate({ scrollTop: parseInt($(tempAnchor, thisPages).offset().top) - headerHeight + "px" }, 1000, "swing", function () {});
73                    } else if ($('a[name="' + tempAnchorToken + '"]', thisContent).length) {
74                        $("html, body").animate({ scrollTop: parseInt($('a[name="' + tempAnchorToken + '"]:last-child', thisContent).offset().top) - headerHeight + "px" }, 1000, "swing", function () {});
75                    }
76                });
77            if (templateSettings.allowResizeWebsiteFunction != false) {
78                var thisLastPage = $(".page_wrapper", thisWebsite).last();
79                window.resizeWebsiteFunction = function () {
80                    var pageHeight = thisLastPage.outerHeight();
81                    var windowHeight = $(window).height();
82                    var websiteHeight = thisWebsite.outerHeight();
83                    var heightDiff = 0;
84                    var minHeight = pageHeight;
85                    if (windowHeight > websiteHeight) {
86                        heightDiff = windowHeight - websiteHeight;
87                        minHeight = pageHeight + heightDiff;
88                        thisLastPage.css("min-height", minHeight + "px");
89                    }
90                };
91                $(window).resize(function () {
92                    resizeWebsiteFunction();
93                });
94                onLoadFunctions.push(function () {
95                    resizeWebsiteFunction();
96                });
97            }
98            var thisTourBlock = $(".tour_block", thisPages);
99            if (thisTourBlock.length && thisTourBlock.hasClass("tour_block_shift")) {
100                var thisTourHeader = thisTourBlock.prev("h2");
101                var thisTourParent = thisTourBlock.parents(".page");
102                var thisTourBanner = thisTourParent.find(".page_banner");
103                var thisTourWrapper = thisTourBanner.find(".banner_wrapper");
104                var thisTourOverlay = thisTourBanner.find(".banner_overlay");
105                var thisTourBlockHeight = thisTourBlock.outerHeight();
106                if (thisTourBanner.length && thisTourBanner.is(":visible")) {
107                    thisTourBanner.addClass("page_banner_tour").css({ height: thisTourBlockHeight + "px" });
108                    thisTourOverlay.remove();
109                    thisTourWrapper.css({ backgroundImage: "none", top: 0, bottom: 0, left: 0, right: 0 }).empty();
110                    thisTourBlock.css({ width: "100%", height: "100%" });
111                    thisTourBlock.appendTo(thisTourWrapper);
112                    thisTourHeader.remove();
113                }
114            }
115            
116            // Chức năng cuộn: thêm class "scrolled" vào body khi cuộn xuống
117            window.calculateScrolledFlag = function () {
118                var webBody = $("body");
119                var currentScroll = document.body.scrollTop || document.documentElement.scrollTop || window.pageYOffset || 0;
120                var currentScrollOffset = typeof templateSettings.bodyScrolledOffset == "function" 
121                    ? templateSettings.bodyScrolledOffset() 
122                    : (templateSettings.bodyScrolledOffset || 1);
123                if (currentScroll >= currentScrollOffset) {
124                    webBody.addClass("scrolled");
125                } else {
126                    webBody.removeClass("scrolled");
127                }
128            };
129            $(window).scroll(function () {
130                calculateScrolledFlag();
131            });
132            calculateScrolledFlag();
133        }
134        
135    });
136})(jQuery);

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.