Skip to content

fix(assistant): align sidebar, refine dictation and respond to stop - #262

Merged
chaxus merged 4 commits into
mainfrom
fix/assistant_interactions
Oct 13, 2026
Merged

chaxus merged 4 commits into
mainfrom
fix/assistant_interactions

Conversation

@chaxus

@chaxus chaxus commented Oct 13, 2026 •

Copy link
Copy Markdown
Member

Merge Verdict

[APPROVE] — Local verification and all hosted CI checks pass on 7e912b06b39b92a358ed282b6b557053fd032678.

Summary

The sidebar used different insets for its heading, empty state and composer, while model buttons stacked outer and inner padding. Align those surfaces, use compact settings controls and group model preparation/release actions in one wrapping row. Dictation now has distinct microphone, listening-stop and finishing states, with a compact cancel icon in the toolbar. Stop now returns cancellation to the UI immediately while WebLLM drains the underlying operation before starting another inference.

Commits

  1. fix(assistant): align sidebar content and compact model settings
  2. fix(assistant): clarify compact speech input states
  3. fix(assistant): acknowledge inference cancellation immediately
  4. test(assistant): enter chat before measuring sidebar layout

Risk Analysis

Risk Level Mitigation
Cancelled inference overlaps a new request Medium Keep the internal queue tied to the underlying operation, while racing only the caller against cancellation. Regression verifies the next inference waits until the old operation settles.
Dictation changes a draft unexpectedly Low Preserve finalization, cancellation, interim text and explicit-send behavior. Ignore a late recognition-start callback after Stop.
Narrow sidebar layout Low Add browser checks at 320px and desktop width for alignment, compact button height and horizontal overflow.

Design Decisions

Retain ranui and the existing SpeechRecognition integration. Reference AI Elements' compact microphone toggle, listening feedback and processing states without adding React, shadcn or a new transcription service. Live announcements and reduced-motion behavior remain available.

Code Concerns

No outstanding blocking findings from source review. A stopped WebLLM worker may continue draining internally; subsequent inference waits for that drain to finish instead of sharing the engine concurrently.

Verification

  • Full unit suite: 5,112 tests passed across 172 files.

  • Focused panel, speech, WebLLM and chat-layout tests: 202 passed.

  • Regression for immediate cancellation failed before the fix and passed after it; checks queue serialization as well.

  • Format, oxlint, TypeScript and 1,511 immutable evaluation artifacts validated.

  • Production Vite build completed.

  • Local Chromium browser acceptance: 6/6 passed. Layout checks passed at 320px and 1280px (shared left edges, 30–34px model action height, no settings overflow). Word, Excel, PowerPoint and PDF dictation checks passed for transcript finalization on explicit Send and cancellation preserving the draft.

  • Additional local Chromium coverage: 11 tests passed for composer behavior, locale handling and model-loading geometry at 360px and 640px.

  • CI follow-up: the initial run failed only in the new layout test, which measured a hidden composer while the default view was Settings. Enter Chat through the actual editor and onboarding controls first. The updated test passed at 320px and 1280px against the deployed Cloudflare preview and all three hosted environments.

Conclusion basis
Verified: unit suites, static checks, build and remote trees matching the local commit trees. Reviewed: cancellation callbacks, speech session transitions, moved runtime-row consumers and responsive CSS overrides. Verified in Chromium: responsive geometry and controlled speech-event interaction across all four editors. Hosted verification: all checks passed on 7e912b06b39b92a358ed282b6b557053fd032678, including standard E2E, Docker-image E2E, Cloudflare Pages semantics, preview smoke and lint/validation. Logs confirm both responsive layout cases and all four editor dictation cases passed in each of the three environments. Not covered: physical microphone recognition accuracy and hardware-specific real-model cancellation latency.

@chaxus
chaxus enabled auto-merge (rebase) October 13, 2026 02:10
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 13, 2026 •

Copy link
Copy Markdown

Deploying document with  Cloudflare Pages  Cloudflare Pages

Latest commit: 7e912b0
Status: ✅  Deploy successful!
Preview URL: https://42877869.document-7hm.pages.dev
Branch Preview URL: https://fix-assistant-interactions.document-7hm.pages.dev

View logs

@chaxus
chaxus merged commit 5daa1f1 into main Oct 13, 2026
20 checks passed
@chaxus
chaxus deleted the fix/assistant_interactions branch October 13, 2026 02:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant