Skip to content

Commit ddd1d97

Browse files
authored
added
1 parent 34ae2de commit ddd1d97

File tree

6 files changed

+206
-0
lines changed

6 files changed

+206
-0
lines changed

images/favicon-32x32.png

1.54 KB
Loading

images/favicon.ico

14.7 KB
Binary file not shown.

index.html

Lines changed: 152 additions & 0 deletions
Large diffs are not rendered by default.

styles.css

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
body {
2+
background-color: rgb(7, 7, 7);
3+
}
4+
h1 {
5+
color: rgb(238, 238, 243);
6+
}
7+
p {
8+
color: rgb(245, 244, 244);
9+
}
10+
p {
11+
border: 2px solid rgb(247, 13, 5);
12+
padding: 30px;
13+
}
14+
15+
16+
17+
18+
19+

wide.js

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
const tabItems = document.querySelectorAll(".tab-item");
2+
const tabContentItems = document.querySelectorAll(".tab-content-item");
3+
4+
// Select tab content
5+
function selectItem(e) {
6+
removeBorder();
7+
removeShow();
8+
// Add border to current tab
9+
this.classList.add("tab-border");
10+
// Grab content item from DOM
11+
const tabContentItem = document.querySelector(`#${this.id}-content`);
12+
// Add show class
13+
tabContentItem.classList.add("show");
14+
}
15+
16+
function removeBorder() {
17+
tabItems.forEach((item) => item.classList.remove("tab-border"));
18+
}
19+
20+
function removeShow() {
21+
tabContentItems.forEach((item) => item.classList.remove("show"));
22+
}
23+
24+
// Listen for tab click
25+
tabItems.forEach((item) => item.addEventListener("click", selectItem));

world.css

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
h1 {
2+
color: blue;
3+
font-family: verdana;
4+
font-size: 300%;
5+
}
6+
p {
7+
color: rgb(230, 222, 220);
8+
font-family: courier;
9+
font-size: 160%;
10+
}

0 commit comments

Comments
 (0)