PageSourceSearch

https://naha.org/assets/js/naha.js

js naha.org collected 2026-10-02 02:41:27 UTC 3,836 bytes, 147 lines download raw bytes

1$('.wsmenu .level-1 > ul').addClass('wsmenu-submenu');
2$('.wsmenu .level-2 > ul').addClass('wsmenu-submenu-sub');
3$('.wsmenu li.level-1:nth-last-child(2)').after('<li class="level-1"><a href="/about/boards-committees/naha-directors/"><span>Directors</span></a></li><li class="level-1"><a href="/naha-blog/"><span>Blog</span></a></li>');
4// $('.has-children').prepend('<span class="wsmenu-click"><i class="wsmenu-arrow fa fa-angle-down"></i></span>');
5
6$(document).ready(function(){
7
8	// scroll to top link
9	$('a#top').click(function(){
10	    $("html, body").animate({ scrollTop: 0 }, 600);
11	    return false;
12	});
13	
14	// scroll to anchors
15	$('a.cats').click(function(){
16	    $('html, body').animate({
17	        scrollTop: $( $.attr(this, 'href') ).offset().top
18	    }, 600);
19	    return false;
20	});
21	
22	// scroll to comments
23	$('a.comments').click(function(){
24	    $('html, body').animate({
25	        scrollTop: $( $.attr(this, 'href') ).offset().top
26	    }, 600);
27	    return false;
28	});
29	
30	// newsletter validation
31    $('#newsletter-form').validate();
32    
33    // signup form validation
34    $('.signup').validate();
35    
36    // create listing form validation
37    $('.listing').validate();
38    $('.listing2').validate();
39    
40    // checkout form validate
41    //$('#checkout-review').validate();
42    
43    // signup form generate screen_name
44    var screenname = $('screen_name').val();
45    var fname = $('first_name').val();
46    var lname = $('last_name').val();
47    $('screen_name').val(fname+' '+lname);
48	
49	//toggle for bilaws
50	$('.toggle-view li').click(function () {
51		var text = $(this).children('div.view');
52		if (text.is(':hidden')) {
53			text.slideDown('200');
54			$(this).children('span').html('-');		
55		} else {
56			text.slideUp('200');
57			$(this).children('span').html('+');		
58		}
59	});
60	    
61	// director bios fancybox
62	$(".bioLink").fancybox({
63		maxWidth	: 800,
64		maxHeight	: 800,
65		fitToView	: false,
66		width		: '70%',
67		height		: '70%',
68		autoSize	: true,
69		closeClick	: false,
70		openEffect	: 'fade',
71		closeEffect	: 'fade'
72	});
73	
74	// image fancybox for any image
75	$(".enlarge").fancybox({
76		helpers : {
77	        title: {
78	            type: 'inside'
79	        }
80	    },
81	    afterLoad: function(){
82			this.title = $(this.element).find('img').attr('alt');
83		}
84	});
85	
86	// add selects to billing_region  & shipping_region
87    $('select#billing_region').addClass('selects');
88    $('select#shipping_region').addClass('selects');
89    $('select#billing_country').addClass('selects');
90    $('select#shipping_country').addClass('selects');
91	
92	// blog arcives select stuff
93	$("#months").select2();
94	
95	// selects on account section
96	$(".selects").select2();
97	
98	// selects on search - country
99	$(".select_country").select2({
100		placeholder: "Choose",
101    	allowClear: true
102	});
103	
104	// selects on search - states
105	$(".select_states").select2({
106		placeholder: "Select",
107    	allowClear: true
108	});
109	
110	// selects on search - modalities
111	$(".select_modes").select2({
112		placeholder: "Choose",
113    	allowClear: true
114	});
115	
116	// toggle checkout shipping
117	$('#shipping_same_as_billing').change(function() {
118        if (this.checked) {
119            $('#shipping_details_drawer').slideUp();
120        } else {
121            $('#shipping_details_drawer').slideDown();
122        }
123    });
124    // hide on page load if already checked
125    if ($('#shipping_same_as_billing').is(':checked')) {
126        $('#shipping_details_drawer').hide();
127    }
128    
129	
130	// country controls on account section
131	//$('.us-canada').hide();
132	//$('.international').hide();
133	
134	//$('#country').bind('change', function (e) { 
135	//    if( $('#country').val() == ("United States" || "Canada")) {
136	//      $('.us-canada').fadeIn();
137	//	  $('.international').hide();
138	//    }
139	//    else {
140	//      $('.international').fadeIn();
141	//      $('.us-canada').hide();
142	//    }       
143	//});
144	
145	    
146});
147

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.