Skip to content

Commit db0dc1d

Browse files
authored
Add files via upload
1 parent 1fa77eb commit db0dc1d

3 files changed

Lines changed: 68 additions & 0 deletions

File tree

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
6+
<title>Day 2 -Task 1</title>
7+
<link rel="stylesheet" href="style.css">
8+
</head>
9+
<body>
10+
<div class="container">
11+
<h1>Click to Show Info</h1>
12+
<div class="input">
13+
<p id="para" class="hidden">🎉 Welcome, You clicked the button!</p>
14+
<button id="click">Click me to Reveal!</button>
15+
</div>
16+
</div>
17+
18+
<script src="script.js"></script>
19+
</body>
20+
</html>
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
const para = document.getElementById("para");
2+
const button = document.getElementById("click");
3+
4+
button.addEventListener("click", () => {
5+
para.classList.remove("hidden");
6+
button.textContent = "Clicked!";
7+
});
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
* {
2+
box-sizing: border-box;
3+
margin: 0;
4+
padding: 0;
5+
}
6+
7+
body {
8+
font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
9+
padding: 100px 20px;
10+
background: linear-gradient(to right, lightgreen, lightblue);
11+
text-align: center;
12+
}
13+
14+
.container {
15+
background: white;
16+
padding: 40px;
17+
max-width: 400px;
18+
margin: auto;
19+
box-shadow: 0 0 10px rgba(0, 0, 0, 0.9);
20+
border-radius: 20px;
21+
}
22+
23+
.input {
24+
margin-top: 20px;
25+
}
26+
27+
p {
28+
color: green;
29+
}
30+
31+
button {
32+
margin-top: 10px;
33+
cursor: pointer;
34+
padding: 6px 20px;
35+
border: 3px solid grey;
36+
border-radius: 10px;
37+
}
38+
39+
.hidden {
40+
display: none;
41+
}

0 commit comments

Comments
 (0)