Rename Boolean options to follow Swift naming conventions - #157
Merged
Conversation
Three SwipeMenuViewOptions properties had names that read as broken English and ignored the Swift API Design Guidelines' conventions for Boolean assertions: - TabView.needsAdjustItemViewWidth -> adjustsItemViewWidth, matching UIKit's adjusts... pattern (e.g. adjustsFontSizeToFitWidth). - TabView.needsConvertTextColorRatio -> interpolatesTextColorOnSwipe, which says what actually happens: titles crossfade between textColor and selectedTextColor in proportion to the swipe progress. - TabView.AdditionView.isAnimationOnSwipeEnable -> isAnimationOnSwipeEnabled, fixing the is...Enable grammar. The old spellings are removed. Documentation comments for the renamed options now describe their behavior precisely, and the DocC article, example app, and tests use the new names.
There was a problem hiding this comment.
Clean, purely mechanical rename of three SwipeMenuViewOptions booleans to follow Swift API naming guidelines. Verified no stray references to the old names remain anywhere (source, docs, example app, tests), the changelog documents the breaking change, and the updated doc comments accurately describe the actual runtime behavior. No logic changes, no concurrency concerns.
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.
Summary
Three
SwipeMenuViewOptionsproperties had names that read as broken English and ignored the Swift API Design Guidelines conventions for Boolean assertions. This PR renames them; the old spellings are removed (breaking change, recorded under Unreleased → Breaking in the changelog):TabView.needsAdjustItemViewWidthadjustsItemViewWidthadjusts…pattern (e.g.adjustsFontSizeToFitWidth)TabView.needsConvertTextColorRatiointerpolatesTextColorOnSwipetextColorandselectedTextColorin proportion to the swipe progressTabView.AdditionView.isAnimationOnSwipeEnableisAnimationOnSwipeEnabledis…EnablegrammarThe doc comments for the renamed options now describe the behavior precisely (the old ones, e.g. "AdditionView swipe animation disable feature. Defaults to 'true'", did not). The DocC article, example app, and tests are updated to the new names; no references to the old spellings remain.
Tests