feat(layout): improve flexLayout & fixed layout overlaps (#1314)

* feat(layout): improve flexLayout & fixed layout overlaps

* chore: fix vercel build
This commit is contained in:
Anurag Hazra authored and GitHub committed 2021-09-18 22:39:28 +05:30
1 parent 4dbb9e93b9
commit 97690e173d
6 files changed
+148 -111

No files matched your search

-21
View File
@@ -44,27 +44,6 @@ describe("Test utils.js", () => {
).toHaveTextContent(/Secondary Message/gim);
});
it("should test flexLayout", () => {
const layout = flexLayout({
items: ["<text>1</text>", "<text>2</text>"],
gap: 60,
}).join("");
expect(layout).toBe(
`<g transform=\"translate(0, 0)\"><text>1</text></g><g transform=\"translate(60, 0)\"><text>2</text></g>`,
);
const columns = flexLayout({
items: ["<text>1</text>", "<text>2</text>"],
gap: 60,
direction: "column",
}).join("");
expect(columns).toBe(
`<g transform=\"translate(0, 0)\"><text>1</text></g><g transform=\"translate(0, 60)\"><text>2</text></g>`,
);
});
it("getCardColors: should return expected values", () => {
let colors = getCardColors({
title_color: "f00",