This is the documentation of version 0.62.3. Go to the latest version, 1.0.0-rc.5.
TomTom Maps for JavaScript
    Preparing search index...

    Type Alias PlaceClusterBadgeConfig

    Appearance of the cluster count badge under the pin-clustered marker type.

    Each field applies to single-category and mixed-category clusters alike. The matching PlaceLayersConfig entry (clusterBadge, clusterCount, clusterMixedBadge, clusterMixedCount) overrides it for the paint and layout properties it names.

    type PlaceClusterBadgeConfig = {
        color?: DataDrivenPropertyValueSpecification<string>;
        offset?: [number, number];
        radius?: { mixed?: number; single?: number };
        strokeColor?: DataDrivenPropertyValueSpecification<string>;
        strokeWidth?: DataDrivenPropertyValueSpecification<number>;
        textColor?: DataDrivenPropertyValueSpecification<string>;
        textSize?: DataDrivenPropertyValueSpecification<number>;
    }
    Index
    color?: DataDrivenPropertyValueSpecification<string>

    Badge fill color.

    '#000000'
    
    offset?: [number, number]

    Offset of the single-category badge from the cluster icon, in viewport pixels.

    Applied to the badge circle and the count text together so they can't drift apart. Mixed-category clusters are always centred and ignore this.

    [12, -14]
    
    radius?: { mixed?: number; single?: number }

    Badge radius in pixels, per cluster kind.

    single is the small badge tucked into the corner of a single-category cluster's icon; mixed is the centred badge that replaces the icon entirely for mixed-category clusters, so it defaults larger.

    { single: 11, mixed: 15 }
    
    strokeColor?: DataDrivenPropertyValueSpecification<string>

    Badge outline color.

    '#FFFFFF'
    
    strokeWidth?: DataDrivenPropertyValueSpecification<number>

    Badge outline width in pixels.

    1.5
    
    textColor?: DataDrivenPropertyValueSpecification<string>

    Count text color.

    '#FFFFFF'
    
    textSize?: DataDrivenPropertyValueSpecification<number>

    Count text size in pixels.

    12