diff options
| author | syuilo <4439005+syuilo@users.noreply.github.com> | 2025-06-01 10:44:45 +0900 |
|---|---|---|
| committer | syuilo <4439005+syuilo@users.noreply.github.com> | 2025-06-01 10:44:45 +0900 |
| commit | f4167ae7f1df7c2cd4cf264fc4d79d51b8c51133 (patch) | |
| tree | 9f87a9ee76c82176daa4e81f1b117e90ec933f52 /packages/frontend/src/components/MkPostFormAttaches.vue | |
| parent | fix(frontend): remove unused text (diff) | |
| download | misskey-f4167ae7f1df7c2cd4cf264fc4d79d51b8c51133.tar.gz misskey-f4167ae7f1df7c2cd4cf264fc4d79d51b8c51133.tar.bz2 misskey-f4167ae7f1df7c2cd4cf264fc4d79d51b8c51133.zip | |
enhance(frontend): 非同期的なコンポーネントの読み込み時のハンドリングを強化
Diffstat (limited to 'packages/frontend/src/components/MkPostFormAttaches.vue')
| -rw-r--r-- | packages/frontend/src/components/MkPostFormAttaches.vue | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/packages/frontend/src/components/MkPostFormAttaches.vue b/packages/frontend/src/components/MkPostFormAttaches.vue index dd594ef7f1..f429db94df 100644 --- a/packages/frontend/src/components/MkPostFormAttaches.vue +++ b/packages/frontend/src/components/MkPostFormAttaches.vue @@ -126,7 +126,7 @@ async function rename(file) { async function describe(file: Misskey.entities.DriveFile) { if (mock) return; - const { dispose } = os.popup(defineAsyncComponent(() => import('@/components/MkFileCaptionEditWindow.vue')), { + const { dispose } = await os.popupAsyncWithDialog(import('@/components/MkFileCaptionEditWindow.vue').then(x => x.default), { default: file.comment !== null ? file.comment : '', file: file, }, { @@ -168,9 +168,11 @@ function showFileMenu(file: Misskey.entities.DriveFile, ev: MouseEvent | Keyboar menuItems.push({ text: i18n.ts.preview, icon: 'ti ti-photo-search', - action: () => { - os.popup(defineAsyncComponent(() => import('@/components/MkImgPreviewDialog.vue')), { + action: async () => { + const { dispose } = await os.popupAsyncWithDialog(import('@/components/MkImgPreviewDialog.vue').then(x => x.default), { file: file, + }, { + closed: () => dispose(), }); }, }); |