Bug 834703 - [Transitions. UX] Implement going deeper transitions as specified (r=)

I screwed up the previous PR (https://github.com/mozilla-b2g/gaia/pull/9793) so I am sending a new one with the latest version of the code and skeletons of the new unit tests to test the navigation.js library.