|
2 | 2 | using Microsoft.UI.Xaml.Controls; |
3 | 3 | using Microsoft.UI.Xaml.Media; |
4 | 4 | using OpenClaw.Shared; |
| 5 | +using OpenClawTray.Helpers; |
5 | 6 | using OpenClawTray.Services; |
6 | 7 | using System.Collections.Generic; |
7 | 8 | using System.ComponentModel; |
@@ -204,12 +205,12 @@ private void RebuildCards() |
204 | 205 | foreach (var s in disabled) |
205 | 206 | DisabledPanel.Children.Add(BuildCard(s)); |
206 | 207 |
|
207 | | - EnabledHeaderText.Text = $"Enabled ({enabled.Count})"; |
208 | | - DisabledHeaderText.Text = $"Disabled ({disabled.Count})"; |
| 208 | + EnabledHeaderText.Text = LocalizationHelper.Format("SkillsPage_EnabledHeaderFormat", enabled.Count); |
| 209 | + DisabledHeaderText.Text = LocalizationHelper.Format("SkillsPage_DisabledHeaderFormat", disabled.Count); |
209 | 210 | DisabledExpander.Visibility = disabled.Count > 0 ? Visibility.Visible : Visibility.Collapsed; |
210 | 211 |
|
211 | 212 | var total = _allSkills.Count; |
212 | | - CountText.Text = total > 0 ? $"({enabled.Count}/{total} enabled)" : ""; |
| 213 | + CountText.Text = total > 0 ? LocalizationHelper.Format("SkillsPage_CountFormat", enabled.Count, total) : ""; |
213 | 214 |
|
214 | 215 | if (total > 0) |
215 | 216 | { |
@@ -256,7 +257,7 @@ private Grid BuildCard(SkillData s) |
256 | 257 | }; |
257 | 258 | badge.Child = new TextBlock |
258 | 259 | { |
259 | | - Text = s.IsEnabled ? "Enabled" : "Disabled", |
| 260 | + Text = LocalizationHelper.GetString(s.IsEnabled ? "SkillsPage_BadgeEnabled" : "SkillsPage_BadgeDisabled"), |
260 | 261 | FontSize = 11, |
261 | 262 | FontWeight = Microsoft.UI.Text.FontWeights.SemiBold, |
262 | 263 | Foreground = (Brush)Application.Current.Resources[badgeFgKey], |
|
0 commit comments