-
-
Notifications
You must be signed in to change notification settings - Fork 6.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: cleanup redrawTextBoundingBox #6518
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Ignored Deployment
|
if (isArrowElement(container)) { | ||
const centerX = textElement.x + textElement.width / 2; | ||
const centerY = textElement.y + textElement.height / 2; | ||
const diffWidth = metrics.width - textElement.width; | ||
const diffHeight = metrics.height - textElement.height; | ||
boundTextUpdates.x = centerY - (textElement.height + diffHeight) / 2; | ||
boundTextUpdates.y = centerX - (textElement.width + diffWidth) / 2; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this isn't needed anymore?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no its taken care in computeBoundTextPosition
hence removed from here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for more context it was fixed in computeBoundTextPosition
in this PR - https://github.com/excalidraw/excalidraw/pull/6445/files
* chore: cleanup redrawTextBoundingBox * fix
No description provided.