Removed title and fixed optimizer

This commit is contained in:
Gleb Koval 2021-07-19 02:56:02 +01:00
parent 6c89ca79fe
commit d9bb3c82f7
No known key found for this signature in database
GPG Key ID: 120F2F6DA9D995FB
2 changed files with 3 additions and 6 deletions

View File

@ -41,15 +41,15 @@ export async function get(
).all();
res.writeHead(200);
if (graph.data.style === "line") {
if (data[0].length === 2) {
if (data[0].length === 2 && !Array.isArray(data[0][0])) {
res.end(
JSON.stringify(
data.filter((value, idx) => {
return (
idx === 0 ||
idx === data.length - 1 ||
data[idx - 1][1] !== value ||
data[idx + 1][1] !== value
data[idx - 1][1] !== value[1] ||
data[idx + 1][1] !== value[1]
);
})
)

View File

@ -65,9 +65,6 @@
let c = document.querySelector("div#list");
if (c && g) {
init(c as HTMLElement, "dark").setOption({
title: {
text: g.data.name
},
tooltip: {
trigger: "axis",
order: "valueDesc"