-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
130 lines (87 loc) · 3.7 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
<html lang="en">
<head>
<meta charset="UTF-8"/>
<meta http-equiv="X-UA-Compatible" contents="IE=edge"/>
<meta name="viewport" content="width=device-width,initial-scale=1.0"/>
<title>Side NavBar - Tivotal</title>
<link rel="stylesheet" href="styles.css"/>
<link href='https://unpkg.com/[email protected]/css/boxicons.min.css' rel='stylesheet'>
</head>
<body>
<section class="sidebar">
<div class="nav-header">
<p class="logo">Tivotal</p>
<i class= 'bx bx-menu-alt-right btn-menu'></i>
</div>
<ul class="nav-links">
<li>
<i class='bx bx-search search-btn'></i>
<input type="text" placeholder="search..."/>
<span class="tooltip">Search</span>
</li>
<li> <a href="#">
<i class='bx bx-home-alt-2'></i>
<span class="title">Home</span>
</a><span class="tooltip">Home</span>
</li>
<li> <a href="#">
<i class='bx bx-phone-call'></i>
<span class="title">Calls</span></a>
<span class="tooltip">Calls</span>
</li>
<li> <a href="#">
<i class='bx bx-bookmark'></i>
<span class="title">Bookmarks</span></a>
<span class="tooltip">Bookmarks</span>
</li>
<li> <a href="#">
<i class='bx bx-wallet-alt'></i>
<span class="title">Wallet</span></a>
<span class="tooltip">Wallet</span>
</li>
<li> <a href="#">
<i class='bx bxs-devices'></i>
<span class="title">Devices</span></a>
<span class="tooltip">Devices</span>
</li>
<li id="hm2"> <a href="#">
<i class='bx bx-cog'></i>
<span class="title">Setting </span></a>
<span class="tooltip">Setting</span>
</li>
</ul>
<div class="theme-wrapper">
<i class='bx bxs-moon theme-icon'></i>
<p>Dark Theme</p>
<div class="theme-btn">
<span class="theme-ball"></span>
</div>
</div>
</section>
<section class="home">
<p>Home Content</p>
</section>
<script>
const btn_menu = document.querySelector(".btn-menu");
const side_bar = document.querySelector(".sidebar");
btn_menu.addEventListener("click",function(){
side_bar.classList.toggle("expand");
changebtn();
});
function changebtn(){
if(side_bar.classList.contains("expand")){
btn_menu.classList.replace("bx-menu","bx-menu-alt-right")
} else { btn_menu.classList.replace("bx-menu-alt-right","bx-menu")
}
}
const theme_change = document.querySelector(".theme-btn");
const theme_ball = document.querySelector(".theme-ball")
theme_change.addEventListener("click",function(){
document.body.classList.toggle("dark-mode");
theme_ball.classList.toggle("dark");
document.querySelector(".themewrapper p")
}
)
</script>
</body>
</html>