@@ -4,14 +4,15 @@ import classNames from 'classnames'
4
4
import { CLink , CBadge } from './index'
5
5
import { CIcon } from '@coreui/icons-react'
6
6
import { iconProps } from './CSidebarNavDropdown'
7
- //component - CoreUI / CSidebarNavItem
8
7
8
+ //component - CoreUI / CSidebarNavItem
9
9
const CSidebarNavItem = props => {
10
10
11
11
const {
12
12
children,
13
13
className,
14
14
//
15
+ innerRef,
15
16
name,
16
17
icon,
17
18
fontIcon,
@@ -22,7 +23,6 @@ const CSidebarNavItem = props => {
22
23
} = props
23
24
24
25
//render
25
-
26
26
const classes = classNames (
27
27
'c-sidebar-nav-item' ,
28
28
className
@@ -35,7 +35,7 @@ const CSidebarNavItem = props => {
35
35
36
36
const routerLinkProps = rest . to && { exact : true , activeClassName : 'c-active' }
37
37
return (
38
- < li className = { classes } >
38
+ < li className = { classes } ref = { innerRef } >
39
39
{ children ||
40
40
< CLink
41
41
className = { linkClasses }
@@ -56,6 +56,7 @@ CSidebarNavItem.propTypes = {
56
56
children : PropTypes . node ,
57
57
className : PropTypes . string ,
58
58
//
59
+ innerRef : PropTypes . oneOfType ( [ PropTypes . func , PropTypes . string , PropTypes . object ] ) ,
59
60
icon : PropTypes . oneOfType ( [ PropTypes . string , PropTypes . object ] ) ,
60
61
fontIcon : PropTypes . string ,
61
62
badge : PropTypes . object ,
0 commit comments