From a969a8a4fb183a43133261c565b153fe8275d9cb Mon Sep 17 00:00:00 2001 From: Prakamya_mishra Date: Tue, 27 Jun 2017 14:29:59 +0530 Subject: [PATCH 1/4] updated positioning of contact icons positioned social contact icons in center --- index.html | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/index.html b/index.html index aca8b5e..df56e79 100644 --- a/index.html +++ b/index.html @@ -245,11 +245,9 @@

Let's Get In Touch!


Any Questions? Ping us anytime and we'd love to help you

-
+
-
-
- +
From 64563d5f231e04d7b650aae8f11758bf18bafb79 Mon Sep 17 00:00:00 2001 From: Prakamya_mishra Date: Tue, 27 Jun 2017 14:48:18 +0530 Subject: [PATCH 2/4] added top button js --- js/creative.js | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/js/creative.js b/js/creative.js index 2a38861..492f2f8 100644 --- a/js/creative.js +++ b/js/creative.js @@ -46,3 +46,20 @@ new WOW().init(); })(jQuery); // End of use strict +// Top button +// When the user scrolls down 20px from the top of the document, show the button +window.onscroll = function() {scrollFunction()}; + +function scrollFunction() { + if (document.body.scrollTop > 20 || document.documentElement.scrollTop > 20) { + document.getElementById("myBtn").style.display = "block"; + } else { + document.getElementById("myBtn").style.display = "none"; + } +} + +// When the user clicks on the button, scroll to the top of the document +function topFunction() { + document.body.scrollTop = 0; // For Chrome, Safari and Opera + document.documentElement.scrollTop = 0; // For IE and Firefox +} From 05d0856605b1a57fe411a1a9b31bc18f8c6812a4 Mon Sep 17 00:00:00 2001 From: Prakamya_mishra Date: Tue, 27 Jun 2017 14:49:48 +0530 Subject: [PATCH 3/4] added top button to html --- index.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index df56e79..5157c4d 100644 --- a/index.html +++ b/index.html @@ -252,7 +252,9 @@

Let's Get In Touch!

- + + + From d2bf49f0e68572ad0fba91f54789362df4ed5347 Mon Sep 17 00:00:00 2001 From: Prakamya_mishra Date: Tue, 27 Jun 2017 14:51:30 +0530 Subject: [PATCH 4/4] top button css --- css/creative.css | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/css/creative.css b/css/creative.css index bce1b98..b373bda 100644 --- a/css/creative.css +++ b/css/creative.css @@ -471,6 +471,26 @@ img::-moz-selection { background: 0 0; } +#myBtn { + display: none; /* Hidden by default */ + position: fixed; /* Fixed/sticky position */ + bottom: 20px; /* Place the button at the bottom of the page */ + right: 30px; /* Place the button 30px from the right */ + z-index: 99; /* Make sure it does not overlap */ + border: none; /* Remove borders */ + outline: none; /* Remove outline */ + background-color: #f05f40; /* Set a background color */ + color: white; /* Text color */ + cursor: pointer; /* Add a mouse pointer on hover */ + padding: 15px; /* Some padding */ + border-radius: 10px; /* Rounded corners */ +} + +#myBtn:hover { + background-color: #555; /* Add a dark-grey background on hover */ +} + + body { webkit-tap-highlight-color: #222; -} \ No newline at end of file +}