Spaces:
Paused
Paused
Add remove button
Browse files
app.py
CHANGED
|
@@ -231,6 +231,9 @@ def add_output_click(*struct_ref):
|
|
| 231 |
def remove_output_click(*struct_ref):
|
| 232 |
global visible
|
| 233 |
print("Removing output", visible)
|
|
|
|
|
|
|
|
|
|
| 234 |
visible -= 1
|
| 235 |
structure_texts = struct_ref[::2]
|
| 236 |
reference_texts = struct_ref[1::2]
|
|
|
|
| 231 |
def remove_output_click(*struct_ref):
|
| 232 |
global visible
|
| 233 |
print("Removing output", visible)
|
| 234 |
+
if visible == 0:
|
| 235 |
+
return struct_ref
|
| 236 |
+
|
| 237 |
visible -= 1
|
| 238 |
structure_texts = struct_ref[::2]
|
| 239 |
reference_texts = struct_ref[1::2]
|