镜像自地址
https://github.com/binary-husky/gpt_academic.git
已同步 2025-12-07 15:06:48 +00:00
improve css
这个提交包含在:
@@ -1548,8 +1548,8 @@ async function generate_menu(guiBase64String, btnName){
|
||||
visible: true,
|
||||
__type__: 'update'
|
||||
}, "plugin_arg_menu", "obj");
|
||||
|
||||
// 根据 gui_args,使得对应参数项显现
|
||||
hide_all_elem();
|
||||
// 根据 gui_args, 使得对应参数项显现
|
||||
let text_cnt = 0;
|
||||
for (const key in gui_args) {
|
||||
if (gui_args.hasOwnProperty(key)) {
|
||||
@@ -1558,6 +1558,8 @@ async function generate_menu(guiBase64String, btnName){
|
||||
push_data_to_gradio_component({
|
||||
visible: true,
|
||||
label: gui_args[key].title + "(" + gui_args[key].description + ")",
|
||||
// label: gui_args[key].title,
|
||||
placeholder: gui_args[key].description,
|
||||
__type__: 'update'
|
||||
}, component_name, "obj");
|
||||
if (key === "main_input"){
|
||||
@@ -1574,6 +1576,7 @@ async function generate_menu(guiBase64String, btnName){
|
||||
else {
|
||||
push_data_to_gradio_component(gui_args[key].default_value, component_name, "obj");
|
||||
}
|
||||
document.getElementById(component_name).parentNode.parentNode.style.display = '';
|
||||
text_cnt += 1;
|
||||
}
|
||||
}
|
||||
@@ -1609,18 +1612,31 @@ async function execute_current_pop_up_plugin(){
|
||||
visible: false,
|
||||
__type__: 'update'
|
||||
}, "plugin_arg_menu", "obj");
|
||||
hide_all_elem();
|
||||
|
||||
// execute the plugin
|
||||
push_data_to_gradio_component(JSON.stringify(gui_args), "invisible_current_pop_up_plugin_arg_final", "string");
|
||||
document.getElementById("invisible_callback_btn_for_plugin_exe").click();
|
||||
|
||||
}
|
||||
|
||||
function hide_all_elem(){
|
||||
for (text_cnt = 0; text_cnt < 8; text_cnt++){
|
||||
push_data_to_gradio_component({
|
||||
visible: false,
|
||||
label: "",
|
||||
__type__: 'update'
|
||||
}, "plugin_arg_txt_"+text_cnt, "obj");
|
||||
document.getElementById("plugin_arg_txt_"+text_cnt).parentNode.parentNode.style.display = 'none';
|
||||
}
|
||||
}
|
||||
|
||||
// execute the plugin
|
||||
push_data_to_gradio_component(JSON.stringify(gui_args), "invisible_current_pop_up_plugin_arg_final", "string");
|
||||
document.getElementById("invisible_callback_btn_for_plugin_exe").click();
|
||||
|
||||
function close_current_pop_up_plugin(){
|
||||
push_data_to_gradio_component({
|
||||
visible: false,
|
||||
__type__: 'update'
|
||||
}, "plugin_arg_menu", "obj");
|
||||
hide_all_elem();
|
||||
}
|
||||
|
||||
|
||||
@@ -1630,7 +1646,3 @@ async function execute_current_pop_up_plugin(){
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
在新工单中引用
屏蔽一个用户