images, layout, invoice refactoring