Skip to content

fix(isometric): edit a label in place over its label pill - #16

Open
bcostaaa01 wants to merge 1 commit into
mainfrom
fix/isometric-label-text-edit
Open

bcostaaa01 wants to merge 1 commit into
mainfrom
fix/isometric-label-text-edit

Conversation

@bcostaaa01

Copy link
Copy Markdown
Collaborator

Summary

Double-clicking an isometric object opened the text editor on the label's glyph box, then applied a 60px minimum width, generic padding and an unscaled font size. The result was a second white input box offset over the label pill.

For isometric owners the editor now:

  • sits exactly on the label background pill (or the padded text box when there's no labelBackground)
  • uses the pill's fill and 4px corners, centered single-line text
  • scales the font by the canvas zoom so the text doesn't jump in size
  • skips auto-grow, since a floating label stays one line

Shapes and links keep the existing editor behavior.

Test plan

  • npm run typecheck, npm run lint (on src)
  • Double-click an isometric object in the VS Code preview: editor overlays the label pill, Enter commits, Escape cancels

Double-clicking an isometric object opened the text editor on the label's
glyph box with a 60px minimum, generic padding and an unscaled font, so a
second white box appeared offset over the label. Isometric labels now edit
in an overlay that matches the label background pill exactly: same size,
corners and fill, centered single-line text at the canvas zoom.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant