Change import menu icon depending on destination
Star = wishlist, plus = collection
This commit is contained in:
@@ -32,7 +32,11 @@ defmodule MusicLibraryWeb.RecordLive.ImportComponent do
|
||||
role="list"
|
||||
class="divide-y divide-zinc-100 dark:divide-slate-300/30 mt-5"
|
||||
>
|
||||
<.result :for={release_group <- @release_groups} release_group={release_group} />
|
||||
<.result
|
||||
:for={release_group <- @release_groups}
|
||||
release_group={release_group}
|
||||
icon_name={@icon_name}
|
||||
/>
|
||||
</ul>
|
||||
<div
|
||||
:if={@release_groups == []}
|
||||
@@ -73,8 +77,8 @@ defmodule MusicLibraryWeb.RecordLive.ImportComponent do
|
||||
phx-click={toggle_actions_menu(@release_group.id)}
|
||||
phx-click-away={close_actions_menu(@release_group.id)}
|
||||
>
|
||||
<span class="sr-only"><%= gettext("Open options") %></span>
|
||||
<.icon name="hero-plus" class="-mt-1 h-5 w-5" aria-hidden="true" data-slot="icon" />
|
||||
<span class="sr-only"><%= gettext("Choose which format to import") %></span>
|
||||
<.icon name={@icon_name} class="-mt-1 h-5 w-5" aria-hidden="true" data-slot="icon" />
|
||||
</button>
|
||||
<!--
|
||||
Dropdown menu, show/hide based on menu state.
|
||||
|
||||
@@ -191,6 +191,7 @@
|
||||
record={@record}
|
||||
patch={back_path(@record_list_params)}
|
||||
initial_query=""
|
||||
icon_name="hero-plus"
|
||||
/>
|
||||
</.modal>
|
||||
|
||||
|
||||
@@ -110,7 +110,7 @@
|
||||
phx-click-away={close_actions_menu(track.scrobbled_at_uts)}
|
||||
>
|
||||
<span class="sr-only"><%= gettext("Open options") %></span>
|
||||
<.icon name="hero-plus" class="-mt-1 h-5 w-5" aria-hidden="true" data-slot="icon" />
|
||||
<.icon name="hero-star" class="-mt-1 h-5 w-5" aria-hidden="true" data-slot="icon" />
|
||||
</button>
|
||||
<!--
|
||||
Dropdown menu, show/hide based on menu state.
|
||||
|
||||
@@ -201,6 +201,7 @@
|
||||
record={@record}
|
||||
patch={back_path(@record_list_params)}
|
||||
initial_query=""
|
||||
icon_name="hero-star"
|
||||
/>
|
||||
</.modal>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user