01573: Details without summary

Summary: Details without summary
Created: 2026-10-16 21:58
Status: ToDo
Category: Bug
From: simon
Assigned:
Priority: 1
Version: latest
OS:

Description: PmWiki allows

(:details:) without a summary
(:details:)
See the MDM web docs [[<details> HTML details disclosure element -> https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/details]]
(:detailsend:)

See the MDM web docs <details> HTML details disclosure element

According the specification (https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/details) "A summary or label must be provided using the <summary> element."

Feedback from Holger on my recipes, which use the details block markup, has determined that this is a problem with the Safari browser which is unable to open the details block if no summary is provided.

The suggested fix is that if the user does not specify a summary PmWiki must provide a summary, e.g. of the form <summary>$[Details]</summary>

simon

What should happen if the summary attribute exists but is empty, does Safari work with it? What if it is some kind of space? --Petko

(:details summary="":)
The summary exists but is empty.\\
Safari works
(:detailsend:)

The summary exists but is empty.
Safari works

(:details summary=" ":)
The summary exists but is a space\\
Safari works
(:detailsend:)

The summary exists but is a space
Safari works

(:details summary="&nbsp;":)
The summary exists but is [@&nbsp;@]\\
Safari works
(:detailsend:)
 

The summary exists but is &nbsp;
Safari works

(:details:)
No summary defined\\
Safari does not work
(:detailsend:)

No summary defined
Safari does not work



Tested with Safari on iPadOS (18 October 2026):

  • summary="" – works correctly.
  • summary=" " – works correctly.
  • summary="&nbsp;" – works correctly.
  • No summary – does not work (cannot be expanded).

All three variants with a summary can be expanded and collapsed without problems.

Holger