Add NAS file manager integration and all pending platform changes

- Installed p7h/nas-file-manager package via private VCS repo
- Published config/nas-file-manager.php with super_admin middleware restriction
- Added NAS env vars to .env.example
- Created admin/nas-storage page with connection info panel and file browser widget
- Added NAS Storage link to admin sidebar (super_admin only)
- Added SuperAdminController@nasStorage method and admin.nas-storage route
- Includes all accumulated branch changes: profile wall, 2FA, audit logs,
  settings panel, country/phone/timezone components, posts, slideshow,
  playlist shares, video downloads/shares, comment likes, notifications,
  social links, and more

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
This commit is contained in:
ghassanandClaude Sonnet 4.6 committed 2026-05-13 13:24:32 +03:00
1 parent d44490dfe0
commit 0b2e95ea65
161 files changed
+27496 -7250

No files matched your search

@@ -0,0 +1,47 @@
<x-emails.layout subject="Confirm disabling Two-Factor Authentication">
{{-- Icon --}}
<div style="width:64px;height:64px;border-radius:50%;background:rgba(230,30,30,.12);border:1px solid rgba(230,30,30,.25);margin:0 auto 24px;text-align:center;line-height:64px;font-size:28px;">&#x1F6E1;&#xFE0F;</div>
<h1 class="email-title">Disable Two-Factor Authentication?</h1>
<p class="email-subtitle">Someone requested to turn off 2FA on your account.</p>
<p class="email-text">Hi <strong style="color:#f1f1f1;">{{ $user->name }}</strong>,</p>
<p class="email-text">
A request was made to <strong style="color:#e61e1e;">disable two-factor authentication</strong> on your
<strong style="color:#f1f1f1;">TAKEONE</strong> account. If this was you, click the button below to confirm.
</p>
<div class="email-infobox" style="background:rgba(230,30,30,.08);border-color:rgba(230,30,30,.3);margin-bottom:28px;">
<p style="margin:0;font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;font-size:13px;color:#cc4444;line-height:1.6;">
&#9888;&nbsp; <strong>Warning:</strong> Disabling 2FA will make your account less secure.
Anyone who gains access to your password could log in without a second step.
</p>
</div>
{{-- CTA --}}
<div class="email-btn-wrap">
<a href="{{ $confirmUrl }}" class="email-btn" style="background:#e61e1e;">Yes, disable 2FA</a>
</div>
{{-- Expiry notice --}}
<div class="email-infobox" style="text-align:center;">
<p style="margin:0;font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;font-size:13px;color:#666;line-height:1.6;">
&#9201;&nbsp; This link expires in <strong style="color:#888;">15 minutes</strong>.
If it expires, go to your channel settings and submit the form again.
</p>
</div>
<hr class="email-divider">
<p class="email-note">
<strong style="color:#f1f1f1;">Didn't request this?</strong>
Do not click the button above. Your 2FA remains active. Consider changing your password immediately
as someone may have access to your account.
</p>
<p class="email-note" style="margin-top:12px;">
If the button above doesn't work, copy and paste this link into your browser:<br>
<a href="{{ $confirmUrl }}" style="color:#e61e1e;word-break:break-all;">{{ $confirmUrl }}</a>
</p>
</x-emails.layout>
+218
View File
@@ -0,0 +1,218 @@
<!DOCTYPE html>
<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>{{ $subject ?? config('app.name') }}</title>
<style>
/* Reset */
body, table, td, a { -webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; }
table, td { mso-table-lspace: 0; mso-table-rspace: 0; }
img { -ms-interpolation-mode: bicubic; border: 0; outline: none; text-decoration: none; }
body { margin: 0; padding: 0; background-color: #0f0f0f; width: 100% !important; }
.wrapper { background-color: #0f0f0f; padding: 40px 16px; }
.email-card {
max-width: 600px;
margin: 0 auto;
background: #181818;
border-radius: 16px;
overflow: hidden;
border: 1px solid #2a2a2a;
box-shadow: 0 24px 64px rgba(0,0,0,0.6);
}
/* Header */
.email-header {
background: #0f0f0f;
border-bottom: 1px solid #2a2a2a;
padding: 28px 40px;
text-align: center;
}
.email-header img { height: 36px; display: block; margin: 0 auto; }
/* Body */
.email-body { padding: 40px; }
.email-icon {
width: 64px;
height: 64px;
border-radius: 50%;
margin: 0 auto 24px;
display: flex;
align-items: center;
justify-content: center;
font-size: 28px;
}
h1.email-title {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
font-size: 22px;
font-weight: 700;
color: #f1f1f1;
margin: 0 0 8px;
text-align: center;
line-height: 1.3;
}
p.email-subtitle {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
font-size: 14px;
color: #888;
text-align: center;
margin: 0 0 32px;
line-height: 1.6;
}
p.email-text {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
font-size: 15px;
color: #c8c8c8;
margin: 0 0 20px;
line-height: 1.7;
}
/* CTA Button */
.email-btn-wrap { text-align: center; margin: 32px 0; }
.email-btn {
display: inline-block;
background: #e61e1e;
color: #ffffff !important;
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
font-size: 15px;
font-weight: 700;
text-decoration: none;
padding: 14px 36px;
border-radius: 50px;
letter-spacing: 0.3px;
box-shadow: 0 8px 24px rgba(230,30,30,0.35);
}
.email-btn:hover { background: #c91a1a; }
/* Info box */
.email-infobox {
background: #222;
border: 1px solid #2d2d2d;
border-radius: 12px;
padding: 20px 24px;
margin: 24px 0;
}
.email-infobox-label {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
font-size: 11px;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.08em;
color: #666;
margin: 0 0 12px;
}
.email-inforow {
display: flex;
align-items: flex-start;
gap: 10px;
margin-bottom: 10px;
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}
.email-inforow:last-child { margin-bottom: 0; }
.email-inforow-key {
font-size: 13px;
color: #666;
min-width: 90px;
flex-shrink: 0;
}
.email-inforow-val {
font-size: 13px;
color: #c8c8c8;
font-weight: 500;
word-break: break-all;
}
/* Divider */
.email-divider {
border: none;
border-top: 1px solid #2a2a2a;
margin: 32px 0;
}
/* Small note */
.email-note {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
font-size: 12px;
color: #555;
text-align: center;
line-height: 1.7;
margin: 0;
}
.email-note a { color: #888; text-decoration: underline; }
/* Footer */
.email-footer {
background: #0f0f0f;
border-top: 1px solid #2a2a2a;
padding: 24px 40px;
text-align: center;
}
.email-footer p {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
font-size: 12px;
color: #444;
margin: 4px 0;
line-height: 1.6;
}
.email-footer a { color: #666; text-decoration: none; }
.email-footer a:hover { color: #e61e1e; }
/* Thumbnail */
.email-thumb-wrap { margin: 0 0 28px; text-align: center; }
.email-thumb-wrap a { display: block; }
.email-thumb-wrap img {
width: 100%;
max-width: 520px;
height: auto;
border-radius: 12px;
display: block;
margin: 0 auto;
border: 1px solid #2a2a2a;
}
.email-thumb-placeholder {
width: 100%;
max-width: 520px;
height: 190px;
background: linear-gradient(135deg, #1a1a1a 0%, #2a0808 100%);
border-radius: 12px;
display: flex;
align-items: center;
justify-content: center;
margin: 0 auto;
border: 1px solid #2a2a2a;
flex-direction: column;
gap: 10px;
}
.email-thumb-placeholder span {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
font-size: 15px;
font-weight: 600;
color: #888;
}
@media only screen and (max-width: 600px) {
.wrapper { padding: 20px 10px; }
.email-body { padding: 28px 24px; }
.email-header { padding: 22px 24px; }
.email-footer { padding: 20px 24px; }
h1.email-title { font-size: 20px; }
}
</style>
</head>
<body>
<div class="wrapper">
<div class="email-card">
{{-- Header --}}
<div class="email-header">
<img src="{{ config('app.url') }}/storage/images/fullLogo.png" alt="{{ config('app.name') }}">
</div>
{{-- Body --}}
<div class="email-body">
{{ $slot }}
</div>
{{-- Footer --}}
<div class="email-footer">
<p>&copy; {{ date('Y') }} <strong style="color:#666;">TAKEONE</strong> &mdash; Video Platform</p>
<p><a href="{{ config('app.url') }}">{{ config('app.url') }}</a></p>
<p style="margin-top:8px;">This email was sent to you because you have an account on TAKEONE.</p>
</div>
</div>
</div>
</body>
</html>
@@ -0,0 +1,60 @@
<x-emails.layout subject="{{ $uploader->name }} just uploaded a new video">
{{-- Icon --}}
<div style="width:64px;height:64px;border-radius:50%;background:rgba(230,30,30,.12);border:1px solid rgba(230,30,30,.25);margin:0 auto 24px;text-align:center;line-height:64px;font-size:28px;">&#x1F514;</div>
<h1 class="email-title">New video from {{ $uploader->name }}</h1>
<p class="email-subtitle">A channel you subscribed to just posted new content.</p>
{{-- Thumbnail --}}
<div class="email-thumb-wrap">
@if($video->thumbnail)
<a href="{{ route('videos.show', $video) }}">
<img src="{{ asset('storage/thumbnails/' . $video->thumbnail) }}" alt="{{ $video->title }}">
</a>
@else
<div class="email-thumb-placeholder">
<span style="font-size:32px;">▶</span>
<span>{{ Str::limit($video->title, 40) }}</span>
</div>
@endif
</div>
{{-- Details box --}}
<div class="email-infobox">
<div class="email-infobox-label">Video Details</div>
<div class="email-inforow">
<span class="email-inforow-key">Title</span>
<span class="email-inforow-val">{{ $video->title }}</span>
</div>
@if($video->description)
<div class="email-inforow">
<span class="email-inforow-key">Description</span>
<span class="email-inforow-val">{{ Str::limit($video->description, 100) }}</span>
</div>
@endif
@if($video->formatted_duration)
<div class="email-inforow">
<span class="email-inforow-key">Duration</span>
<span class="email-inforow-val">{{ $video->formatted_duration }}</span>
</div>
@endif
<div class="email-inforow">
<span class="email-inforow-key">Channel</span>
<span class="email-inforow-val">{{ $uploader->name }}</span>
</div>
</div>
{{-- CTA --}}
<div class="email-btn-wrap">
<a href="{{ route('videos.show', $video) }}" class="email-btn">&#9654;&nbsp; Watch Now</a>
</div>
<hr class="email-divider">
<p class="email-note">
You're receiving this because you subscribed to <strong>{{ $uploader->name }}</strong>'s channel on {{ config('app.name') }}.
Visit <a href="{{ route('channel', $uploader->channel) }}">their channel</a> to manage your subscription.
</p>
</x-emails.layout>
@@ -0,0 +1,38 @@
<x-emails.layout subject="Verify your email address">
{{-- Icon --}}
<div style="width:64px;height:64px;border-radius:50%;background:rgba(230,30,30,.12);border:1px solid rgba(230,30,30,.25);margin:0 auto 24px;text-align:center;line-height:64px;font-size:28px;">&#x2709;&#xFE0F;</div>
<h1 class="email-title">Verify your email address</h1>
<p class="email-subtitle">One quick step before you can start sharing videos.</p>
<p class="email-text">Hi <strong style="color:#f1f1f1;">{{ $userName }}</strong>,</p>
<p class="email-text">
Thanks for signing up for <strong style="color:#f1f1f1;">TAKEONE</strong>!
To activate your account and start uploading and watching videos, please verify your email address by clicking the button below.
</p>
{{-- CTA --}}
<div class="email-btn-wrap">
<a href="{{ $url }}" class="email-btn">Verify Email Address</a>
</div>
{{-- Expiry notice --}}
<div class="email-infobox" style="text-align:center;">
<p style="margin:0;font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;font-size:13px;color:#666;line-height:1.6;">
&#9201;&nbsp; This link expires in <strong style="color:#888;">60 minutes</strong>.
If it expires, simply sign in and we'll send you a fresh one.
</p>
</div>
<hr class="email-divider">
<p class="email-note">
If you didn't create a TAKEONE account, you can safely ignore this email &mdash; no action is needed.
</p>
<p class="email-note" style="margin-top:12px;">
If the button above doesn't work, copy and paste this link into your browser:<br>
<a href="{{ $url }}" style="color:#e61e1e;word-break:break-all;">{{ $url }}</a>
</p>
</x-emails.layout>
+64 -79
View File
@@ -1,89 +1,74 @@
<!DOCTYPE html>
<html>
<x-emails.layout subject="Your video is live on TAKEONE">
<head>
<style>
body {
font-family: Arial, sans-serif;
line-height: 1.6;
color: #333;
}
{{-- Icon --}}
<div style="width:64px;height:64px;border-radius:50%;background:rgba(230,30,30,.12);border:1px solid rgba(230,30,30,.25);margin:0 auto 24px;text-align:center;line-height:64px;font-size:28px;">&#x1F3AC;</div>
.container {
max-width: 600px;
margin: 0 auto;
padding: 20px;
}
<h1 class="email-title">Your video is live!</h1>
<p class="email-subtitle">It's uploading and processing right now — we'll have it ready shortly.</p>
.header {
background: #e61e1e;
color: white;
padding: 20px;
text-align: center;
}
<p class="email-text">Hi <strong style="color:#f1f1f1;">{{ $userName }}</strong>,</p>
<p class="email-text">
Your video <strong style="color:#f1f1f1;">"{{ $video->title }}"</strong> has been received and is now queued for processing.
Once encoding is complete it will be publicly available on your channel.
</p>
.content {
padding: 20px;
background: #f9f9f9;
}
.footer {
text-align: center;
padding: 20px;
color: #666;
font-size: 12px;
}
</style>
</head>
<body>
<div class="container">
<div class="header">
<h1>TAKEONE</h1>
</div>
<div class="content">
<h2>Video Uploaded Successfully! 🎉</h2>
<p>Hi {{ $userName }},</p>
<p>Your video <strong>"{{ $video->title }}"</strong> has been uploaded successfully!</p>
<p>Your video is now being processed and will be available shortly.</p>
<p>Check out your uploaded video:</p>
<div style="margin: 20px 0; text-align: center;">
@if ($video->thumbnail)
<a href="{{ url('/videos/' . $video->id) }}">
<img src="{{ asset('storage/thumbnails/' . $video->thumbnail) }}" alt="{{ $video->title }}"
style="max-width: 100%; height: auto; border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,0.3); display: block; margin: 0 auto;">
</a>
@else
<div
style="width: 100%; height: 200px; background: linear-gradient(45deg, #e61e1e, #ff4757); border-radius: 12px; display: flex; align-items: center; justify-content: center; margin: 0 auto; color: white; font-size: 18px; font-weight: bold; box-shadow: 0 8px 24px rgba(230,30,30,0.4);">
<i class="bi bi-play-circle-fill" style="font-size: 48px; margin-right: 16px;"></i>
{{ Str::limit($video->title, 30) }}
</div>
<p style="margin-top: 12px; color: #666; font-size: 14px;">Thumbnail generating...</p>
@endif
{{-- Thumbnail --}}
<div class="email-thumb-wrap">
@if($video->thumbnail)
<a href="{{ route('videos.show', $video) }}">
<img src="{{ asset('storage/thumbnails/' . $video->thumbnail) }}" alt="{{ $video->title }}">
</a>
@else
<div class="email-thumb-placeholder">
<span style="font-size:32px;">▶</span>
<span>{{ Str::limit($video->title, 40) }}</span>
</div>
@endif
</div>
<div style="background: #f0f0f0; padding: 16px; border-radius: 8px; margin: 20px 0;">
<h4 style="margin-top: 0; color: #333;">Video Details:</h4>
<ul style="margin: 0; padding-left: 20px;">
<li><strong>Title:</strong> {{ $video->title }}</li>
<li><strong>Size:</strong> {{ round($video->size / 1024 / 1024, 2) }} MB</li>
<li><strong>Orientation:</strong> {{ $video->orientation ?? 'Horizontal' }}</li>
</ul>
</div>
<p style="text-align: center;">
<a href="{{ url('/videos/' . $video->id) }}"
style="background: #e61e1e; color: white; padding: 12px 24px; text-decoration: none; border-radius: 25px; font-weight: 600; font-size: 16px; display: inline-block; box-shadow: 0 4px 12px rgba(230,30,30,0.4);">▶️
Watch Video</a>
</p>
{{-- Details box --}}
<div class="email-infobox">
<div class="email-infobox-label">Video Details</div>
<div class="email-inforow">
<span class="email-inforow-key">Title</span>
<span class="email-inforow-val">{{ $video->title }}</span>
</div>
<div class="footer">
<p>TAKEONE Video Platform</p>
@if($video->description)
<div class="email-inforow">
<span class="email-inforow-key">Description</span>
<span class="email-inforow-val">{{ Str::limit($video->description, 80) }}</span>
</div>
@endif
<div class="email-inforow">
<span class="email-inforow-key">File size</span>
<span class="email-inforow-val">{{ round($video->size / 1024 / 1024, 2) }} MB</span>
</div>
@if($video->formatted_duration)
<div class="email-inforow">
<span class="email-inforow-key">Duration</span>
<span class="email-inforow-val">{{ $video->formatted_duration }}</span>
</div>
@endif
<div class="email-inforow">
<span class="email-inforow-key">Type</span>
<span class="email-inforow-val" style="text-transform:capitalize;">{{ $video->type ?? 'Generic' }}</span>
</div>
<div class="email-inforow">
<span class="email-inforow-key">Visibility</span>
<span class="email-inforow-val" style="text-transform:capitalize;">{{ $video->visibility ?? 'Public' }}</span>
</div>
</div>
</body>
</html>
{{-- CTA --}}
<div class="email-btn-wrap">
<a href="{{ route('videos.show', $video) }}" class="email-btn">&#9654;&nbsp; Watch Video</a>
</div>
<hr class="email-divider">
<p class="email-note">
Questions? Reply to this email or visit
<a href="{{ config('app.url') }}">{{ config('app.url') }}</a>.
</p>
</x-emails.layout>