Fix layout block validation error and optimise the js
Merge remote-tracking branch 'origin/master' into 2.3