mirror of
https://github.com/nomadkaraoke/karaoke-gen.git
synced 2026-12-04 00:56:43 +09:00
## Summary - The Trim Start/End and Fade In/Out buttons in the input audio editor were **conditionally rendered** — only visible when the selection touched the very start or end of the track. A mid-track selection showed only Cut/Mute/Clear, so users couldn't discover the Fade actions at all. - Reported on a 9:11 track with a 3:02–3:55 selection: the Fade buttons (shipped in #813) appeared to be "missing in prod" when they were actually just hidden by the edge-gating. - Now all four edge-actions **always render** when a selection exists but are `disabled` off-edge, with a tooltip hint explaining how to enable them. ## Changes - `AudioEditor.tsx`: derive `atStartEdge`/`atEndEdge` (1s tolerance, matching the server-side `afade` anchoring in `audio_edit_service.fade_region`); render Trim Start, Fade In, Trim End, Fade Out always, `disabled` off-edge with context-aware `title` tooltips. - 6 new i18n keys (`trimStart/EndSelection`, `trim*/fade*DisabledHint`) added to `en.json` and translated to all 33 locales. - New jest test asserting a mid-track selection renders the four buttons disabled. - Version bump `0.181.0 → 0.182.0`. ## Testing - [x] `AudioEditor.test.tsx` — 26/26 pass (incl. new disabled-state test) - [x] i18n completeness — 33/33 locales at 100% - [x] No new `tsc` errors in changed files ## Review - [x] CodeRabbit CLI review completed locally - [x] In-scope findings addressed (only i18n loanword nits, consistent with existing convention) @coderabbitai ignore --- 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>