PageSourceSearch

https://www.mkm-marui.co.jp/js/main.js

js mkm-marui.co.jp collected 2026-10-05 09:48:49 UTC 2,879 bytes, 133 lines download raw bytes

1
2
3$(function(){
4   // #で始まるアンカーをクリックした場合に処理
5   $('a[href^=#]').click(function() {
6      // スクロールの速度
7      var speed = 400; // ミリ秒
8      // アンカーの値取得
9      var href= $(this).attr("href");
10      // 移動先を取得
11      var target = $(href == "#" || href == "" ? 'html' : href);
12      // 移動先を数値で取得
13      var position = target.offset().top;
14      // スムーススクロール
15      $('body,html').animate({scrollTop:position}, speed, 'swing');
16      return false;
17   });
18});
19//通常TOTOPボタン
20 /*--TOTOPボタン--*/
21$(document).ready(function(){
22
23
24 
25    // トップへスムーススクロール
26    $('.totop a').click(function () {
27        $('body,html').animate({
28        scrollTop: 0
29        }, 500);
30        // ページのトップへ 500 のスピードでスクロールする
31        return false;
32     });
33 
34});
35
36
37/**
38 * auto height
39 */
40
41(function($) {
42
43	$.fn.extend({
44		autoHeight: function(options) {
45			var config = {
46					minHeight: "auto",
47					footerHeight: 0,
48					headerHeight: 0
49				},
50				self = $(this),
51				selfHeight = self.height();
52			
53			$.extend(config, options);
54			
55			var min = parseInt(config.minHeight, 10);
56			config.minHeight =  min > selfHeight ? min : selfHeight;
57
58			$(window).resize(function() {
59				var windowHeight = $(window).height(),
60					h = windowHeight - (config.headerHeight + config.footerHeight +193);
61
62				if (h > config.minHeight) {
63					// 新たな高さを設定する。
64					self.height(h);
65					$("body").css("overflow", "hidden");
66				} else {
67					$("body").css("overflow", "auto");
68				}
69
70			}).resize();
71		
72			return this;
73		}
74
75	});
76
77})(jQuery);
78
79//サイドナビのカレントページ表現 .main_box #side_local .side_list li a
80//
81$(function(){
82	
83    $('.side_list li a').each(function(){
84        var $href = $(this).attr('href');
85        //alert($href );
86        if(location.href.match($href)) {
87            $(this).addClass('current');
88            
89        } else {
90            $(this).removeClass('current');
91        }
92    });
93});
94
95
96
97/*$(function(){
98  $("#toggle").click(function(){
99    $("#gnav").slideToggle();
100    return false;
101  });
102  $(window).on('load resize', function(){
103    var win = $(window).width();
104    var p = 766;
105    if(win > p){
106      $("#gnav").show();
107    } else {
108      $("#gnav").hide();
109    }
110  });
111});*/
112
113$(function(){
114	$('#nav_toggle').click(function(){
115		$("#headline").toggleClass('open');
116		$("#gnav_wrap").slideToggle(500);
117	});
118	    $("#gnav_wrap .close").click(function(){
119        $("#gnav_wrap").slideToggle();
120        $("#headline").toggleClass('open');
121    });
122
123});
124
125 //グローバルナビスマホ時のアコーディオン
126
127  $(function(){
128		$(".accordionBtn").click(function() {
129			$(this).prev("ul").slideToggle();
130			$(this).toggleClass("active");
131			
132		});
133  });

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.