lasthourcloud/resources/views/source/all.blade.php

47 lines
2.1 KiB
PHP
Raw Normal View History

2023-06-12 20:02:10 +00:00
<x-layout>
2023-09-24 19:15:21 +00:00
<div class="flex items-start gap-2">
<h1>Sources</h1>
2024-03-21 11:44:32 +00:00
<x-slide-over fullScreen closeWithX>
<x-slot:title>New GitHub App</x-slot:title>
<x-slot:content>
<livewire:source.github.create />
</x-slot:content>
<button @click="slideOverOpen=true" class="button">+
Add</button>
</x-slide-over>
2023-09-24 19:15:21 +00:00
</div>
2024-03-22 10:34:15 +00:00
<div class="subtitle ">Git sources for your applications.</div>
2023-06-14 10:48:29 +00:00
<div class="grid gap-2 lg:grid-cols-2">
2023-06-12 20:02:10 +00:00
@forelse ($sources as $source)
@if ($source->getMorphClass() === 'App\Models\GithubApp')
2024-03-21 11:44:32 +00:00
<a class="flex gap-4 text-center hover:no-underline box group"
2023-08-11 18:19:42 +00:00
href="{{ route('source.github.show', ['github_app_uuid' => data_get($source, 'uuid')]) }}">
<x-git-icon class="text-white w-9 h-9" git="{{ $source->getMorphClass() }}" />
2023-08-30 12:46:51 +00:00
<div class="text-left group-hover:text-white">
2023-06-12 20:02:10 +00:00
<div>{{ $source->name }}</div>
2023-06-13 08:59:27 +00:00
@if (is_null($source->app_id))
2023-08-30 12:46:51 +00:00
<span class="text-error">Configuration is not finished</span>
2023-06-13 08:59:27 +00:00
@endif
2023-06-12 20:02:10 +00:00
</div>
</a>
@endif
@if ($source->getMorphClass() === 'App\Models\GitlabApp')
2024-03-21 11:44:32 +00:00
<a class="flex gap-4 text-center hover:no-underline box group"
2023-08-11 18:19:42 +00:00
href="{{ route('source.gitlab.show', ['gitlab_app_uuid' => data_get($source, 'uuid')]) }}">
<x-git-icon class="text-white w-9 h-9" git="{{ $source->getMorphClass() }}" />
2023-08-30 12:46:51 +00:00
<div class="text-left group-hover:text-white">
2023-06-12 20:02:10 +00:00
<div>{{ $source->name }}</div>
2023-06-13 08:59:27 +00:00
@if (is_null($source->app_id))
2023-08-30 12:46:51 +00:00
<span class="text-error">Configuration is not finished</span>
2023-06-13 08:59:27 +00:00
@endif
2023-06-12 20:02:10 +00:00
</div>
</a>
@endif
@empty
<div>
<div>No sources found.</div>
</div>
@endforelse
</div>
</x-layout>