OudsOutlinedCard

fun OudsOutlinedCard(modifier: Modifier = Modifier, enabled: Boolean = true, skeleton: OudsSkeleton? = LocalSkeleton.current, content: @Composable OudsCardScope.() -> Unit = { })

This is a convenience function for OudsCard with OudsCardStyle.Outlined. Outlined cards define their boundaries with a border.

Parameters

modifier

The Modifier to be applied to this card.

enabled

Controls the enabled state of the card. When false, the OUDS components inside will be in disabled state.

skeleton

A placeholder state of the component used when the content is not yet available (while loading). The component shows the correct visual structure but with placeholder elements (grey or shimmering blocks) instead of actual content. Can be set directly or inherited from OudsSkeletonProvider. See OudsSkeleton class documentation for all approaches.

content

The content of the card.

See also

Samples

OudsOutlinedCard {
    Column(
        modifier = Modifier.padding(OudsTheme.spaces.fixed.medium),
        verticalArrangement = Arrangement.spacedBy(OudsTheme.spaces.fixed.medium)
    ) {
        Row(
            verticalAlignment = Alignment.CenterVertically,
            horizontalArrangement = Arrangement.spacedBy(OudsTheme.spaces.fixed.small)
        ) {
            Icon(
                imageVector = Icons.Outlined.Phone,
                contentDescription = "Contact icon",
                tint = OudsTheme.colorScheme.content.default
            )
            OudsHeadingText(text = "Customer Service")
        }
        OudsBodyText(text = "Our team is available to help you with any questions or concerns you may have.")
        Row(
            modifier = Modifier.padding(top = OudsTheme.spaces.fixed.small),
            horizontalArrangement = Arrangement.spacedBy(OudsTheme.spaces.fixed.small)
        ) {
            OudsTag(label = "24/7 available", status = OudsTagStatus.Positive(), size = OudsTagSize.Small)
            OudsTag(label = "Multilingual", status = OudsTagStatus.Info(), size = OudsTagSize.Small)
        }
        OudsLabelText(
            text = "Average response time: 5 minutes",
            size = OudsLabelTextSize.Small,
            color = OudsTheme.colorScheme.content.muted
        )
    }
}

fun OudsOutlinedCard(onClick: () -> Unit, modifier: Modifier = Modifier, enabled: Boolean = true, skeleton: OudsSkeleton? = LocalSkeleton.current, interactionSource: MutableInteractionSource? = null, content: @Composable OudsCardScope.() -> Unit = { })

This is a convenience function for OudsCard with OudsCardStyle.Outlined. Outlined cards define their boundaries with a border.

Parameters

onClick

The action to perform when this card is clicked.

modifier

The Modifier to be applied to this card.

enabled

Controls the enabled state of the card. When false, the OUDS components inside will be in disabled state.

skeleton

A placeholder state of the component used when the content is not yet available (while loading). The component shows the correct visual structure but with placeholder elements (grey or shimmering blocks) instead of actual content. Can be set directly or inherited from OudsSkeletonProvider. See OudsSkeleton class documentation for all approaches.

interactionSource

An optional hoisted MutableInteractionSource for observing and emitting Interactions for this card. Note that if null is provided, interactions will still happen internally.

content

The content of the card.

See also

Samples

OudsCard(
    onClick = { /* View offer */ },
    style = OudsCardStyle.Outlined
) {
    Column(
        modifier = Modifier.padding(OudsTheme.spaces.fixed.medium),
        verticalArrangement = Arrangement.spacedBy(OudsTheme.spaces.fixed.medium)
    ) {
        OudsHeadingText(text = "Special Offer")
        OudsBodyText(text = "Get 20% off on your first purchase. Limited time offer for new customers only.")
        Row(
            horizontalArrangement = Arrangement.spacedBy(OudsTheme.spaces.fixed.small)
        ) {
            OudsLabelText(
                text = "Code: WELCOME20",
                size = OudsLabelTextSize.Medium,
                weight = OudsTextWeight.Strong
            )
        }
        OudsInlineAlert(
            label = "Offer ends in 3 days",
            status = OudsInlineAlertStatus.Warning
        )
        OudsButton(
            modifier = Modifier.fillMaxWidth(),
            label = "Shop Now",
            appearance = OudsButtonAppearance.Strong,
            onClick = {}
        )
    }
}