From 1a2da59cedd4ac93c865d05a6450fb82a81a9f62 Mon Sep 17 00:00:00 2001 From: Anton Date: Thu, 1 Feb 2024 21:34:07 +0300 Subject: [PATCH] fix(GoalListItem): keyboard hover --- src/components/GoalListItem/GoalListItem.module.css | 2 +- src/components/GoalListItem/GoalListItem.tsx | 5 +++-- src/components/GoalTableList/GoalTableList.tsx | 3 ++- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/components/GoalListItem/GoalListItem.module.css b/src/components/GoalListItem/GoalListItem.module.css index bfbce89b0..083271542 100644 --- a/src/components/GoalListItem/GoalListItem.module.css +++ b/src/components/GoalListItem/GoalListItem.module.css @@ -10,7 +10,7 @@ color: var(--text-secondary); } -.Row:hover { +.Row_hovered, .Row:hover { border: 1px solid var(--layer-border-hover); background: var(--layer-hover); } diff --git a/src/components/GoalListItem/GoalListItem.tsx b/src/components/GoalListItem/GoalListItem.tsx index 56f4471f1..d79e4bb4d 100644 --- a/src/components/GoalListItem/GoalListItem.tsx +++ b/src/components/GoalListItem/GoalListItem.tsx @@ -6,13 +6,14 @@ import s from './GoalListItem.module.css'; interface GoalListItemProps extends HTMLAttributes { selected?: boolean; + hovered?: boolean; className?: string; onClick?: MouseEventHandler; } -export const GoalListItem: FC = ({ children, selected, className, ...rest }) => { +export const GoalListItem: FC = ({ children, selected, hovered, className, ...rest }) => { return ( - + {children} ); diff --git a/src/components/GoalTableList/GoalTableList.tsx b/src/components/GoalTableList/GoalTableList.tsx index 6d7aa5e69..329c85083 100644 --- a/src/components/GoalTableList/GoalTableList.tsx +++ b/src/components/GoalTableList/GoalTableList.tsx @@ -140,7 +140,8 @@ export const GoalTableList = > renderItem={({ active, hovered: _, ...props }) => ( {row.list.map(({ content, width, className }, index) => (