Skip to content

webui: fix the quality + button rendering as text - #51

Merged
Rust-KVM merged 1 commit into
devfrom
claude/webui-quality-button-fix
Oct 11, 2026
Merged

Rust-KVM merged 1 commit into
devfrom
claude/webui-quality-button-fix

Conversation

@Rust-KVM

Copy link
Copy Markdown
Owner

Requested by 4c · project thread

Summary

Before (regression from #47): the stream quality "+" button rendered as garbled text and stayed disabled, so quality could never be raised.

After: both quality buttons render normally; "+" is disabled only at 100% and "−" only at 10%.

How

In the view! macro an unbraced quality.get() >= 0.95 inside the disabled= attribute was parsed with the > closing the tag, so the rest leaked into the button body. Wrapping both comparisons in braces (move || { ... }) keeps the whole expression in the attribute.

Testing

  • cargo +nightly fmt --all (CI)
  • cargo +nightly clippy --workspace --release --all-targets -- -D warnings (CI)
  • cargo +nightly test --workspace (CI)
  • Frontend touched: trunk build --locked and wasm32 clippy in crates/rkvm-web (CI)
  • Tested on an RK3588 device: deployed to the NanoPC-T6; the garbled text is gone and the button renders correctly.

Checklist

  • No #[allow(...)] suppressions and no new unwrap() / expect() in production paths
  • Hot paths stay zero-copy; periodic loops use MissedTickBehavior::Delay
  • Shared protocol types live in rkvm-proto
  • RPC method set changed → not applicable
  • Module tree or build invariants changed → not applicable

🤖 Generated with Claude Code

https://claude.ai/code/session_01PbdzY6PfT28goR4BhqdsXR


Generated by Claude Code

In view!, `disabled=move || quality.get() >= 0.95` ended the tag at the
`>`, so the button showed "= 0.95 title =Raise stream quality>+" and
stayed disabled, leaving no way to raise quality again. Brace both
quality comparisons; no other view! attribute uses a bare < or >.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added the rkvm-web Leptos / WASM frontend label Oct 11, 2026
@Rust-KVM Rust-KVM self-assigned this Oct 11, 2026
@Rust-KVM
Rust-KVM merged commit 9287b60 into dev Oct 11, 2026
13 checks passed
@Rust-KVM
Rust-KVM deleted the claude/webui-quality-button-fix branch October 12, 2026 13:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

rkvm-web Leptos / WASM frontend

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants