Skip to content

Commit 9399eee

Browse files
committed
feat: add my lovely new roommate resume website
1 parent 2e26340 commit 9399eee

File tree

15 files changed

+394
-1
lines changed

15 files changed

+394
-1
lines changed

2025/index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
<link rel="preconnect" href="https://fonts.googleapis.com">
88
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
99
<link href="https://fonts.googleapis.com/css2?family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap" rel="stylesheet">
10+
<link href="https://fonts.googleapis.com/css2?family=Henny+Penny&family=Honk&family=IBM+Plex+Mono:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;1,100;1,200;1,300;1,400;1,500;1,600;1,700&family=Italianno&display=swap" rel="stylesheet">
1011
<title>Daniel Fraser - Portfolio</title>
1112
</head>
1213
<body>
1.07 MB
Loading
23.6 MB
Binary file not shown.
12.5 MB
Loading
1.25 MB
Loading
93.4 MB
Binary file not shown.
10.9 MB
Binary file not shown.
13.1 MB
Loading

2025/src/App.tsx

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,14 @@
1-
import { useState, useCallback } from "react";
1+
import { useState, useCallback, useEffect } from "react";
22
import { Routes, Route, useLocation, useNavigate } from "react-router-dom";
33
import { useIsMobile } from "./hooks/useIsMobile";
44
import { useAnimations } from "./hooks/useAnimations";
55
import { PATHS } from "./constants/appStates";
6+
import {
7+
PAGE_CONFIG,
8+
DEFAULT_TITLE,
9+
DEFAULT_FAVICON,
10+
} from "./constants/pageConfig";
11+
import { setFavicon } from "./utils/favicon";
612
import type { NavToggleHandler } from "./types";
713
import { NavigationProvider } from "./contexts/navigation/NavigationProvider";
814

@@ -11,6 +17,7 @@ import { HomePage } from "./components/pages/HomePage";
1117
import { DesignPage } from "./components/pages/DesignPage";
1218
import { DevPage } from "./components/pages/DevPage";
1319
import { AboutPage } from "./components/pages/AboutPage";
20+
import { PleaseLetMeLiveWithYouPage } from "./components/pages/PleaseLetMeLiveWithYouPage";
1421
import { Layout } from "./components/layout/Layout";
1522

1623
// Map paths to their corresponding components
@@ -84,6 +91,21 @@ function App() {
8491
[navOpen]
8592
);
8693

94+
// Update page title and favicon based on current route
95+
useEffect(
96+
function onLocationPathnameChanged() {
97+
const pathname = location.pathname as keyof typeof PAGE_CONFIG;
98+
const config = PAGE_CONFIG[pathname];
99+
100+
// Update title
101+
document.title = config?.title ?? DEFAULT_TITLE;
102+
103+
// Update favicon
104+
setFavicon(config?.favicon, DEFAULT_FAVICON);
105+
},
106+
[location.pathname]
107+
);
108+
87109
return (
88110
<NavigationProvider handleNavClick={handleNavClick}>
89111
<Routes>
@@ -105,6 +127,11 @@ function App() {
105127
}
106128
/>
107129
))}
130+
{/* Independent page - bypasses Layout component */}
131+
<Route
132+
path={PATHS.PLEASE_LET_ME_LIVE_WITH_YOU}
133+
element={<PleaseLetMeLiveWithYouPage />}
134+
/>
108135
</Routes>
109136
</NavigationProvider>
110137
);

2025/src/components/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ export { HomePage } from "./pages/HomePage";
1111
export { DesignPage } from "./pages/DesignPage";
1212
export { DevPage } from "./pages/DevPage";
1313
export { AboutPage } from "./pages/AboutPage";
14+
export { PleaseLetMeLiveWithYouPage } from "./pages/PleaseLetMeLiveWithYouPage";
1415

1516
// Shared components
1617
export { Video } from "./shared/Video";

0 commit comments

Comments
 (0)