feat: add reload button to percury unblocker

This commit is contained in:
Percs 2024-10-13 19:22:31 -05:00
parent 2512c86496
commit e04a719140
2 changed files with 15 additions and 9 deletions

View file

@ -30,4 +30,8 @@ export class ScramjetFrame extends EventTarget {
forward() {
this.frame.contentWindow?.history.forward();
}
reload() {
this.frame.contentWindow?.location.reload();
}
}

View file

@ -91,7 +91,7 @@ function Config() {
setTimeout(() => {
modal.close();
modal.style.opacity = 1;
}, 250)
}, 250);
}
return html`
@ -100,7 +100,8 @@ function Config() {
<div class=${[flex, "buttons"]}>
<button on:click=${() => connection.setTransport("/baremod/index.mjs", [store.bareurl])}>use bare server 3</button>
<button on:click=${() =>
connection.setTransport("/libcurl/index.mjs", [{wisp: store.wispurl},
connection.setTransport("/libcurl/index.mjs", [
{ wisp: store.wispurl },
])}>use libcurl.js</button>
<button on:click=${() => connection.setTransport("/epoxy/index.mjs", [{ wisp: store.wispurl }])}>use epoxy</button>
</div>
@ -236,6 +237,7 @@ function App() {
<button on:click=${() => cfg.showModal()}>config</button>
<button on:click=${() => frame.back()}>&lt;-</button>
<button on:click=${() => frame.forward()}>-&gt;</button>
<button on:click=${() => frame.reload()}>&#x21bb;</button>
<input class="bar" bind:value=${use(this.url)} on:input=${(e) => {
this.url = e.target.value;