-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into fix-navbar
- Loading branch information
Showing
15 changed files
with
654 additions
and
409 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,157 @@ | ||
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans:wght@400;700&display=swap"); | ||
@import url("https://fonts.googleapis.com/css2?family=Zilla+Slab:ital,wght@1,300&display=swap"); | ||
|
||
* { | ||
margin: 0; | ||
padding: 0; | ||
box-sizing: border-box; | ||
font-family: "Noto Sans", sans-serif; | ||
} | ||
|
||
body { | ||
position: relative; | ||
overflow-x: hidden; | ||
} | ||
|
||
.contact { | ||
position: relative; | ||
min-height: 100vh; | ||
padding: 50px 100px; | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
flex-direction: column; | ||
z-index: 2; | ||
} | ||
|
||
.background { | ||
position: absolute; | ||
z-index: -1; | ||
background: url("Background.jpeg"); | ||
filter: blur(3px); | ||
-webkit-filter: blur(3px); | ||
width: 100%; | ||
height: 100%; | ||
background-position: center; | ||
background-repeat: no-repeat; | ||
background-size: cover; | ||
} | ||
|
||
.toggle { | ||
display: none; | ||
} | ||
|
||
.contact .content { | ||
max-width: 800px; | ||
text-align: center; | ||
background-color: #00bcd4; | ||
color: #fff; | ||
padding: 20px; | ||
border-radius: 10px; | ||
box-shadow: rgba(0, 0, 0, 0.35) 0px 5px 15px; | ||
} | ||
|
||
.contact .content h2 { | ||
font-size: 36px; | ||
font-weight: 700; | ||
} | ||
|
||
.contact .content p { | ||
font-weight: 400; | ||
} | ||
|
||
.container { | ||
width: 100%; | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
margin-top: 30px; | ||
} | ||
|
||
.contactForm { | ||
width: 40vw; | ||
padding: 40px; | ||
background: #fff; | ||
box-shadow: rgba(0, 0, 0, 0.35) 0px 5px 15px; | ||
border-radius: 10px; | ||
} | ||
|
||
.contactForm .inputBox { | ||
position: relative; | ||
width: 100%; | ||
margin-top: 10px; | ||
} | ||
|
||
.contactForm .inputBox input, | ||
.contactForm .inputBox textarea { | ||
width: 100%; | ||
padding: 5px 0px; | ||
font-size: 16px; | ||
margin: 10px 0; | ||
border: none; | ||
border-bottom: 2px solid #333; | ||
outline: none; | ||
resize: none; | ||
} | ||
|
||
.contactForm .inputBox span { | ||
position: absolute; | ||
left: 0; | ||
padding: 5px 0px; | ||
font-size: 16px; | ||
margin: 10px 0; | ||
pointer-events: none; | ||
transition: 0.2s; | ||
color: #666; | ||
} | ||
|
||
.contactForm .inputBox input:focus ~ span, | ||
.contactForm .inputBox input:valid ~ span, | ||
.contactForm .inputBox textarea:focus ~ span, | ||
.contactForm .inputBox textarea:valid ~ span { | ||
color: #00bcd4; | ||
font-size: 12px; | ||
transform: translateY(-20px); | ||
} | ||
|
||
.submitbtn { | ||
text-align: center; | ||
} | ||
|
||
.btn { | ||
width: 100px; | ||
background: #00bcd4; | ||
color: #fff; | ||
border: none; | ||
cursor: pointer; | ||
padding: 10px; | ||
font-size: 18px; | ||
display: inline-block; | ||
border-radius: 40px; | ||
border: 1px solid #00bcd4; | ||
transition: all 300ms cubic-bezier(0.23, 1, 0.32, 1); | ||
} | ||
|
||
.btn:hover { | ||
background: #fff; | ||
color: #00bcd4; | ||
box-shadow: rgba(0, 0, 0, 0.25) 0 8px 15px; | ||
transform: translateY(-2px); | ||
} | ||
|
||
.btn:active { | ||
box-shadow: none; | ||
transform: translateY(0); | ||
} | ||
|
||
@media (max-width: 991px) { | ||
.contact { | ||
padding: 50px; | ||
} | ||
.container { | ||
flex-direction: column; | ||
} | ||
.contactForm { | ||
width: 100%; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<meta http-equiv="X-UA-Compatible" content="IE=edge" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<meta name="referrer" content="origin" /> | ||
<title>Contact Page</title> | ||
<link rel="shortcut icon" href="../favicon.png" type="image/png" /> | ||
<link rel="stylesheet" href="contact.css" /> | ||
</head> | ||
<body> | ||
<div class="background"></div> | ||
<section class="contact"> | ||
<div class="content toggle" id="thanks"> | ||
<p>Thanks for Contacting Us!</p> | ||
<p> | ||
Click <a href="/index.html">here</a> to go back to the home page. 🤗 | ||
</p> | ||
<p id="counter"></p> | ||
</div> | ||
<div class="content" id="header"> | ||
<h1>Contact Us</h1> | ||
<p> | ||
A community for the students, by the students, and of the students! | ||
We’re here to provide you with all the resources you’ll require in | ||
your journey, and mentor you to become the best of the best. | ||
</p> | ||
</div> | ||
<div class="container"> | ||
<div class="contactForm" id="container"> | ||
<!-- Add below in action the valid email ID to which the mail should be sent over to. --> | ||
<form | ||
action="mailto:youremail@gmail.com" | ||
method="POST" | ||
onsubmit="formHandler(event);" | ||
id="form" | ||
> | ||
<div class="inputBox"> | ||
<input | ||
type="text" | ||
name="First Name" | ||
required="required" | ||
autocomplete="off" | ||
/> | ||
<span>First Name</span> | ||
</div> | ||
<div class="inputBox"> | ||
<input | ||
type="text" | ||
name="Last Name" | ||
required="required" | ||
autocomplete="off" | ||
/> | ||
<span>Last Name</span> | ||
</div> | ||
<div class="inputBox"> | ||
<input | ||
type="email" | ||
name="Email" | ||
required="required" | ||
autocomplete="off" | ||
/> | ||
<span>Email</span> | ||
</div> | ||
<div class="inputBox"> | ||
<textarea | ||
name="Message/Suggestion" | ||
cols="15" | ||
rows="2" | ||
minlength="10" | ||
maxlength="100" | ||
required="required" | ||
></textarea> | ||
<span>Message/Suggestion</span> | ||
</div> | ||
<div class="inputBox submitbtn"> | ||
<button class="btn" type="submit">Submit</button> | ||
</div> | ||
</form> | ||
</div> | ||
</div> | ||
</section> | ||
<script src="contact.js"></script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
const container = document.getElementById("container"); | ||
const header = document.getElementById("header"); | ||
const thanks = document.getElementById("thanks"); | ||
const form = document.getElementById("form"); | ||
const counterElem = document.getElementById("counter"); | ||
|
||
let limit = 30; // 30s to wait until the user should be redirected to the home page. | ||
|
||
const counter = async () => { | ||
return new Promise((resolve, reject) => { | ||
let temp = setInterval(() => { | ||
if (limit == 0) { | ||
clearInterval(temp); | ||
resolve(); | ||
} | ||
counterElem.innerText = `Redirecting you to the homepage in ${limit} seconds`; | ||
limit--; | ||
}, 1000); | ||
}); | ||
}; | ||
|
||
const formHandler = async (e) => { | ||
e.preventDefault(); | ||
form.submit(); | ||
setTimeout(() => { | ||
container.classList.add("toggle"); | ||
header.classList.add("toggle"); | ||
thanks.classList.remove("toggle"); | ||
}, 1000); | ||
await counter(); | ||
window.location.assign("/index.html"); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.