Content Display

Service Hero

Hero banner card for builder canvas and app player, designed for key conversion actions like booking, offers, and catalogue entry points. Renders as a styled colored block with decorative accents, a faint right-side icon, optional badge/title/subtitle/highlight strip, and CTA.

Quick startAdd in 3 steps

Component picker → Content DisplayService Hero, then set copy, colors, and CTA action.

Layout controlsalignment · verticalAlignment

Horizontal and vertical content placement inside fixed-height card.

Actions5 action types

none, alert, navigate-screen, open-url, go-back; action runs only in preview.

What it does

Four things worth knowing

Full-width fixed-height hero layout

Content stacks vertically inside a fixed height block. Use alignment for horizontal placement and verticalAlignment for top/center/bottom positioning.

Decorative accents and faint icon texture

Two accent circles use accentColor, and the right-side background icon uses placeholderIconName with low opacity for visual depth.

Optional badge, overlay, and CTA

Badge appears only when showBadge is true; overlay applies when showOverlay is true with fixed opacity 0.35; CTA appears when showButton is true.

Preview-only action handling

The CTA calls handlePress, but actions are active only when isPreview is true (AppPlayer). In builder canvas, button stays visible but non-interactive.

Builder setup

Find it, drop it, and wire action

Where to find itAdd it to any screen

  1. Component picker → Content DisplayService Hero.
  2. Drop it on home or landing screens where one CTA should dominate.
  3. Set title/subtitle/highlight, then configure action type and payload.

Before you publishThree things to check

  1. Confirm onPressAction and actionData match (alert message, target screen ID, or URL).
  2. Verify contrast for title/subtitle/button on chosen background and overlay.
  3. Validate alignment, vertical placement, and card height on the target screen.
Category: Content DisplayComponent: BuilderPromoCardRegistry key: promo-cardAction runtime: preview-only
Props

Content, layout, and actions

PropTypeDefaultDescription
titlestringconfigured in registryMain hero heading text.
subtitle, highlightTextstringOptional supporting lines under the title.
alignment, verticalAlignmentselectleft, centerHorizontal and vertical content placement inside the card.
showBadge, showButton, showOverlaybooleancomponent defaultsToggles status badge, CTA button, and color overlay.
placeholderBackgroundColor, accentColor, overlayColorcolorcomponent defaultsMain surface color, decorative accents, and overlay tint.
titleColor, subtitleColor, highlightColorcolorcomponent defaultsText colors for title and supporting lines.
badgeText, badgeColor, badgeTextColorstring / colorcomponent defaultsBadge content and styling; badge dot is always green and non-configurable.
buttonText, buttonColor, buttonTextColorstring / colorcomponent defaultsCTA label and pill button style.
onPressAction, actionDataselect / stringnone, Action type and payload used by preview/runtime CTA handler.
fontFamily, titleFontSize, subtitleFontSizestring / numbercomponent defaultsTypography settings for heading and supporting text.
height, borderRadius, paddingnumbercomponent defaultsCard dimensions and inner spacing.
placeholderIconNamestringIonicons nameFaint right-side decorative icon texture; invalid names render nothing safely.
Toggles & colours

Make it yours

Tune visibility, color hierarchy, spacing, and action behavior from the builder editor while keeping CTA intent clear.

PropTypical valueWhat it controls
showBadgetrue / falseStatus badge visibility above title.
showButtontrue / falseCTA button visibility.
showOverlaytrue / falseApplies overlay tint at fixed 0.35 opacity.
placeholderBackgroundColor#6C47FFMain card background color.
accentColor#8B6AFFDecorative corner shapes color.
overlayColorbrand tintOverlay color for darkening/tinting.
buttonColor, buttonTextColorbrand contrastCTA button readability and hierarchy.
Tips

Common mistakes to avoid

Action runs only in preview

The CTA is visible on builder canvas but does not fire action there. Test interactions in AppPlayer where isPreview is true.

Match action type and payload

Always provide compatible actionData for selected onPressAction (message, screen ID, or URL) to avoid no-op interactions.

Overlay opacity is fixed

Opacity is hardcoded to 0.35; changing it requires component code updates in BuilderPromoCard.tsx.

Sync changes across component and registry

If you add props or action types, update BuilderPromoCard.tsx, builderComponentRegistry.ts, and componentDimensions.ts when sizing behavior changes.