Fix: Current currency is not highlighted and not marked#18059
Conversation
|
@iwiznia @rushatgabhane One of you needs to copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
| placeholderText={this.props.translate('common.search')} | ||
| headerMessage={headerMessage} | ||
| safeAreaPaddingBottomStyle={safeAreaPaddingBottomStyle} | ||
| initiallyFocusedOptionKey={_.get(_.find(this.state.currencyData, crc => crc.currencyCode === this.props.iou.selectedCurrencyCode), 'keyForList')} |
There was a problem hiding this comment.
@iwiznia @rushatgabhane I added initiallyFocusedOptionKey prop to OptionsSelector to focus to the current currency instead of the first currency in list when we go to this page
| currencyCode, | ||
| keyForList: currencyCode, | ||
| customIcon: currencyCode === this.props.iou.selectedCurrencyCode ? greenCheckmark : undefined, | ||
| boldStyle: currencyCode === this.props.iou.selectedCurrencyCode, |
There was a problem hiding this comment.
NAB (polish): create a variable isSelectedCurrency and use that instead.
| boldStyle: currencyCode === this.props.iou.selectedCurrencyCode, | |
| customIcon: isSelectedCurrency ? greenCheckmark : undefined | |
| boldStyle: isSelectedCurrency, |
| placeholderText={this.props.translate('common.search')} | ||
| headerMessage={headerMessage} | ||
| safeAreaPaddingBottomStyle={safeAreaPaddingBottomStyle} | ||
| initiallyFocusedOptionKey={_.get(_.find(this.state.currencyData, crc => crc.currencyCode === this.props.iou.selectedCurrencyCode), 'keyForList')} |
There was a problem hiding this comment.
crc => crc.currencyCode
nitpick: @dukenv0307 could you please rename crc to something more descriptive and meaningful? 🙇
I don't have a suggestion because I don't know what crc means
There was a problem hiding this comment.
cool, let's rename it to currency
|
@rushatgabhane I just updated, please help to check again |
Reviewer Checklist
Screenshots/Videos |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/iwiznia in version: 1.3.9-12 🚀
|
|
🚀 Deployed to production by https://github.com/roryabraham in version: 1.3.12-0 🚀
|






Details
Current currency is not highlighted and not marked
Fixed Issues
$ #17372
PROPOSAL: #17372 (comment)
Tests
Offline tests
QA Steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodWaiting for Copylabel for a copy review on the original GH to get the correct copy.STYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)/** comment above it */thisproperly so there are no scoping issues (i.e. foronClick={this.submit}the methodthis.submitshould be bound tothisin the constructor)thisare necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);ifthis.submitis never passed to a component event handler likeonClick)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Web
Screencast.2023-04-27.10.26.47.mp4
Mobile Web - Chrome
Record_2023-04-27-10-28-54.mp4
Mobile Web - Safari
processed-2B8DF3FF-BC97-465A-9681-167E10A470DC-992FC4B4-A6FB-45B3-A234-B9205555477C.mp4
Desktop
Screen.Recording.2023-04-27.at.16.29.22.mov
iOS
Screen.Recording.2023-04-27.at.16.27.10.mov
Android
17372.mp4