Skip to content

Commit

Permalink
chore: change list row text color props
Browse files Browse the repository at this point in the history
  • Loading branch information
gahyuun committed Jun 8, 2024
1 parent 2a492f6 commit 79dc2e7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/ui/lecture/lecture-search/lecture-search-result.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export default function LectureSearchResult() {
const render = (item: SearchLectures, index: number) => {
const searchLectureItem = item;
return (
<List.Row data-cy={`lecture-${searchLectureItem.name}`} key={index} textColor={item.revoked ? 'red' : 'black'}>
<List.Row data-cy={`lecture-${searchLectureItem.name}`} key={index} textColor={item.revoked ? 'gray' : 'black'}>
<Grid cols={4}>
{Object.keys(searchLectureItem).map((key, index) => {
if (key === 'id' || key === 'taken' || key === 'revoked') return null;
Expand Down
4 changes: 2 additions & 2 deletions app/ui/view/molecule/list/list-row.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { twMerge } from 'tailwind-merge';

interface ListRowProps extends React.HTMLAttributes<HTMLDivElement> {
children: ReactNode;
textColor?: 'red' | 'black';
textColor?: 'gray' | 'black';
}

export function ListRow({ children, textColor = 'black', ...props }: ListRowProps) {
Expand All @@ -12,7 +12,7 @@ export function ListRow({ children, textColor = 'black', ...props }: ListRowProp
{...props}
className={twMerge(
'border-solid border-gray-300 border-b-[1px] last:border-b-0 py-4 font-medium text-sm xl:text-base 2xl:text-lg hover:bg-gray-100 group hover:first:rounded-t-xl hover:last:rounded-b-xl',
textColor === 'red' ? 'text-zinc-400' : 'text-zinc-700',
textColor === 'gray' ? 'text-zinc-400' : 'text-zinc-700',
)}
>
{children}
Expand Down

0 comments on commit 79dc2e7

Please sign in to comment.