Skip to content

html <dialog> elements ignore 'closedby' #4233

@egnrse

Description

@egnrse

What happened?

html dialog elements (opened modal) seem to always use closedby=closerequest and ignore any/none.

eg. I can't close a modal dialog element with closedby="any" by clicking somewhere else on the screen. (This is working on firefox (150.0.3) / chrome (148.0.7778.167). )

See a code example below:

<button onclick="document.getElementById('song-details')?.showModal()">Details</button>
<dialog id="song-details" closedby="any"> <!-- the any here gets ignored -->
	<h2 id="title">title</h2>
	<p id="test">test</p>
	<button onclick="document.getElementById('song-details')?.close()">Close</button>
</dialog>

Reproducible?

  • I have checked that this issue cannot be reproduced on Mozilla Firefox.

Version

6.6.12

What platform are you seeing the problem on?

Linux

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions