Attempted restore scroll script added favicons

Tried to add the return scroll for  when the focus left on mobile. Still need to figure it out.

Added favicons.
This commit is contained in:
2018-10-18 00:52:55 -04:00
parent 415264a84f
commit 40f0c47972
12 changed files with 77 additions and 16 deletions

BIN
android-chrome-192x192.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

BIN
android-chrome-256x256.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

BIN
apple-touch-icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

9
browserconfig.xml Normal file
View File

@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<browserconfig>
<msapplication>
<tile>
<square150x150logo src="/mstile-150x150.png"/>
<TileColor>#cdff00</TileColor>
</tile>
</msapplication>
</browserconfig>

BIN
favicon-16x16.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 949 B

BIN
favicon-32x32.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

BIN
favicon.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

View File

@@ -9,8 +9,13 @@
<meta name="apple-mobile-web-app-capable" content="yes">
<link rel="manifest" href="site.webmanifest">
<link rel="apple-touch-icon" href="icon.png">
<!-- Place favicon.ico in the root directory -->
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
<link rel="manifest" href="/site.webmanifest">
<link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5">
<meta name="msapplication-TileColor" content="#cdff00">
<meta name="theme-color" content="#ffffff">
<link rel="stylesheet" href="css/normalize.css">
<link rel="stylesheet" href="css/main.css">
@@ -41,20 +46,8 @@
<div class="b-platevisual__weight">
<img src="images/BarBell.svg" class="b-platevisual__barbell">
<div class="b-platevisual__plates b-platevisual__plates--left">
<!-- <img src="images/45lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--45">
<img src="images/35lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--35">
<img src="images/25lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--25">
<img src="images/10lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--10">
<img src="images/5lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--5">
<img src="images/2halflbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--2half"> -->
</div>
<div class="b-platevisual__plates b-platevisual__plates--right">
<!-- <img src="images/45lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--45">
<img src="images/35lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--35">
<img src="images/25lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--25">
<img src="images/10lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--10">
<img src="images/5lbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--5">
<img src="images/2halflbs-Plate.svg" class="b-platevisual__plate b-platevisual__plate--2half"> -->
</div>
</div>
<p class="subheading">Offset: <span class="input-difference">0</span> LBS</p>

View File

@@ -119,11 +119,34 @@
var savedScrollTop
function saveScroll() {
var savedScrollTop = jQuery(document).scrollTop(); // save scroll position
console.log(savedScrollTop);
}
function restoreScroll() {
jQuery(document).scrollTop(savedScrollTop); // restore it
function restoreScroll(savedScrollTop){
jQuery("html, body").animate({
scrollTop: savedScrollTop
}, 800).offset().top;
}
//Failed scroll restore functions
// jQuery("#Weight").blur(function(event) {
// $("html, body").animate({
// scrollTop: savedScrollTop
// }, 800).offset().top;
// });
/*function restoreScroll() {
$("a").on('click', function(event) {
jQuery(window).scrollTop(savedScrollTop);*/
/* window.scrollTo({
top: "savedScrollTop",
behavior: "smooth"
}); // restore it*/
/*var savedScrollTop = $(document).scrollTop(); // save scroll position

BIN
mstile-150x150.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

17
safari-pinned-tab.svg Normal file
View File

@@ -0,0 +1,17 @@
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
width="260.000000pt" height="260.000000pt" viewBox="0 0 260.000000 260.000000"
preserveAspectRatio="xMidYMid meet">
<metadata>
Created by potrace 1.11, written by Peter Selinger 2001-2013
</metadata>
<g transform="translate(0.000000,260.000000) scale(0.100000,-0.100000)"
fill="#000000" stroke="none">
<path d="M1140 2315 c-157 -29 -303 -94 -435 -192 -189 -140 -331 -361 -392
-608 -25 -101 -25 -352 1 -459 126 -541 641 -893 1170 -801 374 65 680 329
806 695 69 202 69 468 0 670 -56 163 -131 282 -254 406 -143 142 -286 225
-479 275 -105 28 -309 35 -417 14z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 777 B

19
site.webmanifest Normal file
View File

@@ -0,0 +1,19 @@
{
"name": "",
"short_name": "",
"icons": [
{
"src": "/android-chrome-192x192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/android-chrome-256x256.png",
"sizes": "256x256",
"type": "image/png"
}
],
"theme_color": "#ffffff",
"background_color": "#ffffff",
"display": "standalone"
}