From 421056ea43bcde4a771ad83c201fc082656181d3 Mon Sep 17 00:00:00 2001 From: Aditya Tripathi Date: Mon, 14 Sep 2026 05:34:48 +0000 Subject: [PATCH] feat(env-vars): split production and preview into labelled sections Preview and production variables were interleaved in one table with a shared Type column. Drop the Type column and head each scope's rows with a 'Production' / 'Preview deployments' section label, so the two groups read as separate sections. Rows already carry their scope and are ordered production-first, so this is presentation-only. --- .../shared/environment-variable/all.blade.php | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/resources/views/livewire/project/shared/environment-variable/all.blade.php b/resources/views/livewire/project/shared/environment-variable/all.blade.php index ae95ef6806..41b62e3c69 100644 --- a/resources/views/livewire/project/shared/environment-variable/all.blade.php +++ b/resources/views/livewire/project/shared/environment-variable/all.blade.php @@ -1,5 +1,8 @@ @php - $showEnvironmentType = $showPreview; + // Preview and production variables are split into labelled groups instead of a + // shared "Type" column, so the column is dropped and rows are headed by scope. + $groupByScope = $showPreview; + $showEnvironmentType = false; $activeFilterCount = count($variableFilters) + count($serviceFilters) + ($environmentFilter !== 'all' ? 1 : 0); $filterLabels = [ 'managed' => 'Managed', 'user' => 'User-defined', 'buildtime' => 'Buildtime', @@ -212,7 +215,14 @@ Runtime + @php $renderedScope = null; @endphp @foreach ($this->environmentVariablePageRows as $row) + @if ($groupByScope && $row['scope'] !== $renderedScope) + @php $renderedScope = $row['scope']; @endphp +
+ {{ $renderedScope === 'preview' ? 'Preview deployments' : 'Production' }} +
+ @endif @if ($row['kind'] === 'managed')