@deep-podder/dsh-remote-mobile 0.0.6 → 0.0.7

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.
Files changed (45) hide show
  1. package/PROTOCOL.md +97 -9
  2. package/README.md +44 -9
  3. package/SECURITY.md +8 -0
  4. package/auth.js +16 -0
  5. package/bridge.js +336 -9
  6. package/docs/api-notes.md +12 -4
  7. package/docs/engineering-audit.md +252 -0
  8. package/docs/reference-chat-demo.md +41 -0
  9. package/docs/screenshots/chat-light.png +0 -0
  10. package/docs/screenshots/commands-dark.png +0 -0
  11. package/docs/screenshots/pairing-light.png +0 -0
  12. package/docs/screenshots/sessions-light.png +0 -0
  13. package/docs/verification.md +40 -4
  14. package/index.js +1 -1
  15. package/mobile/README.md +81 -35
  16. package/mobile/app.js +4268 -906
  17. package/mobile/index.html +28 -17
  18. package/mobile/lib/away.js +45 -0
  19. package/mobile/lib/constants.js +5 -0
  20. package/mobile/lib/errors.js +42 -0
  21. package/mobile/lib/format.js +94 -0
  22. package/mobile/lib/lock.js +21 -0
  23. package/mobile/manifest.webmanifest +24 -0
  24. package/mobile/mock-server.js +442 -17
  25. package/mobile/model/history.js +119 -0
  26. package/mobile/model/question.js +318 -0
  27. package/mobile/model/turns.js +57 -0
  28. package/mobile/styles/base.css +143 -0
  29. package/mobile/{styles.css → styles/components.css} +1170 -826
  30. package/mobile/styles/overrides.css +269 -0
  31. package/mobile/styles/tokens.css +169 -0
  32. package/mobile/sw.js +28 -4
  33. package/package.json +34 -20
  34. package/protocol.js +87 -0
  35. package/push-policy.js +58 -0
  36. package/server/frames/activity.js +110 -0
  37. package/server/frames/connection.js +21 -0
  38. package/server/frames/history.js +23 -0
  39. package/server/frames/interactions.js +77 -0
  40. package/server/frames/prompts.js +29 -0
  41. package/server/frames/queue.js +58 -0
  42. package/server/frames/sessions.js +201 -0
  43. package/server/frames/settings.js +38 -0
  44. package/server/frames/subagents.js +50 -0
  45. package/server.js +341 -423
@@ -0,0 +1,119 @@
1
+ // Durable transcript rows -> SPA items. Pure: no DOM and no app state.
2
+ import { MAX_TOOL_OUTPUT } from '../lib/constants.js?v=1';
3
+ import { normalizeQuestions, newQuestionDraft, parseQuestionOutput } from './question.js?v=1';
4
+
5
+ export function normalizeHistoryItem(raw) {
6
+ if (!raw || typeof raw !== 'object') return null;
7
+ var kind = raw.kind;
8
+ var ts = Number(raw.ts) || 0;
9
+ if (kind === 'user') {
10
+ var userAttachments = [];
11
+ if (Array.isArray(raw.attachments)) {
12
+ raw.attachments.forEach(function (attachment) {
13
+ if (!attachment || attachment.name === undefined) return;
14
+ var entry = {
15
+ name: String(attachment.name),
16
+ size: Number(attachment.size) || 0,
17
+ mediaType: attachment.mediaType ? String(attachment.mediaType) : '',
18
+ path: attachment.path ? String(attachment.path) : '',
19
+ relativePath: attachment.relativePath
20
+ ? String(attachment.relativePath)
21
+ : ''
22
+ };
23
+ userAttachments.push(entry);
24
+ });
25
+ }
26
+ return {
27
+ kind: 'user',
28
+ id: raw.id || 'u-' + ts,
29
+ text: raw.text == null ? '' : String(raw.text),
30
+ ts: ts,
31
+ attachments: userAttachments.length ? userAttachments : null
32
+ };
33
+ }
34
+ if (kind === 'assistant') {
35
+ return {
36
+ kind: 'assistant',
37
+ id: raw.id || 'a-' + ts,
38
+ text: raw.text == null ? '' : String(raw.text),
39
+ ts: ts
40
+ };
41
+ }
42
+ if (kind === 'tool') {
43
+ var rawQuestionPayload = raw.question;
44
+ var hasQuestionPayload =
45
+ rawQuestionPayload &&
46
+ (Array.isArray(rawQuestionPayload.questions)
47
+ ? rawQuestionPayload.questions.length > 0
48
+ : raw.name === 'ask_user_question');
49
+ if (rawQuestionPayload && hasQuestionPayload) {
50
+ var historyQuestions = normalizeQuestions(rawQuestionPayload.questions);
51
+ var parsedHistory = parseQuestionOutput(raw.output);
52
+ var historyPending =
53
+ !!parsedHistory && parsedHistory.pending === true && !!raw.callId;
54
+ var historyOutcome = raw.ok === false
55
+ ? 'unavailable'
56
+ : historyPending
57
+ ? 'pending'
58
+ : parsedHistory && parsedHistory.outcome === 'declined'
59
+ ? 'declined'
60
+ : parsedHistory && parsedHistory.outcome === 'unavailable'
61
+ ? 'unavailable'
62
+ : 'answered';
63
+ return {
64
+ kind: 'question',
65
+ id: raw.id || 'tool:' + (raw.callId || ts),
66
+ sessionId: null,
67
+ callId: raw.callId || raw.question.callId || null,
68
+ requestId: raw.requestId || raw.question.requestId || null,
69
+ title: raw.title || '',
70
+ questions: historyQuestions,
71
+ draft: newQuestionDraft(historyQuestions),
72
+ index: 0,
73
+ error: null,
74
+ continued: historyPending,
75
+ showPlan: false,
76
+ status: historyOutcome,
77
+ outcome: historyOutcome === 'pending' ? null : historyOutcome,
78
+ resolvedAnswers: parsedHistory ? parsedHistory.answers : null,
79
+ rawOutput: raw.output == null ? '' : String(raw.output).slice(0, MAX_TOOL_OUTPUT),
80
+ readOnly: historyOutcome !== 'pending',
81
+ fromHistory: true,
82
+ ts: ts
83
+ };
84
+ }
85
+ return {
86
+ kind: 'tool',
87
+ id: raw.id || 'tool:' + (raw.callId || ts),
88
+ callId: raw.callId || null,
89
+ name: raw.name || 'tool',
90
+ title: raw.title || '',
91
+ argsPreview: raw.argsPreview || '',
92
+ detail: raw.detail || null,
93
+ output: raw.output == null ? '' : String(raw.output).slice(0, MAX_TOOL_OUTPUT),
94
+ diff: raw.diff || null,
95
+ ok: raw.ok === undefined || raw.ok === null ? null : !!raw.ok,
96
+ durationMs:
97
+ typeof raw.durationMs === 'number' ? raw.durationMs : null,
98
+ ts: ts,
99
+ expanded: false
100
+ };
101
+ }
102
+ if (kind === 'error') {
103
+ return {
104
+ kind: 'error',
105
+ id: raw.id || 'e-' + ts,
106
+ text: raw.text == null ? '' : String(raw.text),
107
+ ts: ts
108
+ };
109
+ }
110
+ if (kind === 'system') {
111
+ return {
112
+ kind: 'system',
113
+ id: raw.id || 's-' + ts,
114
+ text: raw.text == null ? '' : String(raw.text),
115
+ ts: ts
116
+ };
117
+ }
118
+ return null;
119
+ }
@@ -0,0 +1,318 @@
1
+ // Question wire model: normalization, draft state and the answer batch rules.
2
+ // No DOM and no app state; the renderer in app.js owns presentation.
3
+
4
+ export const QUESTION_STATUS_READY = {
5
+ pending: true,
6
+ submitting: true,
7
+ waiting: true
8
+ };
9
+
10
+ export const QUESTION_RECOMMENDED_SUFFIX = /\s*(?:\((?:recommended|推荐)\)|((?:recommended|推荐)))\s*$/i;
11
+
12
+ export function normalizeQuestions(list) {
13
+ var out = [];
14
+ if (!Array.isArray(list)) return out;
15
+ list.forEach(function (raw, index) {
16
+ if (!raw || typeof raw !== 'object') return;
17
+ var id = raw.id === null || raw.id === undefined ? 'q' + index : String(raw.id);
18
+ var options = [];
19
+ (Array.isArray(raw.options) ? raw.options : []).forEach(function (opt) {
20
+ if (typeof opt === 'string') {
21
+ options.push({ label: opt, description: '' });
22
+ return;
23
+ }
24
+ if (!opt || opt.label === null || opt.label === undefined) return;
25
+ options.push({
26
+ label: String(opt.label),
27
+ description: opt.description ? String(opt.description) : ''
28
+ });
29
+ });
30
+ var question = {
31
+ id: id,
32
+ question: raw.question ? String(raw.question) : '',
33
+ header: raw.header ? String(raw.header) : '',
34
+ detail: raw.detail ? String(raw.detail) : '',
35
+ multiSelect: raw.multiSelect === true || raw.multi_select === true,
36
+ options: options
37
+ };
38
+ if (raw.intent && typeof raw.intent === 'object') {
39
+ question.intent = {
40
+ kind: raw.intent.kind ? String(raw.intent.kind) : '',
41
+ approve: raw.intent.approve ? String(raw.intent.approve) : '',
42
+ reject: raw.intent.reject ? String(raw.intent.reject) : '',
43
+ always: raw.intent.always ? String(raw.intent.always) : ''
44
+ };
45
+ }
46
+ out.push(question);
47
+ });
48
+ return out;
49
+ }
50
+
51
+ export function parseRecommendedLabel(label) {
52
+ var text = String(label === null || label === undefined ? '' : label);
53
+ if (QUESTION_RECOMMENDED_SUFFIX.test(text)) {
54
+ return { label: text.replace(QUESTION_RECOMMENDED_SUFFIX, ''), recommended: true };
55
+ }
56
+ return { label: text, recommended: false };
57
+ }
58
+
59
+ export function recommendedOptions(q) {
60
+ var labels = (q && q.options ? q.options : []).map(function (opt) {
61
+ return opt.label;
62
+ });
63
+ var candidates = q && q.multiSelect === true ? labels : labels.slice(0, 1);
64
+ return candidates.filter(function (label) {
65
+ return parseRecommendedLabel(label).recommended;
66
+ });
67
+ }
68
+
69
+ export function normalizeAnswers(list) {
70
+ var out = [];
71
+ if (!Array.isArray(list)) return out;
72
+ list.forEach(function (raw) {
73
+ if (!raw || typeof raw !== 'object') return;
74
+ if (raw.id === null || raw.id === undefined) return;
75
+ var selected = [];
76
+ if (Array.isArray(raw.selected)) {
77
+ raw.selected.forEach(function (label) {
78
+ if (label !== null && label !== undefined) selected.push(String(label));
79
+ });
80
+ } else if (typeof raw.selected === 'string' && raw.selected) {
81
+ selected.push(raw.selected);
82
+ }
83
+ var answer = { id: String(raw.id), selected: selected };
84
+ if (raw.custom !== null && raw.custom !== undefined && String(raw.custom).trim()) {
85
+ answer.custom = String(raw.custom);
86
+ }
87
+ out.push(answer);
88
+ });
89
+ return out;
90
+ }
91
+
92
+ export function parseQuestionOutput(output) {
93
+ if (output === null || output === undefined) return null;
94
+ var text = String(output).trim();
95
+ if (!text) return null;
96
+ var parsed = null;
97
+ try {
98
+ parsed = JSON.parse(text);
99
+ } catch (err) {
100
+ var braceStart = text.indexOf('{');
101
+ var braceEnd = text.lastIndexOf('}');
102
+ if (braceStart >= 0 && braceEnd > braceStart) {
103
+ try {
104
+ parsed = JSON.parse(text.slice(braceStart, braceEnd + 1));
105
+ } catch (err2) {
106
+ parsed = null;
107
+ }
108
+ }
109
+ if (!parsed) {
110
+ var arrStart = text.indexOf('[');
111
+ var arrEnd = text.lastIndexOf(']');
112
+ if (arrStart >= 0 && arrEnd > arrStart) {
113
+ try {
114
+ parsed = JSON.parse(text.slice(arrStart, arrEnd + 1));
115
+ } catch (err3) {
116
+ parsed = null;
117
+ }
118
+ }
119
+ }
120
+ }
121
+ if (parsed === null || parsed === undefined) return null;
122
+ var outcome = null;
123
+ var list = null;
124
+ /* A timed call whose foreground window closed records `{ pending: true }`;
125
+ it is still answerable through the call id, not an answered question. */
126
+ var pending = !!(parsed && typeof parsed === 'object' && parsed.pending === true);
127
+ if (Array.isArray(parsed)) {
128
+ list = parsed;
129
+ } else if (parsed && Array.isArray(parsed.answers)) {
130
+ list = parsed.answers;
131
+ if (parsed.outcome) outcome = String(parsed.outcome);
132
+ } else if (parsed && parsed.selected !== undefined) {
133
+ list = [parsed];
134
+ } else if (parsed && typeof parsed === 'object' && parsed.outcome) {
135
+ outcome = String(parsed.outcome);
136
+ }
137
+ return { answers: normalizeAnswers(list), outcome: outcome, pending: pending };
138
+ }
139
+
140
+ export function emptyQuestionDraft(q) {
141
+ return { selected: recommendedOptions(q), custom: '', skipped: false };
142
+ }
143
+
144
+ export function newQuestionDraft(questions) {
145
+ var draft = {};
146
+ (questions || []).forEach(function (q) {
147
+ draft[q.id] = emptyQuestionDraft(q);
148
+ });
149
+ return draft;
150
+ }
151
+
152
+ export function ensureQuestionDraft(item, q) {
153
+ if (!item.draft) item.draft = {};
154
+ if (!item.draft[q.id]) item.draft[q.id] = emptyQuestionDraft(q);
155
+ return item.draft[q.id];
156
+ }
157
+
158
+ export function answeredDraft(draft) {
159
+ return !!(
160
+ draft &&
161
+ ((draft.selected && draft.selected.length) ||
162
+ String(draft.custom || '').trim())
163
+ );
164
+ }
165
+
166
+ export function completedDraft(draft) {
167
+ return !!draft && (answeredDraft(draft) || draft.skipped === true);
168
+ }
169
+
170
+ export function questionIndex(item) {
171
+ var count = item.questions.length;
172
+ var index = typeof item.index === 'number' ? item.index : 0;
173
+ if (!Number.isFinite(index) || index < 0) index = 0;
174
+ if (index > count - 1) index = count - 1;
175
+ return count > 0 ? index : 0;
176
+ }
177
+
178
+ export function currentQuestion(item) {
179
+ return item.questions[questionIndex(item)] || null;
180
+ }
181
+
182
+ export function currentDraft(item) {
183
+ var q = currentQuestion(item);
184
+ return q ? ensureQuestionDraft(item, q) : null;
185
+ }
186
+
187
+ export function firstIncompleteQuestion(item) {
188
+ for (var i = 0; i < item.questions.length; i += 1) {
189
+ if (!completedDraft(ensureQuestionDraft(item, item.questions[i]))) return i;
190
+ }
191
+ return -1;
192
+ }
193
+
194
+ export function isQuestionReady(item) {
195
+ return !!(item && QUESTION_STATUS_READY[item.status]);
196
+ }
197
+
198
+ export function questionKey(item) {
199
+ if (item.requestId) return 'r:' + item.requestId;
200
+ if (item.callId) return 'c:' + item.callId;
201
+ return 'i:' + item.id;
202
+ }
203
+
204
+ export function firstQuestionText(questions) {
205
+ if (!questions || !questions.length) return 'Question from Harness';
206
+ return questions[0].question || 'Question from Harness';
207
+ }
208
+
209
+ export function formatQuestionsText(questions) {
210
+ return (questions || [])
211
+ .map(function (q, index) {
212
+ var lines = [index + 1 + '. ' + (q.question || 'Question')];
213
+ q.options.forEach(function (opt) {
214
+ lines.push(
215
+ ' - ' + opt.label + (opt.description ? ' — ' + opt.description : '')
216
+ );
217
+ });
218
+ return lines.join('\n');
219
+ })
220
+ .join('\n\n');
221
+ }
222
+
223
+ export function answerForQuestion(item, question, index) {
224
+ var answers = item.resolvedAnswers || [];
225
+ for (var i = 0; i < answers.length; i++) {
226
+ if (answers[i].id === question.id) return answers[i];
227
+ }
228
+ if (Number.isInteger(index) && answers[index]) return answers[index];
229
+ return null;
230
+ }
231
+
232
+ export function answerSummary(item, question, index) {
233
+ var answer = answerForQuestion(item, question, index);
234
+ if (!answer) {
235
+ if (item.outcome === 'declined') return 'Skipped';
236
+ if (item.outcome === 'unavailable' || item.outcome === 'continued') return 'No answer';
237
+ var draft = item.draft && item.draft[question.id];
238
+ if (draft && draft.skipped === true) return 'Skipped';
239
+ /* Only a live draft can stand in for a missing record; a settled card's
240
+ implicit recommended preselection is not what the user answered. */
241
+ if (draft && !item.readOnly) {
242
+ var parts = [];
243
+ if (draft.selected && draft.selected.length) {
244
+ parts.push(draft.selected.join(', '));
245
+ }
246
+ if (String(draft.custom || '').trim()) {
247
+ parts.push('Other: ' + String(draft.custom).trim());
248
+ }
249
+ if (parts.length) return parts.join(' · ');
250
+ }
251
+ return 'Answered';
252
+ }
253
+ var selected = [];
254
+ if (answer.selected && answer.selected.length) {
255
+ selected.push(answer.selected.join(', '));
256
+ }
257
+ if (answer.custom) selected.push('Other: ' + answer.custom);
258
+ return selected.length ? selected.join(' · ') : 'Skipped';
259
+ }
260
+
261
+ export function formatAnswersText(item) {
262
+ var lines = [];
263
+ (item.questions || []).forEach(function (q, index) {
264
+ lines.push(
265
+ index + 1 + '. ' + (q.question || 'Question') + '\n → ' + answerSummary(item, q, index)
266
+ );
267
+ });
268
+ if (!lines.length && item.resolvedAnswers && item.resolvedAnswers.length) {
269
+ item.resolvedAnswers.forEach(function (answer) {
270
+ var value = answer.selected.length
271
+ ? answer.selected.join(', ')
272
+ : answer.custom || 'Answered';
273
+ lines.push(answer.id + ': ' + value);
274
+ });
275
+ }
276
+ return lines.join('\n\n');
277
+ }
278
+
279
+ export function buildQuestionAnswers(item) {
280
+ return item.questions.map(function (q) {
281
+ var draft = ensureQuestionDraft(item, q);
282
+ if (draft.skipped === true) return { id: q.id, selected: [] };
283
+ var custom = String(draft.custom || '').trim();
284
+ var selected = (draft.selected || []).slice();
285
+ if (custom) {
286
+ return {
287
+ id: q.id,
288
+ selected: q.multiSelect === true ? selected : [],
289
+ custom: custom
290
+ };
291
+ }
292
+ return { id: q.id, selected: selected };
293
+ });
294
+ }
295
+
296
+ export function questionFeedback(item) {
297
+ return item.error ? String(item.error) : '';
298
+ }
299
+
300
+ export function questionFeedbackId(item) {
301
+ return 'qf-' + String(item.id).replace(/[^a-zA-Z0-9_-]/g, '');
302
+ }
303
+
304
+ export function planReviewOf(item) {
305
+ if (!item || item.questions.length !== 1) return null;
306
+ var q = item.questions[0];
307
+ var intent = q.intent;
308
+ if (!intent || intent.kind !== 'plan-review' || !q.detail) return null;
309
+ if (q.multiSelect === true) return null;
310
+ var options = q.options || [];
311
+ if (options.length > 2) return null;
312
+ var approve = null;
313
+ options.forEach(function (opt) {
314
+ if (opt.label === intent.approve) approve = opt;
315
+ });
316
+ if (!approve) return null;
317
+ return { question: q, approve: approve, plan: q.detail };
318
+ }
@@ -0,0 +1,57 @@
1
+ // Group transcript rows into renderable blocks. Pure: no DOM, no app state.
2
+ //
3
+ // A turn's tool rows are not guaranteed to follow the assistant message that
4
+ // owns them: DSH records `tool/start`/`tool/end` events as they happen and the
5
+ // assistant message row only when the turn's prose is known, so durable history
6
+ // usually arrives as `[tools..., assistant]` while a live stream produces
7
+ // `[assistant, tools...]`. Both orders must collapse into the same single turn
8
+ // disclosure, or every tool becomes its own card in the transcript.
9
+
10
+ /**
11
+ * @typedef {{ kind: 'item', item: object }} ItemBlock
12
+ * @typedef {{ kind: 'turn', assistant: object|null, tools: object[] }} TurnBlock
13
+ */
14
+
15
+ /**
16
+ * Split transcript rows into item blocks and turn blocks.
17
+ *
18
+ * A boundary row (user/question/approval/error/system) closes the current turn.
19
+ * Tools before their assistant row join it; tools after one stay with it; a
20
+ * sequence of tools with no assistant row at all becomes an assistant-less turn
21
+ * block (`assistant: null`) so it can still fold into one line.
22
+ *
23
+ * @param {readonly object[]} messages normalized transcript rows in order.
24
+ * @returns {(ItemBlock|TurnBlock)[]}
25
+ */
26
+ export function groupTurns(messages) {
27
+ /** @type {(ItemBlock|TurnBlock)[]} */
28
+ var blocks = []
29
+ /** @type {TurnBlock|null} */
30
+ var turn = null
31
+ var list = Array.isArray(messages) ? messages : []
32
+ for (var i = 0; i < list.length; i += 1) {
33
+ var message = list[i]
34
+ if (!message || typeof message !== 'object') continue
35
+ if (message.kind === 'tool') {
36
+ if (turn === null) {
37
+ turn = { kind: 'turn', assistant: null, tools: [] }
38
+ blocks.push(turn)
39
+ }
40
+ turn.tools.push(message)
41
+ continue
42
+ }
43
+ if (message.kind === 'assistant') {
44
+ if (turn !== null && turn.assistant === null) {
45
+ /* Durable ordering: the prose row closes a turn its tools opened. */
46
+ turn.assistant = message
47
+ } else {
48
+ turn = { kind: 'turn', assistant: message, tools: [] }
49
+ blocks.push(turn)
50
+ }
51
+ continue
52
+ }
53
+ turn = null
54
+ blocks.push({ kind: 'item', item: message })
55
+ }
56
+ return blocks
57
+ }
@@ -0,0 +1,143 @@
1
+ /* Reset, base elements and shared primitives. */
2
+
3
+ /* ---------- Reset / base ------------------------------------------------- */
4
+ *,
5
+ *::before,
6
+ *::after {
7
+ box-sizing: border-box;
8
+ }
9
+
10
+ html {
11
+ height: 100%;
12
+ background: var(--bg);
13
+ -webkit-text-size-adjust: 100%;
14
+ text-size-adjust: 100%;
15
+ }
16
+
17
+ body {
18
+ margin: 0;
19
+ min-height: 100%;
20
+ background: var(--bg);
21
+ color: var(--text);
22
+ font-family: var(--font-ui);
23
+ font-size: 15px;
24
+ line-height: 1.5;
25
+ letter-spacing: -0.005em;
26
+ overflow: hidden;
27
+ overscroll-behavior: none;
28
+ -webkit-font-smoothing: antialiased;
29
+ -moz-osx-font-smoothing: grayscale;
30
+ -webkit-tap-highlight-color: transparent;
31
+ }
32
+
33
+ button,
34
+ input,
35
+ textarea {
36
+ font: inherit;
37
+ color: inherit;
38
+ letter-spacing: inherit;
39
+ }
40
+
41
+ button {
42
+ margin: 0;
43
+ padding: 0;
44
+ border: 0;
45
+ background: none;
46
+ cursor: pointer;
47
+ touch-action: manipulation;
48
+ }
49
+
50
+ [hidden] {
51
+ display: none !important;
52
+ }
53
+
54
+ .mono {
55
+ font-family: var(--font-mono);
56
+ font-size: 0.92em;
57
+ letter-spacing: -0.01em;
58
+ }
59
+
60
+ /* Visually hidden but present for assistive technology (live region, labels). */
61
+ .visually-hidden:where(:not(:focus-within, :active)) {
62
+ position: absolute !important;
63
+ clip-path: inset(50%) !important;
64
+ overflow: hidden !important;
65
+ width: 1px !important;
66
+ height: 1px !important;
67
+ margin: -1px !important;
68
+ padding: 0 !important;
69
+ border: 0 !important;
70
+ white-space: nowrap !important;
71
+ }
72
+
73
+ :focus-visible {
74
+ outline: 2px solid var(--focus);
75
+ outline-offset: 2px;
76
+ }
77
+
78
+ ::selection {
79
+ background: var(--selection);
80
+ }
81
+
82
+ .sprite {
83
+ position: absolute;
84
+ width: 0;
85
+ height: 0;
86
+ overflow: hidden;
87
+ }
88
+
89
+ .icon {
90
+ display: block;
91
+ width: 22px;
92
+ height: 22px;
93
+ fill: none;
94
+ stroke: currentColor;
95
+ stroke-width: 1.7;
96
+ stroke-linecap: round;
97
+ stroke-linejoin: round;
98
+ flex: none;
99
+ }
100
+
101
+ .logo-mark {
102
+ display: grid;
103
+ place-items: center;
104
+ width: 52px;
105
+ height: 52px;
106
+ border-radius: 17px;
107
+ background: var(--pill);
108
+ color: var(--pill-ink);
109
+ box-shadow: var(--shadow-soft);
110
+ }
111
+
112
+ .logo-mark-lg {
113
+ width: 66px;
114
+ height: 66px;
115
+ border-radius: 21px;
116
+ }
117
+
118
+ .logo-glyph {
119
+ width: 28px;
120
+ height: 28px;
121
+ fill: none;
122
+ stroke: currentColor;
123
+ stroke-width: 1.9;
124
+ stroke-linecap: round;
125
+ stroke-linejoin: round;
126
+ }
127
+
128
+ .logo-mark-lg .logo-glyph {
129
+ width: 34px;
130
+ height: 34px;
131
+ }
132
+
133
+ .noscript {
134
+ position: fixed;
135
+ inset: auto 0 0;
136
+ z-index: 100;
137
+ margin: 0;
138
+ padding: 16px;
139
+ background: var(--danger);
140
+ color: #fff;
141
+ text-align: center;
142
+ font-weight: 600;
143
+ }