[fix] preform the resize hack when document is ready only