31 lines
825 B
TypeScript
31 lines
825 B
TypeScript
import * as React from 'react';
|
|
import UploadImage from "../UploadImage";
|
|
import HelpQuestions from "../helpQuestions";
|
|
import ResponseSettings from "./responseSettings";
|
|
import BranchingQuestions from "../branchingQuestions";
|
|
|
|
|
|
interface Props {
|
|
switchState: string,
|
|
totalIndex: number,
|
|
}
|
|
|
|
export default function SwitchAnswerOptions({switchState = 'setting', totalIndex }: Props) {
|
|
|
|
switch (switchState) {
|
|
case 'setting':
|
|
return (<ResponseSettings totalIndex={totalIndex}/>);
|
|
break;
|
|
case 'help':
|
|
return (<HelpQuestions/>);
|
|
break
|
|
case 'branching':
|
|
return (<BranchingQuestions/>);
|
|
break;
|
|
case 'image':
|
|
return (<UploadImage/>);
|
|
break;
|
|
default:
|
|
return (<></>)
|
|
}
|
|
} |