diff options
| author | Adam Soltys <[email protected]> | 2026-09-02 18:59:38 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-09-02 18:59:38 -0700 |
| commit | 15d8c6f3dab19c7f51ad00b2fc377bf6eaa7f819 (patch) | |
| tree | 9a9c1aa65a663541992c87e30562a4a28baa3f84 | |
| parent | c4357ab5563aacc3614bfaf8f54cfb5c79a7f1ba (diff) | |
| download | coinosv3-15d8c6f3dab19c7f51ad00b2fc377bf6eaa7f819.tar.gz coinosv3-15d8c6f3dab19c7f51ad00b2fc377bf6eaa7f819.zip | |
A raw npub in a bio stops punching through the profile card: the about text renders through noteBody like any note — npub mentions become clickable @names, other nostr: refs truncate to stubs, URLs linkify — with overflow-wrap catching whatever unbreakable string remains
Co-Authored-By: Claude Fable 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MrkLsNScXe9b6BviUSdmMr
| -rw-r--r-- | src/features/messages.js | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/features/messages.js b/src/features/messages.js index 3f494e4..ca56335 100644 --- a/src/features/messages.js +++ b/src/features/messages.js @@ -1905,7 +1905,14 @@ export function messagesFeature(ctx) { mine ? hook('hatShopEntry') : null)), // no spinner while the kind 0 loads — prefetch keeps this rare, and // an empty beat reads calmer than a spinner - showAbout && !ui.profEdit ? h('p', { class: 'small', style: 'margin:0;white-space:pre-wrap' }, about.slice(0, 1000)) : null, + // The bio rides the same renderer as notes: npub mentions become + // @names, other nostr: refs truncate to stubs, URLs linkify — and + // overflow-wrap catches any remaining unbreakable token (a raw npub + // in a bio was punching clean through the card). + showAbout && !ui.profEdit + ? h('p', { class: 'small', style: 'margin:0;white-space:pre-wrap;overflow-wrap:anywhere' }, + ...noteBody(about.slice(0, 1000))) + : null, // your own npub stays out of the editor — it means nothing to most // people, and the account settings still show it to those who care mine ? null : h('button', { |
