Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

[Bug]: Target width input clamps the value on every keystroke

Aperta Adatta ai principianti
#37 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@AnushreeKasturi ci sta già lavorando.

Dal 17/10/2026.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
82/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
rust

Direzione di ricerca

Leggi crates/app/src/controls.rs:449-478, in particolare il gestore di input della larghezza obiettivo e il relativo binding prop:value. Riproduci il problema digitando 1000 e controlla quando cambia il valore visualizzato. Mantieni il valore grezzo durante la digitazione, applica il limite quando il valore cambia o il campo perde il focus e verifica che svuotare il campo continui a disattivare la larghezza obiettivo.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug good first issue
What happened?

The target width input clamps its value on every keystroke. Typing "1000" does not work: after the first character "1" the value is clamped to the minimum (320), and the reactive prop:value binding rewrites the field. The user ends up with a value they did not type.

Steps to reproduce
  1. Open the app.
  2. Click the "Target width" input.
  3. Type 1000 and watch the field.
Expected behavior

The raw typed value stays in the field while typing, and clamping happens on change or blur. Changing the field to empty disables the target width (current behavior, keep it).

Actual behavior

on:input parses and clamps on every keystroke (crates/app/src/controls.rs:466-473), and prop:value immediately writes the clamped value back, producing results like 3200 instead of 1000.

Where did it go wrong?

UI controls / settings

Settings

Not applicable.

Browser

Any.

CodeFrame version

0.7.0

Console output or extra context

Reference: crates/app/src/controls.rs:449-478. Suggested fix: switch to on:change for clamping, or only clamp when the parsed value is out of range and the input is no longer focused.

Lingua principale
Rust
Stelle
1
Fork
0
Merge medio
1g 7h
PR unite (30g)
5

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di suradet-ps/codeframe

Tutte le issue di suradet-ps/codeframe

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.