fix: clean newline paste thingy

This commit is contained in:
Brooklyn Nicholson 2026-04-13 12:54:48 -05:00
parent eec1db36f7
commit 0642b6cc53
3 changed files with 33 additions and 7 deletions

View file

@ -49,6 +49,8 @@ export const thinkingPreview = (reasoning: string, mode: ThinkingMode, max: numb
return !text || mode === 'collapsed' ? '' : mode === 'full' ? text : compactPreview(text, max)
}
export const stripTrailingPasteNewlines = (text: string) => (/[^\n]/.test(text) ? text.replace(/\n+$/, '') : text)
export const toolTrailLabel = (name: string) =>
name
.split('_')