fix: colour related out of bounds crashes

Signed-off-by: Infi <infi@infi.sh>
This commit is contained in:
Infi 2025-03-11 00:44:32 +01:00
parent 2f435fb7e8
commit 879ddf03d6
1 changed files with 4 additions and 0 deletions

View File

@ -223,6 +223,10 @@ object BrushCompat {
@Composable
fun parseColour(colour: String): Brush {
if (colour.isEmpty()) {
return Brush.solidColor(Color.Unspecified)
}
when {
colour.startsWith("var(") -> {
Log.d(