mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
Fixes text jumping on creation (#266)
* Fixes text jumping on creation * Do not remove node on ESC * Fixed typo
This commit is contained in:
parent
2122a9cf9f
commit
37934c0f8b
5 changed files with 52 additions and 23 deletions
|
@ -131,11 +131,14 @@ export function renderElement(
|
|||
context.fillText(
|
||||
element.text,
|
||||
element.x + scrollX,
|
||||
element.y + element.actualBoundingBoxAscent + scrollY
|
||||
element.y +
|
||||
scrollY +
|
||||
(element.baseline || element.actualBoundingBoxAscent || 0)
|
||||
);
|
||||
context.fillStyle = fillStyle;
|
||||
context.font = font;
|
||||
context.globalAlpha = 1;
|
||||
console.log(element);
|
||||
} else {
|
||||
throw new Error("Unimplemented type " + element.type);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue