docs: distinguish server-hosted Matrix from account chat
ci / linux-x64 (push) Successful in 3m24s
ci / linux-arm64-cross (push) Successful in 3m45s

This commit is contained in:
omar committed 2026-11-02 12:39:28 +03:00
1 parent e4681bef35
commit d0202247ce
5 files changed
+79 -20

No files matched your search

+39 -7
View File
@@ -8,9 +8,9 @@ Token values used (from themes.txt): see §6.
## 0. Architecture: what drives which chat
- **One component for every chat.** `ts-chat` (chat container, render@3472672) renders channel chats, private chats and Matrix rooms.
- Container getters at main.js@~3431811: `isLegacy = !this.room`, `chat = room ? null : item`, and `room` is set only when `item instanceof NW` (a Matrix room, main.js@1521496).
- A **channel item or client item is passed directly**, which makes it a *legacy* chat.
- **One component for every chat.** `ts-chat` (render@3472672) renders legacy channel/private text and room-based chat.
- Container getters at main.js@~3431811: `isLegacy = !this.room`, `chat = room ? null : item`; `room` is set for the shared `NW` room class. A room does not by itself imply a myTeamSpeak account.
- A directly passed channel/client item selects legacy chat. With a decentralized participation, the content view instead passes `roomParticipation.room` (main.js@4324239 / @4326512).
- **Legacy chat model** (module 60408, main.js@2137033). Chat target enum: `CLIENT=1` (private), `CHANNEL=2`, `SERVER=3`, `POKE=4`. Event types: `None, TextMessage, Poke, ChannelJoined, ChannelLeft`.
- Messages (class main.js@2136580) have the fields `time, isPoke, isSystem, isSelfMentioned, isGroupStart, isDayStart`.
- Grouping window constant `CU = 30` (minutes).
@@ -19,16 +19,48 @@ Token values used (from themes.txt): see §6.
- channel: `ChannelInfo` "Info" → `Chat` "Chat" (`universal.chats` count 1) → `ChannelFiles` "Files". `Chat` is only offered when **your own client is in that channel** (isAvailable checks `GetClients().find(own id)`).
- client: `ClientInfo` "Info" → `Chat` (shown only when the client is **not yourself**) → `OwnFiles` (unlisted). This is the private chat.
- server: Recording, `Info`, `ServerLog` "Recent Server Events", Permissions … — **no Chat mode for the server**. A server-chat UI surface was not found (see UNRESOLVED). Only the notification strings `settings.notifications.self.text.(from|to).server` refer to server chat.
- Matrix room (`chatRoom`): Chat / Pinned / Info / Settings. Account-bound; excluded under the no-account requirement.
- Room (`chatRoom`): Chat / Pinned / Info / Settings. Central/homebase rooms are account-bound; server-hosted rooms use the decentralized server-identity path below. Pinning is non-direct-room-only.
- The tool button `currentChannelToolButton` (main.js@1746938) has icon `ChannelShowChat`, title "Show current Channel Chat" / "Showing current Channel Chat" ("Показать текущий чат канала" / "Показывается текущий чат канала"), and a Notification-style badge = `channel.chat.GetUnreadMessagesCount()`. The badge is 0 while that chat is the one being shown.
- **Pokes**:
- Pokes are legacy messages with `isPoke` (bubble class `poke`; no `.poke` CSS rule exists).
- Pokes survive the system-message filter: `!e.isSystem || e.isPoke` (main.js@2140412).
- The poke notification widget is render@1730302, string `channel.chat.events.client.poked_you` "Poked you".
### Feature inventory (legacy = server text message / native; Matrix = myTeamSpeak/homebase-only)
| Feature | Legacy channel / private chat | Matrix-only (account) | Evidence |
### Server-hosted Matrix versus central account chat — static scope correction, 2026-11-02
The server's `MATRIXCHAT` capability enables `hasDecentralMessaging` (main.js@2420596).
The decentralized manager starts unconditionally (@2482171), unlike central/default participation,
which requires `account.isConnected || account.isPseudoConnected` (@2476536).
On a server connection, `getConnectionParticipation` keys participation by `uuidv5/usedIdentityId`
(@2556137); `connectToDecentral` requires that server identity, calls native `getWellKnown(scHandlerId)`
and consumes `chat.domain`. It then calls `tschat_create(scHandlerId, serverUuid, identityId, endpoint)`
and `tschat_connect(tsChatId, displayName, presence)` (@2480332, @2486407, @2526967).
There is no frontend myTeamSpeak login gate in this route. **Native authentication is still unresolved**;
these static findings are not a successful account-free server-room login.
Incoming `PrivateChat` invitations create a direct participation. Manual Accept and the default-false
`autoAcceptIncomingDirectChats` setting both set `permanentlyJoined=true` (@1328392, @3556822), leading
to native `tschat_joinRoom`. Reject calls `tschat_leaveRoom`. An outgoing private request instead uses
`tschat_requestPrivateChat(scHandlerId, clientId)` and waits up to ten seconds for a matching invitation.
Channel participation waits for and accepts its own channel invitation. Peer availability, the
`CAN_RECIEVE_TEXTMESSAGES` hint and room permissions still gate actions.
Both decentralized and central paths use room class `NW` (@2585285). The edit/reply/react/redact menu
does not require a central room (@1523559); edit additionally checks sender/permission and pending/redacted
state, and pinning requires a non-direct room. Native sync/E2EE/event behavior has not been exercised.
Attachments need server `HTTPFT`, or the separate central fallback with `mytsFeaturesEnabled`; do not
infer that account-free room text therefore includes central attachment storage.
Independent implementation is blocked on the native well-known request and full envelope, login/token
issuance, server `uuidv5` derivation, private-request wire command and room/sync callback payloads.
The native string `http://{0}/.well-known/teamspeak/{1}` is recorded in
`../ts6-filetransfer-native-continuation.json`; its placeholders are not established here.
### Feature inventory (legacy server text versus shared room-based chat)
| Feature | Legacy channel / private chat | Room-based (server-hosted or central) | Evidence |
|---|---|---|---|
| Send/receive text, BBCode + markdown render | yes | yes | markdown help intro "We still support BBCode" (en.json `settings.chat.markdown_help.intro.body`) |
| Join/leave/move/kick/ban/poke system rows | yes (`legacyEvent` + `i18nPath`) | own variants | main.js@3305577 |
@@ -396,7 +428,7 @@ Button order `ve` (main.js@3517677). Overflowing items collapse into the **More*
**Hover quick-actions bar:**
- Pill radius (theme), shaded-bg at .9, buttons separated by 1px `--strong-bg` dividers; shows at most 2 buttons plus an expander.
- Matrix-only: needs `room`.
- Room-based: needs `room`, which may belong to a TS server or the central/account connection.
**Keyboard and drag-drop:**
- Composer: `keydown` handler, paste handler, drop handler.