-
@Stable() public final class EloAdStyleOptional styling overrides for the Compose ad views.
Only non-null fields are applied — every other surface uses Material 3 theme defaults. To force light or dark, wrap the ad view in your own
MaterialTheme. Mirrors iOSEloAdStyle.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classEloAdStyle.Companion
-
Field Summary
Fields Modifier and Type Field Description private final ColorcardBackgroundprivate final ColortitleColorprivate final ColordescriptionColorprivate final ColorbadgeColorprivate final ColorcallToActionBackgroundprivate final ColorcallToActionForegroundprivate final ColorborderColorprivate final DpborderWidthprivate final DpcornerRadiusprivate final EloAdDescriptionOverflowdescriptionOverflowprivate final FontFamilyfontFamilyprivate final EloAdChromechrome
-
Constructor Summary
Constructors Constructor Description EloAdStyle(Color cardBackground, Color titleColor, Color descriptionColor, Color badgeColor, Color callToActionBackground, Color callToActionForeground, Color borderColor, Dp borderWidth, Dp cornerRadius, EloAdDescriptionOverflow descriptionOverflow, FontFamily fontFamily, EloAdChrome chrome)
-
Method Summary
Modifier and Type Method Description final ColorgetCardBackground()final ColorgetTitleColor()final ColorgetDescriptionColor()final ColorgetBadgeColor()final ColorgetCallToActionBackground()CTA pill fill, used by the Elo-rendered call-to-action button on creatives that supply a label ( EloAd.ctaText) and forwarded to renderer-backed creatives that draw their own CTA.final ColorgetCallToActionForeground()CTA pill text color; see callToActionBackground. final ColorgetBorderColor()final DpgetBorderWidth()final DpgetCornerRadius()final EloAdDescriptionOverflowgetDescriptionOverflow()How the strip's one-line creative description handles copy wider than the surface; the card wraps its description to three lines instead. final FontFamilygetFontFamily()Typeface for the headline, description, CTA label, and disclosure badge. final EloAdChromegetChrome()Surface decoration. -
-
Constructor Detail
-
EloAdStyle
EloAdStyle(Color cardBackground, Color titleColor, Color descriptionColor, Color badgeColor, Color callToActionBackground, Color callToActionForeground, Color borderColor, Dp borderWidth, Dp cornerRadius, EloAdDescriptionOverflow descriptionOverflow, FontFamily fontFamily, EloAdChrome chrome)
-
-
Method Detail
-
getCardBackground
final Color getCardBackground()
-
getTitleColor
final Color getTitleColor()
-
getDescriptionColor
final Color getDescriptionColor()
-
getBadgeColor
final Color getBadgeColor()
-
getCallToActionBackground
final Color getCallToActionBackground()
CTA pill fill, used by the Elo-rendered call-to-action button on creatives that supply a label (
EloAd.ctaText) and forwarded to renderer-backed creatives that draw their own CTA. Default to the theme's primary / onPrimary. Mirror iOSEloAdStyle.callToActionBackground/-Foreground.
-
getCallToActionForeground
final Color getCallToActionForeground()
CTA pill text color; see callToActionBackground.
nullwith a background set picks black or white, whichever contrasts more.
-
getBorderColor
final Color getBorderColor()
-
getBorderWidth
final Dp getBorderWidth()
-
getCornerRadius
final Dp getCornerRadius()
-
getDescriptionOverflow
final EloAdDescriptionOverflow getDescriptionOverflow()
How the strip's one-line creative description handles copy wider than the surface; the card wraps its description to three lines instead.
nulluses EloAdDescriptionOverflow.Marquee. Mirrors iOSEloAdStyle.descriptionOverflow.
-
getFontFamily
final FontFamily getFontFamily()
Typeface for the headline, description, CTA label, and disclosure badge. The SDK keeps its own sizes and weights.
nullkeeps the theme's family.
-
getChrome
final EloAdChrome getChrome()
Surface decoration.
nulluses EloAdChrome.Standard.
-
-
-
-