Repository navigation
Expand file tree
/
Copy pathsidebar.html
More file actions
347 lines (314 loc) · 15.3 KB
/
Copy pathsidebar.html
File metadata and controls
347 lines (314 loc) · 15.3 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
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
<!DOCTYPE html>
<html lang="en" data-theme="dark">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Mazilla</title>
<link rel="stylesheet" href="sidebar.css" />
</head>
<body>
<div class="app">
<!-- Header -->
<header class="header">
<div class="logo">
<img src="icons/icon128.png" alt="Mazilla Logo" width="20" height="20" class="logo-image">
<span class="logo-text">Mazilla</span>
<span class="badge">v1.3</span>
</div>
<div class="header-actions">
<button class="icon-btn" id="theme-btn" type="button" title="Switch to light theme" aria-label="Switch theme">
<svg class="theme-icon theme-icon-light" width="15" height="15" viewBox="0 0 15 15" fill="none" aria-hidden="true">
<path d="M7.5 4.5a3 3 0 100 6 3 3 0 000-6zM6 7.5a1.5 1.5 0 113 0 1.5 1.5 0 01-3 0z" fill="currentColor"/>
<path d="M7.5 1a.75.75 0 01.75.75v.816a5.54 5.54 0 011.674.693l.577-.577a.75.75 0 011.06 1.06l-.576.578a5.54 5.54 0 01.693 1.674h.817a.75.75 0 010 1.5h-.817a5.54 5.54 0 01-.693 1.674l.576.577a.75.75 0 01-1.06 1.06l-.577-.576a5.54 5.54 0 01-1.674.693v.817a.75.75 0 01-1.5 0v-.817a5.54 5.54 0 01-1.674-.693l-.577.576a.75.75 0 01-1.06-1.06l.576-.577A5.54 5.54 0 012.566 8.31H1.75a.75.75 0 010-1.5h.816A5.54 5.54 0 013.26 5.136l-.576-.577a.75.75 0 011.06-1.06l.577.577A5.54 5.54 0 016 3.383V2.75A.75.75 0 017.5 1z" fill="currentColor"/>
</svg>
<svg class="theme-icon theme-icon-dark" width="15" height="15" viewBox="0 0 15 15" fill="none" aria-hidden="true">
<path d="M7.25 1.5a5.75 5.75 0 100 11.5 5.75 5.75 0 000-11.5zm0 1.5a4.25 4.25 0 000 8.5V3z" fill="currentColor"/>
</svg>
</button>
</div>
</header>
<!-- Nav Tabs -->
<nav class="nav-tabs">
<button class="tab-btn active" data-tab="autoclick">
<svg width="13" height="13" viewBox="0 0 13 13" fill="none">
<path d="M6.5 1L8 5H12L8.5 7.5L10 12L6.5 9.5L3 12L4.5 7.5L1 5H5L6.5 1Z" fill="currentColor"/>
</svg>
Autoclick
</button>
<button class="tab-btn" data-tab="forms">
<svg width="13" height="13" viewBox="0 0 13 13" fill="none">
<rect x="1" y="3" width="11" height="2" rx="1" fill="currentColor"/>
<rect x="1" y="7" width="8" height="2" rx="1" fill="currentColor"/>
<rect x="1" y="11" width="5" height="1.5" rx="0.75" fill="currentColor"/>
</svg>
Forms
</button>
<button class="tab-btn" data-tab="macros">
<svg width="13" height="13" viewBox="0 0 13 13" fill="none">
<rect x="1" y="1" width="11" height="11" rx="2" stroke="currentColor" stroke-width="1.2" fill="none"/>
<path d="M4 6.5L5.5 8L9 5" stroke="currentColor" stroke-width="1.4" stroke-linecap="round" stroke-linejoin="round"/>
</svg>
Macros
</button>
<button class="tab-btn" data-tab="clipboard">
<svg width="13" height="13" viewBox="0 0 13 13" fill="none">
<rect x="2.5" y="1.5" width="8" height="10" rx="1.2" stroke="currentColor" stroke-width="1.2" fill="none"/>
<rect x="4" y="0.5" width="5" height="2.5" rx="0.8" stroke="currentColor" stroke-width="1.2" fill="none"/>
</svg>
Clipboard
</button>
</nav>
<!-- Tab Content -->
<main class="tab-content">
<!-- AUTOCLICK TAB -->
<div class="tab-panel active" id="tab-autoclick">
<!-- Pick Target Section -->
<section class="section">
<div class="section-header">
<h2 class="section-title">Target Element</h2>
<span class="section-hint">Pick a button or element to auto-click</span>
</div>
<div class="pick-zone" id="pick-zone">
<div class="pick-icon">
<svg width="28" height="28" viewBox="0 0 28 28" fill="none">
<circle cx="14" cy="14" r="6" stroke="#00C2A8" stroke-width="1.5"/>
<line x1="14" y1="2" x2="14" y2="7" stroke="#00C2A8" stroke-width="1.5" stroke-linecap="round"/>
<line x1="14" y1="21" x2="14" y2="26" stroke="#00C2A8" stroke-width="1.5" stroke-linecap="round"/>
<line x1="2" y1="14" x2="7" y2="14" stroke="#00C2A8" stroke-width="1.5" stroke-linecap="round"/>
<line x1="21" y1="14" x2="26" y2="14" stroke="#00C2A8" stroke-width="1.5" stroke-linecap="round"/>
<circle cx="14" cy="14" r="2" fill="#00C2A8"/>
</svg>
</div>
<p class="pick-label" id="pick-label">No element selected</p>
<p class="pick-sub" id="pick-sub">Click "Pick Element" to target a button</p>
</div>
<div class="btn-row">
<button class="btn btn-primary" id="pick-btn">
<svg width="13" height="13" viewBox="0 0 13 13" fill="none">
<circle cx="6.5" cy="6.5" r="3" stroke="currentColor" stroke-width="1.3"/>
<line x1="6.5" y1="1" x2="6.5" y2="3" stroke="currentColor" stroke-width="1.3" stroke-linecap="round"/>
<line x1="6.5" y1="10" x2="6.5" y2="12" stroke="currentColor" stroke-width="1.3" stroke-linecap="round"/>
<line x1="1" y1="6.5" x2="3" y2="6.5" stroke="currentColor" stroke-width="1.3" stroke-linecap="round"/>
<line x1="10" y1="6.5" x2="12" y2="6.5" stroke="currentColor" stroke-width="1.3" stroke-linecap="round"/>
</svg>
Pick Element
</button>
<button class="btn btn-ghost" id="clear-btn" disabled>
<svg width="13" height="13" viewBox="0 0 13 13" fill="none">
<path d="M2 2L11 11M11 2L2 11" stroke="currentColor" stroke-width="1.4" stroke-linecap="round"/>
</svg>
Clear
</button>
</div>
<!-- Selector display -->
<div class="selector-display" id="selector-display" style="display:none;">
<label class="field-label">CSS Selector</label>
<div class="selector-row">
<code class="selector-code" id="selector-code"></code>
<button class="copy-btn" id="copy-selector" title="Copy selector">
<svg width="12" height="12" viewBox="0 0 12 12" fill="none">
<rect x="4" y="4" width="7" height="7" rx="1.5" stroke="currentColor" stroke-width="1.2"/>
<path d="M3 8H2a1 1 0 01-1-1V2a1 1 0 011-1h5a1 1 0 011 1v1" stroke="currentColor" stroke-width="1.2"/>
</svg>
</button>
</div>
</div>
</section>
<div class="divider"></div>
<!-- Interval Section -->
<section class="section">
<div class="section-header">
<h2 class="section-title">Click Interval</h2>
<span class="section-hint">How often to click the element</span>
</div>
<!-- Preset intervals -->
<div class="interval-presets">
<button class="preset-btn" data-value="500">0.5s</button>
<button class="preset-btn" data-value="1000">1s</button>
<button class="preset-btn active" data-value="2000">2s</button>
<button class="preset-btn" data-value="5000">5s</button>
<button class="preset-btn" data-value="10000">10s</button>
<button class="preset-btn" data-value="30000">30s</button>
</div>
<!-- Custom interval -->
<div class="custom-interval">
<label class="field-label">Custom interval</label>
<div class="input-row">
<input type="number" class="field-input" id="interval-input" value="2" min="0.1" step="0.1" placeholder="2" />
<select class="field-select" id="interval-unit">
<option value="1000">seconds</option>
<option value="60000">minutes</option>
<option value="1">milliseconds</option>
</select>
</div>
</div>
<!-- Max clicks -->
<div class="custom-interval">
<label class="field-label">Max clicks <span class="optional">(0 = unlimited)</span></label>
<input type="number" class="field-input" id="max-clicks" value="0" min="0" step="1" placeholder="0 = unlimited" />
</div>
</section>
<div class="divider"></div>
<!-- Control Section -->
<section class="section">
<div class="section-header">
<h2 class="section-title">Control</h2>
</div>
<div class="status-bar" id="status-bar">
<div class="status-dot" id="status-dot"></div>
<span id="status-text">Idle — no job running</span>
</div>
<div class="stats-row" id="stats-row" style="display:none;">
<div class="stat-card">
<span class="stat-val" id="stat-clicks">0</span>
<span class="stat-key">clicks</span>
</div>
<div class="stat-card">
<span class="stat-val" id="stat-next">--</span>
<span class="stat-key">next click</span>
</div>
<div class="stat-card">
<span class="stat-val" id="stat-elapsed">0s</span>
<span class="stat-key">elapsed</span>
</div>
</div>
<div class="btn-row control-btns">
<button class="btn btn-success" id="start-btn" disabled>
<svg width="12" height="12" viewBox="0 0 12 12" fill="none">
<path d="M3 2L10 6L3 10V2Z" fill="currentColor"/>
</svg>
Start
</button>
<button class="btn btn-danger" id="stop-btn" disabled>
<svg width="12" height="12" viewBox="0 0 12 12" fill="none">
<rect x="2.5" y="2.5" width="7" height="7" rx="1" fill="currentColor"/>
</svg>
Stop
</button>
</div>
</section>
<div class="divider"></div>
<!-- Saved Jobs -->
<section class="section">
<div class="section-header">
<h2 class="section-title">Saved Jobs</h2>
<button class="btn-link" id="save-job-btn" disabled>+ Save current</button>
</div>
<div id="saved-jobs-list" class="saved-list">
<p class="empty-msg">No saved jobs yet.</p>
</div>
</section>
</div>
<!-- FORMS TAB -->
<div class="tab-panel" id="tab-forms">
<section class="section">
<div class="section-header">
<h2 class="section-title">Capture Form Data</h2>
<span class="section-hint">Pick and fill forms automatically</span>
</div>
<div class="btn-row">
<button class="btn btn-primary" id="capture-form-btn">
<svg width="13" height="13" viewBox="0 0 13 13" fill="none">
<rect x="1" y="2" width="11" height="9" rx="1" stroke="currentColor" stroke-width="1.2" fill="none"/>
<circle cx="4" cy="4.5" r="1" fill="currentColor"/>
<path d="M1 7L4 5L7 8L12 2" stroke="currentColor" stroke-width="1.2" stroke-linecap="round" stroke-linejoin="round"/>
</svg>
Capture Form
</button>
</div>
</section>
<div class="divider"></div>
<section class="section">
<div class="section-header">
<h2 class="section-title">Form Templates</h2>
<span class="section-hint" id="forms-hint">No forms captured yet</span>
</div>
<div id="forms-list" class="saved-list">
<p class="empty-msg">No saved form templates yet. Capture a form to get started.</p>
</div>
</section>
</div>
<!-- CLIPBOARD TAB -->
<div class="tab-panel" id="tab-clipboard">
<section class="section">
<div class="section-header">
<h2 class="section-title">Add Value</h2>
<span class="section-hint">Save text to reuse in form fields</span>
</div>
<div class="clipboard-add-form">
<label class="field-label" for="clipboard-name-input">Label</label>
<input type="text" class="field-input" id="clipboard-name-input" placeholder="e.g. Email, Username" />
<label class="field-label" for="clipboard-value-input">Value</label>
<textarea class="field-input clipboard-value-input" id="clipboard-value-input" rows="3" placeholder="Text to insert into inputs"></textarea>
<button class="btn btn-primary clipboard-add-btn" id="clipboard-add-btn" type="button">
<svg width="13" height="13" viewBox="0 0 13 13" fill="none" aria-hidden="true">
<path d="M6.5 2v9M2 6.5h9" stroke="currentColor" stroke-width="1.4" stroke-linecap="round"/>
</svg>
Add to Clipboard
</button>
</div>
</section>
<div class="divider"></div>
<section class="section">
<div class="section-header">
<h2 class="section-title">Saved Values</h2>
<span class="section-hint" id="clipboard-hint">Focus a field on the page, then insert</span>
</div>
<div id="clipboard-list" class="saved-list">
<p class="empty-msg">No saved values yet. Add one above to get started.</p>
</div>
</section>
</div>
<!-- MACROS TAB -->
<div class="tab-panel" id="tab-macros">
<section class="section">
<div class="section-header">
<h2 class="section-title">Macro Recorder</h2>
<span class="section-hint">Record and replay action sequences</span>
</div>
<div class="macro-controls">
<button class="btn btn-primary" id="record-macro-btn">
<svg width="12" height="12" viewBox="0 0 12 12" fill="none">
<circle cx="6" cy="6" r="4" fill="currentColor"/>
</svg>
Start Recording
</button>
<button class="btn btn-danger" id="stop-record-btn" disabled style="display:none;">
<svg width="12" height="12" viewBox="0 0 12 12" fill="none">
<rect x="2" y="2" width="8" height="8" rx="1" fill="currentColor"/>
</svg>
Stop Recording
</button>
</div>
<div class="macro-status" id="macro-status" style="display:none;">
<div class="status-bar">
<div class="status-dot recording"></div>
<span id="macro-status-text">Recording...</span>
</div>
<div class="macro-events" id="macro-events">
<p class="empty-msg">No events recorded yet</p>
</div>
</div>
</section>
<div class="divider"></div>
<section class="section">
<div class="section-header">
<h2 class="section-title">Saved Macros</h2>
<span class="section-hint" id="macros-hint">No macros saved yet</span>
</div>
<div id="macros-list" class="saved-list">
<p class="empty-msg">No saved macros yet. Record a macro to get started.</p>
</div>
</section>
</div>
</main>
<!-- Footer -->
<footer class="footer">
<span>Mazilla</span>
<span class="footer-dot">·</span>
<span>Page Automation</span>
</footer>
</div>
<script src="sidebar.js"></script>
</body>
</html>