grvverma's picture
You are a skilled web developer and product designer. Build functional pages for an AI-powered study web app that includes these core sections: **Quizzes**, **Notes**, and **Pricing**.
114b4e0 verified
Raw History Blame Contribute Delete
15.3 kB
<!DOCTYPE html>
<html lang="en" class="h-full">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Notes | BrainyBytes AI</title>
<link rel="stylesheet" href="style.css">
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://unpkg.com/feather-icons"></script>
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
</head>
<body class="bg-gray-50 dark:bg-gray-900 min-h-full flex flex-col">
<custom-navbar></custom-navbar>
<main class="flex-grow py-8 px-4 sm:px-6 lg:px-8 max-w-7xl mx-auto">
<div class="flex justify-between items-center mb-8">
<h1 class="text-3xl font-bold dark:text-white">Your Notes</h1>
<button onclick="showNewNoteModal()" class="bg-primary-500 hover:bg-primary-600 text-white px-4 py-2 rounded-lg flex items-center gap-2 transition">
<i data-feather="plus"></i>
<span>New Note</span>
</button>
</div>
<!-- Search and Filter -->
<div class="mb-8">
<div class="grid md:grid-cols-2 gap-4">
<div>
<label class="sr-only" for="note-search">Search notes</label>
<div class="relative">
<input type="text" id="note-search" placeholder="Search notes..." class="w-full px-4 py-2 pl-10 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:text-white">
<div class="absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none">
<i data-feather="search" class="text-gray-400"></i>
</div>
</div>
</div>
<div>
<label class="sr-only" for="note-filter">Filter by topic</label>
<select id="note-filter" class="w-full px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:text-white">
<option value="">All Topics</option>
<option>Biology</option>
<option>French</option>
<option>JavaScript</option>
<option>History</option>
</select>
</div>
</div>
</div>
<!-- Notes Grid -->
<div class="grid md:grid-cols-2 lg:grid-cols-3 gap-6">
<!-- Sample Note 1 -->
<div class="bg-white dark:bg-gray-800 rounded-xl shadow-md overflow-hidden transition transform hover:scale-[1.02]">
<div class="p-6">
<div class="flex justify-between items-start mb-2">
<h2 class="text-xl font-bold dark:text-white">Photosynthesis Process</h2>
<div class="flex gap-2">
<button class="text-gray-400 hover:text-gray-600 dark:hover:text-gray-200 transition">
<i data-feather="edit"></i>
</button>
<button class="text-gray-400 hover:text-gray-600 dark:hover:text-gray-200 transition">
<i data-feather="trash-2"></i>
</button>
</div>
</div>
<div class="flex items-center gap-2 mb-4">
<span class="bg-primary-100 dark:bg-primary-900 text-primary-800 dark:text-primary-200 text-xs px-2 py-1 rounded-full">Biology</span>
<span class="text-sm text-gray-500 dark:text-gray-400">Last updated 2 days ago</span>
</div>
<p class="text-gray-600 dark:text-gray-300 mb-4 line-clamp-3">
Photosynthesis is the process by which green plants use sunlight to synthesize foods from carbon dioxide and water. It generally involves the green pigment chlorophyll and generates oxygen as a byproduct.
</p>
<div class="flex flex-wrap gap-2 mb-4">
<span class="text-xs bg-gray-100 dark:bg-gray-700 text-gray-800 dark:text-gray-200 px-2 py-1 rounded-full">Light Reactions</span>
<span class="text-xs bg-gray-100 dark:bg-gray-700 text-gray-800 dark:text-gray-200 px-2 py-1 rounded-full">Chloroplasts</span>
<span class="text-xs bg-gray-100 dark:bg-gray-700 text-gray-800 dark:text-gray-200 px-2 py-1 rounded-full">Calvin Cycle</span>
</div>
<div class="flex items-center justify-between">
<a href="#" class="text-primary-600 dark:text-primary-400 font-medium hover:underline flex items-center gap-1">
<i data-feather="layers" class="w-4 h-4"></i>
View Flashcards
</a>
<a href="#" class="text-secondary-600 dark:text-secondary-400 font-medium hover:underline flex items-center gap-1">
<i data-feather="play" class="w-4 h-4"></i>
Take Quiz
</a>
</div>
</div>
</div>
<!-- Sample Note 2 -->
<div class="bg-white dark:bg-gray-800 rounded-xl shadow-md overflow-hidden transition transform hover:scale-[1.02]">
<div class="p-6">
<div class="flex justify-between items-start mb-2">
<h2 class="text-xl font-bold dark:text-white">French Greetings</h2>
<div class="flex gap-2">
<button class="text-gray-400 hover:text-gray-600 dark:hover:text-gray-200 transition">
<i data-feather="edit"></i>
</button>
<button class="text-gray-400 hover:text-gray-600 dark:hover:text-gray-200 transition">
<i data-feather="trash-2"></i>
</button>
</div>
</div>
<div class="flex items-center gap-2 mb-4">
<span class="bg-secondary-100 dark:bg-secondary-900 text-secondary-800 dark:text-secondary-200 text-xs px-2 py-1 rounded-full">French</span>
<span class="text-sm text-gray-500 dark:text-gray-400">Last updated 1 week ago</span>
</div>
<p class="text-gray-600 dark:text-gray-300 mb-4 line-clamp-3">
Common French greetings and phrases: Bonjour (Hello), Comment ça va? (How are you?), Je m'appelle... (My name is...), Au revoir (Goodbye), Merci (Thank you), S'il vous plaît (Please).
</p>
<div class="flex flex-wrap gap-2 mb-4">
<span class="text-xs bg-gray-100 dark:bg-gray-700 text-gray-800 dark:text-gray-200 px-2 py-1 rounded-full">Vocabulary</span>
<span class="text-xs bg-gray-100 dark:bg-gray-700 text-gray-800 dark:text-gray-200 px-2 py-1 rounded-full">Beginner</span>
</div>
<div class="flex items-center justify-between">
<a href="#" class="text-primary-600 dark:text-primary-400 font-medium hover:underline flex items-center gap-1">
<i data-feather="layers" class="w-4 h-4"></i>
View Flashcards
</a>
<a href="#" class="text-secondary-600 dark:text-secondary-400 font-medium hover:underline flex items-center gap-1">
<i data-feather="play" class="w-4 h-4"></i>
Take Quiz
</a>
</div>
</div>
</div>
<!-- Sample Note 3 -->
<div class="bg-white dark:bg-gray-800 rounded-xl shadow-md overflow-hidden transition transform hover:scale-[1.02]">
<div class="p-6">
<div class="flex justify-between items-start mb-2">
<h2 class="text-xl font-bold dark:text-white">JS Event Loop</h2>
<div class="flex gap-2">
<button class="text-gray-400 hover:text-gray-600 dark:hover:text-gray-200 transition">
<i data-feather="edit"></i>
</button>
<button class="text-gray-400 hover:text-gray-600 dark:hover:text-gray-200 transition">
<i data-feather="trash-2"></i>
</button>
</div>
</div>
<div class="flex items-center gap-2 mb-4">
<span class="bg-yellow-100 dark:bg-yellow-900 text-yellow-800 dark:text-yellow-200 text-xs px-2 py-1 rounded-full">JavaScript</span>
<span class="text-sm text-gray-500 dark:text-gray-400">Last updated 3 weeks ago</span>
</div>
<p class="text-gray-600 dark:text-gray-300 mb-4 line-clamp-3">
The event loop is what allows JavaScript to handle asynchronous operations despite being single-threaded. It continuously checks the call stack and the callback queue...
</p>
<div class="flex flex-wrap gap-2 mb-4">
<span class="text-xs bg-gray-100 dark:bg-gray-700 text-gray-800 dark:text-gray-200 px-2 py-1 rounded-full">Asynchronous</span>
<span class="text-xs bg-gray-100 dark:bg-gray-700 text-gray-800 dark:text-gray-200 px-2 py-1 rounded-full">Advanced</span>
<span class="text-xs bg-gray-100 dark:bg-gray-700 text-gray-800 dark:text-gray-200 px-2 py-1 rounded-full">Callbacks</span>
</div>
<div class="flex items-center justify-between">
<a href="#" class="text-primary-600 dark:text-primary-400 font-medium hover:underline flex items-center gap-1">
<i data-feather="layers" class="w-4 h-4"></i>
View Flashcards
</a>
<a href="#" class="text-secondary-600 dark:text-secondary-400 font-medium hover:underline flex items-center gap-1">
<i data-feather="play" class="w-4 h-4"></i>
Take Quiz
</a>
</div>
</div>
</div>
</div>
</main>
<!-- New Note Modal -->
<div id="newNoteModal" class="fixed inset-0 z-50 hidden flex items-center justify-center bg-black bg-opacity-50 p-4">
<div class="bg-white dark:bg-gray-800 rounded-xl shadow-lg p-6 w-full max-w-2xl">
<div class="flex justify-between items-center mb-4">
<h2 class="text-xl font-bold dark:text-white">Create New Note</h2>
<button onclick="hideNewNoteModal()" class="text-gray-400 hover:text-gray-600 dark:hover:text-gray-200 transition">
<i data-feather="x"></i>
</button>
</div>
<form id="noteForm">
<div class="mb-4">
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">Title</label>
<input type="text" required class="w-full px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:text-white">
</div>
<div class="mb-4">
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">Topic</label>
<select class="w-full px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:text-white">
<option>Biology</option>
<option>French</option>
<option>JavaScript</option>
<option>History</option>
<option>Other</option>
</select>
</div>
<div class="mb-4">
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">Content</label>
<textarea rows="6" class="w-full px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:text-white"></textarea>
</div>
<div class="mb-4">
<label class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1">Tags (comma separated)</label>
<input type="text" class="w-full px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:text-white">
</div>
<div class="mb-4">
<label class="flex items-center text-sm text-gray-700 dark:text-gray-300">
<input type="checkbox" class="rounded border-gray-300 text-primary-600 shadow-sm focus:border-primary-300 focus:ring focus:ring-primary-200 focus:ring-opacity-50">
<span class="ml-2">Generate flashcards from this note</span>
</label>
</div>
<div class="flex justify-end gap-3">
<button type="button" onclick="hideNewNoteModal()" class="px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg text-gray-700 dark:text-gray-300 hover:bg-gray-50 dark:hover:bg-gray-700 transition">
Cancel
</button>
<button type="submit" class="px-4 py-2 bg-primary-500 hover:bg-primary-600 text-white rounded-lg transition">
Save Note
</button>
</div>
</form>
</div>
</div>
<custom-footer></custom-footer>
<!-- Scripts -->
<script src="components/navbar.js"></script>
<script src="components/footer.js"></script>
<script src="script.js"></script>
<script>
feather.replace();
function showNewNoteModal() {
document.getElementById('newNoteModal').classList.remove('hidden');
document.body.style.overflow = 'hidden';
}
function hideNewNoteModal() {
document.getElementById('newNoteModal').classList.add('hidden');
document.body.style.overflow = '';
}
document.getElementById('noteForm').addEventListener('submit', function(e) {
e.preventDefault();
// Handle form submission
hideNewNoteModal();
});
</script>
</body>
</html>