-
Notifications
You must be signed in to change notification settings - Fork 43
Offline mode drawer PAY-1713 #4014
Offline mode drawer PAY-1713 #4014
Conversation
Note - re-used the drawer header from Share to Story drawer instead of following the Figma for now. Going to ask design if we're going to standardize the header soon. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
excellent job! it's looking really clean
packages/mobile/src/components/drawers/OfflineListeningDrawer.tsx
Outdated
Show resolved
Hide resolved
) | ||
|
||
const handleSaveChanges = useCallback(() => { | ||
if (isFavoritesMarkedForDownload) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could maybe collapse the if else's into something a bit more explicit:
`if (isFavoritesMarkedForDownload && !isFavoritesOn) {...} else if (!isFavoritesMarkedForDownload && isFavoritesOn) {...} ? main idea being to make clear we do stuff when the value has changed
packages/mobile/src/components/drawers/OfflineListeningDrawer.tsx
Outdated
Show resolved
Hide resolved
packages/mobile/src/components/drawers/OfflineListeningDrawer.tsx
Outdated
Show resolved
Hide resolved
packages/mobile/src/components/drawers/OfflineListeningDrawer.tsx
Outdated
Show resolved
Hide resolved
}, [dispatch, switchValue]) | ||
|
||
return ( | ||
<TouchableOpacity onPress={handlePressStatusIndicator}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it might not work, but i wonder if we could use IconButton for this? the nice thing with that is it comes in with some built-in hitSlop to make it easier to press.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sadly we cannot because the "loading" indicator state is a rive component not an icon component. can add in a hitslop here if we run into issues pressing the button in qa!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice yeah makes sense, and sounds like a plan :)
It looks like there may be some changes to native mobile code, which requires triggering a full app release. Please follow the instructions here: https://www.notion.so/audiusproject/When-to-bump-app-version-2644a8f772364a4d91f44abcba44ce0b?pvs=4. cc @nicoback2 @sliptype |
Preview this change https://demo.audius.co/nkang--offline-mode-drawer |
Co-authored-by: Nikki Kang <kangaroo233@gmail.com>
Description
Designs: https://www.figma.com/file/ClKssErI6tIMmZFwQifp9f/%F0%9F%92%B0-USDC-%2B-Payments%3A-Feature?type=design&node-id=1078-48999&mode=design&t=azQUY0z4AurR5HWo-0
How Has This Been Tested?
Screenshots