feat: add backstage/filament-mails

This commit is contained in:
idevakk
2025-09-28 22:43:41 +05:30
parent 5325eb34cd
commit 122c4d8f89
18 changed files with 619 additions and 2 deletions

View File

View File

@@ -0,0 +1,8 @@
<a type="button"
href="{{ route('filament.' . Filament\Facades\Filament::getCurrentPanel()->getId() . '.mails.attachment.download', [
'tenant' => Filament\Facades\Filament::getTenant(),
'mail' => $getState()->mail_id,
'attachment' => $getState()->id,
'filename' => $getState()->filename,
]) }}"
class="rounded-md bg-white px-3.5 py-2.5 text-sm font-semibold cursor-pointer text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 hover:bg-gray-50">Download</a>

View File

@@ -0,0 +1,5 @@
<div class="prose prose-sm sm:prose lg:prose-lg xl:prose-2xl max-w-full overflow-x-auto">
<pre class="whitespace-pre-wrap break-words">
<code class="language-html">{{ $html }}</code>
</pre>
</div>

View File

@@ -0,0 +1,6 @@
<div class="w-full h-screen">
<iframe
src="{{ route('filament.' . Filament\Facades\Filament::getCurrentPanel()->getId() . '.mails.preview', ['tenant' => Filament\Facades\Filament::getTenant(), 'mail' => $mail->id]) }}"
class="w-full h-full max-w-full" style="width: 100vw; height: 100vh; border: none;">
</iframe>
</div>