Фтуер готов. Приложение в работоспособном состоянии

This commit is contained in:
Alexander Andreev 2026-01-03 15:30:03 +03:00
parent bab91b6448
commit 860078f149

View File

@ -15,11 +15,14 @@
<slot /> <slot />
</main> </main>
<nav class="bottom-nav"> <footer class="app-footer">
<NuxtLink to="/village" class="nav-item">Village</NuxtLink> <nav class="bottom-nav">
<NuxtLink to="/habits" class="nav-item">Habits</NuxtLink> <NuxtLink to="/" class="nav-item">Главная</NuxtLink>
<NuxtLink to="/leaderboard" class="nav-item">Leaderboard</NuxtLink> <NuxtLink to="/habits" class="nav-item">Привычки</NuxtLink>
</nav> <NuxtLink to="/village" class="nav-item">Деревня</NuxtLink>
<NuxtLink to="/leaderboard" class="nav-item">Лидеры</NuxtLink>
</nav>
</footer>
</div> </div>
</template> </template>
@ -31,7 +34,7 @@ const { user } = useAuth();
.default-layout { .default-layout {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
height: 100vh; min-height: 100vh; /* Use min-height to allow content to push height */
background-color: #eef5ff; background-color: #eef5ff;
color: #333; color: #333;
} }
@ -53,17 +56,28 @@ const { user } = useAuth();
.app-content { .app-content {
flex-grow: 1; flex-grow: 1;
overflow-y: auto; overflow-y: auto; /* Allow content to scroll */
padding: 15px; padding: 15px;
/* Add padding-bottom to prevent content from being overlapped by fixed footer */
padding-bottom: 60px; /* Adjust based on footer height */
}
.app-footer {
flex-shrink: 0;
position: fixed; /* Changed to fixed as per request */
bottom: 0;
width: 100%;
background-color: #ffffff;
border-top: 1px solid #dcdcdc;
padding: 10px 0;
box-sizing: border-box; /* Include padding in width */
z-index: 1000; /* Ensure footer is on top */
} }
.bottom-nav { .bottom-nav {
display: flex; display: flex;
justify-content: space-around; justify-content: space-around;
padding: 10px 0; width: 100%;
background-color: #ffffff;
border-top: 1px solid #dcdcdc;
flex-shrink: 0;
} }
.nav-item { .nav-item {
@ -71,6 +85,8 @@ const { user } = useAuth();
color: #4a90e2; color: #4a90e2;
padding: 5px 10px; padding: 5px 10px;
border-radius: 5px; border-radius: 5px;
text-align: center;
flex: 1; /* Distribute space evenly */
} }
.nav-item.router-link-exact-active { .nav-item.router-link-exact-active {