|
12 | 12 |
|
13 | 13 | <header class="site-header"> |
14 | 14 | <div class="header-container"> |
15 | | - <a href="/" class="header-logo">OpenBoot</a> |
16 | | - <nav class="header-nav"> |
17 | | - <a href="/explore" class:active={currentPath === '/explore' || currentPath.startsWith('/explore')}>Explore</a> |
18 | | - <a href="/docs" class:active={currentPath === '/docs' || currentPath.startsWith('/docs')}>Docs</a> |
19 | | - </nav> |
| 15 | + <div class="header-left"> |
| 16 | + <a href="/" class="header-logo">OpenBoot</a> |
| 17 | + <nav class="header-nav"> |
| 18 | + <a href="/explore" class:active={currentPath === '/explore' || currentPath.startsWith('/explore')}>Explore</a> |
| 19 | + <a href="/docs" class:active={currentPath === '/docs' || currentPath.startsWith('/docs')}>Docs</a> |
| 20 | + </nav> |
| 21 | + <div class="header-actions"> |
| 22 | + {#if children}{@render children()}{/if} |
| 23 | + <GitHubStarBadge /> |
| 24 | + {#if $auth.loading} |
| 25 | + |
| 26 | + {:else if $auth.user} |
| 27 | + <a href="/dashboard" class="header-dashboard-link">Dashboard</a> |
| 28 | + <span class="header-separator">/</span> |
| 29 | + <a href="/api/auth/logout" class="header-logout-link">Logout</a> |
| 30 | + {:else} |
| 31 | + <a href="/login" class="header-login-link">Sign in</a> |
| 32 | + {/if} |
| 33 | + </div> |
| 34 | + </div> |
20 | 35 | <div class="header-right"> |
21 | | - {#if children}{@render children()}{/if} |
22 | | - <GitHubStarBadge /> |
23 | | - {#if $auth.loading} |
24 | | - |
25 | | - {:else if $auth.user} |
26 | | - <a href="/dashboard" class="header-dashboard-link">Dashboard</a> |
27 | | - <span class="header-separator">/</span> |
28 | | - <a href="/api/auth/logout" class="header-logout-link">Logout</a> |
29 | | - {:else} |
30 | | - <a href="/login" class="header-login-link">Sign in</a> |
31 | | - {/if} |
32 | 36 | <ThemeToggle /> |
33 | 37 | </div> |
34 | 38 | </div> |
|
52 | 56 | margin: 0 auto; |
53 | 57 | padding: 14px 24px; |
54 | 58 | display: flex; |
55 | | - justify-content: flex-start; |
| 59 | + justify-content: space-between; |
| 60 | + align-items: center; |
| 61 | + } |
| 62 | +
|
| 63 | + .header-left { |
| 64 | + display: flex; |
56 | 65 | align-items: center; |
57 | 66 | gap: 20px; |
58 | 67 | } |
|
108 | 117 | transform: scaleX(1); |
109 | 118 | } |
110 | 119 |
|
111 | | - .header-right { |
| 120 | + .header-actions { |
112 | 121 | display: flex; |
113 | 122 | align-items: center; |
114 | 123 | gap: 16px; |
115 | 124 | } |
116 | 125 |
|
| 126 | + .header-right { |
| 127 | + display: flex; |
| 128 | + align-items: center; |
| 129 | + } |
| 130 | +
|
117 | 131 | .header-dashboard-link, |
118 | 132 | .header-login-link, |
119 | 133 | .header-logout-link { |
|
0 commit comments