refactor(renderer): L132 — share resetForm() across download + addPlaylist
Extract the post-enqueue reset (URL + probe + one-shot trim/schedule/advanced/ incognito/options) into resetForm(), called by both download() and addPlaylist(). clearProbe() stays the lighter probe-only reset for onUrlChange. Also fixes a latent inconsistency: addPlaylist previously left the trim/schedule/advanced panels open after enqueuing a playlist. typecheck + eslint + prettier green. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
+6
-1
@@ -770,7 +770,12 @@ token system + shared primitives (UI/SIMP — high value, larger effort) · i18n
|
||||
"interrupted"); user-facing ones are capitalized with periods. Fine when interpolated, jarring if shown raw.
|
||||
- [ ] **L131 — Taskbar `error` state is ephemeral** — it's driven by live `error` items, so "Clear
|
||||
finished" flips the red taskbar bar back to normal even though failures occurred (out of sync with the persisted error log).
|
||||
- [ ] **L132 — `clearProbe` + form-reset logic is duplicated** in DownloadBar (`onUrlChange`, `download`, `addPlaylist`).
|
||||
- [x] **L132 — `clearProbe` + form-reset logic is duplicated** in DownloadBar (`onUrlChange`, `download`, `addPlaylist`).
|
||||
*Fixed: a shared `resetForm()` in [useDownloadBar.ts](src/renderer/src/components/downloadBar/useDownloadBar.ts)
|
||||
now owns the post-enqueue reset (URL + probe + the one-shot trim/schedule/advanced/incognito/options),
|
||||
called by both `download()` and `addPlaylist()`. `clearProbe()` stays the lighter probe-only reset for
|
||||
`onUrlChange`. Also fixes a latent inconsistency — `addPlaylist` previously left the trim/schedule/advanced
|
||||
panels open after enqueuing.*
|
||||
- [ ] **L133 — `Field` controls mix `aria-label` + visible `label`.** Many `Field label="X"` wrap a
|
||||
`Select aria-label="X"`, so AT announces the name twice (extends M20 across DownloadOptionsForm).
|
||||
- [ ] **L134 — Inconsistent disabled affordance for busy buttons.** Some stay enabled-looking with a
|
||||
|
||||
Reference in New Issue
Block a user