diff --git a/frontend/src/App.js b/frontend/src/App.js
index 002acef..b6c493d 100644
--- a/frontend/src/App.js
+++ b/frontend/src/App.js
@@ -178,6 +178,7 @@ export default function App() {
const [quickCheckResult, setQuickCheckResult] = useState(null);
const [currentPage, setCurrentPage] = useState('home');
const [navOpen, setNavOpen] = useState(false);
+ const [calendarFilter, setCalendarFilter] = useState(null);
const [showAddCVE, setShowAddCVE] = useState(false);
const [showUserManagement, setShowUserManagement] = useState(false);
const [showAuditLog, setShowAuditLog] = useState(false);
@@ -961,7 +962,11 @@ export default function App() {
isOpen={navOpen}
onClose={() => setNavOpen(false)}
currentPage={currentPage}
- onNavigate={setCurrentPage}
+ onNavigate={(page) => {
+ // Clear calendar filter when navigating directly via the nav drawer
+ if (page === 'reporting') setCalendarFilter(null);
+ setCurrentPage(page);
+ }}
/>
{/* Scanning line effect */}
@@ -1036,7 +1041,7 @@ export default function App() {
{/* Page content */}
- {currentPage === 'reporting' && }
+ {currentPage === 'reporting' && }
{currentPage === 'knowledge-base' && }
{currentPage === 'exports' && }
@@ -2220,7 +2225,12 @@ export default function App() {
Calendar
-
+ {
+ setCalendarFilter(dateStr);
+ setCurrentPage('reporting');
+ }}
+ />
{/* Open Vendor Tickets */}
diff --git a/frontend/src/components/CalendarWidget.js b/frontend/src/components/CalendarWidget.js
index 1a9771a..bddc758 100644
--- a/frontend/src/components/CalendarWidget.js
+++ b/frontend/src/components/CalendarWidget.js
@@ -16,7 +16,7 @@ function toLocalDateStr(date) {
return `${y}-${m}-${d}`;
}
-export default function CalendarWidget() {
+export default function CalendarWidget({ onDateClick }) {
const today = new Date();
const todayStr = toLocalDateStr(today);
@@ -116,15 +116,19 @@ export default function CalendarWidget() {
return (
1 ? 's' : ''} due` : undefined}
+ title={hasDue ? `${dueCount} finding${dueCount > 1 ? 's' : ''} due — click to view` : undefined}
+ onClick={hasDue && onDateClick ? () => onDateClick(dateStr) : undefined}
style={{
display: 'flex', flexDirection: 'column', alignItems: 'center',
gap: '2px', padding: '3px 1px',
borderRadius: '4px',
background: isToday ? 'rgba(14,165,233,0.2)' : 'transparent',
border: isToday ? '1px solid rgba(14,165,233,0.5)' : '1px solid transparent',
- cursor: hasDue ? 'default' : 'default',
+ cursor: hasDue ? 'pointer' : 'default',
+ transition: hasDue ? 'background 0.15s' : undefined,
}}
+ onMouseEnter={hasDue ? (e) => { e.currentTarget.style.background = isToday ? 'rgba(14,165,233,0.35)' : 'rgba(239,68,68,0.15)'; } : undefined}
+ onMouseLeave={hasDue ? (e) => { e.currentTarget.style.background = isToday ? 'rgba(14,165,233,0.2)' : 'transparent'; } : undefined}
>
+ filterDate ? { dueDate: new Set([filterDate]) } : {}
+ );
const [openFilter, setOpenFilter] = useState(null);
const filterBtnRefs = useRef({});