M
M
MagicMight2020-05-21 12:56:17
React
MagicMight, 2020-05-21 12:56:17

How to highlight column and row on hover in React + Ant Design?

I use the Ant Design component library. In library tables, by default, hovering highlights the row that the mouse is hovering over. Does the library itself have a way to add highlighting for both columns and rows so that the cursor is at the intersection?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
H
hzzzzl, 2020-05-21
@hzzzzl

I just recently highlighted the columns through data-attributes, in the Reakt state it will be even easier to find out the position of the column / row by index in the array
How to highlight the corresponding. column?
I won’t say about “Does the library itself have a way”, but in general it is quite solvable, onMouseEnter you add classes

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question