rename getApproxMinLineWidth -> getApproxMinContainerWidth and getApproxMinLineHeight -> getApproxMinContainerHeight

This commit is contained in:
Aakansha Doshi 2023-03-22 14:55:51 +05:30
parent b799490ece
commit ee8fff8e8b
3 changed files with 10 additions and 11 deletions

View file

@ -83,7 +83,7 @@ export const measureText = (
return { width, height };
};
export const getApproxMinLineWidth = (
export const getApproxMinContainerWidth = (
font: FontString,
lineHeight: ExcalidrawTextElement["lineHeight"],
) => {
@ -97,8 +97,7 @@ export const getApproxMinLineWidth = (
return maxCharWidth + BOUND_TEXT_PADDING * 2;
};
// FIXME rename to getApproxMinContainerHeight
export const getApproxMinLineHeight = (
export const getApproxMinContainerHeight = (
fontSize: ExcalidrawTextElement["fontSize"],
lineHeight: ExcalidrawTextElement["lineHeight"],
) => {