From d59753baa592e4ae22507d756eb56f0a0c284d71 Mon Sep 17 00:00:00 2001 From: Stephanie Smith Date: Sun, 15 Sep 2024 23:08:48 -0700 Subject: [PATCH] removing domain from search results urls to ensure router links (#619) --- .../vue/src/components/SearchResultsList/SearchResultsList.vue | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/vue/src/components/SearchResultsList/SearchResultsList.vue b/packages/vue/src/components/SearchResultsList/SearchResultsList.vue index 35d721f8..b6e3207b 100644 --- a/packages/vue/src/components/SearchResultsList/SearchResultsList.vue +++ b/packages/vue/src/components/SearchResultsList/SearchResultsList.vue @@ -192,7 +192,10 @@ export default defineComponent({ page.content_type = handle page.id = page._id page.score = page._score + // ensure router links page.url = page._source.url + ? page._source.url.replace(/^[^:]+:\/\/[^/?#]+/, '') + : undefined page.title = page._source.title page.type = pageType page.topic = topic