Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PRD-610] feat: Allow click on searched file's path #2246

Merged
merged 2 commits into from
Nov 13, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/assistant/ResultMenu/SuggestionItemTextSecondary.jsx
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

on peut squash les 2 commits je pense

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

J'ai voulu laisser la contribution de @Ldoppea 😉

Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ import React from 'react'
import AppLinker from 'cozy-ui/transpiled/react/AppLinker'
import SuggestionItemTextHighlighted from './SuggestionItemTextHighlighted'
import useBreakpoints from 'cozy-ui/transpiled/react/providers/Breakpoints'

import styles from './styles.styl'
import Link from 'cozy-ui/transpiled/react/Link'

const SuggestionItemTextSecondary = ({ text, query, url, slug }) => {
const { isMobile } = useBreakpoints()
Expand All @@ -22,8 +21,9 @@ const SuggestionItemTextSecondary = ({ text, query, url, slug }) => {
return (
<AppLinker app={app} href={url}>
{({ href, onClick }) => (
<a
className={styles['suggestion-item-parent-link']}
<Link
color="textSecondary"
underline="hover"
href={href}
onClick={e => {
e.stopPropagation()
Expand All @@ -37,7 +37,7 @@ const SuggestionItemTextSecondary = ({ text, query, url, slug }) => {
query={query}
slug={slug}
/>
</a>
</Link>
)}
</AppLinker>
)
Expand Down
7 changes: 0 additions & 7 deletions src/assistant/ResultMenu/styles.styl
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,3 @@
&-inner
max-height 16.5rem
overflow auto

.suggestion-item-parent-link
color var(--primaryTextColor)
text-decoration none

&:hover
text-decoration underline
Loading