Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -7,7 +7,7 @@ def check_words(user_text, input_text):
|
|
7 |
if user_text == os.getenv("USERNAME") and input_text == os.getenv("PASSWORD"):
|
8 |
return gr.update(visible=True), gr.update(visible=False), gr.update(value=""), gr.update(value="") # Show Panel 2, hide Panel 1
|
9 |
else:
|
10 |
-
return gr.update(visible=False), gr.update(visible=True)
|
11 |
|
12 |
# Function to hide Panel 2
|
13 |
def hide_panel():
|
|
|
7 |
if user_text == os.getenv("USERNAME") and input_text == os.getenv("PASSWORD"):
|
8 |
return gr.update(visible=True), gr.update(visible=False), gr.update(value=""), gr.update(value="") # Show Panel 2, hide Panel 1
|
9 |
else:
|
10 |
+
return gr.update(visible=False), gr.update(visible=True), user_text, input_text # Keep Panel 2 hidden, show Panel 1
|
11 |
|
12 |
# Function to hide Panel 2
|
13 |
def hide_panel():
|