fix bug when image size turn to 0
bind resize event
add a html file