Skip to content

Commit

Permalink
fix: nav and scroll
Browse files Browse the repository at this point in the history
  • Loading branch information
arpowers committed Apr 11, 2024
1 parent edd52cf commit 7c1d806
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion @fiction/core/plugin-router/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ export class FictionRouter<
history,
routes: this.vueRoutes.value,
scrollBehavior(to, from, savedPosition) {
if (to.hash)
if (to.hash !== from.hash && to.hash)
return { el: to.hash, behavior: 'smooth' }
else if (savedPosition)
return savedPosition
Expand Down
2 changes: 1 addition & 1 deletion @fiction/themes/cards/CardSite.vue
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ const primary = vue.computed(() => site.value?.colors.value.primary || getColorS
</script>

<template>
<div class="x-site overflow-y-scroll h-full w-full relative">
<div class="x-site">
<div class="x-font-body bg-theme-0 dark:bg-theme-950 text-theme-1000 dark:text-theme-0" :class="site?.isEditable.value ? '' : ''">
<div
class="x-engine"
Expand Down

0 comments on commit 7c1d806

Please sign in to comment.