Implement how it works page

This commit is contained in:
adilallo
2026-05-17 22:40:06 -06:00
parent 450da4d8ab
commit 40ce5064d6
35 changed files with 707 additions and 123 deletions
+22
View File
@@ -60,4 +60,26 @@ describe("ContentBanner", () => {
render(<ContentBanner post={mockPost} />);
expect(screen.getByText("Test description")).toBeInTheDocument();
});
it("renders guide variant with left-aligned copy and logo mark", () => {
const { container } = render(
<ContentBanner post={mockPost} variant="guide" />,
);
expect(
screen.getByRole("heading", { name: "Test Article" }),
).toBeInTheDocument();
expect(screen.getByText("Test description")).toBeInTheDocument();
expect(screen.queryByText("Test Author")).not.toBeInTheDocument();
const bannerRow = container.querySelector('[data-node-id="19189:9358"]');
expect(bannerRow).toHaveClass("md:flex-row");
const logoMark = container.querySelector(
'[data-node-id="22078:806960"] img',
);
expect(logoMark).toHaveAttribute(
"src",
expect.stringContaining("guide-banner-logo-arrow.svg"),
);
});
});