Skip to content

Commit

Permalink
yarn lint-fix
Browse files Browse the repository at this point in the history
  • Loading branch information
RONAK-AI647 committed Dec 16, 2024
1 parent b295d9e commit bfb7973
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 30 deletions.
17 changes: 8 additions & 9 deletions docs/common/DocsLibraryLink.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>

<router-link :to="computedLink">
<router-link :to="computedLink">
<code>{{ component }}</code>
</router-link>

Expand All @@ -18,15 +18,14 @@
},
},
computed: {
computedLink() {
// Preserve query parameters in the link
return {
path: '/' + this.component.toLowerCase(),
query: { ...this.$route.query },
};
},
computedLink() {
// Preserve query parameters in the link
return {
path: '/' + this.component.toLowerCase(),
query: { ...this.$route.query },
};
},
},
};
</script>
16 changes: 8 additions & 8 deletions docs/common/DocsPageTemplate/SideNav/NavLink.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</div>
<router-link
v-else
:to="computedLink"
:to="computedLink"
class="block enabled-link"
:href="page.path"
:class="{ 'current-page': currentPage, code: page.isCode }"
Expand Down Expand Up @@ -40,13 +40,13 @@
currentPage() {
return this.page.path === this.$route.path;
},
computedLink() {
// Preserve query parameters in the link
return {
path: this.page.path,
query: { ...this.$route.query },
};
},
computedLink() {
// Preserve query parameters in the link
return {
path: this.page.path,
query: { ...this.$route.query },
};
},
},
};
Expand Down
13 changes: 0 additions & 13 deletions docs/common/DocsPageTemplate/SideNav/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -126,19 +126,6 @@
}, 2000); // 2-second debounce delay
}
// // Modify navigation links to preserve the filter query
// this.$nextTick(() => {
// this.$refs.links.querySelectorAll('a').forEach(link => {
// link.addEventListener('click', event => {
// event.preventDefault();
// const href = new URL(link.href);
// this.$router.push({
// path: href.pathname,
// query: { ...this.$route.query }, // Add existing query params to the new path
// });
// });
// });
// });
// Don't show the nav until the state is set
this.loaded = true;
},
Expand Down

0 comments on commit bfb7973

Please sign in to comment.