edit layout and index