|
|
|
@ -92,20 +92,17 @@ export default function QuestionText({ |
|
|
|
)} |
|
|
|
> |
|
|
|
<QuestionTitle question={question} /> |
|
|
|
<form autoComplete="off" onSubmit={(e) => e.preventDefault()}> |
|
|
|
<Input |
|
|
|
type="text" |
|
|
|
inputMode="email" |
|
|
|
dir="ltr" |
|
|
|
name={`field_${question.id}`} |
|
|
|
hasError={showInvalidState} |
|
|
|
value={localValue} |
|
|
|
onChange={(e) => handleChange(e.target.value)} |
|
|
|
onBlur={handleBlur} |
|
|
|
placeholder={question.extras.placeHolder} |
|
|
|
disabled={disabled || isMuted} |
|
|
|
/> |
|
|
|
</form> |
|
|
|
<Input |
|
|
|
type="text" |
|
|
|
inputMode="email" |
|
|
|
dir="ltr" |
|
|
|
hasError={showInvalidState} |
|
|
|
value={localValue} |
|
|
|
onChange={(e) => handleChange(e.target.value)} |
|
|
|
onBlur={handleBlur} |
|
|
|
placeholder={question.extras.placeHolder} |
|
|
|
disabled={disabled || isMuted} |
|
|
|
/> |
|
|
|
{showInvalidState ? ( |
|
|
|
<span className="block group-10 font-semibold text-[#F2465F]"> |
|
|
|
{question.validation?.errorMessage || |
|
|
|
@ -133,22 +130,19 @@ export default function QuestionText({ |
|
|
|
)} |
|
|
|
> |
|
|
|
<QuestionTitle question={question} /> |
|
|
|
<form autoComplete="off" onSubmit={(e) => e.preventDefault()}> |
|
|
|
<Input |
|
|
|
type={isNumericQuestion ? "tel" : "text"} |
|
|
|
inputMode={isNumericQuestion ? "numeric" : "text"} |
|
|
|
pattern={isNumericQuestion ? "[0-9]*" : undefined} |
|
|
|
name={`field_${question.id}`} |
|
|
|
value={localValue} |
|
|
|
onChange={(e) => handleChange(e.target.value)} |
|
|
|
onBlur={handleBlur} |
|
|
|
placeholder={question.extras.placeHolder} |
|
|
|
disabled={disabled || isMuted} |
|
|
|
className={cn( |
|
|
|
isMuted && "opacity-50 cursor-not-allowed bg-[#F5F5F5] border-[#E2E8F0]", |
|
|
|
)} |
|
|
|
/> |
|
|
|
</form> |
|
|
|
<Input |
|
|
|
type={isNumericQuestion ? "tel" : "text"} |
|
|
|
inputMode={isNumericQuestion ? "numeric" : "text"} |
|
|
|
pattern={isNumericQuestion ? "[0-9]*" : undefined} |
|
|
|
value={localValue} |
|
|
|
onChange={(e) => handleChange(e.target.value)} |
|
|
|
onBlur={handleBlur} |
|
|
|
placeholder={question.extras.placeHolder} |
|
|
|
disabled={disabled || isMuted} |
|
|
|
className={cn( |
|
|
|
isMuted && "opacity-50 cursor-not-allowed bg-[#F5F5F5] border-[#E2E8F0]", |
|
|
|
)} |
|
|
|
/> |
|
|
|
{isMarjaQuestion ? ( |
|
|
|
<div className="mt-2.5 flex items-center"> |
|
|
|
<label className="flex cursor-pointer items-center gap-2 select-none active:scale-[0.99] transition-all"> |
|
|
|
|