Android: split large UI files into per-component files#262
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Refactors the Android UI layer by extracting previously inlined Compose UI blocks and formatting/date helpers into dedicated component and utility files, reducing screen file sizes while keeping behavior the same.
Changes:
- Extracts task list UI pieces (group header, task item, chips) into
ui/components/. - Extracts task form sections (date/time picker, recurrence, scheduling, notifications) into
ui/components/and date/time helpers intoui/utils/. - Extracts navigation route definitions into
ui/navigation/Routes.ktand updatesAppNavigationimports accordingly.
Reviewed changes
Copilot reviewed 16 out of 16 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| android/app/src/main/java/com/dkhalife/tasks/ui/utils/TaskFormatters.kt | New shared task/due-date/recurrence formatting helpers extracted from screens. |
| android/app/src/main/java/com/dkhalife/tasks/ui/utils/DateTimeUtils.kt | New shared ISO parse/format and display formatting helpers for ZonedDateTime. |
| android/app/src/main/java/com/dkhalife/tasks/ui/screen/TaskListScreen.kt | Slims screen by delegating list row UI to extracted components. |
| android/app/src/main/java/com/dkhalife/tasks/ui/screen/TaskFormScreen.kt | Slims screen by delegating recurrence/scheduling/notifications UI to extracted sections and shared date utils. |
| android/app/src/main/java/com/dkhalife/tasks/ui/screen/LabelsScreen.kt | Slims screen by delegating label row + dialog UI to extracted components. |
| android/app/src/main/java/com/dkhalife/tasks/ui/navigation/Routes.kt | New centralized navigation routes + bottom-nav screen metadata. |
| android/app/src/main/java/com/dkhalife/tasks/ui/navigation/AppNavigation.kt | Updates navigation to use extracted Screen/Routes and trims imports. |
| android/app/src/main/java/com/dkhalife/tasks/ui/components/TaskItem.kt | New extracted task card component with actions and chips. |
| android/app/src/main/java/com/dkhalife/tasks/ui/components/TaskChips.kt | New extracted chip components (due date, recurrence, notifications, label). |
| android/app/src/main/java/com/dkhalife/tasks/ui/components/SchedulingSection.kt | New extracted scheduling preferences + end date UI section. |
| android/app/src/main/java/com/dkhalife/tasks/ui/components/RecurrenceSection.kt | New extracted recurrence selector UI section. |
| android/app/src/main/java/com/dkhalife/tasks/ui/components/NotificationsSection.kt | New extracted notifications toggles UI section. |
| android/app/src/main/java/com/dkhalife/tasks/ui/components/LabelItem.kt | New extracted label list row component. |
| android/app/src/main/java/com/dkhalife/tasks/ui/components/LabelDialog.kt | New extracted create/edit label dialog. |
| android/app/src/main/java/com/dkhalife/tasks/ui/components/GroupHeader.kt | New extracted collapsible group header row component. |
| android/app/src/main/java/com/dkhalife/tasks/ui/components/DateTimePickerRow.kt | New extracted two-step date+time picker row component. |
android/app/src/main/java/com/dkhalife/tasks/ui/navigation/AppNavigation.kt
Outdated
Show resolved
Hide resolved
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
Break down large Android UI files so each component lives in its own file.
New files - ui/components/
New files - ui/utils/
New files - ui/navigation/
Reduced files
No functional changes - purely structural.