|
@ -182,7 +182,7 @@ def _mark_post_as_read(actor: str, post_id: str, post_category: str) -> None:
|
|||
if post_id not in content:
|
||||
read_file.seek(0, 0)
|
||||
read_file.write(post_id + content)
|
||||
except Exception as ex:
|
||||
except OSError as ex:
|
||||
print('EX: Failed to mark post as read' + str(ex))
|
||||
else:
|
||||
with open(read_posts_filename, 'w+', encoding='utf-8') as read_file:
|
||||
|
|
|
@ -758,6 +758,15 @@ a:focus {
|
|||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.container img.postScopeIcon {
|
||||
float: none;
|
||||
width: 30px;
|
||||
margin: 0 0;
|
||||
padding: 0 0;
|
||||
border-radius: 0;
|
||||
vertical-align: -6px;
|
||||
}
|
||||
|
||||
.container.darker {
|
||||
background-color: var(--main-bg-color-reply);
|
||||
}
|
||||
|
|
|
@ -48,7 +48,8 @@ beginning. The ActivityPub protocol was initially called
|
|||
creation. Fediverse servers are typically referred to as “instances”,
|
||||
but they are really just websites which can speak with each other using
|
||||
the vocabulary of ActivityPub. Choosing an instance is the same as
|
||||
choosing a website that you trust to handle your data.</p>
|
||||
choosing a website that you trust to handle your data. This is <em>the
|
||||
social web</em>.</p>
|
||||
<p>Servers such as <a
|
||||
href="https://github.com/mastodon/mastodon">Mastodon</a> are well known,
|
||||
but these are aimed at large scale deployments on powerful hardware
|
||||
|
@ -622,6 +623,9 @@ shortcuts</em> link at the bottom of the left column.</p>
|
|||
<figcaption aria-hidden="true">Keyboard shortcuts screen</figcaption>
|
||||
</figure>
|
||||
<h1 id="calendar">Calendar</h1>
|
||||
<p><em>“There is nothing in this world that does not have a decisive
|
||||
moment”</em></p>
|
||||
<p>– Henri Cartier-Bresson</p>
|
||||
<p>The calendar is not yet a standardized feature of the fediverse as a
|
||||
whole, but has existed in Friendica and Zot instances for a long time.
|
||||
Being able to attach a date and time to a post and then have it appear
|
||||
|
|
|
@ -465,6 +465,10 @@ At the bottom of the timeline there will usually be an arrow icon to go to the n
|
|||

|
||||
|
||||
# Calendar
|
||||
*"There is nothing in this world that does not have a decisive moment"*
|
||||
|
||||
-- Henri Cartier-Bresson
|
||||
|
||||
The calendar is not yet a standardized feature of the fediverse as a whole, but has existed in Friendica and Zot instances for a long time. Being able to attach a date and time to a post and then have it appear on your calendar and perhaps also the calendars of your followers is quite useful for organizing things with minimum effort. Until such time as federated calendar functionality becomes more standardized this may only work between Epicyon instances.
|
||||
|
||||
Calendar events are really just ordinary posts with a date, time and perhaps also a location attached to them. Posts with *Public* scope which have a date and time will appear on the calendars of your followers, unless they have opted out of receiving calendar events from you.
|
||||
|
|
|
@ -293,7 +293,7 @@ def manual_approve_follow_request(session, session_onion, session_i2p,
|
|||
followers_file.seek(0, 0)
|
||||
followers_file.write(approve_handle_full + '\n' +
|
||||
content)
|
||||
except Exception as ex:
|
||||
except OSError as ex:
|
||||
print('WARN: Manual follow accept. ' +
|
||||
'Failed to write entry to followers file ' + str(ex))
|
||||
else:
|
||||
|
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 9.5 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 9.5 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 9.5 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 9.3 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 9.6 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 9.4 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 12 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 13 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 13 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 12 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 8.5 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 9.1 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 8.4 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 7.4 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 7.4 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 8.5 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 9.1 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 8.4 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 7.4 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 7.4 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 9.5 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 9.6 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 9.5 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 8.8 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 9.2 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 8.8 KiB After Width: | Height: | Size: 8.9 KiB |
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "طرح سؤال",
|
||||
"Possible answers": "إجابات ممكنة",
|
||||
"replying to": "الرد على",
|
||||
"publicly replying to": "الرد علنًا على",
|
||||
"replying to followers": "الرد على المتابعين",
|
||||
"replying unlisted": "الرد غير مدرج",
|
||||
"replying to themselves": "الرد على أنفسهم",
|
||||
"announces": "يعلن",
|
||||
"Previous month": "الشهر الماضى",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "প্রশ্ন জিজ্ঞাসা কর",
|
||||
"Possible answers": "সম্ভাব্য উত্তর",
|
||||
"replying to": "এর জবাব",
|
||||
"publicly replying to": "প্রকাশ্যে উত্তর দিচ্ছেন",
|
||||
"replying to followers": "অনুগামীদের উত্তর",
|
||||
"replying unlisted": "অতালিকাভুক্ত উত্তর",
|
||||
"replying to themselves": "নিজেদের জবাব দিচ্ছে",
|
||||
"announces": "ঘোষণা করে",
|
||||
"Previous month": "পূর্ববর্তী মাস",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Fer una pregunta",
|
||||
"Possible answers": "Respostes possibles",
|
||||
"replying to": "responent",
|
||||
"publicly replying to": "responent públicament",
|
||||
"replying to followers": "responent als seguidors",
|
||||
"replying unlisted": "responent sense llistar",
|
||||
"replying to themselves": "responent-se",
|
||||
"announces": "anuncia",
|
||||
"Previous month": "Mes anterior",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Gofyn cwestiwn",
|
||||
"Possible answers": "Atebion posib",
|
||||
"replying to": "ateb i",
|
||||
"publicly replying to": "yn ateb yn gyhoeddus",
|
||||
"replying to followers": "ateb i ddilynwyr",
|
||||
"replying unlisted": "ateb heb ei restru",
|
||||
"replying to themselves": "ateb iddynt eu hunain",
|
||||
"announces": "yn cyhoeddi",
|
||||
"Previous month": "Y mis blaenorol",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Stelle eine Frage",
|
||||
"Possible answers": "Mögliche Antworten",
|
||||
"replying to": "antworten auf",
|
||||
"publicly replying to": "öffentlich antworten",
|
||||
"replying to followers": "followern antworten",
|
||||
"replying unlisted": "antworten nicht aufgeführt",
|
||||
"replying to themselves": "sich selbst antworten",
|
||||
"announces": "kündigt an",
|
||||
"Previous month": "Vorheriger Monat",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Κάνε μια ερώτηση",
|
||||
"Possible answers": "Πιθανές απαντήσεις",
|
||||
"replying to": "απαντώντας σε",
|
||||
"publicly replying to": "απαντώντας δημόσια σε",
|
||||
"replying to followers": "απαντώντας στους ακόλουθους",
|
||||
"replying unlisted": "απαντώντας εκτός λίστας",
|
||||
"replying to themselves": "απαντώντας στον εαυτό τους",
|
||||
"announces": "ανακοινώνει",
|
||||
"Previous month": "Προηγούμενος μήνας",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Ask a question",
|
||||
"Possible answers": "Possible answers",
|
||||
"replying to": "replying to",
|
||||
"publicly replying to": "publicly replying to",
|
||||
"replying to followers": "replying to followers",
|
||||
"replying unlisted": "replying to unlisted",
|
||||
"replying to themselves": "replying to themselves",
|
||||
"announces": "announces",
|
||||
"Previous month": "Previous month",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Haz una pregunta",
|
||||
"Possible answers": "Respuestas posibles",
|
||||
"replying to": "respondiendo a",
|
||||
"publicly replying to": "respondiendo públicamente a",
|
||||
"replying to followers": "en respuesta a las seguidoras",
|
||||
"replying unlisted": "respondiendo no listada",
|
||||
"replying to themselves": "respondiéndose a sí mismo",
|
||||
"announces": "anuncia",
|
||||
"Previous month": "Mes anterior",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "یه سوال بپرس",
|
||||
"Possible answers": "پاسخ های ممکن",
|
||||
"replying to": "در حال پاسخ دادن به",
|
||||
"publicly replying to": "علنی پاسخ دادن به",
|
||||
"replying to followers": "پاسخ به دنبال کنندگان",
|
||||
"replying unlisted": "در حال پاسخ به فهرست نشده",
|
||||
"replying to themselves": "به خودشان پاسخ می دهند",
|
||||
"announces": "اعلام می کند",
|
||||
"Previous month": "ماه گذشته",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Poser une question",
|
||||
"Possible answers": "Des réponses possibles",
|
||||
"replying to": "répondre à",
|
||||
"publicly replying to": "répondre publiquement à",
|
||||
"replying to followers": "répondre aux abonnés",
|
||||
"replying unlisted": "réponse non répertoriée",
|
||||
"replying to themselves": "se répondre à eux-mêmes",
|
||||
"announces": "annonce",
|
||||
"Previous month": "Le mois précédent",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Ceist a chur",
|
||||
"Possible answers": "Freagraí féideartha",
|
||||
"replying to": "ag freagairt",
|
||||
"publicly replying to": "ag freagairt go poiblí ar",
|
||||
"replying to followers": "ag freagairt do leantóirí",
|
||||
"replying unlisted": "freagra neamhliostaithe",
|
||||
"replying to themselves": "ag freagairt dóibh féin",
|
||||
"announces": "fógraíonn",
|
||||
"Previous month": "An mhí roimhe seo",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "प्रश्न पूछें",
|
||||
"Possible answers": "संभावित उत्तर",
|
||||
"replying to": "करने के लिए जवाब दे",
|
||||
"publicly replying to": "सार्वजनिक रूप से जवाब दे रहा है",
|
||||
"replying to followers": "अनुयायियों को जवाब देना",
|
||||
"replying unlisted": "असूचीबद्ध उत्तर दे रहा है",
|
||||
"replying to themselves": "खुद को जवाब दे",
|
||||
"announces": "की घोषणा",
|
||||
"Previous month": "पिछ्ला महिना",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Fai una domanda",
|
||||
"Possible answers": "Possibili risposte",
|
||||
"replying to": "rispondendo a",
|
||||
"publicly replying to": "rispondendo pubblicamente a",
|
||||
"replying to followers": "rispondere ai follower",
|
||||
"replying unlisted": "rispondendo non in elenco",
|
||||
"replying to themselves": "rispondendo a se stessi",
|
||||
"announces": "annuncia",
|
||||
"Previous month": "Il mese scorso",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "質問する",
|
||||
"Possible answers": "可能な答え",
|
||||
"replying to": "に返信する",
|
||||
"publicly replying to": "公に返信する",
|
||||
"replying to followers": "フォロワーへの返信",
|
||||
"replying unlisted": "リストにない返信",
|
||||
"replying to themselves": "自分に返信する",
|
||||
"announces": "発表する",
|
||||
"Previous month": "前月",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "질문하기",
|
||||
"Possible answers": "가능한 답변",
|
||||
"replying to": "답장",
|
||||
"publicly replying to": "공개적으로 답장",
|
||||
"replying to followers": "팔로워에게 회신",
|
||||
"replying unlisted": "목록에 없는 회신",
|
||||
"replying to themselves": "스스로에게 답장",
|
||||
"announces": "발표하다",
|
||||
"Previous month": "지난달",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Pirsek bipirsin",
|
||||
"Possible answers": "Bersivên gengaz",
|
||||
"replying to": "bersivandin",
|
||||
"publicly replying to": "bi raya giştî re bersiv dide",
|
||||
"replying to followers": "bersiva şagirtan dide",
|
||||
"replying unlisted": "bersivê nelîste",
|
||||
"replying to themselves": "bersiva xwe didin",
|
||||
"announces": "îlan dike",
|
||||
"Previous month": "Meha berê",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Een vraag stellen",
|
||||
"Possible answers": "Mogelijke antwoorden",
|
||||
"replying to": "reageren op",
|
||||
"publicly replying to": "openbaar beantwoorden",
|
||||
"replying to followers": "reageren op volgers",
|
||||
"replying unlisted": "niet vermeld reageren",
|
||||
"replying to themselves": "zichzelf beantwoorden",
|
||||
"announces": "kondigt aan",
|
||||
"Previous month": "Vorige maand",
|
||||
|
|
|
@ -190,6 +190,9 @@
|
|||
"Ask a question": "Ask a question",
|
||||
"Possible answers": "Possible answers",
|
||||
"replying to": "replying to",
|
||||
"publicly replying to": "publicly replying to",
|
||||
"replying to followers": "replying to followers",
|
||||
"replying unlisted": "replying unlisted",
|
||||
"replying to themselves": "replying to themselves",
|
||||
"announces": "announces",
|
||||
"Previous month": "Previous month",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Zadać pytanie",
|
||||
"Possible answers": "Możliwe odpowiedzi",
|
||||
"replying to": "odpowiadając na",
|
||||
"publicly replying to": "publicznie odpowiadac na",
|
||||
"replying to followers": "odpowiadanie obserwującym",
|
||||
"replying unlisted": "odpowiadanie niepubliczne",
|
||||
"replying to themselves": "odpowiadając sobie",
|
||||
"announces": "ogłasza",
|
||||
"Previous month": "Poprzedni miesiac",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Faça uma pergunta",
|
||||
"Possible answers": "Possíveis respostas",
|
||||
"replying to": "respondendo a",
|
||||
"publicly replying to": "respondendo publicamente a",
|
||||
"replying to followers": "respondendo aos seguidores",
|
||||
"replying unlisted": "respondendo não listado",
|
||||
"replying to themselves": "respondendo a si mesmos",
|
||||
"announces": "anuncia",
|
||||
"Previous month": "Mês anterior",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Задайте вопрос",
|
||||
"Possible answers": "Возможные ответы",
|
||||
"replying to": "отвечая на",
|
||||
"publicly replying to": "публично отвечая на",
|
||||
"replying to followers": "отвечаю подписчикам",
|
||||
"replying unlisted": "ответ не в списке",
|
||||
"replying to themselves": "отвечая на себя",
|
||||
"announces": "анонсов",
|
||||
"Previous month": "Предыдущий месяц",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Uliza Swali",
|
||||
"Possible answers": "Majibu yawezekana",
|
||||
"replying to": "kujibu kwa",
|
||||
"publicly replying to": "kujibu hadharani",
|
||||
"replying to followers": "kujibu wafuasi",
|
||||
"replying unlisted": "kujibu bila kuorodheshwa",
|
||||
"replying to themselves": "kujibu wenyewe",
|
||||
"announces": "inatangaza",
|
||||
"Previous month": "Mwezi uliopita",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Bir soru sor",
|
||||
"Possible answers": "Olası cevaplar",
|
||||
"replying to": "yanıtlamak",
|
||||
"publicly replying to": "herkese açık olarak yanıtlama",
|
||||
"replying to followers": "takipçilere cevap verme",
|
||||
"replying unlisted": "liste dışı yanıtlama",
|
||||
"replying to themselves": "kendilerine cevap vermek",
|
||||
"announces": "duyurur",
|
||||
"Previous month": "Geçtiğimiz ay",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "Задайте питання",
|
||||
"Possible answers": "Можливі відповіді",
|
||||
"replying to": "відповідаючи на",
|
||||
"publicly replying to": "публічно відповідаючи на",
|
||||
"replying to followers": "відповідаючи підписникам",
|
||||
"replying unlisted": "відповідати не в списку",
|
||||
"replying to themselves": "відповідаючи собі",
|
||||
"announces": "оголошує",
|
||||
"Previous month": "Попередній місяць",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "פרעגן אַ קשיא",
|
||||
"Possible answers": "מעגלעך ענטפֿערס",
|
||||
"replying to": "ענטפערן צו",
|
||||
"publicly replying to": "עפנטלעך ענטפער צו",
|
||||
"replying to followers": "ענטפער צו אנהענגערס",
|
||||
"replying unlisted": "ענטפערן אַנליסטיד",
|
||||
"replying to themselves": "ענטפערן צו זיך",
|
||||
"announces": "אַנאַונסיז",
|
||||
"Previous month": "פֿריִערדיקע חודש",
|
||||
|
|
|
@ -194,6 +194,9 @@
|
|||
"Ask a question": "问一个问题",
|
||||
"Possible answers": "可能的答案",
|
||||
"replying to": "回覆",
|
||||
"publicly replying to": "公开回复",
|
||||
"replying to followers": "回复关注者",
|
||||
"replying unlisted": "回复不公开",
|
||||
"replying to themselves": "回覆自己",
|
||||
"announces": "宣布",
|
||||
"Previous month": "前一个月",
|
||||
|
|
|
@ -353,6 +353,8 @@ def _save_individual_post_as_html_to_cache(base_dir: str,
|
|||
get_cached_post_directory(base_dir, nickname, domain)
|
||||
cached_post_filename = \
|
||||
get_cached_post_filename(base_dir, nickname, domain, post_json_object)
|
||||
if not cached_post_filename:
|
||||
return False
|
||||
|
||||
# create the cache directory if needed
|
||||
if not os.path.isdir(html_post_cache_dir):
|
||||
|
@ -1381,14 +1383,27 @@ def _reply_to_yourself_html(translate: {}) -> str:
|
|||
return title_str
|
||||
|
||||
|
||||
def _replying_to_with_scope(post_json_object: {}, translate: {}) -> str:
|
||||
"""Returns the replying to string
|
||||
"""
|
||||
replying_to_str = 'replying to'
|
||||
if is_followers_post(post_json_object):
|
||||
replying_to_str = 'replying to followers'
|
||||
elif is_public_post(post_json_object):
|
||||
replying_to_str = 'publicly replying to'
|
||||
elif is_unlisted_post(post_json_object):
|
||||
replying_to_str = 'replying unlisted'
|
||||
if translate.get(replying_to_str):
|
||||
replying_to_str = translate[replying_to_str]
|
||||
return replying_to_str
|
||||
|
||||
|
||||
def _reply_to_unknown_html(translate: {},
|
||||
post_json_object: {},
|
||||
nickname: str) -> str:
|
||||
"""Returns the html title for a reply to an unknown handle
|
||||
"""
|
||||
replying_to_str = 'replying to'
|
||||
if translate.get(replying_to_str):
|
||||
replying_to_str = translate[replying_to_str]
|
||||
replying_to_str = _replying_to_with_scope(post_json_object, translate)
|
||||
post_id = post_json_object['object']['inReplyTo']
|
||||
post_link = '/users/' + nickname + '?convthread=' + \
|
||||
post_id.replace('/', '--')
|
||||
|
@ -1418,9 +1433,7 @@ def _reply_with_unknown_path_html(translate: {},
|
|||
"""Returns html title for a reply with an unknown path
|
||||
eg. does not contain /statuses/
|
||||
"""
|
||||
replying_to_str = 'replying to'
|
||||
if translate.get(replying_to_str):
|
||||
replying_to_str = translate[replying_to_str]
|
||||
replying_to_str = _replying_to_with_scope(post_json_object, translate)
|
||||
post_id = post_json_object['object']['inReplyTo']
|
||||
post_link = '/users/' + nickname + '?convthread=' + \
|
||||
post_id.replace('/', '--')
|
||||
|
@ -1436,12 +1449,11 @@ def _reply_with_unknown_path_html(translate: {},
|
|||
|
||||
def _get_reply_html(translate: {},
|
||||
in_reply_to: str, reply_display_name: str,
|
||||
nickname: str) -> str:
|
||||
nickname: str,
|
||||
post_json_object: {}) -> str:
|
||||
"""Returns html title for a reply
|
||||
"""
|
||||
replying_to_str = 'replying to'
|
||||
if translate.get(replying_to_str):
|
||||
replying_to_str = translate[replying_to_str]
|
||||
replying_to_str = _replying_to_with_scope(post_json_object, translate)
|
||||
post_link = '/users/' + nickname + '?convthread=' + \
|
||||
in_reply_to.replace('/', '--')
|
||||
return ' ' + \
|
||||
|
@ -1549,7 +1561,8 @@ def _get_post_title_reply_html(base_dir: str,
|
|||
_log_post_timing(enable_timing_log, post_start_time, '13.6')
|
||||
|
||||
title_str += \
|
||||
_get_reply_html(translate, in_reply_to, reply_display_name, nickname)
|
||||
_get_reply_html(translate, in_reply_to, reply_display_name,
|
||||
nickname, post_json_object)
|
||||
|
||||
if mitm:
|
||||
title_str += _mitm_warning_html(translate)
|
||||
|
@ -2171,6 +2184,26 @@ def individual_post_as_html(signing_priv_key_pem: str,
|
|||
actor_nickname = 'dev'
|
||||
actor_domain, _ = get_domain_from_actor(post_actor)
|
||||
|
||||
# scope icon before display name
|
||||
if is_followers_post(post_json_object):
|
||||
title_str += \
|
||||
' <img loading="lazy" decoding="async" src="/' + \
|
||||
'icons/scope_followers.png" class="postScopeIcon" title="' + \
|
||||
translate['Only to followers'] + ':" alt="' + \
|
||||
translate['Only to followers'] + ':"/>\n'
|
||||
elif is_unlisted_post(post_json_object):
|
||||
title_str += \
|
||||
' <img loading="lazy" decoding="async" src="/' + \
|
||||
'icons/scope_unlisted.png" class="postScopeIcon" title="' + \
|
||||
translate['Not on public timeline'] + ':" alt="' + \
|
||||
translate['Not on public timeline'] + ':"/>\n'
|
||||
elif is_reminder(post_json_object):
|
||||
title_str += \
|
||||
' <img loading="lazy" decoding="async" src="/' + \
|
||||
'icons/scope_reminder.png" class="postScopeIcon" title="' + \
|
||||
translate['Scheduled note to yourself'] + ':" alt="' + \
|
||||
translate['Scheduled note to yourself'] + ':"/>\n'
|
||||
|
||||
display_name = get_display_name(base_dir, post_actor, person_cache)
|
||||
if display_name:
|
||||
if len(display_name) < 2 or \
|
||||
|
|
|
@ -705,7 +705,7 @@ def html_profile(signing_priv_key_pem: str,
|
|||
display_name = \
|
||||
add_emoji_to_display_name(session, base_dir, http_prefix,
|
||||
nickname, domain,
|
||||
display_name, True, translate)
|
||||
display_name, False, translate)
|
||||
domain_full = get_full_domain(domain, port)
|
||||
profile_description = profile_json['summary']
|
||||
profile_description = \
|
||||
|
|
|
@ -1062,7 +1062,7 @@ def load_individual_post_as_html_from_cache(base_dir: str,
|
|||
with open(cached_post_filename, 'r', encoding='utf-8') as file:
|
||||
post_html = file.read()
|
||||
break
|
||||
except Exception as ex:
|
||||
except OSError as ex:
|
||||
print('ERROR: load_individual_post_as_html_from_cache ' +
|
||||
str(tries) + ' ' + str(ex))
|
||||
# no sleep
|
||||
|
|