@if ($thread->type == App\Thread::TYPE_NOTE) {!! __h(':person added a note', ['person' => ''.htmlspecialchars($thread->getCreatedBy()->getFullName(true)).'']) !!} @else @if ($thread->type == App\Thread::TYPE_MESSAGE) @php $action_color = config('app.colors')['text_user']; @endphp @else @php $action_color = config('app.colors')['text_customer']; @endphp @endif @if ($thread->isForwarded()) @php $trans_text = __(':person forwarded a conversation :forward_parent_conversation_number') @endphp @elseif ($loop->last) @php $trans_text = __(':person started the conversation') @endphp @else @php $trans_text = __(':person replied') @endphp @endif @php $trans_params = ['person' => ''.htmlspecialchars($thread->getCreatedBy()->getFullName(true)).'']; // Highlight sender when From is different from Reply-To. if ($thread->isCustomerMessage() && ($from_header = $thread->getFromIfDifferentFromReplyTo($customer ?? null)) ) { $trans_params['person'] .= ' <'.$from_header.'>'; } if ($thread->isForwarded()) { $trans_params['forward_parent_conversation_number'] = '#'.htmlspecialchars($thread->getMetaFw(App\Thread::META_FORWARD_PARENT_CONVERSATION_NUMBER)).''; } @endphp {!! __h($trans_text, $trans_params) !!} @endif