fix: form submission
This commit is contained in:
parent
1a0b35d615
commit
7f85686d93
3 changed files with 7 additions and 7 deletions
Before Width: | Height: | Size: 428 KiB After Width: | Height: | Size: 428 KiB |
|
@ -98,7 +98,7 @@ async fn open_post(ctx: web::Data<Args>) -> impl Responder {
|
||||||
|
|
||||||
#[get("/curtain.jpeg")]
|
#[get("/curtain.jpeg")]
|
||||||
async fn curtain_jpeg() -> impl Responder {
|
async fn curtain_jpeg() -> impl Responder {
|
||||||
let curtain = include_bytes!("./curatain.jpeg");
|
let curtain = include_bytes!("./curtain.jpeg");
|
||||||
|
|
||||||
let curtain = actix_web::web::Bytes::from_static(curtain);
|
let curtain = actix_web::web::Bytes::from_static(curtain);
|
||||||
|
|
||||||
|
|
|
@ -81,7 +81,7 @@ SPDX-License-Identifier: AGPL-3.0-or-later
|
||||||
width: 50%;
|
width: 50%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
filter: brightness(180%);
|
filter: brightness(180%);
|
||||||
background-image: url("./curatain-min.jpeg");
|
background-image: url("./curtain.jpeg");
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
}
|
}
|
||||||
|
@ -283,13 +283,13 @@ SPDX-License-Identifier: AGPL-3.0-or-later
|
||||||
|
|
||||||
function detectSpaceKey(event) {
|
function detectSpaceKey(event) {
|
||||||
if(event.keyCode == 13) {
|
if(event.keyCode == 13) {
|
||||||
|
|
||||||
showTime();
|
showTime();
|
||||||
|
|
||||||
var form = document.createElement("form");
|
fetch("/", {method: "post"}).then(() =>
|
||||||
form.setAttribute("action", "/");
|
startCountdown()
|
||||||
form.setAttribute("method", "post");
|
);
|
||||||
}
|
}
|
||||||
// startCountdown();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function showTime() {
|
function showTime() {
|
||||||
|
|
Loading…
Add table
Reference in a new issue