diff --git a/app/templates/index.html b/app/templates/index.html
index 588e0ff..52a31db 100755
--- a/app/templates/index.html
+++ b/app/templates/index.html
@@ -9,6 +9,7 @@
--dark: #2c2c2c;
--darker: #171717;
--light: #bfbfbf;
+ --confirm: #970000;
}
html {
height: 100%;
@@ -21,7 +22,6 @@
}
img, video {
max-width: 100%;
- max-height: 100vh;
width: auto;
height: auto;
}
@@ -54,7 +54,6 @@
}
div.post {
width: 70vw;
- margin-left: 20px;
}
.container {
display: flex;
@@ -65,7 +64,8 @@
height: 100vh;
flex-direction: column;
overflow-y: auto;
- padding: 5px
+ padding: 5px;
+ margin-right: 20px;
}
}
/* phone */
@@ -89,6 +89,7 @@
align-items: center;
padding-top: 5px;
padding-bottom: 5px;
+ margin-bottom: 10px;
}
.content {
align-items: center;
@@ -106,9 +107,6 @@
background-color: var(--darker);
color: var(--light);
}
- .content h1 {
- margin-left: 20px;
- }
.invert {
filter: invert(1);
transition: filter 0.3s;
@@ -133,6 +131,9 @@
font-size: 1.25rem;
font-weight: bold;
}
+ .button-wrapper button.confirm {
+ background-color: var(--confirm)
+ }
.button-wrapper button.gallery {
padding: 5px;
background-color: var(--darker);
@@ -271,16 +272,16 @@
// main button code
function hide(button, permalink){
- const div = button.closest('.post');
- div.scrollTo({
- top: 0,
- behavior: 'smooth'
- });
- div.remove();
- try {
- fetch('/hide' + permalink);
- } catch (error) {
- console.error('Could hide', error);
+ if (button.classList.contains('confirm')) {
+ div = button.closest('.post');
+ div.remove();
+ try {
+ fetch('/hide' + permalink);
+ } catch (error) {
+ console.error('Could not hide', error);
+ }
+ } else {
+ button.classList.add('confirm');
}
}