PageSourceSearch

https://www.now-planning.co.jp/design/themes/pc/js/common.js

js now-planning.co.jp collected 2026-10-05 09:53:48 UTC 1,449 bytes, 55 lines download raw bytes

1$(function(){
2
3	
4
5	/* _off の画像を _on にする
6	-------------------------------------------- */
7	images = $('img');
8	for( var i = 0; i < images.length; i++ ){
9		if( images[i].getAttribute('src').match("_off.") ){
10			images[i].onmouseover = function() {
11				this.setAttribute("src", this.getAttribute("src").replace("_off.", "_on."));
12			};
13			images[i].onmouseout = function() {
14				this.setAttribute("src", this.getAttribute("src").replace("_on.", "_off."));
15			};
16		};
17	};
18
19
20	/* 開閉式コンテンツの作成
21	-------------------------------------------- */
22	$('.toggle').css('cursor','pointer');
23	$('.toggle').next().css('display','none');
24	$('.toggle:target').next().css('display','block');
25	$('.toggle').click(function(e){
26		e.preventDefault();
27		$(this).next().slideToggle();
28	});
29
30
31	/* ページ内リンクをスクロールにする
32	-------------------------------------------- */
33	$('.anchor').click(function(){
34		href = $(this).attr('href');
35		if(href=='#')
36			$('html, body').animate({scrollTop: 0},600);
37		else
38			$('html, body').animate({scrollTop: $(href).offset().top},600);
39		return false;
40	});
41
42
43	/* 画面右下のボタンのオンオフ制御
44	-------------------------------------------- */
45	$(window).scroll(function(){
46		if($(this).scrollTop() > 220){
47			$('.top_header .header_top').css('background-color','#fff');
48		}
49		else{
50			$('.top_header .header_top').css('background-color','transparent');
51		}
52	});
53
54
55});

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.