fixed a bug

This commit is contained in:
2026-08-26 10:46:09 +08:00
parent 1b6090e44c
commit a6297e2f9f
4 changed files with 102 additions and 2 deletions

View File

@@ -15,6 +15,10 @@ button{flex:1;height:44px;border:0;border-radius:10px;color:#fff;background:#256
.sentence{padding:12px;border-radius:10px;background:#1c2228;color:#cbd5e1;line-height:1.5}
.active-sentence{outline:2px solid #14b8a6;color:#fff}
.selected-sentence{background:#334155;color:#fff}
.score{margin-top:6px;font-size:12px;color:#94a3b8}
.score.good{color:#14b8a6}.score.low{color:#f97316}
.footer{margin-top:16px;font-size:13px;color:#94a3b8}
.footer a{color:#60a5fa;text-decoration:none}
</style>
<div class="wrap">
@@ -128,6 +132,11 @@ async function load() {
});
video.currentTime = item.start_ms / 1000;
};
const score = document.createElement('div');
score.className = 'score' + (item.overall_score >= 80 ? ' good' : item.overall_score && item.overall_score < 60 ? ' low' : '');
score.textContent = `总分 ${Number(item.overall_score || 0).toFixed(1)}`;
if (item.recognized_text) score.textContent += ` · 识别:${item.recognized_text}`;
node.appendChild(score);
sentenceList.appendChild(node);
});
originalButton.onclick = playOriginal;
@@ -142,3 +151,4 @@ async function load() {
}
load();
</script>
<p class="footer">了解更多或下载跟读App<a href="https://www.pgyer.com/genduchong" target="_blank" rel="noopener">www.pgyer.com/genduchong</a></p>