feat(ui): add separate icon and text colorization for CustomButton

- Add colorizeSystemText setting for text color (icon only was already supported)
- JSON parse supports iconColor and textColor fields separately
- Legacy "color" field still works for both icon and text
- Enable colorization no longer depends on show icon setting
- Refactor resolveColor helper to eliminate duplicate code
This commit is contained in:
loner
2026-04-06 08:18:28 +08:00
parent 55c7f344b3
commit f21e8fb82a
4 changed files with 61 additions and 12 deletions
+3
View File
@@ -105,6 +105,8 @@
"collapse-condition-description": "If the output text matches this value, the button will collapse.",
"collapse-condition-label": "Collapse condition",
"color-selection-description": "Apply theme colors to icon and text.",
"icon-color-selection-description": "Apply theme colors to icons.",
"text-color-selection-description": "Apply theme colors to text.",
"default-tooltip": "Custom button, configure in settings",
"display-command-output-description": "Enter a command to run at a regular interval. The first line of its output will be displayed as text.",
"display-command-output-label": "Display command output",
@@ -523,6 +525,7 @@
"select-color": "Select color",
"select-color-description": "Apply theme colors for emphasis.",
"select-icon-color": "Select icon color",
"select-text-color": "Select text color",
"settings": "Settings",
"shortcuts": "Shortcuts",
"shutdown": "Shutdown",