resolves #11: resizes to fit content