mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-02 21:32:34 +00:00
Fix gradient on GradientFloatingActionButton
This commit is contained in:
committed by
Benoit Marty
parent
61a6e8dcf4
commit
0a62d40d1d
+2
-1
@@ -27,6 +27,7 @@ import androidx.compose.ui.draw.drawBehind
|
|||||||
import androidx.compose.ui.geometry.Offset
|
import androidx.compose.ui.geometry.Offset
|
||||||
import androidx.compose.ui.geometry.Size
|
import androidx.compose.ui.geometry.Size
|
||||||
import androidx.compose.ui.geometry.center
|
import androidx.compose.ui.geometry.center
|
||||||
|
import androidx.compose.ui.graphics.BlendMode
|
||||||
import androidx.compose.ui.graphics.Color
|
import androidx.compose.ui.graphics.Color
|
||||||
import androidx.compose.ui.graphics.LinearGradientShader
|
import androidx.compose.ui.graphics.LinearGradientShader
|
||||||
import androidx.compose.ui.graphics.RadialGradientShader
|
import androidx.compose.ui.graphics.RadialGradientShader
|
||||||
@@ -97,8 +98,8 @@ fun GradientFloatingActionButton(
|
|||||||
.graphicsLayer(shape = shape, clip = false)
|
.graphicsLayer(shape = shape, clip = false)
|
||||||
.clip(shape)
|
.clip(shape)
|
||||||
.drawBehind {
|
.drawBehind {
|
||||||
drawRect(brush = radialShaderBrush, alpha = 0.4f)
|
|
||||||
drawRect(brush = linearShaderBrush)
|
drawRect(brush = linearShaderBrush)
|
||||||
|
drawRect(brush = radialShaderBrush, alpha = 0.4f, blendMode = BlendMode.Overlay)
|
||||||
}
|
}
|
||||||
.clickable(
|
.clickable(
|
||||||
enabled = true,
|
enabled = true,
|
||||||
|
|||||||
Reference in New Issue
Block a user