mirror of
https://github.com/formbricks/formbricks.git
synced 2026-04-17 19:14:53 -05:00
added tabindex
This commit is contained in:
@@ -36,7 +36,14 @@ export default function ConsentQuestion({
|
||||
e.preventDefault();
|
||||
onSubmit({ [question.id]: value });
|
||||
}}>
|
||||
<label className="relative z-10 mt-4 flex w-full cursor-pointer items-center rounded-md border border-gray-200 bg-slate-50 p-4 text-sm text-slate-800 focus:outline-none">
|
||||
<label
|
||||
tabIndex={1}
|
||||
onKeyDown={(e) => {
|
||||
if (e.key == "Enter") {
|
||||
onChange({ [question.id]: "accepted" });
|
||||
}
|
||||
}}
|
||||
className="relative z-10 mt-4 flex w-full cursor-pointer items-center rounded-md border border-gray-200 bg-slate-50 p-4 text-sm text-slate-800 focus:outline-none focus:ring-2 focus:ring-slate-500 focus:ring-offset-2">
|
||||
<input
|
||||
type="checkbox"
|
||||
id={question.id}
|
||||
@@ -62,10 +69,11 @@ export default function ConsentQuestion({
|
||||
|
||||
<div className="mt-4 flex w-full justify-between">
|
||||
{!isFirstQuestion && (
|
||||
<BackButton backButtonLabel={question.backButtonLabel} onClick={() => onBack()} />
|
||||
<BackButton tabIndex={3} backButtonLabel={question.backButtonLabel} onClick={() => onBack()} />
|
||||
)}
|
||||
<div />
|
||||
<SubmitButton
|
||||
tabIndex={2}
|
||||
brandColor={brandColor}
|
||||
question={question}
|
||||
isLastQuestion={isLastQuestion}
|
||||
|
||||
Reference in New Issue
Block a user