diff --git a/css/appstyling-v2.css b/css/appstyling-v2.css index dbfda02..03e41da 100644 --- a/css/appstyling-v2.css +++ b/css/appstyling-v2.css @@ -122,7 +122,6 @@ p.subheading { font-weight: 500; line-height: 28px; letter-spacing: .015px; - display: none; } .b-platevisual__weight{ diff --git a/index.html b/index.html index 730dbaf..3ea9db7 100644 --- a/index.html +++ b/index.html @@ -42,7 +42,7 @@
-

0 LBS

+

45 LBS

diff --git a/js/Weight Calculation Script-Edited-Jquery-V4.js b/js/Weight Calculation Script-Edited-Jquery-V4.js index a452876..6c728fa 100644 --- a/js/Weight Calculation Script-Edited-Jquery-V4.js +++ b/js/Weight Calculation Script-Edited-Jquery-V4.js @@ -174,10 +174,12 @@ //reset inputs and plate visuals jQuery(".b-infoentry__reset").click(function(){ + var bar = jQuery(".input-bar").val(); jQuery(".input-weight, .input-weightsneeded").val(''); - jQuery(".input-final, .input-difference").html('0'); + jQuery(".input-final, .input-difference").html(bar); animatePlatesOut(); - jQuery(".b-infoentry__reset, .b-platevisual__weightfinal, .b-platevisual__weightdifference").hide(); + jQuery(".b-platevisual__plates").html(""); + jQuery(".b-infoentry__reset, .b-platevisual__weightdifference").hide(); }); //Saves scroll position on focus and restores @@ -200,4 +202,16 @@ jQuery(".input-weight").on('blur', function(){ restoreScroll() }); + + //Updates Bar Weight if plate visuals do not exist. + jQuery(".input-bar").on("change", function() { + var bar = jQuery(".input-bar").val(); + if (jQuery('.b-platevisual__plate').length == 0){ + jQuery(".input-final").html(bar); + } + }); + + }); + +