online
                                
                                
                                
                                    online copied to clipboard
                            
                            
                            
                        Replace magic numbers with keycode constants
This is an Easy Hack. Potential mentors: @eszkadev
Detailed description and rationale
There are directly provided numbers for key codes in some places. We can use already defined constant variables. This makes code more readable and obvious. We don't have to comment every place with human readable label.
Code pointers
Example: instead of 112 -> KeyCode.F1 in https://github.com/CollaboraOnline/online/blob/master/browser/src/map/handler/Map.Keyboard.js#L331
Links to related documentation
Here is example map with number (KeyCode) -> UNOCode binding: https://github.com/CollaboraOnline/online/blob/master/browser/src/map/handler/Map.Keyboard.js#L20
we want something similar but rather:
Name -> KeyCode number like: F1: 112 so later we can use KeyCode.F1 instead of 112
hey can i work on this issue?? we only need to change it to KeyCode.F1??
@eszkadev Please assign it to me. I think this would be doable for me as I am a complete newbie
done with: https://github.com/CollaboraOnline/online/pull/5319
Thanks @callmetushar123