PageSourceSearch

https://www.alexanderpalace.org/lostsplendor/assets/js/plugins.js

js alexanderpalace.org collected 2026-10-02 06:23:31 UTC 6,540 bytes, 81 lines download raw bytes

1(function() {
2    var method;
3    var noop = function () {};
4    var methods = [
5        'assert', 'clear', 'count', 'debug', 'dir', 'dirxml', 'error',
6        'exception', 'group', 'groupCollapsed', 'groupEnd', 'info', 'log',
7        'markTimeline', 'profile', 'profileEnd', 'table', 'time', 'timeEnd',
8        'timeStamp', 'trace', 'warn'
9    ];
10    var length = methods.length;
11    var console = (window.console = window.console || {});
12
13    while (length--) {
14        method = methods[length];
15
16        // Only stub undefined methods.
17        if (!console[method]) {
18            console[method] = noop;
19        }
20    }
21}());
22
23/**
24 * Common tools
25 */
26$.extend({
27    cncPrepareInputs: function() {
28        $('input[type="radio"], input[type="checkbox"]').on('click', function() {
29            if ($(this).prop("checked") === true) {
30                $('input[name="' + $(this).attr('name') + '"]:radio').parent().removeClass('highlight');
31
32                $(this).parent().addClass('highlight');
33            } else {
34                $(this).parent().removeClass('highlight');
35            }
36        });
37
38        if ($('input:checked').length > 0) {
39            $('input:checked').parent().addClass('highlight');
40        }
41
42        $('.auto-toggle').button('toggle');
43        $('.auto-hide').addClass('hide');
44    },
45    cncFixColumns: function(row, column, screenWidth) {
46        if ((window.innerWidth >= screenWidth) && ($(row).length > 0)) {
47            $(row).each(function() {
48                var max = 0,
49                    columns = $(this).find(column);
50
51                if (columns.length > 1) {
52                    columns.each(function() {
53                        var myHeight = $(this).outerHeight();
54                        if (myHeight > max) {
55                            max = myHeight;
56                        }
57                    });
58
59                    columns.each(function() {
60                        $(this).css('min-height', max + 'px');
61                    });
62                }
63            });
64        }
65    }
66});
67
68/*! Lazy Load 1.9.3 - MIT license - Copyright 2010-2013 Mika Tuupola */
69!function(a,b,c,d){var e=a(b);a.fn.lazyload=function(f){function g(){var b=0;i.each(function(){var c=a(this);if(!j.skip_invisible||c.is(":visible"))if(a.abovethetop(this,j)||a.leftofbegin(this,j));else if(a.belowthefold(this,j)||a.rightoffold(this,j)){if(++b>j.failure_limit)return!1}else c.trigger("appear"),b=0})}var h,i=this,j={threshold:0,failure_limit:0,event:"scroll",effect:"show",container:b,data_attribute:"original",skip_invisible:!0,appear:null,load:null,placeholder:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB/AAffA0nNPuCLAAAAAElFTkSuQmCC"};return f&&(d!==f.failurelimit&&(f.failure_limit=f.failurelimit,delete f.failurelimit),d!==f.effectspeed&&(f.effect_speed=f.effectspeed,delete f.effectspeed),a.extend(j,f)),h=j.container===d||j.container===b?e:a(j.container),0===j.event.indexOf("scroll")&&h.bind(j.event,function(){return g()}),this.each(function(){var b=this,c=a(b);b.loaded=!1,(c.attr("src")===d||c.attr("src")===!1)&&c.is("img")&&c.attr("src",j.placeholder),c.one("appear",function(){if(!this.loaded){if(j.appear){var d=i.length;j.appear.call(b,d,j)}a("<img />").bind("load",function(){var d=c.attr("data-"+j.data_attribute);c.hide(),c.is("img")?c.attr("src",d):c.css("background-image","url('"+d+"')"),c[j.effect](j.effect_speed),b.loaded=!0;var e=a.grep(i,function(a){return!a.loaded});if(i=a(e),j.load){var f=i.length;j.load.call(b,f,j)}}).attr("src",c.attr("data-"+j.data_attribute))}}),0!==j.event.indexOf("scroll")&&c.bind(j.event,function(){b.loaded||c.trigger("appear")})}),e.bind("resize",function(){g()}),/(?:iphone|ipod|ipad).*os 5/gi.test(navigator.appVersion)&&e.bind("pageshow",function(b){b.originalEvent&&b.originalEvent.persisted&&i.each(function(){a(this).trigger("appear")})}),a(c).ready(function(){g()}),this},a.belowthefold=function(c,f){var g;return g=f.container===d||f.container===b?(b.innerHeight?b.innerHeight:e.height())+e.scrollTop():a(f.container).offset().top+a(f.container).height(),g<=a(c).offset().top-f.threshold},a.rightoffold=function(c,f){var g;return g=f.container===d||f.container===b?e.width()+e.scrollLeft():a(f.container).offset().left+a(f.container).width(),g<=a(c).offset().left-f.threshold},a.abovethetop=function(c,f){var g;return g=f.container===d||f.container===b?e.scrollTop():a(f.container).offset().top,g>=a(c).offset().top+f.threshold+a(c).height()},a.leftofbegin=function(c,f){var g;return g=f.container===d||f.container===b?e.scrollLeft():a(f.container).offset().left,g>=a(c).offset().left+f.threshold+a(c).width()},a.inviewport=function(b,c){return!(a.rightoffold(b,c)||a.leftofbegin(b,c)||a.belowthefold(b,c)||a.abovethetop(b,c))},a.extend(a.expr[":"],{"below-the-fold":function(b){return a.belowthefold(b,{threshold:0})},"above-the-top":function(b){return!a.belowthefold(b,{threshold:0})},"right-of-screen":function(b){return a.rightoffold(b,{threshold:0})},"left-of-screen":function(b){return!a.rightoffold(b,{threshold:0})}
69,"in-viewport":function(b){return a.inviewport(b,{threshold:0})},"above-the-fold":function(b){return!a.belowthefold(b,{threshold:0})},"right-of-fold":function(b){return a.rightoffold(b,{threshold:0})},"left-of-fold":function(b){return!a.rightoffold(b,{threshold:0})}})}(jQuery,window,document);
70
71/*
72* rwdImageMaps jQuery plugin v1.5
73*
74* Allows image maps to be used in a responsive design by recalculating the area coordinates to match the actual image size on load and window.resize
75*
76* Copyright (c) 2013 Matt Stow
77* https://github.com/stowball/jQuery-rwdImageMaps
78* http://mattstow.com
79* Licensed under the MIT license
80*/
81;(function(a){a.fn.rwdImageMaps=function(){var c=this;var b=function(){c.each(function(){if(typeof(a(this).attr("usemap"))=="undefined"){return}var e=this,d=a(e);a("<img />").load(function(){var g="width",m="height",n=d.attr(g),j=d.attr(m);if(!n||!j){var o=new Image();o.src=d.attr("src");if(!n){n=o.width}if(!j){j=o.height}}var f=d.width()/100,k=d.height()/100,i=d.attr("usemap").replace("#",""),l="coords";a('map[name="'+i+'"]').find("area").each(function(){var r=a(this);if(!r.data(l)){r.data(l,r.attr(l))}var q=r.data(l).split(","),p=new Array(q.length);for(var h=0;h<p.length;++h){if(h%2===0){p[h]=parseInt(((q[h]/n)*100)*f)}else{p[h]=parseInt(((q[h]/j)*100)*k)}}r.attr(l,p.toString())})}).attr("src",d.attr("src"))})};a(window).resize(b).trigger("resize");return this}})(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.