fix(creator-ranking): 텍스트 크기 기준을 확장한다

This commit is contained in:
2026-07-10 10:16:09 +09:00
parent 63a7c28e96
commit f477b563a2
2 changed files with 31 additions and 0 deletions
@@ -5,6 +5,12 @@ data class CreatorRankingTextStyle(
val nameTextSizeSp: Int,
val deltaTextSizeSp: Int
) {
fun scaledBy(scale: Float): CreatorRankingScaledTextStyle = CreatorRankingScaledTextStyle(
rankTextSizeSp = rankTextSizeSp * scale,
nameTextSizeSp = nameTextSizeSp * scale,
deltaTextSizeSp = deltaTextSizeSp * scale
)
companion object {
fun fromPlacement(placement: CreatorRankingPlacement): CreatorRankingTextStyle {
return when (placement.viewType) {
@@ -25,3 +31,9 @@ data class CreatorRankingTextStyle(
fun fromRank(rank: Int): CreatorRankingTextStyle = fromPlacement(CreatorRankingPlacement.fromRank(rank))
}
}
data class CreatorRankingScaledTextStyle(
val rankTextSizeSp: Float,
val nameTextSizeSp: Float,
val deltaTextSizeSp: Float
)