From e014ded82a630bd91b15be4307125f5580119f4d Mon Sep 17 00:00:00 2001 From: Adam Mathes Date: Fri, 13 Feb 2026 13:50:25 -0800 Subject: Analyze page size and fix frontend tests --- frontend/coverage/src/App.tsx.html | 46 ++++++++++++-------------------------- 1 file changed, 14 insertions(+), 32 deletions(-) (limited to 'frontend/coverage/src/App.tsx.html') diff --git a/frontend/coverage/src/App.tsx.html b/frontend/coverage/src/App.tsx.html index 956b16a..0d5195d 100644 --- a/frontend/coverage/src/App.tsx.html +++ b/frontend/coverage/src/App.tsx.html @@ -23,9 +23,9 @@
- 73.68% + 78.94% Statements - 14/19 + 15/19
@@ -44,9 +44,9 @@
- 73.68% + 78.94% Lines - 14/19 + 15/19
@@ -153,13 +153,7 @@ 88 89 90 -91 -92 -93 -94 -95 -96 -97  +91        @@ -198,21 +192,14 @@     1x +1x         -  -        -  -  -  -  -  -  1x 1x   @@ -237,6 +224,7 @@       +  2x     @@ -256,7 +244,7 @@      
import React, { useEffect, useState } from 'react';
-import { BrowserRouter, Routes, Route, Navigate, useLocation } from 'react-router-dom';
+import { BrowserRouter, Routes, Route, Navigate, useLocation, useNavigate } from 'react-router-dom';
 import Login from './components/Login';
 import './App.css';
  
@@ -293,24 +281,17 @@ import FeedItems from './components/FeedItems';
 import Settings from './components/Settings';
  
 function Dashboard() {
+  const navigate = useNavigate();
   return (
     <div className="dashboard">
       <header className="dashboard-header">
         <h1>Neko Reader</h1>
         <nav>
-          <a href="/settings" onClick={(e) => {
-            e.preventDefault();
-            window.history.pushState({}, '', '/settings');
-            // Quick hack for navigation without full router link if inside Router context, 
-            // but here we are inside BrowserRouter so we should use Link or just simple navigation
-            // actually let's just use a real Link if we can, but we need import.
-            // For now, let's just rely on the Router catching the URL change if we use proper Link
-            // or just a button that navigates.
-          }} style={{ color: 'white', marginRight: '1rem' }}>Settings</a>
+          <button onClick={() => navigate('/settings')} className="nav-link" style={{ color: 'white', marginRight: '1rem', background: 'none', border: 'none', cursor: 'pointer', fontSize: 'inherit', fontFamily: 'inherit' }}>Settings</button>
  
           <button onClick={() => {
             fetch('/api/logout', { method: 'POST' })
-              .then(() => window.location.href = '/login/');
+              .then(() => window.location.href = '/v2/login');
           }} className="logout-btn">
             Logout
           </button>
@@ -323,8 +304,9 @@ function Dashboard() {
         <main className="dashboard-main">
           <Routes>
             <Route path="/feed/:feedId" element={<FeedItems />} />
+            <Route path="/tag/:tagName" element={<FeedItems />} />
             <Route path="/settings" element={<Settings />} />
-            <Route path="/" element={<p>Select a feed to view items.</p>} />
+            <Route path="/" element={<FeedItems />} />
           </Routes>
         </main>
       </div>
@@ -358,7 +340,7 @@ export default App;