Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/components/NotificationRow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,13 @@ import { NotificationHeader } from './notification/NotificationHeader';

interface INotificationRow {
notification: Notification;
isAnimated?: boolean;
isRead?: boolean;
}

export const NotificationRow: FC<INotificationRow> = ({
notification,
isAnimated = false,
isRead = false,
}: INotificationRow) => {
const {
Expand Down Expand Up @@ -88,10 +90,9 @@ export const NotificationRow: FC<INotificationRow> = ({
id={notification.id}
className={cn(
'group flex border-b border-gray-100 bg-white px-3 py-2 hover:bg-gray-100 dark:border-gray-darker dark:bg-gray-dark dark:text-white dark:hover:bg-gray-darker',
animateExit &&
(isAnimated || animateExit) &&
'translate-x-full opacity-0 transition duration-[350ms] ease-in-out',
showAsRead && Opacity.READ,
isRead && Opacity.READ,
(isRead || showAsRead) && Opacity.READ,
)}
>
<div
Expand Down
1 change: 1 addition & 0 deletions src/components/RepositoryNotifications.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ export const RepositoryNotifications: FC<IRepositoryNotifications> = ({
<NotificationRow
key={notification.id}
notification={notification}
isAnimated={animateExit}
isRead={showAsRead}
/>
))}
Expand Down