tangled
alpha
login
or
join now
vielle.dev
/
pdsls
forked from
pds.ls/pdsls
0
fork
atom
atproto explorer
0
fork
atom
overview
issues
pulls
pipelines
repo collection list redesign
juli.ee
5 months ago
0de5d905
3217321f
verified
This commit was signed with the committer's
known signature
.
juli.ee
SSH Key Fingerprint:
SHA256:mBrT4x0JdzLpbVR95g1hjI1aaErfC02kmLRkPXwsYCk=
+29
-58
2 changed files
expand all
collapse all
unified
split
src
views
pds.tsx
repo.tsx
+1
-1
src/views/pds.tsx
···
52
52
<div class="flex items-center">
53
53
<A
54
54
href={`/at://${repo.did}`}
55
55
-
class="grow truncate rounded py-0.5 font-mono text-blue-400 hover:bg-neutral-200 active:bg-neutral-300 dark:hover:bg-neutral-700 dark:active:bg-neutral-600"
55
55
+
class="grow truncate rounded py-0.5 font-mono hover:bg-neutral-200 active:bg-neutral-300 dark:hover:bg-neutral-700 dark:active:bg-neutral-600"
56
56
>
57
57
{repo.did}
58
58
</A>
+28
-57
src/views/repo.tsx
···
130
130
setDownloading(false);
131
131
};
132
132
133
133
-
const toggleCollection = (authority: string) => {
134
134
-
setNsids({
135
135
-
...nsids(),
136
136
-
[authority]: { ...nsids()![authority], hidden: !nsids()![authority].hidden },
137
137
-
});
138
138
-
};
139
139
-
140
133
return (
141
134
<Show when={repo()}>
142
135
<div class="flex w-full flex-col gap-2 break-words">
···
226
219
onInput={(e) => setFilter(e.currentTarget.value)}
227
220
class="grow"
228
221
/>
229
229
-
<div class="flex flex-col font-mono">
230
230
-
<div class="grid grid-cols-[min-content_1fr] items-center gap-x-2 overflow-hidden text-sm">
231
231
-
<For
232
232
-
each={Object.keys(nsids() ?? {}).filter((authority) =>
233
233
-
filter() ?
234
234
-
authority.startsWith(filter()!) || filter()?.startsWith(authority)
235
235
-
: true,
236
236
-
)}
237
237
-
>
238
238
-
{(authority) => (
239
239
-
<>
240
240
-
<button onclick={() => toggleCollection(authority)} class="flex items-center">
241
241
-
<span
242
242
-
classList={{
243
243
-
"iconify lucide--chevron-down text-lg transition-transform": true,
244
244
-
"-rotate-90": nsids()?.[authority].hidden,
245
245
-
}}
246
246
-
></span>
247
247
-
</button>
248
248
-
<button
249
249
-
class="bg-transparent text-left wrap-anywhere"
250
250
-
onclick={() => toggleCollection(authority)}
251
251
-
>
252
252
-
{authority}
253
253
-
</button>
254
254
-
<Show when={!nsids()?.[authority].hidden}>
255
255
-
<div></div>
256
256
-
<div class="flex flex-col">
257
257
-
<For
258
258
-
each={nsids()?.[authority].nsids.filter((nsid) =>
259
259
-
filter() ?
260
260
-
nsid.startsWith(filter()!.split(".").slice(2).join("."))
261
261
-
: true,
262
262
-
)}
263
263
-
>
264
264
-
{(nsid) => (
265
265
-
<A
266
266
-
href={`/at://${did}/${authority}.${nsid}`}
267
267
-
class="text-blue-400 hover:underline active:underline"
268
268
-
>
269
269
-
{authority}.{nsid}
270
270
-
</A>
271
271
-
)}
272
272
-
</For>
273
273
-
</div>
274
274
-
</Show>
275
275
-
</>
276
276
-
)}
277
277
-
</For>
278
278
-
</div>
222
222
+
<div class="flex flex-col overflow-hidden font-mono text-sm">
223
223
+
<For
224
224
+
each={Object.keys(nsids() ?? {}).filter((authority) =>
225
225
+
filter() ?
226
226
+
authority.startsWith(filter()!) || filter()?.startsWith(authority)
227
227
+
: true,
228
228
+
)}
229
229
+
>
230
230
+
{(authority) => (
231
231
+
<div class="flex flex-col rounded-lg p-1 hover:bg-neutral-200 dark:hover:bg-neutral-700">
232
232
+
<For
233
233
+
each={nsids()?.[authority].nsids.filter((nsid) =>
234
234
+
filter() ? nsid.startsWith(filter()!.split(".").slice(2).join(".")) : true,
235
235
+
)}
236
236
+
>
237
237
+
{(nsid) => (
238
238
+
<A
239
239
+
href={`/at://${did}/${authority}.${nsid}`}
240
240
+
class="hover:underline active:underline"
241
241
+
>
242
242
+
<span>{authority}</span>
243
243
+
<span class="text-neutral-500 dark:text-neutral-400">.{nsid}</span>
244
244
+
</A>
245
245
+
)}
246
246
+
</For>
247
247
+
</div>
248
248
+
)}
249
249
+
</For>
279
250
</div>
280
251
</Show>
281
252
<Show when={location.hash === "#identity"}>