A great place for you is the CSS Tricks article . It conveys all the meanings that vertical-align
can have and the various uses of each in a clear concise form.
Here are the options:
vertical-align: baseline vertical-align: sub vertical-align: super vertical-align: text-top vertical-align: text-bottom vertical-align: middle vertical-align: top vertical-align: bottom
And here are the valid options for table cells:
baseline (and sub, super, text-top, text-bottom, <length>, and <percentage>) Align the baseline of the cell with the baseline of all other cells in the row that are baseline-aligned. top Align the top padding edge of the cell with the top of the row. middle Center the padding box of the cell within the row. bottom Align the bottom padding edge of the cell with the bottom of the row.
In addition, you can try other tricks, such as setting the line-height
equal to the height of the parent container.
source share