Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions internal/httpapi/web/dist/views/projects.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,9 @@ function renderWorkflowEditorBody(lanes, listId = "workflowModalLaneList", ghost
</div>
`).join("")}
</div>
<div class="row">
<input class="input" id="${escapeHTML(ghostId)}" placeholder="Add lane..." />
<div class="row" style="gap:8px;align-items:center;">
<input class="input" id="${escapeHTML(ghostId)}" placeholder="Add lane..." style="flex:1;min-width:0;" />
<button type="button" class="btn btn--small" id="workflowModalGhostAdd" aria-label="Add lane">Add</button>
</div>
`;
}
Expand Down Expand Up @@ -183,6 +184,7 @@ function createWorkflowEditorRenderer() {
onLanesChange();
});
});
const ghostAddBtn = container.querySelector("#workflowModalGhostAdd");
if (ghostInput) {
const commitGhostLane = () => {
const text = (ghostInput.value || "").trim();
Expand All @@ -191,15 +193,18 @@ function createWorkflowEditorRenderer() {
insertLaneBeforeDone(lanes, text);
ghostInput.value = "";
onLanesChange();
requestAnimationFrame(() => {
const next = container.querySelector(`#${ghostId}`);
next?.focus();
});
};
ghostInput.addEventListener("keydown", (e) => {
if (e.key === "Enter") {
e.preventDefault();
commitGhostLane();
}
});
ghostInput.addEventListener("input", () => { commitGhostLane(); });
ghostInput.addEventListener("blur", () => { commitGhostLane(); });
ghostAddBtn?.addEventListener("click", () => { commitGhostLane(); });
}
if (list && typeof Sortable !== "undefined") {
sortableInstance = Sortable.create(list, {
Expand Down
13 changes: 9 additions & 4 deletions internal/httpapi/web/modules/views/projects.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,9 @@ function renderWorkflowEditorBody(
</div>
`).join("")}
</div>
<div class="row">
<input class="input" id="${escapeHTML(ghostId)}" placeholder="Add lane..." />
<div class="row" style="gap:8px;align-items:center;">
<input class="input" id="${escapeHTML(ghostId)}" placeholder="Add lane..." style="flex:1;min-width:0;" />
<button type="button" class="btn btn--small" id="workflowModalGhostAdd" aria-label="Add lane">Add</button>
</div>
`;
}
Expand Down Expand Up @@ -201,19 +202,23 @@ function createWorkflowEditorRenderer() {
});
});

const ghostAddBtn = container.querySelector("#workflowModalGhostAdd") as HTMLButtonElement | null;
if (ghostInput) {
const commitGhostLane = () => {
const text = (ghostInput.value || "").trim();
if (!text) return;
insertLaneBeforeDone(lanes, text);
ghostInput.value = "";
onLanesChange();
requestAnimationFrame(() => {
const next = container.querySelector(`#${ghostId}`) as HTMLInputElement | null;
next?.focus();
});
};
ghostInput.addEventListener("keydown", (e) => {
if (e.key === "Enter") { e.preventDefault(); commitGhostLane(); }
});
ghostInput.addEventListener("input", () => { commitGhostLane(); });
ghostInput.addEventListener("blur", () => { commitGhostLane(); });
ghostAddBtn?.addEventListener("click", () => { commitGhostLane(); });
}

if (list && typeof Sortable !== "undefined") {
Expand Down
2 changes: 1 addition & 1 deletion internal/version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ package version
//
// Convention: Update when releasing (e.g., "1.0.0", "1.1.0"); match git tags
// (e.g., tag "v1.0.0" should have Version = "1.0.0").
const Version = "3.5.6"
const Version = "3.5.7"

// ExportFormatVersion is the version of the backup/export data format.
// Only increment this when the ExportData structure changes in a breaking way.
Expand Down
Loading