Show podcast duration

main
bashrc 2026-04-13 16:33:05 +01:00
parent 2a80702267
commit 1c5e2f86e7
30 changed files with 68 additions and 30 deletions

View File

@ -672,8 +672,7 @@ def xml_podcast_to_dict(base_dir: str, xml_item: str, xml_str: str) -> {}:
duration = duration.split('>')[1] duration = duration.split('>')[1]
if '<' in duration: if '<' in duration:
duration = duration.split('<')[0] duration = duration.split('<')[0]
if duration.isdigit(): podcast_properties['duration'] = duration
podcast_properties['duration'] = duration
# get the image for the podcast, if it exists # get the image for the podcast, if it exists
podcast_episode_image = None podcast_episode_image = None

View File

@ -767,5 +767,6 @@
"Bot": "الروبوت", "Bot": "الروبوت",
"Show Map": "عرض الخريطة", "Show Map": "عرض الخريطة",
"Organisation": "منظمة", "Organisation": "منظمة",
"Group": "مجموعة" "Group": "مجموعة",
"minutes": "دقائق"
} }

View File

@ -767,5 +767,6 @@
"Bot": "রোবট", "Bot": "রোবট",
"Show Map": "মানচিত্র দেখান", "Show Map": "মানচিত্র দেখান",
"Organisation": "সংগঠন", "Organisation": "সংগঠন",
"Group": "গ্রুপ" "Group": "গ্রুপ",
"minutes": "মিনিট"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Mostra el mapa", "Show Map": "Mostra el mapa",
"Organisation": "Organització", "Organisation": "Organització",
"Group": "Grup" "Group": "Grup",
"minutes": "minuts"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Dangos Map", "Show Map": "Dangos Map",
"Organisation": "Sefydliad", "Organisation": "Sefydliad",
"Group": "Grŵp" "Group": "Grŵp",
"minutes": "munudau"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Roboter", "Bot": "Roboter",
"Show Map": "Karte anzeigen", "Show Map": "Karte anzeigen",
"Organisation": "Organisation", "Organisation": "Organisation",
"Group": "Gruppe" "Group": "Gruppe",
"minutes": "minuten"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Ρομπότ", "Bot": "Ρομπότ",
"Show Map": "Εμφάνιση Χάρτη", "Show Map": "Εμφάνιση Χάρτη",
"Organisation": "Οργάνωση", "Organisation": "Οργάνωση",
"Group": "Ομάδα" "Group": "Ομάδα",
"minutes": "πρακτικά"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Show Map", "Show Map": "Show Map",
"Organisation": "Organisation", "Organisation": "Organisation",
"Group": "Group" "Group": "Group",
"minutes": "minutes"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Mostrar mapa", "Show Map": "Mostrar mapa",
"Organisation": "Organización", "Organisation": "Organización",
"Group": "Grupo" "Group": "Grupo",
"minutes": "minutos"
} }

View File

@ -767,5 +767,6 @@
"Bot": "ربات", "Bot": "ربات",
"Show Map": "نمایش نقشه", "Show Map": "نمایش نقشه",
"Organisation": "سازمان", "Organisation": "سازمان",
"Group": "گروه" "Group": "گروه",
"minutes": "دقیقه"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Robotti", "Bot": "Robotti",
"Show Map": "Näytä kartta", "Show Map": "Näytä kartta",
"Organisation": "Organisaatio", "Organisation": "Organisaatio",
"Group": "Ryhmä" "Group": "Ryhmä",
"minutes": "minuuttia"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Afficher la carte", "Show Map": "Afficher la carte",
"Organisation": "Organisation", "Organisation": "Organisation",
"Group": "Groupe" "Group": "Groupe",
"minutes": "minutes"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Róbat", "Bot": "Róbat",
"Show Map": "Taispeáin Léarscáil", "Show Map": "Taispeáin Léarscáil",
"Organisation": "Eagraíocht", "Organisation": "Eagraíocht",
"Group": "Grúpa" "Group": "Grúpa",
"minutes": "nóiméad"
} }

View File

@ -767,5 +767,6 @@
"Bot": "רוֹבּוֹט", "Bot": "רוֹבּוֹט",
"Show Map": "הצג מפה", "Show Map": "הצג מפה",
"Organisation": "אִרגוּן", "Organisation": "אִרגוּן",
"Group": "קְבוּצָה" "Group": "קְבוּצָה",
"minutes": "פּרוֹטוֹקוֹל"
} }

View File

@ -767,5 +767,6 @@
"Bot": "रोबोट", "Bot": "रोबोट",
"Show Map": "नक्शा दिखाएं", "Show Map": "नक्शा दिखाएं",
"Organisation": "संगठन", "Organisation": "संगठन",
"Group": "समूह" "Group": "समूह",
"minutes": "मिनट"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Mostra mappa", "Show Map": "Mostra mappa",
"Organisation": "Organizzazione", "Organisation": "Organizzazione",
"Group": "Gruppo" "Group": "Gruppo",
"minutes": "minuti"
} }

View File

@ -767,5 +767,6 @@
"Bot": "ロボット", "Bot": "ロボット",
"Show Map": "地図を表示", "Show Map": "地図を表示",
"Organisation": "組織", "Organisation": "組織",
"Group": "グループ" "Group": "グループ",
"minutes": "分"
} }

View File

@ -767,5 +767,6 @@
"Bot": "기계 인간", "Bot": "기계 인간",
"Show Map": "지도 표시", "Show Map": "지도 표시",
"Organisation": "조직", "Organisation": "조직",
"Group": "그룹" "Group": "그룹",
"minutes": "분"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Nexşeya Nîşan Bide", "Show Map": "Nexşeya Nîşan Bide",
"Organisation": "Sazûman", "Organisation": "Sazûman",
"Group": "Kom" "Group": "Kom",
"minutes": "deqîqe"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Kaart weergeven", "Show Map": "Kaart weergeven",
"Organisation": "Organisatie", "Organisation": "Organisatie",
"Group": "Groep" "Group": "Groep",
"minutes": "notulen"
} }

View File

@ -763,5 +763,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Show Map", "Show Map": "Show Map",
"Organisation": "Organisation", "Organisation": "Organisation",
"Group": "Group" "Group": "Group",
"minutes": "minutes"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Pokaż mapę", "Show Map": "Pokaż mapę",
"Organisation": "Organizacja", "Organisation": "Organizacja",
"Group": "Grupa" "Group": "Grupa",
"minutes": "protokół"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Robô", "Bot": "Robô",
"Show Map": "Mostrar mapa", "Show Map": "Mostrar mapa",
"Organisation": "Organização", "Organisation": "Organização",
"Group": "Grupo" "Group": "Grupo",
"minutes": "minutos"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Робот", "Bot": "Робот",
"Show Map": "Показать карту", "Show Map": "Показать карту",
"Organisation": "Организация", "Organisation": "Организация",
"Group": "Группа" "Group": "Группа",
"minutes": "минут"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Roboti", "Bot": "Roboti",
"Show Map": "Onyesha Ramani", "Show Map": "Onyesha Ramani",
"Organisation": "Shirika", "Organisation": "Shirika",
"Group": "Kundi" "Group": "Kundi",
"minutes": "dakika"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Bot", "Bot": "Bot",
"Show Map": "Haritayı Göster", "Show Map": "Haritayı Göster",
"Organisation": "Organizasyon", "Organisation": "Organizasyon",
"Group": "Grup" "Group": "Grup",
"minutes": "dakika"
} }

View File

@ -767,5 +767,6 @@
"Bot": "Робот", "Bot": "Робот",
"Show Map": "Показати карту", "Show Map": "Показати карту",
"Organisation": "Організація", "Organisation": "Організація",
"Group": "Група" "Group": "Група",
"minutes": "хвилин"
} }

View File

@ -767,5 +767,6 @@
"Bot": "ראָבאָט", "Bot": "ראָבאָט",
"Show Map": "ווייַזן מאַפּע", "Show Map": "ווייַזן מאַפּע",
"Organisation": "אָרגאַניזאַציע", "Organisation": "אָרגאַניזאַציע",
"Group": "גרופּע" "Group": "גרופּע",
"minutes": "מינוטן"
} }

View File

@ -767,5 +767,6 @@
"Bot": "机器人", "Bot": "机器人",
"Show Map": "显示地图", "Show Map": "显示地图",
"Organisation": "组织", "Organisation": "组织",
"Group": "团体" "Group": "团体",
"minutes": "分钟"
} }

View File

@ -462,6 +462,17 @@ def html_podcast_episode(translate: {},
'<p><span itemprop="description">' + \ '<p><span itemprop="description">' + \
podcast_description + '</span></p>\n' podcast_description + '</span></p>\n'
if podcast_properties.get('duration'):
if podcast_properties['duration'].isdigit():
podcast_str += \
'<p><span itemprop="description">' + \
podcast_properties['duration'] + ' ' + \
translate['minutes'] + '</span></p>\n'
else:
podcast_str += \
'<p><span itemprop="description">' + \
podcast_properties['duration'] + '</span></p>\n'
# donate button # donate button
if podcast_properties.get('funding'): if podcast_properties.get('funding'):
if podcast_properties['funding'].get('url'): if podcast_properties['funding'].get('url'):