auth-users.ts 3.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. // @ts-nocheck
  2. import { RegistryDefinations } from '../types'
  3. export const AUTH_USERS_SHORTCUT_IDS = {
  4. AUTH_USERS_REFRESH: 'auth-users.refresh',
  5. AUTH_USERS_CLEAR_SORT: 'auth-users.clear-sort',
  6. AUTH_USERS_TOGGLE_ALL_SELECTION: 'auth-users.toggle-all-selection',
  7. AUTH_USERS_DELETE_SELECTED: 'auth-users.delete-selected',
  8. AUTH_USERS_EXIT_SELECTION: 'auth-users.exit-selection',
  9. AUTH_USERS_CLOSE_PANEL: 'auth-users.close-panel',
  10. AUTH_USERS_START_NAV_DOWN: 'auth-users.start-nav-down',
  11. AUTH_USERS_START_NAV_UP: 'auth-users.start-nav-up',
  12. AUTH_USERS_CREATE_USER: 'auth-users.create-user',
  13. AUTH_USERS_INVITE_USER: 'auth-users.invite-user',
  14. }
  15. export type AuthUsersShortcutId =
  16. (typeof AUTH_USERS_SHORTCUT_IDS)[keyof typeof AUTH_USERS_SHORTCUT_IDS]
  17. export const authUsersRegistry: RegistryDefinations<AuthUsersShortcutId> = {
  18. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_REFRESH]: {
  19. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_REFRESH,
  20. label: 'Refresh users',
  21. sequence: ['Shift+R'],
  22. showInSettings: false,
  23. options: { ignoreInputs: true, registerInCommandMenu: true },
  24. },
  25. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_CLEAR_SORT]: {
  26. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_CLEAR_SORT,
  27. label: 'Clear sort',
  28. sequence: ['S', 'C'],
  29. showInSettings: false,
  30. options: { ignoreInputs: true, registerInCommandMenu: true },
  31. },
  32. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_TOGGLE_ALL_SELECTION]: {
  33. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_TOGGLE_ALL_SELECTION,
  34. label: 'Toggle selection on all displayed users',
  35. sequence: ['Mod+A'],
  36. showInSettings: false,
  37. options: { ignoreInputs: true },
  38. },
  39. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_DELETE_SELECTED]: {
  40. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_DELETE_SELECTED,
  41. label: 'Delete selected users',
  42. sequence: ['Mod+Backspace'],
  43. showInSettings: false,
  44. options: { ignoreInputs: true },
  45. },
  46. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_EXIT_SELECTION]: {
  47. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_EXIT_SELECTION,
  48. label: 'Clear user selection',
  49. sequence: ['Escape'],
  50. showInSettings: false,
  51. options: { ignoreInputs: true, conflictBehavior: 'allow' },
  52. },
  53. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_CLOSE_PANEL]: {
  54. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_CLOSE_PANEL,
  55. label: 'Close user details panel',
  56. sequence: ['Escape'],
  57. showInSettings: false,
  58. options: { ignoreInputs: true, conflictBehavior: 'allow' },
  59. },
  60. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_START_NAV_DOWN]: {
  61. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_START_NAV_DOWN,
  62. label: 'Move focus into users grid',
  63. sequence: ['ArrowDown'],
  64. showInSettings: false,
  65. options: { ignoreInputs: true },
  66. },
  67. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_START_NAV_UP]: {
  68. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_START_NAV_UP,
  69. label: 'Move focus into users grid',
  70. sequence: ['ArrowUp'],
  71. showInSettings: false,
  72. options: { ignoreInputs: true },
  73. },
  74. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_CREATE_USER]: {
  75. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_CREATE_USER,
  76. label: 'Create new user',
  77. sequence: ['I', 'U'],
  78. showInSettings: false,
  79. options: { ignoreInputs: true, registerInCommandMenu: true },
  80. },
  81. [AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_INVITE_USER]: {
  82. id: AUTH_USERS_SHORTCUT_IDS.AUTH_USERS_INVITE_USER,
  83. label: 'Send user invitation',
  84. sequence: ['I', 'I'],
  85. showInSettings: false,
  86. options: { ignoreInputs: true, registerInCommandMenu: true },
  87. },
  88. }