File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
src/components/DatasetDetailPage/FileTree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -123,12 +123,10 @@ const FileTreeRow: React.FC<Props> = ({
123123 const externalUrl = node . link ?. url ;
124124
125125 const rowRef = React . useRef < HTMLDivElement | null > ( null ) ;
126- // Highlight only if this row is exactly the subject folder (e.g., "sub-04")
127- // const isSubjectFolder =
128- // node.kind === "folder" && /^sub-[A-Za-z0-9]+$/i.test(node.name);
126+ // Highlight only if this row is exactly the same as the focus highlightText
129127 const isExactHit =
130- ! ! highlightText &&
131- node . name . trim ( ) . toLowerCase ( ) === highlightText . trim ( ) . toLowerCase ( ) ;
128+ node . name . trim ( ) . toLowerCase ( ) ===
129+ ( highlightText ?? "" ) . trim ( ) . toLowerCase ( ) ;
132130
133131 React . useEffect ( ( ) => {
134132 if ( isExactHit && rowRef . current ) {
You can’t perform that action at this time.
0 commit comments