-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcavern.html
More file actions
64 lines (61 loc) · 2.53 KB
/
cavern.html
File metadata and controls
64 lines (61 loc) · 2.53 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>CodeQuest — Flexbox Caverns</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="/src/styles/input.css">
<link rel="stylesheet" href="/src/styles/output.css">
<link rel="stylesheet" href="/src/styles/main.css">
<link rel="stylesheet" href="/src/styles/style.css">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Tiny5&display=swap"
rel="stylesheet">
<style>
/* textarea { font-family: monospace; }
iframe { background: white; } */
</style>
</head>
<body class="bg-slate-950 text-slate-100 max-w-7xl mx-auto p-6 space-y-4">
<!-- Left Panel: Dialogue + Quest -->
<div class="bg-slate-900 p-4 overflow-y-auto">
<h1 class="text-xl font-bold mb-2">🌀 Flexbox Caverns</h1>
<div id="dialogueBox" class="mb-4 space-y-2"></div>
<div id="questBox">
<h2 id="questTitle" class="text-lg font-bold"></h2>
<p id="questText" class="mt-2"></p>
<button id="hintBtn"
class="mt-2 px-2 py-1 bg-emerald-500/80 text-slate-900 rounded">Hint</button>
<p id="hint" class="hidden text-emerald-300 mt-2"></p>
</div>
</div>
<div class="grid grid-cols-1 md:grid-cols-2 gap-4 ">
<!-- Middle Panel: Code Editor -->
<div class="bg-slate-950">
<textarea id="editor"
class="p-3 w-full h-96 bg-gray-800 text-green-300 font-mono rounded resize-none"></textarea>
</div>
<!-- Right Panel: Preview -->
<div class="bg-slate-800 p-2">
<iframe id="preview" class="w-full h-96 rounded"></iframe>
</div>
</div>
<!-- Controls -->
<div
class="bottom-0 left-0 right-0 bg-slate-900 p-2 flex justify-between">
<button id="prevBtn" class="px-3 py-1 bg-slate-700 rounded">⬅
Prev</button>
<div class="flex gap-2">
<button id="runBtn"
class="px-3 py-1 bg-sky-500 text-slate-900 rounded">Run</button>
<button id="submitBtn"
class="px-3 py-1 bg-emerald-500 text-slate-900 rounded">Submit</button>
<button id="nextBtn" class="px-3 py-1 bg-slate-600 rounded"
disabled>Next ➡</button>
</div>
</div>
<script src="car.js"></script>
</body>
</html>