Add optional toggle for Relationship Status Fields (v2.1.2)

- Added relationships.enabled toggle in tracker configuration
- Relationship fields and emoji badges can now be disabled/enabled
- UI toggle added in Edit Trackers > Present Characters tab
- Updated prompt generation to respect the toggle
- Maintains backward compatibility with existing configs
- Added i18n translations (en, zh-tw)
This commit is contained in:
Spicy_Marinara
2026-01-03 00:55:29 +01:00
parent d44bb1cff9
commit c6b71ec1aa
8 changed files with 121 additions and 20 deletions
+15
View File
@@ -550,6 +550,21 @@ function migrateToTrackerConfig() {
'Neutral': '⚖️'
};
}
// Migrate to new relationships structure if not already present
if (!pc.relationships) {
pc.relationships = {
enabled: true, // Default to enabled for backward compatibility
relationshipEmojis: pc.relationshipEmojis || {
'Lover': '❤️',
'Friend': '⭐',
'Ally': '🤝',
'Enemy': '⚔️',
'Neutral': '⚖️'
}
};
}
if (!pc.thoughts) {
pc.thoughts = {
enabled: true,