fix errors
rearrange ui, fix errors
resolve conflict