메일 본문 내용 사용자 경험 개선
This commit is contained in:
@@ -2,16 +2,16 @@
|
||||
|
||||
/**
|
||||
* 메일 발송 액션 노드
|
||||
* SMTP를 통해 이메일을 발송하는 노드
|
||||
* 등록된 메일 계정을 선택하여 이메일을 발송하는 노드
|
||||
*/
|
||||
|
||||
import { memo } from "react";
|
||||
import { Handle, Position, NodeProps } from "reactflow";
|
||||
import { Mail, Server } from "lucide-react";
|
||||
import { Mail, User, CheckCircle } from "lucide-react";
|
||||
import type { EmailActionNodeData } from "@/types/node-editor";
|
||||
|
||||
export const EmailActionNode = memo(({ data, selected }: NodeProps<EmailActionNodeData>) => {
|
||||
const hasSmtpConfig = data.smtpConfig?.host && data.smtpConfig?.port;
|
||||
const hasAccount = !!data.accountId;
|
||||
const hasRecipient = data.to && data.to.trim().length > 0;
|
||||
const hasSubject = data.subject && data.subject.trim().length > 0;
|
||||
|
||||
@@ -38,16 +38,17 @@ export const EmailActionNode = memo(({ data, selected }: NodeProps<EmailActionNo
|
||||
|
||||
{/* 본문 */}
|
||||
<div className="space-y-2 p-3">
|
||||
{/* SMTP 설정 상태 */}
|
||||
{/* 발송 계정 상태 */}
|
||||
<div className="flex items-center gap-2 text-xs">
|
||||
<Server className="h-3 w-3 text-gray-400" />
|
||||
<User className="h-3 w-3 text-gray-400" />
|
||||
<span className="text-gray-600">
|
||||
{hasSmtpConfig ? (
|
||||
<span className="text-green-600">
|
||||
{data.smtpConfig.host}:{data.smtpConfig.port}
|
||||
{hasAccount ? (
|
||||
<span className="flex items-center gap-1 text-green-600">
|
||||
<CheckCircle className="h-3 w-3" />
|
||||
계정 선택됨
|
||||
</span>
|
||||
) : (
|
||||
<span className="text-orange-500">SMTP 설정 필요</span>
|
||||
<span className="text-orange-500">발송 계정 선택 필요</span>
|
||||
)}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user