adapt pictures for EventCards

This commit is contained in:
2026-04-01 23:52:56 +02:00
parent f1798c496b
commit c210aec76f
3 changed files with 18 additions and 13 deletions
+5 -1
View File
@@ -14,7 +14,11 @@
position: relative; position: relative;
justify-content: space-between; justify-content: space-between;
} }
.profileImg{
width:40px;
height:40px;
border-radius: 50%;
}
.activeHeaderContent { .activeHeaderContent {
+4 -2
View File
@@ -23,7 +23,9 @@ function Header() {
const [mobileMenu, setMobileMenu] = useState<boolean>(false); const [mobileMenu, setMobileMenu] = useState<boolean>(false);
const [notifications, setNotifications] = useState<Notification[]>([]); const [notifications, setNotifications] = useState<Notification[]>([]);
const notificationRef = useRef<HTMLDivElement>(null); const notificationRef = useRef<HTMLDivElement>(null);
const profileImageUrl = user?.profile_photo_path
? `${import.meta.env.VITE_API_URL}/storage/${user.profile_photo_path}`
: "/person.svg";
useEffect(() => { useEffect(() => {
if (!user) return; if (!user) return;
@@ -140,7 +142,7 @@ function Header() {
<Link to="/profile" className={styles.profileLink}> <Link to="/profile" className={styles.profileLink}>
<img <img
className={styles.profileImg} className={styles.profileImg}
src={user?.profile_photo_path || "/person.svg"} src={profileImageUrl}
alt="profile" alt="profile"
/> />
</Link> </Link>
@@ -24,23 +24,22 @@
} }
.eventImageDiv { .eventImageDiv {
display: flex; width: 10rem;
align-items: center; height: 7rem;
justify-content: center;
margin-right: 1rem;
width: auto;
height: 6rem;
flex-shrink: 0; flex-shrink: 0;
overflow: hidden;
border-radius: 20px;
margin-right: 1rem;
} }
.eventImage { .eventImage {
max-width: 100%; width: 100%;
max-height: 100%; height: 100%;
object-fit: contain; object-fit: cover;
border-radius: 20px;
} }
.eventContent { .eventContent {
display: flex; display: flex;
width: 100%; width: 100%;