refactor: extract reusable UI components#19
Merged
Conversation
Replace 7 private drag handle composables across sheets with a single reusable SheetDragHandle component that accepts an optional color parameter. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace 3 private selection indicator/checkbox composables on each platform with a shared SelectionIndicator that accepts size and iconSize parameters. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace private PropertyRow/OutfitPropertyRow implementations in detail sheets with a shared PropertyRow component on both platforms. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace 8+ gradient button variants across both platforms with a unified WornGradientButton component. Provides gradient presets (Save, Green, GreenCta, Indigo) and supports icons, loading, disabled states, and customizable shape/elevation. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace inline chip implementations across both platforms with a shared WornChip component. Used in CategoryFilterChips, SeasonSection, FitSection, MaterialSection, and SettingsScreen ChipGroup/MultiChipGroup. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace duplicated empty state layouts in WardrobeScreen and OutfitsScreen with a shared EmptyStateView that encapsulates the circle icon container, title, description, and optional action slot. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace duplicated error content in GapsScreen and TryItScreen with a shared ErrorContentView component on both Android (Compose) and iOS (SwiftUI). The component accepts a retryButtonColor parameter to support different accent colors per screen. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…ents Replace duplicated delete confirmation dialogs and selection headers in WardrobeScreen and OutfitsScreen with shared components on both platforms. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.
Summary
Extract 9 reusable UI components from duplicated code across Android (Compose) and iOS (SwiftUI) screens, aligning the codebase with the design system defined in
design/design.pen. This eliminates ~1,400 lines of duplicated UI code while adding ~1,900 lines of well-structured, reusable components with previews.Changes
Test plan
./gradlew :composeApp:assembleDebug— Android builds successfully./gradlew detekt— no lint issuesChecklist
./gradlew detektpasses🤖 Generated with Claude Code