File tree Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Original file line number Diff line number Diff line change @@ -77,7 +77,7 @@ export class Grid {
7777 } ) ;
7878
7979 /** Whether the focus is in the grid. */
80- private readonly _hasFocus = signal ( false ) ;
80+ private readonly _isFocused = signal ( false ) ;
8181
8282 constructor ( ) {
8383 afterRenderEffect ( ( ) => {
@@ -86,7 +86,7 @@ export class Grid {
8686
8787 afterRenderEffect ( ( ) => {
8888 const activeCell = this . pattern . activeCell ( ) ;
89- const hasFocus = untracked ( ( ) => this . _hasFocus ( ) ) ;
89+ const hasFocus = untracked ( ( ) => this . _isFocused ( ) ) ;
9090 const isRoving = this . focusMode ( ) === 'roving' ;
9191 if ( activeCell !== undefined && isRoving && hasFocus ) {
9292 activeCell . element ( ) . focus ( ) ;
@@ -96,12 +96,12 @@ export class Grid {
9696
9797 /** Handles focusin events on the grid. */
9898 onFocusIn ( ) {
99- this . _hasFocus . set ( true ) ;
99+ this . _isFocused . set ( true ) ;
100100 }
101101
102102 /** Handles focusout events on the grid. */
103103 onFocusOut ( ) {
104- this . _hasFocus . set ( false ) ;
104+ this . _isFocused . set ( false ) ;
105105 }
106106
107107 /** Gets the cell pattern for a given element. */
Original file line number Diff line number Diff line change @@ -122,13 +122,9 @@ export class GridPattern {
122122 const manager = new PointerEventManager ( ) ;
123123
124124 if ( this . inputs . enableSelection ( ) ) {
125- manager
126- . on ( ( ) => {
127- this . dragging . set ( false ) ;
128- } )
129- . on ( Modifier . Shift , ( ) => {
130- this . dragging . set ( false ) ;
131- } ) ;
125+ manager . on ( [ Modifier . Shift , Modifier . None ] , ( ) => {
126+ this . dragging . set ( false ) ;
127+ } ) ;
132128 }
133129
134130 return manager ;
You can’t perform that action at this time.
0 commit comments