ShowHotkeys.jsx 626 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. import React from 'react';
  2. /**
  3. *
  4. * @export
  5. * @extends {React.Component}
  6. */
  7. export default class ShowHotkeys extends React.Component {
  8. // when this is called it returns the hotkey stroke
  9. static getHotkeyStroke() {
  10. return {
  11. stroke: ['/'],
  12. ctrlKey: true,
  13. metaKey: true,
  14. altKey: false,
  15. shiftKey: false,
  16. };
  17. }
  18. static getComponent() {
  19. return <ShowHotkeys />;
  20. }
  21. componentDidMount() {
  22. // show modal to create a page
  23. $('#shortcuts-modal').modal('toggle');
  24. return null;
  25. }
  26. render() {
  27. return (
  28. <React.Fragment>
  29. </React.Fragment>
  30. );
  31. }
  32. }