HL7 / emedicinal-product-info

Gravitate Health Project
14 stars 8 forks source link

Section titles in section.text #108

Open adamzkover opened 2 months ago

adamzkover commented 2 months ago

From the May 2024 Connectathon Track Report: "Don’t include heading elements <h1>-<h6> in ePI document section content, as EPI document headings are mapped to section.title elements."

I would argue for including the section title in the text, and, regardless of the decision, documenting the reasons for and against in the IG.

  1. Elements in the content allow richer formatting of the title. The data type of section.title is string. Formatting like sub- or subscript, italic, or line break, can be added with escaped HTML tags, but handling these can become a security issue. (See the IG publisher warning: "The string value contains text that looks like embedded HTML tags. If this content is rendered to HTML without appropriate post-processing, it may be a security risk.")
  2. If the title is included in section.text, then the section.text elements contain all text that should be displayed to the user, without having to fetch some parts from other elements.
  3. The level of the header tag in section.text would guide the author when lower-level headers are added in the text (e.g., if the section title is h3, that means that the first subdivision should be h4.

Consistency can become an issue as the title is repeated in two elements. On the other hand, this allows section.title to be simpler, more like metadata, used to generate an index or ToC.

cander2 commented 2 months ago

Hi Adam, I don't think titles should have any formatting and they should be managed by the style sheet. If we have industry put headings in tags then they are likely to all manage it differently. If we use title it was constrain what they are able to do. That and the titles should align with the regulator's template.