PageSourceSearch

https://www.masumuradoll.co.jp/SHOP/js/floating_menu.js

js masumuradoll.co.jp collected 2026-09-25 06:08:07 UTC 1,056 bytes, 45 lines download raw bytes

1$(function ($) {
2    var floatingMenu = $('#floating-menu');
3    floatingMenu.hide();
4
5    $(window).scroll(function () {
6        if ($(this).scrollTop() > 100) {
7            floatingMenu.fadeIn();
8        } else {
9            floatingMenu.fadeOut();
10        }
11    });
12
13    if ($(window).scrollTop() > 100 && !floatingMenu.is(':visible')) {
14        floatingMenu.fadeIn();
15    }
16
17    floatingMenu.find('p').click(function () {
18        var top = 0;
19        var id = $(this).attr('id');
20        if (id === 'to-cart') {
21            top = $('#pi_cart').offset().top;
22        }
23        $('body,html').animate({
24            scrollTop: top
25        }, 500);
26        return false;
27    });
28});
29
30function addOnload(func) {
31    try {
32        window.addEventListener("load", func, false);
33    } catch (e) {
34        window.attachEvent("onload", func);
35    }
36}
37
38function loadBtnToCart() {
39    addOnload(function () {
40        var btnToCart = document.getElementById('to-cart');
41        if (btnToCart !== null) {
42            btnToCart.style.display = '';
43        }
44    });
45}

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.