diff --git a/web/app/challenges/[id]/components/attempt-composer.tsx b/web/app/challenges/[id]/components/attempt-composer.tsx new file mode 100644 index 000000000..753c04a67 --- /dev/null +++ b/web/app/challenges/[id]/components/attempt-composer.tsx @@ -0,0 +1,64 @@ +'use client' + +import Button from '@/app/components/base/button' +import Textarea from '@/app/components/base/textarea' +import { RiLoader4Line } from '@remixicon/react' +import type { AttemptResult, LiveOutputState, Translate } from './types' +import LiveOutputCard from './live-output-card' +import AttemptHistory from './attempt-history' + +type AttemptComposerProps = { + userInput: string + onUserInputChange: (value: string) => void + onSubmit: () => Promise | void + submitting: boolean + t: Translate + liveOutput: LiveOutputState + attempts: AttemptResult[] +} + +export default function AttemptComposer({ + userInput, + onUserInputChange, + onSubmit, + submitting, + t, + liveOutput, + attempts, +}: AttemptComposerProps) { + return ( +
+

+ {t('challenges.player.yourAttempt')} +

+ +