mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-11-16 11:50:42 +08:00
Stop handling URL hash through routing
We stop handling the URL hash through the routing system. Hashes are local to the current view and can be handled by the shown components. Signed-off-by: Thomas Scholtes <geigerzaehler@axiom.fm>
This commit is contained in:
@@ -11,7 +11,6 @@
|
||||
import { Renderer } from "@app/lib/markdown";
|
||||
|
||||
export let content: string;
|
||||
export let hash: string | undefined = undefined;
|
||||
// If present, resolve all relative links with respect to this URL
|
||||
export let linkBaseUrl: string | undefined = undefined;
|
||||
export let path: string = "/";
|
||||
@@ -69,8 +68,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
if (hash) scrollIntoView(hash);
|
||||
|
||||
// Iterate over all images, and replace the source with a canonicalized URL
|
||||
// pointing at the projects /raw endpoint.
|
||||
if (rawPath) {
|
||||
@@ -112,6 +109,10 @@
|
||||
}
|
||||
|
||||
await Promise.allSettled(treeChanges);
|
||||
|
||||
if (window.location.hash) {
|
||||
scrollIntoView(window.location.hash.substring(1));
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user