<style>
    .text-bg-danger {
    color: white !important;
    background-color: RGBA(210, 109, 105, var(--bs-bg-opacity, 1)) !important;
}
</style>


<?php if(Laravel\Jetstream\Jetstream::hasTeamFeatures()): ?>
    <div class="app-utility-item app-user-dropdown dropdown">
        
        <?php if(Auth::user()->currentTeam?->id): ?>
        <a class="dropdown-toggle" id="user-dropdown-toggle" data-bs-toggle="dropdown" href="#" role="button"
        aria-expanded="false"><?php echo e(Auth::user()->currentTeam?->name); ?></a>
        <?php else: ?>  
        <a class="dropdown-toggle" id="user-dropdown-toggle" data-bs-toggle="dropdown" href="#" role="button"
        aria-expanded="false">Sin equipo</a>
        <?php endif; ?>



        <ul class="dropdown-menu" aria-labelledby="user-dropdown-toggle">
            <!--<li><a class="dropdown-item" href="<?php echo e(route('profile.show')); ?>">Perfil</a></li>-->
            <?php if(Auth::user()->currentTeam?->id): ?>
            <li><a class="dropdown-item" href="<?php echo e(route('teamMe', Auth::user()->currentTeam?->id)); ?>">Equipo</a>
            </li>
            <?php endif; ?>

            <?php if (app(\Illuminate\Contracts\Auth\Access\Gate::class)->check('create', Laravel\Jetstream\Jetstream::newTeamModel())): ?>
                <li><a class="dropdown-item" href="<?php echo e(route('teams.create')); ?>">Nuevo equipo</a></li>
            <?php endif; ?>
            <li><a class="dropdown-item" href="<?php echo e(route('invitations')); ?>">Mis solicitudes  
             <span class="badge text-bg-danger" ><?php echo e(Help::countTeamInvitations()); ?></span>     </a></li>

            <?php if(count(Auth::user()->allTeams())>0): ?>
                <li>
                    <hr class="dropdown-divider">
                </li>
                <?php $__currentLoopData = Auth::user()->allTeams(); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $team): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                <?php if (isset($component)) { $__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4 = $component; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'jetstream::components.switchable-team','data' => ['team' => $team]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
<?php $component->withName('jet-switchable-team'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
<?php endif; ?>
<?php $component->withAttributes(['team' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($team)]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4)): ?>
<?php $component = $__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4; ?>
<?php unset($__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4); ?>
<?php endif; ?>
                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
            <?php endif; ?>

           

          

        </ul>
    </div>
<?php endif; ?>
<?php /**PATH C:\laragon\www\sistema-contable-laravel\resources\views/layouts/components/teams.blade.php ENDPATH**/ ?>