Skip to content

Commit df8f3bf

Browse files
committed
UI Improved
1 parent 1e3b8f7 commit df8f3bf

File tree

5 files changed

+21
-27
lines changed

5 files changed

+21
-27
lines changed

image_1.png

4.26 KB
Loading

image_2.png

-8.8 KB
Loading

image_3.png

-16.3 KB
Loading

index.html

+18-22
Original file line numberDiff line numberDiff line change
@@ -5,48 +5,44 @@
55
<meta charset="UTF-8">
66
<meta http-equiv="X-UA-Compatible" content="IE=edge">
77
<meta name="viewport" content="width=device-width, initial-scale=1.0">
8-
<title>Visualizer for Sorting Algorithms</title>
8+
<title>Sorting Visualizer</title>
99
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-BmbxuPwQa2lc/FVzBcNJ7UAyJxM6wuqIj61tLrc4wSX0szH/Ev+nYRRuWlolflfl" crossorigin="anonymous">
1010
<link rel="stylesheet" href="style.css">
1111
</head>
1212
<header>
13-
<nav style="background-color: #42C2FF; font-weight: bold;" class=" navbar-brand navbar-expand-lg" align="center" >Visualizer for Sorting Algorithms</nav>
13+
<nav class=" navbar-brand navbar-expand-lg bg-info" align="center">Sorting Visualizer</nav>
1414
<nav>
15-
<div class="row navbar navbar-expand-lg navbar-dark" style="background-color: #85F4FF;">
16-
15+
<div class="row navbar navbar-expand-lg navbar-dark bg-dark">
1716
<div class=" navbar-brand nav-link col gap-2 d-sm-flex" id="newArray">
1817
<button type="button" class="btn btn-toolbar btn-outline-success btn-light btn-group btn-sm newArray">New Array</button>
1918
</div>
20-
21-
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
22-
<span class="navbar-toggler-icon"></span>
23-
</button>
24-
<div class="collapse navbar-collapse col gap-2 ms-auto justify-content-end" id="navbarNav">
25-
26-
<button type="button" class="btn btn-outline-info btn-light btn-sm insertionSort" style="color: black;">Insertion Sort</button>
27-
<button type="button" class="btn btn-outline-info btn-light btn-sm selectionSort" style="color: black;">Selection Sort</button>
28-
<button type="button" class="btn btn-outline-info btn-light btn-sm bubbleSort" style="color: black;">Bubble Sort</button>
29-
<button type="button" class="btn btn-outline-info btn-light btn-sm quickSort" style="color: black;">Quick Sort</button>
30-
<button type="button" class="btn btn-outline-info btn-light btn-sm mergeSort" style="color: black;">Merge Sort</button>
31-
</div>
32-
33-
<div class="col" id="input" >
34-
<span id="size" style="font-size: 20px; font-weight: bold; margin-left: 100px;">Size
19+
<div class="col" id="input">
20+
<span id="size">Size
3521
<input id="arr_sz" type="range" min="5" max="100" step=1 value=60>
3622
</span>
37-
<span id="speed" style="font-size: 20px; font-weight: bold; margin-right: 50px;">Speed
23+
<span id="speed">Speed
3824
<input id="speed_input" type="range" min="20" max="300" stepDown=10 value=60>
3925
</span>
4026
</div>
41-
27+
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
28+
<span class="navbar-toggler-icon"></span>
29+
</button>
30+
<div class="collapse navbar-collapse col gap-2 ms-auto justify-content-end" id="navbarNav">
31+
32+
<button type="button" class="btn btn-outline-info btn-light btn-sm insertionSort">Insertion Sort</button>
33+
<button type="button" class="btn btn-outline-info btn-light btn-sm selectionSort">Selection Sort</button>
34+
<button type="button" class="btn btn-outline-info btn-light btn-sm bubbleSort">Bubble Sort</button>
35+
<button type="button" class="btn btn-outline-info btn-light btn-sm quickSort">Quick Sort</button>
36+
<button type="button" class="btn btn-outline-info btn-light btn-sm mergeSort">Merge Sort</button>
37+
</div>
4238
</div>
4339
</nav>
4440
</div>
4541
</header>
4642

4743
<body class="bottom text-white">
4844

49-
<div id="bars" class="flex-container bg-gradient border-2" style="background-color: #B8FFF9;"></div>
45+
<div id="bars" class="flex-container bg-gradient border-2"></div>
5046
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta2/dist/js/bootstrap.bundle.min.js" integrity="sha384-b5kHyXgcpbZJO/tY9Ul7kGkf1S0CWuKcCD38l8YkeH8z8QjE0GmW1gYU5S9FOnJ0" crossorigin="anonymous"></script>
5147
<script src="js_files/sorting.js"></script>
5248
<script src="js_files/bubble.js"></script>

style.css

+3-5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
.flex-container {
32
margin-top: 20px;
43
display: flex;
@@ -31,15 +30,15 @@
3130
}
3231

3332
.flex-item {
34-
background: #42C2FF;
33+
background: cyan;
3534
border: 1pt solid black;
3635
width: 15px;
3736
transition: 0.1s all ease;
3837
}
3938

4039
.row {
4140
display: grid;
42-
grid-template-columns: 0.25fr 1fr 1fr;
41+
grid-template-columns: 1fr 1fr 2fr;
4342
}
4443

4544
.bottom {
@@ -50,5 +49,4 @@
5049
display: flex;
5150
padding: 10px;
5251
justify-content: space-around;
53-
}
54-
52+
}

0 commit comments

Comments
 (0)