Fix UI bugs

This commit is contained in:
simon 2019-10-26 20:28:29 -04:00
parent cbb043f03f
commit 85ab2858f6
4 changed files with 5 additions and 6 deletions

View File

@ -5,7 +5,7 @@
#define EPILOG "Made by simon987 <me@simon987.net>. Released under GPL-3.0" #define EPILOG "Made by simon987 <me@simon987.net>. Released under GPL-3.0"
static const char *const Version = "1.0.4"; static const char *const Version = "1.0.5";
static const char *const usage[] = { static const char *const usage[] = {
"sist2 scan [OPTION]... PATH", "sist2 scan [OPTION]... PATH",
"sist2 index [OPTION]... INDEX", "sist2 index [OPTION]... INDEX",

File diff suppressed because one or more lines are too long

View File

@ -170,11 +170,10 @@ function createDocCard(hit) {
} }
//Tags //Tags
//todo: handle new tags
switch (mimeCategory) { switch (mimeCategory) {
case "video": case "video":
case "image": case "image":
if (hit.hasOwnProperty("videoc")) { if (hit["_source"].hasOwnProperty("videoc")) {
let formatTag = document.createElement("span"); let formatTag = document.createElement("span");
formatTag.setAttribute("class", "badge badge-pill badge-video"); formatTag.setAttribute("class", "badge badge-pill badge-video");
formatTag.appendChild(document.createTextNode(hit["_source"]["videoc"].replace(" ", ""))); formatTag.appendChild(document.createTextNode(hit["_source"]["videoc"].replace(" ", "")));
@ -182,7 +181,7 @@ function createDocCard(hit) {
} }
break; break;
case "audio": { case "audio": {
if (hit.hasOwnProperty("audioc")) { if (hit["_source"].hasOwnProperty("audioc")) {
let formatTag = document.createElement("span"); let formatTag = document.createElement("span");
formatTag.setAttribute("class", "badge badge-pill badge-audio"); formatTag.setAttribute("class", "badge badge-pill badge-audio");
formatTag.appendChild(document.createTextNode(hit["_source"]["audioc"])); formatTag.appendChild(document.createTextNode(hit["_source"]["audioc"]));

View File

@ -1,4 +1,4 @@
const SIZE = 20; const SIZE = 40;
let mimeMap = []; let mimeMap = [];
let tree; let tree;