Skip to content

Commit a08ba72

Browse files
committed
EAP
1 parent 6e8e20f commit a08ba72

27 files changed

+426
-178
lines changed

resources/assets/background-pattern-dark.svg

+1
Loading

resources/assets/background-pattern.svg

+1
Loading

resources/css/app.css

+12-2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,16 @@
1111
backdrop-filter: blur(20px);
1212
}
1313

14+
.background-pattern {
15+
background-image: url('../assets/background-pattern.svg');
16+
}
17+
18+
@media(prefers-color-scheme: dark) {
19+
.background-pattern {
20+
background-image: url('../assets/background-pattern-dark.svg');
21+
}
22+
}
23+
1424

1525
/* Whole menu */
1626
nav ul {
@@ -49,7 +59,7 @@ nav > ul > li > ul {
4959
& > li {
5060
@apply font-normal;
5161

52-
a {
62+
& a {
5363
@apply w-full block;
5464
@apply py-1.5;
5565
@apply border-l pl-3 dark:border-white/10;
@@ -177,7 +187,7 @@ nav > ul > li > ul {
177187
}
178188

179189
.DocSearch-Button-Placeholder {
180-
@apply dark:text-white/60 pr-56 text-xs;
190+
@apply dark:text-white/60 pr-44 text-xs;
181191
}
182192

183193
.DocSearch-Button-Keys {
+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
<div class="flex items-center justify-center bg-teal-500 p-2 text-center text-sm text-white text-balance">
1+
<div class="flex items-center justify-center bg-teal-500 p-2 text-center text-md text-white text-balance transition-all ease-out duration-500 -translate-y-[100%]"
2+
x-init="$el.classList.add('-translate-y-0')">
23
<a href="/newsletter" onclick="fathom.trackEvent('alert_click');">
3-
📲&nbsp;&nbsp;Excited for NativePHP for iOS and Android? Sign up for the newsletter &rightarrow;
4+
📲&nbsp;&nbsp;Excited for NativePHP for iOS and Android? <u>Sign up for the newsletter &rightarrow;</u>
45
</a>
56
</div>

resources/views/components/banner.blade.php

-56
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
<a {{ $attributes->class(['group
2+
inline-block
3+
text-sm bg-purple-500 border-purple-600
4+
dark:border-purple-500 dark:bg-purple-700
5+
hover:bg-purple-600 dark:hover:bg-purple-800
6+
px-4 py-1.5
7+
border rounded-md
8+
font-medium
9+
text-white
10+
']) }} href="{{route('early-adopter')}}">
11+
<div class="group-hover:animate-none flex items-center gap-2"
12+
x-data="{earlyAnimated: $persist(false)}"
13+
x-init="setTimeout(() => {earlyAnimated = true}, 6000)"
14+
x-bind:class="!earlyAnimated ? 'animate-pulse' : ''"
15+
x-on:click="earlyAnimated = false"
16+
>
17+
18+
<x-icons.party-popper class="size-4"/>
19+
{{-- <x-icons.sparkles class="size-4"/>--}}
20+
{{-- <x-icons.device-mobile-phone class="size-4"/>--}}
21+
<span>Soon on iOS!</span>
22+
</div>
23+
</a>

resources/views/components/footer.blade.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
Logo by <a href="https://twitter.com/caneco" target="_blank">Caneco</a>.
1212
</p>
1313
</div>
14-
14+
1515
<div class="flex items-center justify-center space-x-6">
16-
<x-social-networks-all/>
16+
<x-social-networks-all/>
1717
</div>
1818
</footer>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
@props(['hasMenu' => false])
2+
<div class="sticky top-0 z-50
3+
text-white blur-background bg-gray-50/85 dark:bg-gray-800/85
4+
border-b border-gray-100 dark:border-0
5+
">
6+
7+
<div class="hidden lg:block">
8+
<x-alert/>
9+
</div>
10+
11+
<div class="relative flex top-0 left-0 z-50
12+
md:grid md:grid-cols-4
13+
items-center justify-between gap-6 px-6 py-3
14+
mx-auto max-w-8xl
15+
sm:py-4">
16+
<a
17+
href="/"
18+
class="inline-flex items-center transition rounded hover:text-white/80 focus:outline-none
19+
max-md:w-32
20+
focus-visible:ring-2 focus-visible:ring-white/80 focus-visible:ring-offset-2 focus-visible:ring-offset-red-600"
21+
>
22+
<img src="{{ asset('logo.svg') }}" class="h-8 dark:hidden">
23+
<img src="{{ asset('logo-dark.svg') }}" class="hidden h-8 dark:block">
24+
<span class="sr-only">NativePHP</span>
25+
</a>
26+
27+
<div class="flex-1 md:col-span-2 lg:mx-16 xl:mx-32">
28+
<div id="docsearch"></div>
29+
</div>
30+
31+
<div class="hidden lg:flex items-center justify-end space-x-5">
32+
33+
<a href="https://bsky.app/profile/nativephp.bsky.social" title="Bluesky">
34+
<x-icons.bluesky class="size-5 text-black dark:invert hover:text-[#00aaa6] hover:invert-0"/>
35+
</a>
36+
37+
<a href="https://discord.gg/X62tWNStZK" title="Go to discord server">
38+
<x-icons.discord class="size-5 text-black dark:text-white hover:text-[#00aaa6]"/>
39+
</a>
40+
41+
<a href="https://opencollective.com/nativephp" title="NativePHP on LinkedIn">
42+
<x-icons.opencollective class="size-5 text-black dark:invert hover:text-[#00aaa6] hover:invert-0"/>
43+
</a>
44+
45+
<a href="https://github.com/nativephp" title="Source code of NativePHP">
46+
<x-icons.github class="size-5 dark:fill-white hover:fill-[#00aaa6]"/>
47+
</a>
48+
</div>
49+
<div class="lg:hidden flex justify-end pl-4">
50+
@if($hasMenu)
51+
<button type="button" class="" @click="showDocsNavigation = !showDocsNavigation">
52+
<div x-show="!showDocsNavigation">
53+
<x-icons.menu class="w-6 h-6 text-teal-600 dark:text-teal-300"/>
54+
</div>
55+
<div x-show="showDocsNavigation">
56+
<x-icons.close class="w-6 h-6 text-teal-600"/>
57+
</div>
58+
</button>
59+
@else
60+
<a href="{{route('docs')}}" class="text-teal-600 hover:text-teal-800 dark:text-teal-400 dark:hover:text-teal-200
61+
flex items-center gap-1">
62+
<x-icons.book-text class="size-5"/>
63+
<span class="text-md hidden sm:inline">Documentation</span>
64+
</a>
65+
@endif
66+
</div>
67+
</div>
68+
</div>
69+
<div class="block lg:hidden">
70+
<x-alert/>
71+
</div>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<svg {{$attributes}} xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.25" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-book-open-text"><path d="M12 7v14"/><path d="M16 12h2"/><path d="M16 8h2"/><path d="M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z"/><path d="M6 12h2"/><path d="M6 8h2"/></svg>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<svg {{$attributes}} xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.25" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-book-text"><path d="M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20"/><path d="M8 11h8"/><path d="M8 7h6"/></svg>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<svg {{ $attributes }} xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="size-6">
2+
<path stroke-linecap="round" stroke-linejoin="round" d="M10.5 1.5H8.25A2.25 2.25 0 0 0 6 3.75v16.5a2.25 2.25 0 0 0 2.25 2.25h7.5A2.25 2.25 0 0 0 18 20.25V3.75a2.25 2.25 0 0 0-2.25-2.25H13.5m-3 0V3h3V1.5m-3 0h3m-3 18.75h3" />
3+
</svg>
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
1-
<svg
1+
<svg
22
{{ $attributes }}
33
viewBox="0 -28.5 256 256" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" preserveAspectRatio="xMidYMid">
44
<g>
5-
<path d="M216.856339,16.5966031 C200.285002,8.84328665 182.566144,3.2084988 164.041564,0 C161.766523,4.11318106 159.108624,9.64549908 157.276099,14.0464379 C137.583995,11.0849896 118.072967,11.0849896 98.7430163,14.0464379 C96.9108417,9.64549908 94.1925838,4.11318106 91.8971895,0 C73.3526068,3.2084988 55.6133949,8.86399117 39.0420583,16.6376612 C5.61752293,67.146514 -3.4433191,116.400813 1.08711069,164.955721 C23.2560196,181.510915 44.7403634,191.567697 65.8621325,198.148576 C71.0772151,190.971126 75.7283628,183.341335 79.7352139,175.300261 C72.104019,172.400575 64.7949724,168.822202 57.8887866,164.667963 C59.7209612,163.310589 61.5131304,161.891452 63.2445898,160.431257 C105.36741,180.133187 151.134928,180.133187 192.754523,160.431257 C194.506336,161.891452 196.298154,163.310589 198.110326,164.667963 C191.183787,168.842556 183.854737,172.420929 176.223542,175.320965 C180.230393,183.341335 184.861538,190.991831 190.096624,198.16893 C211.238746,191.588051 232.743023,181.531619 254.911949,164.955721 C260.227747,108.668201 245.831087,59.8662432 216.856339,16.5966031 Z M85.4738752,135.09489 C72.8290281,135.09489 62.4592217,123.290155 62.4592217,108.914901 C62.4592217,94.5396472 72.607595,82.7145587 85.4738752,82.7145587 C98.3405064,82.7145587 108.709962,94.5189427 108.488529,108.914901 C108.508531,123.290155 98.3405064,135.09489 85.4738752,135.09489 Z M170.525237,135.09489 C157.88039,135.09489 147.510584,123.290155 147.510584,108.914901 C147.510584,94.5396472 157.658606,82.7145587 170.525237,82.7145587 C183.391518,82.7145587 193.761324,94.5189427 193.539891,108.914901 C193.539891,123.290155 183.391518,135.09489 170.525237,135.09489 Z" fill-rule="nonzero">
6-
7-
</path>
5+
<path d="M216.856339,16.5966031 C200.285002,8.84328665 182.566144,3.2084988 164.041564,0 C161.766523,4.11318106 159.108624,9.64549908 157.276099,14.0464379 C137.583995,11.0849896 118.072967,11.0849896 98.7430163,14.0464379 C96.9108417,9.64549908 94.1925838,4.11318106 91.8971895,0 C73.3526068,3.2084988 55.6133949,8.86399117 39.0420583,16.6376612 C5.61752293,67.146514 -3.4433191,116.400813 1.08711069,164.955721 C23.2560196,181.510915 44.7403634,191.567697 65.8621325,198.148576 C71.0772151,190.971126 75.7283628,183.341335 79.7352139,175.300261 C72.104019,172.400575 64.7949724,168.822202 57.8887866,164.667963 C59.7209612,163.310589 61.5131304,161.891452 63.2445898,160.431257 C105.36741,180.133187 151.134928,180.133187 192.754523,160.431257 C194.506336,161.891452 196.298154,163.310589 198.110326,164.667963 C191.183787,168.842556 183.854737,172.420929 176.223542,175.320965 C180.230393,183.341335 184.861538,190.991831 190.096624,198.16893 C211.238746,191.588051 232.743023,181.531619 254.911949,164.955721 C260.227747,108.668201 245.831087,59.8662432 216.856339,16.5966031 Z M85.4738752,135.09489 C72.8290281,135.09489 62.4592217,123.290155 62.4592217,108.914901 C62.4592217,94.5396472 72.607595,82.7145587 85.4738752,82.7145587 C98.3405064,82.7145587 108.709962,94.5189427 108.488529,108.914901 C108.508531,123.290155 98.3405064,135.09489 85.4738752,135.09489 Z M170.525237,135.09489 C157.88039,135.09489 147.510584,123.290155 147.510584,108.914901 C147.510584,94.5396472 157.658606,82.7145587 170.525237,82.7145587 C183.391518,82.7145587 193.761324,94.5189427 193.539891,108.914901 C193.539891,123.290155 183.391518,135.09489 170.525237,135.09489 Z" fill-rule="nonzero" fill="currentColor"></path>
86
</g>
9-
</svg>
7+
</svg>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<svg {{ $attributes }} xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.25" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-gift"><rect x="3" y="8" width="18" height="4" rx="1"/><path d="M12 8v13"/><path d="M19 12v7a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-7"/><path d="M7.5 8a2.5 2.5 0 0 1 0-5A4.8 8 0 0 1 12 8a4.8 8 0 0 1 4.5-5 2.5 2.5 0 0 1 0 5"/></svg>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<svg {{$attributes}} xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.25" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-party-popper"><path d="M5.8 11.3 2 22l10.7-3.79"/><path d="M4 3h.01"/><path d="M22 8h.01"/><path d="M15 2h.01"/><path d="M22 20h.01"/><path d="m22 2-2.24.75a2.9 2.9 0 0 0-1.96 3.12c.1.86-.57 1.63-1.45 1.63h-.38c-.86 0-1.6.6-1.76 1.44L14 10"/><path d="m22 13-.82-.33c-.86-.34-1.82.2-1.98 1.11c-.11.7-.72 1.22-1.43 1.22H17"/><path d="m11 2 .33.82c.34.86-.2 1.82-1.11 1.98C9.52 4.9 9 5.52 9 6.23V7"/><path d="M11 13c1.93 1.93 2.83 4.17 2 5-.83.83-3.07-.07-5-2-1.93-1.93-2.83-4.17-2-5 .83-.83 3.07.07 5 2Z"/></svg>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<svg {{$attributes}} xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.25" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-sparkles"><path d="M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z"/><path d="M20 3v4"/><path d="M22 5h-4"/><path d="M4 17v2"/><path d="M5 18H3"/></svg>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<x-layout :hasMenu="! empty($sidebarLeft)">
2+
<main class="overflow-hidden lg:flex lg:flex-1 lg:flex-col">
3+
4+
<div class="max-w-8xl mx-auto px-4 sm:px-6 md:px-8">
5+
<main class="overflow-hidden lg:flex lg:flex-1 lg:flex-col">
6+
7+
@if(!empty($sidebarLeft))
8+
<x-sidebar-left-navigation>
9+
{{ $sidebarLeft }}
10+
</x-sidebar-left-navigation>
11+
@endif
12+
13+
14+
<div class="lg:pl-[19.5rem]">
15+
<div class="max-w-3xl mx-auto pt-4 sm:pt-6 xl:max-w-none xl:ml-0 xl:mr-[15.5rem] xl:pr-16">
16+
17+
@if(!empty($sidebarRight))
18+
<x-sidebar-right>
19+
{{ $sidebarRight }}
20+
</x-sidebar-right>
21+
@endif
22+
23+
{{ $slot }}
24+
25+
<x-footer/>
26+
</div>
27+
</div>
28+
</main>
29+
</div>
30+
</main>
31+
</x-layout>

resources/views/components/layout.blade.php

+5-3
Original file line numberDiff line numberDiff line change
@@ -16,18 +16,20 @@
1616
href="https://fonts.bunny.net/css?family=be-vietnam-pro:700|inter:400,500,600|rubik:400,700"
1717
rel="stylesheet"
1818
/>
19-
19+
<script defer src="https://cdn.jsdelivr.net/npm/@alpinejs/[email protected]/dist/cdn.min.js"></script>
2020
@vite(["resources/css/app.css", "resources/js/app.js"])
2121

2222
<!-- Fathom - beautiful, simple website analytics -->
2323
<script src="https://cdn.usefathom.com/script.js" data-site="HALHTNZU" defer></script>
2424
<!-- / Fathom -->
2525
</head>
26-
<body class="min-h-screen font-sans antialiased bg-white dark:bg-gray-900 dark:text-white"
26+
<body class="min-h-screen font-sans antialiased bg-white dark:bg-gray-900 dark:text-white
27+
@isset($backgroundPattern) background-pattern @endisset
28+
"
2729
x-data="{ showDocsNavigation: false }"
2830
>
2931

30-
<x-banner />
32+
<x-header-banner :hasMenu="$hasMenu ?? false" />
3133
{{ $slot }}
3234
<script src="https://cdn.jsdelivr.net/npm/@docsearch/js@3"></script>
3335
<script type="text/javascript">

resources/views/components/link-button.blade.php

+8-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,14 @@
11
<a {{ $attributes->class(['
2+
inline-block
3+
w-fit
24
font-medium
3-
border border-gray-300 dark:border-gray-700 rounded-lg
5+
shadow-sm dark:shadow-white/10
6+
border border-gray-300 dark:border-transparent
7+
bg-white dark:bg-gray-700
8+
rounded-lg
49
px-4 py-2
5-
hover:text-[#00aaa6] hover:border-[#00aaa6]/25
10+
text-black dark:text-gray-100
11+
hover:text-[#00aaa6] hover:border-[#00aaa6]/25 dark:hover:border-transparent
612
flex items-center gap-2
713
text-sm
814
']) }}>

resources/views/components/sidebar-left.blade.php resources/views/components/sidebar-left-navigation.blade.php

+4-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
dark:text-gray-200
1313
">
1414
<nav class="flex flex-col flex-1">
15-
{!! $navigation !!}
15+
{!! $slot !!}
1616
</nav>
1717
</div>
1818

@@ -25,7 +25,9 @@
2525
x-transition:leave-start="translate-y-0 opacity-100"
2626
x-transition:leave-end="translate-y-1 opacity-0"
2727
class="fixed top-12 left-0 z-40 w-full h-screen pt-10 pb-16 overflow-y-auto bg-white dark:bg-gray-700 mt-2 px-4 border-b border-[#00aaa6] border-opacity-50 dark:border-opacity-90">
28-
{!! $navigation !!}
28+
29+
30+
{!! $slot !!}
2931

3032

3133
<div class="my-16 flex items-center justify-center space-x-6">

resources/views/components/sidebar-right.blade.php

+1-25
Original file line numberDiff line numberDiff line change
@@ -11,29 +11,5 @@
1111
1212
border-l border-[#00aaa6] border-opacity-10 dark:border-gray-800
1313
">
14-
<x-sidebar-title>On this page</x-sidebar-title>
15-
@if (count($tableOfContents) > 0)
16-
<ul class="mt-4 space-y-2 text-sm">
17-
@foreach($tableOfContents as $item)
18-
<li class="hover:text-[#00aaa6] text-gray-700 dark:text-gray-300
19-
20-
@if($item['level'] == 2) font-semibold leading-6 @endif
21-
@if($item['level'] == 3) ml-4 leading-4 pb-0.5 @endif
22-
@if($item['level'] == 3 && ($tableOfContents[$loop->index+1]['level']??0) == 2) pb-2 @endif
23-
">
24-
<a href="#{{ $item['anchor'] }}">{{ $item['title'] }}</a>
25-
</li>
26-
@endforeach
27-
</ul>
28-
@endif
29-
30-
<x-sidebar-title class="mt-8">Featured sponsors</x-sidebar-title>
31-
<div class="mt-4 flex flex-col gap-4 w-3/4 pl-3">
32-
<x-sponsors-featured height="h-12" :same-height="false"/>
33-
</div>
34-
35-
<x-sidebar-title class="mt-8">Corporate sponsors</x-sidebar-title>
36-
<div class="mt-4 flex flex-col gap-6 w-3/4 pl-3">
37-
<x-sponsors-corporate height="h-8"/>
38-
</div>
14+
{{ $slot }}
3915
</div>

resources/views/components/social-networks-all.blade.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
</a>
55

66
<a href="https://discord.gg/X62tWNStZK" title="Go to discord server">
7-
<x-icons.discord class="size-5 dark:fill-white hover:fill-[#00aaa6]" />
7+
<x-icons.discord class="size-5 text-black dark:text-white hover:text-[#00aaa6]" />
88
</a>
99

1010
<a href="https://opencollective.com/nativephp" title="NativePHP on Open Collective">

0 commit comments

Comments
 (0)