Gradio - Changing background colour in all devices
I am trying to force Gradio to show a white background colour ALL the time in all browsers. My code below works to force white colour on my desktop (using Firefox) but on mobile it’s still showing the typical default Gradio black background. How to change this behaviour to permanently show a white background in all devices? Thank youdemo = gr.Interface(lambda x:x+x, inputs=gr.Textbox(label='Test'), outputs=gr.Textbox(label='test2'),
        css=".gradio-container {background-color: white} ").launch(share=False)
2023-06-09T22:44:04Z
hi, if you’re tying to force dark/light them on Gradio app, you can try thisimport gradio as gr

interface = gr.Interface(lambda a: a, "text", "text")

with gr.Blocks() as block:
    interface.render()
    block.load(
        None,
        None,
        _js="""
  () => {
  const params = new URLSearchParams(window.location.search);
  if (!params.has('__theme')) {
    params.set('__theme', 'dark');
    window.location.search = params.toString();
  }
  }""",
    )

block.launch(share=False)