Feat rebrand armature (#43)
All checks were successful
CI/CD / detect-changes (push) Successful in 3s
CI/CD / test-frontend (push) Successful in 5s
CI/CD / test-go-pg (push) Successful in 2m34s
CI/CD / test-sqlite (push) Successful in 2m46s
CI/CD / build-and-deploy (push) Successful in 1m55s

Co-authored-by: Jeffrey Smith <jasafpro@gmail.com>
Co-committed-by: Jeffrey Smith <jasafpro@gmail.com>
This commit was merged in pull request #43.
This commit is contained in:
2026-03-31 23:25:37 +00:00
committed by xcaliber
parent fb5284f667
commit 680ec3b897
321 changed files with 956 additions and 1033 deletions

View File

@@ -238,7 +238,7 @@ export const debugEngine = {
try {
snap.storageKeys = Object.keys(localStorage).filter(k =>
k.startsWith('chatSwitchboard') || k.startsWith('switchboard') || k.startsWith('sb_')
k.startsWith('armatureChat') || k.startsWith('armature') || k.startsWith('arm_')
);
} catch (_) {
snap.storageKeys = '(error reading)';
@@ -355,7 +355,7 @@ export const debugEngine = {
// ── Export ───────────────────────────────
exportText() {
let text = `=== Switchboard Core Debug Export ===\n`;
let text = `=== Armature Debug Export ===\n`;
text += `Exported: ${new Date().toISOString()}\n`;
text += `URL: ${location.href}\n`;
text += `ENV: ${window.__ENV__ || 'unknown'} | VERSION: ${window.__VERSION__ || 'unknown'} | BASE: ${window.__BASE__ || '(root)'}\n`;
@@ -395,7 +395,7 @@ export const debugEngine = {
const url = URL.createObjectURL(blob);
const a = document.createElement('a');
a.href = url;
a.download = `switchboard-debug-${new Date().toISOString().replace(/[:.]/g, '-')}.txt`;
a.download = `armature-debug-${new Date().toISOString().replace(/[:.]/g, '-')}.txt`;
a.click();
URL.revokeObjectURL(url);
},

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: Action Registry
// Armature — SDK: Action Registry
// ==========================================
// Named actions that extensions expose for invocation.
//

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: API Domain Namespaces
// Armature — SDK: API Domain Namespaces
// ==========================================
// Namespaced domain clients wrapping restClient.
// Each domain is a plain object with typed methods.

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: Auth Module
// Armature — SDK: Auth Module
// ==========================================
// Owns token storage, login/logout/refresh lifecycle,
// and the permissions/teams/policies cache.
@@ -9,7 +9,7 @@
// ==========================================
const BASE = window.__BASE__ || '';
const _storageKey = BASE ? `sb_auth_${BASE.replace(/\//g, '')}` : 'sb_auth';
const _storageKey = BASE ? `arm_auth_${BASE.replace(/\//g, '')}` : 'arm_auth';
/**
* Create the auth module.
@@ -44,9 +44,9 @@ export function createAuth() {
}));
// Cookie sync for Go template page auth
if (_accessToken) {
document.cookie = `sb_token=${_accessToken}; path=/; max-age=900; SameSite=Strict`;
document.cookie = `arm_token=${_accessToken}; path=/; max-age=900; SameSite=Strict`;
} else {
document.cookie = 'sb_token=; path=/; max-age=0';
document.cookie = 'arm_token=; path=/; max-age=0';
}
}
@@ -71,7 +71,7 @@ export function createAuth() {
_policies = {};
localStorage.removeItem(_storageKey);
sessionStorage.removeItem('sw-chat-active');
document.cookie = 'sb_token=; path=/; max-age=0';
document.cookie = 'arm_token=; path=/; max-age=0';
if (_refreshTimer) { clearTimeout(_refreshTimer); _refreshTimer = null; }
}
@@ -197,9 +197,9 @@ export function createAuth() {
async boot() {
_loadTokens();
if (!_refreshToken) {
// No tokens in localStorage — clear any stale sb_token cookie
// No tokens in localStorage — clear any stale arm_token cookie
// so Go SSR middleware doesn't trust a leftover cookie.
document.cookie = 'sb_token=; path=/; max-age=0';
document.cookie = 'arm_token=; path=/; max-age=0';
return;
}

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: RBAC Gate
// Armature — SDK: RBAC Gate
// ==========================================
// Synchronous permission checking for render paths.
//

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: Event Bus
// Armature — SDK: Event Bus
// ==========================================
// Labeled event bus with WebSocket bridge.
// Port of events.js as ES module with factory pattern.

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK Entry Point
// Armature — SDK Entry Point
// ==========================================
// Assembles all SDK modules into the `sw` object
// and runs the boot sequence.

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: Markdown Renderer
// Armature — SDK: Markdown Renderer
// ==========================================
// Unified markdown rendering via `marked` (v16, vendored).
// Delegates fenced code blocks to sw.renderers and

View File

@@ -1,8 +1,8 @@
// ==========================================
// Switchboard Core — SDK: Pipe/Filter Pipeline
// Armature — SDK: Pipe/Filter Pipeline
// ==========================================
// Three-stage pipeline: pre-send, stream, render.
// Verbatim port of switchboard-sdk.js pipe code.
// Verbatim port of armature-sdk.js pipe code.
//
// Factory: createPipe()
// ==========================================

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: Realtime
// Armature — SDK: Realtime
// ==========================================
// Room-scoped publish/subscribe over the WebSocket bridge.
//

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: Renderer Registry
// Armature — SDK: Renderer Registry
// ==========================================
// Kernel-level renderer registration. Extensions register
// block renderers (fenced code blocks) and post renderers

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: REST Client
// Armature — SDK: REST Client
// ==========================================
// Internal HTTP engine for the new SDK.
// All domain clients and auth module use this.

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: Slot System
// Armature — SDK: Slot System
// ==========================================
// Named shell regions where extensions inject UI.
//

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: Storage Module
// Armature — SDK: Storage Module
// ==========================================
// Namespaced localStorage wrapper.
//

View File

@@ -1,5 +1,5 @@
// ==========================================
// Switchboard Core — SDK: Theme Control
// Armature — SDK: Theme Control
// ==========================================
// Theme management: localStorage + data-theme + system pref.
// Port of Theme from ui-primitives.js as ES module.
@@ -7,7 +7,7 @@
// Factory: createTheme(emitFn)
// ==========================================
const _key = 'switchboard_theme';
const _key = 'armature_theme';
/**
* Create the theme module.

View File

@@ -158,7 +158,7 @@ export default function SettingsSection() {
<label class="toggle-label"><input type="checkbox" checked=${cfg.footer_enabled} onChange=${e => set('footer_enabled', e.target.checked)} /><span class="toggle-track"></span><span>Show footer bar</span></label>
${cfg.footer_enabled && html`
<div style="margin-top:8px;">
<div class="form-group"><label>Text</label><input value=${cfg.footer_text} onInput=${e => set('footer_text', e.target.value)} placeholder="Powered by Switchboard Core" /></div>
<div class="form-group"><label>Text</label><input value=${cfg.footer_text} onInput=${e => set('footer_text', e.target.value)} placeholder="Powered by Armature" /></div>
</div>
`}
</div>

View File

@@ -26,9 +26,9 @@ export function Hero({ base = '', version = '', env = null }) {
<div class="login-hero-brand login-anim login-anim-1">
<img class="login-hero-brand-icon"
src="${base}/favicon.svg?v=${version}"
alt="Switchboard Core" />
alt="Armature" />
<span class="login-hero-brand-text">
Switchboard <span class="hl">Core</span>
Armature
</span>
</div>
<h1 class="login-anim login-anim-2">

View File

@@ -48,8 +48,8 @@ function LoginSurface() {
const switchToLogin = useCallback(() => setTab('login'), []);
const heading = tab === 'login'
? { title: 'Welcome back', sub: 'Sign in to your Switchboard instance' }
: { title: 'Create account', sub: 'Join your team on Switchboard' };
? { title: 'Welcome back', sub: 'Sign in to your Armature instance' }
: { title: 'Create account', sub: 'Join your team on Armature' };
return html`
<div class="login-shell">

View File

@@ -23,11 +23,11 @@ function WelcomeSurface() {
const hasSurfaces = surfaces.length > 0;
return html`
<${Topbar} title="Switchboard" />
<${Topbar} title="Armature" />
<div style="flex:1;display:flex;align-items:center;justify-content:center;padding:24px;">
<div style="max-width:420px;width:100%;background:var(--bg-surface);border:1px solid var(--border);border-radius:12px;padding:32px;text-align:center;">
<div style="font-size:36px;margin-bottom:16px;">${hasSurfaces ? '🏠' : '📦'}</div>
<h2 style="font-size:20px;font-weight:600;margin:0 0 8px;">Welcome to Switchboard</h2>
<h2 style="font-size:20px;font-weight:600;margin:0 0 8px;">Welcome to Armature</h2>
${hasSurfaces ? html`
<p style="font-size:14px;color:var(--text-2);margin:0 0 24px;line-height:1.5;">
No default surface is configured. Choose a surface from