File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -138,6 +138,7 @@ export const UnderlineNav = forwardRef(
138138 sx : sxProp = defaultSxProp ,
139139 loadingCounters = false ,
140140 children,
141+ ...props
141142 } : UnderlineNavProps ,
142143 forwardedRef ,
143144 ) => {
@@ -175,7 +176,7 @@ export const UnderlineNav = forwardRef(
175176 // This is the case where the viewport is too narrow to show any list item with the more menu. In this case, we only show the dropdown
176177 const onlyMenuVisible = responsiveProps . items . length === 0
177178
178- if ( __DEV__ ) {
179+ if ( __DEV__ && process . env . NODE_ENV !== 'test' ) {
179180 // Practically, this is not a conditional hook, it is just making sure this hook runs only on DEV not PROD.
180181 // eslint-disable-next-line react-hooks/rules-of-hooks
181182 useEffect ( ( ) => {
@@ -308,6 +309,7 @@ export const UnderlineNav = forwardRef(
308309 sx = { merge < BetterSystemStyleObject > ( getNavStyles ( theme ) , sxProp ) }
309310 aria-label = { ariaLabel }
310311 ref = { navRef }
312+ { ...props }
311313 >
312314 < NavigationList sx = { ulStyles } ref = { listRef } role = "list" >
313315 { listItems . map ( listItem => {
You can’t perform that action at this time.
0 commit comments