Constrain email table sizing around intrinsic image widths
This commit is contained in:
1 parent
b0fca36bca
commit
3da88510df
3 files changed
+4
-2
No files matched your search
@@ -17,6 +17,8 @@ test("meaningful image alt and explicit dimensions survive MJML round trip", asy
|
||||
const rendered = await renderEmail(documentFor(false), { mjml: true });
|
||||
if (!rendered.ok) throw new Error("Render failed");
|
||||
expect(rendered.value.parts.text.content).toContain("Accessible & descriptive");
|
||||
expect(rendered.value.parts.html.content.match(/table-layout:fixed/g)).toHaveLength(2);
|
||||
expect(rendered.value.parts.html.content).toContain("max-width:100%;width:600px");
|
||||
expect(rendered.value.exports!.mjml).toContain('width="320px" height="180px"');
|
||||
let id = 0;
|
||||
const imported = importMjml(rendered.value.exports!.mjml!, { id: () => `n${++id}` });
|
||||
|
||||
Reference in new issue
Block a user