PageSourceSearch

https://alterna.jp/share/js_responsive/pagetop.js?d=20261002

js alterna.jp collected 2026-10-05 04:56:04 UTC 1,226 bytes, 41 lines download raw bytes

1//ページトップに戻る
2$(function(){
3  var pageTop = $('#pageTop');
4  var winHeight = $(window).height();
5  var wrap = $('#wrapper');
6  var wrapOuterHeight = wrap.outerHeight();
7  var wrapPaddingBtm = parseInt(wrap.css('padding-bottom'), 10);
8  var wrapHeight = wrapOuterHeight - wrapPaddingBtm;
9  var footHeight = $('#footer-link').outerHeight();
10  var fadeHeight = wrapHeight - winHeight - footHeight;
11  if ($(window).width() <= 1024) {
12    var mapBtn = $('#map-btn');
13    if (!mapBtn.length===0) {
14      return false;
15    } else {
16      var mapBtnBtm = parseInt(mapBtn.css('bottom'), 10);
17      var pageTopHeight = pageTop.height();
18      $(pageTop,'a').css({'bottom':mapBtnBtm+pageTopHeight+10+'px'});
19    }
20  }
21  $(window).scroll(function () {
22    if ($(window).width() >= 1025) {
23      if ($(this).scrollTop() > 100 ) {
24        pageTop.fadeIn();
25      } else {
26        pageTop.fadeOut();
27      }
28    }
29    if ($(window).width() <= 1024) {
30      if ($(this).scrollTop() > 100 && $(this).scrollTop() < fadeHeight ) {
31        pageTop.fadeIn();
32      } else {
33        pageTop.fadeOut();
34      }
35    }
36  });
37  pageTop.click(function () {
38    $('body, html').animate({ scrollTop: 0 }, 500);
39    return false;
40  });
41});

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.