Site logo

Archived topic

Increase padding in footer bar

5 replies · Started by Jörg on November 29, 2021

Viewing posts 1–6 of 6

Hi,
I try to increase the minimum recommended touch target at my footer bar. How can I use additional padding to bring the tap target size up to 48px?
Thanks for the Help

Hi there,

Were you pertaining to the text links on the footer?

If that's the case, you can add padding to them through CSS:

.footer-bar aside#text-31 a { 
    padding: 12px; 
}

.footer-bar aside#text-31 p {
    display: flex;
    margin-bottom: 0;
}

.inside-site-info {
    display: flex;
    justify-content: space-between;
}

.footer-bar {
    margin-left: auto;
    order: 2;
}

.textwidget {
    display: flex;
    flex-direction: column;
}

.textwidget > *,
.textwidget > * a {
    flex: 1 0 100%;
    text-align: right;
}

Hi, thanks for the fast reply. I tried the code and reduced it to:

.footer-bar aside#text-31 a {
padding: 12px;
}

With this, the padding increased to 43. But Lighthouse is still reporting, that the space around the text is too small.

If you want to have a look, here is the url: https://tri-it-fit.de/mitochondrien-und-die-energiegewinnung-im-ausdauersport/

I'm talking about the four links on the right (Impressum etc.)

Is there something else I can do?

Hi there,

You need the links to be at the block level or the padding will collapse thanks to its the links parent being a list item.

.footer-bar aside#text-31 a {
    padding: 12px 0;
    display: inline-block;
}

Thanks. That will do the trick. ;)

Glad to hear that!

This archived topic is closed to new replies.