Fix unreadable user markdown colors and truncate long texts in deletion dialogs (#17555)

* webui: limit conversation name length in dialogs

* webui: fix unreadable colors on links and table cell hover in user markdown

* webui: keep table borders visible in user markdown

* webui: updating unified exports

* Update tools/server/webui/src/lib/components/app/chat/ChatAttachments/ChatAttachmentThumbnailFile.svelte

Co-authored-by: Aleksander Grygier <aleksander.grygier@gmail.com>

* chore: update webui build output

* chore: update webui build output

* chore: update webui build output

---------

Co-authored-by: Aleksander Grygier <aleksander.grygier@gmail.com>
This commit is contained in:
Pascal
2025-12-15 16:34:53 +01:00
committed by GitHub
parent 165caaf5fb
commit 0f4f35e7be
7 changed files with 38 additions and 12 deletions
@@ -34,12 +34,3 @@ export function getFileTypeLabel(input: string | undefined): string {
// Handle AttachmentType or other plain strings
return input.toUpperCase();
}
/**
* Truncates text content for preview display
* @param content - The text content to truncate
* @returns Truncated content with ellipsis if needed
*/
export function getPreviewText(content: string): string {
return content.length > 150 ? content.substring(0, 150) + '...' : content;
}
+2 -1
View File
@@ -43,7 +43,8 @@ export { createMessageCountMap, getMessageCount } from './conversation-utils';
export { copyToClipboard, copyCodeToClipboard } from './copy';
// File preview utilities
export { getFileTypeLabel, getPreviewText } from './file-preview';
export { getFileTypeLabel } from './file-preview';
export { getPreviewText } from './text';
// File type utilities
export {
+7
View File
@@ -0,0 +1,7 @@
/**
* Returns a shortened preview of the provided content capped at the given length.
* Appends an ellipsis when the content exceeds the maximum.
*/
export function getPreviewText(content: string, max = 150): string {
return content.length > max ? content.slice(0, max) + '...' : content;
}