This commit is contained in:
Stephan Porada 2020-04-06 12:52:26 +02:00
parent 41f24a03b4
commit 1ed696f558
3 changed files with 5 additions and 3 deletions

View File

@ -56,4 +56,8 @@ function queryRenderResults(payload) {
queryResultsExportElement.classList.remove("disabled"); queryResultsExportElement.classList.remove("disabled");
activateInspect(); activateInspect();
} }
if (expertModeSwitchElement) {
let initialTokenElements = document.getElementsByClassName("token");
expertModeOn(initialTokenElements, resultsJSON);
}
} }

View File

@ -225,8 +225,6 @@ function expertModeOn(tokenElements, results) {
let token; let token;
console.log("expertModeOn!"); console.log("expertModeOn!");
console.log(results);
console.log("hier:", tokenElements);
for (let tokenElement of tokenElements) { for (let tokenElement of tokenElements) {
tokenElement.classList.add("chip"); tokenElement.classList.add("chip");
tokenElement.classList.add("hoverable"); tokenElement.classList.add("hoverable");

View File

@ -280,6 +280,7 @@
receivedMatchCountElement = document.getElementById("received-match-count"); receivedMatchCountElement = document.getElementById("received-match-count");
matchCountElement = document.getElementById("match-count"); matchCountElement = document.getElementById("match-count");
textLookupCountElement = document.getElementById("text-lookup-count"); textLookupCountElement = document.getElementById("text-lookup-count");
var expertModeSwitchElement = document.getElementById("display-options-form-expert_mode");
document.addEventListener("DOMContentLoaded", () => { document.addEventListener("DOMContentLoaded", () => {
@ -345,7 +346,6 @@
} }
// epxert mode table view // epxert mode table view
expertModeSwitchElement = document.getElementById("display-options-form-expert_mode");
expertModeSwitchElement.addEventListener("change", function(event) { expertModeSwitchElement.addEventListener("change", function(event) {
let currentTokenElements = document.getElementsByClassName("token"); let currentTokenElements = document.getElementsByClassName("token");
let paginationElements = document.getElementsByClassName("pagination"); let paginationElements = document.getElementsByClassName("pagination");