- Branch/tag tap opens one screen with swipeable Files/History tabs (Route.BranchDetail replaces Route.CodeBrowser/Route.History)
- Repository rows show last-commit time; repository All/Favorites tabs are swipeable
- Fix overlapping commit-detail layout (BoxWithConstraints sibling stacking)
- Fix BranchDetailScreen tab row jammed against status bar
- Fix diff view horizontal scroll not working
- Simplify references-loading message; remove in-app back buttons in favor of system back gesture; replace manual refresh buttons with pull-to-refresh
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Live, iterative round of changes driven by the human product owner
testing on their own device over wireless adb:
- Tapping a branch/tag opens commit history instead of the file browser
- Selected reference row is color-coded instead of a text label
- Branch/tag rows and commit rows show commit date/time with time zone
- Tapping a changed file shows a parsed before/after diff, client-side
(new UnifiedDiffParser, no extra network call)
- The two diff panels scroll vertically in sync and share one
horizontal scroll position
- Diff lines are colored by text only (red/green)
- On a >=600dp-wide screen (a Z Fold's inner screen unfolded) the file
list and selected diff show side by side
- Removed the branch/tag compare feature entirely, per direct request
Also fixes a real bug found via live device debugging: getCommitDetail
requested the wrong URL path (missing "git/"), causing every commit
tap to 404.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Gitea's Go handlers serialize a nil slice as the JSON literal `null`
rather than `[]` for some list endpoints when there are no items
(e.g. a repository with no branches). parseList treated that as a
parse failure and threw ApiFailure.InvalidResponse, surfacing as a
misleading "server error" on a completely successful 200 OK.
Diagnosed live against the human product owner's real Gitea instance
via wireless adb (repositories CSOT-T8-iPTN-AMA / CSOT-T8-MACRO_SA):
confirmed via the Gitea container's own request log that the call
was a genuine 200 OK, then used temporary debug-only logging to
narrow the cause to the literal null body. Fixed at the shared
parseList helper so every sibling list endpoint benefits, not just
the one that was reported.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Continues Codex's paused in-progress fix in this worktree (confirmed
safe to pick up by the human product owner). A missing or malformed
branch commit timestamp no longer fails the whole branch page; the
latest-branch picker now filters to branches with a known timestamp
before selecting the max, and reports Failed (not Empty) when none
are known. Adds the one missing test case from the in-progress
coverage (all branches with unknown timestamps) plus an explicit
test proving the reference screen never depended on the field.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Fixes the recorded P3 CodeBrowserViewModel Main-dispatcher issue,
scans the whole repo for secrets, and reviews the manifest/backup/
token-storage security posture. Minification and any authenticated-
screen device regression are explicitly left blocked: this agent
cannot enter a password to complete Gitea login, confirmed with the
human product owner rather than silently skipped.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Signed-in users can view notifications (unread-only or all), paginated,
and jump from an issue/PR notification to that repository's work items.
No mark-read/unread/pinned write endpoint is exposed, matching the
existing single-write-scope posture from ADR-004.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Adds read-only GET /user/orgs and GET /orgs/{org}/repos to
GiteaRepositoryBrowserApi (a third interface, OrganizationsRepository),
reusing existing repository mapping rather than duplicating it.
Repository list gains an organization filter chip row (all + one per
org), keeping the existing recent-push sort and paging. Organizations
are fetched once per session and cached; a failure to load them
degrades to an empty filter row instead of blocking the repository
list itself. Filtering only applies to the all-repositories mode,
since Gitea star is not organization-scoped.
Closes MVP outcome #2 in docs/product.md. No task file existed
beforehand; created it first per AGENTS.md.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Replace MainActivity's three independent booleans (browsingCode/
browsingHistory/browsingWorkItems) with one typed List<Route> back
stack, restorable through configuration change and process death.
Route holds only stable primitives (owner/name/ref/ref-kind), never
tokens or content. A genuine LIFO stack, not just a refactor: back now
correctly unwinds through arbitrarily nested screens instead of
relying on which boolean happened to still be true underneath another.
No task file existed for this task beforehand (only proposed in an
earlier handoff document); created it first per AGENTS.md.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Separate issue and PR list/detail tabs, paginated, with comments
(issues) and reviews+comments (PRs). Deleted/unavailable authors
render a fixed placeholder instead of crashing or inventing identity;
every status is a text label, never color-only.
Reuses TASK-010 directly; no shared/domain file touched. Both list
types dedupe by number per page. Entry point is a new button on the
repository references screen.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Paginated commit history for the current ref, commit detail with
distinguished added/modified/deleted/renamed file status, bounded and
explicitly-truncated patch text, and a ref comparison flow validating
one entered ref against the currently open ref as base.
Reuses TASK-004's listCommits and this session's own TASK-009
HistoryRepository; no shared/domain file touched. Entry point is a new
history button on the existing code browser header.
Self-review caught and fixed a bug before writing tests: a failed
commit-detail fetch discarded which commit had failed, so retry
silently reloaded the whole list instead of re-fetching the commit the
user tried to open.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Implemented directly at human product owner's direction, independent
of Codex's separate uncommitted attempt at the same task (not read or
referenced here).
- CommitDetail (reusing CommitSummary) with per-file added/modified/
deleted/renamed/other status; deleted-author and missing-rename-path
cases handled without crashing or inventing data.
- BoundedPatch for commit and comparison diffs, sourced from Gitea's
.diff raw-text endpoints (JSON commit/compare objects only carry
file status, not diff content); byte limit then line limit, both
constructor-injected and validated positive.
- Comparison uses one combined base...head path segment, built by
concatenating both refs before a single addPathSegment call so each
is escaped exactly once; pagination computed locally since Gitea's
compare endpoint has no server-side paging.
- Reuses Page<T> and ApiFailure; no put/delete/postForm call anywhere
in the file (read-only, as required).
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Frozen domain/data contracts for issues, pull requests, reviews, and
comments so TASK-008's UI can be built without touching shared layers.
- Separate immutable IssueSummary/Detail and PullRequestSummary/Detail
models; WorkItemAuthor.Unavailable instead of inventing an identity
for deleted/null authors.
- PullRequestState derived from Gitea's merged flag + open/closed
state (no single field already encodes "merged").
- listIssues drops entries with a non-null pull_request field so
Gitea's issue-list endpoint (which also returns PRs) never
duplicates listPullRequests, done client-side rather than trusting
an unverified query parameter.
- Reuses existing Page<T> and ApiFailure rather than new parallel
types. Read-only: no put/delete/postForm call anywhere in the file.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
TASK-018, human product owner priority-1 request. Adds write:user
OAuth scope (ADR-004) and relaxes OAuthClientConfig's read-only guard
to an explicit, hard-coded write-scope allow-list rather than a
general write-scope allowance. GiteaRepositoryBrowserApi gains star/
unstar/listStarred via a new RepositoryFavorites interface, reusing
its existing repository mapping. RepositoryListViewModel tracks an
ALL/FAVORITES mode; toggling favorite confirms against the server
before updating UI state rather than acting optimistically.
No create/edit/merge/close/comment endpoint is introduced. Favorite
state is never cached locally.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
TASK-017, human product owner priority-1 request. Repository list now
requests sort=updated&order=desc from Gitea, loads 5 repositories per
page with explicit prev/next navigation, and each visible row
independently fetches and shows its most recently committed branch.
Removes the legacy eager-loading RepositoryListApi in favor of the
existing paged GiteaRepositoryBrowser.listRepositories. Fixes two
issues found in self-review: missing error handling on page
navigation, and repositories with no default branch (empty repos)
previously failing the whole page instead of just that row.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Independent read-only review of 8a47d30/bbbff77/16c46a5 per
handoff/claude-master-handoff.md's review-and-freeze step. Verified
build/test/lint independently rather than trusting recorded evidence.
Fixed P2: requireSuccess() collapsed HTTP 409/422 into the generic
InvalidResponse, which would have blocked TASK-007's planned
conflict/unprocessable error states. Added ApiFailure.Conflict and
ApiFailure.Unprocessable with test coverage.
Recorded a P3 (CPU-bound work on the Main dispatcher in
CodeBrowserViewModel) for TASK-016 rather than fixing it now. Closed
TASK-005/006's mutual contract-freeze checkboxes. No P0/P1 found.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Pure-Kotlin classifier for feature/codebrowser/content/ that turns
already-loaded SourceContent bytes into bounded text, binary, Git LFS
pointer, unsupported-encoding, or oversized results with caller-supplied
positive byte/character/line limits, per handoff/task-006a-ready.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>