Skip to content

Commit

Permalink
BACKLOG-21345: Add data attribute for tree item depth
Browse files Browse the repository at this point in the history
  • Loading branch information
gflores-jahia committed Dec 19, 2023
1 parent 3d0d1fa commit 478effa
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/components/TreeView/ControlledTreeView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ const ControlledTreeViewForwardRef: React.ForwardRefRenderFunction<HTMLUListElem
'aria-expanded': isOpen,
'aria-busy': isLoading,
'aria-current': isHighlighted ? 'page' : null,
'data-treeItem-depth': depth,
key: `${depth}-${node.id}`,
style: {'--treeItem-depth': depth},
...node.treeItemProps
Expand Down

0 comments on commit 478effa

Please # to comment.