Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[HOLD for payment 2024-03-29] IOS - Workspace - Offline indicator in workspace page overlaps with navigation bar #38520

Closed
1 of 6 tasks
kbecciv opened this issue Mar 18, 2024 · 18 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Weekly KSv2

Comments

@kbecciv
Copy link

kbecciv commented Mar 18, 2024

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 1.4.54-0
Reproducible in staging?: y
Reproducible in production?: y
Issue reported by: Applause - Internal Team

Action Performed:

  1. Launch New Expensify app.
  2. Go to Profile > Workspaces.
  3. Select any workspace.
  4. Go offline.

Expected Result:

Offline indicator will not overlap with navigation bar.

Actual Result:

Offline indicator overlaps with navigation bar.

Workaround:

n/a

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

image

View all open jobs on GitHub

@kbecciv kbecciv added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Mar 18, 2024
Copy link

melvin-bot bot commented Mar 18, 2024

Triggered auto assignment to @abekkala (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

@kbecciv
Copy link
Author

kbecciv commented Mar 18, 2024

We think that this bug might be related to #wave-collect - Release 1

@kbecciv
Copy link
Author

kbecciv commented Mar 18, 2024

@abekkala I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors

@allgandalf
Copy link
Contributor

allgandalf commented Mar 18, 2024

Proposal

Please re-state the problem that we are trying to solve in this issue.

What is the root cause of that problem?

We set style prop to have bottom padding :

<ScreenWrapper
testID={WorkspaceInitialPage.displayName}
includeSafeAreaPaddingBottom={false}
style={[styles.pb0]}

This in overturns the below style for bottom padding:

if (includeSafeAreaPaddingBottom || (isOffline && shouldShowOfflineIndicator)) {
paddingStyle.paddingBottom = paddingBottom;
}

What changes do you think we should make in order to solve the problem?

Remove the style={[styles.pb0]} prop as this sets the bottom padding to 0.

What alternative solutions did you explore? (Optional)

@rmm-fl
Copy link
Contributor

rmm-fl commented Mar 18, 2024

Proposal

Please re-state the problem that we are trying to solve in this issue.

ios - Offline indicator overlaps with navigation bar.

What is the root cause of that problem?

ScreenWrapper has styles.pb0 here:

<ScreenWrapper
testID={WorkspaceInitialPage.displayName}
includeSafeAreaPaddingBottom={false}
style={[styles.pb0]}

What changes do you think we should make in order to solve the problem?

Remove padding style and replace it with this:

     <ScreenWrapper
            testID={WorkspaceInitialPage.displayName}
            shouldEnablePickerAvoiding={false}
            shouldShowOfflineIndicatorInWideScreen
        >

Similar usage here:

<ScreenWrapper
shouldEnablePickerAvoiding={false}
shouldShowOfflineIndicatorInWideScreen
testID={WorkspacesListPage.displayName}
>

Result

Screenshot 2024-03-19 at 02 44 29

What alternative solutions did you explore? (Optional)

@allgandalf
Copy link
Contributor

This bug is also visible for Collect Workspaces and my proposal fixes it for both the views :)

@allgandalf
Copy link
Contributor

hello @rmm-fl , shouldShowOfflineIndicatorInWideScreen is not used to determine the style of the indicator, it is used as a boolean condition to show content, I think you must have confused yourself with the intention to use shouldShowOfflineIndicatorInWideScreen :)

{!isSmallScreenWidth && shouldShowOfflineIndicatorInWideScreen && (

@mkhutornyi
Copy link
Contributor

This is follow-up of ideal nav v2
cc: @kosmydel

@ShridharGoel
Copy link
Contributor

Proposal

Please re-state the problem that we are trying to solve in this issue.

IOS - Workspace - Offline indicator in workspace page overlaps with navigation bar.

What is the root cause of that problem?

Padding is being set as 0.

<ScreenWrapper
testID={WorkspaceInitialPage.displayName}
includeSafeAreaPaddingBottom={false}
style={[styles.pb0]}
>

This is happening only on iOS because we don't have this horizontal bottom bar on other platforms. If we use fullscreen mode in Android, then we might be able to see the same issue there as well.

What changes do you think we should make in order to solve the problem?

We should add a condition which only uses 0 padding if user is online. If user is offline, then the style will be set to undefined and padding would be set inside ScreenWrapper.

<ScreenWrapper
    testID={WorkspaceInitialPage.displayName}
    includeSafeAreaPaddingBottom={false}
    style={!isOffline ? styles.pb0 : undefined}
>

Then, padding would be taken from here:

// We always need the safe area padding bottom if we're showing the offline indicator since it is bottom-docked.
if (includeSafeAreaPaddingBottom || (isOffline && shouldShowOfflineIndicator)) {
paddingStyle.paddingBottom = paddingBottom;
}

In the above condition {!isOffline ? styles.pb0 : undefined}, we don't need check for includeSafeAreaPaddingBottom because if it always false.
Also, we don't need check for shouldShowOfflineIndicator because if it always true.

@WojtekBoman
Copy link
Contributor

@mkhutornyi Because it's follow-up to ideal-nav-v2, I can look into it :) As far as I know, removing style prop from the ScreenWrapper in WorkspaceInitialPage.tsx should solve this issue. I'll prepare a PR :)

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels Mar 19, 2024
Copy link

melvin-bot bot commented Mar 19, 2024

Triggered auto assignment to @marcaaron, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Mar 22, 2024
@melvin-bot melvin-bot bot changed the title IOS - Workspace - Offline indicator in workspace page overlaps with navigation bar [HOLD for payment 2024-03-29] IOS - Workspace - Offline indicator in workspace page overlaps with navigation bar Mar 22, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Mar 22, 2024
Copy link

melvin-bot bot commented Mar 22, 2024

Reviewing label has been removed, please complete the "BugZero Checklist".

Copy link

melvin-bot bot commented Mar 22, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.55-3 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

If no regressions arise, payment will be issued on 2024-03-29. 🎊

Copy link

melvin-bot bot commented Mar 22, 2024

BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:

  • [@marcaaron] The PR that introduced the bug has been identified. Link to the PR:
  • [@marcaaron] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment:
  • [@marcaaron] A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion:
  • [@marcaaron] Determine if we should create a regression test for this bug.
  • [@marcaaron] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
  • [@abekkala] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:

@situchan
Copy link
Contributor

Please assign me here

@abekkala
Copy link
Contributor

PAYMENT SUMMARY FOR MAR 29

@abekkala
Copy link
Contributor

@slafortune will be handling payment for me while I'm ooo

@slafortune
Copy link
Contributor

Paid

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Weekly KSv2
Projects
None yet
Development

No branches or pull requests

10 participants