<%= @title %>

<%= for tag <- @container.tags do %> <.link href="#" class="mx-2 my-1 px-4 py-2 rounded-lg title text-xl" style={"color: #{tag.text_color}; background-color: #{tag.bg_color}"} phx-click="delete" phx-value-tag-id={tag.id} phx-target={@myself} data-confirm={ dgettext( "prompts", "Are you sure you want to remove the %{tag_name} tag from %{container_name}?", tag_name: tag.name, container_name: @container.name ) } > <%= tag.name %> <% end %> <%= if @container.tags |> Enum.empty?() do %>

<%= gettext("No tags") %> <%= display_emoji("😔") %>

<% end %>
<%= unless tag_options(@tags, @container) |> Enum.empty?() do %>
<.form :let={f} for={:tag} id="add-tag-to-container-form" class="flex flex-col space-y-4 sm:space-y-0 sm:grid sm:grid-cols-3 sm:gap-4 justify-center items-center" phx-target={@myself} phx-submit="save" > <%= select(f, :tag_id, tag_options(@tags, @container), class: "text-center col-span-2 input input-primary" ) %> <%= error_tag(f, :tag_id, "col-span-3 text-center") %> <%= submit(dgettext("actions", "Add"), class: "mx-auto btn btn-primary", phx_disable_with: dgettext("prompts", "Adding...") ) %> <% end %>