⚠ This page is served via a proxy. Original site: https://github.com
This service does not collect credentials or authentication data.
Skip to content

Conversation

@dieguezguille
Copy link
Member

@dieguezguille dieguezguille commented Jan 30, 2026


Open with Devin

Summary by CodeRabbit

  • New Features

    • Entrance/exit motion added to Getting Started and Card Status; Getting Started now appears only when relevant KYC/deployment state applies for clearer guidance.
  • Bug Fixes

    • KYC status handling refined with improved retry and error-suppression behavior for more consistent status reporting and fewer spurious failures.
    • Onboarding step determination updated to reflect live KYC/deployment state.
  • Chores

    • Added patch-level changelog entries documenting these updates.

@changeset-bot
Copy link

changeset-bot bot commented Jan 30, 2026

🦋 Changeset detected

Latest commit: 6839afd

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@coderabbitai
Copy link

coderabbitai bot commented Jan 30, 2026

Walkthrough

Adds mount/unmount animations to GettingStarted and CardStatus, refactors onboarding step logic to accept hasKYC/isDeployed (removing external step mutation), centralizes richer KYC query defaults (retry and meta.suppressError), removes some local suppressions, and adds two patch changeset files.

Changes

Cohort / File(s) Summary
Changesets
​.changeset/chatty-regions-smoke.md, ​.changeset/dry-pumas-jog.md
Add two patch-level changeset entries for @exactly/mobile with brief changelog notes.
Animations — Home components
src/components/home/CardStatus.tsx, src/components/home/GettingStarted.tsx
Add key props and enter/exit animation props to root stacks to enable mount/unmount transitions.
Home composition & KYC rendering
src/components/home/Home.tsx
Introduce AnimatePresence, wrap CardStatus and GettingStarted, adjust GettingStarted rendering to depend on fetched KYC/deployment state, and simplify local KYC query handling.
Card: KYC query usage
src/components/card/Card.tsx
Remove local meta.suppressError usage from the ["kyc","status"] useQuery call, reverting to default error propagation.
QueryClient defaults
src/utils/queryClient.ts
Centralize richer defaults for ["kyc","status"]: add expected(error) classifier, retry policy (up to 3, skip for expected errors), and set meta.suppressError to expected; retain stale/gc times.
Onboarding state & steps
src/components/getting-started/GettingStarted.tsx, src/utils/useOnboardingSteps.ts
Introduce useOnboardingState to compute hasKYC/isDeployed; change useOnboardingSteps from a parameterless, stateful/query-backed hook to a pure memoized function accepting { hasKYC, isDeployed } and remove external setSteps.
Manifest
package.json
Minor single-line edit.

Sequence Diagram(s)

sequenceDiagram
  participant UI as Home / GettingStarted / CardStatus
  participant Animator as AnimatePresence
  participant QC as QueryClient
  participant API as getKYCStatus API
  participant Chain as Blockchain

  UI->>Animator: mount GettingStarted / CardStatus (keyed)
  Animator->>UI: apply enterStyle (opacity/translateY)
  UI->>QC: request ["kyc","status"] (useQuery)
  UI->>Chain: request bytecode for account (useBytecode)
  QC->>API: call getKYCStatus
  API-->>QC: success / error
  alt success
    QC-->>UI: return KYC status
  else error
    QC->>QC: retry up to 3 unless expected(error)
    QC-->>UI: propagate or suppress per meta.suppressError
  end
  UI->>UI: compute hasKYC/isDeployed -> useOnboardingSteps({hasKYC,isDeployed})
  Animator->>UI: apply exitStyle on unmount
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

Suggested reviewers

  • cruzdanilo
  • franm91
🚥 Pre-merge checks | ✅ 1 | ❌ 1
❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Title check ❓ Inconclusive The title '✨ misc app improvements' is vague and non-descriptive, using the term 'misc' which conveys no meaningful information about the specific changes made. Replace the vague title with a specific description of the main change, such as 'Refactor onboarding state management and add animations' or 'Improve KYC status query defaults and onboarding flow'.
✅ Passed checks (1 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fixes

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist
Copy link

Summary of Changes

Hello @dieguezguille, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request introduces several user experience improvements and bug fixes across the mobile application. It specifically addresses a gesture handler warning by ensuring callbacks are executed on the main React Native thread, and enhances the visual fluidity of the home screen by adding subtle entrance and exit animations to key components like the CardStatus and GettingStarted sections. Additionally, the data fetching logic for KYC status has been optimized to handle specific error states more gracefully, reducing redundant API calls.

Highlights

  • Gesture Handler Warning Fix: Implemented scheduleOnRN to correctly handle onPress callbacks within react-native-gesture-handler's onEnd event, resolving potential worklet warnings in BenefitCard.tsx.
  • Enhanced UI Animations: Introduced entrance and exit animations for the CardStatus and GettingStarted components using tamagui's animation properties and AnimatePresence for a smoother user experience.
  • Refined KYC Data Fetching: Modified the KYC status query to prevent unnecessary retries for specific API error responses (e.g., 'no kyc', 'not started'), improving efficiency and user experience in Home.tsx.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request primarily focuses on enhancing the user experience with animations and fixing a worklet gesture warning. It introduces entry and exit animations to the CardStatus and GettingStarted components on the home screen by utilizing AnimatePresence from tamagui and applying specific animation properties. The BenefitCard component is updated to fix a worklet gesture warning by importing scheduleOnRN and wrapping the onPress callback within a worklet. Additionally, the KYC status query in Home.tsx is refined to prevent retries for specific API errors and the rendering condition for the GettingStarted component is changed from !isPendingKYC to isKYCFetched.

Copy link

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

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

Devin Review found 1 potential issue.

View issue and 5 additional flags in Devin Review.

Open in Devin Review

@sentry
Copy link

sentry bot commented Jan 30, 2026

Codecov Report

❌ Patch coverage is 81.81818% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 65.74%. Comparing base (321e822) to head (6839afd).

Files with missing lines Patch % Lines
src/components/getting-started/GettingStarted.tsx 80.00% 3 Missing ⚠️
src/components/home/Home.tsx 57.14% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #705      +/-   ##
==========================================
+ Coverage   65.27%   65.74%   +0.47%     
==========================================
  Files         190      190              
  Lines        5996     5994       -2     
  Branches     1734     1734              
==========================================
+ Hits         3914     3941      +27     
+ Misses       1903     1873      -30     
- Partials      179      180       +1     
Flag Coverage Δ
e2e 65.71% <81.81%> (+18.91%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@cruzdanilo cruzdanilo force-pushed the fixes branch 2 times, most recently from acd0f14 to fcb7829 Compare January 30, 2026 22:31
Copy link

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

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

Devin Review found 1 new potential issue.

View issue and 7 additional flags in Devin Review.

Open in Devin Review

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/components/home/Home.tsx (1)

107-116: 🧹 Nitpick | 🔵 Trivial

Consider extracting the shared error predicate.

The same error condition (APIError with specific text values) is duplicated in both retry and suppressError. Extracting this into a helper function would reduce duplication and ensure both checks stay in sync.

♻️ Proposed refactor
+function isExpectedKYCError(error: unknown): boolean {
+  return (
+    error instanceof APIError &&
+    (error.text === "no kyc" || error.text === "not started" || error.text === "bad kyc")
+  );
+}
+
 const {
   data: KYCStatus,
   isFetched: isKYCFetched,
   refetch: refetchKYCStatus,
 } = useQuery({
   queryKey: ["kyc", "status"],
   queryFn: async () => getKYCStatus(),
-  retry: (_, error) =>
-    !(
-      error instanceof APIError &&
-      (error.text === "no kyc" || error.text === "not started" || error.text === "bad kyc")
-    ),
-  meta: {
-    suppressError: (error) =>
-      error instanceof APIError &&
-      (error.text === "no kyc" || error.text === "not started" || error.text === "bad kyc"),
-  },
+  retry: (_, error) => !isExpectedKYCError(error),
+  meta: { suppressError: isExpectedKYCError },
 });
🤖 Fix all issues with AI agents
In `@src/components/home/Home.tsx`:
- Around line 201-203: The exit animation isn't triggered because GettingStarted
sometimes returns null while still mounted; change the mount condition to the
parent by rendering <GettingStarted .../> only when it should be shown (e.g.,
use isKYCFetched && (isKYCApproved === false || !bytecode) or a new boolean like
shouldShowGettingStarted) inside the AnimatePresence wrapper and remove the
internal early "return null" path from the GettingStarted component (so
GettingStarted no longer mounts and unmounts silently); update references to
props isDeployed/hasKYC (or isKYCApproved/bytecode) to compute the show/hide
logic in Home.tsx and keep GettingStarted responsible only for its animated
content.

)}
{!isPendingKYC && <GettingStarted isDeployed={!!bytecode} hasKYC={isKYCApproved} />}
<AnimatePresence>
{isKYCFetched && <GettingStarted isDeployed={!!bytecode} hasKYC={isKYCApproved} />}

This comment was marked as outdated.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/components/home/Home.tsx (1)

107-116: 🧹 Nitpick | 🔵 Trivial

Consider extracting the error check to reduce duplication.

The same error text check ("no kyc", "not started", "bad kyc") is duplicated between retry and suppressError. Extract a helper predicate for consistency and maintainability.

♻️ Proposed refactor
+const isKYCPendingError = (error: unknown) =>
+  error instanceof APIError &&
+  (error.text === "no kyc" || error.text === "not started" || error.text === "bad kyc");
+
 const {
   data: KYCStatus,
   isFetched: isKYCFetched,
   refetch: refetchKYCStatus,
 } = useQuery({
   queryKey: ["kyc", "status"],
   queryFn: async () => getKYCStatus(),
-  retry: (_, error) =>
-    !(
-      error instanceof APIError &&
-      (error.text === "no kyc" || error.text === "not started" || error.text === "bad kyc")
-    ),
-  meta: {
-    suppressError: (error) =>
-      error instanceof APIError &&
-      (error.text === "no kyc" || error.text === "not started" || error.text === "bad kyc"),
-  },
+  retry: (_, error) => !isKYCPendingError(error),
+  meta: { suppressError: isKYCPendingError },
 });

Copy link

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

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

Devin Review found 1 new potential issue.

View issue and 8 additional flags in Devin Review.

Open in Devin Review

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In `@src/components/getting-started/GettingStarted.tsx`:
- Around line 26-38: The useOnboardingState hook (which calls useBytecode and
useQuery) is being invoked twice causing redundant hooks; update GettingStarted
to call useOnboardingState() once and pass the resulting { hasKYC, isDeployed }
into CurrentStep as props, then remove the duplicate useOnboardingState()
invocation from CurrentStep and change CurrentStep to accept these two props
instead of calling the hook itself; ensure any references to
useBytecode/useQuery remain only inside useOnboardingState and update prop
types/signature for CurrentStep accordingly.
- Line 29: The variable name returned from useQuery is using PascalCase
(KYCStatus); rename it to camelCase (kycStatus) in the destructuring of useQuery
in GettingStarted.tsx (const { data: kycStatus } = useQuery(...)) and update
every usage/reference in this file (including any JSX, conditionals, or
callbacks) to use kycStatus so it follows JS/TS naming conventions and remains
consistent with getKYCStatus and useQuery.

@cruzdanilo cruzdanilo merged commit 6839afd into main Feb 2, 2026
14 of 15 checks passed
@cruzdanilo cruzdanilo deleted the fixes branch February 2, 2026 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants