Skip to content

Conversation

@NaoCoding
Copy link
Member

Fix #290

This pull request enhances the user experience in the shape and arrow picker toolbars by improving how the currently selected pointer is visually indicated and ensuring pointer type updates are handled consistently. The changes focus on adding selection state to toolbar buttons and updating pointer logic when toggling toolbars.

UI Improvements:

  • Added a selected prop to both shape and arrow picker buttons, using PlaitBoard.isPointer to visually indicate which pointer is currently active. [1] [2]

Pointer Logic Updates:

  • Updated the pointer type logic in the creation toolbar: when toggling the shape or arrow picker, the pointer type is set to either the current pointer or the button's pointer, depending on whether the current pointer matches the type being toggled. [1] [2]

Codebase Consistency:

  • Updated imports to include PlaitBoard from @plait/core in both arrow-picker.tsx and shape-picker.tsx for the new selection logic. [1] [2]

@cloudflare-workers-and-pages
Copy link

Deploying drawnix with  Cloudflare Pages  Cloudflare Pages

Latest commit: 48eb049
Status: ✅  Deploy successful!
Preview URL: https://16ef85c8.drawnix.pages.dev
Branch Preview URL: https://fix-290.drawnix.pages.dev

View logs

@pubuzhixing8
Copy link
Contributor

pubuzhixing8 commented Sep 10, 2025

LGTM, Thanks for you contributing @NaoCoding .

@pubuzhixing8 pubuzhixing8 merged commit d9b6371 into develop Sep 10, 2025
2 checks passed
@pubuzhixing8 pubuzhixing8 deleted the fix-290 branch September 10, 2025 02:02
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.

Should close freehand panel when switch to other pointer or click other tool icon

3 participants