PageSourceSearch

http://seishin-n-clinic.com/cmswp/wp-content/themes/seishin-n-clinic/js/base.js

js seishin-n-clinic.com collected 2026-10-05 11:15:59 UTC 6,457 bytes, 179 lines download raw bytes

1/*--------------------------------------------------------------------------
2    form mail 半角
3 ---------------------------------------------------------------------------*/
4 jQuery(function($){
5    $(".mailadd").change(function(){
6        var str = $(this).val();
7        str = str.replace( /[A-Za-z0-9-!”#$%&’()=<>,.?_[]{}@^~¥]/g, function(s) {
8            return String.fromCharCode(s.charCodeAt(0) - 65248);
9        });
10        $(this).val(str);
11    }).change();
12});
13/*--------------------------------------------------------------------------
14    panel-btn
15 ---------------------------------------------------------------------------*/
16
17 jQuery(function($){
18  $(document).ready(function(){
19    var w = $(window).width();
20    var x = 1223;/* 1214 991 */
21    if (w <= x){
22      $("#gnav").hide();
23    }
24  });
25
26  $("#panel-btn").click(function(){
27    $("#gnav").slideToggle(400);
28    $("#panel-btn-icon").toggleClass("close");
29    return false;
30  });
31
32  $(window).resize(function(){
33    var w = $(window).width();
34    var x = 1223;/* 1214 991 */
35    $("#panel-btn-icon").removeClass("close");
36    if(w > x){
37      $("#gnav").show();
38    } else {
39      $("#gnav").hide();
40    }
41  });
42});
43
44/*--------------------------------------------------------------------------
45    Page-top
46---------------------------------------------------------------------------*/
47jQuery(function($){
48// $(function(){
49  var $btn = $('#page-top a');
50  var isHidden = true;
51  $btn.hide();
52  $(window).scroll(function () {
53    if( $(this).scrollTop() > 300 ) {
54      if( isHidden ) {
55        $btn.stop(true,true).fadeIn();
56        isHidden = false;
57      }
58    } else {
59      if( !isHidden ) {
60        $btn.stop(true,true).fadeOut();
61        isHidden = true;
62      }
63    }
64  });
65  $btn.click(function(){
66    $('html, body').animate({
67        'scrollTop': 0
68      }, 900, 'easeInOutExpo');
69    return false;
70  });
71});
72/*--------------------------------------------------------------------------
73    Page-Scroll
74---------------------------------------------------------------------------*/
75jQuery(function($){
76$('a[href^="#"]').click(function(){
77// $(function(){
78     //$('a[href^=#]').click(function(){
79        var speed = 500;
80        var href= $(this).attr("href");
81        var target = $(href == "#" || href == "" ? 'html' : href);
82        var position = target.offset().top;
83        $("html, body").animate({scrollTop:position}, speed, "easeInOutExpo");
84        return false;
85    });
86});
87
88
89/*--------------------------------------------------------------------------
90     SNS-Share
91  ---------------------------------------------------------------------------*/
92
93 //* DOMの読み込み完了後に処理 */
94 if(window.addEventListener) {
95  //window.addEventListener( "load" , shareButtonReadSyncer, false );
96 }else{
97 // window.attachEvent( "onload", shareButtonReadSyncer );
98 }
99
100 /* シェアボタンを読み込む関数 */
101 function shareButtonReadSyncer(){
102/*
103 // 遅延ロードする場合は次の行と、終わりの方にある行のコメント(//)を外す
104 // setTimeout(function(){
105
106 // Twitter (オリジナルボタンを使用するので、コメントアウトして無効化)
107 // window.twttr=(function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],t=window.twttr||{};if(d.getElementById(id))return;js=d.createElement(s);js.id=id;js.src="https://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);t._e=[];t.ready=function(f){t._e.push(f);};return t;}(document,"script","twitter-wjs"));
108
109 // Facebook
110 (function(d, s, id) {
111  var js, fjs = d.getElementsByTagName(s)[0];
112  if (d.getElementById(id)) return;
113  js = d.createElement(s); js.id = id;
114  js.src = "//connect.facebook.net/ja_JP/sdk.js#xfbml=1&version=v2.0";
115  fjs.parentNode.insertBefore(js, fjs);
116 }(document, 'script', 'facebook-jssdk'));
117
118 // Google+
119 var scriptTag = document.createElement("script");
120 scriptTag.type = "text/javascript"
121 scriptTag.src = "https://apis.google.com/js/platform.js";
122 scriptTag.async = true;
123 document.getElementsByTagName("head")[0].appendChild(scriptTag);
124
125 // はてなブックマーク
126 var scriptTag = document.createElement("script");
127 scriptTag.type = "text/javascript"
128 scriptTag.src = "https://b.st-hatena.com/js/bookmark_button.js";
129 scriptTag.async = true;
130 document.getElementsByTagName("head")[0].appendChild(scriptTag);
131
132 // pocket
133 (!function(d,i){if(!d.getElementById(i)){var j=d.createElement("script");j.id=i;j.src="https://widgets.getpocket.com/v1/j/btn.js?v=1";var w=d.getElementById(i);d.body.appendChild(j);}}(document,"pocket-btn-js"));
134
135 //},5000); //ページを開いて5秒後(5,000ミリ秒後)にシェアボタンを読み込む
136*/
137 }
138
139
140
141 /*--------------------------------------------------------------------------
142   Animation
143  ---------------------------------------------------------------------------*/
144 jQuery(function($){
145 $(document).ready(function() {
146 $(".show00").waypoint(function() {$(".show00 h1").addClass("animated fadeInDown");},{offset: "50%"});
147  $(".show00").waypoint(function() {$(".show00 h2").addClass("animated fadeInDown");},{offset: "50%"});
148 $(".show00").waypoint(function() {$(".show00 p").addClass("animated fadeInUp");},{offset: "70%"});
149 $(".show01").waypoint(function() {$(".show01").addClass("animated fadeIn");},{offset: "70%"});
150 $(".show02").waypoint(function() {$(".show02").addClass("animated fadeIn");},{offset: "70%"});
151 $(".show03").waypoint(function() {$(".show03").addClass("animated fadeIn");},{offset: "70%"});
152$(".show04").waypoint(function() {$(".show04").addClass("animated fadeIn");},{offset: "70%"});
153 });
154 });
155 /*--------------------------------------------------------------------------
156   js-matchHeight
157  ---------------------------------------------------------------------------*/
158
159 
160 /*
161  * ===============================================================================
162  *
163  *Congtact-form
164  *
165  * ===============================================================================
166  */
167 jQuery(function($){
168         var targetInput = ':text, :password, textarea';
169         $(targetInput).addClass('jInput');
170         $(targetInput).focus(function(){
171                 $(this).addClass('jFocus');
172         });
173         $(targetInput).blur(function(){
174                 if ($(this).find('.jFocus')) {
175                         $(this).removeClass('jFocus');
176                 }
177         });
178
179 });

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.