diff options
| author | 2026-02-08 17:11:46 -0500 | |
|---|---|---|
| committer | 2026-02-08 17:11:46 -0500 | |
| commit | aab52593acc2a96c772808b28daa18a366a310a9 (patch) | |
| tree | 9481460f3a9920b00fe913d6a500a4d3d316b177 /docs/fr/img/logo_freshrss.png | |
| parent | f65e6b1cf89bcc827e252dbdc806ad85a6b09f61 (diff) | |
Don’t break NetNewsWire’s footnote detection1.28.1-customcustom
If NetNewsWire detects that a link points to a footnote within the same
post, then tapping on that link will produce a popover displaying the
text of said footnote. Otherwise, it is treated as a regular link and
opened in the default web browser.
Detecting a footnote requires two things:
1. The link URL must consist only of a fragment (i.e. it begins with
`#`).
2. There must exist another element (typically `<li>`) in the post’s
HTML with an `id` attribute matching the fragment (that is, the text
after `#`).
Because FreshRSS’s web frontend can display multiple articles at once,
all relative URLs (including bare fragments) are automatically converted
to absolute URLs at ingestion time, and `id` attributes are replaced
with `data-sanitized-id` attributes. These changes avoid conflicts in
the web UI, but they break NNW’s footnote detection.
Since I use FreshRSS solely as a backend service for NNW (and other
clients), it is reasonable for me to disable those two sanitization
steps in order to take full advantage of NNW’s features.
Remove `id` from the list of attributes to rename, and add it to the
list of allowed attributes for `<li>` elements (as otherwise, it would
be stripped entirely). Convert the `absolutize_url()` function into a
no-op if the relative URL provided appears to be a local fragment.
Diffstat (limited to 'docs/fr/img/logo_freshrss.png')
0 files changed, 0 insertions, 0 deletions
