diff --git a/public/preload.js b/public/preload.js
index 0793215..83305a3 100644
--- a/public/preload.js
+++ b/public/preload.js
@@ -246,15 +246,6 @@ window.pluginInfo = () => {
return JSON.parse(fs.readFileSync(path.join(__dirname, 'plugin.json')))
}
-
-let GetFilePath = (Path, File) => {
- if (utools.isDev()) {
- return path.join(__dirname, Path, File)
- } else {
- return path.join(__dirname.replace(/([a-zA-Z0-9\-]+\.asar)/, '$1.unpacked'), Path, File)
- }
-}
-
let getSleepCodeByShell = ms => {
var cmd, tempFilePath
if (utools.isWindows()) {
diff --git a/src/App.vue b/src/App.vue
index 7de9bc0..4ae5f70 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -67,4 +67,14 @@ export default defineComponent({
--q-dark: #303133;
--q-dark-page: #303133;
}
+.commandLogo {
+ cursor: pointer;
+ transition: 0.2s;
+ filter: drop-shadow(2px 1px 1px grey);
+}
+.commandLogo:hover {
+ transition: 0.5s;
+ transform: translateY(-5px);
+ filter: drop-shadow(2px 1px 5px grey);
+}
diff --git a/src/components/CommandEditor.vue b/src/components/CommandEditor.vue
index d4fa441..9d817a9 100644
--- a/src/components/CommandEditor.vue
+++ b/src/components/CommandEditor.vue
@@ -145,10 +145,22 @@
ref="editor"
:style="{
top: languageBarHeight + 'px',
- left: this.action.type === 'run' ? '0' : sideBarWidth + 'px',
+ left: editorLeft,
transition: '0.3s',
}"
/>
+
+ ctrl + s 保存
+ ctrl + b 运行
+ alt + z 自动换行
+
@@ -205,6 +217,9 @@ export default {
"搜索结果"
);
},
+ editorLeft() {
+ return this.action.type === "run" ? "0" : this.sideBarWidth + "px";
+ },
},
created() {},
methods: {
diff --git a/src/components/CommandSideBar.vue b/src/components/CommandSideBar.vue
index 795fa7c..d3e8a97 100644
--- a/src/components/CommandSideBar.vue
+++ b/src/components/CommandSideBar.vue
@@ -234,6 +234,7 @@
(currentCommand.features.icon = dataUrl)"
+ position="left"
ref="icon"
/>
@@ -395,15 +396,3 @@ export default {
},
};
-
-
diff --git a/src/components/ConfigurationMenu.vue b/src/components/ConfigurationMenu.vue
index afb5189..df75527 100644
--- a/src/components/ConfigurationMenu.vue
+++ b/src/components/ConfigurationMenu.vue
@@ -144,7 +144,7 @@
-
+
@@ -176,7 +176,7 @@
-
+
@@ -218,6 +218,7 @@ export default {
},
props: {
isTagStared: Boolean,
+ currentTag: String,
},
methods: {
// 导入命令且定位
@@ -257,6 +258,13 @@ export default {
this.$profile.backgroundImg = reset ? null : this.selectFile.path;
this.configurationPage.$forceUpdate();
},
+ unMarkTag() {
+ this.$utools.whole.removeFeature(
+ `panel_${window.hexEncode(this.currentTag)}`
+ );
+ _.pull(this.$root.$refs.view.activatedQuickPanels, this.currentTag);
+ quickcommand.showMessageBox("取消收藏成功");
+ },
},
};
diff --git a/src/components/IconPicker.vue b/src/components/IconPicker.vue
index 55d4795..0e808e0 100644
--- a/src/components/IconPicker.vue
+++ b/src/components/IconPicker.vue
@@ -1,6 +1,6 @@
-
+
更改图标
@@ -108,6 +108,9 @@ export default {
dataUrl: null,
};
},
+ props: {
+ position: String,
+ },
methods: {
setIcon(dataUrl) {
this.dataUrl = dataUrl;
diff --git a/src/components/PanelSetting.vue b/src/components/PanelSetting.vue
index 374c09b..c2c5adb 100644
--- a/src/components/PanelSetting.vue
+++ b/src/components/PanelSetting.vue
@@ -1,26 +1,84 @@
-
+
-
-
+
-
-
+
+ (features.icon = dataUrl)"
+ position="right"
+ />
diff --git a/src/pages/ConfigurationPage.vue b/src/pages/ConfigurationPage.vue
index 9c124e5..e44b9c7 100644
--- a/src/pages/ConfigurationPage.vue
+++ b/src/pages/ConfigurationPage.vue
@@ -164,6 +164,7 @@
>
@@ -313,6 +314,10 @@ export default {
// 所有的快捷命令
this.allQuickCommands = this.getAllQuickCommands();
this.importDefaultCommands();
+ if (this.$route.params.tags) {
+ this.currentTag = window.hexDecode(this.$route.params.tags);
+ this.commandCardStyle = "mini";
+ }
},
importDefaultCommands() {
for (var code of Object.keys(defaultCommands)) {
@@ -327,7 +332,7 @@ export default {
let quickpanels = [];
features.forEach((x) =>
x.code.slice(0, 6) == "panel_"
- ? quickpanels.push(hexDecode(x.code.slice(6)))
+ ? quickpanels.push(window.hexDecode(x.code.slice(6)))
: currentFts.push(x)
);
return {
diff --git a/src/router/routes.js b/src/router/routes.js
index 1467124..7f792bf 100644
--- a/src/router/routes.js
+++ b/src/router/routes.js
@@ -2,45 +2,45 @@ const routes = [{
path: '/configuration',
name: 'configuration',
component: () =>
- import('pages/ConfigurationPage.vue')
+ import ('pages/ConfigurationPage.vue')
},
{
path: '/code',
name: 'code',
component: () =>
- import('pages/RunCodePage.vue')
+ import ('pages/RunCodePage.vue')
},
{
path: '/newcommand',
component: () =>
- import('pages/NewCommand.vue')
+ import ('pages/NewCommand.vue')
},
{
path: '/:type(default|files|img|key|regex|window|professional)_:uid(\\w+)',
name: 'command',
component: () =>
- import('pages/CommandPage.vue')
+ import ('pages/CommandPage.vue')
},
{
path: '/panel_:tags(\\w+)',
name: 'panel',
component: () =>
- import('pages/ConfigurationPage.vue')
+ import ('pages/ConfigurationPage.vue')
},
{
path: '/needupdate',
name: 'needupdate',
props: true,
component: () =>
- import('pages/updateWarningPage.vue')
+ import ('pages/updateWarningPage.vue')
},
{
path: '/loading',
name: 'loading',
component: () =>
- import('pages/LoadingPage.vue')
+ import ('pages/LoadingPage.vue')
}
]
-export default routes
+export default routes
\ No newline at end of file