Skip to content

Commit 909e188

Browse files
committed
Preserve alpha channel when updating color in ColorSpectrum
1 parent c696ac7 commit 909e188

File tree

1 file changed

+2
-2
lines changed
  • fluent/src/commonMain/kotlin/io/github/composefluent/component

1 file changed

+2
-2
lines changed

fluent/src/commonMain/kotlin/io/github/composefluent/component/ColorPicker.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1341,7 +1341,7 @@ sealed class ColorSpectrum {
13411341
excludeRadius = false
13421342
)
13431343
?.let { color ->
1344-
state.updateColor(color)
1344+
state.updateColor(color.copy(alpha = state.color.alpha))
13451345
}
13461346
}
13471347
}
@@ -1615,7 +1615,7 @@ sealed class ColorSpectrum {
16151615
excludeRadius = false
16161616
)
16171617
?.let { color ->
1618-
state.updateColor(color)
1618+
state.updateColor(color.copy(alpha = state.color.alpha))
16191619
}
16201620
}
16211621
}

0 commit comments

Comments
 (0)