Removed debug logging from StoryEditorClient and added autoFocus to prom
This commit is contained in:
@@ -82,7 +82,6 @@ export function StoryEditorClient() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const result = await response.json();
|
const result = await response.json();
|
||||||
console.log("Editor: full API response:", result);
|
|
||||||
|
|
||||||
const {
|
const {
|
||||||
story: storyData,
|
story: storyData,
|
||||||
@@ -90,8 +89,6 @@ export function StoryEditorClient() {
|
|||||||
isOwner: ownerStatus,
|
isOwner: ownerStatus,
|
||||||
} = result;
|
} = result;
|
||||||
|
|
||||||
console.log("Editor: received story data:", storyData);
|
|
||||||
|
|
||||||
setStory(storyData);
|
setStory(storyData);
|
||||||
setIsOwner(ownerStatus ?? false); // Default to false if undefined
|
setIsOwner(ownerStatus ?? false); // Default to false if undefined
|
||||||
setPages(
|
setPages(
|
||||||
|
|||||||
@@ -67,6 +67,8 @@ export function GeneratePageModal({
|
|||||||
setShowPreview(null);
|
setShowPreview(null);
|
||||||
setIsGenerating(false);
|
setIsGenerating(false);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Initialize characters list with existing ones
|
// Initialize characters list with existing ones
|
||||||
const existingItems: CharacterItem[] = existingCharacters.map((url) => ({
|
const existingItems: CharacterItem[] = existingCharacters.map((url) => ({
|
||||||
url,
|
url,
|
||||||
@@ -326,6 +328,7 @@ export function GeneratePageModal({
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<textarea
|
<textarea
|
||||||
|
autoFocus
|
||||||
value={prompt}
|
value={prompt}
|
||||||
onChange={(e) => setPrompt(e.target.value)}
|
onChange={(e) => setPrompt(e.target.value)}
|
||||||
placeholder={
|
placeholder={
|
||||||
|
|||||||
Reference in New Issue
Block a user