Merge pull request #408 from vivganes/intl-hashtags

fix #407 correct non-english hashtags
This commit is contained in:
Vitor Pamplona
2023-05-14 17:37:18 -04:00
committed by GitHub
@@ -335,7 +335,7 @@ private fun SearchBar(accountViewModel: AccountViewModel, navController: NavCont
}
}
val hashtagSearch = Pattern.compile("(?:\\s|\\A)#([A-Za-z0-9_\\-]+)")
val hashtagSearch = Pattern.compile("(?:\\s|\\A)#([^\\s!@#\$%^&*()=+./,\\[{\\]};:'\"?><]+)")
fun findHashtags(content: String): List<String> {
val matcher = hashtagSearch.matcher(content)