@@ -56,7 +56,7 @@ object SettingsComposable {
5656 onClick : () -> Unit = {},
5757 iconSize : Dp = 24.dp,
5858 fontColor : Color = SettingsTheme .typography.title.color,
59- fontSizeSp : Float = 24f
59+ titleFontSize : TextUnit = TextUnit . Unspecified
6060 ) {
6161 Row (
6262 modifier = Modifier
@@ -81,7 +81,7 @@ object SettingsComposable {
8181 text = title
8282 setTextSize(
8383 TypedValue .COMPLEX_UNIT_SP ,
84- fontSizeSp
84+ if (titleFontSize != TextUnit . Unspecified ) titleFontSize.value else 18f
8585 )
8686 setTextColor(fontColor.toArgb()) // Optional
8787 }
@@ -99,8 +99,8 @@ object SettingsComposable {
9999 title : String ,
100100 description : String? = null,
101101 iconSize : Dp = 96.dp,
102- titleFontSize : TextUnit = 24.sp ,
103- descriptionFontSize : TextUnit = 14.sp ,
102+ titleFontSize : TextUnit = TextUnit . Unspecified ,
103+ descriptionFontSize : TextUnit = TextUnit . Unspecified ,
104104 fontColor : Color = SettingsTheme .typography.title.color,
105105 onIconClick : (() -> Unit )? = null // Optional click callback
106106 ) {
@@ -127,7 +127,7 @@ object SettingsComposable {
127127 text = title
128128 setTextSize(
129129 TypedValue .COMPLEX_UNIT_SP ,
130- if (titleFontSize != TextUnit .Unspecified ) titleFontSize.value else 24f
130+ if (titleFontSize != TextUnit .Unspecified ) titleFontSize.value else 18f
131131 )
132132 setTextColor(fontColor.toArgb())
133133 setPadding(0 , 0 , 0 , 24 )
@@ -145,7 +145,7 @@ object SettingsComposable {
145145 setTextColor(fontColor.toArgb())
146146 setTextSize(
147147 TypedValue .COMPLEX_UNIT_SP ,
148- if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 14f
148+ if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 12f
149149 )
150150 movementMethod = LinkMovementMethod .getInstance()
151151 }
@@ -228,7 +228,7 @@ object SettingsComposable {
228228 setTextColor(fontColor.toArgb())
229229 setTextSize(
230230 TypedValue .COMPLEX_UNIT_SP ,
231- if (titleFontSize != TextUnit .Unspecified ) titleFontSize.value else 16f
231+ if (titleFontSize != TextUnit .Unspecified ) titleFontSize.value else 18f
232232 )
233233 }
234234 },
@@ -244,7 +244,7 @@ object SettingsComposable {
244244 setTextColor(fontColor.toArgb())
245245 setTextSize(
246246 TypedValue .COMPLEX_UNIT_SP ,
247- if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 14f
247+ if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 12f
248248 )
249249 }
250250 },
@@ -259,8 +259,8 @@ object SettingsComposable {
259259 fun TitleWithHtmlLink (
260260 title : String ,
261261 description : String? = null,
262- titleFontSize : TextUnit = 24.sp ,
263- descriptionFontSize : TextUnit = 18.sp ,
262+ titleFontSize : TextUnit = TextUnit . Unspecified ,
263+ descriptionFontSize : TextUnit = TextUnit . Unspecified ,
264264 titleColor : Color = SettingsTheme .typography.title.color,
265265 descriptionColor : Color = SettingsTheme .typography.title.color
266266 ) {
@@ -277,7 +277,7 @@ object SettingsComposable {
277277 setTextColor(titleColor.toArgb())
278278 setTextSize(
279279 TypedValue .COMPLEX_UNIT_SP ,
280- if (titleFontSize != TextUnit .Unspecified ) titleFontSize.value else 24f
280+ if (titleFontSize != TextUnit .Unspecified ) titleFontSize.value else 18f
281281 )
282282 movementMethod = LinkMovementMethod .getInstance()
283283 }
@@ -294,7 +294,7 @@ object SettingsComposable {
294294 setTextColor(descriptionColor.toArgb())
295295 setTextSize(
296296 TypedValue .COMPLEX_UNIT_SP ,
297- if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 14f
297+ if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 12f
298298 )
299299 movementMethod = LinkMovementMethod .getInstance()
300300 }
@@ -309,8 +309,8 @@ object SettingsComposable {
309309 fun TitleWithHtmlLinks (
310310 title : String ,
311311 descriptions : List <String > = emptyList(),
312- titleFontSize : TextUnit = 24.sp ,
313- descriptionFontSize : TextUnit = 18.sp ,
312+ titleFontSize : TextUnit = TextUnit . Unspecified ,
313+ descriptionFontSize : TextUnit = TextUnit . Unspecified ,
314314 titleColor : Color = SettingsTheme .typography.title.color,
315315 descriptionColor : Color = SettingsTheme .typography.title.color,
316316 columns : Boolean = false // if true, use Column for links
@@ -329,15 +329,15 @@ object SettingsComposable {
329329 setTextColor(titleColor.toArgb())
330330 setTextSize(
331331 TypedValue .COMPLEX_UNIT_SP ,
332- if (titleFontSize != TextUnit .Unspecified ) titleFontSize.value else 24f
332+ if (titleFontSize != TextUnit .Unspecified ) titleFontSize.value else 18f
333333 )
334334 }
335335 },
336336 modifier = Modifier .wrapContentHeight()
337337 )
338338
339339 if (descriptions.isNotEmpty()) {
340- Spacer (modifier = Modifier .height(4 .dp))
340+ // Spacer(modifier = Modifier.height(4.dp))
341341
342342 if (columns) {
343343 // Use Column layout for links
@@ -352,7 +352,7 @@ object SettingsComposable {
352352 setTextColor(descriptionColor.toArgb())
353353 setTextSize(
354354 TypedValue .COMPLEX_UNIT_SP ,
355- if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 14f
355+ if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 12f
356356 )
357357 movementMethod = LinkMovementMethod .getInstance()
358358 }
@@ -378,7 +378,7 @@ object SettingsComposable {
378378 setTextColor(descriptionColor.toArgb())
379379 setTextSize(
380380 TypedValue .COMPLEX_UNIT_SP ,
381- if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 14f
381+ if (descriptionFontSize != TextUnit .Unspecified ) descriptionFontSize.value else 12f
382382 )
383383 movementMethod = LinkMovementMethod .getInstance()
384384 }
@@ -401,7 +401,7 @@ object SettingsComposable {
401401 fontSize : TextUnit = TextUnit .Unspecified ,
402402 onClick : () -> Unit = {}
403403 ) {
404- val resolvedFontSizeSp = if (fontSize != TextUnit .Unspecified ) fontSize.value else 20f
404+ val resolvedFontSizeSp = if (fontSize != TextUnit .Unspecified ) fontSize.value else 18f
405405 val fontColor = SettingsTheme .typography.header.color
406406
407407 AndroidView (
@@ -439,7 +439,7 @@ object SettingsComposable {
439439 var isChecked by remember { mutableStateOf(defaultState) }
440440
441441 // Extract font size and color from theme safely in composable scope
442- val resolvedFontSizeSp = if (fontSize != TextUnit .Unspecified ) fontSize.value else 16f
442+ val resolvedFontSizeSp = if (fontSize != TextUnit .Unspecified ) fontSize.value else 14f
443443 val fontColor = SettingsTheme .typography.title.color
444444
445445 Row (
0 commit comments