diff --git a/app/Http/Controllers/LogoController.php b/app/Http/Controllers/LogoController.php new file mode 100644 index 00000000..1a2a53d3 --- /dev/null +++ b/app/Http/Controllers/LogoController.php @@ -0,0 +1,16 @@ +make("logo"); + } +} diff --git a/environment/dev/app/nginx.conf b/environment/dev/app/nginx.conf index c52336f9..56249e3c 100644 --- a/environment/dev/app/nginx.conf +++ b/environment/dev/app/nginx.conf @@ -35,6 +35,7 @@ http { if (!-e $request_filename) { rewrite ^.*$ /index.php last; } + location ~ \.php$ { fastcgi_pass unix:/run/php-fpm.sock; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; diff --git a/lang/en/alt.php b/lang/en/alt.php index 685e8fad..038d6d56 100644 --- a/lang/en/alt.php +++ b/lang/en/alt.php @@ -37,4 +37,5 @@ "linkedin" => "LinkedIn icon", "facebook" => "Facebook icon", "youtube" => "YouTube icon", + "download" => "download icon", ]; diff --git a/lang/en/buttons.php b/lang/en/buttons.php index 269130d5..a680d5ee 100644 --- a/lang/en/buttons.php +++ b/lang/en/buttons.php @@ -19,4 +19,5 @@ "apply_now" => "Apply now!", "back_to_portfolio" => "Back to portfolio", "accept_all" => "Accept all", + "download" => "Download", ]; diff --git a/lang/en/content.php b/lang/en/content.php index 8f190d06..5ecc5b6d 100644 --- a/lang/en/content.php +++ b/lang/en/content.php @@ -360,4 +360,8 @@ "text_2" => "privacy policy.", ], "at" => "at", + "logo" => [ + "title_1" => "Download", + "title_2" => "materials", + ], ]; diff --git a/lang/en/materials.php b/lang/en/materials.php new file mode 100644 index 00000000..d5698c31 --- /dev/null +++ b/lang/en/materials.php @@ -0,0 +1,14 @@ + [ + "title" => "Brand book", + "description" => "Set of rules for the use of logos", + ], + "logo" => [ + "title" => "Logo", + "description" => "Logo in png, pdf, svg formats", + ], +]; diff --git a/lang/en/meta.php b/lang/en/meta.php index 0f088471..5f64424d 100644 --- a/lang/en/meta.php +++ b/lang/en/meta.php @@ -39,4 +39,8 @@ "title" => "Company data", "description" => "Company data of Blumilk Sp. z o.o.", ], + "logo" => [ + "title" => "Downloads", + "description" => "Downloads materials like logo or brand guide.", + ], ]; diff --git a/lang/pl/alt.php b/lang/pl/alt.php index 303b4aa1..b4c767c9 100644 --- a/lang/pl/alt.php +++ b/lang/pl/alt.php @@ -37,4 +37,5 @@ "linkedin" => "ikona LinkedIn", "facebook" => "ikona Facebook", "youtube" => "ikona YouTube", + "download" => "ikona pobierania", ]; diff --git a/lang/pl/buttons.php b/lang/pl/buttons.php index e3377ad5..0b2a2ac3 100644 --- a/lang/pl/buttons.php +++ b/lang/pl/buttons.php @@ -19,4 +19,5 @@ "apply_now" => "Aplikuj teraz!", "back_to_portfolio" => "Wróć do portfolio", "accept_all" => "Akceptuj wszystkie", + "download" => "Pobierz", ]; diff --git a/lang/pl/content.php b/lang/pl/content.php index 2963ae77..2834eb58 100644 --- a/lang/pl/content.php +++ b/lang/pl/content.php @@ -357,4 +357,8 @@ "text_2" => "politykę prywatności.", ], "at" => "w", + "logo" => [ + "title_1" => "Materiały", + "title_2" => "do pobrania", + ], ]; diff --git a/lang/pl/materials.php b/lang/pl/materials.php new file mode 100644 index 00000000..11883ca7 --- /dev/null +++ b/lang/pl/materials.php @@ -0,0 +1,14 @@ + [ + "title" => "Księga znaków", + "description" => "Zbiór zasad wykorzystania logotypu", + ], + "logo" => [ + "title" => "Logo", + "description" => "Logo w formatach png, pdf, svg", + ], +]; diff --git a/lang/pl/meta.php b/lang/pl/meta.php index 6da6cd41..fada9099 100644 --- a/lang/pl/meta.php +++ b/lang/pl/meta.php @@ -39,4 +39,8 @@ "title" => "Dane firmy", "description" => "Dane firmy Blumilk Sp. z o.o.", ], + "logo" => [ + "title" => "Materiały do pobrania", + "description" => "Materiały do pobrania takie jak logo czy księga znaków.", + ], ]; diff --git a/public/materials/brand_book.pdf b/public/materials/brand_book.pdf new file mode 100644 index 00000000..6d44453c Binary files /dev/null and b/public/materials/brand_book.pdf differ diff --git a/public/materials/logo.zip b/public/materials/logo.zip new file mode 100644 index 00000000..df33dc07 Binary files /dev/null and b/public/materials/logo.zip differ diff --git a/resources/views/components/small-primary-button.blade.php b/resources/views/components/small-primary-button.blade.php index bdd4705d..fc9624a9 100644 --- a/resources/views/components/small-primary-button.blade.php +++ b/resources/views/components/small-primary-button.blade.php @@ -1,5 +1,6 @@ +{{ $attributes->merge([ +'class' => "block shadow-sm text-base h-12 3xl:text-lg text-center transform transition hover:scale-110 rounded-lg bg-website-normal px-6 3xl:px-5 py-3 font-normal leading-7.5 text-white flex items-center justify-center" ]) }} +@isset($href) href="{{ $href }}" @endisset> {{$slot}} diff --git a/resources/views/logo.blade.php b/resources/views/logo.blade.php new file mode 100644 index 00000000..75bf3b37 --- /dev/null +++ b/resources/views/logo.blade.php @@ -0,0 +1,59 @@ +@extends("layout.public", ["excludeBigBubbles" => true]) + +@php + $filesDirectory = public_path("materials"); + $materials = []; + + if (file_exists($filesDirectory) && is_dir($filesDirectory)) { + foreach (scandir($filesDirectory) as $file) { + if (!in_array($file, [".", ".."])) { + $fileKey = pathinfo($file, PATHINFO_FILENAME); + $filePath = $filesDirectory . "/" . $file; + + $materials[] = [ + "title" => __("materials.{$fileKey}.title"), + "description" => __("materials.{$fileKey}.description"), + "file_type" => pathinfo($file, PATHINFO_EXTENSION), + "file_size" => number_format(filesize($filePath) / 1048576, 2) . " MB", + "download_url" => asset("materials/" . $file), + ]; + } + } + } +@endphp + +@section("title", __("meta.logo.title")) +@section("description", __("meta.logo.description")) + +@section("content") + + + + {{ __("content.logo.title_1") }} + {{ __("content.logo.title_2") }} + + + + @foreach($materials as $material) + + + + + + {{ $material["file_type"] }}, {{ $material["file_size"] }} + + + + {{ $material["title"] }} + {{ $material["description"] }} + + + + {{ __("buttons.download") }} + {{ __("alt.download") }} + + + + @endforeach + +@endsection diff --git a/routes/web.php b/routes/web.php index 405e2c3c..7bb1555e 100644 --- a/routes/web.php +++ b/routes/web.php @@ -7,6 +7,7 @@ use Blumilk\Website\Http\Controllers\CompanyDataController; use Blumilk\Website\Http\Controllers\ContactController; use Blumilk\Website\Http\Controllers\HomeController; +use Blumilk\Website\Http\Controllers\LogoController; use Blumilk\Website\Http\Controllers\NewsController; use Blumilk\Website\Http\Controllers\PolicyController; use Blumilk\Website\Http\Controllers\ProjectsController; @@ -28,6 +29,7 @@ $router->get($uri->translate("contact"), [ContactController::class, "index"])->name("contact"); $router->post($uri->translate("contact"), [ContactController::class, "store"])->name("contact.create"); $router->get($uri->translate("privacy-policy"), PolicyController::class)->name("privacy-policy"); +$router->get($uri->translate("logo"), LogoController::class)->name("logo"); $router->get($uri->translate("news"), [NewsController::class, "index"])->name("news"); $router->get($uri->translate("news/{slug}"), [NewsController::class, "get"])->name("news.entry");
{{ $material["description"] }}