Open-source, secure environment with real-world tools for enterprise-grade agents.
Python agentaiai-agentai-agentscode-interpretercopilotdevelopmentdevtoolsgptgpt-4javascriptllmnextjsopenaipythonreactsoftwaretypescript
Add handlers
Vasek Mlejnskyc07bfc6e101e
diff --git a/components/AgentInstructions.tsx b/components/AgentInstructions.tsxindex e325386a7..2fbd380af 100644--- a/components/AgentInstructions.tsx+++ b/components/AgentInstructions.tsx@@ -8,7 +8,7 @@ export interface Props {value: stringonChange: (value: string) => voidonBack: () => void- onNext: (instructions: string) => void+ onNext: () => void}function AgentInstructions({@@ -38,7 +38,7 @@ function AgentInstructions({</button><buttonclassName="px-2 py-1 font-medium rounded-md text-sm border border-transparent bg-indigo-600/30 text-indigo-500 hover:bg-transparent hover:border-indigo-600 transition-all"- onClick={() => onNext(content)}+ onClick={onNext}>Continue</button>diff --git a/pages/agent/smol-developer/setup.tsx b/pages/agent/smol-developer/setup.tsxindex 104f72d7f..1ac502b06 100644--- a/pages/agent/smol-developer/setup.tsx+++ b/pages/agent/smol-developer/setup.tsx@@ -113,7 +113,7 @@ function Setup() {const [selectedRepository, setSelectedRepository] = useState<RepoSetup>()const { repos, refetch } = useRepositories(github)const [instructions, setInstructions] = useState('')- const [openAIAPIKey, setOpenAIAPIKey] = useState<string>()+ const [openAIAPIKey, setOpenAIAPIKey] = useState<string>('')const handleMessageEvent = useCallback((event: MessageEvent) => {if (event.data.accessToken) {@@ -240,11 +240,10 @@ function Setup() {)}{currentStep === 1 && (<AgentInstructions+ value={instructions}+ onChange={setInstructions}onBack={() => previousStep()}- onNext={i => {- setInstructions(i)- nextStep()- }}+ onNext={() => nextStep()}/>)}{currentStep === 2 && (