diff --git a/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts b/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts index 33d4719be..c88d3e111 100644 --- a/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts +++ b/apps/ai-game-creator-shell/src/view/ui-editor/useUiEditorPage.ts @@ -1367,31 +1367,6 @@ export function useUiEditorSession( } } - async function generateCode() { - if ( - !resourceId || - isGenerating || - isSaving || - isLoading || - isAiRunning || - loadError || - persistedRevision === null || - editor.isLocked - ) { - return null; - } - setIsGenerating(true); - try { - return await editor.runWithStateLocked(() => - stateStore.generateCode(resourceId), - ); - } catch { - return null; - } finally { - setIsGenerating(false); - } - } - async function saveAndGenerateCode() { if ( !resourceId || @@ -1630,7 +1605,6 @@ export function useUiEditorSession( hasWarnings: () => postCheckIssuesForSave(editor.state).length > 0, warnings: () => postCheckIssuesForSave(editor.state), save, - generateCode, saveAndGenerateCode, }, };