홈 - 크리에이터 랭킹 뱃지 변경
This commit is contained in:
21
SodaLive/Resources/Assets.xcassets/img_rank_1.imageset/Contents.json
vendored
Normal file
21
SodaLive/Resources/Assets.xcassets/img_rank_1.imageset/Contents.json
vendored
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
{
|
||||||
|
"images" : [
|
||||||
|
{
|
||||||
|
"filename" : "img_rank_1.png",
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "1x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "2x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "3x"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"info" : {
|
||||||
|
"author" : "xcode",
|
||||||
|
"version" : 1
|
||||||
|
}
|
||||||
|
}
|
||||||
BIN
SodaLive/Resources/Assets.xcassets/img_rank_1.imageset/img_rank_1.png
vendored
Normal file
BIN
SodaLive/Resources/Assets.xcassets/img_rank_1.imageset/img_rank_1.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 16 KiB |
21
SodaLive/Resources/Assets.xcassets/img_rank_2.imageset/Contents.json
vendored
Normal file
21
SodaLive/Resources/Assets.xcassets/img_rank_2.imageset/Contents.json
vendored
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
{
|
||||||
|
"images" : [
|
||||||
|
{
|
||||||
|
"filename" : "img_rank_2.png",
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "1x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "2x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "3x"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"info" : {
|
||||||
|
"author" : "xcode",
|
||||||
|
"version" : 1
|
||||||
|
}
|
||||||
|
}
|
||||||
BIN
SodaLive/Resources/Assets.xcassets/img_rank_2.imageset/img_rank_2.png
vendored
Normal file
BIN
SodaLive/Resources/Assets.xcassets/img_rank_2.imageset/img_rank_2.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 16 KiB |
21
SodaLive/Resources/Assets.xcassets/img_rank_3.imageset/Contents.json
vendored
Normal file
21
SodaLive/Resources/Assets.xcassets/img_rank_3.imageset/Contents.json
vendored
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
{
|
||||||
|
"images" : [
|
||||||
|
{
|
||||||
|
"filename" : "img_rank_3.png",
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "1x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "2x"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"idiom" : "universal",
|
||||||
|
"scale" : "3x"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"info" : {
|
||||||
|
"author" : "xcode",
|
||||||
|
"version" : 1
|
||||||
|
}
|
||||||
|
}
|
||||||
BIN
SodaLive/Resources/Assets.xcassets/img_rank_3.imageset/img_rank_3.png
vendored
Normal file
BIN
SodaLive/Resources/Assets.xcassets/img_rank_3.imageset/img_rank_3.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 16 KiB |
@@ -1,12 +0,0 @@
|
|||||||
{
|
|
||||||
"images" : [
|
|
||||||
{
|
|
||||||
"filename" : "rank_1.pdf",
|
|
||||||
"idiom" : "universal"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"info" : {
|
|
||||||
"author" : "xcode",
|
|
||||||
"version" : 1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Binary file not shown.
@@ -1,12 +0,0 @@
|
|||||||
{
|
|
||||||
"images" : [
|
|
||||||
{
|
|
||||||
"filename" : "rank_2.pdf",
|
|
||||||
"idiom" : "universal"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"info" : {
|
|
||||||
"author" : "xcode",
|
|
||||||
"version" : 1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Binary file not shown.
@@ -1,12 +0,0 @@
|
|||||||
{
|
|
||||||
"images" : [
|
|
||||||
{
|
|
||||||
"filename" : "rank_3.pdf",
|
|
||||||
"idiom" : "universal"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"info" : {
|
|
||||||
"author" : "xcode",
|
|
||||||
"version" : 1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Binary file not shown.
@@ -15,19 +15,27 @@ struct HomeCreatorRankingItemView: View {
|
|||||||
|
|
||||||
let onClickFollow: (Int, Bool) -> Void
|
let onClickFollow: (Int, Bool) -> Void
|
||||||
|
|
||||||
let crowns = ["rank_1", "rank_2", "rank_3"]
|
let crowns = ["img_rank_1", "img_rank_2", "img_rank_3"]
|
||||||
|
|
||||||
@AppStorage("token") private var token: String = UserDefaults.string(forKey: UserDefaultsKey.token)
|
@AppStorage("token") private var token: String = UserDefaults.string(forKey: UserDefaultsKey.token)
|
||||||
|
|
||||||
var body: some View {
|
var body: some View {
|
||||||
ZStack(alignment: .topLeading) {
|
|
||||||
VStack(spacing: 0) {
|
VStack(spacing: 0) {
|
||||||
|
ZStack(alignment: .center) {
|
||||||
DownsampledKFImage(
|
DownsampledKFImage(
|
||||||
url: URL(string: item.profileImageUrl),
|
url: URL(string: item.profileImageUrl),
|
||||||
size: CGSize(width: 84, height: 84)
|
size: CGSize(width: 84, height: 84)
|
||||||
)
|
)
|
||||||
.clipShape(Circle())
|
.clipShape(Circle())
|
||||||
|
|
||||||
|
if rank <= 3 {
|
||||||
|
Image(crowns[rank - 1])
|
||||||
|
.resizable()
|
||||||
|
.frame(width: 108, height: 105)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.frame(width: 108, height: 105)
|
||||||
|
|
||||||
Text(item.nickname)
|
Text(item.nickname)
|
||||||
.font(.custom(Font.preRegular.rawValue, size: 16))
|
.font(.custom(Font.preRegular.rawValue, size: 16))
|
||||||
.foregroundColor(.white)
|
.foregroundColor(.white)
|
||||||
@@ -61,14 +69,6 @@ struct HomeCreatorRankingItemView: View {
|
|||||||
.background(Color(hex: "263238"))
|
.background(Color(hex: "263238"))
|
||||||
.cornerRadius(16)
|
.cornerRadius(16)
|
||||||
.padding(.top, 20)
|
.padding(.top, 20)
|
||||||
|
|
||||||
if rank <= 3 {
|
|
||||||
Image(crowns[rank - 1])
|
|
||||||
.resizable()
|
|
||||||
.frame(width: 40, height: 40)
|
|
||||||
.padding(.leading, 10)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user