added layout-state model
fixed routing bug
fixed links rendering