Current map range (max/min lat/long)

Is there a way to read the current range of the displayed map in the @code block,so that if a user has zoomed in, or the map is a shape file for only one country, eg for the USA, I'm not trying to draw markers outside of the currently displayed map range in my code?

16 Replies 1 reply marked as answer

SB Swetha Babu Syncfusion Team July 1, 2020 06:12 PM UTC

Hi Ralph, 

Thank you for your update. 

We cannot read the range of the displayed map in the @code block. However, we can render the maps based on the center position of a country or continent and align it by ZoomFactor property. We can zoom in to the particular shape using the “Latitude” and “Longitude” property in the “MapsCenterPosition” class. We can draw markers using the latitude and longitude value in the maps within this range with the MapsMarker class. We have created the simple blazor application to demonstrate the same and the same can be downloaded from the below sample link. 


Please find the below screenshot for the above sample output 

 

In the above sample, we have rendered the world map. We have zoomed in to the USA country  based on the latitude and longitude property value in center position of the maps using the “ZoomFacter” property in “MapsZoomSettings”.  

Please let us know that the above sample meets your requirement. If not, please provide us detailed requirement. It will be helpful for us to analyze further and assist you better. 

Regards, 
Swetha Babu


RH Ralph Hope July 2, 2020 08:36 AM UTC

That's helpful, thank you.  Is there a way to read the map center and zoom factor to approximate the latitude and longitude range?

You're currently working on an update due to be in the 2020 Volume 3 release which will allow the creation of any number of charts on a map.  

This is a related point - it will be useful to know the extent of a map so that if a user wants to see 20 charts, as they zoom in the number of charts can be maintained -- my use case is that I always show the x number (eg 20)  most important pie charts out of a possible set of 100s, so when zoomed out you'd see the 20 most important for the whole world, but if you zoomed in on a smaller area you'd see the 20 most important in that map extent.  

Is there any chance of this making it into a future release?  There is already the ability to create markers in the code, and it would be useful general functionality to know how many the user can actually see.


SB Swetha Babu Syncfusion Team July 3, 2020 03:21 PM UTC

Hi Ralph, 

Thank you for your update. 

We have analyzed your query and came to know that you are trying to expand the cluster of pie charts while zooming the maps component.  We support marker cluster feature in which the markers are grouped as clusters. When zooming the maps, the cluster gets expanded and the markers are moved to the proper locations. Please find the online sample link for the marker clustering for your reference. 


Please let us know that the above scenario is your requirement.  

However, we tried rendering the Pie chart in the marker template with this feature. But the pie charts are not hidden when marker cluster feature is enabled. We are checking this issue and we will update you with further details on July 7th, 2020. 

Query: Is there a way to read the map center and zoom factor to approximate the latitude and longitude range? 

We do not have support to read the map center position and the zoom factor for the provided latitude and longitude range. Please provide us your complete requirement. It will be helpful for us to analyze further and assist you better. 

Regards, 
Swetha Babu


RH Ralph Hope July 6, 2020 08:57 AM UTC

Many thanks for the update.  Once the clustering is working for charts, I wonder if it's possible to show an aggregated data piechart for the cluster rather than a marker just showing now many markers are hidden in the cluster?


SB Swetha Babu Syncfusion Team July 7, 2020 05:33 PM UTC

Hi Ralph, 

Thank you for your update. 

Please find the details for the queries from the below table. 

Query 
Details 
pie charts are not hidden when marker cluster feature is enabled 
We have checked the reported issue. We have considered this as a bug and logged a defect report for the same. We will include this fix along with the panning issue with pie chart in our upcoming weekly patch release which is expected to be available at the mid of July, 2020. 
it's possible to show an aggregated data pie chart for the cluster rather than a marker just showing now many markers are hidden in the cluster 
We do not have template support for the marker cluster in the maps. So we will not be able to add a pie chart in the marker cluster for providing the aggregated data. We will analyze the feasibility for this feature and update you with further details on 9th July, 2020. 

Please let us know if you need further assistance. 

Regards, 
Swetha Babu


SB Swetha Babu Syncfusion Team July 14, 2020 02:51 AM UTC

Hi Ralph, 

Thank you for your patience. 

We have analyzed feasibility for the template support for marker cluster. We have considered this a feature implementation and logged as a feature request for the same. We will include this implementation in our upcoming Volume 2 SP 1 release which is expected to rolled out in the month of August, 2020. 

Please let us know if you need further assistance. 

Regards, 
Swetha Babu


RH Ralph Hope July 14, 2020 07:28 AM UTC

Fantastic, thanks, it would be an amazingly useful feature!


SB Swetha Babu Syncfusion Team July 14, 2020 12:47 PM UTC

Hi Ralph, 

Most Welcome! We will let you know once the release is rolled out. 

Regards, 
Swetha Babu


SA Sabari Anand Senthamarai Kannan Syncfusion Team August 30, 2020 06:52 PM UTC

Hi Ralph, 

Sorry for the inconvenience caused. 

We have not included the template support for marker cluster in our weekly NuGet releases. However, we will implement this with high priority and include this in our 2020 Volume 3 release which is expected to be available by the end of September, 2020. 

Regards, 
Sabari Anand


SB Swetha Babu Syncfusion Team October 6, 2020 04:01 PM UTC

Hi Ralph,

Sorry for the inconvenience caused.

We have not included the reported issue of marker cluster template support in our Volume 3 Main Release. However, we will include the fix for the reported in our next weekly NuGet release which is expected to be available on 20th October, 2020.

Regards,
Swetha Babu


SB Swetha Babu Syncfusion Team October 20, 2020 05:28 PM UTC

Hi Ralph,

Thank you for your patience.

We have included the fix for the reported issue of "pie chart gets hidden while panning" in our weekly NuGet patch release(v18.3.42). You can download the package from the below link.

https://www.nuget.org/packages/Syncfusion.Blazor/
 
  
We have created the simple Blazor application to demonstrate the same and it can be downloaded from the below link. 
  
  
We are unable to include your other requirements “marker cluster template” and  “declarative syntax support” in this package. We are still working in them with high priority. We will include the fixes for these implementations in our next weekly NuGet release which is expected to be available on October 27, 2020. 

Please let us know if you need any further assistance.

Regards,
Swetha Babu
 



IR Indumathi Ravi Syncfusion Team October 27, 2020 09:31 PM UTC

Hi Ralph, 
  
Sorry for the inconvenience caused. 
  
We have implemented the marker cluster template support in the script side for the Blazor Maps component. But we are facing issues when rendering marker cluster with the Blazor specific interop methods in the application. So the marker templates are not clustering properly. We are working in this with high priority. We will implement this support and declarative syntax support for marker template and provide it as custom package on or before November 3, 2020. 
  
Regards, 
Indumathi 



IR Indumathi Ravi Syncfusion Team November 3, 2020 11:17 PM UTC

Hi Ralph,

Sorry for the inconvenience caused.

We have implemented the marker cluster template support in the Blazor Maps component. We can render the marker cluster template in the map when data source is provided with multiple location values. Please find the screen capture video of the working of the cluster template from the below link.


In the above video, we have provided markers as images using the template support.

Please find the NuGet package for the implementation from the below link.


We are still facing issue when Pie chart is rendered with the marker and cluster template implementation. The pie charts gets hidden when the clustering process is started. The support for declarative syntax for marker settings are also not implemented in this package. We will implement these support and provide you the package on November 11, 2020.

Regards,
Indumathi R



IR Indumathi Ravi Syncfusion Team November 12, 2020 01:45 AM UTC

Hi Ralph, 
  
Sorry for the inconvenience caused. 
  
We have implemented the marker template rendering in the declarative syntax. But the Pie charts are not rendering properly in the marker templates with the declarative syntax. The marker clusters are also not rendering properly when Pie chart is used as templates for the clusters. Since the Pie chart is different component and it does not comes under Maps architecture, we are facing some complexities internally to update the DOM elements for the markers and clusters. However, we are checking on this with high priority. We will check these issues and update you with further details on November 17, 2020. However, we have provided the custom package for the declarative syntax below for your reference. 
  
  
We have also created a sample to demonstrate the marker templates with default cluster shapes rendered with declarative syntax. Please find the sample application from the below link. 
  
Please let us know if you need any further assistance. 
  
Regards, 
Indumathi R 



IR Indumathi Ravi Syncfusion Team November 18, 2020 02:23 AM UTC

Hi Ralph, 
  
Thank you for your patience. 
  
We have fixed the mentioned issues in the Pie chart rendering with the marker cluster template and the declarative syntax with marker settings in the Maps component. The marker templates and its cluster are now rendered as Pie charts. Please find the sample application and custom NuGet package links below. We have also recorded the working of the implementation as video and it can be downloaded from the below link. 
  
  
Please let us know that this implementation meets your requirement. The provided implementation is still in testing phase. We will fix further issues found in the testing phase and provide you the custom package on November 23, 2020. 
  
Regards, 
Indumathi R 



SA Sabari Anand Senthamarai Kannan Syncfusion Team November 23, 2020 05:17 PM UTC

Hi Ralph, 
  
We've been continuously trying to resolve the issues in zooming and panning the cluster templates with the Pie chart in the Maps component. But the issues are more complex than we originally thought. Multiple clusters are not rendered correctly when the Pie chart is used in the template. We also face issues in cluster expansion with the cluster template as the Pie chart.  
 
To resolve these issues, we need to make major architectural changes in the component itself. We have planned to make these architectural changes, but this involves more time for analysis, design, development, and testing. So, we have estimated that these changes can be completed around the mid of January 2021. We will complete and provide you the custom patch on the mentioned timeline. Can you please let us know if this timeline will be acceptable for you? 
  
We apologize for the inconvenience caused. 
 
Regards, 
Sabari Anand

Marked as answer
Loader.
Up arrow icon