From d2f537f86890949a0d29a5b1761628ea87a9b3c9 Mon Sep 17 00:00:00 2001 From: lonkaars Date: Sun, 31 Jan 2021 14:30:02 +0100 Subject: editGameSettings dialog --- components/dialogBox.tsx | 15 ++-- components/gameSettings.tsx | 212 +++++++++++++++++++++++++------------------- 2 files changed, 128 insertions(+), 99 deletions(-) (limited to 'components') diff --git a/components/dialogBox.tsx b/components/dialogBox.tsx index 74fe99b..5ef5c3f 100644 --- a/components/dialogBox.tsx +++ b/components/dialogBox.tsx @@ -1,23 +1,25 @@ -import { ReactNode } from 'react'; +import { ReactNode, CSSProperties } from 'react'; import { Vierkant } from './ui'; import CancelIcon from '@material-ui/icons/Cancel'; -interface DialogBoxProps { +export function DialogBox(props: { children: ReactNode; title: string; -} - -export function DialogBox(props: DialogBoxProps) { + style?: CSSProperties; + onclick?: () => void; +}) { return

{props.title}

+ + {props.children}
} diff --git a/components/gameSettings.tsx b/components/gameSettings.tsx index fb5188e..c037fe3 100644 --- a/components/gameSettings.tsx +++ b/components/gameSettings.tsx @@ -1,49 +1,63 @@ -import { ReactNode, CSSProperties } from 'react'; +import { ReactNode, Component } from 'react'; import { Button, Vierkant, CheckBox, Input } from './ui'; import { DialogBox } from './dialogBox'; import BuildRoundedIcon from '@material-ui/icons/BuildRounded'; -export function CurrentGameSettings(/*props: CurrentGameSettingsProps*/) { - return
-

- Geen tijdslimiet
- Standaardregels
- Gerangschikt -

- -
; + left: 0, + transform: "translateY(-50%)" + }}> + Geen tijdslimiet
+ Standaardregels
+ Gerangschikt +

+ + + ; + } } function GameSettingsSection(props: { @@ -73,62 +87,74 @@ function GameSettingsSection(props: { } -function GameRule(props: { - title: string; - description: string; - style?: CSSProperties; -}) { - return
*/ +/*

{props.title}

*/ +/*

{props.description}

*/ +/*
; */ +/* } */ + +/* + +
-

{props.title}

-

{props.description}

-
; -} + + + + + +
+*/ -export function EditGameSettings() { - return -
- -
- - - -
- - Timer gebruiken voor bijde spelers -
- -
- - -
- - -
- -
-
; +export class EditGameSettings extends Component<{ + parentState: { editGameRulesDialogVisible: boolean; }; + hideEditGameRules: () => void; +}> { + + render () { + return +
+ +
+ + + +
+ + Timer gebruiken voor bijde spelers +
+ +
+
; + } } -- cgit v1.2.3