Fix: Taxes page still shown when disable the taxes from other browser#76611
Fix: Taxes page still shown when disable the taxes from other browser#76611puneetlath merged 12 commits intoExpensify:mainfrom
Conversation
Codecov Report❌ Looks like you've decreased code coverage for some files. Please write tests to increase, or at least maintain, the existing level of code coverage. See our documentation here for how to interpret this table.
|
|
@Krishna2323 Please 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] |
joekaufmanexpensify
left a comment
There was a problem hiding this comment.
@ryntgh does this fix address this bug for all features on the more features page?
@joekaufmanexpensify yes, it fixes all features pages. |
|
@ryntgh the tag import page is not closing sometimes — could you please check? Could you also thoroughly test all the other features again? I think I’ve seen the same issue on one more page. Thanks! Monosnap.screencast.2025-12-05.16-42-27.mp4 |
|
@ryntgh the above bug happens probably because we haven't passed |
|
@Krishna2323 thanks for pointing this out! I’ll look into this tomorrow |
|
@ryntgh bump |
|
@Krishna2323 Sorry for the late response, I've updated the PR I also found the same navigation case in |
|
@ryntgh there are two more components that use |
|
@Krishna2323 Thanks for the feedback! I've updated the PR accordingly |
|
@puneetlath the This would ensure consistent access control with other company cards pages and fix the bug where the page doesn't navigate away when the feature is disabled from another browser. Looking at the codebase, most company cards pages are wrapped with
Current Protection in
|
This comment was marked as outdated.
This comment was marked as outdated.
|
@ryntgh on the iOS app, I briefly see a blank screen. Could you please check that? It can also be seen in your iOS native recording. ios_native.mp4 |
|
Oh yeah, it looks like iOS native has a blank screen issue when opening any page from the selected feature page. I’ll investigate this tomorrow morning |
|
@Krishna2323 Sure, I've updated the PR to use |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppandroid_native.mp4Android: mWeb Chromeandroid_chrome.mp4iOS: HybridAppios_native.mp4iOS: mWeb Safariios_safari.mp4MacOS: Chrome / Safariweb_chrome.mp4 |
|
@puneetlath, could you please check this comment and the recordings below? On native platforms, we first go back to the Feature page and then to the More Features page. This is for fixing #76611 (comment). iOS: HybridAppios_native.mp4iOS: mWeb Safariios_safari.mp4 |
|
@puneetlath friendly bump! |
|
Sorry for the delay. It makes sense to me to address that if it's relevant to what we're doing here. |
|
@ryntgh could you please fix
@puneetlath what about this^—are we fine with it? iOS: HybridAppios_native.mp4iOS: mWeb Safariios_safari.mp4 |
Sorry for the delay, I've updated the PR |
|
@ryntgh why did you added |
|
@Krishna2323 Since the Travel feature is currently available on the More features page, I think we should address this, as users with a public domain can easily access
But I'm not entirely sure if this is necessary, since it's an error page shown during the Travel flow. Should we wrap it, or is this edge case acceptable? What do you think? |
|
@puneetlath please check this comment before merging. Thanks! |
|
@puneetlath friendly bump! |
puneetlath
left a comment
There was a problem hiding this comment.
I'm good with it. Sorry for the delay!
|
✋ 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/puneetlath in version: 9.3.3-0 🚀
|
|
🚀 Deployed to production by https://github.com/francoisl in version: 9.3.3-8 🚀
|
| <AccessOrNotFoundWrapper | ||
| policyID={policyID} | ||
| accessVariants={[CONST.POLICY.ACCESS_VARIANTS.ADMIN, CONST.POLICY.ACCESS_VARIANTS.PAID]} | ||
| featureName={CONST.POLICY.MORE_FEATURES.ARE_RULES_ENABLED} |
There was a problem hiding this comment.
The page is not related to the Rules feature. Fixed in #81313.
| function PublicDomainErrorPage({route}: PublicDomainErrorPageProps) { | ||
| const styles = useThemeStyles(); | ||
| const {translate} = useLocalize(); | ||
| const [activePolicyID] = useOnyx(ONYXKEYS.NVP_ACTIVE_POLICY_ID, {canBeMissing: true}); |
There was a problem hiding this comment.
This comes from #82773. We can't activate the policy ID here because the active policy ID is not the policy of the currently opened workspace. We should use the policy ID of the current workspace by passing it as a parameter.
| testID="PublicDomainErrorPage" | ||
| <AccessOrNotFoundWrapper | ||
| policyID={activePolicyID} | ||
| featureName={CONST.POLICY.MORE_FEATURES.IS_TRAVEL_ENABLED} |

Explanation of Change
This PR adds
isFocusedto the dependency array of theuseEffectthat handles navigation when a feature is disabled, so that the user is navigated to the More features page when the RHP is openedFixed Issues
$ #75861
PROPOSAL: #75861 (comment)
Tests
Same as QA Steps
Offline tests
Same as QA Steps
QA Steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.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
Android: Native
Android-Native.mp4
Android: mWeb Chrome
Android-mWeb.mp4
iOS: Native
iOS-Native.mp4
iOS: mWeb Safari
iOS-mWeb.mp4
MacOS: Chrome / Safari
MacOS-Chrome.mp4