feat: refactor MailViewer and add utility functions for email handling and attachment processing
This commit is contained in:
37
frontend/src/lib/utils/mail/index.ts
Normal file
37
frontend/src/lib/utils/mail/index.ts
Normal file
@@ -0,0 +1,37 @@
|
||||
/**
|
||||
* Mail utilities barrel export
|
||||
*/
|
||||
|
||||
// Constants
|
||||
export {
|
||||
IFRAME_UTIL_HTML,
|
||||
EMAIL_EXTENSIONS,
|
||||
CONTENT_TYPES,
|
||||
PEC_FILES,
|
||||
} from './constants';
|
||||
|
||||
// Data utilities
|
||||
export {
|
||||
arrayBufferToBase64,
|
||||
createDataUrl,
|
||||
looksLikeBase64,
|
||||
tryDecodeBase64,
|
||||
} from './data-utils';
|
||||
|
||||
// Attachment handlers
|
||||
export {
|
||||
openPDFAttachment,
|
||||
openImageAttachment,
|
||||
openEMLAttachment,
|
||||
type AttachmentHandlerResult,
|
||||
} from './attachment-handlers';
|
||||
|
||||
// Email loader
|
||||
export {
|
||||
getEmailFileType,
|
||||
isEmailFile,
|
||||
loadEmailFromPath,
|
||||
openAndLoadEmail,
|
||||
processEmailBody,
|
||||
type LoadEmailResult,
|
||||
} from './email-loader';
|
||||
Reference in New Issue
Block a user