[wp-trac] [WordPress Trac] #52224: RSS Widget: allow removing the feed icon link
WordPress Trac
noreply at wordpress.org
Mon Jan 4 22:44:48 UTC 2021
#52224: RSS Widget: allow removing the feed icon link
-------------------------+------------------------------
Reporter: sabernhardt | Owner: sabernhardt
Type: enhancement | Status: accepted
Priority: normal | Milestone: Awaiting Review
Component: Widgets | Version:
Severity: normal | Resolution:
Keywords: | Focuses: accessibility
-------------------------+------------------------------
Changes (by sabernhardt):
* owner: (none) => sabernhardt
* status: new => accepted
Comment:
In addition to creating a filter for the icon link HTML,
[attachment:"52224.filter.diff"]:
- Adds a unique class name to each of the links to help theme authors
update styles (for example, Twenty Twenty could have `.widget_rss .widget-
title a.rsswidget:first-of-type:not(.rss-widget-title) { display: none;
}`)
- Adds internationalization function to translate "RSS" in alt text
- Adds `loading="lazy"`, as recommended on #50041
- Moves the link-related variables inside the `if($title)` conditional
I expect this needs some polishing.
If desired, revisions to this filter could:
1. Facilitate editing the heading text link as well (either adding an
image inside or removing that link so the heading is only text).
2. Encourage removing the icon link (within the docblock).
3. Keep the icon removal opt-in (it's opt-in with this patch), but adjust
the filter so we can consider a switch to opt-out later if themes support
that by then.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/52224#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list