@@ -192,20 +192,55 @@
|
||||
</div>
|
||||
<div slot="body">
|
||||
<div>
|
||||
<kbd>{{ getSpecialKey() }}</kbd>
|
||||
+
|
||||
<kbd>G</kbd>
|
||||
<label>{{ $t("send_request") }}</label>
|
||||
<kbd>{{ getSpecialKey() }} G</kbd>
|
||||
</div>
|
||||
<div>
|
||||
<kbd>{{ getSpecialKey() }}</kbd
|
||||
>+<kbd>S</kbd>
|
||||
<label>{{ $t("save_to_collections") }}</label>
|
||||
<kbd>{{ getSpecialKey() }} S</kbd>
|
||||
</div>
|
||||
<div>
|
||||
<kbd>{{ getSpecialKey() }}</kbd
|
||||
>+<kbd>K</kbd>
|
||||
<label>{{ $t("copy_request_link") }}</label>
|
||||
<kbd>{{ getSpecialKey() }} K</kbd>
|
||||
</div>
|
||||
<div>
|
||||
<kbd>{{ getSpecialKey() }}</kbd
|
||||
>+<kbd>L</kbd>
|
||||
<label>{{ $t("reset_request") }}</label>
|
||||
<kbd>{{ getSpecialKey() }} L</kbd>
|
||||
</div>
|
||||
<hr />
|
||||
<div>
|
||||
<kbd>Alt</kbd>+<kbd>🠋</kbd>
|
||||
<label>{{ $t("select_next_method") }}</label>
|
||||
</div>
|
||||
<div>
|
||||
<kbd>Alt</kbd>+<kbd>🠉</kbd>
|
||||
<label>{{ $t("select_previous_method") }}</label>
|
||||
</div>
|
||||
<hr />
|
||||
<div>
|
||||
<kbd>Alt</kbd>+<kbd>G</kbd>
|
||||
<label>{{ $t("select_get_method") }}</label>
|
||||
</div>
|
||||
<div>
|
||||
<kbd>Alt</kbd>+<kbd>H</kbd>
|
||||
<label>{{ $t("select_head_method") }}</label>
|
||||
</div>
|
||||
<div>
|
||||
<kbd>Alt</kbd>+<kbd>P</kbd>
|
||||
<label>{{ $t("select_post_method") }}</label>
|
||||
</div>
|
||||
<div>
|
||||
<kbd>Alt</kbd>+<kbd>U</kbd>
|
||||
<label>{{ $t("select_put_method") }}</label>
|
||||
</div>
|
||||
<div>
|
||||
<kbd>Alt</kbd>+<kbd>X</kbd>
|
||||
<label>{{ $t("select_delete_method") }}</label>
|
||||
</div>
|
||||
</div>
|
||||
<div slot="footer"></div>
|
||||
|
||||
@@ -295,5 +295,12 @@
|
||||
"are_you_sure_remove_collection": "Are you sure you want to remove this Collection?",
|
||||
"are_you_sure_remove_folder": "Are you sure you want to remove this folder?",
|
||||
"are_you_sure_remove_request": "Are you sure you want to remove this request?",
|
||||
"are_you_sure_remove_environment": "Are you sure you want to remove this environment?"
|
||||
"are_you_sure_remove_environment": "Are you sure you want to remove this environment?",
|
||||
"select_next_method": "Select Next method",
|
||||
"select_previous_method": "Select Previous method",
|
||||
"select_get_method": "Select GET method",
|
||||
"select_head_method": "Select HEAD method",
|
||||
"select_post_method": "Select POST method",
|
||||
"select_put_method": "Select PUT method",
|
||||
"select_delete_method": "Select DELETE method"
|
||||
}
|
||||
|
||||
@@ -9,11 +9,12 @@
|
||||
<span class="select-wrapper">
|
||||
<v-popover>
|
||||
<input
|
||||
v-if="!customMethod"
|
||||
id="method"
|
||||
class="method"
|
||||
v-if="!customMethod"
|
||||
v-model="method"
|
||||
readonly
|
||||
autofocus
|
||||
/>
|
||||
<input v-else v-model="method" placeholder="CUSTOM" />
|
||||
<template slot="popover">
|
||||
@@ -1349,13 +1350,25 @@ export default {
|
||||
filenames: "",
|
||||
navigatorShare: navigator.share,
|
||||
runningRequest: false,
|
||||
|
||||
settings: {
|
||||
SCROLL_INTO_ENABLED:
|
||||
typeof this.$store.state.postwoman.settings.SCROLL_INTO_ENABLED !== "undefined"
|
||||
? this.$store.state.postwoman.settings.SCROLL_INTO_ENABLED
|
||||
: true,
|
||||
},
|
||||
currentMethodIndex: 0,
|
||||
methodMenuItems: [
|
||||
"GET",
|
||||
"HEAD",
|
||||
"POST",
|
||||
"PUT",
|
||||
"DELETE",
|
||||
"CONNECT",
|
||||
"OPTIONS",
|
||||
"TRACE",
|
||||
"PATCH",
|
||||
"CUSTOM",
|
||||
],
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
@@ -2687,20 +2700,44 @@ export default {
|
||||
} else {
|
||||
this.cancelRequest()
|
||||
}
|
||||
} else if (e.key === "s" && (e.ctrlKey || e.metaKey)) {
|
||||
}
|
||||
if (e.key === "s" && (e.ctrlKey || e.metaKey)) {
|
||||
e.preventDefault()
|
||||
this.saveRequest()
|
||||
} else if (e.key === "k" && (e.ctrlKey || e.metaKey)) {
|
||||
}
|
||||
if (e.key === "k" && (e.ctrlKey || e.metaKey)) {
|
||||
e.preventDefault()
|
||||
this.copyRequest()
|
||||
} else if (e.key === "j" && (e.ctrlKey || e.metaKey)) {
|
||||
}
|
||||
if (e.key === "j" && (e.ctrlKey || e.metaKey)) {
|
||||
e.preventDefault()
|
||||
this.$refs.clearAll.click()
|
||||
} else if (e.key === "Escape") {
|
||||
}
|
||||
if (e.key === "Escape") {
|
||||
e.preventDefault()
|
||||
this.showModal = this.showTokenList = this.showTokenRequestList = this.showRequestModal = false
|
||||
this.isHidden = true
|
||||
}
|
||||
if ((e.key === "g" || e.key === "G") && e.altKey) {
|
||||
this.method = "GET"
|
||||
}
|
||||
if ((e.key === "h" || e.key === "H") && e.altKey) {
|
||||
this.method = "HEAD"
|
||||
}
|
||||
if ((e.key === "p" || e.key === "P") && e.altKey) {
|
||||
this.method = "POST"
|
||||
}
|
||||
if ((e.key === "u" || e.key === "U") && e.altKey) {
|
||||
this.method = "PUT"
|
||||
}
|
||||
if ((e.key === "x" || e.key === "x") && e.altKey) {
|
||||
this.method = "DELETE"
|
||||
}
|
||||
if (e.key == "ArrowUp" && e.altKey && this.currentMethodIndex > 0) {
|
||||
this.method = this.methodMenuItems[--this.currentMethodIndex % this.methodMenuItems.length]
|
||||
} else if (e.key == "ArrowDown" && e.altKey && this.currentMethodIndex < 9) {
|
||||
this.method = this.methodMenuItems[++this.currentMethodIndex % this.methodMenuItems.length]
|
||||
}
|
||||
}
|
||||
document.addEventListener("keydown", this._keyListener.bind(this))
|
||||
await this.oauthRedirectReq()
|
||||
|
||||
Reference in New Issue
Block a user