mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-11-29 02:00:31 +08:00
Migrate to the heartwood protocol stack
Signed-off-by: Rūdolfs Ošiņš <rudolfs@osins.org>
This commit is contained in:
@@ -3,17 +3,13 @@
|
||||
|
||||
import { closeFocused } from "@app/components/Floating.svelte";
|
||||
import { sessionStore, disconnect } from "@app/lib/session";
|
||||
import { toClipboard } from "@app/lib/utils";
|
||||
import { toClipboard, formatNodeId } from "@app/lib/utils";
|
||||
|
||||
import Avatar from "@app/components/Comment/Avatar.svelte";
|
||||
import Button from "@app/components/Button.svelte";
|
||||
import Floating from "@app/components/Floating.svelte";
|
||||
import Icon from "@app/components/Icon.svelte";
|
||||
|
||||
function formatId(id: string) {
|
||||
return id.substring(0, 4) + " – " + id.substring(id.length - 4, id.length);
|
||||
}
|
||||
|
||||
let icon: "clipboard-small" | "checkmark-small" = "clipboard-small";
|
||||
|
||||
const restoreIcon = debounce(() => {
|
||||
@@ -43,7 +39,7 @@
|
||||
position: absolute;
|
||||
right: 5rem;
|
||||
top: 5rem;
|
||||
width: 16.5rem;
|
||||
width: 15rem;
|
||||
}
|
||||
.info {
|
||||
align-items: flex-start;
|
||||
@@ -118,7 +114,6 @@
|
||||
font-family: var(--font-family-monospace);
|
||||
font-size: var(--font-size-tiny);
|
||||
user-select: none;
|
||||
width: 11rem;
|
||||
word-break: break-all;
|
||||
}
|
||||
.disconnect {
|
||||
@@ -171,7 +166,7 @@
|
||||
title={$sessionStore.publicKey} />
|
||||
</div>
|
||||
<div class="user-id txt-small">
|
||||
{formatId($sessionStore.publicKey)}
|
||||
{formatNodeId($sessionStore.publicKey)}
|
||||
</div>
|
||||
</div>
|
||||
{:else}
|
||||
@@ -214,7 +209,7 @@
|
||||
}
|
||||
}}>
|
||||
<div class="id">
|
||||
{$sessionStore.publicKey}
|
||||
{formatNodeId($sessionStore.publicKey)}
|
||||
</div>
|
||||
<div class="id-clipboard">
|
||||
<Icon name={icon} />
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
import * as modal from "@app/lib/modal";
|
||||
import Link from "@app/components/Link.svelte";
|
||||
import Modal from "@app/components/Modal.svelte";
|
||||
import { formatRadicleId, getSeedEmoji } from "@app/lib/utils";
|
||||
import { formatRepositoryId, getSeedEmoji } from "@app/lib/utils";
|
||||
|
||||
export let query: string;
|
||||
export let results: ProjectResult[];
|
||||
@@ -48,7 +48,7 @@
|
||||
{getSeedEmoji(project.seed.host)} {project.info.name}
|
||||
</span>
|
||||
<span class="id">
|
||||
{formatRadicleId(project.info.id)}
|
||||
{formatRepositoryId(project.info.id)}
|
||||
</span>
|
||||
</span>
|
||||
</Link>
|
||||
|
||||
Reference in New Issue
Block a user