Fix unitlayout remove not working. Change remove feature of edit. Minor JS cleanup.