mirror of
https://github.com/fork-maintainers/iceraven-browser
synced 2024-11-17 15:26:23 +00:00
[fenix] For https://github.com/mozilla-mobile/fenix/issues/26737 - Use the body2 for title else caption style in the Pocket section
This commit is contained in:
parent
5202efa275
commit
e48fd2951e
@ -52,7 +52,6 @@ import androidx.compose.ui.tooling.preview.PreviewParameterProvider
|
|||||||
import androidx.compose.ui.unit.Dp
|
import androidx.compose.ui.unit.Dp
|
||||||
import androidx.compose.ui.unit.IntSize
|
import androidx.compose.ui.unit.IntSize
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import androidx.compose.ui.unit.sp
|
|
||||||
import kotlinx.coroutines.delay
|
import kotlinx.coroutines.delay
|
||||||
import mozilla.components.service.pocket.PocketStory
|
import mozilla.components.service.pocket.PocketStory
|
||||||
import mozilla.components.service.pocket.PocketStory.PocketRecommendedStory
|
import mozilla.components.service.pocket.PocketStory.PocketRecommendedStory
|
||||||
@ -119,9 +118,9 @@ fun PocketStory(
|
|||||||
Text(
|
Text(
|
||||||
text = story.title,
|
text = story.title,
|
||||||
color = FirefoxTheme.colors.textPrimary,
|
color = FirefoxTheme.colors.textPrimary,
|
||||||
fontSize = 14.sp,
|
|
||||||
overflow = TextOverflow.Ellipsis,
|
overflow = TextOverflow.Ellipsis,
|
||||||
maxLines = 2,
|
maxLines = 2,
|
||||||
|
style = FirefoxTheme.typography.body2,
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
subtitle = {
|
subtitle = {
|
||||||
@ -131,17 +130,17 @@ fun PocketStory(
|
|||||||
Text(
|
Text(
|
||||||
text = story.publisher,
|
text = story.publisher,
|
||||||
color = FirefoxTheme.colors.textSecondary,
|
color = FirefoxTheme.colors.textSecondary,
|
||||||
fontSize = 12.sp,
|
|
||||||
overflow = TextOverflow.Ellipsis,
|
overflow = TextOverflow.Ellipsis,
|
||||||
maxLines = 1,
|
maxLines = 1,
|
||||||
|
style = FirefoxTheme.typography.caption,
|
||||||
)
|
)
|
||||||
} else if (isValidTimeToRead) {
|
} else if (isValidTimeToRead) {
|
||||||
Text(
|
Text(
|
||||||
text = "${story.timeToRead} min",
|
text = "${story.timeToRead} min",
|
||||||
color = FirefoxTheme.colors.textSecondary,
|
color = FirefoxTheme.colors.textSecondary,
|
||||||
fontSize = 12.sp,
|
|
||||||
overflow = TextOverflow.Ellipsis,
|
overflow = TextOverflow.Ellipsis,
|
||||||
maxLines = 1,
|
maxLines = 1,
|
||||||
|
style = FirefoxTheme.typography.caption,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -174,9 +173,9 @@ fun PocketSponsoredStory(
|
|||||||
Text(
|
Text(
|
||||||
text = story.title,
|
text = story.title,
|
||||||
color = FirefoxTheme.colors.textPrimary,
|
color = FirefoxTheme.colors.textPrimary,
|
||||||
fontSize = 14.sp,
|
|
||||||
overflow = TextOverflow.Ellipsis,
|
overflow = TextOverflow.Ellipsis,
|
||||||
maxLines = 2,
|
maxLines = 2,
|
||||||
|
style = FirefoxTheme.typography.body2,
|
||||||
)
|
)
|
||||||
|
|
||||||
Spacer(Modifier.height(9.dp))
|
Spacer(Modifier.height(9.dp))
|
||||||
@ -184,9 +183,9 @@ fun PocketSponsoredStory(
|
|||||||
Text(
|
Text(
|
||||||
text = stringResource(R.string.pocket_stories_sponsor_indication),
|
text = stringResource(R.string.pocket_stories_sponsor_indication),
|
||||||
color = FirefoxTheme.colors.textSecondary,
|
color = FirefoxTheme.colors.textSecondary,
|
||||||
fontSize = 12.sp,
|
|
||||||
overflow = TextOverflow.Ellipsis,
|
overflow = TextOverflow.Ellipsis,
|
||||||
maxLines = 1,
|
maxLines = 1,
|
||||||
|
style = FirefoxTheme.typography.caption,
|
||||||
)
|
)
|
||||||
|
|
||||||
Spacer(Modifier.height(7.dp))
|
Spacer(Modifier.height(7.dp))
|
||||||
@ -194,9 +193,9 @@ fun PocketSponsoredStory(
|
|||||||
Text(
|
Text(
|
||||||
text = story.sponsor,
|
text = story.sponsor,
|
||||||
color = FirefoxTheme.colors.textSecondary,
|
color = FirefoxTheme.colors.textSecondary,
|
||||||
fontSize = 12.sp,
|
|
||||||
overflow = TextOverflow.Ellipsis,
|
overflow = TextOverflow.Ellipsis,
|
||||||
maxLines = 1,
|
maxLines = 1,
|
||||||
|
style = FirefoxTheme.typography.caption,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -429,8 +428,7 @@ fun PoweredByPocketHeader(
|
|||||||
Text(
|
Text(
|
||||||
text = stringResource(R.string.pocket_stories_feature_title),
|
text = stringResource(R.string.pocket_stories_feature_title),
|
||||||
color = textColor,
|
color = textColor,
|
||||||
fontSize = 12.sp,
|
style = FirefoxTheme.typography.caption,
|
||||||
lineHeight = 16.sp,
|
|
||||||
)
|
)
|
||||||
|
|
||||||
ClickableSubstringLink(
|
ClickableSubstringLink(
|
||||||
|
Loading…
Reference in New Issue
Block a user