From d2acc670e1f312296212b096b87014c2f91284bc Mon Sep 17 00:00:00 2001
From: nsfisis <nsfisis@gmail.com>
Date: Wed, 31 Dec 2025 03:00:21 +0900
Subject: feat(client): add CreateNoteModal for note-based card creation
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Replace CreateCardModal with CreateNoteModal in DeckDetailPage. The new
modal allows users to select a note type and dynamically enter field
values based on the selected type's fields. Cards are auto-generated
from the note with preview of how many cards will be created.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
---
 src/client/pages/DeckDetailPage.tsx | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

(limited to 'src/client/pages/DeckDetailPage.tsx')

diff --git a/src/client/pages/DeckDetailPage.tsx b/src/client/pages/DeckDetailPage.tsx
index 5a3c14e..9a158f6 100644
--- a/src/client/pages/DeckDetailPage.tsx
+++ b/src/client/pages/DeckDetailPage.tsx
@@ -11,7 +11,7 @@ import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
 import { useCallback, useEffect, useState } from "react";
 import { Link, useParams } from "wouter";
 import { ApiClientError, apiClient } from "../api";
-import { CreateCardModal } from "../components/CreateCardModal";
+import { CreateNoteModal } from "../components/CreateNoteModal";
 import { DeleteCardModal } from "../components/DeleteCardModal";
 import { EditCardModal } from "../components/EditCardModal";
 
@@ -238,7 +238,7 @@ export function DeckDetailPage() {
 									className="w-5 h-5"
 									aria-hidden="true"
 								/>
-								Add Card
+								Add Note
 							</button>
 						</div>
 
@@ -256,7 +256,7 @@ export function DeckDetailPage() {
 									No cards yet
 								</h3>
 								<p className="text-muted text-sm mb-4">
-									Add cards to start studying
+									Add notes to start studying
 								</p>
 								<button
 									type="button"
@@ -268,7 +268,7 @@ export function DeckDetailPage() {
 										className="w-5 h-5"
 										aria-hidden="true"
 									/>
-									Add Your First Card
+									Add Your First Note
 								</button>
 							</div>
 						)}
@@ -360,11 +360,11 @@ export function DeckDetailPage() {
 
 			{/* Modals */}
 			{deckId && (
-				<CreateCardModal
+				<CreateNoteModal
 					isOpen={isCreateModalOpen}
 					deckId={deckId}
 					onClose={() => setIsCreateModalOpen(false)}
-					onCardCreated={fetchCards}
+					onNoteCreated={fetchCards}
 				/>
 			)}
 
-- 
cgit v1.2.3-70-g09d2

