Open sebkur opened 1 year ago
Hi @sebkur, I saw your post on Slack but figured I would answer in both places, to help anyone else who also searches for this issue.
I believe the problem is actually related to this open issue on Compose for Desktop: https://github.com/JetBrains/compose-jb/issues/1450
As a side note: Earlier this year I made some improvements to how we handle clickable text in compose-richtext
which solved a common problem developers have with the standard ClickableText
component - that is, ClickableText consumes all tap interactions rather than the ones it should be responsible for, which causes a follow-on effect where you lose interaction effects like the ripple on Android, and you lose the ability to allow parent Composables to handle tap events.
☝️ what all this means is that if JetBrains are able to resolve the SelectionContainer
issue then having clickable and selectable text in compose-richtext
should just work with no changes required by us.
Hope that helps, reach out if you need more info.
Thanks @morrisseyai
Here's an example. With the
SelectionContainer
selecting the text is possible, but clicking the link does nothing. Without it, clicking the link works, but selecting text doesn't work of course:Is there some other way to make text selectable or is this is a bug?