mirror of
				https://github.com/Unleash/unleash.git
				synced 2025-10-27 11:02:16 +01:00 
			
		
		
		
	fix: add focus style to vertical tabs (#4186)
https://linear.app/unleash/issue/2-1206/we-need-focus-state-for-vertical-menu Adds a `focus-visible` style to vertical tabs in order to improve keyboard navigation. 
This commit is contained in:
		
							parent
							
								
									6638a2f47d
								
							
						
					
					
						commit
						82d855ea1f
					
				@ -30,7 +30,14 @@ const StyledTab = styled(Button)<{ selected: boolean }>(
 | 
			
		||||
        '&.Mui-disabled': {
 | 
			
		||||
            pointerEvents: 'auto',
 | 
			
		||||
        },
 | 
			
		||||
        '&:focus-visible': {
 | 
			
		||||
            outline: `2px solid ${theme.palette.primary.main}`,
 | 
			
		||||
        },
 | 
			
		||||
        justifyContent: 'space-between',
 | 
			
		||||
        '& > span': {
 | 
			
		||||
            borderTopLeftRadius: 0,
 | 
			
		||||
            borderBottomLeftRadius: 0,
 | 
			
		||||
        },
 | 
			
		||||
    })
 | 
			
		||||
);
 | 
			
		||||
 | 
			
		||||
@ -48,10 +55,8 @@ export const VerticalTab = ({
 | 
			
		||||
    <StyledTab
 | 
			
		||||
        selected={Boolean(selected)}
 | 
			
		||||
        onClick={onClick}
 | 
			
		||||
        disableRipple
 | 
			
		||||
        disableElevation
 | 
			
		||||
        disableFocusRipple
 | 
			
		||||
        disableTouchRipple
 | 
			
		||||
        fullWidth
 | 
			
		||||
    >
 | 
			
		||||
        {label}
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user