change layout of documents in event