update
Browse files7883 unmodified lines7884788578867887788878897890852 unmodified lines874387448745874687478748874934 unmodified lines8784878587868787878887898790266 unmodified lines9057905890599060906190629063754 unmodified lines981898199820982198229823982498259826982798289829983098319832983398347883 unmodified linesshow_label=False,height=320,layout="bubble",bubble_full_width=True,group_consecutive_messages=True,visible=False,elem_id="beta_chat"852 unmodified linesshow_progress="hidden",).then(generation_code,inputs=[input, image_input, generation_image_input, file_input, website_url_input, setting, history, current_model, search_toggle, language_dropdown, provider_state, image_generation_toggle, image_to_image_toggle, image_to_image_prompt, text_to_image_prompt, image_to_video_toggle, image_to_video_prompt, text_to_video_toggle, text_to_video_prompt, video_to_video_toggle, video_to_video_prompt, video_input, text_to_music_toggle, text_to_music_prompt, image_video_to_animation_toggle, animation_mode_dropdown, animation_quality_dropdown, animation_video_input, login_button, login_button],outputs=[code_output, history, sandbox, history_output]).then(end_generation_ui,34 unmodified linesshow_progress="hidden",).then(generation_code,inputs=[input, image_input, generation_image_input, file_input, website_url_input, setting, history, current_model, search_toggle, language_dropdown, provider_state, image_generation_toggle, image_to_image_toggle, image_to_image_prompt, text_to_image_prompt, image_to_video_toggle, image_to_video_prompt, text_to_video_toggle, text_to_video_prompt, video_to_video_toggle, video_to_video_prompt, video_input, text_to_music_toggle, text_to_music_prompt, login_button, login_button],outputs=[code_output, history, sandbox, history_output]).then(end_generation_ui,266 unmodified linesshow_progress="hidden",).then(generation_code,inputs=[input, image_input, generation_image_input, file_input, website_url_input, setting, history, current_model, search_toggle, language_dropdown, provider_state, image_generation_toggle, image_to_image_toggle, image_to_image_prompt, text_to_image_prompt, image_to_video_toggle, image_to_video_prompt, text_to_video_toggle, text_to_video_prompt, video_to_video_toggle, video_to_video_prompt, video_input, text_to_music_toggle, text_to_music_prompt, image_video_to_animation_toggle, animation_mode_dropdown, animation_quality_dropdown, animation_video_input, login_button, login_button],outputs=[code_output, history, sandbox, history_output]).then(end_generation_ui,754 unmodified lines# Keep the old deploy method as fallback (if not logged in, user can still use the old method)# Optionally, you can keep the old deploy_btn.click for the default method as a secondary button.# Handle login status changes to update UIlogin_button.login(update_ui_for_auth_status,inputs=[login_button, login_button],outputs=[input, btn, auth_status],queue=False)login_button.logout(update_ui_for_auth_status,inputs=[login_button, login_button],outputs=[input, btn, auth_status],queue=False)7883 unmodified lines788478857886788778887889852 unmodified lines874287438744874587468747874834 unmodified lines8783878487858786878787888789266 unmodified lines9056905790589059906090619062754 unmodified lines981798189819982098219822982398249825982698277883 unmodified linesshow_label=False,height=320,layout="bubble",group_consecutive_messages=True,visible=False,elem_id="beta_chat"852 unmodified linesshow_progress="hidden",).then(generation_code,inputs=[input, image_input, generation_image_input, file_input, website_url_input, setting, history, current_model, search_toggle, language_dropdown, provider_state, image_generation_toggle, image_to_image_toggle, image_to_image_prompt, text_to_image_prompt, image_to_video_toggle, image_to_video_prompt, text_to_video_toggle, text_to_video_prompt, video_to_video_toggle, video_to_video_prompt, video_input, text_to_music_toggle, text_to_music_prompt, image_video_to_animation_toggle, animation_mode_dropdown, animation_quality_dropdown, animation_video_input],outputs=[code_output, history, sandbox, history_output]).then(end_generation_ui,34 unmodified linesshow_progress="hidden",).then(generation_code,inputs=[input, image_input, generation_image_input, file_input, website_url_input, setting, history, current_model, search_toggle, language_dropdown, provider_state, image_generation_toggle, image_to_image_toggle, image_to_image_prompt, text_to_image_prompt, image_to_video_toggle, image_to_video_prompt, text_to_video_toggle, text_to_video_prompt, video_to_video_toggle, video_to_video_prompt, video_input, text_to_music_toggle, text_to_music_prompt],outputs=[code_output, history, sandbox, history_output]).then(end_generation_ui,266 unmodified linesshow_progress="hidden",).then(generation_code,inputs=[input, image_input, generation_image_input, file_input, website_url_input, setting, history, current_model, search_toggle, language_dropdown, provider_state, image_generation_toggle, image_to_image_toggle, image_to_image_prompt, text_to_image_prompt, image_to_video_toggle, image_to_video_prompt, text_to_video_toggle, text_to_video_prompt, video_to_video_toggle, video_to_video_prompt, video_input, text_to_music_toggle, text_to_music_prompt, image_video_to_animation_toggle, animation_mode_dropdown, animation_quality_dropdown, animation_video_input],outputs=[code_output, history, sandbox, history_output]).then(end_generation_ui,754 unmodified lines# Keep the old deploy method as fallback (if not logged in, user can still use the old method)# Optionally, you can keep the old deploy_btn.click for the default method as a secondary button.# Handle login/logout button clicks to update UI# The LoginButton automatically handles OAuth flow, we just need to update UI on clicklogin_button.click(update_ui_for_auth_status,inputs=[],outputs=[input, btn, auth_status],queue=False)
app.py+7-14