Skip to content
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: make text in tooltip selectable #4841

Merged
merged 1 commit into from
Feb 21, 2025
Merged

fix: make text in tooltip selectable #4841

merged 1 commit into from
Feb 21, 2025

Conversation

jarekdanielak
Copy link
Contributor

Closes #4834

Proposed Changes

Make text inside of a tooltip selectable.

Screenshot 2025-02-20 at 12 47 54

Checklist

To ensure you provided everything we need to look at your PR:

  • Brief textual description of the changes present
  • Visual demo attached
  • Steps to try out present, i.e. using the @bpmn-io/sr tool
  • Related issue linked via Closes {LINK_TO_ISSUE} or Related to {LINK_TO_ISSUE}

@barmac
Copy link
Collaborator

barmac commented Feb 20, 2025

The selection works, but it is impossible to do if you open the tooltip via click. This is probably related to how we hide the tooltip: https://github.com/bpmn-io/properties-panel/blob/main/src/components/entries/Tooltip.js#L93C23-L93C39

Screen.Recording.2025-02-20.at.13.39.45.mov

@barmac
Copy link
Collaborator

barmac commented Feb 20, 2025

CSS is good but it solves the issue only partially. The rest needs to be fixed upstream though.

@barmac
Copy link
Collaborator

barmac commented Feb 20, 2025

@jarekdanielak for the properties panel part, this may be useful: https://developer.mozilla.org/en-US/docs/Web/API/Selection/containsNode

@jarekdanielak
Copy link
Contributor Author

Let me fix the properties panel part and reopen this when it's ready.

@jarekdanielak jarekdanielak marked this pull request as draft February 20, 2025 13:04
@bpmn-io-tasks bpmn-io-tasks bot added in progress Currently worked on and removed needs review Review pending labels Feb 20, 2025
@barmac
Copy link
Collaborator

barmac commented Feb 20, 2025

We could also merge this, and open a separate issue of "Tooltip closes unexpectedly when trying to select" (closing #4834).

@jarekdanielak jarekdanielak marked this pull request as ready for review February 20, 2025 19:43
@bpmn-io-tasks bpmn-io-tasks bot added needs review Review pending and removed in progress Currently worked on labels Feb 20, 2025
@jarekdanielak
Copy link
Contributor Author

Let's merge this and look into bpmn-io/properties-panel#399 for more improvements on the tooltips.

@barmac barmac merged commit 773469e into main Feb 21, 2025
15 checks passed
@bpmn-io-tasks bpmn-io-tasks bot removed the needs review Review pending label Feb 21, 2025
@barmac barmac deleted the tooltip-select branch February 21, 2025 08:28
@github-actions github-actions bot added this to the M86 milestone Feb 21, 2025
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.

2 participants