Adds relative div to ensure that sorting arrow doesn't run away
This commit is contained in:
parent
82729085d2
commit
cca53ed154
1 changed files with 2 additions and 0 deletions
|
|
@ -40,12 +40,14 @@ defmodule PinchflatWeb.CustomComponents.TableComponents do
|
|||
phx-click={col[:sort_key] && "sort_update"}
|
||||
phx-value-sort_key={col[:sort_key]}
|
||||
>
|
||||
<div class="relative">
|
||||
{col[:label]}
|
||||
<.icon
|
||||
:if={to_string(@sort_key) == col[:sort_key]}
|
||||
name={if @sort_direction == :asc, do: "hero-chevron-up", else: "hero-chevron-down"}
|
||||
class="w-3 h-3 mt-2 ml-1 absolute"
|
||||
/>
|
||||
</div>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
|
|
|||
Loading…
Reference in a new issue