@extends('layouts.account') @section('title', __('Offers')) @section('heading', __('Offers')) @section('subheading', __('Negotiations you are part of, on either side.')) @section('account') @if ($negotiations->isEmpty()) {{ __('Browse properties') }} @else
@foreach ($negotiations as $negotiation) @php($yourTurn = $negotiation->awaitingReplyFrom($user))
{{ $negotiation->status->label() }} @if ($yourTurn) {{ __('Your turn') }} @endif

{{ $negotiation->listing?->title ?? __('A listing') }}

{{ $negotiation->isSeller($user) ? __('From :name', ['name' => $negotiation->buyer?->name]) : __('With :name', ['name' => $negotiation->seller?->name]) }}

{{ $negotiation->formattedLatest() }}

@if ($negotiation->listing?->price)

{{ __('Asking :price', ['price' => $negotiation->listing->formattedPrice()]) }}

@endif

{{ $negotiation->latest_offer_at?->diffForHumans() }}

@endforeach
{{ $negotiations->links() }}
@endif @endsection