diff --git a/packages/x-tree-view/src/internals/plugins/useTreeViewFocus/useTreeViewFocus.ts b/packages/x-tree-view/src/internals/plugins/useTreeViewFocus/useTreeViewFocus.ts index 53c7d132503c..7f579a85adf9 100644 --- a/packages/x-tree-view/src/internals/plugins/useTreeViewFocus/useTreeViewFocus.ts +++ b/packages/x-tree-view/src/internals/plugins/useTreeViewFocus/useTreeViewFocus.ts @@ -7,7 +7,7 @@ import { UseTreeViewFocusSignature } from './useTreeViewFocus.types'; import { useInstanceEventHandler } from '../../hooks/useInstanceEventHandler'; import { getActiveElement } from '../../utils/utils'; import { getFirstNavigableItem } from '../../utils/tree'; -import {MuiCancellableEvent} from "../../models/MuiCancellableEvent"; +import { MuiCancellableEvent } from '../../models/MuiCancellableEvent'; const useTabbableItemId = ( instance: TreeViewUsedInstance, @@ -130,7 +130,8 @@ export const useTreeViewFocus: TreeViewPlugin = ({ }); const createRootHandleFocus = - (otherHandlers: EventHandlers) => (event: React.FocusEvent & MuiCancellableEvent) => { + (otherHandlers: EventHandlers) => + (event: React.FocusEvent & MuiCancellableEvent) => { otherHandlers.onFocus?.(event); if (event.defaultMuiPrevented) { return;