Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
infwinston committed Oct 20, 2023
1 parent 545b808 commit 0388935
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions fastchat/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,15 +192,11 @@ def pretty_print_semaphore(semaphore):

"""A javascript function to get url parameters for the gradio web server."""
get_window_url_params_js = """
function() {
() => {
document.body.classList.toggle('dark');
document.body.classList.toggle('light');
document.querySelector('gradio-app').style.backgroundColor = 'var(--color-background-primary)';
const params = new URLSearchParams(window.location.search);
url_params = Object.fromEntries(params);
console.log("url_params", url_params);
return url_params;
}
}
"""


Expand Down

0 comments on commit 0388935

Please sign in to comment.