I have 3 images aligned vertically at a fixed height div. How can I make sure that the top and bottom padding between them remains even when adding or removing an image.
Let's say the Div height is 100 pixels and the image height is 20 pixels. Thus, 3 images with 20px are summed up to 60 pixels. The remaining 40px should be evenly distributed as a complement between images.
Similarly, when another image is added, the remaining 20px should be indented between all images.
Property: vertical-align: middle does not work here.
source
share