Introducing Gradio Clients

Watch

New to Gradio? Start here: Getting Started

See the Release History

LogoutButton

gradio.LogoutButton(ยทยทยท)

Description

Creates a Button to log out a user from a Space using OAuth.
which handles both the login and logout processes.

Behavior

As input component: (Rarely used) the str corresponding to the button label when the button is clicked

Your function should accept one of these types:
def predict(
	value: str | None
)
	...

As output component: string corresponding to the button label

Your function should return one of these types:
def predict(ยทยทยท) -> str | None
	...	
	return value

Initialization

Parameters

Shortcuts

Class Interface String Shortcut Initialization

gradio.LogoutButton

"logoutbutton"

Uses default values

Event Listeners

Description

Event listeners allow you to respond to user interactions with the UI components you've defined in a Gradio Blocks app. When a user interacts with an element, such as changing a slider value or uploading an image, a function is called.

Supported Event Listeners

The LogoutButton component supports the following event listeners. Each event listener takes the same parameters, which are listed in the Event Parameters table below.

Listener Description

LogoutButton.click(fn, ยทยทยท)

Triggered when the Button is clicked.

Event Parameters

Parameters