sdkjs-plugins icon indicating copy to clipboard operation
sdkjs-plugins copied to clipboard

Unable to add keyboard listening event

Open WarmSally opened this issue 3 years ago • 5 comments

Excuse me, I want to add the monitoring of keyboard function keys to formulate some special behaviors, but I can't find the corresponding API on the official website.I want to ask if the existing API supports listening for keyboard events

WarmSally avatar Apr 07 '21 07:04 WarmSally

For example, I want to listen for the Enter key,I tried two ways the first,I use the API provided by the official website to monitor character input,

window.Asc.plugin.event_onInputHelperInput = function(data){
}

the second,I use the ‘document.addEventListener’ to monitor keyboard pressed events; But neither method worked

WarmSally avatar Apr 07 '21 07:04 WarmSally

@askonev Please take a look

ShockwaveNN avatar Apr 07 '21 09:04 ShockwaveNN

I also encountered the same problem, please help to solve it

bxja avatar Apr 08 '21 09:04 bxja

@WarmSally @bxja

Unfortunately, this functionality does not exist at the moment, but I started an enhancement bug №49548 to add these methods. Thank you for your idea and for improving the ONLYOFFICE project.

askonev avatar Apr 08 '21 12:04 askonev

Thanks for your help

WarmSally avatar Apr 09 '21 03:04 WarmSally