@props(['events' => []])
@php $displayedCategories = []; $currentPath = request()->path(); $segments = explode('/', $currentPath); $slug = end($segments); $ubicacion = empty($slug) ? env('APP_PAIS') : $slug; @endphp @foreach ($events['highlightCategories']['categories'] as $event) {{-- @dd($events['highlightCategories']['categories'][1]['products'][0]) --}} @if (count($event['products']) > 0) {{-- @dd($event['products'][0]['active']) --}} {{-- @if ($event['products'][0]['active'] == true) --}} {{ $event['name'] }} {{-- @endif --}} @endif @endforeach
{{-- x-data="{ isDragging: false, startX: 0, scrollLeft: 0, handleMouseDown(e) { if (e.target.tagName === 'IMG') { e.preventDefault(); return; } this.isDragging = true; this.startX = e.pageX - this.$el.offsetLeft; this.scrollLeft = this.$el.scrollLeft; } }" x-on:mousedown="handleMouseDown" x-on:mouseleave="isDragging = false" x-on:mouseup="isDragging = false" x-on:mousemove="if (isDragging) { $event.preventDefault(); const x = $event.pageX - $el.offsetLeft; const walk = (x - startX); $el.scrollLeft = scrollLeft - walk; }" --}}