preview-clip findings: add Play button + length comparison to verify before approving
each preview-clip finding now renders a dedicated detail card: File Length vs Real Length (e.g. 28s vs 200s) and a Play button so the user can listen to the clip and confirm it's a busted ~30s preview before approving the delete + re-download. reuses the existing _renderPlayButton/playFindingTrack path that dead_file/orphan findings already use (the finding carries file_path + title/artist/album, everything it needs).
This commit is contained in:
parent
bd3c5860f6
commit
034a19b24f
1 changed files with 11 additions and 0 deletions
|
|
@ -3195,6 +3195,17 @@ function _renderFindingDetail(f) {
|
|||
tnHtml += _renderPlayButton(f);
|
||||
return tnHtml;
|
||||
|
||||
case 'short_preview_track':
|
||||
if (d.artist) rows.push(['Artist', d.artist]);
|
||||
if (d.album) rows.push(['Album', d.album]);
|
||||
if (d.title) rows.push(['Title', d.title]);
|
||||
if (d.file_duration_s != null) rows.push(['File Length', `${d.file_duration_s}s`, 'warning']);
|
||||
if (d.expected_duration_s != null) rows.push(['Real Length', `${d.expected_duration_s}s`, 'success']);
|
||||
if (d.original_path) rows.push(['Path', d.original_path, 'path']);
|
||||
// Play button lets the user hear the clip and confirm it's a busted ~30s preview
|
||||
// before approving the delete + re-download.
|
||||
return media + _gridRows(rows) + _renderPlayButton(f);
|
||||
|
||||
default:
|
||||
// Generic: render all detail keys
|
||||
Object.entries(d).forEach(([k, v]) => {
|
||||
|
|
|
|||
Loading…
Reference in a new issue