Skip to content

Define an optional value and use it for setting dialog returnValue #11280

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 22, 2025

Conversation

lukewarlow
Copy link
Member

@lukewarlow lukewarlow commented May 1, 2025

Define a new 'optional value' for buttons and submit inputs, this is used instead of 'value' when setting a dialog's returnValue.

Fixes #11092

(See WHATWG Working Mode: Changes for more details.)


/form-control-infrastructure.html ( diff )
/form-elements.html ( diff )
/input.html ( diff )
/interactive-elements.html ( diff )

Define a new 'optional value' for buttons and submit inputs,
this is used instead of 'value' when setting a dialog's returnValue.
@lukewarlow
Copy link
Member Author

@annevk hopefully this is roughly what you had in mind?

Copy link
Member

@annevk annevk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had forgotten about this, but this looks like an improvement over the status quo.

Add submit button check.

ought to be used*
@lukewarlow lukewarlow force-pushed the form-submit-returnvalue-fix branch from a54c9f8 to cadc51c Compare May 7, 2025 22:37
Copy link
Member

@annevk annevk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Modulo Infra-alignment this looks good. Thanks for tackling it!

@lukewarlow
Copy link
Member Author

Thanks for the review, this should be ready to go

@annevk annevk merged commit f3444c2 into whatwg:main May 22, 2025
2 checks passed
annevk pushed a commit to web-platform-tests/wpt that referenced this pull request May 22, 2025
We now assert the actual value of returnValue when the submit button has no attribute.

See whatwg/html#11280.
annevk pushed a commit to web-platform-tests/wpt that referenced this pull request May 22, 2025
lando-prod-mozilla bot pushed a commit to mozilla-firefox/firefox that referenced this pull request May 23, 2025
Automatic update from web-platform-tests
Update dialog form submission test

We now assert the actual value of returnValue when the submit button has no attribute.

See whatwg/html#11280.
--

wpt-commits: 76c3c693ab36c5a7eb523ec798d60cfd57379423
wpt-pr: 51484

Differential Revision: https://phabricator.services.mozilla.com/D251003
lando-prod-mozilla bot pushed a commit to mozilla-firefox/firefox that referenced this pull request May 23, 2025
…mmand buttons,

Automatic update from web-platform-tests
Add more dialog returnValue tests for command buttons

See whatwg/html#11280.
--

wpt-commits: 975e4f6ae35d7390beab0ba0c871a349f15ea87e
wpt-pr: 52278

Differential Revision: https://phabricator.services.mozilla.com/D251005
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request May 24, 2025
Automatic update from web-platform-tests
Update dialog form submission test

We now assert the actual value of returnValue when the submit button has no attribute.

See whatwg/html#11280.
--

wpt-commits: 76c3c693ab36c5a7eb523ec798d60cfd57379423
wpt-pr: 51484

Differential Revision: https://phabricator.services.mozilla.com/D251003
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request May 24, 2025
…mmand buttons,

Automatic update from web-platform-tests
Add more dialog returnValue tests for command buttons

See whatwg/html#11280.
--

wpt-commits: 975e4f6ae35d7390beab0ba0c871a349f15ea87e
wpt-pr: 52278

Differential Revision: https://phabricator.services.mozilla.com/D251005
i3roly pushed a commit to i3roly/firefox-dynasty that referenced this pull request May 26, 2025
Automatic update from web-platform-tests
Update dialog form submission test

We now assert the actual value of returnValue when the submit button has no attribute.

See whatwg/html#11280.
--

wpt-commits: 76c3c693ab36c5a7eb523ec798d60cfd57379423
wpt-pr: 51484

Differential Revision: https://phabricator.services.mozilla.com/D251003
i3roly pushed a commit to i3roly/firefox-dynasty that referenced this pull request May 26, 2025
…mmand buttons,

Automatic update from web-platform-tests
Add more dialog returnValue tests for command buttons

See whatwg/html#11280.
--

wpt-commits: 975e4f6ae35d7390beab0ba0c871a349f15ea87e
wpt-pr: 52278

Differential Revision: https://phabricator.services.mozilla.com/D251005
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request May 28, 2025
Automatic update from web-platform-tests
Update dialog form submission test

We now assert the actual value of returnValue when the submit button has no attribute.

See whatwg/html#11280.
--

wpt-commits: 76c3c693ab36c5a7eb523ec798d60cfd57379423
wpt-pr: 51484

Differential Revision: https://phabricator.services.mozilla.com/D251003

UltraBlame original commit: 984064be0606698b570273a83a79d2fda0276504
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request May 28, 2025
…mmand buttons,

Automatic update from web-platform-tests
Add more dialog returnValue tests for command buttons

See whatwg/html#11280.
--

wpt-commits: 975e4f6ae35d7390beab0ba0c871a349f15ea87e
wpt-pr: 52278

Differential Revision: https://phabricator.services.mozilla.com/D251005

UltraBlame original commit: 4df6b216f6a259ee1077dafe848ddcfde0d8c807
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request May 28, 2025
Automatic update from web-platform-tests
Update dialog form submission test

We now assert the actual value of returnValue when the submit button has no attribute.

See whatwg/html#11280.
--

wpt-commits: 76c3c693ab36c5a7eb523ec798d60cfd57379423
wpt-pr: 51484

Differential Revision: https://phabricator.services.mozilla.com/D251003

UltraBlame original commit: 984064be0606698b570273a83a79d2fda0276504
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request May 28, 2025
…mmand buttons,

Automatic update from web-platform-tests
Add more dialog returnValue tests for command buttons

See whatwg/html#11280.
--

wpt-commits: 975e4f6ae35d7390beab0ba0c871a349f15ea87e
wpt-pr: 52278

Differential Revision: https://phabricator.services.mozilla.com/D251005

UltraBlame original commit: 4df6b216f6a259ee1077dafe848ddcfde0d8c807
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request May 28, 2025
Automatic update from web-platform-tests
Update dialog form submission test

We now assert the actual value of returnValue when the submit button has no attribute.

See whatwg/html#11280.
--

wpt-commits: 76c3c693ab36c5a7eb523ec798d60cfd57379423
wpt-pr: 51484

Differential Revision: https://phabricator.services.mozilla.com/D251003

UltraBlame original commit: 984064be0606698b570273a83a79d2fda0276504
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request May 28, 2025
…mmand buttons,

Automatic update from web-platform-tests
Add more dialog returnValue tests for command buttons

See whatwg/html#11280.
--

wpt-commits: 975e4f6ae35d7390beab0ba0c871a349f15ea87e
wpt-pr: 52278

Differential Revision: https://phabricator.services.mozilla.com/D251005

UltraBlame original commit: 4df6b216f6a259ee1077dafe848ddcfde0d8c807
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Ambiguous wording in form submission leads to interop issue
2 participants