mirror of
https://github.com/stancl/tenancy-docs.git
synced 2025-12-12 02:04:03 +00:00
Version select
This commit is contained in:
parent
a3915750cb
commit
bbe4fcd7fc
3 changed files with 17 additions and 2 deletions
|
|
@ -55,6 +55,16 @@
|
|||
@include('_nav.search-input')
|
||||
@endif
|
||||
</div>
|
||||
|
||||
<div class="flex flex-1 justify-end items-center text-right md:pl-10">
|
||||
<select id="versionSelect">
|
||||
@foreach($page->navigation as $version => $_)
|
||||
<option value="{{ $page->baseUrl . $version }}">
|
||||
{{ $version }}
|
||||
</option>
|
||||
@endforeach
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@yield('nav-toggle')
|
||||
|
|
@ -80,5 +90,10 @@
|
|||
</li>
|
||||
</ul>
|
||||
</footer>
|
||||
<script>
|
||||
document.getElementById('versionSelect').addEventListener('change', function () {
|
||||
window.location = document.getElementById('versionSelect').value;
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue