update metadata and layout