mapbox / mapbox/mapbox-maps-flutter

Decoding FillLayer with fill expression makes layer transparent, others too

Open
#968 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Dart
Stars
380
Forks
204
PR merge metrics
No merged PRs in 30d

Description

when using `FillLayer.decode` function and having style json with fill color expression, the function sets fillColorExpression properly, but also sets fillColor to `0` - this causes layer to be transparent

It's similar for LineLayer when we have lineColor, or when we have textColor.
Also in some cases if the value is not an expression but the string direct value, then parsing / decoding throws error, because it tries to cast the value to List (but it can be just string)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the FillLayer.decode implementation and the corresponding decoding paths for LineLayer lineColor and textColor. Reproduce the reported expression and direct-string cases, then add regression coverage showing that expression values do not also reset the color and that direct string values decode without an error.

Written by the indexing model from the issue text.

Assessment

Tech stack
dart, flutter
Domain
mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.