refactor: AsyncImage -> KFImage 로 변경
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
//
|
||||
|
||||
import SwiftUI
|
||||
import Kingfisher
|
||||
|
||||
struct ChatBgSelectionView: View {
|
||||
|
||||
@@ -77,16 +78,17 @@ struct ChatBgSelectionView: View {
|
||||
|
||||
ZStack(alignment: .bottomTrailing) {
|
||||
// 이미지
|
||||
AsyncImage(url: URL(string: item.imageUrl)) { image in
|
||||
image
|
||||
.resizable()
|
||||
.scaledToFill()
|
||||
.frame(width: width, height: height)
|
||||
.clipped()
|
||||
} placeholder: {
|
||||
Rectangle()
|
||||
.fill(Color.gray.opacity(0.3))
|
||||
}
|
||||
KFImage(URL(string: item.imageUrl))
|
||||
.placeholder {
|
||||
Rectangle()
|
||||
.fill(Color.gray.opacity(0.3))
|
||||
}
|
||||
.cancelOnDisappear(true)
|
||||
.downsampling(size: CGSize(width: width, height: height))
|
||||
.resizable()
|
||||
.scaledToFill()
|
||||
.frame(width: width, height: height)
|
||||
.clipped()
|
||||
.overlay {
|
||||
Rectangle()
|
||||
.stroke(lineWidth: 5)
|
||||
|
||||
Reference in New Issue
Block a user