Closed Bug 1676333 Opened 5 years ago Closed 5 years ago

[meta] add support for restricted subset of HTML

Categories

(Firefox Graveyard :: Pioneer, enhancement)

enhancement

Tracking

(firefox84 verified)

VERIFIED FIXED
84 Branch
Tracking Status
firefox84 --- verified

People

(Reporter: rhelmer, Assigned: rhelmer)

Details

(Keywords: feature-testing-meta)

Attachments

(1 file)

The only formatting about:ion currently supports are line-feeds which get translated into bullet points, supporting a strict subset of HTML would be better.

For instance:
bold/emphasis
bullet points and ordered lists
links
[...]

We've investigated a few other options:

  1. frames (either iframe or <browser>) - getting the security settings correct here is tough, and the CSS layout as well.
  2. markdown parser. adding this in-tree feels riskier at this stage
  3. having study partners display their own form. this makes the onboarding experience pretty rocky.

The implementation I've been working on does takes output from remote-settings (which uses content signatures) and then uses DOMParser and creates a brand-new DOM tree, only copying over an allow-list of tag names and attributes. The textContent of each node is transferred over as well.

Pushed by rhelmer@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/afd7ba1670b0 restricted HTML support for Ion r=Dexter,freddyb
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → 84 Branch
Status: RESOLVED → VERIFIED
Summary: add support for restricted subset of HTML → [meta] add support for restricted subset of HTML
Product: Firefox → Firefox Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: