gitea plug
This commit is contained in:
1 parent
86508ffcca
commit
dd1afbbeb2
6 files changed
+1650
-30
No files matched your search
@@ -15,42 +15,64 @@
|
||||
- [x] Welcome view + accounts management form
|
||||
- [x] Connection test against `/api/v1/user`
|
||||
|
||||
## Phase 2 — issue reader (next)
|
||||
## Phase 2 — issue reader ✅
|
||||
|
||||
- [ ] **Issue list view** in the overlay:
|
||||
- Search box (`q` parameter)
|
||||
- [x] **Issue list view** in the overlay:
|
||||
- Search box (`q` parameter, debounced 350ms)
|
||||
- State filter (open/closed/all)
|
||||
- Owner/team filter (optional dropdown)
|
||||
- Pagination (reuse pattern from email plugin)
|
||||
- Pagination (prev/next, hasMore heuristic since Gitea doesn't always return total)
|
||||
- Each row: title, repo path, state badge, labels, author, age
|
||||
- [ ] **Issue detail view** (right pane):
|
||||
- Subject + state + labels + assignees + milestone
|
||||
- Body (markdown rendered with the existing core renderer)
|
||||
- Comments list (each with author + timestamp)
|
||||
- [x] **Issue detail view** (right pane):
|
||||
- Subject + state badge + labels + #number + repo
|
||||
- Body (markdown rendered via `hyprcrd.markdown.render` — exposed by core)
|
||||
- Comments list (each with author + relative timestamp + rendered markdown)
|
||||
- "Open on Gitea" link button
|
||||
- [ ] **Extract → card**:
|
||||
- Card title = issue title
|
||||
- Card body = markdown with metadata header + body + comments + `#gitea` `#issue` tags
|
||||
- Optionally store backref `(account_id, owner, repo, index)` in a
|
||||
`gitea_issue_links` table for later sync
|
||||
- [x] **Extract → card**:
|
||||
- Card title = `[repo#number] title`
|
||||
- Card body = metadata header + body + comments + `#gitea #issue` tags
|
||||
- Color: green (#22c55e)
|
||||
- [ ] **Issue → card backlink** in a `gitea_issue_links` table — needed
|
||||
for Phase 5 bidirectional sync
|
||||
|
||||
## Phase 3 — write operations
|
||||
|
||||
- [ ] **Add comment** from the detail view
|
||||
- [ ] **Close / reopen** issue
|
||||
- [ ] **Edit title / body** (only for the issue creator)
|
||||
- [ ] **Set labels** (need to fetch repo labels, multi-select UI)
|
||||
- [ ] **Set assignees** (typeahead from repo collaborators)
|
||||
- [ ] **Set milestone**
|
||||
- [ ] **Set due date**
|
||||
- [x] **Add comment** — composer textarea always visible at the bottom of the
|
||||
detail pane. Ctrl/Cmd+Enter posts. New comment is appended to local state
|
||||
and re-rendered immediately.
|
||||
- [x] **Close / reopen** — single button in the action bar that toggles state.
|
||||
Updates the badge, button label, and the row in the list.
|
||||
- [x] **Edit title** — pencil icon next to the title swaps to an inline input.
|
||||
Enter saves, Escape cancels. PATCH `/issues/{index}`.
|
||||
- [x] **Edit body** — pencil icon next to the body swaps to a textarea.
|
||||
Ctrl/Cmd+Enter saves, Escape cancels.
|
||||
- [x] **Set labels** — tag icon opens an inline editor that fetches the repo's
|
||||
label list (`GET /api/gitea/repo/.../labels`) and shows checkboxes with
|
||||
original colors. Save uses `PUT /issues/{index}/labels`.
|
||||
- [ ] **Set assignees** — needs a collaborator typeahead (next round, see
|
||||
TODO Phase 3.5)
|
||||
- [ ] **Set milestone** — needs milestone fetch + dropdown (next round)
|
||||
- [ ] **Set due date** — date picker (next round)
|
||||
|
||||
## Phase 3.5 — remaining metadata
|
||||
|
||||
- [ ] `GET /api/gitea/repo/{accId}/{owner}/{repo}/milestones`
|
||||
- [ ] `GET /api/gitea/repo/{accId}/{owner}/{repo}/collaborators`
|
||||
- [ ] Milestone dropdown in detail view
|
||||
- [ ] Assignee multi-select with typeahead
|
||||
- [ ] Due date input + clear button
|
||||
|
||||
## Phase 4 — create issues
|
||||
|
||||
- [ ] **"new issue" button** in the overlay
|
||||
- [x] **"new issue" button** in the list toolbar
|
||||
- [x] **Repo picker** loaded from `/user/repos` (cached per account, filtered
|
||||
to non-archived repos with push permission)
|
||||
- [x] **Title + body + labels** form
|
||||
- [x] **Submit** creates via POST `/repo/{accId}/{owner}/{repo}/issues`,
|
||||
refreshes list, auto-opens the new issue in the detail view
|
||||
- [ ] **Create from card**: a card → push as new gitea issue, store the
|
||||
backref so future edits can sync both ways
|
||||
backref so future edits can sync both ways (Phase 5)
|
||||
- [ ] **Pre-fill template** from a repo's `.gitea/ISSUE_TEMPLATE.md`
|
||||
if available
|
||||
if available (next round)
|
||||
|
||||
## Phase 5 — bidirectional sync (the killer feature)
|
||||
|
||||
|
||||
Reference in new issue
Block a user