In my application I need a modal with URL state that can be accessed from any route. The previous state should also be persisted so that I can return to it on closing the modal.
In addition, when I directly access the route through the URL, the component should be loaded without the modal
The discussion that came closest to what i'm looking for is this, http://stackoverflow.com/questions/27942891/emberjs-modal-as-a-route
The answer in the above discussion cannot be used here since I need it for all my routes.
The difference in my usecase is that the modal will have a route that is not nested within the other routes in the app.
If you are in the route 'rootURL/some_route', the modal when opened should have the following route 'rootURL/modal_route'. When the modal is closed, the state should be returned to 'rootURL/some_route'. But if you directly navigate to 'rootURL/modal_route', the same component that was used in the modal should be rendered as a page.
Any pointers on how this can be implemented?