Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
mirai-mamori authored Mar 31, 2020
1 parent 7221595 commit a912028
Showing 1 changed file with 6 additions and 25 deletions.
31 changes: 6 additions & 25 deletions js/sakura-app.js
Original file line number Diff line number Diff line change
Expand Up @@ -417,9 +417,9 @@ $(document).ready(function () {
$(".changeSkin-gear").css("visibility", "visible");
}, 300);
}
$(".changeSkin-gear").click(function () {
$("#changskin").click(function () {
$(".skin-menu").toggleClass('show');
})
})
$(".skin-menu #close-skinMenu").click(function () {
closeSkinMenu();
});
Expand Down Expand Up @@ -1785,42 +1785,23 @@ var home = location.href,
},
GT: function () {
var cwidth = document.body.clientWidth,
cheight = window.innerHeight,
pc_to_top = document.querySelector(".cd-top"),
mb_to_top = document.querySelector("#moblieGoTop"),
changeskin = document.querySelector(".changeSkin-gear");
changeskin = document.querySelector("#changskin");

$(window).scroll(function() {
if (cwidth <= 860) {
if ($(this).scrollTop() > 20) {
mb_to_top.style.transform = "scale(1)";
} else {
mb_to_top.style.transform = "scale(0)";
}
} else {
if (cwidth > 860) {
if ($(this).scrollTop() > 100) {
pc_to_top.classList.add("cd-is-visible");
changeskin.style.bottom = "0";
if (cheight > 950) {
pc_to_top.style.top = "0";
} else {
pc_to_top.style.top = cheight - 950 + "px";
}
changeskin.style.transform = "scale(1)";
} else {
changeskin.style.bottom = "-999px";
pc_to_top.style.top = "-999px";
pc_to_top.classList.remove("cd-fade-out", "cd-is-visible");
}
if ($(this).scrollTop() > 1200) {
pc_to_top.classList.add("cd-fade-out");
changeskin.style.transform = "scale(0)";
}
}
});

//smooth scroll to top
pc_to_top.onclick = function() {
topFunction();
}
}
}
$(function () {
Expand Down

0 comments on commit a912028

Please sign in to comment.