<div>
    <div class="container">
      <div class="  d-flex width-50 justify-content-center btn btn-sm bg-secondary text-center my-2 " >TECHNOPET Madagascar</div>
        <div class="d-flex justify-content-around ">
            <a href="{{route('mail')}}" class="btn btn-secondary" role="button">Mail</a>
            <a href="{{route('database')}}" class="btn btn-secondary" role="button">Database</a>
            
            
        </div>
        
    </div>
    {{-- <div class="  d-flex width-50 justify-content-center btn btn-sm bg-secondary text-center my-2 " >TECHNOPET Madagascar</div> --}}
    <hr>
    @if(session()->has('success'))
    <div class="alert alert-success " role = "alert">{{session()->get('success')}}</div>
    @endif
    {{-- <a href="" class="  d-flex width-50 justify-content-center btn btn-sm bg-info text-center my-2 " role="button">Add New account</a> --}}
    {{-- <button type="button" class="btn btn-primary" data-toggle="modal" data-target="#exampleModal1" data-whatever="@mdo" wire:model='Addmail'>Add New Account</button> --}}
    
    @if($updateMail)
    <div class="bg-secondary width-1px height-1px text-white text-center mx-25">Update Email</div>
      @include('livewire.tpm.mail.update')
    @endif
    
    {{-- <button class="btn btn-sm d-flex width-50 justify-content-center " wire:click='create()'>Add New Email</button> --}}
    <a href="#" wire:click='create()' class="  d-flex width-50 justify-content-center btn btn-sm bg-secondary text-white text-center my-2 " role="button">Add New Email</a>
    @if($createEmail)
    <div class="bg-secondary width-1px height-1px text-white text-center mx-25">New Email</div>
      @include('livewire.tpm.mail.create')
    @endif
    <div class="bg-secondary width-1px height-1px text-white text-center mx-25">Email-List</div>
    
    <div class="card my-4">
        <input class ="input" type="text" placeholder="Search" wire:model.debounce.800ms.live="search">
    </div>
    
    
    
        <table class="table table-striped table-hover ">
            <thead>
              <tr>
                
                <th >Compte</th>
                <th >Password</th>
                {{-- <th >Action</th> --}}
              </tr>
            </thead>
            <tbody>
                @foreach($mails as $mail)
              <tr>
                
                <td>{{$mail->mail}}</td>
                <td>{{$mail->pass}}</td>
                <td>
                    
                    <button wire:click="edit({{$mail->id}})" class = "btn btn-secondary btn-sm">Edit</button>
                    <button wire:click="delete({{$mail->id}})" class = "btn btn-danger btn-sm">Delete</button>
                    
                    
                  </td>
                @endforeach
                
              </tr>
              </tbody>
              </table>
              {{$mails->links('livewire.pagination')}}
</div>
