fix(dashboard): hero-аватар показывает загруженную картинку, а не только инициалы

This commit is contained in:
Maxim Dolgolyov
2026-06-01 10:00:46 +03:00
parent 7d478c1c1b
commit 2d83896a9a
+2 -2
View File
@@ -1874,8 +1874,8 @@
if (!user) throw new Error('Not logged in');
document.getElementById('user-name').textContent = user?.name?.split(' ')[0] || 'Студент';
document.getElementById('dh-avatar').textContent =
(user?.name || 'LS').split(' ').slice(0, 2).map(w => w[0]?.toUpperCase() || '').join('') || 'LS';
// Hero-аватар: загруженная картинка (avatar_url) или инициалы — как в сайдбаре
LS.renderNavAvatar(document.getElementById('dh-avatar'), user);
LS.showBoardIfAllowed();
if (isTeacher) {
document.getElementById('btn-admin').style.display = '';