betcard finish

pull/3/head
lucas delanier 2 years ago
parent 63d2814784
commit 563bf353a8

@ -16,6 +16,9 @@
D98C4D7F2AB9D019007A6B4D /* AllInUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D98C4D7E2AB9D019007A6B4D /* AllInUITests.swift */; };
D98C4D812AB9D019007A6B4D /* AllInUITestsLaunchTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D98C4D802AB9D019007A6B4D /* AllInUITestsLaunchTests.swift */; };
D98C4D8E2AB9D440007A6B4D /* TopBarView.swift in Sources */ = {isa = PBXBuildFile; fileRef = D98C4D8D2AB9D440007A6B4D /* TopBarView.swift */; };
EC2C1EEB2AC08BE80091D57C /* BetCard.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC2C1EEA2AC08BE80091D57C /* BetCard.swift */; };
EC2C1EED2AC093820091D57C /* TextCapsule.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC2C1EEC2AC093820091D57C /* TextCapsule.swift */; };
EC2C1EEF2AC098D30091D57C /* UsersPreview.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC2C1EEE2AC098D30091D57C /* UsersPreview.swift */; };
EC46D7DD2ABCCC270030AC04 /* MenuView.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC46D7DC2ABCCC270030AC04 /* MenuView.swift */; };
EC46D7DF2ABCE0A20030AC04 /* ParameterMenuView.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC46D7DE2ABCE0A20030AC04 /* ParameterMenuView.swift */; };
EC50BF962ABF4D3300197685 /* SplashScreen.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC50BF952ABF4D3300197685 /* SplashScreen.swift */; };
@ -57,6 +60,9 @@
D98C4D802AB9D019007A6B4D /* AllInUITestsLaunchTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AllInUITestsLaunchTests.swift; sourceTree = "<group>"; };
D98C4D8D2AB9D440007A6B4D /* TopBarView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TopBarView.swift; sourceTree = "<group>"; };
EC0EA7AF2ABDAAD1006BA4A0 /* PlusJakartaSans.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = PlusJakartaSans.ttf; sourceTree = "<group>"; };
EC2C1EEA2AC08BE80091D57C /* BetCard.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = BetCard.swift; path = allin/Views/BetCard.swift; sourceTree = SOURCE_ROOT; };
EC2C1EEC2AC093820091D57C /* TextCapsule.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = TextCapsule.swift; path = allin/Views/TextCapsule.swift; sourceTree = SOURCE_ROOT; };
EC2C1EEE2AC098D30091D57C /* UsersPreview.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = UsersPreview.swift; path = allin/Views/UsersPreview.swift; sourceTree = SOURCE_ROOT; };
EC46D7DC2ABCCC270030AC04 /* MenuView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = MenuView.swift; path = allin/Views/MenuView.swift; sourceTree = SOURCE_ROOT; };
EC46D7DE2ABCE0A20030AC04 /* ParameterMenuView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = ParameterMenuView.swift; path = allin/Views/ParameterMenuView.swift; sourceTree = SOURCE_ROOT; };
EC50BF952ABF4D3300197685 /* SplashScreen.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = SplashScreen.swift; path = allin/Screens/SplashScreen.swift; sourceTree = SOURCE_ROOT; };
@ -100,6 +106,9 @@
EC87FCDA2ABBA6AC00363986 /* TrendingBetCard.swift */,
EC46D7DC2ABCCC270030AC04 /* MenuView.swift */,
EC46D7DE2ABCE0A20030AC04 /* ParameterMenuView.swift */,
EC2C1EEA2AC08BE80091D57C /* BetCard.swift */,
EC2C1EEC2AC093820091D57C /* TextCapsule.swift */,
EC2C1EEE2AC098D30091D57C /* UsersPreview.swift */,
);
path = Views;
sourceTree = "<group>";
@ -331,15 +340,18 @@
files = (
EC87FCD62ABBA24000363986 /* Extensions.swift in Sources */,
EC46D7DD2ABCCC270030AC04 /* MenuView.swift in Sources */,
EC2C1EEB2AC08BE80091D57C /* BetCard.swift in Sources */,
EC87FCD92ABBA60900363986 /* Colors.swift in Sources */,
D98C4D662AB9D017007A6B4D /* ContentView.swift in Sources */,
D92EC57C2ABADA2800CCD30E /* CoinCounterView.swift in Sources */,
EC2C1EED2AC093820091D57C /* TextCapsule.swift in Sources */,
D98C4D8E2AB9D440007A6B4D /* TopBarView.swift in Sources */,
EC50BF962ABF4D3300197685 /* SplashScreen.swift in Sources */,
EC9A45B02ABDF4A800125D41 /* HomeScreen.swift in Sources */,
EC46D7DF2ABCE0A20030AC04 /* ParameterMenuView.swift in Sources */,
EC50BF982ABF541B00197685 /* WelcomeScreen.swift in Sources */,
D98C4D642AB9D017007A6B4D /* AllInApp.swift in Sources */,
EC2C1EEF2AC098D30091D57C /* UsersPreview.swift in Sources */,
EC87FCDB2ABBA6AC00363986 /* TrendingBetCard.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;

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

@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "Ellipse 1-2.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: 20 KiB

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

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

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

@ -5,9 +5,9 @@
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0xF3",
"green" : "0x7E",
"red" : "0xAA"
"blue" : "0.953",
"green" : "0.494",
"red" : "0.667"
}
},
"idiom" : "universal"

@ -22,7 +22,13 @@ struct AllinColor {
static let TopBarColorBlue = Color("TopBarColorBlue")
static let TopBarColorPurple = Color("TopBarColorPurple")
static let DescriptionColorMenu = Color("DescriptionColorMenu")
static let lightGray = Color("LightGray")
static let BorderColorMenu = Color("BorderColorMenu")
static let PrimaryTextColor = Color("PrimaryTextColor")
static let DelimiterGray = Color("DelimiterGray")
static let CapsuleGray = Color("CapsuleGray")
static let gradiantCard = LinearGradient(
gradient: Gradient(colors: [AllinColor.pinkAccentText, AllinColor.blueAccent]),
startPoint: .bottomLeading,

@ -15,12 +15,13 @@ struct Home: View {
VStack(alignment: .center, spacing: 0) {
TopBarView(showMenu: self.$showMenu)
ScrollView{
TrendingBetCard()
}
TrendingBetCard().padding(.top,25)
BetCard()
}.padding([.leading,.trailing],25)
Spacer()
}
.edgesIgnoringSafeArea(.bottom)
.edgesIgnoringSafeArea(.bottom).background(AllinColor.backgroundWhite)
}
}

@ -0,0 +1,72 @@
//
// BetCard.swift
// AllIn
//
// Created by étudiant on 24/09/2023.
//
import SwiftUI
struct BetCard: View {
var body: some View {
VStack(spacing: 0){
VStack(alignment: .leading,spacing: 2){
HStack{
Spacer()
Text("proposé par Lucas").font(.system(size: 10)).foregroundColor(AllinColor.lightGray)
}
Text("Etudes").font(.system(size: 15)).foregroundColor(AllinColor.lightGray)
Text("Emre va réussir son TP de CI/CD mercredi?").font(.system(size: 20)).fontWeight(.bold)
HStack{
Text("Commence le").font(.system(size: 15)).foregroundColor(AllinColor.lightGray)
TextCapsule()
TextCapsule()
Spacer()
}
}.frame(width: .infinity).padding(.all,15)
.background(.white).cornerRadius(20, corners: [.topLeft,.topRight]).padding(.bottom,0)
VStack(alignment: .leading,spacing: 2){
HStack{
Spacer()
UsersPreview()
Text(" 4 joueurs en attente").font(.system(size: 15)).foregroundColor(AllinColor.lightGray).fontWeight(.medium)
Spacer()
}.padding(0)
Button {
} label: {
Text("Participer")
.font(.system(size: 30))
.fontWeight(.bold)
.frame(maxWidth: .infinity).padding(10)
.multilineTextAlignment(.center)
.overlay {
AllinColor.gradiantCard.frame(width: 170)
.mask(
Text("Participer")
.font(.system(size: 30))
.fontWeight(.bold)
.frame(maxWidth: .infinity).padding(10)
)
}
}
.accentColor(.white)
.buttonStyle(.borderedProminent).padding([.top],5)
}.frame(width: .infinity).padding(.all,8)
.background(AllinColor.CapsuleGray).cornerRadius(20, corners: [.bottomLeft,.bottomRight]).padding(.bottom,0).border(width: 1, edges: [.top], color: AllinColor.DelimiterGray)
}
}
}
struct BetCard_Previews: PreviewProvider {
static var previews: some View {
BetCard()
}
}

@ -0,0 +1,23 @@
//
// TextCapsule.swift
// AllIn
//
// Created by étudiant on 24/09/2023.
//
import SwiftUI
struct TextCapsule: View {
var body: some View {
Text("12 sept.").font(.system(size: 15)).foregroundColor(AllinColor.PrimaryTextColor).fontWeight(.bold).padding([.leading,.trailing],10).padding([.top,.bottom], 5).background(AllinColor.CapsuleGray).clipShape(Capsule()).overlay( /// apply a rounded border
RoundedRectangle(cornerRadius: 20)
.stroke(AllinColor.DelimiterGray, lineWidth: 1)
)
}
}
struct TextCapsule_Previews: PreviewProvider {
static var previews: some View {
TextCapsule()
}
}

@ -76,7 +76,6 @@ struct TrendingBetCard: View {
.stroke(AllinColor.gradiantCard, lineWidth: 5)
)
.clipShape(RoundedRectangle(cornerRadius: 20, style: .continuous))
.padding([.leading, .trailing], 20)
}
}

@ -0,0 +1,33 @@
//
// UsersPreview.swift
// AllIn
//
// Created by étudiant on 24/09/2023.
//
import SwiftUI
struct UsersPreview: View {
var body: some View {
HStack(spacing: -20){
Image("DefaultUserIcon")
.resizable()
.frame(width: 35, height: 35)
Image("DefaultUserIcon")
.resizable()
.frame(width: 35, height: 35)
Image("DefaultUserIcon")
.resizable()
.frame(width: 35, height: 35)
Image("DefaultUserIcon")
.resizable()
.frame(width: 35, height: 35)
}
}
}
struct UsersPreview_Previews: PreviewProvider {
static var previews: some View {
UsersPreview()
}
}
Loading…
Cancel
Save