mirror of
https://github.com/gradio-app/gradio.git
synced 2025-03-13 11:57:29 +08:00
flag/screenshot btn fix
This commit is contained in:
parent
e5f7efdbe1
commit
4b69268414
@ -125,12 +125,20 @@ function gradio(config, fn, target) {
|
||||
io_master.last_input = null;
|
||||
io_master.last_output = null;
|
||||
});
|
||||
if (config["allow_screenshot"]) {
|
||||
|
||||
if (config["allow_screenshot"] && !config["allow_flagging"]) {
|
||||
target.find(".screenshot").css("visibility", "visible");
|
||||
target.find(".flag").css("display", "none")
|
||||
}
|
||||
if(config["allow_flagging"]){
|
||||
if (!config["allow_screenshot"] && config["allow_flagging"]) {
|
||||
target.find(".flag").css("visibility", "visible");
|
||||
target.find(".screenshot").css("display", "none")
|
||||
}
|
||||
if (config["allow_screenshot"] && config["allow_flagging"]) {
|
||||
target.find(".screenshot").css("visibility", "visible");
|
||||
target.find(".flag").css("visibility", "visible")
|
||||
}
|
||||
|
||||
target.find(".screenshot").click(function() {
|
||||
$(".screenshot").hide();
|
||||
$(".screenshot_logo").show();
|
||||
|
Loading…
Reference in New Issue
Block a user