Construct the Auth tab's assistant — the markup was emitted but never wired

This commit is contained in:
Gmer4Lfe
2026-08-14 23:53:17 -04:00
parent 0101aef51a
commit bb7c112a2d
+21
View File
@@ -1092,6 +1092,27 @@ document.getElementById('vv-au-cert-run').addEventListener('click', function() {
_loadCerts(() => { btn.disabled = false; btn.textContent = 'Refresh'; }); _loadCerts(() => { btn.disabled = false; btn.textContent = 'Refresh'; });
}); });
// ── Assistant ────────────────────────────────────────────────────────────────
// vv_ai_chat_markup() emits markup and nothing else — the instance has to be constructed here,
// as every other placement does. Without this the card renders complete and is entirely inert:
// the profile chip has no label because applyProfile() never ran, and clicking it does nothing
// because the picker was never wired.
//
// Guarded on the element because the card is behind vv_ai_ui_on(), so on a node with no reachable
// model this block finds nothing and does nothing rather than throwing on a missing prefix.
if (document.getElementById('vv-au-ai-chat')) {
VvAiChat({
prefix: 'vv-au-ai',
profile: 'varaverk',
scopeLabel: 'Auth',
scope: () => 'Auth',
// Pinned, like the other cards: without it this resumes whatever thread was last open
// anywhere, which could land the card mid-conversation under a profile this tab never offers.
resumeProfile: 'varaverk',
empty: 'Ask about a proxy host, a rule, a group, or why a login is being refused.',
});
}
// ── Boot ────────────────────────────────────────────────────────────────────── // ── Boot ──────────────────────────────────────────────────────────────────────
_loadProxies(); _loadProxies();