Extract image gallery to a component