fix z-index action to account for deleted elems and add tests (#1077)

This commit is contained in:
David Luzar 2020-03-26 08:28:50 +01:00 committed by GitHub
parent fb82715ef7
commit 6fd2a3b2e5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 254 additions and 31 deletions

View file

@ -300,6 +300,10 @@ export class App extends React.Component<any, AppState> {
return this.setState(...args);
},
},
app: {
configurable: true,
value: this,
},
});
}
@ -2498,7 +2502,9 @@ declare global {
h: {
elements: readonly ExcalidrawElement[];
state: AppState;
setState: React.Component<any, AppState>["setState"];
history: SceneHistory;
app: InstanceType<typeof App>;
};
}
}