alorma / Compose-Settings

Compose Multiplatform #Compose Settings library
https://alorma.github.io/Compose-Settings/
MIT License
429 stars 27 forks source link

SettingsSwitch causing unnecessary height #203

Closed LossyDragon closed 8 months ago

LossyDragon commented 8 months ago

From version 0.25.0 and onwards, making a SettingsSwitch causes the setting item to become almost full height when only a title is used, and full height when title and subtitle.

I remember playing around with the SettingsSwitch composable a while back and I recall its the Switch causing the height to overscale. I don't have that poc anymore but did whip up a quick preview through AS using 0.25.0. Version 0.24.0 does not display this symptom.

studio64_Ear7Yxuqbt

dessalines commented 8 months ago

I'm also getting this on material3:1.2.0-rc01

My current workaround is : .height(88.dp)

The issue seems to come from a bug with IntrinsicHeight here: https://github.com/alorma/Compose-Settings/blob/main/compose-settings-ui/src/commonMain/kotlin/com/alorma/compose/settings/ui/internal/SettingsTileScaffold.kt#L31

It may not be a bug with this library, but with jetpack compose, but I haven't found an issue there yet.

alorma commented 8 months ago

Hi! Can you open a PR for this, please?

dessalines commented 8 months ago

Sure, I'm testing out some fixes shortly.

dessalines commented 8 months ago

@alorma I saw you did a release for 1.0.9, but it didn't get pushed to sonatype:

https://central.sonatype.com/search?q=com.github.alorma&smo=true

alorma commented 8 months ago

I tried...

But not sure why, but github actions is broken on this repo and now it doesn't run...

Any Idea? 😅

dessalines commented 8 months ago

I don't use github actions, but maybe you could just run the same commands from your local machine to do a deploy?

dessalines commented 8 months ago

Any luck fixing the deployments? Maybe there's someone we could reach out to for expertise.

alorma commented 8 months ago

Didn't had time this week.

I hope that this weekend I could work a little on this.

dessalines commented 8 months ago

Gotcha, thx!