const CLOSING = `Regards,\nPhilproperties IT Team\n\nThis is an automated message from STARR System. Please do not reply.`; const build = (body) => `${body.trim()}\n\n${CLOSING}`; export const emailTemplates = { OTP: ({ otp, expiryMinutes = 10 }) => ({ subject: "Email OTP Verification - STARR System", text: build(` Dear User, Please use the One-Time Password (OTP) below to verify your email address. This code is valid for ${expiryMinutes} minutes. ${otp} For security reasons, please do not share this code with anyone. If you did not request this, please contact the administrator. `), }), WELCOME: ({ name }) => ({ subject: "Welcome to STARR System", text: build(` Dear ${name}, We are pleased to welcome you to the STARR System. Your account has been successfully created and is now ready for use. You may now access your dashboard and begin using the available services. We look forward to supporting you. `), }), PASSWORD_CHANGED: () => ({ subject: "Password Update Confirmation - STARR System", text: build(` Dear User, This is to confirm that your account password has been successfully changed. If you did not perform this action, please reset your password immediately or contact support. For your security, we recommend using a strong and unique password. `), }), ADDED_TO_GROUP: ({ groupName }) => ({ subject: "Group Assignment Notification - STARR System", text: build(` Dear User, You have been assigned to the group "${groupName}" in the STARR System. This assignment grants you access to shared resources and collaboration tools within the group. Please log in to your account to view group details. `), }), TASK_ASSIGNED: ({ taskTitle, dueDate }) => ({ subject: "New Task Assignment - STARR System", text: build(` Dear User, You have been assigned a new task in the STARR System. Task: ${taskTitle} Due Date: ${dueDate} Kindly ensure completion within the specified timeframe. `), }), ADD_STAFF: ({ name, email, password, expiryHours = 24 }) => ({ subject: "Your Staff Account Has Been Created - STARR System", text: build(` Dear ${name}, Your staff account has been successfully created in the STARR System. Below are your login credentials: Email: ${email} Password: ${password} This temporary password is valid for ${expiryHours} hours. You will be required to change it upon first login. If you did not request this account or believe this was created in error, please contact your administrator immediately to have it deactivated. For security, please do not share your credentials with anyone. If you need a new password, contact your administrator. `), }), };