PageSourceSearch

https://dubaiairports.ae/resourcepackages/da/assets/js/notification-banner.js

js dubaiairports.ae collected 2026-10-02 02:42:42 UTC 1,625 bytes, 37 lines download raw bytes

1document.addEventListener("DOMContentLoaded", () => {
2    const isActiveClassname = "is-active";
3    const notificationBanners = document.querySelectorAll('.notification-banner');
4
5    notificationBanners.forEach((notificationBanner) => {
6        const itemUrl = notificationBanner.dataset.itemUrl;
7        const notificationKey = `notificationDismissed-${itemUrl}`;
8        const notificationBody = notificationBanner.querySelector(`#notification-body-${itemUrl}`);
9        const notificationCloseButton = notificationBanner.querySelector(`[data-notification-dismiss="${itemUrl}"]`);
10        const notificationFoldButton = notificationBanner.querySelector(`[data-notification-fold="${itemUrl}"]`);
11
12        if (localStorage.getItem(notificationKey) === null) {
13            notificationBanner.setAttribute("aria-hidden", false);
14        }
15
16        notificationCloseButton.addEventListener("click", () => {
17            notificationBanner.setAttribute("aria-hidden", true);
18            localStorage.setItem(notificationKey, "true");
19        });
20
21        notificationFoldButton.addEventListener("click", () => {
22            notificationBanner.classList.toggle(isActiveClassname);
23
24            notificationBody.setAttribute("aria-hidden",
25                notificationBody.getAttribute("aria-hidden") === "true"
26                    ? "false"
27                    : "true"
28            );
29
30            notificationFoldButton.setAttribute("aria-expanded",
31                notificationFoldButton.getAttribute("aria-expanded") === "true"
32                    ? "false"
33                    : "true"
34            );
35        });
36    });
37});

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.