@mocanvas/mocanvas · function
declare function getNoteGrowY(shape: NoteShape, editor?: {
getCurrentTheme?(): TLTheme;
} | null): numbergrowY a note needs so its (centered) text fits; the note keeps its square
width.
Returned in *unscaled* units — the label is measured at the scale the note
is actually drawn at, and the overflow is then divided back out, because
growY is stored as a number of unit-note pixels and multiplied by scale
when the height is computed. Returning the scaled overflow instead is what
made a note from a .tldr file, where the prop has always meant the
unscaled thing, come out too short for its own text.
mocanvas is built by Symbio. Free for non-commercial, non-profit and development use; commercial use needs an agreement. Not affiliated with or endorsed by tldraw.