You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
panBy allows AnimationOptions as an optinoal parameter. So, it seems like it can be set offset for animation separately from panBy's offset. But if it's set offset on panBy and offset on AnimationOptions, it works with offset on AnimationOptions.
The optional options parameter for panBy uses options from AnimationOptions, one of which is offset. However, panBy already has a required offset parameter. According to the OP, if options.offset is specified it overrides the offset param's value in panBy.
The description for the two offsets is different, but I'm having trouble determining what the implications are for a user who chooses to use both offset and options.offset for panBy.
"of the target center relative to real map container center at the end of animation."
I think both of these descriptions could use some clarification, and we should probably add a caveat to the panBy docs about using them together. @mapbox/gl-js could someone assist me with getting a handle on what users need to know here?
Description
panBy allows
AnimationOptions
as an optinoal parameter. So, it seems like it can be setoffset
for animation separately from panBy's offset. But if it's set offset on panBy and offset on AnimationOptions, it works with offset on AnimationOptions.Link to Demonstration
docs:
fiddle: https://jsfiddle.net/L15dohmx/
Expected Behavior
panBy should not allow offset on AnimationOptions.
Actual Behavior
it overrides offset by AnimationOptions.
The text was updated successfully, but these errors were encountered: