Download web/src/lib/dashboard-modal-shell.test.ts from SaylorTwift/hermes-agent: direct link, hf CLI and curl.
- Browser
- Download file 852 Bytes
-
https://huggingface.co/SaylorTwift/hermes-agent/resolve/main/web/src/lib/dashboard-modal-shell.test.ts
- Command line
-
hf download hf://SaylorTwift/hermes-agent/web/src/lib/dashboard-modal-shell.test.ts
-
curl -L -o dashboard-modal-shell.test.ts https://huggingface.co/SaylorTwift/hermes-agent/resolve/main/web/src/lib/dashboard-modal-shell.test.ts
852 Bytes
| import { describe, expect, it } from "vitest"; | |
| import { | |
| DASHBOARD_MODAL_BACKDROP, | |
| DASHBOARD_MODAL_PANEL, | |
| shouldCloseOuterModalOnEscape, | |
| } from "./dashboard-modal-shell"; | |
| describe("dashboard modal shell", () => { | |
| it("uses an opaque panel (bg-card), not the glass Card default", () => { | |
| expect(DASHBOARD_MODAL_PANEL).toMatch(/\bbg-card\b/); | |
| expect(DASHBOARD_MODAL_PANEL).not.toMatch(/bg-background-base\/\d+/); | |
| }); | |
| it("keeps the backdrop above page chrome (z-[100])", () => { | |
| expect(DASHBOARD_MODAL_BACKDROP).toMatch(/z-\[100\]/); | |
| expect(DASHBOARD_MODAL_BACKDROP).toMatch(/\bbg-background\/85\b/); | |
| }); | |
| it("does not close the outer modal on Escape while a nested picker is open", () => { | |
| expect(shouldCloseOuterModalOnEscape(true)).toBe(false); | |
| expect(shouldCloseOuterModalOnEscape(false)).toBe(true); | |
| }); | |
| }); | |