-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add upload menu shortcuts #1529
Conversation
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
This comment was marked as resolved.
This comment was marked as resolved.
b6f978a
to
ec7069e
Compare
ec7069e
to
9ec5f71
Compare
@@ -32,38 +32,11 @@ window._oc_capabilities = { files: {} } | |||
|
|||
// Example use: | |||
// cy.mount(MyComponent) | |||
Cypress.Commands.add('mount', (component, optionsOrProps) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See Ferdinand's comment on this: nextcloud/server#48725 (comment)
onKeyDown(event: KeyboardEvent) { | ||
// Shift + u opens the menu | ||
if (event.key === 'u') { | ||
// If we have a menu, open it | ||
if (this.haveMenu) { | ||
this.openedMenu = true | ||
return | ||
} | ||
|
||
// Otherwise, trigger the default action | ||
this.onTriggerPick() | ||
} | ||
|
||
if (event.key === 'Escape' && this.openedMenu) { | ||
this.openedMenu = false | ||
} | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The important part
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review based on the "important part" 🚀
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
9ec5f71
to
42269c4
Compare
Subset of nextcloud/server#30484
Follow-up of nextcloud/server#49432