prevent content going over the edge