Skip to content

Commit

Permalink
Popup feature for privacy and terms
Browse files Browse the repository at this point in the history
Html and js part is in the index.html and css part is in wanderer.css
  • Loading branch information
amyra98 committed Mar 16, 2022
1 parent d4b9b37 commit cc64e8f
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 1 deletion.
32 changes: 32 additions & 0 deletions CSS/wanderer.css
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,36 @@ div.internaltextcolor2{
}
div.contentfont{
font-family: Cambria;
}
.popup{
width: 800px;
background-color: rgb(129, 165, 182);
border-radius: 6px;
position: absolute;
margin-top: 900px;
opacity: 1;
left: 50%;
transform: translate(-50%,-50%) scale(0.1);
text-align: center;
padding: 0 30px 30px;
color: #333;
visibility: hidden;
transition: transform 0.4s, top 0.4s;
}
.open-popup{
visibility: visible;
top: 100%;
transform: translate(-50%,-50%) scale(1);
}
.popup button{
width: 100%;
margin-top: 50px;
padding: 10px 0px;
background: rgb(133, 75, 75);
color: #fff;
border: 0;
outline: none;
font-size: 18px;
border-radius: 4px;
cursor: pointer;
}
19 changes: 18 additions & 1 deletion HTML/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -207,13 +207,30 @@ <h3 class="head1">Follow Us On :</h3><br>
<div class="row justify-content-between">
<div class="col-lg-120">
<div>
<p >© 2020-2021 Wanderer Pvt. Ltd. &nbsp&nbsp<a href="#">Privacy</a> · <a href="#">Terms</a></p>
<p >© 2020-2021 Wanderer Pvt. Ltd. &nbsp&nbsp<h5 onclick="openPopup()">Privacy</h5><h5 onclick="openPopup()">Terms</h5></p>
<div class="popup" id="popup">
<h2>Rules and Regulations</h2>
<p>
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
</p>
<button type="button" onclick="closePopup()">OK</button>
</div>
</div>
</div>
</div>
</div>
</div>
</footer>
<script>
let popup= document.getElementById("popup");
function openPopup(){
popup.classList.add("open-popup");
}
function closePopup(){
popup.classList.remove("open-popup");
}
</script>

<script src="../js/totop.js"></script>
<script src="https://code.jquery.com/jquery-3.4.1.slim.min.js"
integrity="sha384-J6qa4849blE2+poT4WnyKhv5vZF5SrPo0iEjwBvKU7imGFAV0wwj1yYfoRSJoZ+n"
Expand Down

0 comments on commit cc64e8f

Please sign in to comment.