FacetWP – custom snazzy map design

mgibbs189

{{gist file=”functions.php” lang=”php”}}
<?php

add_filter( ‘facetwp_map_init_args’, function( $settings ) {
$styles = ‘[{“featureType”:”water”,”elementType”:”geometry”,”stylers”:[{“color”:”#193341″}]},{“featureType”:”landscape”,”elementType”:”geometry”,”stylers”:[{“color”:”#2c5a71″}]},{“featureType”:”road”,”elementType”:”geometry”,”stylers”:[{“color”:”#29768a”},{“lightness”:-37}]},{“featureType”:”poi”,”elementType”:”geometry”,”stylers”:[{“color”:”#406d80″}]},{“featureType”:”transit”,”elementType”:”geometry”,”stylers”:[{“color”:”#406d80″}]},{“elementType”:”labels.text.stroke”,”stylers”:[{“visibility”:”on”},{“color”:”#3e606f”},{“weight”:2},{“gamma”:0.84}]},{“elementType”:”labels.text.fill”,”stylers”:[{“color”:”#ffffff”}]},{“featureType”:”administrative”,”elementType”:”geometry”,”stylers”:[{“weight”:0.6},{“color”:”#1a3541″}]},{“elementType”:”labels.icon”,”stylers”:[{“visibility”:”off”}]},{“featureType”:”poi.park”,”elementType”:”geometry”,”stylers”:[{“color”:”#2c5a71″}]}]’;
$settings[‘init’][‘styles’] = json_decode( $styles );
return $settings;
});

{{/gist}}