- Hinweisleiste per B2IN_ANNOUNCEMENT_BAR ausgeblendet (Standard aus) - Hero: „Räume aus einer Hand.“ als neue Überschrift, zweiter Button entfernt - Projekttext mit zentralem deutschen Vertragspartner (Punkt statt Gedankenstrich) - Otterpohl als vierte Kernmarke: Text v2, Abschnitt „Montage“, Titelbild getauscht - Markenabschnitte: Absätze mit „- “ als Liste mit fetter Einleitung - Titelbilder und Galerien für CABINET, Rotpunkt, Febrü und Otterpohl (WebP) - Feedback 17.09. in den Markentexten, Demobilder entfernt, WhatsApp-Nummer - Palette „Modern“ fest ohne Schalter, Entwurf /entwurf mit Hero-Slideshow - Seeder-Liste fürs Deployment im Entwicklungsplan Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
69 lines
2.4 KiB
PHP
69 lines
2.4 KiB
PHP
<?php
|
|
|
|
namespace App\Livewire\Web\Components\Ui;
|
|
|
|
use Livewire\Component;
|
|
|
|
class Footer extends Component
|
|
{
|
|
/** @var array<string, mixed> */
|
|
public array $content = [];
|
|
|
|
/** Farbwelt der Seite (`interior` | `immobilien`), in mount() festgehalten. */
|
|
public string $world = 'interior';
|
|
|
|
/** @var array<string, array{label: string, url: string, active: bool}> */
|
|
public array $worlds = [];
|
|
|
|
public string $logoPath = '';
|
|
|
|
/**
|
|
* Negatives Logo für die Farbvariante „Modern“ (Nachtrag 18): dort liegt der Interior-Footer
|
|
* dunkel in Tanne. Die Palette schaltet im Browser, deshalb liegen beide Logos im Markup und
|
|
* das Stylesheet blendet das passende ein. Leer in der Immobilien-Welt, die ohnehin das
|
|
* negative Logo trägt.
|
|
*/
|
|
public string $logoPathDark = '';
|
|
|
|
/**
|
|
* Fuer die Immobilien-Welt zeigen die gemeinsamen Footer-Links auf die Seiten dieser Welt.
|
|
*
|
|
* @var array<string, string>
|
|
*/
|
|
private const IMMOBILIEN_LINKS = [
|
|
'/faq' => '/immobilien/faq',
|
|
'/about' => '/immobilien/ueber-b2in',
|
|
'/magazin' => '/immobilien/magazin',
|
|
];
|
|
|
|
public function mount(): void
|
|
{
|
|
$section = cms_theme_section('footer');
|
|
$this->content = is_array($section) ? $section : [];
|
|
$this->world = b2in_world();
|
|
|
|
if ($this->world === 'immobilien' && is_array($this->content['links'] ?? null)) {
|
|
$this->content['links'] = array_map(function ($link) {
|
|
if (is_array($link) && isset(self::IMMOBILIEN_LINKS[$link['url'] ?? ''])) {
|
|
$link['url'] = self::IMMOBILIEN_LINKS[$link['url']];
|
|
}
|
|
|
|
return $link;
|
|
}, $this->content['links']);
|
|
}
|
|
$this->worlds = b2in_worlds($this->world);
|
|
|
|
// Der Interior-Footer liegt auf Sand (helle Fläche) und trägt deshalb das positive
|
|
// Logo; der Immobilien-Footer bleibt dunkel und nutzt die negative Variante.
|
|
$variant = $this->world === 'immobilien' ? 'negative' : 'positive';
|
|
$this->logoPath = \App\Helpers\ThemeHelper::getLogoPath($variant, $this->world);
|
|
$this->logoPathDark = $this->world === 'immobilien'
|
|
? ''
|
|
: \App\Helpers\ThemeHelper::getLogoPath('negative', $this->world);
|
|
}
|
|
|
|
public function render()
|
|
{
|
|
return view('livewire.web.components.ui.footer');
|
|
}
|
|
}
|