1
0
mirror of https://codeberg.org/tom79/Fedilab synced 2024-12-12 03:16:36 +01:00

Add tags in any when pinned / Fix quotes with tags breaking lines

This commit is contained in:
Thomas 2023-01-04 11:53:51 +01:00
parent 785257cc6c
commit 9d6a2057ab
2 changed files with 3 additions and 1 deletions

View File

@ -221,6 +221,8 @@ public class HashTagActivity extends BaseActivity {
tagTimeline.name = stripTag.trim(); tagTimeline.name = stripTag.trim();
tagTimeline.isNSFW = false; tagTimeline.isNSFW = false;
tagTimeline.isART = false; tagTimeline.isART = false;
tagTimeline.any = new ArrayList<>();
tagTimeline.any.add(stripTag.trim());
pinnedTimeline.tagTimeline = tagTimeline; pinnedTimeline.tagTimeline = tagTimeline;
pinned.pinnedTimelines.add(pinnedTimeline); pinned.pinnedTimelines.add(pinnedTimeline);
if (update) { if (update) {

View File

@ -124,7 +124,7 @@ public class SpannableHelper {
if (status != null && status.mentions != null) { if (status != null && status.mentions != null) {
mentions.addAll(status.mentions); mentions.addAll(status.mentions);
} }
text = text.replaceAll("((<\\s?p\\s?>|<\\s?br\\s?/?>)&gt;(((?!([<])).)*))", "$2<blockquote>$3</blockquote>"); text = text.replaceAll("((<\\s?p\\s?>|<\\s?br\\s?/?>)&gt;(((?!(<\\s?br\\s?/?>|<\\s?/s?p\\s?>)).)*))", "$2<blockquote>$3</blockquote>");
text = text.trim().replaceAll("\\s{3}", "&nbsp;&nbsp;&nbsp;"); text = text.trim().replaceAll("\\s{3}", "&nbsp;&nbsp;&nbsp;");
text = text.trim().replaceAll("\\s{2}", "&nbsp;&nbsp;"); text = text.trim().replaceAll("\\s{2}", "&nbsp;&nbsp;");
SpannableString initialContent; SpannableString initialContent;