ui: use hidden state for wizard streaming panels

This commit is contained in:
a.tolmachev
2026-05-02 14:40:58 +00:00
parent 4203c34dcf
commit 4256d16426
2 changed files with 9 additions and 9 deletions
+5 -5
View File
@@ -1718,7 +1718,7 @@ function updateStreamingConfigVisibility() {
if (!node) return;
var group = node.closest('.form-group') || node.closest('.checkbox-pill');
if (group) {
group.style.display = isUnary ? 'none' : '';
group.hidden = isUnary;
}
});
@@ -1732,8 +1732,8 @@ function updateStreamingConfigVisibility() {
: tKey('wizard.streaming.help.window')));
}
if (toolFamily) toolFamily.style.display = (isSession || isAsyncJob) ? '' : 'none';
if (asyncRow) asyncRow.style.display = isAsyncJob ? '' : 'none';
if (toolFamily) toolFamily.hidden = !(isSession || isAsyncJob);
if (asyncRow) asyncRow.hidden = !isAsyncJob;
ensureStreamingToolFamilyDefaults(mode);
}
@@ -2213,7 +2213,7 @@ async function runWizardLiveAction(button, busyLabel, handler) {
function updateWizardProtocolVisibility() {
var grpcTools = document.getElementById('wizard-grpc-live-tools');
if (grpcTools) grpcTools.style.display = wizardProtocol === 'grpc' ? '' : 'none';
if (grpcTools) grpcTools.hidden = wizardProtocol !== 'grpc';
updateStreamingModeOptions();
updateStreamingConfigVisibility();
}
@@ -2225,7 +2225,7 @@ function showWizardLiveStatus(title, text, isError) {
if (!root || !titleEl || !textEl) return;
titleEl.textContent = title;
textEl.textContent = text;
root.style.display = '';
root.hidden = false;
root.classList.toggle('is-error', !!isError);
root.classList.toggle('is-success', !isError);
}