Age | Commit message (Collapse) | Author |
|
Port 44a7d87cb1f5df953b6c14c16c59e2e4ead1bcb9 to glitch-soc
Signed-off-by: Claire <claire.github-309c@sitedethib.com>
|
|
I don't like it changing files this way, but it's basically what
c49213f0ea311daba590db1d7a14a641cbd9fe93 and a few others did.
|
|
Port 91582937f34c74dd76dabe7253864da8565f227e to glitch-soc
Signed-off-by: Thibaut Girka <thib@sitedethib.com>
|
|
Port 2dee293c4c98486d387105224023fad02b8b0d96 to glitch-soc
Signed-off-by: Thibaut Girka <thib@sitedethib.com>
|
|
|
|
|
|
So far, glitch-soc used history.length to decide whether to call `goBack()` or
go to / in order to not leave the webUI. This made clicking the “Back” button
go to the “Getting started” column instead of going back in the browser's
history when such an action would leave the web UI, but also when:
- The WebUI is refreshed (F5)
- A tab is restored
- The history length reaches its maximum (e.g., 50 in Firefox)
This commit fixes these shortcomings by checking `window.history.state`.
Indeed, we only want to go back in the browser's history when the current
location has been reached from within the WebUI, which only happens via
`pushState` as far as I know. Since browser store the serialized state in
the browser history, this also survives page reload and session restoration.
|
|
|