feat: add code block line wrap toggle
Adds a chat code block wrap toggle in markdown code block headers Persists and restores the setting across desktop/web settings Adds localized labels and OpenChamber search entry for the new option
This commit is contained in:
@@ -507,6 +507,9 @@ const applyDesktopUiPreferences = (settings: DesktopSettings) => {
|
||||
if (typeof settings.showToolFileIcons === 'boolean' && settings.showToolFileIcons !== store.showToolFileIcons) {
|
||||
store.setShowToolFileIcons(settings.showToolFileIcons);
|
||||
}
|
||||
if (typeof settings.codeBlockLineWrap === 'boolean' && settings.codeBlockLineWrap !== store.codeBlockLineWrap) {
|
||||
store.setCodeBlockLineWrap(settings.codeBlockLineWrap);
|
||||
}
|
||||
if (typeof settings.showTurnChangedFiles === 'boolean' && settings.showTurnChangedFiles !== store.showTurnChangedFiles) {
|
||||
store.setShowTurnChangedFiles(settings.showTurnChangedFiles);
|
||||
}
|
||||
@@ -1044,6 +1047,9 @@ const sanitizeWebSettings = (payload: unknown): DesktopSettings | null => {
|
||||
if (typeof candidate.showToolFileIcons === 'boolean') {
|
||||
result.showToolFileIcons = candidate.showToolFileIcons;
|
||||
}
|
||||
if (typeof candidate.codeBlockLineWrap === 'boolean') {
|
||||
result.codeBlockLineWrap = candidate.codeBlockLineWrap;
|
||||
}
|
||||
if (typeof candidate.showTurnChangedFiles === 'boolean') {
|
||||
result.showTurnChangedFiles = candidate.showTurnChangedFiles;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user