-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
270 lines (241 loc) · 9.43 KB
/
Copy pathindex.html
File metadata and controls
270 lines (241 loc) · 9.43 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
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
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>CRSWRD</title>
<meta
name="description"
content="Build a crossword in seconds. Solve it right away."
/>
<link rel="stylesheet" href="styles.css" />
</head>
<body>
<a class="skip-link" href="#main">Skip to main content</a>
<header class="site-header">
<div class="container">
<div class="brand">
<div class="brand-text">
<h1 class="brand-title">CRSWRD</h1>
<p class="brand-subtitle">Build it. Solve it.</p>
</div>
<!-- Push actions to the right -->
<div class="brand-spacer" aria-hidden="true"></div>
<div class="brand-actions" aria-label="Header actions">
<button
id="themeToggleBtn"
class="btn-mini btn-theme"
type="button"
aria-label="Toggle theme"
aria-pressed="true"
title="Switch theme"
>
🌙 Dark
</button>
</div>
</div>
</div>
</header>
<main id="main" class="layout">
<!-- Left: Config panel (Phase 1 focus) -->
<section class="panel" aria-labelledby="config-title">
<h2 id="config-title" class="panel-title">Puzzle Settings</h2>
<p id="status" class="sr-only" role="status" aria-live="polite"></p>
<form
id="configForm"
class="config-form"
aria-describedby="config-help"
>
<fieldset class="fieldset">
<legend class="sr-only">Puzzle settings</legend>
<div class="field">
<label for="difficulty">Difficulty</label>
<select id="difficulty" name="difficulty" required>
<option value="easy">Easy</option>
<option value="medium" selected>Medium</option>
<option value="hard">Hard</option>
</select>
</div>
<div class="field">
<label for="pack">Pack</label>
<select id="pack" name="pack" required>
<option value="general" selected>General</option>
<option value="movies">Movies</option>
<option value="music">Music</option>
<option value="transportation">Transportation</option>
<option value="eighties">The 80's</option>
<option value="nineties">The 90's</option>
<option value="worldevents">21st Century</option>
<option value="sports">Sports</option>
<option value="holidays">Holidays</option>
<option value="animals">Animals</option>
<!-- Picks from all installed packs (now and future). -->
<option value="everything">Everything</option>
</select>
</div>
<div class="field">
<label for="tone">Tone</label>
<select id="tone" name="tone" required>
<option value="serious" selected>Serious</option>
<option value="funny">Funny</option>
<!-- Randomly picks Serious or Funny per puzzle. -->
<option value="random">Random</option>
</select>
</div>
<div class="field">
<label for="timeLength">Grid size</label>
<select id="timeLength" name="timeLength" required>
<option value="small">Small</option>
<option value="medium" selected>Medium</option>
<option value="large">Large</option>
</select>
</div>
<button id="generateBtn" type="submit" class="btn-primary">
Generate Puzzle
</button>
<div class="config-tips" aria-label="Tips">
<div class="config-tips-title">How to play</div>
<p id="config-help" class="helper">
Pick your settings, then click Generate Puzzle. Changes apply to
the next puzzle only.
</p>
<p class="helper helper-sub">
Click a cell and type. Backspace clears.
</p>
<p class="helper helper-sub">
Arrow keys move. Click the same cell to switch Across/Down.
</p>
<p class="helper helper-sub">
Press Tab to jump to the active clue.
</p>
</div>
</fieldset>
</form>
</section>
<!-- Right: App stage (placeholder for later phases) -->
<section class="stage" aria-label="Puzzle stage">
<!-- Mobile-only toggle -->
<button
id="toggleConfigBtn"
class="btn-secondary mobile-only"
type="button"
aria-expanded="true"
>
Puzzle settings
</button>
<!-- Hidden input used to trigger the on-screen keyboard on Android tablets.
Keep it near the keyboard button so the intent is obvious. -->
<input
id="mobileInput"
class="mobile-input"
type="text"
inputmode="text"
autocomplete="off"
autocapitalize="characters"
spellcheck="false"
aria-label="Crossword input"
/>
<!-- The stage card is the centered "play area" -->
<div class="stage-card">
<div class="stage-card-inner">
<div class="stage-top">
<!-- Touch devices: a way to bring the keyboard back without refreshing -->
<div
class="keyboard-bar touch-only"
aria-label="Keyboard controls"
>
<button
id="keyboardBtn"
class="btn-mini btn-keyboard"
type="button"
>
Keyboard
</button>
<span class="keyboard-hint"
>Tap to bring back the keyboard</span
>
</div>
<div class="gameplay-controls" aria-label="Gameplay controls">
<div class="control-group">
<button id="checkLetterBtn" class="btn-mini">
Check Letter
</button>
<button id="checkWordBtn" class="btn-mini">Check Word</button>
<button id="checkPuzzleBtn" class="btn-mini">
Check Puzzle
</button>
</div>
<div class="control-group">
<button id="revealLetterBtn" class="btn-mini">
Reveal Letter
</button>
<button id="revealWordBtn" class="btn-mini">
Reveal Word
</button>
<button id="revealPuzzleBtn" class="btn-mini">
Reveal Puzzle
</button>
</div>
<div class="control-group control-group-end">
<button id="resetPuzzleBtn" class="btn-mini">Reset</button>
<button id="newPuzzleBtn" class="btn-mini">New Puzzle</button>
</div>
<span
id="checkStatus"
class="check-status"
role="status"
aria-live="polite"
></span>
</div>
</div>
<div class="puzzle-layout" aria-label="Crossword puzzle">
<!-- Grid -->
<div class="puzzle-grid-wrap">
<div class="puzzle-bar" aria-label="Active selection">
<span id="activeDir" class="pill" aria-live="polite"
>Across</span
>
<span
id="activeClue"
class="puzzle-bar-text"
aria-live="polite"
>
Click any white cell to start.
</span>
<span
id="activeMeta"
class="puzzle-bar-meta"
aria-live="polite"
></span>
</div>
<div
id="crossword"
class="crossword"
role="grid"
aria-label="Crossword grid"
></div>
</div>
<!-- Clues -->
<aside class="clues" aria-label="Clues">
<div class="clues-section" aria-label="Across clues">
<h3 class="clues-title">Across</h3>
<ol id="acrossClues" class="clue-list"></ol>
</div>
<div class="clues-section" aria-label="Down clues">
<h3 class="clues-title">Down</h3>
<ol id="downClues" class="clue-list"></ol>
</div>
</aside>
</div>
</div>
</div>
</section>
</main>
<footer class="site-footer">
<div class="container">
🤖 Vibe-coded by The BIMsider & ChatGPT. Build it. Solve it.
</div>
</footer>
<script src="app.js"></script>
</body>
</html>