courrier multi account restore compose
This commit is contained in:
parent
e99d08fccf
commit
539ecd51b9
@ -280,7 +280,7 @@ export default function ComposeEmail(props: ComposeEmailProps) {
|
|||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="flex flex-col h-full">
|
<div className="flex flex-col h-full max-h-[80vh]">
|
||||||
<ComposeEmailHeader
|
<ComposeEmailHeader
|
||||||
type={type}
|
type={type}
|
||||||
onClose={onClose}
|
onClose={onClose}
|
||||||
@ -393,64 +393,63 @@ export default function ComposeEmail(props: ComposeEmailProps) {
|
|||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
{/* Modal Footer */}
|
{/* Modal Footer - now inside the main modal container and visually attached */}
|
||||||
<div className="flex-none flex items-center justify-between px-6 py-3 border-t border-gray-200 bg-white">
|
<div className="flex-none flex items-center justify-between px-6 py-3 border-t border-gray-200 bg-white">
|
||||||
<div className="flex items-center gap-2">
|
<div className="flex items-center gap-2">
|
||||||
{/* File Input for Attachments */}
|
{/* File Input for Attachments */}
|
||||||
<input
|
<input
|
||||||
type="file"
|
type="file"
|
||||||
id="file-attachment"
|
id="file-attachment"
|
||||||
className="hidden"
|
className="hidden"
|
||||||
multiple
|
multiple
|
||||||
onChange={(e) => {
|
onChange={(e) => {
|
||||||
if (e.target.files && e.target.files.length > 0) {
|
if (e.target.files && e.target.files.length > 0) {
|
||||||
handleAttachmentAdd(e.target.files);
|
handleAttachmentAdd(e.target.files);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
<label htmlFor="file-attachment">
|
<label htmlFor="file-attachment">
|
||||||
<Button
|
|
||||||
variant="outline"
|
|
||||||
size="icon"
|
|
||||||
className="rounded-full bg-white hover:bg-gray-100 border-gray-300"
|
|
||||||
onClick={(e) => {
|
|
||||||
e.preventDefault();
|
|
||||||
document.getElementById('file-attachment')?.click();
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<Paperclip className="h-4 w-4 text-gray-600" />
|
|
||||||
</Button>
|
|
||||||
</label>
|
|
||||||
{sending && <span className="text-xs text-gray-500 ml-2">Preparing attachment...</span>}
|
|
||||||
</div>
|
|
||||||
<div className="flex items-center gap-3">
|
|
||||||
<Button
|
<Button
|
||||||
variant="ghost"
|
variant="outline"
|
||||||
className="text-gray-600 hover:text-gray-700 hover:bg-gray-100"
|
size="icon"
|
||||||
onClick={onClose}
|
className="rounded-full bg-white hover:bg-gray-100 border-gray-300"
|
||||||
disabled={sending}
|
onClick={(e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
document.getElementById('file-attachment')?.click();
|
||||||
|
}}
|
||||||
>
|
>
|
||||||
Cancel
|
<Paperclip className="h-4 w-4 text-gray-600" />
|
||||||
</Button>
|
</Button>
|
||||||
<Button
|
</label>
|
||||||
className="bg-blue-600 text-white hover:bg-blue-700"
|
{sending && <span className="text-xs text-gray-500 ml-2">Preparing attachment...</span>}
|
||||||
onClick={handleSend}
|
</div>
|
||||||
disabled={sending}
|
<div className="flex items-center gap-3">
|
||||||
>
|
<Button
|
||||||
{sending ? (
|
variant="ghost"
|
||||||
<>
|
className="text-gray-600 hover:text-gray-700 hover:bg-gray-100"
|
||||||
<Loader2 className="mr-2 h-4 w-4 animate-spin" />
|
onClick={onClose}
|
||||||
Sending...
|
disabled={sending}
|
||||||
</>
|
>
|
||||||
) : (
|
Cancel
|
||||||
<>
|
</Button>
|
||||||
<SendHorizontal className="mr-2 h-4 w-4" />
|
<Button
|
||||||
Send
|
className="bg-blue-600 text-white hover:bg-blue-700"
|
||||||
</>
|
onClick={handleSend}
|
||||||
)}
|
disabled={sending}
|
||||||
</Button>
|
>
|
||||||
</div>
|
{sending ? (
|
||||||
|
<>
|
||||||
|
<Loader2 className="mr-2 h-4 w-4 animate-spin" />
|
||||||
|
Sending...
|
||||||
|
</>
|
||||||
|
) : (
|
||||||
|
<>
|
||||||
|
<SendHorizontal className="mr-2 h-4 w-4" />
|
||||||
|
Send
|
||||||
|
</>
|
||||||
|
)}
|
||||||
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user