File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import React, {
55 ReactNode ,
66 isValidElement ,
77 ReactElement ,
8+ HtmlHTMLAttributes ,
89} from 'react' ;
910import { Text } from '../content' ;
1011import { css } from '@emotion/core' ;
@@ -114,21 +115,24 @@ type TabPaneChildFCProps = { isSelected: boolean };
114115 * Function component child for lazy loading support. See storybook
115116 */
116117type TabPaneChildFC = ( props : TabPaneChildFCProps ) => ReactNode ;
117- type TabPaneProps = {
118+ interface TabPaneProps
119+ extends Omit < HtmlHTMLAttributes < HTMLDivElement > , 'children' > {
118120 name : string ;
119121 children : ReactNode | TabPaneChildFC ;
120122 className ?: string ;
121- } ;
123+ }
122124
123125export const TabPane = ( {
124126 name,
125127 children,
126128 className,
127129 isSelected = false ,
130+ ...divProps
128131} : TabPaneProps & { isSelected ?: boolean } ) => {
129132 return (
130133 < div
131134 data-tab-name = { name }
135+ { ...divProps }
132136 hidden = { ! isSelected }
133137 role = "tabpanel"
134138 className = { className }
You can’t perform that action at this time.
0 commit comments