1// JavaScript Document 2 3 4//********************************************* 5// slider 6//********************************************* 7 8jQuery(function($){ 9 10let swipeOption = { 11 loop: true, 12 effect: 'slide', 13 autoplay: { 14 delay: 4000, 15 disableOnInteraction: false, 16 }, 17 speed: 2000, 18 pagination: { 19 el: '.swiper-pagination', 20 clickable: true, 21 } 22} 23new Swiper('.TopSwiper', swipeOption); 24 25}); 26 27 28//********************************************* 29// setViewport 30//********************************************* 31 32//$(function(){ 33// // setViewport 34// spView = 'width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=0'; 35// tbView = 'width=1200px,maximum-scale=2.0,user-scalable=1'; 36// 37// if(navigator.userAgent.indexOf('iPhone') > 0 || navigator.userAgent.indexOf('iPod') > 0 || (navigator.userAgent.indexOf('Android') > 0 && navigator.userAgent.indexOf('Mobile') > 0)){ 38// $('head').prepend('<meta name="viewport" content="' + spView + '" id="viewport">'); 39// } else if(navigator.userAgent.indexOf('iPad') > 0 || (navigator.userAgent.indexOf('Android') > 0 && navigator.userAgent.indexOf('Mobile') == -1) || navigator.userAgent.indexOf('A1_07') > 0 || navigator.userAgent.indexOf('SC-01C') > 0){ 40// $('head').prepend('<meta name="viewport" content="' + tbView + '" id="viewport">'); 41// } 42//}); 43 44 45 46 47 48//********************************************* 49// gotop 50//********************************************* 51 52$(function() { 53 var pageTop = $('.totop'); 54 pageTop.hide(); 55 $(window).scroll(function () { 56 if ($(this).scrollTop() > 500) { 57 pageTop.fadeIn(); 58 } else { 59 pageTop.fadeOut(); 60 } 61 }); 62 pageTop.click(function () { 63 $('body, html').animate({scrollTop:0}, 500, 'swing'); 64 return false; 65 }); 66}); 67 68 69 70//********************************************* 71// scroll 72//********************************************* 73 74$(function(){ 75 // #ã§å§â¹Ã£Â¾ãââ¹Ã£ÆÂªÃ£ÆÂ³Ã£â¯ãââãâ¯ãÆÂªÃ£ÆÆÃ£â¯ãÂâãÂŸå ´åÂË 76 $('a[href^="#"]').click(function() { 77 // ãâ¹ãâ¯ãÆÂãÆÂ¼Ã£ÆÂ«Ã£Â®éâ¬Å¸Ã¥ÂºÂ¦ 78 let speed = 400; 79 // ãâ¹ãâ¯ãÆÂãÆÂ¼Ã£ÆÂ«Ã£â¿ãâ¤ãÆâ 80 let type = 'swing'; 81 // href属æâ¬Â§Ã£Â®åÂâå¾â 82 let href= $(this).attr("href"); 83 // ç§»åâ¹â¢Ã¥â¦Ëã®åÂâå¾âï¼ËhrefãÂÅ#indexãªãââ°Ã£ÆËÃ£ÆÆÃ£Æâ$(html)ã«ãâ¬Âï¼Ⱐ84 let target = $(href == "#index" ? 'html' : href); 85 // ç§»åâ¹â¢Ã¥â¦Ëã®ãÆÂãâ¸ãâ·ãÆÂ§Ã£ÆÂ³Ã¥Ââå¾â 86 let position = target.offset().top; 87 // animateã§ãâÂ¹Ã£Æ Ã£ÆÂ¼Ã£â¹ãâ¹ãâ¯ãÆÂãÆÂ¼Ã£ÆÂ« 88 $('body,html').animate({scrollTop:position}, speed, type); 89 return false; 90 }); 91}); 92 93 94//********************************************* 95// menu 96//********************************************* 97 98$(window).on('scroll',function(){ 99 100 $(".box h3 span").each(function(){ 101 var position = $(this).offset().top; 102 var scroll = $(window).scrollTop(); 103 var windowHeight = $(window).height(); 104 if (scroll > position - windowHeight){ 105 $(this).addClass('isActive'); 106 } 107 }); 108 109 }); 110 111 112 113//********************************************* 114// menu 115//********************************************* 116 117$(function(){ 118 $('.menu-trigger').on('click',function(){ 119 $(this).toggleClass('active'); 120 $('.header-inner').fadeToggle(); 121 }); 122 123// $('.menu-trigger').on('click',function(){ 124// $(this).toggleClass('active'); 125// $('.header-inner').fadeOut(); 126// }); 127 128 $('.header-inner .main a').on('click',function(){ 129 $('.header-inner').fadeOut(); 130 }); 131}); 132 133 134 135//********************************************* 136// accordion 137//********************************************* 138 139 140$(function () { 141 $('.cont02 .block a').on('click', function () { 142// $(this).next().slideToggle(); 143 $(this).children('a .open').slideToggle(); 144 $(this).children('a .close').slideToggle(); 145 146 $(this).closest('li').find('.hideBox').slideToggle(); 147// $('.cont02 .block a .close').slideToggle(); 148// $('.cont02 .block a .open').slideToggle(); 149// $(this).next('.hideBox').slideToggle(); 150 }); 151}); 152 153 154 155 156//********************************************* 157// wow 158//********************************************* 159var wow = new WOW( 160 { 161 boxClass: 'wow', // animated element css class (default is wow) 162 animateClass: 'animated', // animation css class (default is animated) 163 offset: 0, // distance to the element when triggering the animation (default is 0) 164 mobile: false // trigger animations on mobile devices (true is default) 165 } 166); 167wow.init(); 168 169 170 171 172 173//********************************************* 174// scroll 175//********************************************* 176 177 178/* $(window).scroll(function () { 179 if($(window).scrollTop() > 100) { 180 $('header').addClass('fixed'); 181 } else { 182 $('header').removeClass('fixed'); 183 } 184}); */ 185 186 187 188 189 190//********************************************* 191// anker 192//********************************************* 193 194 195jQuery(function(){ 196 var windowWidth = $(window).width(); 197 var headerHight = 100; 198 jQuery('a[href^=#]').click(function() { 199 var speed = 1000; 200 var href= jQuery(this).attr("href"); 201 var target = jQuery(href == "#" || href == "" ? 'html' : href); 202 var position = target.offset().top-headerHight; 203 jQuery('body,html').animate({scrollTop:position}, speed, 'swing'); 204 return false;
205 }); 206}); 207 208 209 210 211 212//********************************************* 213// æåæ°å¶é 214//********************************************* 215$(function() { 216 var count = 30; 217 $('.text_limit30').each(function() { 218 var thisText = $(this).text(); 219 var textLength = thisText.length; 220 if (textLength > count) { 221 var showText = thisText.substring(0, count); 222 var insertText = showText += '...'; 223 $(this).html(insertText); 224 }; 225 }); 226}); 227 228 229 230$(function() { 231 var count = 20; 232 $('.text_limit20').each(function() { 233 var thisText = $(this).text(); 234 var textLength = thisText.length; 235 if (textLength > count) { 236 var showText = thisText.substring(0, count); 237 var insertText = showText += '...'; 238 $(this).html(insertText); 239 }; 240 }); 241}); 242 243 244 245 246 247//********************************************* 248// ããã¼ãã£ã³ã° 249//********************************************* 250(function($) { 251 252$(function () { 253 //click 254 $(".floatingBanner .bl_floatingBanner_close").click(function(){ 255 $(".floatingBanner").fadeOut(); 256 $(window).off("scroll", display); 257 }); 258}); 259 260})(jQuery); 261 262 263 264 265 266 267 268//********************************************* 269// è¦ç´ ãã°ã©ãã¼ã·ã§ã³ã§é ãã¦éé 270//********************************************* 271$(function(){ 272 $('button').on('click', function(){ 273 // ã¯ãªãã¯ãããã¿ã³ã®è¦ªè¦ç´ ã«ã¯ã©ã¹ãä»ä¸ 274 const target = $(this).closest('.container'); 275 276 // activeã¯ã©ã¹ã常ã«è¿½å ï¼å¤ããªãï¼ 277 target.addClass('active'); 278 279 // ã¹ã¯ãã¼ã«é åãå«ããé«ããåå¾ã»ä»ä¸ãã 280 const height = target.get(0).scrollHeight; 281 target.css('height', height); 282 283 // ããã¹ãã夿´ãã 284 $(this).text('éãã'); 285 }); 286}); 287 288 289 290 291 292 293 294 295//********************************************* 296// matchHeight 297//********************************************* 298$(function() { 299 function setH4Heights() { 300 // è¡ãããã®ã¢ã¤ãã æ°ãè¨å® 301 var itemsPerRow = $(window).width() < 768 ? 2 : 3; // ã¹ããã®å ´åã¯2ããã以å¤ã¯3 302 303 // è¡ãã¨ã®æå¤§é«ãã管çããé å 304 var rowHeights = []; 305 306 // åè¡ãã«ã¼ã 307 $("main.post section .txt").each(function(index) { 308 var h4 = $(this).find("h3"); 309 var rowIndex = Math.floor(index / itemsPerRow); // ç¾å¨ã®è¡ã¤ã³ããã¯ã¹ãåå¾ 310 311 // ç¾å¨ã®è¡ã®æå¤§é«ããåå¾ 312 if (!rowHeights[rowIndex]) { 313 rowHeights[rowIndex] = 0; // åæå 314 } 315 if (h4.height() > rowHeights[rowIndex]) { 316 rowHeights[rowIndex] = h4.height(); // æå¤§é«ããæ´æ° 317 } 318 }); 319 320 // åè¡ã®h4ã«æå¤§é«ããé©ç¨ 321 $("main.post section .txt").each(function(index) { 322 var h4 = $(this).find("h3"); 323 var rowIndex = Math.floor(index / itemsPerRow); // ç¾å¨ã®è¡ã¤ã³ããã¯ã¹ãåå¾ 324 h4.css("height", rowHeights[rowIndex] + "px"); // æå¤§é«ããè¨å® 325 }); 326 } 327 328 // ååå®è¡ 329 setH4Heights(); 330 331 // ãªãµã¤ãºã¤ãã³ã 332 $(window).on('resize', function() { 333 setH4Heights();
333 // ãªãµã¤ãºæã«ãé«ããåè¨å® 334 }); 335}); 336 337 338 339$(function(){ 340 //é«ãã®æå¤§å¤ãä»£å ¥ããããã®å¤æ°h 341 var h = 0; 342 343 //ããããã®è¦ç´ ã®é«ãã調ã¹ã 344ã $("#busspot .cont02 main section .txt h4").each(function(){ 345 // è¦ç´ ã®é«ããã¨å¤æ°hã®å¤ãæ¯è¼ãã大ããæ¹ã夿°hã«ä»£å ¥ãã¾ã 346 if($(this).height() > h) { 347 h = $(this).height(); 348 } 349 }); 350 351 // è¦ç´ ã®é«ãã夿°hã®å¤ã«çµ±ä¸ãã¾ã 352 $("#busspot .cont02 main section .txt h4").css("height", h + "px"); 353}); 354 355 356 357 358$(function() { 359 function setH4Heights() { 360 // è¡ãããã®ã¢ã¤ãã æ°ãè¨å® 361 var itemsPerRow = $(window).width() < 768 ? 2 : 3; // ã¹ããã®å ´åã¯2ããã以å¤ã¯3 362 363 // è¡ãã¨ã®æå¤§é«ãã管çããé å 364 var rowHeights = []; 365 366 // åè¡ãã«ã¼ã 367 $("#busspot .cont03 main section").each(function(index) { 368 var h4 = $(this).find("h4"); 369 var rowIndex = Math.floor(index / itemsPerRow); // ç¾å¨ã®è¡ã¤ã³ããã¯ã¹ãåå¾ 370 371 // ç¾å¨ã®è¡ã®æå¤§é«ããåå¾ 372 if (!rowHeights[rowIndex]) { 373 rowHeights[rowIndex] = 0; // åæå 374 } 375 if (h4.height() > rowHeights[rowIndex]) { 376 rowHeights[rowIndex] = h4.height(); // æå¤§é«ããæ´æ° 377 } 378 }); 379 380 // åè¡ã®h4ã«æå¤§é«ããé©ç¨ 381 $("#busspot .cont03 main section").each(function(index) { 382 var h4 = $(this).find("h4"); 383 var rowIndex = Math.floor(index / itemsPerRow); // ç¾å¨ã®è¡ã¤ã³ããã¯ã¹ãåå¾ 384 h4.css("height", rowHeights[rowIndex] + "px"); // æå¤§é«ããè¨å® 385 }); 386 } 387 388 // ååå®è¡ 389 setH4Heights(); 390 391 // ãªãµã¤ãºã¤ãã³ã 392 $(window).on('resize', function() { 393 setH4Heights();
393 // ãªãµã¤ãºæã«ãé«ããåè¨å® 394 }); 395}); 396 397 398 399 400 401//********************************************* 402// parallax 403//********************************************* 404jQuery( window ).bind( 'scroll', function() { 405 scrolled = jQuery( window ).scrollTop(); 406 weight1 = 0.02; 407 weight2 = 0.02; 408 weight3 = 0.02; 409 weight4 = 0.02; 410 jQuery( '.about .img01' ).css( 'top', 10 - scrolled * weight1 + '%' ); 411 jQuery( '.about .img02' ).css( 'top', 30 - scrolled * weight2 + '%' ); 412 jQuery( '.about .img03' ).css( 'top', 60 - scrolled * weight3 + '%' ); 413 jQuery( '.about .img04' ).css( 'top', 80 - scrolled * weight4 + '%' ); 414}); 415 416 417jQuery(window).bind('scroll', function() { 418 var scrolled = jQuery(window).scrollTop(); // ã¹ã¯ãã¼ã«éãåå¾ 419 420 jQuery('.about .img01, .about .img02, .about .img03, .about .img04').each(function() { 421 var offset = jQuery(this).offset().top; // ç»åã®ä½ç½® 422 423 // ç»åãç»é¢ã®ä¸ãã50pxã®ä½ç½®ã«éãããéæåº¦ã0ã«ãã 424 if (scrolled >= offset - 50) { 425 jQuery(this).css('opacity', 0); // éæåº¦ã0ã«è¨å® 426 } else { 427 jQuery(this).css('opacity', 1); // ç»åãç»é¢ã®ä¸ãã50pxã«éãã¦ããªãå ´åã¯éæåº¦ã1ã«æ»ã 428 } 429 }); 430}); 431 432 433 434 435 436 437 438 439 440 441 442
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.