Conversation
There was a problem hiding this comment.
Pull request overview
This PR delivers the “Discover V2” redesign, updating the Discover tab’s UI/UX and wiring new analytics + persistence needed to measure protocol engagement and browser/tab usage.
Changes:
- Adds a new Discover homepage layout (trending carousel, recents, dApps) with expanded section views and a protocol-details bottom sheet.
- Replaces the old UrlBar + BottomNavigation with a unified BottomNavigationBar and updates tab overview interactions.
- Introduces Discover analytics events and a persisted
recentProtocolsstore; extends backend protocol payloads for trending/background imagery.
Reviewed changes
Copilot reviewed 40 out of 42 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| src/services/backend.ts | Extends protocol response mapping to include backgroundUrl and isTrending. |
| src/services/analytics/index.ts | Exposes new Discover tracking helpers on the analytics facade. |
| src/services/analytics/discover.ts | Implements Discover-specific analytics events and source constants. |
| src/navigators/TabNavigator.tsx | Hydrates recentProtocols and fetches protocols on mount. |
| src/i18n/locales/pt/translations.json | Updates/extends Discover strings for the new UI. |
| src/i18n/locales/en/translations.json | Updates/extends Discover strings for the new UI. |
| src/hooks/useBrowserActions.ts | Adds Discover tracking for URL-bar navigation and tab close/all-close actions. |
| src/ducks/recentProtocols.ts | Adds persisted Zustand store for recently visited known protocols. |
| src/config/types.ts | Extends DiscoverProtocol with backgroundUrl + isTrending. |
| src/config/constants.ts | Adds storage key + renames browser animation duration constants. |
| src/config/analyticsConfig.ts | Registers new Discover analytics event names. |
| src/components/sds/Input/index.tsx | Extends input props to support controlled selection handling. |
| src/components/sds/Icon/index.tsx | Adds ChevronRightBold icon to the icon registry. |
| src/components/sds/Badge/index.tsx | Updates success badge color tokens to lime scale. |
| src/components/sds/App/index.tsx | Removes local app-logo fallback data; prefers protocol icons/favicons. |
| src/components/sds/App/data.ts | Removes embedded base64 SDS app logo dataset. |
| src/components/screens/HomeScreen/ManageAccounts.tsx | Makes navigation optional; adds showAddWallet toggle for reuse in Discover. |
| src/components/screens/HomeScreen/ManageAccountBottomSheet.tsx | Conditionally renders “Add wallet” button based on showAddWallet. |
| src/components/screens/DiscoveryScreen/components/index.ts | Updates component exports to new BottomNavigationBar. |
| src/components/screens/DiscoveryScreen/components/VerticalListSection.tsx | Adds vertical list section component for Recents/DApps preview. |
| src/components/screens/DiscoveryScreen/components/TrendingCarouselSection.tsx | Adds wrapper section around the trending carousel + title behavior. |
| src/components/screens/DiscoveryScreen/components/TabOverview.tsx | Redesigns tab overview footer/actions using a context menu. |
| src/components/screens/DiscoveryScreen/components/SectionTitle.tsx | Adds reusable tappable section header with chevron. |
| src/components/screens/DiscoveryScreen/components/ProtocolRow.tsx | Adds row UI for protocol list items with “Open” CTA. |
| src/components/screens/DiscoveryScreen/components/ProtocolDetailsBottomSheet.tsx | Adds protocol details bottom sheet prior to navigation. |
| src/components/screens/DiscoveryScreen/components/ExpandedSectionView.tsx | Adds full-screen expanded list view for sections. |
| src/components/screens/DiscoveryScreen/components/DiscoveryHomepage.tsx | Refactors homepage into Trending/Recents/DApps with expand + details flows. |
| src/components/screens/DiscoveryScreen/components/DiscoverWelcomeModal.tsx | Adds one-time welcome/onboarding modal for Discover. |
| src/components/screens/DiscoveryScreen/components/BottomNavigationBar.tsx | Implements unified bottom bar: avatar, back, url/search, menu, tab count. |
| src/components/screens/DiscoveryScreen/components/UrlBar.tsx | Removes old UrlBar component. |
| src/components/screens/DiscoveryScreen/components/BottomNavigation.tsx | Removes old BottomNavigation component. |
| src/components/screens/DiscoveryScreen/DiscoveryScreen.tsx | Integrates new nav bar, welcome modal, account switch sheet, and analytics hooks. |
| src/components/screens/BiometricsEnableScreen/BiometricsEnableScreen.tsx | Switches image import to centralized assets/images export. |
| src/components/TrendingCarousel.tsx | Adds reusable trending carousel + card rendering. |
| src/components/TrendingCardImage.tsx | Adds card background image handling with timeout + placeholder. |
| src/assets/images/iphone-frame.png | Adds/updates the iPhone frame image asset. |
| src/assets/images/index.ts | Centralizes image exports via images object. |
| src/assets/icons/chevron-right-bold.svg | Adds chevron-right-bold SVG asset. |
| tests/services/analytics/discover.test.ts | Adds unit coverage for new Discover analytics helpers. |
| tests/hooks/useBrowserActions.test.tsx | Updates tests to cover new Discover analytics behavior in browser actions. |
| tests/helpers/protocols.test.ts | Updates protocol fixtures for new DiscoverProtocol shape. |
| tests/ducks/protocols.test.ts | Updates protocol store tests for new DiscoverProtocol shape. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
src/components/screens/DiscoveryScreen/components/DiscoveryHomepage.tsx Outdated Show resolved Hide resolved
src/components/screens/DiscoveryScreen/components/TabOverview.tsx Outdated Show resolved Hide resolved
This reverts commit 851dc87.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 44 out of 46 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| // Fetch discover protocols and hydrate recent protocols store on mount | ||
| useEffect(() => { | ||
| fetchProtocols(); | ||
| useRecentProtocolsStore.persist.rehydrate(); | ||
| // eslint-disable-next-line react-hooks/exhaustive-deps |
There was a problem hiding this comment.
useRecentProtocolsStore is created with persist(...) and (without skipHydration) will auto-hydrate on store creation. Calling useRecentProtocolsStore.persist.rehydrate() here adds an extra AsyncStorage read on every TabNavigator mount and it also runs even when discoverEnabled is false. Consider removing this call, or (if manual hydration is truly required) set skipHydration: true in the store and only trigger/await a single rehydrate when Discover is enabled.
# Conflicts: # src/ducks/auth.ts
| Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
Summary
Complete redesign of the Discover tab.
Design Doc: https://docs.google.com/document/d/1u7Zw4DHzZBwVa6FdBgsg8P9yP2hkcKzubFHhtXAn2v0/edit?tab=t.0#heading=h.g63ji0xvvbbc
This redesign:
What
recentProtocols) persisting the last 5 visited known protocolssuccessvariant to match Figma's lime color scale (bg-lime-2 border-lime-6)Analytics events added
discover: protocol openedurl,protocol_name,source,is_known_protocoldiscover: protocol details viewedprotocol_name,tagsdiscover: protocol opened from detailsprotocol_name,urldiscover: tab createdtab_count,sourcediscover: tab closedtab_count,had_urldiscover: all tabs closedtab_countdiscover: welcome modal viewedSource values:
trending_carousel,recent_list,dapps_list,expanded_trending_list,expanded_recent_list,expanded_dapps_list,url_bar,tab_overview,automaticNew components
TrendingCarousel/TrendingCardImage— reusable carousel with image cardsBottomNavigationBar— replaces oldUrlBar+BottomNavigationDiscoveryHomepage— (refactored) homepage with trending, recents, dapps sectionsProtocolDetailsBottomSheet— protocol info overlayProtocolRow— individual protocol list itemVerticalListSection/ExpandedSectionView— collapsible/expandable list sectionsTrendingCarouselSection/SectionTitle— section wrappersDiscoverWelcomeModal— one-time onboarding modalRemoved components
UrlBar— merged intoBottomNavigationBarBottomNavigation— replaced byBottomNavigationBarApp/data.ts— removed hardcoded dApp logos (now fetched from backend)Known limitations
currently forced as trending(temporary until this kube PR withis_trendingproperty is deployed)Test plan
Checklist
PR structure
Testing
Release