Url

An annotation that contains a url string. When clicking on the text to which this annotation is attached, the app will try to open the url using androidx.compose.ui.platform.UriHandler. However, if linkInteractionListener is provided, its LinkInteractionListener.onClick method will be called instead and so you need to then handle opening url manually (for example by calling androidx.compose.ui.platform.UriHandler).

Constructors

Link copied to clipboard
constructor(url: String, linkInteractionListener: LinkInteractionListener? = null)

Creates a URL-based link annotation.

Properties

Link copied to clipboard

Interaction listener triggered when user interacts with this link.

Link copied to clipboard
val url: String

The URL to navigate to when the link is clicked.

Functions

Link copied to clipboard
fun copy(url: String = this.url, linkInteractionListener: LinkInteractionListener? = this.linkInteractionListener): OudsLinkAnnotation.Url

Creates a copy of this URL link with optionally modified properties.

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
open override fun toString(): String