From 96bc042d67a6175e0d899b7f7ce7d13de3a0dbf2 Mon Sep 17 00:00:00 2001 From: syuilo <4439005+syuilo@users.noreply.github.com> Date: Fri, 9 May 2025 19:41:54 +0900 Subject: Feat: サーバー初期設定ウィザード (#15954) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * wip * wip * Update welcome.setup.vue * wip * wip * wip * wip * Update MkServerSetupWizard.vue * Update MkServerSetupWizard.vue * wip * wip * wip * Update types.ts * wip * wip * Update CHANGELOG.md --- packages/frontend/src/os.ts | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) (limited to 'packages/frontend/src/os.ts') diff --git a/packages/frontend/src/os.ts b/packages/frontend/src/os.ts index 813b49635d..d891525782 100644 --- a/packages/frontend/src/os.ts +++ b/packages/frontend/src/os.ts @@ -547,18 +547,24 @@ export function success(): Promise { }); } -export function waiting(text?: string | null): Promise { - return new Promise(resolve => { - const showing = ref(true); - const { dispose } = popup(MkWaitingDialog, { - success: false, - showing: showing, - text, - }, { - done: () => resolve(), - closed: () => dispose(), - }); +export function waiting(text?: string | null): () => void { + window.document.body.setAttribute('inert', 'true'); + + const showing = ref(true); + const { dispose } = popup(MkWaitingDialog, { + success: false, + showing: showing, + text, + }, { + closed: () => { + window.document.body.removeAttribute('inert'); + dispose(); + }, }); + + return () => { + showing.value = false; + }; } export function form(title: string, f: F): Promise<{ canceled: true, result?: undefined } | { canceled?: false, result: GetFormResultType }> { -- cgit v1.2.3-freya