PageSourceSearch

http://verticalurbanism.org/wp-content/themes/mds-multiple-theme/assets/js/navigation.js

js verticalurbanism.org collected 2026-09-25 03:55:19 UTC 865 bytes, 24 lines download raw bytes

1document.addEventListener('DOMContentLoaded', () => {
2    const mainNavItems = document.querySelectorAll('.navigation__main__item a');
3    const currentPath = window.location.pathname; // e.g. "/about/team"
4
5    const pgStructure = {
6        'news-events': ['news-events'],
7        'resources': ['resources'],
8        'get-involved': ['get-involved'],
9        'about': ['about'],
10    };
11
12    // Loop through your structure
13    for (const [section, slugs] of Object.entries(pgStructure)) {
14        // If the path contains one of the slugs
15        if (slugs.some(slug => currentPath.includes(`/${slug}`))) {
16            mainNavItems.forEach(item => {
17                const href = item.getAttribute('href');
18                if (href && href.includes(section)) {
19                    item.classList.add('activepg');
20                }
21            });
22        }
23    }
24});

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.