@@ -851,7 +851,7 @@ function injectStyle() {
851851 body.yui-taking-over.yui-user-cursor-revealed #${ ROOT_ID } .yui-guide-plugin-backdrop,
852852 body.yui-taking-over.yui-user-cursor-revealed #${ ROOT_ID } .yui-guide-plugin-backdrop *,
853853 body.yui-taking-over.yui-user-cursor-revealed #${ ROOT_ID } .yui-guide-plugin-interaction-shield,
854- body.yui-taking-over.yui-user-cursor-revealed #${ ROOT_ID } .yui-guide-plugin-spotlight, {
854+ body.yui-taking-over.yui-user-cursor-revealed #${ ROOT_ID } .yui-guide-plugin-spotlight {
855855 cursor: auto !important;
856856 }
857857
@@ -1148,6 +1148,7 @@ class PluginDashboardGuideRuntime {
11481148 lastForwardedSkipScreenX = NaN
11491149 lastForwardedSkipScreenY = NaN
11501150 spotlightRefreshRaf : number | null = null
1151+ cursorClickResetTimer : number | null = null
11511152 boundPointerMoveHandler = ( event : PointerEvent | MouseEvent ) => {
11521153 this . handleInterrupt ( event )
11531154 }
@@ -2031,10 +2032,34 @@ class PluginDashboardGuideRuntime {
20312032 }
20322033
20332034 clickCursor ( durationMs = DEFAULT_CURSOR_CLICK_VISIBLE_MS ) {
2034- void durationMs
2035+ if ( this . cursorClickResetTimer !== null ) {
2036+ window . clearTimeout ( this . cursorClickResetTimer )
2037+ this . cursorClickResetTimer = null
2038+ }
2039+ this . root ?. setAttribute ( 'data-yui-cursor-hidden' , 'true' )
2040+ this . spotlight ?. setAttribute ( 'data-yui-cursor-hidden' , 'true' )
2041+ document . documentElement . classList . add ( 'yui-user-cursor-revealed' )
2042+ document . body . classList . add ( 'yui-user-cursor-revealed' )
2043+ document . documentElement . classList . add ( 'yui-taking-over' )
2044+ document . body . classList . add ( 'yui-taking-over' )
2045+ this . cursorClickResetTimer = window . setTimeout ( ( ) => {
2046+ this . cursorClickResetTimer = null
2047+ this . resetCursorVisualState ( )
2048+ } , Math . max ( 0 , durationMs ) )
20352049 }
20362050
2037- resetCursorVisualState ( ) { }
2051+ resetCursorVisualState ( ) {
2052+ if ( this . cursorClickResetTimer !== null ) {
2053+ window . clearTimeout ( this . cursorClickResetTimer )
2054+ this . cursorClickResetTimer = null
2055+ }
2056+ this . root ?. removeAttribute ( 'data-yui-cursor-hidden' )
2057+ this . spotlight ?. removeAttribute ( 'data-yui-cursor-hidden' )
2058+ if ( ! this . userCursorRevealed ) {
2059+ document . documentElement . classList . remove ( 'yui-user-cursor-revealed' )
2060+ document . body . classList . remove ( 'yui-user-cursor-revealed' )
2061+ }
2062+ }
20382063
20392064 stopGhostCursorAnimation ( ) {
20402065 this . cancelCursorMotion ( )
0 commit comments