From 39cd7ab801fdb844ea79643fcb93eebb7e71a060 Mon Sep 17 00:00:00 2001 From: JonKazama-Hellion Date: Sat, 2 May 2026 14:26:13 +0200 Subject: [PATCH] feat(auto-tell-tabs): make greeted toggle button opt-in (default off, greeter-specific) --- ChatTwo/Configuration.cs | 6 ++++++ ChatTwo/Resources/HellionStrings.Designer.cs | 2 ++ ChatTwo/Resources/HellionStrings.de.resx | 6 ++++++ ChatTwo/Resources/HellionStrings.resx | 6 ++++++ ChatTwo/Ui/ChatLogWindow.cs | 6 ++++-- ChatTwo/Ui/SettingsTabs/ChatLog.cs | 3 +++ 6 files changed, 27 insertions(+), 2 deletions(-) diff --git a/ChatTwo/Configuration.cs b/ChatTwo/Configuration.cs index 042abcf..915f5e1 100755 --- a/ChatTwo/Configuration.cs +++ b/ChatTwo/Configuration.cs @@ -95,6 +95,11 @@ public class Configuration : IPluginConfiguration // Number of prior tells to preload from the message store when an // auto tell tab is spawned. Range 0–100; 0 disables preload. public int AutoTellTabsHistoryPreload = 20; + // Show the greeter "marked-as-greeted" toggle button next to each + // temp tab and dim the tab name when set. Off by default because the + // workflow is specific to club-greeter use cases — most users just + // want the auto tabs themselves without the extra UI affordance. + public bool AutoTellTabsShowGreetedToggle; public int GetRetentionDays(ChatType type) { @@ -284,6 +289,7 @@ public class Configuration : IPluginConfiguration AutoTellTabsLimit = other.AutoTellTabsLimit; AutoTellTabsCompactDisplay = other.AutoTellTabsCompactDisplay; AutoTellTabsHistoryPreload = other.AutoTellTabsHistoryPreload; + AutoTellTabsShowGreetedToggle = other.AutoTellTabsShowGreetedToggle; } } diff --git a/ChatTwo/Resources/HellionStrings.Designer.cs b/ChatTwo/Resources/HellionStrings.Designer.cs index e05d332..b2a7c9e 100644 --- a/ChatTwo/Resources/HellionStrings.Designer.cs +++ b/ChatTwo/Resources/HellionStrings.Designer.cs @@ -182,6 +182,8 @@ internal class HellionStrings internal static string ChatLog_AutoTellTabs_Limit_Description => Get(nameof(ChatLog_AutoTellTabs_Limit_Description)); internal static string ChatLog_AutoTellTabs_Compact_Name => Get(nameof(ChatLog_AutoTellTabs_Compact_Name)); internal static string ChatLog_AutoTellTabs_Compact_Description => Get(nameof(ChatLog_AutoTellTabs_Compact_Description)); + internal static string ChatLog_AutoTellTabs_GreetedToggle_Name => Get(nameof(ChatLog_AutoTellTabs_GreetedToggle_Name)); + internal static string ChatLog_AutoTellTabs_GreetedToggle_Description => Get(nameof(ChatLog_AutoTellTabs_GreetedToggle_Description)); internal static string ChatLog_AutoTellTabs_PreloadHint => Get(nameof(ChatLog_AutoTellTabs_PreloadHint)); internal static string ChatLog_AutoTellTabs_ConflictHint => Get(nameof(ChatLog_AutoTellTabs_ConflictHint)); diff --git a/ChatTwo/Resources/HellionStrings.de.resx b/ChatTwo/Resources/HellionStrings.de.resx index 17401fd..c4d2826 100644 --- a/ChatTwo/Resources/HellionStrings.de.resx +++ b/ChatTwo/Resources/HellionStrings.de.resx @@ -412,6 +412,12 @@ Zeigt nur einen dünnen Separator zwischen normalen Tabs und Auto-Tell-Tabs, ohne Sektions-Header. + + „Als begrüßt markieren"-Button anzeigen + + + Fügt neben jedem Auto-Tell-Tab einen Klick-Button hinzu, um einen Gesprächspartner als bereits begrüßt zu markieren — der Tab-Name wird dann gedimmt. Nützlich für Club-Greeter, die parallel viele Konversationen führen. Standardmäßig aus. + Die Anzahl der vorgeladenen Tells lässt sich im Datenschutz-Tab einstellen. diff --git a/ChatTwo/Resources/HellionStrings.resx b/ChatTwo/Resources/HellionStrings.resx index 3402f84..01cb688 100644 --- a/ChatTwo/Resources/HellionStrings.resx +++ b/ChatTwo/Resources/HellionStrings.resx @@ -412,6 +412,12 @@ Show only a thin separator between persistent tabs and auto tell tabs, without the section header. + + Show "mark as greeted" button + + + Adds a click-to-toggle button next to each auto tell tab to mark a partner as already greeted, dimming the tab name when set. Useful for club greeters tracking many parallel conversations; off by default. + The number of preloaded tells is configured in the Privacy tab. diff --git a/ChatTwo/Ui/ChatLogWindow.cs b/ChatTwo/Ui/ChatLogWindow.cs index d222db1..0ba15f6 100644 --- a/ChatTwo/Ui/ChatLogWindow.cs +++ b/ChatTwo/Ui/ChatLogWindow.cs @@ -1329,7 +1329,9 @@ public sealed class ChatLogWindow : Window var selectableLabel = $"{tab.Name}{unread}###log-tab-{tabI}"; var isCurrentTab = Plugin.LastTab == tabI || Plugin.WantedTab == tabI; - if (tab.IsTempTab) + var showGreetedAffordance = tab.IsTempTab && Plugin.Config.AutoTellTabsShowGreetedToggle; + + if (showGreetedAffordance) { // Greeted toggle sits left of the selectable so the // click areas stay separate. The icon also doubles @@ -1360,7 +1362,7 @@ public sealed class ChatLogWindow : Window } bool clicked; - if (tab.IsTempTab && tab.IsGreeted) + if (showGreetedAffordance && tab.IsGreeted) { // Dim the tab name once the user marked the partner // as greeted, so a glance at the sidebar tells them diff --git a/ChatTwo/Ui/SettingsTabs/ChatLog.cs b/ChatTwo/Ui/SettingsTabs/ChatLog.cs index 426a34c..a88f5be 100644 --- a/ChatTwo/Ui/SettingsTabs/ChatLog.cs +++ b/ChatTwo/Ui/SettingsTabs/ChatLog.cs @@ -146,6 +146,9 @@ internal sealed class ChatLog : ISettingsTab ImGui.Checkbox(HellionStrings.ChatLog_AutoTellTabs_Compact_Name, ref Mutable.AutoTellTabsCompactDisplay); ImGuiUtil.HelpMarker(HellionStrings.ChatLog_AutoTellTabs_Compact_Description); + ImGui.Checkbox(HellionStrings.ChatLog_AutoTellTabs_GreetedToggle_Name, ref Mutable.AutoTellTabsShowGreetedToggle); + ImGuiUtil.HelpMarker(HellionStrings.ChatLog_AutoTellTabs_GreetedToggle_Description); + ImGui.Spacing(); ImGuiUtil.HelpText(HellionStrings.ChatLog_AutoTellTabs_PreloadHint);