repo
stringlengths
7
90
file_url
stringlengths
81
315
file_path
stringlengths
4
228
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 14:38:15
2026-01-05 02:33:18
truncated
bool
2 classes
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/validators.py
gradio/validators.py
from typing import TYPE_CHECKING, Any from gradio_client.documentation import document if TYPE_CHECKING: import numpy as np @document() def is_audio_correct_length( audio: tuple[int, "np.ndarray"], min_length: float | None, max_length: float | None ) -> dict[str, Any]: """ Validates that the audio l...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/oauth.py
gradio/oauth.py
from __future__ import annotations import hashlib import os import time import typing import urllib.parse import warnings from dataclasses import dataclass, field import fastapi from fastapi.responses import RedirectResponse from huggingface_hub import get_token, whoami from gradio.utils import get_space OAUTH_CLIE...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/screen_recording_utils.py
gradio/screen_recording_utils.py
import asyncio import os import shutil import tempfile import traceback from pathlib import Path DEFAULT_TEMP_DIR = os.environ.get("GRADIO_TEMP_DIR") or str( Path(tempfile.gettempdir()) / "gradio" ) async def process_video_with_ffmpeg(input_path, output_path, params): from ffmpy import FFmpeg current_in...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/templates.py
gradio/templates.py
from __future__ import annotations from collections.abc import Callable, Iterable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal import numpy as np import PIL.Image from gradio import components from gradio.components.audio import WaveformOptions from gradio.components.image_editor...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/networking.py
gradio/networking.py
""" Defines helper methods useful for setting up ports, launching servers, and creating tunnels. """ from __future__ import annotations import os import time import warnings from pathlib import Path import httpx from gradio.routes import App # HACK: to avoid circular import # noqa: F401 from gradio.tunneling impor...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/tunneling.py
gradio/tunneling.py
import atexit import hashlib import os import platform import re import stat import subprocess import sys import time from pathlib import Path import httpx from huggingface_hub.constants import HF_HOME from gradio.exceptions import ChecksumMismatchError VERSION = "0.3" CURRENT_TUNNELS: list["Tunnel"] = [] machine =...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/events.py
gradio/events.py
"""Contains all of the events that can be triggered in a gr.Blocks() app, with the exception of the on-page-load event, which is defined in gr.Blocks().load().""" from __future__ import annotations import dataclasses from collections.abc import Callable, Sequence, Set from functools import partial, wraps from typing ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/__main__.py
gradio/__main__.py
from gradio.cli import cli if __name__ == "__main__": cli()
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/mcp.py
gradio/mcp.py
import base64 import contextlib import copy import os import re import tempfile import warnings from collections.abc import AsyncIterator, Sequence from io import BytesIO from pathlib import Path from typing import TYPE_CHECKING, Any, Optional, cast from urllib.parse import unquote import gradio_client.utils as client...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/data_classes.py
gradio/data_classes.py
"""Pydantic data models and other dataclasses. This is the only file that uses Optional[] typing syntax instead of | None syntax to work with pydantic""" from __future__ import annotations import pathlib import secrets import shutil from abc import ABC, abstractmethod from collections.abc import Iterator from enum im...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/interface.py
gradio/interface.py
""" This file defines two useful high-level abstractions to build Gradio apps: Interface and TabbedInterface. """ from __future__ import annotations import inspect import json import os import warnings from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.do...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/i18n.py
gradio/i18n.py
from __future__ import annotations import re import warnings from typing import Any class I18nData: """ A class that wraps a translation key with metadata. This object will be serialized and sent to the frontend, where the actual translation will happen using the frontend's i18n system. """ ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/route_utils.py
gradio/route_utils.py
from __future__ import annotations import asyncio import functools import hashlib import hmac import json import os import pickle import re import shutil import threading import unicodedata import uuid from collections import defaultdict, deque from collections.abc import AsyncGenerator, Callable from contextlib impor...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/helpers.py
gradio/helpers.py
""" Defines helper methods useful for loading and caching Interface examples. """ from __future__ import annotations import ast import copy import csv import inspect import os import shutil import warnings from collections.abc import Callable, Iterable, Sequence from functools import partial from pathlib import Path ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/queueing.py
gradio/queueing.py
from __future__ import annotations import asyncio import copy import inspect import os import platform import random import time import traceback import uuid from collections import defaultdict from queue import Queue as ThreadQueue from typing import TYPE_CHECKING, Any, Literal, cast import fastapi import numpy as n...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/ipython_ext.py
gradio/ipython_ext.py
try: from IPython.core.magic import ( needs_local_scope, register_cell_magic, ) from IPython.core.magic_arguments import argument, magic_arguments, parse_argstring except ImportError: pass import gradio as gr from gradio.routes import App from gradio.utils import BaseReloader class Ce...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/utils.py
gradio/utils.py
"""Handy utility functions.""" from __future__ import annotations import asyncio import copy import functools import hashlib import importlib import importlib.metadata import importlib.resources import inspect import json import os import pkgutil import posixpath import re import shutil import site import subprocess ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/pipelines.py
gradio/pipelines.py
"""This module should not be used directly as its API is subject to change. Instead, please use the `gr.Interface.from_pipeline()` function.""" from __future__ import annotations from typing import TYPE_CHECKING from gradio.pipelines_utils import ( handle_diffusers_pipeline, handle_transformers_js_pipeline, ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/external.py
gradio/external.py
"""This module should not be used directly as its API is subject to change. Instead, use the `gr.Blocks.load()` or `gr.load()` functions.""" from __future__ import annotations import json import os import re import tempfile import warnings from collections.abc import Callable, Generator from pathlib import Path from ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/node_server.py
gradio/node_server.py
from __future__ import annotations import os import signal import socket import subprocess import sys import time import warnings from concurrent.futures import TimeoutError from contextlib import closing from pathlib import Path from typing import TYPE_CHECKING if TYPE_CHECKING: # Only import for type checking (to ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/__init__.py
gradio/__init__.py
import json import gradio._simple_templates import gradio.image_utils import gradio.processing_utils import gradio.templates from gradio import components, layouts, mcp, themes, validators from gradio.blocks import Blocks from gradio.chat_interface import ChatInterface from gradio.cli import deploy from gradio.compone...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/http_server.py
gradio/http_server.py
from __future__ import annotations import os import socket import sys import threading import time from collections.abc import Callable from functools import partial from typing import TYPE_CHECKING, TypeVar import uvicorn from uvicorn.config import Config from gradio.exceptions import ServerFailedToStartError from ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/blocks_events.py
gradio/blocks_events.py
from __future__ import annotations from gradio.component_meta import create_or_modify_pyi from gradio.events import EventListener, Events BLOCKS_EVENTS: list[EventListener | str] = [Events.load] class BlocksMeta(type): def __new__(cls, name, bases, attrs): for event in BLOCKS_EVENTS: trigger...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/context.py
gradio/context.py
# Defines the Context class, which is used to store the state of all Blocks that are being rendered. from __future__ import annotations from contextvars import ContextVar from typing import TYPE_CHECKING if TYPE_CHECKING: # Only import for type checking (is False at runtime). from gradio.blocks import BlockCont...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/state_holder.py
gradio/state_holder.py
from __future__ import annotations import datetime import os import threading from collections import OrderedDict from collections.abc import Iterator from copy import copy, deepcopy from typing import TYPE_CHECKING, Any if TYPE_CHECKING: from gradio.blocks import Blocks from gradio.components import State ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/routes.py
gradio/routes.py
"""Implements a FastAPI server to run the gradio interface. Note that some types in this module use the Optional/Union notation so that they work correctly with pydantic.""" from __future__ import annotations import asyncio import contextlib import hashlib import importlib.resources import inspect import io import js...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/component_meta.py
gradio/component_meta.py
from __future__ import annotations import ast import inspect from abc import ABCMeta from functools import wraps from pathlib import Path from jinja2 import Template from gradio.events import EventListener from gradio.exceptions import ComponentDefinitionError from gradio.utils import no_raise_exception INTERFACE_T...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/server_messages.py
gradio/server_messages.py
from typing import Literal, Union from gradio_client.utils import ServerMessage from pydantic import BaseModel class BaseMessage(BaseModel): msg: ServerMessage event_id: str | None = None class ProgressUnit(BaseModel): index: int | float | None = None length: int | float | None = None unit: str...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/media.py
gradio/media.py
""" Media Registry for Gradio Demos This module provides a centralized way to access media files. Usage: from gradio.media import get_image, get_video, get_audio, get_model3d, get_file # Get specific media files cheetah_img = get_image("cheetah1.jpg") world_video = get_video("world.mp4") cantina_...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/pipelines_utils.py
gradio/pipelines_utils.py
""" Defines internal helper methods for handling transformers and diffusers pipelines. These are used by load_from_pipeline method in pipelines.py. """ from typing import Any import numpy as np from PIL import Image from gradio import components def handle_transformers_pipeline(pipeline: Any) -> dict[str, Any] | N...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/file_explorer.py
gradio/components/file_explorer.py
"""gr.FileExplorer() component""" from __future__ import annotations import fnmatch import os from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component, server f...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/image.py
gradio/components/image.py
"""gr.Image() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal import numpy as np import PIL.Image from gradio_client import handle_file from gradio_client.documentation import document from gradio...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/navbar.py
gradio/components/navbar.py
"""gr.Navbar() component.""" from __future__ import annotations from typing import Any, Literal from gradio_client.documentation import document from gradio.components.base import Component from gradio.events import Events @document() class Navbar(Component): """ Creates a navigation bar component for mul...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/dataframe.py
gradio/components/dataframe.py
"""gr.Dataframe() component""" from __future__ import annotations import re import warnings from collections.abc import Callable, Sequence from typing import ( TYPE_CHECKING, Any, Literal, Union, ) import numpy as np import semantic_version from gradio_client.documentation import document from gradi...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/file.py
gradio/components/file.py
"""gr.File() component""" from __future__ import annotations import tempfile from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal import gradio_client.utils as client_utils from gradio_client import handle_file from gradio_client.documentation import ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/json_component.py
gradio/components/json_component.py
"""gr.JSON() component.""" from __future__ import annotations import json import warnings from collections.abc import Callable, Sequence from typing import ( TYPE_CHECKING, Any, Literal, ) import orjson from gradio_client.documentation import document from gradio.components.base import Component from gr...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/dialogue.py
gradio/components/dialogue.py
from __future__ import annotations from collections.abc import Callable from typing import Literal from gradio_client.documentation import document from gradio.components.base import Component, server from gradio.components.button import Button from gradio.data_classes import GradioModel, GradioRootModel from gradio...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/image_editor.py
gradio/components/image_editor.py
r"""gr.ImageEditor() component.""" from __future__ import annotations import dataclasses import warnings from collections.abc import Iterable, Sequence from io import BytesIO from pathlib import Path from typing import ( TYPE_CHECKING, Any, Literal, Union, cast, ) import numpy as np import PIL.Im...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/color_picker.py
gradio/components/color_picker.py
"""gr.ColorPicker() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component from gradio.events import Events from gradio.i18n import I1...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/browser_state.py
gradio/components/browser_state.py
"""gr.BrowserState() component.""" from __future__ import annotations import secrets import string from typing import Any from gradio_client.documentation import document from gradio.components.base import Component from gradio.events import Events @document() class BrowserState(Component): EVENTS = [Events.c...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/state.py
gradio/components/state.py
"""gr.State() component.""" from __future__ import annotations import math from collections.abc import Callable from copy import deepcopy from typing import Any from gradio_client.documentation import document from gradio.components.base import Component from gradio.events import Events def default_delete_callbac...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/html.py
gradio/components/html.py
"""gr.HTML() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component from gradio.components.button import Button from gradio.events imp...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/datetime.py
gradio/components/datetime.py
"""gr.DateTime() component.""" from __future__ import annotations import re from datetime import datetime, timedelta from typing import Any, Literal import pytz from gradio_client.documentation import document from gradio.components.base import FormComponent from gradio.components.button import Button from gradio.e...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/audio.py
gradio/components/audio.py
"""gr.Audio() component.""" from __future__ import annotations import dataclasses import io from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal import anyio import httpx import numpy as np from gradio_client import handle_file from gradio_client impo...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/timer.py
gradio/components/timer.py
"""gr.Timer() component.""" from __future__ import annotations from typing import TYPE_CHECKING from gradio_client.documentation import document from gradio.components.base import Component from gradio.events import Events if TYPE_CHECKING: pass @document() class Timer(Component): """ Special compone...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/upload_button.py
gradio/components/upload_button.py
"""gr.UploadButton() component.""" from __future__ import annotations import tempfile import warnings from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal import gradio_client.utils as client_utils from gradio_client import handle_file from gradio_cli...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/markdown.py
gradio/components/markdown.py
"""gr.Markdown() component.""" from __future__ import annotations import inspect from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component from gradio.events import Events from gradio.i1...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/fallback.py
gradio/components/fallback.py
from gradio.components.base import Component class Fallback(Component): def preprocess(self, payload): """ This docstring is used to generate the docs for this custom component. Parameters: payload: the data to be preprocessed, sent from the frontend Returns: ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/model3d.py
gradio/components/model3d.py
"""gr.Model3D() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Literal from gradio_client import handle_file from gradio_client.documentation import document from gradio.components.base import Component from ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/label.py
gradio/components/label.py
"""gr.Label() component.""" from __future__ import annotations import json import operator from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal, Union from gradio_client.documentation import document from gradio.components.base import Component from ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/number.py
gradio/components/number.py
"""gr.Number() component.""" from __future__ import annotations import json from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component, FormComponent from gradio.components.button import ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/api_component.py
gradio/components/api_component.py
"""gr.Api() component.""" from __future__ import annotations from typing import Any from gradio.components.base import Component class Api(Component): """ A generic component that holds any value. Used for generating APIs with no actual frontend component. """ EVENTS = [] def __init__( ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/clear_button.py
gradio/components/clear_button.py
"""Predefined buttons with bound events that can be included in a gr.Blocks for convenience.""" from __future__ import annotations import copy import json from collections.abc import Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document fro...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/code.py
gradio/components/code.py
"""gr.Code() component""" from __future__ import annotations from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component from gradio.components.button import Button from gradio.events impo...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/slider.py
gradio/components/slider.py
"""gr.Slider() component.""" from __future__ import annotations import json import math import random from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component, FormComponent from gradio...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/dataset.py
gradio/components/dataset.py
"""gr.Dataset() component.""" from __future__ import annotations import warnings from collections.abc import Sequence from typing import Any, Literal from gradio_client.documentation import document from gradio import processing_utils from gradio.components.base import ( Component, get_component_instance, )...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/multimodal_textbox.py
gradio/components/multimodal_textbox.py
"""gr.MultimodalTextbox() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal, TypedDict, cast import gradio_client.utils as client_utils from gradio_client import handle_file from gradio_client.docume...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/plot.py
gradio/components/plot.py
"""gr.Plot() component.""" from __future__ import annotations import json from collections.abc import Sequence from types import ModuleType from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio import processing_utils from gradio.components.base import Component...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/checkbox.py
gradio/components/checkbox.py
"""gr.Checkbox() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component, FormComponent from gradio.components.button import Button fro...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/annotated_image.py
gradio/components/annotated_image.py
"""gr.AnnotatedImage() component.""" from __future__ import annotations from collections.abc import Sequence from typing import TYPE_CHECKING, Any, Literal import gradio_client.utils as client_utils import numpy as np import PIL.Image from gradio_client import handle_file from gradio_client.documentation import docu...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/checkboxgroup.py
gradio/components/checkboxgroup.py
"""gr.CheckboxGroup() component""" from __future__ import annotations from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component, FormComponent from gradio.components.button import Button...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/chatbot.py
gradio/components/chatbot.py
"""gr.Chatbot() component.""" from __future__ import annotations import copy import inspect from collections.abc import Callable, Sequence from dataclasses import dataclass, field from pathlib import Path from typing import ( TYPE_CHECKING, Any, Literal, Union, cast, ) from gradio_client import u...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/native_plot.py
gradio/components/native_plot.py
from __future__ import annotations import json from collections.abc import Callable, Sequence, Set from typing import ( TYPE_CHECKING, Any, Literal, ) from gradio_client.documentation import document from gradio.components.base import Component from gradio.data_classes import GradioModel from gradio.even...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/__init__.py
gradio/components/__init__.py
from gradio.components.annotated_image import AnnotatedImage from gradio.components.audio import Audio from gradio.components.base import ( Component, FormComponent, StreamingInput, StreamingOutput, _Keywords, component, get_component_instance, ) from gradio.components.browser_state import B...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/deep_link_button.py
gradio/components/deep_link_button.py
"""Predefined button to copy a shareable link to the current Gradio Space.""" from __future__ import annotations import textwrap import time from collections.abc import Sequence from pathlib import Path from typing import TYPE_CHECKING, Literal from gradio_client.documentation import document from gradio import uti...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/dropdown.py
gradio/components/dropdown.py
"""gr.Dropdown() component.""" from __future__ import annotations import warnings from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component, FormComponent from gradio.components.button i...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/video.py
gradio/components/video.py
"""gr.Video() component.""" from __future__ import annotations import asyncio import json import subprocess import tempfile import warnings from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal from gradio_client import handle_file from gradio_client i...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/imageslider.py
gradio/components/imageslider.py
"""gr.ImageSlider() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal import numpy as np import PIL.Image from gradio_client import handle_file from gradio_client.documentation import document from ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/button.py
gradio/components/button.py
"""gr.Button() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component from gradio.events import Events from g...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/login_button.py
gradio/components/login_button.py
"""Predefined button to sign in with Hugging Face in a Gradio Space.""" from __future__ import annotations import json import time from collections.abc import Sequence from pathlib import Path from typing import TYPE_CHECKING, Literal from gradio_client.documentation import document from gradio import utils from gr...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/base.py
gradio/components/base.py
"""Contains all of the components that can be used with Gradio Interface / Blocks. Along with the docs for each component, you can find the names of example demos that use each component. These demos are located in the `demo` directory.""" from __future__ import annotations import abc import hashlib import inspect im...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/duplicate_button.py
gradio/components/duplicate_button.py
"""gr.DuplicateButton() component""" from __future__ import annotations from collections.abc import Sequence from pathlib import Path from typing import TYPE_CHECKING, Literal from gradio_client.documentation import document from gradio.components import Button, Component from gradio.context import get_blocks_conte...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/radio.py
gradio/components/radio.py
"""gr.Radio() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component, FormComponent from gradio.components.button import Button from g...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/highlighted_text.py
gradio/components/highlighted_text.py
"""gr.HighlightedText() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal, Union from gradio_client.documentation import document from gradio.components.base import Component from gradio.components.button import Button from...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/download_button.py
gradio/components/download_button.py
"""gr.DownloadButton() component.""" from __future__ import annotations import tempfile from collections.abc import Callable, Sequence from pathlib import Path from typing import TYPE_CHECKING, Literal from gradio_client import handle_file from gradio_client.documentation import document from gradio.components.base...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/textbox.py
gradio/components/textbox.py
"""gr.Textbox() component.""" from __future__ import annotations import dataclasses import warnings from collections.abc import Callable, Sequence from typing import TYPE_CHECKING, Any, Literal from gradio_client.documentation import document from gradio.components.base import Component, FormComponent from gradio.c...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/gallery.py
gradio/components/gallery.py
"""gr.Gallery() component.""" from __future__ import annotations from collections.abc import Callable, Sequence from concurrent.futures import ThreadPoolExecutor from pathlib import Path from typing import ( TYPE_CHECKING, Any, Literal, Union, ) from urllib.parse import quote, urlparse import numpy a...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/paramviewer.py
gradio/components/paramviewer.py
from __future__ import annotations from collections.abc import Mapping, Sequence from typing import TYPE_CHECKING, Literal, TypedDict from gradio_client.documentation import document from gradio.components.base import Component from gradio.events import Events if TYPE_CHECKING: from gradio.components import Tim...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/custom_html_components/audio_gallery.py
gradio/components/custom_html_components/audio_gallery.py
import gradio as gr class AudioGallery(gr.HTML): def __init__( self, audio_urls: list[str], *, value: str | None = None, labels: list[str] | None = None, columns: int = 3, label: str | None = None, **kwargs, ): self.audio_urls = audio_url...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/components/custom_html_components/colored_checkbox_group.py
gradio/components/custom_html_components/colored_checkbox_group.py
import gradio as gr class ColoredCheckboxGroup(gr.HTML): def __init__( self, choices: list[str], *, value: list[str] | None = None, colors: list[str], label: str | None = None, **kwargs, ): html_template = """ <div class="colored-checkbox...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/sidebar.py
gradio/layouts/sidebar.py
from __future__ import annotations from typing import Literal from gradio_client.documentation import document from gradio.blocks import BlockContext from gradio.component_meta import ComponentMeta from gradio.events import Events from gradio.i18n import I18nData @document() class Sidebar(BlockContext, metaclass=C...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/accordion.py
gradio/layouts/accordion.py
from __future__ import annotations from typing import TYPE_CHECKING, Literal from gradio_client.documentation import document from gradio.blocks import BlockContext from gradio.component_meta import ComponentMeta from gradio.events import Events from gradio.i18n import I18nData if TYPE_CHECKING: pass @documen...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/draggable.py
gradio/layouts/draggable.py
from __future__ import annotations from typing import Literal from gradio_client.documentation import document from gradio.blocks import BlockContext from gradio.component_meta import ComponentMeta @document() class Draggable(BlockContext, metaclass=ComponentMeta): """ Draggable is a layout element within ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/walkthrough.py
gradio/layouts/walkthrough.py
from __future__ import annotations from gradio_client.documentation import document from gradio.blocks import BlockContext from gradio.component_meta import ComponentMeta from gradio.events import Events from gradio.i18n import I18nData @document() class Walkthrough(BlockContext, metaclass=ComponentMeta): """ ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/form.py
gradio/layouts/form.py
from __future__ import annotations from typing import TYPE_CHECKING from gradio.blocks import BlockContext, Blocks from gradio.component_meta import ComponentMeta from gradio.layouts.column import Column from gradio.layouts.row import Row if TYPE_CHECKING: from gradio.blocks import Block class Form(BlockContex...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/group.py
gradio/layouts/group.py
from __future__ import annotations from typing import Literal from gradio_client.documentation import document from gradio.blocks import BlockContext from gradio.component_meta import ComponentMeta @document() class Group(BlockContext, metaclass=ComponentMeta): """ Group is a layout element within Blocks w...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/__init__.py
gradio/layouts/__init__.py
from .accordion import Accordion from .column import Column from .draggable import Draggable from .form import Form from .group import Group from .row import Row from .sidebar import Sidebar from .tabs import Tab, TabItem, Tabs from .walkthrough import Step, Walkthrough __all__ = [ "Accordion", "Column", "...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/tabs.py
gradio/layouts/tabs.py
from __future__ import annotations from typing import Literal from gradio_client.documentation import document from gradio.blocks import BlockContext from gradio.component_meta import ComponentMeta from gradio.events import Events from gradio.i18n import I18nData class Tabs(BlockContext, metaclass=ComponentMeta): ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/row.py
gradio/layouts/row.py
from __future__ import annotations import warnings from typing import Literal from gradio_client.documentation import document from gradio.blocks import BlockContext from gradio.component_meta import ComponentMeta @document() class Row(BlockContext, metaclass=ComponentMeta): """ Row is a layout element wit...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/layouts/column.py
gradio/layouts/column.py
from __future__ import annotations import warnings from typing import Literal from gradio_client.documentation import document from gradio.blocks import BlockContext from gradio.component_meta import ComponentMeta @document() class Column(BlockContext, metaclass=ComponentMeta): """ Column is a layout eleme...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/glass.py
gradio/themes/glass.py
from __future__ import annotations from collections.abc import Iterable from gradio.themes.base import Base from gradio.themes.utils import colors, fonts, sizes class Glass(Base): def __init__( self, *, primary_hue: colors.Color | str = colors.blue, secondary_hue: colors.Color | ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/citrus.py
gradio/themes/citrus.py
from __future__ import annotations from collections.abc import Iterable from gradio.themes.base import Base from gradio.themes.utils import colors, fonts, sizes class Citrus(Base): def __init__( self, *, primary_hue: colors.Color | str = colors.amber, secondary_hue: colors.Color ...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/ocean.py
gradio/themes/ocean.py
from __future__ import annotations from collections.abc import Iterable from gradio.themes.base import Base from gradio.themes.utils import colors, fonts, sizes class Ocean(Base): def __init__( self, *, primary_hue: colors.Color | str = colors.emerald, secondary_hue: colors.Color...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/default.py
gradio/themes/default.py
from __future__ import annotations from collections.abc import Iterable from gradio.themes.base import Base from gradio.themes.utils import colors, fonts, sizes class Default(Base): def __init__( self, *, primary_hue: colors.Color | str = colors.orange, secondary_hue: colors.Colo...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/upload_theme.py
gradio/themes/upload_theme.py
from __future__ import annotations import argparse from gradio.themes import ThemeClass def main(): parser = argparse.ArgumentParser(description="Upload a demo to a space") parser.add_argument("theme", type=str, help="Theme json file") parser.add_argument("repo_name", type=str, help="HF repo name to sto...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/__init__.py
gradio/themes/__init__.py
from gradio.themes.base import Base, ThemeClass from gradio.themes.citrus import Citrus from gradio.themes.default import Default from gradio.themes.glass import Glass from gradio.themes.monochrome import Monochrome from gradio.themes.ocean import Ocean from gradio.themes.origin import Origin from gradio.themes.soft im...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/builder_app.py
gradio/themes/builder_app.py
import inspect import time from collections.abc import Iterable from gradio_client.documentation import document_fn import gradio as gr themes = [ gr.themes.Base, gr.themes.Default, gr.themes.Soft, gr.themes.Monochrome, gr.themes.Glass, gr.themes.Origin, gr.themes.Citrus, gr.themes.Oc...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/base.py
gradio/themes/base.py
from __future__ import annotations import json import re import tempfile import textwrap import warnings from collections.abc import Iterable from pathlib import Path import huggingface_hub import semantic_version as semver from gradio_client.documentation import document from huggingface_hub import CommitOperationAd...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
true
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/soft.py
gradio/themes/soft.py
from __future__ import annotations from collections.abc import Iterable from gradio.themes.base import Base from gradio.themes.utils import colors, fonts, sizes class Soft(Base): def __init__( self, *, primary_hue: colors.Color | str = colors.indigo, secondary_hue: colors.Color |...
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false
gradio-app/gradio
https://github.com/gradio-app/gradio/blob/3b56b13268ddcaf74d4e85e5dbf5a616d7843995/gradio/themes/monochrome.py
gradio/themes/monochrome.py
from __future__ import annotations from collections.abc import Iterable from gradio.themes.base import Base from gradio.themes.utils import colors, fonts, sizes class Monochrome(Base): def __init__( self, *, primary_hue: colors.Color | str = colors.neutral, secondary_hue: colors....
python
Apache-2.0
3b56b13268ddcaf74d4e85e5dbf5a616d7843995
2026-01-04T14:40:26.993006Z
false