mirror of
https://github.com/getpaseo/paseo.git
synced 2026-10-24 18:22:38 +00:00
* feat(app): streamline sidebar usage and stacked sheets * fix(app): restore compact sidebar navigation clicks The close button container emitted box-none through Unistyles as invalid CSS and intercepted New workspace clicks. Let React Native apply click-through behavior at the view boundary. Keep the import journey on its existing New workspace screen and assert only the visible transcript. * fix(app): cap menu sheets at eighty percent height Keep long sidebar usage reports recognizably sheet-sized while allowing the content to scroll. Short menu sheets retain dynamic sizing.
16 lines
627 B
TypeScript
16 lines
627 B
TypeScript
import { describe, expect, it } from "vitest";
|
|
import { formatAmount } from "./format";
|
|
|
|
describe("formatAmount", () => {
|
|
it("groups thousands in the app's language", () => {
|
|
expect(formatAmount(12345, "credits", "en")).toBe("12,345");
|
|
expect(formatAmount(12345, "requests", "en")).toBe("12,345");
|
|
expect(formatAmount(12345, "credits", "fr").replace(/\s/g, " ")).toBe("12 345");
|
|
});
|
|
|
|
it("formats dollars as the language writes currency", () => {
|
|
expect(formatAmount(1234.5, "usd", "en")).toBe("$1,234.50");
|
|
expect(formatAmount(1234.5, "usd", "fr").replace(/\s/g, " ")).toBe("1 234,50 $US");
|
|
});
|
|
});
|