忆旧游(新朋故侣,诗酒迟留,吴山苍苍,渺渺兮余怀也。寄沈尧道诸公),
张炎 ,宋代, 记开帘过酒,隔水悬灯,款语梅边。未了清游兴,又飘然独去,何处山川。淡风暗收榆荚,吹下沈郎钱。叹客里光阴,消磨艳冶,都在尊前。
留连。殢人处,是镜曲窥莺,兰阜围泉。醉拂珊瑚树,写百年幽恨,分付吟笺。故乡几回飞梦,江雨夜凉船。纵忘却归期,千山未必无杜鹃。
// 状态1:音频正在播放 → 暂停
if (audio && !audio.paused) {
audio.pause();
btn.innerText = "朗读";
btn.style.backgroundColor = '';
btn.style.color = '#000';
return;
}
// 状态2:音频已暂停 → 尝试继续播放,加catch兜底
if (audio && audio.paused) {
audio.play().then(()=>{
btn.innerText = "暂停";
btn.style.backgroundColor = 'green';
btn.style.color = 'white';
}).catch(e=>{
console.error("续播失败Safari限制:",e);
alert("苹果浏览器续播受限,将重新生成音频");
audio = null;
btn.innerText = "朗读";
btn.style.backgroundColor = '';
btn.style.color = '#000';
})
return;
}