refactor(ai-toolbar): stack attachment previews by row
This commit is contained in:
@@ -466,9 +466,7 @@ export const AIToolbar = ({
|
|||||||
animate={{ opacity: 1, y: 0 }}
|
animate={{ opacity: 1, y: 0 }}
|
||||||
exit={{ opacity: 0, y: 4 }}
|
exit={{ opacity: 0, y: 4 }}
|
||||||
transition={{ duration: 0.15 }}
|
transition={{ duration: 0.15 }}
|
||||||
className={
|
className="mt-3 grid gap-2"
|
||||||
isMobile ? "mt-3 grid gap-2" : "mt-3 grid gap-2 grid-cols-2"
|
|
||||||
}
|
|
||||||
>
|
>
|
||||||
{imagePreviews.map((preview, index) => (
|
{imagePreviews.map((preview, index) => (
|
||||||
<motion.div
|
<motion.div
|
||||||
|
|||||||
@@ -184,6 +184,13 @@ describe("AI capture redesign", () => {
|
|||||||
|
|
||||||
expect(source).toContain("rounded-[10px] bg-card p-3 shadow-sm");
|
expect(source).toContain("rounded-[10px] bg-card p-3 shadow-sm");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
test("attachment previews stack one per row instead of using a two-column desktop grid", () => {
|
||||||
|
const source = readToolbarSource();
|
||||||
|
|
||||||
|
expect(source).not.toContain('"mt-3 grid gap-2 grid-cols-2"');
|
||||||
|
expect(source).toContain('"mt-3 grid gap-2"');
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
// ─── Cycle 6: Composer footer bar ────────────────────────────────────────────
|
// ─── Cycle 6: Composer footer bar ────────────────────────────────────────────
|
||||||
|
|||||||
Reference in New Issue
Block a user