Skip to content

Open-source social media scheduler built for AI agents and the teams behind them. Create, schedule and publish posts to every network through MCP or the REST API, or write them yourself in a composer your team will love.

Redesign transactional emails with shared Maizzle components (#395)

Paulo Castellano893878592e81
diff --git a/app/Mail/PostNoteAdded.php b/app/Mail/PostNoteAdded.php
index 2129493c2..3edb2abd6 100644
--- a/app/Mail/PostNoteAdded.php
+++ b/app/Mail/PostNoteAdded.php
@@ -5,7 +5,6 @@ declare(strict_types=1);
namespace App\Mail;
use App\Models\PostNote;
-use App\Models\PostPlatform;
use App\Models\User;
use App\Support\Mail\PostExcerpt;
use Illuminate\Bus\Queueable;
@@ -49,9 +48,6 @@ class PostNoteAdded extends Mailable implements ShouldQueue
->with('socialAccount')
->enabled()
->get()
- ->map(fn (PostPlatform $postPlatform): string => $postPlatform->notificationLabel())
- ->unique()
- ->values()
->all(),
'url' => route('app.posts.edit', ['post' => $post, 'comment' => $this->note->id]),
],
diff --git a/app/Mail/PostPublishFailed.php b/app/Mail/PostPublishFailed.php
index cc52c634c..a8bb79006 100644
--- a/app/Mail/PostPublishFailed.php
+++ b/app/Mail/PostPublishFailed.php
@@ -6,6 +6,7 @@ namespace App\Mail;
use App\Enums\PostPlatform\Status;
use App\Models\Post;
+use App\Support\Mail\PostPreview;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Mail\Mailable;
@@ -30,17 +31,11 @@ class PostPublishFailed extends Mailable implements ShouldQueue
public function content(): Content
{
- $failedPlatforms = $this->post->postPlatforms()
+ $postPlatform = $this->post->postPlatforms()
->with('socialAccount')
->enabled()
- ->get()
- ->filter(fn ($pp) => $pp->status === Status::Failed)
- ->map(fn ($pp) => [
- 'name' => $pp->notificationLabel(),
- 'error' => $pp->error_message,
- ])
- ->values()
- ->all();
+ ->where('status', Status::Failed)
+ ->first();
return new Content(
view: 'mail.post-publish-failed',
@@ -48,7 +43,12 @@ class PostPublishFailed extends Mailable implements ShouldQueue
'title' => __('mail.post_publish_failed.title'),
'previewText' => __('mail.post_publish_failed.preview'),
'workspaceName' => $this->post->workspace->name,
- 'failedPlatforms' => $failedPlatforms,
+ 'publication' => $postPlatform ? [
+ 'accountName' => $postPlatform->display_name,
+ 'platform' => $postPlatform->platform,
+ 'error' => $postPlatform->error_message,
+ ] : null,
+ 'postPreview' => PostPreview::from($this->post),
'url' => route('app.posts.index', ['tab' => 'sent', 'post' => $this->post->id]),
],
);
diff --git a/app/Mail/PostPublished.php b/app/Mail/PostPublished.php
index 64422f001..04d43c862 100644
--- a/app/Mail/PostPublished.php
+++ b/app/Mail/PostPublished.php
@@ -4,8 +4,8 @@ declare(strict_types=1);
namespace App\Mail;
-use App\Enums\PostPlatform\Status;
use App\Models\Post;
+use App\Support\Mail\PostPreview;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Mail\Mailable;
@@ -30,17 +30,11 @@ class PostPublished extends Mailable implements ShouldQueue
public function content(): Content
{
- $publishedPlatforms = $this->post->postPlatforms()
+ $postPlatform = $this->post->postPlatforms()
->with('socialAccount')
->enabled()
- ->get()
- ->filter(fn ($pp) => $pp->status === Status::Published)
- ->map(fn ($pp) => [
- 'name' => $pp->notificationLabel(),
- 'url' => $pp->platform_url,
- ])
- ->values()
- ->all();
+ ->published()
+ ->first();
return new Content(
view: 'mail.post-published',
@@ -48,7 +42,12 @@ class PostPublished extends Mailable implements ShouldQueue
'title' => __('mail.post_published.title'),
'previewText' => __('mail.post_published.preview'),
'workspaceName' => $this->post->workspace->name,
- 'publishedPlatforms' => $publishedPlatforms,
+ 'publication' => $postPlatform ? [
+ 'accountName' => $postPlatform->display_name,
+ 'platform' => $postPlatform->platform,
+ ] : null,
+ 'postPreview' => PostPreview::from($this->post),
+ 'publishedUrl' => $postPlatform?->platform_url,
'url' => route('app.posts.edit', $this->post),
],
);
diff --git a/app/Support/Mail/ApprovalEmailPosts.php b/app/Support/Mail/ApprovalEmailPosts.php
index 9f674d6a1..cad136fce 100644
--- a/app/Support/Mail/ApprovalEmailPosts.php
+++ b/app/Support/Mail/ApprovalEmailPosts.php
@@ -38,13 +38,12 @@ class ApprovalEmailPosts
/**
* @param Collection<int, Post> $posts
- * @return list<string>
+ * @return list<PostPlatform>
*/
public static function channels(Collection $posts): array
{
return $posts->flatMap(fn (Post $post) => $post->postPlatforms)
- ->map(fn (PostPlatform $postPlatform): string => $postPlatform->notificationLabel())
- ->unique()
+ ->unique(fn (PostPlatform $postPlatform): string => $postPlatform->social_account_id ?? $postPlatform->id)
->values()
->all();
}
@@ -54,12 +53,12 @@ class ApprovalEmailPosts
* publishing now. One shared moment collapses into a single line.
*
* @param Collection<int, Post> $posts
- * @return array{at: ?string, perChannel: list<array{channel: string, at: ?string}>}
+ * @return array{at: ?string, perChannel: list<array{channels: list<PostPlatform>, at: ?string}>}
*/
public static function goesOut(Collection $posts, User $recipient): array
{
$perChannel = $posts->map(fn (Post $post): array => [
- 'channel' => implode(', ', self::channels(collect([$post]))),
+ 'channels' => self::channels(collect([$post])),
'at' => $post->status === PostStatus::Scheduled ? self::time($post->scheduled_at, $recipient) : null,
]);
diff --git a/app/Support/Mail/PostPreview.php b/app/Support/Mail/PostPreview.php
new file mode 100644
index 000000000..ee9bc99d4
--- /dev/null
+++ b/app/Support/Mail/PostPreview.php
@@ -0,0 +1,37 @@
+<?php
+
+declare(strict_types=1);
+
+namespace App\Support\Mail;
+
+use App\Models\Post;
+
+class PostPreview
+{
+ /**
+ * @return array{text: string, image: ?array{url: string, alt: string, width: int}, attachment: ?string}
+ */
+ public static function from(Post $post): array
+ {
+ $media = $post->media_items->first();
+ $image = null;
+
+ if ($media?->isImage() && filled($media->url)) {
+ $width = $media->width();
+ $height = $media->height();
+ $scale = $width > 0 && $height > 0 ? min(1, 440 / $width, 280 / $height) : null;
+
+ $image = [
+ 'url' => $media->url,
+ 'alt' => $media->altText() ?? '',
+ 'width' => $scale !== null ? max(1, (int) round($width * $scale)) : 240,
+ ];
+ }
+
+ return [
+ 'text' => PostExcerpt::from($post->content, 500),
+ 'image' => $image,
+ 'attachment' => $media?->original_filename,
+ ];
+ }
+}
diff --git a/lang/ar/mail.php b/lang/ar/mail.php
index 82d7230f8..b50bf71fc 100644
--- a/lang/ar/mail.php
+++ b/lang/ar/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'أداة مفتوحة المصدر لجدولة منشورات التواصل الاجتماعي',
+ 'tagline' => 'أُرسل بواسطة فريق :brand',
'manage_notifications' => 'إدارة الإشعارات',
'signoff' => 'مع التحية،',
'team' => 'فريق TryPost',
@@ -16,7 +16,7 @@ return [
'title' => 'حساب :platform يحتاج إلى إعادة ربط',
'preview' => 'أعد ربط حساب :platform في :workspace لمتابعة جدولة المنشورات.',
'heading' => 'تم فصل الحساب',
- 'intro' => 'تم فصل حساب <strong>:platform</strong> الخاص بك <strong>:account</strong> عن مساحة العمل <strong>:workspace</strong>.',
+ 'intro' => 'تم فصل الحساب التالي عن مساحة العمل :workspace.',
'reasons_title' => 'قد يكون هذا حدث للأسباب التالية:',
'reason_expired' => 'انتهت صلاحية رمز الوصول',
'reason_revoked' => 'قمت بإلغاء وصول TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'عرض في المسودات',
],
+ 'post_preview' => [
+ 'no_text' => 'منشور بدون نص',
+ 'error' => 'ما الذي حدث',
+ ],
+
'post_publish_failed' => [
'subject' => 'فشل نشر منشورك في :workspace',
'title' => 'فشل نشر منشورك',
- 'preview' => 'فشلت منصة واحدة أو أكثر في النشر.',
+ 'preview' => 'فشل نشر منشورك',
'heading' => 'فشل نشر منشورك',
- 'body' => 'فشل نشر منشورك المجدول في مساحة العمل :workspace على منصة واحدة أو أكثر.',
- 'platforms_title' => 'المنصات التي فشلت:',
+ 'body' => 'تعذر نشر منشورك في :workspace.',
'button' => 'عرض المنشور',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'تم نشر منشورك بنجاح.',
'heading' => 'تم نشر منشورك',
'body' => 'تم نشر منشورك في مساحة العمل :workspace بنجاح.',
- 'platforms_title' => 'تم النشر على:',
- 'view_post' => 'عرض المنشور',
- 'button' => 'عرض المنشور',
+ 'button' => 'عرض على الشبكة',
+ 'open_in_app' => 'فتح في TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'أُوقف الويب هوك مؤقتًا بعد إخفاقات متكررة',
'preview' => 'أوقفنا ويب هوكًا مؤقتًا بعد 5 إخفاقات تسليم متتالية.',
'heading' => 'أُوقف الويب هوك مؤقتًا بعد إخفاقات متكررة',
- 'body' => 'أوقفنا الويب هوك على :endpoint مؤقتًا بعد 5 إخفاقات تسليم متتالية. راجع الـ endpoint وأعد تفعيله من صفحة تفاصيل الويب هوك.',
+ 'body' => 'أوقفنا ويب هوكًا مؤقتًا بعد 5 إخفاقات تسليم متتالية.',
+ 'next_steps' => 'راجع الـ endpoint وأعد تفعيله من صفحة تفاصيل الويب هوك.',
'button' => 'عرض الويب هوك',
],
diff --git a/lang/de/mail.php b/lang/de/mail.php
index e64519450..58199ef60 100644
--- a/lang/de/mail.php
+++ b/lang/de/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Open-Source-Tool zur Planung von Social-Media-Beiträgen',
+ 'tagline' => 'Gesendet vom :brand-Team',
'manage_notifications' => 'Benachrichtigungen verwalten',
'signoff' => 'Viele Grüße,',
'team' => 'Das TryPost-Team',
@@ -16,7 +16,7 @@ return [
'title' => 'Dein :platform-Konto muss neu verbunden werden',
'preview' => 'Verbinde dein :platform-Konto in :workspace neu, um weiter Beiträge zu planen.',
'heading' => 'Konto getrennt',
- 'intro' => 'Dein <strong>:platform</strong>-Konto <strong>:account</strong> wurde vom Workspace <strong>:workspace</strong> getrennt.',
+ 'intro' => 'Das folgende Konto wurde vom Workspace :workspace getrennt.',
'reasons_title' => 'Mögliche Gründe:',
'reason_expired' => 'Dein Zugriffstoken ist abgelaufen',
'reason_revoked' => 'Du hast den Zugriff von TryPost widerrufen',
@@ -99,13 +99,17 @@ return [
'button' => 'In den Entwürfen ansehen',
],
+ 'post_preview' => [
+ 'no_text' => 'Beitrag ohne Text',
+ 'error' => 'Was passiert ist',
+ ],
+
'post_publish_failed' => [
'subject' => 'Dein Beitrag in :workspace konnte nicht veröffentlicht werden',
'title' => 'Dein Beitrag konnte nicht veröffentlicht werden',
- 'preview' => 'Eine oder mehrere Plattformen konnten nicht veröffentlichen.',
+ 'preview' => 'Dein Beitrag konnte nicht veröffentlicht werden',
'heading' => 'Dein Beitrag konnte nicht veröffentlicht werden',
- 'body' => 'Dein geplanter Beitrag im Workspace :workspace konnte auf einer oder mehreren Plattformen nicht veröffentlicht werden.',
- 'platforms_title' => 'Fehlgeschlagene Plattformen:',
+ 'body' => 'Dein Beitrag in :workspace konnte nicht veröffentlicht werden.',
'button' => 'Beitrag ansehen',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Dein Beitrag wurde erfolgreich veröffentlicht.',
'heading' => 'Dein Beitrag wurde veröffentlicht',
'body' => 'Dein Beitrag im Workspace :workspace wurde erfolgreich veröffentlicht.',
- 'platforms_title' => 'Veröffentlicht auf:',
- 'view_post' => 'Beitrag ansehen',
- 'button' => 'Beitrag ansehen',
+ 'button' => 'Im Netzwerk ansehen',
+ 'open_in_app' => 'In TryPost öffnen',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook nach wiederholten Fehlern pausiert',
'preview' => 'Wir haben einen Webhook nach 5 aufeinanderfolgenden Zustellfehlern pausiert.',
'heading' => 'Webhook nach wiederholten Fehlern pausiert',
- 'body' => 'Wir haben den Webhook unter :endpoint nach 5 aufeinanderfolgenden Zustellfehlern pausiert. Prüfe den Endpoint und aktiviere ihn wieder auf der Webhook-Detailseite.',
+ 'body' => 'Wir haben einen Webhook nach 5 aufeinanderfolgenden Zustellfehlern pausiert.',
+ 'next_steps' => 'Prüfe den Endpoint und aktiviere ihn wieder auf der Webhook-Detailseite.',
'button' => 'Webhook anzeigen',
],
diff --git a/lang/el/mail.php b/lang/el/mail.php
index 9cde048af..b43326ccd 100644
--- a/lang/el/mail.php
+++ b/lang/el/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Εργαλείο ανοιχτού κώδικα για προγραμματισμό δημοσιεύσεων',
+ 'tagline' => 'Στάλθηκε από την ομάδα :brand',
'manage_notifications' => 'Διαχείριση ειδοποιήσεων',
'signoff' => 'Με εκτίμηση,',
'team' => 'Η ομάδα του TryPost',
@@ -16,7 +16,7 @@ return [
'title' => 'Ο λογαριασμός :platform χρειάζεται επανασύνδεση',
'preview' => 'Επανασυνδέστε τον λογαριασμό :platform στο :workspace για να συνεχίσετε να προγραμματίζετε δημοσιεύσεις.',
'heading' => 'Ο λογαριασμός αποσυνδέθηκε',
- 'intro' => 'Ο λογαριασμός σας <strong>:platform</strong> <strong>:account</strong> αποσυνδέθηκε από τον χώρο εργασίας <strong>:workspace</strong>.',
+ 'intro' => 'Ο παρακάτω λογαριασμός αποσυνδέθηκε από τον χώρο εργασίας :workspace.',
'reasons_title' => 'Αυτό μπορεί να συνέβη επειδή:',
'reason_expired' => 'Το διακριτικό πρόσβασης έληξε',
'reason_revoked' => 'Ανακαλέσατε την πρόσβαση του TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'Προβολή στα πρόχειρα',
],
+ 'post_preview' => [
+ 'no_text' => 'Δημοσίευση χωρίς κείμενο',
+ 'error' => 'Τι συνέβη',
+ ],
+
'post_publish_failed' => [
'subject' => 'Η δημοσίευσή σας απέτυχε στο :workspace',
'title' => 'Η δημοσίευσή σας απέτυχε',
- 'preview' => 'Μία ή περισσότερες πλατφόρμες δεν κατάφεραν να δημοσιεύσουν.',
+ 'preview' => 'Η δημοσίευσή σας απέτυχε',
'heading' => 'Η δημοσίευσή σας απέτυχε',
- 'body' => 'Η προγραμματισμένη δημοσίευσή σας στον χώρο εργασίας :workspace απέτυχε σε μία ή περισσότερες πλατφόρμες.',
- 'platforms_title' => 'Πλατφόρμες με σφάλμα:',
+ 'body' => 'Δεν ήταν δυνατή η δημοσίευση της ανάρτησής σας στο :workspace.',
'button' => 'Προβολή δημοσίευσης',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Η δημοσίευσή σας ολοκληρώθηκε με επιτυχία.',
'heading' => 'Η δημοσίευσή σας δημοσιεύτηκε',
'body' => 'Η δημοσίευσή σας στον χώρο εργασίας :workspace ολοκληρώθηκε με επιτυχία.',
- 'platforms_title' => 'Δημοσιεύτηκε σε:',
- 'view_post' => 'Προβολή δημοσίευσης',
- 'button' => 'Προβολή δημοσίευσης',
+ 'button' => 'Προβολή στο δίκτυο',
+ 'open_in_app' => 'Άνοιγμα στο TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Το webhook τέθηκε σε παύση μετά από επαναλαμβανόμενες αποτυχίες',
'preview' => 'Θέσαμε ένα webhook σε παύση μετά από 5 διαδοχικές αποτυχίες παράδοσης.',
'heading' => 'Το webhook τέθηκε σε παύση μετά από επαναλαμβανόμενες αποτυχίες',
- 'body' => 'Θέσαμε το webhook στο :endpoint σε παύση μετά από 5 διαδοχικές αποτυχίες παράδοσης. Ελέγξτε το endpoint και ενεργοποιήστε το ξανά από τη σελίδα λεπτομερειών του webhook.',
+ 'body' => 'Θέσαμε ένα webhook σε παύση μετά από 5 διαδοχικές αποτυχίες παράδοσης.',
+ 'next_steps' => 'Ελέγξτε το endpoint και ενεργοποιήστε το ξανά από τη σελίδα λεπτομερειών του webhook.',
'button' => 'Προβολή webhook',
],
diff --git a/lang/en/mail.php b/lang/en/mail.php
index f494c545d..f621d2f2c 100644
--- a/lang/en/mail.php
+++ b/lang/en/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Open-source social media scheduling tool',
+ 'tagline' => 'Sent by the :brand team',
'manage_notifications' => 'Manage notifications',
'signoff' => 'Best regards,',
'team' => 'The TryPost Team',
@@ -16,7 +16,7 @@ return [
'title' => 'Your :platform account needs to be reconnected',
'preview' => 'Please reconnect your :platform account in :workspace to continue scheduling posts.',
'heading' => 'Account Disconnected',
- 'intro' => 'Your <strong>:platform</strong> account <strong>:account</strong> has been disconnected from the <strong>:workspace</strong> workspace.',
+ 'intro' => 'The following account was disconnected from the :workspace workspace.',
'reasons_title' => 'This may have happened because:',
'reason_expired' => 'Your access token expired',
'reason_revoked' => 'You revoked access to TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'View in drafts',
],
+ 'post_preview' => [
+ 'no_text' => 'Post without text',
+ 'error' => 'What went wrong',
+ ],
+
'post_publish_failed' => [
'subject' => 'Your post failed to publish in :workspace',
'title' => 'Your post failed to publish',
- 'preview' => 'One or more platforms failed to publish your post.',
+ 'preview' => 'Your post failed to publish',
'heading' => 'Your post failed to publish',
- 'body' => 'Your scheduled post in the :workspace workspace failed to publish on one or more platforms.',
- 'platforms_title' => 'Failed platforms:',
+ 'body' => 'We could not publish your post in :workspace.',
'button' => 'View Post',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Your post has been published successfully.',
'heading' => 'Your post was published',
'body' => 'Your post in the :workspace workspace has been published successfully.',
- 'platforms_title' => 'Published on:',
- 'view_post' => 'View post',
- 'button' => 'View Post',
+ 'button' => 'View on social network',
+ 'open_in_app' => 'Open in TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook paused after repeated failures',
'preview' => 'We paused a webhook after 5 consecutive delivery failures.',
'heading' => 'Webhook paused after repeated failures',
- 'body' => 'We paused the webhook at :endpoint after 5 consecutive delivery failures. Review the endpoint and re-enable it from the webhook details page.',
+ 'body' => 'We paused a webhook after 5 consecutive delivery failures.',
+ 'next_steps' => 'Review the endpoint and re-enable it from the webhook details page.',
'button' => 'View webhook',
],
diff --git a/lang/es/mail.php b/lang/es/mail.php
index dfa1af39a..e73cfb045 100644
--- a/lang/es/mail.php
+++ b/lang/es/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Herramienta de código abierto para programar redes sociales',
+ 'tagline' => 'Enviado por el equipo de :brand',
'manage_notifications' => 'Gestionar notificaciones',
'signoff' => 'Un saludo,',
'team' => 'El equipo de TryPost',
@@ -16,7 +16,7 @@ return [
'title' => 'Tu cuenta de :platform necesita reconectarse',
'preview' => 'Reconecta tu cuenta de :platform en :workspace para seguir programando publicaciones.',
'heading' => 'Cuenta desconectada',
- 'intro' => 'Tu cuenta de <strong>:platform</strong> <strong>:account</strong> se ha desconectado del espacio de trabajo <strong>:workspace</strong>.',
+ 'intro' => 'La siguiente cuenta se desconectó del espacio de trabajo :workspace.',
'reasons_title' => 'Esto puede haber ocurrido porque:',
'reason_expired' => 'Tu token de acceso caducó',
'reason_revoked' => 'Revocaste el acceso a TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'Ver en borradores',
],
+ 'post_preview' => [
+ 'no_text' => 'Publicación sin texto',
+ 'error' => 'Qué ocurrió',
+ ],
+
'post_publish_failed' => [
'subject' => 'Tu publicación falló en :workspace',
'title' => 'Tu publicación falló',
- 'preview' => 'Una o más plataformas no pudieron publicar.',
+ 'preview' => 'Tu publicación falló',
'heading' => 'Tu publicación falló',
- 'body' => 'Tu publicación programada en el espacio de trabajo :workspace falló en una o más plataformas.',
- 'platforms_title' => 'Plataformas con error:',
+ 'body' => 'No pudimos publicar tu post en :workspace.',
'button' => 'Ver publicación',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Tu publicación se publicó correctamente.',
'heading' => 'Tu publicación salió',
'body' => 'Tu publicación en el espacio de trabajo :workspace se publicó correctamente.',
- 'platforms_title' => 'Publicada en:',
- 'view_post' => 'Ver publicación',
- 'button' => 'Ver publicación',
+ 'button' => 'Ver en la red social',
+ 'open_in_app' => 'Abrir en TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook pausado tras fallos repetidos',
'preview' => 'Pausamos un webhook tras 5 fallos consecutivos de entrega.',
'heading' => 'Webhook pausado tras fallos repetidos',
- 'body' => 'Pausamos el webhook en :endpoint tras 5 fallos consecutivos de entrega. Revisa el endpoint y actívalo de nuevo en la página de detalles del webhook.',
+ 'body' => 'Pausamos un webhook tras 5 fallos consecutivos de entrega.',
+ 'next_steps' => 'Revisa el endpoint y actívalo de nuevo en la página de detalles del webhook.',
'button' => 'Ver webhook',
],
diff --git a/lang/fr/mail.php b/lang/fr/mail.php
index 39069e437..d2dffb09e 100644
--- a/lang/fr/mail.php
+++ b/lang/fr/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Outil open source de planification pour les réseaux sociaux',
+ 'tagline' => 'Envoyé par l’équipe :brand',
'manage_notifications' => 'Gérer les notifications',
'signoff' => 'Cordialement,',
'team' => 'L\'équipe TryPost',
@@ -16,7 +16,7 @@ return [
'title' => 'Votre compte :platform doit être reconnecté',
'preview' => 'Reconnectez votre compte :platform dans :workspace pour continuer à planifier vos publications.',
'heading' => 'Compte déconnecté',
- 'intro' => 'Votre compte <strong>:platform</strong> <strong>:account</strong> a été déconnecté de l’espace de travail <strong>:workspace</strong>.',
+ 'intro' => 'Le compte ci-dessous a été déconnecté de l’espace de travail :workspace.',
'reasons_title' => 'Cela peut être dû à :',
'reason_expired' => 'Votre jeton d’accès a expiré',
'reason_revoked' => 'Vous avez révoqué l’accès de TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'Voir dans les brouillons',
],
+ 'post_preview' => [
+ 'no_text' => 'Publication sans texte',
+ 'error' => 'Ce qui s’est passé',
+ ],
+
'post_publish_failed' => [
'subject' => 'Votre publication a échoué dans :workspace',
'title' => 'Votre publication a échoué',
- 'preview' => 'Une ou plusieurs plateformes n’ont pas pu publier.',
+ 'preview' => 'Votre publication a échoué',
'heading' => 'Votre publication a échoué',
- 'body' => 'Votre publication planifiée dans l’espace de travail :workspace a échoué sur une ou plusieurs plateformes.',
- 'platforms_title' => 'Plateformes en échec :',
+ 'body' => 'Nous n’avons pas pu publier votre post dans :workspace.',
'button' => 'Voir la publication',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Votre publication a bien été publiée.',
'heading' => 'Votre publication est en ligne',
'body' => 'Votre publication dans l’espace de travail :workspace a bien été publiée.',
- 'platforms_title' => 'Publiée sur :',
- 'view_post' => 'Voir la publication',
- 'button' => 'Voir la publication',
+ 'button' => 'Voir sur le réseau',
+ 'open_in_app' => 'Ouvrir dans TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook mis en pause après des échecs répétés',
'preview' => 'Nous avons mis un webhook en pause après 5 échecs de livraison consécutifs.',
'heading' => 'Webhook mis en pause après des échecs répétés',
- 'body' => 'Nous avons mis le webhook de :endpoint en pause après 5 échecs de livraison consécutifs. Vérifiez l\'endpoint et réactivez-le depuis la page de détails du webhook.',
+ 'body' => 'Nous avons mis un webhook en pause après 5 échecs de livraison consécutifs.',
+ 'next_steps' => 'Vérifiez l\'endpoint et réactivez-le depuis la page de détails du webhook.',
'button' => 'Voir le webhook',
],
diff --git a/lang/it/mail.php b/lang/it/mail.php
index cfb73ef2f..83cd8bbdc 100644
--- a/lang/it/mail.php
+++ b/lang/it/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Strumento open source per pianificare i social',
+ 'tagline' => 'Inviato dal team :brand',
'manage_notifications' => 'Gestisci le notifiche',
'signoff' => 'Cordiali saluti,',
'team' => 'Il team di TryPost',
@@ -16,7 +16,7 @@ return [
'title' => 'Il tuo account :platform deve essere ricollegato',
'preview' => 'Ricollega il tuo account :platform in :workspace per continuare a pianificare i post.',
'heading' => 'Account disconnesso',
- 'intro' => 'Il tuo account <strong>:platform</strong> <strong>:account</strong> è stato disconnesso dallo spazio di lavoro <strong>:workspace</strong>.',
+ 'intro' => 'Il seguente account è stato disconnesso dallo spazio di lavoro :workspace.',
'reasons_title' => 'Può essere successo perché:',
'reason_expired' => 'Il tuo token di accesso è scaduto',
'reason_revoked' => 'Hai revocato l’accesso a TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'Vedi nelle bozze',
],
+ 'post_preview' => [
+ 'no_text' => 'Post senza testo',
+ 'error' => 'Cosa è successo',
+ ],
+
'post_publish_failed' => [
'subject' => 'La pubblicazione del tuo post in :workspace non è riuscita',
'title' => 'La pubblicazione del tuo post non è riuscita',
- 'preview' => 'Una o più piattaforme non sono riuscite a pubblicare.',
+ 'preview' => 'La pubblicazione del tuo post non è riuscita',
'heading' => 'La pubblicazione del tuo post non è riuscita',
- 'body' => 'Il tuo post pianificato nello spazio di lavoro :workspace non è stato pubblicato su una o più piattaforme.',
- 'platforms_title' => 'Piattaforme non riuscite:',
+ 'body' => 'Non è stato possibile pubblicare il tuo post in :workspace.',
'button' => 'Vedi post',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Il tuo post è stato pubblicato correttamente.',
'heading' => 'Il tuo post è stato pubblicato',
'body' => 'Il tuo post nello spazio di lavoro :workspace è stato pubblicato correttamente.',
- 'platforms_title' => 'Pubblicato su:',
- 'view_post' => 'Vedi post',
- 'button' => 'Vedi post',
+ 'button' => 'Vedi sul social',
+ 'open_in_app' => 'Apri in TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook messo in pausa dopo errori ripetuti',
'preview' => 'Abbiamo messo in pausa un webhook dopo 5 errori di consegna consecutivi.',
'heading' => 'Webhook messo in pausa dopo errori ripetuti',
- 'body' => 'Abbiamo messo in pausa il webhook su :endpoint dopo 5 errori di consegna consecutivi. Controlla l\'endpoint e riattivalo dalla pagina dei dettagli del webhook.',
+ 'body' => 'Abbiamo messo in pausa un webhook dopo 5 errori di consegna consecutivi.',
+ 'next_steps' => 'Controlla l\'endpoint e riattivalo dalla pagina dei dettagli del webhook.',
'button' => 'Vedi webhook',
],
diff --git a/lang/ja/mail.php b/lang/ja/mail.php
index 6ee5dbb2a..3fbd1b6de 100644
--- a/lang/ja/mail.php
+++ b/lang/ja/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'オープンソースの SNS 投稿スケジュールツール',
+ 'tagline' => ':brandチームより送信',
'manage_notifications' => '通知設定',
'signoff' => 'よろしくお願いいたします。',
'team' => 'TryPost チーム',
@@ -16,7 +16,7 @@ return [
'title' => ':platform アカウントの再接続が必要です',
'preview' => ':workspace の :platform アカウントを再接続すると、投稿の予約を続けられます。',
'heading' => 'アカウントが切断されました',
- 'intro' => 'ワークスペース <strong>:workspace</strong> から <strong>:platform</strong> アカウント <strong>:account</strong> が切断されました。',
+ 'intro' => '以下のアカウントがワークスペース :workspace から切断されました。',
'reasons_title' => '考えられる原因:',
'reason_expired' => 'アクセストークンの有効期限が切れた',
'reason_revoked' => 'TryPost のアクセス権を取り消した',
@@ -99,13 +99,17 @@ return [
'button' => '下書きで見る',
],
+ 'post_preview' => [
+ 'no_text' => 'テキストのない投稿',
+ 'error' => 'エラーの詳細',
+ ],
+
'post_publish_failed' => [
'subject' => ':workspace で投稿の公開に失敗しました',
'title' => '投稿の公開に失敗しました',
- 'preview' => '1 つ以上のプラットフォームで公開に失敗しました。',
+ 'preview' => '投稿の公開に失敗しました',
'heading' => '投稿の公開に失敗しました',
- 'body' => 'ワークスペース :workspace の予約投稿が、1 つ以上のプラットフォームで公開に失敗しました。',
- 'platforms_title' => '失敗したプラットフォーム:',
+ 'body' => ':workspace の投稿を公開できませんでした。',
'button' => '投稿を見る',
],
@@ -115,9 +119,8 @@ return [
'preview' => '投稿が正常に公開されました。',
'heading' => '投稿が公開されました',
'body' => 'ワークスペース :workspace の投稿が正常に公開されました。',
- 'platforms_title' => '公開先:',
- 'view_post' => '投稿を見る',
- 'button' => '投稿を見る',
+ 'button' => 'SNSで投稿を見る',
+ 'open_in_app' => 'TryPostで開く',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => '連続した失敗のためWebhookを一時停止しました',
'preview' => '配信が5回連続で失敗したため、Webhookを一時停止しました。',
'heading' => '連続した失敗のためWebhookを一時停止しました',
- 'body' => ':endpoint のWebhookを、配信が5回連続で失敗したため一時停止しました。Endpointを確認し、Webhookの詳細ページから再度有効にしてください。',
+ 'body' => '配信が5回連続で失敗したため、Webhookを一時停止しました。',
+ 'next_steps' => 'Endpointを確認し、Webhookの詳細ページから再度有効にしてください。',
'button' => 'Webhookを見る',
],
diff --git a/lang/ko/mail.php b/lang/ko/mail.php
index d3bf3b35b..031796d74 100644
--- a/lang/ko/mail.php
+++ b/lang/ko/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => '오픈소스 소셜 미디어 예약 발행 도구',
+ 'tagline' => ':brand 팀에서 보냄',
'manage_notifications' => '알림 관리',
'signoff' => '감사합니다.',
'team' => 'TryPost 팀',
@@ -16,7 +16,7 @@ return [
'title' => ':platform 계정을 다시 연결해야 합니다',
'preview' => '게시물 예약을 계속하려면 :workspace의 :platform 계정을 다시 연결하세요.',
'heading' => '계정 연결 해제됨',
- 'intro' => '워크스페이스 <strong>:workspace</strong>에서 <strong>:platform</strong> 계정 <strong>:account</strong>의 연결이 해제되었습니다.',
+ 'intro' => '아래 계정이 :workspace 워크스페이스에서 연결 해제되었습니다.',
'reasons_title' => '다음과 같은 이유일 수 있습니다:',
'reason_expired' => '액세스 토큰이 만료되었습니다',
'reason_revoked' => 'TryPost의 접근 권한을 취소했습니다',
@@ -99,13 +99,17 @@ return [
'button' => '초안에서 보기',
],
+ 'post_preview' => [
+ 'no_text' => '텍스트 없는 게시물',
+ 'error' => '오류 내용',
+ ],
+
'post_publish_failed' => [
'subject' => ':workspace에서 게시물 발행에 실패했습니다',
'title' => '게시물 발행에 실패했습니다',
- 'preview' => '하나 이상의 플랫폼에서 발행하지 못했습니다.',
+ 'preview' => '게시물 발행에 실패했습니다',
'heading' => '게시물 발행에 실패했습니다',
- 'body' => '워크스페이스 :workspace의 예약 게시물이 하나 이상의 플랫폼에서 발행되지 않았습니다.',
- 'platforms_title' => '실패한 플랫폼:',
+ 'body' => ':workspace의 게시물을 게시하지 못했습니다.',
'button' => '게시물 보기',
],
@@ -115,9 +119,8 @@ return [
'preview' => '게시물이 정상적으로 발행되었습니다.',
'heading' => '게시물이 발행되었습니다',
'body' => '워크스페이스 :workspace의 게시물이 정상적으로 발행되었습니다.',
- 'platforms_title' => '발행된 플랫폼:',
- 'view_post' => '게시물 보기',
- 'button' => '게시물 보기',
+ 'button' => '소셜 미디어에서 보기',
+ 'open_in_app' => 'TryPost에서 열기',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => '반복된 실패로 웹훅이 일시정지되었습니다',
'preview' => '연속 5회 전달에 실패한 뒤 웹훅을 일시정지했습니다.',
'heading' => '반복된 실패로 웹훅이 일시정지되었습니다',
- 'body' => ':endpoint의 웹훅을 연속 5회 전달 실패 후 일시정지했습니다. Endpoint를 확인한 뒤 웹훅 상세 페이지에서 다시 사용하세요.',
+ 'body' => '연속 5회 전달에 실패한 뒤 웹훅을 일시정지했습니다.',
+ 'next_steps' => 'Endpoint를 확인한 뒤 웹훅 상세 페이지에서 다시 사용하세요.',
'button' => '웹훅 보기',
],
diff --git a/lang/nl/mail.php b/lang/nl/mail.php
index c18f2043a..86438f826 100644
--- a/lang/nl/mail.php
+++ b/lang/nl/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Open-source tool om social media in te plannen',
+ 'tagline' => 'Verzonden door het :brand-team',
'manage_notifications' => 'Meldingen beheren',
'signoff' => 'Met vriendelijke groet,',
'team' => 'Het TryPost-team',
@@ -16,7 +16,7 @@ return [
'title' => 'Je :platform-account moet opnieuw worden verbonden',
'preview' => 'Verbind je :platform-account in :workspace opnieuw om posts te blijven inplannen.',
'heading' => 'Account losgekoppeld',
- 'intro' => 'Je <strong>:platform</strong>-account <strong>:account</strong> is losgekoppeld van de werkruimte <strong>:workspace</strong>.',
+ 'intro' => 'Het onderstaande account is losgekoppeld van de werkruimte :workspace.',
'reasons_title' => 'Dit kan zijn gebeurd omdat:',
'reason_expired' => 'Je toegangstoken is verlopen',
'reason_revoked' => 'Je hebt de toegang van TryPost ingetrokken',
@@ -99,13 +99,17 @@ return [
'button' => 'Bekijken in concepten',
],
+ 'post_preview' => [
+ 'no_text' => 'Bericht zonder tekst',
+ 'error' => 'Wat er misging',
+ ],
+
'post_publish_failed' => [
'subject' => 'Je post in :workspace kon niet worden gepubliceerd',
'title' => 'Je post kon niet worden gepubliceerd',
- 'preview' => 'Een of meer platforms konden niet publiceren.',
+ 'preview' => 'Je post kon niet worden gepubliceerd',
'heading' => 'Je post kon niet worden gepubliceerd',
- 'body' => 'Je ingeplande post in de werkruimte :workspace kon op een of meer platforms niet worden gepubliceerd.',
- 'platforms_title' => 'Mislukte platforms:',
+ 'body' => 'Je bericht in :workspace kon niet worden gepubliceerd.',
'button' => 'Post bekijken',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Je post is succesvol gepubliceerd.',
'heading' => 'Je post is gepubliceerd',
'body' => 'Je post in de werkruimte :workspace is succesvol gepubliceerd.',
- 'platforms_title' => 'Gepubliceerd op:',
- 'view_post' => 'Post bekijken',
- 'button' => 'Post bekijken',
+ 'button' => 'Bekijk op social media',
+ 'open_in_app' => 'Open in TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook gepauzeerd na herhaalde fouten',
'preview' => 'We hebben een webhook gepauzeerd na 5 opeenvolgende afleverfouten.',
'heading' => 'Webhook gepauzeerd na herhaalde fouten',
- 'body' => 'We hebben de webhook op :endpoint gepauzeerd na 5 opeenvolgende afleverfouten. Controleer het endpoint en schakel het weer in op de webhookdetailpagina.',
+ 'body' => 'We hebben een webhook gepauzeerd na 5 opeenvolgende afleverfouten.',
+ 'next_steps' => 'Controleer het endpoint en schakel het weer in op de webhookdetailpagina.',
'button' => 'Webhook bekijken',
],
diff --git a/lang/pl/mail.php b/lang/pl/mail.php
index 3ee62fb10..a79d36e8a 100644
--- a/lang/pl/mail.php
+++ b/lang/pl/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Otwartoźródłowe narzędzie do planowania postów w social mediach',
+ 'tagline' => 'Wysłane przez zespół :brand',
'manage_notifications' => 'Zarządzaj powiadomieniami',
'signoff' => 'Pozdrawiamy,',
'team' => 'Zespół TryPost',
@@ -16,7 +16,7 @@ return [
'title' => 'Twoje konto :platform wymaga ponownego połączenia',
'preview' => 'Połącz ponownie konto :platform w :workspace, aby dalej planować posty.',
'heading' => 'Konto rozłączone',
- 'intro' => 'Twoje konto <strong>:platform</strong> <strong>:account</strong> zostało rozłączone z przestrzenią roboczą <strong>:workspace</strong>.',
+ 'intro' => 'Poniższe konto zostało odłączone od przestrzeni roboczej :workspace.',
'reasons_title' => 'Mogło się to stać, ponieważ:',
'reason_expired' => 'Twój token dostępu wygasł',
'reason_revoked' => 'Cofnięto dostęp dla TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'Zobacz w wersjach roboczych',
],
+ 'post_preview' => [
+ 'no_text' => 'Post bez tekstu',
+ 'error' => 'Co się stało',
+ ],
+
'post_publish_failed' => [
'subject' => 'Nie udało się opublikować posta w :workspace',
'title' => 'Nie udało się opublikować posta',
- 'preview' => 'Co najmniej jedna platforma nie opublikowała posta.',
+ 'preview' => 'Nie udało się opublikować posta',
'heading' => 'Nie udało się opublikować posta',
- 'body' => 'Twój zaplanowany post w przestrzeni roboczej :workspace nie został opublikowany na co najmniej jednej platformie.',
- 'platforms_title' => 'Platformy z błędem:',
+ 'body' => 'Nie udało się opublikować Twojego posta w :workspace.',
'button' => 'Zobacz post',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Twój post został opublikowany pomyślnie.',
'heading' => 'Twój post został opublikowany',
'body' => 'Twój post w przestrzeni roboczej :workspace został opublikowany pomyślnie.',
- 'platforms_title' => 'Opublikowano na:',
- 'view_post' => 'Zobacz post',
- 'button' => 'Zobacz post',
+ 'button' => 'Zobacz w serwisie',
+ 'open_in_app' => 'Otwórz w TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook wstrzymany po powtarzających się błędach',
'preview' => 'Wstrzymaliśmy webhook po 5 kolejnych błędach dostarczenia.',
'heading' => 'Webhook wstrzymany po powtarzających się błędach',
- 'body' => 'Wstrzymaliśmy webhook pod adresem :endpoint po 5 kolejnych błędach dostarczenia. Sprawdź endpoint i włącz go ponownie na stronie szczegółów webhooka.',
+ 'body' => 'Wstrzymaliśmy webhook po 5 kolejnych błędach dostarczenia.',
+ 'next_steps' => 'Sprawdź endpoint i włącz go ponownie na stronie szczegółów webhooka.',
'button' => 'Zobacz webhook',
],
diff --git a/lang/pt-BR/mail.php b/lang/pt-BR/mail.php
index 74e4c3c69..f436b5e1f 100644
--- a/lang/pt-BR/mail.php
+++ b/lang/pt-BR/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Ferramenta open-source de agendamento para redes sociais',
+ 'tagline' => 'Enviado pela equipe :brand',
'manage_notifications' => 'Gerenciar notificações',
'signoff' => 'Atenciosamente,',
'team' => 'A equipe TryPost',
@@ -16,7 +16,7 @@ return [
'title' => 'Sua conta do :platform precisa ser reconectada',
'preview' => 'Reconecte sua conta do :platform em :workspace para continuar agendando publicações.',
'heading' => 'Conta desconectada',
- 'intro' => 'Sua conta do <strong>:platform</strong> <strong>:account</strong> foi desconectada da área de trabalho <strong>:workspace</strong>.',
+ 'intro' => 'A conta abaixo foi desconectada da área de trabalho :workspace.',
'reasons_title' => 'Isso pode ter acontecido porque:',
'reason_expired' => 'Seu token de acesso expirou',
'reason_revoked' => 'Você revogou o acesso do TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'Ver nos rascunhos',
],
+ 'post_preview' => [
+ 'no_text' => 'Publicação sem texto',
+ 'error' => 'O que aconteceu',
+ ],
+
'post_publish_failed' => [
'subject' => 'Sua publicação falhou em :workspace',
'title' => 'Sua publicação falhou',
- 'preview' => 'Uma ou mais plataformas falharam ao publicar.',
+ 'preview' => 'Sua publicação falhou',
'heading' => 'Sua publicação falhou',
- 'body' => 'Sua publicação agendada na área de trabalho :workspace falhou em uma ou mais plataformas.',
- 'platforms_title' => 'Plataformas com falha:',
+ 'body' => 'Não foi possível publicar seu post em :workspace.',
'button' => 'Ver publicação',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Sua publicação foi publicada com sucesso.',
'heading' => 'Sua publicação foi ao ar',
'body' => 'Sua publicação na área de trabalho :workspace foi publicada com sucesso.',
- 'platforms_title' => 'Publicada em:',
- 'view_post' => 'Ver publicação',
- 'button' => 'Ver publicação',
+ 'button' => 'Ver na rede social',
+ 'open_in_app' => 'Abrir no TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook pausado após falhas repetidas',
'preview' => 'Pausamos um webhook após 5 falhas consecutivas de entrega.',
'heading' => 'Webhook pausado após falhas repetidas',
- 'body' => 'Pausamos o webhook em :endpoint após 5 falhas consecutivas de entrega. Revise o endpoint e reative-o na página de detalhes do webhook.',
+ 'body' => 'Pausamos um webhook após 5 falhas consecutivas de entrega.',
+ 'next_steps' => 'Revise o endpoint e reative-o na página de detalhes do webhook.',
'button' => 'Ver webhook',
],
diff --git a/lang/ru/mail.php b/lang/ru/mail.php
index 1aa896274..460ff9651 100644
--- a/lang/ru/mail.php
+++ b/lang/ru/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Открытый инструмент для планирования постов в соцсетях',
+ 'tagline' => 'Отправлено командой :brand',
'manage_notifications' => 'Управлять уведомлениями',
'signoff' => 'С уважением,',
'team' => 'Команда TryPost',
@@ -16,7 +16,7 @@ return [
'title' => 'Аккаунт :platform нужно переподключить',
'preview' => 'Переподключите аккаунт :platform в :workspace, чтобы продолжить планировать посты.',
'heading' => 'Аккаунт отключён',
- 'intro' => 'Ваш аккаунт <strong>:platform</strong> <strong>:account</strong> был отключён от рабочего пространства <strong>:workspace</strong>.',
+ 'intro' => 'Следующий аккаунт отключён от рабочего пространства :workspace.',
'reasons_title' => 'Это могло произойти потому, что:',
'reason_expired' => 'Срок действия токена доступа истёк',
'reason_revoked' => 'Вы отозвали доступ у TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'Посмотреть в черновиках',
],
+ 'post_preview' => [
+ 'no_text' => 'Публикация без текста',
+ 'error' => 'Что произошло',
+ ],
+
'post_publish_failed' => [
'subject' => 'Не удалось опубликовать пост в :workspace',
'title' => 'Не удалось опубликовать пост',
- 'preview' => 'Одна или несколько платформ не смогли опубликовать пост.',
+ 'preview' => 'Не удалось опубликовать пост',
'heading' => 'Не удалось опубликовать пост',
- 'body' => 'Ваш запланированный пост в рабочем пространстве :workspace не опубликовался на одной или нескольких платформах.',
- 'platforms_title' => 'Платформы с ошибкой:',
+ 'body' => 'Не удалось опубликовать ваш пост в :workspace.',
'button' => 'Открыть пост',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Ваш пост успешно опубликован.',
'heading' => 'Ваш пост опубликован',
'body' => 'Ваш пост в рабочем пространстве :workspace успешно опубликован.',
- 'platforms_title' => 'Опубликовано в:',
- 'view_post' => 'Открыть пост',
- 'button' => 'Открыть пост',
+ 'button' => 'Открыть в соцсети',
+ 'open_in_app' => 'Открыть в TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Вебхук приостановлен после повторных ошибок',
'preview' => 'Мы приостановили вебхук после 5 подряд неудачных доставок.',
'heading' => 'Вебхук приостановлен после повторных ошибок',
- 'body' => 'Мы приостановили вебхук на :endpoint после 5 подряд неудачных доставок. Проверьте endpoint и включите его снова на странице вебхука.',
+ 'body' => 'Мы приостановили вебхук после 5 подряд неудачных доставок.',
+ 'next_steps' => 'Проверьте endpoint и включите его снова на странице вебхука.',
'button' => 'Открыть вебхук',
],
diff --git a/lang/tr/mail.php b/lang/tr/mail.php
index 2f4d79ee2..7132aa7b0 100644
--- a/lang/tr/mail.php
+++ b/lang/tr/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Sosyal medya paylaşımlarını planlamak için açık kaynaklı araç',
+ 'tagline' => ':brand ekibi tarafından gönderildi',
'manage_notifications' => 'Bildirimleri yönet',
'signoff' => 'Saygılarımızla,',
'team' => 'TryPost Ekibi',
@@ -16,7 +16,7 @@ return [
'title' => ':platform hesabının yeniden bağlanması gerekiyor',
'preview' => 'Gönderi planlamaya devam etmek için :workspace çalışma alanındaki :platform hesabını yeniden bağla.',
'heading' => 'Hesap bağlantısı kesildi',
- 'intro' => '<strong>:platform</strong> hesabın <strong>:account</strong>, <strong>:workspace</strong> çalışma alanından koptu.',
+ 'intro' => 'Aşağıdaki hesabın :workspace çalışma alanıyla bağlantısı kesildi.',
'reasons_title' => 'Bunun nedeni şunlar olabilir:',
'reason_expired' => 'Erişim jetonunun süresi doldu',
'reason_revoked' => 'TryPost erişimini iptal ettin',
@@ -99,13 +99,17 @@ return [
'button' => 'Taslaklarda görüntüle',
],
+ 'post_preview' => [
+ 'no_text' => 'Metinsiz gönderi',
+ 'error' => 'Ne oldu',
+ ],
+
'post_publish_failed' => [
'subject' => ':workspace çalışma alanında gönderin paylaşılamadı',
'title' => 'Gönderin paylaşılamadı',
- 'preview' => 'Bir veya daha fazla platformda paylaşım başarısız oldu.',
+ 'preview' => 'Gönderin paylaşılamadı',
'heading' => 'Gönderin paylaşılamadı',
- 'body' => ':workspace çalışma alanında planladığın gönderi, bir veya daha fazla platformda paylaşılamadı.',
- 'platforms_title' => 'Başarısız platformlar:',
+ 'body' => ':workspace içindeki gönderiniz yayınlanamadı.',
'button' => 'Gönderiyi gör',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Gönderin başarıyla paylaşıldı.',
'heading' => 'Gönderin paylaşıldı',
'body' => ':workspace çalışma alanındaki gönderin başarıyla paylaşıldı.',
- 'platforms_title' => 'Şurada paylaşıldı:',
- 'view_post' => 'Gönderiyi gör',
- 'button' => 'Gönderiyi gör',
+ 'button' => 'Sosyal ağda görüntüle',
+ 'open_in_app' => 'TryPost’ta aç',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook tekrarlanan hatalardan sonra duraklatıldı',
'preview' => 'Üst üste 5 teslim hatasından sonra bir webhooku duraklattık.',
'heading' => 'Webhook tekrarlanan hatalardan sonra duraklatıldı',
- 'body' => ':endpoint adresindeki webhooku üst üste 5 teslim hatasından sonra duraklattık. Endpointi gözden geçirin ve webhook ayrıntı sayfasından yeniden etkinleştirin.',
+ 'body' => 'Üst üste 5 teslim hatasından sonra bir webhooku duraklattık.',
+ 'next_steps' => 'Endpointi gözden geçirin ve webhook ayrıntı sayfasından yeniden etkinleştirin.',
'button' => 'Webhooku gör',
],
diff --git a/lang/uk/mail.php b/lang/uk/mail.php
index 2ab6e36ad..31d55e206 100644
--- a/lang/uk/mail.php
+++ b/lang/uk/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => 'Відкритий інструмент для планування дописів у соцмережах',
+ 'tagline' => 'Надіслано командою :brand',
'manage_notifications' => 'Керувати сповіщеннями',
'signoff' => 'З повагою,',
'team' => 'Команда TryPost',
@@ -16,7 +16,7 @@ return [
'title' => 'Обліковий запис :platform потребує повторного підключення',
'preview' => 'Підключіть обліковий запис :platform у :workspace повторно, щоб далі планувати дописи.',
'heading' => 'Обліковий запис відключено',
- 'intro' => 'Ваш обліковий запис <strong>:platform</strong> <strong>:account</strong> було відключено від робочого простору <strong>:workspace</strong>.',
+ 'intro' => 'Наведений нижче обліковий запис від’єднано від робочого простору :workspace.',
'reasons_title' => 'Це могло статися, тому що:',
'reason_expired' => 'Термін дії токена доступу минув',
'reason_revoked' => 'Ви скасували доступ для TryPost',
@@ -99,13 +99,17 @@ return [
'button' => 'Переглянути в чернетках',
],
+ 'post_preview' => [
+ 'no_text' => 'Публікація без тексту',
+ 'error' => 'Що сталося',
+ ],
+
'post_publish_failed' => [
'subject' => 'Не вдалося опублікувати допис у :workspace',
'title' => 'Не вдалося опублікувати допис',
- 'preview' => 'Одна або кілька платформ не змогли опублікувати допис.',
+ 'preview' => 'Не вдалося опублікувати допис',
'heading' => 'Не вдалося опублікувати допис',
- 'body' => 'Ваш запланований допис у робочому просторі :workspace не опублікувався на одній або кількох платформах.',
- 'platforms_title' => 'Платформи з помилкою:',
+ 'body' => 'Не вдалося опублікувати ваш допис у :workspace.',
'button' => 'Переглянути допис',
],
@@ -115,9 +119,8 @@ return [
'preview' => 'Ваш допис успішно опубліковано.',
'heading' => 'Ваш допис опубліковано',
'body' => 'Ваш допис у робочому просторі :workspace успішно опубліковано.',
- 'platforms_title' => 'Опубліковано в:',
- 'view_post' => 'Переглянути допис',
- 'button' => 'Переглянути допис',
+ 'button' => 'Відкрити в соцмережі',
+ 'open_in_app' => 'Відкрити в TryPost',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Вебхук призупинено після повторних помилок',
'preview' => 'Ми призупинили вебхук після 5 підряд невдалих доставок.',
'heading' => 'Вебхук призупинено після повторних помилок',
- 'body' => 'Ми призупинили вебхук на :endpoint після 5 підряд невдалих доставок. Перевірте endpoint і ввімкніть його знову на сторінці вебхука.',
+ 'body' => 'Ми призупинили вебхук після 5 підряд невдалих доставок.',
+ 'next_steps' => 'Перевірте endpoint і ввімкніть його знову на сторінці вебхука.',
'button' => 'Відкрити вебхук',
],
diff --git a/lang/zh/mail.php b/lang/zh/mail.php
index 64dc7f66d..40b514692 100644
--- a/lang/zh/mail.php
+++ b/lang/zh/mail.php
@@ -5,7 +5,7 @@ declare(strict_types=1);
return [
'layout' => [
- 'tagline' => '开源的社交媒体排期发布工具',
+ 'tagline' => '由 :brand 团队发送',
'manage_notifications' => '管理通知',
'signoff' => '祝好,',
'team' => 'TryPost 团队',
@@ -16,7 +16,7 @@ return [
'title' => ':platform 账号需要重新连接',
'preview' => '请重新连接 :workspace 中的 :platform 账号,以继续排期发布。',
'heading' => '账号已断开',
- 'intro' => '你的 <strong>:platform</strong> 账号 <strong>:account</strong> 已从工作区 <strong>:workspace</strong> 断开。',
+ 'intro' => '以下账号已与工作区 :workspace 断开连接。',
'reasons_title' => '可能的原因:',
'reason_expired' => '访问令牌已过期',
'reason_revoked' => '你撤销了 TryPost 的访问权限',
@@ -99,13 +99,17 @@ return [
'button' => '在草稿中查看',
],
+ 'post_preview' => [
+ 'no_text' => '无文字的帖子',
+ 'error' => '错误详情',
+ ],
+
'post_publish_failed' => [
'subject' => ':workspace 中的内容发布失败',
'title' => '内容发布失败',
- 'preview' => '有一个或多个平台发布失败。',
+ 'preview' => '内容发布失败',
'heading' => '内容发布失败',
- 'body' => '工作区 :workspace 中已排期的内容在一个或多个平台上发布失败。',
- 'platforms_title' => '发布失败的平台:',
+ 'body' => '无法发布 :workspace 中的帖子。',
'button' => '查看内容',
],
@@ -115,9 +119,8 @@ return [
'preview' => '你的内容已成功发布。',
'heading' => '内容已发布',
'body' => '工作区 :workspace 中的内容已成功发布。',
- 'platforms_title' => '已发布到:',
- 'view_post' => '查看内容',
- 'button' => '查看内容',
+ 'button' => '在社交平台查看',
+ 'open_in_app' => '在 TryPost 中打开',
],
'webhook_paused' => [
@@ -125,7 +128,8 @@ return [
'title' => 'Webhook 因连续失败已暂停',
'preview' => '连续 5 次投递失败后,我们暂停了一个 webhook。',
'heading' => 'Webhook 因连续失败已暂停',
- 'body' => '连续 5 次投递失败后,我们暂停了 :endpoint 上的 webhook。请检查该 endpoint,并在 webhook 详情页重新启用。',
+ 'body' => '连续 5 次投递失败后,我们暂停了一个 webhook。',
+ 'next_steps' => '请检查该 endpoint,并在 webhook 详情页重新启用。',
'button' => '查看 webhook',
],
diff --git a/maizzle/components/alert.html b/maizzle/components/alert.html
new file mode 100644
index 000000000..2f18f12fa
--- /dev/null
+++ b/maizzle/components/alert.html
@@ -0,0 +1,14 @@
+<script props>
+ module.exports = {
+ title: `@{{ __('${props['title-key']}') }}`,
+ }
+</script>
+
+<table role="presentation" class="w-full mt-4">
+ <tr>
+ <td class="rounded-xl border border-solid border-border bg-muted p-5 sm:p-4">
+ <p class="m-0 text-sm leading-5 font-semibold text-destructive-text">{!! title !!}</p>
+ <p class="m-0 mt-1.5 text-sm leading-[22px] text-foreground"><yield /></p>
+ </td>
+ </tr>
+</table>
diff --git a/maizzle/components/button.html b/maizzle/components/button.html
index 22336c72f..bc32ff5a0 100644
--- a/maizzle/components/button.html
+++ b/maizzle/components/button.html
@@ -4,14 +4,20 @@
left: 'text-left',
center: 'text-center',
right: 'text-right',
- }[props.align] || ''
+ }[props.align] || 'text-center'
+
+ let variant = props.variant === 'secondary'
+ ? 'bg-surface border-border'
+ : 'bg-primary border-primary'
+
+ let size = props.size === 'sm'
+ ? 'px-4 py-2.5 text-sm leading-5 whitespace-nowrap sm:px-1.5 sm:text-xs'
+ : 'px-6 py-3 text-base leading-6'
let styles = [
'display: inline-block;',
'text-decoration: none;',
- 'padding: 16px 24px;',
- 'font-size: 16px;',
- 'line-height: 1;',
+ 'font-weight: 600;',
'border-radius: 8px;',
]
@@ -19,18 +25,16 @@
if (props['bg-color'] && !hasBgClass()) {
styles.push(`background-color: ${props['bg-color']};`)
- } else {
- styles.push('background-color: #7c3aed;')
}
if (props.color) {
styles.push(`color: ${props.color};`)
- } else {
- styles.push('color: #ffffff;')
}
module.exports = {
align,
+ variant,
+ size,
href: props.href,
styles: styles.join(''),
msoPt: props['mso-pt'] || '16px',
@@ -39,7 +43,7 @@
</script>
<div class="{{ align }}">
- <a attributes href="{{ href }}" style="{{ styles }}">
+ <a attributes href="{{ href }}" class="{{ variant }} {{ size }} border border-solid text-foreground text-center" style="{{ styles }}">
<outlook trim>
<i class="mso-font-width-[150%]" style="mso-text-raise: {{ msoPb }};" hidden>&emsp;</i>
</outlook>
@@ -50,4 +54,4 @@
<i class="mso-font-width-[150%]" hidden>&emsp;&#8203;</i>
</outlook>
</a>
-</div>
\ No newline at end of file
+</div>
diff --git a/maizzle/components/channel-identity.html b/maizzle/components/channel-identity.html
new file mode 100644
index 000000000..0076cf813
--- /dev/null
+++ b/maizzle/components/channel-identity.html
@@ -0,0 +1,26 @@
+<script props>
+ module.exports = {
+ platformExpression: props.platform,
+ accountNameExpression: props['account-name'],
+ }
+</script>
+
+@php
+ $emailChannelPlatform = {!! platformExpression !!};
+ $emailChannelName = {!! accountNameExpression !!};
+@endphp
+
+<table role="presentation" class="w-full">
+ <tr>
+ <td class="w-11 align-middle">
+ <img src="@{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}"
+ width="32" height="32" alt="" class="block rounded-lg">
+ </td>
+ <td class="align-middle">
+ <p class="m-0 text-base leading-5 font-semibold text-foreground">@{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p class="m-0 mt-0.5 text-[13px] leading-[18px] text-muted-foreground">@{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+</table>
diff --git a/maizzle/components/channel-list.html b/maizzle/components/channel-list.html
new file mode 100644
index 000000000..f8e017c46
--- /dev/null
+++ b/maizzle/components/channel-list.html
@@ -0,0 +1,15 @@
+<script props>
+ module.exports = {
+ channelsExpression: props.channels || '$channels',
+ }
+</script>
+
+@foreach({!! channelsExpression !!} as $emailChannel)
+ <table role="presentation" class="w-full mt-3">
+ <tr>
+ <td class="rounded-xl border border-solid border-border bg-surface p-4">
+ <x-channel-identity platform="$emailChannel->platform" account-name="$emailChannel->display_name" />
+ </td>
+ </tr>
+ </table>
+@endforeach
diff --git a/maizzle/components/footer-authenticated.html b/maizzle/components/footer-authenticated.html
index b9d8a00fa..f0a409cbd 100644
--- a/maizzle/components/footer-authenticated.html
+++ b/maizzle/components/footer-authenticated.html
@@ -1,48 +1,7 @@
-<tr>
- <td align="center" class="text-center text-zinc-600 text-xs p-6">
- <p class="m-0 mb-2">
- @{{ __('mail.layout.tagline') }}
- </p>
-
- <p class="m-0 mt-2">
- <a href="@{{ route('app.notifications.preferences') }}" target="_blank"
- class="text-zinc-600 [text-decoration:none] hover:![text-decoration:underline]">
- @{{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
-
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" class="mx-auto mt-4">
- <tr>
- <td class="px-1">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="@{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub">
- </a>
- </td>
- <td class="px-1">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="@{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X">
- </a>
- </td>
- <td class="px-1">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="@{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube">
- </a>
- </td>
- <td class="px-1">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="@{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord">
- </a>
- </td>
- <td class="px-1">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="@{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram">
- </a>
- </td>
- </tr>
- </table>
-
- <p class="m-0 mt-3">
- &copy; @{{ date('Y') }} TryPost.it
- </p>
- </td>
-</tr>
+<x-footer>
+ <p class="m-0 mt-2">
+ <a href="@{{ route('app.notifications.preferences') }}" target="_blank" class="text-muted-foreground underline">
+ @{{ __('mail.layout.manage_notifications') }}
+ </a>
+ </p>
+</x-footer>
diff --git a/maizzle/components/footer.html b/maizzle/components/footer.html
index 6fe68efd0..80bfde2e1 100644
--- a/maizzle/components/footer.html
+++ b/maizzle/components/footer.html
@@ -1,9 +1,11 @@
<tr>
- <td align="center" class="text-center text-zinc-600 text-xs p-6">
+ <td align="center" class="text-center text-muted-foreground text-xs leading-5 px-6 py-6">
<p class="m-0 mb-2">
- @{{ __('mail.layout.tagline') }}
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
</p>
+ <yield />
+
<table role="presentation" cellpadding="0" cellspacing="0" border="0" class="mx-auto mt-3">
<tr>
<td class="px-1">
@@ -27,7 +29,7 @@
</a>
</td>
<td class="px-1">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
<img src="@{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram">
</a>
</td>
diff --git a/maizzle/components/header.html b/maizzle/components/header.html
index 8dbb4ce69..f8d3fabb9 100644
--- a/maizzle/components/header.html
+++ b/maizzle/components/header.html
@@ -1,5 +1,5 @@
-<div class="my-12 sm:my-8 text-center">
+<div class="text-center">
<a href="https://trypost.it" target="_blank">
<img src="@{{ asset('/images/emails/logo-header.png') }}" width="150" height="33" alt="TryPost" style="width: 150px; height: auto;">
</a>
-</div>
\ No newline at end of file
+</div>
diff --git a/maizzle/components/heading.html b/maizzle/components/heading.html
new file mode 100644
index 000000000..88b43a100
--- /dev/null
+++ b/maizzle/components/heading.html
@@ -0,0 +1,3 @@
+<h1 class="m-0 mb-6 font-heading text-2xl font-semibold leading-8 text-foreground">
+ <yield />
+</h1>
diff --git a/maizzle/components/list.html b/maizzle/components/list.html
new file mode 100644
index 000000000..b858c6dde
--- /dev/null
+++ b/maizzle/components/list.html
@@ -0,0 +1,3 @@
+<ul attributes class="m-0 mt-2 px-5 leading-6">
+ <yield />
+</ul>
diff --git a/maizzle/components/message.html b/maizzle/components/message.html
new file mode 100644
index 000000000..d737a7e8b
--- /dev/null
+++ b/maizzle/components/message.html
@@ -0,0 +1,37 @@
+<script props>
+ module.exports = {
+ authenticated: props.authenticated === true || props.authenticated === 'true',
+ }
+</script>
+
+<table role="presentation" class="w-full bg-canvas font-sans">
+ <tr>
+ <td align="center" class="px-4">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" class="w-full max-w-[552px]">
+ <tr>
+ <td class="py-8">
+ <x-header />
+ </td>
+ </tr>
+ <tr>
+ <td align="@{{ $direction === 'rtl' ? 'right' : 'left' }}"
+ class="rounded-xl border border-solid border-border bg-surface p-8 sm:p-6 text-base leading-6 text-foreground">
+ <yield />
+ </td>
+ </tr>
+ <if condition="authenticated">
+ <x-footer-authenticated />
+ </if>
+ <else>
+ <x-footer />
+ </else>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+</table>
diff --git a/maizzle/components/post-preview.html b/maizzle/components/post-preview.html
new file mode 100644
index 000000000..ae7e68aa3
--- /dev/null
+++ b/maizzle/components/post-preview.html
@@ -0,0 +1,18 @@
+<table role="presentation" class="w-full mt-6">
+ <tr>
+ <td class="rounded-xl border border-solid border-border p-5 sm:p-4">
+ <x-channel-identity platform="$publication['platform']" account-name="$publication['accountName']" />
+
+ @if($postPreview['text'] !== '')
+ <p class="m-0 mt-5 leading-6 text-foreground" style="white-space: pre-line;">@{{ $postPreview['text'] }}</p>
+ @endif
+
+ @if($postPreview['image'])
+ <img src="@{{ $postPreview['image']['url'] }}" alt="@{{ $postPreview['image']['alt'] }}"
+ width="@{{ $postPreview['image']['width'] }}" class="mt-5 h-auto max-w-full rounded-lg">
+ @elseif($postPreview['text'] === '')
+ <p class="m-0 mt-5 text-sm text-muted-foreground">@{{ $postPreview['attachment'] ?: __('mail.post_preview.no_text') }}</p>
+ @endif
+ </td>
+ </tr>
+</table>
diff --git a/maizzle/layouts/main.html b/maizzle/layouts/main.html
index 300326c79..4e4f817b9 100644
--- a/maizzle/layouts/main.html
+++ b/maizzle/layouts/main.html
@@ -1,5 +1,10 @@
+@use('App\Enums\User\Locale')
+@php
+ $direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
+
<!DOCTYPE html>
-<html lang="@{{ str_replace('_', '-', app()->getLocale()) }}" dir="@{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="@{{ str_replace('_', '-', app()->getLocale()) }}" dir="@{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
@@ -26,11 +31,15 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
@tailwind components;
@tailwind utilities;
+ .email-context {
+ @apply mt-4 rounded-lg bg-muted p-4;
+ }
+
img {
@apply max-w-full align-middle;
}
@@ -38,7 +47,7 @@
<stack name="head" />
</head>
-<body class="m-0 p-0 w-full [word-break:break-word] [-webkit-font-smoothing:antialiased] {{ page.bodyClass || '' }}">
+<body class="m-0 p-0 w-full bg-canvas [word-break:break-word] [-webkit-font-smoothing:antialiased] {{ page.bodyClass || '' }}">
@if(isset($previewText))
<div class="hidden">
@{{ $previewText }}
diff --git a/maizzle/tailwind.config.js b/maizzle/tailwind.config.js
index be42a5d52..d6310d766 100644
--- a/maizzle/tailwind.config.js
+++ b/maizzle/tailwind.config.js
@@ -9,4 +9,26 @@ module.exports = {
'./templates/**/*.html',
'./layouts/**/*.html',
],
+ theme: {
+ extend: {
+ colors: {
+ canvas: '#f7f6f3',
+ surface: '#ffffff',
+ foreground: '#292928',
+ muted: '#f7f6f3',
+ 'muted-foreground': '#5a5a59',
+ border: '#eae8e5',
+ primary: '#ddd6fe',
+ 'primary-text': '#6d28d9',
+ 'success-subtle': '#d9f1d1',
+ 'success-text': '#337046',
+ 'critical-subtle': '#ffdbd6',
+ 'destructive-text': '#7f0f00',
+ },
+ fontFamily: {
+ sans: ['Inter', 'Arial', 'Helvetica', 'sans-serif'],
+ heading: ['Outfit', 'Inter', 'Arial', 'Helvetica', 'sans-serif'],
+ },
+ },
+ },
}
diff --git a/maizzle/templates/account-disconnected.html b/maizzle/templates/account-disconnected.html
index 24a9b44e2..760a7f180 100644
--- a/maizzle/templates/account-disconnected.html
+++ b/maizzle/templates/account-disconnected.html
@@ -1,48 +1,39 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.account_disconnected.heading') }}
+ </x-heading>
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.account_disconnected.heading') }}
- </h1>
+ <p class="m-0 leading-6">
+ {!! __('mail.account_disconnected.intro', ['workspace' => '<strong>'.e($workspaceName).'</strong>']) !!}
+ </p>
- <p class="m-0 leading-6">
- {!! __('mail.account_disconnected.intro', ['platform' => '<strong>'.e($platformName).'</strong>', 'account' => '<strong>'.e($accountName).'</strong>', 'workspace' => '<strong>'.e($workspaceName).'</strong>']) !!}
- </p>
+ <table role="presentation" class="w-full mt-6">
+ <tr>
+ <td class="rounded-xl border border-solid border-border p-5 sm:p-4">
+ <x-channel-identity platform="$account->platform" account-name="$account->accountDisplayName()" />
+ </td>
+ </tr>
+ </table>
- <p class="m-0 mt-4 leading-6">
- @{{ __('mail.account_disconnected.reasons_title') }}
- </p>
+ <p class="m-0 mt-4 leading-6">
+ @{{ __('mail.account_disconnected.reasons_title') }}
+ </p>
- <ul class="m-0 mt-2 pl-5 leading-6">
- <li>@{{ __('mail.account_disconnected.reason_expired') }}</li>
- <li>@{{ __('mail.account_disconnected.reason_revoked') }}</li>
- <li>@{{ __('mail.account_disconnected.reason_error') }}</li>
- </ul>
+ <x-list>
+ <li>@{{ __('mail.account_disconnected.reason_expired') }}</li>
+ <li>@{{ __('mail.account_disconnected.reason_revoked') }}</li>
+ <li>@{{ __('mail.account_disconnected.reason_error') }}</li>
+ </x-list>
- <p class="m-0 mt-4 leading-6">
- @{{ __('mail.account_disconnected.reconnect_cta') }}
- </p>
+ <p class="m-0 mt-4 leading-6">
+ @{{ __('mail.account_disconnected.reconnect_cta') }}
+ </p>
- <x-spacer height="24px" />
+ <x-spacer height="24px" />
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.account_disconnected.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
- </td>
- </tr>
- </table>
- </div>
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.account_disconnected.button') }}
+ </x-button>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/email-verification.html b/maizzle/templates/email-verification.html
index 874db682d..7ab7e91f8 100644
--- a/maizzle/templates/email-verification.html
+++ b/maizzle/templates/email-verification.html
@@ -1,44 +1,30 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-800 bg-white rounded shadow-sm">
- <p class="leading-6 mt-0">
- @{{ __('mail.email_verification.greeting', ['name' => $user->name]) }}
- </p>
+ <x-message>
+ <x-heading>@{{ __('mail.email_verification.subject') }}</x-heading>
- <p class="leading-6">
- @{{ __('mail.email_verification.body') }}
- </p>
+ <p class="leading-6 mt-0">
+ @{{ __('mail.email_verification.greeting', ['name' => $user->name]) }}
+ </p>
- <x-spacer height="24px" />
+ <p class="leading-6">
+ @{{ __('mail.email_verification.body') }}
+ </p>
- <div class="text-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.email_verification.button') }}
- </x-button>
- </div>
+ <x-spacer height="24px" />
- <x-spacer height="24px" />
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.email_verification.button') }}
+ </x-button>
- <p class="leading-6">
- @{{ __('mail.email_verification.ignore') }}
- </p>
- <p class="leading-6 mb-0">
- @{{ __('mail.layout.signoff') }}
- <br />
- @{{ __('mail.layout.team') }}
- </p>
- </td>
- </tr>
- </table>
- <x-footer />
- </td>
- </tr>
- </table>
- </div>
+ <x-spacer height="24px" />
+
+ <p class="leading-6">
+ @{{ __('mail.email_verification.ignore') }}
+ </p>
+ <p class="leading-6 mb-0">
+ @{{ __('mail.layout.signoff') }}
+ <br />
+ @{{ __('mail.layout.team') }}
+ </p>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/password-reset.html b/maizzle/templates/password-reset.html
index e1cdd7544..11d4b5803 100644
--- a/maizzle/templates/password-reset.html
+++ b/maizzle/templates/password-reset.html
@@ -1,44 +1,30 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-800 bg-white rounded shadow-sm">
- <p class="leading-6 mt-0">
- @{{ __('mail.password_reset.greeting', ['name' => $user->name]) }}
- </p>
+ <x-message>
+ <x-heading>@{{ __('mail.password_reset.subject') }}</x-heading>
- <p class="leading-6">
- @{{ __('mail.password_reset.body') }}
- </p>
+ <p class="leading-6 mt-0">
+ @{{ __('mail.password_reset.greeting', ['name' => $user->name]) }}
+ </p>
- <x-spacer height="24px" />
+ <p class="leading-6">
+ @{{ __('mail.password_reset.body') }}
+ </p>
- <div class="text-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.password_reset.button') }}
- </x-button>
- </div>
+ <x-spacer height="24px" />
- <x-spacer height="24px" />
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.password_reset.button') }}
+ </x-button>
- <p class="leading-6">
- @{{ __('mail.password_reset.expiry') }}
- </p>
- <p class="leading-6 mb-0">
- @{{ __('mail.layout.signoff') }}
- <br />
- @{{ __('mail.layout.team') }}
- </p>
- </td>
- </tr>
- </table>
- <x-footer />
- </td>
- </tr>
- </table>
- </div>
+ <x-spacer height="24px" />
+
+ <p class="leading-6">
+ @{{ __('mail.password_reset.expiry') }}
+ </p>
+ <p class="leading-6 mb-0">
+ @{{ __('mail.layout.signoff') }}
+ <br />
+ @{{ __('mail.layout.team') }}
+ </p>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/post-approval-requested.html b/maizzle/templates/post-approval-requested.html
index 5c2c57244..53c68618a 100644
--- a/maizzle/templates/post-approval-requested.html
+++ b/maizzle/templates/post-approval-requested.html
@@ -1,60 +1,39 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.post_approval_requested.heading') }}
+ </x-heading>
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.post_approval_requested.heading') }}
- </h1>
+ <p class="m-0 leading-6">
+ @{{ __('mail.post_approval_requested.body', ['name' => $requesterName, 'email' => $requesterEmail, 'workspace' => $workspaceName]) }}
+ </p>
- <p class="m-0 leading-6">
- @{{ __('mail.post_approval_requested.body', ['name' => $requesterName, 'email' => $requesterEmail, 'workspace' => $workspaceName]) }}
- </p>
+ <div class="email-context">
+ <p class="m-0 leading-6 text-sm text-foreground" style="white-space: pre-line;">@{{ $postExcerpt !== '' ? $postExcerpt : __('mail.post_approval_requested.post_without_text') }}</p>
+ </div>
- <div class="mt-4 p-4 bg-zinc-50 rounded">
- <p class="m-0 leading-6 text-sm text-zinc-900" style="white-space: pre-line;">@{{ $postExcerpt !== '' ? $postExcerpt : __('mail.post_approval_requested.post_without_text') }}</p>
- </div>
+ <p class="m-0 mt-4 text-sm font-semibold text-foreground">
+ @{{ __('mail.post_approval_requested.channels') }}
+ </p>
+ <x-channel-list />
- <p class="m-0 mt-4 text-sm font-semibold text-zinc-900">
- @{{ __('mail.post_approval_requested.channels') }}
- </p>
- <ul class="m-0 mt-2 pl-5 leading-6 text-sm">
- @foreach($channels as $channel)
- <li><strong>@{{ $channel }}</strong></li>
- @endforeach
- </ul>
+ <p class="m-0 mt-4 text-sm font-semibold text-foreground">
+ @{{ __('mail.post_approval_requested.requested_time') }}
+ </p>
+ <p class="m-0 mt-2 leading-6 text-sm">
+ @if($queued)
+ @{{ __('mail.post_approval_requested.next_queue_slot') }}
+ @elseif($requestedTime !== null)
+ @{{ $requestedTime }}
+ @else
+ @{{ __('mail.post_approval_requested.as_soon_as_approved') }}
+ @endif
+ </p>
- <p class="m-0 mt-4 text-sm font-semibold text-zinc-900">
- @{{ __('mail.post_approval_requested.requested_time') }}
- </p>
- <p class="m-0 mt-2 leading-6 text-sm">
- @if($queued)
- @{{ __('mail.post_approval_requested.next_queue_slot') }}
- @elseif($requestedTime !== null)
- @{{ $requestedTime }}
- @else
- @{{ __('mail.post_approval_requested.as_soon_as_approved') }}
- @endif
- </p>
+ <x-spacer height="24px" />
- <x-spacer height="24px" />
-
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.post_approval_requested.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
- </td>
- </tr>
- </table>
- </div>
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.post_approval_requested.button') }}
+ </x-button>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/post-approved.html b/maizzle/templates/post-approved.html
index fdcc6e080..c61af75cc 100644
--- a/maizzle/templates/post-approved.html
+++ b/maizzle/templates/post-approved.html
@@ -1,58 +1,40 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.post_approved.heading') }}
+ </x-heading>
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.post_approved.heading') }}
- </h1>
+ <p class="m-0 leading-6">
+ @{{ __('mail.post_approved.body', ['name' => $approverName, 'workspace' => $workspaceName]) }}
+ </p>
- <p class="m-0 leading-6">
- @{{ __('mail.post_approved.body', ['name' => $approverName, 'workspace' => $workspaceName]) }}
- </p>
+ @if(count($goesOutPerChannel) > 0)
+ <p class="m-0 mt-4 text-sm font-semibold text-foreground">
+ @{{ __('mail.post_approved.goes_out') }}
+ </p>
+ @foreach($goesOutPerChannel as $goesOut)
+ <x-channel-list channels="$goesOut['channels']" />
+ <p class="m-0 mt-2 text-sm leading-6">
+ @{{ $goesOut['at'] ?? __('mail.post_approved.publishing_now') }}
+ </p>
+ @endforeach
+ @else
+ <p class="m-0 mt-4 text-sm font-semibold text-foreground">
+ @{{ __('mail.post_approved.channels') }}
+ </p>
+ <x-channel-list />
+ <p class="m-0 mt-4 text-sm font-semibold text-foreground">
+ @{{ __('mail.post_approved.goes_out') }}
+ </p>
+ <p class="m-0 mt-2 leading-6 text-sm">
+ @{{ $goesOutAt ?? __('mail.post_approved.publishing_now') }}
+ </p>
+ @endif
- <p class="m-0 mt-4 text-sm font-semibold text-zinc-900">
- @{{ __('mail.post_approved.channels') }}
- </p>
- <ul class="m-0 mt-2 pl-5 leading-6 text-sm">
- @foreach($channels as $channel)
- <li><strong>@{{ $channel }}</strong></li>
- @endforeach
- </ul>
+ <x-spacer height="24px" />
- <p class="m-0 mt-4 text-sm font-semibold text-zinc-900">
- @{{ __('mail.post_approved.goes_out') }}
- </p>
- @if(count($goesOutPerChannel) > 0)
- <ul class="m-0 mt-2 pl-5 leading-6 text-sm">
- @foreach($goesOutPerChannel as $goesOut)
- <li>{!! __('mail.post_approved.channel_time', ['channel' => '<strong>'.e($goesOut['channel']).'</strong>', 'time' => e($goesOut['at'] ?? __('mail.post_approved.publishing_now'))]) !!}</li>
- @endforeach
- </ul>
- @else
- <p class="m-0 mt-2 leading-6 text-sm">
- @{{ $goesOutAt ?? __('mail.post_approved.publishing_now') }}
- </p>
- @endif
-
- <x-spacer height="24px" />
-
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.post_approved.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
- </td>
- </tr>
- </table>
- </div>
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.post_approved.button') }}
+ </x-button>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/post-at-risk.html b/maizzle/templates/post-at-risk.html
index 719826716..2001cc030 100644
--- a/maizzle/templates/post-at-risk.html
+++ b/maizzle/templates/post-at-risk.html
@@ -1,57 +1,34 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
-
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.post_at_risk.heading') }}
- </h1>
-
- <p class="m-0 leading-6">
- @{{ __('mail.post_at_risk.intro', ['workspace' => $workspaceName]) }}
- </p>
-
- <table class="w-full mt-4" style="border-collapse: collapse">
- @foreach($atRiskGroups as $group)
- <tr>
- <td class="py-3" style="border-bottom: 1px solid #e4e4e7">
- <div style="display: flex; align-items: center">
- <div style="width: 8px; height: 8px; border-radius: 50%; background-color: @{{ $group['account']->platform->color() }}; margin-right: 12px"></div>
- <div>
- <strong class="text-zinc-900">@{{ $group['account']->platform->label() }}</strong>
- <span class="text-zinc-500"> - @{{ $group['account']->accountDisplayName() }}</span>
- <div class="text-zinc-500" style="font-size: 14px; margin-top: 4px">
- @{{ trans_choice('mail.post_at_risk.posts_label', $group['postCount'], ['count' => $group['postCount'], 'times' => $group['times'], 'timezone' => $timezone]) }}
- </div>
- </div>
- </div>
- </td>
- </tr>
- @endforeach
- </table>
-
- <p class="m-0 mt-4 leading-6">
- @{{ __('mail.post_at_risk.reconnect_cta') }}
- </p>
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.post_at_risk.heading') }}
+ </x-heading>
- <x-spacer height="24px" />
+ <p class="m-0 leading-6">
+ @{{ __('mail.post_at_risk.intro', ['workspace' => $workspaceName]) }}
+ </p>
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.post_at_risk.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
+ @foreach($atRiskGroups as $group)
+ <table role="presentation" class="w-full mt-4">
+ <tr>
+ <td class="rounded-xl border border-solid border-border p-5 sm:p-4">
+ <x-channel-identity platform="$group['account']->platform" account-name="$group['account']->accountDisplayName()" />
+ <p class="m-0 mt-3 text-sm text-muted-foreground">
+ @{{ trans_choice('mail.post_at_risk.posts_label', $group['postCount'], ['count' => $group['postCount'], 'times' => $group['times'], 'timezone' => $timezone]) }}
+ </p>
</td>
</tr>
</table>
- </div>
+ @endforeach
+
+ <p class="m-0 mt-4 leading-6">
+ @{{ __('mail.post_at_risk.reconnect_cta') }}
+ </p>
+
+ <x-spacer height="24px" />
+
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.post_at_risk.button') }}
+ </x-button>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/post-note-added.html b/maizzle/templates/post-note-added.html
index 37d54a49d..bca2762fc 100644
--- a/maizzle/templates/post-note-added.html
+++ b/maizzle/templates/post-note-added.html
@@ -1,52 +1,31 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.post_note_added.heading') }}
+ </x-heading>
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.post_note_added.heading') }}
- </h1>
+ <p class="m-0 leading-6">
+ @{{ __('mail.post_note_added.body', ['author' => $authorName, 'workspace' => $workspaceName]) }}
+ </p>
- <p class="m-0 leading-6">
- @{{ __('mail.post_note_added.body', ['author' => $authorName, 'workspace' => $workspaceName]) }}
- </p>
+ <div class="email-context">
+ <p class="m-0 leading-6 text-foreground" style="white-space: pre-line;">@{{ $noteBody }}</p>
+ </div>
- <div class="mt-4 p-4 bg-zinc-50 rounded">
- <p class="m-0 leading-6 text-zinc-900" style="white-space: pre-line;">@{{ $noteBody }}</p>
- </div>
+ <div class="email-context">
+ <p class="m-0 text-sm font-semibold text-foreground">
+ @{{ __('mail.post_note_added.post_title') }}
+ </p>
+ <p class="m-0 mt-2 leading-6 text-sm" style="white-space: pre-line;">@{{ $postExcerpt !== '' ? $postExcerpt : __('mail.post_note_added.post_without_text') }}</p>
+ @if(count($channels) > 0)
+ <x-channel-list />
+ @endif
+ </div>
- <div class="mt-4 p-4 bg-zinc-50 rounded">
- <p class="m-0 text-sm font-semibold text-zinc-900">
- @{{ __('mail.post_note_added.post_title') }}
- </p>
- <p class="m-0 mt-2 leading-6 text-sm" style="white-space: pre-line;">@{{ $postExcerpt !== '' ? $postExcerpt : __('mail.post_note_added.post_without_text') }}</p>
- @if(count($channels) > 0)
- <ul class="m-0 mt-2 pl-5 leading-6 text-sm">
- @foreach($channels as $channel)
- <li><strong>@{{ $channel }}</strong></li>
- @endforeach
- </ul>
- @endif
- </div>
+ <x-spacer height="24px" />
- <x-spacer height="24px" />
-
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.post_note_added.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
- </td>
- </tr>
- </table>
- </div>
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.post_note_added.button') }}
+ </x-button>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/post-publish-failed.html b/maizzle/templates/post-publish-failed.html
index 084d26cc4..341120b4d 100644
--- a/maizzle/templates/post-publish-failed.html
+++ b/maizzle/templates/post-publish-failed.html
@@ -1,50 +1,26 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.post_publish_failed.heading') }}
+ </x-heading>
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.post_publish_failed.heading') }}
- </h1>
+ <p class="m-0 leading-6">
+ @{{ __('mail.post_publish_failed.body', ['workspace' => $workspaceName]) }}
+ </p>
- <p class="m-0 leading-6">
- @{{ __('mail.post_publish_failed.body', ['workspace' => $workspaceName]) }}
- </p>
+ @if($publication)
+ <x-post-preview />
+ @if($publication['error'])
+ <x-alert title-key="mail.post_preview.error">
+ @{{ $publication['error'] }}
+ </x-alert>
+ @endif
+ @endif
- <div class="mt-4 p-4 bg-zinc-50 rounded">
- <p class="m-0 text-sm font-semibold text-zinc-900">
- @{{ __('mail.post_publish_failed.platforms_title') }}
- </p>
- <ul class="m-0 mt-2 pl-5 leading-6 text-sm">
- @foreach($failedPlatforms as $platform)
- <li>
- <strong>@{{ $platform['name'] }}</strong>
- @if($platform['error'])
- — @{{ $platform['error'] }}
- @endif
- </li>
- @endforeach
- </ul>
- </div>
+ <x-spacer height="24px" />
- <x-spacer height="24px" />
-
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.post_publish_failed.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
- </td>
- </tr>
- </table>
- </div>
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.post_publish_failed.button') }}
+ </x-button>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/post-published.html b/maizzle/templates/post-published.html
index 2260f0b52..62b5e7a5b 100644
--- a/maizzle/templates/post-published.html
+++ b/maizzle/templates/post-published.html
@@ -1,50 +1,39 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.post_published.heading') }}
+ </x-heading>
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.post_published.heading') }}
- </h1>
+ <p class="m-0 leading-6">
+ @{{ __('mail.post_published.body', ['workspace' => $workspaceName]) }}
+ </p>
- <p class="m-0 leading-6">
- @{{ __('mail.post_published.body', ['workspace' => $workspaceName]) }}
- </p>
+ @if($publication)
+ <x-post-preview />
+ @endif
- <div class="mt-4 p-4 bg-green-50 rounded">
- <p class="m-0 text-sm font-semibold text-green-900">
- @{{ __('mail.post_published.platforms_title') }}
- </p>
- <ul class="m-0 mt-2 pl-5 leading-6 text-sm">
- @foreach($publishedPlatforms as $platform)
- <li>
- <strong>@{{ $platform['name'] }}</strong>
- @if($platform['url'])
- — <a href="@{{ $platform['url'] }}" target="_blank" class="text-green-700 underline">@{{ __('mail.post_published.view_post') }}</a>
- @endif
- </li>
- @endforeach
- </ul>
- </div>
+ <x-spacer height="24px" />
- <x-spacer height="24px" />
-
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.post_published.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
- </td>
- </tr>
- </table>
- </div>
+ @if($publishedUrl)
+ <table role="presentation" align="center" class="mx-auto">
+ <tr>
+ <td class="align-middle">
+ <x-button href="@{{ $publishedUrl }}" variant="primary" size="sm">
+ @{{ __('mail.post_published.button') }}
+ </x-button>
+ </td>
+ <td class="w-3 sm:w-2" aria-hidden="true">&nbsp;</td>
+ <td class="align-middle">
+ <x-button href="@{{ $url }}" variant="secondary" size="sm">
+ @{{ __('mail.post_published.open_in_app') }}
+ </x-button>
+ </td>
+ </tr>
+ </table>
+ @else
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.post_published.open_in_app') }}
+ </x-button>
+ @endif
+ </x-message>
</x-main>
diff --git a/maizzle/templates/post-rejected.html b/maizzle/templates/post-rejected.html
index 4506b5474..63a42965d 100644
--- a/maizzle/templates/post-rejected.html
+++ b/maizzle/templates/post-rejected.html
@@ -1,43 +1,22 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.post_rejected.heading') }}
+ </x-heading>
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.post_rejected.heading') }}
- </h1>
+ <p class="m-0 leading-6">
+ @{{ __('mail.post_rejected.body', ['name' => $approverName, 'workspace' => $workspaceName]) }}
+ </p>
- <p class="m-0 leading-6">
- @{{ __('mail.post_rejected.body', ['name' => $approverName, 'workspace' => $workspaceName]) }}
- </p>
+ <p class="m-0 mt-4 text-sm font-semibold text-foreground">
+ @{{ __('mail.post_rejected.channels') }}
+ </p>
+ <x-channel-list />
- <p class="m-0 mt-4 text-sm font-semibold text-zinc-900">
- @{{ __('mail.post_rejected.channels') }}
- </p>
- <ul class="m-0 mt-2 pl-5 leading-6 text-sm">
- @foreach($channels as $channel)
- <li><strong>@{{ $channel }}</strong></li>
- @endforeach
- </ul>
+ <x-spacer height="24px" />
- <x-spacer height="24px" />
-
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.post_rejected.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
- </td>
- </tr>
- </table>
- </div>
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.post_rejected.button') }}
+ </x-button>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/webhook-paused.html b/maizzle/templates/webhook-paused.html
index 817bfe4d6..9887947a7 100644
--- a/maizzle/templates/webhook-paused.html
+++ b/maizzle/templates/webhook-paused.html
@@ -1,34 +1,30 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.webhook_paused.heading') }}
+ </x-heading>
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.webhook_paused.heading') }}
- </h1>
+ <p class="m-0 leading-6">
+ @{{ __('mail.webhook_paused.body') }}
+ </p>
- <p class="m-0 leading-6">
- @{{ __('mail.webhook_paused.body', ['endpoint' => $endpoint]) }}
- </p>
+ <div class="email-context">
+ <p class="m-0 text-sm text-muted-foreground">
+ @{{ __('webhooks.create.endpoint') }}
+ </p>
+ <p dir="ltr" class="m-0 mt-2 text-sm font-semibold text-foreground break-all">
+ @{{ $endpoint }}
+ </p>
+ </div>
- <x-spacer height="24px" />
+ <p class="m-0 mt-6 leading-6">
+ @{{ __('mail.webhook_paused.next_steps') }}
+ </p>
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.webhook_paused.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
- </td>
- </tr>
- </table>
- </div>
+ <x-spacer height="24px" />
+
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.webhook_paused.button') }}
+ </x-button>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/workspace-connections-disconnected.html b/maizzle/templates/workspace-connections-disconnected.html
index 64da447f4..8344b797d 100644
--- a/maizzle/templates/workspace-connections-disconnected.html
+++ b/maizzle/templates/workspace-connections-disconnected.html
@@ -1,64 +1,41 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
-
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.workspace_connections_disconnected.heading') }}
- </h1>
-
- <p class="m-0 leading-6">
- {!! __('mail.workspace_connections_disconnected.intro', ['workspace' => '<strong>'.e($workspaceName).'</strong>']) !!}
- </p>
-
- <table class="w-full mt-4" style="border-collapse: collapse">
- @foreach($disconnectedAccounts as $account)
- <tr>
- <td class="py-3" style="border-bottom: 1px solid #e4e4e7">
- <div style="display: flex; align-items: center">
- <div style="width: 8px; height: 8px; border-radius: 50%; background-color: @{{ $account->platform->color() }}; margin-right: 12px"></div>
- <div>
- <strong class="text-zinc-900">@{{ $account->platform->label() }}</strong>
- <span class="text-zinc-500"> - @{{ $account->accountDisplayName() }}</span>
- </div>
- </div>
- </td>
- </tr>
- @endforeach
- </table>
-
- <p class="m-0 mt-6 leading-6">
- @{{ __('mail.workspace_connections_disconnected.reasons_title') }}
- </p>
-
- <ul class="m-0 mt-2 pl-5 leading-6">
- <li>@{{ __('mail.workspace_connections_disconnected.reason_expired') }}</li>
- <li>@{{ __('mail.workspace_connections_disconnected.reason_revoked') }}</li>
- <li>@{{ __('mail.workspace_connections_disconnected.reason_changed') }}</li>
- </ul>
-
- <p class="m-0 mt-4 leading-6">
- @{{ __('mail.workspace_connections_disconnected.reconnect_cta') }}
- </p>
-
- <x-spacer height="24px" />
-
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.workspace_connections_disconnected.button') }}
- </x-button>
- </div>
- </td>
- </tr>
- </table>
- <x-footer-authenticated />
- </td>
- </tr>
- </table>
- </div>
+ <x-message authenticated="true">
+ <x-heading>
+ @{{ __('mail.workspace_connections_disconnected.heading') }}
+ </x-heading>
+
+ <p class="m-0 leading-6">
+ {!! __('mail.workspace_connections_disconnected.intro', ['workspace' => '<strong>'.e($workspaceName).'</strong>']) !!}
+ </p>
+
+ @foreach($disconnectedAccounts as $account)
+ <table role="presentation" class="w-full mt-4">
+ <tr>
+ <td class="rounded-xl border border-solid border-border p-5 sm:p-4">
+ <x-channel-identity platform="$account->platform" account-name="$account->accountDisplayName()" />
+ </td>
+ </tr>
+ </table>
+ @endforeach
+
+ <p class="m-0 mt-6 leading-6">
+ @{{ __('mail.workspace_connections_disconnected.reasons_title') }}
+ </p>
+
+ <x-list>
+ <li>@{{ __('mail.workspace_connections_disconnected.reason_expired') }}</li>
+ <li>@{{ __('mail.workspace_connections_disconnected.reason_revoked') }}</li>
+ <li>@{{ __('mail.workspace_connections_disconnected.reason_changed') }}</li>
+ </x-list>
+
+ <p class="m-0 mt-4 leading-6">
+ @{{ __('mail.workspace_connections_disconnected.reconnect_cta') }}
+ </p>
+
+ <x-spacer height="24px" />
+
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.workspace_connections_disconnected.button') }}
+ </x-button>
+ </x-message>
</x-main>
diff --git a/maizzle/templates/workspace-invite.html b/maizzle/templates/workspace-invite.html
index 67a769973..d3d74e5e1 100644
--- a/maizzle/templates/workspace-invite.html
+++ b/maizzle/templates/workspace-invite.html
@@ -1,50 +1,33 @@
<x-main>
- <div class="bg-zinc-50 sm:px-4 font-sans">
- <table align="center">
- <tr>
- <td class="w-[552px] max-w-full">
- <x-header />
+ <x-message>
+ <x-heading>
+ @{{ __('mail.workspace_invite.heading') }}
+ </x-heading>
- <table class="w-full">
- <tr>
- <td class="p-12 sm:px-6 text-base text-zinc-700 bg-white rounded shadow-sm">
- <h1 class="m-0 mb-6 text-2xl sm:leading-8 text-black font-semibold">
- @{{ __('mail.workspace_invite.heading') }}
- </h1>
+ <p class="m-0 leading-6">
+ {!! __('mail.workspace_invite.intro', ['workspace' => e($workspaceName)]) !!}
+ </p>
- <p class="m-0 leading-6">
- {!! __('mail.workspace_invite.intro', ['workspace' => e($workspaceName)]) !!}
- </p>
+ <p class="m-0 mt-4 leading-6">
+ @if($isAdmin)
+ {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.admin')).'</strong>']) !!}
+ @elseif($requiresApproval)
+ {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.needs_approval')).'</strong>']) !!}
+ @else
+ {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.member')).'</strong>']) !!}
+ @endif
+ </p>
- <p class="m-0 mt-4 leading-6">
- @if($isAdmin)
- {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.admin')).'</strong>']) !!}
- @elseif($requiresApproval)
- {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.needs_approval')).'</strong>']) !!}
- @else
- {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.member')).'</strong>']) !!}
- @endif
- </p>
+ <x-spacer height="24px" />
- <x-spacer height="24px" />
+ <x-button href="@{{ $url }}">
+ @{{ __('mail.workspace_invite.button') }}
+ </x-button>
- <div class="flex items-center justify-center">
- <x-button href="@{{ $url }}">
- @{{ __('mail.workspace_invite.button') }}
- </x-button>
- </div>
+ <x-spacer height="24px" />
- <x-spacer height="24px" />
-
- <p class="m-0 leading-6 text-zinc-500 text-sm">
- @{{ __('mail.workspace_invite.expiry') }}
- </p>
- </td>
- </tr>
- </table>
- <x-footer />
- </td>
- </tr>
- </table>
- </div>
+ <p class="m-0 leading-6 text-muted-foreground text-sm">
+ @{{ __('mail.workspace_invite.expiry') }}
+ </p>
+ </x-message>
</x-main>
diff --git a/resources/views/mail/account-disconnected.blade.php b/resources/views/mail/account-disconnected.blade.php
index 28d6ea229..e8e420e73 100644
--- a/resources/views/mail/account-disconnected.blade.php
+++ b/resources/views/mail/account-disconnected.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,19 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
+ .sm-p-4 {
+ padding: 16px !important
}
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,96 +48,122 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.account_disconnected.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {!! __('mail.account_disconnected.intro', ['platform' => '<strong>'.e($platformName).'</strong>', 'account' => '<strong>'.e($accountName).'</strong>', 'workspace' => '<strong>'.e($workspaceName).'</strong>']) !!}
- </p>
- <p style="margin: 16px 0 0; line-height: 24px">
- {{ __('mail.account_disconnected.reasons_title') }}
- </p>
- <ul style="margin: 8px 0 0; padding-left: 20px; line-height: 24px">
- <li>{{ __('mail.account_disconnected.reason_expired') }}</li>
- <li>{{ __('mail.account_disconnected.reason_revoked') }}</li>
- <li>{{ __('mail.account_disconnected.reason_error') }}</li>
- </ul>
- <p style="margin: 16px 0 0; line-height: 24px">
- {{ __('mail.account_disconnected.reconnect_cta') }}
- </p>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.account_disconnected.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.account_disconnected.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {!! __('mail.account_disconnected.intro', ['workspace' => '<strong>'.e($workspaceName).'</strong>']) !!}
+ </p>
+ <table role="presentation" style="margin-top: 24px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td class="sm-p-4" style="border-radius: 12px; border: 1px solid #eae8e5; padding: 20px">@php
+ $emailChannelPlatform = $account->platform;
+ $emailChannelName = $account->accountDisplayName();
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 16px 0 0; line-height: 24px">
+ {{ __('mail.account_disconnected.reasons_title') }}
+ </p>
+ <ul style="margin: 8px 0 0; padding-left: 20px; padding-right: 20px; line-height: 24px">
+ <li>{{ __('mail.account_disconnected.reason_expired') }}</li>
+ <li>{{ __('mail.account_disconnected.reason_revoked') }}</li>
+ <li>{{ __('mail.account_disconnected.reason_error') }}</li>
+ </ul>
+ <p style="margin: 16px 0 0; line-height: 24px">
+ {{ __('mail.account_disconnected.reconnect_cta') }}
+ </p>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.account_disconnected.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/email-verification.blade.php b/resources/views/mail/email-verification.blade.php
index e65d08419..a5be85a2f 100644
--- a/resources/views/mail/email-verification.blade.php
+++ b/resources/views/mail/email-verification.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,25 +28,16 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -50,89 +45,98 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #27272a; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <p style="margin-top: 0; line-height: 24px">
- {{ __('mail.email_verification.greeting', ['name' => $user->name]) }}
- </p>
- <p style="line-height: 24px">
- {{ __('mail.email_verification.body') }}
- </p>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="text-align: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.email_verification.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <p style="line-height: 24px">
- {{ __('mail.email_verification.ignore') }}
- </p>
- <p style="margin-bottom: 0; line-height: 24px">
- {{ __('mail.layout.signoff') }}
- <br>
- {{ __('mail.layout.team') }}
- </p>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928">
+ {{ __('mail.email_verification.subject') }}
+ </h1>
+ <p style="margin-top: 0; line-height: 24px">
+ {{ __('mail.email_verification.greeting', ['name' => $user->name]) }}
+ </p>
+ <p style="line-height: 24px">
+ {{ __('mail.email_verification.body') }}
+ </p>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.email_verification.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </div>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <p style="line-height: 24px">
+ {{ __('mail.email_verification.ignore') }}
+ </p>
+ <p style="margin-bottom: 0; line-height: 24px">
+ {{ __('mail.layout.signoff') }}
+ <br>
+ {{ __('mail.layout.team') }}
+ </p>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/password-reset.blade.php b/resources/views/mail/password-reset.blade.php
index 5332fb95f..bd65ba460 100644
--- a/resources/views/mail/password-reset.blade.php
+++ b/resources/views/mail/password-reset.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,25 +28,16 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -50,89 +45,98 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #27272a; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <p style="margin-top: 0; line-height: 24px">
- {{ __('mail.password_reset.greeting', ['name' => $user->name]) }}
- </p>
- <p style="line-height: 24px">
- {{ __('mail.password_reset.body') }}
- </p>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="text-align: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.password_reset.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <p style="line-height: 24px">
- {{ __('mail.password_reset.expiry') }}
- </p>
- <p style="margin-bottom: 0; line-height: 24px">
- {{ __('mail.layout.signoff') }}
- <br>
- {{ __('mail.layout.team') }}
- </p>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928">
+ {{ __('mail.password_reset.subject') }}
+ </h1>
+ <p style="margin-top: 0; line-height: 24px">
+ {{ __('mail.password_reset.greeting', ['name' => $user->name]) }}
+ </p>
+ <p style="line-height: 24px">
+ {{ __('mail.password_reset.body') }}
+ </p>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.password_reset.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </div>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <p style="line-height: 24px">
+ {{ __('mail.password_reset.expiry') }}
+ </p>
+ <p style="margin-bottom: 0; line-height: 24px">
+ {{ __('mail.layout.signoff') }}
+ <br>
+ {{ __('mail.layout.team') }}
+ </p>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/post-approval-requested.blade.php b/resources/views/mail/post-approval-requested.blade.php
index 9a0ba9413..94bb02fe8 100644
--- a/resources/views/mail/post-approval-requested.blade.php
+++ b/resources/views/mail/post-approval-requested.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,16 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
- }
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,108 +45,129 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.post_approval_requested.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {{ __('mail.post_approval_requested.body', ['name' => $requesterName, 'email' => $requesterEmail, 'workspace' => $workspaceName]) }}
- </p>
- <div style="margin-top: 16px; border-radius: 4px; background-color: #fafafa; padding: 16px">
- <p style="white-space: pre-line; margin: 0; font-size: 14px; line-height: 24px; color: #18181b">{{ $postExcerpt !== '' ? $postExcerpt : __('mail.post_approval_requested.post_without_text') }}</p>
- </div>
- <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #18181b">
- {{ __('mail.post_approval_requested.channels') }}
- </p>
- <ul style="margin: 8px 0 0; padding-left: 20px; font-size: 14px; line-height: 24px">
- @foreach($channels as $channel)
- <li><strong>{{ $channel }}</strong></li>
- @endforeach
- </ul>
- <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #18181b">
- {{ __('mail.post_approval_requested.requested_time') }}
- </p>
- <p style="margin: 8px 0 0; font-size: 14px; line-height: 24px">
- @if($queued)
- {{ __('mail.post_approval_requested.next_queue_slot') }}
- @elseif($requestedTime !== null)
- {{ $requestedTime }}
- @else
- {{ __('mail.post_approval_requested.as_soon_as_approved') }}
- @endif
- </p>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.post_approval_requested.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.post_approval_requested.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {{ __('mail.post_approval_requested.body', ['name' => $requesterName, 'email' => $requesterEmail, 'workspace' => $workspaceName]) }}
+ </p>
+ <div style="margin-top: 16px; border-radius: 8px; background-color: #f7f6f3; padding: 16px">
+ <p style="white-space: pre-line; margin: 0; font-size: 14px; line-height: 24px; color: #292928">{{ $postExcerpt !== '' ? $postExcerpt : __('mail.post_approval_requested.post_without_text') }}</p>
+ </div>
+ <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #292928">
+ {{ __('mail.post_approval_requested.channels') }}
+ </p>@foreach($channels as $emailChannel)
+ <table role="presentation" style="margin-top: 12px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 16px">@php
+ $emailChannelPlatform = $emailChannel->platform;
+ $emailChannelName = $emailChannel->display_name;
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+ </table>
+ @endforeach <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #292928">
+ {{ __('mail.post_approval_requested.requested_time') }}
+ </p>
+ <p style="margin: 8px 0 0; font-size: 14px; line-height: 24px">
+ @if($queued)
+ {{ __('mail.post_approval_requested.next_queue_slot') }}
+ @elseif($requestedTime !== null)
+ {{ $requestedTime }}
+ @else
+ {{ __('mail.post_approval_requested.as_soon_as_approved') }}
+ @endif
+ </p>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.post_approval_requested.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/post-approved.blade.php b/resources/views/mail/post-approved.blade.php
index ed758d28e..9a008d6f1 100644
--- a/resources/views/mail/post-approved.blade.php
+++ b/resources/views/mail/post-approved.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,16 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
- }
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,106 +45,154 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.post_approved.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {{ __('mail.post_approved.body', ['name' => $approverName, 'workspace' => $workspaceName]) }}
- </p>
- <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #18181b">
- {{ __('mail.post_approved.channels') }}
- </p>
- <ul style="margin: 8px 0 0; padding-left: 20px; font-size: 14px; line-height: 24px">
- @foreach($channels as $channel)
- <li><strong>{{ $channel }}</strong></li>
- @endforeach
- </ul>
- <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #18181b">
- {{ __('mail.post_approved.goes_out') }}
- </p>
- @if(count($goesOutPerChannel) > 0)
- <ul style="margin: 8px 0 0; padding-left: 20px; font-size: 14px; line-height: 24px">
- @foreach($goesOutPerChannel as $goesOut)
- <li>{!! __('mail.post_approved.channel_time', ['channel' => '<strong>'.e($goesOut['channel']).'</strong>', 'time' => e($goesOut['at'] ?? __('mail.post_approved.publishing_now'))]) !!}</li>
- @endforeach
- </ul>
- @else
- <p style="margin: 8px 0 0; font-size: 14px; line-height: 24px">
- {{ $goesOutAt ?? __('mail.post_approved.publishing_now') }}
- </p>
- @endif <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.post_approved.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.post_approved.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {{ __('mail.post_approved.body', ['name' => $approverName, 'workspace' => $workspaceName]) }}
+ </p>
+ @if(count($goesOutPerChannel) > 0)
+ <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #292928">
+ {{ __('mail.post_approved.goes_out') }}
+ </p>
+ @foreach($goesOutPerChannel as $goesOut)@foreach($goesOut['channels'] as $emailChannel)
+ <table role="presentation" style="margin-top: 12px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 16px">@php
+ $emailChannelPlatform = $emailChannel->platform;
+ $emailChannelName = $emailChannel->display_name;
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+ </table>
+ @endforeach
+ <p style="margin: 8px 0 0; font-size: 14px; line-height: 24px">
+ {{ $goesOut['at'] ?? __('mail.post_approved.publishing_now') }}
+ </p>
+ @endforeach
+ @else
+ <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #292928">
+ {{ __('mail.post_approved.channels') }}
+ </p>@foreach($channels as $emailChannel)
+ <table role="presentation" style="margin-top: 12px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 16px">@php
+ $emailChannelPlatform = $emailChannel->platform;
+ $emailChannelName = $emailChannel->display_name;
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+ </table>
+ @endforeach
+ <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #292928">
+ {{ __('mail.post_approved.goes_out') }}
+ </p>
+ <p style="margin: 8px 0 0; font-size: 14px; line-height: 24px">
+ {{ $goesOutAt ?? __('mail.post_approved.publishing_now') }}
+ </p>
+ @endif <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.post_approved.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/post-at-risk.blade.php b/resources/views/mail/post-at-risk.blade.php
index 6444ee64d..ee6cf61c6 100644
--- a/resources/views/mail/post-at-risk.blade.php
+++ b/resources/views/mail/post-at-risk.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,19 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
+ .sm-p-4 {
+ padding: 16px !important
}
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,106 +48,119 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.post_at_risk.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {{ __('mail.post_at_risk.intro', ['workspace' => $workspaceName]) }}
- </p>
- <table style="border-collapse: collapse; margin-top: 16px; width: 100%" cellpadding="0" cellspacing="0" role="none">
- @foreach($atRiskGroups as $group)
- <tr>
- <td style="border-bottom: 1px solid #e4e4e7; padding-top: 12px; padding-bottom: 12px">
- <div style="display: flex; align-items: center">
- <div style="width: 8px; height: 8px; border-radius: 50%; background-color: {{ $group['account']->platform->color() }}; margin-right: 12px"></div>
- <div>
- <strong style="color: #18181b">{{ $group['account']->platform->label() }}</strong>
- <span style="color: #71717a"> - {{ $group['account']->accountDisplayName() }}</span>
- <div style="font-size: 14px; margin-top: 4px; color: #71717a">
- {{ trans_choice('mail.post_at_risk.posts_label', $group['postCount'], ['count' => $group['postCount'], 'times' => $group['times'], 'timezone' => $timezone]) }}
- </div>
- </div>
- </div>
- </td>
- </tr>
- @endforeach
- </table>
- <p style="margin: 16px 0 0; line-height: 24px">
- {{ __('mail.post_at_risk.reconnect_cta') }}
- </p>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.post_at_risk.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.post_at_risk.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {{ __('mail.post_at_risk.intro', ['workspace' => $workspaceName]) }}
+ </p>
+ @foreach($atRiskGroups as $group)
+ <table role="presentation" style="margin-top: 16px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td class="sm-p-4" style="border-radius: 12px; border: 1px solid #eae8e5; padding: 20px">@php
+ $emailChannelPlatform = $group['account']->platform;
+ $emailChannelName = $group['account']->accountDisplayName();
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0; font-size: 14px; color: #5a5a59">
+ {{ trans_choice('mail.post_at_risk.posts_label', $group['postCount'], ['count' => $group['postCount'], 'times' => $group['times'], 'timezone' => $timezone]) }}
+ </p>
+ </td>
+ </tr>
+ </table>
+ @endforeach
+ <p style="margin: 16px 0 0; line-height: 24px">
+ {{ __('mail.post_at_risk.reconnect_cta') }}
+ </p>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.post_at_risk.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/post-note-added.blade.php b/resources/views/mail/post-note-added.blade.php
index 966ee0527..814f26fcf 100644
--- a/resources/views/mail/post-note-added.blade.php
+++ b/resources/views/mail/post-note-added.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,16 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
- }
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,101 +45,123 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.post_note_added.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {{ __('mail.post_note_added.body', ['author' => $authorName, 'workspace' => $workspaceName]) }}
- </p>
- <div style="margin-top: 16px; border-radius: 4px; background-color: #fafafa; padding: 16px">
- <p style="white-space: pre-line; margin: 0; line-height: 24px; color: #18181b">{{ $noteBody }}</p>
- </div>
- <div style="margin-top: 16px; border-radius: 4px; background-color: #fafafa; padding: 16px">
- <p style="margin: 0; font-size: 14px; font-weight: 600; color: #18181b">
- {{ __('mail.post_note_added.post_title') }}
- </p>
- <p style="white-space: pre-line; margin: 8px 0 0; font-size: 14px; line-height: 24px">{{ $postExcerpt !== '' ? $postExcerpt : __('mail.post_note_added.post_without_text') }}</p>
- @if(count($channels) > 0)
- <ul style="margin: 8px 0 0; padding-left: 20px; font-size: 14px; line-height: 24px">
- @foreach($channels as $channel)
- <li><strong>{{ $channel }}</strong></li>
- @endforeach
- </ul>
- @endif
- </div>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.post_note_added.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.post_note_added.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {{ __('mail.post_note_added.body', ['author' => $authorName, 'workspace' => $workspaceName]) }}
+ </p>
+ <div style="margin-top: 16px; border-radius: 8px; background-color: #f7f6f3; padding: 16px">
+ <p style="white-space: pre-line; margin: 0; line-height: 24px; color: #292928">{{ $noteBody }}</p>
+ </div>
+ <div style="margin-top: 16px; border-radius: 8px; background-color: #f7f6f3; padding: 16px">
+ <p style="margin: 0; font-size: 14px; font-weight: 600; color: #292928">
+ {{ __('mail.post_note_added.post_title') }}
+ </p>
+ <p style="white-space: pre-line; margin: 8px 0 0; font-size: 14px; line-height: 24px">{{ $postExcerpt !== '' ? $postExcerpt : __('mail.post_note_added.post_without_text') }}</p>
+ @if(count($channels) > 0)@foreach($channels as $emailChannel)
+ <table role="presentation" style="margin-top: 12px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 16px">@php
+ $emailChannelPlatform = $emailChannel->platform;
+ $emailChannelName = $emailChannel->display_name;
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+ </table>
+ @endforeach
+ @endif
+ </div>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.post_note_added.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/post-publish-failed.blade.php b/resources/views/mail/post-publish-failed.blade.php
index d2b990c97..3040f145f 100644
--- a/resources/views/mail/post-publish-failed.blade.php
+++ b/resources/views/mail/post-publish-failed.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,19 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
+ .sm-p-4 {
+ padding: 16px !important
}
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,100 +48,130 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.post_publish_failed.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {{ __('mail.post_publish_failed.body', ['workspace' => $workspaceName]) }}
- </p>
- <div style="margin-top: 16px; border-radius: 4px; background-color: #fafafa; padding: 16px">
- <p style="margin: 0; font-size: 14px; font-weight: 600; color: #18181b">
- {{ __('mail.post_publish_failed.platforms_title') }}
- </p>
- <ul style="margin: 8px 0 0; padding-left: 20px; font-size: 14px; line-height: 24px">
- @foreach($failedPlatforms as $platform)
- <li>
- <strong>{{ $platform['name'] }}</strong>
- @if($platform['error'])
- — {{ $platform['error'] }}
- @endif
- </li>
- @endforeach
- </ul>
- </div>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.post_publish_failed.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.post_publish_failed.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {{ __('mail.post_publish_failed.body', ['workspace' => $workspaceName]) }}
+ </p>
+ @if($publication)
+ <table role="presentation" style="margin-top: 24px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td class="sm-p-4" style="border-radius: 12px; border: 1px solid #eae8e5; padding: 20px">@php
+ $emailChannelPlatform = $publication['platform'];
+ $emailChannelName = $publication['accountName'];
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table> @if($postPreview['text'] !== '')
+ <p style="white-space: pre-line; margin: 20px 0 0; line-height: 24px; color: #292928">{{ $postPreview['text'] }}</p>
+ @endif
+ @if($postPreview['image'])
+ <img src="{{ $postPreview['image']['url'] }}" alt="{{ $postPreview['image']['alt'] }}" width="{{ $postPreview['image']['width'] }}" style="vertical-align: middle; margin-top: 20px; height: auto; max-width: 100%; border-radius: 8px" height="auto">
+ @elseif($postPreview['text'] === '')
+ <p style="margin: 20px 0 0; font-size: 14px; color: #5a5a59">{{ $postPreview['attachment'] ?: __('mail.post_preview.no_text') }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ @if($publication['error'])<table role="presentation" style="margin-top: 16px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td class="sm-p-4" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #f7f6f3; padding: 20px">
+ <p style="margin: 0; font-size: 14px; font-weight: 600; line-height: 20px; color: #7f0f00">{{ __('mail.post_preview.error') }}</p>
+ <p style="margin: 6px 0 0; font-size: 14px; line-height: 22px; color: #292928">
+ {{ $publication['error'] }}
+ </p>
+ </td>
+ </tr>
+ </table>
+ @endif
+ @endif <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.post_publish_failed.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/post-published.blade.php b/resources/views/mail/post-published.blade.php
index 7ef24561f..902eb97d7 100644
--- a/resources/views/mail/post-published.blade.php
+++ b/resources/views/mail/post-published.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,29 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
+ .sm-w-2 {
+ width: 8px !important
+ }
+ .sm-p-4 {
+ padding: 16px !important
}
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
+ .sm-p-6 {
+ padding: 24px !important
}
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
+ .sm-px-1_5 {
+ padding-left: 6px !important;
+ padding-right: 6px !important
}
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-text-xs {
+ font-size: 12px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,100 +58,143 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.post_published.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {{ __('mail.post_published.body', ['workspace' => $workspaceName]) }}
- </p>
- <div style="margin-top: 16px; border-radius: 4px; background-color: #f0fdf4; padding: 16px">
- <p style="margin: 0; font-size: 14px; font-weight: 600; color: #14532d">
- {{ __('mail.post_published.platforms_title') }}
- </p>
- <ul style="margin: 8px 0 0; padding-left: 20px; font-size: 14px; line-height: 24px">
- @foreach($publishedPlatforms as $platform)
- <li>
- <strong>{{ $platform['name'] }}</strong>
- @if($platform['url'])
- — <a href="{{ $platform['url'] }}" target="_blank" style="color: #15803d; text-decoration: underline">{{ __('mail.post_published.view_post') }}</a>
- @endif
- </li>
- @endforeach
- </ul>
- </div>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.post_published.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.post_published.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {{ __('mail.post_published.body', ['workspace' => $workspaceName]) }}
+ </p>
+ @if($publication)
+ <table role="presentation" style="margin-top: 24px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td class="sm-p-4" style="border-radius: 12px; border: 1px solid #eae8e5; padding: 20px">@php
+ $emailChannelPlatform = $publication['platform'];
+ $emailChannelName = $publication['accountName'];
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table> @if($postPreview['text'] !== '')
+ <p style="white-space: pre-line; margin: 20px 0 0; line-height: 24px; color: #292928">{{ $postPreview['text'] }}</p>
+ @endif
+ @if($postPreview['image'])
+ <img src="{{ $postPreview['image']['url'] }}" alt="{{ $postPreview['image']['alt'] }}" width="{{ $postPreview['image']['width'] }}" style="vertical-align: middle; margin-top: 20px; height: auto; max-width: 100%; border-radius: 8px" height="auto">
+ @elseif($postPreview['text'] === '')
+ <p style="margin: 20px 0 0; font-size: 14px; color: #5a5a59">{{ $postPreview['attachment'] ?: __('mail.post_preview.no_text') }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ @endif <div role="separator" style="line-height: 24px">&zwj;</div> @if($publishedUrl)
+ <table role="presentation" align="center" style="margin-left: auto; margin-right: auto" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="vertical-align: middle">
+ <div style="text-align: center">
+ <a href="{{ $publishedUrl }}" class="sm-px-1_5 sm-text-xs" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; white-space: nowrap; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 10px 16px; text-align: center; font-size: 14px; line-height: 20px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.post_published.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
+ </a>
+ </div>
+ </td>
+ <td class="sm-w-2" aria-hidden="true" style="width: 12px">&nbsp;</td>
+ <td style="vertical-align: middle">
+ <div style="text-align: center">
+ <a href="{{ $url }}" class="sm-px-1_5 sm-text-xs" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; white-space: nowrap; border: 1px solid #eae8e5; background-color: #ffffff; padding: 10px 16px; text-align: center; font-size: 14px; line-height: 20px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.post_published.open_in_app') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
+ </a>
+ </div>
+ </td>
+ </tr>
+ </table>
+ @else<div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.post_published.open_in_app') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </div>
+ @endif
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/post-rejected.blade.php b/resources/views/mail/post-rejected.blade.php
index 859b47c65..8a83b0057 100644
--- a/resources/views/mail/post-rejected.blade.php
+++ b/resources/views/mail/post-rejected.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,16 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
- }
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,93 +45,114 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.post_rejected.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {{ __('mail.post_rejected.body', ['name' => $approverName, 'workspace' => $workspaceName]) }}
- </p>
- <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #18181b">
- {{ __('mail.post_rejected.channels') }}
- </p>
- <ul style="margin: 8px 0 0; padding-left: 20px; font-size: 14px; line-height: 24px">
- @foreach($channels as $channel)
- <li><strong>{{ $channel }}</strong></li>
- @endforeach
- </ul>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.post_rejected.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.post_rejected.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {{ __('mail.post_rejected.body', ['name' => $approverName, 'workspace' => $workspaceName]) }}
+ </p>
+ <p style="margin: 16px 0 0; font-size: 14px; font-weight: 600; color: #292928">
+ {{ __('mail.post_rejected.channels') }}
+ </p>@foreach($channels as $emailChannel)
+ <table role="presentation" style="margin-top: 12px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 16px">@php
+ $emailChannelPlatform = $emailChannel->platform;
+ $emailChannelName = $emailChannel->display_name;
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+ </table>
+ @endforeach <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.post_rejected.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/webhook-paused.blade.php b/resources/views/mail/webhook-paused.blade.php
index df7846753..86dabda40 100644
--- a/resources/views/mail/webhook-paused.blade.php
+++ b/resources/views/mail/webhook-paused.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,16 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
- }
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,85 +45,100 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.webhook_paused.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {{ __('mail.webhook_paused.body', ['endpoint' => $endpoint]) }}
- </p>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.webhook_paused.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.webhook_paused.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {{ __('mail.webhook_paused.body') }}
+ </p>
+ <div style="margin-top: 16px; border-radius: 8px; background-color: #f7f6f3; padding: 16px">
+ <p style="margin: 0; font-size: 14px; color: #5a5a59">
+ {{ __('webhooks.create.endpoint') }}
+ </p>
+ <p dir="ltr" style="margin: 8px 0 0; word-break: break-all; font-size: 14px; font-weight: 600; color: #292928">
+ {{ $endpoint }}
+ </p>
+ </div>
+ <p style="margin: 24px 0 0; line-height: 24px">
+ {{ __('mail.webhook_paused.next_steps') }}
+ </p>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.webhook_paused.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/workspace-connections-disconnected.blade.php b/resources/views/mail/workspace-connections-disconnected.blade.php
index 9d0ed7975..6f2d8695b 100644
--- a/resources/views/mail/workspace-connections-disconnected.blade.php
+++ b/resources/views/mail/workspace-connections-disconnected.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,31 +28,19 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
- .hover-i-text-decoration-underline:hover {
- text-decoration: underline !important
- }
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
+ .sm-p-4 {
+ padding: 16px !important
}
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -56,111 +48,124 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.workspace_connections_disconnected.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {!! __('mail.workspace_connections_disconnected.intro', ['workspace' => '<strong>'.e($workspaceName).'</strong>']) !!}
- </p>
- <table style="border-collapse: collapse; margin-top: 16px; width: 100%" cellpadding="0" cellspacing="0" role="none">
- @foreach($disconnectedAccounts as $account)
- <tr>
- <td style="border-bottom: 1px solid #e4e4e7; padding-top: 12px; padding-bottom: 12px">
- <div style="display: flex; align-items: center">
- <div style="width: 8px; height: 8px; border-radius: 50%; background-color: {{ $account->platform->color() }}; margin-right: 12px"></div>
- <div>
- <strong style="color: #18181b">{{ $account->platform->label() }}</strong>
- <span style="color: #71717a"> - {{ $account->accountDisplayName() }}</span>
- </div>
- </div>
- </td>
- </tr>
- @endforeach
- </table>
- <p style="margin: 24px 0 0; line-height: 24px">
- {{ __('mail.workspace_connections_disconnected.reasons_title') }}
- </p>
- <ul style="margin: 8px 0 0; padding-left: 20px; line-height: 24px">
- <li>{{ __('mail.workspace_connections_disconnected.reason_expired') }}</li>
- <li>{{ __('mail.workspace_connections_disconnected.reason_revoked') }}</li>
- <li>{{ __('mail.workspace_connections_disconnected.reason_changed') }}</li>
- </ul>
- <p style="margin: 16px 0 0; line-height: 24px">
- {{ __('mail.workspace_connections_disconnected.reconnect_cta') }}
- </p>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.workspace_connections_disconnected.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <p style="margin: 8px 0 0">
- <a href="{{ route('app.notifications.preferences') }}" target="_blank" class="hover-i-text-decoration-underline" style="color: #52525b; text-decoration: none">
- {{ __('mail.layout.manage_notifications') }}
- </a>
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 16px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.workspace_connections_disconnected.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {!! __('mail.workspace_connections_disconnected.intro', ['workspace' => '<strong>'.e($workspaceName).'</strong>']) !!}
+ </p>
+ @foreach($disconnectedAccounts as $account)
+ <table role="presentation" style="margin-top: 16px; width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td class="sm-p-4" style="border-radius: 12px; border: 1px solid #eae8e5; padding: 20px">@php
+ $emailChannelPlatform = $account->platform;
+ $emailChannelName = $account->accountDisplayName();
+ @endphp
+ <table role="presentation" style="width: 100%" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="width: 44px; vertical-align: middle">
+ <img src="{{ asset('images/accounts/'.$emailChannelPlatform->network().'.png') }}" width="32" height="32" alt style="max-width: 100%; vertical-align: middle; display: block; border-radius: 8px">
+ </td>
+ <td style="vertical-align: middle">
+ <p style="margin: 0; font-size: 16px; font-weight: 600; line-height: 20px; color: #292928">{{ $emailChannelName }}</p>
+ @if($emailChannelName !== $emailChannelPlatform->label())
+ <p style="margin: 2px 0 0; font-size: 13px; line-height: 18px; color: #5a5a59">{{ $emailChannelPlatform->label() }}</p>
+ @endif
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+ </table>
+ @endforeach
+ <p style="margin: 24px 0 0; line-height: 24px">
+ {{ __('mail.workspace_connections_disconnected.reasons_title') }}
+ </p>
+ <ul style="margin: 8px 0 0; padding-left: 20px; padding-right: 20px; line-height: 24px">
+ <li>{{ __('mail.workspace_connections_disconnected.reason_expired') }}</li>
+ <li>{{ __('mail.workspace_connections_disconnected.reason_revoked') }}</li>
+ <li>{{ __('mail.workspace_connections_disconnected.reason_changed') }}</li>
+ </ul>
+ <p style="margin: 16px 0 0; line-height: 24px">
+ {{ __('mail.workspace_connections_disconnected.reconnect_cta') }}
+ </p>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.workspace_connections_disconnected.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <p style="margin: 8px 0 0">
+ <a href="{{ route('app.notifications.preferences') }}" target="_blank" style="color: #5a5a59; text-decoration: underline">
+ {{ __('mail.layout.manage_notifications') }}
</a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/resources/views/mail/workspace-invite.blade.php b/resources/views/mail/workspace-invite.blade.php
index 7cbd5174a..b286ab58e 100644
--- a/resources/views/mail/workspace-invite.blade.php
+++ b/resources/views/mail/workspace-invite.blade.php
@@ -1,5 +1,9 @@
+@use('App\Enums\User\Locale')
+@php
+$direction = Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr';
+@endphp
<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ \App\Enums\User\Locale::tryFrom(app()->getLocale())?->direction() ?? 'ltr' }}" xmlns:v="urn:schemas-microsoft-com:vml">
+<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" dir="{{ $direction }}" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
<meta charset="utf-8">
<meta name="x-apple-disable-message-reformatting">
@@ -24,28 +28,16 @@
@endif
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
- <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet" media="screen">
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Outfit:wght@600&display=swap" rel="stylesheet" media="screen">
<style>
@media (max-width: 600px) {
- .sm-my-8 {
- margin-top: 32px !important;
- margin-bottom: 32px !important
- }
- .sm-px-4 {
- padding-left: 16px !important;
- padding-right: 16px !important
- }
- .sm-px-6 {
- padding-left: 24px !important;
- padding-right: 24px !important
- }
- .sm-leading-8 {
- line-height: 32px !important
+ .sm-p-6 {
+ padding: 24px !important
}
}
</style>
</head>
-<body style="margin: 0; width: 100%; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
+<body style="margin: 0; width: 100%; background-color: #f7f6f3; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
@if(isset($previewText))
<div style="display: none">
{{ $previewText }}
@@ -53,93 +45,97 @@
</div>
@endif
<div role="article" aria-roledescription="email" aria-label="{{ $title }}" lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <div class="sm-px-4" style="background-color: #fafafa; font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif">
- <table align="center" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td style="width: 552px; max-width: 100%">
- <div class="sm-my-8" style="margin-top: 48px; margin-bottom: 48px; text-align: center">
- <a href="https://trypost.it" target="_blank">
- <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
- </a>
- </div>
- <table style="width: 100%" cellpadding="0" cellspacing="0" role="none">
- <tr>
- <td class="sm-px-6" style="border-radius: 4px; background-color: #fffffe; padding: 48px; font-size: 16px; color: #3f3f46; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05)">
- <h1 class="sm-leading-8" style="margin: 0 0 24px; font-size: 24px; font-weight: 600; color: #000001">
- {{ __('mail.workspace_invite.heading') }}
- </h1>
- <p style="margin: 0; line-height: 24px">
- {!! __('mail.workspace_invite.intro', ['workspace' => e($workspaceName)]) !!}
- </p>
- <p style="margin: 16px 0 0; line-height: 24px">
- @if($isAdmin)
- {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.admin')).'</strong>']) !!}
- @elseif($requiresApproval)
- {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.needs_approval')).'</strong>']) !!}
- @else
- {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.member')).'</strong>']) !!}
- @endif
- </p>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <div style="display: flex; align-items: center; justify-content: center">
- <div>
- <a href="{{ $url }}" style="display: inline-block; text-decoration: none; padding: 16px 24px; font-size: 16px; line-height: 1; border-radius: 8px; background-color: #7c3aed; color: #ffffff">
- <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
- <span style="mso-text-raise: 16px">{{ __('mail.workspace_invite.button') }}</span>
- <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
- </a>
- </div>
- </div>
- <div role="separator" style="line-height: 24px">&zwj;</div>
- <p style="margin: 0; font-size: 14px; line-height: 24px; color: #71717a">
- {{ __('mail.workspace_invite.expiry') }}
- </p>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td align="center" style="padding: 24px; text-align: center; font-size: 12px; color: #52525b">
- <p style="margin: 0 0 8px">
- {{ __('mail.layout.tagline') }}
- </p>
- <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
- <tr>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://github.com/trypostit/trypost" target="_blank">
- <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://x.com/trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.youtube.com/@trypostit" target="_blank">
- <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ <table role="presentation" style="width: 100%; background-color: #f7f6f3; font-family: Inter, Arial, Helvetica, sans-serif" cellpadding="0" cellspacing="0">
+ <tr>
+ <td align="center" style="padding-left: 16px; padding-right: 16px">
+ <!--[if mso]>
+ <table role="presentation" width="552" align="center"><tr><td>
+ <![endif]-->
+ <table role="presentation" align="center" style="width: 100%; max-width: 552px" cellpadding="0" cellspacing="0">
+ <tr>
+ <td style="padding-top: 32px; padding-bottom: 32px">
+ <div style="text-align: center">
+ <a href="https://trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/logo-header.png') }}" width="150" height="auto" alt="TryPost" style="max-width: 100%; vertical-align: middle; width: 150px; height: auto">
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://trypost.it/discord" target="_blank">
- <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td align="{{ $direction === 'rtl' ? 'right' : 'left' }}" class="sm-p-6" style="border-radius: 12px; border: 1px solid #eae8e5; background-color: #ffffff; padding: 32px; font-size: 16px; line-height: 24px; color: #292928">
+ <h1 style="margin: 0 0 24px; font-family: Outfit, Inter, Arial, Helvetica, sans-serif; font-size: 24px; font-weight: 600; line-height: 32px; color: #292928"> {{ __('mail.workspace_invite.heading') }}</h1>
+ <p style="margin: 0; line-height: 24px">
+ {!! __('mail.workspace_invite.intro', ['workspace' => e($workspaceName)]) !!}
+ </p>
+ <p style="margin: 16px 0 0; line-height: 24px">
+ @if($isAdmin)
+ {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.admin')).'</strong>']) !!}
+ @elseif($requiresApproval)
+ {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.needs_approval')).'</strong>']) !!}
+ @else
+ {!! __('mail.workspace_invite.role', ['role' => '<strong>'.e(__('mail.workspace_invite.roles.member')).'</strong>']) !!}
+ @endif
+ </p>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <div style="text-align: center">
+ <a href="{{ $url }}" style="display: inline-block; text-decoration: none; font-weight: 600; border-radius: 8px; border: 1px solid #ddd6fe; background-color: #ddd6fe; padding: 12px 24px; text-align: center; font-size: 16px; line-height: 24px; color: #292928">
+ <!--[if mso]><i style="mso-font-width: 150%; mso-text-raise: 31px" hidden>&emsp;</i><![endif]-->
+ <span style="mso-text-raise: 16px">{{ __('mail.workspace_invite.button') }}</span>
+ <!--[if mso]><i hidden style="mso-font-width: 150%">&emsp;&#8203;</i><![endif]-->
</a>
- </td>
- <td style="padding-left: 4px; padding-right: 4px">
- <a href="https://www.instagram.com/trypost.en" target="_blank">
- <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
- </a>
- </td>
- </tr>
- </table>
- <p style="margin: 12px 0 0">
- &copy; {{ date('Y') }} TryPost.it
- </p>
- </td>
- </tr>
- </table>
- </div>
+ </div>
+ <div role="separator" style="line-height: 24px">&zwj;</div>
+ <p style="margin: 0; font-size: 14px; line-height: 24px; color: #5a5a59">
+ {{ __('mail.workspace_invite.expiry') }}
+ </p>
+ </td>
+ </tr>
+ <tr>
+ <td align="center" style="padding: 24px; text-align: center; font-size: 12px; line-height: 20px; color: #5a5a59">
+ <p style="margin: 0 0 8px">
+ {!! str_replace(':brand', '<a href="https://trypost.it" target="_blank" style="color: inherit; font-weight: 600; text-decoration: none;">TryPost</a>', e(__('mail.layout.tagline'))) !!}
+ </p>
+ <table role="presentation" cellpadding="0" cellspacing="0" border="0" style="margin-left: auto; margin-right: auto; margin-top: 12px">
+ <tr>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://github.com/trypostit/trypost" target="_blank">
+ <img src="{{ asset('/images/emails/social/github.png') }}" width="20" height="20" alt="GitHub" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://x.com/trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/x.png') }}" width="20" height="20" alt="X" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.youtube.com/@trypostit" target="_blank">
+ <img src="{{ asset('/images/emails/social/youtube.png') }}" width="20" height="20" alt="YouTube" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://trypost.it/discord" target="_blank">
+ <img src="{{ asset('/images/emails/social/discord.png') }}" width="20" height="20" alt="Discord" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ <td style="padding-left: 4px; padding-right: 4px">
+ <a href="https://www.instagram.com/trypost.it" target="_blank">
+ <img src="{{ asset('/images/emails/social/instagram.png') }}" width="20" height="20" alt="Instagram" style="max-width: 100%; vertical-align: middle">
+ </a>
+ </td>
+ </tr>
+ </table>
+ <p style="margin: 12px 0 0">
+ &copy; {{ date('Y') }} TryPost.it
+ </p>
+ </td>
+ </tr>
+ </table>
+ <!--[if mso]>
+ </td></tr></table>
+ <![endif]-->
+ </td>
+ </tr>
+ </table>
</div>
</body>
</html>
\ No newline at end of file
diff --git a/tests/Feature/Mail/MailLocalizationTest.php b/tests/Feature/Mail/MailLocalizationTest.php
index 393ef6a6d..1ce1b3889 100644
--- a/tests/Feature/Mail/MailLocalizationTest.php
+++ b/tests/Feature/Mail/MailLocalizationTest.php
@@ -15,6 +15,7 @@ use App\Models\User;
use App\Models\Webhook;
use App\Models\Workspace;
use Illuminate\Support\Facades\Mail;
+use Symfony\Component\DomCrawler\Crawler;
function localizedOwner(Locale $locale): User
{
@@ -90,7 +91,8 @@ test('the subject and body of a rendered mailable are actually translated', func
$mailable->assertSeeInHtml(__('mail.account_disconnected.heading', [], 'pt-BR'));
$mailable->assertSeeInHtml(__('mail.account_disconnected.reason_expired', [], 'pt-BR'));
- $mailable->assertSeeInHtml(__('mail.layout.tagline', [], 'pt-BR'));
+ $footer = (new Crawler($mailable->render()))->filter('p > a[href="https://trypost.it"]')->ancestors()->first();
+ expect($footer->text())->toBe(__('mail.layout.tagline', ['brand' => 'TryPost'], 'pt-BR'));
$mailable->assertDontSeeInHtml(__('mail.account_disconnected.heading', [], 'en'));
});
diff --git a/tests/Feature/Mail/MailRenderingTest.php b/tests/Feature/Mail/MailRenderingTest.php
index 123ff4780..8fd0e9ede 100644
--- a/tests/Feature/Mail/MailRenderingTest.php
+++ b/tests/Feature/Mail/MailRenderingTest.php
@@ -27,6 +27,39 @@ use Illuminate\Auth\Notifications\ResetPassword;
use Illuminate\Auth\Notifications\VerifyEmail;
use Illuminate\Notifications\Notification as BaseNotification;
use Illuminate\Support\Facades\Mail;
+use Symfony\Component\DomCrawler\Crawler;
+
+test('the shared email layout keeps the action and the appropriate footer', function (string $template, bool $hasPreferences, Locale $locale) {
+ app()->setLocale($locale->value);
+
+ $html = view("mail.{$template}", [
+ 'title' => 'TryPost',
+ 'previewText' => 'Your TryPost update',
+ 'url' => 'https://example.test/email-action',
+ 'user' => User::factory()->make(['name' => 'Paulo']),
+ 'workspaceName' => 'Launch Team',
+ 'platformName' => 'YouTube',
+ 'accountName' => 'Paulo',
+ 'account' => SocialAccount::factory()->make(['platform' => Platform::YouTube, 'display_name' => 'Paulo']),
+ 'isAdmin' => false,
+ 'requiresApproval' => true,
+ ])->render();
+
+ $document = new Crawler($html);
+
+ expect($document->filter('h1')->count())->toBe(1)
+ ->and($document->filter('a[href="https://example.test/email-action"]')->count())->toBe(1)
+ ->and($document->filter('a[href="https://www.instagram.com/trypost.it"]')->count())->toBe(1)
+ ->and($document->filter('a[href="'.route('app.notifications.preferences').'"]')->count())->toBe($hasPreferences ? 1 : 0)
+ ->and($document->filter('html')->attr('dir'))->toBe($locale->direction())
+ ->and($document->filter('h1')->ancestors()->first()->attr('align'))->toBe($locale->direction() === 'rtl' ? 'right' : 'left')
+ ->and($html)->not->toContain('<x-', 'trypost.en');
+})->with([
+ 'notification' => ['account-disconnected', true],
+ 'invitation' => ['workspace-invite', false],
+ 'verification' => ['email-verification', false],
+ 'password reset' => ['password-reset', false],
+])->with([Locale::English, Locale::PortugueseBrazil, Locale::Arabic]);
test('the workspace invite renders in the requested locale and names the workspace', function () {
$account = Account::factory()->create(['name' => 'Acme Co']);
@@ -102,6 +135,7 @@ test('the post note email renders the note, the post and its channels', function
$mailable->assertSeeInHtml('Can we swap the image?');
$mailable->assertSeeInHtml('Launch day is here');
$mailable->assertSeeInHtml('LinkedIn');
+ $mailable->assertSeeInHtml(asset('images/accounts/linkedin.png'));
$mailable->assertSeeInHtml(route('app.posts.edit', ['post' => $post, 'comment' => $note->id]), false);
})->with([Locale::English, Locale::PortugueseBrazil]);
@@ -145,6 +179,8 @@ test('the disconnected-connections digest renders every account and reason', fun
foreach ($accounts as $account) {
$mailable->assertSeeInHtml($account->platform->label());
+ $mailable->assertSeeInHtml($account->accountDisplayName());
+ $mailable->assertSeeInHtml(asset('images/accounts/'.$account->platform->network().'.png'));
}
});
@@ -201,6 +237,7 @@ test('the approval request email renders who asked, the channels, the excerpt an
$mailable->assertSeeInHtml(__('mail.post_approval_requested.button', [], $locale->value));
$mailable->assertSeeInHtml('Big launch tomorrow');
$mailable->assertSeeInHtml('LinkedIn');
+ $mailable->assertSeeInHtml(asset('images/accounts/linkedin.png'));
$mailable->assertSeeInHtml(route('app.posts.index', ['tab' => 'approvals']), false);
})->with([Locale::English, Locale::PortugueseBrazil]);
@@ -229,6 +266,9 @@ test('the approved and rejected emails render the approver, the channels and the
$rejected = (new PostRejected([$post->id], $approver))->locale($locale->value);
+ $rejected->assertSeeInHtml(asset('images/accounts/linkedin.png'));
+ $approved->assertSeeInHtml(asset('images/accounts/linkedin.png'));
+
$rejected->assertHasSubject(__('mail.post_rejected.subject', ['name' => 'Ada Approver'], $locale->value));
$rejected->assertSeeInHtml(e(__('mail.post_rejected.body', ['name' => 'Ada Approver', 'workspace' => 'Acme Workspace'], $locale->value)), false);
$rejected->assertSeeInHtml(__('mail.post_rejected.button', [], $locale->value));
@@ -331,17 +371,17 @@ test('the approved email lists the time of each channel when they go out at diff
$mailable = (new PostApproved([$linkedIn->id, $x->id, $mastodon->id], $approver, $author))->locale($locale->value);
$mailable->assertSeeInOrderInHtml([
- $linkedIn->postPlatforms()->sole()->notificationLabel(),
+ $linkedIn->postPlatforms()->sole()->display_name,
approvalEmailTimeLabel($morning, $author, $locale),
- $x->postPlatforms()->sole()->notificationLabel(),
+ $x->postPlatforms()->sole()->display_name,
approvalEmailTimeLabel($evening, $author, $locale),
- $mastodon->postPlatforms()->sole()->notificationLabel(),
+ $mastodon->postPlatforms()->sole()->display_name,
__('mail.post_approved.publishing_now', [], $locale->value),
]);
- $mailable->assertSeeInHtml(__('mail.post_approved.channel_time', [
- 'channel' => '<strong>'.e($x->postPlatforms()->sole()->notificationLabel()).'</strong>',
- 'time' => approvalEmailTimeLabel($evening, $author, $locale),
- ], $locale->value), false);
+ $document = new Crawler($mailable->render());
+ foreach ([Platform::LinkedIn, Platform::X, Platform::Mastodon] as $platform) {
+ expect($document->filter('img[src="'.asset('images/accounts/'.$platform->network().'.png').'"]')->count())->toBe(1);
+ }
})->with([Locale::English, Locale::PortugueseBrazil, Locale::French]);
test('the approved email shows one time when every channel goes out together', function () {
@@ -402,3 +442,17 @@ test('the email layout carries the recipient locale and direction', function (Lo
'arabic' => [Locale::Arabic, 'rtl'],
'portuguese' => [Locale::PortugueseBrazil, 'ltr'],
]);
+
+test('approval emails keep distinct channels with the same name and escape their names', function () {
+ $author = User::factory()->create(['timezone' => 'UTC']);
+ $workspace = Workspace::factory()->create(['account_id' => $author->account_id, 'user_id' => $author->id]);
+ $first = approvalEmailPost($workspace, $author, Platform::Instagram, 'Studio <Team>');
+ $second = approvalEmailPost($workspace, $author, Platform::Instagram, 'Studio <Team>');
+
+ $html = (new PostRejected([$first->id, $second->id], $author))->render();
+ $document = new Crawler($html);
+
+ expect($document->filter('img[src="'.asset('images/accounts/instagram.png').'"]')->count())->toBe(2)
+ ->and($html)->toContain('Studio &lt;Team&gt;')
+ ->not->toContain('Studio <Team>');
+});
diff --git a/tests/Feature/Mail/PostPublicationPreviewTest.php b/tests/Feature/Mail/PostPublicationPreviewTest.php
new file mode 100644
index 000000000..e6b447be9
--- /dev/null
+++ b/tests/Feature/Mail/PostPublicationPreviewTest.php
@@ -0,0 +1,165 @@
+<?php
+
+declare(strict_types=1);
+
+use App\Enums\PostPlatform\Status;
+use App\Enums\SocialAccount\Platform;
+use App\Enums\User\Locale;
+use App\Mail\PostPublished;
+use App\Mail\PostPublishFailed;
+use App\Models\Post;
+use App\Models\PostPlatform;
+use App\Models\SocialAccount;
+use App\Support\Mail\PostPreview;
+use Symfony\Component\DomCrawler\Crawler;
+
+test('the email channel component resolves the platform name and its network logo', function (Platform $platform) {
+ $html = view('mail.post-published', [
+ 'title' => 'Published',
+ 'workspaceName' => 'Launch Team',
+ 'url' => 'https://example.test/post',
+ 'publishedUrl' => null,
+ 'publication' => ['platform' => $platform, 'accountName' => 'Paulo <Studio>'],
+ 'postPreview' => ['text' => 'Launch day', 'image' => null, 'attachment' => null],
+ ])->render();
+ $document = new Crawler($html);
+ $icon = 'images/accounts/'.$platform->network().'.png';
+
+ expect($document->filter('img[src="'.asset($icon).'"]')->count())->toBe(1)
+ ->and($document->filter('p')->reduce(fn (Crawler $node): bool => $node->text() === 'Paulo <Studio>')->count())->toBe(1)
+ ->and($html)->toContain(e($platform->label()))
+ ->not->toContain('<Studio>', '<x-channel-identity', '{!! platformExpression !!}')
+ ->and(is_file(public_path($icon)))->toBeTrue();
+})->with(Platform::cases());
+
+test('publication emails show the channel and escaped post content separately', function (Status $status, Locale $locale) {
+ app()->setLocale($locale->value);
+ $post = Post::factory()->create(['content' => '<p>Tom &amp; Jerry</p><p>New post</p>']);
+ $account = SocialAccount::factory()->instagram()->create([
+ 'workspace_id' => $post->workspace_id,
+ 'display_name' => 'Paulo Castellano',
+ 'username' => 'paulocastellano',
+ ]);
+ PostPlatform::factory()->instagram()->create([
+ 'post_id' => $post->id,
+ 'social_account_id' => $account->id,
+ 'status' => $status,
+ 'platform_url' => 'https://www.instagram.com/p/published-post/',
+ 'error_message' => 'Connection expired <script>alert(1)</script>',
+ ]);
+ PostPlatform::factory()->disabled()->create([
+ 'post_id' => $post->id,
+ 'status' => $status,
+ 'error_message' => 'Disabled target error',
+ ]);
+
+ $mail = $status === Status::Published ? new PostPublished($post) : new PostPublishFailed($post);
+ $html = $mail->render();
+ $document = new Crawler($html);
+
+ expect($html)->toContain("Tom &amp; Jerry\nNew post", 'Paulo Castellano', 'Instagram')
+ ->not->toContain('Instagram (@paulocastellano)', 'Disabled target error')
+ ->and($document->filter('script')->count())->toBe(0)
+ ->and($document->filter('img[src="'.asset('images/accounts/instagram.png').'"]')->count())->toBe(1);
+
+ if ($status === Status::Published) {
+ expect($document->filter('a[href="https://www.instagram.com/p/published-post/"]')->count())->toBe(1)
+ ->and($document->filter('a[href="https://www.instagram.com/p/published-post/"]')->text())->toBe(__('mail.post_published.button'))
+ ->and($document->filter('a[href="'.route('app.posts.edit', $post).'"]')->text())->toBe(__('mail.post_published.open_in_app'))
+ ->and($document->filter('body')->text())->not->toContain('https://www.instagram.com/p/published-post/')
+ ->and($html)->not->toContain('Connection expired');
+
+ $publicAction = $document->filter('a[href="https://www.instagram.com/p/published-post/"]');
+ $appAction = $document->filter('a[href="'.route('app.posts.edit', $post).'"]');
+
+ expect($publicAction->closest('tr')->getNode(0))->toBe($appAction->closest('tr')->getNode(0))
+ ->and($publicAction->attr('style'))->toContain('background-color: #ddd6fe', 'border')
+ ->and($appAction->attr('style'))->toContain('background-color: #ffffff', 'border');
+ } else {
+ $mail->assertSeeInOrderInHtml([
+ 'New post',
+ __('mail.post_preview.error'),
+ 'Connection expired &lt;script&gt;alert(1)&lt;/script&gt;',
+ ], false);
+ }
+})->with([Status::Published, Status::Failed])->with([Locale::English, Locale::PortugueseBrazil, Locale::Arabic]);
+
+test('published email keeps the channel snapshot and falls back to the app when no public link exists', function () {
+ $post = Post::factory()->published()->create(['content' => null]);
+ PostPlatform::factory()->instagram()->published()->create([
+ 'post_id' => $post->id,
+ 'social_account_id' => null,
+ 'platform_name' => 'Archived profile',
+ 'platform_url' => null,
+ ]);
+
+ $mail = new PostPublished($post);
+
+ $mail->assertSeeInHtml('Archived profile');
+ $mail->assertSeeInHtml(__('mail.post_preview.no_text'));
+ $mail->assertSeeInHtml(route('app.posts.edit', $post));
+
+ expect((new Crawler($mail->render()))->filter('a[href="'.route('app.posts.edit', $post).'"]')->count())->toBe(1);
+ $mail->assertSeeInHtml(__('mail.post_published.open_in_app'));
+ $mail->assertDontSeeInHtml(__('mail.post_published.button'));
+});
+
+test('the email preview uses the first image and preserves its proportions', function () {
+ $post = Post::factory()->make([
+ 'content' => null,
+ 'media' => [[
+ 'path' => 'portrait.jpg',
+ 'url' => 'https://example.test/portrait.jpg',
+ 'type' => 'image',
+ 'meta' => ['width' => 1080, 'height' => 1920, 'alt_text' => 'Our studio'],
+ ]],
+ ]);
+
+ expect(PostPreview::from($post)['image'])->toBe([
+ 'url' => 'https://example.test/portrait.jpg',
+ 'alt' => 'Our studio',
+ 'width' => 158,
+ ]);
+});
+
+test('the email preview does not render a video as an image', function () {
+ $post = Post::factory()->make([
+ 'content' => null,
+ 'media' => [[
+ 'path' => 'launch.mp4',
+ 'url' => 'https://example.test/launch.mp4',
+ 'type' => 'video',
+ 'original_filename' => 'Launch video.mp4',
+ ], [
+ 'path' => 'second.jpg',
+ 'url' => 'https://example.test/second.jpg',
+ 'type' => 'image',
+ ]],
+ ]);
+
+ expect(PostPreview::from($post))->toBe([
+ 'text' => '',
+ 'image' => null,
+ 'attachment' => 'Launch video.mp4',
+ ]);
+});
+
+test('the image preview renders without a caption and escapes its alternative text', function () {
+ $post = Post::factory()->published()->create([
+ 'content' => null,
+ 'media' => [[
+ 'path' => 'photo.jpg',
+ 'url' => 'https://example.test/photo.jpg',
+ 'type' => 'image',
+ 'meta' => ['alt_text' => 'Studio " onclick="alert(1)'],
+ ]],
+ ]);
+ PostPlatform::factory()->instagram()->published()->create(['post_id' => $post->id]);
+
+ $document = new Crawler((new PostPublished($post))->render());
+ $image = $document->filter('img[src="https://example.test/photo.jpg"]');
+
+ expect($image->count())->toBe(1)
+ ->and($image->attr('alt'))->toBe('Studio " onclick="alert(1)')
+ ->and($image->attr('onclick'))->toBeNull();
+});
diff --git a/tests/Unit/Mail/PostPublishFailedTest.php b/tests/Unit/Mail/PostPublishFailedTest.php
index 9bc520f6a..58ed2f048 100644
--- a/tests/Unit/Mail/PostPublishFailedTest.php
+++ b/tests/Unit/Mail/PostPublishFailedTest.php
@@ -24,7 +24,8 @@ test('failed email falls back to the page display name when facebook has no user
$mail = new PostPublishFailed($post);
- $mail->assertSeeInHtml('Facebook Page (@InboxPlacement.io)');
+ $mail->assertSeeInHtml('Facebook Page');
+ $mail->assertSeeInHtml('InboxPlacement.io');
$mail->assertDontSeeInHtml('Facebook Page (@)');
});
diff --git a/tests/Unit/Mail/PostPublishedTest.php b/tests/Unit/Mail/PostPublishedTest.php
index d1f7b1590..2cc87485a 100644
--- a/tests/Unit/Mail/PostPublishedTest.php
+++ b/tests/Unit/Mail/PostPublishedTest.php
@@ -25,7 +25,8 @@ test('published email falls back to the page display name when facebook has no u
$mail = new PostPublished($post);
- $mail->assertSeeInHtml('Facebook Page (@InboxPlacement.io)');
+ $mail->assertSeeInHtml('Facebook Page');
+ $mail->assertSeeInHtml('InboxPlacement.io');
$mail->assertDontSeeInHtml('Facebook Page (@)');
$mail->assertSeeInHtml('https://www.facebook.com/permalink.php?story_fbid=pfbid0&id=61592851040951');
});
@@ -46,7 +47,8 @@ test('published email uses the username when the display name is empty', functio
$mail = new PostPublished($post);
- $mail->assertSeeInHtml('Bluesky (@inboxplacementio.bsky.social)');
+ $mail->assertSeeInHtml('Bluesky');
+ $mail->assertSeeInHtml('inboxplacementio.bsky.social');
$mail->assertDontSeeInHtml('Bluesky (@)');
});
diff --git a/tests/Unit/Mail/WebhookPausedMailTest.php b/tests/Unit/Mail/WebhookPausedMailTest.php
index 15f9d2ac3..4f4cf8c3d 100644
--- a/tests/Unit/Mail/WebhookPausedMailTest.php
+++ b/tests/Unit/Mail/WebhookPausedMailTest.php
@@ -2,9 +2,11 @@
declare(strict_types=1);
+use App\Enums\User\Locale;
use App\Mail\WebhookPausedMail;
use App\Models\Webhook;
use Illuminate\Contracts\Queue\ShouldQueue;
+use Symfony\Component\DomCrawler\Crawler;
test('webhook paused mail has the translated subject', function () {
$webhook = Webhook::factory()->create([
@@ -39,7 +41,9 @@ test('webhook paused mail is queueable', function () {
expect(new WebhookPausedMail($webhook))->toBeInstanceOf(ShouldQueue::class);
});
-test('webhook paused mail renders the maizzle layout', function () {
+test('webhook paused mail separates the endpoint from the explanation in every locale', function (string $locale) {
+ app()->setLocale($locale);
+
$webhook = Webhook::factory()->create([
'endpoint' => 'https://example.com/hooks',
]);
@@ -47,11 +51,28 @@ test('webhook paused mail renders the maizzle layout', function () {
$mail = new WebhookPausedMail($webhook);
$mail->assertSeeInHtml(__('mail.webhook_paused.title'));
- $mail->assertSeeInHtml(__('mail.webhook_paused.body', [
- 'endpoint' => 'https://example.com/hooks',
- ]));
+ $mail->assertSeeInOrderInHtml([
+ __('mail.webhook_paused.body'),
+ __('webhooks.create.endpoint'),
+ 'https://example.com/hooks',
+ __('mail.webhook_paused.next_steps'),
+ ]);
$mail->assertSeeInHtml(__('mail.webhook_paused.button'));
$mail->assertSeeInHtml(route('app.webhooks.show', $webhook));
- $mail->assertSeeInHtml('Manage notifications');
+ $mail->assertSeeInHtml(__('mail.layout.manage_notifications'));
$mail->assertSeeInHtml(route('app.notifications.preferences'));
+
+ $document = new Crawler($mail->render());
+
+ expect($document->filter('p[dir="ltr"]')->text())->toBe($webhook->endpoint);
+})->with(Locale::values());
+
+test('the highlighted webhook endpoint is escaped as text', function () {
+ $endpoint = 'https://example.com/hooks?label=<script>alert(1)</script>&topic=posts';
+ $webhook = Webhook::factory()->create(['endpoint' => $endpoint]);
+ $html = (new WebhookPausedMail($webhook))->render();
+ $document = new Crawler($html);
+
+ expect($document->filter('p[dir="ltr"]')->text())->toBe($endpoint)
+ ->and($document->filter('script')->count())->toBe(0);
});
diff --git a/tests/fixtures/single-line-copy.php b/tests/fixtures/single-line-copy.php
index 1acd8bb1f..312cdd5a9 100644
--- a/tests/fixtures/single-line-copy.php
+++ b/tests/fixtures/single-line-copy.php
@@ -55,6 +55,8 @@ return [
'create.tabs.ideas' => 8,
'create.tabs.templates' => 10,
'labels.description' => 47,
+ 'mail.post_published.button' => 22,
+ 'mail.post_published.open_in_app' => 19,
'mcp.authorize.approve' => 13,
'mcp.authorize.cancel' => 9,
'mcp.authorize.select_workspace' => 28,