mirror of
https://github.com/fofolee/uTools-quickcommand.git
synced 2025-06-07 21:46:12 +08:00
修复收藏文件、网址的bug
This commit is contained in:
parent
1770f27725
commit
413d89183a
@ -2,7 +2,7 @@
|
||||
export default {
|
||||
mounted() {
|
||||
utools.setExpendHeight(0);
|
||||
this.$root.payload.forEach((file) => {
|
||||
this.$root.enterData.payload.forEach((file) => {
|
||||
let uid = this.getUid();
|
||||
let fileInfo = window.getFileInfo({
|
||||
type: "file",
|
||||
|
@ -24,7 +24,7 @@ export default {
|
||||
);
|
||||
url = choise.text + "://" + url;
|
||||
}
|
||||
let title = this.$root.payload.title
|
||||
let title = this.$root.enterData.payload.title
|
||||
.replace(/和另外 \d+ 个页面.*/, "")
|
||||
.replace(/[-|—] .*?[Edge|Firefox|Chrome].*/, "")
|
||||
.trim();
|
||||
@ -39,7 +39,7 @@ export default {
|
||||
let uid = this.getUid();
|
||||
let command = {
|
||||
features: {
|
||||
explain: `访问${title}`,
|
||||
explain: title,
|
||||
cmds: [title],
|
||||
platform: ["linux", "win32", "darwin"],
|
||||
code: `key_${uid}`,
|
||||
@ -51,7 +51,7 @@ export default {
|
||||
};
|
||||
try {
|
||||
let res = await quickcommand.downloadFile(iconUrl, iconPath);
|
||||
if (res) command.features.icon = iconPath;
|
||||
if (res) command.features.icon = window.getBase64Ico(iconPath);
|
||||
} catch (e) {}
|
||||
this.importCommand(command);
|
||||
utools.showNotification("操作成功!");
|
||||
|
Loading…
x
Reference in New Issue
Block a user