feat(ui): Improve GitHub repository selection and styling

This commit is contained in:
Andras Bacsai
2025-03-11 22:29:17 +01:00
parent 911957ff66
commit e8b3f68e66
2 changed files with 22 additions and 20 deletions

View File

@@ -15,9 +15,9 @@
</div>
<div class="pb-4">Deploy any public or private Git repositories through a GitHub App.</div>
@if ($github_apps->count() !== 0)
<h2 class="pt-4 pb-4">Select a Github App</h2>
<div class="flex flex-col gap-2">
@if ($current_step === 'github_apps')
<h2 class="pt-4 pb-4">Select a Github App</h2>
<div class="flex flex-col justify-center gap-2 text-left">
@foreach ($github_apps as $ghapp)
<div class="flex">
@@ -43,25 +43,28 @@
@endif
@if ($current_step === 'repository')
@if ($repositories->count() > 0)
<div class="flex items-end gap-2">
<x-forms.select class="w-full" label="Repository" wire:model="selected_repository_id">
@foreach ($repositories as $repo)
@if ($loop->first)
<option selected value="{{ data_get($repo, 'id') }}">
{{ data_get($repo, 'name') }}
</option>
@else
<option value="{{ data_get($repo, 'id') }}">{{ data_get($repo, 'name') }}
</option>
@endif
@endforeach
</x-forms.select>
<div class="flex flex-col gap-2 pb-6">
<div class="flex gap-2">
<x-forms.select class="w-full" label="Repository" wire:model="selected_repository_id">
@foreach ($repositories as $repo)
@if ($loop->first)
<option selected value="{{ data_get($repo, 'id') }}">
{{ data_get($repo, 'name') }}
</option>
@else
<option value="{{ data_get($repo, 'id') }}">{{ data_get($repo, 'name') }}
</option>
@endif
@endforeach
</x-forms.select>
</div>
<x-forms.button wire:click.prevent="loadBranches"> Load Repository </x-forms.button>
</div>
@else
<div>No repositories found. Check your GitHub App configuration.</div>
@endif
@if ($branches->count() > 0)
<h2 class="text-lg font-bold">Configuration</h2>
<div class="flex flex-col gap-2 pb-6">
<form class="flex flex-col" wire:submit='submit'>
<div class="flex flex-col gap-2 pb-6">