Reserve space for window controls and split the titlebar clusters so brand and chrome no longer collide. Replace the full-screen status spinner with lightweight activity jobs in the event tray.
This commit is contained in:
+35
-1
@@ -4,7 +4,16 @@
|
||||
*/
|
||||
import { manager, Methods } from '../client/manager.js'
|
||||
import { presentError, explainError } from '../client/errors.js'
|
||||
import { runJob, renderJobPanel, subscribeJobs, listJobs } from '../client/jobs.js'
|
||||
import {
|
||||
runJob,
|
||||
renderJobPanel,
|
||||
subscribeJobs,
|
||||
listJobs,
|
||||
showActivity as jobsShowActivity,
|
||||
updateActivity as jobsUpdateActivity,
|
||||
completeActivity as jobsCompleteActivity,
|
||||
getJob,
|
||||
} from '../client/jobs.js'
|
||||
import {
|
||||
warmSnapshot,
|
||||
clearSnapshotCache,
|
||||
@@ -144,6 +153,28 @@ export function dismissJobDrawer(drawer) {
|
||||
}, JOB_EXIT_ANIM_MS)
|
||||
}
|
||||
|
||||
/** Activity helpers for uiUtils (replace full-screen spinners) */
|
||||
export function showActivity(message) {
|
||||
const job = jobsShowActivity(message)
|
||||
showJob(job)
|
||||
return job
|
||||
}
|
||||
|
||||
export function updateActivity(message) {
|
||||
const job = jobsUpdateActivity(message)
|
||||
if (job) showJob(job)
|
||||
return job
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {boolean} [ok=true]
|
||||
*/
|
||||
export function completeActivity(ok = true) {
|
||||
const job = jobsCompleteActivity(ok)
|
||||
if (job) showJob(job)
|
||||
return job
|
||||
}
|
||||
|
||||
/**
|
||||
* Deploy container with step visibility (uses deployContainer RPC).
|
||||
*/
|
||||
@@ -575,6 +606,9 @@ export function initOpsApp({ navigateToView, sendCommand }) {
|
||||
appendLiveEvent,
|
||||
dismissJobDrawer,
|
||||
showJob,
|
||||
showActivity,
|
||||
updateActivity,
|
||||
completeActivity,
|
||||
explainError,
|
||||
presentError: (err, method) => presentError(err, method, { showAlert, notificationManager }),
|
||||
statusBadge,
|
||||
|
||||
Reference in New Issue
Block a user