Refactor ship status to be enum instead of string.
This commit is contained in:
@@ -12,36 +12,37 @@
|
||||
</h1>
|
||||
|
||||
<div class="space-y-5">
|
||||
<!-- start ship item -->
|
||||
|
||||
{% for ship in ships %}
|
||||
<div class="bg-[#16202A] rounded-2xl pl-5 py-5 pr-11 flex flex-col min-[1174px]:flex-row min-[1174px]:justify-between">
|
||||
<div class="flex justify-center min-[1174px]:justify-start">
|
||||
<img class="h-[83px] w-[84px]" src="/images/status-in-progress.png" alt="Status: in progress">
|
||||
<img class="h-[83px] w-[84px]" src="/images/status-in-progress.png" alt="Status: {{ ship.status.value }}">
|
||||
<div class="ml-5">
|
||||
<div class="rounded-2xl py-1 px-3 flex justify-center w-32 items-center bg-amber-400/10">
|
||||
<div class="rounded-full h-2 w-2 bg-amber-400 blur-[1px] mr-2"></div>
|
||||
<p class="uppercase text-xs text-nowrap">in progress</p>
|
||||
<p class="uppercase text-xs text-nowrap">{{ ship.status.value }}</p>
|
||||
</div>
|
||||
<h4 class="text-[22px] pt-1 font-semibold">
|
||||
<a
|
||||
class="hover:text-slate-200"
|
||||
href="#"
|
||||
>USS LeafyCruiser</a>
|
||||
href="{{ path('app_starship_show', {id: ship.id}) }}"
|
||||
>{{ ship.name }}</a>
|
||||
</h4>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex justify-center min-[1174px]:justify-start mt-2 min-[1174px]:mt-0 shrink-0">
|
||||
<div class="border-r border-white/20 pr-8">
|
||||
<p class="text-slate-400 text-xs">Captain</p>
|
||||
<p class="text-xl">Jean-Luc Pickles</p>
|
||||
<p class="text-xl">{{ ship.captain }}</p>
|
||||
</div>
|
||||
|
||||
<div class="pl-8 w-[100px]">
|
||||
<p class="text-slate-400 text-xs">Class</p>
|
||||
<p class="text-xl">Garden</p>
|
||||
<p class="text-xl">{{ ship.class }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- end ship item -->
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
<p class="text-lg mt-5 text-center md:text-left">
|
||||
|
||||
Reference in New Issue
Block a user