Elffuss BraidHub

utopia-ia/elffuss-claw public

The brain's status is also shown in words next to its dot

Left partly fixed by ux-fix (audit control #2, the model picker): the status
dot next to the picker got a translated title and accessible name, but on
screen it was still only a colour. A short visible word now sits next to it:
"Básico", "Cargando…", "Listo", "Listo · GPU" (Basic, Loading…, Ready, Ready
· GPU), hidden from screen readers because the dot's own name already says
it in full.

The dot no longer shrinks in the crowded phone header: it was squeezed into
a sliver at 390 px. Checked there and on a desktop width: one line, no
sideways scroll.

ux-modelo.mjs checks the visible word with the stand-in Ollama loaded.
Changesete28a6a0b8e80a0b437b1645e044e8f80e66306c389618b4a0b9e60b4e13a5db9
AuthorKikoCis <kikocisneros@gmail.com> · 2026-10-11 18:30 +02:00
CommitterKikoCis <kikocisneros@gmail.com> · 2026-10-11 18:30 +02:00
Parents2401d59705ea

Browse the files at this changeset

5 files changed

modified tests/ux-modelo.mjs +5 −0
@@ -41,6 +41,11 @@
4141 await p.evaluate(() => document.getElementById('loading-stage') ? 'escaparate puesto' : 'sin placeholder'));
4242 ok('el selector se llama «Cerebro (modelo de IA)» y el punto dice su estado', await p.getAttribute('#model-select', 'aria-label') === 'Cerebro (modelo de IA)'
4343 && await p.getAttribute('#model-status', 'aria-label') === 'Modelo listo');
44+// …y lo dice también a la vista, con palabras: el punto solo era un color.
45+ok('junto al punto, el estado en palabras («Listo»), visible', await p.evaluate(() => {
46+ const t = document.getElementById('model-status-txt');
47+ return t?.textContent === 'Listo' && t.getClientRects().length > 0 && getComputedStyle(t).visibility !== 'hidden';
48+}));
4449
4550 await p.click('#tabs button[data-tab="ajustes"]');
4651 await p.evaluate(() => {
modified web/css/elffuss.css +6 −1
@@ -70,11 +70,15 @@
7070 padding: 6px 8px;
7171 font-size: .85rem;
7272 }
73-.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
73+.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
7474 .dot.off { background: #4a5062; }
7575 .dot.loading { background: var(--warn); animation: pulse 1.2s ease-in-out infinite; }
7676 .dot.on { background: var(--ok); }
7777 .dot.gpu { background: var(--accent2); box-shadow: 0 0 8px var(--accent2); }
78+/* El estado del cerebro en palabras, junto al punto (el color solo no basta).
79+ El margen negativo lo arrima al punto: el hueco entre controles es mayor. */
80+.model-st-txt { font-size: .72rem; color: var(--muted); white-space: nowrap; flex: none; margin-left: -5px; }
81+.model-st-txt.loading { color: var(--warn); }
7882 @keyframes pulse { 50% { opacity: .35; } }
7983
8084 /* ---------- layout ---------- */
@@ -489,6 +493,7 @@
489493 .brand { flex: none; }
490494 .brand b, #model-ico, .model-card { display: none; }
491495 #btn-clear, #btn-perms { padding: 7px 9px; font-size: .78rem; }
496+ .model-st-txt { margin-left: -2px; font-size: .68rem; }
492497
493498 #log { padding: 10px; }
494499 .msg { max-width: 100%; font-size: .9rem; }
modified web/index.html +3 −0
@@ -39,6 +39,9 @@
3939 </label>
4040 <a id="model-card" class="model-card" target="_blank" rel="noopener noreferrer" hidden>ⓘ</a>
4141 <span id="model-status" class="dot off" role="img" title="estado del modelo"></span>
42+ <!-- El estado también en palabras, a la vista: el punto solo era un color. Para
43+ un lector de pantalla ya lo dice el aria-label del punto. -->
44+ <span id="model-status-txt" class="model-st-txt" aria-hidden="true"></span>
4245 <button id="btn-clear" class="ghost icon-btn" title="Nueva conversación"></button>
4346 <button id="btn-mind" class="ghost icon-btn" title="Mente de Elffuss — cerebro autónomo">🧠</button>
4447 <button id="disk-chip" class="ghost" hidden></button>
modified web/js/i18n.js +3 −0
@@ -265,6 +265,8 @@
265265 webResults: 'Resultados para «{q}»:', webNoResults: 'Sin resultados para «{q}».',
266266 webImagesBad: 'respuesta inesperada del buscador de imágenes', webNoImages: 'Sin imágenes para «{q}».',
267267 webGallery: 'Galería con {n} imágenes de «{q}» abierta en el visualizador.',
268+ // Estado del cerebro en corto, a la vista junto al punto (ui.modelStatus)
269+ modelStOffShort: 'Básico', modelStLoadingShort: 'Cargando…', modelStOnShort: 'Listo', modelStGpuShort: 'Listo · GPU',
268270 },
269271 en: {
270272 welcome: 'An operating system with a soul that lives in your browser. Here apps aren’t installed: they’re created when you ask, appearing on the right. I can use your folders (with permission), store encrypted secrets, schedule tasks and browse for you. Everything stays on your machine.',
@@ -512,6 +514,7 @@
512514 webResults: 'Results for “{q}”:', webNoResults: 'No results for “{q}”.',
513515 webImagesBad: 'unexpected answer from the image search', webNoImages: 'No images for “{q}”.',
514516 webGallery: 'Gallery with {n} images of “{q}” open in the viewer.',
517+ modelStOffShort: 'Basic', modelStLoadingShort: 'Loading…', modelStOnShort: 'Ready', modelStGpuShort: 'Ready · GPU',
515518 },
516519 uk: {
517520 claim: "застосунків не існує: їх створюють",
modified web/js/ui.js +7 −1
@@ -864,10 +864,16 @@
864864 export function modelStatus(state) { // 'off' | 'loading' | 'on' | 'gpu'
865865 const d = $('model-status');
866866 d.className = 'dot ' + state;
867- // El punto solo era color (y un title en español): ahora dice el estado.
867+ // El punto solo era color (y un title en español): ahora dice el estado, en su
868+ // nombre accesible y, en corto, con palabras a la vista junto a él.
868869 const txt = tr({ off: 'modelStOff', loading: 'modelStLoading', on: 'modelStOn', gpu: 'modelStGpu' }[state] || 'modelStOff');
869870 d.title = txt;
870871 d.setAttribute('aria-label', txt);
872+ const corto = $('model-status-txt');
873+ if (corto) {
874+ corto.textContent = tr({ off: 'modelStOffShort', loading: 'modelStLoadingShort', on: 'modelStOnShort', gpu: 'modelStGpuShort' }[state] || 'modelStOffShort');
875+ corto.className = 'model-st-txt ' + state;
876+ }
871877 }
872878
873879 // ---------- selector de modelo (dinámico) ----------