fix bug with wrong widths on page's load