1

Image of the Website Footer

body {
    background-color: #222;
}

.minimal-footer {
    margin-left: 15%;
    color: #add8e6;
    font-family: 'Roboto Mono', monospace;
    list-style: none;
    font-size: 11px;
}

.text-wrapper {
    list-style: none;
    margin-top: 4%;
    margin-bottom: 4%;
    font-size: 12px
}


.text-wrapper li a {
    text-decoration: none;
    color: #add8e6;
}

.text-wrapper li a:hover {
    color: #fff;
    font-weight: bold; 
}
  <footer>
            <div class="minimal-footer">
                <ul class="text-wrapper">
                    <li><img src="img/creator.png" style="height: 16px;"><span class="footer-text"> Created by Obito</span></li>
                    <li><img src="img/creator.png" style="height: 16px;"><span class="footer-text"> Follow our <a href="twitter.com/ObitoFN">Twitter</a></span></li>
                    <li><img src="img/creator.png" style="height: 16px;"><span class="footer-text"> Check our other <a href="">Socials</a></span></li>
                    <li><img src="img/creator.png" style="height: 16px;"><span class="footer-text"> Support this <a href="">Project</a></span></li>
                </ul>
            </div>
        </footer>

I have already tried vertically aligning both the text and the image in my code, attached above, but I couldn't find a solution. There is always padding on either the top or the bottom of the text, disallowing it to center itself with the image, which I want to remove.

1 Answers1

0

this should do the trick:

.text-wrapper li {
    display: flex;
    align-items: center;
}
biberman
  • 5,606
  • 4
  • 11
  • 35
  • Thanks, it worked but now the hyperlink that I have added is stuck to the text on the left, with no space in between – Sahib Anand Mar 24 '21 at 09:03
  • Could you show an image again? In my testcase it look nearly like this: ```[img] Follow our Twitter``` – biberman Mar 24 '21 at 11:00