Skip to content

Commit

Permalink
fix lints
Browse files Browse the repository at this point in the history
  • Loading branch information
dyc3 committed Feb 13, 2024
1 parent 76a6a54 commit aac1ce3
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 61 deletions.
2 changes: 1 addition & 1 deletion packages/ott-vis-datasource/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
"strict": true,
"typeRoots": ["../../node_modules/@types"],
"esModuleInterop": true,
"jsx": "react",
"jsx": "react"
}
}
45 changes: 16 additions & 29 deletions packages/ott-vis/src/aggregate.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,24 +10,20 @@ const sampleSystemState: SystemState = [
id: "2bd5e4a7-14f6-4da4-bedd-72946864a7bf",
region: "ewr",
rooms: [
{name: "foo", clients: 2},
{name: "bar", clients: 0},
{ name: "foo", clients: 2 },
{ name: "bar", clients: 0 },
],
},
{
id: "419580cb-f576-4314-8162-45340c94bae1",
region: "ewr",
rooms: [
{name: "baz", clients: 3},
]
rooms: [{ name: "baz", clients: 3 }],
},
{
id: "0c85b46e-d343-46a3-ae4f-5f2aa1a8bdac",
region: "cdg",
rooms: [
{name: "qux", clients: 0},
]
}
rooms: [{ name: "qux", clients: 0 }],
},
],
},
{
Expand All @@ -38,24 +34,20 @@ const sampleSystemState: SystemState = [
id: "2bd5e4a7-14f6-4da4-bedd-72946864a7bf",
region: "ewr",
rooms: [
{name: "foo", clients: 1},
{name: "bar", clients: 2},
{ name: "foo", clients: 1 },
{ name: "bar", clients: 2 },
],
},
{
id: "419580cb-f576-4314-8162-45340c94bae1",
region: "ewr",
rooms: [
{name: "baz", clients: 0},
]
rooms: [{ name: "baz", clients: 0 }],
},
{
id: "0c85b46e-d343-46a3-ae4f-5f2aa1a8bdac",
region: "cdg",
rooms: [
{name: "qux", clients: 0},
]
}
rooms: [{ name: "qux", clients: 0 }],
},
],
},
{
Expand All @@ -66,27 +58,23 @@ const sampleSystemState: SystemState = [
id: "2bd5e4a7-14f6-4da4-bedd-72946864a7bf",
region: "ewr",
rooms: [
{name: "foo", clients: 0},
{name: "bar", clients: 0},
{ name: "foo", clients: 0 },
{ name: "bar", clients: 0 },
],
},
{
id: "419580cb-f576-4314-8162-45340c94bae1",
region: "ewr",
rooms: [
{name: "baz", clients: 0},
]
rooms: [{ name: "baz", clients: 0 }],
},
{
id: "0c85b46e-d343-46a3-ae4f-5f2aa1a8bdac",
region: "cdg",
rooms: [
{name: "qux", clients: 4},
]
}
rooms: [{ name: "qux", clients: 4 }],
},
],
},
]
];

describe("aggregation helpers", () => {
it("counts room clients", () => {
Expand All @@ -106,4 +94,3 @@ describe("aggregation helpers", () => {
});
});
});

46 changes: 16 additions & 30 deletions packages/ott-vis/src/components/CorePanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,24 +37,20 @@ const sampleSystemState: SystemState = [
id: "2bd5e4a7-14f6-4da4-bedd-72946864a7bf",
region: "ewr",
rooms: [
{name: "foo", clients: 2},
{name: "bar", clients: 0},
{ name: "foo", clients: 2 },
{ name: "bar", clients: 0 },
],
},
{
id: "419580cb-f576-4314-8162-45340c94bae1",
region: "ewr",
rooms: [
{name: "baz", clients: 3},
]
rooms: [{ name: "baz", clients: 3 }],
},
{
id: "0c85b46e-d343-46a3-ae4f-5f2aa1a8bdac",
region: "cdg",
rooms: [
{name: "qux", clients: 0},
]
}
rooms: [{ name: "qux", clients: 0 }],
},
],
},
{
Expand All @@ -65,24 +61,20 @@ const sampleSystemState: SystemState = [
id: "2bd5e4a7-14f6-4da4-bedd-72946864a7bf",
region: "ewr",
rooms: [
{name: "foo", clients: 1},
{name: "bar", clients: 2},
{ name: "foo", clients: 1 },
{ name: "bar", clients: 2 },
],
},
{
id: "419580cb-f576-4314-8162-45340c94bae1",
region: "ewr",
rooms: [
{name: "baz", clients: 0},
]
rooms: [{ name: "baz", clients: 0 }],
},
{
id: "0c85b46e-d343-46a3-ae4f-5f2aa1a8bdac",
region: "cdg",
rooms: [
{name: "qux", clients: 0},
]
}
rooms: [{ name: "qux", clients: 0 }],
},
],
},
{
Expand All @@ -93,29 +85,23 @@ const sampleSystemState: SystemState = [
id: "2bd5e4a7-14f6-4da4-bedd-72946864a7bf",
region: "ewr",
rooms: [
{name: "foo", clients: 0},
{name: "bar", clients: 0},
{ name: "foo", clients: 0 },
{ name: "bar", clients: 0 },
],
},
{
id: "419580cb-f576-4314-8162-45340c94bae1",
region: "ewr",
rooms: [
{name: "baz", clients: 0},
]
rooms: [{ name: "baz", clients: 0 }],
},
{
id: "0c85b46e-d343-46a3-ae4f-5f2aa1a8bdac",
region: "cdg",
rooms: [
{name: "qux", clients: 4},
]
}
rooms: [{ name: "qux", clients: 4 }],
},
],
},
]


];

export const CorePanel: React.FC<Props> = ({ options, data, width, height }) => {
const styles = useStyles2(getStyles);
Expand Down
2 changes: 1 addition & 1 deletion packages/ott-vis/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
"strict": true,
"typeRoots": ["../../node_modules/@types"],
"esModuleInterop": true,
"jsx": "react",
"jsx": "react"
}
}

0 comments on commit aac1ce3

Please sign in to comment.