mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-09-16 22:10:48 +02:00
14 lines
443 B
TypeScript
14 lines
443 B
TypeScript
import { isTransparent } from "../utils";
|
|
|
|
describe("Test isTransparent", () => {
|
|
it("should return true when color is rgb transparent", () => {
|
|
expect(isTransparent("#ff00")).toEqual(true);
|
|
expect(isTransparent("#fff00000")).toEqual(true);
|
|
expect(isTransparent("transparent")).toEqual(true);
|
|
});
|
|
|
|
it("should return false when color is not transparent", () => {
|
|
expect(isTransparent("#ced4da")).toEqual(false);
|
|
});
|
|
});
|