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

chore(IT Wallet): [SIW-1927] Add pull-to-refresh to the wallet screen #6556

Merged
merged 16 commits into from
Dec 17, 2024

Conversation

mastro993
Copy link
Contributor

@mastro993 mastro993 commented Dec 16, 2024

Short description

This PR enables the "pull to refresh" feature in the wallet home screen.

List of changes proposed in this pull request

  • Fixed in issue in the IOScrollView component, which was causing the RefreshIndicator to ne be displayed correctly. See more here: ScrollView: RefreshControl not visible during refreshing if snapToOffsets is used. facebook/react-native#27324 (cc @dmnplb)
  • Refactored WalletHomeScreen removing unnecessary extra components
  • Moved analytics sagas from watchWalletSaga to dedicated handleWalletAnalyticsSaga
  • Added walletUpdate action, handled by handleWalletUpdateSaga, which updates the wallet content
  • Improved wallet placeholders handling in the watchWalletSaga handler and wallet reducer: placeholders are no more replacing existing cards with the same key
  • Added isWalletScreenRefreshingSelector selector, to get the wallet refresh state

How to test

Navigate to the wallet screen, try to "pull to refresh" and see if the content is being updated/refreshed and the refresh indicator works as expected.

Demo

RPReplay_Final1734428052.MP4

@mastro993 mastro993 changed the title [SIW-1927] Add pull-to-refresh in the wallet screen [SIW-1927] Add pull-to-refresh to the wallet screen Dec 16, 2024
@pagopa-github-bot pagopa-github-bot changed the title [SIW-1927] Add pull-to-refresh to the wallet screen chore(IT Wallet): [SIW-1927] Add pull-to-refresh to the wallet screen Dec 16, 2024
@pagopa-github-bot
Copy link
Collaborator

pagopa-github-bot commented Dec 16, 2024

Affected stories

  • ⚙️ SIW-1927: [io-app] abilitare il pull to refresh per Bonus&Pagamenti

Generated by 🚫 dangerJS against 2b901fd

Copy link

codecov bot commented Dec 16, 2024

Codecov Report

Attention: Patch coverage is 57.14286% with 24 lines in your changes missing coverage. Please review.

Project coverage is 49.25%. Comparing base (4f204b4) to head (8078e45).
Report is 898 commits behind head on master.

Files with missing lines Patch % Lines
.../features/wallet/saga/handleWalletAnalyticsSaga.ts 0.00% 12 Missing ⚠️
ts/features/wallet/saga/handleWalletUpdateSaga.ts 0.00% 4 Missing ⚠️
ts/features/wallet/screens/WalletHomeScreen.tsx 84.00% 4 Missing ⚠️
ts/features/wallet/saga/index.ts 0.00% 3 Missing ⚠️
ts/features/wallet/store/reducers/cards.ts 75.00% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #6556      +/-   ##
==========================================
+ Coverage   48.42%   49.25%   +0.82%     
==========================================
  Files        1488     1553      +65     
  Lines       31617    31983     +366     
  Branches     7669     7240     -429     
==========================================
+ Hits        15311    15752     +441     
+ Misses      16238    16192      -46     
+ Partials       68       39      -29     
Files with missing lines Coverage Δ
ts/components/ui/IOScrollView.tsx 87.17% <100.00%> (ø)
ts/features/wallet/store/actions/index.ts 100.00% <100.00%> (ø)
ts/features/wallet/store/selectors/index.ts 92.50% <100.00%> (ø)
ts/features/wallet/utils/index.tsx 77.77% <100.00%> (ø)
ts/features/wallet/store/reducers/cards.ts 97.14% <75.00%> (ø)
ts/features/wallet/saga/index.ts 14.28% <0.00%> (ø)
ts/features/wallet/saga/handleWalletUpdateSaga.ts 0.00% <0.00%> (ø)
ts/features/wallet/screens/WalletHomeScreen.tsx 77.14% <84.00%> (ø)
.../features/wallet/saga/handleWalletAnalyticsSaga.ts 0.00% <0.00%> (ø)

... and 1729 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b8229dc...8078e45. Read the comment docs.

@mastro993 mastro993 self-assigned this Dec 16, 2024
Copy link
Contributor

github-actions bot commented Dec 17, 2024

Jira Pull Request Link

This Pull Request refers to the following Jira issue SIW-1927

Copy link
Collaborator

@gispada gispada left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mastro993 mastro993 merged commit 31f4df0 into master Dec 17, 2024
11 checks passed
@mastro993 mastro993 deleted the SIW-1927-add-pull-to-refresh-to-wallet branch December 17, 2024 21:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants