diff options
| author | Jon Staab <jstaab@protonmail.com> | 2023-05-12 05:10:45 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-05-12 05:10:45 -0700 |
| commit | e5302f84c74cf42d878a3ed18257a16bc0d3b748 (patch) | |
| tree | b1a3ad9c0317bf7c38f34c500559b66ff7c0a22d /08.md | |
| parent | 1c728516dfdc7508ce27eda222bde78466e3457d (diff) | |
| parent | 4208652dc7a39c63c39559b13c656ec30400fcba (diff) | |
Merge branch 'master' into patch-1
Diffstat (limited to '08.md')
| -rw-r--r-- | 08.md | 6 |
1 files changed, 5 insertions, 1 deletions
| @@ -1,10 +1,12 @@ | |||
| 1 | > __Warning__ `unrecommended`: deprecated in favor of [NIP-27](27.md) | ||
| 2 | |||
| 1 | NIP-08 | 3 | NIP-08 |
| 2 | ====== | 4 | ====== |
| 3 | 5 | ||
| 4 | Handling Mentions | 6 | Handling Mentions |
| 5 | ----------------- | 7 | ----------------- |
| 6 | 8 | ||
| 7 | `final` `optional` `author:fiatjaf` `author:scsibug` | 9 | `final` `unrecommended` `optional` `author:fiatjaf` `author:scsibug` |
| 8 | 10 | ||
| 9 | This document standardizes the treatment given by clients of inline mentions of other events and pubkeys inside the content of `text_note`s. | 11 | This document standardizes the treatment given by clients of inline mentions of other events and pubkeys inside the content of `text_note`s. |
| 10 | 12 | ||
| @@ -15,3 +17,5 @@ Once a mention is identified, for example, the pubkey `27866e9d854c78ae625b867ee | |||
| 15 | The same process applies for mentioning event IDs. | 17 | The same process applies for mentioning event IDs. |
| 16 | 18 | ||
| 17 | A client that receives a `text_note` event with such `#[index]` mentions in its `.content` CAN do a search-and-replace using the actual contents from the `.tags` array with the actual pubkey or event ID that is mentioned, doing any desired context augmentation (for example, linking to the pubkey or showing a preview of the mentioned event contents) it wants in the process. | 19 | A client that receives a `text_note` event with such `#[index]` mentions in its `.content` CAN do a search-and-replace using the actual contents from the `.tags` array with the actual pubkey or event ID that is mentioned, doing any desired context augmentation (for example, linking to the pubkey or showing a preview of the mentioned event contents) it wants in the process. |
| 20 | |||
| 21 | Where `#[index]` has an `index` that is outside the range of the tags array or points to a tag that is not an `e` or `p` tag or a tag otherwise declared to support this notation, the client MUST NOT perform such replacement or augmentation, but instead display it as normal text. | ||