Skip to main content
Logo Appt Light

Success Criterion 3.3.4 - Level AA

Error Prevention (Legal, Financial, Data)

Ensure data is submitted deliberately. Allows users to undo, correct or confirm a submission. At least one of these options must be provided for submissions that cause a legal obligation, financial transaction, or loss of data. These options reduce the chance of unforeseen consequences.

Impact

  • Everyone benefits from preventing unforeseen consequences.

  • Confirming submissions is important for users of assistive technologies because they are more likely make mistakes when entering data.

Check

Is confirmation requested before submissions are final?

This can be tested without assistive technologies.

Solution

Use a dialog for confirmation

On Android, you can show a dialog by using AlertDialogBottomSheetDialog or DialogFragment. You should always add a close button by using the setNegativeButton method. The focus of assistive technologies is automatically trapped inside the dialog while it's visible.

val builder = AlertDialog.Builder(this)
builder.setTitle("Confirm Appt membership?")
builder.setMessage("Your bank account will be billed.")

builder.setPositiveButton("Proceed") { dialog, which ->
  // Proceed
}

builder.setNegativeButton("Cancel") { dialog, which ->
  // Cancel
}

builder.show()

Resources

Feedback?

Let us know!