<div id="btb-timeline-task-<?php echo $comment['id']; ?>" class="<?php echo $cc; ?> card <?php if ( ($cc + 1) != count($comments) ) : ?>mb-4<?php else : ?>mb-2<?php endif; ?>">
    <div class="card-header">
        <div class="d-flex justify-content-between">
            <div class="d-flex">
<?php
                if ( !file_exists(PATH_ASSETS.'/images/avatar/'.$comment['createdByName'].'.jpg')) :
                    $parts    = explode(' ', $comment['createdByName']);
                    $initials = substr($parts[0], 0, 1) . substr(end($parts), 0, 1);
?>
                    <div class="initial-avatar flex-shrink-0 me-2" alt="<?php echo $comment['createdByName']; ?>" title="<?php echo $comment['createdByName']; ?>"><?php echo $initials; ?></div>
<?php
                else :
?>
                    <img src="<?php echo URL_ASSETS; ?>/images/avatar/<?php echo $comment['createdByName']; ?>.jpg" alt="<?php echo $comment['createdByName']; ?>" title="<?php echo $comment['createdByName']; ?>" class="avatar-small">
<?php
                endif;
?>
                <div class="flex-1 align-self-center ms-2">
                    <p class="mb-0"><span class="fw-bold"><?php echo $comment['createdByName']; ?></span> updated a task</p>
                    <small class="text-muted"><?php echo time_elapsed_string($comment['createdAt']); ?> &#183; <?php echo $userProject['city']; ?>, <?php echo COMPANY_STATE_ABBR; ?></small>
                </div>
            </div>
        </div>
    </div>
    <div id="btb-post-body-<?php echo $comment['id']; ?>" class="card-body">
        <div class="d-flex align-items-center justify-content-between">
            <div class="d-block">
                <div><?php echo $comment['title']; ?></div>
                <span class="small text-muted"><?php echo $comment['category']; ?></span>
            </div>
<?php 
            switch ( $comment['status'] ) {
                case 'N/A' :
                    $class = "text-bg-secondary";
                    break;
                case 'Not Started' :
                    $class = "text-bg-danger";
                    break;
                case 'Negotiating' :
                    $class = "text-bg-primary";
                    break;
                case 'Scheduled' :
                    $class = "text-bg-info";
                    break;
                case 'In Progress' :
                    $class = "text-bg-warning";
                    break;
                case 'Completed' :
                    $class = "text-bg-success";
                    break;
            }
?>
            <span class="badge rounded-pill <?php echo $class; ?> text-end py-2"><?php echo $comment['status']; ?></span>
        </div>
    </div>
</div>