mapbox-gl-js
mapbox-gl-js copied to clipboard
feature-state expression is incorrectly evaluated in queryRenderedFeatures
mapbox-gl-js version: 1.12.0
browser: Google Chrome v86
Steps to Trigger Behavior
- Use
feature-stateexpression in a paint property for a symbol feature - Query this feature using
queryRenderedFeatures
Link to Demonstration
https://jsfiddle.net/osvodef/sdtr63jp/24/
Expected Behavior
Feature state is taken into account, correct value of the property is returned.
Actual Behavior
Default value of the property is returned.
The bug only affects symbol features. As far as I understood, this is because lookupSymbolFeatures doesn't pass sourceFeatureState arg to loadMatchingFeatures (in the file feature_index.js).
I just stumbled across this and I can confirm this is still an issue. Are there any easy ways to fix this or any plans on prioritizing this bug?