common-adapters: remove unused/narrow-use components#29260
Merged
chrisnojima merged 1 commit intoMay 29, 2026
Conversation
Contributor
chrisnojima
commented
May 29, 2026
- Delete TeamWithPopup (unused everywhere)
- Delete timeline-marker.meta.tsx (single color constant, inlined)
- Move TimelineMarker to system-git-push/ (only caller)
- Move PlatformIcon to profile/ (only callers are in profile/)
- Remove BottomSheetModal/Backdrop/ScrollView from index (only used internally in popup/, not via Kb.*)
- Remove ProfileCard from index (wired internally, never imported externally)
- Box2Animated removed; callers use createAnimatedComponent(Kb.Box2) or Animated.createAnimatedComponent(Kb.Box2) locally
- Remove dead ReAnimated={} export from index
- Remove duplicate ConnectedNameWithIcon alias (same as NameWithIcon)
- box.tsx: import Reanimated from ./reanimated instead of directly from react-native-reanimated
- Delete TeamWithPopup (unused everywhere)
- Delete timeline-marker.meta.tsx (single color constant, inlined)
- Move TimelineMarker to system-git-push/ (only caller)
- Move PlatformIcon to profile/ (only callers are in profile/)
- Remove BottomSheetModal/Backdrop/ScrollView from index (only used
internally in popup/, not via Kb.*)
- Remove ProfileCard from index (wired internally, never imported
externally)
- Box2Animated removed; callers use createAnimatedComponent(Kb.Box2)
or Animated.createAnimatedComponent(Kb.Box2) locally
- Remove dead ReAnimated={} export from index
- Remove duplicate ConnectedNameWithIcon alias (same as NameWithIcon)
- box.tsx: import Reanimated from ./reanimated instead of directly
from react-native-reanimated
There was a problem hiding this comment.
Pull request overview
This PR cleans up shared/common-adapters by removing unused/internal components from the public index and relocating narrow-use components closer to their callers. The goal is to reduce the surface area of the Kb.* namespace and clarify ownership of each component.
Changes:
- Delete
TeamWithPopupand thetimeline-marker.meta.tsxcolor constant; moveTimelineMarkerintosystem-git-push/andPlatformIconintoprofile/. - Trim
common-adapters/index.tsx(dropBox2Animated,ConnectedNameWithIcon,PlatformIcon,ProfileCard,TimelineMarker,TeamWithPopup,BottomSheet*, deadReAnimated={}); update callers to useKb.NameWithIconor locally-builtAnimated.createAnimatedComponent(Kb.Box2). - Drop the unused direct
react-native-reanimatedimport inbox.tsxalong withBox2Animated.
Reviewed changes
Copilot reviewed 17 out of 17 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| shared/common-adapters/index.tsx | Removes unused/internal exports from the public index. |
| shared/common-adapters/box.tsx | Removes Box2Animated and the direct reanimated import it required. |
| shared/common-adapters/team-with-popup.tsx | Deletes the unused component. |
| shared/common-adapters/timeline-marker.meta.tsx | Deletes the single-constant meta file. |
| shared/chat/conversation/messages/system-git-push/timeline-marker.tsx | Relocated TimelineMarker; inlines the color constant and imports Box2 from @/common-adapters. |
| shared/chat/conversation/messages/system-git-push/container.tsx | Uses the local TimelineMarker import. |
| shared/profile/platform-icon.tsx | Renames Render to PlatformIcon and imports Box2/IconAuto/ImageIcon/IconType from @/common-adapters. |
| shared/profile/pgp/choice/index.tsx, shared/profile/generic/proofs-list.tsx | Switch to importing PlatformIcon directly from @/profile/platform-icon. |
| shared/chat/audio/audio-recorder.native.tsx | Replaces Kb.Box2Animated with a local Animated.createAnimatedComponent(Kb.Box2). |
| shared/team-building/service-tab-bar.tsx | Replaces Kb.Box2Animated with createAnimatedComponent(Kb.Box2). |
| shared/team-building/user-bubble.tsx, shared/people/follow-suggestions.tsx, shared/teams/team/menu-container.tsx, shared/router-v2/tab-bar.desktop.tsx, shared/profile/user/index.tsx, shared/chat/conversation/info-panel/header.tsx | Replace Kb.ConnectedNameWithIcon with Kb.NameWithIcon after the duplicate alias was removed. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
49971c9
into
nojima/HOTPOT-next-670-clean-2
1 of 2 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.