Skip to content

Commit

Permalink
Automatically display the latest version on the library upgrade page.
Browse files Browse the repository at this point in the history
  • Loading branch information
tabuna committed Dec 1, 2024
1 parent f19ab86 commit 85d679e
Showing 1 changed file with 16 additions and 5 deletions.
21 changes: 16 additions & 5 deletions resources/views/library/upgrade.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,27 @@
которого необходимо придерживаться.
</x-slot>

<x-slot:content >
<x-slot:content>
<div class="d-none d-md-flex align-items-baseline lead fw-bold mx-md-auto text-md-center">
<span class="d-inline-block mx-2 mx-sm-3 display-5 opacity-25">7.x</span>
<span class="d-inline-block mx-2 mx-sm-3 display-4 opacity-50 border-5">8.x</span>
<span class="d-inline-block mx-2 mx-sm-3 display-3 opacity-75">9.x</span>
<span class="d-inline-block mx-2 mx-sm-3 display-1 border-bottom border-primary">10.x</span>
@php
$version = \Str::of(\App\Docs::DEFAULT_VERSION)->before('.')->toString();
@endphp

@foreach(collect()->range(0,3)->reverse() as $index)
<span @class([
'd-inline-block mx-2 mx-sm-3',
'display-' . ($index + 1),
'opacity-' . [100, 75, 50, 25][$index],
'border-bottom border-primary' => $index === 0,
])>
{{ $version - $index }}.x
</span>
@endforeach
</div>
</x-slot:content>
</x-header>


@php
$sections = collect([
"security",
Expand Down

0 comments on commit 85d679e

Please sign in to comment.