This fixes and issue where the stylers would just end up as empty objects when added since System.Text.Json could not figure out how to serialize them correctly. This also changes how MapTypeStyle is constructed since its no longer an object array but an array of the abstract class. This does however prevent that people implement their own style objects, but from my understanding that should never be needed since we have all the available styles specified in the project.
Testing this requires a api-key but if you check the map object in JS it now contains the correct styles.
This fixes and issue where the stylers would just end up as empty objects when added since System.Text.Json could not figure out how to serialize them correctly. This also changes how MapTypeStyle is constructed since its no longer an object array but an array of the abstract class. This does however prevent that people implement their own style objects, but from my understanding that should never be needed since we have all the available styles specified in the project.
Testing this requires a api-key but if you check the map object in JS it now contains the correct styles.