Skip to content

Commit

Permalink
Improve passing of search path through dashboard links
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelBurgess committed Feb 28, 2024
1 parent dba7814 commit e0f4ec2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ const PowerpipeLogo = () => {
<div className="mr-1 md:mr-4">
<ExternalLink
ignoreDataMode
to={`/${searchPathPrefix ? `?search_path_prefix=${searchPathPrefix}` : ""}`}
to={`/${!!searchPathPrefix.length ? `?search_path_prefix=${searchPathPrefix}` : ""}`}
>
<div className="block md:hidden w-8">
{theme.name === ThemeNames.STEAMPIPE_DEFAULT && <Logo />}
Expand Down
4 changes: 2 additions & 2 deletions ui/dashboard/src/components/DashboardList/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ const TitlePart = ({ part, searchPathPrefix }) => {
<ExternalLink
className="link-highlight hover:underline"
ignoreDataMode
to={`/${part.full_name}${searchPathPrefix ? `?search_path_prefix=${searchPathPrefix}` : ""}`}
to={`/${part.full_name}${!!searchPathPrefix.length ? `?search_path_prefix=${searchPathPrefix}` : ""}`}
>
{part.title || part.short_name}
</ExternalLink>
Expand All @@ -98,7 +98,7 @@ const BenchmarkTitle = ({ benchmark, searchValue, searchPathPrefix }) => {
<ExternalLink
className="link-highlight hover:underline"
ignoreDataMode
to={`/${benchmark.full_name}${searchPathPrefix ? `?search_path_prefix=${searchPathPrefix}` : ""}`}
to={`/${benchmark.full_name}${!!searchPathPrefix.length ? `?search_path_prefix=${searchPathPrefix}` : ""}`}
>
{benchmark.title || benchmark.short_name}
</ExternalLink>
Expand Down

0 comments on commit e0f4ec2

Please sign in to comment.