File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed
packages/react-core/src/components/Tabs Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,8 @@ export interface TabsProps
4747 children : TabsChild | TabsChild [ ] ;
4848 /** Additional classes added to the tabs */
4949 className ?: string ;
50+ /** Additional inline styles added to the tabs */
51+ style ?: React . CSSProperties ;
5052 /** Tabs background color variant */
5153 variant ?: 'default' | 'secondary' ;
5254 /** The index of the active tab */
@@ -468,6 +470,7 @@ class Tabs extends Component<TabsProps, TabsState> {
468470 render ( ) {
469471 const {
470472 className,
473+ style,
471474 children,
472475 activeKey,
473476 defaultActiveKey,
@@ -576,7 +579,11 @@ class Tabs extends Component<TabsProps, TabsState> {
576579 ) }
577580 { ...getOUIAProps ( Tabs . displayName , ouiaId !== undefined ? ouiaId : this . state . ouiaStateId , ouiaSafe ) }
578581 id = { id && id }
579- style = { { [ linkAccentLength . name ] : currentLinkAccentLength , [ linkAccentStart . name ] : currentLinkAccentStart } }
582+ style = { {
583+ [ linkAccentLength . name ] : currentLinkAccentLength ,
584+ [ linkAccentStart . name ] : currentLinkAccentStart ,
585+ ...style
586+ } }
580587 { ...props }
581588 >
582589 { expandable && isVertical && (
Original file line number Diff line number Diff line change @@ -27,6 +27,7 @@ export const TabsDefault: React.FunctionComponent = () => {
2727 isBox = { isBox }
2828 aria-label = "Tabs in the default example"
2929 role = "region"
30+ style = { { border : '1px solid red' } }
3031 >
3132 < Tab eventKey = { 0 } title = { < TabTitleText > Users</ TabTitleText > } aria-label = "Default content - users" >
3233 Users
You can’t perform that action at this time.
0 commit comments