Get rid of profile detail, redirect externally

This commit is contained in:
Jon Staab
2024-10-24 12:50:49 -07:00
parent 03b4f2c46c
commit cad096b019
15 changed files with 57 additions and 201 deletions
+7
View File
@@ -1,7 +1,9 @@
import twColors from "tailwindcss/colors"
import {get, derived} from "svelte/store"
import {nip19} from "nostr-tools"
import type {Maybe} from "@welshman/lib"
import {
ctx,
setContext,
remove,
assoc,
@@ -132,6 +134,11 @@ export const imgproxy = (url: string, {w = 640, h = 1024} = {}) => {
export const entityLink = (entity: string) => `https://coracle.social/${entity}`
export const pubkeyLink = (
pubkey: string,
relays = ctx.app.router.FromPubkeys([pubkey]).getUrls(),
) => entityLink(nip19.nprofileEncode({pubkey, relays}))
export const tagRoom = (room: string, url: string) => [ROOM, room, url]
export const getDefaultPubkeys = () => {