release: bump version to 0.51.0
This commit is contained in:
@@ -30,6 +30,7 @@ function createController(options = {}) {
|
||||
calls.push("connector:render");
|
||||
return options.connectorReady ?? true;
|
||||
},
|
||||
isAnimating: () => options.connectorAnimating === true,
|
||||
hide: () => calls.push("connector:hide"),
|
||||
};
|
||||
const controller = new PresentationController({
|
||||
@@ -126,6 +127,17 @@ describe("PresentationController", () => {
|
||||
expect(calls).toEqual(["connector:render"]);
|
||||
});
|
||||
|
||||
test("update does not interrupt an active connector draw animation", async () => {
|
||||
const { calls, controller } = createController({ connectorAnimating: true });
|
||||
|
||||
await controller.present(createRequest({ calls }));
|
||||
calls.length = 0;
|
||||
const updated = controller.update();
|
||||
|
||||
expect(updated).toBe(true);
|
||||
expect(calls).toEqual([]);
|
||||
});
|
||||
|
||||
test("rect source anchors are passed as center point plus sourceRect", async () => {
|
||||
const { controller, pathCalls } = createController();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user