Azure-Samples / azure-maps-html-marker-layer

An Azure Maps Web SDK module that provides a layer that renders point data from a data source as HTML elements on the map.
MIT License
5 stars 9 forks source link

textClassName is not applied correctly #3

Closed nhi-dang-by closed 3 years ago

nhi-dang-by commented 3 years ago

Please provide us with the following information:

This issue is for a: (mark with an x)

- [x] bug report -> please search issues before submitting
- [ ] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)

Minimal steps to reproduce


<style>
.textColor {
fill: #FFFFF;
}
</style>

new window.atlas.PieChartMarker({ position: [15,20], values: [1,2,3,4,5], colors: [color1, color2, color3, color4, color5], fillColor: theme.palette.background.default, text: 155, visible: true, anchor: 'center', strokeWidth: 1, strokeColor: 'white', textClassName: 'textColor' })



In this scenario, the override color is not applied. Text color is still black
Ideally, i would like to override the style using style attribute, not class

### Any log messages given by the failure
>

### Expected/desired behavior
> Should be able to override style

### OS and Version?
> macOS (Mojave)

### Versions
>

### Mention any other details that might be useful

> ---------------------------------------------------------------
> Thanks! We'll be in touch soon.
rbrundritt commented 3 years ago

I fixed the bug with the textClassName. Using classes rather than inline styles is preferred.