Pārlūkot izejas kodu

Add divider in metrics

Kirk Trombley 3 gadi atpakaļ
vecāks
revīzija
96bd2e27d4
1 mainītis faili ar 9 papildinājumiem un 0 dzēšanām
  1. 9 0
      nearest.html

+ 9 - 0
nearest.html

@@ -40,6 +40,15 @@
       `);
       `);
 
 
       Object.entries(metrics).forEach(([name, metric]) => {
       Object.entries(metrics).forEach(([name, metric]) => {
+        if (name === "inertia") {
+          const spacer = document.createElement("option");
+          spacer.disabled = true;
+          document.getElementById("sort-metric").appendChild(spacer);
+          spacer.innerHTML = "---";
+          const clone = spacer.cloneNode();
+          document.getElementById("cluster-sort-metric").appendChild(clone);
+          clone.innerHTML = "---";
+        }
         const opt = document.createElement("option");
         const opt = document.createElement("option");
         opt.setAttribute("value", name);
         opt.setAttribute("value", name);
         document.getElementById("sort-metric").appendChild(opt);
         document.getElementById("sort-metric").appendChild(opt);