Closed (fixed)
Project:
Olivero
Version:
8.x-1.x-dev
Component:
User interface
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
22 Jun 2020 at 13:42 UTC
Updated:
22 Jul 2020 at 12:24 UTC
Jump to comment: Most recent, Most recent file

Comments
Comment #2
hansa11 commentedComment #3
kostyashupenkoWould be cool to see some steps about how to reproduce
Comment #4
hansa11 commented@kostyashupenko Here are the steps:
1. Create a view
2. Enable
Include RSS Feed3. On the view page, there'll be this block at the bottom.
Comment #5
hansa11 commentedComment #6
kostyashupenkoOk, so if i did everything correctly - then i see the following:

rss link comes as a part of view, where view - is a content section. But rss link is supposed to be in sidebar (on block-layout level). Any ideas how it can be managed?
Comment #7
kiran.kadam911@kostyashupenko As per the understanding, we need to create an RSS feed block and need to place that in the new social block region.
For region: Create a new region for a social block which structure is already available on
template > layout > page.html.twigat line 117 currently in TODO.But in views, there is no option for the block to Include RSS Feed.
Feel free to add your opinion.
Thanks!
Comment #8
mherchelTheres a core block called "syndicate" that should work for this. Note this is new to me, I didn't know this block existed out of the box.
Comment #9
kiran.kadam911Comment #10
kiran.kadam911Kindly review the attached patch. Clear cache once patch applied.
Screenshot: If RSS feed in the social region(left side) and in another region
Thanks!
Comment #11
andrewmacpherson commentedCan you post the resulting markup for the block? I'm concerned this fails WCAG link purpose criterion. We already noted that about the Proof-of-concept, in an early accessibility review video call.
+++ b/config/optional/block.block.olivero_syndicate.ymlThe standard profile in Drupal core doesn't currently use the syndicate block from node module. Instead it uses the RSS views attachment on the front page view. So we might end up with 2 feed icons this way. I think we'll want to revisit this before making Olivero the default theme for Standard profile; one of the feed icons would have to go.
Comment #12
andrewmacpherson commentedIn the screenshot in #10, the RSS icon radiates from the top-right corner. It normally comes from the bottom-left corner. You can see this in the other icon in the main content.
Comment #13
kiran.kadam911@andrewmacpherson Thanks for quick review.
1. Block Markup which is referred from POC https://olivero-poc.netlify.app/
If block placed in social region markup:
If block placed in another region markup:
2. As per @mherchel #8 comment and after confirming on #d9-theme channel(https://drupal.slack.com/archives/CJT807H7T/p1593516632115800) I gohead with this. But as per @@andrewmacpherson comment need to confirm once again with @mherchel or other team.
3. RSS icon rotates properly.
Kindly review the attached updated patch.
Thanks!
Comment #14
kostyashupenko1.
Is
display: block;really necessary here?2.
what for
imgtag here? and why such solution with margins? Just add margins to the wrapper if need.3.
If you need
display: flex;only because ofdisplay: block;for svg, then what prevents to make svg inline?4.
You have to optimize this svg:
- Remove all "fill" attributes and make colours fully manageable from css
- Combine rect + path
- For path i see a lot of almost similar values, that means path is not optimized well, need to reduce quality of it (and it will be no visual difference between "before" and "after" optimisations)
5.
Combine both if statements to one
6.
For what exactly you need to override whole block template? Only to add
<div class="rotate">wrapper around content? Is it possible just to add this class tocontent_attributesand adapt styles?Comment #15
kiran.kadam911Comment #16
andrewmacpherson commented@kiran.kadam911 - Thanks for providing the full markup in #13.
The link does indeed fail two WCAG success criteria at level A - 2.4.4 "Link Purpose (in context)", and 4.1.2 "Name, Role, Value".
The fault lies in the over-ridden
feed-icon.html.twigtemplate. The equivalent version from system module passes both of these WCAG success criteria, because there is text inside the link.To correct this, move the text inside the link, the same as it is in the original template from the system module. (Update CSS if necessary.)
There's another problem here though. The new template for Olivero doesn't respect the top-level
titleattribute which is passed in to the theme template. The original template from System module produces dynamic link text, like so:{{ 'Subscribe to @title'|t({'@title': title}) }}This is important, because this is a general-purpose template. It isn't solely used by the Syndicate block from the node module; it's also used by various other modules like views and aggregator (and probably some contrib modules). If Olivero's feed icon template doesn't respect the title variable, then feed icons produced by Views won't have the intended link names.
I noticed a related problem with the Syndicate block; it doesn't pass a
titlevariable into thefeed_icontemplate at all! This isn't Olivero's fault, so I opened #3156244: Title variable isn't set by Syndicate block - so the link text is an unfinished sentence. Standard profile doesn't currently use the Syndicate block, so this bug might not have been found if Olivero hadn't tried to use it.Upshot: if Olivero is going to make changes to the
feed-icon.html.twigtemplate, it needs to be flexible enough to cover all the other uses which the template is already used for. We can't just brute-force it to match what was in the Olivero proof-of-concept.Comment #17
andrewmacpherson commentedThe issue title here is misleading. It refers to the Views RSS feed block, but the work done has targetted the Syndicate block from the Node module.
For completeness, both of these should be styled. The aggregator module uses feed-icon theme too.
Comment #18
kiran.kadam911In the next 2/3 days, I am not able to work on it. So instead of keeping with me, I am unassigning it. Thanks!
Comment #19
kostyashupenkoPatch with fixes for #14 and #16
Comment #20
mherchelThis needs a bit of cleanup.
1) There's too much markup when the region is empty.
2) the contextual menu is also rotated.
Comment #21
mherchelI'm going to try to do some work on this right now.
Comment #22
mherchelSome more work on this. This is working (you can add multiple blocks like "powered by Drupal, etc), and it also contextual menus work as expected.
Still need to move some CSS from the component into layout though. So still work to do.
Comment #23
mherchelMessed up my patches. Here are the correct ones 🤞
Comment #24
mherchelMoved the layout portion of the CSS into the layouts, and fixed an IE11 bug.
This is good to go.
Comment #25
mherchelComment #26
mherchelThis next patch takes into account the comments by @andrewmacpherson in #16, and works around the core bug in #3156244: Title variable isn't set by Syndicate block - so the link text is an unfinished sentence by doing the following:
Comment #27
andrewmacpherson commented#26 - that's a good improvement towards satisfying WCAG Link Purpose. We no longer have a link without a name, which is great. However it may not suffice to identify the purpose of the link.
Note that Olivero still doesn't know what the
titlevariable will actually contain. There's been some progress in the related #3156244: Title variable isn't set by Syndicate block - so the link text is an unfinished sentence. So far, we are assuming the Syndicate block will pass the site name in as the title variable. When using the default feed-icon template (from system module, or stable9 theme), the resulting link would be called "subscribe to ". But using the feed-icon template from patch #26, the link would be called "". This isn't sufficient to identify the link purpose as pointing to an RSS feed, and it can't be distinguished from the other "" link from the branding block (which doesn't point to a feed).(FWIW, I'm not convinced that the system module's "subscribe to ..." sufficiently identifies the purpose of an RSS feed link. "RSS feed" is much clearer.)
What does
varrefer to? Shouldn't this ask{% if title ...?Comment #28
mherchelGah... it totally should! That's a brain fart and a half!
Comment #30
mherchelCommitting this (with variable changes) to get the region in for the final alpha. Any final changes can go in followup issues.