-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
40 changed files
with
607 additions
and
120 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
67 changes: 52 additions & 15 deletions
67
apps/frontend/src/components/Game/GameBoard/ResultDisplay/index.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,40 @@ | ||
import React from 'react'; | ||
import Header from '../Header'; | ||
import { Outlet, Routes, Route } from 'react-router-dom'; | ||
import PropTypes from 'prop-types'; | ||
|
||
const SetupForm = () => { | ||
const SetupForm = ({ parent }) => { | ||
return ( | ||
<form className="container p-0 bg-light rounded text-dark"> | ||
<div className="container p-0 bg-light rounded text-dark"> | ||
<Header headerText={'Game setup'} /> | ||
</form> | ||
<Routes> | ||
{parent.children.map((child, index) => ( | ||
<Route | ||
path={child.path} | ||
index={child.index} | ||
key={index} | ||
element={ | ||
<child.Element | ||
label={child.elementProps.label} | ||
btnText={child.elementProps.buttonText} | ||
btnColor={child.elementProps.buttonColorClass} | ||
FormElement={child.elementProps.FormElement} | ||
id={child.elementProps.id} | ||
name={child.name} | ||
schema={child.schema} | ||
{...child} | ||
/> | ||
} | ||
/> | ||
))} | ||
</Routes> | ||
<Outlet /> | ||
</div> | ||
); | ||
}; | ||
|
||
SetupForm.propTypes = { | ||
parent: PropTypes.object, | ||
}; | ||
|
||
export default SetupForm; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.