package emails

import (
	"git.ma-al.com/goc_daniel/b2b/app/templ/layout"
	"git.ma-al.com/goc_daniel/b2b/app/view"
	"git.ma-al.com/goc_daniel/b2b/app/utils/i18n"
)

templ EmailAdminNotificationWrapper(data view.EmailLayout[view.EmailAdminNotificationData]) {
	@layout.Base( i18n.T___(data.LangID, "email.email_admin_notification_title")) {
        <div class="container">
            <div class="email-wrapper">
                <div class="email-header">
                    <h1>New User Registration</h1>
                </div>
                <div class="email-body">
                    <p>Hello Administrator,</p>
                    <p>A new user has completed their registration and requires repository access.</p>
                    <div class="info-box">
                        <strong>User Details:</strong>
                        <p><strong>Name:</strong> { data.Data.UserName } </p>
                        <p><strong>Email:</strong> { data.Data.UserEmail } </p>
                    </div>
                    <p>Please assign the appropriate repositories to this user in the admin panel.</p>
                    <div style="text-align: center;">
                        <a href="{ data.Data.BaseURL }/admin/users" class="button">Go to Admin Panel</a>
                    </div>
                </div>
                <div class="email-footer">
                    <p>&copy; 2024 Gitea Manager. All rights reserved.</p>
                </div>
            </div>
        </div>
    }
}