Repository navigation
Conversation
Use null-or-undefined fallback for arc angles instead of replacing zero with the default sector size. Co-authored-by: generaltony007 <144252170+GeneralTony007@users.noreply.github.com>
Cover literal and scriptable zero, mixed indexed and scriptable values, positive angles, and null/undefined fallback. Co-authored-by: generaltony007 <144252170+GeneralTony007@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Polar area arc angles currently use
angle || defaultAngle, so an explicit angle of zero is replaced by the default sector size. This also affects scriptable and indexable angles. For example,[0, 180]renders two semicircles rather than a zero-angle first arc followed by one 180-degree arc.Change
Only fall back for null or undefined angles, using the existing helper. Keep the existing hidden-element behavior and positive-angle behavior unchanged. This adds no option or API.
Seven regression/control cases cover literal zero, scriptable zero, mixed indexable and scriptable angles, positive angles, and null/undefined fallback. Four cases fail on unchanged master.
Validation
71d44219.[0, 180].Firefox and package-integration tests were not run. The adjacent types-only PR #12313 does not change this runtime fallback.