- 🇳🇿New Zealand chroid
https://www.drupal.org/project/drupal/issues/953034 🌱 [meta] Themes improperly check renderable arrays when determining visibility Needs work
- Status changed to Closed: won't fix
about 1 year ago 8:01pm 7 December 2023
The 'tabs' block, when placed into a region on it's own, still triggers region visibility if the user has no permission to see/use.
Particularly noticeable if you have margining on the top of regions, which will generate unexpected white space. Note, this isn't reproduceable when there are other user visible blocks output in the region.
'Zero' a region, and move the 'tabs' block into it. View the site as anon, and inspect the output:
White space and the pre-content region is delivered here even though the user doesn't have access to local tasks (tabs).
A quick win, is to trim the twig output in the page template:
{% if page.pre_content| %}
to
{% if page.pre_content|trim %}
Though this only deals with the issue at the very end of the 'chain', so it'd be nice to see if we can find when/how that presents further up.
Identify the culprit further up in the rendering of the page, or if more preferrable, just roll the template trim as a solution.
Closed: won't fix
9.1
Code
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
https://www.drupal.org/project/drupal/issues/953034 🌱 [meta] Themes improperly check renderable arrays when determining visibility Needs work