Fix stepper checkmarks, error recovery, radio button spacing
- Both steppers now show green checkmark on final step when completed instead of leaving it highlighted as 'current' (blue) - Stems error is cleared at the start of every generate_stems attempt, not just on success — no stale error messages after retry - Radio buttons in stems section use same compact spacing as checkboxes
This commit is contained in:
parent
24838c73ac
commit
9df4c685a4
2 changed files with 11 additions and 5 deletions
|
|
@ -111,7 +111,8 @@
|
|||
margin:.6rem 0;
|
||||
padding:.4rem 0;
|
||||
}
|
||||
.song-row input[type="checkbox"]{
|
||||
.song-row input[type="checkbox"],
|
||||
.song-row input[type="radio"]{
|
||||
width:auto;
|
||||
margin:.2rem 0 0 0;
|
||||
flex-shrink:0;
|
||||
|
|
@ -256,8 +257,9 @@
|
|||
<ol class="steps" aria-label="Request progress">
|
||||
{% for i in range(steps|length) %}
|
||||
{% set key, label = steps[i] %}
|
||||
{% set is_completed = i < current_step %}
|
||||
{% set is_current = i == current_step %}
|
||||
{% set is_last = i == steps|length - 1 %}
|
||||
{% set is_completed = i < current_step or (is_last and current_step == i) %}
|
||||
{% set is_current = i == current_step and not is_last %}
|
||||
<li class="step-item {% if is_completed %}completed{% elif is_current %}current{% else %}upcoming{% endif %}" {% if is_current %}aria-current="step"{% endif %}>
|
||||
<div class="step-indicator">
|
||||
{% if is_completed %}✓{% else %}{{ i + 1 }}{% endif %}
|
||||
|
|
@ -282,10 +284,11 @@
|
|||
{% if mg_steps[j][0] == current_mg %}{% set ns.mg_index = j %}{% endif %}
|
||||
{% endfor %}
|
||||
{% if current_mg in ('FAILED', 'ERROR', 'CANCELLED') %}{% set ns.mg_index = -2 %}{% endif %}
|
||||
{% set mg_completed_step = req.musicgpt_status in ('COMPLETED', 'FINISHED') %}
|
||||
{% for j in range(mg_steps|length) %}
|
||||
{% set mg_key, mg_label = mg_steps[j] %}
|
||||
{% set mg_completed = j < ns.mg_index %}
|
||||
{% set mg_current = j == ns.mg_index %}
|
||||
{% set mg_completed = j < ns.mg_index or mg_completed_step %}
|
||||
{% set mg_current = j == ns.mg_index and not mg_completed_step %}
|
||||
<li class="step-item {% if mg_completed %}completed{% elif mg_current %}current{% else %}upcoming{% endif %} {% if ns.mg_index == -2 and not mg_completed and not mg_current %}upcoming{% endif %}" {% if mg_current %}aria-current="step"{% endif %}>
|
||||
<div class="step-indicator">
|
||||
{% if mg_completed %}✓{% else %}{{ j + 1 }}{% endif %}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue