Fix error when toggle sidebar

In the previous commit, when the viewport was small and the sidebar was
toggled, an error prevented the content wrapper from resizing.