From c9391d67eb56de72d25a76e21fe2ef134532c902 Mon Sep 17 00:00:00 2001 From: Vladimir Mandic Date: Fri, 21 Mar 2025 21:17:41 -0400 Subject: [PATCH] video tab modernui layout Signed-off-by: Vladimir Mandic --- CHANGELOG.md | 2 +- TODO.md | 8 -------- extensions-builtin/sdnext-modernui | 2 +- javascript/imageParams.js | 1 + javascript/progressBar.js | 2 ++ javascript/sdnext.css | 8 ++++---- modules/video_models/models_def.py | 4 ++-- scripts/prompt_enhance.py | 2 +- 8 files changed, 12 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f98afce51..71a623c51 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,7 +14,7 @@ - Video: HunyuanVideo-I2V incompatible with latest transformers - Video: FasterCache and PyramidAttentionBroadcast granular config - Video: FasterCache and PyramidAttentionBroadcast for LTX and WAN - - Video: HunyuanVideo-I2V-16ch + - Video: HunyuanVideo-I2V-16/33ch - Video: CogVideo-15 support ### Highlights for 2025-03-21 diff --git a/TODO.md b/TODO.md index f262d8b78..0575e97c7 100644 --- a/TODO.md +++ b/TODO.md @@ -4,14 +4,6 @@ Main ToDo list can be found at [GitHub projects](https://github.com/users/vladma ## Current -- Video tab: - - remote vae - - tiny vae - - lora - - accelerators: teacache, pab, fastercache, paraattention, perflow - - modernui tab -- Detailer daemon: https://github.com/muerrilla/sd-webui-detail-daemon/blob/main/scripts/detail_daemon.py - ## Future Candidates - Redesign postprocessing diff --git a/extensions-builtin/sdnext-modernui b/extensions-builtin/sdnext-modernui index a9e015993..4d0bde42e 160000 --- a/extensions-builtin/sdnext-modernui +++ b/extensions-builtin/sdnext-modernui @@ -1 +1 @@ -Subproject commit a9e015993194fe7b7c6222c9f32efbb557287a67 +Subproject commit 4d0bde42e95c801dba3a48b9161e12b8ddc5d5bd diff --git a/javascript/imageParams.js b/javascript/imageParams.js index 9ac42ace2..69057ba5e 100644 --- a/javascript/imageParams.js +++ b/javascript/imageParams.js @@ -9,6 +9,7 @@ async function initDragDrop() { if (tab === 0) promptTarget = 'txt2img_prompt_image'; else if (tab === 1) promptTarget = 'img2img_prompt_image'; else if (tab === 2) promptTarget = 'control_prompt_image'; + else if (tab === 3) promptTarget = 'video_prompt_image'; else return; const imgParent = gradioApp().getElementById(promptTarget); const fileInput = imgParent.querySelector('input[type="file"]'); diff --git a/javascript/progressBar.js b/javascript/progressBar.js index cfc9a9039..1edcbb501 100644 --- a/javascript/progressBar.js +++ b/javascript/progressBar.js @@ -14,9 +14,11 @@ function checkPaused(state) { lastState.paused = state ? !state : !lastState.paused; const t_el = document.getElementById('txt2img_pause'); const i_el = document.getElementById('img2img_pause'); + const c_el = document.getElementById('control_pause'); const v_el = document.getElementById('video_pause'); if (t_el) t_el.innerText = lastState.paused ? 'Resume' : 'Pause'; if (i_el) i_el.innerText = lastState.paused ? 'Resume' : 'Pause'; + if (c_el) c_el.innerText = lastState.paused ? 'Resume' : 'Pause'; if (v_el) v_el.innerText = lastState.paused ? 'Resume' : 'Pause'; } diff --git a/javascript/sdnext.css b/javascript/sdnext.css index ec5e4fa3d..10f1f66d4 100644 --- a/javascript/sdnext.css +++ b/javascript/sdnext.css @@ -102,13 +102,13 @@ button.custom-button { border-radius: var(--button-large-radius); padding: var(- #txt2img_prompt_container, #img2img_prompt_container, #control_prompt_container, #video_prompt_container { margin-right: var(--layout-gap) } #txt2img_footer, #img2img_footer, #control_footer { height: fit-content; display: none; } #txt2img_generate_box, #img2img_generate_box { gap: 0.5em; flex-wrap: unset; min-width: unset; width: 66.6%; } -#control_generate_box { gap: 0.5em; flex-wrap: unset; min-width: unset; width: 100%; } -#control_generate_box button:nth-child(1) { flex-grow: 2; } -#control_generate_box button:nth-child(2) { flex-grow: 1; } +#control_generate_box, #video_generate_box { gap: 0.5em; flex-wrap: unset; min-width: unset; width: 100%; } +#control_generate_box button:nth-child(1), #video_generate_box button:nth-child(1) { flex-grow: 2; } +#control_generate_box button:nth-child(2), #video_generate_box button:nth-child(2) { flex-grow: 1; } #txt2img_actions_column, #img2img_actions_column, #control_actions_column, #video_actions_column { gap: 0.3em; height: fit-content; } #txt2img_generate_box>button, #img2img_generate_box>button, #control_generate_box>button, #video_generate_box>button, #txt2img_enqueue, #img2img_enqueue, #txt2img_enqueue>button, #img2img_enqueue>button { min-height: 44px !important; max-height: 44px !important; line-height: 1em; white-space: break-spaces; min-width: unset; } #txt2img_enqueue_wrapper, #img2img_enqueue_wrapper, #control_enqueue_wrapper { min-width: unset !important; width: 31%; } -#txt2img_generate_line2, #img2img_generate_line2, #txt2img_tools, #img2img_tools, #control_generate_line2, #control_tools { display: flex; } +#txt2img_generate_line2, #img2img_generate_line2, #txt2img_tools, #img2img_tools, #control_generate_line2, #control_tools, #video_generate_line2, #video_tools { display: flex; } #txt2img_generate_line2>button, #img2img_generate_line2>button, #extras_generate_box>button, #control_generate_line2>button, #txt2img_tools>button, #img2img_tools>button, #control_tools>button { height: 2em; line-height: 0; font-size: var(--text-md); min-width: unset; display: block !important; } #txt2img_prompt, #txt2img_neg_prompt, #img2img_prompt, #img2img_neg_prompt, #control_prompt, #control_neg_prompt, #video_prompt, #video_neg_prompt { display: contents; } diff --git a/modules/video_models/models_def.py b/modules/video_models/models_def.py index da0ff8cc2..8c1c3f81a 100644 --- a/modules/video_models/models_def.py +++ b/modules/video_models/models_def.py @@ -15,9 +15,9 @@ import transformers - LTXVideo 0.9.5 T2V: pass/pass/fail, v095 pipeline is tbd - LTXVideo 0.9.5 I2V: pass/pass/fail, v095 pipeline is tbd - LTXVideo 0.9.1 T2V: pass/pass/pass -- LTXVideo 0.9.1 I2V: pass/pass/tbd +- LTXVideo 0.9.1 I2V: pass/pass/pass - LTXVideo 0.9.0 T2V: pass/pass/pass -- LTXVideo 0.9.0 I2V: pass/pass/tbd +- LTXVideo 0.9.0 I2V: pass/pass/pass - WAN 2.1 1.3B T2V: pass/pass/pass - WAN 2.1 14B T2V: pass/pass/pass diff --git a/scripts/prompt_enhance.py b/scripts/prompt_enhance.py index 0ad17bba4..17613964a 100644 --- a/scripts/prompt_enhance.py +++ b/scripts/prompt_enhance.py @@ -95,5 +95,5 @@ class Script(scripts.Script): shared.log.debug(f'Prompt enhance: prompt="{p.prompt}"') def after_component(self, component, **kwargs): # searching for actual ui prompt components - if getattr(component, 'elem_id', '') in ['txt2img_prompt', 'img2img_prompt', 'control_prompt']: + if getattr(component, 'elem_id', '') in ['txt2img_prompt', 'img2img_prompt', 'control_prompt', 'video_prompt']: self.prompt = component