PageSourceSearch

https://www.officialmiguel.com/js/scripts.js?v=a0a3a0

js officialmiguel.com collected 2026-09-24 21:17:51 UTC 3,198 bytes, 101 lines download raw bytes

1// gsap
2gsap.from("#main-header", {
3    duration: 0.4,
4    y: "-20%",
5    opacity: 0,
6    delay: 1,
7});
8
9gsap.from("footer", {
10    duration: 0.4,
11    y: "20%",
12    opacity: 0,
13    delay: 1,
14});
15
16gsap.from("main", {
17    duration: 0.6,
18    opacity: 0,
19    delay: 1.5,
20});
21
22// modals
23(function ($, root, undefined) {
24    // Z-index bring to front for windows
25    let windowZ = 100;
26    $(document).on("mousedown", ".window header", function () {
27        windowZ++;
28        $(this).closest(".window").css("z-index", windowZ);
29    });
30    $(function () {
31        "use strict";
32
33        // Toggle menu video
34        $(document).on("click", ".video", function () {
35            $(".window").addClass("hidden");
36            $(this).parent().toggleClass("hidden");
37            $("#videosWindow").removeClass("hidden");
38            windowZ++;
39            $("#videosWindow").css("z-index", windowZ);
40        });
41
42        $(document).on("click", ".btn-close-video", function () {
43            $("#videosWindow").addClass("hidden");
44            $("#iframeWindow").addClass("hidden");
45        });
46
47        // Toggle menu music
48        $(document).on("click", ".music", function () {
49            $(".window").addClass("hidden");
50            $(this).parent().toggleClass("hidden");
51            $("#musicWindow").removeClass("hidden");
52            windowZ++;
53            $("#musicWindow").css("z-index", windowZ);
54        });
55
56        $(document).on("click", ".btn-close-music", function () {
57            $("#musicWindow").addClass("hidden");
58        });
59
60        // Toggle tour music
61        $(document).on("click", ".tour", function () {
62            $(".window").addClass("hidden");
63            $(this).parent().toggleClass("hidden");
64            $("#tourWindow").removeClass("hidden");
65            windowZ++;
66            $("#tourWindow").css("z-index", windowZ);
67        });
68
69        $(document).on("click", ".btn-close-tour", function () {
70            $("#tourWindow").addClass("hidden");
71        });
72
73        // Toggle ytiframe iframe
74        $(document).on("click", ".video-frame", function (e) {
75            e.preventDefault(); // Prevent anchor navigation
76            // Get album title from sibling span
77            var albumTitle = $(this).text();
78            if (!albumTitle) {
79                albumTitle = $(this).parent().find(".album").text();
80            }
81            $("#iframeWindow .title h2").text(albumTitle);
82            // Open modal
83            $(this).parent().toggleClass("hidden");
84            $("#iframeWindow").removeClass("hidden");
85            windowZ++;
86            $("#iframeWindow").css("z-index", windowZ);
87            // Change iframe src
88            var url = $(this).attr("href");
89            // If the link is a YouTube URL, convert to embed format
90            if (url && url.includes("youtube.com/watch?v=")) {
91                var videoId = url.split("v=")[1].split("&")[0];
92                url = "https://www.youtube.com/embed/" + videoId;
93            }
94            $("#iframeWindow iframe").attr("src", url);
95        });
96
97        $(document).on("click", ".btn-close-tour", function () {
98            $("#iframeWindow").addClass("hidden");
99        });
100    });
101})(jQuery, this);

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.