OudsLink
An OUDS link which displays a text and an optional icon.
In the case it is used in an OudsColoredBox, its monochrome variant is automatically displayed. The tokens associated with this variant can be customized and are identified with the Mono
suffix (for instance colorContentEnabledMono
in OudsLinkTokens).
Parameters
Text displayed in the link.
Icon displayed in the link.
Callback invoked when the link is clicked.
Modifier applied to the link.
Size of the button.
Controls the enabled state of the link. When false
, the link will not be clickable.
Samples
import androidx.compose.runtime.Composable
import androidx.compose.ui.res.painterResource
import com.orange.ouds.core.component.link.OudsLink
fun main() {
//sampleStart
OudsLink(
text = "Link",
icon = OudsLink.Icon(painterResource(id = android.R.drawable.star_on)),
onClick = { /* Do something! */ },
)
//sampleEnd
}
An OUDS link which displays an arrow before (OudsLink.Arrow.Back) or after (OudsLink.Arrow.Next) a text.
In the case it is used in an OudsColoredBox, its monochrome variant is automatically displayed. The tokens associated with this variant can be customized and are identified with the Mono
suffix (for instance colorContentEnabledMono
in OudsLinkTokens).
Parameters
Text displayed in the link.
Arrow displayed in the link. When OudsLink.Arrow.Back, the arrow is displayed before the text. When OudsLink.Arrow.Next, the arrow is displayed after the text.
Callback invoked when the link is clicked.
Modifier applied to the link.
Size of the button.
Controls the enabled state of the link. When false
, the link will not be clickable.
Samples
import androidx.compose.runtime.Composable
import androidx.compose.ui.res.painterResource
import com.orange.ouds.core.component.link.OudsLink
fun main() {
//sampleStart
OudsLink(
text = "Link",
arrow = OudsLink.Arrow.Next,
onClick = { /* Do something! */ },
)
//sampleEnd
}