Fix: Exclude CSV files from text preview loader so they render as interactive spreadsheets
This commit is contained in:
parent
4da31c52c0
commit
7c6eebb151
@ -92,6 +92,9 @@ export const AssetViewerModal: React.FC<AssetViewerModalProps> = ({
|
|||||||
|
|
||||||
const isTextOrCodeAsset = (url: string, type: string) => {
|
const isTextOrCodeAsset = (url: string, type: string) => {
|
||||||
const assetUrl = url.toLowerCase();
|
const assetUrl = url.toLowerCase();
|
||||||
|
if (assetUrl.endsWith('.csv') || type.includes('csv')) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
return (
|
return (
|
||||||
assetUrl.endsWith('.md') ||
|
assetUrl.endsWith('.md') ||
|
||||||
assetUrl.endsWith('.txt') ||
|
assetUrl.endsWith('.txt') ||
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user