Added in support for margins
Added in random element generation to example.html