Tweak wait_until option

Small tweaks to https://github.com/lightpanda-io/browser/pull/1896

Improve the wait ergonomics with an Option with default parameter. Revert
page pointer logic to original (don't think that change was necessary).
This commit is contained in:
Karl Seguin
2026-03-19 20:29:20 +08:00
parent e2be8525c4
commit a4cb5031d1
8 changed files with 25 additions and 18 deletions

View File

@@ -106,7 +106,7 @@ pub fn run(allocator: Allocator, file: []const u8, session: *lp.Session) !void {
defer try_catch.deinit();
try page.navigate(url, .{});
_ = session.wait(2000, .load);
_ = session.wait(.{});
ls.local.eval("testing.assertOk()", "testing.assertOk()") catch |err| {
const caught = try_catch.caughtOrError(allocator, err);