you need to set the line-height property of the li elements to the same as the height of the custom icon.
For example, if your icon is 32 pixels high, you should write:
ul li { line-height: 32px; }
It is better to use an identifier to identify the ul element, otherwise you may end up affecting all ul in the document.
source share