modified: serv_nginx/bbvue/src/views/Profile.vue

try fix with dowble img
This commit is contained in:
2025-10-17 10:48:52 +05:00
parent 27394b1a99
commit 87d0635b49
+4 -8
View File
@@ -10,7 +10,8 @@
<!-- Секция аватара -->
<div class="avatar-section">
<div class="avatar-preview">
<img v-if="user.avatar" :src="avatarUrl" class="avatar-image">
<img v-if="user.avatar && !avatarLoadError" :src="avatarUrl"
:alt="`Аватар ${user.firstName} ${user.lastName}`" class="avatar-image" @error="handleAvatarError">
<div v-else class="avatar-placeholder">
👤
</div>
@@ -652,7 +653,6 @@ export default {
.avatar-section {
margin-bottom: 1.5rem;
}
.avatar-preview {
position: relative;
width: 150px;
@@ -663,6 +663,7 @@ export default {
border: 4px solid #2e8b57;
background: linear-gradient(135deg, #f5f5f5, #e0e0e0);
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
isolation: isolate; /* Новое свойство */
}
.avatar-image {
@@ -670,9 +671,7 @@ export default {
height: 100%;
object-fit: cover;
transition: transform 0.3s ease;
position: absolute;
top: 0;
left: 0;
display: block; /* Убедитесь, что block */
}
.avatar-placeholder {
@@ -684,9 +683,6 @@ export default {
font-size: 4rem;
background: linear-gradient(135deg, #2e8b57, #3cb371);
color: white;
position: absolute;
top: 0;
left: 0;
}
.avatar-image:hover {