🚧 adding GameResumeFrame

dev_views_Historic
Rémi REGNAULT 11 months ago
parent 38b104d059
commit 74f9d011e4

@ -7,6 +7,7 @@
objects = {
/* Begin PBXBuildFile section */
643AB6932BFCEFD00018DA73 /* GameResumeFrame.swift in Sources */ = {isa = PBXBuildFile; fileRef = 643AB6922BFCEFD00018DA73 /* GameResumeFrame.swift */; };
6458345C2BF5F92300E18321 /* DouShouQi_AppApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6458345B2BF5F92300E18321 /* DouShouQi_AppApp.swift */; };
6458345E2BF5F92300E18321 /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6458345D2BF5F92300E18321 /* ContentView.swift */; };
645834602BF5F92500E18321 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 6458345F2BF5F92500E18321 /* Assets.xcassets */; };
@ -61,6 +62,7 @@
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
643AB6922BFCEFD00018DA73 /* GameResumeFrame.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GameResumeFrame.swift; sourceTree = "<group>"; };
645834582BF5F92300E18321 /* DouShouQi_App.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = DouShouQi_App.app; sourceTree = BUILT_PRODUCTS_DIR; };
6458345B2BF5F92300E18321 /* DouShouQi_AppApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DouShouQi_AppApp.swift; sourceTree = "<group>"; };
6458345D2BF5F92300E18321 /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = "<group>"; };
@ -112,6 +114,14 @@
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
643AB6912BFCEFB70018DA73 /* Game */ = {
isa = PBXGroup;
children = (
643AB6922BFCEFD00018DA73 /* GameResumeFrame.swift */,
);
path = Game;
sourceTree = "<group>";
};
6458344F2BF5F92300E18321 = {
isa = PBXGroup;
children = (
@ -209,6 +219,7 @@
649ABF5E2BF60ED5002E8894 /* Components */ = {
isa = PBXGroup;
children = (
643AB6912BFCEFB70018DA73 /* Game */,
645B4C1C2BFCC95000FD658A /* Player */,
649ABF5F2BF60F2D002E8894 /* MainMenuButton.swift */,
649B59A32BF64574002BAE38 /* TitlePageFrame.swift */,
@ -392,6 +403,7 @@
645B4C252BFCD3C600FD658A /* ScoreBoardView.swift in Sources */,
649B59AE2BF64EAB002BAE38 /* AppImages.swift in Sources */,
649ABF602BF60F2D002E8894 /* MainMenuButton.swift in Sources */,
643AB6932BFCEFD00018DA73 /* GameResumeFrame.swift in Sources */,
649B59B22BF65392002BAE38 /* TextStyles.swift in Sources */,
6458345C2BF5F92300E18321 /* DouShouQi_AppApp.swift in Sources */,
645B4C202BFCCA0500FD658A /* PlayerResumeFrame.swift in Sources */,

@ -0,0 +1,51 @@
//
// GameResumeFrame.swift
// DouShouQi_App
//
// Created by Rémi REGNAULT on 21/05/2024.
//
import SwiftUI
struct GameResumeFrame: View {
// Players Params
let Player1Name: String
let Player2Name: String
// Game Params
let Status: String
var body: some View {
ZStack {
HStack(alignment: .center) {
VStack(alignment: .leading) {
Text("\(Player1Name) vs \(Player2Name)")
.font(.headline)
Text(Status)
.font(.subheadline)
.foregroundColor(.gray)
}
Spacer()
Text("Detail >")
.frame(width: 100)
.foregroundColor(.gray)
}
.padding(10)
.overlay(
RoundedRectangle(cornerRadius: 3)
.stroke(.gray, lineWidth: 2)
)
}.padding(10)
}
}
struct GameResumeFrame_Previews: PreviewProvider {
static var previews: some View {
GameResumeFrame(Player1Name: "Rayhan", Player2Name: "Remi", Status: "Winner: Remi")
}
}
Loading…
Cancel
Save