Spaces:
Sleeping
Sleeping
Commit
·
31447cd
1
Parent(s):
3a43614
Login changes
Browse files
app.py
CHANGED
|
@@ -116,7 +116,10 @@ def get_next_components():
|
|
| 116 |
|
| 117 |
with gr.Blocks(css=css, head=yt_init_js) as main_page:
|
| 118 |
gr.Markdown("## Caption Editor")
|
| 119 |
-
|
|
|
|
|
|
|
|
|
|
| 120 |
|
| 121 |
current_user = gr.Textbox(visible=False, interactive=False)
|
| 122 |
current_video_id = gr.Textbox(value=start_video_id, visible=False, interactive=False)
|
|
@@ -157,7 +160,7 @@ with gr.Blocks(css=css, head=yt_init_js) as main_page:
|
|
| 157 |
add_entry_button = gr.Button("Add Entry", variant="secondary")
|
| 158 |
|
| 159 |
with gr.Row():
|
| 160 |
-
|
| 161 |
with gr.Group(visible=False) as editing_panel:
|
| 162 |
gr.Markdown("### Edit Caption Entry")
|
| 163 |
with gr.Row(equal_height=False):
|
|
|
|
| 116 |
|
| 117 |
with gr.Blocks(css=css, head=yt_init_js) as main_page:
|
| 118 |
gr.Markdown("## Caption Editor")
|
| 119 |
+
|
| 120 |
+
if user == "anonymous_user":
|
| 121 |
+
gr.LoginButton()
|
| 122 |
+
gr.Textbox(value=f"Currently logged in as: {user}")
|
| 123 |
|
| 124 |
current_user = gr.Textbox(visible=False, interactive=False)
|
| 125 |
current_video_id = gr.Textbox(value=start_video_id, visible=False, interactive=False)
|
|
|
|
| 160 |
add_entry_button = gr.Button("Add Entry", variant="secondary")
|
| 161 |
|
| 162 |
with gr.Row():
|
| 163 |
+
# Editing panel (initially hidden) - spans full width
|
| 164 |
with gr.Group(visible=False) as editing_panel:
|
| 165 |
gr.Markdown("### Edit Caption Entry")
|
| 166 |
with gr.Row(equal_height=False):
|