Spaces:
Sleeping
Sleeping
Update app2.py
Browse files91 unmodified lines9293949596959697983 unmodified lines10210310410610510610710810910911011111291 unmodified lines buttons_to_add.append(option) # Add to header if not already present filter_list.value = [] # Clear the selected options after adding them to the header update_header() # Update the header after adding options print("This is the button list2:", buttons_to_add, flush=True) run_tldr = partial(run_code, buttons_to_add) add_to_header_button.on_click(add_to_header)
# Function to update the header layout with the newly created buttons3 unmodified lines header_button = pn.widgets.Button(name=button_name, button_type = 'primary', button_style = 'outline') header_button.on_click(remove_from_header) # Add callback to remove the header button header_buttons.append(header_button)
print("This is the button list2:", buttons_to_add, flush=True) run_tldr = partial(run_code, buttons_to_add) # Update the filter list options to exclude buttons that are already in the header filter_list.options = [option for option in entered_options if option not in buttons_to_add] print("This is the button list1:", flush=True)
app2.py+4-4