diff --git a/src/Programs/ui/ProgramsRoot.tsx b/src/Programs/ui/ProgramsRoot.tsx index 334fb87e3..f7d5115eb 100644 --- a/src/Programs/ui/ProgramsRoot.tsx +++ b/src/Programs/ui/ProgramsRoot.tsx @@ -2,6 +2,9 @@ import React, { useState, useEffect } from "react"; import { IPlayer } from "../../PersonObjects/IPlayer"; import { getAvailableCreatePrograms } from "../ProgramHelpers"; +import { Box, ButtonGroup, Tooltip, Typography } from "@material-ui/core"; +import Button from "@material-ui/core/Button"; + interface IProps { player: IPlayer; } @@ -19,34 +22,29 @@ export function ProgramsRoot(props: IProps): React.ReactElement { return ( <> -

- This page displays any programs that you are able to create. Writing the code for a program takes time, which - can vary based on how complex the program is. If you are working on creating a program you can cancel at any - time. Your progress will be saved and you can continue later. -

+
+ + + This page displays any programs that you are able to create. Writing the code for a program takes time, which + can vary based on how complex the program is. If you are working on creating a program you can cancel at any + time. Your progress will be saved and you can continue later. + + + + {getAvailableCreatePrograms(props.player).map((program) => { + const create = program.create; + if (create === null) return <>; - -
-
-
-
-
+ return ( + + + + ) + })} +
+
- ); + ) } diff --git a/src/engine.jsx b/src/engine.jsx index 621d3f506..b48e46fb6 100644 --- a/src/engine.jsx +++ b/src/engine.jsx @@ -152,7 +152,7 @@ const Engine = { Engine.Display.content.style.display = "block"; routing.navigateTo(Page.CreateProgram); MainMenuLinks.CreateProgram.classList.add("active"); - ReactDOM.render(, Engine.Display.content); + ReactDOM.render(, Engine.Display.content); }, loadFactionsContent: function () {