How exactly the image vertical offset is calculated here, what formula? From my understanding, vertical-align:middle in the image should move it’s vertical midpoint to some specific point of the text, but how exactly?
The context is that I wasn’t able to understand how vertical-align works exactly while I was learning html, so I tried to ask this on StackOverflow, but instead got all my questions and accounts deleted because apparently this is a too stupid question. So I googled “web dev forum” and here I am. But fortunately, I found the answer myself a day later, by testing.
Thank you for the link, I will definitely read it, but in my case setting both elements to “middle” didn’t help.
Instead, the answer was - Text offset depends on the font size of it’s parent (in my case, the parent is body)
I have realized it by doing more tests.