Files
t3code/apps/web/src/rightPanelLayout.test.ts
T
Julius Marminge 60dc48a413 Require Cursor API key for provider checks
- Switch Cursor provider status and model discovery to the SDK catalog
- Improve chat content lane alignment and provider secret handling
2026-08-03 11:45:07 -04:00

20 lines
884 B
TypeScript

import { describe, expect, it } from "vite-plus/test";
import { resolveThreadPanelPresentation } from "./rightPanelLayout";
describe("resolveThreadPanelPresentation", () => {
it("uses the stable workspace width minus the real right panel width", () => {
expect(resolveThreadPanelPresentation(null, 0, false)).toBe("inline");
expect(resolveThreadPanelPresentation(1_104, 0, false)).toBe("inline");
expect(resolveThreadPanelPresentation(1_103, 0, false)).toBe("popover");
expect(resolveThreadPanelPresentation(1_400, 0, false)).toBe("inline");
expect(resolveThreadPanelPresentation(1_400, 540, false)).toBe("popover");
expect(resolveThreadPanelPresentation(1_644, 540, false)).toBe("inline");
});
it("uses a popover while the real right panel is maximized", () => {
expect(resolveThreadPanelPresentation(2_000, 0, true)).toBe("popover");
});
});