Spaces:
Sleeping
Sleeping
| import gradio as gr | |
| def test(x, profile: gr.OAuthProfile | None): | |
| if profile is None: | |
| return "I don't know you." | |
| return f"{x} {profile.name}" | |
| with gr.Blocks() as demo: | |
| l = gr.LoginButton() | |
| t1 = gr.Textbox() | |
| t2 = gr.Textbox() | |
| t1.submit(test, t1, t2) | |
| demo.launch() |