Add copyable current ID to the header

This commit is contained in:
Rūdolfs Ošiņš
2024-09-11 09:44:48 +02:00
parent c558235a49
commit 8a417404b8
11 changed files with 396 additions and 15 deletions
+6 -1
View File
@@ -4,6 +4,7 @@
import * as router from "@app/lib/router";
import CopyableId from "@app/components/CopyableId.svelte";
import Header from "@app/components/Header.svelte";
import RepoCard from "@app/components/RepoCard.svelte";
@@ -22,7 +23,11 @@
}
</style>
<Header currentPage="Repositories" />
<Header>
<svelte:fragment slot="center">
<CopyableId id={`did:key:${config.publicKey}`} />
</svelte:fragment>
</Header>
<div class="layout">
<div class="repo-grid">
{#each repos as repo}
+10 -2
View File
@@ -1,7 +1,9 @@
<script lang="ts">
import type { RepoInfo } from "@bindings/RepoInfo";
import CopyableId from "@app/components/CopyableId.svelte";
import Header from "@app/components/Header.svelte";
import Icon from "@app/components/Icon.svelte";
import Link from "@app/components/Link.svelte";
export let repo: RepoInfo;
@@ -9,9 +11,15 @@
$: project = repo.payloads["xyz.radicle.project"]!;
</script>
<Header currentPage="Repositories" />
<Header>
<svelte:fragment slot="icon-left">
<Icon name="sidebar" />
</svelte:fragment>
<svelte:fragment slot="center">
<CopyableId id={repo.rid} />
</svelte:fragment>
</Header>
<div>{project.data.name}</div>
<div>{repo.rid}</div>
Issues
<Link route={{ resource: "repo.issues", rid: repo.rid, status: "open" }}>