mirror of
https://github.com/simon987/Simple-Incremental-Search-Tool.git
synced 2025-12-14 07:39:05 +00:00
Finished path search & autocomplete. Added font parsing
This commit is contained in:
@@ -9,19 +9,19 @@
|
||||
|
||||
function swapToForm(elem, fields, formAction, inputName) {
|
||||
|
||||
var form = document.createElement("form");
|
||||
let form = document.createElement("form");
|
||||
form.setAttribute("action", formAction);
|
||||
|
||||
for (var i in fields) {
|
||||
for (let i in fields) {
|
||||
|
||||
var hiddenInput = document.createElement("input");
|
||||
let hiddenInput = document.createElement("input");
|
||||
hiddenInput.setAttribute("type", "hidden");
|
||||
hiddenInput.setAttribute("value", fields[i].value);
|
||||
hiddenInput.setAttribute("name", fields[i].name);
|
||||
form.appendChild(hiddenInput);
|
||||
}
|
||||
|
||||
var input = document.createElement("input");
|
||||
let input = document.createElement("input");
|
||||
input.setAttribute("class", "form-control");
|
||||
input.setAttribute("type", "text");
|
||||
input.setAttribute("name", inputName);
|
||||
|
||||
@@ -563,9 +563,17 @@
|
||||
docCard.appendChild(contentDiv);
|
||||
}
|
||||
|
||||
//Font_name
|
||||
if (hit.hasOwnProperty("highlight") && hit["highlight"].hasOwnProperty("font_name")) {
|
||||
let contentDiv = document.createElement("div");
|
||||
contentDiv.setAttribute("class", "content-div bg-light");
|
||||
contentDiv.insertAdjacentHTML('afterbegin', hit["highlight"]["font_name"][0]);
|
||||
docCard.appendChild(contentDiv);
|
||||
}
|
||||
|
||||
//Audio
|
||||
if (mimeCategory === "audio") {
|
||||
|
||||
//TODO
|
||||
}
|
||||
|
||||
if (thumbnail !== null) {
|
||||
|
||||
Reference in New Issue
Block a user