Open tdulcet opened 4 months ago
Hmm interesting, it seems this is a feature of the template
tag. Does it work if you set shadowrootmode
to open
?
Does it work if you set
shadowrootmode
toopen
?
No, setting it "open" breaks the template element and produces an exception: TypeError: can't access property "content", template is null
. The solution might be to iterate over any template elements separately and then perform the query on each one.
HTML template elements are not localized as expected:
The issue is that they are not found by
document.querySelectorAll
: https://github.com/TinyWebEx/Localizer/blob/f6da4ca47caf7d4c93725363f2bbc994f1d655fd/Localizer.js#L283-L286This affects my Thunderbird Send add-on, which uses an HTML template element in the popup. See https://github.com/tdulcet/Thunderbird-Send/pull/14.
CC: @DenB10