一个图标的优化
This commit is contained in:
Binary file not shown.
@@ -13,13 +13,13 @@ struct HomeView: View {
|
|||||||
var body: some View {
|
var body: some View {
|
||||||
ScrollView {
|
ScrollView {
|
||||||
VStack(spacing: 12) {
|
VStack(spacing: 12) {
|
||||||
// Search
|
Search
|
||||||
// Banner
|
// Banner
|
||||||
// Navigation
|
// Navigation
|
||||||
// TodayKill
|
// TodayKill
|
||||||
// Living
|
// Living
|
||||||
// Bestselling
|
// Bestselling
|
||||||
PartyReading
|
// PartyReading
|
||||||
// NewBooks
|
// NewBooks
|
||||||
// Categories
|
// Categories
|
||||||
}
|
}
|
||||||
@@ -271,18 +271,22 @@ struct HomeView: View {
|
|||||||
.padding(12)
|
.padding(12)
|
||||||
.background(Color.white)
|
.background(Color.white)
|
||||||
.cornerRadius(32)
|
.cornerRadius(32)
|
||||||
ZStack {
|
Image(systemName: "bell")
|
||||||
Image(systemName: "bell").resizable().frame(width: 24, height: 24)
|
.resizable()
|
||||||
Text("9")
|
.frame(width: 24, height: 24)
|
||||||
.font(.system(size: 12))
|
.overlay(alignment: .topTrailing) {
|
||||||
.padding(4)
|
Circle()
|
||||||
.frame(minWidth: 24)
|
.fill(Color.red)
|
||||||
.background(Color.red)
|
.frame(width: 20, height: 20)
|
||||||
.foregroundColor(Color.white)
|
.offset(x: 4, y: -8)
|
||||||
.cornerRadius(99)
|
}
|
||||||
.offset(x: 10, y: -10)
|
.overlay(alignment: .topTrailing) {
|
||||||
}
|
Text("20")
|
||||||
.padding(.trailing, 12)
|
.foregroundColor(Color.white)
|
||||||
|
.font(.system(size: 12))
|
||||||
|
.offset(x: 2, y: -5)
|
||||||
|
}
|
||||||
|
Spacer()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user