Новые правки
This commit is contained in:
parent
41d790bfa3
commit
cd8da6b3b8
1 changed files with 41 additions and 13 deletions
|
|
@ -64,11 +64,7 @@ import { COMPANY } from "@constants";
|
|||
</a>
|
||||
|
||||
<!-- Блок авторизации для мобильных -->
|
||||
<div class="mobile-auth-block" id="mobile-auth-block">
|
||||
<a href="/auth/sign-in" class="mobile-auth-btn" id="mobile-auth-btn">
|
||||
<span>Войти</span>
|
||||
</a>
|
||||
</div>
|
||||
<div class="mobile-auth-block" id="mobile-auth-block"></div>
|
||||
|
||||
<button class="burger-btn" id="burger-btn" aria-label="Открыть меню">
|
||||
<span class="burger-line"></span>
|
||||
|
|
@ -271,14 +267,48 @@ import { COMPANY } from "@constants";
|
|||
.mobile-actions {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 16px;
|
||||
gap: 12px;
|
||||
}
|
||||
|
||||
/* Мобильный блок авторизации */
|
||||
/* Мобильный блок авторизации */
|
||||
.mobile-auth-block {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
/* Кнопка входа - круглая иконка */
|
||||
.mobile-auth-btn {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 36px;
|
||||
height: 36px;
|
||||
padding: 0;
|
||||
background: transparent;
|
||||
border: 2px solid #1e3050;
|
||||
border-radius: 50%;
|
||||
color: #1e3050;
|
||||
text-decoration: none;
|
||||
transition: all 0.3s ease;
|
||||
}
|
||||
|
||||
.mobile-auth-btn:hover {
|
||||
background: #1e3050;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
/* Кнопка выхода - круглая иконка */
|
||||
.mobile-auth-btn.logout-btn {
|
||||
width: 36px;
|
||||
height: 36px;
|
||||
border: 2px solid #ef4444;
|
||||
border-radius: 50%;
|
||||
color: #ef4444;
|
||||
}
|
||||
|
||||
.mobile-auth-btn.logout-btn:hover {
|
||||
background: #ef4444;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
/* Кнопка входа - как в десктопе */
|
||||
|
|
@ -409,7 +439,7 @@ import { COMPANY } from "@constants";
|
|||
.mobile-actions {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 16px;
|
||||
gap: 12px;
|
||||
}
|
||||
.mobile-phone-btn,
|
||||
.burger-btn,
|
||||
|
|
@ -507,10 +537,8 @@ import { COMPANY } from "@constants";
|
|||
localStorage.removeItem('user');
|
||||
localStorage.removeItem('pocketbase_auth');
|
||||
document.querySelector('.header-right')?.classList.remove('auth-active');
|
||||
// Редирект на текущую страницу с параметром loggedout
|
||||
const currentUrl = window.location.pathname + window.location.search + window.location.hash;
|
||||
const separator = currentUrl.includes('?') ? '&' : '?';
|
||||
window.location.href = currentUrl + separator + 'loggedout=true';
|
||||
// Остаемся на той же странице
|
||||
window.location.reload();
|
||||
});
|
||||
|
||||
// Добавляем класс для изменения порядка
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue