Skip to content

Commit

Permalink
remove background color
Browse files Browse the repository at this point in the history
  • Loading branch information
0xZhangKe committed Jul 28, 2024
1 parent a07ba1c commit adca546
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.zhangke.imageviewer

import androidx.compose.foundation.background
import androidx.compose.foundation.gestures.detectDragGestures
import androidx.compose.foundation.gestures.detectTapGestures
import androidx.compose.foundation.gestures.detectVerticalDragGestures
Expand All @@ -16,7 +15,6 @@ import androidx.compose.runtime.setValue
import androidx.compose.ui.Modifier
import androidx.compose.ui.geometry.Offset
import androidx.compose.ui.geometry.Size
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.input.pointer.pointerInput
import androidx.compose.ui.input.pointer.util.VelocityTracker
import androidx.compose.ui.input.pointer.util.addPointerInputChange
Expand Down Expand Up @@ -91,11 +89,10 @@ fun ImageViewer(
modifier = Modifier
.offset(
x = state.currentOffsetXPixel.pxToDp(density),
y = state.currentOffsetYPixel.pxToDp(density)
y = state.currentOffsetYPixel.pxToDp(density),
)
.width(state.currentWidthPixel.pxToDp(density))
.height(state.currentHeightPixel.pxToDp(density))
.background(Color.Yellow),
.height(state.currentHeightPixel.pxToDp(density)),
content = {
content()
},
Expand Down
2 changes: 1 addition & 1 deletion sample/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ android {
dependencies {
testImplementation(libs.junit)
androidTestImplementation(libs.androidx.espresso.core)
implementation("com.github.0xZhangKe:ImageViewer:1.0.0")
implementation("com.github.0xZhangKe:ImageViewer:1.0.2")

implementation(libs.androidx.activity.ktx)
implementation(libs.androidx.core.ktx)
Expand Down

0 comments on commit adca546

Please sign in to comment.