From 9b2d93642e2c94ed96d08858f9e0f737eeba5489 Mon Sep 17 00:00:00 2001 From: lonkaars Date: Tue, 5 Jan 2021 20:39:59 +0100 Subject: home pagina klaar --- src/components/page.tsx | 7 +++-- src/components/vierkant.tsx | 34 ++++++++++++----------- src/global.css | 26 +++++++++++++----- src/pages/home.tsx | 66 ++++++++++++++++++++++++++++++++++----------- 4 files changed, 94 insertions(+), 39 deletions(-) diff --git a/src/components/page.tsx b/src/components/page.tsx index 8fea132..44b00ba 100644 --- a/src/components/page.tsx +++ b/src/components/page.tsx @@ -7,8 +7,11 @@ var CenteredPageStyle: CSSProperties = { export class CenteredPage extends Component { render () { - return
-
{this.props.children}
+ return
+
{this.props.children}
; } } diff --git a/src/components/vierkant.tsx b/src/components/vierkant.tsx index 6140e7a..588d73d 100644 --- a/src/components/vierkant.tsx +++ b/src/components/vierkant.tsx @@ -1,20 +1,24 @@ -import { Component, CSSProperties } from "react"; +import { ReactNode } from "react"; -var VierkantStyle: CSSProperties = { - padding: 24, - backgroundColor: "var(--background)", - borderRadius: 8, - color: "var(--text)", - margin: 6, // geen margin collapse = 12px marge - display: "inline-block", - position: "relative" +interface VierkantProps { + href?: string; + width?: string; + height?: string; + children?: ReactNode; } -export class Vierkant extends Component { - render () { - return
- {this.props.children} -
- } +export function Vierkant(props: VierkantProps) { + return {props.children} } diff --git a/src/global.css b/src/global.css index 9ef59d4..5787cee 100644 --- a/src/global.css +++ b/src/global.css @@ -25,15 +25,27 @@ body { } /* font size */ -html { - font-size: 14px; -} +html { font-size: 14px; } /* link color fix */ -a { - color: var(--text); +a { color: var(--text); } + +/* centering misschien */ +.CenteredPageInner { text-align: center; } +.CenteredPageInner > * { text-align: left; } + +/* line height reset */ +h1, h2, p, span, td, th { + margin: 0; + line-height: 1.2; } -p { - margin: 6px 0; +/* table groottes met percentages werkt nu */ +table { table-layout: fixed; } + +/* table styles */ +td, th { + padding: 4px; + font-size: 15px; } + diff --git a/src/pages/home.tsx b/src/pages/home.tsx index 65f9ead..853dede 100644 --- a/src/pages/home.tsx +++ b/src/pages/home.tsx @@ -38,33 +38,43 @@ var SquareSize: CSSProperties = { height: 90 } +var LeftAlignedTableColumn: CSSProperties = { + textAlign: "left", + paddingLeft: 16 +} + +var RightAlignedTableColumn: CSSProperties = { + textAlign: "right", + paddingRight: 16 +} + function HomePage() { return (
4 op een rij - + Nieuw spel
-
- + + Puzzels
-
- + + Tegen computer
-
- + +
@@ -75,23 +85,49 @@ function HomePage() { }}>

Gebruikersnaam

-

Score: 400

-

- N W +

Score: 400

+

+ 0 W / - N V + 0 V / - N G + 0 G

- + + +

Recente partijen

+ + + + + + + + + + + + + + + + + + + +
TegenstanderUitkomstZettenDatum
Naam hierGewonnen7Vandaag
Nog meer namenGelijkspel42Gisteren
+
+ +

Nieuws ofzo

+

Chess.com heeft heel veel troep waar niemand naar kijkt

+
); -- cgit v1.2.3