feat: Expose the API to calculate offsets and remove offsetTop and offsetLeft props (#3265)

* feat: Expose the API to calculate offsets and remove offsetTop and offsetLeft props

* update

* fix tests

* fix

* update readme and changelog

* fix

* better
This commit is contained in:
Aakansha Doshi 2021-03-20 13:00:49 +05:30 committed by GitHub
parent add1785ace
commit de99484a1f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 53 additions and 73 deletions

View file

@ -162,10 +162,6 @@ export type ExcalidrawAPIRefValue =
export interface ExcalidrawProps {
width?: number;
height?: number;
/** if not supplied, calculated by Excalidraw */
offsetLeft?: number;
/** if not supplied, calculated by Excalidraw */
offsetTop?: number;
onChange?: (
elements: readonly ExcalidrawElement[],
appState: AppState,