mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-02-02 08:33:36 +00:00
fix: address second round of PR review feedback
- Add fallback for unknown enhancement modes in history button to prevent "Enhanced (undefined)" UI bug - Move DescriptionHistoryEntry interface to top level in add-feature-dialog - Import and use EnhancementMode type in edit-feature-dialog to eliminate hardcoded types - Make FollowUpHistoryEntry extend BaseHistoryEntry for consistency Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -54,7 +54,9 @@ export function EnhancementHistoryButton<T extends BaseHistoryEntry>({
|
||||
return 'Original';
|
||||
}
|
||||
if (entry.source === 'enhance') {
|
||||
return `Enhanced (${ENHANCEMENT_MODE_LABELS[entry.enhancementMode ?? 'improve']})`;
|
||||
const mode = entry.enhancementMode ?? 'improve';
|
||||
const label = ENHANCEMENT_MODE_LABELS[mode as EnhancementMode] ?? mode;
|
||||
return `Enhanced (${label})`;
|
||||
}
|
||||
return 'Edited';
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user