The interface's words follow the style guide (#507)
docs/STYLE-GUIDE.md sets the rules: sentence case, "Unable to ..." and what to do for a failure, podcast not show, address not URL, check not scan, no dashes or symbols for words, buttons that start with a verb. The page, admin, sign-in and the app's alert now follow it: the copy failure, the download and sharing states, the feed's error label, the DeadAir lines, the search boxes' clear buttons (which said only "Clear"), the icon picker's Auto and Initials, the r key's "Refresh" (it reloads the lists), the admin log's Scans tab. "add it in Settings" stays in lower case: it is a link inside a sentence. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RqkrVCCH8YcP2Y3i8VNYWA
This commit is contained in:
@@ -33,7 +33,7 @@ function setSrc(url: string): Promise<void>|null{
|
||||
return ready.then(()=>{
|
||||
// Its playlist and audio requests join the trace of the tap that played them (#192).
|
||||
hls=new w.Hls({xhrSetup:(xhr: XMLHttpRequest)=>xhr.setRequestHeader('traceparent',traceparent())});
|
||||
hls.on(w.Hls.Events.ERROR,(_: string,d: {fatal: boolean, type: string, details: string})=>{ if(d.fatal){ toast('Unable to play the DeadAir version. Try again, or turn DeadAir off for this show.',true);
|
||||
hls.on(w.Hls.Events.ERROR,(_: string,d: {fatal: boolean, type: string, details: string})=>{ if(d.fatal){ toast('Unable to play the DeadAir version. Try again, or turn DeadAir off for this podcast.',true);
|
||||
report('player_error',{msg:`hls.js: ${d.type} ${d.details}`,feed:player.feed,enclosure:player.enc}); } });
|
||||
hls.loadSource(url); hls.attachMedia(audio);
|
||||
});
|
||||
@@ -247,7 +247,7 @@ function paintDead(){
|
||||
if(!f||b.hidden) return;
|
||||
b.setAttribute('aria-pressed',String(!!f.deadair));
|
||||
b.innerHTML=tile(f.deadair?'deadair-on':'deadair-off');
|
||||
b.title=f.deadair?'DeadAir is cutting the dead air from this show':'DeadAir: cut the dead air from this show';
|
||||
b.title=f.deadair?'DeadAir is cutting the dead air from this podcast':'DeadAir: cut the dead air from this podcast';
|
||||
}
|
||||
$<HTMLButtonElement>('#pdead').onclick=async()=>{
|
||||
const f=S.feeds.find(x=>x.id===player.feed); if(!f) return;
|
||||
@@ -256,8 +256,8 @@ $<HTMLButtonElement>('#pdead').onclick=async()=>{
|
||||
catch(err){ toast(why(err),true); return; }
|
||||
f.deadair=on; paintDead();
|
||||
const switched=await switchVersion();
|
||||
toast(!on?'DeadAir is off for this show':switched?'DeadAir is cutting the dead air from this show'
|
||||
:'DeadAir is on for this show. Episodes lose their dead air a few minutes after they download.');
|
||||
toast(!on?'DeadAir is off for this podcast':switched?'DeadAir is cutting the dead air from this podcast'
|
||||
:'DeadAir is on for this podcast. Episodes lose their dead air a few minutes after they download.');
|
||||
renderEntries();
|
||||
};
|
||||
/// Carries on at the same place in the other version of what is playing, once DeadAir has been
|
||||
@@ -352,7 +352,7 @@ function keysModal(){
|
||||
[g('a'),'All Subscriptions'],[g('d'),'Directory'],
|
||||
[g('u'),'Up Next'],[g('l'),'Currently Listening'],[g('s'),'Settings'],
|
||||
[k('Shift')+' '+k('J'),'Next feed'],[k('Shift')+' '+k('K'),'Previous feed'],
|
||||
[k('/'),'Search items, Currently Listening or the Directory'],[k('r'),'Refresh'],[k('['),'Show or hide the feed list'],
|
||||
[k('/'),'Search items, Currently Listening or the Directory'],[k('r'),'Reload the lists'],[k('['),'Show or hide the feed list'],
|
||||
['Items'],
|
||||
[k('j')+' or '+k('n'),'Next item'],[k('k')+' or '+k('p'),'Previous item'],
|
||||
[k('Shift')+' '+k('A'),'Mark all read'],
|
||||
|
||||
Reference in New Issue
Block a user