Skip to content

Commit

Permalink
Merge pull request #916 from cornell-dti/eric/fix_ui
Browse files Browse the repository at this point in the history
Fixed UI Bugs for QMI Wrapped
  • Loading branch information
rgu0114 authored Dec 19, 2024
2 parents 2b9f742 + df76936 commit bee32f5
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 37 deletions.
42 changes: 18 additions & 24 deletions src/components/includes/TopBarNotifications.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -113,18 +113,29 @@ const TopBarNotifications = (
src={countdownZero && hasWrapped ? ribbonNotif : notification}
alt="Notification icon"
/>
{!hasViewed &&
<img
className="notifications__indicator"
src={notif}
alt="Notification indicator"
/>
}
{!hasViewed && <img className="notifications__indicator" src={notif} alt="Notification indicator" />}
</div>
<div
className={`notifications__dropdown notifications__${dropped ? "visible" : "hidden"}`}
onClick={(e) => e.stopPropagation()}
>
{/* Additional notification when countdownZero is true */}
{hasWrapped && countdownZero && (
<div
onClick={() => handleNotifClick()}
className="notifications__notification"
style={{ backgroundColor: "#DBE8FD", borderRadius: "8px" }}
>
<div className="notification__header">
<div className="notification__title">Queue Me In Wrapped</div>
</div>
<div className="notification__content">
Queue Me In Wrapped has been added to your notifications queue.
You can revisit your office
hour statistics any time by clicking here!
</div>
</div>
)}
{notifications === undefined || (notifications.length === 0 && !countdownZero) ? (
<div className="notification__placeholder">You do not have any notifications</div>
) : (
Expand All @@ -147,23 +158,6 @@ const TopBarNotifications = (
</div>
))
)}
{/* Additional notification when countdownZero is true */}
{hasWrapped && countdownZero && (
<div
onClick={() => handleNotifClick()}
className="notifications__notification"
style={{ backgroundColor: "#DBE8FD", borderRadius: "8px" }}
>
<div className="notification__header">
<div className="notification__title">Queue Me In Wrapped</div>
</div>
<div className="notification__content">
Queue Me In Wrapped has been added to your notifications queue.
You can revisit your office
hour statistics any time by clicking here!
</div>
</div>
)}
</div>
</div>
);
Expand Down
5 changes: 2 additions & 3 deletions src/components/includes/Wrapped.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -506,13 +506,12 @@ const Wrapped= (props: Props): JSX.Element => {
const Visits = () => (
<div>
<div className="visit">

<div style={{ display: "flex", justifyContent: "flex-end", fontWeight: "bold" }}>
<div className="visit top-text">
YOU WORKED SO HARD THIS YEAR!
</div>
<div className="visit mid-text">
<Typography variant="h3">
<Typography variant="h3" style={{ fontWeight: 700 }}>
WITH...
</Typography>
</div>
Expand Down Expand Up @@ -540,7 +539,7 @@ const Wrapped= (props: Props): JSX.Element => {
</div>
</div>
</div>
)
);

const TimeSpent = () => (
<>
Expand Down
20 changes: 10 additions & 10 deletions src/styles/Wrapped.scss
Original file line number Diff line number Diff line change
Expand Up @@ -180,8 +180,8 @@
position: absolute;
top: 3rem;
left: 3rem;
font-weight: 600;
font-size: 27px;
font-size: 35px;
font-weight: bold;
}

&.nums-container{
Expand All @@ -205,19 +205,19 @@
position: absolute;
bottom: 7.5rem;
right: 3rem;
font-weight: 600;
font-size: 27px;
font-size: 35px;
text-align: right;
font-weight: bold;
width: 300px;
}

&.bottom-text{
position: absolute;
bottom: 5rem;
right: 3rem;
font-weight: 600;
font-size: 27px;
font-size: 35px;
text-align: right;
font-weight: bold;
width: 300px;
}
&.smallGirl{
Expand All @@ -241,10 +241,10 @@
}
&.text{
font-weight: bold;
font-size: 2rem;
margin-bottom: 2rem;
line-height: 2.5rem;
text-align: left;
font-size: 35px;
}
&.personalityType {
font-family: "Roboto";
Expand Down Expand Up @@ -275,7 +275,7 @@

&.top-text{
font-weight: bold;
font-size: 27px;
font-size: 35px;
margin-bottom: 2rem;
line-height: 2.5rem;
text-align: left;
Expand Down Expand Up @@ -501,14 +501,14 @@
font-size: 35px;
}
&.center-text {
font-weight: 600;
font-weight: bold;
width: 279px;
height: 71px;
position: absolute;
top: 195px;
left: 270px;
line-height: 40px;
font-size: 27px;
font-size: 35px;
}
}

Expand Down

0 comments on commit bee32f5

Please sign in to comment.