Refine Python tools task interface
Build custom container images / build (map[base_image:php:8-fpm-alpine build_args:PHP_VERSION=8 context:php8-pgsql fingerprint_command:{ apk info -v | LC_ALL=C sort; find /usr/local/lib/php/extensions /usr/local/etc/php/conf.d -type f -exec sha256sum {} + | LC_ALL=C sort; } name:ph… (push) Successful in 39s
Build custom container images / build (map[base_image:postgres:18 build_args:PG_VERSION=18 POSTGIS_VERSION=3 VCHORD_VERSION=0.5.3 context:postgres fingerprint_command:{ dpkg-query -W -f='${binary:Package}=${Version}\n' | LC_ALL=C sort; find /usr/lib/postgresql -type f -exec sha256su… (push) Successful in 53s
Build custom container images / build (map[base_image:python:3 build_args:PYTHON_VERSION=3 context:python-tools fingerprint_command:{ dpkg-query -W -f='${binary:Package}=${Version}\n' | LC_ALL=C sort; pip freeze | LC_ALL=C sort; } name:python-tools oci_labels:org.opencontainers.ima… (push) Successful in 1m17s

This commit is contained in:
ajp_anton
2026-08-18 04:21:11 +00:00
parent b256147d28
commit 7e6dea8b24
11 changed files with 311 additions and 95 deletions
+32 -12
View File
@@ -37,8 +37,15 @@ const refreshArtifacts = async (container) => {
for (const artifact of artifacts) {
const item = document.createElement("li");
const link = document.createElement("a");
link.href = artifact.url;
link.textContent = artifact.name;
if (artifact.view_url) {
link.href = artifact.view_url;
link.target = "_blank";
link.rel = "noopener";
link.textContent = `Open ${artifact.name}`;
} else {
link.href = artifact.url;
link.textContent = `Download ${artifact.name}`;
}
item.append(link);
list.append(item);
}
@@ -51,15 +58,24 @@ for (const container of document.querySelectorAll("#run-artifacts")) {
window.setInterval(() => refreshArtifacts(container), 2000);
}
for (const control of document.querySelectorAll("select[data-execution-mode]")) {
const buttonLabel = control.closest("form")?.querySelector(".task-action .button-label");
const updateButtonLabel = () => {
if (buttonLabel && control.selectedOptions[0]) {
buttonLabel.textContent = control.selectedOptions[0].textContent;
for (const choice of document.querySelectorAll("button[data-execution-choice]")) {
choice.addEventListener("click", () => {
const control = choice.closest(".split-button");
const value = control?.querySelector("input[data-execution-value]");
const label = control?.querySelector(".button-label");
if (!control || !value || !label) {
return;
}
};
control.addEventListener("change", updateButtonLabel);
updateButtonLabel();
value.value = choice.dataset.value || "";
label.textContent = choice.dataset.label || "Run";
control.querySelectorAll("button[data-execution-choice]").forEach((option) => {
option.setAttribute("aria-pressed", String(option === choice));
});
const menu = control.querySelector("details");
if (menu) {
menu.open = false;
}
});
}
for (const form of document.querySelectorAll("form[data-wait-for-result]")) {
@@ -78,6 +94,9 @@ for (const form of document.querySelectorAll("form[data-wait-for-result]")) {
controls.forEach((control) => {
control.disabled = value;
});
form.querySelectorAll("details.split-menu").forEach((menu) => {
menu.open = false;
});
if (value) {
window.addEventListener("beforeunload", warnBeforeLeaving);
} else {
@@ -103,11 +122,12 @@ for (const form of document.querySelectorAll("form[data-wait-for-result]")) {
return;
}
const artifacts = (await response.json()).artifacts;
if (!artifacts.length) {
const artifact = artifacts.find((item) => !item.view_url);
if (!artifact) {
return;
}
const link = document.createElement("a");
link.href = artifacts[0].url;
link.href = artifact.url;
link.download = "";
document.body.append(link);
link.click();