feat: refine widget interactions
This commit is contained in:
1 parent
a8a7545f40
commit
842e86012d
107 files changed
+3144
-1233
No files matched your search
@@ -0,0 +1,23 @@
|
||||
import { describe, expect, test } from "vitest";
|
||||
|
||||
import { getArchiveCompactLayout } from "./component";
|
||||
|
||||
describe("archive team warrior compact layout", () => {
|
||||
test("keeps only primary counters in a minimum-size widget", () => {
|
||||
expect(getArchiveCompactLayout(180, 100)).toMatchObject({
|
||||
metricColumns: 2,
|
||||
showBandwidth: false,
|
||||
showBroadcast: false,
|
||||
showSecondaryCounts: false,
|
||||
});
|
||||
});
|
||||
|
||||
test("adds secondary information as height becomes available", () => {
|
||||
expect(getArchiveCompactLayout(320, 260)).toMatchObject({
|
||||
metricColumns: 4,
|
||||
showBandwidth: true,
|
||||
showBroadcast: true,
|
||||
showSecondaryCounts: true,
|
||||
});
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user