mirror of
https://github.com/rubickCenter/rubick
synced 2025-12-25 20:09:27 +08:00
✨ 支持插件分离,增加开发者工具功能
This commit is contained in:
@@ -142,6 +142,7 @@ const showSeparate = () => {
|
||||
{
|
||||
label: "开发者工具",
|
||||
click: () => {
|
||||
ipcRenderer.send("msg-trigger", { type: "openPluginDevTools" });
|
||||
// todo
|
||||
},
|
||||
},
|
||||
@@ -179,6 +180,9 @@ const getIcon = () => {
|
||||
}
|
||||
|
||||
const newWindow = () => {
|
||||
ipcRenderer.send("msg-trigger", {
|
||||
type: "detachPlugin",
|
||||
});
|
||||
// todo
|
||||
};
|
||||
</script>
|
||||
|
||||
@@ -27,6 +27,13 @@ const searchManager = () => {
|
||||
state.searchValue = value;
|
||||
};
|
||||
|
||||
window.getMainInputInfo = () => {
|
||||
return {
|
||||
value: state.searchValue,
|
||||
placeholder: state.placeholder,
|
||||
};
|
||||
};
|
||||
|
||||
return {
|
||||
...toRefs(state),
|
||||
onSearch,
|
||||
|
||||
1
src/renderer/shims-vue.d.ts
vendored
1
src/renderer/shims-vue.d.ts
vendored
@@ -21,4 +21,5 @@ interface Window {
|
||||
initRubick: () => void;
|
||||
setCurrentPlugin: (plugin: any) => void;
|
||||
pluginLoaded: () => void;
|
||||
getMainInputInfo: () => any;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user