Skip to content

Commit 3025373

Browse files
committed
feat: preview plain text files in web view
1 parent b100532 commit 3025373

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

Sushitrain/Utils.swift

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,14 @@ extension SushitrainEntry {
259259
}
260260

261261
var isWebPreviewable: Bool {
262-
return self.isPDF || self.isHTML || self.isImage
262+
if self.isPDF || self.isHTML || self.isImage {
263+
return true
264+
}
265+
266+
return [
267+
"text/plain",
268+
"text/csv",
269+
].contains(self.mimeType())
263270
}
264271

265272
var isStreamable: Bool {

0 commit comments

Comments
 (0)