[Mobidziennik] Fix missing linebreaks when sending messages. (#63)

This commit is contained in:
Kuba Szczodrzyński 2021-09-08 22:49:14 +02:00 committed by GitHub
parent c1062cd7ed
commit 680a5dfea3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -503,10 +503,14 @@ class MessagesComposeFragment : Fragment(), CoroutineScope {
text.toString()
}
textHtml = textHtml
.replace("</b><b>", "")
.replace("</i><i>", "")
.replace("p style=\"margin-top:0; margin-bottom:0;\"", "p")
if (app.profile.loginStoreType == LoginStore.LOGIN_TYPE_MOBIDZIENNIK) {
textHtml = textHtml
.replace("p style=\"margin-top:0; margin-bottom:0;\"", "span")
.replace("</p>", "</span>")
.replace("</p><br>", "</p>")
.replace("<b>", "<strong>")
.replace("</b>", "</strong>")
.replace("<i>", "<em>")