Fix Search lexicon highlight

This commit is contained in:
Thomas Andres Gomez 2023-12-13 09:31:45 +01:00
parent 6fb3b2c10c
commit 9cbd33fd2e
2 changed files with 6 additions and 6 deletions

View file

@ -82,7 +82,7 @@ class SearchUseCase @Inject constructor(
text = item.race,
highlightRegex styleWith typography.search.extractHighlight,
),
status = item.status?.let { extractWordRegex.find(it) }?.let {
status = item.status?.let { extractSentenceRegex.find(it) }?.let {
AnnotatedString(
text = "$statusPrefix ",
spanStyle = typography.search.extractBold,
@ -91,7 +91,7 @@ class SearchUseCase @Inject constructor(
highlightRegex styleWith typography.search.extractHighlight,
)
},
location = item.location?.let { extractWordRegex.find(it) }?.let {
location = item.location?.let { extractSentenceRegex.find(it) }?.let {
AnnotatedString(
text = "$locationPrefix ",
spanStyle = typography.search.extractBold,

View file

@ -57,8 +57,8 @@ fun CharacterSheetHeader(
alignment = Alignment.CenterHorizontally
),
) {
header.value?.resource?.let {
ResourcePoint(resource = it, onClick = onResource)
header.value?.speed?.let {
LabelPoint(label = it)
}
header.value?.armorClass?.let {
LabelPoint(label = it)
@ -69,8 +69,8 @@ fun CharacterSheetHeader(
header.value?.dC?.let {
LabelPoint(label = it)
}
header.value?.speed?.let {
LabelPoint(label = it)
header.value?.resource?.let {
ResourcePoint(resource = it, onClick = onResource)
}
}