From 86402ef9261d557f30a6ffdc8fbf361a84026c46 Mon Sep 17 00:00:00 2001 From: Andras Bacsai <5845193+andrasbacsai@users.noreply.github.com> Date: Mon, 28 Sep 2026 15:39:00 +0200 Subject: [PATCH] fix(ui): clean up the server rows of multi-server applications - Show the status summary next to the server name on the primary and additional server rows. - Move Deploy, Make primary, Stop and Remove into one Actions dropdown per server row. Co-Authored-By: Claude Opus 5.5 --- .../project/shared/destination.blade.php | 148 +++++++++++------- 1 file changed, 94 insertions(+), 54 deletions(-) diff --git a/resources/views/livewire/project/shared/destination.blade.php b/resources/views/livewire/project/shared/destination.blade.php index 6af96038fb..70a5bf5bb1 100644 --- a/resources/views/livewire/project/shared/destination.blade.php +++ b/resources/views/livewire/project/shared/destination.blade.php @@ -23,6 +23,7 @@ class="rounded-sm bg-coollabs/10 px-1.5 py-0.5 text-[11px] font-medium text-coollabs dark:bg-warning/10 dark:text-warning"> Primary +

Network @@ -36,18 +37,35 @@ Open server - @if ($hasAdditionalDestinations) - - Deploy - - @if (str($resource->status)->startsWith('running')) - - Stop - - @endif + @can('deploy', $resource) +

+ + +
+ @endcan @endif @@ -60,13 +78,6 @@ @foreach ($additionalDestinations as $destination) @php $destinationStatus = str(data_get($destination, 'pivot.status')); - $destinationStatusType = match (true) { - $destinationStatus->startsWith('running') => 'success', - $destinationStatus->startsWith('exited') => 'error', - $destinationStatus->startsWith(['starting', 'restarting']) => 'warning', - default => 'neutral', - }; - $destinationStatusLabel = $destinationStatus->before(':')->headline()->value() ?: 'Unknown'; @endphp
@@ -76,9 +87,12 @@
-

- {{ data_get($destination, 'server.name') }} -

+
+

+ {{ data_get($destination, 'server.name') }} +

+ +

Network @@ -91,39 +105,65 @@

Open server - @if ($destinationStatus->startsWith('running')) - - @elseif ($destinationStatus->startsWith(['starting', 'restarting'])) - - @elseif ($destinationStatus->startsWith('exited')) - - @else - - @endif - - Deploy - - - Make primary - - @if ($destinationStatus->startsWith('running')) - - Stop - - @endif - + @can('deploy', $resource) +
+ + +
+ @endcan + @can('update', $resource) + + @endcan
@endforeach