index.html (3)
index.html (3)
DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Year 1, Section 1: Algebra 1</title>
<style>
body {
font-family: Arial, sans-serif;
line-height: 1.6;
margin: 0;
padding: 20px;
background-color: #f4f4f4;
}
.container {
max-width: 1200px;
margin: 0 auto;
background-color: #fff;
padding: 20px;
border-radius: 5px;
box-shadow: 0 0 10px rgba(0,0,0,0.1);
}
h1, h2, h3 {
color: #333;
}
.tab {
overflow: hidden;
border: 1px solid #ccc;
background-color: #f1f1f1;
}
.tab button {
background-color: inherit;
float: left;
border: none;
outline: none;
cursor: pointer;
padding: 14px 16px;
transition: 0.3s;
font-size: 17px;
}
.tab button:hover {
background-color: #ddd;
}
.tab button.active {
background-color: #ccc;
}
.tabcontent {
display: none;
padding: 6px 12px;
border: 1px solid #ccc;
border-top: none;
}
#dictionary input {
width: 100%;
padding: 12px 20px;
margin: 8px 0;
display: inline-block;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
}
#dictionary-list {
list-style-type: none;
padding: 0;
}
#dictionary-list li {
background-color: #f1f1f1;
margin: 5px 0;
padding: 10px;
border-radius: 3px;
}
</style>
</head>
<body>
<div class="container">
<h1>Year 1, Section 1: Algebra 1</h1>
<div class="tab">
<button class="tablinks" onclick="openTab(event, 'Content')"
id="defaultOpen">Content</button>
<button class="tablinks" onclick="openTab(event, 'WorkSolutions')">Work
Solutions</button>
<button class="tablinks" onclick="openTab(event, 'Quiz')">Quiz</button>
<button class="tablinks" onclick="openTab(event,
'Simulations')">Simulations</button>
<button class="tablinks" onclick="openTab(event,
'Resources')">Resources</button>
<button class="tablinks" onclick="openTab(event,
'Projects')">Projects</button>
<button class="tablinks" onclick="openTab(event,
'Dictionary')">Dictionary</button>
</div>
<script>
function openTab(evt, tabName) {
var i, tabcontent, tablinks;
tabcontent = document.getElementsByClassName("tabcontent");
for (i = 0; i < tabcontent.length; i++) {
tabcontent[i].style.display = "none";
}
tablinks = document.getElementsByClassName("tablinks");
for (i = 0; i < tablinks.length; i++) {
tablinks[i].className = tablinks[i].className.replace(" active",
"");
}
document.getElementById(tabName).style.display = "block";
evt.currentTarget.className += " active";
}
document.getElementById("defaultOpen").click();
function searchDictionary() {
var input, filter, ul, li, i, txtValue;
input = document.getElementById("dictionarySearch");
filter = input.value.toUpperCase();
ul = document.getElementById("dictionary-list");
li = ul.getElementsByTagName("li");
for (i = 0; i < li.length; i++) {
txtValue = li[i].textContent || li[i].innerText;
if (txtValue.toUpperCase().indexOf(filter) > -1) {
li[i].style.display = "";
} else {
li[i].style.display = "none";
}
}
}
</script>
</body>
</html>