81496c775e
Build all frontend views using Go html/template with HTMX interactions and mobile-first CSS with dark mode and iPhone safe areas. Templates: - layout.html: base layout with fixed bottom nav (Dashboard, Issues, PRs, Settings) - dashboard.html: card-based triage view with priority indicators - issues.html: issue list with filter bar (org, state) and infinite scroll - pulls.html: PR list with diff stats and merge status - issue_detail.html: issue detail with comments, label assignment - pull_detail.html: PR detail with diff stats and review form - create_issue.html: issue creation form with searchable repo selector CSS (static/style.css): - Mobile-first dark mode with CSS variables - iPhone safe areas via env(safe-area-inset-bottom) - Responsive: 2-column grid at 640px+ breakpoint - Light mode support via prefers-color-scheme - Card, label, badge, form, button component styles - HTMX loading indicator and spinner animation - Reduced motion support HTMX patterns: - hx-get with hx-target for SPA-like navigation - hx-trigger="revealed" for infinite scroll - hx-post with hx-swap for inline form actions - Filter bar with hx-trigger="change" and hx-include Closes leeworks-agents/gitea-mobile#5 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
44 lines
1.2 KiB
HTML
44 lines
1.2 KiB
HTML
{{define "content"}}
|
|
<h1>{{.Issue.Title}}</h1>
|
|
|
|
<div class="card">
|
|
<div class="card-meta">
|
|
<span class="state-open">{{.Issue.State}}</span>
|
|
<span>{{.Issue.RepoOwner}}/{{.Issue.RepoName}} #{{.Issue.Number}}</span>
|
|
{{range .Issue.Labels}}
|
|
<span class="label" style="color:#{{.Color}};border:1px solid #{{.Color}}">{{.Name}}</span>
|
|
{{end}}
|
|
</div>
|
|
{{if .Issue.Body}}
|
|
<div class="card-body">{{.Issue.Body}}</div>
|
|
{{end}}
|
|
</div>
|
|
|
|
{{if .Comments}}
|
|
<h2>Comments</h2>
|
|
{{range .Comments}}
|
|
<div class="comment">
|
|
<div class="comment-header">
|
|
<strong>{{.User}}</strong>
|
|
<span>{{.CreatedAt}}</span>
|
|
</div>
|
|
<div class="comment-body">{{.Body}}</div>
|
|
</div>
|
|
{{end}}
|
|
{{end}}
|
|
|
|
<div class="card" style="margin-top:1rem;">
|
|
<h2>Actions</h2>
|
|
<form hx-post="/issues/{{.Issue.RepoOwner}}/{{.Issue.RepoName}}/{{.Issue.Number}}/labels" hx-swap="outerHTML" style="margin-bottom:0.5rem;">
|
|
<div class="filter-bar" style="margin-bottom:0.5rem;">
|
|
<select name="label_id">
|
|
{{range .AvailableLabels}}
|
|
<option value="{{.ID}}">{{.Name}}</option>
|
|
{{end}}
|
|
</select>
|
|
<button type="submit" class="btn btn-secondary" style="width:auto;padding:0.5rem 1rem;">Apply Label</button>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
{{end}}
|