feat: add player invitation and autojoin functionality

Implement a system to invite players via generated URLs that
automatically configure their name and role.

- Add `InviteDialog` to allow users to generate and copy invite links
- Implement autojoin logic in `ConnectDialog` based on URL parameters
- Add an "+ invite" button to the `JournalPanel` player list
- Ensure `autojoin` parameter is stripped on disconnect to allow
  manual connection later
This commit is contained in:
2026-07-06 18:41:40 +08:00
parent 1d0f2f7c3e
commit 7cfc0fd4f3
2 changed files with 163 additions and 39 deletions
+3
View File
@@ -583,6 +583,9 @@ export function disconnectStream(): void {
setState("connected", false);
setState("connectionStatus", "disconnected");
setState("players", {});
// Strip autojoin param so the dialog shows normally on next connect
removeUrlParam("autojoin");
}
// ---------------------------------------------------------------------------