mikepenz/multiplatform-markdown-renderer

SelectionContainer prevents clicks on links

Melodeiro opened this issue · 4 comments

About this issue

Link is not clickable when SelectionContainer is used. For example:

SelectionContainer {
    Markdown(content = "[test](https://exampmle.com)")
}

It is possible to solve that by using onPointerEvent() with PointerEventPass.Initial. Probably checking if click has finished at the same position as started would do the trick. Could you take a look, please?

Details

version: 0.10.0

This appears to be a more general issue as it seems to be also reported here: https://issuetracker.google.com/issues/184950231

And has also been discussed here: https://slack-chats.kotlinlang.org/t/8320645/click-handling-inside-selectioncontainer-is-still-a-big-prob

Unfortunately I do not see a solution or workaround for these at this time

Unfortunately I do not see a solution or workaround for these at this time

If you know how to get a cursor position at the onPointerEvent(), then it is actually possible to make a workaround, i think. Or am i missing something? Haven't researched enough. I just checked that click events are working correctly