show error color when link extraction failes

This commit is contained in:
simon 2021-09-10 14:27:30 +07:00
parent 3b07355f0b
commit 4580ea6f87
4 changed files with 11 additions and 10 deletions

View File

@ -1,6 +1,7 @@
:root { :root {
--main-bg: #00202f; --main-bg: #00202f;
--highlight-bg: #00293b; --highlight-bg: #00293b;
--highlight-error: #990202;
--highlight-bg-transparent: #00293baf; --highlight-bg-transparent: #00293baf;
--main-font: #eeeeee; --main-font: #eeeeee;
--accent-font-dark: #259485; --accent-font-dark: #259485;

View File

@ -1,19 +1,10 @@
:root { :root {
--main-bg: #eeeeee; --main-bg: #eeeeee;
--highlight-bg: #d9e0d9; --highlight-bg: #d9e0d9;
--highlight-error: #f79c9c;
--highlight-bg-transparent: #00293baf; --highlight-bg-transparent: #00293baf;
--main-font: #00202f; --main-font: #00202f;
--accent-font-dark: #259485; --accent-font-dark: #259485;
--accent-font-light: #35b399; --accent-font-light: #35b399;
--img-filter: invert(50%) sepia(9%) saturate(2940%) hue-rotate(122deg) brightness(94%) contrast(90%); --img-filter: invert(50%) sepia(9%) saturate(2940%) hue-rotate(122deg) brightness(94%) contrast(90%);
} }
/* :root {
--main-bg: #00202f;
--highlight-bg: #00293b;
--highlight-bg-transparent: #00293baf;
--main-font: #eeeeee;
--accent-font-dark: #259485;
--accent-font-light: #97d4c8;
--img-filter: invert(50%) sepia(9%) saturate(2940%) hue-rotate(122deg) brightness(94%) contrast(90%);
} */

View File

@ -478,6 +478,13 @@ button:hover {
padding: 30px 0 15px 0; padding: 30px 0 15px 0;
} }
.download-progress.info {
background-color: var(--highlight-bg);
}
.download-progress.error {
background-color: var(--highlight-error);
}
/* settings */ /* settings */
.settings-group { .settings-group {

View File

@ -54,6 +54,7 @@ function buildDownloadMessage(dlProgress) {
var dlStatus = dlProgress['status']; var dlStatus = dlProgress['status'];
var dlTitle = dlProgress['title']; var dlTitle = dlProgress['title'];
var dlMessage = dlProgress['message']; var dlMessage = dlProgress['message'];
var dlLevel = dlProgress['level'];
// animate // animate
if (dlStatus === 'rescan') { if (dlStatus === 'rescan') {
animate('rescan-icon', 'rotate-img'); animate('rescan-icon', 'rotate-img');
@ -64,6 +65,7 @@ function buildDownloadMessage(dlProgress) {
var box = document.getElementById('downloadMessage'); var box = document.getElementById('downloadMessage');
var message = document.createElement('div'); var message = document.createElement('div');
message.classList.add('download-progress'); message.classList.add('download-progress');
message.classList.add(dlLevel);
message.id = 'progress'; message.id = 'progress';
message.setAttribute('data', dlStatus); message.setAttribute('data', dlStatus);
var title = document.createElement('h3'); var title = document.createElement('h3');