frontend improvement

This commit is contained in:
2026-06-10 19:22:24 +02:00
parent 52ea84747a
commit 177d975b4d
2 changed files with 29 additions and 4 deletions
+4 -4
View File
@@ -93,11 +93,11 @@ async function getReadable(feed, index) {
doc.querySelectorAll('img').forEach(resolveTemplatedImage);
doc.querySelectorAll('video, audio').forEach(el => el.remove());
// Some feeds (e.g. Deutsche Welle) leave behind a heading + play-icon SVG
// for an embedded video player whose actual <video>/<iframe> we already
// stripped — without it, the heading is just a giant orphaned icon that
// takes up space and links nowhere.
// for an embedded video/audio player whose actual <video>/<audio>/<iframe>
// we already stripped — without it, the heading is just a giant orphaned
// icon that takes up space and links nowhere.
doc.querySelectorAll('[aria-label]').forEach(el => {
if (/^(Eingebettetes|Embedded) Video/i.test(el.getAttribute('aria-label'))) {
if (/^(Eingebettete[rs]?|Embedded) (Video|Audio)/i.test(el.getAttribute('aria-label'))) {
el.remove()
}
})