-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsort.html
More file actions
71 lines (59 loc) · 2.19 KB
/
sort.html
File metadata and controls
71 lines (59 loc) · 2.19 KB
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Sorting Algorithms Visualization</title>
<link rel="stylesheet" href="./styles/sort.css">
</head>
<body>
<!-- Navbar -->
<div class="navbar">
<a href="explanation.html">Explanation</a>
<a href="sort.html" class="current">Visualization</a>
<a href="complexity.html">Time Complexity</a>
</div>
<div class="container">
<header class="header">
<h1>Sorting Algorithm Visualization</h1>
<div class="algorithm-name" id="algorithmName">No algorithm detected</div>
</header>
<div class="visualization-wrapper">
<button class="btn" id="prev" onclick="prevStep()" disabled>
← Prev
</button>
<div id="arrayContainer">
<div class="empty-state">
<div class="empty-state-text"></div>
</div>
</div>
<button class="btn" id="next" onclick="nextStep()" disabled>
Next →
</button>
</div>
<div class="step-info">
<div class="label">Current Step</div>
<div class="value">
<span id="stepNumber">0</span> / <span id="totalSteps">0</span>
</div>
</div>
<div class="status-message" id="statusMessage"></div>
</div>
<script src="./scripts/handler.js"></script>
<script src="./scripts/sortscript.js"></script>
</body>
</html>
<!-- DEBUG -->
<!-- Dropdown for sorting method -->
<!-- <select id="sortMethod">
<option value="bubble">Bubble Sort</option>
<option value="insertion">Insertion Sort</option>
<option value="selection">Selection Sort</option>
<option value="quick">Quick Sort</option>
<option value="merge">Merge Sort</option>
<option value="counting">Counting Sort</option>
<option value="radix">Radix Sort</option>
<option value="heap">Heap Sort</option>
<option value="bucket">Bucket Sort</option>
</select> -->
<!-- <input type="text" id="arrayInput" placeholder="Enter array (e.g. 5, 3, 8, 1, 2)" /> -->