PageSourceSearch

https://worklab.jp/wp-content/themes/worklab/common/js/common.js

js worklab.jp collected 2026-10-08 12:30:04 UTC 1,517 bytes, 48 lines download raw bytes

1$(function(){
2	$('a[href*=\\#]:not([href=\\#])').click(function() {
3	if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') && location.hostname == this.hostname) {
4			var $target = $(this.hash);
5			$target = $target.length && $target || $('[name=' + this.hash.slice(1) +']');
6			if ($target.length) {
7				if($(this).parents('.menuBox').length){
8					setTimeout(function(){
9						var targetOffset = $target.offset().top;
10						$('html,body').animate({scrollTop: targetOffset}, 1000);
11					},100);
12				}else{
13					var targetOffset = $target.offset().top;
14					$('html,body').animate({scrollTop: targetOffset}, 1000);
15				}
16				return false;
17			}
18		}
19	});
20	
21	var state = false;
22	var scrollpos;
23	// $('.menu,.menuBg,.spNaviLink').on('click', function(){
24	$('.menu,.menuBg').on('click', function(){
25		if(state == false) {
26			$('body').addClass('fixed');
27			$('.menuBox').stop().toggleClass('on');
28			$('.menuBg').stop().fadeIn();
29			$('.menu').addClass('on');
30			state = true;
31		} else {
32			state = false;
33			$('body').removeClass('fixed');
34			$('.menuBox').stop().toggleClass('on');
35			$('.menuBg').stop().fadeOut();
36			$('.menu').removeClass('on');
37		}
38		return false;
39	});
40});
41
42$(window).on('load',function(){
43	var localLink = window.location+'';
44	if(localLink.indexOf("#") != -1 && localLink.slice(-1) != '#'){	
45		localLink = localLink.slice(localLink.indexOf("#")+1);
46		$('html,body').animate({scrollTop: $('#'+localLink).offset().top}, 500);
47	}
48});

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.