fix: arrow icon next to toggle in settings [WPB-22554] #4504
+2
−10
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.



PR Submission Checklist for internal contributors
The PR Title
SQPIT-764The PR Description
What's new in this PR?
Issues
In settings, for rows that have a toggle, there shouldn't be an arrow icon visible, the app should either show a toggle or arrow icon.
Causes (Optional)
This is just an outcome of actually fixing the part of code that had no sense before, as previously it was like this:
so in case of null
trailingIcon(and it should be null when there's a toggle) it was passing theImageVectorbut it wasn't drawing it (not wrapped in any Icon nor Image drawable) and when replacing material Icons it was actually wrapped withIconbecause it was probably noticed that it doesn't do anything.Solutions
Remove creating
Iconwith arrow whentrailingIconis null - in this case it shouldn't have any trailing icon.Testing
How to Test
Open settings and check "lock with passcode" option, if app lock is enabled for the user and not enforced by team, so when the toggle is visible and editable.
Attachments (Optional)
PR Post Submission Checklist for internal contributors (Optional)
PR Post Merge Checklist for internal contributors
References
feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764.