Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -88,76 +88,6 @@ type StrPath = str | PathLike[str]
|
|
| 88 |
|
| 89 |
type Json = Mapping[str, Json] | Sequence[Json] | str | int | float | bool | None
|
| 90 |
|
| 91 |
-
theme = gr.themes.Glass(
|
| 92 |
-
primary_hue="purple",
|
| 93 |
-
secondary_hue=gr.themes.Color(c100="#f3f4f6", c200="#e5e7eb", c300="#d1d5db", c400="#9ca3af", c50="#f9fafb", c500="#6b7280", c600="#4b5563", c700="#374151", c800="rgba(28.422987236857917, 2.1975645867375784, 39.326663208007815, 1)", c900="#1c0227", c950="#1c0227"),
|
| 94 |
-
neutral_hue=gr.themes.Color(c100="#f3e8ff", c200="#e9d5ff", c300="#d8b4fe", c400="#c084fc", c50="#faf5ff", c500="#a855f7", c600="rgba(83.78266724809674, 29.540070278324272, 132.9400207519531, 1)", c700="rgba(48.28126126334004, 17.30792685680411, 76.3866943359375, 1)", c800="rgba(46.03751121625044, 13.894996526550633, 72.53336791992187, 1)", c900="#2e0e49", c950="#2e0e49"),
|
| 95 |
-
radius_size="none",
|
| 96 |
-
).set(
|
| 97 |
-
background_fill_primary='*neutral_700',
|
| 98 |
-
background_fill_secondary='*secondary_800',
|
| 99 |
-
border_color_accent='*neutral_600',
|
| 100 |
-
border_color_primary='*secondary_600',
|
| 101 |
-
color_accent_soft='*neutral_700',
|
| 102 |
-
link_text_color='*secondary_500',
|
| 103 |
-
link_text_color_active='*secondary_500',
|
| 104 |
-
link_text_color_hover='*secondary_400',
|
| 105 |
-
link_text_color_visited='*secondary_600',
|
| 106 |
-
code_background_fill='*neutral_800',
|
| 107 |
-
shadow_spread_dark='0px',
|
| 108 |
-
block_background_fill='*secondary_800',
|
| 109 |
-
block_border_color='*secondary_600',
|
| 110 |
-
block_border_width='1px',
|
| 111 |
-
block_label_background_fill='*secondary_700',
|
| 112 |
-
block_label_border_color='*secondary_600',
|
| 113 |
-
block_label_text_color='*neutral_200',
|
| 114 |
-
block_label_text_size='*text_sm',
|
| 115 |
-
block_title_text_color='*neutral_200',
|
| 116 |
-
checkbox_background_color='*secondary_400',
|
| 117 |
-
checkbox_border_color='*neutral_700',
|
| 118 |
-
checkbox_border_color_hover='*neutral_600',
|
| 119 |
-
checkbox_label_border_color='*secondary_700',
|
| 120 |
-
checkbox_label_gap='*form_gap_width',
|
| 121 |
-
error_background_fill='*background_fill_primary',
|
| 122 |
-
error_border_color='#ef4444',
|
| 123 |
-
error_text_color='#fef2f2',
|
| 124 |
-
error_icon_color='#ef4444',
|
| 125 |
-
input_background_fill='*secondary_600',
|
| 126 |
-
input_border_color='*secondary_600',
|
| 127 |
-
input_border_color_focus='*secondary_500',
|
| 128 |
-
input_placeholder_color='*neutral_500',
|
| 129 |
-
input_radius='*radius_xxs',
|
| 130 |
-
stat_background_fill='*primary_500',
|
| 131 |
-
table_border_color='*neutral_700',
|
| 132 |
-
table_even_background_fill='*neutral_700',
|
| 133 |
-
table_odd_background_fill='*neutral_700',
|
| 134 |
-
button_border_width='0px',
|
| 135 |
-
button_border_width_dark='0px',
|
| 136 |
-
button_transition='all 0.5s ease',
|
| 137 |
-
button_large_text_weight='500',
|
| 138 |
-
button_medium_text_weight='500',
|
| 139 |
-
button_primary_background_fill='linear-gradient(30deg, *primary_800 0%, *primary_950 50%)',
|
| 140 |
-
button_primary_background_fill_dark='linear-gradient(30deg, *primary_800 0%, *primary_950 50%)',
|
| 141 |
-
button_primary_background_fill_hover='linear-gradient(90deg, *primary_950 0%, *primary_700 60%)',
|
| 142 |
-
button_primary_background_fill_hover_dark='linear-gradient(90deg, *primary_950 0%, *primary_700 60%)',
|
| 143 |
-
button_primary_border_color='*primary_600',
|
| 144 |
-
button_primary_border_color_hover='*primary_500',
|
| 145 |
-
button_primary_text_color='white',
|
| 146 |
-
button_primary_text_color_hover='*code_background_fill',
|
| 147 |
-
button_primary_text_color_hover_dark='*code_background_fill',
|
| 148 |
-
button_primary_shadow='*button_primary_shadow',
|
| 149 |
-
button_primary_shadow_active='*button_primary_shadow',
|
| 150 |
-
button_secondary_background_fill='linear-gradient(100deg, *primary_950 0%, *primary_600 70%)',
|
| 151 |
-
button_secondary_background_fill_dark='linear-gradient(100deg, *primary_950 0%, *primary_600 70%)',
|
| 152 |
-
button_secondary_background_fill_hover='linear-gradient(90deg, *primary_700 0%, *primary_950 60%)',
|
| 153 |
-
button_secondary_background_fill_hover_dark='linear-gradient(90deg, *primary_700 0%, *primary_950 60%)',
|
| 154 |
-
button_secondary_border_color='*neutral_600',
|
| 155 |
-
button_secondary_border_color_hover='*neutral_500',
|
| 156 |
-
button_secondary_text_color='white',
|
| 157 |
-
button_secondary_text_color_hover='*table_even_background_fill',
|
| 158 |
-
button_secondary_text_color_hover_dark='*table_even_background_fill',
|
| 159 |
-
button_cancel_text_color_hover='white'
|
| 160 |
-
)
|
| 161 |
|
| 162 |
class SegmentSize(IntEnum):
|
| 163 |
"""Enumeration of segment sizes for audio separation."""
|
|
@@ -1219,7 +1149,7 @@ def render_app() -> gr.Blocks:
|
|
| 1219 |
|
| 1220 |
with gr.Blocks(
|
| 1221 |
title="Redzone-6 Audio Playground",
|
| 1222 |
-
theme=theme
|
| 1223 |
css=css,
|
| 1224 |
delete_cache=(cache_delete_frequency, cache_delete_cutoff),
|
| 1225 |
) as app:
|
|
|
|
| 88 |
|
| 89 |
type Json = Mapping[str, Json] | Sequence[Json] | str | int | float | bool | None
|
| 90 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 91 |
|
| 92 |
class SegmentSize(IntEnum):
|
| 93 |
"""Enumeration of segment sizes for audio separation."""
|
|
|
|
| 1149 |
|
| 1150 |
with gr.Blocks(
|
| 1151 |
title="Redzone-6 Audio Playground",
|
| 1152 |
+
theme=gr.Theme.load(str(Path(__file__).parent / "config/theme.json")),
|
| 1153 |
css=css,
|
| 1154 |
delete_cache=(cache_delete_frequency, cache_delete_cutoff),
|
| 1155 |
) as app:
|