@glassly/miniapp-cli 0.1.10 → 0.1.11-dev.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +41 -0
- package/package.json +2 -1
- package/src/api.ts +11 -0
- package/src/dev.ts +7 -4
- package/src/sim/background-worker.ts +112 -0
- package/src/sim/background.ts +52 -0
- package/src/sim/client/app.css +450 -0
- package/src/sim/client/index.html +118 -0
- package/src/sim/client/main.ts +249 -0
- package/src/sim/control.ts +96 -0
- package/src/sim/device.test.ts +20 -0
- package/src/sim/device.ts +68 -0
- package/src/sim/host.test.ts +250 -0
- package/src/sim/host.ts +952 -0
- package/src/sim/screenshot.ts +61 -0
- package/src/sim/server.ts +412 -0
- package/src/sim/sim.ts +333 -0
- package/src/sim/storage.ts +46 -0
|
@@ -0,0 +1,450 @@
|
|
|
1
|
+
:root {
|
|
2
|
+
color-scheme: dark;
|
|
3
|
+
--ground: #101214;
|
|
4
|
+
--surface: #171a1d;
|
|
5
|
+
--raised: #1f2327;
|
|
6
|
+
--line: #2b3036;
|
|
7
|
+
--text: #e7e9ea;
|
|
8
|
+
--dim: #8b949c;
|
|
9
|
+
--ink: #00ff88;
|
|
10
|
+
--warn: #f0b429;
|
|
11
|
+
--bad: #ff6b5e;
|
|
12
|
+
--mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
* {
|
|
16
|
+
box-sizing: border-box;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
[hidden] {
|
|
20
|
+
display: none !important;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
html,
|
|
24
|
+
body {
|
|
25
|
+
height: 100%;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
body {
|
|
29
|
+
margin: 0;
|
|
30
|
+
display: grid;
|
|
31
|
+
grid-template-rows: auto minmax(0, 1fr) minmax(140px, 28vh);
|
|
32
|
+
background: var(--ground);
|
|
33
|
+
color: var(--text);
|
|
34
|
+
font: 13px/1.45 system-ui, -apple-system, "Segoe UI", sans-serif;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
button,
|
|
38
|
+
input {
|
|
39
|
+
font: inherit;
|
|
40
|
+
color: inherit;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.muted {
|
|
44
|
+
color: var(--dim);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.bar {
|
|
48
|
+
display: flex;
|
|
49
|
+
align-items: center;
|
|
50
|
+
justify-content: space-between;
|
|
51
|
+
gap: 16px;
|
|
52
|
+
padding: 8px 16px;
|
|
53
|
+
border-bottom: 1px solid var(--line);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.identity {
|
|
57
|
+
display: flex;
|
|
58
|
+
align-items: baseline;
|
|
59
|
+
gap: 10px;
|
|
60
|
+
min-width: 0;
|
|
61
|
+
white-space: nowrap;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.mark {
|
|
65
|
+
font-weight: 650;
|
|
66
|
+
letter-spacing: 0.01em;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.app-name {
|
|
70
|
+
padding-left: 10px;
|
|
71
|
+
border-left: 1px solid var(--line);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.bar-actions {
|
|
75
|
+
display: flex;
|
|
76
|
+
align-items: center;
|
|
77
|
+
gap: 12px;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.state {
|
|
81
|
+
font: 12px var(--mono);
|
|
82
|
+
color: var(--dim);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.state::before {
|
|
86
|
+
content: "";
|
|
87
|
+
display: inline-block;
|
|
88
|
+
width: 7px;
|
|
89
|
+
height: 7px;
|
|
90
|
+
margin-right: 6px;
|
|
91
|
+
border-radius: 50%;
|
|
92
|
+
background: var(--dim);
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.state[data-state="running"] {
|
|
96
|
+
color: var(--text);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.state[data-state="running"]::before {
|
|
100
|
+
background: var(--ink);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.state[data-state="crashed"],
|
|
104
|
+
.state[data-state="offline"] {
|
|
105
|
+
color: var(--bad);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.state[data-state="crashed"]::before,
|
|
109
|
+
.state[data-state="offline"]::before {
|
|
110
|
+
background: var(--bad);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.bench {
|
|
114
|
+
display: grid;
|
|
115
|
+
grid-template-columns: minmax(0, 1fr) auto;
|
|
116
|
+
gap: 20px;
|
|
117
|
+
min-height: 0;
|
|
118
|
+
padding: 16px;
|
|
119
|
+
overflow: auto;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
.glasses {
|
|
123
|
+
display: grid;
|
|
124
|
+
grid-template-columns: minmax(380px, 760px) minmax(280px, 1fr);
|
|
125
|
+
align-items: start;
|
|
126
|
+
gap: 20px;
|
|
127
|
+
min-width: 0;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.lens-wrap {
|
|
131
|
+
min-width: 0;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.lens {
|
|
135
|
+
position: relative;
|
|
136
|
+
aspect-ratio: 2 / 1;
|
|
137
|
+
border-radius: 10px;
|
|
138
|
+
background: #000;
|
|
139
|
+
outline: 1px solid var(--line);
|
|
140
|
+
overflow: hidden;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.lens canvas {
|
|
144
|
+
display: block;
|
|
145
|
+
width: 100%;
|
|
146
|
+
height: 100%;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.lens-note {
|
|
150
|
+
position: absolute;
|
|
151
|
+
inset: 0;
|
|
152
|
+
display: grid;
|
|
153
|
+
place-items: center;
|
|
154
|
+
color: var(--dim);
|
|
155
|
+
font: 12px var(--mono);
|
|
156
|
+
background: rgba(0, 0, 0, 0.7);
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
.lens-meta {
|
|
160
|
+
display: flex;
|
|
161
|
+
justify-content: space-between;
|
|
162
|
+
padding: 6px 2px 0;
|
|
163
|
+
font: 11px var(--mono);
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
.controls {
|
|
167
|
+
display: grid;
|
|
168
|
+
gap: 14px;
|
|
169
|
+
max-width: 520px;
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
fieldset {
|
|
173
|
+
margin: 0;
|
|
174
|
+
padding: 0;
|
|
175
|
+
border: 0;
|
|
176
|
+
min-width: 0;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
legend {
|
|
180
|
+
padding: 0 0 5px;
|
|
181
|
+
font-size: 11px;
|
|
182
|
+
text-transform: uppercase;
|
|
183
|
+
letter-spacing: 0.06em;
|
|
184
|
+
color: var(--dim);
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.keys,
|
|
188
|
+
.row {
|
|
189
|
+
display: flex;
|
|
190
|
+
gap: 6px;
|
|
191
|
+
align-items: center;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
.keys,
|
|
195
|
+
.row.wrap {
|
|
196
|
+
flex-wrap: wrap;
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
.row.wrap {
|
|
200
|
+
align-items: end;
|
|
201
|
+
row-gap: 8px;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
.row + .row {
|
|
205
|
+
margin-top: 6px;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
button {
|
|
209
|
+
padding: 5px 10px;
|
|
210
|
+
border: 1px solid var(--line);
|
|
211
|
+
border-radius: 6px;
|
|
212
|
+
background: var(--raised);
|
|
213
|
+
cursor: pointer;
|
|
214
|
+
white-space: nowrap;
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
button:hover {
|
|
218
|
+
border-color: #46505a;
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
button:active,
|
|
222
|
+
button.pressed {
|
|
223
|
+
background: #2a3138;
|
|
224
|
+
border-color: var(--ink);
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
button:focus-visible,
|
|
228
|
+
input:focus-visible {
|
|
229
|
+
outline: 2px solid var(--ink);
|
|
230
|
+
outline-offset: 1px;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
button.primary {
|
|
234
|
+
background: var(--ink);
|
|
235
|
+
border-color: var(--ink);
|
|
236
|
+
color: #04130b;
|
|
237
|
+
font-weight: 600;
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
button.quiet {
|
|
241
|
+
background: transparent;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
kbd {
|
|
245
|
+
margin-left: 4px;
|
|
246
|
+
padding: 0 4px;
|
|
247
|
+
border: 1px solid var(--line);
|
|
248
|
+
border-radius: 3px;
|
|
249
|
+
font: 10px var(--mono);
|
|
250
|
+
color: var(--dim);
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
input[type="text"],
|
|
254
|
+
input[type="number"] {
|
|
255
|
+
min-width: 0;
|
|
256
|
+
padding: 5px 8px;
|
|
257
|
+
border: 1px solid var(--line);
|
|
258
|
+
border-radius: 6px;
|
|
259
|
+
background: var(--surface);
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
#say-text,
|
|
263
|
+
#notify-content {
|
|
264
|
+
flex: 1;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
input[type="number"] {
|
|
268
|
+
width: 96px;
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
#battery {
|
|
272
|
+
width: 62px;
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
.field {
|
|
276
|
+
display: grid;
|
|
277
|
+
gap: 2px;
|
|
278
|
+
font-size: 11px;
|
|
279
|
+
color: var(--dim);
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
.field input {
|
|
283
|
+
color: var(--text);
|
|
284
|
+
font-size: 13px;
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
.check {
|
|
288
|
+
display: inline-flex;
|
|
289
|
+
align-items: center;
|
|
290
|
+
gap: 5px;
|
|
291
|
+
color: var(--dim);
|
|
292
|
+
white-space: nowrap;
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
.phone {
|
|
296
|
+
display: flex;
|
|
297
|
+
flex-direction: column;
|
|
298
|
+
align-items: center;
|
|
299
|
+
gap: 8px;
|
|
300
|
+
font-size: 12px;
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
.phone-body {
|
|
304
|
+
--scale: 0.7;
|
|
305
|
+
position: relative;
|
|
306
|
+
width: calc(393px * var(--scale));
|
|
307
|
+
height: calc(852px * var(--scale));
|
|
308
|
+
border-radius: calc(44px * var(--scale));
|
|
309
|
+
outline: 1px solid var(--line);
|
|
310
|
+
box-shadow: 0 0 0 calc(7px * var(--scale)) #050607;
|
|
311
|
+
background: #000;
|
|
312
|
+
overflow: hidden;
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
.phone-body iframe {
|
|
316
|
+
display: block;
|
|
317
|
+
width: 393px;
|
|
318
|
+
height: 852px;
|
|
319
|
+
border: 0;
|
|
320
|
+
transform: scale(var(--scale));
|
|
321
|
+
transform-origin: 0 0;
|
|
322
|
+
background: #fff;
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
.phone-empty {
|
|
326
|
+
position: absolute;
|
|
327
|
+
inset: 0;
|
|
328
|
+
display: grid;
|
|
329
|
+
place-items: center;
|
|
330
|
+
padding: 24px;
|
|
331
|
+
text-align: center;
|
|
332
|
+
color: var(--dim);
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
.phone a {
|
|
336
|
+
text-decoration: none;
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
.phone a:hover {
|
|
340
|
+
color: var(--text);
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
.panel {
|
|
344
|
+
display: grid;
|
|
345
|
+
grid-template-rows: auto minmax(0, 1fr);
|
|
346
|
+
min-height: 0;
|
|
347
|
+
border-top: 1px solid var(--line);
|
|
348
|
+
background: var(--surface);
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
.tabs {
|
|
352
|
+
display: flex;
|
|
353
|
+
align-items: center;
|
|
354
|
+
gap: 2px;
|
|
355
|
+
padding: 4px 10px 0;
|
|
356
|
+
border-bottom: 1px solid var(--line);
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
.tabs [role="tab"] {
|
|
360
|
+
border: 0;
|
|
361
|
+
border-bottom: 2px solid transparent;
|
|
362
|
+
border-radius: 0;
|
|
363
|
+
background: none;
|
|
364
|
+
color: var(--dim);
|
|
365
|
+
padding: 5px 10px 6px;
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
.tabs [role="tab"][aria-selected="true"] {
|
|
369
|
+
color: var(--text);
|
|
370
|
+
border-bottom-color: var(--ink);
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
.spacer {
|
|
374
|
+
flex: 1;
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
.tab {
|
|
378
|
+
margin: 0;
|
|
379
|
+
padding: 8px 14px;
|
|
380
|
+
overflow: auto;
|
|
381
|
+
font: 12px/1.5 var(--mono);
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
.log-line {
|
|
385
|
+
display: grid;
|
|
386
|
+
grid-template-columns: 62px 84px minmax(0, 1fr);
|
|
387
|
+
gap: 10px;
|
|
388
|
+
white-space: pre-wrap;
|
|
389
|
+
overflow-wrap: anywhere;
|
|
390
|
+
}
|
|
391
|
+
|
|
392
|
+
.log-line .time,
|
|
393
|
+
.log-line .source {
|
|
394
|
+
color: var(--dim);
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
.log-line[data-source="background"] .source {
|
|
398
|
+
color: #b79cf7;
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
.log-line[data-source="ui"] .source {
|
|
402
|
+
color: #6cc7e6;
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
.log-line[data-level="warn"] .message {
|
|
406
|
+
color: var(--warn);
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
.log-line[data-level="error"] .message {
|
|
410
|
+
color: var(--bad);
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
.state-grid {
|
|
414
|
+
display: grid;
|
|
415
|
+
grid-template-columns: max-content minmax(0, 1fr);
|
|
416
|
+
gap: 3px 18px;
|
|
417
|
+
align-content: start;
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
.state-grid dt {
|
|
421
|
+
color: var(--dim);
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
.state-grid dd {
|
|
425
|
+
margin: 0;
|
|
426
|
+
overflow-wrap: anywhere;
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
.state-grid .flag {
|
|
430
|
+
color: var(--warn);
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
@media (max-width: 1180px) {
|
|
434
|
+
.glasses {
|
|
435
|
+
grid-template-columns: minmax(0, 760px);
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
@media (max-width: 900px) {
|
|
440
|
+
body {
|
|
441
|
+
grid-template-rows: auto auto minmax(180px, 30vh);
|
|
442
|
+
height: auto;
|
|
443
|
+
min-height: 100%;
|
|
444
|
+
}
|
|
445
|
+
|
|
446
|
+
.bench {
|
|
447
|
+
grid-template-columns: minmax(0, 1fr);
|
|
448
|
+
overflow: visible;
|
|
449
|
+
}
|
|
450
|
+
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
|
+
<title>Glassly Simulator</title>
|
|
7
|
+
<link rel="stylesheet" href="/sim/app.css" />
|
|
8
|
+
</head>
|
|
9
|
+
<body>
|
|
10
|
+
<header class="bar">
|
|
11
|
+
<div class="identity">
|
|
12
|
+
<span class="mark">Glassly Simulator</span>
|
|
13
|
+
<span id="app-name" class="app-name"></span>
|
|
14
|
+
<span id="app-package" class="muted"></span>
|
|
15
|
+
</div>
|
|
16
|
+
<div class="bar-actions">
|
|
17
|
+
<span id="run-state" class="state" data-state="stopped">stopped</span>
|
|
18
|
+
<button id="restart" class="quiet" title="Restart the background script">Restart</button>
|
|
19
|
+
</div>
|
|
20
|
+
</header>
|
|
21
|
+
|
|
22
|
+
<main class="bench">
|
|
23
|
+
<section class="glasses" aria-label="Glasses">
|
|
24
|
+
<div class="lens-wrap">
|
|
25
|
+
<div class="lens" id="lens">
|
|
26
|
+
<canvas id="display" width="576" height="288"></canvas>
|
|
27
|
+
<div id="lens-note" class="lens-note" hidden></div>
|
|
28
|
+
</div>
|
|
29
|
+
<div class="lens-meta">
|
|
30
|
+
<span id="device-model"></span>
|
|
31
|
+
<span id="display-meta" class="muted"></span>
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
|
|
35
|
+
<div class="controls">
|
|
36
|
+
<fieldset>
|
|
37
|
+
<legend>Touch bar</legend>
|
|
38
|
+
<div class="keys">
|
|
39
|
+
<button data-touch="single_tap">Tap <kbd>T</kbd></button>
|
|
40
|
+
<button data-touch="double_tap">Double tap <kbd>D</kbd></button>
|
|
41
|
+
<button data-touch="triple_tap">Triple tap</button>
|
|
42
|
+
<button data-touch="long_press">Hold <kbd>H</kbd></button>
|
|
43
|
+
<button data-touch="swipe_up">Swipe up <kbd>↑</kbd></button>
|
|
44
|
+
<button data-touch="swipe_down">Swipe down <kbd>↓</kbd></button>
|
|
45
|
+
</div>
|
|
46
|
+
</fieldset>
|
|
47
|
+
<fieldset>
|
|
48
|
+
<legend>Head and button</legend>
|
|
49
|
+
<div class="keys">
|
|
50
|
+
<button data-touch="head_up">Look up <kbd>U</kbd></button>
|
|
51
|
+
<button data-touch="head_down">Look down <kbd>J</kbd></button>
|
|
52
|
+
<button data-button="short">Button <kbd>B</kbd></button>
|
|
53
|
+
<button data-button="long">Long button</button>
|
|
54
|
+
</div>
|
|
55
|
+
</fieldset>
|
|
56
|
+
<fieldset>
|
|
57
|
+
<legend>Speech heard by the glasses</legend>
|
|
58
|
+
<form id="say" class="row">
|
|
59
|
+
<input id="say-text" type="text" placeholder="Type what the wearer says" autocomplete="off" />
|
|
60
|
+
<input id="say-language" type="text" value="en-US" size="6" aria-label="Language" />
|
|
61
|
+
<label class="check"><input id="say-interim" type="checkbox" /> interim</label>
|
|
62
|
+
<button type="submit" class="primary">Say</button>
|
|
63
|
+
</form>
|
|
64
|
+
</fieldset>
|
|
65
|
+
<fieldset>
|
|
66
|
+
<legend>Phone and sensors</legend>
|
|
67
|
+
<div class="row wrap">
|
|
68
|
+
<label class="field">Glasses battery
|
|
69
|
+
<input id="battery" type="number" min="0" max="100" value="80" />
|
|
70
|
+
</label>
|
|
71
|
+
<label class="field">Latitude
|
|
72
|
+
<input id="lat" type="number" step="any" value="37.7749" />
|
|
73
|
+
</label>
|
|
74
|
+
<label class="field">Longitude
|
|
75
|
+
<input id="lng" type="number" step="any" value="-122.4194" />
|
|
76
|
+
</label>
|
|
77
|
+
<button id="send-location">Set location</button>
|
|
78
|
+
</div>
|
|
79
|
+
<div class="row wrap">
|
|
80
|
+
<label class="check"><input id="connected" type="checkbox" checked /> glasses connected</label>
|
|
81
|
+
<label class="check"><input id="light" type="checkbox" /> light phone theme</label>
|
|
82
|
+
<label class="check"><input id="aloud" type="checkbox" /> speak aloud</label>
|
|
83
|
+
</div>
|
|
84
|
+
<form id="notify" class="row">
|
|
85
|
+
<input id="notify-title" type="text" placeholder="Notification title" autocomplete="off" />
|
|
86
|
+
<input id="notify-content" type="text" placeholder="Notification text" autocomplete="off" />
|
|
87
|
+
<button type="submit">Notify</button>
|
|
88
|
+
</form>
|
|
89
|
+
</fieldset>
|
|
90
|
+
</div>
|
|
91
|
+
</section>
|
|
92
|
+
|
|
93
|
+
<section class="phone" aria-label="Phone">
|
|
94
|
+
<div class="phone-body" id="phone-body">
|
|
95
|
+
<iframe id="phone-frame" title="Miniapp phone page"></iframe>
|
|
96
|
+
<div id="phone-empty" class="phone-empty" hidden>This miniapp has no phone page.</div>
|
|
97
|
+
</div>
|
|
98
|
+
<a id="phone-link" class="muted" href="/ui/" target="_blank" rel="noopener">Open the phone page in its own tab</a>
|
|
99
|
+
</section>
|
|
100
|
+
</main>
|
|
101
|
+
|
|
102
|
+
<section class="panel">
|
|
103
|
+
<nav class="tabs" role="tablist">
|
|
104
|
+
<button role="tab" data-tab="log" aria-selected="true">Log</button>
|
|
105
|
+
<button role="tab" data-tab="scene" aria-selected="false">Scene</button>
|
|
106
|
+
<button role="tab" data-tab="state" aria-selected="false">State</button>
|
|
107
|
+
<span class="spacer"></span>
|
|
108
|
+
<label class="check"><input id="follow" type="checkbox" checked /> follow</label>
|
|
109
|
+
<button id="clear-log" class="quiet">Clear</button>
|
|
110
|
+
</nav>
|
|
111
|
+
<div id="tab-log" class="tab log" role="tabpanel"></div>
|
|
112
|
+
<pre id="tab-scene" class="tab" role="tabpanel" hidden></pre>
|
|
113
|
+
<div id="tab-state" class="tab state-grid" role="tabpanel" hidden></div>
|
|
114
|
+
</section>
|
|
115
|
+
|
|
116
|
+
<script type="module" src="/sim/app.js"></script>
|
|
117
|
+
</body>
|
|
118
|
+
</html>
|