diff --git a/tubearchivist/home/templates/home/video.html b/tubearchivist/home/templates/home/video.html
index f30a231..f4fa7c8 100644
--- a/tubearchivist/home/templates/home/video.html
+++ b/tubearchivist/home/templates/home/video.html
@@ -45,6 +45,10 @@
Youtube: Deactivated
{% endif %}
Video ID: {{ video.youtube_id }}
+
+
+ Are you sure?
+
diff --git a/tubearchivist/static/css/dark.css b/tubearchivist/static/css/dark.css
index a2669b9..3708489 100644
--- a/tubearchivist/static/css/dark.css
+++ b/tubearchivist/static/css/dark.css
@@ -2,6 +2,7 @@
--main-bg: #00202f;
--highlight-bg: #00293b;
--highlight-error: #990202;
+ --highlight-error-light: #c44343;
--highlight-bg-transparent: #00293baf;
--main-font: #eeeeee;
--accent-font-dark: #259485;
diff --git a/tubearchivist/static/css/light.css b/tubearchivist/static/css/light.css
index e2a85d0..6ad74c1 100644
--- a/tubearchivist/static/css/light.css
+++ b/tubearchivist/static/css/light.css
@@ -1,11 +1,12 @@
:root {
--main-bg: #eeeeee;
--highlight-bg: #d9e0d9;
- --highlight-error: #f79c9c;
+ --highlight-error: #990202;
+ --highlight-error-light: #c44343;
--highlight-bg-transparent: #00293baf;
--main-font: #00202f;
--accent-font-dark: #259485;
--accent-font-light: #35b399;
--img-filter: invert(50%) sepia(9%) saturate(2940%) hue-rotate(122deg) brightness(94%) contrast(90%);
- --img-filter-error: invert(83%) sepia(35%) saturate(1238%) hue-rotate(297deg) brightness(103%) contrast(97%);
+ --img-filter-error: invert(16%) sepia(60%) saturate(3717%) hue-rotate(349deg) brightness(86%) contrast(120%);
}
diff --git a/tubearchivist/static/css/style.css b/tubearchivist/static/css/style.css
index af78eef..6cbe388 100644
--- a/tubearchivist/static/css/style.css
+++ b/tubearchivist/static/css/style.css
@@ -205,6 +205,19 @@ button:hover {
color: var(--main-font);
}
+/* delete button */
+.delete-confirm {
+ display: none;
+}
+
+.danger-button {
+ background-color: var(--highlight-error);
+}
+
+.danger-button:hover {
+ background-color: var(--highlight-error-light);
+}
+
/* navigation */
.top-nav {
display: block;
@@ -658,6 +671,10 @@ button:hover {
background-color: var(--highlight-error);
}
+.download-progress.error h3 {
+ color: #fff;
+}
+
/* settings */
.settings-group {
background-color: var(--highlight-bg);
@@ -675,6 +692,7 @@ button:hover {
.danger-zone {
background-color: var(--highlight-error);
+ color: #fff;
padding: 3px;
}
diff --git a/tubearchivist/static/script.js b/tubearchivist/static/script.js
index 488e47e..636de79 100644
--- a/tubearchivist/static/script.js
+++ b/tubearchivist/static/script.js
@@ -176,6 +176,34 @@ function fsRescan() {
toReplace.appendChild(message);
}
+// delete from file system
+function deleteConfirm() {
+ console.log("confirm delete");
+ to_show = document.getElementById("delete-button");
+ document.getElementById("delete-item").style.display = 'none';
+ to_show.style.display = "block";
+}
+
+function deleteItem(button) {
+ var to_delete = button.getAttribute("data-id");
+ var to_redirect = button.getAttribute("data-redirect");
+ var payload = JSON.stringify({"delete-video": to_delete});
+ console.log(payload);
+ console.log(to_redirect);
+ sendPost(payload);
+ setTimeout(function(){
+ var redirect = "/channel/" + to_redirect;
+ window.location.replace(redirect);
+ return false;
+ }, 1000);
+}
+
+function cancelDelete() {
+ console.log("cancel delete");
+ document.getElementById("delete-button").style.display = 'none';
+ document.getElementById("delete-item").style.display = 'block';
+}
+
// player
function createPlayer(button) {
var mediaUrl = button.getAttribute('data-src');