PageSourceSearch

https://sgr.fi/fi/application/views/scripts/javascripts/globals.js?v=3.1

js sgr.fi collected 2026-10-02 04:04:41 UTC 2,216 bytes, 74 lines download raw bytes

1if (!Omeka) {
2    var Omeka = {};
3}
4
5(function($) {
6    // Skip to content
7    Omeka.skipNav = function () {
8      $("#skipnav").click(function(e) {
9          e.preventDefault();
10          $("#content").attr("tabindex", -1).focus();
11      });
12    
13      $("#content").on("blur focusout", function () {
14          $(this).removeAttr("tabindex");
15      });
16    };
17    
18    // Show advanced options for site-wide search.
19    Omeka.showAdvancedForm = function () {
20        var advanced_form = $('#advanced-form');
21
22        $('.show-advanced').click(function(e) {
23            e.preventDefault();
24            advanced_form.toggleClass('open').toggleClass('closed');
25        });
26    };
27
28    Omeka.megaMenu = function (menuSelector, customMenuOptions) {
29        if (typeof menuSelector === 'undefined') {
30            menuSelector = '#primary-nav';
31        }
32
33        var menuOptions = {
34            /* prefix for generated unique id attributes, which are required
35             to indicate aria-owns, aria-controls and aria-labelledby */
36            uuidPrefix: "accessible-megamenu",
37
38            /* css class used to define the megamenu styling */
39            menuClass: "nav-menu",
40
41            /* css class for a top-level navigation item in the megamenu */
42            topNavItemClass: "nav-item",
43
44            /* css class for a megamenu panel */
45            panelClass: "sub-nav",
46
47            /* css class for a group of items within a megamenu panel */
48            panelGroupClass: "sub-nav-group",
49
50            /* css class for the hover state */
51            hoverClass: "hover",
52
53            /* css class for the focus state */
54            focusClass: "focus",
55
56            /* css class for the open state */
57            openClass: "open"
58        };
59
60        $.extend(menuOptions, customMenuOptions);
61
62        $(menuSelector).accessibleMegaMenu(menuOptions);
63    };
64
65    $(document).ready(function () {
66        $('.omeka-media').on('error', function () {
67            if (this.networkState === HTMLMediaElement.NETWORK_NO_SOURCE ||
68                this.networkState === HTMLMediaElement.NETWORK_EMPTY
69            ) {
70                $(this).replaceWith(this.innerHTML);
71            }
72        });
73    });
74})(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.