fix(ai-toolbar): wrap masonry prompt cards correctly

This commit is contained in:
2026-04-22 17:45:57 -04:00
parent e1a12d0c71
commit a93d95ee2e
2 changed files with 5 additions and 2 deletions

View File

@@ -343,7 +343,7 @@ export const AIToolbar = ({
type="button"
variant="secondary"
size="sm"
className="h-auto w-full text-left justify-start rounded-2xl px-3 py-2 text-[11px] leading-relaxed"
className="h-auto w-full justify-start text-left whitespace-normal rounded-2xl px-3 py-2 text-[11px] leading-relaxed"
onClick={() => onAiTemplateSelect(prompt)}
disabled={aiLoading || !canUseAi}
>

View File

@@ -172,7 +172,10 @@ describe("AI capture redesign", () => {
expect(source).toContain("Try:");
expect(source).toContain("columns-2");
expect(source).toContain("break-inside-avoid");
expect(source).toContain("w-full text-left");
expect(source).toContain("whitespace-normal");
expect(source).toMatch(
/className="[^"]*\bw-full\b[^"]*\btext-left\b[^"]*\bwhitespace-normal\b[^"]*"/,
);
});
test("desktop composer uses a two-column row when the page gives it full-width space", () => {