reorder element generation and fix specs

reorder element generation and fix specs