Skip to content

Commit 59e4ffd

Browse files
committed
fix: prevent section deselection on route change if navigating between section blocks
1 parent 512834b commit 59e4ffd

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

resources/assets/editor/views/[section].vue

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,10 @@
4242
store.selectSection(route.params.section);
4343
});
4444
45-
onBeforeRouteLeave(() => {
46-
store.deselectSection(route.params.section);
45+
onBeforeRouteLeave((to, from) => {
46+
if (!(to.params as any).section) {
47+
store.deselectSection(route.params.section);
48+
}
4749
});
4850
4951
function goBack() {

src/Settings/Support/ImageValue.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,6 @@ private function getSizedUrl(string $size): string
4343
return $this->url;
4444
}
4545

46-
return url("cache/{$size}/" . $this->path);
46+
return url("cache/{$size}/".$this->path);
4747
}
4848
}

0 commit comments

Comments
 (0)