diff --git a/src/components/catalog/views/navigation/CatalogNavigationItemView.tsx b/src/components/catalog/views/navigation/CatalogNavigationItemView.tsx index b855caa6..9179edba 100644 --- a/src/components/catalog/views/navigation/CatalogNavigationItemView.tsx +++ b/src/components/catalog/views/navigation/CatalogNavigationItemView.tsx @@ -1,5 +1,5 @@ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; -import { FC, useRef } from 'react'; +import { FC } from 'react'; import { ICatalogNode } from '../../../../api'; import { Base, LayoutGridItem, Text } from '../../../../common'; import { useCatalog } from '../../../../hooks'; @@ -16,18 +16,10 @@ export const CatalogNavigationItemView: FC = pro { const { node = null, child = false } = props; const { activateNode = null } = useCatalog(); - const elementRef = useRef(); - - const selectNode = () => - { - if(node.isBranch && !node.isActive) elementRef?.current?.scrollIntoView(); - - activateNode(node); - } return ( - - + + activateNode(node) } className={ child ? 'inset' : '' }> { node.localization } { node.isBranch &&