Add form factors

https://bugzilla.mozilla.org/show_bug.cgi?id=978150

This includes the commit from pull request 1859. It may be easier to just review the new commit. The plan is to commit this in coordination but it was easier to do the work in separate chunks.