1// Navåºå®--------------------------------------- 2 3$(function () { 4 var $header = $("#top-head"); 5 // Nav Fixedãä¸åºå® 6 $(window).scroll(function () { 7 if ($(window).scrollTop() > 500) { 8 $header.addClass("fixed"); 9 } else { 10 $header.removeClass("fixed"); 11 } 12 }); 13 14 //$(window).scroll(function() { 15 //if ($(window).scrollTop() > 3000) { 16 //$header.addClass('bg-white'); 17 //} else { 18 //$header.removeClass('bg-white'); 19 //} 20 //}); 21 22 $(window).scroll(function () { 23 if ($(window).scrollTop() > $("#other").offset().top) { 24 $header.addClass("bg-white"); 25 } //ãã以å¤ï¼ã¤ã¾ãã»ã¯ã·ã§ã³ï¼ã§ããå ´åï¼ã¯ãã 26 else $header.removeClass("bg-white"); 27 }); 28 29 $(window).scroll(function () { 30 //ã»ã¯ã·ã§ã³ï¼ããï¼ã®éã¯ãã 31 if ( 32 $(window).scrollTop() > $("#about").offset().top && 33 $(window).scrollTop() < $("#menu").offset().top 34 ) { 35 $(".index header .header_wrap nav .gnav .page_link a").css( 36 "color", 37 "#fff" 38 ); 39 } //ã»ã¯ã·ã§ã³ï¼ããé²ãã ããã //ãã以å¤ï¼ã¤ã¾ãã»ã¯ã·ã§ã³ï¼ã§ããå ´åï¼ã¯ãã 40 else 41 $(".index header .header_wrap nav .gnav .page_link a").css( 42 "color", 43 "#333" 44 ); 45 }); 46 47 $(window).scroll(function () { 48 //ã»ã¯ã·ã§ã³ï¼ããï¼ã®éã¯ãã 49 if ( 50 $(window).scrollTop() > $("#about").offset().top && 51 $(window).scrollTop() < $("#menu").offset().top 52 ) { 53 $(".index header .header_wrap nav .gnav .page_link span").css( 54 "color", 55 "#fff" 56 ); 57 } //ã»ã¯ã·ã§ã³ï¼ããé²ãã ããã //ãã以å¤ï¼ã¤ã¾ãã»ã¯ã·ã§ã³ï¼ã§ããå ´åï¼ã¯ãã 58 else 59 $(".index header .header_wrap nav .gnav .page_link span").css( 60 "color", 61 "#333" 62 ); 63 }); 64 65 // Nav Toggle Buttonããã³ãã¼ã¬ã¼ 66 // $('#nav-toggle').click(function(){ 67 // $header.toggleClass('open'); 68 // }); 69 // $('#global_nav li a').on('click', function(){ 70 // if (window.innerWidth <= 768) { 71 // $('#nav_toggle').click(); 72 // } 73 // }); 74}); 75 76// $(function(){ 77// var state = false; 78// var scrollpos; 79// 80// $('#nav-toggle').on('click', function(){ 81// if(state == false) { 82// scrollpos = $(window).scrollTop(); 83// $('body').addClass('bg-fixed').css({'top': -scrollpos}); 84// // $('#fullpage').addClass('fullpage') 85// // $('#fullpage').removeAttr('id'); 86// state = true; 87// } else { 88// $('body').removeClass('bg-fixed').css({'top': 0}); 89// // $('#fullpage').removeClass('fullpage') 90// // $('.fullpage').attr('id', 'fullpage') 91// window.scrollTo( 0 , scrollpos ); 92// state = false; 93// } 94// }); 95// 96// }); 97 98//Fullpage--------------------------------------- 99 100$(function () { 101 $("#fullpage").fullpage({ 102 scrollingSpeed: 600, 103 autoScrolling: true, 104 hybrid: true, 105 fitToSection: false, 106 fitToSectionDelay: 1000, 107 scrollBar: false, 108 easing: "easeInOutCubic", 109 easingcss3: "ease", 110 loopBottom: false, 111 loopTop: false, 112 loopHorizontal: true, 113 continuousVertical: false, 114 continuousHorizontal: false, 115 scrollHorizontally: false, 116 interlockedSlides: false, 117 dragAndMove: false, 118 offsetSections: false, 119 resetSliders: false, 120 fadingEffect: false, 121 normalScrollElements: ".element", 122 scrollOverflow: false, 123 scrollOverflowReset: false, 124 scrollOverflowOptions: null, 125 touchSensitivity: 15, 126 normalScrollElementTouchThreshold: 5, 127 bigSectionsDestination: null, 128 }); 129}); 130 131// Woprdpress_rest_apiãããã¥ã¼ã¹ãåå¾ 132news_get(3); 133function news_get(num) { 134 fetch("https://oliviersandco.jp/blog/wp-json/wp/v2/news?per_page=3") 135 .then((res) => res.json()) 136 .then((json) => { 137 $.each(json, function (index, value) { 138 var news_id = value.id; 139 var news_title = value.title.rendered; 140 var news_content = value.content.rendered; 141 var news_date = formatDate(new Date(value.date)); 142 $("#news_list").append( 143 "<dl><dt>" + 144 news_date + 145 '</dt><dd><a class="pc_only" href="hpgen/HPB/categories/18840.html#' + 146 news_id + 147 '">' + 148 news_title + 149 '</a><a class="sp_tb_only" href="hpgen/HPB/entries/1.html#' + 150 news_id + 151 '">' + 152 news_title + 153 "</a></dd></dl>" 154 ); 155 }); 156 });
157 // æ¥ä»ãã©ã¼ããã 158 function formatDate(dt) { 159 var y = dt.getFullYear(); 160 var m = ("00" + (dt.getMonth() + 1)).slice(-2); 161 var d = ("00" + dt.getDate()).slice(-2); 162 return y + "." + m + "." + d; 163 } 164} 165 166// wordpressããã©ã³ãã³ã°ãåå¾ 167function ranking_get() { 168 fetch("https://oliviersandco.jp/blog/wp-json/wp/v2/webtool/2634") 169 .then((res) => res.json()) 170 .then((json) => { 171 $("#rankingArea").append(json.content.rendered); 172 }); 173} 174 175// wordpressããã¹ã©ã¤ãã¼ãåå¾ 176function getTopSlider() { 177 return fetch("https://oliviersandco.jp/blog/wp-json/wp/v2/webtool/2650") 178 .then((res) => res.json()) 179 .then((json) => { 180 var consequence = $("#topSliders .fp-tableCell").prepend( 181 json.content.rendered 182 ); 183 var slider = consequence.find("a"); 184 //URLã«ã?demoããã¤ãã¦ããªãå ´å 185 if (location.search.indexOf("demo") < 0) { 186 //åå¾ãã¼ã¿æ¥ä»å¦ç 187 var now = new Date(); 188 console.log(slider); 189 slider.each(function () { 190 var start = new Date($(this).data("release")); 191 var end = new Date($(this).data("enddate")); 192 if (start > now || end < now) { 193 $(this).remove(); 194 } 195 }); 196 } 197 return slider; 198 }) 199 .then(() => { 200 $("#p_slider,#p_slider_sp").bxSlider({ 201 mode: "fade", 202 auto: true, 203 pager: false, 204 infiniteLoop: true, 205 control: false, 206 speed: 4000, 207 touchEnabled: false, 208 onSliderLoad: function () { 209 $("ul.bxslider li span").css("visibility", "visible"); 210 }, 211 }); 212 }); 213}
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.