File tree Expand file tree Collapse file tree 2 files changed +2
-1
lines changed
src/vs/workbench/services/hover/browser Expand file tree Collapse file tree 2 files changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -145,6 +145,7 @@ export interface IHoverOptions {
145
145
* Whether to trap focus in the following ways:
146
146
* - When the hover closes, focus goes to the element that had focus before the hover opened
147
147
* - If there are elements in the hover to focus, focus stays inside of the hover when tabbing
148
+ * Note that this is overridden to true when in screen reader optimized mode.
148
149
*/
149
150
trapFocus ?: boolean ;
150
151
Original file line number Diff line number Diff line change @@ -44,8 +44,8 @@ export class HoverService implements IHoverService {
44
44
}
45
45
this . _currentHoverOptions = options ;
46
46
this . _lastHoverOptions = options ;
47
- // HACK, remove when #189076 is fixed
48
47
const trapFocus = options . trapFocus || this . _accessibilityService . isScreenReaderOptimized ( ) ;
48
+ // HACK, remove this check when #189076 is fixed
49
49
if ( ! skipLastFocusedUpdate ) {
50
50
if ( trapFocus && document . activeElement ) {
51
51
this . _lastFocusedElementBeforeOpen = document . activeElement as HTMLElement ;
You can’t perform that action at this time.
0 commit comments