Skip to content

feat: add symbolZOffset to symbol layer #3802

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mathieupost
Copy link
Contributor

Description

Add support for symbol-z-offset

I've filled the values in v8.json based on other values I saw there. I don't exactly know what each field should be (especially in expression and property-type), so I'm not 100% certain that these are correct.

Also, at some point yarn generate added the values at the right places, but for some reason it doesn't anymore for me at the moment and removes everything except for the entry in v8.json. I'm probably doing something wrong here, but I've restored what was initially added by yarn generate.

Checklist

  • I've read CONTRIBUTING.md
  • I updated the doc/other generated code with running yarn generate in the root folder
  • I have tested the new feature on /example app.
    • Actually not in the /example app as I couldn't get it to build, but it does work in our own application FWIW (with both V11 and New Architecture enabled).
    • In V11 mode/ios
    • In New Architecture mode/ios
    • In V11 mode/android
    • In New Architecture mode/android
  • I added/updated a sample - if a new feature was implemented (/example)

Screenshot OR Video

with.mov
without.mov

@mathieupost mathieupost had a problem deploying to CI with Mapbox Tokens March 7, 2025 12:43 — with GitHub Actions Failure
@mathieupost mathieupost had a problem deploying to CI with Mapbox Tokens March 7, 2025 12:43 — with GitHub Actions Failure
@mathieupost mathieupost had a problem deploying to CI with Mapbox Tokens March 7, 2025 12:43 — with GitHub Actions Failure
@mathieupost mathieupost had a problem deploying to CI with Mapbox Tokens March 7, 2025 12:43 — with GitHub Actions Failure
@mathieupost mathieupost had a problem deploying to CI with Mapbox Tokens March 7, 2025 12:43 — with GitHub Actions Failure
@mathieupost mathieupost had a problem deploying to CI with Mapbox Tokens March 7, 2025 12:43 — with GitHub Actions Failure
@mathieupost mathieupost had a problem deploying to CI with Mapbox Tokens March 7, 2025 12:43 — with GitHub Actions Failure
@mfazekas
Copy link
Contributor

mfazekas commented Apr 5, 2025

@mathieupost thanks so much for looking into this.

v8.json is sourced from:
https://raw.githubusercontent.com/mapbox/mapbox-gl-js/master/src/style-spec/reference/v8.json

yarn fetch:style:spec should update the v8.json

@mathieupost
Copy link
Contributor Author

Thanks for the pointer!

Unfortunately it seems that symbolZOffset is not yet in there, so running that command will remove it from the v8.json

@mfazekas
Copy link
Contributor

Thanks for the pointer!

Unfortunately it seems that symbolZOffset is not yet in there, so running that command will remove it from the v8.json

symbol-z-offset is in the json? Have you tried to update the json file with yarn fetch:style:spec ?

@mathieupost
Copy link
Contributor Author

mathieupost commented Apr 17, 2025

Yeah I've updated with yarn fetch:style:spec. I see that there is actually one in paint_symbol, but I need one in layout_symbol, but that is not yet in https://raw.githubusercontent.com/mapbox/mapbox-gl-js/master/src/style-spec/reference/v8.json

It's still an experimental feature, so maybe that's why it's not yet there.

@mfazekas
Copy link
Contributor

Yeah I've updated with yarn fetch:style:spec. I see that there is actually one in paint_symbol, but I need one in layout_symbol, but that is not yet in https://raw.githubusercontent.com/mapbox/mapbox-gl-js/master/src/style-spec/reference/v8.json

It's still an experimental feature, so maybe that's why it's not yet there.

But why do we need in layout_symbol, we do parse paint_symbol-s as well, don't we?

https://github.com/rnmapbox/maps/blob/main/scripts/autogenHelpers/generateCodeWithEjs.mjs#L102-L103

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants