P粉7978557902023-09-04 00:29:16
<Tree.DirectoryTree className="custom-tree"> {data.map((item) => { return ( <Tree.TreeNode // @ts-ignore item={item} icon={<></>} key={item.user_folder_id} title={item.title} > {item?.data.map((node) => { return ( <Tree.TreeNode node={node} key={node.node_id} title={ node.title } ></Tree.TreeNode> ); })} </Tree.TreeNode> ); })} </Tree.DirectoryTree>
styles.less
.custom-tree .ant-tree-treenode:hover::before {
background: blue !important;
}