Welcome to my Website!

This is a paragraph! Here's how you make a link: Neocities.

Here's how you can make bold and italic text.

Here's how you can add an image:

Site hosted by Neocities

Here's how to make a list:

To learn more HTML/CSS, check out these tutorials!

import React, { useMemo } from 'react'; import { VStack, HStack, Text, Badge, Card, Heading, Box, Button } from '@chakra-ui/react'; import { Calendar, Clock, Award, BookOpen } from 'lucide-react'; import { getDaysDifference, formatDateForDisplay } from '../utils/calendarHelpers'; export default function AgendaView({ assignments, onAssignmentClick, grades, studyTime, onLogStudyTime }) { const groupedAssignments = useMemo(() => { const now = new Date(); const groups = { overdue: [], today: [], thisWeek: [], upcoming: [], noDate: [] }; assignments.forEach(assignment => { if (!assignment.dueDate) { groups.noDate.push(assignment); return; } const diffDays = getDaysDifference(assignment.dueDate, now); if (assignment.status === 'Done') { return; } if (diffDays < 0) { groups.overdue.push(assignment); } else if (diffDays === 0) { groups.today.push(assignment); } else if (diffDays <= 7) { groups.thisWeek.push(assignment); } else { groups.upcoming.push(assignment); } }); return groups; }, [assignments]); const AssignmentCard = ({ assignment }) => { const hasGrade = grades[assignment.id] !== undefined; const hasStudyTime = studyTime[assignment.id] !== undefined; return ( onAssignmentClick(assignment)} cursor="pointer"> {assignment.name} {assignment.status ?? 'Not set'} {assignment.priority && ( {assignment.priority} )} {hasGrade && ( {grades[assignment.id]}% )} {hasStudyTime && ( {studyTime[assignment.id]}h )} {assignment.dueDate && ( {formatDateForDisplay(assignment.dueDate)} )} {assignment.timeline && ( {assignment.timeline} )} ); }; const Section = ({ title, count, items, color = 'blue' }) => { if (items.length === 0) return null; return ( {title} {count} {items.map(assignment => ( ))} ); }; return (
{assignments.filter(a => a.status !== 'Done').length === 0 && ( All caught up! No pending assignments. )} ); } const useWebStorage = () => { const getItem = async (key) => { try { const item = localStorage.getItem(key); if (!item) { return { value: null, version: 0 }; } const parsed = JSON.parse(item); return { value: parsed.value, version: parsed.version || 0 }; } catch (err) { console.error(`Failed to get item ${key}:`, err); return { value: null, version: 0 }; } }; const setItem = async (key, value, version = 0) => { try { const data = { value, version: version + 1, updatedAt: new Date().toISOString() }; localStorage.setItem(key, JSON.stringify(data)); return true; } catch (err) { console.error(`Failed to set item ${key}:`, err); return false; } }; const removeItem = async (key) => { try { localStorage.removeItem(key); return true; } catch (err) { console.error(`Failed to remove item ${key}:`, err); return false; } }; return { getItem, setItem, removeItem }; }; export default useWebStorage;