improve emails

This commit is contained in:
ThatOneCalculator 2023-05-10 14:27:46 -07:00
parent f4489af1bc
commit 3519bffbbc
2 changed files with 9 additions and 7 deletions

View File

@ -46,20 +46,20 @@ export async function sendEmail(
</head> </head>
<body style="background: #191724; padding: 16px; margin: 0; font-family: sans-serif; font-size: 14px;"> <body style="background: #191724; padding: 16px; margin: 0; font-family: sans-serif; font-size: 14px;">
<main style="max-width: 500px; margin: 0 auto; background: #1f1d2e; color: #e0def4;"> <main style="max-width: 500px; margin: 0 auto; background: #1f1d2e; color: #e0def4;">
<header style="padding: 32px; background: #31748f; display: flex;"> <header style="padding: 32px; background: #31748f; color: #e0def4; display: flex;">
<img src="${meta.logoImageUrl || meta.iconUrl || iconUrl}" style="max-width: 128px; max-height: 72px; vertical-align: bottom; margin-right: 16px;"/> <img src="${meta.logoImageUrl || meta.iconUrl || iconUrl}" style="max-width: 128px; max-height: 72px; vertical-align: bottom; margin-right: 16px;"/>
<h1 style="margin: 0 0 1em 0;">${meta.name}</h1> <h1 style="margin: 0 0 1em 0;">${meta.name}</h1>
</header> </header>
<article style="padding: 32px;"> <article style="padding: 32px;">
<h1>${subject}</h1> <h1 style="color: #ebbcba !important;">${subject}</h1>
<div>${html}</div> <div style="color: #e0def4;">${html}</div>
</article> </article>
<footer style="padding: 32px; border-top: solid 1px #26233a;"> <footer style="padding: 32px; border-top: solid 1px #26233a;">
<a href="${emailSettingUrl}" style="color: #31748f !important;">${"Email setting"}</a> <a href="${emailSettingUrl}" style="color: #9ccfd8 !important;">${"Email Settings"}</a>
</footer> </footer>
</main> </main>
<nav style="box-sizing: border-box; max-width: 500px; margin: 16px auto 0 auto; padding: 0 32px;"> <nav style="box-sizing: border-box; max-width: 500px; margin: 16px auto 0 auto; padding: 0 32px;">
<a href="${config.url}" style="color: #6e6a86 !important;">${config.host}</a> <a href="${config.url}" style="color: #9ccfd8 !important;">${config.host}</a>
</nav> </nav>
</body> </body>
</html>`, </html>`,

View File

@ -213,14 +213,16 @@
v-if="user.host == null && iAmModerator" v-if="user.host == null && iAmModerator"
inline inline
@click="sendModMail" @click="sendModMail"
>{{ i18n.ts.sendModMail }}</FormButton ><i class="ph-warning-diamond ph-bold ph-lg"></i>
{{ i18n.ts.sendModMail }}</FormButton
> >
<FormButton <FormButton
v-if="$i.isAdmin" v-if="$i.isAdmin"
inline inline
danger danger
@click="deleteAccount" @click="deleteAccount"
>{{ i18n.ts.deleteAccount }}</FormButton ><i class="ph-user-minus ph-bold ph-lg"></i>
{{ i18n.ts.deleteAccount }}</FormButton
> >
</div> </div>
<FormTextarea <FormTextarea