Select to view content in your preferred language

is expression supported in the styles in @arcgis/core 4.22? arcgis will lost accuracy when converting colors?

604
2
06-07-2022 02:55 AM
3kmsdistance
Emerging Contributor

How does one dynamically style a vector tile layer based on data that is external to the layer?
 
when I use expression  as show below,  it take effets
 
paintProperties["fill-color"] = [
"match",
[ "get", "admincode1"],
"#F00",
"#00F",
"#FF0",
"#0F0",
"#0FF"
];


but when I use color Array like 
"#3900b3", "#714dbf", "#9e6b90", "#cf9270", "#ebb698", layer can not show real colors
 arcgis will lost accuracy when converting colors?
 
paintProperties["fill-color"] = [
"match",
[ "get", "admincode1"],
"#3900b3",
"#714dbf",
"#9e6b90",
"#cf9270",
"#ebb698"
];

0 Kudos
2 Replies
SalamAleykum
New Contributor

try switch admincode, one time for me it works. Problem is that HEX-codes can't be red correctly (for good color inspiration can use this https://create.vista.com/colors/color-names/jade-green/). And you need edit this. I can't say what for now, maybe later.

0 Kudos
3kmsdistance
Emerging Contributor

it doesnot solve the problem

can you describe it more clearly?

thanks a lot

0 Kudos