From bdc72e5817782316bb2c56ab362b4aa237236bef Mon Sep 17 00:00:00 2001 From: syuilo <4439005+syuilo@users.noreply.github.com> Date: Wed, 19 Mar 2025 15:17:41 +0900 Subject: clean up --- packages/frontend/src/components/MkPageWindow.vue | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'packages/frontend/src/components/MkPageWindow.vue') diff --git a/packages/frontend/src/components/MkPageWindow.vue b/packages/frontend/src/components/MkPageWindow.vue index 8a1a9c58d2..a6049b4d91 100644 --- a/packages/frontend/src/components/MkPageWindow.vue +++ b/packages/frontend/src/components/MkPageWindow.vue @@ -60,9 +60,8 @@ const windowRouter = routerFactory(props.initialPath); const pageMetadata = ref(null); const windowEl = shallowRef>(); -const history = ref<{ path: string; key: string; }[]>([{ +const history = ref<{ path: string; }[]>([{ path: windowRouter.getCurrentPath(), - key: windowRouter.getCurrentKey(), }]); const buttonsLeft = computed(() => { const buttons: Record[] = []; @@ -100,12 +99,12 @@ function getSearchMarker(path: string) { const searchMarkerId = ref(getSearchMarker(props.initialPath)); windowRouter.addListener('push', ctx => { - history.value.push({ path: ctx.path, key: ctx.key }); + history.value.push({ path: ctx.path }); }); windowRouter.addListener('replace', ctx => { history.value.pop(); - history.value.push({ path: ctx.path, key: ctx.key }); + history.value.push({ path: ctx.path }); }); windowRouter.addListener('change', ctx => { @@ -155,7 +154,7 @@ const contextmenu = computed(() => ([{ function back() { history.value.pop(); - windowRouter.replace(history.value.at(-1)!.path, history.value.at(-1)!.key); + windowRouter.replace(history.value.at(-1)!.path); } function reload() { -- cgit v1.2.3-freya