# This module is created for the landing page from __future__ import annotations from typing import Iterable import gradio as gr from gradio.themes.base import Base from gradio.themes.utils import colors, fonts, sizes import main_page class Custom(Base): # A class for custom theme for the app def __init__( self, *, primary_hue: colors.Color | str = colors.gray, secondary_hue: colors.Color | str = colors.gray, neutral_hue: colors.Color | str = colors.gray, spacing_size: sizes.Size | str = sizes.spacing_lg, radius_size: sizes.Size | str = sizes.radius_md, text_size: sizes.Size | str = sizes.text_lg, font: fonts.Font | str | Iterable[fonts.Font | str] = ( fonts.GoogleFont("Quicksand"), "ui-sans-serif", "sans-serif", ), font_mono: fonts.Font | str | Iterable[fonts.Font | str] = ( fonts.GoogleFont("IBM Plex Mono"), "ui-monospace", "monospace", ), ): super().__init__( primary_hue=primary_hue, secondary_hue=secondary_hue, neutral_hue=neutral_hue, spacing_size=spacing_size, radius_size=radius_size, text_size=text_size, font=font, font_mono=font_mono, ) super().set( body_background_fill="linear-gradient(#988558, #C19A6B,#C2B280)", # Background light mode body_background_fill_dark="linear-gradient(#080402, #0d0907, #28231d)", # Background dark mode button_primary_background_fill="radial-gradient(#3f3a2b, #433f2e)", button_primary_background_fill_hover="radial-gradient(#2b281d, #302d21)", button_primary_text_color="white", button_primary_background_fill_dark="radial-gradient(#3f3a2b, #433f2e)", button_primary_background_fill_hover_dark="radial-gradient(#2b281d, #302d21)", slider_color="radial-gradient(#3f3a2b, #433f2e)", slider_color_dark="radial-gradient(#3f3a2b, #433f2e)", block_title_text_weight="600", block_border_width="3px", block_shadow="*shadow_drop_lg", button_shadow="*shadow_drop_lg", button_large_padding="32px", ) def __saveUserName(a): # Function to save the username (for the input) if not a: # If the user does not give the input, then display a warning text markdown = gr.Markdown( "