- API и страницы профиля (редактирование, смена пароля, аватар), публичные карточки. - Сайдбар: блок пользователя, пункт Users для admin/root, исправлен порядок инициализации (показ admin-only после initAuthSession, currentUser). - GET /auth/me: ответ через ProfileMeResponse, исправлена валидация (is_founder bool). Команды и роли - Маршруты и UI команд; при редактировании роли: видимость Team, выбор команды в модалке, только команды с активным членством; API team_id в details/ update. - GET /api/v1/teams?membership=active для списка «своих» команд. - Форма роли: сегмент Team, панель выбора команды только при Team и не при с
47 lines
2.7 KiB
HTML
47 lines
2.7 KiB
HTML
{% extends "base.xhtml" %}
|
|
{% from "macros/page-hero.xhtml" import page_hero %}
|
|
{% block content %}
|
|
<div class="dashboard-page profile-page" data-page="profile-avatar">
|
|
{{ page_hero("Account", "Profile photo", "Drag an image here or browse. We store your original file plus 54px, 128px, and 256px versions for the UI.") }}
|
|
<section class="dashboard-panel dashboard-panel--primary">
|
|
<div class="profile-avatar-layout">
|
|
<div class="profile-avatar-preview-col">
|
|
<p class="muted small-note" id="profile-avatar-hint">
|
|
Your current photo. After choosing an image, drag it and use zoom to frame the circle before upload.
|
|
</p>
|
|
<div class="profile-avatar-viewport-wrap">
|
|
<div id="profile-avatar-viewport" class="profile-avatar-viewport" aria-label="Avatar preview">
|
|
<img id="profile-avatar-display-img" class="profile-avatar-display-img" src="" alt="" />
|
|
<div id="profile-avatar-edit-layer" class="profile-avatar-edit-layer" hidden="hidden">
|
|
<img id="profile-avatar-edit-img" src="" alt="" draggable="false" />
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div id="profile-avatar-controls" class="profile-avatar-controls" hidden="hidden">
|
|
<label class="profile-avatar-zoom-label" for="profile-avatar-zoom">
|
|
<span>Zoom</span>
|
|
<input type="range" id="profile-avatar-zoom" min="100" max="400" value="100" step="1" />
|
|
</label>
|
|
<p class="muted small-note profile-avatar-drag-hint">Drag the photo to position it inside the circle.</p>
|
|
</div>
|
|
</div>
|
|
<div class="profile-avatar-upload-col">
|
|
<div id="profile-avatar-drop" class="profile-avatar-drop" tabindex="0" role="button" aria-label="Drop image to upload">
|
|
<input type="file" id="profile-avatar-file" accept="image/jpeg,image/png,image/gif,image/webp" class="profile-avatar-file-input" />
|
|
<div class="profile-avatar-drop-inner">
|
|
<i class="fa-solid fa-cloud-arrow-up profile-avatar-drop-icon" aria-hidden="true"></i>
|
|
<p><strong>Drag & drop</strong> an image here, or <span class="profile-avatar-browse">browse</span></p>
|
|
<p class="muted small-note">JPEG, PNG, GIF, WebP · max 5 MB</p>
|
|
</div>
|
|
</div>
|
|
<div class="profile-avatar-actions">
|
|
<button type="button" class="cta-button" id="profile-avatar-upload-btn" disabled="disabled">Upload</button>
|
|
<button type="button" class="btn-danger" id="profile-avatar-remove-btn">Remove photo</button>
|
|
<button type="button" class="btn-muted" id="profile-avatar-back-btn">Back to profile</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</section>
|
|
</div>
|
|
{% endblock %}
|