From 16cec4a535960b4dbd2ccf97a83b07f18910f083 Mon Sep 17 00:00:00 2001
From: haorwen
Date: Sat, 27 Jun 2026 22:24:21 +0800
Subject: [PATCH] feat(channel): redesign guest mode warning dialog
- Reorder buttons: Confirm (primary) > Switch to Private > Disable Guest Mode (small gray)
- Update title and description to focus on visibility impact
- Add confirm key to en/zh locales; remove dont_remind key
---
public/locales/en/chat.json | 8 ++++----
public/locales/zh/chat.json | 8 ++++----
src/components/ChannelModal/index.tsx | 8 ++++----
3 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/public/locales/en/chat.json b/public/locales/en/chat.json
index 0cdca4f3..130f91f0 100644
--- a/public/locales/en/chat.json
+++ b/public/locales/en/chat.json
@@ -79,10 +79,10 @@
"remark_placeholder": "Set Nickname",
"guest_mode_warning": {
- "title": "Guest Mode is Enabled",
- "desc": "Unauthenticated visitors can see messages in public channels. You may disable guest mode or switch to a private channel instead.",
+ "title": "This Channel Will Be Visible to Guests",
+ "desc": "If you continue, guest users may be able to see messages in this public channel.",
+ "confirm": "Confirm",
"disable_guest": "Disable Guest Mode",
- "switch_private": "Switch to Private Channel",
- "dont_remind": "Don't remind me again"
+ "switch_private": "Switch to Private Channel"
}
}
diff --git a/public/locales/zh/chat.json b/public/locales/zh/chat.json
index d8f067f9..429737c3 100644
--- a/public/locales/zh/chat.json
+++ b/public/locales/zh/chat.json
@@ -78,10 +78,10 @@
"remark_placeholder": "备注该用户",
"guest_mode_warning": {
- "title": "访客模式已开启",
- "desc": "未登录的访客可以看到公共频道的消息流。您可以前往关闭访客模式,或改为创建私有频道。",
+ "title": "该频道将对访客可见",
+ "desc": "继续创建后,访客用户可能会看到该公共频道中的消息。",
+ "confirm": "确认创建",
"disable_guest": "关闭访客模式",
- "switch_private": "改为私有频道",
- "dont_remind": "不再提醒"
+ "switch_private": "改为私有频道"
}
}
diff --git a/src/components/ChannelModal/index.tsx b/src/components/ChannelModal/index.tsx
index bb61d3aa..7088391a 100644
--- a/src/components/ChannelModal/index.tsx
+++ b/src/components/ChannelModal/index.tsx
@@ -48,17 +48,17 @@ const GuestModeWarning: FC = ({ onDisableGuest, onSwitchP
{t("guest_mode_warning.desc")}
-