chore: back-forward in bidi
This commit is contained in:
parent
ad70e7a783
commit
4c6019d308
|
|
@ -315,12 +315,18 @@ export class BidiPage implements PageDelegate {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
goBack(): Promise<boolean> {
|
async goBack(): Promise<boolean> {
|
||||||
throw new Error('Method not implemented.');
|
return await this._session.send('browsingContext.traverseHistory', {
|
||||||
|
context: this._session.sessionId,
|
||||||
|
delta: -1,
|
||||||
|
}).then(() => true).catch(() => false);
|
||||||
}
|
}
|
||||||
|
|
||||||
goForward(): Promise<boolean> {
|
async goForward(): Promise<boolean> {
|
||||||
throw new Error('Method not implemented.');
|
return await this._session.send('browsingContext.traverseHistory', {
|
||||||
|
context: this._session.sessionId,
|
||||||
|
delta: +1,
|
||||||
|
}).then(() => true).catch(() => false);
|
||||||
}
|
}
|
||||||
|
|
||||||
async forceGarbageCollection(): Promise<void> {
|
async forceGarbageCollection(): Promise<void> {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue