mdn / mdn/browser-compat-data

html.elements.input - Firefox Android partially supports `required` and `pattern`

Open
#18,353 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

browser:firefox_android data:html p3
Dominant language
JSON
Stars
5.8k
Forks
2.6k
Avg merge
1d 21h
Merged PRs (30d)
186

Description

What type of issue is this?

Browser bug (a bug with a feature that may impact site compatibility)

What information was incorrect, unhelpful, or incomplete?

I believe that Firefox Android does not fully supports required and pattern attributes.
The browser should show an error message on violation of this 2 attributes, but Firefox Android does not.
I have checked this on Firefox Android Nightly 109.0a1 (Build #2015918955). At least some infos on how to workaround this issue on Firefox Android would be appreciated.

What browsers does this problem apply to, if applicable?

Firefox Android, surely since 107.2.0 up to the latest Nightly 109.0a1

What did you expect to see?

That Firefox Android is not fully supporting this HTML standard feature, and some sort of workaround to it.

Did you test this? If so, how?
  1. Go to https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/required#result
  2. Tap "submit query" without filling the "required" input
  3. The form is not submitted, but no message is shown to the user
Can you link to any release notes, bugs, pull requests, or MDN pages related to this?
Do you have anything more you want to share?

The bugzilla report is open since 2018, so maybe is not an easy fix. Firefox Android is the only main browser affected, it would be great to advice a workaround on the mdn page. On reddit I found an interesting suggestion of a workaround based on the :user-invalid pseudo selector, that is supported only by Firefox (desktop and mobile).

MDN URL

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input

MDN metadata
MDN page report details
  • Query: html.elements.input
  • Report started: 2022-12-01T19:57:51.778Z

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the MDN page for html.elements.input and inspect its compatibility data for the required and pattern attributes. Check the linked Fenix and Bugzilla reports to confirm Firefox Android's behavior and determine whether the page needs corrected support information or workaround guidance. Done means the reported behavior is accurately reflected for affected Firefox Android versions.

Written by the indexing model from the issue text.

Assessment

Tech stack
html
Domain
documentation, web-dev
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.