1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 10:48:11 +00:00

LibWeb: Flesh out apply the history step to setup the navigation API

We now populate the navigation history entries in the navigation API and
fire more navigation events as appropriate.
This commit is contained in:
Andrew Kaster 2023-09-27 22:59:57 -06:00 committed by Alexander Kalenik
parent a8091c009b
commit 6c1944ee61
11 changed files with 339 additions and 78 deletions

View file

@ -3,10 +3,10 @@
test(() => {
let n = window.navigation;
// FIXME: Once we set up the interaction between Navigables and Navigation,
// These two should become 1 and [object NavigationHistoryEntry], respectively
println(`entries is empty: ${n.entries().length == 0}`);
println(`currentEntry is null: ${n.currentEntry == null}`);
let len = n.entries().length;
println(`entries[length - 1] is current entry: ${n.entries()[len - 1] === n.currentEntry}`);
println(`currentEntry is a ${n.currentEntry}`);
println(`transition is null: ${n.transition == null}`);
println(`canGoBack: ${n.canGoBack}`);