JoshuaJADaniel commented on issue #34621:
URL: https://github.com/apache/superset/issues/34621#issuecomment-3386419793

   @fin-gal
   
   > We expose them to the user through checkboxes, buttons, etc... As is done 
for the line settings: filled, stroked, width, etc... I assume this method by 
default would apply these settings to all points globally
   
   Correct, that's how we would implement it if we wanted the text settings to 
be applied globally.
   
   > I can't think of an easy way to assign them to specific points through the 
UI?
   
   Agreed, doing per-point customizations through the UI would be clunky and/or 
inflexible.
   
   > One way could be to take in some kind of JSON from the user
   
   I was thinking of something similar too. Specifically, what do you think 
about allowing customization to happen through the GeoJSON `properties` object 
itself? For example, the `properties` object could look something like this:
   
   ```json5
   {
     "type": "Feature",
     "geometry": {
       "type": "Point",
       "coordinates": [-92.0060, 42.7128]
     },
     "properties": {
       "name": "New York City",
       "labelSize": 24,
       "labelColor": "#ff0000" // We could also let this be [r, g, b, a] for 
flexibility
     }
   }
   ```
   
   My thinking is that the user would anyway be providing the label text 
through the `properties` object, so if they want to (optionally) customize the 
labels, they can just add the extra properties to do so. This would be simple 
and flexible.
   
   > Or we get the properties from the user's data [...] A similar mechanism 
could be used to customise the features styling directly from the user's data, 
and this would also allow per-point customisation. but maybe this is overkill?
   
   I did not think of this, but it could be a possibility as you said.
   
   > For the icons, here I'm not sure at all, so I don't have much feedback.
   
   I guess if there's no strong inclination to let icons be customized globally 
versus per point, we could just make it per point to cover all the use cases. 
To do so, the way it works would probably be very similar to enabling labels 
(i.e., icon image URLs and other values are provided via the `properties` 
object).
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to