From 3ce2180325bb5dbc8f8c247ba4116546719d6209 Mon Sep 17 00:00:00 2001 From: ardhikaxx Date: Wed, 25 Feb 2026 10:38:01 +0700 Subject: [PATCH] refactor(ticket): simplify design seperti boarding pass Design Changes: - Remove complex animations dan gradients - Clean minimalist layout seperti tiket pesawat - Background gradient soft blue (#e0f2fe to #f0f9ff) - Header horizontal: brand kiri, info tiket kanan - Destination code besar 'WISATA' di tengah - QR code centered dengan label 'Scan untuk verifikasi' - Info grid 2 kolom: nama pemesan & harga - Footer simple dengan border dashed - Small decorative corners (18px) - Typography hierarchy jelas - Spacing konsisten dan breathable - No borders, no heavy shadows - Soft shadow untuk depth minimal - Color palette: teal (#0f766e) + slate (#64748b) - Font sizes: 32px brand, 48px destination, 18px info - Clean dan professional look --- resources/views/pdf/ticket.blade.php | 539 +++++++----------- .../views/user/tickets/download.blade.php | 421 ++++++-------- 2 files changed, 384 insertions(+), 576 deletions(-) diff --git a/resources/views/pdf/ticket.blade.php b/resources/views/pdf/ticket.blade.php index e3048bf..3a93c03 100644 --- a/resources/views/pdf/ticket.blade.php +++ b/resources/views/pdf/ticket.blade.php @@ -11,408 +11,289 @@ body { font-family: DejaVu Sans, sans-serif; - background: #f0fdfa; - padding: 20px; + background: #f0f9ff; + padding: 30px 20px; } .ticket-container { width: 100%; - max-width: 850px; + max-width: 600px; margin: 0 auto; - position: relative; } .ticket-box { - border: 5px solid #0f766e; + background: linear-gradient(135deg, #e0f2fe 0%, #f0f9ff 100%); border-radius: 24px; - overflow: hidden; - background: white; - box-shadow: 0 20px 60px rgba(15, 118, 110, 0.4); + padding: 40px 35px; + box-shadow: 0 20px 60px rgba(15, 118, 110, 0.15); position: relative; } - .ticket-background { - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; - opacity: 0.03; - z-index: 0; - } - - .ticket-content { - position: relative; - z-index: 1; - } - - /* Header dengan wave pattern */ - .header { - background: linear-gradient(135deg, #0d9488 0%, #0f766e 50%, #115e59 100%); - color: white; - text-align: center; - padding: 40px 30px 50px 30px; - position: relative; - overflow: hidden; - } - - .header::before { - content: ''; - position: absolute; - top: 0; - left: -50%; - width: 200%; - height: 100%; - background: radial-gradient(circle at 30% 50%, rgba(20, 184, 166, 0.3) 0%, transparent 50%); - animation: wave 15s ease-in-out infinite; - } - - .header::after { - content: ''; - position: absolute; - bottom: -2px; - left: 0; - width: 100%; - height: 40px; - background: white; - border-radius: 50% 50% 0 0 / 100% 100% 0 0; - } - - @keyframes wave { - 0%, 100% { transform: translateX(0) translateY(0); } - 50% { transform: translateX(10%) translateY(-5%); } - } - - .header-content { - position: relative; - z-index: 1; - } - - .header-icon { - width: 60px; - height: 60px; - background: rgba(255, 255, 255, 0.2); - border-radius: 50%; - display: inline-flex; - align-items: center; - justify-content: center; - margin-bottom: 15px; - border: 3px solid rgba(255, 255, 255, 0.3); - } - - .header-icon-inner { - width: 35px; - height: 35px; - background: white; - border-radius: 50%; - } - - .header h1 { - font-size: 48px; - font-weight: 900; - margin: 0 0 12px 0; - letter-spacing: 6px; - text-shadow: 4px 4px 8px rgba(0,0,0,0.4); - color: #ffffff; - text-transform: uppercase; - } - - .header p { - font-size: 18px; - margin: 0; - font-weight: 600; - color: #ccfbf1; - letter-spacing: 2px; - text-shadow: 2px 2px 4px rgba(0,0,0,0.3); - } - - .ticket-body { - padding: 40px 35px 35px 35px; - } - - /* QR Section dengan layout horizontal */ - .qr-section { + /* Header Section */ + .ticket-header { display: table; width: 100%; - margin: 0 0 35px 0; - padding: 30px; - background: linear-gradient(135deg, #f0fdfa 0%, #e6fffa 100%); - border-radius: 20px; - border: 4px dashed #14b8a6; - position: relative; - } - - .qr-section::before { - content: ''; - position: absolute; - top: -4px; - left: -4px; - right: -4px; - bottom: -4px; - background: linear-gradient(135deg, #14b8a6 0%, #0f766e 100%); - border-radius: 20px; - z-index: -1; - opacity: 0.08; - } - - .qr-left { - display: table-cell; - width: 50%; - vertical-align: middle; - text-align: center; - padding-right: 20px; - } - - .qr-right { - display: table-cell; - width: 50%; - vertical-align: middle; - text-align: center; - padding-left: 20px; - border-left: 3px solid #14b8a6; - } - - .qr-code-wrapper { - background: white; - padding: 20px; - border-radius: 16px; - display: inline-block; - box-shadow: 0 8px 25px rgba(15, 118, 110, 0.3); - border: 4px solid #0f766e; - } - - .qr-label { - font-size: 13px; - color: #0f766e; - font-weight: 700; - margin-bottom: 10px; - text-transform: uppercase; - letter-spacing: 1px; - } - - .ticket-code { - font-size: 32px; - font-weight: 900; - letter-spacing: 5px; - color: #0f766e; - padding: 15px 25px; - background: white; - border-radius: 12px; - display: inline-block; - border: 3px solid #14b8a6; - box-shadow: 0 6px 20px rgba(15, 118, 110, 0.2); - margin-top: 10px; - } - - .divider { - height: 4px; - background: linear-gradient(90deg, transparent 0%, #14b8a6 20%, #0f766e 50%, #14b8a6 80%, transparent 100%); - margin: 30px 0; - border-radius: 2px; - } - - .info-section { - background: linear-gradient(135deg, #f0fdfa 0%, #ffffff 100%); - border-radius: 20px; - padding: 30px; margin-bottom: 30px; - border: 3px solid #ccfbf1; - box-shadow: 0 4px 15px rgba(15, 118, 110, 0.08); } - .info-row { - display: table; - width: 100%; - margin: 18px 0; - padding: 15px 0; - border-bottom: 3px solid #e0f2fe; - } - - .info-row:last-child { - border-bottom: none; - margin-bottom: 0; - } - - .info-label { + .header-left { display: table-cell; - width: 45%; - font-size: 15px; - color: #0f766e; - font-weight: 800; - text-transform: uppercase; - letter-spacing: 0.5px; + width: 60%; + vertical-align: middle; } - .info-value { + .header-right { display: table-cell; - width: 55%; - font-size: 16px; - color: #111827; - font-weight: 700; + width: 40%; + vertical-align: middle; text-align: right; } - .price-highlight { - color: #0f766e; - font-size: 20px; - background: #ccfbf1; - padding: 8px 16px; - border-radius: 10px; + .brand-name { + font-size: 32px; font-weight: 900; - border: 2px solid #14b8a6; + color: #0f766e; + letter-spacing: 2px; + margin-bottom: 5px; } + .brand-subtitle { + font-size: 13px; + color: #0f766e; + font-weight: 600; + letter-spacing: 0.5px; + } + + .ticket-type { + font-size: 11px; + color: #64748b; + font-weight: 700; + text-transform: uppercase; + letter-spacing: 1px; + margin-bottom: 3px; + } + + .ticket-name { + font-size: 16px; + color: #0f766e; + font-weight: 800; + } + + /* Destination Section */ + .destination-section { + text-align: center; + margin-bottom: 35px; + } + + .destination-code { + font-size: 48px; + font-weight: 900; + color: #0f766e; + letter-spacing: 8px; + margin-bottom: 8px; + } + + .destination-detail { + font-size: 14px; + color: #64748b; + font-weight: 600; + } + + /* QR Section */ + .qr-section { + text-align: center; + margin-bottom: 35px; + padding: 25px; + background: white; + border-radius: 16px; + box-shadow: 0 4px 15px rgba(15, 118, 110, 0.1); + } + + .qr-label { + font-size: 10px; + color: #64748b; + font-weight: 700; + text-transform: uppercase; + letter-spacing: 1px; + margin-bottom: 15px; + } + + .qr-code-wrapper { + display: inline-block; + padding: 15px; + background: white; + border: 3px solid #e0f2fe; + border-radius: 12px; + } + + .ticket-code-text { + font-size: 16px; + font-weight: 700; + color: #64748b; + letter-spacing: 3px; + margin-top: 15px; + } + + /* Info Grid */ + .info-grid { + display: table; + width: 100%; + margin-bottom: 20px; + } + + .info-row { + display: table-row; + } + + .info-cell { + display: table-cell; + padding: 18px 0; + border-bottom: 2px solid #e0f2fe; + } + + .info-cell:first-child { + width: 50%; + padding-right: 15px; + } + + .info-cell:last-child { + width: 50%; + padding-left: 15px; + text-align: right; + } + + .info-label { + font-size: 11px; + color: #64748b; + font-weight: 700; + text-transform: uppercase; + letter-spacing: 1px; + margin-bottom: 5px; + display: block; + } + + .info-value { + font-size: 18px; + color: #0f766e; + font-weight: 800; + } + + .info-value-large { + font-size: 22px; + color: #0f766e; + font-weight: 900; + } + + /* Footer Note */ .footer-note { text-align: center; - color: #0f766e; - font-size: 13px; - margin-top: 30px; - padding: 22px; - background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%); - border-radius: 16px; - border: 4px solid #fbbf24; - font-weight: 600; + font-size: 11px; + color: #64748b; line-height: 1.6; + margin-top: 25px; + padding-top: 20px; + border-top: 2px dashed #cbd5e1; } .footer-note strong { - color: #92400e; - display: block; - margin-bottom: 10px; - font-size: 15px; - font-weight: 900; - text-transform: uppercase; - letter-spacing: 1px; - } - - .watermark { - position: fixed; - opacity: 0.015; - font-size: 120px; - top: 50%; - left: 50%; - transform: translate(-50%, -50%) rotate(-45deg); - font-weight: 900; color: #0f766e; - z-index: 0; - letter-spacing: 15px; + font-weight: 800; } + /* Decorative Elements */ .ticket-corner { position: absolute; - width: 50px; - height: 50px; - border: 5px solid #14b8a6; + width: 20px; + height: 20px; + border: 3px solid #0f766e; } .corner-tl { - top: -5px; - left: -5px; + top: 15px; + left: 15px; border-right: none; border-bottom: none; - border-radius: 24px 0 0 0; } .corner-tr { - top: -5px; - right: -5px; + top: 15px; + right: 15px; border-left: none; border-bottom: none; - border-radius: 0 24px 0 0; } .corner-bl { - bottom: -5px; - left: -5px; + bottom: 15px; + left: 15px; border-right: none; border-top: none; - border-radius: 0 0 0 24px; } .corner-br { - bottom: -5px; - right: -5px; + bottom: 15px; + right: 15px; border-left: none; border-top: none; - border-radius: 0 0 24px 0; } -
BANYU BIRU NGANJUK
-
- - @if(file_exists(public_path('images/background.jpg'))) - Background - @endif -
-
- -
-
-
-
-
-

BANYU BIRU

-

Pemandian Air Panas Nganjuk

-
-
- - -
- -
-
-
Scan QR Code
-
- @if(file_exists(public_path($item->qr_code_path))) - QR Code - @endif -
-
-
-
Kode Tiket
-
{{ $item->ticket_code }}
-
-
- -
- - -
-
- Nama Pemesan - {{ $order->user->name }} -
-
- Jenis Tiket - {{ $item->ticket->name }} -
-
- Tanggal Kunjungan - {{ \Carbon\Carbon::parse($order->visit_date)->isoFormat('dddd, D MMMM Y') }} -
-
- Harga Tiket - Rp {{ number_format($item->price, 0, ',', '.') }} -
-
- - -
diff --git a/resources/views/user/tickets/download.blade.php b/resources/views/user/tickets/download.blade.php index 16d1edd..2e2aa32 100644 --- a/resources/views/user/tickets/download.blade.php +++ b/resources/views/user/tickets/download.blade.php @@ -5,272 +5,195 @@ @push('styles') @endpush @@ -312,52 +235,56 @@
-
-
-
-
-
BANYU BIRU
- Pemandian Air Panas Nganjuk +
+
BANYU BIRU
+
Pemandian Air Panas Nganjuk
+
+
+
Tiket
+
{{ $item->ticket->name }}
- + +
+
WISATA
+
{{ $order->visit_date->format('d F Y') }}
+
+ +
-
-
Scan QR Code
-
- @if(file_exists(public_path($item->qr_code_path))) - QR Code - @else -
- -
- @endif -
-
-
-
Kode Tiket
-
{{ $item->ticket_code }}
+
Scan untuk verifikasi
+
+ @if(file_exists(public_path($item->qr_code_path))) + QR Code + @else +
+ +
+ @endif
+
{{ $item->ticket_code }}
-
- - +
- Jenis Tiket - {{ $item->ticket->name }} -
-
- Tanggal Kunjungan - {{ $order->visit_date->format('d M Y') }} -
-
- Harga - Rp {{ number_format($item->price, 0, ',', '.') }} +
+ Nama Pemesan +
{{ $order->user->name }}
+
+
+ Harga +
Rp {{ number_format($item->price, 0, ',', '.') }}
+
+ + +