summaryrefslogtreecommitdiffhomepage
path: root/src/components
diff options
context:
space:
mode:
authorrealtradam <[email protected]>2024-06-19 19:41:29 -0400
committerrealtradam <[email protected]>2024-06-19 19:41:29 -0400
commitfc6c10718a633f0439b3aac045d4537c58bc7c6e (patch)
treefa6b3a234650a1852e0d1a80e8b5c1b7c00123ac /src/components
parentd477cb8af05a6b8acdb8afa1811777a68e742211 (diff)
downloadmalcz.com-fc6c10718a633f0439b3aac045d4537c58bc7c6e.tar.gz
malcz.com-fc6c10718a633f0439b3aac045d4537c58bc7c6e.zip
add small changes
Diffstat (limited to 'src/components')
-rw-r--r--src/components/Apps.tsx30
-rw-r--r--src/components/CloseWindow.tsx9
-rw-r--r--src/components/Home.tsx2
-rw-r--r--src/components/Layout.tsx5
4 files changed, 41 insertions, 5 deletions
diff --git a/src/components/Apps.tsx b/src/components/Apps.tsx
new file mode 100644
index 0000000..e4dea26
--- /dev/null
+++ b/src/components/Apps.tsx
@@ -0,0 +1,30 @@
+import { useState, useEffect } from "react";
+//import { Link } from "react-router-dom";
+//import GameCard from "./GameCard";
+//import Button from "./Button";
+//import { GameType } from "../types";
+
+
+export default function Apps () {
+ //const [games, setGames] = useState<GameType[]>([]);
+
+
+ return(
+ <>
+ <div>
+ <div className="flex flex-col gap-16 max-w-6xl shrink">
+ <div className="title font-bold text-6xl font-title">Apps</div>
+ <div className="jumbotron jumbotron-fluid bg-transparent">
+ <div className="container secondary-color">
+ </div>
+ </div>
+ <div className="prose prose-invert-off">
+ <h1>Game Holster</h1>
+ <p>This is a work in progress thingie</p>
+ <p>talk about your app here</p>
+ </div>
+ </div>
+ </div>
+ </>
+ );
+}
diff --git a/src/components/CloseWindow.tsx b/src/components/CloseWindow.tsx
index 40c5962..bb33e0a 100644
--- a/src/components/CloseWindow.tsx
+++ b/src/components/CloseWindow.tsx
@@ -1,10 +1,17 @@
//import { Link } from "react-router-dom";
//export default () => (
-export default function Home () {
+export default function CloseWindow () {
+ // trigger localStorage listener in other tabs.
+ // this forces react rerender where required.
localStorage.setItem("logged in trigger", String(Math.random()));
+ // close window once done
window.close();
+
+ // window can only be closed if it was opened by javascript.
+ // if the window was opened by a user then just redirect to
+ // the home page instead.
window.location.replace("/");
return(
diff --git a/src/components/Home.tsx b/src/components/Home.tsx
index 7430549..ec15c9b 100644
--- a/src/components/Home.tsx
+++ b/src/components/Home.tsx
@@ -1,6 +1,4 @@
-//import { Link } from "react-router-dom";
-//export default () => (
export default function Home () {
return(
<>
diff --git a/src/components/Layout.tsx b/src/components/Layout.tsx
index fc50468..3d3747d 100644
--- a/src/components/Layout.tsx
+++ b/src/components/Layout.tsx
@@ -16,11 +16,12 @@ export default function Layout ({userData}: userData)
<nav id="sidebar-content" dir="rtl" className="text-stone-50 p-6 w-full h-screen overflow-y-auto overflow-x-hidden">
<div dir='ltr'>
{ userData.name ? <div className="flex items-end gap-2 pb-2"> <div className="text-xs"> Logged in as: </div> <div>{userData.name}</div> </div> : <a href="" onClick={loginLink} className="pb-2"> Login with Github </a> }
- <div className="text-3xl py-10 text-center font-title">Tradam</div>
+ <div className="text-3xl py-10 text-center font-title">Adam <br/>Malczewski</div>
<div className="flex flex-col items-center gap-1">
<Button link={ <Link to="/" className="absolute flex top-0 left-0 w-36 h-16 text-stone-50 bg-transparent justify-center items-center" role="button"><div className="h-min">About Me</div></Link> }/>
- <Button link={ <Link to="/blogs" className="absolute flex top-0 left-0 w-36 h-16 text-stone-50 bg-transparent justify-center items-center" role="button"><div className="h-min">Blog</div></Link> }/>
+ <Button link={ <Link to="/apps" className="absolute flex top-0 left-0 w-36 h-16 text-stone-50 bg-transparent justify-center items-center" role="button"><div className="h-min">Apps</div></Link> }/>
<Button link={ <Link to="/games" className="absolute flex top-0 left-0 w-36 h-16 text-stone-50 bg-transparent justify-center items-center" role="button"><div className="h-min">Games</div></Link> }/>
+ {/*<Button link={ <Link to="/blogs" className="absolute flex top-0 left-0 w-36 h-16 text-stone-50 bg-transparent justify-center items-center" role="button"><div className="h-min">Blog</div></Link> }/>*/}
<Button link={ <div className="text-stone-50 bg-transparent w-36 h-16 flex justify-center items-center">
<a id="contact" href="mailto:[email protected]" className="w-36 h-16 relative text-center whitespace-nowrap flex justify-center items-center">
<div className="contact w-36 h-16 flex items-center justify-center">