refactor(user-agents): why it uses regex

This commit is contained in:
MeexReay 2025-08-31 04:36:06 +03:00
parent 313561cf39
commit 8c2772366d
2 changed files with 10 additions and 8 deletions

View File

@ -27,7 +27,7 @@ export default function Protocol() {
{
name: "User Agents",
desc: "A community-made solution to identify clients by a unique symbol in front of their username.",
curator: "@kostya-zero",
curator: "@MeexReay",
href: "/protocol/user-agents",
},
{

View File

@ -11,7 +11,6 @@ import {
import Text from "@/components/blocks/Text";
import PageTitle from "@/components/blocks/PageTitle";
import Code from "@/components/blocks/Code";
import InlineCode from "@/components/blocks/InlineCode";
type UserAgent = {
client: string;
@ -79,16 +78,19 @@ export default function UserAgents() {
<b>User Agents</b>.
</Text>
<Text>
User Agents in RAC are implemented by adding an extra Unicode symbol as
a prefix to usernames. For example, a message sent with the Tower
User Agents in RAC are implemented by changing the message regex.
For example, a message sent with the Tower
client:
</Text>
<Code>{"▲<zero> Hello, world!"}</Code>
<Text>
The <InlineCode></InlineCode> symbol in front of the username indicates
that this message was sent using the Tower client. The client should use
regex to parse these messages and determine the client, username, and
message.
It can be just a prefix, or actually a new message structure,
For example, first versions of Mefedroniy, sent messages like this:
</Text>
<Code>{"banon: Hello, world!"}</Code>
<Text>
That{"'"}s why the clients should use regex to parse these messages
and determine the client, username, and message.
</Text>
<h3 className={"text-3xl text-stone-300 font-semibold font-rokkitt"}>
Known Agents