/** * 첨부파일 영역 및 파일 칩 UI 컴포넌트 */ import { escapeHTML } from '../utils.js'; /** * 파일 확장자에 따른 아이콘 반환 */ export function getFileIcon(mime) { if (!mime) return '📎'; mime = mime.toLowerCase(); if (mime.includes('image')) return '🖼️'; if (mime.includes('pdf')) return '📕'; if (mime.includes('word') || mime.includes('text')) return '📄'; if (mime.includes('zip') || mime.includes('compressed')) return '📦'; return '📎'; } /** * 첨부파일 영역 HTML 생성 */ export function renderAttachmentBox(attachments) { if (!attachments || attachments.length === 0) return ''; let html = '
'; return html; }