NCIOCPL / cgov-digital-platform

The Cancer.gov Digital Communications Platform
GNU General Public License v2.0
11 stars 33 forks source link

Italicized headings in CDR do not display as expected on live site #3641

Open lburack opened 1 year ago

lburack commented 1 year ago

Issue description

The CDR allows for italics in headings (section titles), but the italics does not display on the live Cancer.gov site. The italics does not display in Publish Preview either.

A CDR user reported the problem with this example page, where BRCA should be italicized in the "Clinical Management of Carriers of BRCA Pathogenic Variants" heading/section title

FWIW, Drupal allows for italics in headings and it does display as expected (here's a Drupal page with italicized headings: https://www.cancer.gov/about-cancer/causes-prevention/risk/infectious-agents)

ESTIMATE TBD

What's the expected result?

What's the actual result?

Additional details / screenshot

Screen Shot 2022-11-15 at 6 23 51 PM

Related Tickets

lburack commented 1 year ago

FYI @bkline - William alerted me of this issue so I logged this ticket. But I am now realizing you all may have a different process for logging CDR related bugs. I didn't want this issue to get lost in the sea of my chat messages so I've logged it here. CC @amydugan

venglisch commented 1 year ago

This is indeed a DP issue. The filters are providing the information to display the gene name in italics but the field displaying the section title has that information stripped. I'm guessing that the "Section Title" field in Drupal only allows ASCII. This is the title coming from the filter:

Clinical Management of Carriers of BRCA Pathogenic Variants

and this is the title displayed in the edit page: Clinical Management of Carriers of BRCA Pathogenic Variants

venglisch commented 1 year ago

Oh well, GH is converting the entered HTML.

bkline commented 1 year ago

The requirements tell us we can only store plain text in that field, so I removed the bug tag.

venglisch commented 1 year ago

The field that displays the section title can only handle plain text - that's why the requirements are asking for plain text here. The section title for the document that @lburack mentions is using a "Heading" field which does allows minor formatting. Someone will have to make a decision if the properties for the "Section Title" field used for the PDQ summaries should be modified or if we need to tell the user that markup in section titles cannot be done.