Updated: Comment 0

Problem/Motivation

When you test a random block patch and move a block to the footer region you will realize that the title of the block is not displayed, see bartik/css/style.css

#footer .block > h2 {
  /* @extend .visually-hidden */
  position: absolute !important;
  clip: rect(1px, 1px, 1px, 1px);
  overflow: hidden;
  height: 1px;
}

I can't really imagine that this is part of the exception of users, if they want to hide it, they can just do it.

Proposed resolution

  • Change the default value to '0' (disabled) for label_display attribute in bartik_footer block.
  • Fix the menu links styles when the title is disabled on footer_fifth region.
  • Remove the dotted line on the bottom of these menu links in order to enhance presentation.
  • Fix style issues that prevent to easily read block titles in footer.

Remaining tasks

User interface changes

API changes

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

tim.plunkett’s picture

This was in D7, see #845834: Fix Bartiks Header because its totally borked and bartik_preprocess_block (D7)

This was changed to hardcoded CSS in #1968360: Remove per-region block markup, which is a technically a regression.

poojakural’s picture

I found block title visible on other footer section but only hide on main footer section. If we remove this css then block title would start appear

RavindraSingh’s picture

Status: Active » Needs review
Issue tags: +#Drupal8 #Theme, +#bartik

Processing the patch for review.

emma.maria’s picture

Issue summary: View changes
FileSize
39.63 KB

We unfortunately can't just remove the CSS that hides the titles. This is because as part of the Bartik design and certain blocks assigned to regions on install we do not want to show their titles.

See screenshot....
 


 
Therefore we need to consider how we can turn the block title visibility off by default for the footer items as well as getting rid of the CSS that hides them.

emma.maria’s picture

Status: Needs review » Needs work
Issue tags: -#Drupal8 #Theme, -#bartik +frontend, +CSS
idebr’s picture

@emma.maria Some block titles are disabled by default by the install profiles, for example Bartik breadcrumbs in the Standard profile ('label_display'):

core\profiles\standard\config\install\block.block.bartik_breadcrumbs.yml

id: bartik_breadcrumbs
theme: bartik
weight: 0
status: true
langcode: en
region: breadcrumb
plugin: system_breadcrumb_block
settings:
  id: system_breadcrumb_block
  label: Breadcrumbs
  provider: system
  label_display: '0'

So the block title can be disabled by default, but the title should at least look decent if a site builder enable its, don't you think?

tim.plunkett’s picture

@idebr Agreed, we should do both.

emma.maria’s picture

Yes I agree. There is an existing issue for the footer block titles somewhere. I also experimented with the block install files to make sure I was on the right track with my instructions :) so yes let's do it!

juankvillegas’s picture

Issue summary: View changes
Status: Needs work » Needs review
Issue tags: +LatinAmerica2015
FileSize
1.77 KB
1.6 KB
8.92 KB

We worked on this issue in Thursday's Sprint Code in DrupalCon LatinAmerica.

  • Changed the default value to '0' (disabled) for label_display attribute in bartik_footer block.
  • Fixed the menu links styles when the title is disabled on footer_fifth region.
  • Removed the dotted line on the bottom of these menu links in order to enhance presentation as can be seen by the attached screenshot:
    broken dotted line under text in footer

This patch was created with peer programming by juankvillegas, jidrone, ibustos, davidlfg, geffio, fredysan and andres-mejia

ibustos’s picture

I went ahead and applied the patch in #9 and using the minimal profile along with Bartik, created a new custom block and added it to footer five. I can confirm the title does show up.

jclema’s picture

Title: h2 on footer blocks is hidden » h2 on footer blocks must be hidden by default but must show when its enable
jidrone’s picture

Status: Needs review » Reviewed & tested by the community

I used the patch in #9 with a standard profile installation, and it works for me.

Also, I saw the new menu links styling and looks pretty good.

juankvillegas’s picture

FileSize
4.64 KB

Here is the final result:
Final Result

tim.plunkett’s picture

Status: Reviewed & tested by the community » Needs work
+++ b/core/themes/bartik/css/components/footer.css
@@ -36,16 +36,12 @@
+#site-footer__bottom .menu li a:hover {
+  color: rgba(255, 255, 255, 0.95);
+}

@@ -115,12 +111,20 @@
+  color: #fcfcfc;
+  color: rgba(255, 255, 255, 0.8);
+  font-size: 0.857em;
+  border-bottom: none;
...
+  color: #fcfcfc;
+  color: rgba(255, 255, 255, 0.8);
+  font-size: 0.857em;
+  border-bottom: none;

It's not clear why there are changes to a styling here, this is about H2?

AFAIK the H2 is not a link here.

The screenshot in #13 shows that the header text is not legible.

juankvillegas’s picture

Status: Needs work » Reviewed & tested by the community

There are changes needed to the styling because only removing the css that hides the H2 title converts the links to blue (check patch in #2)... so, there must be added some styles to put those links almost white again.

The titles are not legible, but they are not legible on all the footer area, and this issue was affecting only the Footer Fifth region, that's why we decided to do not include a fix for it here... I think it must be a separate issue.

tim.plunkett’s picture

Status: Reviewed & tested by the community » Needs work

In HEAD, there is no way to get a block title in the footer that violates our accessibility rules.
This patch now allows site builders to cause accessibility problems. Therefore it is the responsibility of this issue to fix it.

See #6, #7, and #8.

juankvillegas’s picture

FileSize
24.82 KB

Actually in any Footer region from First to Fourth, titles can be normally enabled/disabled.
Titles working on 1st to 4th footer regions

I'll search for the titles legibility issue and try to fix it too.

juankvillegas’s picture

Assigned: Unassigned » juankvillegas

I did a quick (but responsible) research and I didn't find any issue related with titles legibility.

juankvillegas’s picture

Fixed style issues that prevent to easily read block titles in footer.

Here is the final result with all the changes applied:
Footer Block Titles Fixed

juankvillegas’s picture

I just removed a commented style in #19

juankvillegas’s picture

... and here are the styles with titles disabled in Footer Bottom section:
Fixed styles with titles disabled

juankvillegas’s picture

Status: Needs work » Needs review
idebr’s picture

Status: Needs review » Needs work
Issue tags: +Needs reroll

Patch no longer applies after #2422363: Rewrite the menu CSS components inline with our CSS standards was committed:

error: patch failed: core/themes/bartik/css/components/footer.css:115
error: core/themes/bartik/css/components/footer.css: patch does not applyt

emma.maria’s picture

Assigned: juankvillegas » Unassigned

The latest patch has caused design regressions to the footer_first to footer_fourth regions (lost the border and the spacing). The original intention of this issue was to fix the hidden by CSS force H2 titles in the footer which only occurs in the footer_fifth region and not the column regions.

The patch needs to be amended to keep the original layout and style of all the footer regions and only affect the H2 titles. If the styling to fix the footer_fifth title improves footer_first to fourth, by using a useful reusable CSS selector for all regions I am all for that.

Otherwise leave the other regions alone as there is an existing issue for footer first to fourth regions titles (which have correct visibility behaviour but bad contrast) here #2304971: Change default block title colors in Footer first to fourth regions to improve contrast.

prateekS’s picture

Assigned: Unassigned » prateekS
prateekS’s picture

Assigned: prateekS » Unassigned
prateekS’s picture

I am not able to reproduce this issue. I guess problem is title of blocks should not visible if blocks on footers not enable. Which i tried by enabling/disabling blocks on footer regions but not able to find this issue. Is this resolved .

crazyrohila’s picture

Assigned: Unassigned » crazyrohila
Issue summary: View changes
FileSize
18.61 KB

Still issue exist. I have enable the title of fifth block, but not able to see in footer block. and visiblity of other first-to-forth column block title is also not so clear.
Footer block title issue

Working on reroll.

crazyrohila’s picture

Assigned: crazyrohila » Unassigned
Status: Needs work » Needs review
FileSize
1.31 KB

Rerolled patch.

Status: Needs review » Needs work

The last submitted patch, 29: footer-block-title-visibility-2148319-29.patch, failed testing.

Chloe Chen’s picture

updated footer region one to four title color to be #ffffff, to increase contrast and differ from link color

crazyrohila’s picture

@chloe I think this patch should be on https://www.drupal.org/node/2304971.
Scope of this issue is, just show title of footer_bottom/footer_fifth when user checked 'display title' in block configuration.

crazyrohila’s picture

Status: Needs work » Needs review
Issue tags: -Needs reroll
FileSize
1.03 KB

Pass to bot...

tim.plunkett’s picture

Please combine the last two patches. We can't introduce a visual regression. Pretty sure we had this conversation already.

Status: Needs review » Needs work

The last submitted patch, 33: footer-fifth-block-title-visibility-2148319-33.patch, failed testing.

Manjit.Singh’s picture

Combining last two patches :)

crazyrohila’s picture

@tim, sorry was not aware of.

@manjit,

+++ b/core/themes/bartik/css/components/footer.css
@@ -3,6 +3,9 @@
+  color: #f2f2f2;

color should be the same as we have for `.content`.

crazyrohila’s picture

Status: Needs work » Needs review
FileSize
1.32 KB

As per above comment, block title should have same color as block content.

Status: Needs review » Needs work

The last submitted patch, 38: footer-block-title-visibility-2148319-38.patch, failed testing.

LewisNyman’s picture

+++ b/core/profiles/standard/config/install/block.block.bartik_footer.yml
@@ -9,7 +9,7 @@ settings:
-  label_display: visible
+  label_display: 0

I think the test is failing because this should not be an integer

+++ b/core/profiles/standard/config/install/block.block.bartik_footer.yml
@@ -9,7 +9,7 @@ settings:
-  label_display: visible
+  label_display: '0'

In previous patches, the value was a string

crazyrohila’s picture

Status: Needs work » Needs review
FileSize
1.32 KB

Let's see now.

Manjit.Singh’s picture

Status: Needs review » Reviewed & tested by the community

Looks good now :) I think we have to close it now.

The last submitted patch, 31: h2-on-footer-show-when-enabled-2148319-9719693.patch, failed testing.

The last submitted patch, 36: footer-block-title-visibility-2148319-36.patch, failed testing.

joshtaylor’s picture

Status: Reviewed & tested by the community » Needs review
FileSize
1.25 KB

https://www.drupal.org/node/2398451 broke this patch?

Straight reroll.

idebr’s picture

Issue summary: View changes
Status: Needs review » Reviewed & tested by the community
FileSize
128.03 KB

Thanks @joshtaylor! Did a manual test to confirm the title is now displayed correctly when the title is not hidden:

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

CSS is not frozen in beta. Committed 66af922 and pushed to 8.0.x. Thanks!

  • alexpott committed 66af922 on 8.0.x
    Issue #2148319 by crazyrohila, juankvillegas, Manjit.Singh, poojakural,...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.