jeziellago / compose-markdown

Markdown Text for Android Jetpack Compose 📋.
MIT License
567 stars 47 forks source link

[ADDED] Added the ability to select text #55

Closed therxmv closed 1 year ago

therxmv commented 1 year ago

Added the ability to select text

czf0613 commented 1 year ago

I find a bug with isTextSelectable, here is my case:

MarkdownText(
                        markdown = message.content,
                        color = MaterialTheme.colorScheme.onSurfaceVariant,
                        modifier = Modifier
                            .clip(MaterialTheme.shapes.extraSmall)
                            .background(color = MaterialTheme.colorScheme.surfaceVariant)
                            .padding(8.dp),
                        linkifyMask = 0,
                        disableLinkMovementMethod = true,
                        isTextSelectable = true
                    )

Text Selectable will not work when the disableLinkMovementMethod is set to true, is there any solution?