remove utm marks
This commit is contained in:
@@ -1,7 +1,14 @@
|
|||||||
|
'use client'
|
||||||
|
|
||||||
import { SearchItem } from './file-search-panel'
|
import { SearchItem } from './file-search-panel'
|
||||||
|
|
||||||
export function SearchedGlobalFilesList({ list }: { list: SearchItem[] }) {
|
export function SearchedGlobalFilesList({ list }: { list: SearchItem[] }) {
|
||||||
|
|
||||||
|
const cleanUrlForDisplay = (url: string) => {
|
||||||
|
if (!url) return '#';
|
||||||
|
return url.split('?')[0];
|
||||||
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
{list.map(
|
{list.map(
|
||||||
@@ -35,8 +42,8 @@ export function SearchedGlobalFilesList({ list }: { list: SearchItem[] }) {
|
|||||||
<div className="global-result-passage">
|
<div className="global-result-passage">
|
||||||
{item?.pageTitle}
|
{item?.pageTitle}
|
||||||
</div>
|
</div>
|
||||||
<a href={item?.pageUrl} target="_blank" className="global-result-url" title={item?.pageUrl}>
|
<a href={item?.pageUrl ? cleanUrlForDisplay(item?.pageUrl) : ''} target="_blank" className="global-result-url" title={item?.pageUrl ? cleanUrlForDisplay(item?.pageUrl) : ''}>
|
||||||
{item?.pageUrl}
|
{item?.pageUrl ? cleanUrlForDisplay(item?.pageUrl) : ''}
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user