WowPress-Tailwind/theme/template-parts/widgets/boss_kills.php

32 lines
961 B
PHP
Raw Permalink Normal View History

2024-04-23 22:43:54 +02:00
<?php
2024-08-05 20:19:44 +02:00
if(!empty($instance['raid_name'])){
$raid_name = $instance['raid_name'];
}else{
$raid_name = "";
}
2024-04-23 22:43:54 +02:00
?>
<div class="bg-glass shadow p-auto order-last flex flex-col gap-2">
<h3 class="text-xl font-bold text-center"><?= $this->title ?></h3>
2024-08-05 20:19:44 +02:00
<h4 class="text-lg font-bold text-center"><?= $raid_name ?></h4>
2024-04-27 21:21:33 +02:00
<div class="relative pt-1">
<div class="overflow-hidden h-2 mb-4 text-xs flex bg-slate-200">
<div style="width:<?=$this->getCompletePercent($instance)?>%" class="shadow-none flex flex-col text-center whitespace-nowrap text-white justify-center bg-alliance"></div>
</div>
</div>
2024-04-23 22:43:54 +02:00
<?php
2024-04-27 21:21:33 +02:00
foreach ($this->getBossList($instance) as $boss) {
2024-04-23 22:43:54 +02:00
?>
2024-04-27 21:21:33 +02:00
<div class="flex flex-row gap-2">
<div><?= $boss['name'] ?></div>
<div class="w-full text-end"><?= $boss['date'] ? format_date($boss['date']) : "Nicht besiegt" ?></div>
</div>
2024-04-23 22:43:54 +02:00
<?php
}
?>
</div>