rename ammo groups to packs everywhere

This commit is contained in:
2023-03-29 23:49:45 -04:00
parent 0544b58ab6
commit 4b6d0952f8
35 changed files with 160 additions and 168 deletions

View File

@ -203,9 +203,7 @@
navigate={Routes.pack_show_path(Endpoint, :show, pack)}
class="text-primary-600 link"
aria-label={
dgettext("actions", "View ammo group of %{pack_count} bullets",
pack_count: pack_count
)
dgettext("actions", "View pack of %{pack_count} bullets", pack_count: pack_count)
}
>
<i class="fa-fw fa-lg fas fa-eye"></i>

View File

@ -4,7 +4,7 @@ defmodule CanneryWeb.PackLive.FormComponent do
"""
use CanneryWeb, :live_component
alias Cannery.Ammo.{Pack, AmmoType}
alias Cannery.Ammo.{AmmoType, Pack}
alias Cannery.{Accounts.User, Ammo, Containers, Containers.Container}
alias Ecto.Changeset
alias Phoenix.LiveView.Socket

View File

@ -148,7 +148,7 @@ defmodule CanneryWeb.PackLive.Index do
}
} = socket
) do
# get total number of ammo groups to determine whether to display onboarding
# get total number of packs to determine whether to display onboarding
# prompts
packs_count = Ammo.get_packs_count!(current_user, true)
packs = Ammo.list_packs(search, class, current_user, show_used)

View File

@ -151,9 +151,7 @@
navigate={Routes.pack_show_path(Endpoint, :show, pack)}
class="text-primary-600 link"
aria-label={
dgettext("actions", "View ammo group of %{pack_count} bullets",
pack_count: pack_count
)
dgettext("actions", "View pack of %{pack_count} bullets", pack_count: pack_count)
}
>
<i class="fa-fw fa-lg fas fa-eye"></i>
@ -163,9 +161,7 @@
patch={Routes.pack_index_path(Endpoint, :edit, pack)}
class="text-primary-600 link"
aria-label={
dgettext("actions", "Edit ammo group of %{pack_count} bullets",
pack_count: pack_count
)
dgettext("actions", "Edit pack of %{pack_count} bullets", pack_count: pack_count)
}
>
<i class="fa-fw fa-lg fas fa-edit"></i>
@ -175,7 +171,7 @@
patch={Routes.pack_index_path(Endpoint, :clone, pack)}
class="text-primary-600 link"
aria-label={
dgettext("actions", "Clone ammo group of %{pack_count} bullets",
dgettext("actions", "Clone pack of %{pack_count} bullets",
pack_count: pack_count
)
}
@ -190,7 +186,7 @@
phx-value-id={pack.id}
data-confirm={dgettext("prompts", "Are you sure you want to delete this ammo?")}
aria-label={
dgettext("actions", "Delete ammo group of %{pack_count} bullets",
dgettext("actions", "Delete pack of %{pack_count} bullets",
pack_count: pack_count
)
}

View File

@ -59,7 +59,7 @@
patch={Routes.pack_show_path(Endpoint, :edit, @pack)}
class="mx-4 my-2 text-primary-600 link"
aria-label={
dgettext("actions", "Edit ammo group of %{pack_count} bullets", pack_count: @pack.count)
dgettext("actions", "Edit pack of %{pack_count} bullets", pack_count: @pack.count)
}
>
<i class="fa-fw fa-lg fas fa-edit"></i>
@ -71,9 +71,7 @@
phx-click="delete"
data-confirm={dgettext("prompts", "Are you sure you want to delete this ammo?")}
aria-label={
dgettext("actions", "Delete ammo group of %{pack_count} bullets",
pack_count: @pack.count
)
dgettext("actions", "Delete pack of %{pack_count} bullets", pack_count: @pack.count)
}
>
<i class="fa-fw fa-lg fas fa-trash"></i>