Added check if stacked before resetting height

If items are stacked one on top of the other, script won’t set content
containers to equal heights. This helps avoid unneeded white space at
the bottom of each.