tangled
alpha
login
or
join now
tjh.dev
/
test
forked from
tangled.org/core
0
fork
atom
Mirror of @tangled.org/core. Running on a Raspberry Pi Zero 2 (Please be gentle).
0
fork
atom
overview
issues
pulls
pipelines
use cards
oppi.li
11 months ago
bc9ee4ef
0158248f
+9
-96
1 changed file
expand all
collapse all
unified
split
appview
pages
templates
user
profile.html
+9
-96
appview/pages/templates/user/profile.html
···
10
10
{{ block "collaboratingRepos" . }}{{ end }}
11
11
</div>
12
12
<div class="md:col-span-2 order-3 md:order-3">
13
13
-
{{ block "profileTimeline2" . }}{{ end }}
13
13
+
{{ block "profileTimeline" . }}{{ end }}
14
14
</div>
15
15
</div>
16
16
{{ end }}
17
17
18
18
-
{{ define "profileTimeline2" }}
18
18
+
{{ define "profileTimeline" }}
19
19
<p class="text-sm font-bold py-2 dark:text-white">ACTIVITY</p>
20
20
<div class="flex flex-col gap-6 relative">
21
21
{{ with .ProfileTimeline }}
22
22
{{ range $idx, $byMonth := .ByMonth }}
23
23
{{ with $byMonth }}
24
24
-
<div>
24
24
+
<div class="bg-white dark:bg-gray-800 px-6 py-4 rounded drop-shadow-sm">
25
25
{{ if eq $idx 0 }}
26
26
<p class="text-sm font-bold py-2 dark:text-white">This month</p>
27
27
{{ else }}
···
55
55
<details open>
56
56
<summary class="list-none cursor-pointer">
57
57
<div class="flex items-center gap-2">
58
58
-
{{ i "unfold-vertical" "w-4 h-4" }}
59
59
-
created {{ len $items }} repositories
58
58
+
created {{ len $items }} {{if eq (len $items) 1 }}repository{{else}}repositories{{end}}
60
59
</div>
61
60
</summary>
62
62
-
<div class="p-2 pl-8 text-sm flex flex-col gap-3">
61
61
+
<div class="p-2 text-sm flex flex-col gap-3">
63
62
{{ range $items }}
64
63
<div class="flex flex-wrap items-center gap-2">
65
64
<span class="text-gray-500 dark:text-gray-400">
···
89
90
<details open>
90
91
<summary class="list-none cursor-pointer">
91
92
<div class="flex items-center gap-2">
92
92
-
{{ i "unfold-vertical" "w-4 h-4" }}
93
93
<span>
94
94
-
created {{ len $items }} issues
94
94
+
created {{ len $items }} {{if eq (len $items) 1 }}issue{{else}}issues{{end}}
95
95
</span>
96
96
<span class="px-2 py-1/2 text-sm rounded-sm text-white bg-green-600 dark:bg-green-700">
97
97
{{$stats.Open}} open
···
100
102
</span>
101
103
</div>
102
104
</summary>
103
103
-
<div class="p-2 pl-8 text-sm flex flex-col gap-3">
105
105
+
<div class="p-2 text-sm flex flex-col gap-3">
104
106
{{ range $items }}
105
107
{{ $repoOwner := index $handleMap .Metadata.Repo.Did }}
106
108
{{ $repoName := .Metadata.Repo.Name }}
···
141
143
<details open>
142
144
<summary class="list-none cursor-pointer">
143
145
<div class="flex items-center gap-2">
144
144
-
{{ i "unfold-vertical" "w-4 h-4" }}
145
146
<span>
146
146
-
created {{ len $items }} pull requests
147
147
+
created {{ len $items }} {{if eq (len $items) 1 }}pull request{{else}}pull requests{{end}}
147
148
</span>
148
149
<span class="px-2 py-1/2 text-sm rounded-sm text-white bg-green-600 dark:bg-green-700">
149
150
{{$stats.Open}} open
···
155
158
</span>
156
159
</div>
157
160
</summary>
158
158
-
<div class="p-2 pl-8 text-sm flex flex-col gap-3">
161
161
+
<div class="p-2 text-sm flex flex-col gap-3">
159
162
{{ range $items }}
160
163
{{ $repoOwner := index $handleMap .Repo.Did }}
161
164
{{ $repoName := .Repo.Name }}
···
189
192
</div>
190
193
</details>
191
194
{{ end }}
192
192
-
{{ end }}
193
193
-
194
194
-
{{ define "profileTimeline" }}
195
195
-
<div class="flex flex-col gap-3 relative">
196
196
-
<p class="px-6 text-sm font-bold py-2 dark:text-white">ACTIVITY</p>
197
197
-
{{ range .ProfileTimeline }}
198
198
-
{{ if eq .Type "issue" }}
199
199
-
<div class="px-6 py-2 bg-white dark:bg-gray-800 rounded drop-shadow-sm w-fit max-w-full flex items-center gap-2">
200
200
-
{{ $textColor := "text-gray-800 dark:text-gray-400" }}
201
201
-
{{ $icon := "ban" }}
202
202
-
{{ if .Issue.Open }}
203
203
-
{{ $textColor = "text-green-600 dark:text-green-500" }}
204
204
-
{{ $icon = "circle-dot" }}
205
205
-
{{ end }}
206
206
-
<div class="p-1 {{ $textColor }}">
207
207
-
{{ i $icon "w-5 h-5" }}
208
208
-
</div>
209
209
-
<div>
210
210
-
<p class="text-gray-600 dark:text-gray-300">
211
211
-
<a href="/{{ index $.DidHandleMap .Repo.Did }}/{{ .Repo.Name }}/issues/{{ .Issue.IssueId }}" class="no-underline hover:underline">{{ .Issue.Title }} <span class="text-gray-500 dark:text-gray-400">#{{ .Issue.IssueId }}</span></a>
212
212
-
on
213
213
-
<a href="/{{ index $.DidHandleMap .Repo.Did }}/{{ .Repo.Name }}" class="no-underline hover:underline">{{ index $.DidHandleMap .Repo.Did }}<span class="select-none">/</span>{{ .Repo.Name }}</a>
214
214
-
<time class="text-gray-700 dark:text-gray-400 text-xs ml-2">{{ .Issue.Created | shortTimeFmt }}</time>
215
215
-
</p>
216
216
-
</div>
217
217
-
</div>
218
218
-
{{ else if eq .Type "pull" }}
219
219
-
<div class="px-6 py-2 bg-white dark:bg-gray-800 rounded drop-shadow-sm w-fit flex items-center gap-3">
220
220
-
{{ $textColor := "text-gray-800 dark:text-gray-400" }}
221
221
-
{{ $icon := "git-pull-request-closed" }}
222
222
-
{{ if .Pull.State.IsOpen }}
223
223
-
{{ $textColor = "text-green-600 dark:text-green-500" }}
224
224
-
{{ $icon = "git-pull-request" }}
225
225
-
{{ else if .Pull.State.IsMerged }}
226
226
-
{{ $textColor = "text-purple-600 dark:text-purple-500" }}
227
227
-
{{ $icon = "git-merge" }}
228
228
-
{{ end }}
229
229
-
<div class="{{ $textColor }} p-1">
230
230
-
{{ i $icon "w-5 h-5" }}
231
231
-
</div>
232
232
-
<div>
233
233
-
<p class="text-gray-600 dark:text-gray-300">
234
234
-
<a href="/{{ index $.DidHandleMap .Repo.Did }}/{{ .Repo.Name }}/pulls/{{ .Pull.PullId }}" class="no-underline hover:underline">{{ .Pull.Title }} <span class="text-gray-500 dark:text-gray-400">#{{ .Pull.PullId }}</span></a>
235
235
-
on
236
236
-
<a href="/{{ index $.DidHandleMap .Repo.Did }}/{{ .Repo.Name }}" class="no-underline hover:underline">
237
237
-
{{ index $.DidHandleMap .Repo.Did }}<span class="select-none">/</span>{{ .Repo.Name }}</a>
238
238
-
<time class="text-gray-700 dark:text-gray-400 text-xs ml-2">{{ .Pull.Created | shortTimeFmt }}</time>
239
239
-
</p>
240
240
-
</div>
241
241
-
</div>
242
242
-
{{ else if eq .Type "repo" }}
243
243
-
<div class="px-6 py-2 bg-white dark:bg-gray-800 rounded drop-shadow-sm w-fit flex items-center gap-3">
244
244
-
{{ if .Source }}
245
245
-
<div class="text-gray-800 dark:text-gray-400 p-1">
246
246
-
{{ i "git-fork" "w-5 h-5" }}
247
247
-
</div>
248
248
-
{{ else }}
249
249
-
<div class="text-gray-800 dark:text-gray-400 p-1">
250
250
-
{{ i "book-plus" "w-5 h-5" }}
251
251
-
</div>
252
252
-
{{ end }}
253
253
-
<div>
254
254
-
<p class="text-gray-600 dark:text-gray-300">
255
255
-
256
256
-
{{ if .Source }}
257
257
-
forked
258
258
-
<a href="/{{ index $.DidHandleMap .Source.Did }}/{{ .Source.Name }}" class="no-underline hover:underline">
259
259
-
{{ index $.DidHandleMap .Source.Did }}/{{ .Source.Name }}
260
260
-
</a>
261
261
-
to
262
262
-
<a href="/{{ didOrHandle $.UserHandle $.UserDid }}/{{ .Repo.Name }}" class="no-underline hover:underline">{{ .Repo.Name }}</a>
263
263
-
{{ else }}
264
264
-
created
265
265
-
<a href="/{{ index $.DidHandleMap .Repo.Did }}/{{ .Repo.Name }}" class="no-underline hover:underline">{{ .Repo.Name }}</a>
266
266
-
{{ end }}
267
267
-
<time class="text-gray-700 dark:text-gray-400 text-xs ml-2">{{ .Repo.Created | shortTimeFmt }}</time>
268
268
-
</p>
269
269
-
</div>
270
270
-
</div>
271
271
-
{{ end }}
272
272
-
{{ else }}
273
273
-
<p class="px-6 dark:text-white">This user does not have any activity yet.</p>
274
274
-
{{ end }}
275
275
-
</div>
276
195
{{ end }}
277
196
278
197
{{ define "profileCard" }}