File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
44The format is based on [ Keep a Changelog] ( https://keepachangelog.com/en/1.0.0/ ) ,
55and this project adheres to [ Semantic Versioning] ( https://semver.org/spec/v2.0.0.html ) .
66
7+ # [ 2.2.3]
8+ ## Fixed
9+ - Enhanced native DOM focus behavior by adding and removing the data-focused attribute during focus transitions.
10+
711# [ 2.2.2]
812## Added
913- New export for ` SpatialNavigation ` core service with types
Original file line number Diff line number Diff line change @@ -1451,6 +1451,8 @@ class SpatialNavigationService {
14511451 focusDetails
14521452 ) ;
14531453
1454+ oldComponent . node ?. removeAttribute ?.( 'data-focused' ) ;
1455+
14541456 this . log ( 'setCurrentFocusedKey' , 'onBlur' , oldComponent ) ;
14551457 }
14561458
@@ -1463,6 +1465,8 @@ class SpatialNavigationService {
14631465 newComponent . node . focus ( this . domNodeFocusOptions ) ;
14641466 }
14651467
1468+ newComponent . node ?. setAttribute ?.( 'data-focused' , 'true' ) ;
1469+
14661470 newComponent . onUpdateFocus ( true ) ;
14671471 newComponent . onFocus (
14681472 this . getNodeLayoutByFocusKey ( this . focusKey ) ,
You can’t perform that action at this time.
0 commit comments