Show map within separate dropdown

main
bashrc 2026-02-24 10:39:00 +00:00
parent 7ba9ede278
commit 91b9a33950
29 changed files with 70 additions and 28 deletions

View File

@ -764,5 +764,6 @@
"Status": "حالة",
"Warning: Possible dangerous link": "تحذير: رابط خطير محتمل",
"Mutual": "مشترك",
"Bot": "الروبوت"
"Bot": "الروبوت",
"Show Map": "عرض الخريطة"
}

View File

@ -764,5 +764,6 @@
"Status": "অবস্থা",
"Warning: Possible dangerous link": "সতর্কতা: সম্ভাব্য বিপজ্জনক লিঙ্ক",
"Mutual": "পারস্পরিক",
"Bot": "রোবট"
"Bot": "রোবট",
"Show Map": "মানচিত্র দেখান"
}

View File

@ -764,5 +764,6 @@
"Status": "Estat",
"Warning: Possible dangerous link": "Avís: Possible enllaç perillós",
"Mutual": "Mútua",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Mostra el mapa"
}

View File

@ -764,5 +764,6 @@
"Status": "Statws",
"Warning: Possible dangerous link": "Rhybudd: Cyswllt peryglus posibl",
"Mutual": "Cydfuddiannol",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Dangos Map"
}

View File

@ -764,5 +764,6 @@
"Status": "Status",
"Warning: Possible dangerous link": "Warnung: Möglicher gefährlicher Link",
"Mutual": "Gegenseitig",
"Bot": "Roboter"
"Bot": "Roboter",
"Show Map": "Karte anzeigen"
}

View File

@ -764,5 +764,6 @@
"Status": "Κατάσταση",
"Warning: Possible dangerous link": "Προειδοποίηση: Πιθανός επικίνδυνος σύνδεσμος",
"Mutual": "Αμοιβαίος",
"Bot": "Ρομπότ"
"Bot": "Ρομπότ",
"Show Map": "Εμφάνιση Χάρτη"
}

View File

@ -764,5 +764,6 @@
"Status": "Status",
"Warning: Possible dangerous link": "Warning: Possible dangerous link",
"Mutual": "Mutual",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Show Map"
}

View File

@ -764,5 +764,6 @@
"Status": "Estado",
"Warning: Possible dangerous link": "Advertencia: Posible enlace peligroso",
"Mutual": "Mutual",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Mostrar mapa"
}

View File

@ -764,5 +764,6 @@
"Status": "وضعیت",
"Warning: Possible dangerous link": "هشدار: احتمال لینک خطرناک",
"Mutual": "متقابل",
"Bot": "ربات"
"Bot": "ربات",
"Show Map": "نمایش نقشه"
}

View File

@ -764,5 +764,6 @@
"Status": "Status",
"Warning: Possible dangerous link": "Varoitus: Mahdollisesti vaarallinen linkki",
"Mutual": "Keskinäinen",
"Bot": "Robotti"
"Bot": "Robotti",
"Show Map": "Näytä kartta"
}

View File

@ -764,5 +764,6 @@
"Status": "Statut",
"Warning: Possible dangerous link": "Avertissement : lien potentiellement dangereux",
"Mutual": "Mutuelle",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Afficher la carte"
}

View File

@ -764,5 +764,6 @@
"Status": "Stádas",
"Warning: Possible dangerous link": "Rabhadh: Nasc contúirteach féideartha",
"Mutual": "Frithpháirteach",
"Bot": "Róbat"
"Bot": "Róbat",
"Show Map": "Taispeáin Léarscáil"
}

View File

@ -764,5 +764,6 @@
"Status": "סטָטוּס",
"Warning: Possible dangerous link": "אזהרה: קישור מסוכן אפשרי",
"Mutual": "הֲדָדִי",
"Bot": "רוֹבּוֹט"
"Bot": "רוֹבּוֹט",
"Show Map": "הצג מפה"
}

View File

@ -764,5 +764,6 @@
"Status": "स्थिति",
"Warning: Possible dangerous link": "चेतावनी: संभावित खतरनाक लिंक",
"Mutual": "आपसी",
"Bot": "रोबोट"
"Bot": "रोबोट",
"Show Map": "नक्शा दिखाएं"
}

View File

@ -764,5 +764,6 @@
"Status": "Stato",
"Warning: Possible dangerous link": "Attenzione: possibile collegamento pericoloso",
"Mutual": "Reciproca",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Mostra mappa"
}

View File

@ -764,5 +764,6 @@
"Status": "状態",
"Warning: Possible dangerous link": "警告: 危険なリンクの可能性があります",
"Mutual": "共通の",
"Bot": "ロボット"
"Bot": "ロボット",
"Show Map": "地図を表示"
}

View File

@ -764,5 +764,6 @@
"Status": "상태",
"Warning: Possible dangerous link": "경고: 위험한 링크가 있을 수 있습니다",
"Mutual": "상호간의",
"Bot": "기계 인간"
"Bot": "기계 인간",
"Show Map": "지도 표시"
}

View File

@ -764,5 +764,6 @@
"Status": "Cî",
"Warning: Possible dangerous link": "Hişyarî: Girêdaneke gengaz a xeternak",
"Mutual": "Beramberî",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Nexşeya Nîşan Bide"
}

View File

@ -764,5 +764,6 @@
"Status": "Status",
"Warning: Possible dangerous link": "Waarschuwing: Mogelijk gevaarlijke link",
"Mutual": "Wederzijds",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Kaart weergeven"
}

View File

@ -760,5 +760,6 @@
"Status": "Status",
"Warning: Possible dangerous link": "Warning: Possible dangerous link",
"Mutual": "Mutual",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Show Map"
}

View File

@ -764,5 +764,6 @@
"Status": "Status",
"Warning: Possible dangerous link": "Ostrzeżenie: Możliwe niebezpieczne łącze",
"Mutual": "Wzajemne",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Pokaż mapę"
}

View File

@ -764,5 +764,6 @@
"Status": "Estatuto",
"Warning: Possible dangerous link": "Aviso: possível ligação perigosa",
"Mutual": "Mútua",
"Bot": "Robô"
"Bot": "Robô",
"Show Map": "Mostrar mapa"
}

View File

@ -764,5 +764,6 @@
"Status": "Статус",
"Warning: Possible dangerous link": "Внимание: возможная опасная ссылка",
"Mutual": "Взаимный",
"Bot": "Робот"
"Bot": "Робот",
"Show Map": "Показать карту"
}

View File

@ -764,5 +764,6 @@
"Status": "Hali",
"Warning: Possible dangerous link": "Onyo: Kiungo hatari kinachowezekana",
"Mutual": "Kuheshimiana",
"Bot": "Roboti"
"Bot": "Roboti",
"Show Map": "Onyesha Ramani"
}

View File

@ -764,5 +764,6 @@
"Status": "Durum",
"Warning: Possible dangerous link": "Uyarı: Olası tehlikeli bağlantı",
"Mutual": "Karşılıklı",
"Bot": "Bot"
"Bot": "Bot",
"Show Map": "Haritayı Göster"
}

View File

@ -764,5 +764,6 @@
"Status": "Статус",
"Warning: Possible dangerous link": "Попередження: Можливе небезпечне посилання",
"Mutual": "Взаємне",
"Bot": "Робот"
"Bot": "Робот",
"Show Map": "Показати карту"
}

View File

@ -764,5 +764,6 @@
"Status": "סטאַטוס",
"Warning: Possible dangerous link": "ווארענונג: מעגלעכער געפערלעכער פארבינדונג",
"Mutual": "קעגנצייַטיק",
"Bot": "ראָבאָט"
"Bot": "ראָבאָט",
"Show Map": "ווייַזן מאַפּע"
}

View File

@ -764,5 +764,6 @@
"Status": "地位",
"Warning: Possible dangerous link": "警告:可能存在危险链接",
"Mutual": "相互的",
"Bot": "机器人"
"Bot": "机器人",
"Show Map": "显示地图"
}

View File

@ -2316,6 +2316,16 @@ def _mentions_to_person_options(html_str: str, nickname: str, domain: str,
return html_str
def _get_show_map_button(post_id: str, translate: {},
map_content: str) -> str:
"""Returns the markup for a "show map" button
"""
return ' <details><summary class="cw" tabindex="10">' + \
translate['Show Map'] + '</summary>' + \
'<div id="' + post_id + '">' + map_content + \
'</div></details>\n'
def individual_post_as_html(signing_priv_key_pem: str,
allow_downloads: bool,
recent_posts_cache: {}, max_recent_posts: int,
@ -3426,6 +3436,10 @@ def individual_post_as_html(signing_priv_key_pem: str,
post_html += ' <div class="post-title">\n' + \
' ' + title_str + \
reply_avatar_image_in_post + ' </div>\n'
if map_str:
map_str = _get_show_map_button(post_id, translate, map_str)
post_html += \
content_str + citations_str + map_str + \
reaction_str + footer_str + '\n'