@php $floatingButton = collect($floatingButton)->pluck('value', 'key'); $title = $floatingButton->get('title'); $bgColor = $floatingButton->get('background_color'); $bgColor = $bgColor === 'transparent' ? 'var(--primary-color)' : $bgColor; $enableRingAnimation = $floatingButton->get('enable_ring_animation'); $marginBetween = setting('fob-floating-buttons.margin_between', 0); $url = $floatingButton->get('url'); switch ($floatingButton->get('type')) { case 'phone': $url = 'tel:' . $url; break; case 'email': $url = 'mailto:' . $url; break; case 'whatsapp': $url = 'https://wa.me/' . $url; break; } @endphp
  • $bgColor, "margin: {$marginBetween}px 0" => $marginBetween]) > get('open_in_the_new_tab')) target="_blank" @endif class="ring-animation"> @if ($icon = ($floatingButton->get('icon_image') ?: $floatingButton->get('icon')))
    @if($enableRingAnimation)
    @endif @if ($floatingButton->get('icon_image')) {{ RvMedia::image($icon, $title, attributes: ['class' => 'sb-icon']) }} @else @endif
    @endif
    {{ $title }}