Update ParameterMenuView 🔨

Menu
Emre KARTAL 2 years ago
parent 38fdd33d06
commit 0c163a124b

@ -0,0 +1,38 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0x45",
"green" : "0x45",
"red" : "0x45"
}
},
"idiom" : "universal"
},
{
"appearances" : [
{
"appearance" : "luminosity",
"value" : "dark"
}
],
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0x45",
"green" : "0x45",
"red" : "0x45"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "chevron-left-solid (1) 1.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 959 B

@ -5,9 +5,9 @@
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.173",
"green" : "0.173",
"red" : "0.173"
"blue" : "0x2C",
"green" : "0x2C",
"red" : "0x2C"
}
},
"idiom" : "universal"

@ -0,0 +1,38 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0x89",
"green" : "0x89",
"red" : "0x89"
}
},
"idiom" : "universal"
},
{
"appearances" : [
{
"appearance" : "luminosity",
"value" : "dark"
}
],
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0x89",
"green" : "0x89",
"red" : "0x89"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

@ -13,7 +13,7 @@ struct ContentView: View {
var body: some View {
let drag = DragGesture()
let closeDrag = DragGesture()
.onEnded {
if $0.translation.width < -100 {
withAnimation{
@ -33,8 +33,7 @@ struct ContentView: View {
.transition(.move(edge: .leading))
}
}
.gesture(drag)
.gesture(closeDrag)
}
}
}

@ -18,6 +18,8 @@ struct AllinColor {
static let TopBarColorPink = Color("TopBarColorPink")
static let TopBarColorBlue = Color("TopBarColorBlue")
static let TopBarColorPurple = Color("TopBarColorPurple")
static let DescriptionColorMenu = Color("DescriptionColorMenu")
static let BorderColorMenu = Color("BorderColorMenu")
static let gradiantCard = LinearGradient(
gradient: Gradient(colors: [AllinColor.pinkAccentText, AllinColor.blueAccent]),
startPoint: .bottomLeading,

@ -10,19 +10,20 @@ import SwiftUI
struct MenuView: View {
var body: some View {
VStack(alignment: .leading) {
VStack(alignment: .leading, spacing: 10) {
ParameterMenuView(icon: "VideoGame", title: "CREER UN BET")
.padding(.top, 100)
ParameterMenuView(icon: "VideoGame", title: "CREER UN BET", description: "Créez un nouveau BET et faites participer vos amis.")
.padding([.leading,.trailing], 13)
ParameterMenuView(icon: "Eyes", title: "HISTORIQUE DES BETS")
.padding(.top, 30)
ParameterMenuView(icon: "Eyes", title: "HISTORIQUE DES BETS", description: "Consultez vos paris en cours et terminés.")
.padding([.leading,.trailing], 13)
ParameterMenuView(icon: "Friends", title: "AMIS")
.padding(.top, 30)
ParameterMenuView(icon: "Friends", title: "AMIS", description: "Défiez vos porches en les ajoutant en amis.")
.padding([.leading,.trailing], 13)
ParameterMenuView(icon: "Money", title: "BET EN COURS")
.padding(.top, 30)
ParameterMenuView(icon: "Money", title: "BET EN COURS", description: "Gérez vos bets et récompensez les gagnants.")
.padding([.leading,.trailing], 13)
Spacer()
Image("GearIcon")
.resizable()

@ -11,16 +11,30 @@ struct ParameterMenuView: View {
var icon: String
var title: String
var description: String
var body: some View {
HStack {
Image(icon)
Text(title)
.foregroundColor(.white)
.font(.headline)
VStack(alignment: .leading){
Text(title)
.betTextStyle(weight: .bold, color: .white, size: 13)
Text(description)
.betTextStyle(weight: .bold, color: AllinColor.DescriptionColorMenu, size: 9)
}
Spacer()
Image("ChevronRightIcon")
.resizable()
.frame(width: 10, height: 18)
}
.padding([.leading,.trailing], 10)
.padding([.top,.bottom], 15)
.background(AllinColor.darkLight)
.cornerRadius(12)
.overlay(
RoundedRectangle(cornerRadius: 12, style: .continuous)
.stroke(AllinColor.BorderColorMenu, lineWidth: 3)
)
.clipShape(RoundedRectangle(cornerRadius: 12, style: .continuous))
}
}

@ -71,7 +71,6 @@ struct TrendingBetCard: View {
}
.frame(height: 127, alignment: .topLeading)
.background(AllinColor.darkerGray)
.overlay(
RoundedRectangle(cornerRadius: 20, style: .continuous)
.stroke(AllinColor.gradiantCard, lineWidth: 5)

Loading…
Cancel
Save