773 lines
50 KiB
HTML
773 lines
50 KiB
HTML
{{/*
|
|
Chat surface (Phase 1 bridge).
|
|
Server renders the page shell with full SPA scaffold.
|
|
Existing SPA JS (app.js, ui-core.js, chat.js, etc.) populates
|
|
these pre-built DOM elements with data.
|
|
|
|
v0.22.6 fix: The original index.html contained the full scaffold
|
|
(1,296 lines). When it was replaced with a redirect stub, this
|
|
template needed the scaffold — but it was shipped empty.
|
|
This template restores the required DOM structure.
|
|
*/}}
|
|
|
|
{{define "surface-chat"}}
|
|
|
|
{{/* ── Splash / Auth Gate ───────────────────────
|
|
Server-rendered surfaces use /login for auth, so the splash
|
|
is hidden by default. Kept as a DOM node so showSplash()/
|
|
hideSplash() in app.js don't crash on null. */}}
|
|
<div id="splashGate" class="splash" style="display:none;">
|
|
<div class="splash-hero">
|
|
<div id="brandHeadline" class="splash-title"></div>
|
|
<div id="brandTagline" class="splash-subtitle"></div>
|
|
<div id="brandPills" class="splash-pills"></div>
|
|
</div>
|
|
<div class="splash-auth">
|
|
<div id="splashError" class="splash-error" style="display:none;"></div>
|
|
<div class="auth-tabs">
|
|
<button id="authTabLogin" class="auth-tab active" onclick="switchAuthTab('login')">Sign In</button>
|
|
<button id="authTabRegister" class="auth-tab" onclick="switchAuthTab('register')">Register</button>
|
|
</div>
|
|
<div id="authLoginForm">
|
|
<input type="text" id="authLogin" placeholder="Username or email" autocomplete="username">
|
|
<input type="password" id="authPassword" placeholder="Password" autocomplete="current-password">
|
|
<button id="authLoginBtn" onclick="handleLogin()">Sign In</button>
|
|
</div>
|
|
<div id="authRegisterForm" style="display:none;">
|
|
<input type="text" id="authUsername" placeholder="Username" autocomplete="username">
|
|
<input type="text" id="authEmail" placeholder="Email" autocomplete="email">
|
|
<input type="password" id="authRegPassword" placeholder="Password" autocomplete="new-password">
|
|
<button id="authRegisterBtn" onclick="handleRegister()">Create Account</button>
|
|
</div>
|
|
<div id="authError" class="auth-error"></div>
|
|
<div id="brandAuthFooter" class="auth-footer"></div>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* ── Crash Catcher (visible without devtools) ── */}}
|
|
<div id="crashBanner" style="display:none;position:fixed;top:0;left:0;right:0;z-index:99999;background:#b00020;color:#fff;padding:12px 20px;font-family:monospace;font-size:13px;max-height:40vh;overflow-y:auto;">
|
|
<strong>⚠ Init Error</strong> <button onclick="this.parentElement.style.display='none'" style="float:right;background:none;border:1px solid #fff;color:#fff;cursor:pointer;padding:2px 8px;border-radius:3px">✕</button>
|
|
<pre id="crashDetail" style="margin:8px 0 0;white-space:pre-wrap;font-size:12px;"></pre>
|
|
</div>
|
|
<script nonce="{{$.CSPNonce}}">
|
|
window.addEventListener('error', function(e) {
|
|
var b = document.getElementById('crashBanner');
|
|
var d = document.getElementById('crashDetail');
|
|
if (b && d) {
|
|
b.style.display = '';
|
|
d.textContent += (e.filename || '') + ':' + (e.lineno || '') + ' ' + (e.message || e) + '\n';
|
|
}
|
|
});
|
|
window.addEventListener('unhandledrejection', function(e) {
|
|
var b = document.getElementById('crashBanner');
|
|
var d = document.getElementById('crashDetail');
|
|
if (b && d) {
|
|
b.style.display = '';
|
|
d.textContent += 'Promise: ' + (e.reason?.message || e.reason || 'unknown') + '\n' + (e.reason?.stack || '') + '\n';
|
|
}
|
|
});
|
|
</script>
|
|
|
|
{{/* ── App Container ───────────────────────── */}}
|
|
<div id="appContainer" class="app" style="display:none;height:100%;">
|
|
|
|
{{/* Fallback banner (admin-only, shown by Events role.fallback) */}}
|
|
<div id="roleFallbackBanner" class="role-fallback-banner" style="display:none;"></div>
|
|
|
|
<div class="app-body">
|
|
|
|
{{/* ── Sidebar ─────────────────────── */}}
|
|
<div id="sidebar" class="sidebar">
|
|
<div class="sidebar-top">
|
|
{{/* Brand — click toggles sidebar */}}
|
|
<div class="sb-brand" onclick="UI.toggleSidebar()" role="button" tabindex="0">
|
|
<div id="brandSidebarLogo" class="sb-logo">
|
|
<img src="{{.BasePath}}/favicon-32.png" alt="" class="brand-logo-img">
|
|
</div>
|
|
<span id="brandSidebarText" class="brand-text">Switchboard</span>
|
|
<span id="brandWordmark" class="brand-text" style="display:none;"></span>
|
|
</div>
|
|
|
|
{{/* New Chat button */}}
|
|
<button id="newChatBtn" class="sb-btn" onclick="newChat()" title="New chat">
|
|
<svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><line x1="12" y1="5" x2="12" y2="19"/><line x1="5" y1="12" x2="19" y2="12"/></svg>
|
|
<span class="sb-label">New Chat</span>
|
|
</button>
|
|
</div>
|
|
|
|
{{/* Search (outside sidebar-top, below brand section) */}}
|
|
<div id="sidebarSearch" class="sidebar-search">
|
|
<svg class="search-icon" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="11" cy="11" r="8"/><line x1="21" y1="21" x2="16.65" y2="16.65"/></svg>
|
|
<input type="text" id="chatSearchInput" placeholder="Search chats…" autocomplete="off">
|
|
<button id="chatSearchClear" class="sidebar-search-clear" title="Clear search">✕</button>
|
|
</div>
|
|
|
|
{{/* Sidebar toggle (hidden on desktop, used by JS for mobile) */}}
|
|
<button id="sidebarToggle" class="sb-btn sidebar-toggle" title="Toggle sidebar">
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><line x1="3" y1="6" x2="21" y2="6"/><line x1="3" y1="12" x2="21" y2="12"/><line x1="3" y1="18" x2="21" y2="18"/></svg>
|
|
</button>
|
|
|
|
{{/* Sidebar Tabs (Chats / Files) */}}
|
|
{{/* Sidebar Tabs (kept hidden — only Files tab used by EditorMode) */}}
|
|
<div id="sidebarTabs" class="sidebar-tabs" style="display:none;">
|
|
<button class="sidebar-tab active" data-tab="chats">Chats</button>
|
|
<button id="sidebarFilesTab" class="sidebar-tab" data-tab="files" style="display:none;">Files</button>
|
|
</div>
|
|
|
|
{{/* Three-section nav: Projects / Channels / Chats */}}
|
|
<div id="sidebarNav" class="sidebar-nav sidebar-tab-panel" data-tab-panel="chats">
|
|
{{/* Projects section */}}
|
|
<div class="sb-section" id="sbSectionProjects">
|
|
<div class="sb-section-header" onclick="UI.toggleSidebarSection('projects')">
|
|
<span class="sb-section-arrow" id="sbArrowProjects">▾</span>
|
|
<span class="sb-section-label">Projects</span>
|
|
<button class="sb-section-add" title="New project"
|
|
onclick="event.stopPropagation();if(typeof createProject==='function')createProject();">
|
|
<svg width="11" height="11" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><line x1="12" y1="5" x2="12" y2="19"/><line x1="5" y1="12" x2="19" y2="12"/></svg>
|
|
</button>
|
|
</div>
|
|
<div class="sb-section-body" id="sbBodyProjects">
|
|
{{/* Populated by UI.renderProjectsSection() */}}
|
|
</div>
|
|
</div>
|
|
|
|
{{/* Channels section (DMs + named channels) */}}
|
|
<div class="sb-section" id="sbSectionChannels">
|
|
<div class="sb-section-header" onclick="UI.toggleSidebarSection('channels')">
|
|
<span class="sb-section-arrow" id="sbArrowChannels">▾</span>
|
|
<span class="sb-section-label">Channels</span>
|
|
<button class="sb-section-add" title="New channel"
|
|
onclick="event.stopPropagation();newChannelOrDM();">
|
|
<svg width="11" height="11" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><line x1="12" y1="5" x2="12" y2="19"/><line x1="5" y1="12" x2="19" y2="12"/></svg>
|
|
</button>
|
|
</div>
|
|
<div class="sb-section-body" id="sbBodyChannels">
|
|
{{/* Populated by UI.renderChannelsSection() */}}
|
|
</div>
|
|
</div>
|
|
|
|
{{/* Chats section (personal AI chats + folders) */}}
|
|
<div class="sb-section" id="sbSectionChats">
|
|
<div class="sb-section-header" onclick="UI.toggleSidebarSection('chats')">
|
|
<span class="sb-section-arrow" id="sbArrowChats">▾</span>
|
|
<span class="sb-section-label">Chats</span>
|
|
<div class="sb-section-add-group" onclick="event.stopPropagation();">
|
|
<button class="sb-section-add" title="New chat" onclick="newChat();">
|
|
<svg width="11" height="11" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><line x1="12" y1="5" x2="12" y2="19"/><line x1="5" y1="12" x2="19" y2="12"/></svg>
|
|
</button>
|
|
<button class="sb-section-add" title="New folder" onclick="newFolder();">
|
|
<svg width="11" height="11" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z"/></svg>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
<div class="sb-section-body" id="sbBodyChats"
|
|
ondragover="event.preventDefault();event.dataTransfer.dropEffect='move';this.classList.add('drag-over')"
|
|
ondragleave="this.classList.remove('drag-over')"
|
|
ondrop="onChatSectionDrop(event)">
|
|
{{/* Populated by UI.renderChatList() */}}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* Legacy chatHistory id kept for JS compatibility during transition */}}
|
|
<div id="chatHistory" style="display:none;"></div>
|
|
|
|
{{/* Files panel (editor mode) */}}
|
|
<div class="sidebar-tab-panel" data-tab-panel="files" style="display:none;"></div>
|
|
|
|
{{/* User / bottom */}}
|
|
<div class="sidebar-bottom">
|
|
{{if .SurfaceEnabled "notes"}}
|
|
<button id="notesBtn" class="sb-btn sidebar-notes-btn">
|
|
<svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/><polyline points="14 2 14 8 20 8"/><line x1="16" y1="13" x2="8" y2="13"/><line x1="16" y1="17" x2="8" y2="17"/></svg>
|
|
<span class="sb-label">Notes</span>
|
|
</button>
|
|
{{end}}
|
|
{{if .SurfaceEnabled "editor"}}
|
|
<a href="{{.BasePath}}/editor" class="sb-btn sidebar-editor-btn" title="Editor">
|
|
<svg width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><polyline points="16 18 22 12 16 6"/><polyline points="8 6 2 12 8 18"/></svg>
|
|
<span class="sb-label">Editor</span>
|
|
</a>
|
|
{{end}}
|
|
<div class="sidebar-bottom-divider"></div>
|
|
{{template "user-menu" dict "ID" ""}}
|
|
</div>
|
|
</div>
|
|
|
|
{{/* Sidebar overlay (mobile) */}}
|
|
<div id="sidebarOverlay" class="sidebar-overlay" style="display:none;"></div>
|
|
|
|
{{/* Mobile menu button */}}
|
|
<button id="mobileMenuBtn" class="mobile-menu-btn">
|
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><line x1="3" y1="6" x2="21" y2="6"/><line x1="3" y1="12" x2="21" y2="12"/><line x1="3" y1="18" x2="21" y2="18"/></svg>
|
|
</button>
|
|
|
|
{{/* ── Workspace ───────────────────── */}}
|
|
<div class="workspace">
|
|
<div class="workspace-primary workspace-pane">
|
|
|
|
{{/* Chat header: model selector + caps + tokens + panel + notif */}}
|
|
<div class="chat-header">
|
|
{{template "model-selector" dict "ID" ""}}
|
|
<div class="chat-header-right">
|
|
<span id="chatTokenCount" class="token-count" title="Estimated token count"></span>
|
|
<span id="summarizedHistory" class="summarized-badge" style="display:none;" title="Earlier messages are summarized">📋 Summarized</span>
|
|
<button id="summarizeBtn" class="action-btn" style="display:none;" title="Summarize older messages">
|
|
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/><polyline points="14 2 14 8 20 8"/><line x1="16" y1="13" x2="8" y2="13"/><line x1="16" y1="17" x2="8" y2="17"/></svg>
|
|
</button>
|
|
{{/* Panel toggle */}}
|
|
<button id="panelToggleBtn" class="action-btn" title="Toggle side panel" onclick="if(typeof PanelRegistry!=='undefined')PanelRegistry.toggle('preview')">
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="3" y="3" width="18" height="18" rx="2"/><line x1="15" y1="3" x2="15" y2="21"/></svg>
|
|
</button>
|
|
{{/* Notification bell (inline, not fixed) */}}
|
|
<div id="notifWrap" class="notif-wrap">
|
|
<button class="notif-bell" onclick="Notifications.toggleDropdown()">
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9"/><path d="M13.73 21a2 2 0 0 1-3.46 0"/></svg>
|
|
<span id="notifBadge" class="notif-badge" style="display:none;">0</span>
|
|
</button>
|
|
<div id="notifDropdown" class="notif-dropdown" style="display:none;">
|
|
<div id="notifPanelList"></div>
|
|
<div id="notifPanelMore" style="text-align:center;padding:8px;"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* v0.23.2: Channel context banner — shown for DMs and named channels */}}
|
|
<div id="channelContextBanner" class="channel-context-banner" style="display:none;"></div>
|
|
|
|
{{/* Messages */}}
|
|
<div id="chatMessages" class="msg-container">
|
|
{{/* Populated by UI.renderMessages() */}}
|
|
</div>
|
|
|
|
{{/* Context warning */}}
|
|
<div id="contextWarning" class="context-warning" style="display:none;">
|
|
<span id="contextWarningText"></span>
|
|
</div>
|
|
|
|
{{/* File strip */}}
|
|
<div id="fileStrip" class="file-strip"></div>
|
|
|
|
{{/* Streaming tools display */}}
|
|
<div id="streamTools" class="stream-tools" style="display:none;"></div>
|
|
|
|
{{/* Input area (centered, padded bottom) */}}
|
|
<div class="chat-input-area">
|
|
{{/* Input toolbar (attach, tools toggle, KB) */}}
|
|
<div class="input-toolbar">
|
|
<button id="attachBtn" class="action-btn attach-btn" title="Attach file">
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M21.44 11.05l-9.19 9.19a6 6 0 0 1-8.49-8.49l9.19-9.19a4 4 0 0 1 5.66 5.66l-9.2 9.19a2 2 0 0 1-2.83-2.83l8.49-8.48"/></svg>
|
|
</button>
|
|
{{/* Tools toggle */}}
|
|
<div class="tools-toggle-wrap" style="display:none;">
|
|
<button id="toolsToggleBtn" class="action-btn tools-toggle-btn" title="Tools">
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><polyline points="16 18 22 12 16 6"/><polyline points="8 6 2 12 8 18"/></svg>
|
|
</button>
|
|
<div id="toolsPopup" class="popup tools-popup"></div>
|
|
</div>
|
|
{{/* Knowledge Bases toggle */}}
|
|
<div class="kb-toggle-wrap">
|
|
<button id="kbToggleBtn" class="action-btn kb-toggle-btn" title="Knowledge Bases">
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M4 19.5A2.5 2.5 0 0 1 6.5 17H20"/><path d="M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z"/></svg>
|
|
</button>
|
|
<div id="kbPopup" class="popup kb-popup"></div>
|
|
</div>
|
|
{{/* tools-toggle.js + knowledge-ui.js show/populate these at init */}}
|
|
</div>
|
|
|
|
{{/* Input wrap: CM6 editor + send/stop */}}
|
|
<div class="input-wrap">
|
|
<div id="messageInputWrap">
|
|
{{/* CM6 mounts here (chat.js). Fallback textarea below. */}}
|
|
<textarea id="messageInput" placeholder="Type a message…" rows="1"></textarea>
|
|
</div>
|
|
<div class="input-actions">
|
|
<span id="inputTokenCount" class="input-token-count"></span>
|
|
<button id="sendBtn" class="action-btn send-btn" title="Send message">
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><line x1="22" y1="2" x2="11" y2="13"/><polygon points="22 2 15 22 11 13 2 9 22 2"/></svg>
|
|
</button>
|
|
<button id="stopBtn" class="action-btn stop-btn" title="Stop generating">
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="3" y="3" width="18" height="18" rx="2" ry="2"/></svg>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="chat-footer">
|
|
<span class="chat-version">Switchboard v{{.Version}}</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* Resize handle */}}
|
|
<div id="workspaceHandle" class="workspace-handle"></div>
|
|
|
|
{{/* Side panel (secondary pane) */}}
|
|
<div id="workspaceSecondary" class="workspace-secondary workspace-pane">
|
|
<div class="side-panel-header">
|
|
<span id="sidePanelLabel" class="side-panel-label"></span>
|
|
<div class="side-panel-header-actions">
|
|
<span id="sidePanelPanelActions"></span>
|
|
<button id="sidePanelFullscreenBtn" class="side-panel-btn" title="Toggle fullscreen" onclick="toggleSidePanelFullscreen()">
|
|
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><polyline points="15 3 21 3 21 9"/><polyline points="9 21 3 21 3 15"/><line x1="21" y1="3" x2="14" y2="10"/><line x1="3" y1="21" x2="10" y2="14"/></svg>
|
|
</button>
|
|
<button class="side-panel-btn" title="Close panel" onclick="PanelRegistry.closeAll()">
|
|
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><line x1="18" y1="6" x2="6" y2="18"/><line x1="6" y1="6" x2="18" y2="18"/></svg>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
<div id="sidePanelBody" class="side-panel-body">
|
|
{{/* Preview panel page */}}
|
|
<div id="sidePanelPreview" class="side-panel-page">
|
|
<iframe id="previewFrame" class="preview-frame" sandbox="allow-scripts allow-same-origin" style="display:none;"></iframe>
|
|
<div id="previewEmpty" class="preview-empty">
|
|
<p>Open a code block preview or extension output here.</p>
|
|
</div>
|
|
</div>
|
|
{{/* Notes and project panels are registered dynamically by their JS modules */}}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* Side panel overlay (mobile) */}}
|
|
<div id="sidePanelOverlay" class="side-panel-overlay" style="display:none;"></div>
|
|
|
|
{{/* ── Toast Container ─────────────────────── */}}
|
|
<div id="toastContainer" class="toast-container"></div>
|
|
|
|
{{/* ── Lightbox ────────────────────────────── */}}
|
|
<div id="lightbox" class="lightbox" onclick="closeLightbox()">
|
|
<img id="lightboxImg" src="" alt="">
|
|
</div>
|
|
|
|
{{/* ── Command Palette ─────────────────────── */}}
|
|
<div id="cmdPalette" class="cmd-palette" style="display:none;">
|
|
<div class="cmd-palette-inner">
|
|
<input type="text" class="cmd-palette-input" placeholder="Type a command…" autocomplete="off">
|
|
<div class="cmd-palette-results"></div>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* ── Hidden File Input ─────── */}}
|
|
<input type="file" id="fileInput" multiple style="display:none;">
|
|
|
|
{{/* ── Settings Modal ──────────────────────── */}}
|
|
<div id="settingsModal" class="modal-overlay">
|
|
<div class="modal-content modal-lg">
|
|
<div class="modal-header">
|
|
<h2>Settings</h2>
|
|
<button id="settingsCloseBtn" class="modal-close" onclick="closeModal('settingsModal')">✕</button>
|
|
</div>
|
|
<div class="modal-tabs">
|
|
<button class="settings-tab active" data-stab="general" onclick="UI.switchSettingsTab('general')">General</button>
|
|
<button class="settings-tab" data-stab="appearance" onclick="UI.switchSettingsTab('appearance')">Appearance</button>
|
|
<button id="settingsProvidersTabBtn" class="settings-tab" data-stab="providers" onclick="UI.switchSettingsTab('providers')">My Providers</button>
|
|
<button id="settingsPersonasTabBtn" class="settings-tab" data-stab="personas" onclick="UI.switchSettingsTab('personas')">My Personas</button>
|
|
<button id="settingsUsageTabBtn" class="settings-tab" data-stab="usage" onclick="UI.switchSettingsTab('usage')">Usage</button>
|
|
<button class="settings-tab" data-stab="profile" onclick="UI.switchSettingsTab('profile')">Profile</button>
|
|
<button id="settingsRolesTabBtn" class="settings-tab" data-stab="roles" onclick="UI.switchSettingsTab('roles')" style="display:none;">Roles</button>
|
|
<button id="settingsKBTabBtn" class="settings-tab" data-stab="kb" onclick="UI.switchSettingsTab('kb')" style="display:none;">Knowledge</button>
|
|
<button id="settingsTeamsSection" class="settings-tab" data-stab="teams" onclick="UI.switchSettingsTab('teams')">Teams</button>
|
|
</div>
|
|
<div class="modal-body">
|
|
{{/* General tab */}}
|
|
<div id="settingsGeneralTab" class="settings-tab-content" style="display:block;">
|
|
<div class="form-group">
|
|
<label>Model</label>
|
|
<select id="settingsModel"></select>
|
|
</div>
|
|
<div class="form-group">
|
|
<label>System Prompt</label>
|
|
<textarea id="settingsSystemPrompt" rows="4"></textarea>
|
|
</div>
|
|
<div class="form-group">
|
|
<label>Max Tokens <span id="settingsMaxHint" class="form-hint"></span></label>
|
|
<input type="number" id="settingsMaxTokens" placeholder="default">
|
|
</div>
|
|
<div class="form-group">
|
|
<label>Temperature</label>
|
|
<input type="range" id="settingsTemp" min="0" max="2" step="0.1" value="0.7">
|
|
</div>
|
|
<div class="form-group">
|
|
<label><input type="checkbox" id="settingsThinking"> Show thinking blocks</label>
|
|
</div>
|
|
</div>
|
|
{{/* Appearance tab */}}
|
|
<div id="settingsAppearanceTab" class="settings-tab-content" style="display:none;">
|
|
<div class="form-group">
|
|
<label>Message Font Size</label>
|
|
<div style="display:flex;align-items:center;gap:8px;">
|
|
<input type="range" id="settingsMsgFont" min="12" max="20" step="1" value="14">
|
|
<span id="msgFontValue">14px</span>
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<label>UI Scale</label>
|
|
<div style="display:flex;align-items:center;gap:8px;">
|
|
<input type="range" id="settingsScale" min="0.8" max="1.2" step="0.05" value="1.0">
|
|
<span id="scaleValue">100%</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{{/* Providers tab */}}
|
|
<div id="settingsProvidersTab" class="settings-tab-content" style="display:none;">
|
|
<div id="userProvidersDisabled" class="notice" style="display:none;">Personal API keys are not enabled by your administrator.</div>
|
|
<button id="providerShowAddBtn" class="btn-small" style="display:none;">+ Add Provider</button>
|
|
<div id="providerAddForm" style="display:none;"></div>
|
|
<div id="providerList"></div>
|
|
</div>
|
|
{{/* Personas tab */}}
|
|
<div id="settingsPersonasTab" class="settings-tab-content" style="display:none;">
|
|
<button id="userAddPersonaBtn" class="btn-small" style="display:none;">+ New Persona</button>
|
|
<div id="userAddPersonaForm" style="display:none;"></div>
|
|
<div id="userPersonaList"></div>
|
|
</div>
|
|
{{/* Usage tab */}}
|
|
<div id="settingsUsageTab" class="settings-tab-content" style="display:none;">
|
|
<div id="myUsageTotals"></div>
|
|
</div>
|
|
{{/* Profile tab */}}
|
|
<div id="settingsProfileTab" class="settings-tab-content" style="display:none;">
|
|
<div class="form-group">
|
|
<label>Avatar</label>
|
|
<div style="display:flex;align-items:center;gap:12px;margin-bottom:4px;">
|
|
<div id="avatarPreview" class="user-avatar" style="width:48px;height:48px;font-size:20px;">
|
|
<span id="avatarPreviewLetter">?</span>
|
|
</div>
|
|
<div style="display:flex;gap:6px;">
|
|
<button id="avatarUploadBtn" class="btn-small">Upload</button>
|
|
<button id="avatarRemoveBtn" class="btn-small btn-danger" style="display:none;">Remove</button>
|
|
</div>
|
|
<input type="file" id="avatarFileInput" accept="image/*" style="display:none;">
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<label>Display Name</label>
|
|
<input type="text" id="profileDisplayName">
|
|
</div>
|
|
<div class="form-group">
|
|
<label>Email</label>
|
|
<input type="email" id="profileEmail" disabled>
|
|
</div>
|
|
<div class="form-group">
|
|
<button id="profileChangePwBtn" class="btn-small">Change Password</button>
|
|
<div id="profileChangePwForm" style="display:none;margin-top:8px;">
|
|
<input type="password" id="profileCurrentPw" placeholder="Current password" autocomplete="current-password" style="margin-bottom:6px;">
|
|
<input type="password" id="profileNewPw" placeholder="New password" autocomplete="new-password" style="margin-bottom:6px;">
|
|
<input type="password" id="profileConfirmPw" placeholder="Confirm new password" autocomplete="new-password" style="margin-bottom:6px;">
|
|
<button id="profileSavePwBtn" class="btn-small">Update Password</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{{/* Roles tab (admin) */}}
|
|
<div id="settingsRolesTab" class="settings-tab-content" style="display:none;">
|
|
<div id="userRolesDisabled" class="notice" style="display:none;"></div>
|
|
<div id="userRolesConfig"></div>
|
|
<div id="userModelList"></div>
|
|
</div>
|
|
{{/* KB tab */}}
|
|
<div id="settingsKBTab" class="settings-tab-content" style="display:none;">
|
|
<div id="kbManagePanel"></div>
|
|
</div>
|
|
{{/* Teams tab */}}
|
|
<div id="settingsTeamsTab" class="settings-tab-content" style="display:none;">
|
|
<div id="settingsTeamsList"></div>
|
|
<div id="settingsTeamMembers" style="display:none;"></div>
|
|
<div id="settingsTeamPersonas" style="display:none;">
|
|
<div id="teamPersonaList"></div>
|
|
</div>
|
|
<div id="settingsTeamProviders" style="display:none;">
|
|
<button id="settingsTeamAddProviderBtn" class="btn-small" style="display:none;">+ Add Provider</button>
|
|
<div id="settingsTeamProviderForm" style="display:none;"></div>
|
|
</div>
|
|
<div id="settingsTeamGroups" style="display:none;"></div>
|
|
<div id="settingsTeamAudit" style="display:none;"></div>
|
|
<div id="settingsTeamUsageTotals" style="display:none;"></div>
|
|
</div>
|
|
{{/* Memory tab */}}
|
|
<div id="settingsMemoryTab" class="settings-tab-content" style="display:none;">
|
|
<div id="settingsMemoryContent"></div>
|
|
</div>
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button id="settingsSaveBtn" class="btn-primary" onclick="UI.saveSettingsAndClose()">Save</button>
|
|
<button class="btn-secondary" onclick="closeModal('settingsModal')">Cancel</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* ── Admin Panel (SPA modal — fallback, admin surface is preferred) */}}
|
|
<div id="adminPanel" class="modal-overlay">
|
|
<div class="modal-content modal-xl">
|
|
<div class="modal-header">
|
|
<h2>Admin</h2>
|
|
<button class="modal-close" onclick="closeModal('adminPanel')">✕</button>
|
|
</div>
|
|
<div class="modal-body" style="display:flex;min-height:400px;">
|
|
<div id="adminSidebar" class="admin-sidebar"></div>
|
|
<div class="admin-content" style="flex:1;overflow-y:auto;padding:16px;">
|
|
{{/* Admin sections — dynamically shown/hidden by ui-admin.js */}}
|
|
<div id="adminStats" class="admin-section"></div>
|
|
<div id="adminModelList" class="admin-section" style="display:none;"></div>
|
|
<div id="adminProviderList" class="admin-section" style="display:none;"></div>
|
|
<div id="adminUserList" class="admin-section" style="display:none;"></div>
|
|
<div id="adminTeamList" class="admin-section" style="display:none;"></div>
|
|
<div id="adminHealthContent" class="admin-section" style="display:none;">
|
|
<button id="adminHealthRefreshBtn" class="btn-small">Refresh</button>
|
|
</div>
|
|
<div id="adminRolesContent" class="admin-section" style="display:none;"></div>
|
|
<div id="adminCapabilityList" class="admin-section" style="display:none;"></div>
|
|
<div id="adminExtensionsList" class="admin-section" style="display:none;"></div>
|
|
<div id="adminPricingTable" class="admin-section" style="display:none;"></div>
|
|
<div id="adminAuditList" class="admin-section" style="display:none;">
|
|
<div style="display:flex;gap:8px;margin-bottom:8px;">
|
|
<select id="auditFilterAction"><option value="">All actions</option></select>
|
|
<select id="auditFilterResource"><option value="">All resources</option></select>
|
|
</div>
|
|
<div id="auditPagination" style="display:flex;gap:8px;align-items:center;">
|
|
<button id="auditPrevBtn" class="btn-small" disabled>← Prev</button>
|
|
<span id="auditPageInfo"></span>
|
|
<button id="auditNextBtn" class="btn-small">Next →</button>
|
|
</div>
|
|
</div>
|
|
<div id="adminStorageContent" class="admin-section" style="display:none;"></div>
|
|
<div id="adminRoutingPolicyList" class="admin-section" style="display:none;">
|
|
<button id="adminAddRoutingPolicyBtn" class="btn-small">+ Add Policy</button>
|
|
<div id="adminRoutingForm" style="display:none;"></div>
|
|
<div style="margin-top:16px;border-top:1px solid var(--border);padding-top:16px;">
|
|
<h4>Test Routing</h4>
|
|
<div style="display:flex;gap:8px;align-items:center;flex-wrap:wrap;">
|
|
<input type="text" id="routingTestModel" placeholder="Model ID">
|
|
<input type="text" id="routingTestUser" placeholder="User ID (optional)">
|
|
<button id="routingTestBtn" class="btn-small">Test</button>
|
|
</div>
|
|
<pre id="routingTestResult" style="margin-top:8px;font-size:12px;"></pre>
|
|
</div>
|
|
</div>
|
|
<div id="adminUsageResults" class="admin-section" style="display:none;">
|
|
<div id="adminUsageTotals"></div>
|
|
<div id="_adminUsageContainer"></div>
|
|
</div>
|
|
{{/* Settings admin section */}}
|
|
<div class="admin-section" style="display:none;">
|
|
<div class="form-group"><label><input type="checkbox" id="adminRegToggle"> Registration Enabled</label></div>
|
|
<div class="form-group"><label>Default User State</label><select id="adminRegDefaultState"><option value="active">Active</option><option value="pending">Pending Approval</option></select></div>
|
|
<div class="form-group"><label><input type="checkbox" id="adminUserProvidersToggle"> Allow User BYOK</label></div>
|
|
<div class="form-group"><label><input type="checkbox" id="adminUserPersonasToggle"> Allow User Personas</label></div>
|
|
<div class="form-group"><label><input type="checkbox" id="adminKBDirectAccessToggle"> KB Direct Access</label></div>
|
|
<div class="form-group"><label>Default Model</label><select id="adminDefaultModel"></select></div>
|
|
<div class="form-group"><label>System Prompt</label><textarea id="adminSystemPrompt" rows="4"></textarea></div>
|
|
<div class="form-group"><label><input type="checkbox" id="adminBannerEnabled"> Banner</label></div>
|
|
<div id="bannerConfigFields" style="display:none;">
|
|
<input type="text" id="adminBannerText" placeholder="Banner text">
|
|
<div style="display:flex;gap:8px;margin-top:6px;">
|
|
<input type="color" id="adminBannerBg" value="#007a33"><input type="text" id="adminBannerBgHex" value="#007a33" style="width:80px;">
|
|
<input type="color" id="adminBannerFg" value="#ffffff"><input type="text" id="adminBannerFgHex" value="#ffffff" style="width:80px;">
|
|
</div>
|
|
<div id="bannerPreview" class="banner-preview" style="margin-top:8px;"></div>
|
|
</div>
|
|
<div class="form-group"><label><input type="checkbox" id="adminMemoryExtractionEnabled"> Memory Extraction</label></div>
|
|
<div id="memoryExtractionConfigFields" style="display:none;">
|
|
<label><input type="checkbox" id="adminMemoryAutoApprove"> Auto-approve</label>
|
|
</div>
|
|
<div class="form-group"><label><input type="checkbox" id="adminCompactionEnabled"> Auto-Compaction</label></div>
|
|
<div id="compactionConfigFields" style="display:none;">
|
|
<label>Threshold <input type="number" id="adminCompactionThreshold" value="100000"></label>
|
|
<label>Cooldown <input type="number" id="adminCompactionCooldown" value="3600"></label>
|
|
</div>
|
|
<div class="form-group">
|
|
<label>Web Search</label>
|
|
<select id="adminSearchProvider"><option value="">Disabled</option><option value="searxng">SearXNG</option></select>
|
|
<div id="searxngConfigFields" style="display:none;">
|
|
<input type="text" id="adminSearchEndpoint" placeholder="SearXNG URL">
|
|
<input type="text" id="adminSearchApiKey" placeholder="API key (optional)">
|
|
<input type="number" id="adminSearchMaxResults" placeholder="Max results" value="5">
|
|
</div>
|
|
</div>
|
|
<button id="adminRunCleanup" class="btn-small btn-danger" style="margin-top:12px;">Run Cleanup</button>
|
|
<div id="adminVaultStatus" style="margin-top:12px;"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* ── Team Admin Modal ────────────────────── */}}
|
|
<div id="teamAdminModal" class="modal-overlay">
|
|
<div class="modal-content modal-lg" style="max-width:900px;height:80vh;display:flex;flex-direction:column;">
|
|
<div class="modal-header" style="flex-shrink:0;">
|
|
<h2 id="teamAdminTitle">Team Admin</h2>
|
|
<button id="teamAdminCloseBtn" class="modal-close">✕</button>
|
|
</div>
|
|
<div class="modal-body" style="display:flex;flex:1;min-height:0;padding:0;">
|
|
{{/* Team picker (multi-team admins) */}}
|
|
<div id="teamAdminPicker" style="padding:20px;flex:1;overflow-y:auto;">
|
|
<div id="teamAdminPickerList"></div>
|
|
</div>
|
|
|
|
{{/* Tabbed team management */}}
|
|
<div id="teamAdminContent" style="display:none;flex:1;display:flex;flex-direction:column;min-width:0;">
|
|
{{/* Tab bar */}}
|
|
<div id="teamAdminTabs" style="display:flex;gap:2px;padding:8px 16px;border-bottom:1px solid var(--border);flex-shrink:0;overflow-x:auto;">
|
|
<button class="admin-tab active" data-ttab="members" onclick="UI.switchTeamTab('members')">Members</button>
|
|
<button class="admin-tab" data-ttab="providers" onclick="UI.switchTeamTab('providers')">Providers</button>
|
|
<button class="admin-tab" data-ttab="personas" onclick="UI.switchTeamTab('personas')">Personas</button>
|
|
<button class="admin-tab" data-ttab="knowledge" onclick="UI.switchTeamTab('knowledge')">Knowledge</button>
|
|
<button class="admin-tab" data-ttab="groups" onclick="UI.switchTeamTab('groups')">Groups</button>
|
|
<button class="admin-tab" data-ttab="settings" onclick="UI.switchTeamTab('settings')">Settings</button>
|
|
<button class="admin-tab" data-ttab="usage" onclick="UI.switchTeamTab('usage')">Usage</button>
|
|
<button class="admin-tab" data-ttab="activity" onclick="UI.switchTeamTab('activity')">Activity</button>
|
|
</div>
|
|
|
|
{{/* Tab content panels */}}
|
|
<div style="flex:1;overflow-y:auto;padding:16px;">
|
|
{{/* Members */}}
|
|
<div id="teamTabMembers" class="team-tab-content">
|
|
<div id="settingsTeamMembers"></div>
|
|
<div id="settingsTeamAddMember" class="admin-inline-form" style="display:none;margin-top:12px;">
|
|
<div style="display:flex;gap:8px;align-items:flex-end;">
|
|
<div class="form-group" style="flex:1"><label>User</label><select id="settingsTeamMemberUser"><option value="">Select user...</option></select></div>
|
|
<div class="form-group"><label>Role</label><select id="settingsTeamMemberRole"><option value="member">Member</option><option value="admin">Admin</option></select></div>
|
|
<button class="btn-small btn-primary" id="settingsTeamAddMemberSubmit">Add</button>
|
|
<button class="btn-small" onclick="document.getElementById('settingsTeamAddMember').style.display='none'">Cancel</button>
|
|
</div>
|
|
</div>
|
|
<button class="btn-small" id="settingsTeamAddMemberBtn" style="margin-top:8px">+ Add Member</button>
|
|
</div>
|
|
|
|
{{/* Providers */}}
|
|
<div id="teamTabProviders" class="team-tab-content" style="display:none;">
|
|
<div id="settingsTeamProviders"></div>
|
|
<div id="settingsTeamProviderForm" style="display:none;margin-top:12px;"></div>
|
|
<button class="btn-small" id="settingsTeamAddProviderBtn" style="margin-top:8px">+ Add Provider</button>
|
|
</div>
|
|
|
|
{{/* Personas */}}
|
|
<div id="teamTabPersonas" class="team-tab-content" style="display:none;">
|
|
<div id="teamPersonaList"></div>
|
|
<div id="settingsTeamPersonas" style="display:none;"></div>
|
|
<div style="display:none;"><select id="teamPersona_model"></select></div>
|
|
</div>
|
|
|
|
{{/* Knowledge */}}
|
|
<div id="teamTabKnowledge" class="team-tab-content" style="display:none;">
|
|
<div id="teamKBContent"></div>
|
|
</div>
|
|
|
|
{{/* Groups */}}
|
|
<div id="teamTabGroups" class="team-tab-content" style="display:none;">
|
|
<div id="settingsTeamGroups"></div>
|
|
</div>
|
|
|
|
{{/* Settings */}}
|
|
<div id="teamTabSettings" class="team-tab-content" style="display:none;">
|
|
<div style="max-width:500px;">
|
|
<div class="form-group" style="margin-bottom:12px;">
|
|
<label class="toggle-label"><input type="checkbox" id="teamSettingPrivatePolicy"><span class="toggle-track"></span><span>Require private providers (BYOK)</span></label>
|
|
<div class="toggle-hint">Team members must use their own API keys</div>
|
|
</div>
|
|
<div class="form-group" style="margin-bottom:12px;">
|
|
<label class="toggle-label"><input type="checkbox" id="teamSettingAllowProviders" checked><span class="toggle-track"></span><span>Allow team providers</span></label>
|
|
<div class="toggle-hint">Team admins can add shared provider configs</div>
|
|
</div>
|
|
<button class="btn-small btn-primary" id="teamSettingSaveBtn">Save Settings</button>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* Usage */}}
|
|
<div id="teamTabUsage" class="team-tab-content" style="display:none;">
|
|
<div id="settingsTeamUsageTotals"></div>
|
|
</div>
|
|
|
|
{{/* Activity (Audit) */}}
|
|
<div id="teamTabActivity" class="team-tab-content" style="display:none;">
|
|
<div style="margin-bottom:8px;">
|
|
<select id="teamAuditFilterAction" style="font-size:12px;padding:4px 8px;"><option value="">All actions</option></select>
|
|
</div>
|
|
<div id="settingsTeamAudit"></div>
|
|
<div id="teamAuditPagination" style="display:flex;gap:8px;align-items:center;margin-top:8px;">
|
|
<button id="teamAuditPrevBtn" class="btn-small" disabled>← Prev</button>
|
|
<span id="teamAuditPageInfo" class="text-muted" style="font-size:12px;"></span>
|
|
<button id="teamAuditNextBtn" class="btn-small">Next →</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* ── Debug Modal moved to base.html (available on all surfaces) ── */}}
|
|
|
|
{{/* ── Notification bell is now inside .chat-header ── */}}
|
|
|
|
{{/* ── Routing Policy Form (shared) ────────── */}}
|
|
<div id="routingPolicyForm" style="display:none;">
|
|
<input type="hidden" id="rpId">
|
|
<div class="form-group"><label>Name</label><input type="text" id="rpName"></div>
|
|
<div class="form-group"><label>Priority</label><input type="number" id="rpPriority" value="100"></div>
|
|
<div class="form-group"><label>Type</label><select id="rpType"><option value="weighted">Weighted</option><option value="failover">Failover</option><option value="round_robin">Round Robin</option></select></div>
|
|
<div class="form-group"><label>Scope</label><select id="rpScope" onchange="Pages.routingScopeChanged(this)"><option value="global">Global</option><option value="team">Team</option></select></div>
|
|
<div id="rpTeamGroup" class="form-group" style="display:none;"><label>Team</label><select id="rpTeamId"></select></div>
|
|
<div class="form-group"><label>Config (JSON)</label><textarea id="rpConfig" rows="4">{}</textarea></div>
|
|
<div class="form-group"><label><input type="checkbox" id="rpActive" checked> Active</label></div>
|
|
<div style="display:flex;gap:8px;">
|
|
<button id="rpSaveBtn" class="btn-primary" onclick="Pages.saveRoutingPolicy()">Save</button>
|
|
<button id="rpCancelBtn" class="btn-secondary" onclick="Pages.hideRoutingForm()">Cancel</button>
|
|
</div>
|
|
</div>
|
|
|
|
{{/* ── Auto-Compact Toggle (chat header option) */}}
|
|
<div id="autoCompactToggle" style="display:none;">
|
|
<label><input type="checkbox" id="autoCompactCheck"> Auto-compact</label>
|
|
</div>
|
|
|
|
{{/* ── Fetch Models Button (admin) ─────────── */}}
|
|
<button id="fetchModelsBtn" style="display:none;"></button>
|
|
|
|
{{end}}
|
|
|
|
{{define "css-chat"}}
|
|
<link rel="stylesheet" href="{{.BasePath}}/css/editor-mode.css?v={{.Version}}">
|
|
<link rel="stylesheet" href="{{.BasePath}}/css/persona-kb.css?v={{.Version}}">
|
|
<link rel="stylesheet" href="{{.BasePath}}/css/memory.css?v={{.Version}}">
|
|
<link rel="stylesheet" href="{{.BasePath}}/css/notifications.css?v={{.Version}}">
|
|
<link rel="stylesheet" href="{{.BasePath}}/css/channel-models.css?v={{.Version}}">
|
|
<link rel="stylesheet" href="{{.BasePath}}/css/notification-prefs.css?v={{.Version}}">
|
|
<link rel="stylesheet" href="{{.BasePath}}/branding/custom.css" onerror="this.remove()">
|
|
{{end}}
|
|
|
|
{{define "scripts-chat"}}
|
|
{{/* Vendor libs */}}
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/vendor/marked.min.js" onerror="this.onerror=null;this.src='https://cdnjs.cloudflare.com/ajax/libs/marked/16.3.0/lib/marked.umd.min.js'"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/vendor/purify.min.js" onerror="this.onerror=null;this.src='https://cdnjs.cloudflare.com/ajax/libs/dompurify/3.2.4/purify.min.js'"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/vendor/codemirror/codemirror.bundle.js?v={{$.Version}}" onerror="console.warn('[CM6] Bundle not available — falling back to textarea')"></script>
|
|
{{/* App JS — order matches index.html (minus api/events/ui-primitives already in base) */}}
|
|
{{/* debug.js and repl.js now loaded in base.html for all surfaces */}}
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/extensions.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/panels.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/ui-format.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/ui-settings.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/ui-admin.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/tokens.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/notes.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/note-graph.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/files.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/tools-toggle.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/knowledge-ui.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/memory-ui.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/persona-kb.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/projects-ui.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/channel-models.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/notification-prefs.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/notifications.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/chat.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/settings-handlers.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/admin-handlers.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/surface-nav.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/editor-mode.js?v={{$.Version}}"></script>
|
|
<script nonce="{{$.CSPNonce}}" src="{{$.BasePath}}/js/app.js?v={{$.Version}}"></script>
|
|
{{end}}
|