fix: list item interactions on share

This commit is contained in:
Ramires Viana 2021-03-25 15:47:49 +00:00
parent c0d85f3d85
commit 87f1881b42
4 changed files with 8 additions and 10 deletions

View File

@ -56,6 +56,12 @@ export default {
let prompt = this.$refs.currentComponent; let prompt = this.$refs.currentComponent;
// Esc!
if (event.keyCode === 27) {
event.stopImmediatePropagation();
this.$store.commit("closeHovers");
}
// Enter // Enter
if (event.keyCode == 13) { if (event.keyCode == 13) {
switch (this.show) { switch (this.show) {

View File

@ -34,7 +34,7 @@
} }
.share__box__info { .share__box__info {
flex: 1 1 auto; flex: 1 1 18em;
} }
.share__box__element { .share__box__element {

View File

@ -25,6 +25,7 @@
transition: .1s ease background, .1s ease opacity; transition: .1s ease background, .1s ease opacity;
align-items: center; align-items: center;
cursor: pointer; cursor: pointer;
user-select: none;
} }
#listing .item div:last-of-type { #listing .item div:last-of-type {

View File

@ -124,15 +124,6 @@ export default {
} }
}, },
keyEvent(event) { keyEvent(event) {
if (this.show !== null) {
// Esc!
if (event.keyCode === 27) {
this.$store.commit("closeHovers");
}
return;
}
// F1! // F1!
if (event.keyCode === 112) { if (event.keyCode === 112) {
event.preventDefault(); event.preventDefault();