Wrong behaviour of <details> <summary>

RESOLVED FIXED in Firefox 67

Status

()

defect
P3
normal
RESOLVED FIXED
5 months ago
2 months ago

People

(Reporter: matthias.miguelkoehler, Assigned: TYLin)

Tracking

(Blocks 1 bug)

65 Branch
mozilla67
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox67 fixed)

Details

Attachments

(2 attachments)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:65.0) Gecko/20100101 Firefox/65.0

Steps to reproduce:

I created an example here: https://stackoverflow.com/questions/53353524/handle-details-tag-and-checkbox-click-event-with-firefox

Click on a child button element of <summary>

Actual results:

<summary> of <details> showed expanded content.

Expected results:

<summary> of <details> shouldnt show expanded content.

Component: Untriaged → DOM: Events
Product: Firefox → Core
Component: DOM: Events → DOM: Core & HTML
Priority: -- → P3

Ting-Yu might recall something about details/summary :)

I can fix this one.

Emilio, thanks for the tip :)

Assignee: nobody → aethanyc
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true

When nsGenericHTMLElement::IsInteractiveHTMLContent() was introduced,
HTMLDetailsElement didn't exist yet. It's better to override
IsInteractiveHTMLContent() for HTMLDetailsElement than check the details
tag in its parent class.

Depends on D18791

Attachment #9041692 - Attachment description: Bug 1524893 - Do not toggle <details> when clicking on an interactive html content in <summary>. → Bug 1524893 - Prevent Label and Summary elements from handling click event if clicking on interactive html content.
Pushed by aethanyc@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/a2336e360977
Prevent Label and Summary elements from handling click event if clicking on interactive html content. r=smaug
https://hg.mozilla.org/integration/autoland/rev/4d0958fba8db
Override IsInteractiveHTMLContent() for HTMLDetailsElement. r=smaug
Status: ASSIGNED → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla67
Duplicate of this bug: 1554691
Duplicate of this bug: 1539490
You need to log in before you can comment on or make changes to this bug.