wpsl_cluster_marker_colors

  1. Description
  2. Parameters
  3. Usage
  4. Changelog
  5. Source File

Description

This filter allows customization of the default cluster marker colors.

  • ‘lowDensityColor’ => ‘#0066ff’ (blue)
  • ‘highDensityColor’ => ‘#ff0000’ (red)
  • ‘labelColor’ => ‘#fff’ (white)

Parameters

$colors - (array) The default cluster colors.

Usage

add_filter( 'wpsl_cluster_marker_colors', function( $colors ) {
  return array(
    'lowDensityColor'  => $colors['lowDensityColor'], // you can use the defaults
    'highDensityColor' => '#ffff00',
    'labelColor'       => '#000000'
  );
});

Changelog

Since 2.3.2

Source File

This filter is located in /frontend/class-frontend.php

Placement

The code needs to be placed in the functions.php file inside your active theme folder.