fix bug in image component