Fix issue when certain SVGs cannot be viewed by #1697

This commit is contained in:
T8RIN
2025-02-21 12:43:53 +03:00
parent e332f0dec3
commit a005542272
3 changed files with 13 additions and 6 deletions

View File

@ -128,6 +128,13 @@ dependencies {
implementation(libs.bouncycastle.provider)
}
allprojects {
configurations.all {
resolutionStrategy.dependencySubstitution {
substitute(module("com.caverock:androidsvg-aar:1.4")).using(module("com.github.deckerst:androidsvg:cc9d59a88f"))
}
}
}
afterEvaluate {
android.productFlavors.forEach { flavor ->

View File

@ -190,9 +190,6 @@ fun ImagePager(
Box(
modifier = Modifier
.fillMaxSize()
.background(
MaterialTheme.colorScheme.scrim.copy(alpha = 0.6f * progress)
)
.withLayoutCorners { corners ->
graphicsLayer {
scaleX = scale
@ -201,6 +198,9 @@ fun ImagePager(
clip = true
}
}
.background(
MaterialTheme.colorScheme.scrim.copy(alpha = 0.6f * progress)
)
) {
val moreThanOneUri = (uris?.size ?: 0) > 1

View File

@ -185,9 +185,6 @@ internal fun MediaImagePager(
Box(
modifier = Modifier
.fillMaxSize()
.background(
MaterialTheme.colorScheme.scrim.copy(alpha = 0.6f * progress)
)
.withLayoutCorners { corners ->
graphicsLayer {
scaleX = scale
@ -196,6 +193,9 @@ internal fun MediaImagePager(
clip = true
}
}
.background(
MaterialTheme.colorScheme.scrim.copy(alpha = 0.6f * progress)
)
) {
val moreThanOneUri = media.size > 1
val currentMedia = media.getOrNull(pagerState.currentPage)