Skip to content

Commit

Permalink
Show "You" when assigned (#378)
Browse files Browse the repository at this point in the history
  • Loading branch information
mveytsman authored Jun 5, 2024
1 parent ef1df94 commit db6d414
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions lib/bike_brigade_web/live/campaign_signup_live/show.ex
Original file line number Diff line number Diff line change
Expand Up @@ -215,11 +215,15 @@ defmodule BikeBrigadeWeb.CampaignSignupLive.Show do

def signup_button(assigns) do
~H"""
<div>
<div class="flex flex-col space-y-2 md:items-center md:space-y-0 md:flex-row md:space-x-2">
<%= if @task.assigned_rider do %>
<span :if={@task.assigned_rider.id != @current_rider_id} class="mr-2">
<div :if={@task.assigned_rider.id != @current_rider_id}>
<%= split_first_name(@task.assigned_rider.name) %>
</span>
</div>
<div :if={@task.assigned_rider.id == @current_rider_id}>
You
</div>
<.button
:if={task_eligigle_for_unassign(@task, @campaign, @current_rider_id)}
Expand Down

0 comments on commit db6d414

Please sign in to comment.