@@ -34,7 +34,18 @@ export const getDefaultFeatureStyler = (size = 24, colorizer = () => "#2664D8")
3434 } ;
3535 } ;
3636} ;
37-
37+ export const defaultClusteringOptions = {
38+ spiderfyOnMaxZoom : false ,
39+ showCoverageOnHover : false ,
40+ zoomToBoundsOnClick : false ,
41+ maxClusterRadius : 40 ,
42+ disableClusteringAtZoom : 19 ,
43+ animate : false ,
44+ cismapZoomTillSpiderfy : 12 ,
45+ selectionSpiderfyMinZoom : 12 ,
46+ colorizer : ( props ) => props . color ,
47+ clusterIconSize : 30 ,
48+ } ;
3849// Since this component is simple and static, there's no parent container for it.
3950const FeatureCollection = ( props ) => {
4051 const {
@@ -91,16 +102,7 @@ const FeatureCollection = (props) => {
91102 }
92103
93104 const _clusterOptions = {
94- spiderfyOnMaxZoom : false ,
95- showCoverageOnHover : false ,
96- zoomToBoundsOnClick : false ,
97- maxClusterRadius : 40 ,
98- disableClusteringAtZoom : 19 ,
99- animate : false ,
100- cismapZoomTillSpiderfy : 12 ,
101- selectionSpiderfyMinZoom : 12 ,
102- colorizer : ( props ) => props . color ,
103- clusterIconSize : 30 ,
105+ ...defaultClusteringOptions ,
104106 ...clusteringOptionsFromContext ,
105107 ...clusteringOptions ,
106108 } ;
0 commit comments